USB: iowarrior: drop redundant disconnect mutex
authorJohan Hovold <johan@kernel.org>
Wed, 9 Oct 2019 10:48:44 +0000 (12:48 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 10 Oct 2019 10:45:06 +0000 (12:45 +0200)
commit7c5b971d623fdb40c03205e99f9ef68002b34726
treecf70ffb402c783466d0a1dfb96409e8e887bca77
parentb5f8d46867ca233d773408ffbe691a8062ed718f
USB: iowarrior: drop redundant disconnect mutex

Drop the redundant disconnect mutex which was introduced after the
open-disconnect race had been addressed generally in USB core by commit
d4ead16f50f9 ("USB: prevent char device open/deregister race").

Specifically, the rw-semaphore in core guarantees that all calls to
open() will have completed and that no new calls to open() will occur
after usb_deregister_dev() returns. Hence there is no need use the
driver data as an inverted disconnected flag.

Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://lore.kernel.org/r/20191009104846.5925-5-johan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/misc/iowarrior.c