blob: 06ca22b7789e6ecf8a3e403eafab8cf7fccff41f [file] [log] [blame]
From 5b7ab64ba8e33ae73e5abb0fe5443ec35a4ba1d7 Mon Sep 17 00:00:00 2001
From: Thomas Gleixner <tglx@linutronix.de>
Date: Fri, 3 Jul 2009 08:44:44 -0500
Subject: [PATCH] signals: Do not wakeup self
commit c0445b35154b777c8b4340c5930a1b2924a7f86f in tip.
Signals which are delivered by current to current can do without
waking up current :)
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
diff --git a/kernel/signal.c b/kernel/signal.c
index 934ae5e..549df9d 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -542,6 +542,9 @@ void signal_wake_up(struct task_struct *t, int resume)
set_tsk_thread_flag(t, TIF_SIGPENDING);
+ if (unlikely(t == current))
+ return;
+
/*
* For SIGKILL, we want to wake it up in the stopped/traced/killable
* case. We don't check t->state here because there is a race with it
--
1.7.1.1