All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] qemu-kvm: Remove kvm_set_boot_cpu_id
@ 2011-06-03 14:39 Jan Kiszka
  2011-06-20 14:56 ` Marcelo Tosatti
  0 siblings, 1 reply; 2+ messages in thread
From: Jan Kiszka @ 2011-06-03 14:39 UTC (permalink / raw)
  To: Avi Kivity, Marcelo Tosatti; +Cc: kvm

Upstream just as well as qemu-kvm only support CPU 0 as boot CPU. And
that is also the KVM ABI default if the user does not issue any
KVM_SET_BOOT_CPU_ID.

So let's drop this redundancy. It can be re-introduced via upstream once
we support something more sophisticated.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 qemu-kvm.c        |   11 -----------
 qemu-kvm.h        |    2 --
 target-i386/kvm.c |    5 -----
 3 files changed, 0 insertions(+), 18 deletions(-)

diff --git a/qemu-kvm.c b/qemu-kvm.c
index 649af9c..80cc077 100644
--- a/qemu-kvm.c
+++ b/qemu-kvm.c
@@ -655,14 +655,3 @@ int kvm_update_ioport_access(CPUState *env)
 #endif /* CONFIG_KVM_DEVICE_ASSIGNMENT */
     return 0;
 }
-
-int kvm_set_boot_cpu_id(KVMState *s, uint32_t id)
-{
-#ifdef KVM_CAP_SET_BOOT_CPU_ID
-    int r = kvm_ioctl(s, KVM_CHECK_EXTENSION, KVM_CAP_SET_BOOT_CPU_ID);
-    if (r > 0) {
-        return kvm_vm_ioctl(s, KVM_SET_BOOT_CPU_ID, id);
-    }
-#endif
-    return -ENOSYS;
-}
diff --git a/qemu-kvm.h b/qemu-kvm.h
index 942baf2..09d07d0 100644
--- a/qemu-kvm.h
+++ b/qemu-kvm.h
@@ -291,8 +291,6 @@ extern unsigned int kvm_shadow_memory;
 
 int kvm_handle_tpr_access(CPUState *env);
 
-int kvm_set_boot_cpu_id(KVMState *s, uint32_t id);
-
 #else
 #define kvm_nested 0
 #endif
diff --git a/target-i386/kvm.c b/target-i386/kvm.c
index 74a9960..de26646 100644
--- a/target-i386/kvm.c
+++ b/target-i386/kvm.c
@@ -662,11 +662,6 @@ int kvm_arch_init(KVMState *s)
         }
     }
 
-    ret = kvm_set_boot_cpu_id(s, 0);
-    if (ret < 0 && ret != -ENOSYS) {
-        return ret;
-    }
-
     return 0;
 }
 
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] qemu-kvm: Remove kvm_set_boot_cpu_id
  2011-06-03 14:39 [PATCH] qemu-kvm: Remove kvm_set_boot_cpu_id Jan Kiszka
@ 2011-06-20 14:56 ` Marcelo Tosatti
  0 siblings, 0 replies; 2+ messages in thread
From: Marcelo Tosatti @ 2011-06-20 14:56 UTC (permalink / raw)
  To: Jan Kiszka; +Cc: Avi Kivity, kvm

On Fri, Jun 03, 2011 at 04:39:55PM +0200, Jan Kiszka wrote:
> Upstream just as well as qemu-kvm only support CPU 0 as boot CPU. And
> that is also the KVM ABI default if the user does not issue any
> KVM_SET_BOOT_CPU_ID.
> 
> So let's drop this redundancy. It can be re-introduced via upstream once
> we support something more sophisticated.
> 
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
>  qemu-kvm.c        |   11 -----------
>  qemu-kvm.h        |    2 --
>  target-i386/kvm.c |    5 -----
>  3 files changed, 0 insertions(+), 18 deletions(-)

Applied, thanks.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-06-20 16:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-03 14:39 [PATCH] qemu-kvm: Remove kvm_set_boot_cpu_id Jan Kiszka
2011-06-20 14:56 ` Marcelo Tosatti

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.