]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
octeontx2-af: mcs: Remove redundant 'flush_workqueue()' calls
authorChen Ni <nichen@iscas.ac.cn>
Mon, 24 Mar 2025 08:08:54 +0000 (16:08 +0800)
committerJakub Kicinski <kuba@kernel.org>
Tue, 25 Mar 2025 16:24:40 +0000 (09:24 -0700)
'destroy_workqueue()' already drains the queue before destroying it, so
there is no need to flush it explicitly.

Remove the redundant 'flush_workqueue()' calls.

This was generated with coccinelle:

@@
expression E;
@@

- flush_workqueue(E);
  destroy_workqueue(E);

Signed-off-by: Chen Ni <nichen@iscas.ac.cn>
Reviewed-by: Geetha sowjanya <gakula@marvell.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20250324080854.408188-1-nichen@iscas.ac.cn
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/marvell/octeontx2/af/mcs_rvu_if.c

index d39d86e694ccf7530237a904315a294726cf55f8..655dd4726d36efb52313895e7ccf7e3c587dbf1b 100644 (file)
@@ -925,7 +925,6 @@ void rvu_mcs_exit(struct rvu *rvu)
        if (!rvu->mcs_intr_wq)
                return;
 
-       flush_workqueue(rvu->mcs_intr_wq);
        destroy_workqueue(rvu->mcs_intr_wq);
        rvu->mcs_intr_wq = NULL;
 }