Skip to content

Commit 456607b

Browse files
Merge pull request #4794 from jeromecoutant/PR_F767
NUCLEO_F767ZI : boot issue with GCC
2 parents f4de24b + 9e334a6 commit 456607b

File tree

1 file changed

+7
-17
lines changed

1 file changed

+7
-17
lines changed

targets/TARGET_STM/TARGET_STM32F7/TARGET_STM32F767xI/device/TOOLCHAIN_GCC_ARM/startup_stm32f767xx.S

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,6 @@ defined in linker script */
5858
.word _sdata
5959
/* end address for the .data section. defined in linker script */
6060
.word _edata
61-
/* start address for the .bss section. defined in linker script */
62-
.word _sbss
63-
/* end address for the .bss section. defined in linker script */
64-
.word _ebss
6561
/* stack used for SystemInit_ExtMemCtl; always internal RAM used */
6662

6763
/**
@@ -95,24 +91,18 @@ LoopCopyDataInit:
9591
adds r2, r0, r1
9692
cmp r2, r3
9793
bcc CopyDataInit
98-
ldr r2, =_sbss
99-
b LoopFillZerobss
100-
/* Zero fill the bss segment. */
101-
FillZerobss:
102-
movs r3, #0
103-
str r3, [r2], #4
104-
105-
LoopFillZerobss:
106-
ldr r3, = _ebss
107-
cmp r2, r3
108-
bcc FillZerobss
10994

11095
/* Call the clock system initialization function.*/
11196
bl SystemInit
11297
/* Call static constructors */
113-
bl __libc_init_array
98+
//bl __libc_init_array
11499
/* Call the application's entry point.*/
115-
bl main
100+
//bl main
101+
// Calling the crt0 'cold-start' entry point. There __libc_init_array is called
102+
// and when existing hardware_init_hook() and software_init_hook() before
103+
// starting main(). software_init_hook() is available and has to be called due
104+
// to initializsation when using rtos.
105+
bl _start
116106
bx lr
117107
.size Reset_Handler, .-Reset_Handler
118108

0 commit comments

Comments
 (0)