Commit 283fdd0b authored by Cornelia Huck's avatar Cornelia Huck Committed by Martin Schwidefsky

[S390] cio: Dont call ->release directly.

Just put the cdev's reference count to give up our reference.
Signed-off-by: default avatarCornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: default avatarMartin Schwidefsky <schwidefsky@de.ibm.com>
parent 90ed2b69
...@@ -751,8 +751,8 @@ static int io_subchannel_initialize_dev(struct subchannel *sch, ...@@ -751,8 +751,8 @@ static int io_subchannel_initialize_dev(struct subchannel *sch,
/* Do first half of device_register. */ /* Do first half of device_register. */
device_initialize(&cdev->dev); device_initialize(&cdev->dev);
if (!get_device(&sch->dev)) { if (!get_device(&sch->dev)) {
if (cdev->dev.release) /* Release reference from device_initialize(). */
cdev->dev.release(&cdev->dev); put_device(&cdev->dev);
return -ENODEV; return -ENODEV;
} }
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment