diff mbox series

[net-next] net: phy: LAN937x: add interrupt support for link detection

Message ID 20220423154727.29052-1-arun.ramadoss@microchip.com (mailing list archive)
State Accepted
Commit fb0a43f5bd454dfae94aeb293b32669c6ef83b37
Delegated to: Netdev Maintainers
Headers show
Series [net-next] net: phy: LAN937x: add interrupt support for link detection | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Single patches do not need cover letters
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers success CCed 9 of 9 maintainers
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 8 lines checked
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Arun Ramadoss April 23, 2022, 3:47 p.m. UTC
Added the config_intr and handle_interrupt for the LAN937x phy which is
same as the LAN87xx phy.

Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>
---
 drivers/net/phy/microchip_t1.c | 2 ++
 1 file changed, 2 insertions(+)


base-commit: cfc1d91a7d78cf9de25b043d81efcc16966d55b3

Comments

Andrew Lunn April 23, 2022, 3:59 p.m. UTC | #1
On Sat, Apr 23, 2022 at 09:17:27PM +0530, Arun Ramadoss wrote:
> Added the config_intr and handle_interrupt for the LAN937x phy which is
> same as the LAN87xx phy.
> 
> Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>

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

While looking at the code, i noticed LAN87XX has PHY_POLL_CABLE_TEST
where as LAN937X does not. Is this correct?

    Andrew
Arun Ramadoss April 24, 2022, 10:15 a.m. UTC | #2
On Sat, 2022-04-23 at 17:59 +0200, Andrew Lunn wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you
> know the content is safe
> 
> On Sat, Apr 23, 2022 at 09:17:27PM +0530, Arun Ramadoss wrote:
> > Added the config_intr and handle_interrupt for the LAN937x phy
> > which is
> > same as the LAN87xx phy.
> > 
> > Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>
> 
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>
> 
> While looking at the code, i noticed LAN87XX has PHY_POLL_CABLE_TEST
> where as LAN937X does not. Is this correct?
> 
>     Andrew
Yes Andrew, When I added the LAN937x support in the below patch I added
the call back for the cable_test_start and cable_test_get_status and
forgot to add the PHY_POLL_CABLE_TEST flag.

https://patchwork.kernel.org/project/netdevbpf/patch/20220304094401.31375-6-arun.ramadoss@microchip.com/

I initially posted the patch for adding flag in net-next, but you have
suggested to me sent the bug fix patch for this. I sent the bug fix
patch for adding the flag. 

https://patchwork.kernel.org/project/netdevbpf/patch/20220413071409.13530-1-arun.ramadoss@microchip.com/
patchwork-bot+netdevbpf@kernel.org April 26, 2022, 8:20 a.m. UTC | #3
Hello:

This patch was applied to netdev/net-next.git (master)
by Paolo Abeni <pabeni@redhat.com>:

On Sat, 23 Apr 2022 21:17:27 +0530 you wrote:
> Added the config_intr and handle_interrupt for the LAN937x phy which is
> same as the LAN87xx phy.
> 
> Signed-off-by: Arun Ramadoss <arun.ramadoss@microchip.com>
> ---
>  drivers/net/phy/microchip_t1.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> [...]

Here is the summary with links:
  - [net-next] net: phy: LAN937x: add interrupt support for link detection
    https://git.kernel.org/netdev/net-next/c/fb0a43f5bd45

You are awesome, thank you!
diff mbox series

Patch

diff --git a/drivers/net/phy/microchip_t1.c b/drivers/net/phy/microchip_t1.c
index 796fbcb7dafe..d4c93d59bc53 100644
--- a/drivers/net/phy/microchip_t1.c
+++ b/drivers/net/phy/microchip_t1.c
@@ -792,6 +792,8 @@  static struct phy_driver microchip_t1_phy_driver[] = {
 		.flags          = PHY_POLL_CABLE_TEST,
 		.features	= PHY_BASIC_T1_FEATURES,
 		.config_init	= lan87xx_config_init,
+		.config_intr    = lan87xx_phy_config_intr,
+		.handle_interrupt = lan87xx_handle_interrupt,
 		.suspend	= genphy_suspend,
 		.resume		= genphy_resume,
 		.config_aneg    = lan87xx_config_aneg,