public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [announce, patch, RFC] "big IRQ lock" removal, IRQ cleanups.
@ 2002-07-22 14:45 Oleg Nesterov
  2002-07-22 14:58 ` [patch] big IRQ lock removal, 2.5.27-D9 Ingo Molnar
  2002-07-22 18:03 ` [announce, patch, RFC] "big IRQ lock" removal, IRQ cleanups george anzinger
  0 siblings, 2 replies; 7+ messages in thread
From: Oleg Nesterov @ 2002-07-22 14:45 UTC (permalink / raw)
  To: linux-kernel; +Cc: Ingo Molnar, george anzinger

Hello.

> > [...] To do this from irq.c means that it must exit with interrupts off
> > and the the low level code needs to keep them off till the irtn. [...]

> yes, we are very careful to keep irqs disabled in do_IRQ(), both before
> and after calling the handler.

Note that smp_xxx_interrupt() functions must be carefull
with preemt_{disable,enable} brackets.

For example, smp_invalidate_interrupt() may be preempted
after put_cpu(). Probably not big deal (it is return path),
but it is better to use preempt_enable_no_resched() here -
let ret_from_intr: do its job.

smp_{error,spurious,thermal}_interrupt() - all of them
use printk() without bumping preemt_count and have problem
after spin_unlock_irqrestore(&logbuf_lock, flags).

If these problems worth fixing, then preempt_stop (cli)
can be killed in entry.S:ret_from_intr(), yes? If i understand
correctly none of the irq handlers should return to low level
code with irq enabled.

P.S.

May I suggest somebody with good english fix
Documentation/preempt-locking.txt?
It states, that disabled interrupts prevents preemption.
Yes, but only in a sense, that the delivery of reschedule
interrupt is suppressed.

Process with irqs disabled and current->preempt_count == 0 can
be preempted (with interrupts enabled) after spin_lock/unlock etc.
Even in UP case preemption can happen while calling wake_up_...().

Oleg.

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

end of thread, other threads:[~2002-07-23  9:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-07-22 14:45 [announce, patch, RFC] "big IRQ lock" removal, IRQ cleanups Oleg Nesterov
2002-07-22 14:58 ` [patch] big IRQ lock removal, 2.5.27-D9 Ingo Molnar
2002-07-22 17:25   ` Oleg Nesterov
2002-07-22 21:19   ` Oleg Nesterov
2002-07-23  9:18     ` Ingo Molnar
2002-07-22 18:03 ` [announce, patch, RFC] "big IRQ lock" removal, IRQ cleanups george anzinger
2002-07-22 18:04   ` Ingo Molnar

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