[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v3 7/7] libxl: Add interface for querying hypervisor about PCI topology
On 02/13/2015 07:43 AM, Wei Liu wrote: On Mon, Feb 09, 2015 at 03:04:35PM -0500, Boris Ostrovsky wrote: [...]+#ifdef LIBXL_HAVE_PCITOPO +libxl_pcitopology *libxl_get_pci_topology(libxl_ctx *ctx, int *num_devs) +{ + GC_INIT(ctx); + physdev_pci_device_t *devs; + uint8_t *nodes; + libxl_pcitopology *ret = NULL; + int i, rc; + + *num_devs = libxl__pci_numdevs(gc); + if (*num_devs <= 0) { + LOG(ERROR, "Unable to determine number of PCI devices");Is 0 an error? What if the system actually have no PCI devices? Right, zero should be a non-error value. -boris The rest looks OK to me. Wei. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |