diff options
Diffstat (limited to 'drivers/s390/cio/device_ops.c')
-rw-r--r-- | drivers/s390/cio/device_ops.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/s390/cio/device_ops.c b/drivers/s390/cio/device_ops.c index 795abb5a65ba..a60124264bee 100644 --- a/drivers/s390/cio/device_ops.c +++ b/drivers/s390/cio/device_ops.c | |||
@@ -6,7 +6,6 @@ | |||
6 | * Author(s): Martin Schwidefsky (schwidefsky@de.ibm.com) | 6 | * Author(s): Martin Schwidefsky (schwidefsky@de.ibm.com) |
7 | * Cornelia Huck (cornelia.huck@de.ibm.com) | 7 | * Cornelia Huck (cornelia.huck@de.ibm.com) |
8 | */ | 8 | */ |
9 | #include <linux/config.h> | ||
10 | #include <linux/module.h> | 9 | #include <linux/module.h> |
11 | #include <linux/init.h> | 10 | #include <linux/init.h> |
12 | #include <linux/errno.h> | 11 | #include <linux/errno.h> |
@@ -78,7 +77,8 @@ ccw_device_start_key(struct ccw_device *cdev, struct ccw1 *cpa, | |||
78 | return -ENODEV; | 77 | return -ENODEV; |
79 | if (cdev->private->state == DEV_STATE_NOT_OPER) | 78 | if (cdev->private->state == DEV_STATE_NOT_OPER) |
80 | return -ENODEV; | 79 | return -ENODEV; |
81 | if (cdev->private->state == DEV_STATE_VERIFY) { | 80 | if (cdev->private->state == DEV_STATE_VERIFY || |
81 | cdev->private->state == DEV_STATE_CLEAR_VERIFY) { | ||
82 | /* Remember to fake irb when finished. */ | 82 | /* Remember to fake irb when finished. */ |
83 | if (!cdev->private->flags.fake_irb) { | 83 | if (!cdev->private->flags.fake_irb) { |
84 | cdev->private->flags.fake_irb = 1; | 84 | cdev->private->flags.fake_irb = 1; |
@@ -270,7 +270,8 @@ ccw_device_wake_up(struct ccw_device *cdev, unsigned long ip, struct irb *irb) | |||
270 | * We didn't get channel end / device end. Check if path | 270 | * We didn't get channel end / device end. Check if path |
271 | * verification has been started; we can retry after it has | 271 | * verification has been started; we can retry after it has |
272 | * finished. We also retry unit checks except for command reject | 272 | * finished. We also retry unit checks except for command reject |
273 | * or intervention required. | 273 | * or intervention required. Also check for long busy |
274 | * conditions. | ||
274 | */ | 275 | */ |
275 | if (cdev->private->flags.doverify || | 276 | if (cdev->private->flags.doverify || |
276 | cdev->private->state == DEV_STATE_VERIFY) | 277 | cdev->private->state == DEV_STATE_VERIFY) |
@@ -279,6 +280,10 @@ ccw_device_wake_up(struct ccw_device *cdev, unsigned long ip, struct irb *irb) | |||
279 | !(irb->ecw[0] & | 280 | !(irb->ecw[0] & |
280 | (SNS0_CMD_REJECT | SNS0_INTERVENTION_REQ))) | 281 | (SNS0_CMD_REJECT | SNS0_INTERVENTION_REQ))) |
281 | cdev->private->intparm = -EAGAIN; | 282 | cdev->private->intparm = -EAGAIN; |
283 | else if ((irb->scsw.dstat & DEV_STAT_ATTENTION) && | ||
284 | (irb->scsw.dstat & DEV_STAT_DEV_END) && | ||
285 | (irb->scsw.dstat & DEV_STAT_UNIT_EXCEP)) | ||
286 | cdev->private->intparm = -EAGAIN; | ||
282 | else | 287 | else |
283 | cdev->private->intparm = -EIO; | 288 | cdev->private->intparm = -EIO; |
284 | 289 | ||