mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-21 06:01:23 +00:00
signalfd simplification
This simplifies signalfd code, by avoiding it to remain attached to the sighand during its lifetime. In this way, the signalfd remain attached to the sighand only during poll(2) (and select and epoll) and read(2). This also allows to remove all the custom "tsk == current" checks in kernel/signal.c, since dequeue_signal() will only be called by "current". I think this is also what Ben was suggesting time ago. The external effect of this, is that a thread can extract only its own private signals and the group ones. I think this is an acceptable behaviour, in that those are the signals the thread would be able to fetch w/out signalfd. Signed-off-by: Davide Libenzi <davidel@xmailserver.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
9db619e665
commit
b8fceee17a
8 changed files with 39 additions and 217 deletions
|
@ -86,7 +86,7 @@ extern struct nsproxy init_nsproxy;
|
|||
.count = ATOMIC_INIT(1), \
|
||||
.action = { { { .sa_handler = NULL, } }, }, \
|
||||
.siglock = __SPIN_LOCK_UNLOCKED(sighand.siglock), \
|
||||
.signalfd_list = LIST_HEAD_INIT(sighand.signalfd_list), \
|
||||
.signalfd_wqh = __WAIT_QUEUE_HEAD_INITIALIZER(sighand.signalfd_wqh), \
|
||||
}
|
||||
|
||||
extern struct group_info init_groups;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue