- Remove the unused and unsafe ufs_ihashlookup. This function returned a

vnode pointer that could not be used since no locks were held.

Sponsored by:	Isilon Systems, Inc.
This commit is contained in:
Jeff Roberson 2005-02-14 20:51:39 +00:00
parent 59284d27d7
commit a8127ebb5d
2 changed files with 0 additions and 24 deletions

View File

@ -74,8 +74,6 @@ int ufs_getlbns(struct vnode *, ufs2_daddr_t, struct indir *, int *);
int ufs_ihashget(struct cdev *, ino_t, int, struct vnode **);
void ufs_ihashinit(void);
int ufs_ihashins(struct inode *, int, struct vnode **);
struct vnode *
ufs_ihashlookup(struct cdev *, ino_t);
void ufs_ihashrem(struct inode *);
void ufs_ihashuninit(void);
int ufs_inactive(struct vop_inactive_args *);

View File

@ -77,28 +77,6 @@ ufs_ihashuninit()
mtx_destroy(&ufs_ihash_mtx);
}
/*
* Use the device/inum pair to find the incore inode, and return a pointer
* to it. If it is in core, return it, even if it is locked.
*/
struct vnode *
ufs_ihashlookup(dev, inum)
struct cdev *dev;
ino_t inum;
{
struct inode *ip;
mtx_lock(&ufs_ihash_mtx);
LIST_FOREACH(ip, INOHASH(dev, inum), i_hash)
if (inum == ip->i_number && dev == ip->i_dev)
break;
mtx_unlock(&ufs_ihash_mtx);
if (ip)
return (ITOV(ip));
return (NULLVP);
}
/*
* Use the device/inum pair to find the incore inode, and return a pointer
* to it. If it is in core, but locked, wait for it.