]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: extent_io: Move the BUG_ON() in flush_write_bio() one level up
authorQu Wenruo <wqu@suse.com>
Wed, 20 Mar 2019 06:27:41 +0000 (14:27 +0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 29 Apr 2019 17:02:23 +0000 (19:02 +0200)
commitc7d0c172e70f731548de7281cdb851a1df601b39
tree605c229bc0529a5de782eca5599c69e763160a4d
parent1cbe538cd3b1df13f117f83e81a920b4da30b6ad
btrfs: extent_io: Move the BUG_ON() in flush_write_bio() one level up

We have a BUG_ON() in flush_write_bio() to handle the return value of
submit_one_bio().

Move the BUG_ON() one level up to all its callers.

This patch will introduce temporary variable, @flush_ret to keep code
change minimal in this patch. That variable will be cleaned up when
enhancing the error handling later.

Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent_io.c