Re: 2.4.12-ac4 10Mbit NE2k interrupt load kills p166

Samium Gromoff (_deepfire@mail.ru)
Mon, 10 Dec 2001 02:04:22 +0300 (MSK)


> What might be interesting would be to edit 8390.c and change
>
> /* Mask interrupts from the ethercard.
> SMP: We have to grab the lock here otherwise the IRQ handler
> on another CPU can flip window and race the IRQ mask set. We end
> up trashing the mcast filter not disabling irqs if we dont lock
> */
>
> spin_lock_irqsave(&ei_local->page_lock, flags);
> outb_p(0x00, e8390_base + EN0_IMR);
> spin_unlock_irqrestore(&ei_local->page_lock, flags);
>
> to use
>
> /* this is the missing spin_trylock_irqsave longhand.. */
> save_flags(flags);
> __cli();
> if(!spin_trylock(&ei_local->page_lock))
> {
> restore_flags(flags);
> return 1;
> }
> outb_p(0x00, e8390_base + EN0_IMR);
> spin_unlock_irqrestore(&ei_local->page_lock, flags);
building the kernel is in the progress, so i`ll report asap...

I`m so glad somebody still cares of the good ol` boxes :-)

regards, Samium Gromoff
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/