aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/paravirt.c
diff options
context:
space:
mode:
authorBorislav Petkov <petkovbb@googlemail.com>2009-08-31 03:50:09 -0400
committerH. Peter Anvin <hpa@zytor.com>2009-08-31 18:14:26 -0400
commit132ec92f3f70fe365c1f4b8d46e66cf8a2a16880 (patch)
treef8e3f3ab5541f583030b0bcd5f3f81ca338f77a2 /arch/x86/kernel/paravirt.c
parent366d19e181be873c70f4aafca3931d77d781ccd7 (diff)
x86, msr: Add rd/wrmsr interfaces with preset registers
native_{rdmsr,wrmsr}_safe_regs are two new interfaces which allow presetting of a subset of eight x86 GPRs before executing the rd/wrmsr instructions. This is needed at least on AMD K8 for accessing an erratum workaround MSR. Originally based on an idea by H. Peter Anvin. Signed-off-by: Borislav Petkov <petkovbb@gmail.com> LKML-Reference: <1251705011-18636-1-git-send-email-petkovbb@gmail.com> Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'arch/x86/kernel/paravirt.c')
-rw-r--r--arch/x86/kernel/paravirt.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/paravirt.c b/arch/x86/kernel/paravirt.c
index 70ec9b951d76..67594af43b38 100644
--- a/arch/x86/kernel/paravirt.c
+++ b/arch/x86/kernel/paravirt.c
@@ -362,8 +362,10 @@ struct pv_cpu_ops pv_cpu_ops = {
362#endif 362#endif
363 .wbinvd = native_wbinvd, 363 .wbinvd = native_wbinvd,
364 .read_msr = native_read_msr_safe, 364 .read_msr = native_read_msr_safe,
365 .rdmsr_regs = native_rdmsr_safe_regs,
365 .read_msr_amd = native_read_msr_amd_safe, 366 .read_msr_amd = native_read_msr_amd_safe,
366 .write_msr = native_write_msr_safe, 367 .write_msr = native_write_msr_safe,
368 .wrmsr_regs = native_wrmsr_safe_regs,
367 .read_tsc = native_read_tsc, 369 .read_tsc = native_read_tsc,
368 .read_pmc = native_read_pmc, 370 .read_pmc = native_read_pmc,
369 .read_tscp = native_read_tscp, 371 .read_tscp = native_read_tscp,