diff options
| author | Karl Mehltretter <kmehltretter@gmail.com> | 2026-08-08 14:36:08 +0200 |
|---|---|---|
| committer | Andrew Morton <akpm@linux-foundation.org> | 2026-08-19 19:55:05 -0700 |
| commit | d9c0fd5533fb23bc445bd581feb140e966195936 (patch) | |
| tree | 53a1b77ca256ba08ba1f18d5de338e817c79b216 /scripts/stackusage | |
| parent | 5779e0f30fa4246748d4168a0f53298443f3744e (diff) | |
| download | linux-d9c0fd5533fb23bc445bd581feb140e966195936.tar.gz linux-d9c0fd5533fb23bc445bd581feb140e966195936.zip | |
lib/interval_tree: fix allocation warning messages
WARN_ON_ONCE() takes a condition, not a message. The string literals are
always true, so the warnings still trigger but the messages are never
printed.
Use WARN_ONCE(1, ...) instead to print the messages and keep the once-only
behavior.
Found with a Coccinelle script. Clang's -Wstring-conversion also flags
such calls but is not enabled in kernel builds.
Link: https://lore.kernel.org/20260808123608.73613-1-kmehltretter@gmail.com
Fixes: 82114e45131f ("lib/interval_tree: add test case for interval_tree_iter_xxx() helpers")
Assisted-by: Claude:claude-fable-5 coccinelle
Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Wei Yang <richard.weiyang@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'scripts/stackusage')
0 files changed, 0 insertions, 0 deletions
