]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
net: phy: Do not warn in phy_stop() on PHY_DOWN
authorFlorian Fainelli <f.fainelli@gmail.com>
Thu, 17 Sep 2020 03:43:10 +0000 (20:43 -0700)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 9 Nov 2020 13:47:15 +0000 (14:47 +0100)
commitf802ca1f30a1c99b35f81144f082a4510cc48f3a
tree2b3772409d522fa41772775a43a44768d660977c
parent84781cc03ee70dc2ce8c546c6fe2e97f6108db87
net: phy: Do not warn in phy_stop() on PHY_DOWN

BugLink: https://bugs.launchpad.net/bugs/1899511
[ Upstream commit 5116a8ade333b6c2e180782139c9c516a437b21c ]

When phy_is_started() was added to catch incorrect PHY states,
phy_stop() would not be qualified against PHY_DOWN. It is possible to
reach that state when the PHY driver has been unbound and the network
device is then brought down.

Fixes: 2b3e88ea6528 ("net: phy: improve phy state checking")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Ian May <ian.may@canonical.com>
drivers/net/phy/phy.c