[PATCH] Define SANLK_INQ_WAIT if missing in headers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



so we can build with older sanlock (like 2.2)
---
I've applied this to the current Debian builds since we're lagging a bit
regarding sanlock but it might make sense to also support this upstream.
Cheers,
 -- Guido

 src/locking/lock_driver_sanlock.c |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/locking/lock_driver_sanlock.c b/src/locking/lock_driver_sanlock.c
index 430e11e..84f81ec 100644
--- a/src/locking/lock_driver_sanlock.c
+++ b/src/locking/lock_driver_sanlock.c
@@ -338,6 +338,9 @@ retry:
     if ((rv = sanlock_add_lockspace(&ls, 0)) < 0) {
         if (-rv == EINPROGRESS) {
 #ifdef HAVE_SANLOCK_INQ_LOCKSPACE
+#  ifndef SANLK_INQ_WAIT
+#    define SANLK_INQ_WAIT 0x00000001
+#  endif
             /* we have this function which blocks until lockspace change the
              * state. It returns 0 if lockspace has been added, -ENOENT if it
              * hasn't. XXX should we goto retry? */
-- 
1.7.10.4

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]