mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-22 23:04:43 +00:00
btrfs: add assertions for tree == inode->io_tree to extent IO helpers
Add assertions to all helpers that get tree as argument and verify that it's the same that can be obtained from the inode or from its pages. In followup patches the redundant arguments and assertions will be removed one by one. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Reviewed-by: Nikolay Borisov <nborisov@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
0ceb34bf46
commit
ae6957ebbf
2 changed files with 12 additions and 0 deletions
|
@ -854,6 +854,8 @@ void btrfs_lock_and_flush_ordered_range(struct extent_io_tree *tree,
|
|||
struct extent_state *cache = NULL;
|
||||
struct extent_state **cachedp = &cache;
|
||||
|
||||
ASSERT(tree == &inode->io_tree);
|
||||
|
||||
if (cached_state)
|
||||
cachedp = cached_state;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue