summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src
diff options
context:
space:
mode:
authorRaghavendra G <raghavendra@zresearch.com>2009-03-25 06:52:05 -0700
committerAnand V. Avati <avati@amp.gluster.com>2009-04-03 19:24:09 +0530
commitcf6f21928dbe3489de5dfdc3513f3be5f5ef529d (patch)
treed9a63fbab63fd185e3801d4c8b42da1efcf0227a /libglusterfs/src
parent6eb419f1ca68f536a700e63c1521e428560a0d9d (diff)
libglusterfsclient code changes
- add dentry support to libglusterfsclient. - changes related to using array, to store context in inode instead of dictionary. - code changes related to cleanup of libglusterfsclient interface. - added glusterfs_mkdir and glusterfs_rmdir - other changes in libglusterfsclient to make it work with code changes in other parts of glusterfs. Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
Diffstat (limited to 'libglusterfs/src')
-rw-r--r--libglusterfs/src/inode.c16
-rw-r--r--libglusterfs/src/inode.h5
2 files changed, 21 insertions, 0 deletions
diff --git a/libglusterfs/src/inode.c b/libglusterfs/src/inode.c
index 90a84f95561..e8c4cca0361 100644
--- a/libglusterfs/src/inode.c
+++ b/libglusterfs/src/inode.c
@@ -205,6 +205,22 @@ __dentry_search_for_inode (inode_t *inode,
}
+dentry_t *
+dentry_search_for_inode (inode_t *inode,
+ ino_t par,
+ const char *name)
+{
+ dentry_t *dentry = NULL;
+ pthread_mutex_lock (&inode->table->lock);
+ {
+ dentry = __dentry_search_for_inode (inode, par, name);
+ }
+ pthread_mutex_unlock (&inode->table->lock);
+
+ return dentry;
+}
+
+
static dentry_t *
__dentry_search (inode_table_t *table,
ino_t par,
diff --git a/libglusterfs/src/inode.h b/libglusterfs/src/inode.h
index d434668a3b4..8800b9767b5 100644
--- a/libglusterfs/src/inode.h
+++ b/libglusterfs/src/inode.h
@@ -148,6 +148,11 @@ inode_t *
inode_from_path (inode_table_t *table,
const char *path);
+dentry_t *
+dentry_search_for_inode (inode_t *inode,
+ ino_t par,
+ const char *name);
+
int
__inode_ctx_put (inode_t *inode, xlator_t *xlator, uint64_t value);