File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -90,6 +90,7 @@ INC += \
90
90
-I$(SPRESENSE_SDK ) /nuttx/include \
91
91
-I$(SPRESENSE_SDK ) /nuttx/arch \
92
92
-I$(SPRESENSE_SDK ) /nuttx/arch/chip \
93
+ -I$(SPRESENSE_SDK ) /nuttx/arch/os \
93
94
-I$(SPRESENSE_SDK ) /sdk/bsp/include \
94
95
-I$(SPRESENSE_SDK ) /sdk/bsp/include/sdk \
95
96
@@ -124,7 +125,6 @@ LDFLAGS = \
124
125
--entry=__start \
125
126
-nostartfiles \
126
127
-nodefaultlibs \
127
- --defsym __stack=_vectors+786432 \
128
128
-T$(SPRESENSE_SDK ) /nuttx/build/ramconfig.ld \
129
129
--gc-sections \
130
130
-Map=$(BUILD ) /output.map \
Original file line number Diff line number Diff line change 27
27
#include <stdint.h>
28
28
#include <sys/boardctl.h>
29
29
30
+ #include "sched/sched.h"
31
+
30
32
#include "boards/board.h"
31
33
32
34
#include "supervisor/port.h"
@@ -68,11 +70,15 @@ void reset_to_bootloader(void) {
68
70
}
69
71
70
72
uint32_t * port_stack_get_limit (void ) {
71
- return & _ebss ;
73
+ struct tcb_s * rtcb = this_task ();
74
+
75
+ return rtcb -> adj_stack_ptr - (uint32_t )rtcb -> adj_stack_size ;
72
76
}
73
77
74
78
uint32_t * port_stack_get_top (void ) {
75
- return & _estack ;
79
+ struct tcb_s * rtcb = this_task ();
80
+
81
+ return rtcb -> adj_stack_ptr ;
76
82
}
77
83
78
84
extern uint32_t _ebss ;
You can’t perform that action at this time.
0 commit comments