diff options
author | Vladimir Oltean <vladimir.oltean@nxp.com> | 2019-11-22 13:46:34 +0200 |
---|---|---|
committer | Dong Aisheng <aisheng.dong@nxp.com> | 2019-12-02 18:04:52 +0800 |
commit | 423c8b04007c85907f8f514de459ebc8541f0a54 (patch) | |
tree | e9f97c9c81289f612a32371fb1f28b214a58f0b6 /include/soc | |
parent | e51cc023c37902e10d1e0109ff0c6ddcce3d5c03 (diff) |
net: mscc: ocelot: introduce more focused PCS ops for PHYLINK
The reason for doing this is that the 2 mainline Ocelot switches so far,
VSC7514 and VSC9959, have radically different SoC/SerDes integration. So
although the PHYLINK callbacks are common, the implementations will
actually lie in device-specific function pointers.
Also, there was a duplicated and unused function pointer for pcs_init in
struct ocelot, remove that.
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Diffstat (limited to 'include/soc')
-rw-r--r-- | include/soc/mscc/ocelot.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/include/soc/mscc/ocelot.h b/include/soc/mscc/ocelot.h index 75d80df851e7..308293ec538a 100644 --- a/include/soc/mscc/ocelot.h +++ b/include/soc/mscc/ocelot.h @@ -412,7 +412,15 @@ enum { struct ocelot; struct ocelot_ops { - void (*pcs_init)(struct ocelot *ocelot, int port); + void (*pcs_init)(struct ocelot *ocelot, int port, + unsigned int link_an_mode, + const struct phylink_link_state *state); + void (*pcs_an_restart)(struct ocelot *ocelot, int port); + void (*pcs_link_state)(struct ocelot *ocelot, int port, + struct phylink_link_state *state); + void (*pcs_validate)(struct ocelot *ocelot, int port, + unsigned long *supported, + struct phylink_link_state *state); int (*reset)(struct ocelot *ocelot); }; @@ -479,8 +487,6 @@ struct ocelot { struct mutex ptp_lock; /* Protects the PTP clock */ spinlock_t ptp_clock_lock; - - void (*port_pcs_init)(struct ocelot_port *port); }; #define ocelot_read_ix(ocelot, reg, gi, ri) __ocelot_read_ix(ocelot, reg, reg##_GSZ * (gi) + reg##_RSZ * (ri)) |