compile and runtime tested

Signed-off-by: Toralf Förster <[email protected]>
---
 arch/x86/kvm/x86.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 8b8fc0b..a6ca7e0 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -5680,15 +5680,17 @@ int kvm_hv_hypercall(struct kvm_vcpu *vcpu)
        kvm_x86_ops->get_cs_db_l_bits(vcpu, &cs_db, &cs_l);
        longmode = is_long_mode(vcpu) && cs_l == 1;
 
+#ifdef CONFIG_X86_64
        if (!longmode) {
+#endif
                param = ((u64)kvm_register_read(vcpu, VCPU_REGS_RDX) << 32) |
                        (kvm_register_read(vcpu, VCPU_REGS_RAX) & 0xffffffff);
                ingpa = ((u64)kvm_register_read(vcpu, VCPU_REGS_RBX) << 32) |
                        (kvm_register_read(vcpu, VCPU_REGS_RCX) & 0xffffffff);
                outgpa = ((u64)kvm_register_read(vcpu, VCPU_REGS_RDI) << 32) |
                        (kvm_register_read(vcpu, VCPU_REGS_RSI) & 0xffffffff);
-       }
 #ifdef CONFIG_X86_64
+       }
        else {
                param = kvm_register_read(vcpu, VCPU_REGS_RCX);
                ingpa = kvm_register_read(vcpu, VCPU_REGS_RDX);
-- 
1.9.2

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to