qemu: hotplug: Export persistent reservations manager helper functions

Export qemuHotplugAttachManagedPR/qemuHotplugRemoveManagedPR for reuse
in blockjob code.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Peter Krempa 2025-02-04 17:51:57 +01:00
parent 8e0591520f
commit fc5b6ed091
2 changed files with 10 additions and 2 deletions

View File

@ -419,7 +419,7 @@ qemuHotplugRemoveDBusVMState(virDomainObj *vm,
* *
* Returns: 0 on success, -1 on error. * Returns: 0 on success, -1 on error.
*/ */
static int int
qemuHotplugAttachManagedPR(virDomainObj *vm, qemuHotplugAttachManagedPR(virDomainObj *vm,
virStorageSource *src, virStorageSource *src,
virDomainAsyncJob asyncJob) virDomainAsyncJob asyncJob)
@ -469,7 +469,7 @@ qemuHotplugAttachManagedPR(virDomainObj *vm,
* Removes the managed PR object from @vm if the configuration does not require * Removes the managed PR object from @vm if the configuration does not require
* it any more. * it any more.
*/ */
static int int
qemuHotplugRemoveManagedPR(virDomainObj *vm, qemuHotplugRemoveManagedPR(virDomainObj *vm,
virDomainAsyncJob asyncJob) virDomainAsyncJob asyncJob)
{ {

View File

@ -125,3 +125,11 @@ qemuHotplugAttachDBusVMState(virQEMUDriver *driver,
int int
qemuHotplugRemoveDBusVMState(virDomainObj *vm, qemuHotplugRemoveDBusVMState(virDomainObj *vm,
virDomainAsyncJob asyncJob); virDomainAsyncJob asyncJob);
int
qemuHotplugAttachManagedPR(virDomainObj *vm,
virStorageSource *src,
virDomainAsyncJob asyncJob);
int
qemuHotplugRemoveManagedPR(virDomainObj *vm,
virDomainAsyncJob asyncJob);