From e0ba72e3a4422c4255fa80191a637d7c65ef4c59 Mon Sep 17 00:00:00 2001 From: "J. R. Okajima" Date: Tue, 23 Jul 2024 16:40:17 +0000 Subject: [PATCH] lockdep: upper limit LOCKDEP_CHAINS_BITS CONFIG_LOCKDEP_CHAINS_BITS value decides the size of chain_hlocks[] in kernel/locking/lockdep.c, and it is checked by add_chain_cache() with BUILD_BUG_ON((1UL << 24) <= ARRAY_SIZE(chain_hlocks)); This patch is just to silence BUILD_BUG_ON(). See also https://lore.kernel.org/all/30795.1620913191@jrobl/ [cmllamas@google.com: fix minor checkpatch issues in commit log] Link: https://lkml.kernel.org/r/20240723164018.2489615-1-cmllamas@google.com Signed-off-by: J. R. Okajima Signed-off-by: Carlos Llamas Acked-by: Tetsuo Handa Cc: Peter Zijlstra Cc: Boqun Feng Cc: Ingo Molnar Cc: Waiman Long Cc: Will Deacon Signed-off-by: Andrew Morton --- lib/Kconfig.debug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index bf0995d328b3..a81d452941ce 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -1515,7 +1515,7 @@ config LOCKDEP_BITS config LOCKDEP_CHAINS_BITS int "Bitsize for MAX_LOCKDEP_CHAINS" depends on LOCKDEP && !LOCKDEP_SMALL - range 10 30 + range 10 21 default 16 help Try increasing this value if you hit "BUG: MAX_LOCKDEP_CHAINS too low!" message.