Re: [PATCH 3/4] dt-bindings: bus: add brcm,bcm6362-wlan
From: Alessio Ferri
Date: Tue Jun 02 2026 - 18:24:45 EST
Il 30/05/2026 13:50, Krzysztof Kozlowski ha scritto:
> On Fri, May 29, 2026 at 02:06:01AM +0200, Alessio Ferri wrote:
>> Document the binding for the SHIM bridge that gates the on-chip
>> 2.4 GHz WLAN block of the Broadcom BCM6362 SoC. The bridge owns the
>> SHIM peephole, a single clock for the macro, and two resets (the
>> SHIM macro itself and its ubus side). It is also a bus: it carries
>> one brcm,bus-axi child describing the bcma backplane behind the
>> SHIM, with a standard interrupt-map routing the d11 core's IRQ to
>> the SoC interrupt controller.
>>
>> Assisted-by: Claude:claude-4.8-opus
>> Signed-off-by: Alessio Ferri <alessio.ferri@xxxxxxxxxxx>
>> ---
>> .../devicetree/bindings/bus/brcm,bcm6362-wlan.yaml | 106 +++++++++++++++++++++
>> 1 file changed, 106 insertions(+)
>>
>> diff --git a/Documentation/devicetree/bindings/bus/brcm,bcm6362-wlan.yaml b/Documentation/devicetree/bindings/bus/brcm,bcm6362-wlan.yaml
>> new file mode 100644
>> index 000000000000..c8d49ccdd2c1
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/bus/brcm,bcm6362-wlan.yaml
>> @@ -0,0 +1,106 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/bus/brcm,bcm6362-wlan.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: Broadcom BCM6362 on-chip WLAN SHIM bridge
>> +
>> +maintainers:
>> + - Alessio Ferri <alessio.ferri@xxxxxxxxxxx>
>> +
>> +description: |
>> + The BCM6362 SoC integrates a 2.4 GHz Broadcom WLAN block whose
>> + register backplane uses the Broadcom AMBA (bcma) architecture. The
>> + backplane is gated by a small SHIM bridge that holds the WLAN macro
>> + in reset and disables its clocks until released by software. CFE
>> + does not release this block, so software bring-up is required
>> + before bcma can enumerate the backplane.
>> +
>> + This binding describes the SHIM bridge node. The SHIM driver brings
>
> Do not describe binding. Do not describe driver.
> Describe hardware.
>
>> + the macro up and then populates the brcm,bus-axi child node, which
>> + describes the bcma backplane behind the SHIM and is bound by the
>> + bcma-host-soc driver. The SoC-specific configuration (big-endian
>> + accessors, SHIM-attached topology, SHIM Control register peephole
>> + pointer) is delivered to bcma via platform_data injected at
>> + populate time, so the brcm,bus-axi child stays SoC-agnostic.
>
> How is it relevant?
>
>> +
>> +properties:
>> + compatible:
>> + const: brcm,bcm6362-wlan
>> +
>> + reg:
>> + maxItems: 1
>> + description: SHIM peephole registers.
>
> What is SHIM?
>
>> +
>> + reg-names:
>> + items:
>> + - const: shim
>> +
>> + clocks:
>> + maxItems: 1
>> +
>> + resets:
>> + items:
>> + - description: SHIM macro reset
>> + - description: SHIM ubus reset
>> +
>> + reset-names:
>> + items:
>> + - const: shim
>> + - const: shim-ubus
>> +
>> + '#address-cells':
>> + const: 1
>> +
>> + '#size-cells':
>> + const: 1
>> +
>> + ranges: true
>> +
>> +patternProperties:
>> + "^axi@[0-9a-f]+$":
>
> Use consistent quotes.
>
>> + type: object
>> + description: The bcma AXI backplane behind the SHIM.
>> + $ref: /schemas/types.yaml#
>
> Need proper ref. You could easily check instead of sending Claude slop -
> is there any binding with above syntax?
>
> You don't get subnodes for buses for devices not being the actual
> buses.
>
> Best regards,
> Krzysztof
>
Sorry for letting AI-slop pass through in this patch and excessive
descriptions.
SHIM is just the control block for the integrated wlan. Copied verbatim
from the original broadcom 96362 code.
For the last sentence, how should i map it? At the very least I need to
tell bcma that this is big-endian before it touches anything, otherwise
it will read/write garbage or even cause a panic. If necessary i can
pick up the quirks after reading the chip-id from the bus, skipping the
new driver and the new bindings.