aboutsummaryrefslogtreecommitdiffstats
path: root/lib/libc/sys/pdfork.2
Commit message (Collapse)AuthorAgeFilesLines
* libc: Fix most issues reported by mandocGordon Bergling2020-12-191-1/+1
| | | | | | | | | | | | | | - varios "new sentence, new line" warnings - varios "sections out of conventional order" warnings - varios "unusual Xr order" warnings - varios "missing section argument" warnings - varios "no blank before trailing delimiter" warnings - varios "normalizing date format" warnings MFC after: 1 month Notes: svn path=/head/; revision=368817
* Add .Xrs to kqueue(2) from pdfork(2) and procdesc(4), to make EVFILT_PROCDESCEdward Tomasz Napierala2018-10-141-1/+2
| | | | | | | | | | | easier to find. Approved by: re (rgrimes) MFC after: 2 weeks Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=339356
* pdwait4(2): Remove documentation of vaporwareConrad Meyer2017-06-171-18/+3
| | | | | | | | | | This syscall has never existed and is not at risk of existing any time soon. Remove documentation referencing it, which has been wrong since FreeBSD 9. Reported by: allanjude@ Notes: svn path=/head/; revision=320058
* Introduce the PD_CLOEXEC for pdfork(2).Mariusz Zaborski2016-06-081-1/+5
| | | | | | | Reviewed by: mjg Notes: svn path=/head/; revision=301573
* use .Mt to mark up email addresses consistently (part4)Baptiste Daroussin2014-06-231-2/+2
| | | | | | | | PR: 191174 Submitted by: Franco Fichtner <franco at lastsummer.de> Notes: svn path=/head/; revision=267774
* Implement kqueue(2) for procdesc(4).Ed Schouten2014-04-071-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | kqueue(2) already supports EVFILT_PROC. Add an EVFILT_PROCDESC that behaves the same, but operates on a procdesc(4) instead. Only implement NOTE_EXIT for now. The nice thing about NOTE_EXIT is that it also returns the exit status of the process, meaning that we can now obtain this value, even if pdwait4(2) is still unimplemented. Notes: - Simply reuse EVFILT_NETDEV for EVFILT_PROCDESC. As both of these will be used on totally different descriptor types, this should not clash. - Let procdesc_kqops_event() reuse the same structure as filt_proc(). The only difference is that procdesc_kqops_event() should also be able to deal with the case where the process was already terminated after registration. Simply test this when hint == 0. - Fix some style(9) issues in filt_proc() to keep it consistent with the newly added procdesc_kqops_event(). - Save the exit status of the process in pd->pd_xstat, as we cannot pick up the proctree_lock from within procdesc_kqops_event(). Discussed on: arch@ Reviewed by: kib@ Notes: svn path=/head/; revision=264231
* Correct return type of pdfork(2).Ed Schouten2014-04-041-2/+2
| | | | | | | | | | | | | The pdfork(2) man page states: "pdfork() returns a PID, 0 or -1, as fork(2) does." As it returns a PID, the return type should obviously be pid_t. As int and pid_t have the same size on all architectures, this change does not affect the ABI in any way. Notes: svn path=/head/; revision=264136
* Make process descriptors standard part of the kernel. rwhod(8) alreadyPawel Jakub Dawidek2013-11-301-6/+0
| | | | | | | | | | | requires process descriptors to work and having PROCDESC in GENERIC seems not enough, especially that we hope to have more and more consumers in the base. MFC after: 3 days Notes: svn path=/head/; revision=258768
* Xref capsicum(4) and procdesc(4) from pdfork(2).Robert Watson2013-08-281-4/+18
| | | | | | | | Suggested by: sbruno MFC after: 3 days Notes: svn path=/head/; revision=255002
* fix a further typo in the pdfork(2) man page.Robert Watson2012-04-301-1/+1
| | | | | | | | Submitted by: Norman Hardy MFC after: 3 days Notes: svn path=/head/; revision=234830
* The returned file descriptor from pdfork(2) is via fdp, not pidp.Robert Watson2012-04-301-2/+2
| | | | | | | | Submitted by: Norman Hardy MFC after: 3 days Notes: svn path=/head/; revision=234829
* Whitespace cleanup:Glen Barber2012-02-251-1/+2
| | | | | | | | | | | | o Wrap sentences on to new lines o Cleanup trailing whitespace Found with: textproc/igor MFC after: 1 week X-MFC-With: r232157 Notes: svn path=/head/; revision=232158
* Fix various typos in manual pages.Glen Barber2012-02-251-2/+2
| | | | | | | | | Submitted by: amdmi3 PR: 165431 MFC after: 1 week Notes: svn path=/head/; revision=232157
* Add experimental support for process descriptorsJonathan Anderson2011-08-181-0/+182
A "process descriptor" file descriptor is used to manage processes without using the PID namespace. This is required for Capsicum's Capability Mode, where the PID namespace is unavailable. New system calls pdfork(2) and pdkill(2) offer the functional equivalents of fork(2) and kill(2). pdgetpid(2) allows querying the PID of the remote process for debugging purposes. The currently-unimplemented pdwait(2) will, in the future, allow querying rusage/exit status. In the interim, poll(2) may be used to check (and wait for) process termination. When a process is referenced by a process descriptor, it does not issue SIGCHLD to the parent, making it suitable for use in libraries---a common scenario when using library compartmentalisation from within large applications (such as web browsers). Some observers may note a similarity to Mach task ports; process descriptors provide a subset of this behaviour, but in a UNIX style. This feature is enabled by "options PROCDESC", but as with several other Capsicum kernel features, is not enabled by default in GENERIC 9.0. Reviewed by: jhb, kib Approved by: re (kib), mentor (rwatson) Sponsored by: Google Inc Notes: svn path=/head/; revision=224987