qemu-e2k/hw
Eric Blake a73049b2a1 numa: Check for qemu_strtosz_MiB error
As shown in the previous commit, qemu_strtosz_MiB sometimes leaves the
result value untouched (we have to audit further to learn that in that
case, the QAPI generator says that visit_type_NumaOptions() will have
zero-initialized it), and sometimes leaves it with the value of a
partial parse before -EINVAL occurs because of trailing garbage.
Rather than blindly treating any string the user may throw at us as
valid, we should check for parse failures.

Fixes: cc001888 ("numa: fixup parsed NumaNodeOptions earlier", v2.11.0)
Signed-off-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Hanna Czenczek <hreitz@redhat.com>
Message-Id: <20230522190441.64278-14-eblake@redhat.com>
2023-06-02 12:29:27 -05:00
..
9pfs
acpi
adc
alpha
arm
audio
avr
block
char
core numa: Check for qemu_strtosz_MiB error 2023-06-02 12:29:27 -05:00
cpu
cris
cxl
display
dma
gpio
hppa
hyperv
i2c
i386
ide
input
intc
ipack
ipmi
isa
loongarch
m68k
mem
microblaze
mips
misc
net
nios2
nubus
nvme
nvram
openrisc
pci
pci-bridge
pci-host
pcmcia
ppc
rdma
remote
riscv
rtc
rx
s390x
scsi
sd
sensor
sh4
smbios
sparc
sparc64
ssi
timer
tpm
tricore
usb
vfio
virtio
watchdog
xen
xenpv
xtensa
Kconfig
meson.build