o Pass td into nfs_mountroot() to eliminate an XXX'd curthread use.

Since it's in the parent function anyway, might as well pass it
  another layer down.

Obtained from:	TrustedBSD Project
This commit is contained in:
Robert Watson 2001-12-31 21:00:00 +00:00
parent 1b17a3c9ca
commit 147839396c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=88746
2 changed files with 3 additions and 4 deletions

View File

@ -252,7 +252,7 @@ extern int nfs_debug;
int nfs_init(struct vfsconf *vfsp);
int nfs_uninit(struct vfsconf *vfsp);
int nfs_mountroot(struct mount *mp);
int nfs_mountroot(struct mount *mp, struct thread *td);
int nfs_send(struct socket *, struct sockaddr *, struct mbuf *,
struct nfsreq *);
int nfs_sndlock(struct nfsreq *);

View File

@ -375,14 +375,13 @@ nfs_fsinfo(struct nfsmount *nmp, struct vnode *vp, struct ucred *cred,
* - build the rootfs mount point and call mountnfs() to do the rest.
*/
int
nfs_mountroot(struct mount *mp)
nfs_mountroot(struct mount *mp, struct thread *td)
{
struct mount *swap_mp;
struct nfsmount *nmp = VFSTONFS(mp);
struct nfsv3_diskless *nd = &nfsv3_diskless;
struct socket *so;
struct vnode *vp;
struct thread *td = curthread; /* XXX */
int error, i;
u_long l;
char buf[128];
@ -737,7 +736,7 @@ nfs_mount(struct mount *mp, char *path, caddr_t data, struct nameidata *ndp,
u_char nfh[NFSX_V3FHMAX];
if (path == NULL) {
nfs_mountroot(mp);
nfs_mountroot(mp, td);
return (0);
}
error = copyin(data, (caddr_t)&args, sizeof (struct nfs_args));