2 FUSE: Filesystem in Userspace
3 Copyright (C) 2001-2007 Miklos Szeredi <miklos@szeredi.hu>
5 This program can be distributed under the terms of the GNU LGPLv2.
6 See the file COPYING.LIB
10 #include "fuse_lowlevel.h"
16 int (*receive_buf
)(struct fuse_session
*se
, struct fuse_buf
*buf
,
17 struct fuse_chan
**chp
);
19 void (*process_buf
)(void *data
, const struct fuse_buf
*buf
,
20 struct fuse_chan
*ch
);
22 void (*destroy
) (void *data
);
39 unsigned int ioctl_64bit
: 1;
45 fuse_interrupt_func_t func
;
49 struct fuse_req
*next
;
50 struct fuse_req
*prev
;
53 struct fuse_notify_req
{
55 void (*reply
)(struct fuse_notify_req
*, fuse_req_t
, fuse_ino_t
,
56 const void *, const struct fuse_buf
*);
57 struct fuse_notify_req
*next
;
58 struct fuse_notify_req
*prev
;
65 int no_remote_posix_lock
;
75 int no_auto_inval_data
;
77 int no_readdirplus_auto
;
78 struct fuse_lowlevel_ops op
;
80 struct cuse_data
*cuse_data
;
83 struct fuse_conn_info conn
;
85 struct fuse_req interrupts
;
88 pthread_key_t pipe_key
;
89 int broken_splice_nonblock
;
91 struct fuse_notify_req notify_list
;
94 struct fuse_chan
*fuse_kern_chan_new(int fd
);
96 int fuse_chan_clearfd(struct fuse_chan
*ch
);
99 * Create a new session
101 * @param data user data
102 * @return new session object, or NULL on failure
104 struct fuse_session
*fuse_session_new(void *data
);
107 * Get the user data provided to the session
109 * @param se the session
110 * @return the user data
112 void *fuse_session_data(struct fuse_session
*se
);
115 void fuse_kern_unmount(const char *mountpoint
, int fd
);
116 int fuse_kern_mount(const char *mountpoint
, struct fuse_args
*args
);
118 int fuse_send_reply_iov_nofree(fuse_req_t req
, int error
, struct iovec
*iov
,
120 void fuse_free_req(fuse_req_t req
);
122 void cuse_lowlevel_init(fuse_req_t req
, fuse_ino_t nodeide
, const void *inarg
);
124 int fuse_start_thread(pthread_t
*thread_id
, void *(*func
)(void *), void *arg
);