[PATCH 02/10] net: tc35815: Drop support for TX49XX boards

From: Thomas Bogendoerfer
Date: Tue Jan 05 2021 - 09:04:38 EST


CPU support for TX49xx is getting removed, so remove support in network
drivers for it.

Signed-off-by: Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx>
---
drivers/net/ethernet/toshiba/tc35815.c | 29 --------------------------
1 file changed, 29 deletions(-)

diff --git a/drivers/net/ethernet/toshiba/tc35815.c b/drivers/net/ethernet/toshiba/tc35815.c
index 7a6e5ff8e5d4..d4712cd2e28c 100644
--- a/drivers/net/ethernet/toshiba/tc35815.c
+++ b/drivers/net/ethernet/toshiba/tc35815.c
@@ -687,39 +687,10 @@ static int tc_mii_init(struct net_device *dev)
return err;
}

-#ifdef CONFIG_CPU_TX49XX
-/*
- * Find a platform_device providing a MAC address. The platform code
- * should provide a "tc35815-mac" device with a MAC address in its
- * platform_data.
- */
-static int tc35815_mac_match(struct device *dev, const void *data)
-{
- struct platform_device *plat_dev = to_platform_device(dev);
- const struct pci_dev *pci_dev = data;
- unsigned int id = pci_dev->irq;
- return !strcmp(plat_dev->name, "tc35815-mac") && plat_dev->id == id;
-}
-
static int tc35815_read_plat_dev_addr(struct net_device *dev)
{
- struct tc35815_local *lp = netdev_priv(dev);
- struct device *pd = bus_find_device(&platform_bus_type, NULL,
- lp->pci_dev, tc35815_mac_match);
- if (pd) {
- if (pd->platform_data)
- memcpy(dev->dev_addr, pd->platform_data, ETH_ALEN);
- put_device(pd);
- return is_valid_ether_addr(dev->dev_addr) ? 0 : -ENODEV;
- }
return -ENODEV;
}
-#else
-static int tc35815_read_plat_dev_addr(struct net_device *dev)
-{
- return -ENODEV;
-}
-#endif

static int tc35815_init_dev_addr(struct net_device *dev)
{
--
2.29.2