* [PATCH 3/5] iomap: call __clear_page_buffers in iomap_page_release [not found] <20200418225123.31850-1-guoqing.jiang@cloud.ionos.com> @ 2020-04-18 22:51 ` Guoqing Jiang 2020-04-19 7:47 ` Christoph Hellwig 0 siblings, 1 reply; 3+ messages in thread From: Guoqing Jiang @ 2020-04-18 22:51 UTC (permalink / raw) To: linux-fsdevel Cc: Guoqing Jiang, Christoph Hellwig, Darrick J . Wong, linux-xfs After the helper is exported, we can call it to simplify code a little. Cc: Christoph Hellwig <hch@infradead.org> Cc: Darrick J. Wong <darrick.wong@oracle.com> Cc: linux-xfs@vger.kernel.org Signed-off-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com> --- fs/iomap/buffered-io.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c index 89e21961d1ad..b06568ad9a7a 100644 --- a/fs/iomap/buffered-io.c +++ b/fs/iomap/buffered-io.c @@ -74,9 +74,7 @@ iomap_page_release(struct page *page) return; WARN_ON_ONCE(atomic_read(&iop->read_count)); WARN_ON_ONCE(atomic_read(&iop->write_count)); - ClearPagePrivate(page); - set_page_private(page, 0); - put_page(page); + __clear_page_buffers(page); kfree(iop); } -- 2.17.1 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 3/5] iomap: call __clear_page_buffers in iomap_page_release 2020-04-18 22:51 ` [PATCH 3/5] iomap: call __clear_page_buffers in iomap_page_release Guoqing Jiang @ 2020-04-19 7:47 ` Christoph Hellwig 2020-04-19 13:18 ` Guoqing Jiang 0 siblings, 1 reply; 3+ messages in thread From: Christoph Hellwig @ 2020-04-19 7:47 UTC (permalink / raw) To: Guoqing Jiang Cc: linux-fsdevel, Christoph Hellwig, Darrick J . Wong, linux-xfs On Sun, Apr 19, 2020 at 12:51:21AM +0200, Guoqing Jiang wrote: > After the helper is exported, we can call it to simplify code a little. > > Cc: Christoph Hellwig <hch@infradead.org> > Cc: Darrick J. Wong <darrick.wong@oracle.com> > Cc: linux-xfs@vger.kernel.org > Signed-off-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com> > --- > fs/iomap/buffered-io.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c > index 89e21961d1ad..b06568ad9a7a 100644 > --- a/fs/iomap/buffered-io.c > +++ b/fs/iomap/buffered-io.c > @@ -74,9 +74,7 @@ iomap_page_release(struct page *page) > return; > WARN_ON_ONCE(atomic_read(&iop->read_count)); > WARN_ON_ONCE(atomic_read(&iop->write_count)); > - ClearPagePrivate(page); > - set_page_private(page, 0); > - put_page(page); > + __clear_page_buffers(page); We should not call a helper mentioning buffers in code that has nothing to do with buffers. If you want to us __clear_page_buffers more widely please give it a better name first. You'll also forgot to Cc me on the other patches in the series, which is a completel no-go as it doesn't allow for a proper review. ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 3/5] iomap: call __clear_page_buffers in iomap_page_release 2020-04-19 7:47 ` Christoph Hellwig @ 2020-04-19 13:18 ` Guoqing Jiang 0 siblings, 0 replies; 3+ messages in thread From: Guoqing Jiang @ 2020-04-19 13:18 UTC (permalink / raw) To: Christoph Hellwig; +Cc: linux-fsdevel, Darrick J . Wong, linux-xfs On 19.04.20 09:47, Christoph Hellwig wrote: > On Sun, Apr 19, 2020 at 12:51:21AM +0200, Guoqing Jiang wrote: >> After the helper is exported, we can call it to simplify code a little. >> >> Cc: Christoph Hellwig <hch@infradead.org> >> Cc: Darrick J. Wong <darrick.wong@oracle.com> >> Cc: linux-xfs@vger.kernel.org >> Signed-off-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com> >> --- >> fs/iomap/buffered-io.c | 4 +--- >> 1 file changed, 1 insertion(+), 3 deletions(-) >> >> diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c >> index 89e21961d1ad..b06568ad9a7a 100644 >> --- a/fs/iomap/buffered-io.c >> +++ b/fs/iomap/buffered-io.c >> @@ -74,9 +74,7 @@ iomap_page_release(struct page *page) >> return; >> WARN_ON_ONCE(atomic_read(&iop->read_count)); >> WARN_ON_ONCE(atomic_read(&iop->write_count)); >> - ClearPagePrivate(page); >> - set_page_private(page, 0); >> - put_page(page); >> + __clear_page_buffers(page); > We should not call a helper mentioning buffers in code that has > nothing to do with buffers. If you want to us __clear_page_buffers > more widely please give it a better name first. Yes, I will rename it to clear_page_private as Matthew suggested. > You'll also forgot to Cc me on the other patches in the series, which is > a completel no-go as it doesn't allow for a proper review. Sorry, will cc you with the series next time. Thanks, Guoqing ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-04-19 13:18 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20200418225123.31850-1-guoqing.jiang@cloud.ionos.com>
2020-04-18 22:51 ` [PATCH 3/5] iomap: call __clear_page_buffers in iomap_page_release Guoqing Jiang
2020-04-19 7:47 ` Christoph Hellwig
2020-04-19 13:18 ` Guoqing Jiang
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).