]> sourceware.org Git - lvm2.git/commitdiff
Remove extra sync calls.
authorZdenek Kabelac <zkabelac@redhat.com>
Fri, 4 Feb 2011 19:21:47 +0000 (19:21 +0000)
committerZdenek Kabelac <zkabelac@redhat.com>
Fri, 4 Feb 2011 19:21:47 +0000 (19:21 +0000)
Remove temporaly added fs_unlock() calls to fix clmvd usablity.
Now when the message passing is properly working - they are no longer needed.
Simplify no_locking  check for VG unlock - as message is always send
for all targets - clustered & non-clustered.

daemons/clvmd/lvm-functions.c
lib/locking/no_locking.c

index 4039bb2f42e05bf969dcd2c33be3fdd569b9d7ff..1fa234837ea29d2ae0fb92c5a8b0af6ef21d6167 100644 (file)
@@ -507,7 +507,6 @@ int do_lock_lv(unsigned char command, unsigned char lock_flags, char *resource)
        switch (command & LCK_MASK) {
        case LCK_LV_EXCLUSIVE:
                status = do_activate_lv(resource, lock_flags, LCK_EXCL);
-               fs_unlock();
                break;
 
        case LCK_LV_SUSPEND:
@@ -517,17 +516,14 @@ int do_lock_lv(unsigned char command, unsigned char lock_flags, char *resource)
        case LCK_UNLOCK:
        case LCK_LV_RESUME:     /* if active */
                status = do_resume_lv(resource, lock_flags);
-               fs_unlock();
                break;
 
        case LCK_LV_ACTIVATE:
                status = do_activate_lv(resource, lock_flags, LCK_READ);
-               fs_unlock();
                break;
 
        case LCK_LV_DEACTIVATE:
                status = do_deactivate_lv(resource, lock_flags);
-               fs_unlock();
                break;
 
        default:
index 87c1e0ff67cab84e76898d489818590c637d4f18..3ad0d38b27e72bcb96d7c4f2de69e4642ec071a2 100644 (file)
@@ -38,9 +38,7 @@ static int _no_lock_resource(struct cmd_context *cmd, const char *resource,
 {
        switch (flags & LCK_SCOPE_MASK) {
        case LCK_VG:
-               if (!strcmp(resource, VG_SYNC_NAMES) ||
-                   (((flags & LCK_TYPE_MASK) == LCK_UNLOCK) &&
-                    is_real_vg(resource)))
+               if (!strcmp(resource, VG_SYNC_NAMES))
                        fs_unlock();
                break;
        case LCK_LV:
This page took 0.041539 seconds and 5 git commands to generate.