X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Flinux%2Fnfsd%2Fnfsd.h;h=5757370b0a23cbe30b334e89aa4accf7dbc842ae;hb=9bf4aaab3e101692164d49b7ca357651eb691cb6;hp=cd9c59cf93fd50320d4ce2a131326fc47bd89318;hpb=5273a3df6485dc2ad6aa7ddd441b9a21970f003b;p=linux-2.6.git diff --git a/include/linux/nfsd/nfsd.h b/include/linux/nfsd/nfsd.h index cd9c59cf9..5757370b0 100644 --- a/include/linux/nfsd/nfsd.h +++ b/include/linux/nfsd/nfsd.h @@ -92,9 +92,9 @@ int nfsd_open(struct svc_rqst *, struct svc_fh *, int, int, struct file *); void nfsd_close(struct file *); int nfsd_read(struct svc_rqst *, struct svc_fh *, - loff_t, struct iovec *,int, unsigned long *); + loff_t, struct kvec *,int, unsigned long *); int nfsd_write(struct svc_rqst *, struct svc_fh *, - loff_t, struct iovec *,int, unsigned long, int *); + loff_t, struct kvec *,int, unsigned long, int *); int nfsd_readlink(struct svc_rqst *, struct svc_fh *, char *, int *); int nfsd_symlink(struct svc_rqst *, struct svc_fh *, @@ -126,9 +126,13 @@ int nfsd_permission(struct svc_export *, struct dentry *, int); #ifdef CONFIG_NFSD_V4 void nfs4_state_init(void); void nfs4_state_shutdown(void); +time_t nfs4_lease_time(void); +void nfs4_reset_lease(time_t leasetime); #else void static inline nfs4_state_init(void){} void static inline nfs4_state_shutdown(void){} +time_t static inline nfs4_lease_time(void){return 0;} +void static inline nfs4_reset_lease(time_t leasetime){} #endif /* @@ -199,6 +203,7 @@ void nfsd_lockd_shutdown(void); #define nfserr_grace __constant_htonl(NFSERR_GRACE) #define nfserr_no_grace __constant_htonl(NFSERR_NO_GRACE) #define nfserr_reclaim_bad __constant_htonl(NFSERR_RECLAIM_BAD) +#define nfserr_badname __constant_htonl(NFSERR_BADNAME) /* error codes for internal use */ /* if a request fails due to kmalloc failure, it gets dropped. @@ -248,7 +253,7 @@ static inline int is_fsid(struct svc_fh *fh, struct knfsd_fh *reffh) #define COMPOUND_SLACK_SPACE 140 /* OP_GETFH */ #define COMPOUND_ERR_SLACK_SPACE 12 /* OP_SETATTR */ -#define NFSD_LEASE_TIME 60 /* seconds */ +#define NFSD_LEASE_TIME (nfs4_lease_time()) #define NFSD_LAUNDROMAT_MINTIMEOUT 10 /* seconds */ /* @@ -280,7 +285,7 @@ static inline int is_fsid(struct svc_fh *fh, struct knfsd_fh *reffh) | FATTR4_WORD1_OWNER | FATTR4_WORD1_OWNER_GROUP | FATTR4_WORD1_RAWDEV \ | FATTR4_WORD1_SPACE_AVAIL | FATTR4_WORD1_SPACE_FREE | FATTR4_WORD1_SPACE_TOTAL \ | FATTR4_WORD1_SPACE_USED | FATTR4_WORD1_TIME_ACCESS | FATTR4_WORD1_TIME_ACCESS_SET \ - | FATTR4_WORD1_TIME_CREATE | FATTR4_WORD1_TIME_DELTA | FATTR4_WORD1_TIME_METADATA \ + | FATTR4_WORD1_TIME_DELTA | FATTR4_WORD1_TIME_METADATA \ | FATTR4_WORD1_TIME_MODIFY | FATTR4_WORD1_TIME_MODIFY_SET | FATTR4_WORD1_MOUNTED_ON_FILEID) /* These will return ERR_INVAL if specified in GETATTR or READDIR. */