Subject: Re: Intel 82557 NIC device driver for MIP running older BSD
To: Martin Husemann <martin@duskware.de>
From: David Christensen <dchrist@dnai.com>
List: tech-net
Date: 09/16/2000 11:36:26
----- Original Message -----
From: "Martin Husemann" <martin@duskware.de>
To: "David Christensen" <dchrist@dnai.com>
Sent: Saturday, September 16, 2000 2:30 AM
Subject: Re: Intel 82557 NIC device driver for MIP running older BSD


> Hi!
>
> >    c. struct cfattach (#ifdef __NetBSD__ ?).
>
> This is a very simple trick to split the old one-struct-per-driver
> into two parts: one bus-specific (match/attach) and one driver
> specific (where all the real functions are called).
>
> We have truckloads of driver that can attach to say an ISA bus, an
> EISA bus and a PCMCIA bus. The driver part of the structs stays the
> same, but the match and attach functions are done in bus-specific
> "frontends".
>
> Makes perfect sense, if you think about it (you do know about the bus
> independend io/mem access framework used in the non-bus-specific part?
> If not read bus_space(9)).
>
>
> Martin

I suspected a change in the API/DDI since 4.4BSD, but didn't know why or
where to look for documentation.


Thanks for the help!  :-)


David Christensen
dchrist@dnai.com