Skip to content
Commit 226173ed authored by Matthew Dharm's avatar Matthew Dharm Committed by Greg Kroah-Hartman
Browse files

[PATCH] USB: storage: Fix messed-up locking



This is patch as550 from Alan Stern.

Apparently someone changed the SCSI core so that it no longer holds the
host lock when doing a device or bus reset.  usb-storage was updated at
the time, but the change was done carelessly.  Some of the code depends
on that lock being held.

This patch reintroduces the host lock where needed and tries to clarify
the comments explaining why the lock is necessary.  It also moves the
code that clears the TIMED_OUT and ABORTING bitflags so that it executes
as soon as the timed-out command has completed (and while the host lock
is held).

Signed-off-by: default avatarAlan Stern <stern@rowland.harvard.edu>
Signed-off-by: default avatarMatthew Dharm <mdharm-usb@one-eyed-alien.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent b789696a
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment