diff options
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/cio/device.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 75acec3b2d6b..51bd3687d163 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c | |||
@@ -487,9 +487,11 @@ static int online_store_handle_offline(struct ccw_device *cdev) | |||
487 | spin_lock_irq(cdev->ccwlock); | 487 | spin_lock_irq(cdev->ccwlock); |
488 | ccw_device_sched_todo(cdev, CDEV_TODO_UNREG_EVAL); | 488 | ccw_device_sched_todo(cdev, CDEV_TODO_UNREG_EVAL); |
489 | spin_unlock_irq(cdev->ccwlock); | 489 | spin_unlock_irq(cdev->ccwlock); |
490 | } else if (cdev->online && cdev->drv && cdev->drv->set_offline) | 490 | return 0; |
491 | } | ||
492 | if (cdev->drv && cdev->drv->set_offline) | ||
491 | return ccw_device_set_offline(cdev); | 493 | return ccw_device_set_offline(cdev); |
492 | return 0; | 494 | return -EINVAL; |
493 | } | 495 | } |
494 | 496 | ||
495 | static int online_store_recog_and_online(struct ccw_device *cdev) | 497 | static int online_store_recog_and_online(struct ccw_device *cdev) |
@@ -506,8 +508,8 @@ static int online_store_recog_and_online(struct ccw_device *cdev) | |||
506 | return -EAGAIN; | 508 | return -EAGAIN; |
507 | } | 509 | } |
508 | if (cdev->drv && cdev->drv->set_online) | 510 | if (cdev->drv && cdev->drv->set_online) |
509 | ccw_device_set_online(cdev); | 511 | return ccw_device_set_online(cdev); |
510 | return 0; | 512 | return -EINVAL; |
511 | } | 513 | } |
512 | 514 | ||
513 | static int online_store_handle_online(struct ccw_device *cdev, int force) | 515 | static int online_store_handle_online(struct ccw_device *cdev, int force) |