path: root/xlators/features/locks/src/locks.h
diff options
authorRavishankar N <>2019-11-07 15:18:30 +0530
committerRavishankar N <>2019-11-28 07:17:00 +0000
commitfce5f68bc72d448490a0d41be494ac54a9181b3c (patch)
tree5c2661ce52553b8c27dbe11cb4d1924cafe109ec /xlators/features/locks/src/locks.h
parent8424df172339d3b2b65bc022e5c8f150f8826dba (diff)
afr: make heal info lockless
Changes in locks xlator: Added support for per-domain inodelk count requests. Caller needs to set GLUSTERFS_MULTIPLE_DOM_LK_CNT_REQUESTS key in the dict and then set each key with name 'GLUSTERFS_INODELK_DOM_PREFIX:<domain name>'. In the response dict, the xlator will send the per domain count as values for each of these keys. Changes in AFR: Replaced afr_selfheal_locked_inspect() with afr_lockless_inspect(). Logic has been added to make the latter behave same as the former, thus not breaking the current heal info output behaviour. fixes: bz#1774011 Change-Id: I9ae08ce768b39aeb6ee230207b5b7fa744176952 Signed-off-by: Ravishankar N <>
Diffstat (limited to 'xlators/features/locks/src/locks.h')
1 files changed, 8 insertions, 0 deletions
diff --git a/xlators/features/locks/src/locks.h b/xlators/features/locks/src/locks.h
index 0ab2aa6..3305350 100644
--- a/xlators/features/locks/src/locks.h
+++ b/xlators/features/locks/src/locks.h
@@ -240,6 +240,7 @@ typedef struct {
gf_boolean_t inodelk_count_req;
gf_boolean_t posixlk_count_req;
gf_boolean_t parent_entrylk_req;
+ gf_boolean_t multiple_dom_lk_requests;
int update_mlock_enforced_flag;
} pl_local_t;
@@ -261,6 +262,13 @@ typedef struct _locks_ctx {
struct list_head metalk_list;
} pl_ctx_t;
+typedef struct _multi_dom_lk_data {
+ xlator_t *this;
+ inode_t *inode;
+ dict_t *xdata_rsp;
+ gf_boolean_t keep_max;
+} multi_dom_lk_data;
typedef enum { DECREMENT, INCREMENT } pl_count_op_t;
pl_ctx_t *