forked from luck/tmp_suning_uos_patched
[S390] tape: fix tape remove function
Fix a bug introduced with git commit dff59b64af
:
- if (cdev->dev.driver_data != NULL) {
+ if (!dev_get_drvdata(&cdev->dev)) {
These two are not equivalent.
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
c1b283d55d
commit
1b52fff059
@ -665,7 +665,7 @@ tape_generic_remove(struct ccw_device *cdev)
|
|||||||
tape_cleanup_device(device);
|
tape_cleanup_device(device);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!dev_get_drvdata(&cdev->dev)) {
|
if (dev_get_drvdata(&cdev->dev)) {
|
||||||
sysfs_remove_group(&cdev->dev.kobj, &tape_attr_group);
|
sysfs_remove_group(&cdev->dev.kobj, &tape_attr_group);
|
||||||
dev_set_drvdata(&cdev->dev, tape_put_device(dev_get_drvdata(&cdev->dev)));
|
dev_set_drvdata(&cdev->dev, tape_put_device(dev_get_drvdata(&cdev->dev)));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user