diff options
author | H. Peter Anvin <hpa@zytor.com> | 2008-08-25 17:27:21 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2008-08-25 17:45:48 -0700 |
commit | c6f31932d0a1d2b13952f506ebc92675e2d8df80 (patch) | |
tree | f08e31afb69ca52e8ba8a1cca316b12bd7bec365 /include | |
parent | f73be6dedf4fa058ce80846dae604b08fa805ca1 (diff) | |
download | kernel_samsung_smdk4412-c6f31932d0a1d2b13952f506ebc92675e2d8df80.zip kernel_samsung_smdk4412-c6f31932d0a1d2b13952f506ebc92675e2d8df80.tar.gz kernel_samsung_smdk4412-c6f31932d0a1d2b13952f506ebc92675e2d8df80.tar.bz2 |
x86: msr: propagate errors from smp_call_function_single()
Propagate error (-ENXIO) from smp_call_function_single(). These
errors can happen when a CPU is unplugged while the MSR driver is
open.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-x86/msr.h | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/include/asm-x86/msr.h b/include/asm-x86/msr.h index ca110ee..ad5f2de 100644 --- a/include/asm-x86/msr.h +++ b/include/asm-x86/msr.h @@ -192,19 +192,20 @@ do { \ #define write_rdtscp_aux(val) wrmsr(0xc0000103, (val), 0) #ifdef CONFIG_SMP -void rdmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h); -void wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h); +int rdmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h); +int wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h); int rdmsr_safe_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h); - int wrmsr_safe_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h); #else /* CONFIG_SMP */ -static inline void rdmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h) +static inline int rdmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h) { rdmsr(msr_no, *l, *h); + return 0; } -static inline void wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h) +static inline int wrmsr_on_cpu(unsigned int cpu, u32 msr_no, u32 l, u32 h) { wrmsr(msr_no, l, h); + return 0; } static inline int rdmsr_safe_on_cpu(unsigned int cpu, u32 msr_no, u32 *l, u32 *h) |