[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 26/30] usb-storage: make its storage SCSI bus ho
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH 26/30] usb-storage: make its storage SCSI bus hotpluggable explicitly |
Date: |
Wed, 24 Sep 2014 14:30:53 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0 |
Il 24/09/2014 13:48, Igor Mammedov ha scritto:
> usb-storage uses SCSI bus to provide underling storage
> (i.e. scsi-disk) and it's hotpluggable. In addition
> during usb-storage hotplug bus_add_child() won't allow
> to add scsi-disk to SCSI bus owned by usb-storage
> if bus is not hotpluggable.
>
> By default SCSI bus was alway hotpluggable even if
> an owner didn't support hotplug. It will change
> once BusState.allow_hotplug field is dropped and
> SCSI bus will be only hotpluggable only if bus owner
> implements HOTPLUG_HANDLER interface.
>
> So make usb-storage implement HOTPLUG_HANDLER interface
> to keep its SCSI bus hotpluggable.
Correct. usb-bot unfortunately is not hot-pluggable because we would
plug it with no SCSI LUN inside. The guest would not be able to access
it. We would have to delay the presentation of the usb-bot device until
after the LUN is there. Perhaps some kind of transaction mechanism?
However, usb-storage builds the outer USB device and the inner SCSI
device at the same time, so it can be hot-plugged.
What you do for usb-storage should also be done for lsi, esp, usb-uas, etc.
Paolo
- Re: [Qemu-devel] [PATCH 23/30] scsi: convert virtio-scsi HBA to hotplug handler API, (continued)
[Qemu-devel] [PATCH 26/30] usb-storage: make its storage SCSI bus hotpluggable explicitly, Igor Mammedov, 2014/09/24
[Qemu-devel] [PATCH 30/30] qdev: HotplugHandler: add support for unplugging BUS-less devices, Igor Mammedov, 2014/09/24
[Qemu-devel] [PATCH 16/30] virtio-serial: convert to hotplug-handler API, Igor Mammedov, 2014/09/24
[Qemu-devel] [PATCH 27/30] usb-storage: drop not needed "allow_hotplug = 0", Igor Mammedov, 2014/09/24