1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-17 10:26:15 +00:00

Ignore writes to microcode update MSR. This MSR is accessed by RHEL7 guest.

Add KTR tracepoints to annotate wrmsr and rdmsr VM exits.
This commit is contained in:
Neel Natu 2014-04-30 02:08:27 +00:00
parent 91e198f6a2
commit 2cb97c9dd6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=265114
2 changed files with 5 additions and 0 deletions

View File

@ -1797,6 +1797,7 @@ vmx_exit_process(struct vmx *vmx, int vcpu, struct vm_exit *vmexit)
vmm_stat_incr(vmx->vm, vcpu, VMEXIT_RDMSR, 1);
retu = false;
ecx = vmxctx->guest_rcx;
VCPU_CTR1(vmx->vm, vcpu, "rdmsr 0x%08x", ecx);
error = emulate_rdmsr(vmx->vm, vcpu, ecx, &retu);
if (error) {
vmexit->exitcode = VM_EXITCODE_RDMSR;
@ -1815,6 +1816,8 @@ vmx_exit_process(struct vmx *vmx, int vcpu, struct vm_exit *vmexit)
eax = vmxctx->guest_rax;
ecx = vmxctx->guest_rcx;
edx = vmxctx->guest_rdx;
VCPU_CTR2(vmx->vm, vcpu, "wrmsr 0x%08x value 0x%016lx",
ecx, (uint64_t)edx << 32 | eax);
error = emulate_wrmsr(vmx->vm, vcpu, ecx,
(uint64_t)edx << 32 | eax, &retu);
if (error) {

View File

@ -47,6 +47,8 @@ emulate_wrmsr(struct vmctx *ctx, int vcpu, uint32_t code, uint64_t val)
case 0xd04: /* Sandy Bridge uncore PMC MSRs */
case 0xc24:
return (0);
case 0x79:
return (0); /* IA32_BIOS_UPDT_TRIG MSR */
default:
break;
}