Subject: RE: MIPS Interrupts.

From: "Kapoor, Pankaj" <[email-masked]>
Date: Tue, 25 Nov 2003 19:24:18 -0500

> The nested interrupt call, do_IRQ(), may still try to call do_softirq()
but
> that it will return immediately as it discovers another instance of
do_softirq()
> is running.  No further nesting occurs as a result. 

How is this detected ? Is this the check of "softirq_pending(cpu)" in the
do_softirq() ?

Can we have a case as shown below :

1. Interrupt 1 is generated : Jump to general exception handler
(0x8000:0180)
2. Save the current context
3. Interrupt 1 is processed which schedules tasklet1 for execution.
	softirq_pending(cpu) = TASKLET_SOFTIRQ
4. Interrupts are reenabled.
5. do_softirq : Tasklet1 is executing & softirq_pending(cpu) = 0.
6. -------> Interrupt 2 is generated : Jump to general exception handler
(0x8000:0180)
		6a) Save the current context
		6b) Interrupt2 is processed which schedules tasklet2 for
execution. 
			softirq_pending(cpu) = TASKLET_SOFTIRQ
		6c) Interrupts are reenabled.
		6d) do_softirq : Tasklet2 is executing &
softirq_pending(cpu) = 0.
		6e) ----> Interrupt3 is generated
			.... and so on.
		.
		.
		.
		6f) Context is restored. Return from exception.
.
.
.
7. Context is restored. Return from exception.

Thanks. 
- Pankaj

---

From: Jun Sun <[email-masked]>
Date: Tue, 25 Nov 2003 16:34:20 -0800

> How is this detected ? Is this the check of "softirq_pending(cpu)" in the

No.  It is 

        if (in_interrupt())
                return;

> softirq_pending(cpu) = 0.

Impossible here, due to the above checking code.  Instead,
Tasklet2 will run by 5) once this interrupt trap returns.

Jun