> greg k-h
> # USB: Fix from Jeff and Pete to keep khubd from being able to be killed
> # by a signal
> diff -Nru a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
> --- a/drivers/usb/core/hub.c Sun Jan 12 22:03:13 2003
> +++ b/drivers/usb/core/hub.c Sun Jan 12 22:03:13 2003
> @@ -1085,6 +1085,12 @@
> + /* keep others from killing us */
> + spin_lock_irq(¤t->sig->siglock);
> + sigemptyset(¤t->blocked);
> + recalc_sigpending();
> + spin_unlock_irq(¤t->sig->siglock);
> /* Setup a nice name */
> strcpy(current->comm, "khubd");
For the record, I disagree with this strongly.
In khubd case, the existing code did it righ. It ran
daemonize(), which should have divorced it from the session
and process group. If daemonize is buggy, it is the place
to fix it. Ingo has the fix for 2.5, in fact, I think he
may have sent it to Linus already (it's __set_special_pids()).
My version of the patch above never was intended as anything
but a stop-gap solution which allowed us to ship a beta on
schedule, while I was investigating the cause.
Jeff told me on IRC that "every bit in 8139too.c thread was
added as a response to a particular problem", but he did not
remember what particular problem this kludge fixed there.
I stole the stop-gap from Stephen's kjournald. Note, that
I do not have any idea why he put it in there. Very likely,
for entirely different reason than working around bugs in
[P.S. Greg, if Jeff's P.O.V. prevails in the court of Linus,
change that sigemptyset() to siginitsetinv(...., sigmask(SIGKILL)).
Otherwise the whole signal checking path in khubd becomes utterly
[P.P.S And take my name from the bk message. Yes, I wrote
the patch, but I do not want to endorse it, however indirectly]
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to firstname.lastname@example.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/