From: Christoph Hellwig <hch@lst.de>
To: "Darrick J. Wong" <djwong@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>,
chandan.babu@oracle.com, linux-xfs@vger.kernel.org
Subject: Re: [PATCH] xfs: ensure st_blocks never goes to zero during COW writes
Date: Wed, 21 Aug 2024 06:46:31 +0200 [thread overview]
Message-ID: <20240821044631.GA27814@lst.de> (raw)
In-Reply-To: <20240821044427.GU865349@frogsfrogsfrogs>
On Tue, Aug 20, 2024 at 09:44:27PM -0700, Darrick J. Wong wrote:
> > Signed-off-by: Christoph Hellwig <hch@lst.de>
>
> How hard is it to hit this race?a I guess all you have to do is statx
> in a loop while doing a bunch of cow writeback?
Yes. That's essential what generic/615 is doing. Now without always_cow
you'd need to do this on freshly reflinked inodes, which makes the
reproducer a bit harder to create.
> > ip->i_nblocks += len;
> > + ip->i_delayed_blks -= len;
>
> This proabably ought to have a comment to reference xfs_bmap_defer_add.
Ok.
> > bi->bi_owner = *ipp;
> > xfs_bmap_update_get_group(mp, bi);
> >
> > + /* see __xfs_bmap_add for details */
>
> xfs_bmap_defer_add?
Yes.
prev parent reply other threads:[~2024-08-21 4:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-20 16:29 [PATCH] xfs: ensure st_blocks never goes to zero during COW writes Christoph Hellwig
2024-08-21 4:44 ` Darrick J. Wong
2024-08-21 4:46 ` Christoph Hellwig [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240821044631.GA27814@lst.de \
--to=hch@lst.de \
--cc=chandan.babu@oracle.com \
--cc=djwong@kernel.org \
--cc=linux-xfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox