Message ID | 10d8576f-a5da-4445-b841-98ceb338da0d@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | cleanup arc emac | expand |
On Tue, Jun 18, 2024 at 06:14:14PM +0200, Johan Jonker wrote: > The last real user nSIM_700 of the "snps,arc-emac" compatible string in > a driver was removed in 2019. The use of this string in the combined DT of > rk3066a/rk3188 as place holder has also been replaced, so > remove emac_arc.c to clean up some code. > > Signed-off-by: Johan Jonker <jbx6244@gmail.com> Reviewed-by: Simon Horman <horms@kernel.org>
On Tue, 2024-06-18 at 18:14 +0200, Johan Jonker wrote: > The last real user nSIM_700 of the "snps,arc-emac" compatible string in > a driver was removed in 2019. The use of this string in the combined DT of > rk3066a/rk3188 as place holder has also been replaced, so > remove emac_arc.c to clean up some code. > > Signed-off-by: Johan Jonker <jbx6244@gmail.com> > --- > > [PATCH 8/8] ARC: nSIM_700: remove unused network options > https://lore.kernel.org/all/20191023124417.5770-9-Eugeniy.Paltsev@synopsys.com/ > --- > drivers/net/ethernet/arc/Kconfig | 10 ---- > drivers/net/ethernet/arc/Makefile | 1 - > drivers/net/ethernet/arc/emac_arc.c | 88 ----------------------------- > 3 files changed, 99 deletions(-) > delete mode 100644 drivers/net/ethernet/arc/emac_arc.c AFAICS this depends on the previous DT patch, which in turn should go via the arm tree. Perhaps the whole series should go via the arm tree? In such case: Acked-by: Paolo Abeni <pabeni@redhat.com>
On Thu, 20 Jun 2024 15:19:24 +0200 Paolo Abeni wrote: > AFAICS this depends on the previous DT patch, which in turn should go > via the arm tree. > > Perhaps the whole series should go via the arm tree? FWIW Heiko said on patch 1 that the whole thing should go via netdev...
Am Donnerstag, 20. Juni 2024, 15:37:29 CEST schrieb Jakub Kicinski: > On Thu, 20 Jun 2024 15:19:24 +0200 Paolo Abeni wrote: > > AFAICS this depends on the previous DT patch, which in turn should go > > via the arm tree. > > > > Perhaps the whole series should go via the arm tree? > > FWIW Heiko said on patch 1 that the whole thing should go via netdev... yep. Reasoning is that the rk3066 is mostly inactive, so taking that dt-patch through the net-tree won't create conflicts with other dt-changes here. And of course both binding and driver changes are the bigger parts of this series.
diff --git a/drivers/net/ethernet/arc/Kconfig b/drivers/net/ethernet/arc/Kconfig index 0a67612af228..0d400a7d8d91 100644 --- a/drivers/net/ethernet/arc/Kconfig +++ b/drivers/net/ethernet/arc/Kconfig @@ -23,16 +23,6 @@ config ARC_EMAC_CORE select PHYLIB select CRC32 -config ARC_EMAC - tristate "ARC EMAC support" - select ARC_EMAC_CORE - depends on OF_IRQ - depends on ARC || COMPILE_TEST - help - On some legacy ARC (Synopsys) FPGA boards such as ARCAngel4/ML50x - non-standard on-chip ethernet device ARC EMAC 10/100 is used. - Say Y here if you have such a board. If unsure, say N. - config EMAC_ROCKCHIP tristate "Rockchip EMAC support" select ARC_EMAC_CORE diff --git a/drivers/net/ethernet/arc/Makefile b/drivers/net/ethernet/arc/Makefile index d63ada577c8e..23586eefec44 100644 --- a/drivers/net/ethernet/arc/Makefile +++ b/drivers/net/ethernet/arc/Makefile @@ -5,5 +5,4 @@ arc_emac-objs := emac_main.o emac_mdio.o obj-$(CONFIG_ARC_EMAC_CORE) += arc_emac.o -obj-$(CONFIG_ARC_EMAC) += emac_arc.o obj-$(CONFIG_EMAC_ROCKCHIP) += emac_rockchip.o diff --git a/drivers/net/ethernet/arc/emac_arc.c b/drivers/net/ethernet/arc/emac_arc.c deleted file mode 100644 index a3afddb23ee8..000000000000 --- a/drivers/net/ethernet/arc/emac_arc.c +++ /dev/null @@ -1,88 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-or-later -/** - * DOC: emac_arc.c - ARC EMAC specific glue layer - * - * Copyright (C) 2014 Romain Perier - * - * Romain Perier <romain.perier@gmail.com> - */ - -#include <linux/etherdevice.h> -#include <linux/module.h> -#include <linux/of_net.h> -#include <linux/platform_device.h> - -#include "emac.h" - -#define DRV_NAME "emac_arc" - -static int emac_arc_probe(struct platform_device *pdev) -{ - struct device *dev = &pdev->dev; - struct arc_emac_priv *priv; - phy_interface_t interface; - struct net_device *ndev; - int err; - - if (!dev->of_node) - return -ENODEV; - - ndev = alloc_etherdev(sizeof(struct arc_emac_priv)); - if (!ndev) - return -ENOMEM; - platform_set_drvdata(pdev, ndev); - SET_NETDEV_DEV(ndev, dev); - - priv = netdev_priv(ndev); - priv->drv_name = DRV_NAME; - - err = of_get_phy_mode(dev->of_node, &interface); - if (err) { - if (err == -ENODEV) - interface = PHY_INTERFACE_MODE_MII; - else - goto out_netdev; - } - - priv->clk = devm_clk_get(dev, "hclk"); - if (IS_ERR(priv->clk)) { - dev_err(dev, "failed to retrieve host clock from device tree\n"); - err = -EINVAL; - goto out_netdev; - } - - err = arc_emac_probe(ndev, interface); -out_netdev: - if (err) - free_netdev(ndev); - return err; -} - -static void emac_arc_remove(struct platform_device *pdev) -{ - struct net_device *ndev = platform_get_drvdata(pdev); - - arc_emac_remove(ndev); - free_netdev(ndev); -} - -static const struct of_device_id emac_arc_dt_ids[] = { - { .compatible = "snps,arc-emac" }, - { /* Sentinel */ } -}; -MODULE_DEVICE_TABLE(of, emac_arc_dt_ids); - -static struct platform_driver emac_arc_driver = { - .probe = emac_arc_probe, - .remove_new = emac_arc_remove, - .driver = { - .name = DRV_NAME, - .of_match_table = emac_arc_dt_ids, - }, -}; - -module_platform_driver(emac_arc_driver); - -MODULE_AUTHOR("Romain Perier <romain.perier@gmail.com>"); -MODULE_DESCRIPTION("ARC EMAC platform driver"); -MODULE_LICENSE("GPL");
The last real user nSIM_700 of the "snps,arc-emac" compatible string in a driver was removed in 2019. The use of this string in the combined DT of rk3066a/rk3188 as place holder has also been replaced, so remove emac_arc.c to clean up some code. Signed-off-by: Johan Jonker <jbx6244@gmail.com> --- [PATCH 8/8] ARC: nSIM_700: remove unused network options https://lore.kernel.org/all/20191023124417.5770-9-Eugeniy.Paltsev@synopsys.com/ --- drivers/net/ethernet/arc/Kconfig | 10 ---- drivers/net/ethernet/arc/Makefile | 1 - drivers/net/ethernet/arc/emac_arc.c | 88 ----------------------------- 3 files changed, 99 deletions(-) delete mode 100644 drivers/net/ethernet/arc/emac_arc.c -- 2.39.2