Patchwork [v3,02/21] kvm: Drop return value of kvm_cpu_exec

login
register
mail settings
Submitter Jan Kiszka
Date Jan. 4, 2011, 8:32 a.m.
Message ID <fa9d5605729977f1c6fdc97bbe94b0e295a7d0b8.1294129949.git.jan.kiszka@web.de>
Download mbox | patch
Permalink /patch/77403/
State New
Headers show

Comments

Jan Kiszka - Jan. 4, 2011, 8:32 a.m.
From: Jan Kiszka <jan.kiszka@siemens.com>

It is not used, it is not needed, so let's remove it.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
 kvm-all.c  |    6 ++----
 kvm-stub.c |    4 ++--
 kvm.h      |    2 +-
 3 files changed, 5 insertions(+), 7 deletions(-)

Patch

diff --git a/kvm-all.c b/kvm-all.c
index 2538283..7518f2c 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -850,7 +850,7 @@  void kvm_cpu_synchronize_post_init(CPUState *env)
     env->kvm_vcpu_dirty = 0;
 }
 
-int kvm_cpu_exec(CPUState *env)
+void kvm_cpu_exec(CPUState *env)
 {
     struct kvm_run *run = env->kvm_run;
     int ret;
@@ -943,7 +943,7 @@  int kvm_cpu_exec(CPUState *env)
 #ifdef KVM_CAP_SET_GUEST_DEBUG
             if (kvm_arch_debug(&run->debug.arch)) {
                 env->exception_index = EXCP_DEBUG;
-                return 0;
+                return;
             }
             /* re-enter, this exception was guest-internal */
             ret = 1;
@@ -960,8 +960,6 @@  int kvm_cpu_exec(CPUState *env)
         env->exit_request = 0;
         env->exception_index = EXCP_INTERRUPT;
     }
-
-    return ret;
 }
 
 int kvm_ioctl(KVMState *s, int type, ...)
diff --git a/kvm-stub.c b/kvm-stub.c
index 5384a4b..352c6a6 100644
--- a/kvm-stub.c
+++ b/kvm-stub.c
@@ -79,9 +79,9 @@  void kvm_cpu_synchronize_post_init(CPUState *env)
 {
 }
 
-int kvm_cpu_exec(CPUState *env)
+void kvm_cpu_exec(CPUState *env)
 {
-    abort ();
+    abort();
 }
 
 int kvm_has_sync_mmu(void)
diff --git a/kvm.h b/kvm.h
index 60a9b42..51ad56f 100644
--- a/kvm.h
+++ b/kvm.h
@@ -46,7 +46,7 @@  int kvm_has_xcrs(void);
 #ifdef NEED_CPU_H
 int kvm_init_vcpu(CPUState *env);
 
-int kvm_cpu_exec(CPUState *env);
+void kvm_cpu_exec(CPUState *env);
 
 #if !defined(CONFIG_USER_ONLY)
 int kvm_log_start(target_phys_addr_t phys_addr, ram_addr_t size);