/freebsd/sys/kern/ |
H A D | kern_kthread.c | 268 struct thread *newtd, *oldtd; in kthread_add1() local 278 newtd = thread_alloc(pages); in kthread_add1() 279 if (newtd == NULL) in kthread_add1() 294 *newtdp = newtd; in kthread_add1() 296 bzero(&newtd->td_startzero, in kthread_add1() 298 bcopy(&oldtd->td_startcopy, &newtd->td_startcopy, in kthread_add1() 302 strcpy(newtd->td_name, tdname); in kthread_add1() 304 TSTHREAD(newtd, newtd->td_name); in kthread_add1() 306 newtd->td_proc = p; /* needed for cpu_copy_thread */ in kthread_add1() 307 newtd->td_pflags |= TDP_KTHREAD; in kthread_add1() [all …]
|
H A D | kern_thr.c | 195 struct thread *newtd; in thread_create() 230 error = kern_thr_alloc(p, 0, &newtd); in thread_create() 234 bzero(&newtd->td_startzero, in thread_create() 236 bcopy(&td->td_startcopy, &newtd->td_startcopy, in thread_create() 238 newtd->td_proc = td->td_proc; in thread_create() 239 newtd->td_rb_list = newtd->td_rbp_list = newtd->td_rb_inact = 0; in thread_create() 240 thread_cow_get(newtd, td); in thread_create() 242 cpu_copy_thread(newtd, t in thread_create() 196 struct thread *newtd; thread_create() local [all...] |
H A D | kern_thread.c | 857 thread_cow_get_proc(struct thread *newtd, struct proc *p) in thread_cow_get_proc() argument 861 newtd->td_realucred = crcowget(p->p_ucred); in thread_cow_get_proc() 862 newtd->td_ucred = newtd->td_realucred; in thread_cow_get_proc() 863 newtd->td_limit = lim_hold(p->p_limit); in thread_cow_get_proc() 864 newtd->td_cowgen = p->p_cowgen; in thread_cow_get_proc() 868 thread_cow_get(struct thread *newtd, struct thread *td) in thread_cow_get() argument 872 newtd->td_realucred = crcowget(td->td_realucred); in thread_cow_get() 873 newtd->td_ucred = newtd->td_realucred; in thread_cow_get() 874 newtd->td_limit = lim_hold(td->td_limit); in thread_cow_get() 875 newtd->td_cowgen = td->td_cowgen; in thread_cow_get()
|
H A D | sched_ule.c | 2181 struct thread *newtd; in sched_switch() local 2265 newtd = choosethread(); in sched_switch() 2266 sched_pctcpu_update(td_get_sched(newtd), 0); in sched_switch() 2272 if (td != newtd) { in sched_switch() 2277 SDT_PROBE2(sched, , , off__cpu, newtd, newtd->td_proc); in sched_switch() 2286 (*dtrace_vtime_switch_func)(newtd); in sched_switch() 2289 cpu_switch(td, newtd, mtx); in sched_switch() 3082 struct thread *newtd; 3084 newtd in sched_throw_grab() 3085 struct thread *newtd; sched_throw_grab() local 3101 struct thread *newtd; sched_ap_entry() local 3127 struct thread *newtd; sched_throw() local [all...] |
H A D | sched_4bsd.c | 1006 struct thread *newtd; in sched_switch() 1055 newtd = choosethread(); in sched_switch() 1056 MPASS(newtd->td_lock == &sched_lock); in sched_switch() 1068 if (td != newtd) { in sched_switch() 1074 SDT_PROBE2(sched, , , off__cpu, newtd, newtd->td_proc); in sched_switch() 1085 (*dtrace_vtime_switch_func)(newtd); in sched_switch() 1088 cpu_switch(td, newtd, tmtx); in sched_switch() 1008 struct thread *newtd; sched_switch() local
|
H A D | subr_smp.c | 1036 struct thread *td, *newtd; in quiesce_all_critical() local 1049 newtd = (struct thread *) in quiesce_all_critical() 1051 if (td != newtd) in quiesce_all_critical()
|
/freebsd/sys/compat/linux/ |
H A D | linux_fork.c | 240 struct thread *newtd; in linux_clone_thread() local 271 error = kern_thr_alloc(p, 0, &newtd); in linux_clone_thread() 275 bzero(&newtd->td_startzero, in linux_clone_thread() 277 bcopy(&td->td_startcopy, &newtd->td_startcopy, in linux_clone_thread() 280 newtd->td_proc = p; in linux_clone_thread() 281 thread_cow_get(newtd, td); in linux_clone_thread() 283 cpu_copy_thread(newtd, td); in linux_clone_thread() 286 linux_proc_init(td, newtd, true); in linux_clone_thread() 288 em = em_find(newtd); in linux_clone_thread() 292 linux_set_cloned_tls(newtd, PTRIN(args->tls)); in linux_clone_thread() [all …]
|
H A D | linux_emul.c | 137 linux_proc_init(struct thread *td, struct thread *newtd, bool init_thread) in linux_proc_init() argument 143 if (newtd != NULL) { in linux_proc_init() 144 p = newtd->td_proc; in linux_proc_init() 150 newtd->td_tid); in linux_proc_init() 152 em->em_tid = newtd->td_tid; in linux_proc_init() 162 newtd->td_emuldata = em; in linux_proc_init()
|
/freebsd/sys/arm/arm/ |
H A D | vfp.c | 280 vfp_new_thread(struct thread *newtd, struct thread *oldtd, bool fork) in vfp_new_thread() argument 284 newpcb = newtd->td_pcb; in vfp_new_thread()
|
/freebsd/sys/arm64/arm64/ |
H A D | vfp.c | 605 vfp_new_thread(struct thread *newtd, struct thread *oldtd, bool fork) in vfp_new_thread() argument 609 newpcb = newtd->td_pcb; in vfp_new_thread()
|
/freebsd/sys/sys/ |
H A D | proc.h | 1246 void thread_cow_get_proc(struct thread *newtd, struct proc *p); 1247 void thread_cow_get(struct thread *newtd, struct thread *td);
|