* [PATCH] net: gemini: add missed free_netdev
@ 2019-11-15 6:24 Chuhong Yuan
2019-11-15 9:50 ` Linus Walleij
2019-11-16 20:54 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Chuhong Yuan @ 2019-11-15 6:24 UTC (permalink / raw)
Cc: Hans Ulli Kroll, Linus Walleij, David S . Miller,
linux-arm-kernel, netdev, linux-kernel, Chuhong Yuan
This driver forgets to free allocated netdev in remove like
what is done in probe failure.
Add the free to fix it.
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
---
drivers/net/ethernet/cortina/gemini.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/cortina/gemini.c b/drivers/net/ethernet/cortina/gemini.c
index e736ce2c58ca..a8f4c69252ff 100644
--- a/drivers/net/ethernet/cortina/gemini.c
+++ b/drivers/net/ethernet/cortina/gemini.c
@@ -2524,6 +2524,7 @@ static int gemini_ethernet_port_remove(struct platform_device *pdev)
struct gemini_ethernet_port *port = platform_get_drvdata(pdev);
gemini_port_remove(port);
+ free_netdev(port->netdev);
return 0;
}
--
2.24.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] net: gemini: add missed free_netdev
2019-11-15 6:24 [PATCH] net: gemini: add missed free_netdev Chuhong Yuan
@ 2019-11-15 9:50 ` Linus Walleij
2019-11-16 20:54 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: Linus Walleij @ 2019-11-15 9:50 UTC (permalink / raw)
To: Chuhong Yuan
Cc: Hans Ulli Kroll, David S . Miller, Linux ARM, netdev, linux-kernel
On Fri, Nov 15, 2019 at 7:25 AM Chuhong Yuan <hslester96@gmail.com> wrote:
> This driver forgets to free allocated netdev in remove like
> what is done in probe failure.
> Add the free to fix it.
>
> Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Looks correct!
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] net: gemini: add missed free_netdev
2019-11-15 6:24 [PATCH] net: gemini: add missed free_netdev Chuhong Yuan
2019-11-15 9:50 ` Linus Walleij
@ 2019-11-16 20:54 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2019-11-16 20:54 UTC (permalink / raw)
To: hslester96
Cc: ulli.kroll, linus.walleij, linux-arm-kernel, netdev, linux-kernel
From: Chuhong Yuan <hslester96@gmail.com>
Date: Fri, 15 Nov 2019 14:24:54 +0800
> This driver forgets to free allocated netdev in remove like
> what is done in probe failure.
> Add the free to fix it.
>
> Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Applied and queued up for -stable, thank you.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-11-16 20:54 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-15 6:24 [PATCH] net: gemini: add missed free_netdev Chuhong Yuan
2019-11-15 9:50 ` Linus Walleij
2019-11-16 20:54 ` David Miller
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).