mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
net: fec: restore dev_id in the cases of probe error
[ Upstream commit e90f686b43 ]
The static variable dev_id always plus one before netdev registerred.
It should restore the dev_id value in the cases of probe error.
Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
5edbe3c024
commit
9043779527
@@ -3543,6 +3543,7 @@ failed_phy:
|
||||
of_node_put(phy_node);
|
||||
failed_ioremap:
|
||||
free_netdev(ndev);
|
||||
dev_id--;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user