From: Peter Oberparleiter Date: Thu, 31 May 2007 15:38:07 +0000 (+0200) Subject: [S390] cio: deregister ccw device when pgid disband failed X-Git-Tag: v2.6.22-rc4~66^2 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3ecb0a5a7b567c9719d61938bcdba22938084b65;p=linux-2.6 [S390] cio: deregister ccw device when pgid disband failed Deregister ccw device when device failure is detected during offline- processing (e.g. when no last-path-gone indication was presented by the hardware) to prevent the device from entering a non-recoverable not-operational state. Signed-off-by: Peter Oberparleiter Signed-off-by: Martin Schwidefsky --- diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index 898ec3b2be..6bba809295 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c @@ -688,6 +688,12 @@ ccw_device_disband_done(struct ccw_device *cdev, int err) ccw_device_done(cdev, DEV_STATE_BOXED); break; default: + cdev->private->flags.donotify = 0; + if (get_device(&cdev->dev)) { + PREPARE_WORK(&cdev->private->kick_work, + ccw_device_call_sch_unregister); + queue_work(ccw_device_work, &cdev->private->kick_work); + } ccw_device_done(cdev, DEV_STATE_NOT_OPER); break; }