]> www.infradead.org Git - users/jedix/linux-maple.git/commit
module: make waiting for a concurrent module loader interruptible
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 9 Aug 2024 15:33:28 +0000 (08:33 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 9 Aug 2024 15:33:28 +0000 (08:33 -0700)
commit2124d84db293ba164059077944e6b429ba530495
tree246b5fe724cdf0009f85fcb86bd03f2bffe14c1f
parentee9a43b7cfe2d8a3520335fea7d8ce71b8cabd9d
module: make waiting for a concurrent module loader interruptible

The recursive aes-arm-bs module load situation reported by Russell King
is getting fixed in the crypto layer, but this in the meantime fixes the
"recursive load hangs forever" by just making the waiting for the first
module load be interruptible.

This should now match the old behavior before commit 9b9879fc0327
("modules: catch concurrent module loads, treat them as idempotent"),
which used the different "wait for module to be ready" code in
module_patient_check_exists().

End result: a recursive module load will still block, but now a signal
will interrupt it and fail the second module load, at which point the
first module will successfully complete loading.

Fixes: 9b9879fc0327 ("modules: catch concurrent module loads, treat them as idempotent")
Cc: Russell King <linux@armlinux.org.uk>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
kernel/module/main.c