netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2)
@ 2025-01-06 11:51 Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 1/9] net: dsa: ksz: remove setting of tx_lpi parameters Russell King (Oracle)
                   ` (9 more replies)
  0 siblings, 10 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:51 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Arınç ÜNAL,
	Daniel Golle, David S. Miller, DENG Qingfang, Eric Dumazet,
	Florian Fainelli, Jakub Kicinski, linux-arm-kernel,
	linux-mediatek, Matthias Brugger, netdev, Paolo Abeni, Sean Wang,
	Simon Horman, UNGLinuxDriver, Vladimir Oltean, Woojung Huh

This is part 2 of the DSA EEE cleanups, removing what has become dead
code as a result of the EEE management phylib now does.

Patch 1 removes the useless setting of tx_lpi parameters in the
ksz driver.

Patch 2 does the same for mt753x.

Patch 3 removes the DSA core code that calls the get_mac_eee() operation.
This needs to be done before removing the implementations because doing
otherwise would cause dsa_user_get_eee() to return -EOPNOTSUPP.

Patches 4..8 remove the trivial get_mac_eee() implementations from DSA
drivers.

Patch 9 finally removes the get_mac_eee() method from struct
dsa_switch_ops.

 drivers/net/dsa/b53/b53_common.c       |  7 -------
 drivers/net/dsa/b53/b53_priv.h         |  1 -
 drivers/net/dsa/bcm_sf2.c              |  1 -
 drivers/net/dsa/microchip/ksz_common.c | 15 ---------------
 drivers/net/dsa/mt7530.c               | 13 -------------
 drivers/net/dsa/mv88e6xxx/chip.c       |  8 --------
 drivers/net/dsa/qca/qca8k-8xxx.c       |  1 -
 drivers/net/dsa/qca/qca8k-common.c     |  7 -------
 drivers/net/dsa/qca/qca8k.h            |  1 -
 include/net/dsa.h                      |  2 --
 net/dsa/user.c                         |  8 --------
 11 files changed, 64 deletions(-)

Changes since RFC:
- Removed removal of phydev check in net/dsa/user.c
- Addition of mt753x changes

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH net-next 1/9] net: dsa: ksz: remove setting of tx_lpi parameters
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
@ 2025-01-06 11:58 ` Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 2/9] net: dsa: mt753x: " Russell King (Oracle)
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:58 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

dsa_user_get_eee() calls the DSA switch get_mac_eee() method followed
by phylink_ethtool_get_eee(), which goes on to call
phy_ethtool_get_eee(). This overwrites all members of the passed
ethtool_keee, which means anything written by the DSA switch
get_mac_eee() method will be discarded.

Remove setting any members in ksz_get_mac_eee().

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/microchip/ksz_common.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/net/dsa/microchip/ksz_common.c b/drivers/net/dsa/microchip/ksz_common.c
index e3512e324572..60a4630dd7ba 100644
--- a/drivers/net/dsa/microchip/ksz_common.c
+++ b/drivers/net/dsa/microchip/ksz_common.c
@@ -3492,14 +3492,6 @@ static bool ksz_support_eee(struct dsa_switch *ds, int port)
 static int ksz_get_mac_eee(struct dsa_switch *ds, int port,
 			   struct ethtool_keee *e)
 {
-	/* There is no documented control of Tx LPI configuration. */
-	e->tx_lpi_enabled = true;
-
-	/* There is no documented control of Tx LPI timer. According to tests
-	 * Tx LPI timer seems to be set by default to minimal value.
-	 */
-	e->tx_lpi_timer = 0;
-
 	return 0;
 }
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 2/9] net: dsa: mt753x: remove setting of tx_lpi parameters
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 1/9] net: dsa: ksz: remove setting of tx_lpi parameters Russell King (Oracle)
@ 2025-01-06 11:58 ` Russell King (Oracle)
  2025-01-06 13:01   ` Chester A. Unal
  2025-01-06 11:58 ` [PATCH net-next 3/9] net: dsa: no longer call ds->ops->get_mac_eee() Russell King (Oracle)
                   ` (7 subsequent siblings)
  9 siblings, 1 reply; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:58 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

dsa_user_get_eee() calls the DSA switch get_mac_eee() method followed
by phylink_ethtool_get_eee(), which goes on to call
phy_ethtool_get_eee(). This overwrites all members of the passed
ethtool_keee, which means anything written by the DSA switch
get_mac_eee() method will be discarded.

Remove setting any members in mt753x_get_mac_eee().

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/mt7530.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/net/dsa/mt7530.c b/drivers/net/dsa/mt7530.c
index 9605febd3573..4c78d049b9f4 100644
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
@@ -3088,12 +3088,6 @@ mt753x_setup(struct dsa_switch *ds)
 static int mt753x_get_mac_eee(struct dsa_switch *ds, int port,
 			      struct ethtool_keee *e)
 {
-	struct mt7530_priv *priv = ds->priv;
-	u32 eeecr = mt7530_read(priv, MT753X_PMEEECR_P(port));
-
-	e->tx_lpi_enabled = !(eeecr & LPI_MODE_EN);
-	e->tx_lpi_timer = LPI_THRESH_GET(eeecr);
-
 	return 0;
 }
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 3/9] net: dsa: no longer call ds->ops->get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 1/9] net: dsa: ksz: remove setting of tx_lpi parameters Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 2/9] net: dsa: mt753x: " Russell King (Oracle)
@ 2025-01-06 11:58 ` Russell King (Oracle)
  2025-01-06 11:58 ` [PATCH net-next 4/9] net: dsa: b53/bcm_sf2: remove b53_get_mac_eee() Russell King (Oracle)
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:58 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

All implementations of get_mac_eee() now just return zero without doing
anything useful. Remove the call to this method in preparation to
removing the method from each DSA driver.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 net/dsa/user.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/net/dsa/user.c b/net/dsa/user.c
index 4a8de48a6f24..c74f2b2b92de 100644
--- a/net/dsa/user.c
+++ b/net/dsa/user.c
@@ -1251,7 +1251,6 @@ static int dsa_user_get_eee(struct net_device *dev, struct ethtool_keee *e)
 {
 	struct dsa_port *dp = dsa_user_to_port(dev);
 	struct dsa_switch *ds = dp->ds;
-	int ret;
 
 	/* Check whether the switch supports EEE */
 	if (!ds->ops->support_eee || !ds->ops->support_eee(ds, dp->index))
@@ -1261,13 +1260,6 @@ static int dsa_user_get_eee(struct net_device *dev, struct ethtool_keee *e)
 	if (!dev->phydev)
 		return -ENODEV;
 
-	if (!ds->ops->get_mac_eee)
-		return -EOPNOTSUPP;
-
-	ret = ds->ops->get_mac_eee(ds, dp->index, e);
-	if (ret)
-		return ret;
-
 	return phylink_ethtool_get_eee(dp->pl, e);
 }
 
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 4/9] net: dsa: b53/bcm_sf2: remove b53_get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (2 preceding siblings ...)
  2025-01-06 11:58 ` [PATCH net-next 3/9] net: dsa: no longer call ds->ops->get_mac_eee() Russell King (Oracle)
@ 2025-01-06 11:58 ` Russell King (Oracle)
  2025-01-06 11:59 ` [PATCH net-next 5/9] net: dsa: ksz: remove ksz_get_mac_eee() Russell King (Oracle)
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:58 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

b53_get_mac_eee() is no longer called by the core DSA code. Remove it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/b53/b53_common.c | 7 -------
 drivers/net/dsa/b53/b53_priv.h   | 1 -
 drivers/net/dsa/bcm_sf2.c        | 1 -
 3 files changed, 9 deletions(-)

diff --git a/drivers/net/dsa/b53/b53_common.c b/drivers/net/dsa/b53/b53_common.c
index 0561b60f668f..79dc77835681 100644
--- a/drivers/net/dsa/b53/b53_common.c
+++ b/drivers/net/dsa/b53/b53_common.c
@@ -2232,12 +2232,6 @@ bool b53_support_eee(struct dsa_switch *ds, int port)
 }
 EXPORT_SYMBOL(b53_support_eee);
 
-int b53_get_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e)
-{
-	return 0;
-}
-EXPORT_SYMBOL(b53_get_mac_eee);
-
 int b53_set_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e)
 {
 	struct b53_device *dev = ds->priv;
@@ -2299,7 +2293,6 @@ static const struct dsa_switch_ops b53_switch_ops = {
 	.port_enable		= b53_enable_port,
 	.port_disable		= b53_disable_port,
 	.support_eee		= b53_support_eee,
-	.get_mac_eee		= b53_get_mac_eee,
 	.set_mac_eee		= b53_set_mac_eee,
 	.port_bridge_join	= b53_br_join,
 	.port_bridge_leave	= b53_br_leave,
diff --git a/drivers/net/dsa/b53/b53_priv.h b/drivers/net/dsa/b53/b53_priv.h
index 99e5cfc98ae8..9e9b5bc0c5d6 100644
--- a/drivers/net/dsa/b53/b53_priv.h
+++ b/drivers/net/dsa/b53/b53_priv.h
@@ -385,7 +385,6 @@ void b53_disable_port(struct dsa_switch *ds, int port);
 void b53_brcm_hdr_setup(struct dsa_switch *ds, int port);
 int b53_eee_init(struct dsa_switch *ds, int port, struct phy_device *phy);
 bool b53_support_eee(struct dsa_switch *ds, int port);
-int b53_get_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e);
 int b53_set_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e);
 
 #endif
diff --git a/drivers/net/dsa/bcm_sf2.c b/drivers/net/dsa/bcm_sf2.c
index a53fb6191e6b..fa2bf3fa9019 100644
--- a/drivers/net/dsa/bcm_sf2.c
+++ b/drivers/net/dsa/bcm_sf2.c
@@ -1233,7 +1233,6 @@ static const struct dsa_switch_ops bcm_sf2_ops = {
 	.port_enable		= bcm_sf2_port_setup,
 	.port_disable		= bcm_sf2_port_disable,
 	.support_eee		= b53_support_eee,
-	.get_mac_eee		= b53_get_mac_eee,
 	.set_mac_eee		= b53_set_mac_eee,
 	.port_bridge_join	= b53_br_join,
 	.port_bridge_leave	= b53_br_leave,
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 5/9] net: dsa: ksz: remove ksz_get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (3 preceding siblings ...)
  2025-01-06 11:58 ` [PATCH net-next 4/9] net: dsa: b53/bcm_sf2: remove b53_get_mac_eee() Russell King (Oracle)
@ 2025-01-06 11:59 ` Russell King (Oracle)
  2025-01-06 11:59 ` [PATCH net-next 6/9] net: dsa: mt753x: " Russell King (Oracle)
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:59 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

ksz_get_mac_eee() is no longer called by the core DSA code. Remove it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/microchip/ksz_common.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/net/dsa/microchip/ksz_common.c b/drivers/net/dsa/microchip/ksz_common.c
index 60a4630dd7ba..89f0796894af 100644
--- a/drivers/net/dsa/microchip/ksz_common.c
+++ b/drivers/net/dsa/microchip/ksz_common.c
@@ -3489,12 +3489,6 @@ static bool ksz_support_eee(struct dsa_switch *ds, int port)
 	return false;
 }
 
-static int ksz_get_mac_eee(struct dsa_switch *ds, int port,
-			   struct ethtool_keee *e)
-{
-	return 0;
-}
-
 static int ksz_set_mac_eee(struct dsa_switch *ds, int port,
 			   struct ethtool_keee *e)
 {
@@ -4664,7 +4658,6 @@ static const struct dsa_switch_ops ksz_switch_ops = {
 	.cls_flower_del		= ksz_cls_flower_del,
 	.port_setup_tc		= ksz_setup_tc,
 	.support_eee		= ksz_support_eee,
-	.get_mac_eee		= ksz_get_mac_eee,
 	.set_mac_eee		= ksz_set_mac_eee,
 	.port_get_default_prio	= ksz_port_get_default_prio,
 	.port_set_default_prio	= ksz_port_set_default_prio,
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 6/9] net: dsa: mt753x: remove ksz_get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (4 preceding siblings ...)
  2025-01-06 11:59 ` [PATCH net-next 5/9] net: dsa: ksz: remove ksz_get_mac_eee() Russell King (Oracle)
@ 2025-01-06 11:59 ` Russell King (Oracle)
  2025-01-06 13:03   ` Chester A. Unal
  2025-01-06 11:59 ` [PATCH net-next 7/9] net: dsa: mv88e6xxx: remove mv88e6xxx_get_mac_eee() Russell King (Oracle)
                   ` (3 subsequent siblings)
  9 siblings, 1 reply; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:59 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

mt753x_get_mac_eee() is no longer called by the core DSA code. Remove
it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/mt7530.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/drivers/net/dsa/mt7530.c b/drivers/net/dsa/mt7530.c
index 4c78d049b9f4..d2d0f091e49e 100644
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
@@ -3085,12 +3085,6 @@ mt753x_setup(struct dsa_switch *ds)
 	return ret;
 }
 
-static int mt753x_get_mac_eee(struct dsa_switch *ds, int port,
-			      struct ethtool_keee *e)
-{
-	return 0;
-}
-
 static int mt753x_set_mac_eee(struct dsa_switch *ds, int port,
 			      struct ethtool_keee *e)
 {
@@ -3233,7 +3227,6 @@ const struct dsa_switch_ops mt7530_switch_ops = {
 	.port_mirror_del	= mt753x_port_mirror_del,
 	.phylink_get_caps	= mt753x_phylink_get_caps,
 	.support_eee		= dsa_supports_eee,
-	.get_mac_eee		= mt753x_get_mac_eee,
 	.set_mac_eee		= mt753x_set_mac_eee,
 	.conduit_state_change	= mt753x_conduit_state_change,
 	.port_setup_tc		= mt753x_setup_tc,
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 7/9] net: dsa: mv88e6xxx: remove mv88e6xxx_get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (5 preceding siblings ...)
  2025-01-06 11:59 ` [PATCH net-next 6/9] net: dsa: mt753x: " Russell King (Oracle)
@ 2025-01-06 11:59 ` Russell King (Oracle)
  2025-01-06 11:59 ` [PATCH net-next 8/9] net: dsa: qca: remove qca8k_get_mac_eee() Russell King (Oracle)
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:59 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

mv88e6xxx_get_mac_eee() is no longer called by the core DSA code.
Remove it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/mv88e6xxx/chip.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
index 570c8642d387..35ae084af166 100644
--- a/drivers/net/dsa/mv88e6xxx/chip.c
+++ b/drivers/net/dsa/mv88e6xxx/chip.c
@@ -1513,13 +1513,6 @@ static void mv88e6xxx_get_regs(struct dsa_switch *ds, int port,
 	mv88e6xxx_reg_unlock(chip);
 }
 
-static int mv88e6xxx_get_mac_eee(struct dsa_switch *ds, int port,
-				 struct ethtool_keee *e)
-{
-	/* Nothing to do on the port's MAC */
-	return 0;
-}
-
 static int mv88e6xxx_set_mac_eee(struct dsa_switch *ds, int port,
 				 struct ethtool_keee *e)
 {
@@ -7100,7 +7093,6 @@ static const struct dsa_switch_ops mv88e6xxx_switch_ops = {
 	.port_max_mtu		= mv88e6xxx_get_max_mtu,
 	.port_change_mtu	= mv88e6xxx_change_mtu,
 	.support_eee		= dsa_supports_eee,
-	.get_mac_eee		= mv88e6xxx_get_mac_eee,
 	.set_mac_eee		= mv88e6xxx_set_mac_eee,
 	.get_eeprom_len		= mv88e6xxx_get_eeprom_len,
 	.get_eeprom		= mv88e6xxx_get_eeprom,
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 8/9] net: dsa: qca: remove qca8k_get_mac_eee()
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (6 preceding siblings ...)
  2025-01-06 11:59 ` [PATCH net-next 7/9] net: dsa: mv88e6xxx: remove mv88e6xxx_get_mac_eee() Russell King (Oracle)
@ 2025-01-06 11:59 ` Russell King (Oracle)
  2025-01-06 11:59 ` [PATCH net-next 9/9] net: dsa: remove get_mac_eee() method Russell King (Oracle)
  2025-01-08  2:20 ` [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) patchwork-bot+netdevbpf
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:59 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

qca8k_get_mac_eee() is no longer called by the core DSA code. Remove it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 drivers/net/dsa/qca/qca8k-8xxx.c   | 1 -
 drivers/net/dsa/qca/qca8k-common.c | 7 -------
 drivers/net/dsa/qca/qca8k.h        | 1 -
 3 files changed, 9 deletions(-)

diff --git a/drivers/net/dsa/qca/qca8k-8xxx.c b/drivers/net/dsa/qca/qca8k-8xxx.c
index 90e24bc00b99..2d56a8152420 100644
--- a/drivers/net/dsa/qca/qca8k-8xxx.c
+++ b/drivers/net/dsa/qca/qca8k-8xxx.c
@@ -2017,7 +2017,6 @@ static const struct dsa_switch_ops qca8k_switch_ops = {
 	.get_sset_count		= qca8k_get_sset_count,
 	.set_ageing_time	= qca8k_set_ageing_time,
 	.support_eee		= dsa_supports_eee,
-	.get_mac_eee		= qca8k_get_mac_eee,
 	.set_mac_eee		= qca8k_set_mac_eee,
 	.port_enable		= qca8k_port_enable,
 	.port_disable		= qca8k_port_disable,
diff --git a/drivers/net/dsa/qca/qca8k-common.c b/drivers/net/dsa/qca/qca8k-common.c
index 560c74c4ac3d..13005f10edb7 100644
--- a/drivers/net/dsa/qca/qca8k-common.c
+++ b/drivers/net/dsa/qca/qca8k-common.c
@@ -557,13 +557,6 @@ int qca8k_set_mac_eee(struct dsa_switch *ds, int port,
 	return ret;
 }
 
-int qca8k_get_mac_eee(struct dsa_switch *ds, int port,
-		      struct ethtool_keee *e)
-{
-	/* Nothing to do on the port's MAC */
-	return 0;
-}
-
 static int qca8k_port_configure_learning(struct dsa_switch *ds, int port,
 					 bool learning)
 {
diff --git a/drivers/net/dsa/qca/qca8k.h b/drivers/net/dsa/qca/qca8k.h
index 24962a395754..d046679265fa 100644
--- a/drivers/net/dsa/qca/qca8k.h
+++ b/drivers/net/dsa/qca/qca8k.h
@@ -520,7 +520,6 @@ int qca8k_get_sset_count(struct dsa_switch *ds, int port, int sset);
 
 /* Common eee function */
 int qca8k_set_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *eee);
-int qca8k_get_mac_eee(struct dsa_switch *ds, int port, struct ethtool_keee *e);
 
 /* Common bridge function */
 void qca8k_port_stp_state_set(struct dsa_switch *ds, int port, u8 state);
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH net-next 9/9] net: dsa: remove get_mac_eee() method
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (7 preceding siblings ...)
  2025-01-06 11:59 ` [PATCH net-next 8/9] net: dsa: qca: remove qca8k_get_mac_eee() Russell King (Oracle)
@ 2025-01-06 11:59 ` Russell King (Oracle)
  2025-01-08  2:20 ` [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) patchwork-bot+netdevbpf
  9 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 11:59 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

The get_mac_eee() is no longer called by the core DSA code, nor are
there any implementations of this method. Remove it.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
 include/net/dsa.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/include/net/dsa.h b/include/net/dsa.h
index 4aeedb296d67..9640d5c67f56 100644
--- a/include/net/dsa.h
+++ b/include/net/dsa.h
@@ -991,8 +991,6 @@ struct dsa_switch_ops {
 	bool	(*support_eee)(struct dsa_switch *ds, int port);
 	int	(*set_mac_eee)(struct dsa_switch *ds, int port,
 			       struct ethtool_keee *e);
-	int	(*get_mac_eee)(struct dsa_switch *ds, int port,
-			       struct ethtool_keee *e);
 
 	/* EEPROM access */
 	int	(*get_eeprom_len)(struct dsa_switch *ds);
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH net-next 2/9] net: dsa: mt753x: remove setting of tx_lpi parameters
  2025-01-06 11:58 ` [PATCH net-next 2/9] net: dsa: mt753x: " Russell King (Oracle)
@ 2025-01-06 13:01   ` Chester A. Unal
  0 siblings, 0 replies; 14+ messages in thread
From: Chester A. Unal @ 2025-01-06 13:01 UTC (permalink / raw)
  To: Russell King (Oracle), Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Ar__n__ __NAL, Daniel Golle,
	David S. Miller, DENG Qingfang, Eric Dumazet, Florian Fainelli,
	Jakub Kicinski, linux-arm-kernel, linux-mediatek,
	Matthias Brugger, netdev, Paolo Abeni, Sean Wang, Simon Horman,
	UNGLinuxDriver, Vladimir Oltean, Woojung Huh

On 06/01/2025 11:58, Russell King (Oracle) wrote:
> dsa_user_get_eee() calls the DSA switch get_mac_eee() method followed
> by phylink_ethtool_get_eee(), which goes on to call
> phy_ethtool_get_eee(). This overwrites all members of the passed
> ethtool_keee, which means anything written by the DSA switch
> get_mac_eee() method will be discarded.
> 
> Remove setting any members in mt753x_get_mac_eee().
> 
> Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>

Reviewed-by: Chester A. Unal <chester.a.unal@arinc9.com>

Chester A.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH net-next 6/9] net: dsa: mt753x: remove ksz_get_mac_eee()
  2025-01-06 11:59 ` [PATCH net-next 6/9] net: dsa: mt753x: " Russell King (Oracle)
@ 2025-01-06 13:03   ` Chester A. Unal
  2025-01-06 15:14     ` Russell King (Oracle)
  0 siblings, 1 reply; 14+ messages in thread
From: Chester A. Unal @ 2025-01-06 13:03 UTC (permalink / raw)
  To: Russell King (Oracle), Andrew Lunn, Heiner Kallweit
  Cc: AngeloGioacchino Del Regno, Daniel Golle, David S. Miller,
	DENG Qingfang, Eric Dumazet, Florian Fainelli, Jakub Kicinski,
	linux-arm-kernel, linux-mediatek, Matthias Brugger, netdev,
	Paolo Abeni, Sean Wang, Simon Horman, UNGLinuxDriver,
	Vladimir Oltean, Woojung Huh

Hey Russell.

The patch subject mentions ksz_get_mac_eee() instead of
mt753x_get_mac_eee(). Keep that in mind if you happen to submit a new
version of this series; this is not enough as the sole reason to submit a
new version, in my opinion.

On 06/01/2025 11:59, Russell King (Oracle) wrote:
> mt753x_get_mac_eee() is no longer called by the core DSA code. Remove
> it.
> 
> Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>

Reviewed-by: Chester A. Unal <chester.a.unal@arinc9.com>

Cheers.
Chester A.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH net-next 6/9] net: dsa: mt753x: remove ksz_get_mac_eee()
  2025-01-06 13:03   ` Chester A. Unal
@ 2025-01-06 15:14     ` Russell King (Oracle)
  0 siblings, 0 replies; 14+ messages in thread
From: Russell King (Oracle) @ 2025-01-06 15:14 UTC (permalink / raw)
  To: Chester A. Unal
  Cc: Andrew Lunn, Heiner Kallweit, AngeloGioacchino Del Regno,
	Daniel Golle, David S. Miller, DENG Qingfang, Eric Dumazet,
	Florian Fainelli, Jakub Kicinski, linux-arm-kernel,
	linux-mediatek, Matthias Brugger, netdev, Paolo Abeni, Sean Wang,
	Simon Horman, UNGLinuxDriver, Vladimir Oltean, Woojung Huh

On Mon, Jan 06, 2025 at 01:03:46PM +0000, Chester A. Unal wrote:
> The patch subject mentions ksz_get_mac_eee() instead of
> mt753x_get_mac_eee(). Keep that in mind if you happen to submit a new
> version of this series; this is not enough as the sole reason to submit a
> new version, in my opinion.

Thanks for spotting that, I've fixed it for the next posting!

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2)
  2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
                   ` (8 preceding siblings ...)
  2025-01-06 11:59 ` [PATCH net-next 9/9] net: dsa: remove get_mac_eee() method Russell King (Oracle)
@ 2025-01-08  2:20 ` patchwork-bot+netdevbpf
  9 siblings, 0 replies; 14+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-01-08  2:20 UTC (permalink / raw)
  To: Russell King
  Cc: andrew, hkallweit1, angelogioacchino.delregno, arinc.unal, daniel,
	davem, dqfext, edumazet, florian.fainelli, kuba, linux-arm-kernel,
	linux-mediatek, matthias.bgg, netdev, pabeni, sean.wang, horms,
	UNGLinuxDriver, olteanv, woojung.huh

Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 6 Jan 2025 11:51:31 +0000 you wrote:
> This is part 2 of the DSA EEE cleanups, removing what has become dead
> code as a result of the EEE management phylib now does.
> 
> Patch 1 removes the useless setting of tx_lpi parameters in the
> ksz driver.
> 
> Patch 2 does the same for mt753x.
> 
> [...]

Here is the summary with links:
  - [net-next,1/9] net: dsa: ksz: remove setting of tx_lpi parameters
    https://git.kernel.org/netdev/net-next/c/0945a7b44220
  - [net-next,2/9] net: dsa: mt753x: remove setting of tx_lpi parameters
    https://git.kernel.org/netdev/net-next/c/22cedc609759
  - [net-next,3/9] net: dsa: no longer call ds->ops->get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/60c6e3a59299
  - [net-next,4/9] net: dsa: b53/bcm_sf2: remove b53_get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/08cef9e1b083
  - [net-next,5/9] net: dsa: ksz: remove ksz_get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/e2d1b8090b69
  - [net-next,6/9] net: dsa: mt753x: remove ksz_get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/9e66e8ebe7a9
  - [net-next,7/9] net: dsa: mv88e6xxx: remove mv88e6xxx_get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/d3889a3d1351
  - [net-next,8/9] net: dsa: qca: remove qca8k_get_mac_eee()
    https://git.kernel.org/netdev/net-next/c/d19be79a67b3
  - [net-next,9/9] net: dsa: remove get_mac_eee() method
    https://git.kernel.org/netdev/net-next/c/2fa8b4383d24

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2025-01-08  2:20 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-06 11:51 [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) Russell King (Oracle)
2025-01-06 11:58 ` [PATCH net-next 1/9] net: dsa: ksz: remove setting of tx_lpi parameters Russell King (Oracle)
2025-01-06 11:58 ` [PATCH net-next 2/9] net: dsa: mt753x: " Russell King (Oracle)
2025-01-06 13:01   ` Chester A. Unal
2025-01-06 11:58 ` [PATCH net-next 3/9] net: dsa: no longer call ds->ops->get_mac_eee() Russell King (Oracle)
2025-01-06 11:58 ` [PATCH net-next 4/9] net: dsa: b53/bcm_sf2: remove b53_get_mac_eee() Russell King (Oracle)
2025-01-06 11:59 ` [PATCH net-next 5/9] net: dsa: ksz: remove ksz_get_mac_eee() Russell King (Oracle)
2025-01-06 11:59 ` [PATCH net-next 6/9] net: dsa: mt753x: " Russell King (Oracle)
2025-01-06 13:03   ` Chester A. Unal
2025-01-06 15:14     ` Russell King (Oracle)
2025-01-06 11:59 ` [PATCH net-next 7/9] net: dsa: mv88e6xxx: remove mv88e6xxx_get_mac_eee() Russell King (Oracle)
2025-01-06 11:59 ` [PATCH net-next 8/9] net: dsa: qca: remove qca8k_get_mac_eee() Russell King (Oracle)
2025-01-06 11:59 ` [PATCH net-next 9/9] net: dsa: remove get_mac_eee() method Russell King (Oracle)
2025-01-08  2:20 ` [PATCH net-next 0/9] net: dsa: cleanup EEE (part 2) patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).