mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-10-30 09:53:10 +00:00
pci: rename virPCIParseDeviceAddress and make it public
This function has utility outside of virpci.c, so make it public. Also the name didn't fit convention, so change it to virPCIDeviceAddressParse.
This commit is contained in:
parent
1d829e1306
commit
31a4a679b3
@ -1694,6 +1694,7 @@ virObjectUnref;
|
|||||||
|
|
||||||
# util/virpci.h
|
# util/virpci.h
|
||||||
virPCIDeviceAddressGetSysfsFile;
|
virPCIDeviceAddressGetSysfsFile;
|
||||||
|
virPCIDeviceAddressParse;
|
||||||
virPCIDeviceCopy;
|
virPCIDeviceCopy;
|
||||||
virPCIDeviceDetach;
|
virPCIDeviceDetach;
|
||||||
virPCIDeviceFileIterate;
|
virPCIDeviceFileIterate;
|
||||||
|
@ -2046,8 +2046,8 @@ logStrToLong_ui(char const *s,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
int
|
||||||
virPCIParseDeviceAddress(char *address,
|
virPCIDeviceAddressParse(char *address,
|
||||||
virPCIDeviceAddressPtr bdf)
|
virPCIDeviceAddressPtr bdf)
|
||||||
{
|
{
|
||||||
char *p = NULL;
|
char *p = NULL;
|
||||||
@ -2111,7 +2111,7 @@ virPCIGetDeviceAddressFromSysfsLink(const char *device_link,
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (virPCIParseDeviceAddress(config_address, *bdf) != 0) {
|
if (virPCIDeviceAddressParse(config_address, *bdf) != 0) {
|
||||||
virReportError(VIR_ERR_INTERNAL_ERROR,
|
virReportError(VIR_ERR_INTERNAL_ERROR,
|
||||||
_("Failed to parse PCI config address '%s'"),
|
_("Failed to parse PCI config address '%s'"),
|
||||||
config_address);
|
config_address);
|
||||||
|
@ -152,6 +152,8 @@ int virPCIGetAddrString(unsigned int domain,
|
|||||||
char **pciConfigAddr)
|
char **pciConfigAddr)
|
||||||
ATTRIBUTE_NONNULL(5) ATTRIBUTE_RETURN_CHECK;
|
ATTRIBUTE_NONNULL(5) ATTRIBUTE_RETURN_CHECK;
|
||||||
|
|
||||||
|
int virPCIDeviceAddressParse(char *address, virPCIDeviceAddressPtr bdf);
|
||||||
|
|
||||||
int virPCIGetVirtualFunctionInfo(const char *vf_sysfs_device_path,
|
int virPCIGetVirtualFunctionInfo(const char *vf_sysfs_device_path,
|
||||||
char **pfname, int *vf_index);
|
char **pfname, int *vf_index);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user