1b138878dSdrahn#!/bin/sh - 2b138878dSdrahn# 3b138878dSdrahn# THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. 4b138878dSdrahn# generated from: 5b138878dSdrahn# 677cf0548Sdrahn# OpenBSD: etc.landisk/MAKEDEV.md,v 1.4 2007/01/05 20:06:24 drahn Exp 7*79cdc5d1Skrw# OpenBSD: MAKEDEV.common,v 1.33 2007/03/07 02:51:17 krw Exp 8b138878dSdrahn# OpenBSD: MAKEDEV.mi,v 1.77 2005/10/06 06:43:19 otto Exp 9b138878dSdrahn# OpenBSD: MAKEDEV.sub,v 1.14 2005/02/07 06:14:18 david Exp 10b138878dSdrahn# 11b138878dSdrahn# 12b138878dSdrahn# Copyright (c) 2001-2004 Todd T. Fries <todd@OpenBSD.org> 13b138878dSdrahn# 14b138878dSdrahn# Permission to use, copy, modify, and distribute this software for any 15b138878dSdrahn# purpose with or without fee is hereby granted, provided that the above 16b138878dSdrahn# copyright notice and this permission notice appear in all copies. 17b138878dSdrahn# 18b138878dSdrahn# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 19b138878dSdrahn# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 20b138878dSdrahn# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 21b138878dSdrahn# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 22b138878dSdrahn# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 23b138878dSdrahn# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 24b138878dSdrahn# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 25b138878dSdrahn# 26b138878dSdrahn# Device "make" file. Valid arguments: 27b138878dSdrahn# all makes all known devices, including local devices. 28b138878dSdrahn# Tries to make the ``standard'' number of each type. 29b138878dSdrahn# ramdisk Ramdisk kernel devices 30b138878dSdrahn# std Standard devices 31b138878dSdrahn# local Configuration specific devices 32b138878dSdrahn# Disks: 33b138878dSdrahn# ccd* Concatenated disk devices 34b138878dSdrahn# cd* ATAPI and SCSI CD-ROM drives 35b138878dSdrahn# ch* SCSI media changers 36b138878dSdrahn# raid* RAIDframe disk devices 37b138878dSdrahn# rd* "rd" pseudo-disks 38b138878dSdrahn# sd* SCSI disks, including flopticals 39b138878dSdrahn# vnd* "file" pseudo-disk devices 40b138878dSdrahn# wd* "winchester" disk drives (ST506, IDE, ESDI, RLL, ...) 41b138878dSdrahn# Tapes: 42b138878dSdrahn# st* SCSI tape drives 43b138878dSdrahn# Terminal ports: 440396b47eSmiod# ttya on-board serial port 45b138878dSdrahn# Pseudo terminals: 46b138878dSdrahn# ptm pty master device 47b138878dSdrahn# pty* Set of 62 master pseudo terminals 48b138878dSdrahn# tty* Set of 62 slave pseudo terminals 49b138878dSdrahn# Console ports: 50b138878dSdrahn# wscons Minimal wscons devices 51b138878dSdrahn# ttyC-J* wscons display devices 52b138878dSdrahn# wskbd* wscons keyboards 53b138878dSdrahn# wsmouse* wscons mice 54b138878dSdrahn# wsmux wscons keyboard/mouse mux devices 55b138878dSdrahn# USB devices: 56b138878dSdrahn# uall All USB devices 57b138878dSdrahn# ttyU* USB serial ports 58b138878dSdrahn# ugen* Generic USB devices 59b138878dSdrahn# uhid* Generic HID devices 60b138878dSdrahn# ulpt* Printer devices 61b138878dSdrahn# urio* Diamond Multimedia Rio 500 62b138878dSdrahn# usb* Bus control devices used by usbd for attach/detach 63b138878dSdrahn# uscanner* Scanners 64b138878dSdrahn# Special purpose devices: 65b138878dSdrahn# audio* Audio devices 66b138878dSdrahn# hotplug devices hot plugging 67b138878dSdrahn# bpf* Berkeley Packet Filter 68b138878dSdrahn# crypto Hardware crypto access driver 69b138878dSdrahn# fd fd/* nodes 70b138878dSdrahn# lkm Loadable kernel modules interface 714e7d0674Skettenis# pci* PCI bus devices 72b138878dSdrahn# pf* Packet Filter 73b138878dSdrahn# radio* FM tuner devices 74b138878dSdrahn# *random In-kernel random data source 75b138878dSdrahn# tun* Network tunnel driver 76b138878dSdrahn# uk* Unknown SCSI devices 77b138878dSdrahn# ss* SCSI scanners 78b138878dSdrahn# systrace* System call tracing device 79b138878dSdrahn# xfs* XFS filesystem node 80b138878dSdrahnPATH=/sbin:/usr/sbin:/bin:/usr/bin 81b138878dSdrahnT=$0 82b138878dSdrahn 83b138878dSdrahn# set this to echo for Echo-Only debugging 84b138878dSdrahn[ "$eo" ] || eo= 85b138878dSdrahn 86b138878dSdrahnhex() 87b138878dSdrahn{ 88b138878dSdrahn case $1 in 89b138878dSdrahn [0-9]) echo -n $1;; 90b138878dSdrahn 10) echo -n a;; 91b138878dSdrahn 11) echo -n b;; 92b138878dSdrahn 12) echo -n c;; 93b138878dSdrahn 13) echo -n d;; 94b138878dSdrahn 14) echo -n e;; 95b138878dSdrahn 15) echo -n f;; 96b138878dSdrahn esac 97b138878dSdrahn} 98b138878dSdrahn 99b138878dSdrahnalph2d() 100b138878dSdrahn{ 101b138878dSdrahn local t="$1" 102b138878dSdrahn local p="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" 103b138878dSdrahn local sub=${p%${t}*} 104b138878dSdrahn echo ${#sub} 105b138878dSdrahn} 106b138878dSdrahn 107b138878dSdrahnh2d() 108b138878dSdrahn{ 109b138878dSdrahn local s="$1" 110b138878dSdrahn local f=${s%*[0-9a-f]} n=${s#[0-9a-f]*} 111b138878dSdrahn 112b138878dSdrahn echo $(($(_h2d $f)*16+ $(_h2d $n) )) 113b138878dSdrahn} 114b138878dSdrahn 115b138878dSdrahn_h2d() 116b138878dSdrahn{ 117b138878dSdrahn case $1 in 118b138878dSdrahn [0-9]) echo -n $1;; 119b138878dSdrahn a) echo -n 10;; 120b138878dSdrahn b) echo -n 11;; 121b138878dSdrahn c) echo -n 12;; 122b138878dSdrahn d) echo -n 13;; 123b138878dSdrahn e) echo -n 14;; 124b138878dSdrahn f) echo -n 15;; 125b138878dSdrahn esac 126b138878dSdrahn} 127b138878dSdrahn 128b138878dSdrahnunt() 129b138878dSdrahn{ 130b138878dSdrahn # XXX pdksh can't seem to deal with locally scoped variables 131b138878dSdrahn # in ${foo#$bar} expansions 132b138878dSdrahn arg="$1" 133b138878dSdrahn tmp="${arg#[a-zA-Z]*}" 134b138878dSdrahn tmp="${tmp%*[a-zA-Z]}" 135b138878dSdrahn while [ "$tmp" != "$arg" ] 136b138878dSdrahn do 137b138878dSdrahn arg=$tmp 138b138878dSdrahn tmp="${arg#[a-zA-Z]*}" 139b138878dSdrahn tmp="${tmp%*[a-zA-Z]}" 140b138878dSdrahn done 141b138878dSdrahn echo $arg 142b138878dSdrahn} 143b138878dSdrahn 144b138878dSdrahndodisk() 145b138878dSdrahn{ 146b138878dSdrahn [ "$DEBUG" ] && set -x 147b138878dSdrahn n=$(($((${5}*${7:-16}))+${6})) count=0 148b138878dSdrahn [ 0$7 -ne 8 ] && l="i j k l m n o p" 149b138878dSdrahn for d in a b c d e f g h $l 150b138878dSdrahn do 151b138878dSdrahn M $1$2$d b $3 $(($n+$count)) 640 operator 152b138878dSdrahn M r$1$2$d c $4 $(($n+$count)) 640 operator 153b138878dSdrahn let count=count+1 154b138878dSdrahn done 155b138878dSdrahn} 156b138878dSdrahn 157b138878dSdrahndodisk2() 158b138878dSdrahn{ 159b138878dSdrahn n=$(($(($5*${7:-16}))+$6)) 160b138878dSdrahn M $1$2a b $3 $n 640 operator 161b138878dSdrahn M r$1$2a c $4 $n 640 operator 162b138878dSdrahn n=$(($n+2)) 163b138878dSdrahn M $1$2c b $3 $n 640 operator 164b138878dSdrahn M r$1$2c c $4 $n 640 operator 165b138878dSdrahn} 166b138878dSdrahn 167b138878dSdrahn# M name b/c major minor [mode] [group] 168b138878dSdrahnRMlist[0]="rm -f" 169b138878dSdrahn 170b138878dSdrahnmkl() { 171b138878dSdrahn mklist[${#mklist[*]}]=";mknod -m $1 $2 $3 $4 $5" 172b138878dSdrahn} 173b138878dSdrahn 174b138878dSdrahnM() { 175b138878dSdrahn RMlist[${#RMlist[*]}]=$1 176b138878dSdrahn mkl ${5-666} $1 $2 $3 $4 177b138878dSdrahn G=${6:-wheel} 178b138878dSdrahn [ "$7" ] && { 179b138878dSdrahn MKlist[${#MKlist[*]}]=";chown $7:$G $1" 180b138878dSdrahn } || { 181b138878dSdrahn case $G in 182b138878dSdrahn wheel) 183b138878dSdrahn [ ${#whlist[*]} = 0 ] && whlist[0]=";chgrp wheel" 184b138878dSdrahn whlist[${#whlist[*]}]="$1" 185b138878dSdrahn ;; 186b138878dSdrahn operator) 187b138878dSdrahn [ ${#oplist[*]} = 0 ] && oplist[0]=";chgrp operator" 188b138878dSdrahn oplist[${#oplist[*]}]="$1" 189b138878dSdrahn ;; 190b138878dSdrahn *) 191b138878dSdrahn MKlist[${#MKlist[*]}]=";chgrp $G $1"; 192b138878dSdrahn esac 193b138878dSdrahn } 194b138878dSdrahn return 0 195b138878dSdrahn} 196b138878dSdrahn 197b138878dSdrahnR() { 198b138878dSdrahn[ "$DEBUG" ] && set -x 199b138878dSdrahnfor i in "$@" 200b138878dSdrahndo 201b138878dSdrahnU=`unt $i` 202b138878dSdrahn[ "$U" ] || U=0 203b138878dSdrahn 204b138878dSdrahncase $i in 205b138878dSdrahnramdisk) 206b138878dSdrahn R std bpf0 wd0 wd1 sd0 tty00 rd0 wsmouse 207b138878dSdrahn R st0 ttyC0 random wskbd0 apm 208b138878dSdrahn ;; 209b138878dSdrahn 210b138878dSdrahnstd) 211b138878dSdrahn M console c 0 0 600 212b138878dSdrahn M tty c 1 0 213b138878dSdrahn M mem c 2 0 640 kmem 214b138878dSdrahn M kmem c 2 1 640 kmem 215b138878dSdrahn M null c 2 2 216b138878dSdrahn M zero c 2 12 217b138878dSdrahn M stdin c 7 0 218b138878dSdrahn M stdout c 7 1 219b138878dSdrahn M stderr c 7 2 220b138878dSdrahn M ksyms c 8 0 640 kmem 221b138878dSdrahn M drum c 3 0 640 kmem 222b138878dSdrahn M klog c 6 0 600 223b138878dSdrahn ;; 224b138878dSdrahn 225b138878dSdrahnxfs*) 226b138878dSdrahn M xfs$U c 51 $U 600 227b138878dSdrahn ;; 228b138878dSdrahn 229b138878dSdrahnsystrace) 230b138878dSdrahn M systrace c 50 0 644 231b138878dSdrahn ;; 232b138878dSdrahn 233b138878dSdrahnss*) 234b138878dSdrahn M ss$U c 29 $(($U*16)) 640 operator 235b138878dSdrahn M nss$U c 29 $(($(($U*16))+1)) 640 operator 236b138878dSdrahn M enss$U c 29 $(($(($U*16))+3)) 640 operator 237b138878dSdrahn RMlist[${#RMlist[*]}]="scan$U" 238b138878dSdrahn MKlist[${#MKlist[*]}]=";umask 77;ln -s ss$U scan$U" 239b138878dSdrahn ;; 240b138878dSdrahn 241b138878dSdrahnuk*) 242b138878dSdrahn M uk$U c 28 $U 640 operator 243b138878dSdrahn ;; 244b138878dSdrahn 245b138878dSdrahntun*) 246b138878dSdrahn M tun$U c 33 $U 600 247b138878dSdrahn ;; 248b138878dSdrahn 249b138878dSdrahn*random) 250b138878dSdrahn n=0 251b138878dSdrahn for pre in " " s u p a 252b138878dSdrahn do 253b138878dSdrahn M ${pre}random c 40 $n 644 254b138878dSdrahn n=$(($n+1)) 255b138878dSdrahn done 256b138878dSdrahn ;; 257b138878dSdrahn 258b138878dSdrahnradio*) 259b138878dSdrahn M radio$U c 97 $U 260b138878dSdrahn MKlist[${#MKlist[*]}]=";[ -e radio ] || ln -s radio$U radio" 261b138878dSdrahn ;; 262b138878dSdrahn 263b138878dSdrahnpf*) 264b138878dSdrahn M pf c 46 0 600 265b138878dSdrahn ;; 266b138878dSdrahn 2674e7d0674Skettenispci*) 2684e7d0674Skettenis M pci$U c 88 $U 600 269*79cdc5d1Skrw MKlist[${#MKlist[*]}]=";[ -h pci ] || ln -sf pci0 pci" 270b138878dSdrahn ;; 271b138878dSdrahn 272b138878dSdrahnlkm) 273b138878dSdrahn M lkm c 35 0 640 _lkm 274b138878dSdrahn ;; 275b138878dSdrahn 276b138878dSdrahnfd) 277b138878dSdrahn RMlist[${#RMlist[*]}]=";mkdir -p fd;rm -f" n=0 278b138878dSdrahn while [ $n -lt 64 ];do M fd/$n c 7 $n;n=$(($n+1));done 279b138878dSdrahn MKlist[${#MKlist[*]}]=";chmod 555 fd" 280b138878dSdrahn ;; 281b138878dSdrahn 282b138878dSdrahncrypto) 283b138878dSdrahn M crypto c 47 0 284b138878dSdrahn ;; 285b138878dSdrahn 286b138878dSdrahnbpf*) 287b138878dSdrahn M bpf$U c 22 $U 600 288b138878dSdrahn ;; 289b138878dSdrahn 290b138878dSdrahnhotplug) 291b138878dSdrahn M hotplug c 37 $U 400 292b138878dSdrahn ;; 293b138878dSdrahn 294b138878dSdrahnaudio*) 295b138878dSdrahn M sound$U c 36 $U 296b138878dSdrahn M mixer$U c 36 $(($U+16)) 297b138878dSdrahn M audio$U c 36 $(($U+128)) 298b138878dSdrahn M audioctl$U c 36 $(($U+192)) 299b138878dSdrahn MKlist[${#MKlist[*]}]=";[ -e audio ] || ln -s audio$U audio" 300b138878dSdrahn MKlist[${#MKlist[*]}]=";[ -e mixer ] || ln -s mixer$U mixer" 301b138878dSdrahn MKlist[${#MKlist[*]}]=";[ -e sound ] || ln -s sound$U sound" 302b138878dSdrahn MKlist[${#MKlist[*]}]=";[ -e audioctl ] || ln -s audioctl$U audioctl" 303b138878dSdrahn ;; 304b138878dSdrahn 305b138878dSdrahnuscanner*) 306b138878dSdrahn M uscanner$U c 69 $U 660 307b138878dSdrahn ;; 308b138878dSdrahn 309b138878dSdrahnusb*) 310b138878dSdrahn [ "$i" = "usb" ] && u= || u=$U 311b138878dSdrahn M usb$u c 64 $U 660 312b138878dSdrahn ;; 313b138878dSdrahn 314b138878dSdrahnurio*) 315b138878dSdrahn M urio$U c 67 $U 660 316b138878dSdrahn ;; 317b138878dSdrahn 318b138878dSdrahnulpt*) 319b138878dSdrahn M ulpt$U c 66 $U 660 320b138878dSdrahn ;; 321b138878dSdrahn 322b138878dSdrahnuhid*) 323b138878dSdrahn M uhid$U c 65 $U 660 324b138878dSdrahn ;; 325b138878dSdrahn 326b138878dSdrahnugen*) 327b138878dSdrahn n=$(($U*16)) 328b138878dSdrahn for j in 0{0,1,2,3,4,5,6,7,8,9} 1{0,1,2,3,4,5} 329b138878dSdrahn do 330b138878dSdrahn M ugen$U.$j c 70 $(($n+10#$j)) 660 331b138878dSdrahn done 332b138878dSdrahn ;; 333b138878dSdrahn 334b138878dSdrahnttyU[0-9a-zA-Z]) 335b138878dSdrahn U=${i#ttyU*} 336b138878dSdrahn o=$(alph2d $U) 337b138878dSdrahn M ttyU$U c 68 $o 660 dialer uucp 338b138878dSdrahn M cuaU$U c 68 $(($o+128)) 660 dialer uucp 339b138878dSdrahn ;; 340b138878dSdrahn 341b138878dSdrahnuall) 342b138878dSdrahn R ttyU0 ttyU1 ttyU2 ttyU3 ugen0 ugen1 ulpt0 ulpt1 uhid0 uhid1 343b138878dSdrahn R uhid2 uhid3 uscanner0 urio0 usb0 usb1 usb2 usb3 usb4 usb5 344b138878dSdrahn ;; 345b138878dSdrahn 346b138878dSdrahnwsmux|wsmouse|wskbd) 347b138878dSdrahn M wsmouse c 63 0 600 348b138878dSdrahn M wskbd c 63 1 600 349b138878dSdrahn ;; 350b138878dSdrahn 351b138878dSdrahnwsmouse*) 352b138878dSdrahn M wsmouse$U c 62 $U 600 353b138878dSdrahn ;; 354b138878dSdrahn 355b138878dSdrahnwskbd*) 356b138878dSdrahn M wskbd$U c 61 $U 600 357b138878dSdrahn ;; 358b138878dSdrahn 359b138878dSdrahntty[C-J]*) 360b138878dSdrahn U=${i##tty[C-J]} 361b138878dSdrahn case $i in 362b138878dSdrahn ttyC*) n=C m=0;; 363b138878dSdrahn ttyD*) n=D m=256;; 364b138878dSdrahn ttyE*) n=E m=512;; 365b138878dSdrahn ttyF*) n=F m=768;; 366b138878dSdrahn ttyG*) n=G m=1024;; 367b138878dSdrahn ttyH*) n=H m=1280;; 368b138878dSdrahn ttyI*) n=I m=1536;; 369b138878dSdrahn ttyJ*) n=J m=1792;; 370b138878dSdrahn esac 371b138878dSdrahn case $U in 372b138878dSdrahn [0-9a-f]) M tty$n$U c 60 $((16#$U+$m)) 600;; 373b138878dSdrahn cfg) M tty${n}cfg c 60 $((255+$m)) 600;; 374b138878dSdrahn *) echo bad unit $U for $i; exit 1;; 375b138878dSdrahn esac 376b138878dSdrahn ;; 377b138878dSdrahn 378b138878dSdrahnwscons) 379b138878dSdrahn R wsmouse0 wsmouse1 wsmouse2 wsmouse3 wskbd0 wskbd1 wskbd2 380b138878dSdrahn R wskbd3 wsmux ttyCcfg ttyC0 ttyC1 ttyC2 ttyC3 ttyC4 ttyC5 381b138878dSdrahn R ttyC6 ttyC7 ttyC8 ttyC9 ttyCa ttyCb 382b138878dSdrahn ;; 383b138878dSdrahn 384b138878dSdrahnpty*) 385b138878dSdrahn if [ $U -gt 15 ]; then 386b138878dSdrahn echo bad unit for pty in: $i 387b138878dSdrahn continue 388b138878dSdrahn fi 389b138878dSdrahn set -A letters p q r s t u v w x y z P Q R S T 390b138878dSdrahn set -A suffixes 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o p q \ 391b138878dSdrahn r s t u v w x y z A B C D E F G H I J K L M N O P Q R S T U V W X \ 392b138878dSdrahn Y Z 393b138878dSdrahn 394b138878dSdrahn name=${letters[$U]} 395b138878dSdrahn n=0 396b138878dSdrahn while [ $n -lt 62 ] 397b138878dSdrahn do 398b138878dSdrahn nam=$name${suffixes[$n]} 399b138878dSdrahn off=$(($U*62)) 400b138878dSdrahn M tty$nam c 4 $(($off+$n)) 401b138878dSdrahn M pty$nam c 5 $(($off+$n)) 402b138878dSdrahn n=$(($n+1)) 403b138878dSdrahn done 404b138878dSdrahn ;; 405b138878dSdrahn 406b138878dSdrahnptm) 407b138878dSdrahn M ptm c 98 0 666 408b138878dSdrahn ;; 409b138878dSdrahn 4100396b47eSmiodttya) 41122170e79Stodd M ttya c 11 0 660 dialer uucp 412b138878dSdrahn ;; 413b138878dSdrahn 414b138878dSdrahnst*) 415b138878dSdrahn n=$(($U*16)) 416b138878dSdrahn for pre in " " n e en 417b138878dSdrahn do 418b138878dSdrahn M ${pre}st$U b 25 $n 660 operator 419b138878dSdrahn M ${pre}rst$U c 25 $n 660 operator 420b138878dSdrahn n=$(($n+1)) 421b138878dSdrahn done 422b138878dSdrahn ;; 423b138878dSdrahn 424b138878dSdrahnvnd*) 425b138878dSdrahn dodisk vnd $U 19 19 $U 0 426b138878dSdrahn dodisk svnd $U 19 19 $U 2048 427b138878dSdrahn ;; 428b138878dSdrahn 429b138878dSdrahnrd*) 430b138878dSdrahn dodisk2 rd $U 18 18 $U 0 431b138878dSdrahn ;; 432b138878dSdrahn 433b138878dSdrahnch*) 434b138878dSdrahn M ch$U c 27 $U 660 operator 435b138878dSdrahn ;; 436b138878dSdrahn 437b138878dSdrahncd*) 438b138878dSdrahn dodisk2 cd $U 26 26 $U 0 439b138878dSdrahn ;; 440b138878dSdrahn 441b138878dSdrahnlocal) 442b138878dSdrahn test -s $T.local && sh $T.local 443b138878dSdrahn ;; 444b138878dSdrahn 445b138878dSdrahnall) 446b138878dSdrahn R ccd0 ccd1 ccd2 ccd3 vnd0 vnd1 vnd2 vnd3 sd0 sd1 sd2 sd3 sd4 447b138878dSdrahn R cd0 cd1 rd0 tun0 tun1 tun2 tun3 bpf0 bpf1 bpf2 bpf3 bpf4 4480396b47eSmiod R bpf5 bpf6 bpf7 bpf8 bpf9 pty0 xfs0 ss0 ss1 ch0 ttya hotplug 44977cf0548Sdrahn R ptm local wscons pci0 pci1 pci2 pci3 uall radio0 audio0 uk0 45077cf0548Sdrahn R random lkm crypto pf systrace wd0 wd1 wd2 wd3 raid0 raid1 45177cf0548Sdrahn R raid2 raid3 std st0 st1 fd 452b138878dSdrahn ;; 453b138878dSdrahn 454b138878dSdrahnwd*|sd*|raid*|ccd*) 455b138878dSdrahn case $i in 456b138878dSdrahn wd*) dodisk wd $U 16 16 $U 0;; 457b138878dSdrahn sd*) dodisk sd $U 24 24 $U 0;; 458b138878dSdrahn raid*) dodisk raid $U 71 71 $U 0;; 459b138878dSdrahn ccd*) dodisk ccd $U 21 21 $U 0;; 460b138878dSdrahn esac 461b138878dSdrahn ;; 462b138878dSdrahn 463b138878dSdrahn*) 464b138878dSdrahn echo $i: unknown device 465b138878dSdrahn ;; 466b138878dSdrahnesac 467b138878dSdrahndone 468b138878dSdrahn} 469b138878dSdrahnR "$@" 470b138878dSdrahn{ 471b138878dSdrahnecho -n ${RMlist[*]} 472b138878dSdrahnecho -n ${mklist[*]} 473b138878dSdrahnecho -n ${MKlist[*]} 474b138878dSdrahnecho -n ${whlist[*]} 475b138878dSdrahnecho ${oplist[*]} 476b138878dSdrahn} | if [ "$eo" = "echo" ]; then 477b138878dSdrahn cat 478b138878dSdrahnelse 479b138878dSdrahn sh 480b138878dSdrahnfi 481