public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xen: suppress known wrmsrs
@ 2008-07-24 20:48 Jeremy Fitzhardinge
  2008-07-28 14:33 ` Ingo Molnar
  0 siblings, 1 reply; 2+ messages in thread
From: Jeremy Fitzhardinge @ 2008-07-24 20:48 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: Linux Kernel Mailing List

In general, Xen doesn't support wrmsr from an unprivileged domain; it
just ends up ignoring the instruction and printing a message on the
console.

Given that there are sets of MSRs we know the kernel will try to write
to, but we don't care, just eat them in xen_write_msr to cut down on
console noise.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
---
 arch/x86/xen/enlighten.c |   13 +++++++++++++
 1 file changed, 13 insertions(+)

===================================================================
--- a/arch/x86/xen/enlighten.c
+++ b/arch/x86/xen/enlighten.c
@@ -803,6 +803,19 @@
 			ret = -EFAULT;
 		break;
 #endif
+
+	case MSR_STAR:
+	case MSR_CSTAR:
+	case MSR_LSTAR:
+	case MSR_SYSCALL_MASK:
+	case MSR_IA32_SYSENTER_CS:
+	case MSR_IA32_SYSENTER_ESP:
+	case MSR_IA32_SYSENTER_EIP:
+		/* Fast syscall setup is all done in hypercalls, so
+		   these are all ignored.  Stub them out here to stop
+		   Xen console noise. */
+		break;
+
 	default:
 		ret = native_write_msr_safe(msr, low, high);
 	}



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] xen: suppress known wrmsrs
  2008-07-24 20:48 [PATCH] xen: suppress known wrmsrs Jeremy Fitzhardinge
@ 2008-07-28 14:33 ` Ingo Molnar
  0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2008-07-28 14:33 UTC (permalink / raw)
  To: Jeremy Fitzhardinge; +Cc: Linux Kernel Mailing List, the arch/x86 maintainers


* Jeremy Fitzhardinge <jeremy@goop.org> wrote:

> In general, Xen doesn't support wrmsr from an unprivileged domain; it 
> just ends up ignoring the instruction and printing a message on the 
> console.
>
> Given that there are sets of MSRs we know the kernel will try to write 
> to, but we don't care, just eat them in xen_write_msr to cut down on 
> console noise.
>
> Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>

applied to tip/x86/xen - thanks,

	Ingo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-07-28 14:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-24 20:48 [PATCH] xen: suppress known wrmsrs Jeremy Fitzhardinge
2008-07-28 14:33 ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox