RE: [PATCH net-next 1/1] net: phy: marvell10g: Add WAKE_PHY support to WOL event
From: Song, Yoong Siang <hidden>
Date: 2021-08-20 01:25:07
Also in:
lkml
quoted
quoted
quoted
Yes, you are right. I missed the effect of get_wol. Is it needed in future to implement link change interrupt in phy driver? Cause I dint see much phy driver implement link change interrupt.If there is a board that has interrupt pin wired correctly from the PHY and the interrupt controller is safe to use (i.e. it is not a PCA953x which cannot handle interrupt storms correctly), then I think the PHY driver should use the interrupt, instead of polling. MarekAny suggestion to avoid the conflict of "WoL on link change" mentioned byRussell?quoted
Is it make sense to create a new member called wolopts under struct phy_device to track the WoL status and return the correct status in get_wolcallback? I really think you need to look at your PMC and see if you can make it an interrupt controller. You only need level interrupts, not edge. So the microcontroller in the PMC could just poll the GPIO. There appears to be a simple IPC between the host and PMC, so just extend it with a couple of registers, interrupt state, interrupt mask, and make use of the existing interrupt between the host and PMC. Andrew
Thanks for your suggestion. Currently, PMC is designed for platform-wide power management and not meant to control any device specific registers. Seem like it is not possible to make PMC an interrupt controller, but I will continue to discuss more with my team. Regards Siang