linux/arch/arc/kernel
Vineet Gupta 8aa9e85ada ARC: !PREEMPT: Ensure Return to kernel mode is IRQ safe
There was a very small race window where resume to kernel mode from a
Exception Path (or pure kernel mode which is true for most of ARC
exceptions anyways), was not disabling interrupts in restore_regs,
clobbering the exception regs

Anton found the culprit call flow (after many sleepless nights)

| 1. we got a Trap from user land
| 2. started to service it.
| 3. While doing some stuff on user-land memory (I think it is padzero()),
|     we got a DataTlbMiss
| 4. On return from it we are taking "resume_kernel_mode" path
| 5. NEED_RESHED is not set, so we go to "return from exception" path in
|     restore regs.
| 6. there seems to be IRQ happening

Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Cc: <stable@vger.kernel.org>   #3.10, 3.12, 3.13, 3.14
Cc: Anton Kolesov <Anton.Kolesov@synopsys.com>
Cc: Francois Bedard <Francois.Bedard@synopsys.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2014-04-30 08:21:43 -07:00
..
.gitignore ARC: Add some .gitignore entries 2013-08-26 09:40:24 +05:30
arc_hostlink.c ARC: Hostlink Pseudo-Driver for Metaware Debugger 2013-02-15 23:16:10 +05:30
arcksyms.c ARC: Build system: Makefiles, Kconfig, Linker script 2013-02-11 20:00:25 +05:30
asm-offsets.c ARC: pt_regs update #5: Use real ECR for pt_regs->event vs. synth values 2013-06-26 14:04:48 +05:30
clk.c ARC: fix typo with clock speed 2013-05-07 13:43:54 +05:30
ctx_sw_asm.S ARC: switch to generic ENTRY/END assembler annotations 2014-03-26 14:31:28 +05:30
ctx_sw.c ARC: [SMP] Fix build failures for large NR_CPUS 2013-11-06 10:41:46 +05:30
devtree.c arc: remove unnecessary prom.h includes 2013-10-09 20:04:01 -05:00
disasm.c ARC port updates for Linux 3.10 (part 1) 2013-05-09 14:36:27 -07:00
entry.S ARC: !PREEMPT: Ensure Return to kernel mode is IRQ safe 2014-04-30 08:21:43 -07:00
fpu.c ARC: Process-creation/scheduling/idle-loop 2013-02-11 20:00:38 +05:30
head.S ARC: [SMP] General Fixes 2014-04-05 14:46:42 +05:30
irq.c arc: remove '__init' for get_hw_config_num_irq() 2013-11-06 10:41:43 +05:30
kgdb.c arc: kgdb: add default implementation for kgdb_roundup_cpus() 2013-11-06 10:41:41 +05:30
kprobes.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2013-11-15 16:47:22 -08:00
Makefile ARC: Add perf support for ARC700 cores 2013-11-12 09:45:38 +05:30
module.c ARC: Fix coding style issues 2013-04-09 12:21:14 +05:30
perf_event.c ARC: [perf] Fix a few thinkos 2013-11-28 15:49:59 +05:30
process.c ARC: pt_regs update #5: Use real ECR for pt_regs->event vs. synth values 2013-06-26 14:04:48 +05:30
ptrace.c ARC: Ignore ptrace SETREGSET request for synthetic register "stop_pc" 2013-10-12 12:00:36 +05:30
reset.c arc: export symbol for pm_power_off in reset.c 2013-11-06 10:41:44 +05:30
setup.c ARC: [cmdline] support External Device Trees from u-boot 2014-01-16 18:53:16 +05:30
signal.c ARC: Fix signal frame management for SA_SIGINFO 2013-10-03 09:43:56 +05:30
smp.c ARC: [SMP] optimize IPI send and receive 2013-12-23 12:05:04 +05:30
stacktrace.c arc: export symbol for save_stack_trace() in stacktrace.c 2013-11-06 10:41:44 +05:30
sys.c ARC: ABIv3: fork/vfork wrappers not needed in "no-legacy-syscall" ABI 2013-03-11 19:01:10 +05:30
time.c ARC: [clockevent] simplify timer ISR 2014-03-26 14:31:30 +05:30
traps.c ARC: Reduce #ifdef'ery for unaligned access emulation 2013-11-06 10:41:39 +05:30
troubleshoot.c ARC changes for 3.11 2013-07-03 11:09:27 -07:00
unaligned.c ARC: Handle zero-overhead-loop in unaligned access handler 2013-09-27 16:28:23 +05:30
unwind.c ARC: warn on improper stack unwind FDE entries 2013-06-27 14:37:59 +05:30
vmlinux.lds.S ARC: Adjustments for gcc 4.8 2013-06-27 14:35:32 +05:30