From: Brian Foster <bfoster@redhat.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 1/4] xfs: drop submit side trans alloc for append ioends
Date: Wed, 7 Apr 2021 07:23:46 -0400 [thread overview]
Message-ID: <YG2WQhu3GcXwIgmO@bfoster> (raw)
In-Reply-To: <20210407063321.GB3339217@infradead.org>
On Wed, Apr 07, 2021 at 07:33:21AM +0100, Christoph Hellwig wrote:
> > @@ -182,12 +155,10 @@ xfs_end_ioend(
> > error = xfs_reflink_end_cow(ip, offset, size);
> > else if (ioend->io_type == IOMAP_UNWRITTEN)
> > error = xfs_iomap_write_unwritten(ip, offset, size, false);
> > - else
> > - ASSERT(!xfs_ioend_is_append(ioend) || ioend->io_private);
>
> I first though we'd now call xfs_setfilesize for unwritten extents
> as well, but as those have already updated di_size we are fine here.
>
> As a future enhancement it would be useful to let xfs_reflink_end_cow
> update the file size similar to what we do for the unwritten case.
>
Agreed. I noticed that when first passing through the code but didn't
want to get into further functional changes.
> > done:
> > - if (ioend->io_private)
> > - error = xfs_setfilesize_ioend(ioend, error);
> > + if (!error && xfs_ioend_is_append(ioend))
> > + error = xfs_setfilesize(ip, ioend->io_offset, ioend->io_size);
> > iomap_finish_ioends(ioend, error);
>
> The done label can move after the call to xfs_setfilesize now.
>
Fixed.
> Otherwise looks good:
>
> Reviewed-by: Christoph Hellwig <hch@lst.de>
>
Thanks.
Brian
next prev parent reply other threads:[~2021-04-07 11:23 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-05 14:58 [PATCH 0/4] xfs: ioend batching log reservation deadlock Brian Foster
2021-04-05 14:59 ` [PATCH 1/4] xfs: drop submit side trans alloc for append ioends Brian Foster
2021-04-07 6:33 ` Christoph Hellwig
2021-04-07 11:23 ` Brian Foster [this message]
2021-04-07 15:31 ` Darrick J. Wong
2021-04-09 13:47 ` Brian Foster
2021-04-09 16:07 ` Darrick J. Wong
2021-04-05 14:59 ` [PATCH 2/4] xfs: open code ioend needs workqueue helper Brian Foster
2021-04-07 6:34 ` Christoph Hellwig
2021-04-07 11:24 ` Brian Foster
2021-04-07 15:23 ` Darrick J. Wong
2021-04-07 15:42 ` Darrick J. Wong
2021-04-05 14:59 ` [PATCH 3/4] xfs: drop unused ioend private merge and setfilesize code Brian Foster
2021-04-05 17:55 ` Christoph Hellwig
2021-04-05 18:08 ` Brian Foster
2021-04-07 6:36 ` Christoph Hellwig
2021-04-07 15:40 ` Darrick J. Wong
2021-04-05 14:59 ` [PATCH 4/4] xfs: drop unnecessary setfilesize helper Brian Foster
2021-04-07 6:37 ` Christoph Hellwig
2021-04-07 15:40 ` Darrick J. Wong
2021-04-06 10:27 ` [PATCH 5/4] iomap: remove unused private field from ioend Brian Foster
2021-04-07 6:40 ` Christoph Hellwig
2021-04-07 15:36 ` Darrick J. Wong
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=YG2WQhu3GcXwIgmO@bfoster \
--to=bfoster@redhat.com \
--cc=hch@infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.