[lkml]   [2005]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH scsi-misc-2.6 08/08] scsi: fix hot unplug sequence
On Wed, 2005-03-23 at 11:14 +0900, Tejun Heo wrote:
> When hot-unplugging using scsi_remove_host() function (as usb
> does), scsi_forget_host() used to be called before
> scsi_host_cancel(). So, the device gets removed first without
> request cleanup and scsi_host_cancel() never gets to call
> scsi_device_cancel() on the removed devices. This results in
> premature completion of hot-unplugging process with active
> requests left in queue, eventually leading to hang/offlined
> device or oops when the active command times out.
> This patch makes scsi_remove_host() call scsi_host_cancel()
> first such that the host is first transited into cancel state
> and all requests of all devices are killed, and then, the
> devices are removed. This patch fixes the oops in eh after
> hot-unplugging bug.

This is actually simply reversing this patch:

And all it does is give us the previous consequences back.

The oops isn't in the eh it's in the usb-storage eh routine.

However, the current host code does need fixing, but the fix is to move
it over to a proper state model rather than the current bit twiddling we


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-04-06 13:30    [W:0.125 / U:0.292 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site