diff options
author | Thomas Pfaff <tpfaff@pcs.com> | 2013-10-11 12:42:49 +0200 |
---|---|---|
committer | Steven Rostedt <rostedt@goodmis.org> | 2013-11-20 20:44:45 -0500 |
commit | 234338131c281dc663432bc34c1563682f4f3d7e (patch) | |
tree | df5b38c164dc05a83ddab7b636876e60432c40bb | |
parent | fdef24704dbd476ff52e9f7985228168c8a5a06d (diff) | |
download | linux-rt-234338131c281dc663432bc34c1563682f4f3d7e.tar.gz |
genirq: Set the irq thread policy without checking CAP_SYS_NICE
In commit ee23871389 ("genirq: Set irq thread to RT priority on
creation") we moved the assigment of the thread's priority from the
thread's function into __setup_irq(). That function may run in user
context for instance if the user opens an UART node and then driver
calls requests in the ->open() callback. That user may not have
CAP_SYS_NICE and so the irq thread won't run with the SCHED_OTHER
policy.
This patch uses sched_setscheduler_nocheck() so we omit the CAP_SYS_NICE
check which is otherwise required for the SCHED_OTHER policy.
Cc: Ivo Sieben <meltedpianoman@gmail.com>
Cc: stable@vger.kernel.org
Cc: stable-rt@vger.kernel.org
Signed-off-by: Thomas Pfaff <tpfaff@pcs.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
[bigeasy: rewrite the changelog]
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
-rw-r--r-- | kernel/irq/manage.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c index a6bea1915855..30211a79525b 100644 --- a/kernel/irq/manage.c +++ b/kernel/irq/manage.c @@ -1024,7 +1024,7 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new) goto out_mput; } - sched_setscheduler(t, SCHED_FIFO, ¶m); + sched_setscheduler_nocheck(t, SCHED_FIFO, ¶m); /* * We keep the reference to the task struct even if |