diff mbox series

ACPICA: fix build with GCC 15 due to -Werror=unterminated-string-initialization

Message ID 20250228210834.811164-1-mpagano@gentoo.org
State New
Headers show
Series ACPICA: fix build with GCC 15 due to -Werror=unterminated-string-initialization | expand

Commit Message

Mike Pagano Feb. 28, 2025, 9:08 p.m. UTC
Fix char length error which appears when compiling with GCC 15:

In file included from ./include/acpi/actbl.h:371,
                 from ./include/acpi/acpi.h:26,
                 from ./include/linux/acpi.h:26,
                 from drivers/acpi/tables.c:19:
./include/acpi/actbl1.h:30:33: error: initializer-string for array of ‘char’ is too long [-Werror=unterminated-string-initialization]
   30 | #define ACPI_SIG_BERT           "BERT"  /* Boot Error Record Table */
      |                                 ^~~~~~
drivers/acpi/tables.c:400:9: note: in expansion of macro ‘ACPI_SIG_BERT’
  400 |         ACPI_SIG_BERT, ACPI_SIG_BGRT, ACPI_SIG_CPEP, ACPI_SIG_ECDT,
      |         ^~~~~~~~~~~~~

Signed-off-by: Mike Pagano <mpagano@gentoo.org>
---
 include/acpi/actypes.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/include/acpi/actypes.h b/include/acpi/actypes.h
index 80767e8bf..e72f74b45 100644
--- a/include/acpi/actypes.h
+++ b/include/acpi/actypes.h
@@ -375,7 +375,7 @@  typedef u64 acpi_physical_address;
 
 /* Names within the namespace are 4 bytes long */
 
-#define ACPI_NAMESEG_SIZE               4	/* Fixed by ACPI spec */
+#define ACPI_NAMESEG_SIZE               5	/* Fixed by ACPI spec */
 #define ACPI_PATH_SEGMENT_LENGTH        5	/* 4 chars for name + 1 char for separator */
 #define ACPI_PATH_SEPARATOR             '.'