btrfs: Cleanup some redundant codes in btrfs_lookup_csums_range()
PATCH 1/2 btrfs: Cleanup some redundant codes in btrfs_lookup_csums_range()
From: Zhi Yong Wu <[email protected]>
Signed-off-by Zhi Yong Wu <[email protected]>
--- fs/btrfs/file-item.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
fs/btrfs/file-item.c +2 -5
@@ -356,11 +356,8 @@ int btrfs_lookup_csums_range(struct btrfs_root *root, u64 start, u64 end,btrfs_item_key_to_cpu (leaf, &key, path->slots[0 ]);if (key.objectid !=BTRFS_EXTENT_CSUM_OBJECTID || - key.type !=BTRFS_EXTENT_CSUM_KEY ) -break ; - -btrfs_item_key_to_cpu (leaf, &key, path->slots[0 ]); -if (key.offset > end) + key.type !=BTRFS_EXTENT_CSUM_KEY || + key.offset > end)break ;if (key.offset > start)
Signature · 1 line
1.7.11.7
PATCH 2/2 btrfs: Cleanup some redundant codes in btrfs_log_inode()
From: Zhi Yong Wu <[email protected]>
Signed-off-by Zhi Yong Wu <[email protected]>
--- fs/btrfs/tree-log.c | 2 -- 1 file changed, 2 deletions(-)
fs/btrfs/tree-log.c +0 -2
@@ -3614,8 +3614,6 @@ static int btrfs_log_inode(struct btrfs_trans_handle *trans,bool fast_search = false;u64 ino =btrfs_ino (inode); - log = root->log_root; - path =btrfs_alloc_path ();if (!path)return -ENOMEM ;
Signature · 1 line
1.7.11.7