All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86/msr: further correct the emulation behaviour of MSR_PRED_CMD
@ 2018-04-17 11:41 Jan Beulich
  2018-04-17 12:30 ` Andrew Cooper
  0 siblings, 1 reply; 5+ messages in thread
From: Jan Beulich @ 2018-04-17 11:41 UTC (permalink / raw)
  To: xen-devel; +Cc: Juergen Gross, Andrew Cooper

Following commit a6aa678fa3 ("x86/msr: Correct the emulation behaviour
of MSR_PRED_CMD") we may end up writing the low bit with the wrong
value. While it's unlikely for a guest to want to write zero there, we
should still permit (this without incurring the overhead of an actual
barrier). Correcting this right away will also help whenever further
bits in the MSR might become defined.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/xen/arch/x86/msr.c
+++ b/xen/arch/x86/msr.c
@@ -247,7 +247,7 @@ int guest_wrmsr(struct vcpu *v, uint32_t
             goto gp_fault; /* Rsvd bit set? */
 
         if ( v == curr )
-            wrmsrl(MSR_PRED_CMD, PRED_CMD_IBPB);
+            wrmsrl(MSR_PRED_CMD, val);
         break;
 
     case MSR_INTEL_MISC_FEATURES_ENABLES:



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

^ permalink raw reply	[flat|nested] 5+ messages in thread
[parent not found: <5AD5DD8202000078001BC0B7@suse.com>]

end of thread, other threads:[~2018-04-17 14:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-17 11:41 [PATCH] x86/msr: further correct the emulation behaviour of MSR_PRED_CMD Jan Beulich
2018-04-17 12:30 ` Andrew Cooper
2018-04-17 12:45   ` Jan Beulich
2018-04-17 14:58     ` Andrew Cooper
     [not found] <5AD5DD8202000078001BC0B7@suse.com>
2018-04-17 14:28 ` Juergen Gross

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.