public inbox for lvm2-cvs@sourceware.org
help / color / mirror / Atom feed
From: agk@sourceware.org
To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org
Subject: LVM2/lib/locking cluster_locking.c
Date: Thu, 08 Dec 2011 18:19:00 -0000	[thread overview]
Message-ID: <20111208181906.8968.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	agk@sourceware.org	2011-12-08 18:19:05

Modified files:
	lib/locking    : cluster_locking.c 

Log message:
	Don't pass LCK_LOCAL to clvmd - it's unused.
	Pass LCK_CLUSTER_VG in args[0] instead of args[1].

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/locking/cluster_locking.c.diff?cvsroot=lvm2&r1=1.62&r2=1.63

--- LVM2/lib/locking/cluster_locking.c	2011/11/30 17:02:37	1.62
+++ LVM2/lib/locking/cluster_locking.c	2011/12/08 18:19:05	1.63
@@ -320,9 +320,10 @@
 	args = alloca(len);
 	strcpy(args + 2, name);
 
-	/* Mask off lock flags */
-	args[0] = flags & (LCK_SCOPE_MASK | LCK_TYPE_MASK | LCK_NONBLOCK | LCK_HOLD); 
-	args[1] = flags & (LCK_LOCAL | LCK_CLUSTER_VG);
+	/* args[0] holds bottom 8 bits except LCK_LOCAL (0x40). */
+	args[0] = flags & (LCK_SCOPE_MASK | LCK_TYPE_MASK | LCK_NONBLOCK | LCK_HOLD | LCK_CLUSTER_VG); 
+
+	args[1] = 0;
 
 	if (flags & LCK_ORIGIN_ONLY)
 		args[1] |= LCK_ORIGIN_ONLY_MODE;
@@ -492,7 +493,7 @@
 		return 0;
 	}
 
-	log_very_verbose("Locking %s %s %s (%s%s%s%s%s%s%s) (0x%x)", lock_scope, lockname,
+	log_very_verbose("Locking %s %s %s (%s%s%s%s%s%s%s%s) (0x%x)", lock_scope, lockname,
 			 lock_type, lock_scope,
 			 flags & LCK_NONBLOCK ? "|NONBLOCK" : "",
 			 flags & LCK_HOLD ? "|HOLD" : "",
@@ -500,6 +501,7 @@
 			 flags & LCK_CLUSTER_VG ? "|CLUSTER" : "",
 			 flags & LCK_CACHE ? "|CACHE" : "",
 			 flags & LCK_ORIGIN_ONLY ? "|ORIGIN_ONLY" : "",
+			 flags & LCK_REVERT ? "|REVERT" : "",
 			 flags);
 
 	/* Send a message to the cluster manager */


             reply	other threads:[~2011-12-08 18:19 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-08 18:19 agk [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-11-30 17:02 mornfall
2011-02-02 23:57 agk
2011-02-01 17:31 jbrassow
2010-11-29 11:13 zkabelac
2009-12-09 18:28 mbroz
2009-12-09 18:16 mbroz
2008-12-16 12:30 wysochanski
2006-05-12 13:33 agk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20111208181906.8968.qmail@sourceware.org \
    --to=agk@sourceware.org \
    --cc=lvm-devel@redhat.com \
    --cc=lvm2-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).