diff options
author | Ganesh Goudar <ganeshgr@linux.ibm.com> | 2022-01-20 17:49:31 +0530 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2022-03-08 00:05:00 +1100 |
commit | cc15ff3275694fedc33cd3d53212a43eec7aa0bc (patch) | |
tree | dc15adec5a7491d5c1d6405e63169188942d45a8 /arch/powerpc/kernel/time.c | |
parent | 0a182611d149b5b747014fbb230ec35b20a45c86 (diff) |
powerpc/mce: Avoid using irq_work_queue() in realmode
In realmode mce handler we use irq_work_queue() to defer
the processing of mce events, irq_work_queue() can only
be called when translation is enabled because it touches
memory outside RMA, hence we enable translation before
calling irq_work_queue and disable on return, though it
is not safe to do in realmode.
To avoid this, program the decrementer and call the event
processing functions from timer handler.
Signed-off-by: Ganesh Goudar <ganeshgr@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220120121931.517974-1-ganeshgr@linux.ibm.com
Diffstat (limited to 'arch/powerpc/kernel/time.c')
-rw-r--r-- | arch/powerpc/kernel/time.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/time.c b/arch/powerpc/kernel/time.c index cd0b8b71ecdd..17598bba54eb 100644 --- a/arch/powerpc/kernel/time.c +++ b/arch/powerpc/kernel/time.c @@ -70,6 +70,7 @@ #include <asm/vdso_datapage.h> #include <asm/firmware.h> #include <asm/asm-prototypes.h> +#include <asm/mce.h> /* powerpc clocksource/clockevent code */ @@ -638,6 +639,7 @@ DEFINE_INTERRUPT_HANDLER_ASYNC(timer_interrupt) if (test_irq_work_pending()) { clear_irq_work_pending(); + mce_run_irq_context_handlers(); irq_work_run(); } |