It can be referenced from the passed transaction handle.

Signed-off-by: Nikolay Borisov <[email protected]>
---
 fs/btrfs/volumes.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 844e5d4fd3e4..35cc5b6a06e0 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -7035,9 +7035,9 @@ int btrfs_init_dev_stats(struct btrfs_fs_info *fs_info)
 }
 
 static int update_dev_stat_item(struct btrfs_trans_handle *trans,
-                               struct btrfs_fs_info *fs_info,
                                struct btrfs_device *device)
 {
+       struct btrfs_fs_info *fs_info = trans->fs_info;
        struct btrfs_root *dev_root = fs_info->dev_root;
        struct btrfs_path *path;
        struct btrfs_key key;
@@ -7130,7 +7130,7 @@ int btrfs_run_dev_stats(struct btrfs_trans_handle *trans,
                 */
                smp_rmb();
 
-               ret = update_dev_stat_item(trans, fs_info, device);
+               ret = update_dev_stat_item(trans, device);
                if (!ret)
                        atomic_sub(stats_cnt, &device->dev_stats_ccnt);
        }
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to