Adopt the same names used for virHostdevReAttach*Devices() for
consistency's sake and to make it easier to jump between the two.
No functional changes.
---
src/qemu/qemu_hostdev.c | 40 ++++++++++++++++++++--------------------
src/qemu/qemu_hostdev.h | 30 +++++++++++++++---------------
src/qemu/qemu_hotplug.c | 12 ++++++------
src/qemu/qemu_process.c | 2 +-
4 files changed, 42 insertions(+), 42 deletions(-)
diff --git a/src/qemu/qemu_hostdev.c b/src/qemu/qemu_hostdev.c
index 8886407..16945c7 100644
--- a/src/qemu/qemu_hostdev.c
+++ b/src/qemu/qemu_hostdev.c
@@ -309,10 +309,10 @@ qemuHostdevPrepareDomainDevices(virQEMUDriverPtr driver,
}
void
-qemuDomainReAttachHostdevDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs)
+qemuHostdevReAttachPCIDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs)
{
virQEMUDriverConfigPtr cfg = virQEMUDriverGetConfig(driver);
const char *oldStateDir = cfg->stateDir;
@@ -325,10 +325,10 @@ qemuDomainReAttachHostdevDevices(virQEMUDriverPtr driver,
}
void
-qemuDomainReAttachHostUSBDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs)
+qemuHostdevReAttachUSBDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs)
{
virHostdevManagerPtr hostdev_mgr = driver->hostdevMgr;
@@ -337,10 +337,10 @@ qemuDomainReAttachHostUSBDevices(virQEMUDriverPtr driver,
}
void
-qemuDomainReAttachHostSCSIDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs)
+qemuHostdevReAttachSCSIDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs)
{
size_t i;
virHostdevManagerPtr hostdev_mgr = driver->hostdevMgr;
@@ -360,18 +360,18 @@ qemuDomainReAttachHostSCSIDevices(virQEMUDriverPtr driver,
}
void
-qemuDomainReAttachHostDevices(virQEMUDriverPtr driver,
- virDomainDefPtr def)
+qemuHostdevReAttachDomainDevices(virQEMUDriverPtr driver,
+ virDomainDefPtr def)
{
if (!def->nhostdevs)
return;
- qemuDomainReAttachHostdevDevices(driver, def->name, def->hostdevs,
- def->nhostdevs);
+ qemuHostdevReAttachPCIDevices(driver, def->name, def->hostdevs,
+ def->nhostdevs);
- qemuDomainReAttachHostUSBDevices(driver, def->name, def->hostdevs,
- def->nhostdevs);
+ qemuHostdevReAttachUSBDevices(driver, def->name, def->hostdevs,
+ def->nhostdevs);
- qemuDomainReAttachHostSCSIDevices(driver, def->name, def->hostdevs,
- def->nhostdevs);
+ qemuHostdevReAttachSCSIDevices(driver, def->name, def->hostdevs,
+ def->nhostdevs);
}
diff --git a/src/qemu/qemu_hostdev.h b/src/qemu/qemu_hostdev.h
index e1f7998..b4514dc 100644
--- a/src/qemu/qemu_hostdev.h
+++ b/src/qemu/qemu_hostdev.h
@@ -56,20 +56,20 @@ int qemuHostdevPrepareDomainDevices(virQEMUDriverPtr driver,
virDomainDefPtr def,
virQEMUCapsPtr qemuCaps,
unsigned int flags);
-void
-qemuDomainReAttachHostUSBDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs);
-void qemuDomainReAttachHostSCSIDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs);
-void qemuDomainReAttachHostdevDevices(virQEMUDriverPtr driver,
- const char *name,
- virDomainHostdevDefPtr *hostdevs,
- int nhostdevs);
-void qemuDomainReAttachHostDevices(virQEMUDriverPtr driver,
- virDomainDefPtr def);
+
+void qemuHostdevReAttachPCIDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs);
+void qemuHostdevReAttachUSBDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs);
+void qemuHostdevReAttachSCSIDevices(virQEMUDriverPtr driver,
+ const char *name,
+ virDomainHostdevDefPtr *hostdevs,
+ int nhostdevs);
+void qemuHostdevReAttachDomainDevices(virQEMUDriverPtr driver,
+ virDomainDefPtr def);
#endif /* __QEMU_HOSTDEV_H__ */
diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
index 507883c..8f2fda9 100644
--- a/src/qemu/qemu_hotplug.c
+++ b/src/qemu/qemu_hotplug.c
@@ -1383,7 +1383,7 @@ qemuDomainAttachHostPCIDevice(virQEMUDriverPtr driver,
if (releaseaddr)
qemuDomainReleaseDeviceAddress(vm, hostdev->info, NULL);
- qemuDomainReAttachHostdevDevices(driver, vm->def->name, &hostdev, 1);
+ qemuHostdevReAttachPCIDevices(driver, vm->def->name, &hostdev, 1);
VIR_FREE(devstr);
VIR_FREE(configfd_name);
@@ -1936,7 +1936,7 @@ qemuDomainAttachHostUSBDevice(virQEMUDriverPtr driver,
vm->def, hostdev, NULL) < 0)
VIR_WARN("Unable to restore host device labelling on hotplug
fail");
if (added)
- qemuDomainReAttachHostUSBDevices(driver, vm->def->name, &hostdev,
1);
+ qemuHostdevReAttachUSBDevices(driver, vm->def->name, &hostdev, 1);
}
VIR_FREE(devstr);
return ret;
@@ -2036,7 +2036,7 @@ qemuDomainAttachHostSCSIDevice(virConnectPtr conn,
ret = 0;
cleanup:
if (ret < 0) {
- qemuDomainReAttachHostSCSIDevices(driver, vm->def->name, &hostdev, 1);
+ qemuHostdevReAttachSCSIDevices(driver, vm->def->name, &hostdev, 1);
if (teardowncgroup && qemuTeardownHostdevCgroup(vm, hostdev) < 0)
VIR_WARN("Unable to remove host device cgroup ACL on hotplug
fail");
if (teardownlabel &&
@@ -2969,7 +2969,7 @@ qemuDomainRemovePCIHostDevice(virQEMUDriverPtr driver,
virDomainObjPtr vm,
virDomainHostdevDefPtr hostdev)
{
- qemuDomainReAttachHostdevDevices(driver, vm->def->name, &hostdev, 1);
+ qemuHostdevReAttachPCIDevices(driver, vm->def->name, &hostdev, 1);
qemuDomainReleaseDeviceAddress(vm, hostdev->info, NULL);
}
@@ -2978,7 +2978,7 @@ qemuDomainRemoveUSBHostDevice(virQEMUDriverPtr driver,
virDomainObjPtr vm,
virDomainHostdevDefPtr hostdev)
{
- qemuDomainReAttachHostUSBDevices(driver, vm->def->name, &hostdev, 1);
+ qemuHostdevReAttachUSBDevices(driver, vm->def->name, &hostdev, 1);
}
static void
@@ -2986,7 +2986,7 @@ qemuDomainRemoveSCSIHostDevice(virQEMUDriverPtr driver,
virDomainObjPtr vm,
virDomainHostdevDefPtr hostdev)
{
- qemuDomainReAttachHostSCSIDevices(driver, vm->def->name, &hostdev, 1);
+ qemuHostdevReAttachSCSIDevices(driver, vm->def->name, &hostdev, 1);
}
static int
diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c
index daeeaf2..2608a16 100644
--- a/src/qemu/qemu_process.c
+++ b/src/qemu/qemu_process.c
@@ -5342,7 +5342,7 @@ void qemuProcessStop(virQEMUDriverPtr driver,
priv->vioserialaddrs = NULL;
}
- qemuDomainReAttachHostDevices(driver, vm->def);
+ qemuHostdevReAttachDomainDevices(driver, vm->def);
def = vm->def;
for (i = 0; i < def->nnets; i++) {
--
2.4.3