aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/mscc/ocelot.h
diff options
context:
space:
mode:
authorGravatar Vladimir Oltean <vladimir.oltean@nxp.com> 2022-05-11 13:06:37 +0300
committerGravatar Jakub Kicinski <kuba@kernel.org> 2022-05-12 16:39:18 -0700
commit7e708760fc114f049df9dccb994e23d20866b310 (patch)
treec6a4f19010382f197987d8b2d2ccda663c9596d2 /drivers/net/ethernet/mscc/ocelot.h
parentnet: mscc: ocelot: minimize holes in struct ocelot_port (diff)
downloadlinux-7e708760fc114f049df9dccb994e23d20866b310.tar.gz
linux-7e708760fc114f049df9dccb994e23d20866b310.tar.bz2
linux-7e708760fc114f049df9dccb994e23d20866b310.zip
net: mscc: ocelot: move ocelot_port_private :: chip_port to ocelot_port :: index
Currently the ocelot switch lib is unaware of the index of a struct ocelot_port, since that is kept in the encapsulating structures of outer drivers (struct dsa_port :: index, struct ocelot_port_private :: chip_port). With the upcoming increase in complexity associated with assigning DSA tag_8021q CPU ports to certain user ports, it becomes necessary for the switch lib to be able to retrieve the index of a certain ocelot_port. Therefore, introduce a new u8 to ocelot_port (same size as the chip_port used by the ocelot switchdev driver) and rework the existing code to populate and use it. Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/mscc/ocelot.h')
-rw-r--r--drivers/net/ethernet/mscc/ocelot.h1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/net/ethernet/mscc/ocelot.h b/drivers/net/ethernet/mscc/ocelot.h
index d0fa8ab6cc81..6d65cc87d757 100644
--- a/drivers/net/ethernet/mscc/ocelot.h
+++ b/drivers/net/ethernet/mscc/ocelot.h
@@ -48,7 +48,6 @@ struct ocelot_port_private {
struct net_device *dev;
struct phylink *phylink;
struct phylink_config phylink_config;
- u8 chip_port;
struct ocelot_port_tc tc;
};