]> git.baikalelectronics.ru Git - kernel.git/commit
net: mscc: ocelot: make phy_mode a member of the common struct ocelot_port
authorVladimir Oltean <vladimir.oltean@nxp.com>
Mon, 6 Jan 2020 01:34:15 +0000 (03:34 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 6 Jan 2020 07:22:33 +0000 (23:22 -0800)
commit09bed1cbc83cfcfaee179b1ace96dcc95c0a0948
tree1857ca1293888c173409f19d094471e3e4d2a67f
parent4aeaffe6012155bdc564757e6008bfdaa8aec07a
net: mscc: ocelot: make phy_mode a member of the common struct ocelot_port

The Ocelot switchdev driver and the Felix DSA one need it for different
reasons. Felix (or at least the VSC9959 instantiation in NXP LS1028A) is
integrated with the traditional NXP Layerscape PCS design which does not
support runtime configuration of SerDes protocol. So it needs to
pre-validate the phy-mode from the device tree and prevent PHYLINK from
attempting to change it. For this, it needs to cache it in a private
variable.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mscc/ocelot.c
drivers/net/ethernet/mscc/ocelot.h
drivers/net/ethernet/mscc/ocelot_board.c
include/soc/mscc/ocelot.h