Linux MIPS Architecture development
 help / color / mirror / Atom feed
* do_IRQ query
@ 2003-06-12 20:16 Ranjan Parthasarathy
  2003-06-12 20:16 ` Ranjan Parthasarathy
  2003-06-12 21:12 ` Jun Sun
  0 siblings, 2 replies; 5+ messages in thread
From: Ranjan Parthasarathy @ 2003-06-12 20:16 UTC (permalink / raw)
  To: linux-mips

Is it safe to call do_IRQ directly inside interrupt handlers without doing a irq_enter. I have seen ksoftirqd_CPUX crashes when I call the do_IRQ routines directly instead of the following sequence.

irq_enter()
do_IRQ
irq_exit()

Some code use it while some do not. The timer code in arch/mips/kernel/time.c uses it in ll_timer_interrupt. Some ports call this function directly in their interrupt handlers.

Any information would be greatly appreciated.

Thank you

Ranjan

^ permalink raw reply	[flat|nested] 5+ messages in thread

* do_IRQ query
  2003-06-12 20:16 do_IRQ query Ranjan Parthasarathy
@ 2003-06-12 20:16 ` Ranjan Parthasarathy
  2003-06-12 21:12 ` Jun Sun
  1 sibling, 0 replies; 5+ messages in thread
From: Ranjan Parthasarathy @ 2003-06-12 20:16 UTC (permalink / raw)
  To: linux-mips

Is it safe to call do_IRQ directly inside interrupt handlers without doing a irq_enter. I have seen ksoftirqd_CPUX crashes when I call the do_IRQ routines directly instead of the following sequence.

irq_enter()
do_IRQ
irq_exit()

Some code use it while some do not. The timer code in arch/mips/kernel/time.c uses it in ll_timer_interrupt. Some ports call this function directly in their interrupt handlers.

Any information would be greatly appreciated.

Thank you

Ranjan

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: do_IRQ query
  2003-06-12 20:16 do_IRQ query Ranjan Parthasarathy
  2003-06-12 20:16 ` Ranjan Parthasarathy
@ 2003-06-12 21:12 ` Jun Sun
  1 sibling, 0 replies; 5+ messages in thread
From: Jun Sun @ 2003-06-12 21:12 UTC (permalink / raw)
  To: Ranjan Parthasarathy; +Cc: linux-mips, jsun

On Thu, Jun 12, 2003 at 01:16:51PM -0700, Ranjan Parthasarathy wrote:
> Is it safe to call do_IRQ directly inside interrupt handlers without doing a irq_enter. I have seen ksoftirqd_CPUX crashes when I call the do_IRQ routines directly instead of the following sequence.
> 
> irq_enter()
> do_IRQ
> irq_exit()
>

This is not right.  irq_enter()/irq_exit() is already called in 
handle_IRQ_event(), which in turn is called by do_IRQ().  YOu 
don't need this yourself.  

The rest of do_IRQ() code is protected by closing interrupts.

Something must be wrong in your system.  If you show the crash message,
we might be able to tell more.

> Some code use it while some do not. The timer code in arch/mips/kernel/time.c uses it in ll_timer_interrupt. Some ports call this function directly in their interrupt handlers.

Those ll_timer_xxx functions are alternative routes (fast ones) to
do_IRQ(), and therefore it needs to protect itself by calling
irq_enter()/irq_exit().

Jun

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: do_IRQ query
@ 2003-06-12 22:15 Ranjan Parthasarathy
  2003-06-12 22:15 ` Ranjan Parthasarathy
  0 siblings, 1 reply; 5+ messages in thread
From: Ranjan Parthasarathy @ 2003-06-12 22:15 UTC (permalink / raw)
  To: Jun Sun, Ranjan Parthasarathy; +Cc: linux-mips

Thank you for the information. I do not have a crash log at this minute. I will send something when I see the crashes again.

Ranjan

-----Original Message-----
From: Jun Sun [mailto:jsun@mvista.com]
Sent: Thursday, June 12, 2003 2:13 PM
To: Ranjan Parthasarathy
Cc: linux-mips@linux-mips.org; jsun@mvista.com
Subject: Re: do_IRQ query


On Thu, Jun 12, 2003 at 01:16:51PM -0700, Ranjan Parthasarathy wrote:
> Is it safe to call do_IRQ directly inside interrupt handlers without doing a irq_enter. I have seen ksoftirqd_CPUX crashes when I call the do_IRQ routines directly instead of the following sequence.
> 
> irq_enter()
> do_IRQ
> irq_exit()
>

This is not right.  irq_enter()/irq_exit() is already called in 
handle_IRQ_event(), which in turn is called by do_IRQ().  YOu 
don't need this yourself.  

The rest of do_IRQ() code is protected by closing interrupts.

Something must be wrong in your system.  If you show the crash message,
we might be able to tell more.

> Some code use it while some do not. The timer code in arch/mips/kernel/time.c uses it in ll_timer_interrupt. Some ports call this function directly in their interrupt handlers.

Those ll_timer_xxx functions are alternative routes (fast ones) to
do_IRQ(), and therefore it needs to protect itself by calling
irq_enter()/irq_exit().

Jun

^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: do_IRQ query
  2003-06-12 22:15 Ranjan Parthasarathy
@ 2003-06-12 22:15 ` Ranjan Parthasarathy
  0 siblings, 0 replies; 5+ messages in thread
From: Ranjan Parthasarathy @ 2003-06-12 22:15 UTC (permalink / raw)
  To: Jun Sun, Ranjan Parthasarathy; +Cc: linux-mips

Thank you for the information. I do not have a crash log at this minute. I will send something when I see the crashes again.

Ranjan

-----Original Message-----
From: Jun Sun [mailto:jsun@mvista.com]
Sent: Thursday, June 12, 2003 2:13 PM
To: Ranjan Parthasarathy
Cc: linux-mips@linux-mips.org; jsun@mvista.com
Subject: Re: do_IRQ query


On Thu, Jun 12, 2003 at 01:16:51PM -0700, Ranjan Parthasarathy wrote:
> Is it safe to call do_IRQ directly inside interrupt handlers without doing a irq_enter. I have seen ksoftirqd_CPUX crashes when I call the do_IRQ routines directly instead of the following sequence.
> 
> irq_enter()
> do_IRQ
> irq_exit()
>

This is not right.  irq_enter()/irq_exit() is already called in 
handle_IRQ_event(), which in turn is called by do_IRQ().  YOu 
don't need this yourself.  

The rest of do_IRQ() code is protected by closing interrupts.

Something must be wrong in your system.  If you show the crash message,
we might be able to tell more.

> Some code use it while some do not. The timer code in arch/mips/kernel/time.c uses it in ll_timer_interrupt. Some ports call this function directly in their interrupt handlers.

Those ll_timer_xxx functions are alternative routes (fast ones) to
do_IRQ(), and therefore it needs to protect itself by calling
irq_enter()/irq_exit().

Jun

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-06-12 22:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-06-12 20:16 do_IRQ query Ranjan Parthasarathy
2003-06-12 20:16 ` Ranjan Parthasarathy
2003-06-12 21:12 ` Jun Sun
  -- strict thread matches above, loose matches on Subject: below --
2003-06-12 22:15 Ranjan Parthasarathy
2003-06-12 22:15 ` Ranjan Parthasarathy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox