linux-stable/arch
Peter Zijlstra 90812dd1f7 x86/extable: Fix ex_handler_msr() print condition
[ Upstream commit a1a5482a2c ]

On Fri, Jun 17, 2022 at 02:08:52PM +0300, Stephane Eranian wrote:
> Some changes to the way invalid MSR accesses are reported by the
> kernel is causing some problems with messages printed on the
> console.
>
> We have seen several cases of ex_handler_msr() printing invalid MSR
> accesses once but the callstack multiple times causing confusion on
> the console.

> The problem here is that another earlier commit (5.13):
>
> a358f40600 ("once: implement DO_ONCE_LITE for non-fast-path "do once" functionality")
>
> Modifies all the pr_*_once() calls to always return true claiming
> that no caller is ever checking the return value of the functions.
>
> This is why we are seeing the callstack printed without the
> associated printk() msg.

Extract the ONCE_IF(cond) part into __ONCE_LTE_IF() and use that to
implement DO_ONCE_LITE_IF() and fix the extable code.

Fixes: a358f40600 ("once: implement DO_ONCE_LITE for non-fast-path "do once" functionality")
Reported-by: Stephane Eranian <eranian@google.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Tested-by: Stephane Eranian <eranian@google.com>
Link: https://lkml.kernel.org/r/YqyVFsbviKjVGGZ9@worktop.programming.kicks-ass.net
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-08-17 15:14:20 +02:00
..
alpha Cleanups (and one fix) around struct mount handling. 2022-06-04 19:00:05 -07:00
arc This set of changes updates init and user mode helper tasks to be 2022-06-03 16:03:05 -07:00
arm ARM: dts: qcom: msm8974: Disable remoteprocs by default 2022-08-17 15:14:19 +02:00
arm64 arm64: dts: qcom: qcs404: Fix incorrect USB2 PHYs assignment 2022-08-17 15:14:19 +02:00
csky csky/tlb: Remove tlb_flush() define 2022-07-21 10:50:13 -07:00
hexagon
ia64 ia64, processor: fix -Wincompatible-pointer-types in ia64_get_irr() 2022-08-17 15:13:56 +02:00
loongarch LoongArch: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK 2022-08-17 15:13:46 +02:00
m68k m68k: virt: Fix missing platform_device_unregister() on error in virt_platform_init() 2022-08-17 15:14:15 +02:00
microblaze This set of changes updates init and user mode helper tasks to be 2022-06-03 16:03:05 -07:00
mips MIPS: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK 2022-08-17 15:13:57 +02:00
nios2 This set of changes updates init and user mode helper tasks to be 2022-06-03 16:03:05 -07:00
openrisc openrisc: unwinder: Fix grammar issue in comment 2022-06-28 17:31:24 +09:00
parisc parisc: io_pgetevents_time64() needs compat syscall in 32-bit compat mode 2022-08-17 15:13:48 +02:00
powerpc powerpc/powernv: Avoid crashing if rng is NULL 2022-08-17 15:13:57 +02:00
riscv RISC-V: Add modules to virtual kernel memory layout dump 2022-08-17 15:13:50 +02:00
s390 KVM: s390: pv: don't present the ecall interrupt twice 2022-08-17 15:13:43 +02:00
sh sh: convert nommu io{re,un}map() to static inline functions 2022-07-03 15:42:32 -07:00
sparc mmu_gather: Remove per arch tlb_{start,end}_vma() 2022-07-21 10:50:13 -07:00
um um: seed rng using host OS rng 2022-08-17 15:13:53 +02:00
x86 x86/extable: Fix ex_handler_msr() print condition 2022-08-17 15:14:20 +02:00
xtensa xtensa: change '.bss' to '.section .bss' 2022-06-20 02:50:34 -07:00
.gitignore
Kconfig arch: make TRACE_IRQFLAGS_NMI_SUPPORT generic 2022-08-17 15:13:59 +02:00