Subject: Re: LAN adapter driver
To: Christian Groessler <cpg@aladdin.de>
From: Marcus Comstedt <marcus@mc.pp.se>
List: port-dreamcast
Date: 06/10/2002 23:46:39
Christian Groessler <cpg@aladdin.de> writes:

> > implementation.  Also, you should check if the LAN adapter doesn't use
> > the same PCI bridge chip (the GAPSPCI) as the BBA, in that case you
> 
> How can I do this? Can I detect GAPSPCI's presence?

The gapspci driver will autodetect it if connected to the G2 bus.  You
should see it in your dmesg.  (Of course, it could be a different
version of the glue chip that does not match the autodetection.)

> 
> > can use that driver too, and use an existing PCI driver for the
> > ethernet chip.
> 
> I haven't found an existing NetBSD PCI driver using this chip
> (mb86960.c).

Hm.  You are right.  There are only PCMCIA drivers for it.  I wonder
if that means that the LAN adapter has a PCMCIA bridge chip instead?
You wouldn't mind opening it up to check what interface logic it uses?

Anyway, the correct driver layering is the following:

  chip specific driver      =  mb86960.c
  interface specific driver =  if_mbe_pcmcia.c / something else
                                                 depending on actual interface
  glue chip driver          =  gapspci.c / something else depending on
                                           actual glue chip used
  peripheral bus driver     =  g2bus.c
  CPU bus driver            =  shb.c

All layers should be present.  In particular, it is not allowed to
bypass the g2bus.c driver for devices connected via the G2 bus.


  // Marcus