From: Paolo Bonzini <pbonzini@redhat.com>
To: Wanpeng Li <kernellwp@gmail.com>, Nadav Amit <nadav.amit@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>, kvm <kvm@vger.kernel.org>,
"Radim Krčmář" <rkrcmar@redhat.com>,
"Liran Alon" <liran.alon@oracle.com>
Subject: Re: [PATCH v3] KVM: X86: Allow userspace to define the microcode version
Date: Tue, 27 Feb 2018 09:36:48 +0100 [thread overview]
Message-ID: <2592816c-80d1-9172-47b4-78613215dc26@redhat.com> (raw)
In-Reply-To: <CANRm+CwC-Zk4Uq7pYjD9vBW_J9EL0hntFCMtd5sUuYn=ztMRXg@mail.gmail.com>
On 27/02/2018 03:22, Wanpeng Li wrote:
>>> @@ -2551,7 +2561,7 @@ int kvm_get_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
>>> msr_info->data = 0;
>>> break;
>>> case MSR_IA32_UCODE_REV:
>>> - msr_info->data = 0x100000000ULL;
>>> + msr_info->data = (u64)vcpu->arch.microcode_version;
>> I think that the shifts are missing here (the version should be on the high
>> bits according to intel_get_microcode_revision() ).
> You are right, it seems that we all miss it before.
It's not that the shift are missing. It's that microcode_version should
be u64 and initialized to 0x100000000ULL. Sorry I was too concise in my
review of v2, and made that implicit.
(Boris noticed offlist that AMD places the revision is in bit 0-31).
Thanks,
Paolo
prev parent reply other threads:[~2018-02-27 8:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-27 1:18 [PATCH v3] KVM: X86: Allow userspace to define the microcode version Wanpeng Li
2018-02-27 1:30 ` Nadav Amit
2018-02-27 2:22 ` Wanpeng Li
2018-02-27 2:27 ` Nadav Amit
2018-02-27 8:36 ` 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=2592816c-80d1-9172-47b4-78613215dc26@redhat.com \
--to=pbonzini@redhat.com \
--cc=kernellwp@gmail.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=liran.alon@oracle.com \
--cc=nadav.amit@gmail.com \
--cc=rkrcmar@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 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).