aboutsummaryrefslogtreecommitdiff
path: root/hw/scsi
diff options
context:
space:
mode:
authorGreg Kurz <groug@kaod.org>2017-08-07 13:36:44 +0200
committerPaolo Bonzini <pbonzini@redhat.com>2017-08-08 10:40:20 +0200
commit1b7ac7cab6a9abaf686fe7a7f4afea155c03d6a8 (patch)
tree4b6f0e5a5594adf30db6bf5f7eb3efb76768c67c /hw/scsi
parent2a96a552f9502ac34c29da2f3a39788db5ee5692 (diff)
downloadqemu-1b7ac7cab6a9abaf686fe7a7f4afea155c03d6a8.zip
qemu-1b7ac7cab6a9abaf686fe7a7f4afea155c03d6a8.tar.gz
qemu-1b7ac7cab6a9abaf686fe7a7f4afea155c03d6a8.tar.bz2
kvm: workaround build break on gcc-7.1.1 / fedora26
Building QEMU on fedora26 with the latest gcc package fails: CC ppc64-softmmu/target/ppc/kvm.o In file included from include/sysemu/hw_accel.h:16:0, from target/ppc/kvm.c:31: target/ppc/kvm.c: In function ‘kvmppc_booke_watchdog_enable’: include/sysemu/kvm.h:449:35: error: ‘args_tmp[i]’ may be used uninitialized in this function [-Werror=maybe-uninitialized] cap.args[i] = args_tmp[i]; \ ^ target/ppc/kvm.c: In function ‘kvmppc_set_papr’: include/sysemu/kvm.h:449:35: error: ‘args_tmp[i]’ may be used uninitialized in this function [-Werror=maybe-uninitialized] cc1: all warnings being treated as errors $ rpm -q gcc gcc-7.1.1-3.fc26.ppc64le The compiler should obviously optimize this code away when no extra agument is passed to kvm_vm_enable_cap() and kvm_vcpu_enable_cap(), but it doesn't. This bug should be fixed one day in gcc, but we can also change our code pattern so that we don't hit the issue anymore. We workaround this, by using memcpy() instead of open-coding the copy. Signed-off-by: Greg Kurz <groug@kaod.org> Message-Id: <150210580404.1343.7325713896658799315.stgit@bahia.lan> Acked-by: Cornelia Huck <cohuck@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/scsi')
0 files changed, 0 insertions, 0 deletions