Re: Strange interrupt behaviour

MOLNAR Ingo (mingo@valerie.inf.elte.hu)
Wed, 15 Jul 1998 03:41:43 +0200 (MET DST)


On Wed, 15 Jul 1998, Andrea Arcangeli wrote:

> On Mon, 13 Jul 1998, Linus Torvalds wrote:
>
> >Oh, having separate interrupt stacks _works_, and on some architectures it
>
> I hacked irq.c and now seems to work on Linux too ;-).

:) you have to make it NR_CPUS indexed too for SMP though ...

also, your kernel apparently never sends signals to current-> (say FPU
stuff or terminal stuff), it would die a quick and horrible death due to
the missing 'struct task_struct' at the end of the IRQ stack.

> I am writing this with the patch applyed ;-).
>
> I am not sure if this is really what I want (I am just very happy that the
> kernel doesn' t crash though ;-). I want that every irq handler have a
> page of ram to use. I want to avoid that 16 nested interrupt could run
> all on the same 8kbyte kernel stack.

nice hack. If the 'current' issue is solved, this also enables us to
(cringe!) schedule IRQs between each other. (to resolve deadlocks on SMP
...)

one problem though could be cacheline-coloring, say we kick out cachelines
on a 2-ways associative caches. (because instead of stacking and filling
up the L1 cache linearly, IRQ stacks collide with each other and process's
stacks on 4K boundaries. Probably a minor issue on 4-ways associative 16k
L1 caches, but an issue on 2-ways associative 8k pentium L1 caches.)

-- mingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html