Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit edd33c99 authored by Josef Bacik's avatar Josef Bacik Committed by Chris Mason
Browse files

Btrfs: don't bug on enomem in readpage



Get rid of the BUG_ON(ret == -ENOMEM) in __extent_read_full_page.  Thanks,

Reported-by: default avatarJérôme Poulin <jeromepoulin@gmail.com>
Signed-off-by: default avatarJosef Bacik <jbacik@fusionio.com>
parent 15e3004a
Loading
Loading
Loading
Loading
+7 −4
Original line number Diff line number Diff line
@@ -2751,12 +2751,15 @@ static int __extent_read_full_page(struct extent_io_tree *tree,
					 end_bio_extent_readpage, mirror_num,
					 *bio_flags,
					 this_bio_flag);
			BUG_ON(ret == -ENOMEM);
			if (!ret) {
				nr++;
				*bio_flags = this_bio_flag;
			}
		if (ret)
		}
		if (ret) {
			SetPageError(page);
			unlock_extent(tree, cur, cur + iosize - 1);
		}
		cur = cur + iosize;
		pg_offset += iosize;
	}