From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: xen-devel@lists.xensource.com, Ian.Jackson@eu.citrix.com,
stefano.stabellini@eu.citrix.com, Ian.Campbell@citrix.com
Cc: konrad.wilk@oracle.com
Subject: [PATCH 1 of 2] traps: AMD PM RDMSRs (MSR_K8_PSTATE_CTRL, etc)
Date: Fri, 24 Feb 2012 01:43:53 -0500 [thread overview]
Message-ID: <a34b652afb0ca484b741.1330065833@phenom.dumpdata.com> (raw)
In-Reply-To: <patchbomb.1330065832@phenom.dumpdata.com>
# HG changeset patch
# User Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
# Date 1330065828 18000
# Node ID a34b652afb0ca484b7416008c95fd36ffbbea334
# Parent a4d93d0e0df2fafe5b3e2dab3e34799498a875e2
traps: AMD PM RDMSRs (MSR_K8_PSTATE_CTRL, etc)
The restriction to read and write the AMD power management MSRs is gated if the
domain 0 is the PM domain (so FREQCTL_dom0_kernel is set). But we can
relax this restriction and allow the privileged domain to read the MSRs
(but not write). This allows the priviliged domain to harvest the power
management information (ACPI _PSS states) and send it to the hypervisor.
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
diff -r a4d93d0e0df2 -r a34b652afb0c xen/arch/x86/traps.c
--- a/xen/arch/x86/traps.c Wed Feb 22 14:33:24 2012 +0000
+++ b/xen/arch/x86/traps.c Fri Feb 24 01:43:48 2012 -0500
@@ -2610,7 +2610,7 @@ static int emulate_privileged_op(struct
case MSR_K8_PSTATE7:
if ( boot_cpu_data.x86_vendor != X86_VENDOR_AMD )
goto fail;
- if ( !is_cpufreq_controller(v->domain) )
+ if ( !is_cpufreq_controller(v->domain) && !IS_PRIV(v->domain) )
{
regs->eax = regs->edx = 0;
break;
next prev parent reply other threads:[~2012-02-24 6:43 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-24 6:43 [PATCH 0 of 2] [RFC] Patches to work with processor-passthru driver (v1) Konrad Rzeszutek Wilk
2012-02-24 6:43 ` Konrad Rzeszutek Wilk [this message]
2012-02-24 10:38 ` [PATCH 1 of 2] traps: AMD PM RDMSRs (MSR_K8_PSTATE_CTRL, etc) Jan Beulich
2012-03-01 16:33 ` Keir Fraser
2012-03-12 18:11 ` Konrad Rzeszutek Wilk
2012-02-24 6:43 ` [PATCH 2 of 2] linux-xencommons: Load processor-passthru Konrad Rzeszutek Wilk
2012-02-24 10:44 ` Jan Beulich
2012-02-27 1:46 ` Konrad Rzeszutek Wilk
2012-02-27 8:31 ` Jan Beulich
2012-03-05 2:49 ` Konrad Rzeszutek Wilk
2012-03-05 11:43 ` Jan Beulich
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=a34b652afb0ca484b741.1330065833@phenom.dumpdata.com \
--to=konrad.wilk@oracle.com \
--cc=Ian.Campbell@citrix.com \
--cc=Ian.Jackson@eu.citrix.com \
--cc=stefano.stabellini@eu.citrix.com \
--cc=xen-devel@lists.xensource.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 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.