From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eugene Korenevsky Subject: [PATCH] kvm-unit-tests: minor: remove unused variable Date: Fri, 12 Dec 2014 22:54:05 +0300 Message-ID: <20141212195405.GA12318@gnote> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Paolo Bonzini To: kvm@vger.kernel.org Return-path: Received: from mail-lb0-f174.google.com ([209.85.217.174]:51178 "EHLO mail-lb0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752179AbaLLTwh (ORCPT ); Fri, 12 Dec 2014 14:52:37 -0500 Received: by mail-lb0-f174.google.com with SMTP id 10so6398459lbg.5 for ; Fri, 12 Dec 2014 11:52:35 -0800 (PST) Content-Disposition: inline Sender: kvm-owner@vger.kernel.org List-ID: Remove unused variable to get rid of compiler warning. And remove commented out code (it can always be restored from git logs). Signed-off-by: Eugene Korenevsky --- x86/vmx_tests.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/x86/vmx_tests.c b/x86/vmx_tests.c index 184fafc..0daaacf 100644 --- a/x86/vmx_tests.c +++ b/x86/vmx_tests.c @@ -1439,12 +1439,10 @@ static int dbgctls_init(struct vmcs *vmcs) static void dbgctls_main(void) { - u64 dr7, debugctl; + u64 dr7; asm volatile("mov %%dr7,%0" : "=r" (dr7)); - debugctl = rdmsr(MSR_IA32_DEBUGCTLMSR); - /* Commented out: KVM does not support DEBUGCTL so far */ - report("Load debug controls", dr7 == 0x404 /* && debugctl == 0x2 */); + report("Load debug controls", dr7 == 0x404); dr7 = 0x408; asm volatile("mov %0,%%dr7" : : "r" (dr7)); @@ -1463,9 +1461,7 @@ static void dbgctls_main(void) vmcall(); asm volatile("mov %%dr7,%0" : "=r" (dr7)); - debugctl = rdmsr(MSR_IA32_DEBUGCTLMSR); - /* Commented out: KVM does not support DEBUGCTL so far */ - report("Guest=host debug controls", dr7 == 0x402 /* && debugctl == 0x1 */); + report("Guest=host debug controls", dr7 == 0x402); dr7 = 0x408; asm volatile("mov %0,%%dr7" : : "r" (dr7)); -- 2.0.4