signal:remove duplicate code
A message that is not in the archive (sent off-list or not yet received): [email protected]
Am 25.05.2015 um 07:49 schrieb yalin wang:
Quoted 15 lines
__dequeue_signal()is only called bydequeue_signal(), after that,dequeue_signal()will callrecalc_sigpending(), this function will set or unsetTIF_SIGPENDINGbit, so we don't need do this in__dequeue_signal()Signed-off-by yalin wang <[email protected]>--- kernel/signal.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)kernel/signal.c +0
-0
kernel/signal.c static int __dequeue_signal(struct sigpending *pending, sigset_t *mask, · line 587
Quoted 5 lines
kernel/signal.c +0
-2@@ -583,10 +583,9 @@ static int __dequeue_signal(struct sigpending *pending, sigset_t *mask,if (sig) {if (current->notifier) {if (sigismember (current->notifier_mask, sig)) { -if (!(current->notifier)(current->notifier_data)) { -clear_thread_flag (TIF_SIGPENDING );
Here be dragons.
In __dequeue_signal() we clear TIF_SIGPENDING depending on the result of ->notifier().
Did you double check that clearing that flag goes hand in hand with recalc_sigpending()?
Thanks,
//richard