1 #ifndef _LINUX_SUNRPC_RPC_PIPE_FS_H
2 #define _LINUX_SUNRPC_RPC_PIPE_FS_H
6 #include <linux/workqueue.h>
17 ssize_t (*upcall
)(struct file
*, struct rpc_pipe_msg
*, char __user
*, size_t);
18 ssize_t (*downcall
)(struct file
*, const char __user
*, size_t);
19 void (*release_pipe
)(struct inode
*);
20 int (*open_pipe
)(struct inode
*);
21 void (*destroy_msg
)(struct rpc_pipe_msg
*);
25 struct inode vfs_inode
;
27 struct list_head pipe
;
28 struct list_head in_upcall
;
29 struct list_head in_downcall
;
33 int nkern_readwriters
;
34 wait_queue_head_t waitq
;
35 #define RPC_PIPE_WAIT_FOR_OPEN 1
37 struct delayed_work queue_timeout
;
38 const struct rpc_pipe_ops
*ops
;
41 static inline struct rpc_inode
*
42 RPC_I(struct inode
*inode
)
44 return container_of(inode
, struct rpc_inode
, vfs_inode
);
47 extern int rpc_queue_upcall(struct inode
*, struct rpc_pipe_msg
*);
50 extern struct dentry
*rpc_create_client_dir(struct dentry
*, struct qstr
*, struct rpc_clnt
*);
51 extern int rpc_remove_client_dir(struct dentry
*);
54 extern struct dentry
*rpc_create_cache_dir(struct dentry
*,
57 struct cache_detail
*);
58 extern void rpc_remove_cache_dir(struct dentry
*);
60 extern struct dentry
*rpc_mkpipe(struct dentry
*, const char *, void *,
61 const struct rpc_pipe_ops
*, int flags
);
62 extern int rpc_unlink(struct dentry
*);
63 extern struct vfsmount
*rpc_get_mount(void);
64 extern void rpc_put_mount(void);
65 extern int register_rpc_pipefs(void);
66 extern void unregister_rpc_pipefs(void);