diff mbox series

[net] net: phy: mediatek: add the missing suspend/resume callbacks

Message ID 20210823044422.164184-1-dqfext@gmail.com (mailing list archive)
State New, archived
Headers show
Series [net] net: phy: mediatek: add the missing suspend/resume callbacks | expand

Commit Message

Qingfang Deng Aug. 23, 2021, 4:44 a.m. UTC
Without suspend/resume callbacks, the PHY cannot be powered down/up
administratively.

Fixes: e40d2cca0189 ("net: phy: add MediaTek Gigabit Ethernet PHY driver")
Signed-off-by: DENG Qingfang <dqfext@gmail.com>
---
 drivers/net/phy/mediatek-ge.c | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Andrew Lunn Aug. 23, 2021, 1 p.m. UTC | #1
On Mon, Aug 23, 2021 at 12:44:21PM +0800, DENG Qingfang wrote:
> Without suspend/resume callbacks, the PHY cannot be powered down/up
> administratively.
> 
> Fixes: e40d2cca0189 ("net: phy: add MediaTek Gigabit Ethernet PHY driver")
> Signed-off-by: DENG Qingfang <dqfext@gmail.com>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew
Jakub Kicinski Aug. 24, 2021, 11:53 p.m. UTC | #2
On Mon, 23 Aug 2021 15:00:08 +0200 Andrew Lunn wrote:
> On Mon, Aug 23, 2021 at 12:44:21PM +0800, DENG Qingfang wrote:
> > Without suspend/resume callbacks, the PHY cannot be powered down/up
> > administratively.
> > 
> > Fixes: e40d2cca0189 ("net: phy: add MediaTek Gigabit Ethernet PHY driver")
> > Signed-off-by: DENG Qingfang <dqfext@gmail.com>  
> 
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>

Applied, thanks!
diff mbox series

Patch

diff --git a/drivers/net/phy/mediatek-ge.c b/drivers/net/phy/mediatek-ge.c
index 11ff335d6228..b7a5ae20edd5 100644
--- a/drivers/net/phy/mediatek-ge.c
+++ b/drivers/net/phy/mediatek-ge.c
@@ -81,6 +81,8 @@  static struct phy_driver mtk_gephy_driver[] = {
 		 */
 		.config_intr	= genphy_no_config_intr,
 		.handle_interrupt = genphy_handle_interrupt_no_ack,
+		.suspend	= genphy_suspend,
+		.resume		= genphy_resume,
 		.read_page	= mtk_gephy_read_page,
 		.write_page	= mtk_gephy_write_page,
 	},
@@ -93,6 +95,8 @@  static struct phy_driver mtk_gephy_driver[] = {
 		 */
 		.config_intr	= genphy_no_config_intr,
 		.handle_interrupt = genphy_handle_interrupt_no_ack,
+		.suspend	= genphy_suspend,
+		.resume		= genphy_resume,
 		.read_page	= mtk_gephy_read_page,
 		.write_page	= mtk_gephy_write_page,
 	},