]> git.baikalelectronics.ru Git - kernel.git/commit
net: ftgmac100: add missing error return code in ftgmac100_probe()
authorYang Yingliang <yangyingliang@huawei.com>
Sat, 22 May 2021 12:02:46 +0000 (20:02 +0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 23 May 2021 23:16:24 +0000 (16:16 -0700)
commitdcfa07be4922fab5022650da7e2aa62e52e5f961
tree18af83356daef4871af6575d4198622e12da2d8d
parent98c0c6ad83045330a11167c5a8b7a3e374142d66
net: ftgmac100: add missing error return code in ftgmac100_probe()

The variables will be free on path err_phy_connect, it should
return error code, or it will cause double free when calling
ftgmac100_remove().

Fixes: aea3df9063ae ("net/faraday: Support NCSI mode")
Fixes: bb58dabda9b0 ("net: ftgmac100: Add support for DT phy-handle property")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/faraday/ftgmac100.c