On Wed, 24 Sep 2014 14:50:41 +0200
Gerd Hoffmann <kra...@redhat.com> wrote:

> On Mi, 2014-09-24 at 11:48 +0000, Igor Mammedov wrote:
> > usb-storage uses SCSI bus to provide underling storage
> > (i.e. scsi-disk) and it's hotpluggable.
> 
> No.  usb-storage itself (the scsi hba) is hotpluggable, but the scsi
> devices connected are not.
Agree,
I'm sorry for my bad English, under "it's hotpluggable" I've meant
usb-storage.

> 
> On the qemu side it isn't a problem, but the protocol has constrains.
> First there is no way to signal devices coming and going, so the guest
> wouldn't see them until reboot (or manual driver reload).  Second for
> multi-lun devices only the number of luns is reported and devices are
> expected to have luns 0 .. $count-1.  So with three devices connected
> and the second being hot-unplugged you end up with an illegal
> configuration.
> 
> Therefore device initialization (IIRC) goes like this today:
> 
>   (1) add hba (i.e. usb-storage).
>   (2) add scsi device.
>   (3) turn off hotplug on the scsi bus.
>   (4) make the whole thing visible to the guest (usb_attach_device).
> 
> cheers,
>   Gerd
> 
> 


Reply via email to