aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/9p/client.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/9p/client.h')
-rw-r--r--include/net/9p/client.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/include/net/9p/client.h b/include/net/9p/client.h
index 7dd3ed85c782..d1aa2cfb30f0 100644
--- a/include/net/9p/client.h
+++ b/include/net/9p/client.h
@@ -195,6 +195,21 @@ struct p9_fid {
195 struct list_head dlist; /* list of all fids attached to a dentry */ 195 struct list_head dlist; /* list of all fids attached to a dentry */
196}; 196};
197 197
198/**
199 * struct p9_dirent - directory entry structure
200 * @qid: The p9 server qid for this dirent
201 * @d_off: offset to the next dirent
202 * @d_type: type of file
203 * @d_name: file name
204 */
205
206struct p9_dirent {
207 struct p9_qid qid;
208 u64 d_off;
209 unsigned char d_type;
210 char d_name[256];
211};
212
198int p9_client_statfs(struct p9_fid *fid, struct p9_rstatfs *sb); 213int p9_client_statfs(struct p9_fid *fid, struct p9_rstatfs *sb);
199int p9_client_rename(struct p9_fid *fid, struct p9_fid *newdirfid, char *name); 214int p9_client_rename(struct p9_fid *fid, struct p9_fid *newdirfid, char *name);
200int p9_client_version(struct p9_client *); 215int p9_client_version(struct p9_client *);
@@ -211,15 +226,31 @@ struct p9_fid *p9_client_walk(struct p9_fid *oldfid, int nwname, char **wnames,
211int p9_client_open(struct p9_fid *fid, int mode); 226int p9_client_open(struct p9_fid *fid, int mode);
212int p9_client_fcreate(struct p9_fid *fid, char *name, u32 perm, int mode, 227int p9_client_fcreate(struct p9_fid *fid, char *name, u32 perm, int mode,
213 char *extension); 228 char *extension);
229int p9_client_link(struct p9_fid *fid, struct p9_fid *oldfid, char *newname);
230int p9_client_symlink(struct p9_fid *fid, char *name, char *symname, gid_t gid,
231 struct p9_qid *qid);
232int p9_client_create_dotl(struct p9_fid *ofid, char *name, u32 flags, u32 mode,
233 gid_t gid, struct p9_qid *qid);
214int p9_client_clunk(struct p9_fid *fid); 234int p9_client_clunk(struct p9_fid *fid);
215int p9_client_remove(struct p9_fid *fid); 235int p9_client_remove(struct p9_fid *fid);
216int p9_client_read(struct p9_fid *fid, char *data, char __user *udata, 236int p9_client_read(struct p9_fid *fid, char *data, char __user *udata,
217 u64 offset, u32 count); 237 u64 offset, u32 count);
218int p9_client_write(struct p9_fid *fid, char *data, const char __user *udata, 238int p9_client_write(struct p9_fid *fid, char *data, const char __user *udata,
219 u64 offset, u32 count); 239 u64 offset, u32 count);
240int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset);
241int p9dirent_read(char *buf, int len, struct p9_dirent *dirent,
242 int proto_version);
220struct p9_wstat *p9_client_stat(struct p9_fid *fid); 243struct p9_wstat *p9_client_stat(struct p9_fid *fid);
221int p9_client_wstat(struct p9_fid *fid, struct p9_wstat *wst); 244int p9_client_wstat(struct p9_fid *fid, struct p9_wstat *wst);
245int p9_client_setattr(struct p9_fid *fid, struct p9_iattr_dotl *attr);
246
247struct p9_stat_dotl *p9_client_getattr_dotl(struct p9_fid *fid,
248 u64 request_mask);
222 249
250int p9_client_mknod_dotl(struct p9_fid *oldfid, char *name, int mode,
251 dev_t rdev, gid_t gid, struct p9_qid *);
252int p9_client_mkdir_dotl(struct p9_fid *fid, char *name, int mode,
253 gid_t gid, struct p9_qid *);
223struct p9_req_t *p9_tag_lookup(struct p9_client *, u16); 254struct p9_req_t *p9_tag_lookup(struct p9_client *, u16);
224void p9_client_cb(struct p9_client *c, struct p9_req_t *req); 255void p9_client_cb(struct p9_client *c, struct p9_req_t *req);
225 256
@@ -229,5 +260,7 @@ void p9stat_free(struct p9_wstat *);
229 260
230int p9_is_proto_dotu(struct p9_client *clnt); 261int p9_is_proto_dotu(struct p9_client *clnt);
231int p9_is_proto_dotl(struct p9_client *clnt); 262int p9_is_proto_dotl(struct p9_client *clnt);
263struct p9_fid *p9_client_xattrwalk(struct p9_fid *, const char *, u64 *);
264int p9_client_xattrcreate(struct p9_fid *, const char *, u64, int);
232 265
233#endif /* NET_9P_CLIENT_H */ 266#endif /* NET_9P_CLIENT_H */