Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
a9ba611ae2
|
@ -254,8 +254,7 @@ STATIC void cleanup_after_vm(supervisor_allocation* heap, mp_obj_t exception) {
|
|||
mp_obj_print_exception(&print, exception);
|
||||
((char *)prev_traceback_allocation->ptr)[traceback_len] = '\0';
|
||||
}
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
prev_traceback_allocation = NULL;
|
||||
}
|
||||
}
|
||||
|
@ -645,10 +644,6 @@ STATIC void __attribute__ ((noinline)) run_boot_py(safe_mode_t safe_mode) {
|
|||
&& safe_mode == NO_SAFE_MODE
|
||||
&& MP_STATE_VM(vfs_mount_table) != NULL;
|
||||
|
||||
if (!ok_to_run) {
|
||||
return;
|
||||
}
|
||||
|
||||
static const char *const boot_py_filenames[] = STRING_LIST("boot.py", "boot.txt");
|
||||
|
||||
// Do USB setup even if boot.py is not run.
|
||||
|
@ -661,6 +656,9 @@ STATIC void __attribute__ ((noinline)) run_boot_py(safe_mode_t safe_mode) {
|
|||
usb_set_defaults();
|
||||
#endif
|
||||
|
||||
pyexec_result_t result = {0, MP_OBJ_NULL, 0};
|
||||
|
||||
if (ok_to_run) {
|
||||
#ifdef CIRCUITPY_BOOT_OUTPUT_FILE
|
||||
vstr_t boot_text;
|
||||
vstr_init(&boot_text, 512);
|
||||
|
@ -670,8 +668,6 @@ STATIC void __attribute__ ((noinline)) run_boot_py(safe_mode_t safe_mode) {
|
|||
// Write version info
|
||||
mp_printf(&mp_plat_print, "%s\nBoard ID:%s\n", MICROPY_FULL_VERSION_INFO, CIRCUITPY_BOARD_ID);
|
||||
|
||||
pyexec_result_t result = {0, MP_OBJ_NULL, 0};
|
||||
|
||||
bool found_boot = maybe_run_list(boot_py_filenames, &result);
|
||||
(void)found_boot;
|
||||
|
||||
|
@ -709,6 +705,7 @@ STATIC void __attribute__ ((noinline)) run_boot_py(safe_mode_t safe_mode) {
|
|||
filesystem_flush();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#if CIRCUITPY_USB
|
||||
// Some data needs to be carried over from the USB settings in boot.py
|
||||
|
@ -914,12 +911,14 @@ void gc_collect(void) {
|
|||
|
||||
void NORETURN nlr_jump_fail(void *val) {
|
||||
reset_into_safe_mode(MICROPY_NLR_JUMP_FAIL);
|
||||
while (true) {}
|
||||
while (true) {
|
||||
}
|
||||
}
|
||||
|
||||
void NORETURN __fatal_error(const char *msg) {
|
||||
reset_into_safe_mode(MICROPY_FATAL_ERROR);
|
||||
while (true) {}
|
||||
while (true) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef NDEBUG
|
||||
|
|
|
@ -38,6 +38,7 @@ import subprocess
|
|||
# Relative to top-level repo dir.
|
||||
PATHS = [
|
||||
# C
|
||||
"main.c",
|
||||
"devices/**/*.[ch]",
|
||||
"drivers/bus/*.[ch]",
|
||||
"extmod/*.[ch]",
|
||||
|
|
Loading…
Reference in New Issue