lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CA+zupgz3JXoxUEHiezEHenTZXSRJ5A2HHjCTvYoo+DqvL9=C-Q@mail.gmail.com>
Date: Tue, 4 Feb 2025 15:36:02 -0800
From: Roy Luo <royluo@...gle.com>
To: Thinh Nguyen <Thinh.Nguyen@...opsys.com>
Cc: "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>, 
	"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>, 
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>, 
	"andre.draszik@...aro.org" <andre.draszik@...aro.org>, "elder@...nel.org" <elder@...nel.org>, 
	"stern@...land.harvard.edu" <stern@...land.harvard.edu>, "crwulff@...il.com" <crwulff@...il.com>, 
	"paul@...pouillou.net" <paul@...pouillou.net>, 
	"jkeeping@...usicbrands.com" <jkeeping@...usicbrands.com>, 
	"yuanlinyu@...onor.com" <yuanlinyu@...onor.com>
Subject: Re: [PATCH v1] usb: gadget: core: flush gadget workqueue after device removal

On Mon, Feb 3, 2025 at 4:55 PM Thinh Nguyen <Thinh.Nguyen@...opsys.com> wrote:
>
> On Tue, Feb 04, 2025, Roy Luo wrote:
> > usb_del_gadget() can lead to new work being scheduled in gadget->work
> > workqueue. This is observed, for example, with the dwc3 driver with the
> > following call stack:
> >   device_del()
> >     gadget_unbind_driver()
> >       usb_gadget_disconnect_locked()
> >         dwc3_gadget_pullup()
> >         dwc3_gadget_soft_disconnect()
> >           usb_gadget_set_state()
> >             schedule_work(&gadget->work)
> >
> > Move flush_work() after device_del() to ensure the workqueue is cleaned
> > up.
> >
> > Fixes: 1ff24d40b3c3 ("usb: dwc3: gadget: Fix incorrect UDC state after manual deconfiguration")
>
> The reference should be targeting the udc core. Probably want to Cc
> stable also.
>

Thanks for the review, sending out v2.

Regards,
Roy Luo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ