Skip to content

Commit

Permalink
net: stmmac: dwmac-intel-plat: remove unnecessary initialization
Browse files Browse the repository at this point in the history
plat_dat is initialized by stmmac_probe_config_dt().
So, initialization is not required by priv->plat.
This removes unnecessary initialization and variables.

Signed-off-by: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Nobuhiro Iwamatsu authored and David S. Miller committed Feb 11, 2021
1 parent 3d368ab commit 0d64523
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions drivers/net/ethernet/stmicro/stmmac/dwmac-intel-plat.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,13 @@ MODULE_DEVICE_TABLE(of, intel_eth_plat_match);

static int intel_eth_plat_probe(struct platform_device *pdev)
{
struct net_device *ndev = platform_get_drvdata(pdev);
struct stmmac_priv *priv = netdev_priv(ndev);
struct plat_stmmacenet_data *plat_dat;
struct stmmac_resources stmmac_res;
const struct of_device_id *match;
struct intel_dwmac *dwmac;
unsigned long rate;
int ret;

plat_dat = priv->plat;
ret = stmmac_get_platform_resources(pdev, &stmmac_res);
if (ret)
return ret;
Expand Down

0 comments on commit 0d64523

Please sign in to comment.