qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] Fix CPU topology initialization


From: Anthony Liguori
Subject: Re: [Qemu-devel] [PATCH] Fix CPU topology initialization
Date: Mon, 11 Jan 2010 10:01:24 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.5) Gecko/20091209 Fedora/3.0-4.fc12 Lightning/1.0pre Thunderbird/3.0

On 01/05/2010 10:26 AM, Jiri Denemark wrote:
Late initialization of CPU topology in CPUState prevents KVM guests to
actually see the topology.

Signed-off-by: Jiri Denemark<address@hidden>

Applied.  Thanks.

Regards,

Anthony Liguori
---
  vl.c |    8 ++++----
  1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/vl.c b/vl.c
index e881e45..a03d7a6 100644
--- a/vl.c
+++ b/vl.c
@@ -3484,10 +3484,10 @@ void qemu_init_vcpu(void *_env)
  {
      CPUState *env = _env;

-    if (kvm_enabled())
-        kvm_init_vcpu(env);
      env->nr_cores = smp_cores;
      env->nr_threads = smp_threads;
+    if (kvm_enabled())
+        kvm_init_vcpu(env);
      return;
  }

@@ -3813,12 +3813,12 @@ void qemu_init_vcpu(void *_env)
  {
      CPUState *env = _env;

+    env->nr_cores = smp_cores;
+    env->nr_threads = smp_threads;
      if (kvm_enabled())
          kvm_start_vcpu(env);
      else
          tcg_init_vcpu(env);
-    env->nr_cores = smp_cores;
-    env->nr_threads = smp_threads;
  }

  void qemu_notify_event(void)





reply via email to

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