From: Jan Kiszka <jan.kiszka@web.de>
To: Avi Kivity <avi@redhat.com>, Marcelo Tosatti <mtosatti@redhat.com>
Cc: kvm <kvm@vger.kernel.org>
Subject: [PATCH] qemu-kvm: Drop redundant kvm_reset_mpstate
Date: Wed, 29 Dec 2010 19:53:39 +0100 [thread overview]
Message-ID: <4D1B83B3.4060607@web.de> (raw)
From: Jan Kiszka <jan.kiszka@siemens.com>
kvm_arch_reset_vcpu includes the same logic (minus the obsolete feature
check), and every caller of kvm_reset_mpstate also calls that function.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
---
qemu-kvm-x86.c | 16 ----------------
1 files changed, 0 insertions(+), 16 deletions(-)
diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c
index 672bcbf..2f1a090 100644
--- a/qemu-kvm-x86.c
+++ b/qemu-kvm-x86.c
@@ -564,20 +564,6 @@ static void kvm_arch_load_mpstate(CPUState *env)
#endif
}
-static void kvm_reset_mpstate(CPUState *env)
-{
-#ifdef KVM_CAP_MP_STATE
- if (kvm_check_extension(kvm_state, KVM_CAP_MP_STATE)) {
- if (kvm_irqchip_in_kernel()) {
- env->mp_state = cpu_is_bsp(env) ? KVM_MP_STATE_RUNNABLE :
- KVM_MP_STATE_UNINITIALIZED;
- } else {
- env->mp_state = KVM_MP_STATE_RUNNABLE;
- }
- }
-#endif
-}
-
#define XSAVE_CWD_RIP 2
#define XSAVE_CWD_RDP 4
#define XSAVE_MXCSR 6
@@ -652,7 +638,6 @@ static int _kvm_arch_init_vcpu(CPUState *env)
#ifdef KVM_EXIT_TPR_ACCESS
kvm_enable_tpr_access_reporting(env);
#endif
- kvm_reset_mpstate(env);
return 0;
}
@@ -761,7 +746,6 @@ void kvm_arch_cpu_reset(CPUState *env)
{
kvm_reset_msrs(env);
kvm_arch_reset_vcpu(env);
- kvm_reset_mpstate(env);
}
#ifdef CONFIG_KVM_DEVICE_ASSIGNMENT
next reply other threads:[~2010-12-29 18:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-29 18:53 Jan Kiszka [this message]
2011-01-04 18:40 ` [PATCH] qemu-kvm: Drop redundant kvm_reset_mpstate Marcelo Tosatti
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=4D1B83B3.4060607@web.de \
--to=jan.kiszka@web.de \
--cc=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
/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.