Commit 391d0ad
net: gemini: Fix missing free_netdev() in error path of gemini_ethernet_port_probe()
[ Upstream commit cf96d97 ]
Replace alloc_etherdev_mq with devm_alloc_etherdev_mqs. In this way,
when probe fails, netdev can be freed automatically.
Fixes: 4d5ae32 ("net: ethernet: Add a driver for Gemini gigabit ethernet")
Reported-by: Hulk Robot <[email protected]>
Signed-off-by: Wang Hai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>1 parent 676f44c commit 391d0ad
1 file changed
+1
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2392 | 2392 | | |
2393 | 2393 | | |
2394 | 2394 | | |
2395 | | - | |
| 2395 | + | |
2396 | 2396 | | |
2397 | 2397 | | |
2398 | 2398 | | |
| |||
2526 | 2526 | | |
2527 | 2527 | | |
2528 | 2528 | | |
2529 | | - | |
2530 | 2529 | | |
2531 | 2530 | | |
2532 | 2531 | | |
| |||
2535 | 2534 | | |
2536 | 2535 | | |
2537 | 2536 | | |
2538 | | - | |
2539 | 2537 | | |
2540 | 2538 | | |
2541 | 2539 | | |
| |||
0 commit comments