qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] target-i386: pc: fix crash when attempting hotp


From: Andreas Färber
Subject: Re: [Qemu-devel] [PATCH] target-i386: pc: fix crash when attempting hotplug CPU with negative ID
Date: Thu, 30 May 2013 17:24:35 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130510 Thunderbird/17.0.6

Am 30.05.2013 17:09, schrieb Igor Mammedov:
> QMP command "{ 'execute': 'cpu-add', 'arguments': { 'id': -1 }}" may cause
> QEMU SIGSEGV at:
>  piix4_cpu_hotplug_req ()
>     ...
>     g->sts[cpu_id / 8] |= (1 << (cpu_id % 8));
>     ...
> 
> Since for PC in current implementation id should be in range [0...maxcpus)
> and maxcpus already checked, add check for lower bound and error out
> on incorrect value.
> 
> Signed-off-by: Igor Mammedov <address@hidden>
> ---
>  hw/i386/pc.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)

Thanks, applied to qom-cpu (with commit message massaged a bit):
https://github.com/afaerber/qemu-cpu/commits/qom-cpu

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg



reply via email to

[Prev in Thread] Current Thread [Next in Thread]