bool kt_init() { cl_object_type_register(&thread_type); init_idle_thread(kc_get_raw(), &init_thread); return true; }
/* Scheduling won't happen immediately but after the exception returns */ void tfm_thrd_activate_schedule(void) { /* * The current thread can be NULL only when initializing. Create the IDLE * thread and set it as the current thread to collect caller context. */ if (CURR_THRD == NULL) { CURR_THRD = init_idle_thread(&idle_thread); } tfm_trigger_pendsv(); }