i386/i386/conf.c is no longer needed.. remove it from files.i386

redistribute a few last routines to beter places and shoot the file

I haven't act actually 'deleted' the file yet togive people time
to
have done a config.. I.e. they are likely to have done one in a week or so
so I'll remove it then..
 it's now empty.
makes the question of a USL copyright rather moot.
This commit is contained in:
Julian Elischer 1995-12-21 20:09:46 +00:00
parent ee0ef56952
commit 1dfcbb0ce3
5 changed files with 99 additions and 145 deletions

View File

@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
# $Id: files.i386,v 1.117 1995/12/12 08:46:40 gibbs Exp $
# $Id: files.i386,v 1.118 1995/12/14 14:35:31 peter Exp $
#
aic7xxx_asm optional ahc device-driver \
dependency "$S/dev/aic7xxx/aic7xxx_asm.c" \
@ -21,7 +21,6 @@ i386/eisa/aha1742.c optional ahb device-driver
i386/eisa/bt74x.c optional bt device-driver
i386/eisa/eisaconf.c optional eisa
i386/i386/autoconf.c standard device-driver
i386/i386/conf.c standard
i386/i386/cons.c standard
i386/i386/db_disasm.c optional ddb
i386/i386/db_interface.c optional ddb

View File

@ -1,7 +1,7 @@
# This file tells config what files go into building a kernel,
# files marked standard are always included.
#
# $Id: files.i386,v 1.117 1995/12/12 08:46:40 gibbs Exp $
# $Id: files.i386,v 1.118 1995/12/14 14:35:31 peter Exp $
#
aic7xxx_asm optional ahc device-driver \
dependency "$S/dev/aic7xxx/aic7xxx_asm.c" \
@ -21,7 +21,6 @@ i386/eisa/aha1742.c optional ahb device-driver
i386/eisa/bt74x.c optional bt device-driver
i386/eisa/eisaconf.c optional eisa
i386/i386/autoconf.c standard device-driver
i386/i386/conf.c standard
i386/i386/cons.c standard
i386/i386/db_disasm.c optional ddb
i386/i386/db_interface.c optional ddb

View File

@ -1,140 +1,6 @@
/*
* Copyright (c) UNIX System Laboratories, Inc. All or some portions
* of this file are derived from material licensed to the
* University of California by American Telephone and Telegraph Co.
* or UNIX System Laboratories, Inc. and are reproduced herein with
* the permission of UNIX System Laboratories, Inc.
* SURPRISE! this file is now empty
* I'll delete it soon, as soon as most people ar e LIKELY to have
* done a new config...
*/
/*
* Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
* This code is derived from software contributed to Berkeley by
* William Jolitz.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the University of
* California, Berkeley and its contributors.
* 4. Neither the name of the University nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* from: @(#)conf.c 5.8 (Berkeley) 5/12/91
* $Id: conf.c,v 1.116 1995/12/14 22:02:41 bde Exp $
*/
#include <sys/param.h>
#include <sys/conf.h>
#include <sys/vnode.h>
#define NUMCDEV 96
#define NUMBDEV 32
struct bdevsw *bdevsw[NUMBDEV];
int nblkdev = NUMBDEV;
struct cdevsw *cdevsw[NUMCDEV];
int nchrdev = NUMCDEV;
/*
* The routines below are total "BULLSHIT" and will be trashed
*/
/*
* Swapdev is a fake device implemented
* in sw.c used only internally to get to swstrategy.
* It cannot be provided to the users, because the
* swstrategy routine munches the b_dev and b_blkno entries
* before calling the appropriate driver. This would horribly
* confuse, e.g. the hashing routines. Instead, /dev/drum is
* provided as a character (raw) device.
*/
dev_t swapdev = makedev(1, 0);
/*
* Routine to determine if a device is a disk.
*
* KLUDGE XXX add flags to cdevsw entries for disks XXX
* A minimal stub routine can always return 0.
*/
int
isdisk(dev, type)
dev_t dev;
int type;
{
switch (major(dev)) {
case 15: /* VBLK: vn, VCHR: cd */
return (1);
case 0: /* wd */
case 2: /* fd */
case 4: /* sd */
case 6: /* cd */
case 7: /* mcd */
case 16: /* scd */
case 17: /* matcd */
case 18: /* ata */
case 19: /* wcd */
case 20: /* od */
if (type == VBLK)
return (1);
return (0);
case 3: /* wd */
case 9: /* fd */
case 13: /* sd */
case 29: /* mcd */
case 43: /* vn */
case 45: /* scd */
case 46: /* matcd */
case 69: /* wcd */
case 70: /* od */
if (type == VCHR)
return (1);
/* fall through */
default:
return (0);
}
/* NOTREACHED */
}
/*
* Routine to convert from character to block device number.
*
* A minimal stub routine can always return NODEV.
*/
dev_t
chrtoblk(dev_t dev)
{
int blkmaj;
struct bdevsw *bd;
struct cdevsw *cd;
if(cd = cdevsw[major(dev)]) {
if ( (bd = cd->d_bdev) )
return(makedev(bd->d_maj,minor(dev)));
}
return(NODEV);
}

View File

@ -30,13 +30,90 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: kern_conf.c,v 1.6 1995/12/08 11:16:55 julian Exp $
* $Id: kern_conf.c,v 1.7 1995/12/13 15:12:48 julian Exp $
*/
#include <sys/param.h>
#include <sys/types.h>
#include <sys/systm.h>
#include <sys/conf.h>
#include <sys/vnode.h>
#define NUMCDEV 96
#define NUMBDEV 32
struct bdevsw *bdevsw[NUMBDEV];
int nblkdev = NUMBDEV;
struct cdevsw *cdevsw[NUMCDEV];
int nchrdev = NUMCDEV;
/*
* Routine to determine if a device is a disk.
*
* KLUDGE XXX add flags to cdevsw entries for disks XXX
* A minimal stub routine can always return 0.
*/
int
isdisk(dev, type)
dev_t dev;
int type;
{
switch (major(dev)) {
case 15: /* VBLK: vn, VCHR: cd */
return (1);
case 0: /* wd */
case 2: /* fd */
case 4: /* sd */
case 6: /* cd */
case 7: /* mcd */
case 16: /* scd */
case 17: /* matcd */
case 18: /* ata */
case 19: /* wcd */
case 20: /* od */
if (type == VBLK)
return (1);
return (0);
case 3: /* wd */
case 9: /* fd */
case 13: /* sd */
case 29: /* mcd */
case 43: /* vn */
case 45: /* scd */
case 46: /* matcd */
case 69: /* wcd */
case 70: /* od */
if (type == VCHR)
return (1);
/* fall through */
default:
return (0);
}
/* NOTREACHED */
}
/*
* Routine to convert from character to block device number.
*
* A minimal stub routine can always return NODEV.
*/
dev_t
chrtoblk(dev_t dev)
{
int blkmaj;
struct bdevsw *bd;
struct cdevsw *cd;
if(cd = cdevsw[major(dev)]) {
if ( (bd = cd->d_bdev) )
return(makedev(bd->d_maj,minor(dev)));
}
return(NODEV);
}
/*
* (re)place an entry in the bdevsw or cdevsw table

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)vm_swap.c 8.5 (Berkeley) 2/17/94
* $Id: vm_swap.c,v 1.32 1995/12/13 15:13:57 julian Exp $
* $Id: vm_swap.c,v 1.33 1995/12/14 09:55:12 phk Exp $
*/
#include <sys/param.h>
@ -56,17 +56,30 @@ static void swstrategy __P((struct buf *));
#define CDEV_MAJOR 4
#define BDEV_MAJOR 1
extern struct cdevsw sw_cdevsw ;
static struct bdevsw sw_bdevsw =
{ noopen, noclose, swstrategy, noioc, /*1*/
nodump, nopsize, NULL, "sw", NULL, -1 };
nodump, nopsize, NULL, "sw", &sw_cdevsw, -1 };
static struct cdevsw sw_cdevsw =
{ nullopen, nullclose, rawread, rawwrite, /*4*/
noioc, nostop, noreset, nodevtotty,/* swap */
noselect, nommap, swstrategy, "sw", NULL, -1 };
noselect, nommap, swstrategy, "sw",
&sw_bdevsw, -1 };
/*
* Swapdev is a fake device implemented
* in sw.c used only internally to get to swstrategy.
* It cannot be provided to the users, because the
* swstrategy routine munches the b_dev and b_blkno entries
* before calling the appropriate driver. This would horribly
* confuse, e.g. the hashing routines. Instead, /dev/drum is
* provided as a character (raw) device.
*/
dev_t swapdev = makedev(BDEV_MAJOR, 0);
/*
* Indirect driver for multi-controller paging.
*/