Add rd, sd, cd, md, st, ss, uk, ch and ipl device entries.
This commit is contained in:
parent
a3a8d0aba7
commit
3896082c5a
@ -1,5 +1,5 @@
|
||||
#!/bin/sh -
|
||||
# $NetBSD: MAKEDEV,v 1.4 1996/07/14 13:58:38 ragge Exp $
|
||||
# $NetBSD: MAKEDEV,v 1.5 1997/01/05 18:49:12 ragge Exp $
|
||||
#
|
||||
# @(#)MAKEDEV 8.1 (Berkeley) 6/9/93
|
||||
#
|
||||
@ -14,6 +14,7 @@
|
||||
# ts* unibus ts11
|
||||
# ut* unibus tu45 emulations (e.g.si 9700)
|
||||
# uu* tu58 cassettes on dl11 controller
|
||||
# st* SCSI tapes
|
||||
# Disks:
|
||||
# hp* massbus rm??
|
||||
# hk* unibus rk06 and rk07
|
||||
@ -24,6 +25,10 @@
|
||||
# rx* unibus rx211 floppy disk
|
||||
# ccd* "concatenated" pseudo-disks
|
||||
# vnd* "file" pseudo-disks
|
||||
# rd* HDC9224 rd disks on VS2000
|
||||
# sd* SCSI disks
|
||||
# cd* SCSI CD-ROM
|
||||
# md* Memory virtual disk
|
||||
# Terminal multiplexors:
|
||||
# dz* unibus dz11 and dz32
|
||||
# dh* unibus dh11 and emulations (e.g. Able dmax, Emulex cs-11)
|
||||
@ -49,6 +54,10 @@
|
||||
# lkm loadable kernel modules
|
||||
# bpf* berkeley packet filter
|
||||
# tun* network tunnel device
|
||||
# ss* SCSI scanner
|
||||
# uk* SCSI unknown
|
||||
# ch* SCSI changer
|
||||
#
|
||||
PATH=/sbin:/usr/sbin:/bin:/usr/bin
|
||||
umask 77
|
||||
for i
|
||||
@ -56,9 +65,9 @@ do
|
||||
case $i in
|
||||
|
||||
all)
|
||||
sh MAKEDEV std vnd0 ccd0 pty0 lkm
|
||||
sh MAKEDEV tms0 ts0
|
||||
sh MAKEDEV ra0 ra1 ra2 ra3 ra4 ra5 ra6 ra7 hp0 hp1
|
||||
sh $0 std vnd0 ccd0 pty0 pty1 lkm
|
||||
sh $0 mt0 mt1 ts0 ts1 st0 st1 uk0 ss0 cd0
|
||||
sh $0 ra0 ra1 ra2 ra3 hp0 hp1 hp2 hp3 sd0 sd1 sd2 sd3 rd0 rd1 rd2
|
||||
;;
|
||||
|
||||
std)
|
||||
@ -80,6 +89,7 @@ std)
|
||||
mknod stdin c 53 0 ; chmod 666 stdin
|
||||
mknod stdout c 53 1 ; chmod 666 stdout
|
||||
mknod stderr c 53 2 ; chmod 666 stderr
|
||||
mknod ipl c 42 0 ; chmod 600 ipl
|
||||
mkdir fd > /dev/null 2>&1
|
||||
(cd fd && eval `echo "" | awk ' BEGIN { \
|
||||
for (i = 0; i < 64; i++) \
|
||||
@ -89,19 +99,20 @@ std)
|
||||
chmod 666 fd/*
|
||||
;;
|
||||
|
||||
ht*|tm*|mt*|ts*|ut*)
|
||||
umask 0 ; unit=`expr $i : '[^0-9]*\(.*\)'`
|
||||
ht*|tm*|mt*|ts*|ut*|st*)
|
||||
umask 0
|
||||
case $i in
|
||||
ht*) name=ht; blk=1; chr=5 ;;
|
||||
mt*) name=mt; blk=15; chr=38;;
|
||||
tm*) name=tm; blk=5; chr=14;;
|
||||
ts*) name=ts; blk=6; chr=16;;
|
||||
ut*) name=ut; blk=10; chr=17;;
|
||||
ht*) name=ht; unit=${i#ht}; blk=1; chr=5 ;;
|
||||
mt*) name=mt; unit=${i#mt}; blk=15; chr=38;;
|
||||
tm*) name=tm; unit=${i#tm}; blk=5; chr=14;;
|
||||
ts*) name=ts; unit=${i#ts}; blk=6; chr=16;;
|
||||
ut*) name=ut; unit=${i#ut}; blk=10; chr=17;;
|
||||
st*) name=st; unit=${i#st}; blk=21; chr=60;;
|
||||
esac
|
||||
case $unit in
|
||||
0|1|2|3|4|5|6|7)
|
||||
four=`expr $unit + 4` ; eight=`expr $unit + 8`
|
||||
twelve=`expr $unit + 12`; twenty=`expr $unit + 20`
|
||||
four=$(($unit + 4)) ; eight=$(($unit + 8))
|
||||
twelve=$(($unit + 12)) ; twenty=$(($unit + 20))
|
||||
mknod $name$unit b $blk $unit
|
||||
mknod $name$four b $blk $four
|
||||
mknod $name$eight b $blk $eight
|
||||
@ -116,8 +127,8 @@ ht*|tm*|mt*|ts*|ut*)
|
||||
mknod r$name$twelve c $chr $twelve
|
||||
if [ $i = ut ]
|
||||
then
|
||||
mknod $name$twenty b $blk $twenty
|
||||
mknod r$name$twenty c $chr $twenty
|
||||
mknod $name$(($unit + 20)) b $blk $(($unit + 20))
|
||||
mknod r$name$(($unit + 20)) c $chr $(($unit + 20))
|
||||
fi
|
||||
if [ ! -e rmt$eight ] # compatibility stuff
|
||||
then
|
||||
@ -142,41 +153,39 @@ ht*|tm*|mt*|ts*|ut*)
|
||||
umask 77
|
||||
;;
|
||||
|
||||
hp*|hk*|up*|ra*|kra*|rl*|rb*|ccd*|vnd*)
|
||||
umask 2 ; unit=`expr $i : '.*[^0-9]\([0-9]*\)'`
|
||||
hp*|hk*|up*|ra*|rl*|rb*|ccd*|vnd*|rd*|sd*)
|
||||
umask 2
|
||||
case $i in
|
||||
hp*) name=hp; blk=0; chr=4;;
|
||||
hk*) name=hk; blk=3; chr=11;;
|
||||
up*) name=up; blk=2; chr=13;;
|
||||
ra*) name=ra; blk=9; chr=9;;
|
||||
kra*) name=kra; blk=16; chr=52;;
|
||||
rb*) name=rb; blk=11; chr=23;;
|
||||
rl*) name=rl; blk=14; chr=32;;
|
||||
ccd*) name=ccd; blk=17; chr=54;;
|
||||
vnd*) name=vnd; blk=18; chr=55;;
|
||||
hp*) name=hp; unit=${i#hp}; blk=0; chr=4;;
|
||||
hk*) name=hk; unit=${i#hk}; blk=3; chr=11;;
|
||||
up*) name=up; unit=${i#up}; blk=2; chr=13;;
|
||||
ra*) name=ra; unit=${i#ra}; blk=9; chr=9;;
|
||||
rb*) name=rb; unit=${i#rb}; blk=11; chr=23;;
|
||||
rl*) name=rl; unit=${i#rl}; blk=14; chr=32;;
|
||||
ccd*) name=ccd; unit=${i#ccd}; blk=17; chr=54;;
|
||||
vnd*) name=vnd; unit=${i#vnd}; blk=18; chr=55;;
|
||||
rd*) name=rd; unit=${i#rd}; blk=19; chr=58;;
|
||||
sd*) name=sd; unit=${i#sd}; blk=20; chr=59;;
|
||||
esac
|
||||
case $unit in
|
||||
0|1|2|3|4|5|6|7|8|9|10|11|12|13|14|15|16|\
|
||||
17|18|19|20|21|22|23|24|25|26|27|28|29|30|31)
|
||||
mknod ${name}${unit}a b $blk `expr $unit '*' 8 + 0`
|
||||
mknod ${name}${unit}b b $blk `expr $unit '*' 8 + 1`
|
||||
mknod ${name}${unit}c b $blk `expr $unit '*' 8 + 2`
|
||||
mknod ${name}${unit}g b $blk `expr $unit '*' 8 + 6`
|
||||
mknod r${name}${unit}a c $chr `expr $unit '*' 8 + 0`
|
||||
mknod r${name}${unit}b c $chr `expr $unit '*' 8 + 1`
|
||||
mknod r${name}${unit}c c $chr `expr $unit '*' 8 + 2`
|
||||
mknod r${name}${unit}g c $chr `expr $unit '*' 8 + 6`
|
||||
if [ $name != hk ]
|
||||
then
|
||||
mknod ${name}${unit}d b $blk `expr $unit '*' 8 + 3`
|
||||
mknod ${name}${unit}e b $blk `expr $unit '*' 8 + 4`
|
||||
mknod ${name}${unit}f b $blk `expr $unit '*' 8 + 5`
|
||||
mknod ${name}${unit}h b $blk `expr $unit '*' 8 + 7`
|
||||
mknod r${name}${unit}d c $chr `expr $unit '*' 8 + 3`
|
||||
mknod r${name}${unit}e c $chr `expr $unit '*' 8 + 4`
|
||||
mknod r${name}${unit}f c $chr `expr $unit '*' 8 + 5`
|
||||
mknod r${name}${unit}h c $chr `expr $unit '*' 8 + 7`
|
||||
fi
|
||||
mknod ${name}${unit}a b $blk $(($unit * 8 + 0))
|
||||
mknod ${name}${unit}b b $blk $(($unit * 8 + 1))
|
||||
mknod ${name}${unit}c b $blk $(($unit * 8 + 2))
|
||||
mknod ${name}${unit}d b $blk $(($unit * 8 + 3))
|
||||
mknod ${name}${unit}e b $blk $(($unit * 8 + 4))
|
||||
mknod ${name}${unit}f b $blk $(($unit * 8 + 5))
|
||||
mknod ${name}${unit}g b $blk $(($unit * 8 + 6))
|
||||
mknod ${name}${unit}h b $blk $(($unit * 8 + 7))
|
||||
mknod r${name}${unit}a c $chr $(($unit * 8 + 0))
|
||||
mknod r${name}${unit}b c $chr $(($unit * 8 + 1))
|
||||
mknod r${name}${unit}c c $chr $(($unit * 8 + 2))
|
||||
mknod r${name}${unit}d c $chr $(($unit * 8 + 3))
|
||||
mknod r${name}${unit}e c $chr $(($unit * 8 + 4))
|
||||
mknod r${name}${unit}f c $chr $(($unit * 8 + 5))
|
||||
mknod r${name}${unit}g c $chr $(($unit * 8 + 6))
|
||||
mknod r${name}${unit}h c $chr $(($unit * 8 + 7))
|
||||
chgrp operator ${name}${unit}[a-h] r${name}${unit}[a-h]
|
||||
chmod 640 ${name}${unit}[a-h] r${name}${unit}[a-h]
|
||||
;;
|
||||
@ -187,8 +196,58 @@ hp*|hk*|up*|ra*|kra*|rl*|rb*|ccd*|vnd*)
|
||||
umask 77
|
||||
;;
|
||||
|
||||
cd*)
|
||||
case $i in
|
||||
cd*) name=cd; unit=${i#cd}; chr=61; blk=22;;
|
||||
esac
|
||||
rm -f $name$unit? r$name$unit?
|
||||
mknod ${name}${unit}a b $blk $(($unit * 8 + 0))
|
||||
mknod ${name}${unit}d b $blk $(($unit * 8 + 3))
|
||||
mknod r${name}${unit}a c $chr $(($unit * 8 + 0))
|
||||
mknod r${name}${unit}d c $chr $(($unit * 8 + 3))
|
||||
chgrp operator $name$unit? r$name$unit?
|
||||
chmod 640 $name$unit? r$name$unit?
|
||||
;;
|
||||
|
||||
ss*)
|
||||
case $i in
|
||||
ss*) name=ss; unit=${i#ss}; chr=64;;
|
||||
esac
|
||||
rm -f $name$unit n$name$unit
|
||||
mknod $name$unit c $chr $(($unit * 16 + 0))
|
||||
mknod n$name$unit c $chr $(($unit * 16 + 1))
|
||||
chgrp operator $name$unit n$name$unit
|
||||
chmod 640 $name$unit n$name$unit
|
||||
;;
|
||||
|
||||
ch*|uk*)
|
||||
case $i in
|
||||
ch*) name=ch; unit=${i#ch}; chr=63;;
|
||||
uk*) name=uk; unit=${i#uk}; chr=65;;
|
||||
esac
|
||||
rm -f $name$unit
|
||||
mknod $name$unit c $chr $unit
|
||||
chgrp operator $name$unit
|
||||
chmod 640 $name$unit
|
||||
;;
|
||||
|
||||
md*)
|
||||
case $i in
|
||||
md*) name=md; unit=${i#md}; chr=62; blk=23;;
|
||||
esac
|
||||
rm -f $name$unit? r$name$unit?
|
||||
mknod ${name}${unit}a b $blk $(($unit * 8 + 0))
|
||||
mknod ${name}${unit}b b $blk $(($unit * 8 + 1))
|
||||
mknod ${name}${unit}c b $blk $(($unit * 8 + 2))
|
||||
mknod r${name}${unit}a c $chr $(($unit * 8 + 0))
|
||||
mknod r${name}${unit}b c $chr $(($unit * 8 + 1))
|
||||
mknod r${name}${unit}c c $chr $(($unit * 8 + 2))
|
||||
chgrp operator $name$unit? r$name$unit?
|
||||
chmod 640 $name$unit? r$name$unit?
|
||||
;;
|
||||
|
||||
rx*)
|
||||
unit=`expr $i : '..\(.*\)'`
|
||||
unit=${i#rx};
|
||||
name=rx; chr=30; blk=12;
|
||||
case $unit in
|
||||
0|1|2|3|4|5|6|7)
|
||||
@ -219,7 +278,7 @@ uu*)
|
||||
;;
|
||||
|
||||
dz*)
|
||||
unit=`expr $i : 'dz\(.*\)'`
|
||||
unit=${i#dz};
|
||||
case $unit in
|
||||
0|1|2|3|4|5|6|7)
|
||||
eval `echo $unit | awk ' { u = $1 } END {
|
||||
@ -291,7 +350,7 @@ lp*|va*|vp*)
|
||||
;;
|
||||
|
||||
pty*)
|
||||
class=`expr $i : 'pty\(.*\)'`
|
||||
class=${i#pty};
|
||||
case $class in
|
||||
0) offset=0 name=p;;
|
||||
1) offset=16 name=q;;
|
||||
@ -354,7 +413,7 @@ dn*|ik*|ps*|ad*|ct*)
|
||||
;;
|
||||
|
||||
bpf*)
|
||||
unit=`expr $i : '...\(.*\)'`
|
||||
unit=${i#bpf};
|
||||
rm -f bpf$unit
|
||||
mknod bpf$unit c 56 $unit
|
||||
chmod 600 bpf$unit
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: files.vax,v 1.22 1996/08/20 14:05:20 ragge Exp $
|
||||
# $NetBSD: files.vax,v 1.23 1997/01/05 18:50:27 ragge Exp $
|
||||
#
|
||||
# new style config file for vax architecture
|
||||
#
|
||||
@ -51,7 +51,7 @@ attach ht at mba
|
||||
file arch/vax/mba/ht.c ht needs-flag
|
||||
|
||||
# MSCP device drivers
|
||||
include "../mscp/files.mscp"
|
||||
include "arch/vax/mscp/files.mscp"
|
||||
major {ra = 9}
|
||||
major {mt = 16}
|
||||
|
||||
@ -115,10 +115,14 @@ major {rd = 19}
|
||||
# Machine-independent SCSI driver.
|
||||
#
|
||||
include "../../../scsi/files.scsi"
|
||||
major { st = 20 }
|
||||
major { sd = 21 }
|
||||
major { cd = 22 }
|
||||
major { ch = 23 }
|
||||
major { sd = 20 }
|
||||
major { st = 21 }
|
||||
major { cd = 22 }
|
||||
|
||||
# Memory Disk for install floppy
|
||||
pseudo-device md
|
||||
file dev/md.c md needs-flag
|
||||
major { md = 23 }
|
||||
|
||||
# builtin NCR5380 SCSI-controller on VAXstation
|
||||
device ncr: scsi, ncr5380sbc
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: conf.c,v 1.25 1996/09/07 12:40:40 mycroft Exp $ */
|
||||
/* $NetBSD: conf.c,v 1.26 1997/01/05 18:50:28 ragge Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1982, 1986 The Regents of the University of California.
|
||||
@ -109,6 +109,12 @@ bdev_decl(sd);
|
||||
#include "st.h"
|
||||
bdev_decl(st);
|
||||
|
||||
#include "cd.h"
|
||||
bdev_decl(cd);
|
||||
|
||||
#include "md.h"
|
||||
bdev_decl(md);
|
||||
|
||||
struct bdevsw bdevsw[] =
|
||||
{
|
||||
bdev_disk_init(NHP,hp), /* 0: RP0?/RM0? */
|
||||
@ -133,6 +139,8 @@ struct bdevsw bdevsw[] =
|
||||
bdev_disk_init(NHDC,hdc), /* 19: HDC9224/RD?? */
|
||||
bdev_disk_init(NSD,sd), /* 20: SCSI disk */
|
||||
bdev_tape_init(NST,st), /* 21: SCSI tape */
|
||||
bdev_disk_init(NCD,cd), /* 22: SCSI CD-ROM */
|
||||
bdev_disk_init(NMD,md), /* 23: memory disk driver */
|
||||
};
|
||||
int nblkdev = sizeof(bdevsw) / sizeof(bdevsw[0]);
|
||||
|
||||
@ -318,6 +326,9 @@ cdev_decl(qv);
|
||||
#include "qd.h"
|
||||
cdev_decl(qd);
|
||||
|
||||
#include "ipl.h"
|
||||
cdev_decl(ipl);
|
||||
|
||||
#if defined(INGRES)
|
||||
#define NII 1
|
||||
#else
|
||||
@ -332,6 +343,14 @@ cdev_decl(bpf);
|
||||
|
||||
#include "tun.h"
|
||||
cdev_decl(tun);
|
||||
cdev_decl(cd);
|
||||
#include "ch.h"
|
||||
cdev_decl(ch);
|
||||
cdev_decl(md);
|
||||
#include "ss.h"
|
||||
cdev_decl(ss);
|
||||
#include "uk.h"
|
||||
cdev_decl(uk);
|
||||
|
||||
dev_decl(filedesc,open);
|
||||
|
||||
@ -379,7 +398,7 @@ struct cdevsw cdevsw[] =
|
||||
cdev_audio_init(NNP,np), /* 39: NP Intelligent Board */
|
||||
cdev_graph_init(NQV,qv), /* 40: QVSS graphic display */
|
||||
cdev_graph_init(NQD,qd), /* 41: QDSS graphic display */
|
||||
cdev_notdef(), /* 42 */
|
||||
cdev_ipl_init(NIPL,ipl), /* 42: Packet filter */
|
||||
cdev_ingres_init(NII,ii), /* 43: Ingres device */
|
||||
cdev_notdef(), /* 44 was Datakit */
|
||||
cdev_notdef(), /* 45 was Datakit */
|
||||
@ -398,6 +417,11 @@ struct cdevsw cdevsw[] =
|
||||
cdev_disk_init(NHDC,hdc), /* 58: HDC9224/RD?? */
|
||||
cdev_disk_init(NSD,sd), /* 59: SCSI disk */
|
||||
cdev_tape_init(NST,st), /* 60: SCSI tape */
|
||||
cdev_disk_init(NCD,cd), /* 61: SCSI CD-ROM */
|
||||
cdev_disk_init(NMD,md), /* 62: memory disk driver */
|
||||
cdev_ch_init(NCH,ch), /* 63: SCSI autochanger */
|
||||
cdev_scanner_init(NSS,ss), /* 64: SCSI scanner */
|
||||
cdev_uk_init(NUK,uk), /* 65: SCSI unknown */
|
||||
};
|
||||
int nchrdev = sizeof(cdevsw) / sizeof(cdevsw[0]);
|
||||
|
||||
@ -476,6 +500,11 @@ int chrtoblktbl[] = {
|
||||
19, /* 58 */
|
||||
20, /* 59 */
|
||||
21, /* 60 */
|
||||
22, /* 61 */
|
||||
23, /* 62 */
|
||||
NODEV, /* 63 */
|
||||
NODEV, /* 64 */
|
||||
NODEV, /* 65 */
|
||||
};
|
||||
|
||||
int
|
||||
|
Loading…
Reference in New Issue
Block a user