aboutsummaryrefslogtreecommitdiff
path: root/hw/sh4
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@redhat.com>2020-03-05 13:12:51 +0100
committerDavid Gibson <david@gibson.dropbear.id.au>2020-03-17 15:08:50 +1100
commitff78b728f6c9d2c274dab20114bfe052322365a1 (patch)
tree4cb1c74428cc0ea33c80b1b5a8812c16b701b97e /hw/sh4
parent81e705494f2915b7b6174bc5695d19ee4a083a85 (diff)
downloadqemu-ff78b728f6c9d2c274dab20114bfe052322365a1.zip
qemu-ff78b728f6c9d2c274dab20114bfe052322365a1.tar.gz
qemu-ff78b728f6c9d2c274dab20114bfe052322365a1.tar.bz2
hw/scsi/spapr_vscsi: Do not mix SRP IU size with DMA buffer size
The 'union srp_iu' is meant as a pointer to any SRP Information Unit type, it is not related to the size of a VIO DMA buffer. Use a plain buffer for the VIO DMA read/write calls. We can remove the reserved buffer from the 'union srp_iu'. This issue was noticed when replacing the zero-length arrays from hw/scsi/srp.h with flexible array member, 'clang -fsanitize=undefined' reported: hw/scsi/spapr_vscsi.c:69:29: error: field 'iu' with variable sized type 'union viosrp_iu' not at the end of a struct or class is a GNU extension [-Werror,-Wgnu-variable-sized-type-not-at-end] union viosrp_iu iu; ^ Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20200305121253.19078-6-philmd@redhat.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/sh4')
0 files changed, 0 insertions, 0 deletions