mirror of
https://github.com/micropython/micropython.git
synced 2025-12-13 08:20:13 +01:00
renesas-ra/main: Replace mp_stack_set with mp_cstack_init_with_top.
Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
@@ -29,7 +29,6 @@
|
||||
#include <string.h>
|
||||
|
||||
#include "py/runtime.h"
|
||||
#include "py/stackctrl.h"
|
||||
#include "py/gc.h"
|
||||
#include "py/mperrno.h"
|
||||
#include "py/mphal.h"
|
||||
@@ -295,11 +294,8 @@ soft_reset:
|
||||
mp_thread_init();
|
||||
#endif
|
||||
|
||||
// Stack limit should be less than real stack size, so we have a chance
|
||||
// to recover from limit hit. (Limit is measured in bytes.)
|
||||
// Note: stack control relies on main thread being initialised above
|
||||
mp_stack_set_top(&_estack);
|
||||
mp_stack_set_limit((char *)&_estack - (char *)&_sstack - 1024);
|
||||
mp_cstack_init_with_top(&_estack, (char *)&_estack - (char *)&_sstack);
|
||||
|
||||
// GC init
|
||||
gc_init(MICROPY_HEAP_START, MICROPY_HEAP_END);
|
||||
|
||||
@@ -92,6 +92,7 @@
|
||||
#define MICROPY_TRACKED_ALLOC (MICROPY_SSL_MBEDTLS || MICROPY_BLUETOOTH_BTSTACK)
|
||||
#define MICROPY_READER_VFS (1)
|
||||
#define MICROPY_ENABLE_GC (1)
|
||||
#define MICROPY_STACK_CHECK_MARGIN (1024)
|
||||
#define MICROPY_ENABLE_EMERGENCY_EXCEPTION_BUF (1)
|
||||
#define MICROPY_EMERGENCY_EXCEPTION_BUF_SIZE (0)
|
||||
#define MICROPY_REPL_INFO (1)
|
||||
|
||||
Reference in New Issue
Block a user