diff options
author | Yevhen Orlov <yevhen.orlov@plvision.eu> | 2022-10-01 12:34:12 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2022-10-03 17:14:52 -0700 |
commit | 90b6f9c098512b72b77028893e42f60316409fb1 (patch) | |
tree | 9031aa93f5867e71b0b9f70ca55895853b432ee9 /drivers/net/ethernet/marvell/prestera/prestera_router.c | |
parent | 333fe4d033fa5aac139f66d8f185877f47427c3d (diff) | |
download | lwn-90b6f9c098512b72b77028893e42f60316409fb1.tar.gz lwn-90b6f9c098512b72b77028893e42f60316409fb1.zip |
net: marvell: prestera: add delayed wq and flush wq on deinit
Flushing workqueues ensures, that no more pending works, related to just
unregistered or deinitialized notifiers. After that we can free memory.
Delayed wq will be used for neighbours in next patches.
Co-developed-by: Taras Chornyi <tchornyi@marvell.com>
Signed-off-by: Taras Chornyi <tchornyi@marvell.com>
Co-developed-by: Oleksandr Mazur <oleksandr.mazur@plvision.eu>
Signed-off-by: Oleksandr Mazur <oleksandr.mazur@plvision.eu>
Signed-off-by: Yevhen Orlov <yevhen.orlov@plvision.eu>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/marvell/prestera/prestera_router.c')
-rw-r--r-- | drivers/net/ethernet/marvell/prestera/prestera_router.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/marvell/prestera/prestera_router.c b/drivers/net/ethernet/marvell/prestera/prestera_router.c index b4fd8276bbce..9625c5870847 100644 --- a/drivers/net/ethernet/marvell/prestera/prestera_router.c +++ b/drivers/net/ethernet/marvell/prestera/prestera_router.c @@ -639,6 +639,7 @@ void prestera_router_fini(struct prestera_switch *sw) unregister_fib_notifier(&init_net, &sw->router->fib_nb); unregister_inetaddr_notifier(&sw->router->inetaddr_nb); unregister_inetaddr_validator_notifier(&sw->router->inetaddr_valid_nb); + prestera_queue_drain(); prestera_k_arb_abort(sw); |