Linux-USB Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH 0/6] USB: iowarrior: disconnect fixes and locking cleanups
@ 2019-10-09 10:48 Johan Hovold
  2019-10-09 10:48 ` [PATCH 1/6] USB: iowarrior: fix use-after-free on disconnect Johan Hovold
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: Johan Hovold @ 2019-10-09 10:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Oliver Neukum, Valentin Vidic, linux-usb, linux-kernel, Johan Hovold

This series fixes a use-after-free bug introduced by a recent
disconnect-deadlock fix that was reported by syzbot. Turns out there was
already a related bug in the driver, and the first patch addresses both
issues.

While looking at the code I found two more use-after-free bugs, which
the next two patches fix.

The next two clean up the driver by dropping two redundant locks.

Tested using a mockup device.

Johan


Johan Hovold (6):
  USB: iowarrior: fix use-after-free on disconnect
  USB: iowarrior: fix use-after-free on release
  USB: iowarrior: fix use-after-free after driver unbind
  USB: iowarrior: drop redundant disconnect mutex
  USB: iowarrior: drop redundant iowarrior mutex
  USB: iowarrior: use pr_err()

 drivers/usb/misc/iowarrior.c | 48 +++++++++++-------------------------
 1 file changed, 15 insertions(+), 33 deletions(-)

-- 
2.23.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, back to index

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-09 10:48 [PATCH 0/6] USB: iowarrior: disconnect fixes and locking cleanups Johan Hovold
2019-10-09 10:48 ` [PATCH 1/6] USB: iowarrior: fix use-after-free on disconnect Johan Hovold
2019-10-09 10:48 ` [PATCH 2/6] USB: iowarrior: fix use-after-free on release Johan Hovold
2019-10-09 10:48 ` [PATCH 3/6] USB: iowarrior: fix use-after-free after driver unbind Johan Hovold
2019-10-09 10:48 ` [PATCH 4/6] USB: iowarrior: drop redundant disconnect mutex Johan Hovold
2019-10-09 10:48 ` [PATCH 5/6] USB: iowarrior: drop redundant iowarrior mutex Johan Hovold
2019-10-09 10:48 ` [PATCH 6/6] USB: iowarrior: use pr_err() Johan Hovold
2019-10-10 10:45 ` [PATCH 0/6] USB: iowarrior: disconnect fixes and locking cleanups Greg Kroah-Hartman

Linux-USB Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-usb/0 linux-usb/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-usb linux-usb/ https://lore.kernel.org/linux-usb \
		linux-usb@vger.kernel.org
	public-inbox-index linux-usb

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-usb


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git