#
18250ec6 |
| 06-Dec-2024 |
John Baldwin <jhb@FreeBSD.org> |
Replace calls to bus_generic_attach with bus_attach_children
Reviewed by: imp Differential Revision: https://reviews.freebsd.org/D47675
|
Revision tags: release/14.2.0, release/13.4.0, release/14.1.0, release/13.3.0, release/14.0.0 |
|
#
685dc743 |
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
Revision tags: release/13.2.0, release/12.4.0, release/13.1.0, release/12.3.0, release/13.0.0, release/12.2.0 |
|
#
ab3fad6e |
| 01-Sep-2020 |
Mateusz Guzik <mjg@FreeBSD.org> |
bhnd: clean up empty lines in .c and .h files
|
Revision tags: release/11.4.0, release/12.1.0, release/11.3.0, release/12.0.0, release/11.2.0 |
|
#
f3524ec8 |
| 29-Mar-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): include a subset of the ChipCommon capability flags in bhnd_chipid; this provides early access to device capability flags required by bhnd(4) bus and bhndb(4) bridge drivers.
|
#
711221ef |
| 19-Jan-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhndb_pci(4): Implement bridge support for CardBus-attached devices.
- Extend the probe method to accept devclasses that inherit from the pci devclass (e.g. cardbus). - Some BCM4306-based CardB
bhndb_pci(4): Implement bridge support for CardBus-attached devices.
- Extend the probe method to accept devclasses that inherit from the pci devclass (e.g. cardbus). - Some BCM4306-based CardBus adapters appear to advertise 4K SPROM, but only the first 2K is mapped into BAR0. We can safely assume that the SPROM data fits within the first 2K of the SPROM, rather than rejecting the SPROM mapping as invalid.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
84d6a5d4 |
| 17-Jan-2018 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhndb_pci(4): fix incorrect BHND_PCI_SRSH_PI workaround
On a SPROM-less device, the PCI(e) bridge core will be initialized with its power-on-reset defaults; this can leave the SPROM-derived BHND_PCI
bhndb_pci(4): fix incorrect BHND_PCI_SRSH_PI workaround
On a SPROM-less device, the PCI(e) bridge core will be initialized with its power-on-reset defaults; this can leave the SPROM-derived BHND_PCI_SRSH_PI value pointing to the wrong backplane address. This value is used by the PCI core when performing address translation between the static register windows in BAR0 that map the PCI core's register block, and backplane address space.
Previously, bhndb_pci(4) incorrectly used the potentially invalid static BAR0 PCI register windows when attempting to correct the BHND_PCI_SRSH_PI value in the PCI core's SPROM shadow.
Instead, we now read/update BHND_PCI_SRSH_PI by fetching the PCI core's backplane address from the core enumeration table, and then using a dynamic register window to explicitly map the PCI core's register block into BAR0.
Sponsored by: The FreeBSD Foundation
show more ...
|
#
6467a17b |
| 15-Dec-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4)/bwn(4): Fix a number of small issues reported by Coverity.
- Fix reference of uninitialized error value in bhndb_generic_resume() if the dynamic window count is 0.
- Fix incorrect bhnd_pm
bhnd(4)/bwn(4): Fix a number of small issues reported by Coverity.
- Fix reference of uninitialized error value in bhndb_generic_resume() if the dynamic window count is 0.
- Fix incorrect bhnd_pmu(4) UPTME_MASK and PLL0_PC2_WILD_INT_MASK constants.
- Variable definitions referenced by our generated SPROM layouts will never be NULL, but add explicit asserts to make that clear.
- Add missing variable initialization in bhnd_nvram_sprom_ident().
- Fix leak of driver array in bhnd_erom_probe_driver_classes().
- Fix zero-length memset() in bhndb_pci_eio_init().
- Fix an off-by-one error and potential invalid OOBSEL bit shift operation in bcma_dinfo_init_intrs().
- Remove dead code in siba_suspend_hw().
- Fix duplicate call to bhnd_pmu_enable_regulator() in both the enable and disable code paths of bhnd_compat_cc_pmu_set_ldoparef().
Reported by: Coverity CIDs: 1355194, 1362020, 1362022, 1373114, 1366563, 1373115, 1381569, 1381579, 1383555, 1383566, 1383571 Sponsored by: The FreeBSD Foundation
show more ...
|
#
566ca880 |
| 14-Dec-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): Include board_devid in the bhnd_board_info structure, and populate the expected default board_vendor value on MIPS SoCs.
This is required by bwn(4) to differentiate between single-band and
bhnd(4): Include board_devid in the bhnd_board_info structure, and populate the expected default board_vendor value on MIPS SoCs.
This is required by bwn(4) to differentiate between single-band and dual-band device variants that otherwise share a common chip ID.
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation
show more ...
|
#
d16875a8 |
| 02-Dec-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhndb(4): Fix leak of child devices and MSI vectors.
- Add missing call to device_delete_children() in bhndb_detach(), without which we're left with stale child devices on module unload. - Pass th
bhndb(4): Fix leak of child devices and MSI vectors.
- Add missing call to device_delete_children() in bhndb_detach(), without which we're left with stale child devices on module unload. - Pass the parent PCI device to pci_release_msi(), not the bhndb_pci(4) child.
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation
show more ...
|
#
eaa5fb4b |
| 28-Nov-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhndb(4): Implement bridge support for the BCM4312 and other PCI_V0 chipsets.
Very early (PCI_V0) Broadcom PCI Wi-Fi chipsets have a few quirks when compared to later PCI(e) core revisions:
- The s
bhndb(4): Implement bridge support for the BCM4312 and other PCI_V0 chipsets.
Very early (PCI_V0) Broadcom PCI Wi-Fi chipsets have a few quirks when compared to later PCI(e) core revisions:
- The standard static BAR0 mapping of the PCI core registers is discontiguous, with siba's cfg0 register block mapped distinctly from the other core registers. - No dedicated ChipCommon register mapping is provided; instead, the single configurable register window must be used to access both ChipCommon and D11 core registers. The D11 core's operational semantics guarantee the safety of -- after disabling interrupts -- borrowing the single dynamic register window to perform the few ChipCommon operations required by a driver.
To support these early PCI devices:
- Allow defining multiple discontiguous BHNDB_REGWIN_T_CORE register windows that map a single port/region, and producing bridged resource allocations backed by those discontiguous windows. - Support stealing existing register window allocations to fulfill indirect bhnd(4) bus I/O requests within address ranges tagged with BHNDB_ALLOC_FULFILL_ON_OVERCOMMIT. - Fix an inverted test of bhndb_is_pcie_attached() that disabled PCI-only clock bring-up required by these devices.
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation
show more ...
|
#
82725ba9 |
| 23-Nov-2017 |
Hans Petter Selasky <hselasky@FreeBSD.org> |
Merge ^/head r325999 through r326131.
|
#
4e96bf3a |
| 22-Nov-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): extend the PMU APIs to support bwn(4)
The bwn(4) driver requires a number of extensions to the bhnd(4) PMU interface to support external configuration of PLLs, LDOs, and other parameters th
bhnd(4): extend the PMU APIs to support bwn(4)
The bwn(4) driver requires a number of extensions to the bhnd(4) PMU interface to support external configuration of PLLs, LDOs, and other parameters that require chipset or PHY-specific workarounds.
These changes add support for:
- Writing raw voltage register values to PHY-specific LDO regulator registers (required by LP-PHY). - Enabling/disabling PHY-specific LDOs (required by LP-PHY) - Writing to arbitrary PMU chipctrl registers (required for common PHY PLL reset support). - Requesting chipset/PLL-specific spurious signal avoidance modes. - Querying clock frequency and latency.
Additionally, rather than updating legacy PWRCTL support to conform to the new PMU interface:
- PWRCTL API is now provided by a bhnd_pwrctl_if.m interface. - Since PWRCTL is only found in older SSB-based chipsets, translation from bhnd(4) bus APIs to corresponding PWRCTL operations is now handled entirely within the siba(4) driver. - The PWRCTL-specific host bridge clock gating APIs in bhnd_bus_if.m have been lifted out into a standalone bhnd_pwrctl_hostb_if.m interface.
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D12664
show more ...
|
#
9ed45324 |
| 22-Nov-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): Add support for querying DMA address translation parameters
BHND Wi-Fi chipsets and SoCs share a common DMA engine, operating within backplane address space. To support host DMA on Wi-Fi ch
bhnd(4): Add support for querying DMA address translation parameters
BHND Wi-Fi chipsets and SoCs share a common DMA engine, operating within backplane address space. To support host DMA on Wi-Fi chipsets, the bridge core maps host address space onto the backplane; any host addresses must be translated to their corresponding backplane address.
- Defines a new bhnd_get_dma_translation(9) API to support querying DMA address translation parameters from the bhnd(4) bus. - Extends bhndb(4) to provide DMA translation descriptors from a DMA address translation table defined in the host bridge-specific bhndb_hwcfg. - Defines bhndb(4) DMA address translation tables for all supported host bridge cores. - Extends mips/broadcom's bhnd_nexus driver to return an identity (no-op) DMA translation descriptor; no translation is required when addressing the SoC backplane.
Approved by: adrian (mentor) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D12582
show more ...
|
#
caeff9a3 |
| 22-Nov-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): implement MIPS and PCI(e) interrupt support
On BHND MIPS SoCs, this replaces the use of hard-coded MIPS IRQ#s in the common bhnd(4) core drivers; we now register an INTRNG child PIC that ha
bhnd(4): implement MIPS and PCI(e) interrupt support
On BHND MIPS SoCs, this replaces the use of hard-coded MIPS IRQ#s in the common bhnd(4) core drivers; we now register an INTRNG child PIC that handles routing of backplane interrupt vectors via the MIPS core.
On BHND PCI devices, backplane interrupt vectors are now routed to the PCI/PCIe host bridge core when bus_setup_intr() is called, where they are dispatched by the PCI core via a host interrupt (e.g. INTx/MSI).
The bhndb(4) bridge driver tracks registered interrupt handlers for the bridged bhnd(4) devices and manages backplane interrupt routing, while delegating actual bus interrupt setup/teardown to the parent bus on behalf of the bridged cores.
Approved by: adrian (mentor, implicit) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D12518
show more ...
|
#
c2c014f2 |
| 07-Nov-2017 |
Hans Petter Selasky <hselasky@FreeBSD.org> |
Merge ^/head r323559 through r325504.
|
Revision tags: release/10.4.0 |
|
#
d2549a44 |
| 28-Sep-2017 |
Enji Cooper <ngie@FreeBSD.org> |
MFhead@r324075
|
#
89294a78 |
| 27-Sep-2017 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd: Add support for supplying bus I/O callbacks when initializing an EROM parser.
This allows us to use the EROM parser API in cases where the standard bus space I/O APIs are unsuitable. In partic
bhnd: Add support for supplying bus I/O callbacks when initializing an EROM parser.
This allows us to use the EROM parser API in cases where the standard bus space I/O APIs are unsuitable. In particular, this will allow us to parse the device enumeration table directly from bhndb(4) drivers, prior to full attach and configuration of the bridge.
Approved by: adrian (mentor) Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D12510
show more ...
|
Revision tags: release/11.1.0, release/11.0.1, release/11.0.0 |
|
#
d002f039 |
| 08-Sep-2016 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r305431 through r305622.
|
#
824b48ef |
| 06-Sep-2016 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): Implement backplane interrupt handling.
This adds bhnd(4) bus-level support for querying backplane interrupt vector routing, and delegating machine/bridge-specific interrupt handling to the
bhnd(4): Implement backplane interrupt handling.
This adds bhnd(4) bus-level support for querying backplane interrupt vector routing, and delegating machine/bridge-specific interrupt handling to the concrete bhnd(4) driver implementation.
On bhndb(4) bridged PCI devices, we provide the PCI/MSI interrupt directly to attached cores.
On MIPS devices, we report a backplane interrupt count of 0, effectively disabling the bus-level interrupt assignment. This allows mips/broadcom to temporarily continue using hard-coded MIPS IRQs until bhnd_mips PIC support is implemented.
Reviewed by: mizhka Approved by: adrian (mentor, implicit)
show more ...
|
#
3d6d3da4 |
| 04-Sep-2016 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r305361 through r305389.
|
#
111d7cb2 |
| 04-Sep-2016 |
Landon J. Fuller <landonf@FreeBSD.org> |
Migrate bhndb(4) to the new bhnd_erom API.
Adds support for probing and initializing bhndb(4) bridge state using the bhnd_erom API, ensuring that full bridge configuration is available *prior* to ac
Migrate bhndb(4) to the new bhnd_erom API.
Adds support for probing and initializing bhndb(4) bridge state using the bhnd_erom API, ensuring that full bridge configuration is available *prior* to actually attaching and enumerating the bhnd(4) child device, allowing us to safely allocate bus-level agent/device resources during bhnd(4) bus enumeration.
- Add a bhnd_erom_probe() method usable by bhndb(4). This is an analogue to the existing bhnd_erom_probe_static() method, and allows the bhndb bridge to discover the best available erom parser class prior to newbus probing of its children. - Add support for supplying identification hints when probing erom devices. This is required on early EXTIF-only chipsets, where chip identification registers are not available. - Migrate bhndb over to the new bhnd_erom API, using bhnd_core_info records rather than bridged bhnd(4) device_t references to determine the bridged chipsets' capability/bridge configuration. - The bhndb parent (e.g. if_bwn) is now required to supply a hardware priority table to the bridge. The default table is currently sufficient for our supported devices. - Drop the two-pass attach approach we used for compatibility with bhndb(4) in the bhnd(4) bus drivers, and instead perform bus enumeration immediately, and allocate bridged per-child bus-level resources during that enumeration.
Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D7768
show more ...
|
#
2f52412d |
| 29-Aug-2016 |
Enji Cooper <ngie@FreeBSD.org> |
MFhead @ r305013
|
#
491cdc1b |
| 27-Aug-2016 |
Dimitry Andric <dim@FreeBSD.org> |
Merge ^/head r304700 through r304884.
|
#
f90f4b65 |
| 27-Aug-2016 |
Landon J. Fuller <landonf@FreeBSD.org> |
bhnd(4): Initial PMU/PWRCTL power and clock management support.
- Added bhnd_pmu driver implementations for PMU and PWRCTL chipsets, derived from Broadcom's ISC-licensed HND code. - Added bhnd bu
bhnd(4): Initial PMU/PWRCTL power and clock management support.
- Added bhnd_pmu driver implementations for PMU and PWRCTL chipsets, derived from Broadcom's ISC-licensed HND code. - Added bhnd bus-level support for routing per-core clock and resource power requests to the PMU device. - Lift ChipCommon support out into the bhnd module, dropping bhnd_chipc.
Reviewed by: mizhka Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D7492
show more ...
|
#
8ef24a0d |
| 17-May-2016 |
Adrian Chadd <adrian@FreeBSD.org> |
[bhnd] Finish bhnd(4) PCI/PCIe-G1 hostb support.
Now that we've got access to SPROM and can access board identification, this implements all known remaining hardware work-arounds for the bhnd(4) PCI
[bhnd] Finish bhnd(4) PCI/PCIe-G1 hostb support.
Now that we've got access to SPROM and can access board identification, this implements all known remaining hardware work-arounds for the bhnd(4) PCI and PCIe-G1 cores operating endpoint mode.
Additionally, this adds an initial set of skeleton PCIe-G2 hostb and pcib drivers, required by fullmac and newer softmac devices.
Submitted by: Landon Fuller <landonf@landonf.org> Differential Revision: https://reviews.freebsd.org/D6377
show more ...
|