aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/cio/device_status.c
diff options
context:
space:
mode:
authorCornelia Huck <cornelia.huck@de.ibm.com>2008-01-26 08:10:43 -0500
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2008-01-26 08:10:59 -0500
commitcd6b4f27b9bb2a6a5ec82b96b87c85421257be6c (patch)
treebf5ac3d351242de6438ab1453a7f1b007f24c29f /drivers/s390/cio/device_status.c
parentbc698bcf8897363732226dc9ecba044771679996 (diff)
[S390] cio: Introduce subchannel->private.
Introduce a private pointer in struct subchannel to store per-subchannel type data (cannot use dev->priv since this is already used for something else). Create a new header io_sch.h for I/O subchannel specific structures and instructions. 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_status.c')
-rw-r--r--drivers/s390/cio/device_status.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/s390/cio/device_status.c b/drivers/s390/cio/device_status.c
index aa96e6752592..ebe0848cfe33 100644
--- a/drivers/s390/cio/device_status.c
+++ b/drivers/s390/cio/device_status.c
@@ -20,6 +20,7 @@
20#include "css.h" 20#include "css.h"
21#include "device.h" 21#include "device.h"
22#include "ioasm.h" 22#include "ioasm.h"
23#include "io_sch.h"
23 24
24/* 25/*
25 * Check for any kind of channel or interface control check but don't 26 * Check for any kind of channel or interface control check but don't
@@ -310,6 +311,7 @@ int
310ccw_device_do_sense(struct ccw_device *cdev, struct irb *irb) 311ccw_device_do_sense(struct ccw_device *cdev, struct irb *irb)
311{ 312{
312 struct subchannel *sch; 313 struct subchannel *sch;
314 struct ccw1 *sense_ccw;
313 315
314 sch = to_subchannel(cdev->dev.parent); 316 sch = to_subchannel(cdev->dev.parent);
315 317
@@ -326,15 +328,16 @@ ccw_device_do_sense(struct ccw_device *cdev, struct irb *irb)
326 /* 328 /*
327 * We have ending status but no sense information. Do a basic sense. 329 * We have ending status but no sense information. Do a basic sense.
328 */ 330 */
329 sch->sense_ccw.cmd_code = CCW_CMD_BASIC_SENSE; 331 sense_ccw = &to_io_private(sch)->sense_ccw;
330 sch->sense_ccw.cda = (__u32) __pa(cdev->private->irb.ecw); 332 sense_ccw->cmd_code = CCW_CMD_BASIC_SENSE;
331 sch->sense_ccw.count = SENSE_MAX_COUNT; 333 sense_ccw->cda = (__u32) __pa(cdev->private->irb.ecw);
332 sch->sense_ccw.flags = CCW_FLAG_SLI; 334 sense_ccw->count = SENSE_MAX_COUNT;
335 sense_ccw->flags = CCW_FLAG_SLI;
333 336
334 /* Reset internal retry indication. */ 337 /* Reset internal retry indication. */
335 cdev->private->flags.intretry = 0; 338 cdev->private->flags.intretry = 0;
336 339
337 return cio_start (sch, &sch->sense_ccw, 0xff); 340 return cio_start(sch, sense_ccw, 0xff);
338} 341}
339 342
340/* 343/*