treewide: Apply nonstring attribute to unterminated strings

Applying the attribute silences the following error and allows
compilation with GCC 15.2.

  error: initializer-string for array of 'char' truncates NUL terminator but destination lacks 'nonstring' attribute

Change-Id: I33cf3219f34e297de03f67d3e73058b10930c9f8
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/90631
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com>
This commit is contained in:
Felix Singer 2025-12-28 18:20:31 +01:00 committed by Matt DeVillier
commit e57478e238
5 changed files with 6 additions and 6 deletions

View file

@ -8,7 +8,7 @@
/* This structure is embedded somewhere in the (uncompressed) bootblock. */
struct metadata_hash_anchor {
uint8_t magic[8];
uint8_t __nonstring magic[8];
struct vb2_hash cbfs_hash;
/* NOTE: This is just reserving space. sizeof(struct vb2_hash) may change between
configurations/versions and cannot be relied upon, so the FMAP hash must be placed

View file

@ -321,7 +321,7 @@ struct lb_gpio {
#define ACTIVE_HIGH 1
uint32_t value;
#define GPIO_MAX_NAME_LENGTH 16
uint8_t name[GPIO_MAX_NAME_LENGTH];
uint8_t __nonstring name[GPIO_MAX_NAME_LENGTH];
};
struct lb_gpios {