drivers: net: cpsw: fix cpsw clock gating issue across suspend/resume
authorMugunthan V N <mugunthanvnm@ti.com>
Tue, 18 Jun 2013 09:34:35 +0000 (15:04 +0530)
committerDavid S. Miller <davem@davemloft.net>
Thu, 20 Jun 2013 01:33:58 +0000 (18:33 -0700)
Due to some hardware integration issue, CPSW sliver modules requires a
reset across suspend/resume cycle for a successful clock gating to
CPGMAC (CPSW and Davinci MDIO) in AM335x PG1.0.
This issue is fixed in PG2.x, though to support suspend/resume on PG1.0
this reset is required.

Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/ti/cpsw.c

index 2fd69db3c09faa5263f64e5881100e7e4eb52bf4..e66a20223abb256355a6d72c70ce26b090dd8467 100644 (file)
@@ -1976,6 +1976,8 @@ static int cpsw_suspend(struct device *dev)
 
        if (netif_running(ndev))
                cpsw_ndo_stop(ndev);
+       soft_reset("sliver 0", &priv->slaves[0].sliver->soft_reset);
+       soft_reset("sliver 1", &priv->slaves[1].sliver->soft_reset);
        pm_runtime_put_sync(&pdev->dev);
 
        return 0;