summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/common-utils.c
diff options
context:
space:
mode:
authorSusant Palai <spalai@redhat.com>2016-04-17 10:14:02 +0530
committerNiels de Vos <ndevos@redhat.com>2016-05-01 18:04:21 -0700
commitc4efd39d339535856c1a0a6b0fad2783587411c9 (patch)
treebd6b6e2c632b42bda264f7cc0327cca4159e49a3 /libglusterfs/src/common-utils.c
parentf1f6a0e2b09884151c37434bd512cb1482608218 (diff)
core: add getactivelk () fop
Change-Id: Ifd0ff278dcf43da064021f5c25e5dcd34347fcde BUG: 1326085 Signed-off-by: Susant Palai <spalai@redhat.com> Reviewed-on: http://review.gluster.org/13970 Smoke: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com>
Diffstat (limited to 'libglusterfs/src/common-utils.c')
-rw-r--r--libglusterfs/src/common-utils.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c
index a1a4c7d43ae..49b76871bab 100644
--- a/libglusterfs/src/common-utils.c
+++ b/libglusterfs/src/common-utils.c
@@ -4213,6 +4213,25 @@ out:
}
void
+gf_free_mig_locks (lock_migration_info_t *locks)
+{
+ lock_migration_info_t *current = NULL;
+ lock_migration_info_t *temp = NULL;
+
+ if (!locks)
+ return;
+
+ if (list_empty (&locks->list))
+ return;
+
+ list_for_each_entry_safe (current, temp, &locks->list, list) {
+ list_del_init (&current->list);
+ GF_FREE (current->client_uid);
+ GF_FREE (current);
+ }
+}
+
+void
_mask_cancellation (void)
{
(void) pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, NULL);
@@ -4287,6 +4306,7 @@ fop_enum_to_pri_string (glusterfs_fop_t fop)
case GF_FOP_STATFS:
case GF_FOP_READDIR:
case GF_FOP_READDIRP:
+ case GF_FOP_GETACTIVELK:
return "HIGH";
case GF_FOP_CREATE: