[libvirt] [PATCH v3 15/26] qemu: Automatically pick target index and model for pci-root controllers
Shivaprasad bhat
shivaprasadbhat at gmail.com
Mon Jun 26 08:49:06 UTC 2017
>
>
> +/**
> + * qemuDomainAddressFindNewTargetIndex:
> + * @def: domain definition
> + *
> + * Find a target index that can be used for a PCI controller.
> + *
> + * Returns: an unused target index, or -1 if all available target
> + * indexes are already taken.
> + */
> +static int
> +qemuDomainAddressFindNewTargetIndex(virDomainDefPtr def)
>
May be rename to qemuDomainAddressFindNewPCIRootTargetIndex ?
+{
> + int idx;
> + int ret = -1;
> +
> + /* Try all indexes between 1 and 31 - QEMU only supports 32
> + * PHBs, and 0 is reserved for the default, implicit one */
> + for (idx = 1; idx <= 31; idx++) {
> + bool found = false;
> + size_t i;
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20170626/88f08f2d/attachment-0001.htm>
More information about the libvir-list
mailing list