]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - fs/ext4/readpage.c
Merge tag 'dmaengine-5.5-rc1' of git://git.infradead.org/users/vkoul/slave-dma
[linux.git] / fs / ext4 / readpage.c
index a30b203fa461c7db9e87a7d98301e6f6087d7114..fef7755300c359ba7c87b283c516241189280d2e 100644 (file)
@@ -360,10 +360,12 @@ int ext4_mpage_readpages(struct address_space *mapping,
                if (bio == NULL) {
                        struct bio_post_read_ctx *ctx;
 
+                       /*
+                        * bio_alloc will _always_ be able to allocate a bio if
+                        * __GFP_DIRECT_RECLAIM is set, see bio_alloc_bioset().
+                        */
                        bio = bio_alloc(GFP_KERNEL,
                                min_t(int, nr_pages, BIO_MAX_PAGES));
-                       if (!bio)
-                               goto set_error_page;
                        ctx = get_bio_post_read_ctx(inode, bio, page->index);
                        if (IS_ERR(ctx)) {
                                bio_put(bio);