Lines Matching refs:to
135 x86_next_page_directory(Thread* from, Thread* to)
137 VMAddressSpace* toAddressSpace = to->team->address_space;
151 /*! Returns to the userland environment given by \a frame for a thread not
154 Before returning to userland all potentially necessary kernel exit work is
158 \param frame The iframe defining the userland environment. Must point to a
171 // return to userland
196 arch_thread_context_switch(Thread* from, Thread* to)
198 cpu_ent* cpuData = to->cpu;
200 cpuData->arch.tss.sp0 = to->kernel_stack_top;
201 x86_set_syscall_stack(to->kernel_stack_top);
203 // set TLS GDT entry to the current thread - since this action is
204 // dependent on the current CPU, we have to do it here
205 if (to->user_local_storage != 0)
206 x86_set_tls_context(to);
210 VMAddressSpace* toAddressSpace = to->team->address_space;
222 // assign the new paging structures to the CPU
236 gX86SwapFPUFunc(from->arch_info.fpu_state, to->arch_info.fpu_state);
238 x86_context_switch(&from->arch_info, &to->arch_info);
253 /*! Saves everything needed to restore the frame in the child fork in the
254 arch_fork_arg structure to be passed to arch_restore_fork_frame().
255 Also makes sure to return the right value.
262 // we need to copy the threads current iframe
265 // we also want fork() to return 0 for the child
272 Needs to be called from within the child team, i.e. instead of
274 This function does not return to the caller, but will enter userland
278 environment to restore. Must point to a location somewhere on the