summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/ha/src/ha.c
diff options
context:
space:
mode:
authorShehjar Tikoo <shehjart@gluster.com>2009-10-01 06:58:47 +0000
committerAnand V. Avati <avati@dev.gluster.com>2009-10-01 07:22:46 -0700
commite11d66c8d6dea72d02f9bcdbf65c67bd5c60b5cc (patch)
treeffa96a3f78b79db2704a5bc410174714fd66fa67 /xlators/cluster/ha/src/ha.c
parent186a86f342625a9dce53fe537f8237c6099d5c54 (diff)
Global: NFS-friendly prototype changes
Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 145 (NFSv3 related additions to 2.1 task list) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=145
Diffstat (limited to 'xlators/cluster/ha/src/ha.c')
-rw-r--r--xlators/cluster/ha/src/ha.c80
1 files changed, 56 insertions, 24 deletions
diff --git a/xlators/cluster/ha/src/ha.c b/xlators/cluster/ha/src/ha.c
index b380cb1e9..b2ca48b10 100644
--- a/xlators/cluster/ha/src/ha.c
+++ b/xlators/cluster/ha/src/ha.c
@@ -64,7 +64,8 @@ ha_lookup_cbk (call_frame_t *frame,
int32_t op_errno,
inode_t *inode,
struct stat *buf,
- dict_t *dict)
+ dict_t *dict,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -307,7 +308,8 @@ ha_truncate_cbk (call_frame_t *frame,
xlator_t *this,
int32_t op_ret,
int32_t op_errno,
- struct stat *buf)
+ struct stat *prebuf,
+ struct stat *postbuf)
{
int ret = -1;
@@ -316,7 +318,8 @@ ha_truncate_cbk (call_frame_t *frame,
STACK_UNWIND (frame,
op_ret,
op_errno,
- buf);
+ prebuf,
+ postbuf);
}
return 0;
}
@@ -357,7 +360,8 @@ ha_ftruncate_cbk (call_frame_t *frame,
xlator_t *this,
int32_t op_ret,
int32_t op_errno,
- struct stat *buf)
+ struct stat *prebuf,
+ struct stat *postbuf)
{
int ret = -1;
@@ -367,7 +371,7 @@ ha_ftruncate_cbk (call_frame_t *frame,
STACK_UNWIND (frame,
op_ret,
op_errno,
- buf);
+ prebuf, postbuf);
}
return 0;
}
@@ -458,7 +462,8 @@ ha_readlink_cbk (call_frame_t *frame,
xlator_t *this,
int32_t op_ret,
int32_t op_errno,
- const char *path)
+ const char *path,
+ struct stat *sbuf)
{
int ret = -1;
@@ -468,7 +473,8 @@ ha_readlink_cbk (call_frame_t *frame,
STACK_UNWIND (frame,
op_ret,
op_errno,
- path);
+ path,
+ sbuf);
}
return 0;
}
@@ -511,7 +517,8 @@ ha_mknod_lookup_cbk (call_frame_t *frame,
int32_t op_errno,
inode_t *inode,
struct stat *buf,
- dict_t *dict)
+ dict_t *dict,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -573,7 +580,9 @@ ha_mknod_cbk (call_frame_t *frame,
int32_t op_ret,
int32_t op_errno,
inode_t *inode,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preparent,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -708,7 +717,8 @@ ha_mkdir_lookup_cbk (call_frame_t *frame,
int32_t op_errno,
inode_t *inode,
struct stat *buf,
- dict_t *dict)
+ dict_t *dict,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -762,7 +772,9 @@ ha_mkdir_cbk (call_frame_t *frame,
int32_t op_ret,
int32_t op_errno,
inode_t *inode,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preparent,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -886,7 +898,9 @@ ha_unlink_cbk (call_frame_t *frame,
void *cookie,
xlator_t *this,
int32_t op_ret,
- int32_t op_errno)
+ int32_t op_errno,
+ struct stat *preparent,
+ struct stat *postparent)
{
int ret = -1;
@@ -931,7 +945,9 @@ ha_rmdir_cbk (call_frame_t *frame,
void *cookie,
xlator_t *this,
int32_t op_ret,
- int32_t op_errno)
+ int32_t op_errno,
+ struct stat *preparent,
+ struct stat *postparent)
{
int ret = -1;
@@ -982,7 +998,8 @@ ha_symlink_lookup_cbk (call_frame_t *frame,
int32_t op_errno,
inode_t *inode,
struct stat *buf,
- dict_t *dict)
+ dict_t *dict,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1036,7 +1053,9 @@ ha_symlink_cbk (call_frame_t *frame,
int32_t op_ret,
int32_t op_errno,
inode_t *inode,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preparent,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1163,7 +1182,11 @@ ha_rename_cbk (call_frame_t *frame,
xlator_t *this,
int32_t op_ret,
int32_t op_errno,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preoldparent,
+ struct stat *postoldparent,
+ struct stat *prenewparent,
+ struct stat *postnewparent)
{
int ret = -1;
@@ -1211,7 +1234,8 @@ ha_link_lookup_cbk (call_frame_t *frame,
int32_t op_errno,
inode_t *inode,
struct stat *buf,
- dict_t *dict)
+ dict_t *dict,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1265,7 +1289,9 @@ ha_link_cbk (call_frame_t *frame,
int32_t op_ret,
int32_t op_errno,
inode_t *inode,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preparent,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1405,7 +1431,9 @@ ha_create_cbk (call_frame_t *frame,
int32_t op_errno,
fd_t *fd,
inode_t *inode,
- struct stat *buf)
+ struct stat *buf,
+ struct stat *preparent,
+ struct stat *postparent)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1602,7 +1630,7 @@ int32_t
ha_open (call_frame_t *frame,
xlator_t *this,
loc_t *loc,
- int32_t flags, fd_t *fd)
+ int32_t flags, fd_t *fd, int wbflags)
{
ha_local_t *local = NULL;
ha_private_t *pvt = NULL;
@@ -1646,7 +1674,7 @@ ha_open (call_frame_t *frame,
ha_open_cbk,
children[i],
children[i]->fops->open,
- loc, flags, fd);
+ loc, flags, fd, wbflags);
if (--cnt == 0)
break;
}
@@ -1719,7 +1747,8 @@ ha_writev_cbk (call_frame_t *frame,
xlator_t *this,
int32_t op_ret,
int32_t op_errno,
- struct stat *stbuf)
+ struct stat *prebuf,
+ struct stat *postbuf)
{
int ret = 0;
ret = ha_handle_cbk (frame, cookie, op_ret, op_errno);
@@ -1728,7 +1757,8 @@ ha_writev_cbk (call_frame_t *frame,
STACK_UNWIND (frame,
op_ret,
op_errno,
- stbuf);
+ prebuf,
+ postbuf);
}
return 0;
}
@@ -1820,7 +1850,9 @@ ha_fsync_cbk (call_frame_t *frame,
void *cookie,
xlator_t *this,
int32_t op_ret,
- int32_t op_errno)
+ int32_t op_errno,
+ struct stat *prebuf,
+ struct stat *postbuf)
{
int ret = 0;
ret = ha_handle_cbk (frame, cookie, op_ret, op_errno);