question about softirqs

Paul Mackerras paulus at samba.org
Sat May 9 09:34:29 EST 2009


Chris Friesen writes:

> I'm trying to figure out where exactly softirqs are called on return 
> from a syscall in 64-bit powerpc.  I can see where they get called for a 
> normal interrupt via the irq_exit() path, but not for syscalls.

If a soft irq is raised in process context, raise_softirq() in
kernel/softirq.c calls wakeup_softirqd() to make sure that ksoftirqd
runs soon to process the soft irq.  So what would happen is that we
would see the TIF_RESCHED_PENDING flag on the current task in the
syscall exit path and call schedule() which would switch to ksoftirqd
to process the soft irq (if it hasn't already been processed by that
stage).

If the soft irq is raised in interrupt context, then the soft irq gets
run via the do_softirq() call in irq_exit(), as you saw.

The soft irq stuff is pretty much all generic code these days, except
for the code to switch to the softirq stack.

Paul.



More information about the Linuxppc-dev mailing list