diff options
author | Miklos Szeredi <miklos@szeredi.hu> | 2005-09-09 13:10:36 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-09-09 14:03:47 -0700 |
commit | 04730fef1f9c7277e5c730b193e681ac095b0507 (patch) | |
tree | 3694ea435eb38f10dadc5c8b6abd603a7e10f52e /fs/fuse/dev.c | |
parent | 413ef8cb302511d8e995e2b0e5517ee1a65b9c77 (diff) |
[PATCH] fuse: transfer readdir data through device
This patch removes a long lasting "hack" in FUSE, which used a separate
channel (a file descriptor refering to a disk-file) to transfer directory
contents from userspace to the kernel.
The patch adds three new operations (OPENDIR, READDIR, RELEASEDIR), which
have semantics and implementation exactly maching the respective file
operations (OPEN, READ, RELEASE).
This simplifies the directory reading code. Also disk space is not
necessary, which can be important in embedded systems.
Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/fuse/dev.c')
-rw-r--r-- | fs/fuse/dev.c | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c index ca6fc0e96d7c..e4ada021d087 100644 --- a/fs/fuse/dev.c +++ b/fs/fuse/dev.c @@ -731,13 +731,6 @@ static struct fuse_req *request_find(struct fuse_conn *fc, u64 unique) return NULL; } -/* fget() needs to be done in this context */ -static void process_getdir(struct fuse_req *req) -{ - struct fuse_getdir_out_i *arg = req->out.args[0].value; - arg->file = fget(arg->fd); -} - static int copy_out_args(struct fuse_copy_state *cs, struct fuse_out *out, unsigned nbytes) { @@ -817,8 +810,6 @@ static ssize_t fuse_dev_writev(struct file *file, const struct iovec *iov, if (!err) { if (req->interrupted) err = -ENOENT; - else if (req->in.h.opcode == FUSE_GETDIR && !oh.error) - process_getdir(req); } else if (!req->interrupted) req->out.h.error = -EIO; request_end(fc, req); |