Deleted Added
full compact
ntfs_ihash.c (60938) ntfs_ihash.c (66615)
1/* $NetBSD: ntfs_ihash.c,v 1.5 1999/09/30 16:56:40 jdolecek Exp $ */
2
3/*
4 * Copyright (c) 1982, 1986, 1989, 1991, 1993, 1995
5 * The Regents of the University of California. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 19 unchanged lines hidden (view full) ---

28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
35 * @(#)ufs_ihash.c 8.7 (Berkeley) 5/17/95
1/* $NetBSD: ntfs_ihash.c,v 1.5 1999/09/30 16:56:40 jdolecek Exp $ */
2
3/*
4 * Copyright (c) 1982, 1986, 1989, 1991, 1993, 1995
5 * The Regents of the University of California. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 19 unchanged lines hidden (view full) ---

28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
35 * @(#)ufs_ihash.c 8.7 (Berkeley) 5/17/95
36 * $FreeBSD: head/sys/fs/ntfs/ntfs_ihash.c 60938 2000-05-26 02:09:24Z jake $
36 * $FreeBSD: head/sys/fs/ntfs/ntfs_ihash.c 66615 2000-10-04 01:29:17Z jasone $
37 */
38
39#include <sys/param.h>
40#include <sys/systm.h>
41#include <sys/kernel.h>
42#include <sys/lock.h>
43#include <sys/vnode.h>
44#include <sys/malloc.h>

--- 25 unchanged lines hidden (view full) ---

70{
71 lockinit(&ntfs_hashlock, PINOD, "ntfs_nthashlock", 0, 0);
72 ntfs_nthashtbl = HASHINIT(desiredvnodes, M_NTFSNTHASH, M_WAITOK,
73 &ntfs_nthash);
74 simple_lock_init(&ntfs_nthash_slock);
75}
76
77/*
37 */
38
39#include <sys/param.h>
40#include <sys/systm.h>
41#include <sys/kernel.h>
42#include <sys/lock.h>
43#include <sys/vnode.h>
44#include <sys/malloc.h>

--- 25 unchanged lines hidden (view full) ---

70{
71 lockinit(&ntfs_hashlock, PINOD, "ntfs_nthashlock", 0, 0);
72 ntfs_nthashtbl = HASHINIT(desiredvnodes, M_NTFSNTHASH, M_WAITOK,
73 &ntfs_nthash);
74 simple_lock_init(&ntfs_nthash_slock);
75}
76
77/*
78 * Destroy inode hash table.
79 */
80void
81ntfs_nthashdestroy(void)
82{
83 lockdestroy(&ntfs_hashlock);
84}
85
86/*
78 * Use the device/inum pair to find the incore inode, and return a pointer
79 * to it. If it is in core, return it, even if it is locked.
80 */
81struct ntnode *
82ntfs_nthashlookup(dev, inum)
83 dev_t dev;
84 ino_t inum;
85{

--- 45 unchanged lines hidden ---
87 * Use the device/inum pair to find the incore inode, and return a pointer
88 * to it. If it is in core, return it, even if it is locked.
89 */
90struct ntnode *
91ntfs_nthashlookup(dev, inum)
92 dev_t dev;
93 ino_t inum;
94{

--- 45 unchanged lines hidden ---