On Sun, Apr 19, 2020 at 10:46:28PM +0200, Mark Kettenis wrote:
> > Date: Sun, 19 Apr 2020 22:24:31 +0200
> > From: Stefan Sperling <s...@stsp.name>
> > 
> > We really should be documenting supported wifi chipsets to help users
> > find devices that will work with OpenBSD.
> > The bwfm(4) man page leaves such questions entirely open at present.
> > 
> > The diff below intends to fill that gap by adding table which lists
> > supported devices. The table includes chipset name, supported bands,
> > MIMO config, and bus attachments.
> > 
> > I have cross-checked data in my table with internet searches. Sometimes
> > I found official product sheets, but some info is based on tech press
> > articles, copies of wikidevi pages, or gleaned from kernel messages
> > posted on forums. It should be mostly accurate and much better than
> > no info at all.
> > 
> > Note that some chips support bus attachments which bwfm does not
> > recognize. I have documented the bus attachments which the driver
> > actually supports, which is a subset of what the chipsets support.
> > This list will need to be kept in sync anyway whenever device support
> > in the driver is improved.
> > 
> > While here, also document the hex product IDs in bwfm's sdmmc attachment
> > driver in source code comments. These hex numbers actually correspond
> > to decimal chipset numbers but that is not immediately obvious so I think
> > adding comments is warranted (of course it would be better to use macros,
> > but I'm not going to go that far in a documentation patch).
> > 
> > ok?
> 
> I like the comments documenting the product IDs.  Don't think there is
> much value here in adding #defines actually.
> 
> As for the man page, can you use "SDIO" instead of "SDMMC"?  That is
> techically more correct and avoids the ugliness of leaving out the
> slash in "SD/MMC".

Sure. I agree that SDIO is way more accurate.

The SYNOPSIS section of the page says the driver will attach at 'sdmmc?'
which is why I used that term. But I guess people will make the mental leap.

diff 5c72fbec79072d838dd652f6d7785e8d2b15dab2 /usr/src
blob - f1df893ec80181f14a37bbc8703739bbca13e316
file + share/man/man4/bwfm.4
--- share/man/man4/bwfm.4
+++ share/man/man4/bwfm.4
@@ -30,6 +30,36 @@ The
 driver provides support for Broadcom and Cypress FullMAC network
 adapters.
 .Pp
+The following table summarizes supported chipsets and their capabilites,
+as well as the bus attachments recognized by the
+.Nm
+driver:
+.Bl -column "Chipset" "Spectrum" "MIMO" "Bus" -offset 6n
+.It Em Chipset Ta Em Spectrum Ta Em MIMO Ta Em Bus
+.It BCM43143 Ta 2GHz Ta 1x1 Ta SDIO/USB
+.It BCM43236 Ta 2GHz/5GHz Ta 2x2 Ta USB
+.It BCM4324 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM43242 Ta 2GHz/5GHz Ta 2x2 Ta USB
+.It BCM4329 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM4330 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM4334 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM43340 Ta 2GHz/5GHz Ta 1x1 Ta SDIO
+.It BCM43341 Ta 2GHz/5GHz Ta 1x1 Ta SDIO
+.It BCM4335 Ta  2GHz/5GHz Ta 1x1 Ta SDIO
+.It BCM43362 Ta 2GHz Ta 1x1 Ta SDIO
+.It BCM43364 Ta 2GHz Ta 1x1 Ta SDIO
+.It BCM4339 Ta  2GHz/5GHz Ta 1x1 Ta SDIO
+.It BCM43430 Ta 2GHz Ta 1x1 Ta SDIO
+.It BCM43455 Ta  2GHz/5GHz Ta 1x1 Ta SDIO
+.It BCM43456 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM4350 Ta 2GHz/5GHz Ta 2x2 Ta PCI
+.It BCM4354 Ta  2GHz/5GHz Ta 2x2 Ta SDIO
+.It BCM4356 Ta 2GHz/5GHz Ta 2x2 Ta PCI/SDIO
+.It BCM43569 Ta 2GHz/5GHz Ta 2x2 Ta USB
+.It BCM43602 Ta 2GHz/5GHz Ta 3x3 Ta PCI
+.It BCM4371 Ta 2GHz/5GHz Ta 2x2 Ta PCI
+.El
+.Pp
 These are the modes the
 .Nm
 driver can operate in:
blob - b053ab936ef10b21834ed74640124d8abe761af2
file + sys/dev/sdmmc/if_bwfm_sdio.c
--- sys/dev/sdmmc/if_bwfm_sdio.c
+++ sys/dev/sdmmc/if_bwfm_sdio.c
@@ -222,12 +222,12 @@ bwfm_sdio_match(struct device *parent, void *match, vo
        case 0x4345:
        case 0x4354:
        case 0x4356:
-       case 0xa887:
-       case 0xa94c:
-       case 0xa94d:
-       case 0xa962:
-       case 0xa9a6:
-       case 0xa9bf:
+       case 0xa887:    /* BCM43143 */
+       case 0xa94c:    /* BCM43340 */
+       case 0xa94d:    /* BCM43341 */
+       case 0xa962:    /* BCM43362 */
+       case 0xa9a6:    /* BCM43430 */
+       case 0xa9bf:    /* BCM43364 */
                break;
        default:
                return 0;


Reply via email to