Message ID | 20171025232124.14120-2-f.fainelli@gmail.com |
---|---|
State | RFC, archived |
Delegated to: | David Miller |
Headers | show |
Series | [RFC,net-next,1/4] net: phy: Export phy_stop_machine() | expand |
On Thu, Oct 26, 2017 at 1:21 AM, Florian Fainelli <f.fainelli@gmail.com> wrote: > phy_stop_machine() is publicly exported in include/linux/phy.y, and is > not made static because it's also used by phy_device.c. Since > phy_start_machine() is already exported, do this here too. This is a > function that provides hard guarantees that the state machine is > properly stopped past that synchronization point. > > Fixes: 00db8189d984 ("This patch adds a PHY Abstraction Layer to the Linux Kernel, enabling ethernet drivers to remain as ignorant as is reasonable of the connected PHY's design and operation details.") > Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c index 2b1e67bc1e73..0ddeb97217ce 100644 --- a/drivers/net/phy/phy.c +++ b/drivers/net/phy/phy.c @@ -595,6 +595,7 @@ void phy_stop_machine(struct phy_device *phydev) phydev->state = PHY_UP; mutex_unlock(&phydev->lock); } +EXPORT_SYMBOL_GPL(phy_stop_machine); /** * phy_error - enter HALTED state for this PHY device
phy_stop_machine() is publicly exported in include/linux/phy.y, and is not made static because it's also used by phy_device.c. Since phy_start_machine() is already exported, do this here too. This is a function that provides hard guarantees that the state machine is properly stopped past that synchronization point. Fixes: 00db8189d984 ("This patch adds a PHY Abstraction Layer to the Linux Kernel, enabling ethernet drivers to remain as ignorant as is reasonable of the connected PHY's design and operation details.") Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> --- drivers/net/phy/phy.c | 1 + 1 file changed, 1 insertion(+)