]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
drivers: net: cpsw: remove pm runtime calls from suspend callbacks
authorGrygorii Strashko <grygorii.strashko@ti.com>
Fri, 24 Jun 2016 18:23:43 +0000 (21:23 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 28 Jun 2016 12:57:18 +0000 (08:57 -0400)
PM runtime is properly handled in cpsw_ndo_open/stop(), as result it
isn't required to duplicate these calls in .suspend()/.resume()
callbacks. Moreover, it might cause unnecessary RPM resume of CPSW
during System suspend in the case it's already suspended because
all ethX interfaces are down already, before System suspend started.

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/ti/cpsw.c

index 4e3d51922248e41875d37ba2298803cbd52c119d..b6c508ef99929a4ef8fa256ad8808a5c7ec1c171 100644 (file)
@@ -2563,8 +2563,6 @@ static int cpsw_suspend(struct device *dev)
                        cpsw_ndo_stop(ndev);
        }
 
-       pm_runtime_put_sync(&pdev->dev);
-
        /* Select sleep pin state */
        pinctrl_pm_select_sleep_state(&pdev->dev);
 
@@ -2577,8 +2575,6 @@ static int cpsw_resume(struct device *dev)
        struct net_device       *ndev = platform_get_drvdata(pdev);
        struct cpsw_priv        *priv = netdev_priv(ndev);
 
-       pm_runtime_get_sync(&pdev->dev);
-
        /* Select default pin state */
        pinctrl_pm_select_default_state(&pdev->dev);