ANDROID: locking/lockdep: Enforce PROVE_RAW_LOCK_NESTING only if PREEMPT_RT
Commit 560af5dc ("lockdep: Enable PROVE_RAW_LOCK_NESTING with PROVE_LOCKING.") and commit d387ceb1 ("Enforce PROVE_RAW_LOCK_NESTING only if ARCH_SUPPORTS_RT") cause PROVE_RAW_LOCK_NESTING to be enabled by default in the GKI. This causes lockdep to splat during Android init because cpufreq_acct_update_power, part of the cpufreq_times driver, grabs a non-raw spinlock in an interrupt context. While the bug reported by lockdep indicates an error when PREEMPT_RT=y, this is not an issue in the ACK because PREEMPT_RT is disabled in GKI builds (and is expected to remain disabled for the time being). Since lockdep stops monitoring after the first issue it encounters, this splat also prevents it from detecting any other locking errors later on. This driver has not been upstreamed, so it is only expected to run with PREEMPT_RT disabled. This is also the case for several other vendor drivers that trigger this bug. Allow PROVE_RAW_LOCK_NESTING to be disabled when !PREEMPT_RT. Bug: 445976477 Change-Id: I05ea46c73ebdb6477ab3b79f242b1b538f405d0d Signed-off-by:Tiffany Yang <ynaffit@google.com>
Loading