aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/gcc-plugins/randomize_layout_plugin.c
diff options
context:
space:
mode:
authorKees Cook <[email protected]>2025-04-15 23:25:19 +0000
committerKees Cook <[email protected]>2025-05-08 16:42:06 +0000
commit82d76bf938389e23c3826b2859fd6c84fd71366a (patch)
treefbe32e6d9c166cb38ac59b20971f418824b3b783 /scripts/gcc-plugins/randomize_layout_plugin.c
parentinteger-wrap: Force full rebuild when .scl file changes (diff)
downloadkernel-82d76bf938389e23c3826b2859fd6c84fd71366a.tar.gz
kernel-82d76bf938389e23c3826b2859fd6c84fd71366a.zip
md/bcache: Mark __nonstring look-up table
GCC 15's new -Wunterminated-string-initialization notices that the 16 character lookup table "zero_uuid" (which is not used as a C-String) needs to be marked as "nonstring": drivers/md/bcache/super.c: In function 'uuid_find_empty': drivers/md/bcache/super.c:549:43: warning: initializer-string for array of 'char' truncates NUL terminator but destination lacks 'nonstring' attribute (17 chars into 16 available) [-Wunterminated-string-initialization] 549 | static const char zero_uuid[16] = "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Add the annotation (since it is not used as a C-String), and switch the initializer to an array of bytes rather than an empty initializer, as preferred by Coly Li. Suggested-by: Coly Li <[email protected]> Link: https://lore.kernel.org/lkml/[email protected]/ Signed-off-by: Kees Cook <[email protected]>
Diffstat (limited to 'scripts/gcc-plugins/randomize_layout_plugin.c')
0 files changed, 0 insertions, 0 deletions