aboutsummaryrefslogtreecommitdiff
path: root/hw/vfio/ccw.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2021-03-05 19:04:46 +0000
committerPeter Maydell <peter.maydell@linaro.org>2021-03-05 19:04:47 +0000
commit91e92cad67caca3bc4b8e920ddb5c8ca64aac9e1 (patch)
treee625cb660d678c8ffd12cefc965449fba76d70c3 /hw/vfio/ccw.c
parentbb736b20a31fa9956195565ea34bc9c28953e70d (diff)
parent39d5d1404ed695f4a1cd2b117a6cf2d92dd8e8b9 (diff)
downloadqemu-91e92cad67caca3bc4b8e920ddb5c8ca64aac9e1.zip
qemu-91e92cad67caca3bc4b8e920ddb5c8ca64aac9e1.tar.gz
qemu-91e92cad67caca3bc4b8e920ddb5c8ca64aac9e1.tar.bz2
Merge remote-tracking branch 'remotes/cohuck-gitlab/tags/s390x-20210305' into staging
some accumulated s390x fixes # gpg: Signature made Fri 05 Mar 2021 15:50:00 GMT # gpg: using RSA key C3D0D66DC3624FF6A8C018CEDECF6B93C6F02FAF # gpg: issuer "cohuck@redhat.com" # gpg: Good signature from "Cornelia Huck <conny@cornelia-huck.de>" [unknown] # gpg: aka "Cornelia Huck <huckc@linux.vnet.ibm.com>" [full] # gpg: aka "Cornelia Huck <cornelia.huck@de.ibm.com>" [full] # gpg: aka "Cornelia Huck <cohuck@kernel.org>" [unknown] # gpg: aka "Cornelia Huck <cohuck@redhat.com>" [unknown] # Primary key fingerprint: C3D0 D66D C362 4FF6 A8C0 18CE DECF 6B93 C6F0 2FAF * remotes/cohuck-gitlab/tags/s390x-20210305: target/s390x/kvm: Simplify debug code vfio-ccw: Do not read region ret_code after write css: SCHIB measurement block origin must be aligned virtio-ccw: commands on revision-less devices s390x/pci: restore missing Query PCI Function CLP data hw/s390x: fix build for virtio-9p-ccw target/s390x/arch_dump: Fix warning for the name field in the PT_NOTE section s390x/cpu_model: disallow unpack for --only-migratable Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/vfio/ccw.c')
-rw-r--r--hw/vfio/ccw.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/hw/vfio/ccw.c b/hw/vfio/ccw.c
index bc78a0a..b2df708 100644
--- a/hw/vfio/ccw.c
+++ b/hw/vfio/ccw.c
@@ -104,9 +104,9 @@ again:
goto again;
}
error_report("vfio-ccw: write I/O region failed with errno=%d", errno);
- ret = -errno;
+ ret = errno ? -errno : -EFAULT;
} else {
- ret = region->ret_code;
+ ret = 0;
}
switch (ret) {
case 0:
@@ -192,9 +192,9 @@ again:
goto again;
}
error_report("vfio-ccw: write cmd region failed with errno=%d", errno);
- ret = -errno;
+ ret = errno ? -errno : -EFAULT;
} else {
- ret = region->ret_code;
+ ret = 0;
}
switch (ret) {
case 0:
@@ -232,9 +232,9 @@ again:
goto again;
}
error_report("vfio-ccw: write cmd region failed with errno=%d", errno);
- ret = -errno;
+ ret = errno ? -errno : -EFAULT;
} else {
- ret = region->ret_code;
+ ret = 0;
}
switch (ret) {
case 0: