diff options
author | Julian Wiedmann <jwi@linux.ibm.com> | 2021-03-16 12:45:13 +0300 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2021-03-16 17:31:00 +0300 |
commit | 1987c55139c9ebe1bed48490c49cfe266cd35ac8 (patch) | |
tree | a8d5ec8861b73cac41244649333c4043c520619b /drivers/s390/block/dasd_devmap.c | |
parent | 86f0a011e548774fd8eb952f67bfeb19f3174dd0 (diff) | |
download | linux-1987c55139c9ebe1bed48490c49cfe266cd35ac8.tar.xz |
s390/dasd: let driver core manage the sysfs attributes
Wire up device_driver->dev_groups, so that really_probe() creates the
sysfs attributes for us automatically.
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Reviewed-by: Jan Hoeppner <hoeppner@linux.ibm.com>
Signed-off-by: Stefan Haberland <sth@linux.ibm.com>
Link: https://lore.kernel.org/r/20210316094513.2601218-3-sth@linux.ibm.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/s390/block/dasd_devmap.c')
-rw-r--r-- | drivers/s390/block/dasd_devmap.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/drivers/s390/block/dasd_devmap.c b/drivers/s390/block/dasd_devmap.c index 03d27ee9cac6..2c40fe15da55 100644 --- a/drivers/s390/block/dasd_devmap.c +++ b/drivers/s390/block/dasd_devmap.c @@ -1772,12 +1772,13 @@ static const struct attribute_group ext_pool_attr_group = { .attrs = ext_pool_attrs, }; -static const struct attribute_group *dasd_attr_groups[] = { +const struct attribute_group *dasd_dev_groups[] = { &dasd_attr_group, &capacity_attr_group, &ext_pool_attr_group, NULL, }; +EXPORT_SYMBOL_GPL(dasd_dev_groups); /* * Return value of the specified feature. @@ -1895,18 +1896,6 @@ void dasd_path_remove_kobjects(struct dasd_device *device) } EXPORT_SYMBOL(dasd_path_remove_kobjects); -int dasd_add_sysfs_files(struct ccw_device *cdev) -{ - return sysfs_create_groups(&cdev->dev.kobj, dasd_attr_groups); -} - -void -dasd_remove_sysfs_files(struct ccw_device *cdev) -{ - sysfs_remove_groups(&cdev->dev.kobj, dasd_attr_groups); -} - - int dasd_devmap_init(void) { |