linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Sean Christopherson <seanjc@google.com>
Cc: Vitaly Kuznetsov <vkuznets@redhat.com>,
	Wanpeng Li <wanpengli@tencent.com>,
	Jim Mattson <jmattson@google.com>, Joerg Roedel <joro@8bytes.org>,
	kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
	Robert Hu <robert.hu@intel.com>,
	Farrah Chen <farrah.chen@intel.com>,
	Danmei Wei <danmei.wei@intel.com>,
	Tom Lendacky <Thomas.Lendacky@amd.com>
Subject: Re: [PATCH] KVM: SVM: Use 'unsigned long' for the physical address passed to VMSAVE
Date: Wed, 3 Feb 2021 09:03:50 +0100	[thread overview]
Message-ID: <cbd8894f-4218-26ca-f0ff-9513fe7b194f@redhat.com> (raw)
In-Reply-To: <20210202223416.2702336-1-seanjc@google.com>

On 02/02/21 23:34, Sean Christopherson wrote:
> diff --git a/arch/x86/kvm/svm/svm_ops.h b/arch/x86/kvm/svm/svm_ops.h
> index 0c8377aee52c..9f007bc8409a 100644
> --- a/arch/x86/kvm/svm/svm_ops.h
> +++ b/arch/x86/kvm/svm/svm_ops.h
> @@ -51,7 +51,12 @@ static inline void invlpga(unsigned long addr, u32 asid)
>  	svm_asm2(invlpga, "c"(asid), "a"(addr));
>  }
>  
> -static inline void vmsave(hpa_t pa)
> +/*
> + * Despite being a physical address, the portion of rAX that is consumed by
> + * VMSAVE, VMLOAD, etc... is still controlled by the effective address size,
> + * hence 'unsigned long' instead of 'hpa_t'.
> + */
> +static inline void vmsave(unsigned long pa)
>  {
>  	svm_asm1(vmsave, "a" (pa), "memory");
>  }
> -- 
> 2.30.0.365.g02bc693789-goog
> 

Squashed, thanks.

Paolo


      parent reply	other threads:[~2021-02-03  8:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-02 22:34 [PATCH] KVM: SVM: Use 'unsigned long' for the physical address passed to VMSAVE Sean Christopherson
2021-02-02 22:36 ` Sean Christopherson
2021-02-03  8:03 ` Paolo Bonzini [this message]

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=cbd8894f-4218-26ca-f0ff-9513fe7b194f@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=Thomas.Lendacky@amd.com \
    --cc=danmei.wei@intel.com \
    --cc=farrah.chen@intel.com \
    --cc=jmattson@google.com \
    --cc=joro@8bytes.org \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robert.hu@intel.com \
    --cc=seanjc@google.com \
    --cc=vkuznets@redhat.com \
    --cc=wanpengli@tencent.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).