From: Matthew Wilcox <willy@infradead.org>
To: Christoph Hellwig <hch@infradead.org>,
"Darrick J. Wong" <darrick.wong@oracle.com>,
linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org
Cc: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Subject: [PATCH] iomap: Do not use GFP_NORETRY to allocate BIOs
Date: Mon, 23 Mar 2020 06:12:44 -0700 [thread overview]
Message-ID: <20200323131244.29435-1-willy@infradead.org> (raw)
From: "Matthew Wilcox (Oracle)" <willy@infradead.org>
If we use GFP_NORETRY, we have to be able to handle failures, and it's
tricky to handle failure here. Other implementations of ->readpages
do not attempt to handle BIO allocation failures, so this is no worse.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
---
fs/iomap/buffered-io.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c
index 417115bfaf6b..2336642d7390 100644
--- a/fs/iomap/buffered-io.c
+++ b/fs/iomap/buffered-io.c
@@ -307,8 +307,6 @@ iomap_readpage_actor(struct inode *inode, loff_t pos, loff_t length, void *data,
if (ctx->bio)
submit_bio(ctx->bio);
- if (ctx->is_readahead) /* same as readahead_gfp_mask */
- gfp |= __GFP_NORETRY | __GFP_NOWARN;
ctx->bio = bio_alloc(gfp, min(BIO_MAX_PAGES, nr_vecs));
ctx->bio->bi_opf = REQ_OP_READ;
if (ctx->is_readahead)
--
2.25.1
next reply other threads:[~2020-03-23 13:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-23 13:12 Matthew Wilcox [this message]
2020-03-23 13:20 ` [PATCH] iomap: Do not use GFP_NORETRY to allocate BIOs Christoph Hellwig
2020-03-23 13:40 ` Matthew Wilcox
2020-03-23 13:55 ` Christoph Hellwig
2020-03-23 15:10 ` Matthew Wilcox
2020-03-23 16:51 ` Christoph Hellwig
2020-03-31 9:21 ` Christoph Hellwig
2020-03-23 15:38 ` 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=20200323131244.29435-1-willy@infradead.org \
--to=willy@infradead.org \
--cc=darrick.wong@oracle.com \
--cc=hch@infradead.org \
--cc=linux-fsdevel@vger.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;
as well as URLs for NNTP newsgroup(s).