MAKEDEV.conf revision 1.1 1 # $NetBSD: MAKEDEV.conf,v 1.1 2003/10/15 19:13:32 jdolecek Exp $
2 #
3 # Copyright (c) 1990 The Regents of the University of California.
4 # All rights reserved.
5 #
6 # Redistribution and use in source and binary forms, with or without
7 # modification, are permitted provided that the following conditions
8 # are met:
9 # 1. Redistributions of source code must retain the above copyright
10 # notice, this list of conditions and the following disclaimer.
11 # 2. Redistributions in binary form must reproduce the above copyright
12 # notice, this list of conditions and the following disclaimer in the
13 # documentation and/or other materials provided with the distribution.
14 # 3. All advertising materials mentioning features or use of this software
15 # must display the following acknowledgement:
16 # This product includes software developed by the University of
17 # California, Berkeley and its contributors.
18 # 4. Neither the name of the University nor the names of its contributors
19 # may be used to endorse or promote products derived from this software
20 # without specific prior written permission.
21 #
22 # THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
23 # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
24 # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
25 # ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
26 # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
27 # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
28 # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 # SUCH DAMAGE.
33 #
34 # @(#)MAKEDEV 5.5 (Berkeley) 5/28/91
35
36 DISKPARTITIONS=8
37
38 MD_DEVICES=
39 all_md)
40 makedev ct0 ct1 rd0 rd1 rd
41 # makedev wscons # should be after 'std'
42 makedev sd0 sd1 sd2 cd0 cd1 st0 st1 ch0
43 makedev hil grf0 ite0 dca0 dcm0 dcm1 dcm2 dcm3 apci0
44 makedev scsibus0 scsibus1 scsibus2 scsibus3
45 makedev ss0 uk0 uk1
46 ;;
47
48 ct*)
49 case $i in
50 ct*) name=ct; unit=${i#ct}; blk=0; chr=7;;
51 esac
52 case $unit in
53 0|1|2|3|4|5|6|7)
54 four=$(($unit + 4)) ; eight=$(($unit + 8))
55 twelve=$(($unit + 12)) ; twenty=$(($unit + 20))
56 #
57 # block devices don't work so don't make them
58 #rm -f ${name}${unit} ${name}${four} ${name}${eight} \
59 # ${name}${twelve}
60 #mknod ${name}${unit} b $blk $unit
61 #mknod ${name}${four} b $blk $four
62 #mknod ${name}${eight} b $blk $eight
63 #mknod ${name}${twelve} b $blk $twelve
64 #ln -fs ${name}{$four} n${name}${unit} ;: sanity w/pdp11 v7
65 #ln -fs ${name}{$twelve} n${name}${eight} ;: ditto
66 #chgrp operator ${name}${unit} ${name}${four} ${name}${eight} \
67 # ${name}${twelve} n${name}${unit} n${name}${eight}
68 #chmod 660 ${name}${unit} ${name}${four} ${name}${eight} \
69 # ${name}${twelve} n${name}${unit} n${name}${eight}
70 #
71 rm -f r${name}${unit} r${name}${four} r${name}${eight} \
72 r${name}${twelve}
73 mknod r${name}${unit} c $chr $unit
74 mknod r${name}${four} c $chr $four
75 mknod r${name}${eight} c $chr $eight
76 mknod r${name}${twelve} c $chr $twelve
77 ln -fs r${name}${four} nr${name}${unit} ;: sanity w/pdp11 v7
78 ln -fs r${name}${twelve} nr${name}${eight} ;: ditto
79 chgrp operator r${name}${unit} r${name}${four} \
80 r${name}${eight} r${name}${twelve} nr${name}${unit} \
81 nr${name}${eight}
82 chmod 660 r${name}${unit} r${name}${four} \
83 r${name}${eight} r${name}${twelve} nr${name}${unit} \
84 nr${name}${eight}
85 ;;
86 *)
87 echo bad unit for tape in: $1
88 ;;
89 esac
90 ;;
91
92 dca*)
93 # XXX What about dca cards?
94 unit=${i#dca}
95 case $unit in
96 0)
97 rm -f tty0
98 mknod tty0 c 12 0
99 ;;
100 *)
101 echo bad unit for dca in: $i
102 ;;
103 esac
104 ;;
105
106 dcm*)
107 unit=${i#dcm}
108 case $unit in
109 0|1|2|3)
110 eval `echo $unit | awk ' { unit = $1; u = 4 * $1 } END {
111 for (i = 0; i < 4; i++)
112 printf("rm -f tty0%x; mknod tty0%x c 15 %d; ",u+i,u+i,u+i); }'`
113 ;;
114 *)
115 echo bad unit for dcm in: $i
116 ;;
117 esac
118 ;;
119
120 apci*)
121 # There exists only one Frodo ASIC per HP9000/400 SPU.
122 unit=${i#apci}
123 case $unit in
124 0)
125 for i in 0 1 2 3; do
126 rm -f ttya${i};
127 mknod ttya${i} c 31 ${i}
128 done
129 ;;
130 *)
131 echo bad unit for apci in: $i
132 ;;
133 esac
134 ;;
135
136 hil)
137 for unit in 0 1 2 3 4 5 6 7
138 do
139 rm -f hil${unit}
140 mknod hil${unit} c 14 ${unit}
141 if [ -f /usr/sbin/hilinfo ]
142 then
143 case `/usr/sbin/hilinfo -t hil${unit}` in
144 mouse)
145 if [ ! -f locator ]
146 then
147 ln -fs hil${unit} locator
148 fi
149 ;;
150 keyboard)
151 if [ ! -f keyboard ]
152 then
153 ln -fs hil${unit} keyboard
154 fi
155 ;;
156 *)
157 ;;
158 esac
159 fi
160 done
161 if [ ! -f /usr/sbin/hilinfo ]
162 then
163 ln -fs hil1 keyboard
164 ln -fs hil3 locator
165 fi
166 chmod 666 hil*
167 # echo "hil: use $0.hpux to make HP-UX names for devices"
168 ;;
169