Jetpack/kernel/kernel-4.9/rt-patches/0053-posix-timers-Prevent-b...

31 lines
953 B
Diff

From 98b54733d416b53b05fdd0727808cf7a5063cc2b Mon Sep 17 00:00:00 2001
From: Thomas Gleixner <tglx@linutronix.de>
Date: Fri, 3 Jul 2009 08:29:20 -0500
Subject: [PATCH 053/352] posix-timers: Prevent broadcast signals
Posix timers should not send broadcast signals and kernel only
signals. Prevent it.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
kernel/time/posix-timers.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/kernel/time/posix-timers.c b/kernel/time/posix-timers.c
index 0e6ed2e..06ef7e4 100644
--- a/kernel/time/posix-timers.c
+++ b/kernel/time/posix-timers.c
@@ -526,6 +526,9 @@ static struct pid *good_sigevent(sigevent_t * event)
case SIGEV_THREAD:
if (event->sigev_signo <= 0 || event->sigev_signo > SIGRTMAX)
return NULL;
+ if (sig_kernel_only(event->sigev_signo) ||
+ sig_kernel_coredump(event->sigev_signo))
+ return NULL;
/* FALLTHRU */
case SIGEV_NONE:
return task_pid(rtn);
--
2.7.4