cc3200: Use MP_REGISTER_ROOT_POINTER().
This uses MP_REGISTER_ROOT_POINTER() to register all port-specific root pointers for the cc3200 port. Signed-off-by: David Lechner <david@pybricks.com>
This commit is contained in:
parent
095ad87adf
commit
226e969ad3
|
@ -166,7 +166,7 @@ OBJ += $(BUILD)/shared/runtime/gchelper_m3.o
|
|||
OBJ += $(BUILD)/pins.o
|
||||
|
||||
# List of sources for qstr extraction
|
||||
SRC_QSTR += $(APP_MODS_SRC_C) $(APP_MISC_SRC_C) $(APP_STM_SRC_C) $(APP_SHARED_SRC_C)
|
||||
SRC_QSTR += $(APP_MODS_SRC_C) $(APP_MISC_SRC_C) $(APP_STM_SRC_C) $(APP_SHARED_SRC_C) $(APP_HAL_SRC_C)
|
||||
# Append any auto-generated sources that are needed by sources listed in
|
||||
# SRC_QSTR
|
||||
SRC_QSTR_AUTO_DEPS +=
|
||||
|
|
|
@ -195,3 +195,5 @@ static void hal_TickInit (void) {
|
|||
MAP_SysTickEnable();
|
||||
}
|
||||
#endif
|
||||
|
||||
MP_REGISTER_ROOT_POINTER(struct _os_term_dup_obj_t *os_term_dup_obj);
|
||||
|
|
|
@ -197,3 +197,4 @@ const mp_obj_type_t mp_irq_type = {
|
|||
.locals_dict = (mp_obj_t)&mp_irq_locals_dict,
|
||||
};
|
||||
|
||||
MP_REGISTER_ROOT_POINTER(mp_obj_list_t mp_irq_obj_list);
|
||||
|
|
|
@ -215,3 +215,4 @@ const mp_obj_module_t mp_module_machine = {
|
|||
};
|
||||
|
||||
MP_REGISTER_MODULE(MP_QSTR_umachine, mp_module_machine);
|
||||
MP_REGISTER_ROOT_POINTER(mp_obj_t machine_config_main);
|
||||
|
|
|
@ -652,3 +652,4 @@ STATIC bool setup_timer_hibernate_wake (void) {
|
|||
return false;
|
||||
}
|
||||
|
||||
MP_REGISTER_ROOT_POINTER(mp_obj_list_t pyb_sleep_obj_list);
|
||||
|
|
|
@ -728,3 +728,4 @@ STATIC const mp_obj_type_t pyb_timer_channel_type = {
|
|||
.locals_dict = (mp_obj_t)&pyb_timer_channel_locals_dict,
|
||||
};
|
||||
|
||||
MP_REGISTER_ROOT_POINTER(mp_obj_list_t pyb_timer_channel_obj_list);
|
||||
|
|
|
@ -666,3 +666,5 @@ const mp_obj_type_t pyb_uart_type = {
|
|||
.protocol = &uart_stream_p,
|
||||
.locals_dict = (mp_obj_t)&pyb_uart_locals_dict,
|
||||
};
|
||||
|
||||
MP_REGISTER_ROOT_POINTER(struct _pyb_uart_obj_t *pyb_uart_objs[2]);
|
||||
|
|
|
@ -139,16 +139,7 @@
|
|||
#define MICROPY_PORT_CONSTANTS \
|
||||
{ MP_ROM_QSTR(MP_QSTR_umachine), MP_ROM_PTR(&mp_module_machine) }, \
|
||||
|
||||
// vm state and root pointers for the gc
|
||||
#define MP_STATE_PORT MP_STATE_VM
|
||||
#define MICROPY_PORT_ROOT_POINTERS \
|
||||
mp_obj_t machine_config_main; \
|
||||
mp_obj_list_t pyb_sleep_obj_list; \
|
||||
mp_obj_list_t mp_irq_obj_list; \
|
||||
mp_obj_list_t pyb_timer_channel_obj_list; \
|
||||
struct _pyb_uart_obj_t *pyb_uart_objs[2]; \
|
||||
struct _os_term_dup_obj_t *os_term_dup_obj; \
|
||||
|
||||
|
||||
// type definitions for the specific machine
|
||||
#define MICROPY_MAKE_POINTER_CALLABLE(p) ((void *)((mp_uint_t)(p) | 1))
|
||||
|
|
Loading…
Reference in New Issue