summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/syncop.h
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2015-02-05 21:23:37 +0530
committerVijay Bellur <vbellur@redhat.com>2015-02-06 14:04:32 -0800
commit2efb36047aa11838b2cde93a3e95741e7ba40bae (patch)
treeb5a06756058974d9d390b1781f8c920cf28859d4 /libglusterfs/src/syncop.h
parentf75bb4a9ca14b50c7f828ee3fe4ba73dd78f094c (diff)
syncop: Provide syncop_ftw and syncop_dir_scan utils
ftw provides file tree walk. dir_scan does just a readdir not readdirp. Also changed Afr's self-heal-daemon's crawling functions to use this. These utils will be used by ec in future to do proactive/full healing. Change-Id: I05715ddb789592c1b79a71e98f1e8cc29aac5c26 BUG: 1177601 Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/9485 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Ravishankar N <ravishankar@redhat.com> Reviewed-by: Krutika Dhananjay <kdhananj@redhat.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'libglusterfs/src/syncop.h')
-rw-r--r--libglusterfs/src/syncop.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/libglusterfs/src/syncop.h b/libglusterfs/src/syncop.h
index e95dd6fc33d..40ed0e865e3 100644
--- a/libglusterfs/src/syncop.h
+++ b/libglusterfs/src/syncop.h
@@ -427,4 +427,16 @@ int
syncop_inodelk (xlator_t *subvol, const char *volume, loc_t *loc, int32_t cmd,
struct gf_flock *lock, dict_t *xdata_req, dict_t **xdata_rsp);
+int
+syncop_ftw (xlator_t *subvol, loc_t *loc, int pid, void *data,
+ int (*fn) (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
+ void *data));
+
+int
+syncop_dir_scan (xlator_t *subvol, loc_t *loc, int pid, void *data,
+ int (*fn) (xlator_t *subvol, gf_dirent_t *entry, loc_t *parent,
+ void *data));
+
+int
+syncop_dirfd (xlator_t *subvol, loc_t *loc, fd_t **fd, int pid);
#endif /* _SYNCOP_H */