diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2013-06-07 08:40:24 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2013-06-07 08:40:25 -0500 |
commit | b8a75b6093309a43f9837bc2ce63bcf15a7b305f (patch) | |
tree | 58966d3259f7b37696bfc98cf460252825256f5a | |
parent | 8819c10b5d55d537d59a0ffd5d623f348fc36c47 (diff) | |
parent | d1db1fa8dfcea9c62643f624f2a07d2fd375ce45 (diff) |
Merge remote-tracking branch 'cohuck/virtio-ccw-upstr' into staging
# By Cornelia Huck
# Via Cornelia Huck
* cohuck/virtio-ccw-upstr:
virtio-ccw: Fix unsetting of indicators.
s390x/css: Fix concurrent sense.
Message-id: 1370592676-22532-1-git-send-email-cornelia.huck@de.ibm.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
-rw-r--r-- | hw/s390x/css.c | 2 | ||||
-rw-r--r-- | hw/s390x/virtio-ccw.c | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/hw/s390x/css.c b/hw/s390x/css.c index e526a1c86c..f82abfe029 100644 --- a/hw/s390x/css.c +++ b/hw/s390x/css.c @@ -777,7 +777,7 @@ int css_do_tsch(SubchDev *sch, IRB *target_irb) (p->chars & PMCW_CHARS_MASK_CSENSE)) { irb.scsw.flags |= SCSW_FLAGS_MASK_ESWF | SCSW_FLAGS_MASK_ECTL; memcpy(irb.ecw, sch->sense_data, sizeof(sch->sense_data)); - irb.esw[1] = 0x02000000 | (sizeof(sch->sense_data) << 8); + irb.esw[1] = 0x01000000 | (sizeof(sch->sense_data) << 8); } } /* Store the irb to the guest. */ diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c index 5f5e267558..44f5772bb2 100644 --- a/hw/s390x/virtio-ccw.c +++ b/hw/s390x/virtio-ccw.c @@ -328,10 +328,10 @@ static int virtio_ccw_cb(SubchDev *sch, CCW1 ccw) ret = -EINVAL; break; } - indicators = ldq_phys(ccw.cda); - if (!indicators) { + if (!ccw.cda) { ret = -EFAULT; } else { + indicators = ldq_phys(ccw.cda); dev->indicators = indicators; sch->curr_status.scsw.count = ccw.count - sizeof(indicators); ret = 0; @@ -348,10 +348,10 @@ static int virtio_ccw_cb(SubchDev *sch, CCW1 ccw) ret = -EINVAL; break; } - indicators = ldq_phys(ccw.cda); - if (!indicators) { + if (!ccw.cda) { ret = -EFAULT; } else { + indicators = ldq_phys(ccw.cda); dev->indicators2 = indicators; sch->curr_status.scsw.count = ccw.count - sizeof(indicators); ret = 0; |