Re: [PATCH] prctl.2: PR_{SET,GET}_CHILD_SUBREAPER

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 10.01.13 23:51, Michael Kerrisk (man-pages) (mtk.manpages@xxxxxxxxx) wrote:


Hey, 

sorry for never doing the doc work! Here are my comments:

> > +.BR PR_SET_CHILD_SUBREAPER " (since Linux 3.3)"
> > +Sets a process, such as a service manager, such that orphan (double-forking)
> > +child processes re-parent to this process instead of
> > +.BR init (8).

I don't like this reference to "double-forking" here. After all, this
also applies to triple-forking, quadruple-forking and even
quintuple-forking... ;-)

Expressing this is difficult, but here's my try:

"Enables that the process becomes a 'subreaper' for all its (immediate
or indirect) offspring processes. Any process whose immediate parent
dies and whose ancestry includes a process where this flag is set will
be reparented to the closest process with this flag set, instead of PID
1. A 'subreaper' hence receives SIGHCLD signals for any orphaned
offspring processes, that otherwise would be received by the init
process."

> > +The service manager
> > +is able to receive
> > +.B SIGCHLD
> > +signals and is able to investigate the process until
> > +it calls
> > +.BR wait (2).

Drop this.

> > +All children of this process will inherit a flag if they should
> > +look for a child_subreaper process at exit. Set

This bit should go, it's an inplementation detail, als Kay already
pointed out.

> > +.I arg2
> > +to 1 or 0 to enable or disable, respectively.
> > +.TP
> > +.BR PR_GET_CHILD_SUBREAPER " (since Linux 3.3)"
> > +Returns whether calling process is a child subreaper (see
> > +.BR PR_SET_CHILD_SUBREAPER ),
> > +in the location pointed to by
> > +.IR "(int\ *) arg2" .
> > +.TP
> >  .BR PR_SET_SECUREBITS " (since Linux 2.6.26)"
> >  Set the "securebits" flags of the calling thread to the value supplied in
> >  .IR arg2 .
> >

Otherwise sounds good.

Lennart

-- 
Lennart Poettering - Red Hat, Inc.
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Documentation]     [Netdev]     [Linux Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux