Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

net: dsa: microchip: Move *_port_setup code to dsa_switch_ops::port_setup()

Right now, the *_port_setup code is in dsa_switch_ops::port_enable(),
which is not the best place for it. This patch moves it to a more
suitable place, dsa_switch_ops::port_setup(), to match the function's
purpose and name.

This patch is a preparation for coming ACL support patch.

Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Oleksij Rempel and committed by
David S. Miller
15299227 e03f0dfb

+2 -3
+2 -3
drivers/net/dsa/microchip/ksz_common.c
··· 2564 2564 return dev->dev_ops->mdb_del(dev, port, mdb, db); 2565 2565 } 2566 2566 2567 - static int ksz_enable_port(struct dsa_switch *ds, int port, 2568 - struct phy_device *phy) 2567 + static int ksz_port_setup(struct dsa_switch *ds, int port) 2569 2568 { 2570 2569 struct ksz_device *dev = ds->priv; 2571 2570 ··· 3496 3497 .phylink_mac_config = ksz_phylink_mac_config, 3497 3498 .phylink_mac_link_up = ksz_phylink_mac_link_up, 3498 3499 .phylink_mac_link_down = ksz_mac_link_down, 3499 - .port_enable = ksz_enable_port, 3500 + .port_setup = ksz_port_setup, 3500 3501 .set_ageing_time = ksz_set_ageing_time, 3501 3502 .get_strings = ksz_get_strings, 3502 3503 .get_ethtool_stats = ksz_get_ethtool_stats,