linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net] net: lan966x: Make sure to release ptp interrupt
@ 2022-04-13 19:57 Horatiu Vultur
  2022-04-15 19:01 ` Jakub Kicinski
  2022-04-15 21:50 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 4+ messages in thread
From: Horatiu Vultur @ 2022-04-13 19:57 UTC (permalink / raw)
  To: netdev, linux-kernel; +Cc: UNGLinuxDriver, davem, kuba, pabeni, Horatiu Vultur

When the lan966x driver is removed make sure to remove also the ptp_irq
IRQ.

Fixes: e85a96e48e3309 ("net: lan966x: Add support for ptp interrupts")
Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
---
 drivers/net/ethernet/microchip/lan966x/lan966x_main.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/ethernet/microchip/lan966x/lan966x_main.c b/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
index 958e55596b82..95830e3e2b1f 100644
--- a/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
+++ b/drivers/net/ethernet/microchip/lan966x/lan966x_main.c
@@ -671,6 +671,9 @@ static void lan966x_cleanup_ports(struct lan966x *lan966x)
 		disable_irq(lan966x->ana_irq);
 		lan966x->ana_irq = -ENXIO;
 	}
+
+	if (lan966x->ptp_irq)
+		devm_free_irq(lan966x->dev, lan966x->ptp_irq, lan966x);
 }
 
 static int lan966x_probe_port(struct lan966x *lan966x, u32 p,
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH net] net: lan966x: Make sure to release ptp interrupt
  2022-04-13 19:57 [PATCH net] net: lan966x: Make sure to release ptp interrupt Horatiu Vultur
@ 2022-04-15 19:01 ` Jakub Kicinski
  2022-04-19  6:30   ` Horatiu Vultur
  2022-04-15 21:50 ` patchwork-bot+netdevbpf
  1 sibling, 1 reply; 4+ messages in thread
From: Jakub Kicinski @ 2022-04-15 19:01 UTC (permalink / raw)
  To: Horatiu Vultur; +Cc: netdev, linux-kernel, UNGLinuxDriver, davem, pabeni

On Wed, 13 Apr 2022 21:57:16 +0200 Horatiu Vultur wrote:
> When the lan966x driver is removed make sure to remove also the ptp_irq
> IRQ.

I presume it's because you want to disable the IRQ so it doesn't fire
during / after remove? Would be good to have such justifications
spelled out in the commit message in the future!

> Fixes: e85a96e48e3309 ("net: lan966x: Add support for ptp interrupts")
> Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net] net: lan966x: Make sure to release ptp interrupt
  2022-04-13 19:57 [PATCH net] net: lan966x: Make sure to release ptp interrupt Horatiu Vultur
  2022-04-15 19:01 ` Jakub Kicinski
@ 2022-04-15 21:50 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 4+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-04-15 21:50 UTC (permalink / raw)
  To: Horatiu Vultur; +Cc: netdev, linux-kernel, UNGLinuxDriver, davem, kuba, pabeni

Hello:

This patch was applied to netdev/net.git (master)
by Jakub Kicinski <kuba@kernel.org>:

On Wed, 13 Apr 2022 21:57:16 +0200 you wrote:
> When the lan966x driver is removed make sure to remove also the ptp_irq
> IRQ.
> 
> Fixes: e85a96e48e3309 ("net: lan966x: Add support for ptp interrupts")
> Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
> ---
>  drivers/net/ethernet/microchip/lan966x/lan966x_main.c | 3 +++
>  1 file changed, 3 insertions(+)

Here is the summary with links:
  - [net] net: lan966x: Make sure to release ptp interrupt
    https://git.kernel.org/netdev/net/c/d08ed852560e

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net] net: lan966x: Make sure to release ptp interrupt
  2022-04-15 19:01 ` Jakub Kicinski
@ 2022-04-19  6:30   ` Horatiu Vultur
  0 siblings, 0 replies; 4+ messages in thread
From: Horatiu Vultur @ 2022-04-19  6:30 UTC (permalink / raw)
  To: Jakub Kicinski; +Cc: netdev, linux-kernel, UNGLinuxDriver, davem, pabeni

The 04/15/2022 21:01, Jakub Kicinski wrote:
> 
> On Wed, 13 Apr 2022 21:57:16 +0200 Horatiu Vultur wrote:
> > When the lan966x driver is removed make sure to remove also the ptp_irq
> > IRQ.
> 
> I presume it's because you want to disable the IRQ so it doesn't fire
> during / after remove? Would be good to have such justifications
> spelled out in the commit message in the future!

Sorry about this. I will improve the commit messages in the future.

> 
> > Fixes: e85a96e48e3309 ("net: lan966x: Add support for ptp interrupts")
> > Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>

-- 
/Horatiu

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-04-19  6:27 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-13 19:57 [PATCH net] net: lan966x: Make sure to release ptp interrupt Horatiu Vultur
2022-04-15 19:01 ` Jakub Kicinski
2022-04-19  6:30   ` Horatiu Vultur
2022-04-15 21:50 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).