]> git.ipfire.org Git - thirdparty/linux.git/commit
rust: bug: Support DEBUG_BUGVERBOSE_DETAILED option
authorFUJITA Tomonori <fujita.tomonori@gmail.com>
Thu, 8 Jan 2026 01:33:50 +0000 (10:33 +0900)
committerMiguel Ojeda <ojeda@kernel.org>
Fri, 30 Jan 2026 04:18:17 +0000 (05:18 +0100)
commit966f79ce6f6b3d138b69cacc3cdcbb5001141b4d
tree677b89705c9a1e253921f2b298a5fd88acb62dd8
parentabbe94591e8864af3df5ba36b61fe8615b8ff990
rust: bug: Support DEBUG_BUGVERBOSE_DETAILED option

Make warn_on() support DEBUG_BUGVERBOSE_DETAILED option, which was
introduced by the commit aec58b48517c ("bugs/core: Extend
__WARN_FLAGS() with the 'cond_str' parameter").

When the option is enabled, WARN splats now show the evaluated
warn_on() condition alongside the file path, e.g.:

------------[ cut here ]------------
WARNING: [val == 1] linux/samples/rust/rust_minimal.rs:27 at _RNvXCsk7t4azzUqHP_12rust_minimalNtB2_11RustMinimalNtCs8pcx3n4
Modules linked in: rust_minimal(+)

Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com>
Reviewed-by: Gary Guo <gary@garyguo.net>
Link: https://patch.msgid.link/20260108013350.2880613-1-fujita.tomonori@gmail.com
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
rust/kernel/bug.rs