Lines Matching full:fr

102 	struct fork_req fr;  in sys_fork()  local
105 bzero(&fr, sizeof(fr)); in sys_fork()
106 fr.fr_flags = RFFDG | RFPROC; in sys_fork()
107 fr.fr_pidp = &pid; in sys_fork()
108 error = fork1(td, &fr); in sys_fork()
120 struct fork_req fr; in sys_pdfork() local
123 bzero(&fr, sizeof(fr)); in sys_pdfork()
124 fr.fr_flags = RFFDG | RFPROC | RFPROCDESC; in sys_pdfork()
125 fr.fr_pidp = &pid; in sys_pdfork()
126 fr.fr_pd_fd = &fd; in sys_pdfork()
127 fr.fr_pd_flags = uap->flags; in sys_pdfork()
134 error = fork1(td, &fr); in sys_pdfork()
147 struct fork_req fr; in sys_vfork() local
150 bzero(&fr, sizeof(fr)); in sys_vfork()
151 fr.fr_flags = RFFDG | RFPROC | RFPPWAIT | RFMEM; in sys_vfork()
152 fr.fr_pidp = &pid; in sys_vfork()
153 error = fork1(td, &fr); in sys_vfork()
164 struct fork_req fr; in sys_rfork() local
175 bzero(&fr, sizeof(fr)); in sys_rfork()
177 fr.fr_flags = RFFDG | RFPROC | RFPPWAIT | RFMEM; in sys_rfork()
178 fr.fr_flags2 = FR2_DROPSIG_CAUGHT; in sys_rfork()
180 fr.fr_flags = uap->flags; in sys_rfork()
182 fr.fr_pidp = &pid; in sys_rfork()
183 error = fork1(td, &fr); in sys_rfork()
366 do_fork(struct thread *td, struct fork_req *fr, struct proc *p2, struct thread *td2, in do_fork() argument
390 p2->p_pid = fork_findpid(fr->fr_flags); in do_fork()
409 if (fr->fr_flags & RFSIGSHARE) in do_fork()
417 if (fr->fr_flags & RFCFDG) { in do_fork()
421 } else if (fr->fr_flags & RFFDG) { in do_fork()
422 if (fr->fr_flags2 & FR2_SHARE_PATHS) in do_fork()
429 if (fr->fr_flags2 & FR2_SHARE_PATHS) in do_fork()
437 if ((fr->fr_flags & RFTHREAD) != 0) { in do_fork()
486 if ((fr->fr_flags & RFPPWAIT) != 0) in do_fork()
505 if (fr->fr_flags & RFSIGSHARE) { in do_fork()
510 if ((fr->fr_flags2 & (FR2_DROPSIG_CAUGHT | FR2_KPROC)) != 0) { in do_fork()
512 if ((fr->fr_flags2 & FR2_DROPSIG_CAUGHT) != 0) in do_fork()
514 if ((fr->fr_flags2 & FR2_KPROC) != 0) in do_fork()
520 if (fr->fr_flags & RFTSIGZMB) in do_fork()
521 p2->p_sigparent = RFTSIGNUM(fr->fr_flags); in do_fork()
522 else if (fr->fr_flags & RFLINUXTHPN) in do_fork()
527 if ((fr->fr_flags2 & FR2_KPROC) != 0) { in do_fork()
569 if ((fr->fr_flags & RFTHREAD) != 0) { in do_fork()
616 if (fr->fr_flags & RFPPWAIT) in do_fork()
641 if ((fr->fr_flags & RFNOWAIT) != 0) { in do_fork()
672 vm_forkproc(td, p2, td2, vm2, fr->fr_flags); in do_fork()
674 if (fr->fr_flags == (RFFDG | RFPROC)) { in do_fork()
678 } else if (fr->fr_flags == (RFFDG | RFPROC | RFPPWAIT | RFMEM)) { in do_fork()
697 if (fr->fr_flags & RFPROCDESC) in do_fork()
698 procdesc_new(p2, fr->fr_pd_flags); in do_fork()
704 EVENTHANDLER_DIRECT_INVOKE(process_fork, p1, p2, fr->fr_flags); in do_fork()
723 if ((fr->fr_flags & RFMEM) == 0 && dtrace_fasttrap_fork) in do_fork()
726 if (fr->fr_flags & RFPPWAIT) { in do_fork()
743 SDT_PROBE3(proc, , , create, p2, p1, fr->fr_flags); in do_fork()
745 if (fr->fr_flags & RFPROCDESC) { in do_fork()
787 if ((fr->fr_flags & RFSTOPPED) == 0) { in do_fork()
788 if (fr->fr_pidp != NULL) in do_fork()
789 *fr->fr_pidp = p2->p_pid; in do_fork()
798 *fr->fr_procp = p2; in do_fork()
848 fork1(struct thread *td, struct fork_req *fr) in fork1() argument
863 flags = fr->fr_flags; in fork1()
864 pages = fr->fr_pages; in fork1()
867 MPASS(fr->fr_procp != NULL && fr->fr_pidp == NULL); in fork1()
869 MPASS(fr->fr_procp == NULL); in fork1()
893 if (fr->fr_pd_fd == NULL) in fork1()
897 if ((fr->fr_pd_flags & ~PD_ALLOWED_AT_FORK) != 0) in fork1()
908 if (fr->fr_procp != NULL) in fork1()
909 *fr->fr_procp = NULL; in fork1()
910 else if (fr->fr_pidp != NULL) in fork1()
911 *fr->fr_pidp = 0; in fork1()
1001 error = procdesc_falloc(td, &fp_procdesc, fr->fr_pd_fd, in fork1()
1002 fr->fr_pd_flags, fr->fr_pd_fcaps); in fork1()
1005 AUDIT_ARG_FD(*fr->fr_pd_fd); in fork1()
1079 do_fork(td, fr, newproc, td2, vm2, fp_procdesc); in fork1()
1095 fdclose(td, fp_procdesc, *fr->fr_pd_fd); in fork1()