libvirt/src/libxl
Daniel Henrique Barboza b0264e9404 virpci.c: simplify virPCIDeviceNew() signature
The current virPCIDeviceNew() signature, receiving 4 uints in sequence
(domain, bus, slot, function), is not neat.

We already have a way to represent a PCI address in virPCIDeviceAddress
that is used in the code. Aside from the test files, most of
virPCIDeviceNew() callers have access to a virPCIDeviceAddress reference,
but then we need to retrieve the 4 required uints (addr.domain, addr.bus,
addr.slot, addr.function) to satisfy virPCIDeviceNew(). The result is
that we have extra verbosity/boilerplate to retrieve an information that
is already available in virPCIDeviceAddress.

A better way is presented by virNVMEDeviceNew(), where the caller just
supplies a virPCIDeviceAddress pointer and the function handles the
details internally.

This patch changes virPCIDeviceNew() to receive a virPCIDeviceAddress
pointer instead of 4 uints.

Reviewed-by: Laine Stump <laine@redhat.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2021-01-29 17:52:10 -03:00
..
libvirtd_libxl.aug
libxl_capabilities.c Fix incorrect g_new0 conversions 2020-10-06 14:26:43 +02:00
libxl_capabilities.h
libxl_conf.c conf: Add VIR_STORAGE_NET_PROTOCOL_NFS disk protocol type 2021-01-08 15:03:16 +01:00
libxl_conf.h
libxl_domain.c libxl: remove a now-unnecessary ret variable and cleanup: label. 2021-01-08 11:35:04 -05:00
libxl_domain.h
libxl_driver.c virpci.c: simplify virPCIDeviceNew() signature 2021-01-29 17:52:10 -03:00
libxl_driver.h
libxl_logger.c util: hash: Retire 'virHashTable' in favor of 'GHashTable' 2020-11-06 10:40:51 +01:00
libxl_logger.h
libxl_migration.c libxl: adopt to VIR_DRV_SUPPORTS_FEATURE return -1 2021-01-06 17:10:05 +03:00
libxl_migration.h
libxl.conf
meson.build util: extract virStorageFile code into storage_source 2021-01-22 11:10:27 +01:00
test_libvirtd_libxl.aug.in
virtxend.init.in
virtxend.service.in
virtxend.sysconf
xen_common.c xen: recognize device_model_override 2020-12-07 15:38:31 -07:00
xen_common.h
xen_xl.c util: extract virStorageFile code into storage_source 2021-01-22 11:10:27 +01:00
xen_xl.h
xen_xm.c domain_conf: make virDomainDiskSetDriver() void 2020-11-11 12:53:11 +01:00
xen_xm.h
xenxs_private.h