Commit ec0d7551 authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by David S. Miller

net: sh_eth: tidyup compile warning

This patch tidyup below warning

${LINUX}/drivers/net/sh_eth.c:1773: warning:
'mdp' may be used uninitialized in this function

Cc: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: default avatarKuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 72e85c45
...@@ -1770,7 +1770,7 @@ static int sh_eth_drv_probe(struct platform_device *pdev) ...@@ -1770,7 +1770,7 @@ static int sh_eth_drv_probe(struct platform_device *pdev)
int ret, devno = 0; int ret, devno = 0;
struct resource *res; struct resource *res;
struct net_device *ndev = NULL; struct net_device *ndev = NULL;
struct sh_eth_private *mdp; struct sh_eth_private *mdp = NULL;
struct sh_eth_plat_data *pd; struct sh_eth_plat_data *pd;
/* get base addr */ /* get base addr */
...@@ -1888,7 +1888,7 @@ static int sh_eth_drv_probe(struct platform_device *pdev) ...@@ -1888,7 +1888,7 @@ static int sh_eth_drv_probe(struct platform_device *pdev)
out_release: out_release:
/* net_dev free */ /* net_dev free */
if (mdp->tsu_addr) if (mdp && mdp->tsu_addr)
iounmap(mdp->tsu_addr); iounmap(mdp->tsu_addr);
if (ndev) if (ndev)
free_netdev(ndev); free_netdev(ndev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment