Subject: Re: BCM5715 not supported
To: Pavel Cahyna <pavel@netbsd.org>
From: None <jonathan@dsg.stanford.edu>
List: tech-kern
Date: 01/26/2007 14:55:49
In message <20070124181945.GA726@beta.martani.repy.czf>,
Pavel Cahyna writes:
>but if_bge.c contains only:
>
>	{ PCI_VENDOR_BROADCOM,
>	  PCI_PRODUCT_BROADCOM_BCM5714,
>	  "Broadcom BCM5714/5715 Gigabit Ethernet",
>	  },
>
>Should I just add the BCM5715, BCM5715S (and also 5714S)? And change the
>description of PCI_PRODUCT_BROADCOM_BCM5714 to just 
>"Broadcom BCM5714 Gigabit Ethernet"?

hi Pavel,

That's... odd, not to say disappointing.  The machine where I
developed the driver fork merged onto the NetBSD-3 branch was
committed via a bcm5715.

The bcm5714S and bcm5715S are different beasts and require support for
the integral TBI/SERDES hardware which, last I looked, no *BSD bge(4)
supports.  So I'd avoid adding entries for them to the table.

I've also privately promised Mark Davies that I'd look into adding (or
merging from my own tree) support for the bcm5754.

As part of adding support for those chips, I intend to remove most
uses of the bcm5705 "quirk" from if_bge.c.  While I am sure those uses
were well-intended, marking all post-5705 variants of the bge chip
family as having a BCM45705 "quirk" is not only incorrect, it makes it
impossible to use that BCM5705 "quirk" to support acutal 5705-specific
quirks.

So, I fully intend to replace all appropriate uses of the 5705 "quirk"
with the chip-family feature-test macros which I added to bge(4) for
that specific purpose --- just as they are used in the netbsd-3 branch
of the driver, and in my own tree, and (independently) by
brad@openbsd.org in OpenBSD's copy of if_bge.c.

I'm very open to more efficient implementation of those chip-family
feature-test macros (say, with an enum or new softc bitflag field,
instead of enumerating PCI-IDs).

I mention this as advance warning to whoever removed those macros, and
replaced them with (incorrect) tests on the 5705 "quirk".