diff mbox series

[RFC,v3,net-next,03/10] dt-bindings: net: dsa: b53: add missing CPU port phy-mode to example

Message ID 20220806141059.2498226-4-vladimir.oltean@nxp.com (mailing list archive)
State Superseded
Delegated to: Netdev Maintainers
Headers show
Series Validate OF nodes for DSA shared ports | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Series has a cover letter
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers warning 2 maintainers not CCed: linux-mediatek@lists.infradead.org linux-arm-kernel@lists.infradead.org
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Vladimir Oltean Aug. 6, 2022, 2:10 p.m. UTC
Looking at b53_srab_phylink_get_caps() I get no indication of what PHY
modes does port 8 support, since it is implemented circularly based on
the p->mode retrieved from the device tree (and in PHY_INTERFACE_MODE_NA
it reports nothing to supported_interfaces).

However if I look at the b53_switch_chips[] element for BCM58XX_DEVICE_ID,
I see that port 8 is the IMP port, and SRAB means the IMP port is
internal to the SoC. So use phy-mode = "internal" in the example.

Note that this will make b53_srab_phylink_get_caps() go through the
"default" case and report PHY_INTERFACE_MODE_INTERNAL to
supported_interfaces, which is probably a good thing.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
v2->v3: patch is new

 Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml | 2 ++
 1 file changed, 2 insertions(+)

Comments

Rob Herring Aug. 9, 2022, 8:11 p.m. UTC | #1
On Sat, 06 Aug 2022 17:10:52 +0300, Vladimir Oltean wrote:
> Looking at b53_srab_phylink_get_caps() I get no indication of what PHY
> modes does port 8 support, since it is implemented circularly based on
> the p->mode retrieved from the device tree (and in PHY_INTERFACE_MODE_NA
> it reports nothing to supported_interfaces).
> 
> However if I look at the b53_switch_chips[] element for BCM58XX_DEVICE_ID,
> I see that port 8 is the IMP port, and SRAB means the IMP port is
> internal to the SoC. So use phy-mode = "internal" in the example.
> 
> Note that this will make b53_srab_phylink_get_caps() go through the
> "default" case and report PHY_INTERFACE_MODE_INTERNAL to
> supported_interfaces, which is probably a good thing.
> 
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
> v2->v3: patch is new
> 
>  Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 

Acked-by: Rob Herring <robh@kernel.org>
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
index 23114d691d2a..2e01371b8288 100644
--- a/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
+++ b/Documentation/devicetree/bindings/net/dsa/brcm,b53.yaml
@@ -254,6 +254,8 @@  examples:
                     ethernet = <&amac2>;
                     label = "cpu";
                     reg = <8>;
+                    phy-mode = "internal";
+
                     fixed-link {
                         speed = <1000>;
                         full-duplex;