|
|
c480ed |
From 2e3774564235a185a2cc4b7a22c17de17498db68 Mon Sep 17 00:00:00 2001
|
|
|
c480ed |
Message-Id: <2e3774564235a185a2cc4b7a22c17de17498db68@dist-git>
|
|
|
c480ed |
From: Michal Privoznik <mprivozn@redhat.com>
|
|
|
c480ed |
Date: Thu, 18 Apr 2019 19:36:31 +0200
|
|
|
c480ed |
Subject: [PATCH] conf: Expose virDomainSCSIDriveAddressIsUsed
|
|
|
c480ed |
|
|
|
c480ed |
RHEl-7.7: https://bugzilla.redhat.com/show_bug.cgi?id=1692296
|
|
|
c480ed |
RHEL-8.1.0: https://bugzilla.redhat.com/show_bug.cgi?id=1692354
|
|
|
c480ed |
|
|
|
c480ed |
This function checks if given drive address is already present in
|
|
|
c480ed |
passed domain definition. Expose the function as it will be used
|
|
|
c480ed |
shortly.
|
|
|
c480ed |
|
|
|
c480ed |
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
c480ed |
Tested-by: Daniel Henrique Barboza <danielhb413@gmail.com>
|
|
|
c480ed |
Reviewed-by: Jim Fehlig <jfehlig@suse.com>
|
|
|
c480ed |
(cherry picked from commit 89237d534f0fe950d06a2081089154160c6c2224)
|
|
|
c480ed |
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
|
|
|
c480ed |
Message-Id: <ef6c1d914a1f6bf0cdb44006b9adf6edf7bb4d41.1555608962.git.mprivozn@redhat.com>
|
|
|
c480ed |
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
|
|
|
c480ed |
---
|
|
|
c480ed |
src/conf/domain_conf.c | 2 +-
|
|
|
c480ed |
src/conf/domain_conf.h | 4 ++++
|
|
|
c480ed |
src/libvirt_private.syms | 1 +
|
|
|
c480ed |
3 files changed, 6 insertions(+), 1 deletion(-)
|
|
|
c480ed |
|
|
|
c480ed |
diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
|
|
|
c480ed |
index d431441f62..e62f78471c 100644
|
|
|
c480ed |
--- a/src/conf/domain_conf.c
|
|
|
c480ed |
+++ b/src/conf/domain_conf.c
|
|
|
c480ed |
@@ -4404,7 +4404,7 @@ virDomainDriveAddressIsUsedByHostdev(const virDomainDef *def,
|
|
|
c480ed |
* Return true if the SCSI drive address is already in use, false
|
|
|
c480ed |
* otherwise.
|
|
|
c480ed |
*/
|
|
|
c480ed |
-static bool
|
|
|
c480ed |
+bool
|
|
|
c480ed |
virDomainSCSIDriveAddressIsUsed(const virDomainDef *def,
|
|
|
c480ed |
const virDomainDeviceDriveAddress *addr)
|
|
|
c480ed |
{
|
|
|
c480ed |
diff --git a/src/conf/domain_conf.h b/src/conf/domain_conf.h
|
|
|
c480ed |
index f05fca284f..dbccf2cf24 100644
|
|
|
c480ed |
--- a/src/conf/domain_conf.h
|
|
|
c480ed |
+++ b/src/conf/domain_conf.h
|
|
|
c480ed |
@@ -2789,6 +2789,10 @@ virDomainXMLNamespacePtr
|
|
|
c480ed |
virDomainXMLOptionGetNamespace(virDomainXMLOptionPtr xmlopt)
|
|
|
c480ed |
ATTRIBUTE_NONNULL(1);
|
|
|
c480ed |
|
|
|
c480ed |
+bool
|
|
|
c480ed |
+virDomainSCSIDriveAddressIsUsed(const virDomainDef *def,
|
|
|
c480ed |
+ const virDomainDeviceDriveAddress *addr);
|
|
|
c480ed |
+
|
|
|
c480ed |
int virDomainDefPostParse(virDomainDefPtr def,
|
|
|
c480ed |
virCapsPtr caps,
|
|
|
c480ed |
unsigned int parseFlags,
|
|
|
c480ed |
diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms
|
|
|
c480ed |
index 624151056a..df27ac4b3a 100644
|
|
|
c480ed |
--- a/src/libvirt_private.syms
|
|
|
c480ed |
+++ b/src/libvirt_private.syms
|
|
|
c480ed |
@@ -520,6 +520,7 @@ virDomainRunningReasonTypeToString;
|
|
|
c480ed |
virDomainSaveConfig;
|
|
|
c480ed |
virDomainSaveStatus;
|
|
|
c480ed |
virDomainSaveXML;
|
|
|
c480ed |
+virDomainSCSIDriveAddressIsUsed;
|
|
|
c480ed |
virDomainSeclabelTypeFromString;
|
|
|
c480ed |
virDomainSeclabelTypeToString;
|
|
|
c480ed |
virDomainShmemDefEquals;
|
|
|
c480ed |
--
|
|
|
c480ed |
2.21.0
|
|
|
c480ed |
|