From patchwork Tue Jan 19 13:06:38 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 73858 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.2) with ESMTP id o0JD6ipS020112 for ; Tue, 19 Jan 2010 13:06:45 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751441Ab0ASNGn (ORCPT ); Tue, 19 Jan 2010 08:06:43 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751336Ab0ASNGm (ORCPT ); Tue, 19 Jan 2010 08:06:42 -0500 Received: from mx1.redhat.com ([209.132.183.28]:26355 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751323Ab0ASNGm (ORCPT ); Tue, 19 Jan 2010 08:06:42 -0500 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o0JD6dOU010628 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 19 Jan 2010 08:06:40 -0500 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by int-mx03.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o0JD6dLF011119; Tue, 19 Jan 2010 08:06:39 -0500 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id BCC8018D450; Tue, 19 Jan 2010 15:06:38 +0200 (IST) Date: Tue, 19 Jan 2010 15:06:38 +0200 From: Gleb Natapov To: Avi Kivity Cc: Jan Kiszka , mtosatti@redhat.com, kvm@vger.kernel.org Subject: Re: [PATCHv3 0/4] Add support for some HYPER-V PV features Message-ID: <20100119130638.GO14345@redhat.com> References: <1263736284-18780-1-git-send-email-gleb@redhat.com> <4B559A84.1040509@siemens.com> <20100119125024.GN14345@redhat.com> <4B55AB48.60900@redhat.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <4B55AB48.60900@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.16 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 47c6e23..a311751 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -3807,12 +3807,12 @@ int kvm_hv_hypercall(struct kvm_vcpu *vcpu) longmode = is_long_mode(vcpu) && cs_l == 1; if (!longmode) { - param = (kvm_register_read(vcpu, VCPU_REGS_RDX) << 32) | - (kvm_register_read(vcpu, VCPU_REGS_RAX) & 0xffffff); - ingpa = (kvm_register_read(vcpu, VCPU_REGS_RBX) << 32) | - (kvm_register_read(vcpu, VCPU_REGS_RCX) & 0xffffff); - outgpa = (kvm_register_read(vcpu, VCPU_REGS_RDI) << 32) | - (kvm_register_read(vcpu, VCPU_REGS_RSI) & 0xffffff); + 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 {