linux_dsm_epyc7002/arch/hexagon/include/asm
Andy Lutomirski f56141e3e2 all arches, signal: move restart_block to struct task_struct
If an attacker can cause a controlled kernel stack overflow, overwriting
the restart block is a very juicy exploit target.  This is because the
restart_block is held in the same memory allocation as the kernel stack.

Moving the restart block to struct task_struct prevents this exploit by
making the restart_block harder to locate.

Note that there are other fields in thread_info that are also easy
targets, at least on some architectures.

It's also a decent simplification, since the restart code is more or less
identical on all architectures.

[james.hogan@imgtec.com: metag: align thread_info::supervisor_stack]
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Kees Cook <keescook@chromium.org>
Cc: David Miller <davem@davemloft.net>
Acked-by: Richard Weinberger <richard@nod.at>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Matt Turner <mattst88@gmail.com>
Cc: Vineet Gupta <vgupta@synopsys.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
Cc: Steven Miao <realmz6@gmail.com>
Cc: Mark Salter <msalter@redhat.com>
Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
Cc: Mikael Starvik <starvik@axis.com>
Cc: Jesper Nilsson <jesper.nilsson@axis.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Richard Kuo <rkuo@codeaurora.org>
Cc: "Luck, Tony" <tony.luck@intel.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Michal Simek <monstr@monstr.eu>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Jonas Bonn <jonas@southpole.se>
Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
Cc: Helge Deller <deller@gmx.de>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Acked-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc)
Tested-by: Michael Ellerman <mpe@ellerman.id.au> (powerpc)
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Chen Liqin <liqin.linux@gmail.com>
Cc: Lennox Wu <lennox.wu@gmail.com>
Cc: Chris Metcalf <cmetcalf@ezchip.com>
Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
Cc: Chris Zankel <chris@zankel.net>
Cc: Max Filippov <jcmvbkbc@gmail.com>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2015-02-12 18:54:12 -08:00
..
asm-offsets.h Hexagon: Add processor and system headers 2011-11-01 07:34:18 -07:00
atomic.h locking,arch,hexagon: Fold atomic_ops 2014-08-14 12:48:06 +02:00
bitops.h arch,hexagon: Convert smp_mb__*() 2014-04-18 14:20:35 +02:00
cache.h Hexagon: set ARCH_DMA_MINALIGN 2014-12-16 13:27:30 -06:00
cacheflush.h hexagon: Fix build failures in linux-next 2014-12-16 13:27:12 -06:00
checksum.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
cmpxchg.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
delay.h arch: hexagon: kernel: add export symbol function __delay() 2014-04-04 18:19:59 -05:00
dma-mapping.h arch: hexagon: Kconfig: add HAVE_DMA_ATTR in Kconfig and remove "linux/dma-mapping.h" from "asm/dma-mapping.h" 2014-04-04 18:19:59 -05:00
dma.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
elf.h Hexagon: update CR year for elf.h 2014-04-04 18:20:02 -05:00
exec.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
fixmap.h hexagon: use generic fixmap.h 2014-01-23 16:36:54 -08:00
fpu.h Hexagon: Core arch-specific header files 2011-11-01 07:34:18 -07:00
futex.h Hexagon: Core arch-specific header files 2011-11-01 07:34:18 -07:00
hexagon_vm.h arch: hexagon: include: asm: add prefix "hvm[ci]_" for all enum members in "hexagon_vm.h" 2014-04-04 18:20:00 -05:00
intrinsics.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
io.h hexagon: Fix build failures in linux-next 2014-12-16 13:27:12 -06:00
irq.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
irqflags.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
Kbuild net, lib: kill arch_fast_hash library bits 2014-12-10 15:17:46 -05:00
kgdb.h hexagon: include: asm: kgdb: extend DBG_MAX_REG_NUM for "cs0/1" 2014-04-04 18:19:59 -05:00
linkage.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
mem-layout.h Hexagon: use correct translation for VMALLOC_START 2013-04-30 19:40:29 -05:00
mmu_context.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
mmu.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
module.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
mutex.h Hexagon: Add generic headers 2011-11-01 07:34:18 -07:00
page.h Hexagon: use correct translations for DMA mappings 2013-04-30 19:40:28 -05:00
perf_event.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
pgalloc.h hexagon: correct type on pgd copy 2014-04-04 18:20:01 -05:00
pgtable.h mm: make FIRST_USER_ADDRESS unsigned long on all archs 2015-02-11 17:06:03 -08:00
processor.h arch, locking: Ciao arch_mutex_cpu_relax() 2014-07-17 12:32:47 +02:00
smp.h smp, hexagon: kill SMP single function call interrupt 2014-04-04 18:20:01 -05:00
spinlock_types.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
spinlock.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
string.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
suspend.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
switch_to.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
syscall.h take sys_fork/sys_vfork/sys_clone prototypes to linux/syscalls.h 2012-11-28 23:43:27 -05:00
thread_info.h all arches, signal: move restart_block to struct task_struct 2015-02-12 18:54:12 -08:00
time.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
timer-regs.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
timex.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
tlb.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
tlbflush.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
traps.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
uaccess.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
vdso.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
vm_fault.h Hexagon: Copyright marking changes 2012-10-18 17:07:21 -05:00
vm_mmu.h Hexagon: update copyright dates 2013-04-30 19:40:27 -05:00