diff mbox series

[net-next,v2,4/7] net: ethernet: fs_enet: drop unused phy_info and mii_if_info

Message ID 20240829161531.610874-5-maxime.chevallier@bootlin.com (mailing list archive)
State Handled Elsewhere, archived
Headers show
Series net: ethernet: fs_enet: Cleanup and phylink conversion | expand

Commit Message

Maxime Chevallier Aug. 29, 2024, 4:15 p.m. UTC
There's no user of the struct phy_info, the 'phy' field and the
mii_if_info in the fs_enet driver, probably dating back when phylib
wasn't as widely used.  Drop these from the driver code.

Acked-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>
---
 drivers/net/ethernet/freescale/fs_enet/fs_enet.h | 11 -----------
 1 file changed, 11 deletions(-)

Comments

Andrew Lunn Aug. 30, 2024, 9:06 p.m. UTC | #1
On Thu, Aug 29, 2024 at 06:15:27PM +0200, Maxime Chevallier wrote:
> There's no user of the struct phy_info, the 'phy' field and the
> mii_if_info in the fs_enet driver, probably dating back when phylib
> wasn't as widely used.  Drop these from the driver code.
> 
> Acked-by: Christophe Leroy <christophe.leroy@csgroup.eu>
> Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew
Andrew Lunn Aug. 30, 2024, 9:07 p.m. UTC | #2
On Thu, Aug 29, 2024 at 06:15:27PM +0200, Maxime Chevallier wrote:
> There's no user of the struct phy_info, the 'phy' field and the
> mii_if_info in the fs_enet driver, probably dating back when phylib
> wasn't as widely used.  Drop these from the driver code.

There might be an include of linux/mii.h you can also drop?

	Andrew
Maxime Chevallier Sept. 4, 2024, 8:52 a.m. UTC | #3
Hi Andrew,

On Fri, 30 Aug 2024 23:07:56 +0200
Andrew Lunn <andrew@lunn.ch> wrote:

> On Thu, Aug 29, 2024 at 06:15:27PM +0200, Maxime Chevallier wrote:
> > There's no user of the struct phy_info, the 'phy' field and the
> > mii_if_info in the fs_enet driver, probably dating back when phylib
> > wasn't as widely used.  Drop these from the driver code.  
> 
> There might be an include of linux/mii.h you can also drop?

Oh nice catch ! They are indeed no longer useful, I'll add that in V3.

Thanks,

Maxime
diff mbox series

Patch

diff --git a/drivers/net/ethernet/freescale/fs_enet/fs_enet.h b/drivers/net/ethernet/freescale/fs_enet/fs_enet.h
index abe4dc97e52a..781f506c933c 100644
--- a/drivers/net/ethernet/freescale/fs_enet/fs_enet.h
+++ b/drivers/net/ethernet/freescale/fs_enet/fs_enet.h
@@ -92,14 +92,6 @@  struct fs_ops {
 	void (*tx_restart)(struct net_device *dev);
 };
 
-struct phy_info {
-	unsigned int id;
-	const char *name;
-	void (*startup) (struct net_device * dev);
-	void (*shutdown) (struct net_device * dev);
-	void (*ack_int) (struct net_device * dev);
-};
-
 /* The FEC stores dest/src/type, data, and checksum for receive packets.
  */
 #define MAX_MTU 1508		/* Allow fullsized pppoe packets over VLAN */
@@ -153,10 +145,7 @@  struct fs_enet_private {
 	cbd_t __iomem *cur_rx;
 	cbd_t __iomem *cur_tx;
 	int tx_free;
-	const struct phy_info *phy;
 	u32 msg_enable;
-	struct mii_if_info mii_if;
-	unsigned int last_mii_status;
 	int interrupt;
 
 	int oldduplex, oldspeed, oldlink;	/* current settings */