mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-30 00:46:39 +07:00
5336377d62
With all the recent module loading cleanups, we've minimized the code that sits under module_mutex, fixing various deadlocks and making it possible to do most of the module loading in parallel. However, that whole conversion totally missed the rather obscure code that adds a new module to the list for BUG() handling. That code was doubly obscure because (a) the code itself lives in lib/bugs.c (for dubious reasons) and (b) it gets called from the architecture-specific "module_finalize()" rather than from generic code. Calling it from arch-specific code makes no sense what-so-ever to begin with, and is now actively wrong since that code isn't protected by the module loading lock any more. So this commit moves the "module_bug_{finalize,cleanup}()" calls away from the arch-specific code, and into the generic code - and in the process protects it with the module_mutex so that the list operations are now safe. Future fixups: - move the module list handling code into kernel/module.c where it belongs. - get rid of 'module_bug_list' and just use the regular list of modules (called 'modules' - imagine that) that we already create and maintain for other reasons. Reported-and-tested-by: Thomas Gleixner <tglx@linutronix.de> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Adrian Bunk <bunk@kernel.org> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: stable@kernel.org Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> |
||
---|---|---|
.. | ||
asm-offsets.c | ||
entry.S | ||
fpu-low.S | ||
fpu.c | ||
gdb-cache.S | ||
gdb-io-serial-low.S | ||
gdb-io-serial.c | ||
gdb-io-ttysm-low.S | ||
gdb-io-ttysm.c | ||
gdb-low.S | ||
gdb-stub.c | ||
head.S | ||
init_task.c | ||
internal.h | ||
io.c | ||
irq.c | ||
kernel_execve.S | ||
kprobes.c | ||
kthread.S | ||
Makefile | ||
mn10300_ksyms.c | ||
mn10300-debug.c | ||
mn10300-serial-low.S | ||
mn10300-serial.c | ||
mn10300-serial.h | ||
mn10300-watchdog-low.S | ||
mn10300-watchdog.c | ||
module.c | ||
process.c | ||
profile-low.S | ||
profile.c | ||
ptrace.c | ||
rtc.c | ||
setup.c | ||
sigframe.h | ||
signal.c | ||
switch_to.S | ||
sys_mn10300.c | ||
time.c | ||
traps.c | ||
vmlinux.lds.S |