summaryrefslogtreecommitdiffstats
path: root/xlators/protocol
diff options
context:
space:
mode:
authorPavan Sondur <pavan@gluster.com>2010-10-05 04:48:27 +0000
committerVijay Bellur <vijay@dev.gluster.com>2010-10-05 03:43:10 -0700
commitf62ff8a8df7ab7c0c551b650f9bd2f1a87b8dc71 (patch)
treec2efc82e784eabe228cc3de0c5b10c57eb56d76e /xlators/protocol
parent79342c436fb994e6a41e3c7b69c962af37e8946a (diff)
features/locks: cluster/afr: Misc fixes for lock recovery.
Signed-off-by: Pavan Vilas Sondur <pavan@gluster.com> Signed-off-by: Vijay Bellur <vijay@dev.gluster.com> BUG: 865 (Add locks recovery support in GlusterFS) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=865
Diffstat (limited to 'xlators/protocol')
-rw-r--r--xlators/protocol/client/src/client-lk.c2
-rw-r--r--xlators/protocol/server/src/server3_1-fops.c5
2 files changed, 7 insertions, 0 deletions
diff --git a/xlators/protocol/client/src/client-lk.c b/xlators/protocol/client/src/client-lk.c
index 089b0d8e44e..76ebc02d69b 100644
--- a/xlators/protocol/client/src/client-lk.c
+++ b/xlators/protocol/client/src/client-lk.c
@@ -471,6 +471,8 @@ client_cmd_to_gf_cmd (int32_t cmd, int32_t *gf_cmd)
*gf_cmd = GF_LK_RESLK_LCKW;
else if (cmd == F_RESLK_UNLCK)
*gf_cmd = GF_LK_RESLK_UNLCK;
+ else if (cmd == F_GETLK_FD)
+ *gf_cmd = GF_LK_GETLK_FD;
else
ret = -1;
diff --git a/xlators/protocol/server/src/server3_1-fops.c b/xlators/protocol/server/src/server3_1-fops.c
index 69d8cfbfa54..6ce7bba55f1 100644
--- a/xlators/protocol/server/src/server3_1-fops.c
+++ b/xlators/protocol/server/src/server3_1-fops.c
@@ -4900,8 +4900,13 @@ server_lk (rpcsvc_request_t *req)
case GF_LK_RESLK_UNLCK:
state->cmd = F_RESLK_UNLCK;
break;
+ case GF_LK_GETLK_FD:
+ state->cmd = F_GETLK_FD;
+ break;
+
}
+
gf_proto_flock_to_flock (&args.flock, &state->flock);
switch (state->type) {