net: dsa: felix: Don't error out on disabled ports with no phy-mode
Subsystems (4)
Vladimir Oltean
maintainerPATCH v2 1/1 net: dsa: felix: Don't error out on disabled ports with no phy-mode
From: Vladimir Oltean <[email protected]>
The felix_parse_ports_node function was tested only on device trees where all ports were enabled. Fix this check so that the driver continues to probe only with the ports where status is not "disabled", as expected.
---
Changes in v2:
- Use for_each_available_child_of_node instead of open-coding the of_device_is_available check.
drivers/net/dsa/ocelot/felix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/dsa/ocelot/felix.c +1 -1
@@ -323,7 +323,7 @@ static int felix_parse_ports_node(struct felix *felix,struct device *dev = felix->ocelot.dev;struct device_node *child; -for_each_child_of_node (ports_node, child) { +for_each_available_child_of_node (ports_node, child) {phy_interface_t phy_mode;u32 port;int err;
Signature · 1 line
2.17.1
Quoted 9 lines · Vladimir Oltean
From: Vladimir Oltean <[email protected]>
The
felix_parse_ports_nodefunction was tested only on device trees where all ports were enabled. Fix this check so that the driver continues to probe only with the ports where status is not "disabled", as expected.Fixes bdeced75b13f ("net: dsa: felix: Add PCS operations for PHYLINK")Signed-off-by Vladimir Oltean <[email protected]>
Signature · 1 line
Florian
Quoted 9 lines · Vladimir Oltean
From: Vladimir Oltean <[email protected]>
The
felix_parse_ports_nodefunction was tested only on device trees where all ports were enabled. Fix this check so that the driver continues to probe only with the ports where status is not "disabled", as expected.Fixes bdeced75b13f ("net: dsa: felix: Add PCS operations for PHYLINK")Signed-off-by Vladimir Oltean <[email protected]>
Andrew
From: Vladimir Oltean <[email protected]>
Date: Thu, 16 Jan 2020 20:41:53 +0200
Quoted 7 lines
From: Vladimir Oltean <[email protected]>
The
felix_parse_ports_nodefunction was tested only on device trees where all ports were enabled. Fix this check so that the driver continues to probe only with the ports where status is not "disabled", as expected.
Quoted 6 lines
Fixes bdeced75b13f ("net: dsa: felix: Add PCS operations for PHYLINK")Signed-off-by Vladimir Oltean <[email protected]>---
Changes in v2:
- Usefor_each_available_child_of_nodeinstead of open-coding theof_device_is_availablecheck.
Applied.