diff options
-rw-r--r-- | drivers/s390/net/claw.c | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/drivers/s390/net/claw.c b/drivers/s390/net/claw.c index 634c7e8e631d..6b1ff90d2f00 100644 --- a/drivers/s390/net/claw.c +++ b/drivers/s390/net/claw.c | |||
@@ -295,17 +295,15 @@ static ssize_t claw_driver_group_store(struct device_driver *ddrv, | |||
295 | } | 295 | } |
296 | static DRIVER_ATTR(group, 0200, NULL, claw_driver_group_store); | 296 | static DRIVER_ATTR(group, 0200, NULL, claw_driver_group_store); |
297 | 297 | ||
298 | static struct attribute *claw_group_attrs[] = { | 298 | static struct attribute *claw_drv_attrs[] = { |
299 | &driver_attr_group.attr, | 299 | &driver_attr_group.attr, |
300 | NULL, | 300 | NULL, |
301 | }; | 301 | }; |
302 | 302 | static struct attribute_group claw_drv_attr_group = { | |
303 | static struct attribute_group claw_group_attr_group = { | 303 | .attrs = claw_drv_attrs, |
304 | .attrs = claw_group_attrs, | ||
305 | }; | 304 | }; |
306 | 305 | static const struct attribute_group *claw_drv_attr_groups[] = { | |
307 | static const struct attribute_group *claw_group_attr_groups[] = { | 306 | &claw_drv_attr_group, |
308 | &claw_group_attr_group, | ||
309 | NULL, | 307 | NULL, |
310 | }; | 308 | }; |
311 | 309 | ||
@@ -3325,17 +3323,13 @@ static int claw_probe(struct ccwgroup_device *cgdev) | |||
3325 | * claw_init and cleanup * | 3323 | * claw_init and cleanup * |
3326 | *---------------------------------------------------------------------*/ | 3324 | *---------------------------------------------------------------------*/ |
3327 | 3325 | ||
3328 | static void __exit | 3326 | static void __exit claw_cleanup(void) |
3329 | claw_cleanup(void) | ||
3330 | { | 3327 | { |
3331 | driver_remove_file(&claw_group_driver.driver, | ||
3332 | &driver_attr_group); | ||
3333 | ccwgroup_driver_unregister(&claw_group_driver); | 3328 | ccwgroup_driver_unregister(&claw_group_driver); |
3334 | ccw_driver_unregister(&claw_ccw_driver); | 3329 | ccw_driver_unregister(&claw_ccw_driver); |
3335 | root_device_unregister(claw_root_dev); | 3330 | root_device_unregister(claw_root_dev); |
3336 | claw_unregister_debug_facility(); | 3331 | claw_unregister_debug_facility(); |
3337 | pr_info("Driver unloaded\n"); | 3332 | pr_info("Driver unloaded\n"); |
3338 | |||
3339 | } | 3333 | } |
3340 | 3334 | ||
3341 | /** | 3335 | /** |
@@ -3344,8 +3338,7 @@ claw_cleanup(void) | |||
3344 | * | 3338 | * |
3345 | * @return 0 on success, !0 on error. | 3339 | * @return 0 on success, !0 on error. |
3346 | */ | 3340 | */ |
3347 | static int __init | 3341 | static int __init claw_init(void) |
3348 | claw_init(void) | ||
3349 | { | 3342 | { |
3350 | int ret = 0; | 3343 | int ret = 0; |
3351 | 3344 | ||
@@ -3364,7 +3357,7 @@ claw_init(void) | |||
3364 | ret = ccw_driver_register(&claw_ccw_driver); | 3357 | ret = ccw_driver_register(&claw_ccw_driver); |
3365 | if (ret) | 3358 | if (ret) |
3366 | goto ccw_err; | 3359 | goto ccw_err; |
3367 | claw_group_driver.driver.groups = claw_group_attr_groups; | 3360 | claw_group_driver.driver.groups = claw_drv_attr_groups; |
3368 | ret = ccwgroup_driver_register(&claw_group_driver); | 3361 | ret = ccwgroup_driver_register(&claw_group_driver); |
3369 | if (ret) | 3362 | if (ret) |
3370 | goto ccwgroup_err; | 3363 | goto ccwgroup_err; |