diff options
Diffstat (limited to 'include/linux/nfsd/nfsd.h')
-rw-r--r-- | include/linux/nfsd/nfsd.h | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/include/linux/nfsd/nfsd.h b/include/linux/nfsd/nfsd.h index d0d4aae7085f..edb54c3171b3 100644 --- a/include/linux/nfsd/nfsd.h +++ b/include/linux/nfsd/nfsd.h | |||
@@ -50,7 +50,7 @@ | |||
50 | * Callback function for readdir | 50 | * Callback function for readdir |
51 | */ | 51 | */ |
52 | struct readdir_cd { | 52 | struct readdir_cd { |
53 | int err; /* 0, nfserr, or nfserr_eof */ | 53 | __be32 err; /* 0, nfserr, or nfserr_eof */ |
54 | }; | 54 | }; |
55 | typedef int (*encode_dent_fn)(struct readdir_cd *, const char *, | 55 | typedef int (*encode_dent_fn)(struct readdir_cd *, const char *, |
56 | int, loff_t, ino_t, unsigned int); | 56 | int, loff_t, ino_t, unsigned int); |
@@ -64,7 +64,7 @@ extern struct svc_serv *nfsd_serv; | |||
64 | * Function prototypes. | 64 | * Function prototypes. |
65 | */ | 65 | */ |
66 | int nfsd_svc(unsigned short port, int nrservs); | 66 | int nfsd_svc(unsigned short port, int nrservs); |
67 | int nfsd_dispatch(struct svc_rqst *rqstp, u32 *statp); | 67 | int nfsd_dispatch(struct svc_rqst *rqstp, __be32 *statp); |
68 | 68 | ||
69 | /* nfsd/vfs.c */ | 69 | /* nfsd/vfs.c */ |
70 | int fh_lock_parent(struct svc_fh *, struct dentry *); | 70 | int fh_lock_parent(struct svc_fh *, struct dentry *); |
@@ -72,57 +72,57 @@ int nfsd_racache_init(int); | |||
72 | void nfsd_racache_shutdown(void); | 72 | void nfsd_racache_shutdown(void); |
73 | int nfsd_cross_mnt(struct svc_rqst *rqstp, struct dentry **dpp, | 73 | int nfsd_cross_mnt(struct svc_rqst *rqstp, struct dentry **dpp, |
74 | struct svc_export **expp); | 74 | struct svc_export **expp); |
75 | int nfsd_lookup(struct svc_rqst *, struct svc_fh *, | 75 | __be32 nfsd_lookup(struct svc_rqst *, struct svc_fh *, |
76 | const char *, int, struct svc_fh *); | 76 | const char *, int, struct svc_fh *); |
77 | int nfsd_setattr(struct svc_rqst *, struct svc_fh *, | 77 | __be32 nfsd_setattr(struct svc_rqst *, struct svc_fh *, |
78 | struct iattr *, int, time_t); | 78 | struct iattr *, int, time_t); |
79 | #ifdef CONFIG_NFSD_V4 | 79 | #ifdef CONFIG_NFSD_V4 |
80 | int nfsd4_set_nfs4_acl(struct svc_rqst *, struct svc_fh *, | 80 | __be32 nfsd4_set_nfs4_acl(struct svc_rqst *, struct svc_fh *, |
81 | struct nfs4_acl *); | 81 | struct nfs4_acl *); |
82 | int nfsd4_get_nfs4_acl(struct svc_rqst *, struct dentry *, struct nfs4_acl **); | 82 | int nfsd4_get_nfs4_acl(struct svc_rqst *, struct dentry *, struct nfs4_acl **); |
83 | #endif /* CONFIG_NFSD_V4 */ | 83 | #endif /* CONFIG_NFSD_V4 */ |
84 | int nfsd_create(struct svc_rqst *, struct svc_fh *, | 84 | __be32 nfsd_create(struct svc_rqst *, struct svc_fh *, |
85 | char *name, int len, struct iattr *attrs, | 85 | char *name, int len, struct iattr *attrs, |
86 | int type, dev_t rdev, struct svc_fh *res); | 86 | int type, dev_t rdev, struct svc_fh *res); |
87 | #ifdef CONFIG_NFSD_V3 | 87 | #ifdef CONFIG_NFSD_V3 |
88 | int nfsd_access(struct svc_rqst *, struct svc_fh *, u32 *, u32 *); | 88 | __be32 nfsd_access(struct svc_rqst *, struct svc_fh *, u32 *, u32 *); |
89 | int nfsd_create_v3(struct svc_rqst *, struct svc_fh *, | 89 | __be32 nfsd_create_v3(struct svc_rqst *, struct svc_fh *, |
90 | char *name, int len, struct iattr *attrs, | 90 | char *name, int len, struct iattr *attrs, |
91 | struct svc_fh *res, int createmode, | 91 | struct svc_fh *res, int createmode, |
92 | u32 *verifier, int *truncp); | 92 | u32 *verifier, int *truncp, int *created); |
93 | int nfsd_commit(struct svc_rqst *, struct svc_fh *, | 93 | __be32 nfsd_commit(struct svc_rqst *, struct svc_fh *, |
94 | loff_t, unsigned long); | 94 | loff_t, unsigned long); |
95 | #endif /* CONFIG_NFSD_V3 */ | 95 | #endif /* CONFIG_NFSD_V3 */ |
96 | int nfsd_open(struct svc_rqst *, struct svc_fh *, int, | 96 | __be32 nfsd_open(struct svc_rqst *, struct svc_fh *, int, |
97 | int, struct file **); | 97 | int, struct file **); |
98 | void nfsd_close(struct file *); | 98 | void nfsd_close(struct file *); |
99 | int nfsd_read(struct svc_rqst *, struct svc_fh *, struct file *, | 99 | __be32 nfsd_read(struct svc_rqst *, struct svc_fh *, struct file *, |
100 | loff_t, struct kvec *, int, unsigned long *); | 100 | loff_t, struct kvec *, int, unsigned long *); |
101 | int nfsd_write(struct svc_rqst *, struct svc_fh *,struct file *, | 101 | __be32 nfsd_write(struct svc_rqst *, struct svc_fh *,struct file *, |
102 | loff_t, struct kvec *,int, unsigned long, int *); | 102 | loff_t, struct kvec *,int, unsigned long, int *); |
103 | int nfsd_readlink(struct svc_rqst *, struct svc_fh *, | 103 | __be32 nfsd_readlink(struct svc_rqst *, struct svc_fh *, |
104 | char *, int *); | 104 | char *, int *); |
105 | int nfsd_symlink(struct svc_rqst *, struct svc_fh *, | 105 | __be32 nfsd_symlink(struct svc_rqst *, struct svc_fh *, |
106 | char *name, int len, char *path, int plen, | 106 | char *name, int len, char *path, int plen, |
107 | struct svc_fh *res, struct iattr *); | 107 | struct svc_fh *res, struct iattr *); |
108 | int nfsd_link(struct svc_rqst *, struct svc_fh *, | 108 | __be32 nfsd_link(struct svc_rqst *, struct svc_fh *, |
109 | char *, int, struct svc_fh *); | 109 | char *, int, struct svc_fh *); |
110 | int nfsd_rename(struct svc_rqst *, | 110 | __be32 nfsd_rename(struct svc_rqst *, |
111 | struct svc_fh *, char *, int, | 111 | struct svc_fh *, char *, int, |
112 | struct svc_fh *, char *, int); | 112 | struct svc_fh *, char *, int); |
113 | int nfsd_remove(struct svc_rqst *, | 113 | __be32 nfsd_remove(struct svc_rqst *, |
114 | struct svc_fh *, char *, int); | 114 | struct svc_fh *, char *, int); |
115 | int nfsd_unlink(struct svc_rqst *, struct svc_fh *, int type, | 115 | __be32 nfsd_unlink(struct svc_rqst *, struct svc_fh *, int type, |
116 | char *name, int len); | 116 | char *name, int len); |
117 | int nfsd_truncate(struct svc_rqst *, struct svc_fh *, | 117 | int nfsd_truncate(struct svc_rqst *, struct svc_fh *, |
118 | unsigned long size); | 118 | unsigned long size); |
119 | int nfsd_readdir(struct svc_rqst *, struct svc_fh *, | 119 | __be32 nfsd_readdir(struct svc_rqst *, struct svc_fh *, |
120 | loff_t *, struct readdir_cd *, encode_dent_fn); | 120 | loff_t *, struct readdir_cd *, encode_dent_fn); |
121 | int nfsd_statfs(struct svc_rqst *, struct svc_fh *, | 121 | __be32 nfsd_statfs(struct svc_rqst *, struct svc_fh *, |
122 | struct kstatfs *); | 122 | struct kstatfs *); |
123 | 123 | ||
124 | int nfsd_notify_change(struct inode *, struct iattr *); | 124 | int nfsd_notify_change(struct inode *, struct iattr *); |
125 | int nfsd_permission(struct svc_export *, struct dentry *, int); | 125 | __be32 nfsd_permission(struct svc_export *, struct dentry *, int); |
126 | int nfsd_sync_dir(struct dentry *dp); | 126 | int nfsd_sync_dir(struct dentry *dp); |
127 | 127 | ||
128 | #if defined(CONFIG_NFSD_V2_ACL) || defined(CONFIG_NFSD_V3_ACL) | 128 | #if defined(CONFIG_NFSD_V2_ACL) || defined(CONFIG_NFSD_V3_ACL) |
@@ -238,6 +238,7 @@ void nfsd_lockd_shutdown(void); | |||
238 | #define nfserr_badname __constant_htonl(NFSERR_BADNAME) | 238 | #define nfserr_badname __constant_htonl(NFSERR_BADNAME) |
239 | #define nfserr_cb_path_down __constant_htonl(NFSERR_CB_PATH_DOWN) | 239 | #define nfserr_cb_path_down __constant_htonl(NFSERR_CB_PATH_DOWN) |
240 | #define nfserr_locked __constant_htonl(NFSERR_LOCKED) | 240 | #define nfserr_locked __constant_htonl(NFSERR_LOCKED) |
241 | #define nfserr_replay_me __constant_htonl(NFSERR_REPLAY_ME) | ||
241 | 242 | ||
242 | /* error codes for internal use */ | 243 | /* error codes for internal use */ |
243 | /* if a request fails due to kmalloc failure, it gets dropped. | 244 | /* if a request fails due to kmalloc failure, it gets dropped. |