summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr-common.c
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2018-03-02 12:37:42 +0530
committerRavishankar N <ravishankar@redhat.com>2018-03-06 08:49:31 +0000
commit51d34907986fba09a560aa18238944811fc47b6a (patch)
treede96fb509f9f51d2d59ff9c781bbb423a7bb38b0 /xlators/cluster/afr/src/afr-common.c
parent4511b45bf4d13581cd74c4b87495eda6d54ec5be (diff)
cluster/afr: Remove unused code paths
Removed 1) afr-v1 self-heal locks related code which is not used anymore 2) transaction has some data types that are not needed, so removed them 3) Never used lock tracing available in afr as gluster's network tracing does the job. So removed that as well. 4) Changelog is always enabled and afr is always used with locks, so __changelog_enabled, afr_lock_server_count etc functions can be deleted. 5) transaction.fop/done/resume always call the same functions, so no need to have these variables. BUG: 1549606 Change-Id: I370c146fec2892d40e674d232a5d7256e003c7f1 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com>
Diffstat (limited to 'xlators/cluster/afr/src/afr-common.c')
-rw-r--r--xlators/cluster/afr/src/afr-common.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c
index d8fee88..c995313 100644
--- a/xlators/cluster/afr/src/afr-common.c
+++ b/xlators/cluster/afr/src/afr-common.c
@@ -4594,9 +4594,6 @@ afr_priv_dump (xlator_t *this)
gf_proc_dump_write("data_self_heal", "%s", priv->data_self_heal);
gf_proc_dump_write("metadata_self_heal", "%d", priv->metadata_self_heal);
gf_proc_dump_write("entry_self_heal", "%d", priv->entry_self_heal);
- gf_proc_dump_write("data_change_log", "%d", priv->data_change_log);
- gf_proc_dump_write("metadata_change_log", "%d", priv->metadata_change_log);
- gf_proc_dump_write("entry-change_log", "%d", priv->entry_change_log);
gf_proc_dump_write("read_child", "%d", priv->read_child);
gf_proc_dump_write("wait_count", "%u", priv->wait_count);
gf_proc_dump_write("heal-wait-queue-length", "%d",
@@ -5324,8 +5321,7 @@ out:
}
int
-afr_internal_lock_init (afr_internal_lock_t *lk, size_t child_count,
- transaction_lk_type_t lk_type)
+afr_internal_lock_init (afr_internal_lock_t *lk, size_t child_count)
{
int ret = -ENOMEM;
@@ -5341,7 +5337,6 @@ afr_internal_lock_init (afr_internal_lock_t *lk, size_t child_count,
lk->lock_op_ret = -1;
lk->lock_op_errno = EUCLEAN;
- lk->transaction_lk_type = lk_type;
ret = 0;
out:
@@ -5408,8 +5403,7 @@ afr_transaction_local_init (afr_local_t *local, xlator_t *this)
afr_private_t *priv = NULL;
priv = this->private;
- ret = afr_internal_lock_init (&local->internal_lock, priv->child_count,
- AFR_TRANSACTION_LK);
+ ret = afr_internal_lock_init (&local->internal_lock, priv->child_count);
if (ret < 0)
goto out;