summaryrefslogtreecommitdiffstats
path: root/net/dsa/dsa_priv.h
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2014-08-27 17:04:51 -0700
committerDavid S. Miller <davem@davemloft.net>2014-08-27 22:59:40 -0700
commit0d8bcdd383b8865e752a7e8edb4712c2e3902052 (patch)
treeb4a91fb89f31582da17c727278039c4df4c0f049 /net/dsa/dsa_priv.h
parentbd47497a0171b96264927e3377254db13b9fe3e3 (diff)
downloadop-kernel-dev-0d8bcdd383b8865e752a7e8edb4712c2e3902052.zip
op-kernel-dev-0d8bcdd383b8865e752a7e8edb4712c2e3902052.tar.gz
net: dsa: allow for more complex PHY setups
Modify the DSA slave interface to be bound to an arbitray PHY, not just the ones that are available as child PHY devices of the switch MDIO bus. This allows us for instance to have external PHYs connected to a separate MDIO bus, but yet also connected to a given switch port. Under certain configurations, the physical port mask might not be a 1:1 mapping to the MII PHYs mask. This is the case, if e.g: Port 1 of the switch is used and connects to a PHY at a MDIO address different than 1. Introduce a phys_mii_mask variable which allows driver to implement and divert their own MDIO read/writes operations for a subset of the MDIO PHY addresses. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa/dsa_priv.h')
-rw-r--r--net/dsa/dsa_priv.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/net/dsa/dsa_priv.h b/net/dsa/dsa_priv.h
index 218d75d..d20364a 100644
--- a/net/dsa/dsa_priv.h
+++ b/net/dsa/dsa_priv.h
@@ -33,6 +33,10 @@ struct dsa_slave_priv {
* to this port.
*/
struct phy_device *phy;
+ phy_interface_t phy_interface;
+ int old_link;
+ int old_pause;
+ int old_duplex;
};
/* dsa.c */
OpenPOWER on IntegriCloud