Deleted Added
full compact
kern_descrip.c (47625) kern_descrip.c (47640)
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 * $Id: kern_descrip.c,v 1.61 1999/05/11 19:54:28 phk Exp $
39 * $Id: kern_descrip.c,v 1.62 1999/05/30 16:52:54 phk Exp $
40 */
41
42#include "opt_compat.h"
43#include "opt_devfs.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/sysproto.h>

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

1289static void *devfs_token_stdin;
1290static void *devfs_token_stdout;
1291static void *devfs_token_stderr;
1292static void *devfs_token_fildesc[NUMFDESC];
1293#endif
1294
1295static void fildesc_drvinit(void *unused)
1296{
40 */
41
42#include "opt_compat.h"
43#include "opt_devfs.h"
44
45#include <sys/param.h>
46#include <sys/systm.h>
47#include <sys/sysproto.h>

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

1289static void *devfs_token_stdin;
1290static void *devfs_token_stdout;
1291static void *devfs_token_stderr;
1292static void *devfs_token_fildesc[NUMFDESC];
1293#endif
1294
1295static void fildesc_drvinit(void *unused)
1296{
1297 dev_t dev;
1298#ifdef DEVFS
1299 int fd;
1300#endif
1301
1302 if( ! fildesc_devsw_installed ) {
1297#ifdef DEVFS
1298 int fd;
1299#endif
1300
1301 if( ! fildesc_devsw_installed ) {
1303 dev = makedev(CDEV_MAJOR,0);
1304 cdevsw_add(&dev,&fildesc_cdevsw,NULL);
1302 cdevsw_add(&fildesc_cdevsw);
1305 fildesc_devsw_installed = 1;
1306#ifdef DEVFS
1307 for (fd = 0; fd < NUMFDESC; fd++)
1308 devfs_token_fildesc[fd] =
1309 devfs_add_devswf(&fildesc_cdevsw, fd, DV_CHR,
1310 UID_BIN, GID_BIN, 0666,
1311 "fd/%d", fd);
1312 devfs_token_stdin =

--- 19 unchanged lines hidden ---
1303 fildesc_devsw_installed = 1;
1304#ifdef DEVFS
1305 for (fd = 0; fd < NUMFDESC; fd++)
1306 devfs_token_fildesc[fd] =
1307 devfs_add_devswf(&fildesc_cdevsw, fd, DV_CHR,
1308 UID_BIN, GID_BIN, 0666,
1309 "fd/%d", fd);
1310 devfs_token_stdin =

--- 19 unchanged lines hidden ---