|
| 1 | +From 62e01b39b8eb0f6260b55d58e85ed230986bba4e Mon Sep 17 00:00:00 2001 |
| 2 | +From: Frederic Pillon < [email protected]> |
| 3 | +Date: Mon, 16 Jun 2025 14:22:51 +0200 |
| 4 | +Subject: [PATCH] feat(wb0): add __libc_init_array call to startup |
| 5 | + |
| 6 | +Signed-off-by: Frederic Pillon < [email protected]> |
| 7 | +--- |
| 8 | + .../ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb05.s | 2 ++ |
| 9 | + .../ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb06.s | 2 ++ |
| 10 | + .../ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb07.s | 2 ++ |
| 11 | + .../ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb09.s | 2 ++ |
| 12 | + 4 files changed, 8 insertions(+) |
| 13 | + |
| 14 | +diff --git a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb05.s b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb05.s |
| 15 | +index a8991a7ea..1aba7b12b 100644 |
| 16 | +--- a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb05.s |
| 17 | ++++ b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb05.s |
| 18 | +@@ -107,6 +107,8 @@ LoopFillZeroBlueRam: |
| 19 | + cmp r2, r3 |
| 20 | + bcc FillZerobssram |
| 21 | + |
| 22 | ++/* Call static constructors */ |
| 23 | ++ bl __libc_init_array |
| 24 | + /* Call the application's entry point.*/ |
| 25 | + bl main |
| 26 | + |
| 27 | +diff --git a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb06.s b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb06.s |
| 28 | +index 3e3334fb0..8a345492a 100644 |
| 29 | +--- a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb06.s |
| 30 | ++++ b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb06.s |
| 31 | +@@ -107,6 +107,8 @@ LoopFillZeroBlueRam: |
| 32 | + cmp r2, r3 |
| 33 | + bcc FillZerobssram |
| 34 | + |
| 35 | ++/* Call static constructors */ |
| 36 | ++ bl __libc_init_array |
| 37 | + /* Call the application's entry point.*/ |
| 38 | + bl main |
| 39 | + |
| 40 | +diff --git a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb07.s b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb07.s |
| 41 | +index d9baea4b4..36664b5f2 100644 |
| 42 | +--- a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb07.s |
| 43 | ++++ b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb07.s |
| 44 | +@@ -107,6 +107,8 @@ LoopFillZeroBlueRam: |
| 45 | + cmp r2, r3 |
| 46 | + bcc FillZerobssram |
| 47 | + |
| 48 | ++/* Call static constructors */ |
| 49 | ++ bl __libc_init_array |
| 50 | + /* Call the application's entry point.*/ |
| 51 | + bl main |
| 52 | + |
| 53 | +diff --git a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb09.s b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb09.s |
| 54 | +index 7c9b47279..2ee46de75 100644 |
| 55 | +--- a/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb09.s |
| 56 | ++++ b/system/Drivers/CMSIS/Device/ST/STM32WB0x/Source/Templates/gcc/startup_stm32wb09.s |
| 57 | +@@ -107,6 +107,8 @@ LoopFillZeroBlueRam: |
| 58 | + cmp r2, r3 |
| 59 | + bcc FillZerobssram |
| 60 | + |
| 61 | ++/* Call static constructors */ |
| 62 | ++ bl __libc_init_array |
| 63 | + /* Call the application's entry point.*/ |
| 64 | + bl main |
| 65 | + |
| 66 | +-- |
| 67 | +2.34.1 |
| 68 | + |
0 commit comments