All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gleb Natapov <gleb@redhat.com>
To: avi@redhat.com
Cc: kvm@vger.kernel.org
Subject: [PATCH 5/6] Rename kvm_(load|save)_mpstate to kvm_arch_(load|save)_mpstate
Date: Sun, 14 Jun 2009 13:52:21 +0300	[thread overview]
Message-ID: <1244976742-22926-5-git-send-email-gleb@redhat.com> (raw)
In-Reply-To: <1244976742-22926-1-git-send-email-gleb@redhat.com>

To be consistent with other function naming.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
---
 qemu-kvm-ia64.c       |    4 ++--
 qemu-kvm-x86.c        |    4 ++--
 qemu-kvm.h            |    2 ++
 target-i386/machine.c |    6 +++---
 target-ia64/machine.c |    4 ++--
 5 files changed, 11 insertions(+), 9 deletions(-)

diff --git a/qemu-kvm-ia64.c b/qemu-kvm-ia64.c
index d33c1c3..234602c 100644
--- a/qemu-kvm-ia64.c
+++ b/qemu-kvm-ia64.c
@@ -98,7 +98,7 @@ void kvm_arch_update_guest_debug(CPUState *env, struct kvm_guest_debug *dbg)
 {
 }
 
-void kvm_save_mpstate(CPUState *env)
+void kvm_arch_save_mpstate(CPUState *env)
 {
 #ifdef KVM_CAP_MP_STATE
     int r;
@@ -112,7 +112,7 @@ void kvm_save_mpstate(CPUState *env)
 #endif
 }
 
-void kvm_load_mpstate(CPUState *env)
+void kvm_arch_load_mpstate(CPUState *env)
 {
 #ifdef KVM_CAP_MP_STATE
     struct kvm_mp_state mp_state = { .mp_state = env->mp_state };
diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c
index 729d600..8e6fb75 100644
--- a/qemu-kvm-x86.c
+++ b/qemu-kvm-x86.c
@@ -295,7 +295,7 @@ void kvm_load_tsc(CPUState *env)
         perror("kvm_set_tsc FAILED.\n");
 }
 
-void kvm_save_mpstate(CPUState *env)
+void kvm_arch_save_mpstate(CPUState *env)
 {
 #ifdef KVM_CAP_MP_STATE
     int r;
@@ -309,7 +309,7 @@ void kvm_save_mpstate(CPUState *env)
 #endif
 }
 
-void kvm_load_mpstate(CPUState *env)
+void kvm_arch_load_mpstate(CPUState *env)
 {
 #ifdef KVM_CAP_MP_STATE
     struct kvm_mp_state mp_state = { .mp_state = env->mp_state };
diff --git a/qemu-kvm.h b/qemu-kvm.h
index fa40542..3b73fe9 100644
--- a/qemu-kvm.h
+++ b/qemu-kvm.h
@@ -69,6 +69,8 @@ int kvm_arch_qemu_create_context(void);
 
 void kvm_arch_save_regs(CPUState *env);
 void kvm_arch_load_regs(CPUState *env);
+void kvm_arch_load_mpstate(CPUState *env);
+void kvm_arch_save_mpstate(CPUState *env);
 int kvm_arch_qemu_init_env(CPUState *cenv);
 void kvm_arch_pre_kvm_run(void *opaque, CPUState *env);
 void kvm_arch_post_kvm_run(void *opaque, CPUState *env);
diff --git a/target-i386/machine.c b/target-i386/machine.c
index 07df1e1..14942c0 100644
--- a/target-i386/machine.c
+++ b/target-i386/machine.c
@@ -34,7 +34,7 @@ void cpu_save(QEMUFile *f, void *opaque)
 
     if (kvm_enabled()) {
         kvm_save_registers(env);
-        kvm_save_mpstate(env);
+        kvm_arch_save_mpstate(env);
     }
 
     for(i = 0; i < CPU_NB_REGS; i++)
@@ -369,12 +369,12 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id)
             kvm_load_tsc(env);
             if (version_id >= 5) {
                 qemu_get_be32s(f, &env->mp_state);
-                kvm_load_mpstate(env);
+                kvm_arch_load_mpstate(env);
             }
         } else {
             kvm_load_registers(env);
             kvm_load_tsc(env);
-            kvm_load_mpstate(env);
+            kvm_arch_load_mpstate(env);
         }
     }
     return 0;
diff --git a/target-ia64/machine.c b/target-ia64/machine.c
index dd205c5..70ef379 100644
--- a/target-ia64/machine.c
+++ b/target-ia64/machine.c
@@ -10,7 +10,7 @@ void cpu_save(QEMUFile *f, void *opaque)
 
     if (kvm_enabled()) {
         kvm_save_registers(env);
-        kvm_save_mpstate(env);
+        kvm_arch_save_mpstate(env);
     }
 }
 
@@ -20,7 +20,7 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id)
 
     if (kvm_enabled()) {
         kvm_load_registers(env);
-        kvm_load_mpstate(env);
+        kvm_arch_load_mpstate(env);
     }
     return 0;
 }
-- 
1.6.2.1


  parent reply	other threads:[~2009-06-14 10:52 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-14 10:52 [PATCH 1/6] env->kvm_cpu_state.init is always zero here Gleb Natapov
2009-06-14 10:52 ` [PATCH 2/6] Do not use env->halted to decide where halted state should be handled Gleb Natapov
2009-06-14 10:52 ` [PATCH 3/6] Call kvm_arch_load_regs() instead of kvm_load_registers() Gleb Natapov
2009-06-14 10:52 ` [PATCH 4/6] Handle vcpu init/sipi by calling a function on vcpu Gleb Natapov
2009-06-15 10:03   ` Avi Kivity
2009-06-15 10:11     ` Gleb Natapov
2009-06-15 10:14       ` Avi Kivity
2009-06-15 10:16         ` Gleb Natapov
2009-06-15 10:26           ` Avi Kivity
2009-06-14 10:52 ` Gleb Natapov [this message]
2009-06-14 10:52 ` [PATCH 6/6] Retrieve mp state info in cpu_synchronize_state() Gleb Natapov
2009-06-15  9:55 ` [PATCH 1/6] env->kvm_cpu_state.init is always zero here Avi Kivity
2009-06-15  9:58   ` Gleb Natapov
2009-06-15 10:05     ` Avi Kivity

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=1244976742-22926-5-git-send-email-gleb@redhat.com \
    --to=gleb@redhat.com \
    --cc=avi@redhat.com \
    --cc=kvm@vger.kernel.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.