Date: Fri, 19 Jan 2018 22:43:08 +0000 (UTC) From: "Landon J. Fuller" <landonf@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r328183 - in head: share/man/man9 sys/dev/bhnd sys/dev/bwn Message-ID: <201801192243.w0JMh80V052287@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: landonf Date: Fri Jan 19 22:43:08 2018 New Revision: 328183 URL: https://svnweb.freebsd.org/changeset/base/328183 Log: bhnd/bwn(4): Define a bhnd(4) softmodem device class for the v.90 modem codec core, and mark the core as unpopulated on all BCM4306 bwn(4) devices. Sponsored by: The FreeBSD Foundation Modified: head/share/man/man9/bhnd.9 head/sys/dev/bhnd/bhnd_ids.h head/sys/dev/bhnd/bhnd_subr.c head/sys/dev/bhnd/bhnd_types.h head/sys/dev/bwn/if_bwn_pci.c head/sys/dev/bwn/if_bwn_pcivar.h Modified: head/share/man/man9/bhnd.9 ============================================================================== --- head/share/man/man9/bhnd.9 Fri Jan 19 22:37:48 2018 (r328182) +++ head/share/man/man9/bhnd.9 Fri Jan 19 22:43:08 2018 (r328183) @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 9, 2017 +.Dd January 19, 2018 .Dt BHND 9 .Os .Sh NAME @@ -1217,6 +1217,8 @@ Interconnect Host Bridge Device Enumeration ROM .It Dv BHND_DEVCLASS_NVRAM NVRAM/Flash Controller +.It Dv BHND_DEVCLASS_SOFTMODEM +Analog/PSTN SoftModem Codec .It Dv BHND_DEVCLASS_USB_HOST USB Host Controller .It Dv BHND_DEVCLASS_USB_DEV Modified: head/sys/dev/bhnd/bhnd_ids.h ============================================================================== --- head/sys/dev/bhnd/bhnd_ids.h Fri Jan 19 22:37:48 2018 (r328182) +++ head/sys/dev/bhnd/bhnd_ids.h Fri Jan 19 22:43:08 2018 (r328183) @@ -444,7 +444,7 @@ #define BHND_COREID_PCI 0x804 /* pci core */ #define BHND_COREID_MIPS 0x805 /* mips core */ #define BHND_COREID_ENET 0x806 /* enet mac core */ -#define BHND_COREID_CODEC 0x807 /* v90 codec core */ +#define BHND_COREID_V90_CODEC 0x807 /* v90 codec core */ #define BHND_COREID_USB 0x808 /* usb 1.1 host/device core */ #define BHND_COREID_ADSL 0x809 /* ADSL core */ #define BHND_COREID_ILINE100 0x80a /* iline100 core */ Modified: head/sys/dev/bhnd/bhnd_subr.c ============================================================================== --- head/sys/dev/bhnd/bhnd_subr.c Fri Jan 19 22:37:48 2018 (r328182) +++ head/sys/dev/bhnd/bhnd_subr.c Fri Jan 19 22:43:08 2018 (r328183) @@ -85,7 +85,7 @@ static const struct bhnd_core_desc { BHND_CDESC(BCM, PCI, PCI, "PCI Bridge"), BHND_CDESC(BCM, MIPS, CPU, "BMIPS CPU"), BHND_CDESC(BCM, ENET, ENET_MAC, "Fast Ethernet MAC"), - BHND_CDESC(BCM, CODEC, OTHER, "V.90 Modem Codec"), + BHND_CDESC(BCM, V90_CODEC, SOFTMODEM, "V.90 SoftModem Codec"), BHND_CDESC(BCM, USB, USB_DUAL, "USB 1.1 Device/Host Controller"), BHND_CDESC(BCM, ADSL, OTHER, "ADSL Core"), BHND_CDESC(BCM, ILINE100, OTHER, "iLine100 HPNA"), Modified: head/sys/dev/bhnd/bhnd_types.h ============================================================================== --- head/sys/dev/bhnd/bhnd_types.h Fri Jan 19 22:37:48 2018 (r328182) +++ head/sys/dev/bhnd/bhnd_types.h Fri Jan 19 22:43:08 2018 (r328183) @@ -66,6 +66,7 @@ typedef enum { BHND_DEVCLASS_USB_HOST, /**< USB host controller */ BHND_DEVCLASS_USB_DEV, /**< USB device controller */ BHND_DEVCLASS_USB_DUAL, /**< USB host/device controller */ + BHND_DEVCLASS_SOFTMODEM, /**< analog/PSTN softmodem codec */ BHND_DEVCLASS_OTHER = 1000, /**< other / unknown */ BHND_DEVCLASS_INVALID /**< no/invalid class */ Modified: head/sys/dev/bwn/if_bwn_pci.c ============================================================================== --- head/sys/dev/bwn/if_bwn_pci.c Fri Jan 19 22:37:48 2018 (r328182) +++ head/sys/dev/bwn/if_bwn_pci.c Fri Jan 19 22:43:08 2018 (r328183) @@ -61,10 +61,13 @@ TUNABLE_INT("hw.bwn_pci.preferred", &prefer_new_driver /* SIBA Devices */ static const struct bwn_pci_device siba_devices[] = { BWN_BCM_DEV(BCM4306_D11A, "BCM4306 802.11a", - BWN_QUIRK_WLAN_DUALCORE), - BWN_BCM_DEV(BCM4306_D11G, "BCM4306 802.11b/g", 0), - BWN_BCM_DEV(BCM4306_D11G_ID2, "BCM4306 802.11b/g", 0), - BWN_BCM_DEV(BCM4306_D11DUAL, "BCM4306 802.11a/b/g", 0), + BWN_QUIRK_WLAN_DUALCORE|BWN_QUIRK_SOFTMODEM_UNPOPULATED), + BWN_BCM_DEV(BCM4306_D11G, "BCM4306 802.11b/g", + BWN_QUIRK_SOFTMODEM_UNPOPULATED), + BWN_BCM_DEV(BCM4306_D11G_ID2, "BCM4306 802.11b/g", + BWN_QUIRK_SOFTMODEM_UNPOPULATED), + BWN_BCM_DEV(BCM4306_D11DUAL, "BCM4306 802.11a/b/g", + BWN_QUIRK_SOFTMODEM_UNPOPULATED), BWN_BCM_DEV(BCM4307, "BCM4307 802.11b", 0), BWN_BCM_DEV(BCM4311_D11G, "BCM4311 802.11b/g", 0), @@ -268,6 +271,9 @@ bwn_pci_is_core_disabled(device_t dev, device_t child, case BHND_DEVCLASS_USB_HOST: return ((sc->quirks & BWN_QUIRK_USBH_UNPOPULATED) != 0); + + case BHND_DEVCLASS_SOFTMODEM: + return ((sc->quirks & BWN_QUIRK_SOFTMODEM_UNPOPULATED) != 0); default: return (false); Modified: head/sys/dev/bwn/if_bwn_pcivar.h ============================================================================== --- head/sys/dev/bwn/if_bwn_pcivar.h Fri Jan 19 22:37:48 2018 (r328182) +++ head/sys/dev/bwn/if_bwn_pcivar.h Fri Jan 19 22:43:08 2018 (r328183) @@ -74,6 +74,13 @@ enum { * unpopulated. */ BWN_QUIRK_USBH_UNPOPULATED = 1<<3, + + /** + * Some early devices (including all BCM4306 chipsets) shipped with + * floating analog softmodem codec cores; set this quirk to treat these + * cores as unpopulated. + */ + BWN_QUIRK_SOFTMODEM_UNPOPULATED = 1<<4, }; /* PCI device descriptor */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201801192243.w0JMh80V052287>