qemu-e2k/hw
Philippe Mathieu-Daudé 52ad57a9b6 hw/intc/i8259: Refactor pic_read_irq() to avoid uninitialized variable
Some compiler versions are smart enough to detect a potentially
uninitialized variable, but are not smart enough to detect that this
cannot happen due to the code flow:

../hw/intc/i8259.c: In function ‘pic_read_irq’:
../hw/intc/i8259.c:203:13: error: ‘irq2’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
   203 |         irq = irq2 + 8;
       |         ~~~~^~~~~~~~~~

Restrict irq2 variable use to the inner statement.

Fixes: 78ef2b6989 ("i8259: Reorder intack in pic_read_irq")
Reported-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210318163059.3686596-1-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-03-19 08:48:18 -04:00
..
9pfs hw/9pfs/9p-synth: Replaced qemu_mutex_lock with QEMU_LOCK_GUARD 2021-03-16 11:41:49 +01:00
acpi
adc clock: Add ClockEvent parameter to callbacks 2021-03-08 17:20:01 +00:00
alpha
arm hw/arm: Connect PWM fans in NPCM7XX boards 2021-03-12 12:50:36 +00:00
audio
avr hw/avr/arduino: List board schematic links 2021-03-15 00:39:52 +01:00
block Parallel NOR Flash patches queue 2021-03-18 23:04:41 +00:00
char hw/char: add goldfish-tty 2021-03-15 21:02:03 +01:00
core Remove many old deprecated features 2021-03-18 19:00:50 +00:00
cpu
cris
display target-arm queue: 2021-03-14 13:18:49 +00:00
dma target-arm queue: 2021-03-10 13:57:31 +00:00
gpio
hppa
hyperv
i2c
i386 hw/scsi: remove 'scsi-disk' device 2021-03-18 09:22:55 +00:00
ide hw/ide: remove 'ide-drive' device 2021-03-18 09:22:55 +00:00
input
intc hw/intc/i8259: Refactor pic_read_irq() to avoid uninitialized variable 2021-03-19 08:48:18 -04:00
ipack
ipmi
isa hw/southbridge: Add missing Kconfig dependency VT82C686 on USB_UHCI 2021-03-15 17:00:59 +01:00
lm32 hw/lm32/Kconfig: Have MILKYMIST select LM32_DEVICES 2021-03-09 22:37:08 +01:00
m68k m68k: add Virtual M68k Machine 2021-03-15 21:03:06 +01:00
mem memory: add a sparse memory device for fuzzing 2021-03-16 14:30:30 -04:00
microblaze
mips hw/mips/gt64xxx: Trace accesses to ISD registers 2021-03-13 20:29:36 +01:00
misc q800 pull request 20210316 2021-03-18 10:05:37 +00:00
moxie
net net: Move NetClientState.info_str to dynamic allocations 2021-03-15 16:41:22 +08:00
nios2
nubus
nvram sysemu: Let VMChangeStateHandler take boolean 'running' argument 2021-03-09 23:13:57 +01:00
openrisc
pci
pci-bridge
pci-host
pcmcia
ppc hw/ide: remove 'ide-drive' device 2021-03-18 09:22:55 +00:00
rdma pvrdma: wean code off pvrdma_ring.h kernel header 2021-03-15 16:41:22 +08:00
remote
riscv Testing, guest-loader and other misc tweaks 2021-03-11 16:20:58 +00:00
rtc
rx qtest: delete superfluous inclusions of qtest.h 2021-03-09 06:03:53 +01:00
s390x s390x/pci: Add missing initialization for g_autofree variables 2021-03-15 15:47:18 +01:00
scsi hw/scsi: remove 'scsi-disk' device 2021-03-18 09:22:55 +00:00
sd
sh4
smbios
sparc
sparc64 hw/ide: remove 'ide-drive' device 2021-03-18 09:22:55 +00:00
ssi hw/ssi: xilinx_spips: Remove DMA related dead codes from zynqmp_spips 2021-03-10 13:54:51 +00:00
timer hw/i8254: fix vmstate load 2021-03-16 14:30:30 -04:00
tpm
tricore tricore: added triboard with tc27x_soc 2021-03-14 14:41:55 +01:00
unicore32
usb usb/storage: clear csw on reset 2021-03-15 17:01:17 +01:00
vfio vfio/migrate: Move switch of dirty tracking into vfio_memory_listener 2021-03-16 10:06:44 -06:00
virtio virtio-net: calculating proper msix vectors on init 2021-03-15 16:41:22 +08:00
watchdog clock: Add ClockEvent parameter to callbacks 2021-03-08 17:20:01 +00:00
xen
xenpv
xtensa
Kconfig semihosting: Move hw/semihosting/ -> semihosting/ 2021-03-10 15:34:12 +00:00
meson.build semihosting: Move hw/semihosting/ -> semihosting/ 2021-03-10 15:34:12 +00:00