Lines Matching refs:p
144 int copy_thread(struct task_struct *p, const struct kernel_clone_args *args) in copy_thread() argument
152 childksp = (unsigned long)task_stack_page(p) + THREAD_SIZE; in copy_thread()
158 p->thread.sched_cfa = 0; in copy_thread()
159 p->thread.csr_euen = 0; in copy_thread()
160 p->thread.csr_crmd = csr_read32(LOONGARCH_CSR_CRMD); in copy_thread()
161 p->thread.csr_prmd = csr_read32(LOONGARCH_CSR_PRMD); in copy_thread()
162 p->thread.csr_ecfg = csr_read32(LOONGARCH_CSR_ECFG); in copy_thread()
165 p->thread.reg03 = childksp; in copy_thread()
166 p->thread.reg23 = (unsigned long)args->fn; in copy_thread()
167 p->thread.reg24 = (unsigned long)args->fn_arg; in copy_thread()
168 p->thread.reg01 = (unsigned long)ret_from_kernel_thread; in copy_thread()
169 p->thread.sched_ra = (unsigned long)ret_from_kernel_thread; in copy_thread()
171 childregs->csr_euen = p->thread.csr_euen; in copy_thread()
172 childregs->csr_crmd = p->thread.csr_crmd; in copy_thread()
173 childregs->csr_prmd = p->thread.csr_prmd; in copy_thread()
174 childregs->csr_ecfg = p->thread.csr_ecfg; in copy_thread()
184 p->thread.reg03 = (unsigned long) childregs; in copy_thread()
185 p->thread.reg01 = (unsigned long) ret_from_fork; in copy_thread()
186 p->thread.sched_ra = (unsigned long) ret_from_fork; in copy_thread()
198 ptrace_hw_copy_thread(p); in copy_thread()
199 clear_tsk_thread_flag(p, TIF_USEDFPU); in copy_thread()
200 clear_tsk_thread_flag(p, TIF_USEDSIMD); in copy_thread()
201 clear_tsk_thread_flag(p, TIF_USEDLBT); in copy_thread()
202 clear_tsk_thread_flag(p, TIF_LSX_CTX_LIVE); in copy_thread()
203 clear_tsk_thread_flag(p, TIF_LASX_CTX_LIVE); in copy_thread()
204 clear_tsk_thread_flag(p, TIF_LBT_CTX_LIVE); in copy_thread()