From 24cb5b4846ebae5543869b5c596c2650f380df53 Mon Sep 17 00:00:00 2001 From: Cornelia Huck Date: Mon, 4 Dec 2006 15:41:01 +0100 Subject: [S390] cio: Use path verification for last path gone after vary off. If the last path to a device is gone after a chpid has been varied off, putting it on the slow queue doesn't prevent a device driver from still attempting to use it (it may stay on the slow queue for a long time). Instead, trigger a verify event which will prevent I/O attempts from the device driver immediately. Signed-off-by: Cornelia Huck Signed-off-by: Martin Schwidefsky --- drivers/s390/cio/device_fsm.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'drivers/s390/cio/device_fsm.c') diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index de3d0857db9..7665000e8df 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c @@ -59,6 +59,17 @@ device_set_disconnected(struct subchannel *sch) cdev->private->state = DEV_STATE_DISCONNECTED; } +int device_trigger_verify(struct subchannel *sch) +{ + struct ccw_device *cdev; + + cdev = sch->dev.driver_data; + if (!cdev || !cdev->online) + return -EINVAL; + dev_fsm_event(cdev, DEV_EVENT_VERIFY); + return 0; +} + /* * Timeout function. It just triggers a DEV_EVENT_TIMEOUT. */ -- cgit v1.2.3-70-g09d2