Re: [PATCH] usb: Remove redundant 'flush_workqueue()' calls

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/12/21 9:30 AM, Christophe JAILLET wrote:
'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: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
---
  drivers/usb/chipidea/otg.c           | 5 ++---
  drivers/usb/gadget/udc/mv_udc_core.c | 4 +---
  drivers/usb/host/u132-hcd.c          | 1 -
  drivers/usb/phy/phy-mv-usb.c         | 5 +----
  drivers/usb/usbip/usbip_event.c      | 1 -
  5 files changed, 4 insertions(+), 12 deletions(-)


diff --git a/drivers/usb/usbip/usbip_event.c b/drivers/usb/usbip/usbip_event.c
index 086ca76dd053..26513540bcdb 100644
--- a/drivers/usb/usbip/usbip_event.c
+++ b/drivers/usb/usbip/usbip_event.c
@@ -137,7 +137,6 @@ int usbip_init_eh(void)
void usbip_finish_eh(void)
  {
-	flush_workqueue(usbip_queue);
  	destroy_workqueue(usbip_queue);
  	usbip_queue = NULL;
  }


Might be better to generate per driver patches.

Looks good to me. For the usbip change in this patch:

Acked-by: Shuah Khan <skhan@xxxxxxxxxxxxxxxxxxx>

thanks,
-- Shuah



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux