Re: [PATCH net-next v4 2/5] dt-bindings: net: realtek,rtl9301-mdio: add clock-frequency
flat view
From: netdev-bot+sashiko@kernel.org
Date: 2026-09-16 13:35:15
Also in:
linux-devicetree
Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider: Critical: 0 · High: 0 · Medium: 0 · Low: 2 - [Low] Concern (validated as a FALSE POSITIVE, retained only per the retention policy): 'the binding adds a per-bus clock-frequency… - [Low] Redundant re-declaration of the common `clock-frequency` property in Documentation/devicetree/bindings/net/realtek,rtl9301-mdio.yaml. -- dt-bindings: net: realtek,rtl9301-mdio: add clock-frequency This documents the MDC frequencies supported by the Realtek Otto switch MDIO controllers, adding per-family clock-frequency value sets and describing the shared frequency selector on RTL839x.
quoted hunk ↗ jump to hunk
diff --git a/Documentation/devicetree/bindings/net/realtek,rtl9301-mdio.yaml b/Documentation/devicetree/bindings/net/realtek,rtl9301-mdio.yaml index 7f5b4897487b2..c5f2289dc0eb2 100644 --- a/Documentation/devicetree/bindings/net/realtek,rtl9301-mdio.yaml +++ b/Documentation/devicetree/bindings/net/realtek,rtl9301-mdio.yaml@@ -56,6 +56,9 @@ patternProperties: reg: maxItems: 1 + clock-frequency: + $ref: /schemas/types.yaml#/definitions/uint32 +
[Severity: Low]
This isn't a bug, but is this declaration needed at all? The mdio-bus
child subschema already does:
'^mdio-bus@[0-3]$':
$ref: mdio.yaml#
and Documentation/devicetree/bindings/net/mdio.yaml already declares the
property:
clock-frequency:
description:
Desired MDIO bus clock frequency in Hz. Values greater than IEEE 802.3
defined 2.5MHz should only be used when all devices on the bus support
the given clock speed.
So the property is already permitted by the referenced schema, and its type
is known to dtschema without an explicit uint32 $ref. Other in-tree
bindings rely on that, for example mscc,miim.yaml uses a bare
"clock-frequency: true" and microchip,pic64hpsc-mdio.yaml declares
clock-frequency with only a default.
The per-family enum blocks added below in the allOf if-then sections are
what actually restrict the accepted values, and those work independently of
this declaration. Could this block be dropped so the common property is
only described in mdio.yaml?
required:
- reg
[ ... ]
quoted hunk ↗ jump to hunk
@@ -77,8 +84,16 @@ allOf: - realtek,rtl8381-mdio - realtek,rtl8382-mdio then: + properties: + mdio-bus@0: + properties: + clock-frequency: + enum: [2500000, 10000000] + default: 2500000 + patternProperties: '^mdio-bus@[1-3]$': false
[ ... ] -- Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20260912130451.3757276-1-markus.stockhausen%40gmx.de