]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
x86/msr: Add rdmsrl_on_cpu() compatibility wrapper
authorIngo Molnar <mingo@kernel.org>
Thu, 15 May 2025 15:49:16 +0000 (17:49 +0200)
committerIngo Molnar <mingo@kernel.org>
Thu, 15 May 2025 15:58:55 +0000 (17:58 +0200)
Add a simple rdmsrl_on_cpu() compatibility wrapper for
rdmsrq_on_cpu(), to make life in -next easier, where
the PM tree recently grew more uses of the old API.

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Acked-by: Mario Limonciello <mario.limonciello@amd.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Juergen Gross <jgross@suse.com>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Xin Li <xin@zytor.com>
Link: https://lore.kernel.org/r/20250512145517.6e0666e3@canb.auug.org.au
arch/x86/include/asm/msr.h

index a9ce56fc8785aa2f72f600d850a87f7bc1d0d5d4..4096b8af4ba76bcf97df533e9c6db5f8645f7840 100644 (file)
@@ -329,6 +329,7 @@ static inline int wrmsr_safe_regs_on_cpu(unsigned int cpu, u32 regs[8])
 /* Compatibility wrappers: */
 #define rdmsrl(msr, val) rdmsrq(msr, val)
 #define wrmsrl(msr, val) wrmsrq(msr, val)
+#define rdmsrl_on_cpu(cpu, msr, q) rdmsrq_on_cpu(cpu, msr, q)
 
 #endif /* __ASSEMBLER__ */
 #endif /* _ASM_X86_MSR_H */