b7fbd568b2
- kvm-migration-Move-yank-outside-qemu_start_incoming_migr.patch [bz#1974683] - kvm-migration-Allow-reset-of-postcopy_recover_triggered-.patch [bz#1974683] - kvm-Remove-RHEL-7.0.0-machine-type.patch [bz#1968519] - kvm-Remove-RHEL-7.1.0-machine-type.patch [bz#1968519] - kvm-Remove-RHEL-7.2.0-machine-type.patch [bz#1968519] - kvm-Remove-RHEL-7.3.0-machine-types.patch [bz#1968519] - kvm-Remove-RHEL-7.4.0-machine-types.patch [bz#1968519] - kvm-Remove-RHEL-7.5.0-machine-types.patch [bz#1968519] - kvm-acpi-pc-revert-back-to-v5.2-PCI-slot-enumeration.patch [bz#1957194] - kvm-migration-failover-reset-partially_hotplugged.patch [bz#1957194] - kvm-hmp-Fix-loadvm-to-resume-the-VM-on-success-instead-o.patch [bz#1957194] - kvm-migration-Move-bitmap_mutex-out-of-migration_bitmap_.patch [bz#1957194] - kvm-i386-cpu-Expose-AVX_VNNI-instruction-to-guest.patch [bz#1957194] - kvm-ratelimit-protect-with-a-mutex.patch [bz#1957194] - kvm-Update-Linux-headers-to-5.13-rc4.patch [bz#1957194] - kvm-i386-Add-ratelimit-for-bus-locks-acquired-in-guest.patch [bz#1957194] - kvm-iothread-generalize-iothread_set_param-iothread_get_.patch [bz#1957194] - kvm-iothread-add-aio-max-batch-parameter.patch [bz#1957194] - kvm-linux-aio-limit-the-batch-size-using-aio-max-batch-p.patch [bz#1957194] - kvm-block-nvme-Fix-VFIO_MAP_DMA-failed-No-space-left-on-.patch [bz#1957194] - kvm-migration-move-wait-unplug-loop-to-its-own-function.patch [bz#1957194] - kvm-migration-failover-continue-to-wait-card-unplug-on-e.patch [bz#1957194] - kvm-aarch64-Add-USB-storage-devices.patch [bz#1957194] - kvm-iotests-Improve-and-rename-test-291-to-qemu-img-bitm.patch [bz#1957194] - kvm-qemu-img-Fail-fast-on-convert-bitmaps-with-inconsist.patch [bz#1957194] - kvm-qemu-img-Add-skip-broken-bitmaps-for-convert-bitmaps.patch [bz#1957194] - kvm-audio-Never-send-migration-section.patch [bz#1957194] - kvm-pc-bios-s390-ccw-bootmap-Silence-compiler-warning-fr.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Use-reset_psw-pointer-instead-of-ha.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-netboot-Use-Wl-prefix-to-pass-param.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Silence-warning-from-Clang-by-marki.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Fix-the-cc-option-macro-in-the-Make.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Silence-GCC-11-stringop-overflow-wa.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Allow-building-with-Clang-too.patch [bz#1939509 bz#1940132] - kvm-pc-bios-s390-ccw-Fix-inline-assembly-for-older-versi.patch [bz#1939509 bz#1940132] - kvm-configure-Fix-endianess-test-with-LTO.patch [bz#1939509 bz#1940132] - kvm-spec-Switch-toolchain-to-Clang-LLVM.patch [bz#1939509 bz#1940132] - kvm-spec-Use-safe-stack-for-x86_64.patch [bz#1939509 bz#1940132] - kvm-spec-Reenable-write-support-for-VMDK-etc.-in-tools.patch [bz#1989841] - Resolves: bz#1974683 (Fail to set migrate incoming for 2nd time after the first time failed) - Resolves: bz#1968519 (Remove all the old 7.0-7.5 machine types) - Resolves: bz#1957194 (Synchronize RHEL-AV 8.5.0 changes to RHEL 9.0.0 Beta) - Resolves: bz#1939509 (QEMU: enable SafeStack) - Resolves: bz#1940132 (QEMU: switch build toolchain to Clang/LLVM) - Resolves: bz#1989841 (RFE: qemu-img cannot convert images into vmdk and vpc formats)
76 lines
3.1 KiB
Diff
76 lines
3.1 KiB
Diff
From c5b348e6d0334333295332c55fc4be51ce2668b8 Mon Sep 17 00:00:00 2001
|
||
From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= <philmd@redhat.com>
|
||
Date: Thu, 22 Apr 2021 16:59:11 +0200
|
||
Subject: [PATCH 33/39] pc-bios/s390-ccw: Silence GCC 11 stringop-overflow
|
||
warning
|
||
MIME-Version: 1.0
|
||
Content-Type: text/plain; charset=UTF-8
|
||
Content-Transfer-Encoding: 8bit
|
||
|
||
RH-Author: Jon Maloy <jmaloy@redhat.com>
|
||
RH-MergeRequest: 24: v7: Add support for building qemu-kvm with clang and safe-stack
|
||
RH-Commit: [6/11] 92851a154f2425363aa1f5ed2bb12740f589229e (jmaloy/qemu-kvm-centos-jon)
|
||
RH-Bugzilla: 1939509 1940132
|
||
RH-Acked-by: Danilo Cesar Lemes de Paula <ddepaula@redhat.com>
|
||
RH-Acked-by: Thomas Huth <thuth@redhat.com>
|
||
RH-Acked-by: Cornelia Huck <cohuck@redhat.com>
|
||
|
||
When building on Fedora 34 (gcc version 11.0.0 20210210) we get:
|
||
|
||
In file included from pc-bios/s390-ccw/main.c:11:
|
||
In function ‘memset’,
|
||
inlined from ‘boot_setup’ at pc-bios/s390-ccw/main.c:185:5,
|
||
inlined from ‘main’ at pc-bios/s390-ccw/main.c:288:5:
|
||
pc-bios/s390-ccw/libc.h:28:14: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]
|
||
28 | p[i] = c;
|
||
| ~~~~~^~~
|
||
|
||
The offending code is:
|
||
|
||
memset((char *)S390EP, 0, 6);
|
||
|
||
where S390EP is a const address:
|
||
|
||
#define S390EP 0x10008
|
||
|
||
The compiler doesn't know how big that pointed area is, so it assume that
|
||
its length is zero. This has been reported as BZ#99578 to GCC:
|
||
"gcc-11 -Warray-bounds or -Wstringop-overread warning when accessing a
|
||
pointer from integer literal"
|
||
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99578
|
||
|
||
As this warning does us more harm than good in the BIOS code (where
|
||
lot of direct accesses to low memory are done), silence this warning
|
||
for all BIOS objects.
|
||
|
||
Suggested-by: Thomas Huth <thuth@redhat.com>
|
||
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
|
||
Message-Id: <20210422145911.2513980-1-philmd@redhat.com>
|
||
Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
|
||
Message-Id: <20210502174836.838816-4-thuth@redhat.com>
|
||
[thuth: Use the pre-existing cc-option macro instead of adding a new one]
|
||
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
|
||
Signed-off-by: Thomas Huth <thuth@redhat.com>
|
||
(cherry picked from commit da231910d33084ccf63f07de210b145e0fa31d98)
|
||
Signed-off-by: Jon Maloy <jmaloy@redhat.com>
|
||
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
||
---
|
||
pc-bios/s390-ccw/Makefile | 1 +
|
||
1 file changed, 1 insertion(+)
|
||
|
||
diff --git a/pc-bios/s390-ccw/Makefile b/pc-bios/s390-ccw/Makefile
|
||
index f0fe84c9eb..83fb1afb73 100644
|
||
--- a/pc-bios/s390-ccw/Makefile
|
||
+++ b/pc-bios/s390-ccw/Makefile
|
||
@@ -30,6 +30,7 @@ OBJECTS = start.o main.o bootmap.o jump2ipl.o sclp.o menu.o \
|
||
virtio.o virtio-scsi.o virtio-blkdev.o libc.o cio.o dasd-ipl.o
|
||
|
||
QEMU_CFLAGS := -Wall $(filter -W%, $(QEMU_CFLAGS))
|
||
+QEMU_CFLAGS += $(call cc-option,-Werror $(QEMU_CFLAGS),-Wno-stringop-overflow)
|
||
QEMU_CFLAGS += -ffreestanding -fno-delete-null-pointer-checks -fno-common -fPIE
|
||
QEMU_CFLAGS += -fwrapv -fno-strict-aliasing -fno-asynchronous-unwind-tables
|
||
QEMU_CFLAGS += $(call cc-option, $(QEMU_CFLAGS), -fno-stack-protector)
|
||
--
|
||
2.27.0
|
||
|