mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
NFS: Use super.c for NFSROOT mount option parsing
Replace duplicate code in NFSROOT for mounting an NFS server on '/' with logic that uses the existing mainline text-based logic in the NFS client. Add documenting comments where appropriate. Note that this means NFSROOT mounts now use the same default settings as v2/v3 mounts done via mount(2) from user space. vers=3,tcp,rsize=<negotiated default>,wsize=<negotiated default> As before, however, no version/protocol negotiation with the server is done. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
60ac03685b
commit
56463e50d1
3 changed files with 187 additions and 17 deletions
|
@ -364,6 +364,7 @@ extern struct nfs_lock_context *nfs_get_lock_context(struct nfs_open_context *ct
|
|||
extern void nfs_put_lock_context(struct nfs_lock_context *l_ctx);
|
||||
extern u64 nfs_compat_user_ino64(u64 fileid);
|
||||
extern void nfs_fattr_init(struct nfs_fattr *fattr);
|
||||
extern unsigned long nfs_inc_attr_generation_counter(void);
|
||||
|
||||
extern struct nfs_fattr *nfs_alloc_fattr(void);
|
||||
|
||||
|
@ -379,9 +380,12 @@ static inline void nfs_free_fhandle(const struct nfs_fh *fh)
|
|||
kfree(fh);
|
||||
}
|
||||
|
||||
/*
|
||||
* linux/fs/nfs/nfsroot.c
|
||||
*/
|
||||
extern int nfs_root_data(char **root_device, char **root_data); /*__init*/
|
||||
/* linux/net/ipv4/ipconfig.c: trims ip addr off front of name, too. */
|
||||
extern __be32 root_nfs_parse_addr(char *name); /*__init*/
|
||||
extern unsigned long nfs_inc_attr_generation_counter(void);
|
||||
|
||||
/*
|
||||
* linux/fs/nfs/file.c
|
||||
|
@ -584,10 +588,6 @@ nfs_fileid_to_ino_t(u64 fileid)
|
|||
return ino;
|
||||
}
|
||||
|
||||
/* NFS root */
|
||||
|
||||
extern void * nfs_root_data(void);
|
||||
|
||||
#define nfs_wait_event(clnt, wq, condition) \
|
||||
({ \
|
||||
int __retval = wait_event_killable(wq, condition); \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue