Also add support for the immediate form MSR read support.
Suggested-by: H. Peter Anvin (Intel)
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/msr.h| 274 --
arch/x86/include/asm/paravirt.h | 40
arch/x86/include/asm/paravirt_types.h | 9
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/msr.h | 18 ++
1 file changed, 2 insertions(+), 16 deletions(-)
diff --git a/arch/x86/include/asm/msr.h b/arch/x86/include/asm/msr.h
index 121597fc5d41..da4f2f6d127f 100644
--- a/arch/x86/include/asm/msr.h
+++ b/arch/x86
Also add support for the immediate form MSR write support.
Originally-by: H. Peter Anvin (Intel)
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/fred.h | 2 +-
arch/x86/include/asm/msr.h| 340 ++
arch/x86/include/asm/paravirt.h | 22
Signed-off-by: Xin Li (Intel)
---
arch/x86/hyperv/hv_apic.c | 6 +++---
arch/x86/include/asm/apic.h | 2 +-
arch/x86/include/asm/switch_to.h | 2 +-
arch/x86/kernel/cpu/amd.c | 2 +-
arch/x86/kernel/cpu/common.c | 8
Now pmu_msr_{read,write}() just do pmu_msr_chk_emulated(), so remove
them and call pmu_msr_chk_emulated() directly.
Suggested-by: H. Peter Anvin (Intel)
Signed-off-by: Xin Li (Intel)
---
arch/x86/xen/enlighten_pv.c | 17 ++---
arch/x86/xen/pmu.c | 24
alternatives pattern, possibly invoking a
different exception handling pattern there, or at least indicating the
"real" location of the fault.
Signed-off-by: H. Peter Anvin (Intel)
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/asm.h | 6 +
arch/x86/include/a
EX_TYPE_FUNC_REWIND
Xin Li (Intel) (14):
x86/msr: Replace __wrmsr() with native_wrmsrl()
x86/msr: Replace __rdmsr() with native_rdmsrl()
x86/msr: Simplify pmu_msr_{read,write}()
x86/msr: Let pv_cpu_ops.write_msr{_safe}() take an u64 instead of two
u32
x86/msr: Replace wrmsr(msr, low, 0
Refactor pv_cpu_ops.write_msr{_safe}() to take the input MSR value
in a single u64 argument, replacing the current dual u32 arguments.
No functional change intended.
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/msr.h| 33 ---
arch/x86/include/asm
__wrmsr() is the lowest level primitive MSR write API, and its direct
use is NOT preferred. Use its wrapper function native_wrmsrl() instead.
No functional change intended.
Signed-off-by: Xin Li (Intel)
---
arch/x86/events/amd/brs.c | 2 +-
arch/x86/include/asm/apic.h
Signed-off-by: Xin Li (Intel)
---
arch/x86/mm/extable.c | 59 ++-
1 file changed, 41 insertions(+), 18 deletions(-)
diff --git a/arch/x86/mm/extable.c b/arch/x86/mm/extable.c
index eb9331240a88..56138c0762b7 100644
--- a/arch/x86/mm/extable.c
+++ b/arch
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/msr-index.h | 6 ++
arch/x86/kvm/vmx/vmenter.S | 28
2 files changed, 30 insertions(+), 4 deletions(-)
diff --git a/arch/x86/include/asm/msr-index.h b/arch/x86/include/asm/msr-index.h
index
feature bit for MSR immediate form instructions.
Suggested-by: Borislav Petkov
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/cpufeatures.h | 19 ++-
arch/x86/kernel/cpu/scattered.c| 1 +
2 files changed, 11 insertions(+), 9 deletions(-)
diff --git a/arch/x86/include
)
Sign-off-by: Xin Li (Intel)
---
arch/x86/xen/enlighten_pv.c | 6 +-
arch/x86/xen/pmu.c | 27 ---
arch/x86/xen/xen-ops.h | 4 ++--
3 files changed, 11 insertions(+), 26 deletions(-)
diff --git a/arch/x86/xen/enlighten_pv.c b/arch/x86/xen/enlighten_pv.c
__rdmsr() is the lowest level primitive MSR read API, and its direct
use is NOT preferred. Use its wrapper function native_rdmsrl() instead.
No functional change intended.
Signed-off-by: Xin Li (Intel)
---
arch/x86/coco/sev/core.c | 2 +-
arch/x86/events/amd/brs.c
Add the instruction opcodes used by the immediate form WRMSRNS/RDMSR
to x86-opcode-map.
Signed-off-by: Xin Li (Intel)
---
arch/x86/lib/x86-opcode-map.txt | 5 +++--
tools/arch/x86/lib/x86-opcode-map.txt | 5 +++--
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/arch/x86/lib
Since the ARGS macros are no longer used in the MSR read/write API
implementation, move them after their definitions.
Signed-off-by: Xin Li (Intel)
---
arch/x86/include/asm/msr.h | 34 +-
1 file changed, 17 insertions(+), 17 deletions(-)
diff --git a/arch/x86
16 matches
Mail list logo