summaryrefslogtreecommitdiffstats
path: root/xlators/cluster
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/cluster')
-rw-r--r--xlators/cluster/afr/src/afr-common.c18
-rw-r--r--xlators/cluster/afr/src/afr-dir-write.c4
-rw-r--r--xlators/cluster/afr/src/afr-lk-common.c2
-rw-r--r--xlators/cluster/afr/src/afr-open.c2
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-common.c22
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-data.c4
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-entry.c12
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-metadata.c2
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-name.c24
-rw-r--r--xlators/cluster/afr/src/afr-self-heald.c12
-rw-r--r--xlators/cluster/afr/src/afr-transaction.c2
-rw-r--r--xlators/cluster/afr/src/pump.c24
-rw-r--r--xlators/cluster/dht/src/dht-common.c90
-rw-r--r--xlators/cluster/dht/src/dht-helper.c8
-rw-r--r--xlators/cluster/dht/src/dht-layout.c4
-rw-r--r--xlators/cluster/dht/src/dht-linkfile.c12
-rw-r--r--xlators/cluster/dht/src/dht-rebalance.c34
-rw-r--r--xlators/cluster/dht/src/dht-rename.c20
-rw-r--r--xlators/cluster/dht/src/dht-selfheal.c18
-rw-r--r--xlators/cluster/dht/src/dht-shared.c2
-rw-r--r--xlators/cluster/dht/src/tier.c12
-rw-r--r--xlators/cluster/dht/src/unittest/dht_layout_mock.c2
-rw-r--r--xlators/cluster/ec/src/ec-combine.c2
-rw-r--r--xlators/cluster/ec/src/ec-common.c6
-rw-r--r--xlators/cluster/ec/src/ec-heal.c10
-rw-r--r--xlators/cluster/ec/src/ec-heald.c8
-rw-r--r--xlators/cluster/ec/src/ec-helpers.c20
-rw-r--r--xlators/cluster/stripe/src/stripe.c20
28 files changed, 198 insertions, 198 deletions
diff --git a/xlators/cluster/afr/src/afr-common.c b/xlators/cluster/afr/src/afr-common.c
index 58c33e20d36..efe8f8bc435 100644
--- a/xlators/cluster/afr/src/afr-common.c
+++ b/xlators/cluster/afr/src/afr-common.c
@@ -680,7 +680,7 @@ afr_inode_refresh_subvol (call_frame_t *frame, xlator_t *this, int i,
priv = this->private;
loc.inode = inode;
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
STACK_WIND_COOKIE (frame, afr_inode_refresh_subvol_cbk,
(void *) (long) i, priv->children[i],
@@ -850,7 +850,7 @@ afr_hash_child (inode_t *inode, int32_t child_count, int hashmode)
}
if (inode) {
- uuid_copy (gfid_copy, inode->gfid);
+ gf_uuid_copy (gfid_copy, inode->gfid);
}
if (hashmode > 1 && inode->ia_type != IA_IFDIR) {
@@ -1379,7 +1379,7 @@ afr_lookup_done (call_frame_t *frame, xlator_t *this)
if (read_subvol == -1 || !readable[read_subvol]) {
read_subvol = i;
- uuid_copy (read_gfid, replies[i].poststat.ia_gfid);
+ gf_uuid_copy (read_gfid, replies[i].poststat.ia_gfid);
local->op_ret = 0;
}
}
@@ -1398,7 +1398,7 @@ afr_lookup_done (call_frame_t *frame, xlator_t *this)
continue;
}
- if (!uuid_compare (replies[i].poststat.ia_gfid, read_gfid))
+ if (!gf_uuid_compare (replies[i].poststat.ia_gfid, read_gfid))
continue;
can_interpret = _gf_false;
@@ -1637,7 +1637,7 @@ afr_can_start_metadata_self_heal(call_frame_t *frame, xlator_t *this)
continue;
}
- if (uuid_compare (stbuf.ia_gfid, replies[i].poststat.ia_gfid)) {
+ if (gf_uuid_compare (stbuf.ia_gfid, replies[i].poststat.ia_gfid)) {
start = _gf_false;
break;
}
@@ -1753,7 +1753,7 @@ afr_lookup_entry_heal (call_frame_t *frame, xlator_t *this)
break;
}
- if (uuid_compare (replies[i].poststat.ia_gfid,
+ if (gf_uuid_compare (replies[i].poststat.ia_gfid,
replies[first].poststat.ia_gfid)) {
need_heal = _gf_true;
break;
@@ -2004,7 +2004,7 @@ afr_discover (call_frame_t *frame, xlator_t *this, loc_t *loc, dict_t *xattr_req
allocate one for us */
local->xattr_req = dict_ref (xattr_req);
- if (uuid_is_null (loc->inode->gfid)) {
+ if (gf_uuid_is_null (loc->inode->gfid)) {
afr_discover_do (frame, this, 0);
return 0;
}
@@ -2115,7 +2115,7 @@ afr_lookup (call_frame_t *frame, xlator_t *this, loc_t *loc, dict_t *xattr_req)
void *gfid_req = NULL;
int ret = 0;
- if (!loc->parent && uuid_is_null (loc->pargfid)) {
+ if (!loc->parent && gf_uuid_is_null (loc->pargfid)) {
if (xattr_req)
dict_del (xattr_req, "gfid-req");
afr_discover (frame, this, loc, xattr_req);
@@ -2149,7 +2149,7 @@ afr_lookup (call_frame_t *frame, xlator_t *this, loc_t *loc, dict_t *xattr_req)
allocate one for us */
ret = dict_get_ptr (xattr_req, "gfid-req", &gfid_req);
if (ret == 0) {
- uuid_copy (local->cont.lookup.gfid_req, gfid_req);
+ gf_uuid_copy (local->cont.lookup.gfid_req, gfid_req);
dict_del (xattr_req, "gfid-req");
}
local->xattr_req = dict_ref (xattr_req);
diff --git a/xlators/cluster/afr/src/afr-dir-write.c b/xlators/cluster/afr/src/afr-dir-write.c
index 4cee1ed9bea..f7ca9108092 100644
--- a/xlators/cluster/afr/src/afr-dir-write.c
+++ b/xlators/cluster/afr/src/afr-dir-write.c
@@ -69,7 +69,7 @@ afr_build_parent_loc (loc_t *parent, loc_t *child, int32_t *op_errno)
}
parent->inode = inode_ref (child->parent);
- uuid_copy (parent->gfid, child->pargfid);
+ gf_uuid_copy (parent->gfid, child->pargfid);
ret = 0;
out:
@@ -314,7 +314,7 @@ afr_mark_new_entry_changelog (call_frame_t *frame, xlator_t *this)
goto out;
new_local->pending = changelog;
- uuid_copy (new_local->loc.gfid, local->cont.dir_fop.buf.ia_gfid);
+ gf_uuid_copy (new_local->loc.gfid, local->cont.dir_fop.buf.ia_gfid);
new_local->loc.inode = inode_ref (local->inode);
new_local->call_count = call_count;
diff --git a/xlators/cluster/afr/src/afr-lk-common.c b/xlators/cluster/afr/src/afr-lk-common.c
index 4b7f8b7fcc2..dc4dfbc42c0 100644
--- a/xlators/cluster/afr/src/afr-lk-common.c
+++ b/xlators/cluster/afr/src/afr-lk-common.c
@@ -65,7 +65,7 @@ afr_entry_lockee_cmp (const void *l1, const void *l2)
loc_gfid ((loc_t*)&r1->loc, gfid1);
loc_gfid ((loc_t*)&r2->loc, gfid2);
- ret = uuid_compare (gfid1, gfid2);
+ ret = gf_uuid_compare (gfid1, gfid2);
/*Entrylks with NULL basename are the 'smallest'*/
if (ret == 0) {
if (!r1->basename)
diff --git a/xlators/cluster/afr/src/afr-open.c b/xlators/cluster/afr/src/afr-open.c
index f8ad8544e10..f1da8b05201 100644
--- a/xlators/cluster/afr/src/afr-open.c
+++ b/xlators/cluster/afr/src/afr-open.c
@@ -52,7 +52,7 @@ afr_is_fd_fixable (fd_t *fd)
return _gf_false;
else if (fd_is_anonymous (fd))
return _gf_false;
- else if (uuid_is_null (fd->inode->gfid))
+ else if (gf_uuid_is_null (fd->inode->gfid))
return _gf_false;
return _gf_true;
diff --git a/xlators/cluster/afr/src/afr-self-heal-common.c b/xlators/cluster/afr/src/afr-self-heal-common.c
index 21b4c4414d9..f3d1f8b0b14 100644
--- a/xlators/cluster/afr/src/afr-self-heal-common.c
+++ b/xlators/cluster/afr/src/afr-self-heal-common.c
@@ -45,7 +45,7 @@ afr_selfheal_post_op (call_frame_t *frame, xlator_t *this, inode_t *inode,
local = frame->local;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
STACK_WIND (frame, afr_selfheal_post_op_cbk, priv->children[subvol],
priv->children[subvol]->fops->xattrop, &loc,
@@ -711,7 +711,7 @@ afr_selfheal_unlocked_lookup_on (call_frame_t *frame, inode_t *parent,
}
loc.parent = inode_ref (parent);
- uuid_copy (loc.pargfid, parent->gfid);
+ gf_uuid_copy (loc.pargfid, parent->gfid);
loc.name = name;
loc.inode = inode_ref (inode);
@@ -749,7 +749,7 @@ afr_selfheal_unlocked_discover_on (call_frame_t *frame, inode_t *inode,
}
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, gfid);
+ gf_uuid_copy (loc.gfid, gfid);
AFR_ONLIST (discover_on, frame, afr_selfheal_discover_cbk, lookup, &loc,
xattr_req);
@@ -840,7 +840,7 @@ afr_selfheal_tryinodelk (call_frame_t *frame, xlator_t *this, inode_t *inode,
struct gf_flock flock = {0, };
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
flock.l_type = F_WRLCK;
flock.l_start = off;
@@ -870,7 +870,7 @@ afr_selfheal_inodelk (call_frame_t *frame, xlator_t *this, inode_t *inode,
local = frame->local;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
flock.l_type = F_WRLCK;
flock.l_start = off;
@@ -908,7 +908,7 @@ afr_selfheal_uninodelk (call_frame_t *frame, xlator_t *this, inode_t *inode,
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
flock.l_type = F_UNLCK;
flock.l_start = off;
@@ -930,7 +930,7 @@ afr_selfheal_tryentrylk (call_frame_t *frame, xlator_t *this, inode_t *inode,
loc_t loc = {0,};
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
AFR_ONALL (frame, afr_selfheal_lock_cbk, entrylk, dom,
&loc, name, ENTRYLK_LOCK_NB, ENTRYLK_WRLCK, NULL);
@@ -954,7 +954,7 @@ afr_selfheal_entrylk (call_frame_t *frame, xlator_t *this, inode_t *inode,
local = frame->local;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
AFR_ONALL (frame, afr_selfheal_lock_cbk, entrylk, dom, &loc,
name, ENTRYLK_LOCK_NB, ENTRYLK_WRLCK, NULL);
@@ -985,7 +985,7 @@ afr_selfheal_unentrylk (call_frame_t *frame, xlator_t *this, inode_t *inode,
loc_t loc = {0,};
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
AFR_ONLIST (locked_on, frame, afr_selfheal_lock_cbk, entrylk,
dom, &loc, name, ENTRYLK_UNLOCK, ENTRYLK_WRLCK, NULL);
@@ -1225,7 +1225,7 @@ afr_inode_find (xlator_t *this, uuid_t gfid)
if (!inode)
return NULL;
- uuid_copy (inode->gfid, gfid);
+ gf_uuid_copy (inode->gfid, gfid);
return inode;
}
@@ -1271,7 +1271,7 @@ afr_selfheal_newentry_mark (call_frame_t *frame, xlator_t *this, inode_t *inode,
priv = this->private;
- uuid_copy (inode->gfid, replies[source].poststat.ia_gfid);
+ gf_uuid_copy (inode->gfid, replies[source].poststat.ia_gfid);
xattr = dict_new();
if (!xattr)
diff --git a/xlators/cluster/afr/src/afr-self-heal-data.c b/xlators/cluster/afr/src/afr-self-heal-data.c
index c0f444a776e..d20b6945a7e 100644
--- a/xlators/cluster/afr/src/afr-self-heal-data.c
+++ b/xlators/cluster/afr/src/afr-self-heal-data.c
@@ -296,7 +296,7 @@ afr_selfheal_data_restore_time (call_frame_t *frame, xlator_t *this,
loc_t loc = {0, };
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
AFR_ONLIST (healed_sinks, frame, attr_cbk, setattr, &loc,
&replies[source].poststat,
@@ -748,7 +748,7 @@ afr_selfheal_data_open (xlator_t *this, inode_t *inode)
return NULL;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
ret = syncop_open (this, &loc, O_RDWR|O_LARGEFILE, fd);
if (ret) {
diff --git a/xlators/cluster/afr/src/afr-self-heal-entry.c b/xlators/cluster/afr/src/afr-self-heal-entry.c
index 13825e1ebad..1f3ea38ffd9 100644
--- a/xlators/cluster/afr/src/afr-self-heal-entry.c
+++ b/xlators/cluster/afr/src/afr-self-heal-entry.c
@@ -44,7 +44,7 @@ afr_selfheal_entry_delete (xlator_t *this, inode_t *dir, const char *name,
subvol = priv->children[child];
loc.parent = inode_ref (dir);
- uuid_copy (loc.pargfid, dir->gfid);
+ gf_uuid_copy (loc.pargfid, dir->gfid);
loc.name = name;
loc.inode = inode_ref (inode);
@@ -97,7 +97,7 @@ afr_selfheal_recreate_entry (xlator_t *this, int dst, int source, inode_t *dir,
return -ENOMEM;
loc.parent = inode_ref (dir);
- uuid_copy (loc.pargfid, dir->gfid);
+ gf_uuid_copy (loc.pargfid, dir->gfid);
loc.name = name;
loc.inode = inode_ref (inode);
@@ -113,7 +113,7 @@ afr_selfheal_recreate_entry (xlator_t *this, int dst, int source, inode_t *dir,
iatt = &replies[source].poststat;
srcloc.inode = inode_ref (inode);
- uuid_copy (srcloc.gfid, iatt->ia_gfid);
+ gf_uuid_copy (srcloc.gfid, iatt->ia_gfid);
mode = st_mode_from_ia (iatt->ia_prot, iatt->ia_type);
@@ -186,7 +186,7 @@ __afr_selfheal_heal_dirent (call_frame_t *frame, xlator_t *this, fd_t *fd,
ret = afr_selfheal_entry_delete (this, fd->inode, name,
inode, i, replies);
} else {
- if (!uuid_compare (replies[i].poststat.ia_gfid,
+ if (!gf_uuid_compare (replies[i].poststat.ia_gfid,
replies[source].poststat.ia_gfid))
continue;
@@ -227,7 +227,7 @@ afr_selfheal_detect_gfid_and_type_mismatch (xlator_t *this,
if (replies[i].op_ret != 0)
continue;
- if (uuid_compare (replies[src_idx].poststat.ia_gfid,
+ if (gf_uuid_compare (replies[src_idx].poststat.ia_gfid,
replies[i].poststat.ia_gfid)) {
gf_log (this->name, GF_LOG_ERROR, "Gfid mismatch "
"detected for <%s/%s>, %s on %s and %s on %s. "
@@ -680,7 +680,7 @@ afr_selfheal_data_opendir (xlator_t *this, inode_t *inode)
return NULL;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
ret = syncop_opendir (this, &loc, fd);
if (ret) {
diff --git a/xlators/cluster/afr/src/afr-self-heal-metadata.c b/xlators/cluster/afr/src/afr-self-heal-metadata.c
index b08bd4ebe34..3d76647e974 100644
--- a/xlators/cluster/afr/src/afr-self-heal-metadata.c
+++ b/xlators/cluster/afr/src/afr-self-heal-metadata.c
@@ -49,7 +49,7 @@ __afr_selfheal_metadata_do (call_frame_t *frame, xlator_t *this, inode_t *inode,
priv = this->private;
loc.inode = inode_ref (inode);
- uuid_copy (loc.gfid, inode->gfid);
+ gf_uuid_copy (loc.gfid, inode->gfid);
gf_log (this->name, GF_LOG_INFO, "performing metadata selfheal on %s",
uuid_utoa (inode->gfid));
diff --git a/xlators/cluster/afr/src/afr-self-heal-name.c b/xlators/cluster/afr/src/afr-self-heal-name.c
index af635f06d52..12163298f7e 100644
--- a/xlators/cluster/afr/src/afr-self-heal-name.c
+++ b/xlators/cluster/afr/src/afr-self-heal-name.c
@@ -43,7 +43,7 @@ __afr_selfheal_assign_gfid (xlator_t *this, inode_t *parent, uuid_t pargfid,
new_local = new_frame->local;
- uuid_copy (parent->gfid, pargfid);
+ gf_uuid_copy (parent->gfid, pargfid);
xdata = dict_new ();
if (!xdata) {
@@ -59,7 +59,7 @@ __afr_selfheal_assign_gfid (xlator_t *this, inode_t *parent, uuid_t pargfid,
loc.parent = inode_ref (parent);
loc.inode = inode_ref (inode);
- uuid_copy (loc.pargfid, pargfid);
+ gf_uuid_copy (loc.pargfid, pargfid);
loc.name = bname;
if (is_gfid_absent) {
@@ -121,13 +121,13 @@ __afr_selfheal_name_impunge (call_frame_t *frame, xlator_t *this,
newentry = alloca0 (priv->child_count);
sources = alloca0 (priv->child_count);
- uuid_copy (parent->gfid, pargfid);
+ gf_uuid_copy (parent->gfid, pargfid);
for (i = 0; i < priv->child_count; i++) {
if (!replies[i].valid)
continue;
- if (uuid_compare (replies[i].poststat.ia_gfid,
+ if (gf_uuid_compare (replies[i].poststat.ia_gfid,
replies[gfid_idx].poststat.ia_gfid) == 0) {
sources[i] = 1;
continue;
@@ -159,7 +159,7 @@ __afr_selfheal_name_expunge (xlator_t *this, inode_t *parent, uuid_t pargfid,
priv = this->private;
loc.parent = inode_ref (parent);
- uuid_copy (loc.pargfid, pargfid);
+ gf_uuid_copy (loc.pargfid, pargfid);
loc.name = bname;
loc.inode = inode_ref (inode);
@@ -216,7 +216,7 @@ afr_selfheal_gfid_idx_get (xlator_t *this, struct afr_reply *replies,
if (!sources[i])
continue;
- if (uuid_is_null (replies[i].poststat.ia_gfid))
+ if (gf_uuid_is_null (replies[i].poststat.ia_gfid))
continue;
gfid_idx = i;
@@ -251,12 +251,12 @@ afr_selfheal_name_need_heal_check (xlator_t *this, struct afr_reply *replies)
if (replies[i].op_ret != replies[first_idx].op_ret)
need_heal = _gf_true;
- if (uuid_compare (replies[i].poststat.ia_gfid,
+ if (gf_uuid_compare (replies[i].poststat.ia_gfid,
replies[first_idx].poststat.ia_gfid))
need_heal = _gf_true;
if ((replies[i].op_ret == 0) &&
- (uuid_is_null(replies[i].poststat.ia_gfid)))
+ (gf_uuid_is_null(replies[i].poststat.ia_gfid)))
need_heal = _gf_true;
}
@@ -328,7 +328,7 @@ afr_selfheal_name_gfid_mismatch_check (xlator_t *this, struct afr_reply *replies
if (!replies[i].valid)
continue;
- if (uuid_is_null (replies[i].poststat.ia_gfid))
+ if (gf_uuid_is_null (replies[i].poststat.ia_gfid))
continue;
if (!gfid) {
@@ -339,7 +339,7 @@ afr_selfheal_name_gfid_mismatch_check (xlator_t *this, struct afr_reply *replies
if (sources[i] || source == -1) {
if ((sources[gfid_idx_iter] || source == -1) &&
- uuid_compare (gfid, replies[i].poststat.ia_gfid)) {
+ gf_uuid_compare (gfid, replies[i].poststat.ia_gfid)) {
gf_msg (this->name, GF_LOG_WARNING, 0,
AFR_MSG_SPLIT_BRAIN,
"GFID mismatch for <gfid:%s>/%s "
@@ -428,7 +428,7 @@ __afr_selfheal_name_do (call_frame_t *frame, xlator_t *this, inode_t *parent,
return ret;
if (gfid_idx == -1) {
- if (!gfid_req || uuid_is_null (gfid_req))
+ if (!gfid_req || gf_uuid_is_null (gfid_req))
return -1;
gfid = gfid_req;
} else {
@@ -654,7 +654,7 @@ afr_selfheal_name_unlocked_inspect (call_frame_t *frame, xlator_t *this,
if (replies[i].op_ret != replies[first_idx].op_ret)
*need_heal = _gf_true;
- if (uuid_compare (replies[i].poststat.ia_gfid,
+ if (gf_uuid_compare (replies[i].poststat.ia_gfid,
replies[first_idx].poststat.ia_gfid))
*need_heal = _gf_true;
}
diff --git a/xlators/cluster/afr/src/afr-self-heald.c b/xlators/cluster/afr/src/afr-self-heald.c
index c38440b4c9b..177e92497fe 100644
--- a/xlators/cluster/afr/src/afr-self-heald.c
+++ b/xlators/cluster/afr/src/afr-self-heald.c
@@ -82,7 +82,7 @@ afr_shd_is_subvol_local (xlator_t *this, int subvol)
loc_t loc = {0, };
loc.inode = this->itable->root;
- uuid_copy (loc.gfid, loc.inode->gfid);
+ gf_uuid_copy (loc.gfid, loc.inode->gfid);
priv = this->private;
syncop_is_subvol_local(priv->children[subvol], &loc, &is_local);
return is_local;
@@ -171,7 +171,7 @@ afr_shd_inode_find (xlator_t *this, xlator_t *subvol, uuid_t gfid)
loc.inode = inode_new (this->itable);
if (!loc.inode)
goto out;
- uuid_copy (loc.gfid, gfid);
+ gf_uuid_copy (loc.gfid, gfid);
ret = syncop_lookup (subvol, &loc, NULL, &iatt, NULL, NULL);
if (ret < 0)
@@ -196,7 +196,7 @@ afr_shd_index_inode (xlator_t *this, xlator_t *subvol)
void *index_gfid = NULL;
rootloc.inode = inode_ref (this->itable->root);
- uuid_copy (rootloc.gfid, rootloc.inode->gfid);
+ gf_uuid_copy (rootloc.gfid, rootloc.inode->gfid);
ret = syncop_getxattr (subvol, &rootloc, &xattr,
GF_XATTROP_INDEX_GFID, NULL);
@@ -408,7 +408,7 @@ afr_shd_index_heal (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
gf_log (healer->this->name, GF_LOG_DEBUG, "got entry: %s",
entry->d_name);
- ret = uuid_parse (entry->d_name, gfid);
+ ret = gf_uuid_parse (entry->d_name, gfid);
if (ret)
return 0;
@@ -847,7 +847,7 @@ afr_shd_gather_entry (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
gf_log (this->name, GF_LOG_DEBUG, "got entry: %s",
entry->d_name);
- ret = uuid_parse (entry->d_name, gfid);
+ ret = gf_uuid_parse (entry->d_name, gfid);
if (ret)
return 0;
@@ -1035,7 +1035,7 @@ afr_shd_get_index_count (xlator_t *this, int i, uint64_t *count)
subvol = priv->children[i];
rootloc.inode = inode_ref (this->itable->root);
- uuid_copy (rootloc.gfid, rootloc.inode->gfid);
+ gf_uuid_copy (rootloc.gfid, rootloc.inode->gfid);
ret = syncop_getxattr (subvol, &rootloc, &xattr,
GF_XATTROP_INDEX_COUNT, NULL);
diff --git a/xlators/cluster/afr/src/afr-transaction.c b/xlators/cluster/afr/src/afr-transaction.c
index afa11bba7ab..d2111060035 100644
--- a/xlators/cluster/afr/src/afr-transaction.c
+++ b/xlators/cluster/afr/src/afr-transaction.c
@@ -548,7 +548,7 @@ afr_handle_quorum (call_frame_t *frame)
return;
if (local->fd) {
- uuid_copy (gfid, local->fd->inode->gfid);
+ gf_uuid_copy (gfid, local->fd->inode->gfid);
file = uuid_utoa (gfid);
} else {
loc_path (&local->loc, local->loc.name);
diff --git a/xlators/cluster/afr/src/pump.c b/xlators/cluster/afr/src/pump.c
index 70038b9406e..139c9b6c447 100644
--- a/xlators/cluster/afr/src/pump.c
+++ b/xlators/cluster/afr/src/pump.c
@@ -38,7 +38,7 @@ afr_set_dict_gfid (dict_t *dict, uuid_t gfid)
goto out;
}
- uuid_copy (*pgfid, gfid);
+ gf_uuid_copy (*pgfid, gfid);
ret = dict_set_dynptr (dict, "gfid-req", pgfid, sizeof (uuid_t));
if (ret)
@@ -73,12 +73,12 @@ afr_build_child_loc (xlator_t *this, loc_t *child, loc_t *parent, char *name)
if (!child)
goto out;
- if (!uuid_is_null (parent->inode->gfid))
- uuid_copy (pargfid, parent->inode->gfid);
- else if (!uuid_is_null (parent->gfid))
- uuid_copy (pargfid, parent->gfid);
+ if (!gf_uuid_is_null (parent->inode->gfid))
+ gf_uuid_copy (pargfid, parent->inode->gfid);
+ else if (!gf_uuid_is_null (parent->gfid))
+ gf_uuid_copy (pargfid, parent->gfid);
- if (uuid_is_null (pargfid))
+ if (gf_uuid_is_null (pargfid))
goto out;
if (strcmp (parent->path, "/") == 0)
@@ -98,7 +98,7 @@ afr_build_child_loc (xlator_t *this, loc_t *child, loc_t *parent, char *name)
child->parent = inode_ref (parent->inode);
child->inode = inode_new (parent->inode->table);
- uuid_copy (child->pargfid, pargfid);
+ gf_uuid_copy (child->pargfid, pargfid);
if (!child->inode) {
ret = -1;
@@ -122,7 +122,7 @@ afr_build_root_loc (xlator_t *this, loc_t *loc)
loc->path = gf_strdup ("/");
loc->name = "";
loc->inode = inode_ref (priv->root_inode);
- uuid_copy (loc->gfid, loc->inode->gfid);
+ gf_uuid_copy (loc->gfid, loc->inode->gfid);
}
static void
@@ -131,9 +131,9 @@ afr_update_loc_gfids (loc_t *loc, struct iatt *buf, struct iatt *postparent)
GF_ASSERT (loc);
GF_ASSERT (buf);
- uuid_copy (loc->gfid, buf->ia_gfid);
+ gf_uuid_copy (loc->gfid, buf->ia_gfid);
if (postparent)
- uuid_copy (loc->pargfid, postparent->ia_gfid);
+ gf_uuid_copy (loc->pargfid, postparent->ia_gfid);
}
static uint64_t pump_pid = 0;
@@ -141,7 +141,7 @@ static inline void
pump_fill_loc_info (loc_t *loc, struct iatt *iatt, struct iatt *parent)
{
afr_update_loc_gfids (loc, iatt, parent);
- uuid_copy (loc->inode->gfid, iatt->ia_gfid);
+ gf_uuid_copy (loc->inode->gfid, iatt->ia_gfid);
}
static int
@@ -489,7 +489,7 @@ gf_pump_traverse_directory (loc_t *loc)
"found readdir entry=%s", entry->d_name);
offset = entry->d_off;
- if (uuid_is_null (entry->d_stat.ia_gfid)) {
+ if (gf_uuid_is_null (entry->d_stat.ia_gfid)) {
gf_log (this->name, GF_LOG_WARNING, "%s/%s: No "
"gfid present skipping",
loc->path, entry->d_name);
diff --git a/xlators/cluster/dht/src/dht-common.c b/xlators/cluster/dht/src/dht-common.c
index 9a98ebfab30..6d36fdbe284 100644
--- a/xlators/cluster/dht/src/dht-common.c
+++ b/xlators/cluster/dht/src/dht-common.c
@@ -294,7 +294,7 @@ selfheal:
main_frame->local = local;
discover_frame->local = NULL;
FRAME_SU_DO (main_frame, dht_local_t);
- uuid_copy (local->loc.gfid, local->gfid);
+ gf_uuid_copy (local->loc.gfid, local->gfid);
ret = dht_selfheal_directory_for_nameless_lookup (main_frame,
dht_lookup_selfheal_cbk,
&local->loc, layout);
@@ -334,10 +334,10 @@ dht_discover_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
/* Check if the gfid is different for file from other node */
- if (!op_ret && uuid_compare (local->gfid, stbuf->ia_gfid)) {
+ if (!op_ret && gf_uuid_compare (local->gfid, stbuf->ia_gfid)) {
- uuid_unparse(stbuf->ia_gfid, gfid_node);
- uuid_unparse(local->gfid, gfid_local);
+ gf_uuid_unparse(stbuf->ia_gfid, gfid_node);
+ gf_uuid_unparse(local->gfid, gfid_local);
gf_msg (this->name, GF_LOG_WARNING, 0,
DHT_MSG_GFID_MISMATCH,
@@ -469,7 +469,7 @@ dht_discover (call_frame_t *frame, xlator_t *this, loc_t *loc)
goto err;
}
- uuid_copy (local->gfid, loc->gfid);
+ gf_uuid_copy (local->gfid, loc->gfid);
discover_frame = copy_frame (frame);
if (!discover_frame) {
@@ -524,15 +524,15 @@ dht_lookup_dir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
layout = local->layout;
- if (!op_ret && uuid_is_null (local->gfid))
+ if (!op_ret && gf_uuid_is_null (local->gfid))
memcpy (local->gfid, stbuf->ia_gfid, 16);
/* Check if the gfid is different for file from other node */
- if (!op_ret && uuid_compare (local->gfid, stbuf->ia_gfid)) {
+ if (!op_ret && gf_uuid_compare (local->gfid, stbuf->ia_gfid)) {
- uuid_unparse(stbuf->ia_gfid, gfid_node);
- uuid_unparse(local->gfid, gfid_local);
+ gf_uuid_unparse(stbuf->ia_gfid, gfid_node);
+ gf_uuid_unparse(local->gfid, gfid_local);
gf_msg (this->name, GF_LOG_WARNING, 0,
DHT_MSG_GFID_MISMATCH,
@@ -631,7 +631,7 @@ unlock:
selfheal:
FRAME_SU_DO (frame, dht_local_t);
- uuid_copy (local->loc.gfid, local->gfid);
+ gf_uuid_copy (local->loc.gfid, local->gfid);
ret = dht_selfheal_directory (frame, dht_lookup_selfheal_cbk,
&local->loc, layout);
out:
@@ -667,7 +667,7 @@ dht_revalidate_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (!conf)
goto out;
- uuid_unparse (local->loc.gfid, gfid);
+ gf_uuid_unparse (local->loc.gfid, gfid);
LOCK (&frame->lock);
{
@@ -803,7 +803,7 @@ out:
}
if (local->need_selfheal) {
local->need_selfheal = 0;
- uuid_copy (local->gfid, local->stbuf.ia_gfid);
+ gf_uuid_copy (local->gfid, local->stbuf.ia_gfid);
local->stbuf.ia_gid = local->prebuf.ia_gid;
local->stbuf.ia_uid = local->prebuf.ia_uid;
copy = create_frame (this, this->ctx->pool);
@@ -888,7 +888,7 @@ dht_lookup_linkfile_create_cbk (call_frame_t *frame, void *cookie,
cached_subvol = local->cached_subvol;
conf = this->private;
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
ret = dht_layout_preset (this, local->cached_subvol, local->loc.inode);
if (ret < 0) {
@@ -1118,7 +1118,7 @@ dht_lookup_everywhere_done (call_frame_t *frame, xlator_t *this)
hashed_subvol = local->hashed_subvol;
cached_subvol = local->cached_subvol;
- uuid_unparse (local->loc.gfid, gfid);
+ gf_uuid_unparse (local->loc.gfid, gfid);
if (local->file_count && local->dir_count) {
gf_msg (this->name, GF_LOG_ERROR, 0,
@@ -1244,7 +1244,7 @@ dht_lookup_everywhere_done (call_frame_t *frame, xlator_t *this)
if (local->skip_unlink.handle_valid_link == _gf_true) {
if (cached_subvol == local->skip_unlink.hash_links_to) {
- if (uuid_compare (local->skip_unlink.cached_gfid,
+ if (gf_uuid_compare (local->skip_unlink.cached_gfid,
local->skip_unlink.hashed_gfid)){
/*GFID different, return error*/
@@ -1335,7 +1335,7 @@ preset_layout:
if (found_non_linkto_on_hashed) {
if (local->need_lookup_everywhere) {
- if (uuid_compare (local->gfid, local->inode->gfid)) {
+ if (gf_uuid_compare (local->gfid, local->inode->gfid)) {
/* GFID different, return error */
DHT_STACK_UNWIND (lookup, frame, -1, ENOENT,
NULL, NULL, NULL, NULL);
@@ -1478,12 +1478,12 @@ dht_lookup_everywhere_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
goto unlock;
}
- if (uuid_is_null (local->gfid))
- uuid_copy (local->gfid, buf->ia_gfid);
+ if (gf_uuid_is_null (local->gfid))
+ gf_uuid_copy (local->gfid, buf->ia_gfid);
- uuid_unparse(local->gfid, gfid);
+ gf_uuid_unparse(local->gfid, gfid);
- if (uuid_compare (local->gfid, buf->ia_gfid)) {
+ if (gf_uuid_compare (local->gfid, buf->ia_gfid)) {
gf_msg (this->name, GF_LOG_WARNING, 0,
DHT_MSG_GFID_MISMATCH,
"%s: gfid differs on subvolume %s,"
@@ -1515,7 +1515,7 @@ dht_lookup_everywhere_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
}
/* non linkfile GFID takes precedence */
- uuid_copy (local->gfid, buf->ia_gfid);
+ gf_uuid_copy (local->gfid, buf->ia_gfid);
if (is_dir) {
local->dir_count++;
@@ -1544,7 +1544,7 @@ dht_lookup_everywhere_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
dht_iatt_merge (this, &local->postparent,
postparent, subvol);
- uuid_copy (local->skip_unlink.cached_gfid,
+ gf_uuid_copy (local->skip_unlink.cached_gfid,
buf->ia_gfid);
} else {
/* This is where we need 'rename' both entries logic */
@@ -1580,7 +1580,7 @@ unlock:
local->skip_unlink.handle_valid_link = _gf_true;
local->skip_unlink.opend_fd_count = fd_count;
local->skip_unlink.hash_links_to = link_subvol;
- uuid_copy (local->skip_unlink.hashed_gfid,
+ gf_uuid_copy (local->skip_unlink.hashed_gfid,
buf->ia_gfid);
gf_msg_debug (this->name, 0, "Found"
@@ -1708,7 +1708,7 @@ dht_lookup_linkfile_cbk (call_frame_t *frame, void *cookie,
local = frame->local;
loc = &local->loc;
- uuid_unparse(loc->gfid, gfid);
+ gf_uuid_unparse(loc->gfid, gfid);
if (op_ret == -1) {
gf_log (this->name, GF_LOG_INFO,
@@ -1741,7 +1741,7 @@ dht_lookup_linkfile_cbk (call_frame_t *frame, void *cookie,
goto err;
}
- if (uuid_compare (local->gfid, stbuf->ia_gfid)) {
+ if (gf_uuid_compare (local->gfid, stbuf->ia_gfid)) {
gf_msg (this->name, GF_LOG_WARNING, 0,
DHT_MSG_GFID_MISMATCH,
"%s: gfid different on data file on %s,"
@@ -1815,7 +1815,7 @@ dht_lookup_directory (call_frame_t *frame, xlator_t *this, loc_t *loc)
local->xattr = NULL;
}
- if (!uuid_is_null (local->gfid)) {
+ if (!gf_uuid_is_null (local->gfid)) {
ret = dict_set_static_bin (local->xattr_req, "gfid-req",
local->gfid, 16);
if (ret)
@@ -1871,7 +1871,7 @@ dht_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
/* This is required for handling stale linkfile deletion,
* or any more call which happens from this 'loc'.
*/
- if (!op_ret && uuid_is_null (local->gfid))
+ if (!op_ret && gf_uuid_is_null (local->gfid))
memcpy (local->gfid, stbuf->ia_gfid, 16);
gf_msg_debug (this->name, 0,
@@ -2074,7 +2074,7 @@ dht_lookup (call_frame_t *frame, xlator_t *this,
local->xattr_req = dict_new ();
}
- if (uuid_is_null (loc->pargfid) && !uuid_is_null (loc->gfid) &&
+ if (gf_uuid_is_null (loc->pargfid) && !gf_uuid_is_null (loc->gfid) &&
!__is_root_gfid (loc->inode->gfid)) {
local->cached_subvol = NULL;
dht_discover (frame, this, loc);
@@ -4762,7 +4762,7 @@ dht_link (call_frame_t *frame, xlator_t *this,
}
if (hashed_subvol != cached_subvol) {
- uuid_copy (local->gfid, oldloc->inode->gfid);
+ gf_uuid_copy (local->gfid, oldloc->inode->gfid);
dht_linkfile_create (frame, dht_link_linkfile_cbk, this,
cached_subvol, hashed_subvol, newloc);
} else {
@@ -5068,8 +5068,8 @@ dht_mkdir_hashed_cbk (call_frame_t *frame, void *cookie,
conf = this->private;
hashed_subvol = local->hashed_subvol;
- if (uuid_is_null (local->loc.gfid) && !op_ret)
- uuid_copy (local->loc.gfid, stbuf->ia_gfid);
+ if (gf_uuid_is_null (local->loc.gfid) && !op_ret)
+ gf_uuid_copy (local->loc.gfid, stbuf->ia_gfid);
if (dht_is_subvol_filled (this, hashed_subvol))
ret = dht_layout_merge (this, layout, prev->this,
@@ -5098,8 +5098,8 @@ dht_mkdir_hashed_cbk (call_frame_t *frame, void *cookie,
local->call_cnt = conf->subvolume_cnt - 1;
- if (uuid_is_null (local->loc.gfid))
- uuid_copy (local->loc.gfid, stbuf->ia_gfid);
+ if (gf_uuid_is_null (local->loc.gfid))
+ gf_uuid_copy (local->loc.gfid, stbuf->ia_gfid);
if (local->call_cnt == 0) {
dht_selfheal_directory (frame, dht_mkdir_selfheal_cbk,
&local->loc, layout);
@@ -5214,7 +5214,7 @@ dht_rmdir_hashed_subvol_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
prev = cookie;
conf = this->private;
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
LOCK (&frame->lock);
{
@@ -5252,7 +5252,7 @@ unlock:
/* TODO: neater interface needed below */
local->stbuf.ia_type = local->loc.inode->ia_type;
- uuid_copy (local->gfid, local->loc.inode->gfid);
+ gf_uuid_copy (local->gfid, local->loc.inode->gfid);
dht_selfheal_restore (frame, dht_rmdir_selfheal_cbk,
&local->loc, local->layout);
} else {
@@ -5305,7 +5305,7 @@ dht_rmdir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
local->need_selfheal = 1;
}
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg_debug (this->name, 0,
"rmdir on %s for %s failed."
@@ -5343,7 +5343,7 @@ unlock:
/* TODO: neater interface needed below */
local->stbuf.ia_type = local->loc.inode->ia_type;
- uuid_copy (local->gfid, local->loc.inode->gfid);
+ gf_uuid_copy (local->gfid, local->loc.inode->gfid);
dht_selfheal_restore (frame, dht_rmdir_selfheal_cbk,
&local->loc, local->layout);
} else if (this_call_cnt) {
@@ -5405,7 +5405,7 @@ dht_rmdir_do (call_frame_t *frame, xlator_t *this)
hashed_subvol = dht_subvol_get_hashed (this, &local->loc);
if (!hashed_subvol) {
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg (this->name, GF_LOG_WARNING, 0,
DHT_MSG_HASHED_SUBVOL_GET_FAILED,
@@ -5465,7 +5465,7 @@ dht_rmdir_linkfile_unlink_cbk (call_frame_t *frame, void *cookie, xlator_t *this
main_frame = local->main_frame;
main_local = main_frame->local;
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
if (op_ret == 0) {
gf_msg_trace (this->name, 0,
@@ -5517,7 +5517,7 @@ dht_rmdir_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
main_local->op_ret = -1;
main_local->op_errno = ENOTEMPTY;
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_log (this->name, GF_LOG_WARNING,
"%s on %s is not a linkfile (type=0%o, gfid = %s)",
@@ -5691,9 +5691,9 @@ dht_rmdir_is_subvol_empty (call_frame_t *frame, xlator_t *this,
if (build_ret != 0)
goto err;
- uuid_copy (lookup_local->loc.gfid, trav->d_stat.ia_gfid);
+ gf_uuid_copy (lookup_local->loc.gfid, trav->d_stat.ia_gfid);
- uuid_unparse(lookup_local->loc.gfid, gfid);
+ gf_uuid_unparse(lookup_local->loc.gfid, gfid);
gf_msg_trace (this->name, 0,
"looking up %s on subvolume %s, gfid = %s",
@@ -5802,7 +5802,7 @@ dht_rmdir_opendir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
this_call_cnt = dht_frame_return (frame);
if (op_ret == -1) {
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg_debug (this->name, 0,
"opendir on %s for %s failed, "
@@ -5946,7 +5946,7 @@ dht_entrylk (call_frame_t *frame, xlator_t *this,
subvol = local->cached_subvol;
if (!subvol) {
- uuid_unparse(loc->gfid, gfid);
+ gf_uuid_unparse(loc->gfid, gfid);
gf_msg_debug (this->name, 0,
"no cached subvolume for path=%s, "
@@ -5996,7 +5996,7 @@ dht_fentrylk (call_frame_t *frame, xlator_t *this,
VALIDATE_OR_GOTO (fd, err);
VALIDATE_OR_GOTO(fd->inode, err);
- uuid_unparse(fd->inode->gfid, gfid);
+ gf_uuid_unparse(fd->inode->gfid, gfid);
subvol = dht_subvol_get_cached (this, fd->inode);
if (!subvol) {
diff --git a/xlators/cluster/dht/src/dht-helper.c b/xlators/cluster/dht/src/dht-helper.c
index 346d19bec88..35d3d0f9dba 100644
--- a/xlators/cluster/dht/src/dht-helper.c
+++ b/xlators/cluster/dht/src/dht-helper.c
@@ -674,7 +674,7 @@ dht_iatt_merge (xlator_t *this, struct iatt *to,
to->ia_dev = from->ia_dev;
- uuid_copy (to->ia_gfid, from->ia_gfid);
+ gf_uuid_copy (to->ia_gfid, from->ia_gfid);
to->ia_ino = from->ia_ino;
to->ia_prot = from->ia_prot;
@@ -914,7 +914,7 @@ dht_migration_complete_check_task (void *data)
goto out;
}
- if (uuid_compare (stbuf.ia_gfid, local->loc.inode->gfid)) {
+ if (gf_uuid_compare (stbuf.ia_gfid, local->loc.inode->gfid)) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_MISMATCH,
"%s: gfid different on the target file on %s",
@@ -1111,7 +1111,7 @@ dht_rebalance_inprogress_task (void *data)
goto out;
}
- if (uuid_compare (stbuf.ia_gfid, local->loc.inode->gfid)) {
+ if (gf_uuid_compare (stbuf.ia_gfid, local->loc.inode->gfid)) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_MISMATCH,
"%s: gfid different on the target file on %s",
@@ -1693,7 +1693,7 @@ dht_lock_request_cmp (const void *val1, const void *val2)
ret = strcmp (lock1->xl->name, lock2->xl->name);
if (ret == 0) {
- ret = uuid_compare (lock1->loc.gfid, lock2->loc.gfid);
+ ret = gf_uuid_compare (lock1->loc.gfid, lock2->loc.gfid);
}
out:
diff --git a/xlators/cluster/dht/src/dht-layout.c b/xlators/cluster/dht/src/dht-layout.c
index 15b183861a7..bbac904743e 100644
--- a/xlators/cluster/dht/src/dht-layout.c
+++ b/xlators/cluster/dht/src/dht-layout.c
@@ -667,7 +667,7 @@ dht_layout_normalize (xlator_t *this, loc_t *loc, dht_layout_t *layout)
goto out;
}
- uuid_unparse(loc->gfid, gfid);
+ gf_uuid_unparse(loc->gfid, gfid);
ret = dht_layout_anomalies (this, loc, layout,
&holes, &overlaps,
@@ -733,7 +733,7 @@ dht_layout_dir_mismatch (xlator_t *this, dht_layout_t *layout, xlator_t *subvol,
char gfid[GF_UUID_BUF_SIZE] = {0};
if(loc && loc->inode)
- uuid_unparse(loc->inode->gfid, gfid);
+ gf_uuid_unparse(loc->inode->gfid, gfid);
for (idx = 0; idx < layout->cnt; idx++) {
if (layout->list[idx].xlator == subvol) {
diff --git a/xlators/cluster/dht/src/dht-linkfile.c b/xlators/cluster/dht/src/dht-linkfile.c
index 90892a8a9bd..14df3187097 100644
--- a/xlators/cluster/dht/src/dht-linkfile.c
+++ b/xlators/cluster/dht/src/dht-linkfile.c
@@ -39,7 +39,7 @@ dht_linkfile_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret)
goto out;
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
is_linkfile = check_is_linkfile (inode, stbuf, xattr,
conf->link_xattr_name);
@@ -136,8 +136,8 @@ dht_linkfile_create (call_frame_t *frame, fop_mknod_cbk_t linkfile_cbk,
}
- if (!uuid_is_null (local->gfid)) {
- uuid_unparse(local->gfid, gfid);
+ if (!gf_uuid_is_null (local->gfid)) {
+ gf_uuid_unparse(local->gfid, gfid);
ret = dict_set_static_bin (dict, "gfid-req", local->gfid, 16);
if (ret)
@@ -146,7 +146,7 @@ dht_linkfile_create (call_frame_t *frame, fop_mknod_cbk_t linkfile_cbk,
"%s: Failed to set dictionary value: "
"key = gfid-req, gfid = %s ", loc->path, gfid);
} else {
- uuid_unparse(loc->gfid, gfid);
+ gf_uuid_unparse(loc->gfid, gfid);
}
ret = dict_set_str (dict, GLUSTERFS_INTERNAL_FOP_KEY, "yes");
@@ -208,7 +208,7 @@ dht_linkfile_unlink_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret == -1) {
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg (this->name, GF_LOG_INFO, op_errno,
DHT_MSG_UNLINK_FAILED,
"Unlinking linkfile %s (gfid = %s)on "
@@ -327,7 +327,7 @@ dht_linkfile_attr_heal (call_frame_t *frame, xlator_t *this)
if (local->stbuf.ia_type == IA_INVAL)
return 0;
- uuid_copy (local->loc.gfid, local->stbuf.ia_gfid);
+ gf_uuid_copy (local->loc.gfid, local->stbuf.ia_gfid);
copy = copy_frame (frame);
diff --git a/xlators/cluster/dht/src/dht-rebalance.c b/xlators/cluster/dht/src/dht-rebalance.c
index fc3b6124dd5..a0837e38528 100644
--- a/xlators/cluster/dht/src/dht-rebalance.c
+++ b/xlators/cluster/dht/src/dht-rebalance.c
@@ -154,7 +154,7 @@ gf_defrag_handle_hardlink (xlator_t *this, loc_t *loc, dict_t *xattrs,
conf = this->private;
- if (uuid_is_null (loc->pargfid)) {
+ if (gf_uuid_is_null (loc->pargfid)) {
gf_msg ("", GF_LOG_ERROR, 0,
DHT_MSG_MIGRATE_FILE_FAILED,
"Migrate file failed :"
@@ -162,7 +162,7 @@ gf_defrag_handle_hardlink (xlator_t *this, loc_t *loc, dict_t *xattrs,
goto out;
}
- if (uuid_is_null (loc->gfid)) {
+ if (gf_uuid_is_null (loc->gfid)) {
gf_msg ("", GF_LOG_ERROR, 0,
DHT_MSG_MIGRATE_FILE_FAILED,
"Migrate file failed :"
@@ -381,7 +381,7 @@ __dht_rebalance_create_dst_file (xlator_t *to, xlator_t *from, loc_t *loc, struc
ret = syncop_lookup (to, loc, NULL, &new_stbuf, NULL, NULL);
if (!ret) {
/* File exits in the destination, check if gfid matches */
- if (uuid_compare (stbuf->ia_gfid, new_stbuf.ia_gfid) != 0) {
+ if (gf_uuid_compare (stbuf->ia_gfid, new_stbuf.ia_gfid) != 0) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_MISMATCH,
"file %s exists in %s with different gfid",
@@ -428,7 +428,7 @@ __dht_rebalance_create_dst_file (xlator_t *to, xlator_t *from, loc_t *loc, struc
ret = syncop_lookup (to, loc, NULL, &check_stbuf, NULL, NULL);
if (!ret) {
- if (uuid_compare (stbuf->ia_gfid, check_stbuf.ia_gfid) != 0) {
+ if (gf_uuid_compare (stbuf->ia_gfid, check_stbuf.ia_gfid) != 0) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_MISMATCH,
"file %s exists in %s with different gfid,"
@@ -918,7 +918,7 @@ dht_migrate_file (xlator_t *this, loc_t *loc, xlator_t *from, xlator_t *to,
flock.l_type = F_WRLCK;
tmp_loc.inode = inode_ref (loc->inode);
- uuid_copy (tmp_loc.gfid, loc->gfid);
+ gf_uuid_copy (tmp_loc.gfid, loc->gfid);
tmp_loc.path = gf_strdup(loc->path);
ret = syncop_inodelk (from, DHT_FILE_MIGRATE_DOMAIN, &tmp_loc, F_SETLKW,
@@ -1155,7 +1155,7 @@ dht_migrate_file (xlator_t *this, loc_t *loc, xlator_t *from, xlator_t *to,
rcvd_enoent_from_src = 1;
}
- if ((uuid_compare (empty_iatt.ia_gfid, loc->gfid) == 0 ) &&
+ if ((gf_uuid_compare (empty_iatt.ia_gfid, loc->gfid) == 0 ) &&
(!rcvd_enoent_from_src)) {
/* take out the source from namespace */
ret = syncop_unlink (from, loc);
@@ -1511,7 +1511,7 @@ gf_defrag_migrate_data (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
goto out;
}
- if (uuid_is_null (entry->d_stat.ia_gfid)) {
+ if (gf_uuid_is_null (entry->d_stat.ia_gfid)) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_NULL,
"%s/%s gfid not present", loc->path,
@@ -1519,9 +1519,9 @@ gf_defrag_migrate_data (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
continue;
}
- uuid_copy (entry_loc.gfid, entry->d_stat.ia_gfid);
+ gf_uuid_copy (entry_loc.gfid, entry->d_stat.ia_gfid);
- if (uuid_is_null (loc->gfid)) {
+ if (gf_uuid_is_null (loc->gfid)) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_GFID_NULL,
"%s/%s gfid not present", loc->path,
@@ -1529,7 +1529,7 @@ gf_defrag_migrate_data (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
continue;
}
- uuid_copy (entry_loc.pargfid, loc->gfid);
+ gf_uuid_copy (entry_loc.pargfid, loc->gfid);
entry_loc.inode->ia_type = entry->d_stat.ia_type;
@@ -1566,8 +1566,8 @@ gf_defrag_migrate_data (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
continue;
}
- if (uuid_parse (uuid_str, node_uuid)) {
- gf_log (this->name, GF_LOG_ERROR, "uuid_parse "
+ if (gf_uuid_parse (uuid_str, node_uuid)) {
+ gf_log (this->name, GF_LOG_ERROR, "gf_uuid_parse "
"failed for %s", entry_loc.path);
continue;
}
@@ -1575,7 +1575,7 @@ gf_defrag_migrate_data (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
/* if file belongs to different node, skip migration
* the other node will take responsibility of migration
*/
- if (uuid_compare (node_uuid, defrag->node_uuid)) {
+ if (gf_uuid_compare (node_uuid, defrag->node_uuid)) {
gf_msg_trace (this->name, 0, "%s does not"
"belong to this node",
entry_loc.path);
@@ -1781,7 +1781,7 @@ gf_defrag_fix_layout (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
goto out;
}
- if (uuid_is_null (entry->d_stat.ia_gfid)) {
+ if (gf_uuid_is_null (entry->d_stat.ia_gfid)) {
gf_log (this->name, GF_LOG_ERROR, "%s/%s"
" gfid not present", loc->path,
entry->d_name);
@@ -1789,7 +1789,7 @@ gf_defrag_fix_layout (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
}
- uuid_copy (entry_loc.gfid, entry->d_stat.ia_gfid);
+ gf_uuid_copy (entry_loc.gfid, entry->d_stat.ia_gfid);
/*In case the gfid stored in the inode by inode_link
* and the gfid obtained in the lookup differs, then
@@ -1805,14 +1805,14 @@ gf_defrag_fix_layout (xlator_t *this, gf_defrag_info_t *defrag, loc_t *loc,
entry_loc.inode = linked_inode;
inode_unref (inode);
- if (uuid_is_null (loc->gfid)) {
+ if (gf_uuid_is_null (loc->gfid)) {
gf_log (this->name, GF_LOG_ERROR, "%s/%s"
" gfid not present", loc->path,
entry->d_name);
continue;
}
- uuid_copy (entry_loc.pargfid, loc->gfid);
+ gf_uuid_copy (entry_loc.pargfid, loc->gfid);
ret = syncop_lookup (this, &entry_loc, NULL, &iatt,
NULL, NULL);
diff --git a/xlators/cluster/dht/src/dht-rename.c b/xlators/cluster/dht/src/dht-rename.c
index c8a05a3939d..7d73eb9f272 100644
--- a/xlators/cluster/dht/src/dht-rename.c
+++ b/xlators/cluster/dht/src/dht-rename.c
@@ -40,7 +40,7 @@ dht_rename_dir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret == -1) {
/* TODO: undo the damage */
- uuid_unparse(local->loc.inode->gfid, gfid);
+ gf_uuid_unparse(local->loc.inode->gfid, gfid);
gf_msg (this->name, GF_LOG_INFO, op_errno,
DHT_MSG_RENAME_FAILED,
@@ -110,7 +110,7 @@ dht_rename_hashed_dir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret == -1) {
/* TODO: undo the damage */
- uuid_unparse(local->loc.inode->gfid, gfid);
+ gf_uuid_unparse(local->loc.inode->gfid, gfid);
gf_msg (this->name, GF_LOG_INFO, op_errno,
DHT_MSG_RENAME_FAILED,
@@ -241,7 +241,7 @@ dht_rename_opendir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret == -1) {
- uuid_unparse(local->loc.inode->gfid, gfid);
+ gf_uuid_unparse(local->loc.inode->gfid, gfid);
gf_msg (this->name, GF_LOG_INFO, op_errno,
DHT_MSG_OPENDIR_FAILED,
"opendir on %s for %s failed,(gfid = %s) ",
@@ -501,7 +501,7 @@ dht_rename_cleanup (call_frame_t *frame)
DHT_MARK_FOP_INTERNAL (xattr);
- uuid_unparse(local->loc.inode->gfid, gfid);
+ gf_uuid_unparse(local->loc.inode->gfid, gfid);
if (local->linked && (dst_hashed != src_hashed) &&
(dst_hashed != src_cached)) {
@@ -535,7 +535,7 @@ dht_rename_cleanup (call_frame_t *frame)
xattr_new = dict_copy_with_ref (xattr, NULL);
- if (uuid_compare (local->loc.pargfid,
+ if (gf_uuid_compare (local->loc.pargfid,
local->loc2.pargfid) == 0) {
DHT_MARKER_DONT_ACCOUNT(xattr_new);
}
@@ -683,7 +683,7 @@ dht_rename_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (link_local->loc.inode)
inode_unref (link_local->loc.inode);
link_local->loc.inode = inode_ref (local->loc.inode);
- uuid_copy (link_local->gfid, local->loc.inode->gfid);
+ gf_uuid_copy (link_local->gfid, local->loc.inode->gfid);
dht_linkfile_create (link_frame, dht_rename_links_create_cbk,
this, src_cached, dst_hashed,
@@ -740,7 +740,7 @@ err:
"deleting old src datafile %s @ %s",
local->loc.path, src_cached->name);
- if (uuid_compare (local->loc.pargfid,
+ if (gf_uuid_compare (local->loc.pargfid,
local->loc2.pargfid) == 0) {
DHT_MARKER_DONT_ACCOUNT(xattr_new);
}
@@ -920,7 +920,7 @@ dht_rename_linkto_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
gf_msg_trace (this->name, 0,
"link %s => %s (%s)", local->loc.path,
local->loc2.path, src_cached->name);
- if (uuid_compare (local->loc.pargfid,
+ if (gf_uuid_compare (local->loc.pargfid,
local->loc2.pargfid) == 0) {
DHT_MARKER_DONT_ACCOUNT(xattr);
}
@@ -1062,7 +1062,7 @@ dht_rename_create_links (call_frame_t *frame)
gf_msg_trace (this->name, 0,
"link %s => %s (%s)", local->loc.path,
local->loc2.path, src_cached->name);
- if (uuid_compare (local->loc.pargfid,
+ if (gf_uuid_compare (local->loc.pargfid,
local->loc2.pargfid) == 0) {
DHT_MARKER_DONT_ACCOUNT(xattr_new);
}
@@ -1281,7 +1281,7 @@ dht_rename (call_frame_t *frame, xlator_t *this,
VALIDATE_OR_GOTO (oldloc, err);
VALIDATE_OR_GOTO (newloc, err);
- uuid_unparse(oldloc->inode->gfid, gfid);
+ gf_uuid_unparse(oldloc->inode->gfid, gfid);
src_hashed = dht_subvol_get_hashed (this, oldloc);
if (!src_hashed) {
diff --git a/xlators/cluster/dht/src/dht-selfheal.c b/xlators/cluster/dht/src/dht-selfheal.c
index 727b2d6027d..f0f44ebf77a 100644
--- a/xlators/cluster/dht/src/dht-selfheal.c
+++ b/xlators/cluster/dht/src/dht-selfheal.c
@@ -657,7 +657,7 @@ dht_selfheal_dir_xattr_persubvol (call_frame_t *frame, loc_t *loc,
goto err;
}
- uuid_unparse(loc->inode->gfid, gfid);
+ gf_uuid_unparse(loc->inode->gfid, gfid);
ret = dht_disk_layout_extract (this, layout, i, &disk_layout);
if (ret == -1) {
@@ -700,8 +700,8 @@ dht_selfheal_dir_xattr_persubvol (call_frame_t *frame, loc_t *loc,
}
}
- if (!uuid_is_null (local->gfid))
- uuid_copy (loc->gfid, local->gfid);
+ if (!gf_uuid_is_null (local->gfid))
+ gf_uuid_copy (loc->gfid, local->gfid);
STACK_WIND (frame, dht_selfheal_dir_xattr_cbk,
subvol, subvol->fops->setxattr,
@@ -1041,8 +1041,8 @@ dht_selfheal_dir_setattr (call_frame_t *frame, loc_t *loc, struct iatt *stbuf,
return 0;
}
- if (!uuid_is_null (local->gfid))
- uuid_copy (loc->gfid, local->gfid);
+ if (!gf_uuid_is_null (local->gfid))
+ gf_uuid_copy (loc->gfid, local->gfid);
local->call_cnt = missing_attr;
for (i = 0; i < layout->cnt; i++) {
@@ -1093,7 +1093,7 @@ dht_selfheal_dir_mkdir_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (op_ret) {
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg (this->name, ((op_errno == EEXIST) ? GF_LOG_DEBUG :
GF_LOG_WARNING),
op_errno, DHT_MSG_DIR_SELFHEAL_FAILED,
@@ -1188,7 +1188,7 @@ dht_selfheal_dir_mkdir (call_frame_t *frame, loc_t *loc,
}
local->call_cnt = missing_dirs;
- if (!uuid_is_null (local->gfid)) {
+ if (!gf_uuid_is_null (local->gfid)) {
dict = dict_new ();
if (!dict)
return -1;
@@ -1739,7 +1739,7 @@ dht_selfheal_directory (call_frame_t *frame, dht_selfheal_dir_cbk_t dir_cbk,
local = frame->local;
this = frame->this;
- uuid_unparse(loc->gfid, gfid);
+ gf_uuid_unparse(loc->gfid, gfid);
dht_layout_anomalies (this, loc, layout,
&local->selfheal.hole_cnt,
@@ -1915,7 +1915,7 @@ dht_dir_attr_heal (void *data)
(GF_SET_ATTR_UID | GF_SET_ATTR_GID),
NULL, NULL);
if (ret) {
- uuid_unparse(local->loc.gfid, gfid);
+ gf_uuid_unparse(local->loc.gfid, gfid);
gf_msg ("dht", GF_LOG_ERROR, -ret,
DHT_MSG_DIR_ATTR_HEAL_FAILED,
diff --git a/xlators/cluster/dht/src/dht-shared.c b/xlators/cluster/dht/src/dht-shared.c
index 3987510441f..0c008d83653 100644
--- a/xlators/cluster/dht/src/dht-shared.c
+++ b/xlators/cluster/dht/src/dht-shared.c
@@ -579,7 +579,7 @@ dht_init (xlator_t *this)
goto err;
}
- if (uuid_parse (node_uuid, defrag->node_uuid)) {
+ if (gf_uuid_parse (node_uuid, defrag->node_uuid)) {
gf_msg (this->name, GF_LOG_ERROR, 0,
DHT_MSG_INVALID_OPTION, "Invalid option:"
" Cannot parse glusterd node uuid");
diff --git a/xlators/cluster/dht/src/tier.c b/xlators/cluster/dht/src/tier.c
index 7e3eaa02c02..51a6a8340e9 100644
--- a/xlators/cluster/dht/src/tier.c
+++ b/xlators/cluster/dht/src/tier.c
@@ -134,7 +134,7 @@ tier_migrate_using_query_file (void *_args)
continue;
}
- uuid_parse (gfid_str, query_record->gfid);
+ gf_uuid_parse (gfid_str, query_record->gfid);
if (dict_get(migrate_data, GF_XATTR_FILE_MIGRATE_KEY))
dict_del(migrate_data, GF_XATTR_FILE_MIGRATE_KEY);
@@ -181,7 +181,7 @@ tier_migrate_using_query_file (void *_args)
goto error;
}
- uuid_copy (p_loc.gfid, link_info->pargfid);
+ gf_uuid_copy (p_loc.gfid, link_info->pargfid);
p_loc.inode = inode_new (defrag->root_inode->table);
if (!p_loc.inode) {
@@ -206,9 +206,9 @@ tier_migrate_using_query_file (void *_args)
inode_unref (p_loc.inode);
p_loc.inode = linked_inode;
- uuid_copy (loc.gfid, query_record->gfid);
+ gf_uuid_copy (loc.gfid, query_record->gfid);
loc.inode = inode_new (defrag->root_inode->table);
- uuid_copy (loc.pargfid, link_info->pargfid);
+ gf_uuid_copy (loc.pargfid, link_info->pargfid);
loc.parent = inode_ref(p_loc.inode);
loc.name = gf_strdup (link_info->file_name);
@@ -229,7 +229,7 @@ tier_migrate_using_query_file (void *_args)
goto error;
}
- uuid_copy (loc.parent->gfid, link_info->pargfid);
+ gf_uuid_copy (loc.parent->gfid, link_info->pargfid);
ret = syncop_lookup (this, &loc, NULL, &current,
NULL, NULL);
@@ -313,7 +313,7 @@ tier_gf_query_callback (gfdb_query_record_t *gfdb_query_record,
GF_VALIDATE_OR_GOTO ("tier", query_cbk_args->defrag, out);
GF_VALIDATE_OR_GOTO ("tier", query_cbk_args->queryFILE, out);
- uuid_unparse (gfdb_query_record->gfid, gfid_str);
+ gf_uuid_unparse (gfdb_query_record->gfid, gfid_str);
fprintf (query_cbk_args->queryFILE, "%s|%s|%ld\n", gfid_str,
gfdb_query_record->_link_info_str,
gfdb_query_record->link_info_size);
diff --git a/xlators/cluster/dht/src/unittest/dht_layout_mock.c b/xlators/cluster/dht/src/unittest/dht_layout_mock.c
index a5c6357a3da..faf871d49be 100644
--- a/xlators/cluster/dht/src/unittest/dht_layout_mock.c
+++ b/xlators/cluster/dht/src/unittest/dht_layout_mock.c
@@ -62,7 +62,7 @@ int _gf_log_callingfn (const char *domain, const char *file,
return 0;
}
-void uuid_unparse(const uuid_t uu, char *out)
+void gf_uuid_unparse(const uuid_t uu, char *out)
{
// could call a will-return function here
// to place the correct data in *out
diff --git a/xlators/cluster/ec/src/ec-combine.c b/xlators/cluster/ec/src/ec-combine.c
index a644d26ce82..709da555627 100644
--- a/xlators/cluster/ec/src/ec-combine.c
+++ b/xlators/cluster/ec/src/ec-combine.c
@@ -64,7 +64,7 @@ int32_t ec_iatt_combine(struct iatt * dst, struct iatt * src, int32_t count)
(dst[i].ia_size != src[i].ia_size)) ||
(st_mode_from_ia(dst[i].ia_prot, dst[i].ia_type) !=
st_mode_from_ia(src[i].ia_prot, src[i].ia_type)) ||
- (uuid_compare(dst[i].ia_gfid, src[i].ia_gfid) != 0))
+ (gf_uuid_compare(dst[i].ia_gfid, src[i].ia_gfid) != 0))
{
gf_log(THIS->name, GF_LOG_WARNING,
"Failed to combine iatt (inode: %lu-%lu, links: %u-%u, "
diff --git a/xlators/cluster/ec/src/ec-common.c b/xlators/cluster/ec/src/ec-common.c
index 1cae44fd0c9..7354277da1b 100644
--- a/xlators/cluster/ec/src/ec-common.c
+++ b/xlators/cluster/ec/src/ec-common.c
@@ -603,7 +603,7 @@ ec_lock_t * ec_lock_allocate(xlator_t * xl, int32_t kind, loc_t * loc)
ec_lock_t * lock;
if ((loc->inode == NULL) ||
- (uuid_is_null(loc->gfid) && uuid_is_null(loc->inode->gfid)))
+ (gf_uuid_is_null(loc->gfid) && gf_uuid_is_null(loc->inode->gfid)))
{
gf_log(xl->name, GF_LOG_ERROR, "Trying to lock based on an invalid "
"inode");
@@ -636,7 +636,7 @@ void ec_lock_destroy(ec_lock_t * lock)
int32_t ec_lock_compare(ec_lock_t * lock1, ec_lock_t * lock2)
{
- return uuid_compare(lock1->loc.gfid, lock2->loc.gfid);
+ return gf_uuid_compare(lock1->loc.gfid, lock2->loc.gfid);
}
ec_lock_link_t *ec_lock_insert(ec_fop_data_t *fop, ec_lock_t *lock,
@@ -1156,7 +1156,7 @@ void ec_get_size_version(ec_fop_data_t * fop)
{
goto out;
}
- if (uuid_is_null(loc.pargfid))
+ if (gf_uuid_is_null(loc.pargfid))
{
if (loc.parent != NULL)
{
diff --git a/xlators/cluster/ec/src/ec-heal.c b/xlators/cluster/ec/src/ec-heal.c
index 6b513df8fe7..d82592d666e 100644
--- a/xlators/cluster/ec/src/ec-heal.c
+++ b/xlators/cluster/ec/src/ec-heal.c
@@ -357,7 +357,7 @@ int32_t ec_heal_create(ec_heal_t * heal, uintptr_t mask, int32_t try_link)
{
memset(&loc, 0, sizeof(loc));
loc.inode = heal->loc.inode;
- uuid_copy(loc.gfid, heal->iatt.ia_gfid);
+ gf_uuid_copy(loc.gfid, heal->iatt.ia_gfid);
ec_link(heal->fop->frame, heal->xl, mask, EC_MINIMUM_ONE,
ec_heal_link_cbk, heal, &loc, &heal->loc, xdata);
@@ -717,7 +717,7 @@ void ec_heal_prepare_others(ec_heal_t * heal)
else
{
if ((heal->iatt.ia_type != cbk->iatt[0].ia_type) ||
- (uuid_compare(heal->iatt.ia_gfid, cbk->iatt[0].ia_gfid) != 0))
+ (gf_uuid_compare(heal->iatt.ia_gfid, cbk->iatt[0].ia_gfid) != 0))
{
ec_heal_remove(heal, cbk);
}
@@ -846,7 +846,7 @@ int32_t ec_heal_open_others(ec_heal_t * heal)
cbk = list_entry(item, ec_cbk_data_t, list);
if ((cbk->op_ret < 0) || (cbk->iatt[0].ia_type != IA_IFREG) ||
- (uuid_compare(heal->iatt.ia_gfid, cbk->iatt[0].ia_gfid) != 0))
+ (gf_uuid_compare(heal->iatt.ia_gfid, cbk->iatt[0].ia_gfid) != 0))
{
ec_heal_exclude(heal, cbk->mask);
}
@@ -1293,7 +1293,7 @@ ec_manager_heal (ec_fop_data_t * fop, int32_t state)
heal = fop->heal;
/* root loc doesn't have pargfid/parent */
if (loc_is_root (&heal->loc) ||
- !uuid_is_null(heal->loc.pargfid) || heal->loc.parent) {
+ !gf_uuid_is_null(heal->loc.pargfid) || heal->loc.parent) {
heal->nameheal = _gf_true;
return EC_STATE_DISPATCH;
} else {
@@ -1332,7 +1332,7 @@ ec_manager_heal (ec_fop_data_t * fop, int32_t state)
return EC_STATE_HEAL_DISPATCH;
/* Only heal data/metadata if enough information is supplied. */
- if (uuid_is_null(heal->loc.gfid))
+ if (gf_uuid_is_null(heal->loc.gfid))
{
ec_heal_entrylk(heal, ENTRYLK_UNLOCK);
diff --git a/xlators/cluster/ec/src/ec-heald.c b/xlators/cluster/ec/src/ec-heald.c
index 6b899414d4d..c4b896a5fb3 100644
--- a/xlators/cluster/ec/src/ec-heald.c
+++ b/xlators/cluster/ec/src/ec-heald.c
@@ -144,7 +144,7 @@ ec_shd_inode_find (xlator_t *this, xlator_t *subvol, uuid_t gfid)
loc.inode = inode_new (this->itable);
if (!loc.inode)
goto out;
- uuid_copy (loc.gfid, gfid);
+ gf_uuid_copy (loc.gfid, gfid);
ret = syncop_lookup (subvol, &loc, NULL, &iatt, NULL, NULL);
if (ret < 0)
@@ -169,7 +169,7 @@ ec_shd_index_inode (xlator_t *this, xlator_t *subvol)
void *index_gfid = NULL;
rootloc.inode = inode_ref (this->itable->root);
- uuid_copy (rootloc.gfid, rootloc.inode->gfid);
+ gf_uuid_copy (rootloc.gfid, rootloc.inode->gfid);
ret = syncop_getxattr (subvol, &rootloc, &xattr,
GF_XATTROP_INDEX_GFID, NULL);
@@ -234,7 +234,7 @@ ec_shd_index_heal (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
gf_log (healer->this->name, GF_LOG_DEBUG, "got entry: %s",
entry->d_name);
- ret = uuid_parse (entry->d_name, loc.gfid);
+ ret = gf_uuid_parse (entry->d_name, loc.gfid);
if (ret)
return 0;
@@ -301,7 +301,7 @@ ec_shd_full_heal (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
loc.parent = inode_ref (parent->inode);
loc.name = entry->d_name;
- uuid_copy (loc.gfid, entry->d_stat.ia_gfid);
+ gf_uuid_copy (loc.gfid, entry->d_stat.ia_gfid);
/* If this fails with ENOENT/ESTALE index is stale */
ret = syncop_gfid_to_path (this->itable, subvol, loc.gfid,
diff --git a/xlators/cluster/ec/src/ec-helpers.c b/xlators/cluster/ec/src/ec-helpers.c
index 139957b55c6..65deba63959 100644
--- a/xlators/cluster/ec/src/ec-helpers.c
+++ b/xlators/cluster/ec/src/ec-helpers.c
@@ -256,19 +256,19 @@ int32_t ec_dict_del_config(dict_t * dict, char * key, ec_config_t * config)
int32_t ec_loc_gfid_check(xlator_t * xl, uuid_t dst, uuid_t src)
{
- if (uuid_is_null(src))
+ if (gf_uuid_is_null(src))
{
return 1;
}
- if (uuid_is_null(dst))
+ if (gf_uuid_is_null(dst))
{
- uuid_copy(dst, src);
+ gf_uuid_copy(dst, src);
return 1;
}
- if (uuid_compare(dst, src) != 0)
+ if (gf_uuid_compare(dst, src) != 0)
{
gf_log(xl->name, GF_LOG_WARNING, "Mismatching GFID's in loc");
@@ -287,7 +287,7 @@ int32_t ec_loc_setup_inode(xlator_t *xl, loc_t *loc)
goto out;
}
} else if (loc->parent != NULL) {
- if (!uuid_is_null(loc->gfid)) {
+ if (!gf_uuid_is_null(loc->gfid)) {
loc->inode = inode_find(loc->parent->table, loc->gfid);
} else if (loc->path && strchr (loc->path, '/')) {
loc->inode = inode_resolve(loc->parent->table, (char *)loc->path);
@@ -310,7 +310,7 @@ int32_t ec_loc_setup_parent(xlator_t *xl, loc_t *loc)
goto out;
}
} else if (loc->inode != NULL) {
- if (!uuid_is_null(loc->pargfid)) {
+ if (!gf_uuid_is_null(loc->pargfid)) {
loc->parent = inode_find(loc->inode->table, loc->pargfid);
} else if (loc->path && strchr (loc->path, '/')) {
path = gf_strdup(loc->path);
@@ -385,8 +385,8 @@ int32_t ec_loc_parent(xlator_t *xl, loc_t *loc, loc_t *parent)
if (loc->parent != NULL) {
parent->inode = inode_ref(loc->parent);
}
- if (!uuid_is_null(loc->pargfid)) {
- uuid_copy(parent->gfid, loc->pargfid);
+ if (!gf_uuid_is_null(loc->pargfid)) {
+ gf_uuid_copy(parent->gfid, loc->pargfid);
}
if (loc->path && strchr (loc->path, '/')) {
str = gf_strdup(loc->path);
@@ -412,7 +412,7 @@ int32_t ec_loc_parent(xlator_t *xl, loc_t *loc, loc_t *parent)
}
if ((parent->inode == NULL) && (parent->path == NULL) &&
- uuid_is_null(parent->gfid)) {
+ gf_uuid_is_null(parent->gfid)) {
gf_log(xl->name, GF_LOG_ERROR, "Parent inode missing for loc_t");
goto out;
@@ -441,7 +441,7 @@ int32_t ec_loc_update(xlator_t *xl, loc_t *loc, inode_t *inode,
inode_unref(loc->inode);
}
loc->inode = inode_ref(inode);
- uuid_copy(loc->gfid, inode->gfid);
+ gf_uuid_copy(loc->gfid, inode->gfid);
}
if (iatt != NULL) {
diff --git a/xlators/cluster/stripe/src/stripe.c b/xlators/cluster/stripe/src/stripe.c
index 8896d7a2ad2..7ac131b2ca9 100644
--- a/xlators/cluster/stripe/src/stripe.c
+++ b/xlators/cluster/stripe/src/stripe.c
@@ -244,11 +244,11 @@ stripe_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (local->postparent_size < postparent->ia_size)
local->postparent_size = postparent->ia_size;
- if (uuid_is_null (local->ia_gfid))
- uuid_copy (local->ia_gfid, buf->ia_gfid);
+ if (gf_uuid_is_null (local->ia_gfid))
+ gf_uuid_copy (local->ia_gfid, buf->ia_gfid);
/* Make sure the gfid on all the nodes are same */
- if (uuid_compare (local->ia_gfid, buf->ia_gfid)) {
+ if (gf_uuid_compare (local->ia_gfid, buf->ia_gfid)) {
gf_log (this->name, GF_LOG_WARNING,
"%s: gfid different on subvolume %s",
local->loc.path, prev->this->name);
@@ -259,7 +259,7 @@ stripe_lookup_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (!callcnt) {
if (local->op_ret == 0 && local->entry_self_heal_needed &&
- !uuid_is_null (local->loc.inode->gfid))
+ !gf_uuid_is_null (local->loc.inode->gfid))
stripe_entry_self_heal (frame, this, local);
if (local->failed)
@@ -1485,8 +1485,8 @@ stripe_mknod_ifreg_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
/* Can be used as a mechanism to understand if mknod
was successful in at least one place */
- if (uuid_is_null (local->ia_gfid))
- uuid_copy (local->ia_gfid, buf->ia_gfid);
+ if (gf_uuid_is_null (local->ia_gfid))
+ gf_uuid_copy (local->ia_gfid, buf->ia_gfid);
if (stripe_ctx_handle(this, prev, local, xdata))
gf_log(this->name, GF_LOG_ERROR,
@@ -1512,7 +1512,7 @@ stripe_mknod_ifreg_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
if (local->failed)
local->op_ret = -1;
- if ((local->op_ret == -1) && !uuid_is_null (local->ia_gfid)) {
+ if ((local->op_ret == -1) && !gf_uuid_is_null (local->ia_gfid)) {
/* ia_gfid set means, at least on one node 'mknod'
is successful */
local->call_count = priv->child_count;
@@ -1590,8 +1590,8 @@ stripe_mknod_first_ifreg_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
local->preparent = *preparent;
local->postparent = *postparent;
- if (uuid_is_null (local->ia_gfid))
- uuid_copy (local->ia_gfid, buf->ia_gfid);
+ if (gf_uuid_is_null (local->ia_gfid))
+ gf_uuid_copy (local->ia_gfid, buf->ia_gfid);
local->preparent.ia_blocks = local->preparent_blocks;
local->preparent.ia_size = local->preparent_size;
local->postparent.ia_blocks = local->postparent_blocks;
@@ -4910,7 +4910,7 @@ stripe_readdirp_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
loc.inode = inode_ref (local_entry->inode);
- uuid_copy (loc.gfid, local_entry->d_stat.ia_gfid);
+ gf_uuid_copy (loc.gfid, local_entry->d_stat.ia_gfid);
local_ent->orig_frame = frame;