diff options
author | David Sterba <dsterba@suse.cz> | 2015-01-02 12:55:46 -0500 |
---|---|---|
committer | David Sterba <dsterba@suse.cz> | 2015-01-14 13:23:47 -0500 |
commit | 14692cc150d3ce10ea8766ccb2a8f483b77b49f0 (patch) | |
tree | 96954530d68d8a7d3ab9b3d741736f60b346d313 /fs | |
parent | 381cf6587f8a8a8e981bc0c1aaaa8859b51dc756 (diff) |
btrfs: cleanup, remove inode_item_info helper
It's only a simple wrapper around btrfs_find_item, the locally defined
key is not used.
Signed-off-by: David Sterba <dsterba@suse.cz>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/btrfs/backref.c | 11 | ||||
-rw-r--r-- | fs/btrfs/backref.h | 3 | ||||
-rw-r--r-- | fs/btrfs/scrub.c | 6 |
3 files changed, 5 insertions, 15 deletions
diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c index 8729cf68d2fe..6fdf82bb03d4 100644 --- a/fs/btrfs/backref.c +++ b/fs/btrfs/backref.c | |||
@@ -1246,17 +1246,6 @@ int btrfs_check_shared(struct btrfs_trans_handle *trans, | |||
1246 | return ret; | 1246 | return ret; |
1247 | } | 1247 | } |
1248 | 1248 | ||
1249 | /* | ||
1250 | * this makes the path point to (inum INODE_ITEM ioff) | ||
1251 | */ | ||
1252 | int inode_item_info(u64 inum, u64 ioff, struct btrfs_root *fs_root, | ||
1253 | struct btrfs_path *path) | ||
1254 | { | ||
1255 | struct btrfs_key key; | ||
1256 | return btrfs_find_item(fs_root, path, inum, ioff, | ||
1257 | BTRFS_INODE_ITEM_KEY, &key); | ||
1258 | } | ||
1259 | |||
1260 | static int inode_ref_info(u64 inum, u64 ioff, struct btrfs_root *fs_root, | 1249 | static int inode_ref_info(u64 inum, u64 ioff, struct btrfs_root *fs_root, |
1261 | struct btrfs_path *path, | 1250 | struct btrfs_path *path, |
1262 | struct btrfs_key *found_key) | 1251 | struct btrfs_key *found_key) |
diff --git a/fs/btrfs/backref.h b/fs/btrfs/backref.h index 2a1ac6bfc724..9c41fbac3009 100644 --- a/fs/btrfs/backref.h +++ b/fs/btrfs/backref.h | |||
@@ -32,9 +32,6 @@ struct inode_fs_paths { | |||
32 | typedef int (iterate_extent_inodes_t)(u64 inum, u64 offset, u64 root, | 32 | typedef int (iterate_extent_inodes_t)(u64 inum, u64 offset, u64 root, |
33 | void *ctx); | 33 | void *ctx); |
34 | 34 | ||
35 | int inode_item_info(u64 inum, u64 ioff, struct btrfs_root *fs_root, | ||
36 | struct btrfs_path *path); | ||
37 | |||
38 | int extent_from_logical(struct btrfs_fs_info *fs_info, u64 logical, | 35 | int extent_from_logical(struct btrfs_fs_info *fs_info, u64 logical, |
39 | struct btrfs_path *path, struct btrfs_key *found_key, | 36 | struct btrfs_path *path, struct btrfs_key *found_key, |
40 | u64 *flags); | 37 | u64 *flags); |
diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index 9e1569ffbf6e..4846f66391a4 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c | |||
@@ -530,7 +530,11 @@ static int scrub_print_warning_inode(u64 inum, u64 offset, u64 root, | |||
530 | goto err; | 530 | goto err; |
531 | } | 531 | } |
532 | 532 | ||
533 | ret = inode_item_info(inum, 0, local_root, swarn->path); | 533 | /* |
534 | * this makes the path point to (inum INODE_ITEM ioff) | ||
535 | */ | ||
536 | ret = btrfs_find_item(local_root, swarn->path, inum, 0, | ||
537 | BTRFS_INODE_ITEM_KEY, NULL); | ||
534 | if (ret) { | 538 | if (ret) { |
535 | btrfs_release_path(swarn->path); | 539 | btrfs_release_path(swarn->path); |
536 | goto err; | 540 | goto err; |