summaryrefslogtreecommitdiff
path: root/kernel/softirq.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-10-19 13:05:38 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-10-19 13:05:38 -0700
commita7204d72db251784808b0c050220992d7f833a2c (patch)
tree3491452ea74b039f3278fd95bb7ad7c88b6b3631 /kernel/softirq.c
parentba6857b2d49646f2d4c245ff58d95d145f380177 (diff)
parent31d141e3a666269a3b6fcccddb0351caf7454240 (diff)
Merge 3.12-rc6 into driver-core-next
We want these fixes here too. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/softirq.c')
-rw-r--r--kernel/softirq.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/kernel/softirq.c b/kernel/softirq.c
index 53cc09ceb0b8..d7d498d8cc4f 100644
--- a/kernel/softirq.c
+++ b/kernel/softirq.c
@@ -328,10 +328,19 @@ void irq_enter(void)
static inline void invoke_softirq(void)
{
- if (!force_irqthreads)
- __do_softirq();
- else
+ if (!force_irqthreads) {
+ /*
+ * We can safely execute softirq on the current stack if
+ * it is the irq stack, because it should be near empty
+ * at this stage. But we have no way to know if the arch
+ * calls irq_exit() on the irq stack. So call softirq
+ * in its own stack to prevent from any overrun on top
+ * of a potentially deep task stack.
+ */
+ do_softirq();
+ } else {
wakeup_softirqd();
+ }
}
static inline void tick_irq_exit(void)