[Engine-devel] Stable PCI Addresses design wiki
Livnat Peer
lpeer at redhat.com
Thu Dec 1 10:22:50 UTC 2011
On 11/30/2011 05:54 PM, Daniel P. Berrange wrote:
> On Wed, Nov 30, 2011 at 10:06:37AM -0500, Eli Mesika wrote:
>> http://www.ovirt.org/wiki/Features/Design/StablePCIAddresses
>
> My primary comment on this is that you likely don't want to restrict
> yourself to PCI addresses.
>
> If RHEVM intends to use virtio-serial controllers you want to maintain
> stable virtio serial addresses
>
> If RHEVM intends to use CCID smartcard controllers you want to maintain
> stable CCID device addresses
>
> If RHEVM intends to use SCSI controllers you will want to maintain
> SCSI drive addresses
>
> If RHEVM intends to use USB controllers you will want to maintain
> USB device addresses
>
> I think you get the idea :-) In general you can say that every single
> device listed in the XML will ultimately have an address associated
> with it. The type address will vary depending on what type of controller
> the device is attached to.
>
> In addition, when you start dealing with these other non-PCI address
> types, you will also need to start dealing with controller devices.
>
> eg, if you add a SCSI disk to the XML
>
> <disk type='file' device='disk'>
> <driver name='qemu' type='raw'/>
> <source file='/var/lib/libvirt/images/test/disk0.raw'/>
> <target dev='sda' bus='scsi'/>
> </disk>
>
> First of all libvirt will want to assign an address to this drive
>
> <disk type='file' device='disk'>
> <driver name='qemu' type='raw'/>
> <source file='/var/lib/libvirt/images/test/disk0.raw'/>
> <target dev='sda' bus='scsi'/>
> <address type='drive' controller='0' bus='0' unit='0'/>
> </disk>
>
> Then, if the corresponding controller does not exist already, libvirt
> will auto-add a controller device, which itself has an address you will
> need to track:
>
> <controller type='scsi' index='0'>
> <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
> </controller>
>
>
> In addition, when QEMU gains support for PCI bridges, or multiple PCI
> root complexes, there will also be the possibility of dealing with
> multiple PCI controllers in the XML too.
>
> So even if you only implement PCI address support in the first iteration,
> I'd really encourage you to at least consider how you will cope with the
> other address types sooner, rather than later.
>
> Regards,
> Daniel
Hi Eli,
- I suggest changing the feature name from stable PCI addresses to
stable device addresses, then document which devices are supported. I
think the first version includes PCI, VirtIO Serial, SCSI, IDE, CCID,
actually anything libvirt supports - right?
- I am missing in the documentation the format of the device addresses
as interchanged between RHEVM and VDSM, specifically i am interested why
use XML and not JSON format for that data.
Thanks, Livnat
More information about the Devel
mailing list