OSDN Git Service

s390x: css: report errors from ccw_dstream_read/write
authorPierre Morel <pmorel@linux.ibm.com>
Thu, 8 Apr 2021 16:32:09 +0000 (18:32 +0200)
committerCornelia Huck <cohuck@redhat.com>
Fri, 9 Apr 2021 08:52:13 +0000 (10:52 +0200)
commitd895d25ae2bb8519aa715dd2a97f09d4a66b189d
tree9f4fd5f816733abef00401752f049af92c0da713
parentd8724020dd13c88a72fc391a6a2cf63abbd3dcca
s390x: css: report errors from ccw_dstream_read/write

ccw_dstream_read/write functions returned values are sometime
not taking into account and reported back to the upper level
of interpretation of CCW instructions.

It follows that accessing an invalid address does not trigger
a subchannel status program check to the guest as it should.

Let's test the return values of ccw_dstream_write[_buf] and
ccw_dstream_read[_buf] and report it to the caller.

Cc: qemu-stable@nongnu.org
Signed-off-by: Pierre Morel <pmorel@linux.ibm.com>
Acked-by: Halil Pasic <pasic@linux.ibm.com>
Message-Id: <1617899529-9329-2-git-send-email-pmorel@linux.ibm.com>
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
hw/char/terminal3270.c
hw/s390x/3270-ccw.c
hw/s390x/css.c
hw/s390x/virtio-ccw.c