Re: [patch] new sys_tkill2() system call, 2.5.70

Linus Torvalds (torvalds@transmeta.com)
Tue, 3 Jun 2003 09:04:29 -0700 (PDT)


On Tue, 3 Jun 2003, Ingo Molnar wrote:
>
> the attached patch, against 2.5.70, adds a new system-call called
> sys_tkill2():

I'd suggest changing the name. It's not "tkill2", it's a totally new
system call with different inputs.

How about calling it "tgkill()" for "thread" and "group", which are the
new inputs?

It would also seem a lot cleaner that the "any" value be "-1" (like it is
for the other kill functions), and it works for both tgid _and_ for pid,
so that

tgkill(-1, pid, sig) == tkill(pid, sig) == kill thread
tgkill(pid, -1, sig) == kill(pid, sig) == kill group

You made the "any" value be 0, and working only for the group. At least to
me, "0" historically means "this process group", while "-1" means "any"
for the signals.

("0" for "this thread group" might make sense, but if I read the patch
correctly, you really have "0 == _any_ thread group").

Hmm?

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/