Lines Matching refs:new_thread
81 struct k_thread *new_thread, *old_thread; in do_swap() local
121 new_thread = z_swap_next_thread(); in do_swap()
123 if (new_thread != old_thread) { in do_swap()
124 z_sched_usage_switch(new_thread); in do_swap()
128 new_thread->base.cpu = arch_curr_cpu()->id; in do_swap()
131 z_smp_release_global_lock(new_thread); in do_swap()
135 z_sched_switch_spin(new_thread); in do_swap()
136 arch_current_thread_set(new_thread); in do_swap()
139 z_reset_time_slice(new_thread); in do_swap()
146 arch_cohere_stacks(old_thread, NULL, new_thread); in do_swap()
155 void *newsh = new_thread->switch_handle; in do_swap()
162 new_thread->switch_handle = NULL; in do_swap()