Re: NE2000 PCI problems FIXED!

Linus Torvalds (torvalds@transmeta.com)
Thu, 21 May 1998 11:17:53 -0700 (PDT)


On Thu, 21 May 1998, Richard B. Johnson wrote:
>
> Current 2.1.102 NE*0000 driver under SMP has this problem, causing
> an Opps upon startup.

It's not an SMP problem, it's a ne2000 driver problem.

The stupid driver initializes the "dev->priv" field _after_ allocating the
interrupt, and if you happen to get an interrupt at the wrong place, the
interrupt routine will crash when it uses dev->priv.

This can happen on UP as well as on SMP, the only reason it probably
happens on SMP is probably just that we use a different interrupt
controller and there may be a pending interrupt that would not have been
there with the old XT-PIC. That does not make it less of a ne2000 bug (for
example, imagine that the irq is shared with some other device, and that
other device might be active at the same time..)

The fix may be as simple as doing the ethdev_init(dev) before allocating
the interrupt.

In short, it's a crap driver,

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu