]> git.itanic.dy.fi Git - linux-stable/commit
net: mdio-mux: be compatible with parent buses which only support C45
authorVladimir Oltean <vladimir.oltean@nxp.com>
Wed, 13 Dec 2023 15:27:12 +0000 (17:27 +0200)
committerJakub Kicinski <kuba@kernel.org>
Fri, 15 Dec 2023 02:55:38 +0000 (18:55 -0800)
commit10ad63da5c036b2fd61600b43217cfa9b4d66f52
tree7b5786fcc83a53d84185f21795ec90e85362ba00
parentd215ab4d6ae8bea8f66a50399745791b7de5b7d8
net: mdio-mux: be compatible with parent buses which only support C45

After the mii_bus API conversion to a split read() / read_c45(), there
might be MDIO parent buses which only populate the read_c45() and
write_c45() function pointers but not the C22 variants.

We haven't seen these in the wild paired with MDIO multiplexers, but
Andrew points out we should treat the corner case.

Link: https://lore.kernel.org/netdev/4ccd7dc9-b611-48aa-865f-68d3a1327ce8@lunn.ch/
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20231213152712.320842-3-vladimir.oltean@nxp.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/mdio/mdio-mux.c