All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Igor Mammedov <imammedo@redhat.com>
Cc: "pingfank@linux.vnet.ibm.com" <pingfank@linux.vnet.ibm.com>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
	"gleb@redhat.com" <gleb@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 2/3] VCPU hotplug support
Date: Tue, 17 Jan 2012 15:22:51 +0100	[thread overview]
Message-ID: <4F15843B.7090108@siemens.com> (raw)
In-Reply-To: <4F1582E2.9080007@siemens.com>

On 2012-01-17 15:17, Jan Kiszka wrote:
>>  
>>  /* output Bochs bios info messages */
>>  //#define DEBUG_BIOS
>> @@ -930,10 +932,22 @@ static void pc_cpu_reset(void *opaque)
>>      env->halted = !cpu_is_bsp(env);
>>  }
>>  
>> -static CPUState *pc_new_cpu(const char *cpu_model)
>> +CPUState *pc_new_cpu(const char *cpu_model)
>>  {
>>      CPUState *env;
>>  
>> +    if (cpu_model == NULL) {
>> +#ifdef TARGET_X86_64
>> +        cpu_model = "qemu64";
>> +#else
>> +        cpu_model = "qemu32";
>> +#endif
> 
> Just always initialize global_cpu_model to a non-NULL value.

Another interface idea: cache the first cpu_model in this function and
use the cached one if a later call passes in NULL. That way PIIX4 would
not need to have access to an ugly global variable.

Jan

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux

  reply	other threads:[~2012-01-17 14:23 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-17 13:17 [Qemu-devel] [PATCH 0/3] Make vcpu hotplug work for qemu Igor Mammedov
2012-01-17 13:17 ` [Qemu-devel] [PATCH 1/3] Introduce a new bus "ICC" to connect APIC Igor Mammedov
2012-01-17 13:57   ` Jan Kiszka
2012-01-17 13:17 ` [Qemu-devel] [PATCH 2/3] VCPU hotplug support Igor Mammedov
2012-01-17 14:17   ` Jan Kiszka
2012-01-17 14:22     ` Jan Kiszka [this message]
2012-01-23 16:29     ` Igor Mammedov
2012-01-23 17:55       ` Jan Kiszka
2012-01-24 16:24         ` Igor Mammedov
2012-01-24 16:37           ` Jan Kiszka
2012-01-17 13:17 ` [Qemu-devel] [PATCH 3/3] add cpu_set qmp command Igor Mammedov
2012-01-17 14:18   ` Jan Kiszka
2012-01-19  9:38     ` Igor Mammedov
2012-01-19 10:24       ` Jan Kiszka
2012-01-19 11:04         ` Igor Mammedov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F15843B.7090108@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=gleb@redhat.com \
    --cc=imammedo@redhat.com \
    --cc=pingfank@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.