btrfs: remove redundant parameter from reada_find_zone
authorDavid Sterba <dsterba@suse.com>
Thu, 2 Mar 2017 18:43:30 +0000 (19:43 +0100)
committerDavid Sterba <dsterba@suse.com>
Tue, 18 Apr 2017 12:07:25 +0000 (14:07 +0200)
We can read fs_info from dev.

Reviewed-by: Liu Bo <bo.li.liu@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/reada.c

index 306e5108aac705d56e10c4a14ef18e842da4584b..2deba18886dba0249504317804730011c966dea9 100644 (file)
@@ -235,10 +235,10 @@ start_machine:
        return ret;
 }
 
-static struct reada_zone *reada_find_zone(struct btrfs_fs_info *fs_info,
-                                         struct btrfs_device *dev, u64 logical,
+static struct reada_zone *reada_find_zone(struct btrfs_device *dev, u64 logical,
                                          struct btrfs_bio *bbio)
 {
+       struct btrfs_fs_info *fs_info = dev->fs_info;
        int ret;
        struct reada_zone *zone;
        struct btrfs_block_group_cache *cache = NULL;
@@ -374,7 +374,7 @@ static struct reada_extent *reada_find_extent(struct btrfs_fs_info *fs_info,
                 if (!dev->bdev)
                        continue;
 
-               zone = reada_find_zone(fs_info, dev, logical, bbio);
+               zone = reada_find_zone(dev, logical, bbio);
                if (!zone)
                        continue;