Skip to content

Commit 1c39606

Browse files
committed
Fix other builds missing new heap bounds functions
1 parent 834259a commit 1c39606

File tree

6 files changed

+33
-13
lines changed

6 files changed

+33
-13
lines changed

ports/atmel-samd/supervisor/port.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,14 @@ uint32_t *port_stack_get_top(void) {
331331
return &_estack;
332332
}
333333

334+
uint32_t *port_heap_get_bottom(void) {
335+
return port_stack_get_limit();
336+
}
337+
338+
uint32_t *port_heap_get_top(void) {
339+
return port_stack_get_top();
340+
}
341+
334342
// Place the word to save 8k from the end of RAM so we and the bootloader don't clobber it.
335343
#ifdef SAMD21
336344
uint32_t* safe_word = (uint32_t*) (HMCRAMC0_ADDR + HMCRAMC0_SIZE - 0x2000);

ports/cxd56/supervisor/port.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,14 @@ uint32_t *port_stack_get_top(void) {
8585
return rtcb->adj_stack_ptr;
8686
}
8787

88+
uint32_t *port_heap_get_bottom(void) {
89+
return port_stack_get_limit();
90+
}
91+
92+
uint32_t *port_heap_get_top(void) {
93+
return port_stack_get_top();
94+
}
95+
8896
extern uint32_t _ebss;
8997

9098
// Place the word to save just after our BSS section that gets blanked.

ports/mimxrt10xx/boards/imxrt1010_evk/flash_config.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,6 @@
88
#include "fsl_flexspi_nor_boot.h"
99
#include "fsl_flexspi_nor_config.h"
1010

11-
/* Component ID definition, used by tools. */
12-
#ifndef FSL_COMPONENT_ID
13-
#define FSL_COMPONENT_ID "platform.drivers.xip_device"
14-
#endif
15-
1611
__attribute__((section(".boot_hdr.ivt")))
1712
/*************************************
1813
* IVT Data
@@ -38,7 +33,6 @@ const BOOT_DATA_T boot_data = {
3833
PLUGIN_FLAG, /* Plugin flag*/
3934
0xFFFFFFFF /* empty - extra data word */
4035
};
41-
#endif
4236

4337
__attribute__((section(".boot_hdr.conf")))
4438
// Values copied from https://github.com/PaulStoffregen/cores/blob/ddb23fa5d97dac763bc06e11b9b41f026bd51f0a/teensy4/bootdata.c#L39

ports/mimxrt10xx/boards/imxrt1060_evk/flash_config.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,6 @@
88
#include "fsl_flexspi_nor_boot.h"
99
#include "fsl_flexspi_nor_config.h"
1010

11-
/* Component ID definition, used by tools. */
12-
#ifndef FSL_COMPONENT_ID
13-
#define FSL_COMPONENT_ID "platform.drivers.xip_device"
14-
#endif
15-
1611
__attribute__((section(".boot_hdr.ivt")))
1712

1813
/*************************************
@@ -39,7 +34,6 @@ const BOOT_DATA_T boot_data = {
3934
PLUGIN_FLAG, /* Plugin flag*/
4035
0xFFFFFFFF /* empty - extra data word */
4136
};
42-
#endif
4337

4438
__attribute__((section(".boot_hdr.conf")))
4539
// Values copied from https://github.com/PaulStoffregen/cores/blob/ddb23fa5d97dac763bc06e11b9b41f026bd51f0a/teensy4/bootdata.c#L39

ports/nrf/supervisor/port.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,14 @@ void reset_cpu(void) {
146146
NVIC_SystemReset();
147147
}
148148

149+
uint32_t *port_heap_get_bottom(void) {
150+
return port_stack_get_limit();
151+
}
152+
153+
uint32_t *port_heap_get_top(void) {
154+
return port_stack_get_top();
155+
}
156+
149157
uint32_t *port_stack_get_limit(void) {
150158
return &_ebss;
151159
}

ports/stm32f4/supervisor/port.c

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ safe_mode_t port_init(void) {
5050
stm32f4_peripherals_gpio_init();
5151

5252
tick_init();
53-
board_init();
53+
board_init();
5454

5555
return NO_SAFE_MODE;
5656
}
@@ -71,6 +71,14 @@ void reset_cpu(void) {
7171
NVIC_SystemReset();
7272
}
7373

74+
uint32_t *port_heap_get_bottom(void) {
75+
return port_stack_get_limit();
76+
}
77+
78+
uint32_t *port_heap_get_top(void) {
79+
return port_stack_get_top();
80+
}
81+
7482
uint32_t *port_stack_get_limit(void) {
7583
return &_ebss;
7684
}

0 commit comments

Comments
 (0)