[bugfix] add ethernet sleep and wake in GSW
Change-Id: I6f7661497ab0c0c660a1946142ac160515b95e03
diff --git a/src/kernel/linux/v4.19/drivers/net/phy/marvell-88q.c b/src/kernel/linux/v4.19/drivers/net/phy/marvell-88q.c
index c51090b..336e323 100755
--- a/src/kernel/linux/v4.19/drivers/net/phy/marvell-88q.c
+++ b/src/kernel/linux/v4.19/drivers/net/phy/marvell-88q.c
@@ -205,6 +205,17 @@
return 0;
}
+int q2220_suspend(struct phy_device *phydev)
+{
+ return phy_write(phydev, MII_ADDR_C45 | 0x038022, 0x1);
+}
+int q2220_resume(struct phy_device *phydev)
+{
+ return phy_write(phydev, MII_ADDR_C45 | 0x038022, 0x10);
+}
+
+
+
static int q2110_match_phy_device(struct phy_device *phydev)
{
return (phydev->c45_ids.device_ids[1] & 0xffffffff) == PHY_ID_88Q2220;
@@ -219,6 +230,8 @@
.match_phy_device = q2110_match_phy_device,
.set_loopback = &q2110_loopback,
.read_status = q2110_read_status,
+ .suspend = q2220_suspend,
+ .resume = q2220_resume,
}
};