diff options
author | Anand Jain <anand.jain@oracle.com> | 2015-03-10 01:38:34 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.cz> | 2015-05-27 13:27:21 +0300 |
commit | 6c14a1641bfaa213bb3c5bcb7f4d8cde234ada70 (patch) | |
tree | 5294abae1abd966bc18b58ce4dbc969f1b710c76 /fs/btrfs/sysfs.c | |
parent | 1ba43816af921219d596c462baa7674ff0228229 (diff) | |
download | linux-6c14a1641bfaa213bb3c5bcb7f4d8cde234ada70.tar.xz |
Btrfs: sysfs btrfs_kobj_rm_device() pass fs_devices instead of fs_info
since btrfs_kobj_rm_device() does nothing with fs_info
Signed-off-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.cz>
Diffstat (limited to 'fs/btrfs/sysfs.c')
-rw-r--r-- | fs/btrfs/sysfs.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c index 82e18f532958..0a5d1eebc27e 100644 --- a/fs/btrfs/sysfs.c +++ b/fs/btrfs/sysfs.c @@ -555,7 +555,7 @@ void btrfs_sysfs_remove_one(struct btrfs_fs_info *fs_info) addrm_unknown_feature_attrs(fs_info, false); sysfs_remove_group(&fs_info->fs_devices->super_kobj, &btrfs_feature_attr_group); sysfs_remove_files(&fs_info->fs_devices->super_kobj, btrfs_attrs); - btrfs_kobj_rm_device(fs_info, NULL); + btrfs_kobj_rm_device(fs_info->fs_devices, NULL); btrfs_sysfs_remove_fsid(fs_info->fs_devices); } @@ -636,20 +636,20 @@ static void init_feature_attrs(void) /* when one_device is NULL, it removes all device links */ -int btrfs_kobj_rm_device(struct btrfs_fs_info *fs_info, +int btrfs_kobj_rm_device(struct btrfs_fs_devices *fs_devices, struct btrfs_device *one_device) { struct hd_struct *disk; struct kobject *disk_kobj; - if (!fs_info->fs_devices->device_dir_kobj) + if (!fs_devices->device_dir_kobj) return -EINVAL; if (one_device && one_device->bdev) { disk = one_device->bdev->bd_part; disk_kobj = &part_to_dev(disk)->kobj; - sysfs_remove_link(fs_info->fs_devices->device_dir_kobj, + sysfs_remove_link(fs_devices->device_dir_kobj, disk_kobj->name); } @@ -657,13 +657,13 @@ int btrfs_kobj_rm_device(struct btrfs_fs_info *fs_info, return 0; list_for_each_entry(one_device, - &fs_info->fs_devices->devices, dev_list) { + &fs_devices->devices, dev_list) { if (!one_device->bdev) continue; disk = one_device->bdev->bd_part; disk_kobj = &part_to_dev(disk)->kobj; - sysfs_remove_link(fs_info->fs_devices->device_dir_kobj, + sysfs_remove_link(fs_devices->device_dir_kobj, disk_kobj->name); } |