OSDN Git Service

net: gemini: Clean up phy registration
authorLinus Walleij <linus.walleij@linaro.org>
Sun, 6 Sep 2020 19:21:13 +0000 (21:21 +0200)
committerJakub Kicinski <kuba@kernel.org>
Sun, 6 Sep 2020 19:27:00 +0000 (12:27 -0700)
commit3e813d61401a634cc67e7e707e2c7e84b207d099
tree02eba79104372eba20d176eee2664b5b6733e04d
parentee1a4c84a76de7c3d3cc04584b745280f6e22ba9
net: gemini: Clean up phy registration

It's nice if the phy is online before we register the netdev
so try to do that first.

Stop trying to do "second tried" to register the phy, it
works perfectly fine the first time.

Stop remvoving the phy in uninit. Remove it when the
driver is remove():d, symmetric to where it is added, in
probe().

Suggested-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reported-by: David Miller <davem@davemloft.net>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/cortina/gemini.c