linux/drivers/md/bcache
Linus Torvalds be913e7c40 gcc-15: get rid of misc extra NUL character padding
This removes two cases of explicit NUL padding that now causes warnings
because of '-Wunterminated-string-initialization' being part of -Wextra
in gcc-15.

Gcc is being silly in this case when it says that it truncates a NUL
terminator, because in these cases there were _multiple_ NUL characters.

But we can get rid of the warning by just simplifying the two
initializers that trigger the warning for me, so this does exactly that.

I'm not sure why the power supply code did that odd

    .attr_name = #_name "\0",

pattern: it was introduced in commit 2cabeaf151 ("power: supply: core:
Cleanup power supply sysfs attribute list"), but that 'attr_name[]'
field is an explicitly sized character array in a statically initialized
variable, and a string initializer always has a terminating NUL _and_
statically initialized character arrays are zero-padded anyway, so it
really seems to be rather extraneous belt-and-suspenders.

The zero_uuid[16] initialization in drivers/md/bcache/super.c makes
perfect sense, but it isn't necessary for the same reasons, and not
worth the new gcc warning noise.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2025-04-20 11:57:54 -07:00
..
Kconfig lib/min_heap: introduce non-inline versions of min heap API functions 2024-11-05 17:12:34 -08:00
Makefile bcache: move closures to lib/ 2023-10-19 14:47:33 -04:00
alloc.c bcache: update min_heap_callbacks to use default builtin swap 2024-11-05 17:12:36 -08:00
bcache.h bcache: remove heap-related macros and switch to generic min_heap 2024-06-24 22:25:00 -07:00
bcache_ondisk.h flexible-array transformations for 6.3-rc1 2023-02-25 12:53:42 -08:00
bset.c bcache: update min_heap_callbacks to use default builtin swap 2024-11-05 17:12:36 -08:00
bset.h bcache: remove heap-related macros and switch to generic min_heap 2024-06-24 22:25:00 -07:00
btree.c bcache: remove heap-related macros and switch to generic min_heap 2024-06-24 22:25:00 -07:00
btree.h Locking changes for v6.5: 2023-06-27 14:14:30 -07:00
debug.c
debug.h
extents.c bcache: update min_heap_callbacks to use default builtin swap 2024-11-05 17:12:36 -08:00
extents.h
features.c
features.h
io.c
journal.c closures: CLOSURE_CALLBACK() to fix type punning 2023-11-24 00:29:58 -05:00
journal.h
movinggc.c block: Delete bio_set_prio() 2024-12-23 08:17:23 -07:00
request.c bcache: call force_wake_up_gc() if necessary in check_should_bypass() 2024-05-28 06:55:59 -06:00
request.h closures: CLOSURE_CALLBACK() to fix type punning 2023-11-24 00:29:58 -05:00
stats.c treewide: Switch/rename to timer_delete[_sync]() 2025-04-05 10:30:12 +02:00
stats.h bcache: Remove dead references to cache_readaheads 2023-06-15 07:30:11 -06:00
super.c gcc-15: get rid of misc extra NUL character padding 2025-04-20 11:57:54 -07:00
sysfs.c bcache: remove heap-related macros and switch to generic min_heap 2024-06-24 22:25:00 -07:00
sysfs.h bcache: make kobj_type structures constant 2023-06-15 07:30:11 -06:00
trace.c
util.c bcache: fix typo 2024-06-24 22:24:56 -07:00
util.h bcache: remove heap-related macros and switch to generic min_heap 2024-06-24 22:25:00 -07:00
writeback.c block: Delete bio_set_prio() 2024-12-23 08:17:23 -07:00
writeback.h