[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID:
<BY3PR18MB4707D450930467656DDFA58DA0A12@BY3PR18MB4707.namprd18.prod.outlook.com>
Date: Mon, 15 Jul 2024 16:02:24 +0000
From: Sai Krishna Gajula <saikrishnag@...vell.com>
To: "nikita.shubin@...uefel.me" <nikita.shubin@...uefel.me>,
Hartley Sweeten
<hsweeten@...ionengravers.com>,
"David S. Miller" <davem@...emloft.net>,
Eric
Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni
<pabeni@...hat.com>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Andrew Lunn
<andrew@...n.ch>
Subject: RE: [PATCH v11 17/38] net: cirrus: add DT support for Cirrus EP93xx
> -----Original Message-----
> From: Nikita Shubin via B4 Relay
> <devnull+nikita.shubin.maquefel.me@...nel.org>
> Sent: Monday, July 15, 2024 2:08 PM
> To: Hartley Sweeten <hsweeten@...ionengravers.com>; David S. Miller
> <davem@...emloft.net>; Eric Dumazet <edumazet@...gle.com>; Jakub
> Kicinski <kuba@...nel.org>; Paolo Abeni <pabeni@...hat.com>
> Cc: netdev@...r.kernel.org; linux-kernel@...r.kernel.org; Andrew Lunn
> <andrew@...n.ch>
> Subject: [PATCH v11 17/38] net: cirrus: add DT support for Cirrus
> EP93xx
>
> From: Nikita Shubin <nikita. shubin@ maquefel. me> - add OF ID match table -
> get phy_id from the device tree, as part of mdio - copy_addr is now always
> used, as there is no SoC/board that aren't - dropped platform header Signed-
> off-by: Nikita
> From: Nikita Shubin <nikita.shubin@...uefel.me>
>
> - add OF ID match table
> - get phy_id from the device tree, as part of mdio
> - copy_addr is now always used, as there is no SoC/board that aren't
> - dropped platform header
>
> Signed-off-by: Nikita Shubin <nikita.shubin@...uefel.me>
> Tested-by: Alexander Sverdlin <alexander.sverdlin@...il.com>
> Reviewed-by: Andrew Lunn <andrew@...n.ch>
> Reviewed-by: Linus Walleij <linus.walleij@...aro.org>
This patch seemed to be for net-next, in case NET, Fixes tag is required. Please check.
> ---
> drivers/net/ethernet/cirrus/ep93xx_eth.c | 63 ++++++++++++++++--------------
> --
> 1 file changed, 32 insertions(+), 31 deletions(-)
>
> diff --git a/drivers/net/ethernet/cirrus/ep93xx_eth.c
> b/drivers/net/ethernet/cirrus/ep93xx_eth.c
> index 1f495cfd7959..2523d9c9d1b8 100644
> --- a/drivers/net/ethernet/cirrus/ep93xx_eth.c
> +++ b/drivers/net/ethernet/cirrus/ep93xx_eth.c
> @@ -16,13 +16,12 @@
> #include <linux/ethtool.h>
> #include <linux/interrupt.h>
> #include <linux/moduleparam.h>
> +#include <linux/of.h>
> #include <linux/platform_device.h>
> #include <linux/delay.h>
> #include <linux/io.h>
> #include <linux/slab.h>
>
> -#include <linux/platform_data/eth-ep93xx.h>
> -
> #define DRV_MODULE_NAME "ep93xx-eth"
>
> #define RX_QUEUE_ENTRIES 64
> @@ -738,25 +737,6 @@ static const struct net_device_ops
> ep93xx_netdev_ops = {
> .ndo_set_mac_address = eth_mac_addr,
> };
>
> -static struct net_device *ep93xx_dev_alloc(struct ep93xx_eth_data *data) -{
> - struct net_device *dev;
> -
> - dev = alloc_etherdev(sizeof(struct ep93xx_priv));
> - if (dev == NULL)
> - return NULL;
> -
> - eth_hw_addr_set(dev, data->dev_addr);
> -
> - dev->ethtool_ops = &ep93xx_ethtool_ops;
> - dev->netdev_ops = &ep93xx_netdev_ops;
> -
> - dev->features |= NETIF_F_SG | NETIF_F_HW_CSUM;
> -
> - return dev;
> -}
> -
> -
> static void ep93xx_eth_remove(struct platform_device *pdev) {
> struct net_device *dev;
> @@ -786,27 +766,47 @@ static void ep93xx_eth_remove(struct
> platform_device *pdev)
>
> static int ep93xx_eth_probe(struct platform_device *pdev) {
> - struct ep93xx_eth_data *data;
> struct net_device *dev;
> struct ep93xx_priv *ep;
> struct resource *mem;
> + void __iomem *base_addr;
> + struct device_node *np;
Small nit, please check if reverse x-mas tree order need to be follow here.
> + u32 phy_id;
> int irq;
> int err;
>
...
> static struct platform_driver ep93xx_eth_driver = {
> .probe = ep93xx_eth_probe,
> .remove_new = ep93xx_eth_remove,
> .driver = {
> .name = "ep93xx-eth",
> + .of_match_table = ep93xx_eth_of_ids,
> },
> };
>
>
> --
> 2.43.2
>
>
Powered by blists - more mailing lists