On Mon, Oct 12, 2015 at 12:26:01 +0200, Michal Privoznik wrote:
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
src/libvirt_private.syms | 2 ++
src/locking/lock_manager.c | 32 ++++++++++++++++++++++++++++++++
src/locking/lock_manager.h | 9 +++++++++
3 files changed, 43 insertions(+)
[...]
diff --git a/src/locking/lock_manager.c b/src/locking/lock_manager.c
index a002ea8..8fc82c8 100644
--- a/src/locking/lock_manager.c
+++ b/src/locking/lock_manager.c
@@ -397,3 +397,35 @@ int virLockManagerFree(virLockManagerPtr lock)
return 0;
}
+
+int virLockManagerRememberSeclabel(virLockManagerPtr lock,
+ const char *path,
+ const char *model,
+ const char *label)
+{
+ VIR_DEBUG("lock=%p path=%s model=%s label=%s",
+ lock, path, model, label);
+
+ if (!lock)
+ return 0;
+
+ CHECK_MANAGER(drvRemember, 0);
Reporting an error but then returning success doesn't seem to be the
right thing to do.
+
+ return lock->driver->drvRemember(lock, path, model, label);
+}
+
+int virLockManagerRecallSeclabel(virLockManagerPtr lock,
+ const char *path,
+ const char *model,
+ char **label)
+{
+ VIR_DEBUG("lock=%p path=%s model=%s label=%p",
+ lock, path, model, label);
+
+ if (!lock)
+ return 0;
+
+ CHECK_MANAGER(drvRecall, 0);
Same here.
+
+ return lock->driver->drvRecall(lock, path, model, label);
+}
Peter