android_kernel_motorola_sm6225/arch/xtensa/kernel
Eric W. Biederman 7d5de91a9a exit: Add and use make_task_dead.
commit 0e25498f8cd43c1b5aa327f373dd094e9a006da7 upstream.

There are two big uses of do_exit.  The first is it's design use to be
the guts of the exit(2) system call.  The second use is to terminate
a task after something catastrophic has happened like a NULL pointer
in kernel code.

Add a function make_task_dead that is initialy exactly the same as
do_exit to cover the cases where do_exit is called to handle
catastrophic failure.  In time this can probably be reduced to just a
light wrapper around do_task_dead. For now keep it exactly the same so
that there will be no behavioral differences introducing this new
concept.

Replace all of the uses of do_exit that use it for catastraphic
task cleanup with make_task_dead to make it clear what the code
is doing.

As part of this rename rewind_stack_do_exit
rewind_stack_and_make_dead.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-02-06 07:49:45 +01:00
..
.gitignore xtensa: tell git to ignore generated files 2013-06-05 10:14:19 -07:00
align.S xtensa: clean up word alignment macros in assembly code 2017-12-10 14:48:53 -08:00
asm-offsets.c xtensa: fix coprocessor context offset definitions 2018-12-05 19:32:05 +01:00
coprocessor.S xtensa: use call instead of callx in assembly code 2017-12-10 14:48:52 -08:00
entry.S Kbuild: rename CC_STACKPROTECTOR[_STRONG] config variables 2018-06-14 12:21:18 +09:00
head.S xtensa: SMP: fix secondary CPU initialization 2019-03-13 14:02:28 -07:00
hw_breakpoint.c perf/arch/xtensa: Implement hw_breakpoint_arch_parse() 2018-06-26 09:07:58 +02:00
irq.c xtensa: call irqchip_init only when CONFIG_USE_OF is selected 2021-10-13 10:10:51 +02:00
Makefile xtensa: build kernel with text-section-literals 2017-12-10 14:48:51 -08:00
mcount.S xtensa: add static function tracer support 2013-07-08 01:18:57 -07:00
module.c xtensa: clean up custom-controlled debug output 2017-12-16 22:37:08 -08:00
mxhead.S xtensa: drop unused sections and remapped reset handlers 2015-11-03 17:19:39 +03:00
pci-dma.c Xtensa improvements for v4.19: 2018-08-22 14:04:41 -07:00
pci.c xtensa/PCI: Use dev_printk() when possible 2018-05-22 07:56:17 -05:00
perf_event.c xtensa: fix xtensa_pmu_setup prototype 2020-08-21 11:05:31 +02:00
platform.c xtensa: cleanup ccount frequency tracking 2013-07-08 01:11:37 -07:00
process.c xtensa: fix get_wchan 2019-03-10 07:17:21 +01:00
ptrace.c ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP 2022-06-14 16:59:13 +02:00
s32c1i_selftest.c xtensa: move S32C1I self-test to a separate file 2016-11-16 15:08:28 -08:00
setup.c xtensa: use CONFIG_USE_OF instead of CONFIG_OF 2021-12-01 09:27:39 +01:00
signal.c ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP 2022-06-14 16:59:13 +02:00
smp.c xtensa: SMP: limit number of possible CPUs by NR_CPUS 2019-03-13 14:02:29 -07:00
stacktrace.c xtensa: fix return_address 2019-04-17 08:38:53 +02:00
syscall.c mm: add ksys_fadvise64_64() helper; remove in-kernel call to sys_fadvise64_64() 2018-04-02 20:16:10 +02:00
time.c xtensa: Fix refcount leak bug in time.c 2022-07-02 16:27:36 +02:00
traps.c exit: Add and use make_task_dead. 2023-02-06 07:49:45 +01:00
vectors.S xtensa: use call instead of callx in assembly code 2017-12-10 14:48:52 -08:00
vmlinux.lds.S xtensa: add NOTES section to the linker script 2018-11-21 09:19:16 +01:00
xtensa_ksyms.c xtensa: fix __sync_fetch_and_{and,or}_4 declarations 2020-07-29 10:16:45 +02:00