]> err.no Git - linux-2.6/commit
[PATCH] usb-storage: fix race between reset and disconnect
authorAlan Stern <stern@rowland.harvard.edu>
Mon, 19 Jun 2006 18:50:15 +0000 (14:50 -0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 12 Jul 2006 23:03:21 +0000 (16:03 -0700)
commiteecd11ed47c8c9bd8e7e3dff35baccae18dd0d84
tree7d91cf5b80a59ff84cdd2bf5f4ae96e82e026276
parent3dd2ae81f70f191f5b6751d18fdfe61dbafda7e8
[PATCH] usb-storage: fix race between reset and disconnect

My recent patch converting usb-storage to use
usb_reset_composite_device() added a bug, a race between reset and
disconnect.  It was necessary to drop the private lock while executing a
reset, and if a disconnect occurs at that time it will cause a crash.

This patch (as722) fixes the problem by explicitly checking for an early
termination after executing each command.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/storage/usb.c