Introduce a couple of variables to make this clearer.

This commit is contained in:
mycroft 1998-03-22 02:26:48 +00:00
parent 72c495dc7c
commit 573bdc9331
2 changed files with 15 additions and 6 deletions

View File

@ -1,6 +1,6 @@
#!/bin/sh -
#
# $NetBSD: MAKEDEV,v 1.62 1998/03/22 01:15:00 mycroft Exp $
# $NetBSD: MAKEDEV,v 1.63 1998/03/22 02:26:48 mycroft Exp $
#
# Copyright (c) 1990 The Regents of the University of California.
# All rights reserved.
@ -83,10 +83,15 @@
# ch* SCSI changer
#
dialin=0
dialout=524288 # high bit of the minor number
PATH=/sbin:/usr/sbin:/bin:/usr/bin
umask 77
for i
do
case $i in
all)
@ -225,8 +230,8 @@ ccd*|fd*|sd*|vnd*|wd*)
com*|tty*) # (XXX -- com should die)
unit=${i#???}
rm -f com$unit tty0$unit dty0$unit
mknod tty0$unit c 8 $(($unit + 0))
mknod dty0$unit c 8 $(($unit + 524288))
mknod tty0$unit c 8 $(($unit + $dialin ))
mknod dty0$unit c 8 $(($unit + $dialout))
chown uucp.wheel tty0$unit dty0$unit
;;

View File

@ -1,6 +1,6 @@
#!/bin/sh -
#
# $NetBSD: MAKEDEV,v 1.34 1998/03/22 01:22:10 mycroft Exp $
# $NetBSD: MAKEDEV,v 1.35 1998/03/22 02:26:49 mycroft Exp $
#
# Copyright (c) 1990 The Regents of the University of California.
# All rights reserved.
@ -70,6 +70,9 @@
# ipl ip filter
# random Random number generator
dialin=0
dialout=524288 # high bit of the minor number
PATH=/sbin:/bin/:/usr/bin:/usr/sbin:/usr/etc
umask 77
@ -119,8 +122,8 @@ tty[abcd])
d) index=5;;
esac
rm -f tty$unit dty$unit
mknod tty$unit c 12 $(($index + 0))
mknod dty$unit c 12 $(($index + 524288))
mknod tty$unit c 12 $(($index + $dialin ))
mknod dty$unit c 12 $(($index + $dialout))
chown uucp.wheel tty$unit dty$unit
;;
@ -380,6 +383,7 @@ local)
sh $0.local all
umask 77
;;
*)
echo $i: unknown device
;;