Re: [PATCH v12 1/3] dt-bindings: perf: Add Broadcom Raspberry Pi AXI PMU definition

[email protected]
Newsgroups org.kernel.vger.linux-perf-users
Message-ID <[email protected]>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] The YAML schema fails to enforce generation-specific constraints for the `firmware` property, and the provided DT example contradicts the documentation.
--

--- Patch [1]: [PATCH v12 1/3] dt-bindings: perf: Add Broadcom Raspberry Pi AXI PMU definition ---
commit 758d3c70fc67aa6ef59b9abc25e70058474c3055
Author: Ian Rogers <[email protected]>

dt-bindings: perf: Add Broadcom Raspberry Pi AXI PMU definition

Add Device Tree bindings for the Broadcom AXI PMU hardware blocks present
in the Raspberry Pi SoC line (BCM2835, BCM2711, BCM2712).

> diff --git a/Documentation/devicetree/bindings/perf/brcm,bcm2835-axiperf.yaml b/Documentation/devicetree/bindings/perf/brcm,bcm2835-axiperf.yaml
> new file mode 100644
> index 0000000000000..8f8686f673377
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/perf/brcm,bcm2835-axiperf.yaml
[ ... ]
> +  firmware:
> +    $ref: /schemas/types.yaml#/definitions/phandle
> +    description: |
> +      Phandle to the Raspberry Pi firmware node. Required on older silicon
> +      (BCM2835-BCM2711) where VideoCore VPU endpoints are exclusively accessed
> +      via firmware mailbox IPC.
> +
> +required:
> +  - compatible
> +  - reg

[Severity: Medium]
Should there be an allOf conditional block here to enforce the firmware
property requirement for older silicon?

The description states it is required for BCM2835 and BCM2711, but device
trees missing it will silently pass schema validation without an explicit
constraint.

> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    pmu@7e00a000 {
> +        compatible = "brcm,bcm2835-axiperf";
> +        reg = <0x7e00a000 0x100>;
> +    };

[Severity: Medium]
Does this example contradict the documentation above?

Since this example uses the "brcm,bcm2835-axiperf" compatible string, shouldn't
it include the firmware property that is documented as required for this SoC?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.