]> www.infradead.org Git - nvme.git/commitdiff
power: supply: mt6370: Remove redundant 'flush_workqueue()' calls
authorChen Ni <nichen@iscas.ac.cn>
Wed, 12 Mar 2025 07:37:29 +0000 (15:37 +0800)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Mon, 17 Mar 2025 15:00:09 +0000 (16:00 +0100)
'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>
Link: https://lore.kernel.org/r/20250312073729.1430053-1-nichen@iscas.ac.cn
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/mt6370-charger.c

index a6939c6059c7fd0da08087d87fdaf2244914d222..98579998b300db41bde9bd528d5b6d3e484be8be 100644 (file)
@@ -772,7 +772,6 @@ static void mt6370_chg_destroy_wq(void *data)
 {
        struct workqueue_struct *wq = data;
 
-       flush_workqueue(wq);
        destroy_workqueue(wq);
 }