[PATCH v2 4/6] net: dwc_eth_qos: remove the field phyaddr of the struct eqos_priv

Ramon Fried rfried.dev at gmail.com
Thu Apr 29 22:12:50 CEST 2021


On Mon, Apr 26, 2021 at 6:47 PM Patrick Delaunay
<patrick.delaunay at foss.st.com> wrote:
>
> Since the commit commit 6a895d039ba7 ("net: Update eQos driver and FEC
> driver to use eth phy interfaces") the field phyaddr of driver private data
> struct eqos_priv is no more used in eqos_start() for the phy_connect()
> parameter.
>
> Now this variable is only initialized in eqos_probe_resources_stm32()
> it can be removed.
>
> Signed-off-by: Patrick Delaunay <patrick.delaunay at foss.st.com>
> ---
>
> Changes in v2:
> - remove unused element in the struct eqos_priv (NEW)
>
>  drivers/net/dwc_eth_qos.c | 5 -----
>  1 file changed, 5 deletions(-)
>
> diff --git a/drivers/net/dwc_eth_qos.c b/drivers/net/dwc_eth_qos.c
> index e8242ca4e1..e625aea8d1 100644
> --- a/drivers/net/dwc_eth_qos.c
> +++ b/drivers/net/dwc_eth_qos.c
> @@ -311,7 +311,6 @@ struct eqos_priv {
>         struct clk clk_slave_bus;
>         struct mii_dev *mii;
>         struct phy_device *phy;
> -       int phyaddr;
>         u32 max_speed;
>         void *descs;
>         int tx_desc_idx, rx_desc_idx;
> @@ -1826,7 +1825,6 @@ static int eqos_probe_resources_stm32(struct udevice *dev)
>         if (ret)
>                 pr_warn("No phy clock provided %d", ret);
>
> -       eqos->phyaddr = -1;
>         ret = dev_read_phandle_with_args(dev, "phy-handle", NULL, 0, 0,
>                                          &phandle_args);
>         if (!ret) {
> @@ -1839,9 +1837,6 @@ static int eqos_probe_resources_stm32(struct udevice *dev)
>                 if (ret)
>                         pr_warn("gpio_request_by_name(phy reset) not provided %d",
>                                 ret);
> -
> -               eqos->phyaddr = ofnode_read_u32_default(phandle_args.node,
> -                                                       "reg", -1);
>         }
>
>         debug("%s: OK\n", __func__);
> --
> 2.17.1
>
Reviewed-by: Ramon Fried <rfried.dev at gmail.com>


More information about the U-Boot mailing list