qemu-e2k/hw/s390x
Claudio Imbrenda 46fa893355 s390x: fix storage attributes migration for non-small guests
Fix storage attribute migration so that it does not fail for guests
with more than a few GB of RAM.
With such guests, the index in the buffer would go out of bounds,
usually by large amounts, thus receiving -EFAULT from the kernel.
Migration itself would be successful, but storage attributes would then
not be migrated completely.

This patch fixes the out of bounds access, and thus migration of all
storage attributes when the guest have large amounts of memory.

Cc: qemu-stable@nongnu.org
Signed-off-by: Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>
Fixes: 903fd80b03 ("s390x/migration: Storage attributes device")
Message-Id: <1516297904-18188-1-git-send-email-imbrenda@linux.vnet.ibm.com>
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
2018-01-22 11:04:52 +01:00
..
3270-ccw.c s390x/css: unrestrict cssids 2017-12-14 17:56:54 +01:00
ccw-device.c
ccw-device.h
css-bridge.c s390x/css: attach css bridge 2017-12-14 17:56:54 +01:00
css.c misc: remove duplicated includes 2017-12-18 17:07:02 +03:00
event-facility.c s390x/event-facility: variable-length event masks 2017-10-20 13:32:10 +02:00
ipl.c s390x/ipl: The s390-ipl device is not hot-pluggable 2017-08-30 18:23:25 +02:00
ipl.h
Makefile.objs s390x: get rid of s390-virtio.c 2017-09-19 18:31:31 +02:00
s390-ccw.c s390x/css: unrestrict cssids 2017-12-14 17:56:54 +01:00
s390-pci-bus.c pci: Eliminate redundant PCIDevice::bus pointer 2017-12-05 19:13:45 +02:00
s390-pci-bus.h s390x/pci: rework PCI STORE BLOCK 2017-12-14 17:56:54 +01:00
s390-pci-inst.c s390x/pci: search for subregion inside the BARs 2017-12-14 17:56:54 +01:00
s390-pci-inst.h s390x/pci: rework PCI STORE BLOCK 2017-12-14 17:56:54 +01:00
s390-pci-stub.c s390x/pci: remove idx from msix msg data 2017-09-19 18:21:32 +02:00
s390-skeys-kvm.c s390x/s390-skeys: Mark the storage key devices with user_creatable = false 2017-08-30 18:23:25 +02:00
s390-skeys.c s390x/s390-skeys: Mark the storage key devices with user_creatable = false 2017-08-30 18:23:25 +02:00
s390-stattrib-kvm.c s390x: fix storage attributes migration for non-small guests 2018-01-22 11:04:52 +01:00
s390-stattrib.c s390x/s390-stattrib: Mark the storage attribute as not user_creatable 2017-08-30 18:23:26 +02:00
s390-virtio-ccw.c possible_cpus: add CPUArchId::type field 2018-01-19 11:18:51 -02:00
s390-virtio-hcall.c s390x: rename s390-virtio.h to s390-virtio-hcall.h 2017-09-19 18:31:31 +02:00
s390-virtio-hcall.h s390/kvm_virtio/linux-headers: remove traces of old virtio transport 2017-11-24 10:52:05 +01:00
sclp.c s390x/sclp: fix missing be conversion 2018-01-22 11:04:52 +01:00
sclpcpu.c s390x/sclp: mark sclp-cpu-hotplug as non-usercreatable 2017-10-06 10:53:02 +02:00
sclpquiesce.c hw/s390x: Mark the "sclpquiesce" device with user_creatable = false 2017-10-06 10:53:02 +02:00
trace-events trace-events: fix code style: print 0x before hex numbers 2017-08-01 12:13:07 +01:00
virtio-ccw.c hw/s390x: Replace fprintf(stderr, "*\n" with qemu_log_mask() 2018-01-22 11:04:52 +01:00
virtio-ccw.h virtio-ccw: Add the virtio-input devices for CCW bus 2017-10-20 13:32:10 +02:00