diff options
author | Cornelia Huck <cornelia.huck@de.ibm.com> | 2008-01-26 08:10:45 -0500 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2008-01-26 08:11:01 -0500 |
commit | b279a4f56d5476a0b9b0a97397f7a7bbe00b9b2f (patch) | |
tree | 8f6fe1b5e68ecc0684a88fb67bd6179cf6c59707 /drivers/s390/cio/device_fsm.c | |
parent | 4e8e56c6713398f417317d449f50c08bf2756c66 (diff) |
[S390] cio: I/O subchannel specific fields.
Some fields may be !0 only for I/O subchannels. Add some checks
where required. Also adapt cio_enable_subchannel() to make the
caller specify the intparm, which makes it more generic.
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/cio/device_fsm.c')
-rw-r--r-- | drivers/s390/cio/device_fsm.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index 44ce7a3d3857..4804d944fb4d 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c | |||
@@ -553,7 +553,8 @@ ccw_device_recognition(struct ccw_device *cdev) | |||
553 | (cdev->private->state != DEV_STATE_BOXED)) | 553 | (cdev->private->state != DEV_STATE_BOXED)) |
554 | return -EINVAL; | 554 | return -EINVAL; |
555 | sch = to_subchannel(cdev->dev.parent); | 555 | sch = to_subchannel(cdev->dev.parent); |
556 | ret = cio_enable_subchannel(sch, sch->schib.pmcw.isc); | 556 | ret = cio_enable_subchannel(sch, sch->schib.pmcw.isc, |
557 | (u32)(addr_t)sch); | ||
557 | if (ret != 0) | 558 | if (ret != 0) |
558 | /* Couldn't enable the subchannel for i/o. Sick device. */ | 559 | /* Couldn't enable the subchannel for i/o. Sick device. */ |
559 | return ret; | 560 | return ret; |
@@ -663,7 +664,8 @@ ccw_device_online(struct ccw_device *cdev) | |||
663 | sch = to_subchannel(cdev->dev.parent); | 664 | sch = to_subchannel(cdev->dev.parent); |
664 | if (css_init_done && !get_device(&cdev->dev)) | 665 | if (css_init_done && !get_device(&cdev->dev)) |
665 | return -ENODEV; | 666 | return -ENODEV; |
666 | ret = cio_enable_subchannel(sch, sch->schib.pmcw.isc); | 667 | ret = cio_enable_subchannel(sch, sch->schib.pmcw.isc, |
668 | (u32)(addr_t)sch); | ||
667 | if (ret != 0) { | 669 | if (ret != 0) { |
668 | /* Couldn't enable the subchannel for i/o. Sick device. */ | 670 | /* Couldn't enable the subchannel for i/o. Sick device. */ |
669 | if (ret == -ENODEV) | 671 | if (ret == -ENODEV) |
@@ -1043,7 +1045,8 @@ ccw_device_start_id(struct ccw_device *cdev, enum dev_event dev_event) | |||
1043 | struct subchannel *sch; | 1045 | struct subchannel *sch; |
1044 | 1046 | ||
1045 | sch = to_subchannel(cdev->dev.parent); | 1047 | sch = to_subchannel(cdev->dev.parent); |
1046 | if (cio_enable_subchannel(sch, sch->schib.pmcw.isc) != 0) | 1048 | if (cio_enable_subchannel(sch, sch->schib.pmcw.isc, |
1049 | (u32)(addr_t)sch) != 0) | ||
1047 | /* Couldn't enable the subchannel for i/o. Sick device. */ | 1050 | /* Couldn't enable the subchannel for i/o. Sick device. */ |
1048 | return; | 1051 | return; |
1049 | 1052 | ||