[PATCH v5 07/36] lockdep: Annotate lockdep assertions for context analysis
Bart Van Assche
bart.vanassche at gmail.com
Fri Dec 19 21:28:48 UTC 2025
On 12/19/25 2:16 PM, Marco Elver wrote:
> It's basically an escape hatch to defer to dynamic analysis where the
> limits of the static analysis are reached.
That's not how lockdep_assert_held() is used in the kernel. This macro
is more often than not used to document assumptions that can be verified
at compile time.
This patch seems like a step in the wrong direction to me because it
*suppresses* compile time analysis compile-time analysis is useful. I
think that this patch either should be dropped or that the __assume()
annotations should be changed into __must_hold() annotations.
Bart.
More information about the Linux-security-module-archive
mailing list