qemu-patch-raspberry4/hw/arm
Ard Biesheuvel 886bc7a049 hw/arm/virt: fix cmdline parsing bug with CPU options and smp > 1
The recently introduced feature that allows 32 bit guests to be
executed under KVM on a 64-bit host incorrectly handles the case
where more than 1 cpu is specified using '-smp N'

For instance, this invocation of qemu

  qemu-system-aarch64 -M virt -cpu cortex-a57,aarch64=off -smp 2

produces the following error

  qemu-system-aarch64: Expected key=value format, found aarch64

which is caused by the destructive parsing performed by
cpu_common_parse_features(), resulting in subsequent attempts
to parse the CPU option string (for each additional CPU) to fail.

So duplicate the string before parsing it, and free it directly
afterwards.

Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Greg Bellows <greg.bellows@linaro.org>
Message-id: 1425402380-10488-1-git-send-email-ard.biesheuvel@linaro.org
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-11 13:21:05 +00:00
..
allwinner-a10.c hw/arm/allwinner-a10: initialize EMAC 2014-02-08 14:50:48 +00:00
armv7m.c target_arm: Parameterise the irq lines for armv7m_init 2015-02-05 13:37:21 +00:00
boot.c target-arm: Change reset to highest available EL 2015-02-05 13:37:22 +00:00
collie.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
cubieboard.c memory: add parameter errp to memory_region_init_ram 2014-09-09 13:41:43 +02:00
digic.c hw/arm/digic: add UART support 2013-12-17 20:12:51 +00:00
digic_boards.c arm/digic_boards: Remove superfluous '\n' around error_report() 2015-03-10 08:15:33 +03:00
exynos4_boards.c machine: Conversion of QEMUMachineInitArgs to MachineState 2014-05-28 17:35:01 +02:00
exynos4210.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
gumstix.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
highbank.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
integratorcp.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
kzm.c memory: add parameter errp to memory_region_init_ram 2014-09-09 13:41:43 +02:00
mainstone.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
Makefile.objs hw/arm: add cubieboard support 2013-12-17 20:12:51 +00:00
musicpal.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
nseries.c hw/usb: simplified usb_enabled 2015-01-08 17:32:27 +00:00
omap1.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
omap2.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
omap_sx1.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
palm.c memory: add parameter errp to memory_region_init_ram 2014-09-09 13:41:43 +02:00
pxa2xx.c hw/usb: simplified usb_enabled 2015-01-08 17:32:27 +00:00
pxa2xx_gpio.c hw/arm/pxa2xx_gpio: Correct and register vmstate 2014-06-29 18:38:40 +01:00
pxa2xx_pic.c savevm: Remove all the unneeded version_minimum_id_old (arm) 2014-05-13 16:09:35 +01:00
realview.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
spitz.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
stellaris.c target_arm: Parameterise the irq lines for armv7m_init 2015-02-05 13:37:21 +00:00
strongarm.c memory: add parameter errp to memory_region_init_ram 2014-09-09 13:41:43 +02:00
strongarm.h hw: move private headers to hw/ subdirectories. 2013-04-08 18:13:16 +02:00
tosa.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
versatilepb.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
vexpress.c hw: Propagate errors through qdev_prop_set_drive() 2015-03-10 11:18:23 +01:00
virt.c hw/arm/virt: fix cmdline parsing bug with CPU options and smp > 1 2015-03-11 13:21:05 +00:00
xilinx_zynq.c error: Use error_report_err() where appropriate 2015-02-18 10:51:09 +01:00
z2.c hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00