summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src
diff options
context:
space:
mode:
authorAmar Tumballi <amar@gluster.com>2010-03-28 23:53:17 +0000
committerAnand V. Avati <avati@dev.gluster.com>2010-03-31 02:22:11 -0700
commit31e69430140538f5fee3e8dc89bd2971917820d1 (patch)
treeada4b36ba616bff17f1a2d2ecba46bc3e09ea27f /libglusterfs/src
parenta79d50fc723ffa4d93fa8f567676b18591fac5fe (diff)
fop namespace cleanup.
removed 'lock_notify', 'lock_fnotify', 'setdents', 'getdents' from 'fop' list, and removed 'stats' from mop list, as they are no more used in the codebase, and had made code bulky/buggy. Signed-off-by: Amar Tumballi <amar@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 734 (keep only the working/usable code in build tree to focus more on development) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=734
Diffstat (limited to 'libglusterfs/src')
-rw-r--r--libglusterfs/src/call-stub.c343
-rw-r--r--libglusterfs/src/call-stub.h105
-rw-r--r--libglusterfs/src/common-utils.c5
-rw-r--r--libglusterfs/src/defaults.c143
-rw-r--r--libglusterfs/src/defaults.h27
-rw-r--r--libglusterfs/src/glusterfs.h12
-rw-r--r--libglusterfs/src/protocol.h63
-rw-r--r--libglusterfs/src/xlator.c5
-rw-r--r--libglusterfs/src/xlator.h81
9 files changed, 0 insertions, 784 deletions
diff --git a/libglusterfs/src/call-stub.c b/libglusterfs/src/call-stub.c
index 17d8c8106..ae67f59dc 100644
--- a/libglusterfs/src/call-stub.c
+++ b/libglusterfs/src/call-stub.c
@@ -1139,65 +1139,6 @@ out:
call_stub_t *
-fop_getdents_stub (call_frame_t *frame,
- fop_getdents_t fn,
- fd_t *fd,
- size_t size,
- off_t off,
- int32_t flag)
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 1, GF_FOP_GETDENTS);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- stub->args.getdents.fn = fn;
- stub->args.getdents.size = size;
- stub->args.getdents.off = off;
- if (fd)
- stub->args.getdents.fd = fd_ref (fd);
- stub->args.getdents.flag = flag;
-out:
- return stub;
-}
-
-
-call_stub_t *
-fop_getdents_cbk_stub (call_frame_t *frame,
- fop_getdents_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno,
- dir_entry_t *entries,
- int32_t count)
-
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 0, GF_FOP_GETDENTS);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- stub->args.getdents_cbk.fn = fn;
- stub->args.getdents_cbk.op_ret = op_ret;
- stub->args.getdents_cbk.op_errno = op_errno;
- if (op_ret >= 0) {
- stub->args.getdents_cbk.entries.next = entries->next;
- /* FIXME: are entries not needed in the caller after
- * creating stub? */
- entries->next = NULL;
- }
-
- stub->args.getdents_cbk.count = count;
-out:
- return stub;
-}
-
-
-
-call_stub_t *
fop_fsyncdir_stub (call_frame_t *frame,
fop_fsyncdir_t fn,
fd_t *fd,
@@ -1768,55 +1709,6 @@ fop_fentrylk_cbk_stub (call_frame_t *frame, fop_fentrylk_cbk_t fn,
call_stub_t *
-fop_setdents_stub (call_frame_t *frame,
- fop_setdents_t fn,
- fd_t *fd,
- int32_t flags,
- dir_entry_t *entries,
- int32_t count)
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 1, GF_FOP_SETDENTS);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- if (fd)
- stub->args.setdents.fd = fd_ref (fd);
- stub->args.setdents.fn = fn;
- stub->args.setdents.flags = flags;
- stub->args.setdents.count = count;
- if (entries) {
- stub->args.setdents.entries.next = entries->next;
- entries->next = NULL;
- }
-out:
- return stub;
-}
-
-call_stub_t *
-fop_setdents_cbk_stub (call_frame_t *frame,
- fop_setdents_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno)
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 0, GF_FOP_SETDENTS);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- stub->args.setdents_cbk.fn = fn;
- stub->args.setdents_cbk.op_ret = op_ret;
- stub->args.setdents_cbk.op_errno = op_errno;
-out:
- return stub;
-
-}
-
-call_stub_t *
fop_readdirp_cbk_stub (call_frame_t *frame,
fop_readdirp_cbk_t fn,
int32_t op_ret,
@@ -2141,90 +2033,6 @@ fop_fxattrop_stub (call_frame_t *frame,
call_stub_t *
-fop_lock_notify_cbk_stub (call_frame_t *frame, fop_lock_notify_cbk_t fn,
- int32_t op_ret, int32_t op_errno)
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 0, GF_FOP_LOCK_NOTIFY);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- stub->args.lock_notify_cbk.fn = fn;
- stub->args.lock_notify_cbk.op_ret = op_ret;
- stub->args.lock_notify_cbk.op_errno = op_errno;
-
-out:
- return stub;
-}
-
-
-call_stub_t *
-fop_lock_notify_stub (call_frame_t *frame, fop_lock_notify_t fn,
- loc_t *loc, int32_t timeout)
-{
- call_stub_t *stub = NULL;
-
- if (!frame)
- return NULL;
-
- stub = stub_new (frame, 1, GF_FOP_LOCK_NOTIFY);
- if (!stub)
- return NULL;
-
- stub->args.lock_notify.fn = fn;
-
- loc_copy (&stub->args.lock_notify.loc, loc);
-
- stub->args.lock_notify.timeout = timeout;
-
- return stub;
-}
-
-
-call_stub_t *
-fop_lock_fnotify_cbk_stub (call_frame_t *frame, fop_lock_fnotify_cbk_t fn,
- int32_t op_ret, int32_t op_errno)
-{
- call_stub_t *stub = NULL;
-
- GF_VALIDATE_OR_GOTO ("call-stub", frame, out);
-
- stub = stub_new (frame, 0, GF_FOP_LOCK_FNOTIFY);
- GF_VALIDATE_OR_GOTO ("call-stub", stub, out);
-
- stub->args.lock_fnotify_cbk.fn = fn;
- stub->args.lock_fnotify_cbk.op_ret = op_ret;
- stub->args.lock_fnotify_cbk.op_errno = op_errno;
-
-out:
- return stub;
-}
-
-
-call_stub_t *
-fop_lock_fnotify_stub (call_frame_t *frame, fop_lock_fnotify_t fn,
- fd_t *fd, int32_t timeout)
-{
- call_stub_t *stub = NULL;
-
- if (!frame)
- return NULL;
-
- stub = stub_new (frame, 1, GF_FOP_LOCK_FNOTIFY);
- if (!stub)
- return NULL;
-
- stub->args.lock_fnotify.fn = fn;
-
- stub->args.lock_fnotify.fd = fd_ref (fd);
- stub->args.lock_fnotify.timeout = timeout;
-
- return stub;
-}
-
-call_stub_t *
fop_setattr_cbk_stub (call_frame_t *frame,
fop_setattr_cbk_t fn,
int32_t op_ret,
@@ -2564,17 +2372,6 @@ call_resume_wind (call_stub_t *stub)
break;
}
- case GF_FOP_GETDENTS:
- {
- stub->args.getdents.fn (stub->frame,
- stub->frame->this,
- stub->args.getdents.fd,
- stub->args.getdents.size,
- stub->args.getdents.off,
- stub->args.getdents.flag);
- break;
- }
-
case GF_FOP_FSYNCDIR:
{
stub->args.fsyncdir.fn (stub->frame,
@@ -2677,17 +2474,6 @@ call_resume_wind (call_stub_t *stub)
break;
}
- case GF_FOP_SETDENTS:
- {
- stub->args.setdents.fn (stub->frame,
- stub->frame->this,
- stub->args.setdents.fd,
- stub->args.setdents.flags,
- &stub->args.setdents.entries,
- stub->args.setdents.count);
- break;
- }
-
case GF_FOP_CHECKSUM:
{
stub->args.checksum.fn (stub->frame,
@@ -2747,22 +2533,6 @@ call_resume_wind (call_stub_t *stub)
break;
}
- case GF_FOP_LOCK_NOTIFY:
- {
- stub->args.lock_notify.fn (stub->frame,
- stub->frame->this,
- &stub->args.lock_notify.loc,
- stub->args.lock_notify.timeout);
- break;
- }
- case GF_FOP_LOCK_FNOTIFY:
- {
- stub->args.lock_fnotify.fn (stub->frame,
- stub->frame->this,
- stub->args.lock_fnotify.fd,
- stub->args.lock_fnotify.timeout);
- break;
- }
case GF_FOP_SETATTR:
{
stub->args.setattr.fn (stub->frame,
@@ -3255,25 +3025,6 @@ call_resume_unwind (call_stub_t *stub)
break;
}
- case GF_FOP_GETDENTS:
- {
- if (!stub->args.getdents_cbk.fn)
- STACK_UNWIND (stub->frame,
- stub->args.getdents_cbk.op_ret,
- stub->args.getdents_cbk.op_errno,
- &stub->args.getdents_cbk.entries,
- stub->args.getdents_cbk.count);
- else
- stub->args.getdents_cbk.fn (stub->frame,
- stub->frame->cookie,
- stub->frame->this,
- stub->args.getdents_cbk.op_ret,
- stub->args.getdents_cbk.op_errno,
- &stub->args.getdents_cbk.entries,
- stub->args.getdents_cbk.count);
- break;
- }
-
case GF_FOP_FSYNCDIR:
{
if (!stub->args.fsyncdir_cbk.fn)
@@ -3452,20 +3203,6 @@ call_resume_unwind (call_stub_t *stub)
break;
}
- case GF_FOP_SETDENTS:
- {
- if (!stub->args.setdents_cbk.fn)
- STACK_UNWIND (stub->frame,
- stub->args.setdents_cbk.op_ret,
- stub->args.setdents_cbk.op_errno);
- else
- stub->args.setdents_cbk.fn (stub->frame,
- stub->frame->cookie,
- stub->frame->this,
- stub->args.setdents_cbk.op_ret,
- stub->args.setdents_cbk.op_errno);
- break;
- }
case GF_FOP_CHECKSUM:
{
@@ -3596,34 +3333,6 @@ call_resume_unwind (call_stub_t *stub)
break;
}
- case GF_FOP_LOCK_NOTIFY:
- {
- if (!stub->args.lock_notify_cbk.fn)
- STACK_UNWIND (stub->frame,
- stub->args.lock_notify_cbk.op_ret,
- stub->args.lock_notify_cbk.op_errno);
- else
- stub->args.lock_notify_cbk.fn (stub->frame,
- stub->frame->cookie,
- stub->frame->this,
- stub->args.lock_notify_cbk.op_ret,
- stub->args.lock_notify_cbk.op_errno);
- break;
- }
- case GF_FOP_LOCK_FNOTIFY:
- {
- if (!stub->args.lock_fnotify_cbk.fn)
- STACK_UNWIND (stub->frame,
- stub->args.lock_fnotify_cbk.op_ret,
- stub->args.lock_fnotify_cbk.op_errno);
- else
- stub->args.lock_fnotify_cbk.fn (stub->frame,
- stub->frame->cookie,
- stub->frame->this,
- stub->args.lock_fnotify_cbk.op_ret,
- stub->args.lock_fnotify_cbk.op_errno);
- break;
- }
case GF_FOP_SETATTR:
{
if (!stub->args.setattr_cbk.fn)
@@ -3839,13 +3548,6 @@ call_stub_destroy_wind (call_stub_t *stub)
break;
}
- case GF_FOP_GETDENTS:
- {
- if (stub->args.getdents.fd)
- fd_unref (stub->args.getdents.fd);
- break;
- }
-
case GF_FOP_FSYNCDIR:
{
if (stub->args.fsyncdir.fd)
@@ -3928,21 +3630,6 @@ call_stub_destroy_wind (call_stub_t *stub)
break;
}
- case GF_FOP_SETDENTS:
- {
- dir_entry_t *entry, *next;
- if (stub->args.setdents.fd)
- fd_unref (stub->args.setdents.fd);
- entry = stub->args.setdents.entries.next;
- while (entry) {
- next = entry->next;
- FREE (entry->name);
- FREE (entry);
- entry = next;
- }
- break;
- }
-
case GF_FOP_CHECKSUM:
{
loc_wipe (&stub->args.checksum.loc);
@@ -3983,17 +3670,6 @@ call_stub_destroy_wind (call_stub_t *stub)
dict_unref (stub->args.fxattrop.xattr);
break;
}
- case GF_FOP_LOCK_NOTIFY:
- {
- loc_wipe (&stub->args.lock_notify.loc);
- break;
- }
- case GF_FOP_LOCK_FNOTIFY:
- {
- if (stub->args.lock_fnotify.fd)
- fd_unref (stub->args.lock_fnotify.fd);
- break;
- }
case GF_FOP_SETATTR:
{
loc_wipe (&stub->args.setattr.loc);
@@ -4144,22 +3820,6 @@ call_stub_destroy_unwind (call_stub_t *stub)
}
break;
- case GF_FOP_GETDENTS:
- {
- dir_entry_t *tmp = NULL, *entries = NULL;
-
- entries = &stub->args.getdents_cbk.entries;
- if (stub->args.getdents_cbk.op_ret >= 0) {
- while (entries->next) {
- tmp = entries->next;
- entries->next = entries->next->next;
- FREE (tmp->name);
- FREE (tmp);
- }
- }
- }
- break;
-
case GF_FOP_FSYNCDIR:
break;
@@ -4197,9 +3857,6 @@ call_stub_destroy_unwind (call_stub_t *stub)
}
break;
- case GF_FOP_SETDENTS:
- break;
-
case GF_FOP_CHECKSUM:
{
if (stub->args.checksum_cbk.op_ret >= 0) {
diff --git a/libglusterfs/src/call-stub.h b/libglusterfs/src/call-stub.h
index 3160e9dd0..afc5b13e9 100644
--- a/libglusterfs/src/call-stub.h
+++ b/libglusterfs/src/call-stub.h
@@ -324,35 +324,6 @@ typedef struct {
fd_t *fd;
} opendir_cbk;
- /* getdents */
- struct {
- fop_getdents_t fn;
- fd_t *fd;
- size_t size;
- off_t off;
- int32_t flag;
- } getdents;
- struct {
- fop_getdents_cbk_t fn;
- int32_t op_ret;
- int32_t op_errno;
- dir_entry_t entries;
- int32_t count;
- } getdents_cbk;
-
- /* setdents */
- struct {
- fop_setdents_t fn;
- fd_t *fd;
- int32_t flags;
- dir_entry_t entries;
- int32_t count;
- } setdents;
- struct {
- fop_setdents_cbk_t fn;
- int32_t op_ret;
- int32_t op_errno;
- } setdents_cbk;
/* fsyncdir */
struct {
@@ -587,28 +558,6 @@ typedef struct {
dict_t *xattr;
} fxattrop_cbk;
- struct {
- fop_lock_notify_t fn;
- loc_t loc;
- int32_t timeout;
- } lock_notify;
- struct {
- fop_lock_notify_cbk_t fn;
- int32_t op_ret;
- int32_t op_errno;
- } lock_notify_cbk;
-
- struct {
- fop_lock_fnotify_t fn;
- fd_t *fd;
- int32_t timeout;
- } lock_fnotify;
- struct {
- fop_lock_fnotify_cbk_t fn;
- int32_t op_ret;
- int32_t op_errno;
- } lock_fnotify_cbk;
-
/* setattr */
struct {
fop_setattr_t fn;
@@ -945,36 +894,6 @@ fop_opendir_cbk_stub (call_frame_t *frame,
fd_t *fd);
call_stub_t *
-fop_getdents_stub (call_frame_t *frame,
- fop_getdents_t fn,
- fd_t *fd,
- size_t size,
- off_t off,
- int32_t flag);
-
-call_stub_t *
-fop_getdents_cbk_stub (call_frame_t *frame,
- fop_getdents_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno,
- dir_entry_t *entries,
- int32_t count);
-
-call_stub_t *
-fop_setdents_stub (call_frame_t *frame,
- fop_setdents_t fn,
- fd_t *fd,
- int32_t flags,
- dir_entry_t *entries,
- int32_t count);
-
-call_stub_t *
-fop_setdents_cbk_stub (call_frame_t *frame,
- fop_setdents_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno);
-
-call_stub_t *
fop_fsyncdir_stub (call_frame_t *frame,
fop_fsyncdir_t fn,
fd_t *fd,
@@ -1194,30 +1113,6 @@ fop_fxattrop_stub_cbk_stub (call_frame_t *frame,
int32_t op_errno);
call_stub_t *
-fop_lock_notify_stub_cbk_stub (call_frame_t *frame,
- fop_lock_notify_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno);
-
-call_stub_t *
-fop_lock_notify_stub (call_frame_t *frame,
- fop_lock_notify_t fn,
- loc_t *loc,
- int32_t timeout);
-
-call_stub_t *
-fop_lock_fnotify_stub_cbk_stub (call_frame_t *frame,
- fop_lock_fnotify_cbk_t fn,
- int32_t op_ret,
- int32_t op_errno);
-
-call_stub_t *
-fop_lock_fnotify_stub (call_frame_t *frame,
- fop_lock_fnotify_t fn,
- fd_t *fd,
- int32_t timeout);
-
-call_stub_t *
fop_setattr_stub (call_frame_t *frame,
fop_setattr_t fn,
loc_t *loc,
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c
index 31727adf8..984ad0794 100644
--- a/libglusterfs/src/common-utils.c
+++ b/libglusterfs/src/common-utils.c
@@ -205,7 +205,6 @@ gf_global_variable_init()
gf_fop_list[GF_FOP_GETXATTR] = "GETXATTR";
gf_fop_list[GF_FOP_REMOVEXATTR] = "REMOVEXATTR";
gf_fop_list[GF_FOP_OPENDIR] = "OPENDIR";
- gf_fop_list[GF_FOP_GETDENTS] = "GETDENTS"; /* 20 */
gf_fop_list[GF_FOP_FSYNCDIR] = "FSYNCDIR";
gf_fop_list[GF_FOP_ACCESS] = "ACCESS";
gf_fop_list[GF_FOP_CREATE] = "CREATE";
@@ -213,7 +212,6 @@ gf_global_variable_init()
gf_fop_list[GF_FOP_FSTAT] = "FSTAT"; /* 25 */
gf_fop_list[GF_FOP_LK] = "LK";
gf_fop_list[GF_FOP_LOOKUP] = "LOOKUP";
- gf_fop_list[GF_FOP_SETDENTS] = "SETDENTS";
gf_fop_list[GF_FOP_READDIR] = "READDIR";
gf_fop_list[GF_FOP_INODELK] = "INODELK"; /* 30 */
gf_fop_list[GF_FOP_FINODELK] = "FINODELK";
@@ -222,8 +220,6 @@ gf_global_variable_init()
gf_fop_list[GF_FOP_CHECKSUM] = "CHECKSUM"; /* 36 */
gf_fop_list[GF_FOP_XATTROP] = "XATTROP";
gf_fop_list[GF_FOP_FXATTROP] = "FXATTROP";
- gf_fop_list[GF_FOP_LOCK_NOTIFY] = "LOCK_NOTIFY";
- gf_fop_list[GF_FOP_LOCK_FNOTIFY]= "LOCK_FNOTIFY";
gf_fop_list[GF_FOP_FSETXATTR] = "FSETXATTR";
gf_fop_list[GF_FOP_FGETXATTR] = "FGETXATTR";
gf_fop_list[GF_FOP_RCHECKSUM] = "RCHECKSUM";
@@ -233,7 +229,6 @@ gf_global_variable_init()
gf_mop_list[GF_MOP_SETVOLUME] = "SETVOLUME"; /* 0 */
gf_mop_list[GF_MOP_GETVOLUME] = "GETVOLUME"; /* 1 */
- gf_mop_list[GF_MOP_STATS] = "STATS";
gf_mop_list[GF_MOP_SETSPEC] = "SETSPEC";
gf_mop_list[GF_MOP_GETSPEC] = "GETSPEC";
gf_mop_list[GF_MOP_LOG] = "LOG";
diff --git a/libglusterfs/src/defaults.c b/libglusterfs/src/defaults.c
index ab88e024c..a007beb45 100644
--- a/libglusterfs/src/defaults.c
+++ b/libglusterfs/src/defaults.c
@@ -706,77 +706,6 @@ default_opendir (call_frame_t *frame,
return 0;
}
-
-static int32_t
-default_getdents_cbk (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno,
- dir_entry_t *entries,
- int32_t count)
-{
- STACK_UNWIND (frame,
- op_ret,
- op_errno,
- entries,
- count);
- return 0;
-}
-
-int32_t
-default_getdents (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- size_t size,
- off_t offset,
- int32_t flag)
-{
- STACK_WIND (frame,
- default_getdents_cbk,
- FIRST_CHILD(this),
- FIRST_CHILD(this)->fops->getdents,
- fd,
- size,
- offset,
- flag);
- return 0;
-}
-
-
-static int32_t
-default_setdents_cbk (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno)
-{
- STACK_UNWIND (frame,
- op_ret,
- op_errno);
- return 0;
-}
-
-int32_t
-default_setdents (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- int32_t flags,
- dir_entry_t *entries,
- int32_t count)
-{
- STACK_WIND (frame,
- default_setdents_cbk,
- FIRST_CHILD(this),
- FIRST_CHILD(this)->fops->setdents,
- fd,
- flags,
- entries,
- count);
- return 0;
-}
-
-
static int32_t
default_fsyncdir_cbk (call_frame_t *frame,
void *cookie,
@@ -1171,35 +1100,6 @@ default_fentrylk (call_frame_t *frame, xlator_t *this,
/* Management operations */
static int32_t
-default_stats_cbk (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno,
- struct xlator_stats *stats)
-{
- STACK_UNWIND (frame,
- op_ret,
- op_errno,
- stats);
- return 0;
-}
-
-
-int32_t
-default_stats (call_frame_t *frame,
- xlator_t *this,
- int32_t flags)
-{
- STACK_WIND (frame,
- default_stats_cbk,
- FIRST_CHILD(this),
- FIRST_CHILD(this)->mops->stats,
- flags);
- return 0;
-}
-
-static int32_t
default_getspec_cbk (call_frame_t *frame,
void *cookie,
xlator_t *this,
@@ -1379,49 +1279,6 @@ default_readdirp (call_frame_t *frame,
return 0;
}
-int32_t
-default_lock_notify_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
- int32_t op_ret, int32_t op_errno)
-{
- STACK_UNWIND (frame, op_ret, op_errno);
- return 0;
-}
-
-
-int32_t
-default_lock_fnotify_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
- int32_t op_ret, int32_t op_errno)
-{
- STACK_UNWIND (frame, op_ret, op_errno);
- return 0;
-}
-
-
-int32_t
-default_lock_notify (call_frame_t *frame, xlator_t *this,
- loc_t *loc, int32_t timeout)
-{
- STACK_WIND (frame,
- default_lock_notify_cbk,
- FIRST_CHILD (this),
- FIRST_CHILD (this)->fops->lock_notify,
- loc, timeout);
- return 0;
-}
-
-
-int32_t
-default_lock_fnotify (call_frame_t *frame, xlator_t *this,
- fd_t *fd, int32_t timeout)
-{
- STACK_WIND (frame,
- default_lock_notify_cbk,
- FIRST_CHILD (this),
- FIRST_CHILD (this)->fops->lock_fnotify,
- fd, timeout);
- return 0;
-}
-
/* notify */
int
diff --git a/libglusterfs/src/defaults.h b/libglusterfs/src/defaults.h
index daab88919..d98fa02cf 100644
--- a/libglusterfs/src/defaults.h
+++ b/libglusterfs/src/defaults.h
@@ -33,10 +33,6 @@
/* Management Operations */
-int32_t default_stats (call_frame_t *frame,
- xlator_t *this,
- int32_t flags);
-
int32_t default_getspec (call_frame_t *frame,
xlator_t *this,
const char *key,
@@ -164,13 +160,6 @@ int32_t default_opendir (call_frame_t *frame,
xlator_t *this,
loc_t *loc, fd_t *fd);
-int32_t default_getdents (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- size_t size,
- off_t offset,
- int32_t flag);
-
int32_t default_fsyncdir (call_frame_t *frame,
xlator_t *this,
fd_t *fd,
@@ -239,13 +228,6 @@ int32_t default_readdirp (call_frame_t *frame,
fd_t *fd,
size_t size, off_t off);
-int32_t default_setdents (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- int32_t flags,
- dir_entry_t *entries,
- int32_t count);
-
int32_t default_xattrop (call_frame_t *frame,
xlator_t *this,
loc_t *loc,
@@ -258,15 +240,6 @@ int32_t default_fxattrop (call_frame_t *frame,
gf_xattrop_flags_t flags,
dict_t *dict);
-int32_t
-default_lock_notify (call_frame_t *frame, xlator_t *this,
- loc_t *loc, int32_t timeout);
-
-int32_t
-default_lock_fnotify (call_frame_t *frame, xlator_t *this,
- fd_t *fd, int32_t timeout);
-
-
int32_t default_notify (xlator_t *this,
int32_t event,
void *data,
diff --git a/libglusterfs/src/glusterfs.h b/libglusterfs/src/glusterfs.h
index 464c43025..4abde409b 100644
--- a/libglusterfs/src/glusterfs.h
+++ b/libglusterfs/src/glusterfs.h
@@ -100,7 +100,6 @@ typedef enum {
GF_FOP_GETXATTR,
GF_FOP_REMOVEXATTR,/* 20 */
GF_FOP_OPENDIR,
- GF_FOP_GETDENTS,
GF_FOP_FSYNCDIR,
GF_FOP_ACCESS,
GF_FOP_CREATE, /* 25 */
@@ -108,7 +107,6 @@ typedef enum {
GF_FOP_FSTAT,
GF_FOP_LK,
GF_FOP_LOOKUP,
- GF_FOP_SETDENTS,
GF_FOP_READDIR,
GF_FOP_INODELK, /* 35 */
GF_FOP_FINODELK,
@@ -117,8 +115,6 @@ typedef enum {
GF_FOP_CHECKSUM,
GF_FOP_XATTROP, /* 40 */
GF_FOP_FXATTROP,
- GF_FOP_LOCK_NOTIFY,
- GF_FOP_LOCK_FNOTIFY,
GF_FOP_FGETXATTR,
GF_FOP_FSETXATTR, /* 45 */
GF_FOP_RCHECKSUM,
@@ -132,7 +128,6 @@ typedef enum {
typedef enum {
GF_MOP_SETVOLUME, /* 0 */
GF_MOP_GETVOLUME, /* 1 */
- GF_MOP_STATS,
GF_MOP_SETSPEC,
GF_MOP_GETSPEC,
GF_MOP_PING, /* 5 */
@@ -187,13 +182,6 @@ typedef enum {
} entrylk_type;
typedef enum {
- GF_GET_ALL = 1,
- GF_GET_DIR_ONLY,
- GF_GET_SYMLINK_ONLY,
- GF_GET_REGULAR_FILES_ONLY,
-} glusterfs_getdents_flags_t;
-
-typedef enum {
GF_XATTROP_ADD_ARRAY,
} gf_xattrop_flags_t;
diff --git a/libglusterfs/src/protocol.h b/libglusterfs/src/protocol.h
index 829d3fa83..f8e03da27 100644
--- a/libglusterfs/src/protocol.h
+++ b/libglusterfs/src/protocol.h
@@ -838,31 +838,6 @@ typedef struct {
char dict[0];
} __attribute__((packed)) gf_fop_lookup_rsp_t;
-
-typedef struct {
- uint64_t ino;
- uint64_t gen;
- int64_t fd;
- uint32_t flags;
- uint32_t count;
- char buf[0];
-} __attribute__((packed)) gf_fop_setdents_req_t;
-typedef struct { } __attribute__((packed)) gf_fop_setdents_rsp_t;
-
-typedef struct {
- uint64_t ino;
- uint64_t gen;
- int64_t fd;
- uint64_t offset;
- uint32_t size;
- uint32_t flags;
-} __attribute__((packed)) gf_fop_getdents_req_t;
-typedef struct {
- uint32_t count;
- char buf[0];
-} __attribute__((packed)) gf_fop_getdents_rsp_t;
-
-
typedef struct {
uint64_t ino;
uint64_t gen;
@@ -906,44 +881,6 @@ typedef struct {
unsigned char strong_checksum[0];
} __attribute__((packed)) gf_fop_rchecksum_rsp_t;
-
-typedef struct {
- uint64_t ino;
- uint64_t gen;
- int32_t timeout;
-} __attribute__((packed)) gf_fop_lock_notify_req_t;
-typedef struct { } __attribute__((packed)) gf_fop_lock_notify_rsp_t;
-
-
-typedef struct {
- int64_t fd;
- int32_t timeout;
-} __attribute__((packed)) gf_fop_lock_fnotify_req_t;
-typedef struct { } __attribute__((packed)) gf_fop_lock_fnotify_rsp_t;
-
-
-typedef struct {
- char name[0];
-} __attribute__((packed)) gf_mop_lock_req_t;
-typedef struct {} __attribute__((packed)) gf_mop_lock_rsp_t;
-
-typedef struct {
- char name[0];
-} __attribute__((packed)) gf_mop_unlock_req_t;
-typedef struct {} __attribute__((packed)) gf_mop_unlock_rsp_t;
-
-typedef struct {
- char pattern[0];
-} __attribute__((packed)) gf_mop_listlocks_req_t;
-typedef struct {} __attribute__((packed)) gf_mop_listlocks_rsp_t;
-
-typedef struct {
- uint32_t flags;
-} __attribute__((packed)) gf_mop_stats_req_t;
-typedef struct {
- char buf[0];
-} __attribute__((packed)) gf_mop_stats_rsp_t;
-
typedef struct {
uint32_t flags;
uint32_t keylen;
diff --git a/libglusterfs/src/xlator.c b/libglusterfs/src/xlator.c
index bc36173d1..ffa1d94e4 100644
--- a/libglusterfs/src/xlator.c
+++ b/libglusterfs/src/xlator.c
@@ -90,19 +90,14 @@ fill_defaults (xlator_t *xl)
SET_DEFAULT_FOP (entrylk);
SET_DEFAULT_FOP (fentrylk);
SET_DEFAULT_FOP (lookup);
- SET_DEFAULT_FOP (setdents);
- SET_DEFAULT_FOP (getdents);
SET_DEFAULT_FOP (checksum);
SET_DEFAULT_FOP (rchecksum);
SET_DEFAULT_FOP (xattrop);
SET_DEFAULT_FOP (fxattrop);
- SET_DEFAULT_FOP (lock_notify);
- SET_DEFAULT_FOP (lock_fnotify);
SET_DEFAULT_FOP (setattr);
SET_DEFAULT_FOP (fsetattr);
SET_DEFAULT_MOP (log);
- SET_DEFAULT_MOP (stats);
SET_DEFAULT_CBK (release);
SET_DEFAULT_CBK (releasedir);
diff --git a/libglusterfs/src/xlator.h b/libglusterfs/src/xlator.h
index 4b9b3e9ce..8cde2ed31 100644
--- a/libglusterfs/src/xlator.h
+++ b/libglusterfs/src/xlator.h
@@ -84,27 +84,6 @@ struct _loc {
inode_t *parent;
};
-
-struct xlator_stats {
- uint64_t nr_files; /* Number of files open via this xlator */
- uint64_t free_disk; /* Mega bytes */
- uint64_t total_disk_size; /* Mega Bytes */
- uint64_t disk_usage; /* Mega bytes */
- uint64_t disk_speed; /* MHz or Mbps */
- uint64_t nr_clients; /* Number of client nodes */
- uint64_t write_usage;
- uint64_t read_usage; /* add more stats here */
-};
-
-
-
-typedef int32_t (*mop_stats_cbk_t) (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno,
- struct xlator_stats *stats);
-
typedef int32_t (*mop_getspec_cbk_t) (call_frame_t *frame,
void *cookie,
xlator_t *this,
@@ -136,9 +115,6 @@ typedef int32_t (*mop_setvolume_t) (call_frame_t *frame,
xlator_t *this,
const char *volume);
-typedef int32_t (*mop_stats_t) (call_frame_t *frame,
- xlator_t *this,
- int32_t flags);
typedef int32_t (*mop_getspec_t) (call_frame_t *frame,
xlator_t *this,
@@ -160,12 +136,10 @@ typedef int32_t (*fop_rchecksum_t) (call_frame_t *frame,
int32_t len);
struct xlator_mops {
- mop_stats_t stats;
mop_getspec_t getspec;
mop_log_t log;
mop_log_cbk_t log_cbk;
- mop_stats_cbk_t stats_cbk;
mop_getspec_cbk_t getspec_cbk;
};
@@ -348,14 +322,6 @@ typedef int32_t (*fop_opendir_cbk_t) (call_frame_t *frame,
int32_t op_errno,
fd_t *fd);
-typedef int32_t (*fop_getdents_cbk_t) (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno,
- dir_entry_t *entries,
- int32_t count);
-
typedef int32_t (*fop_fsyncdir_cbk_t) (call_frame_t *frame,
void *cookie,
xlator_t *this,
@@ -432,12 +398,6 @@ typedef int32_t (*fop_fentrylk_cbk_t) (call_frame_t *frame,
int32_t op_ret,
int32_t op_errno);
-typedef int32_t (*fop_setdents_cbk_t) (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno);
-
typedef int32_t (*fop_readdir_cbk_t) (call_frame_t *frame,
void *cookie,
xlator_t *this,
@@ -466,17 +426,6 @@ typedef int32_t (*fop_fxattrop_cbk_t) (call_frame_t *frame,
int32_t op_errno,
dict_t *xattr);
-typedef int32_t (*fop_lock_notify_cbk_t) (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno);
-
-typedef int32_t (*fop_lock_fnotify_cbk_t) (call_frame_t *frame,
- void *cookie,
- xlator_t *this,
- int32_t op_ret,
- int32_t op_errno);
typedef int32_t (*fop_setattr_cbk_t) (call_frame_t *frame,
void *cookie,
@@ -612,13 +561,6 @@ typedef int32_t (*fop_opendir_t) (call_frame_t *frame,
loc_t *loc,
fd_t *fd);
-typedef int32_t (*fop_getdents_t) (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- size_t size,
- off_t offset,
- int32_t flag);
-
typedef int32_t (*fop_fsyncdir_t) (call_frame_t *frame,
xlator_t *this,
fd_t *fd,
@@ -687,13 +629,6 @@ typedef int32_t (*fop_fentrylk_t) (call_frame_t *frame,
const char *basename, entrylk_cmd cmd,
entrylk_type type);
-typedef int32_t (*fop_setdents_t) (call_frame_t *frame,
- xlator_t *this,
- fd_t *fd,
- int32_t flags,
- dir_entry_t *entries,
- int32_t count);
-
typedef int32_t (*fop_readdir_t) (call_frame_t *frame,
xlator_t *this,
fd_t *fd,
@@ -718,14 +653,6 @@ typedef int32_t (*fop_fxattrop_t) (call_frame_t *frame,
gf_xattrop_flags_t optype,
dict_t *xattr);
-typedef int32_t (*fop_lock_notify_t) (call_frame_t *frame,
- xlator_t *this, loc_t *loc,
- int32_t timeout);
-
-typedef int32_t (*fop_lock_fnotify_t) (call_frame_t *frame,
- xlator_t *this, fd_t *fd,
- int32_t timeout);
-
typedef int32_t (*fop_setattr_t) (call_frame_t *frame,
xlator_t *this,
loc_t *loc,
@@ -775,14 +702,10 @@ struct xlator_fops {
fop_finodelk_t finodelk;
fop_entrylk_t entrylk;
fop_fentrylk_t fentrylk;
- fop_setdents_t setdents;
- fop_getdents_t getdents;
fop_checksum_t checksum;
fop_rchecksum_t rchecksum;
fop_xattrop_t xattrop;
fop_fxattrop_t fxattrop;
- fop_lock_notify_t lock_notify;
- fop_lock_fnotify_t lock_fnotify;
fop_setattr_t setattr;
fop_fsetattr_t fsetattr;
@@ -822,14 +745,10 @@ struct xlator_fops {
fop_finodelk_cbk_t finodelk_cbk;
fop_entrylk_cbk_t entrylk_cbk;
fop_fentrylk_cbk_t fentrylk_cbk;
- fop_setdents_cbk_t setdents_cbk;
- fop_getdents_cbk_t getdents_cbk;
fop_checksum_cbk_t checksum_cbk;
fop_rchecksum_cbk_t rchecksum_cbk;
fop_xattrop_cbk_t xattrop_cbk;
fop_fxattrop_cbk_t fxattrop_cbk;
- fop_lock_notify_cbk_t lock_notify_cbk;
- fop_lock_fnotify_cbk_t lock_fnotify_cbk;
fop_setattr_cbk_t setattr_cbk;
fop_fsetattr_cbk_t fsetattr_cbk;
};