diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-08-31 07:17:17 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-08-31 07:17:17 +0200 |
commit | dd5597245d35cfbb0890b8a868028aa1d2018701 (patch) | |
tree | 865b93bf83987840fd763bf8a3d1c615ccda2f7b /fs/squashfs/block.c | |
parent | 551b6729578a8981c46af964c10bf7d5d9ddca83 (diff) | |
parent | f75aef392f869018f78cfedf3c320a6b3fcfda6b (diff) | |
download | linux-dd5597245d35cfbb0890b8a868028aa1d2018701.tar.bz2 |
Merge 5.9-rc3 into char-misc-next
We need the fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/squashfs/block.c')
-rw-r--r-- | fs/squashfs/block.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/squashfs/block.c b/fs/squashfs/block.c index 76bb1c846845..8a19773b5a0b 100644 --- a/fs/squashfs/block.c +++ b/fs/squashfs/block.c @@ -87,7 +87,11 @@ static int squashfs_bio_read(struct super_block *sb, u64 index, int length, int error, i; struct bio *bio; - bio = bio_alloc(GFP_NOIO, page_count); + if (page_count <= BIO_MAX_PAGES) + bio = bio_alloc(GFP_NOIO, page_count); + else + bio = bio_kmalloc(GFP_NOIO, page_count); + if (!bio) return -ENOMEM; |