Skip to contentSkip to conversation

use kvm_has_sync_mmu from upstream.

PATCH Applied Glauber Costa 2 participants 2 messages Jul 24, 2009 – Jul 29, 2009 KVM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 use kvm_has_sync_mmu from upstream.

they have it, and it does the same as we do.

---
 kvm-all.c  |    3 +++
 qemu-kvm.c |    9 ---------
 2 files changed, 3 insertions(+), 9 deletions(-)
kvm-all.c +3 -0
index b4b5a35..157b968 100644
@@ -848,6 +848,8 @@ int kvm_vcpu_ioctl(CPUState *env, int type, ...)
     return ret;
 }
 
+#endif
+
 int kvm_has_sync_mmu(void)
 {
 #ifdef KVM_CAP_SYNC_MMU
@@ -859,6 +861,7 @@ int kvm_has_sync_mmu(void)
 #endif
 }
 
+#ifdef KVM_UPSTREAM
 void kvm_setup_guest_memory(void *start, size_t size)
 {
     if (!kvm_has_sync_mmu()) {
qemu-kvm.c +0 -9
index bca256c..fdf71a8 100644
@@ -1152,15 +1152,6 @@ int kvm_pit_in_kernel(kvm_context_t kvm)
 	return kvm->pit_in_kernel;
 }
 
-int kvm_has_sync_mmu(void)
-{
-        int r = 0;
-#ifdef KVM_CAP_SYNC_MMU
-        r = kvm_ioctl(kvm_state, KVM_CHECK_EXTENSION, KVM_CAP_SYNC_MMU);
-#endif
-        return r;
-}
-
 int kvm_inject_nmi(kvm_vcpu_context_t vcpu)
 {
 #ifdef KVM_CAP_USER_NMI
Signature · 1 line
1.6.2.2
Applied
#1 lore raw
Quoted 2 lines · Glauber Costa

they have it, and it does the same as we do.

Applied, thanks.

Signature · 1 line
error compiling committee.c: too many arguments to function