gcc15 rightfully complains about access outside array bounds in usage of
taskTable:

arch/powerpc/mach-mpc5xxx/loadtask.c:37:43: error: array subscript 1 is outside 
array bounds of 'int[1]' [-Werror=array-bounds=]

Declare that variable as an array as that's what it actually is.

Signed-off-by: Sascha Hauer <[email protected]>
---
 arch/powerpc/mach-mpc5xxx/loadtask.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/mach-mpc5xxx/loadtask.c 
b/arch/powerpc/mach-mpc5xxx/loadtask.c
index e2489983ee..9302cbdcdc 100644
--- a/arch/powerpc/mach-mpc5xxx/loadtask.c
+++ b/arch/powerpc/mach-mpc5xxx/loadtask.c
@@ -13,12 +13,12 @@
 #include <types.h>
 
 /* BestComm/SmartComm microcode */
-extern int taskTable;
+extern int taskTable[];
 
 void loadtask(int basetask, int tasks)
 {
        int *sram = (int *)MPC5XXX_SRAM;
-       int *task_org = &taskTable;
+       int *task_org = taskTable;
        unsigned int start, offset, end;
        int i;
 
-- 
2.47.2


Reply via email to