Deleted Added
full compact
kern_descrip.c (95277) kern_descrip.c (95552)
1/*
2 * Copyright (c) 1982, 1986, 1989, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

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

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_descrip.c 8.6 (Berkeley) 4/19/94
1/*
2 * Copyright (c) 1982, 1986, 1989, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 * (c) UNIX System Laboratories, Inc.
5 * All or some portions of this file are derived from material licensed
6 * to the University of California by American Telephone and Telegraph
7 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
8 * the permission of UNIX System Laboratories, Inc.

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

31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * @(#)kern_descrip.c 8.6 (Berkeley) 4/19/94
39 * $FreeBSD: head/sys/kern/kern_descrip.c 95277 2002-04-22 20:09:11Z alfred $
39 * $FreeBSD: head/sys/kern/kern_descrip.c 95552 2002-04-27 08:24:29Z tanimura $
40 */
41
42#include "opt_compat.h"
43
44#include <sys/param.h>
45#include <sys/systm.h>
46#include <sys/lock.h>
47#include <sys/malloc.h>

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

108
109/*
110 * Descriptor management.
111 */
112struct filelist filehead; /* head of list of open files */
113int nfiles; /* actual number of open files */
114extern int cmask;
115struct sx filelist_lock; /* sx to protect filelist */
40 */
41
42#include "opt_compat.h"
43
44#include <sys/param.h>
45#include <sys/systm.h>
46#include <sys/lock.h>
47#include <sys/malloc.h>

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

108
109/*
110 * Descriptor management.
111 */
112struct filelist filehead; /* head of list of open files */
113int nfiles; /* actual number of open files */
114extern int cmask;
115struct sx filelist_lock; /* sx to protect filelist */
116struct sx sigio_lock; /* sx to protect pointers to sigio */
116
117/*
118 * System calls on descriptors.
119 */
120#ifndef _SYS_SYSPROTO_H_
121struct getdtablesize_args {
122 int dummy;
123};

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

2181static void
2182filelistinit(dummy)
2183 void *dummy;
2184{
2185 file_zone = uma_zcreate("Files", sizeof(struct file), NULL, NULL,
2186 NULL, NULL, UMA_ALIGN_PTR, 0);
2187
2188 sx_init(&filelist_lock, "filelist lock");
117
118/*
119 * System calls on descriptors.
120 */
121#ifndef _SYS_SYSPROTO_H_
122struct getdtablesize_args {
123 int dummy;
124};

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

2182static void
2183filelistinit(dummy)
2184 void *dummy;
2185{
2186 file_zone = uma_zcreate("Files", sizeof(struct file), NULL, NULL,
2187 NULL, NULL, UMA_ALIGN_PTR, 0);
2188
2189 sx_init(&filelist_lock, "filelist lock");
2190 sx_init(&sigio_lock, "sigio lock");
2189}
2191}