version 1, including all changes.
.
| Rev |
Author |
# |
Line |
| 1 |
perry |
1 |
MAKEDEV |
| |
|
2 |
!!!MAKEDEV |
| |
|
3 |
NAME |
| |
|
4 |
SYNOPSIS |
| |
|
5 |
DESCRIPTION |
| |
|
6 |
OPTIONS |
| |
|
7 |
CUSTOMISATION |
| |
|
8 |
DEVICES |
| |
|
9 |
SEE ALSO |
| |
|
10 |
AUTHOR |
| |
|
11 |
---- |
| |
|
12 |
!!NAME |
| |
|
13 |
|
| |
|
14 |
|
| |
|
15 |
MAKEDEV - create devices |
| |
|
16 |
!!SYNOPSIS |
| |
|
17 |
|
| |
|
18 |
|
| |
|
19 |
__cd dev; ./MAKEDEV -V |
| |
|
20 |
cd dev; ./MAKEDEV [[ -n ] [[ -v ] update |
| |
|
21 |
cd dev; ./MAKEDEV [[ -n ] [[ -v ] [[ -d ]__ ''device |
| |
|
22 |
...'' |
| |
|
23 |
!!DESCRIPTION |
| |
|
24 |
|
| |
|
25 |
|
| |
|
26 |
__MAKEDEV__ is a script that will create the devices in |
| |
|
27 |
/dev used to interface with drivers in the |
| |
|
28 |
kernel. |
| |
|
29 |
|
| |
|
30 |
|
| |
|
31 |
This man page is woefully out of date. A large number of |
| |
|
32 |
devices are supported that are not documented |
| |
|
33 |
here. |
| |
|
34 |
|
| |
|
35 |
|
| |
|
36 |
Note that programs giving the error ``ENOENT: No such file |
| |
|
37 |
or directory'' normally means that the device file is |
| |
|
38 |
missing, whereas ``ENODEV: No such device'' normally means |
| |
|
39 |
the kernel does not have the driver configured or |
| |
|
40 |
loaded. |
| |
|
41 |
!!OPTIONS |
| |
|
42 |
|
| |
|
43 |
|
| |
|
44 |
__-V__ |
| |
|
45 |
|
| |
|
46 |
|
| |
|
47 |
Print out version (actually RCS version information) and |
| |
|
48 |
exit. |
| |
|
49 |
|
| |
|
50 |
|
| |
|
51 |
__-n__ |
| |
|
52 |
|
| |
|
53 |
|
| |
|
54 |
Do not actually update the devices, just print the actions |
| |
|
55 |
that would be performed. |
| |
|
56 |
|
| |
|
57 |
|
| |
|
58 |
__-d__ |
| |
|
59 |
|
| |
|
60 |
|
| |
|
61 |
Delete the devices. The main use for this flag is by |
| |
|
62 |
__MAKEDEV__ itself. |
| |
|
63 |
|
| |
|
64 |
|
| |
|
65 |
__-v__ |
| |
|
66 |
|
| |
|
67 |
|
| |
|
68 |
Be verbose. Print out the actions as they are performed. |
| |
|
69 |
This is the same output as produced by |
| |
|
70 |
__-n__. |
| |
|
71 |
!!CUSTOMISATION |
| |
|
72 |
|
| |
|
73 |
|
| |
|
74 |
Since there is currently no standardisation in what names |
| |
|
75 |
are used for system users and groups, it is possible that |
| |
|
76 |
you may need to modify __MAKEDEV__ to reflect your site's |
| |
|
77 |
settings. Near the top of the file is a mapping from device |
| |
|
78 |
type to user, group and permissions (e.g. all CD-ROM devices |
| |
|
79 |
are set from the $cdrom variable). If you wish to |
| |
|
80 |
change the defaults, this is the section to |
| |
|
81 |
edit. |
| |
|
82 |
!!DEVICES |
| |
|
83 |
|
| |
|
84 |
|
| |
|
85 |
__General Options__ |
| |
|
86 |
|
| |
|
87 |
|
| |
|
88 |
__update__ |
| |
|
89 |
|
| |
|
90 |
|
| |
|
91 |
This only works on kernels which have |
| |
|
92 |
/proc/interrupts (introduced during 1.1.x). This |
| |
|
93 |
file is scanned to see what devices are currently configured |
| |
|
94 |
into the kernel, and this is compared with the previous |
| |
|
95 |
settings stored in the file called DEVICES. Devices |
| |
|
96 |
which are new since then or have a different major number |
| |
|
97 |
are created, and those which are no longer configured are |
| |
|
98 |
deleted. |
| |
|
99 |
|
| |
|
100 |
|
| |
|
101 |
__generic__ |
| |
|
102 |
|
| |
|
103 |
|
| |
|
104 |
Create a generic subset of devices. This is the standard |
| |
|
105 |
devices, plus floppy drives, various hard drives, |
| |
|
106 |
pseudo-terminals, console devices, basic serial devices, |
| |
|
107 |
busmice, and printer ports. |
| |
|
108 |
|
| |
|
109 |
|
| |
|
110 |
__std__ |
| |
|
111 |
|
| |
|
112 |
|
| |
|
113 |
Standard devices. These are: __mem__ - acess to physical |
| |
|
114 |
memory; __kmem__ - access to kernel virtual memory; |
| |
|
115 |
__null__ - null device (infinite sink); __port__ - |
| |
|
116 |
access to I/O ports; __zero__ - null byte source |
| |
|
117 |
(infinite source); __core__ - symlink to /proc/kcore (for |
| |
|
118 |
kernel debugging); __full__ - always returns ENOSPACE on |
| |
|
119 |
write; __ram__ - ramdisk; __tty__ - to access the |
| |
|
120 |
controlling tty of a process. |
| |
|
121 |
|
| |
|
122 |
|
| |
|
123 |
__local__ |
| |
|
124 |
|
| |
|
125 |
|
| |
|
126 |
This simply runs __MAKEDEV.local__. This is a script that |
| |
|
127 |
can create any local devices. |
| |
|
128 |
|
| |
|
129 |
|
| |
|
130 |
__Virtual Terminals__ |
| |
|
131 |
|
| |
|
132 |
|
| |
|
133 |
''console'' |
| |
|
134 |
|
| |
|
135 |
|
| |
|
136 |
This creates the devices associated with the console. This |
| |
|
137 |
is the virtual terminals tty''x'', where ''x'' can be |
| |
|
138 |
from 0 though 63. The device tty0 is the currently active |
| |
|
139 |
vt, and is also known as console. For each vt, |
| |
|
140 |
there are two devices vcs''x'' and vcsa''x'', which |
| |
|
141 |
are used to generate screen-dumps of the vt (the |
| |
|
142 |
__vcs__''x'' is just the text, and __vcsa__''x'' |
| |
|
143 |
includes the attributes). |
| |
|
144 |
|
| |
|
145 |
|
| |
|
146 |
__Serial Devices__ |
| |
|
147 |
|
| |
|
148 |
|
| |
|
149 |
''ttyS{0..63}'' |
| |
|
150 |
|
| |
|
151 |
|
| |
|
152 |
Serial ports and corresponding dialout device. For device |
| |
|
153 |
__ttyS__''x''__,__ there is also the device |
| |
|
154 |
__cua__''x'' which is used to dial out with. This can |
| |
|
155 |
avoid the need for cooperative locks in simple |
| |
|
156 |
situations. |
| |
|
157 |
|
| |
|
158 |
|
| |
|
159 |
''cyclades'' |
| |
|
160 |
|
| |
|
161 |
|
| |
|
162 |
Dial-in and dial-out devices for the cyclades intelligent |
| |
|
163 |
I/O serial card. The dial in device is __ttyC__''x'' |
| |
|
164 |
and the corresponding dial-out device is __cub__''x'' |
| |
|
165 |
Devices for 32 lines are created. |
| |
|
166 |
|
| |
|
167 |
|
| |
|
168 |
__Pseudo Terminals__ |
| |
|
169 |
|
| |
|
170 |
|
| |
|
171 |
''pty[[p-s]'' |
| |
|
172 |
|
| |
|
173 |
|
| |
|
174 |
Each possible argument will create a bank of 16 master and |
| |
|
175 |
slave pairs. The current kernel (1.2) is limited to 64 such |
| |
|
176 |
pairs. The master pseudo-terminals are |
| |
|
177 |
__pty[[p-s][[0-9a-f]__, and the slaves are |
| |
|
178 |
__tty[[p-s][[0-9a-f]__. |
| |
|
179 |
|
| |
|
180 |
|
| |
|
181 |
__Parallel Ports__ |
| |
|
182 |
|
| |
|
183 |
|
| |
|
184 |
''lp'' |
| |
|
185 |
|
| |
|
186 |
|
| |
|
187 |
Standard parallel ports. The devices are created __lp0__, |
| |
|
188 |
__lp1__, and __lp2__. These correspond to ports at |
| |
|
189 |
0x3bc, 0x378 and 0x278. Hence, on some machines, the first |
| |
|
190 |
printer port may actually be __lp1__. |
| |
|
191 |
|
| |
|
192 |
|
| |
|
193 |
''par'' |
| |
|
194 |
|
| |
|
195 |
|
| |
|
196 |
Alternative to ''lp''. Ports are named __par__''x'' |
| |
|
197 |
instead of __lp__''x''__.__ |
| |
|
198 |
|
| |
|
199 |
|
| |
|
200 |
__Bus Mice__ |
| |
|
201 |
|
| |
|
202 |
|
| |
|
203 |
''busmice'' |
| |
|
204 |
|
| |
|
205 |
|
| |
|
206 |
The various bus mice devices. This creates the following |
| |
|
207 |
devices: __logimouse__ (Logitech bus mouse), |
| |
|
208 |
__psmouse__ (PS/2-style mouse), __msmouse__ (Microsoft |
| |
|
209 |
Inport bus mouse) and __atimouse__ (ATI XL bus mouse) and |
| |
|
210 |
__jmouse__ (J-mouse). |
| |
|
211 |
|
| |
|
212 |
|
| |
|
213 |
__Joystick Devices__ |
| |
|
214 |
|
| |
|
215 |
|
| |
|
216 |
''js'' |
| |
|
217 |
|
| |
|
218 |
|
| |
|
219 |
Joystick. Creates __js0__ and __js1__. |
| |
|
220 |
|
| |
|
221 |
|
| |
|
222 |
__Disk Devices__ |
| |
|
223 |
|
| |
|
224 |
|
| |
|
225 |
''fd[[0-7]'' |
| |
|
226 |
|
| |
|
227 |
|
| |
|
228 |
Floppy disk devices. The device __fd__''x'' is the |
| |
|
229 |
device which autodetects the format, and the additional |
| |
|
230 |
devices are fixed format (whose size is indicated in the |
| |
|
231 |
name). The other devices are named as |
| |
|
232 |
__fd__''xLn''__.__ The single letter ''L'' |
| |
|
233 |
identifies the type of floppy disk (d = 5.25 |
| |
|
234 |
''n'' represents the capacity |
| |
|
235 |
of that format in K. Thus the standard formats are |
| |
|
236 |
__fd__''x''__d360__'','' |
| |
|
237 |
__fd__''x''__h1200__'','' |
| |
|
238 |
__fd__''x''__D720__'','' |
| |
|
239 |
__fd__''x''__H1440__'','' and |
| |
|
240 |
fd''x''E2880''.'' |
| |
|
241 |
|
| |
|
242 |
|
| |
|
243 |
For more information see Alain Knaff's fdutils |
| |
|
244 |
package. |
| |
|
245 |
|
| |
|
246 |
|
| |
|
247 |
Devices __fd0__''*'' through __fd3__''*'' are |
| |
|
248 |
floppy disks on the first controller, and devices |
| |
|
249 |
__fd4__''*'' through __fd7__''*'' are floppy |
| |
|
250 |
disks on the second controller. |
| |
|
251 |
|
| |
|
252 |
|
| |
|
253 |
''hd[[a-d]'' |
| |
|
254 |
|
| |
|
255 |
|
| |
|
256 |
AT hard disks. The device __hd__''x'' provides access |
| |
|
257 |
to the whole disk, with the partitions being |
| |
|
258 |
__hd__''x''__[[0-20].__ The four primary partitions |
| |
|
259 |
are __hd__''x''__1__ through |
| |
|
260 |
__hd__''x''__4,__ with the logical partitions being |
| |
|
261 |
numbered from __hd__''x''__5__ though |
| |
|
262 |
__hd__''x''__20.__ (A primary partition can be made |
| |
|
263 |
into an extended partition, which can hold 4 logical |
| |
|
264 |
partitions). By default, only the devices for 4 logical |
| |
|
265 |
partitions are made. The others can be made by uncommenting |
| |
|
266 |
them. |
| |
|
267 |
|
| |
|
268 |
|
| |
|
269 |
Drives hda and hdb are the two on the first controller. If |
| |
|
270 |
using the new IDE driver (rather than the old HD driver), |
| |
|
271 |
then hdc and hdd are the two drives on the secondary |
| |
|
272 |
controller. These devices can also be used to acess IDE |
| |
|
273 |
CDROMs if using the new IDE driver. |
| |
|
274 |
|
| |
|
275 |
|
| |
|
276 |
''xd[[a-d]'' |
| |
|
277 |
|
| |
|
278 |
|
| |
|
279 |
XT hard disks. Partitions are the same as IDE |
| |
|
280 |
disks. |
| |
|
281 |
|
| |
|
282 |
|
| |
|
283 |
''sd[[a-h]'' |
| |
|
284 |
|
| |
|
285 |
|
| |
|
286 |
SCSI hard disks. The partitions are similar to the IDE |
| |
|
287 |
disks, but there is a limit of 11 logical partitions |
| |
|
288 |
(sd''x''5 through sd''x''15). This is to allow there |
| |
|
289 |
to be 8 SCSI disks. |
| |
|
290 |
|
| |
|
291 |
|
| |
|
292 |
''loop'' |
| |
|
293 |
|
| |
|
294 |
|
| |
|
295 |
Loopback disk devices. These allow you to use a regular file |
| |
|
296 |
as a block device. This means that images of filesystems can |
| |
|
297 |
be mounted, and used as normal. This creates 8 devices loop0 |
| |
|
298 |
through loop7. |
| |
|
299 |
|
| |
|
300 |
|
| |
|
301 |
__Tape Devices__ |
| |
|
302 |
|
| |
|
303 |
|
| |
|
304 |
''st[[0-7]'' |
| |
|
305 |
|
| |
|
306 |
|
| |
|
307 |
SCSI tapes. This creates the rewinding tape device |
| |
|
308 |
__st__''x'' and the non-rewinding tape device |
| |
|
309 |
__nst__''x''__.__ |
| |
|
310 |
|
| |
|
311 |
|
| |
|
312 |
''qic'' |
| |
|
313 |
|
| |
|
314 |
|
| |
|
315 |
QIC-80 tapes. The devices created are __rmt8__, |
| |
|
316 |
__rmt16__, __tape-d__, and |
| |
|
317 |
__tape-reset__. |
| |
|
318 |
|
| |
|
319 |
|
| |
|
320 |
''ftape'' |
| |
|
321 |
|
| |
|
322 |
|
| |
|
323 |
Floppy driver tapes (QIC-117). There are 4 methods of access |
| |
|
324 |
depending on the floppy tape drive. For each of access |
| |
|
325 |
methods 0, 1, 2 and 3, the devices __rft__''x'' |
| |
|
326 |
(rewinding) and __nrft__''x'' (non-rewinding) are |
| |
|
327 |
created. For compatability, devices __ftape__ and |
| |
|
328 |
__nftape__ are symlinks to __rft0__ and __nrft0__ |
| |
|
329 |
respectively. |
| |
|
330 |
|
| |
|
331 |
|
| |
|
332 |
__CDROM Devices__ |
| |
|
333 |
|
| |
|
334 |
|
| |
|
335 |
''scd[[0-7]'' |
| |
|
336 |
|
| |
|
337 |
|
| |
|
338 |
SCSI CD players. |
| |
|
339 |
|
| |
|
340 |
|
| |
|
341 |
''sonycd'' |
| |
|
342 |
|
| |
|
343 |
|
| |
|
344 |
Sony CDU-31A CD player. |
| |
|
345 |
|
| |
|
346 |
|
| |
|
347 |
''mcd'' |
| |
|
348 |
|
| |
|
349 |
|
| |
|
350 |
Mitsumi CD player. |
| |
|
351 |
|
| |
|
352 |
|
| |
|
353 |
''cdu535'' |
| |
|
354 |
|
| |
|
355 |
|
| |
|
356 |
Sony CDU-535 CD player. |
| |
|
357 |
|
| |
|
358 |
|
| |
|
359 |
''lmscd'' |
| |
|
360 |
|
| |
|
361 |
|
| |
|
362 |
LMS/Philips CD player. |
| |
|
363 |
|
| |
|
364 |
|
| |
|
365 |
''sbpcd{,1,2,3}'' |
| |
|
366 |
|
| |
|
367 |
|
| |
|
368 |
Sound Blaster CD player. The kernel is capable of supporting |
| |
|
369 |
16 CDROMs, each of which is accessed as |
| |
|
370 |
__sbpcd[[0-9a-f]__. These are assigned in groups of 4 to |
| |
|
371 |
each controller. __sbpcd__ is a symlink to |
| |
|
372 |
__sbpcd0__. |
| |
|
373 |
|
| |
|
374 |
|
| |
|
375 |
__Scanner__ |
| |
|
376 |
|
| |
|
377 |
|
| |
|
378 |
''logiscan'' |
| |
|
379 |
|
| |
|
380 |
|
| |
|
381 |
Logitech ScanMan32 |
| |
|
382 |
|
| |
|
383 |
|
| |
|
384 |
''m105scan'' |
| |
|
385 |
|
| |
|
386 |
|
| |
|
387 |
Mustek M105 Handscanner. |
| |
|
388 |
|
| |
|
389 |
|
| |
|
390 |
''ac4096'' |
| |
|
391 |
|
| |
|
392 |
|
| |
|
393 |
A4Tek Color Handscanner. |
| |
|
394 |
|
| |
|
395 |
|
| |
|
396 |
__Audio__ |
| |
|
397 |
|
| |
|
398 |
|
| |
|
399 |
''audio'' |
| |
|
400 |
|
| |
|
401 |
|
| |
|
402 |
This creates the audio devices used by the sound driver. |
| |
|
403 |
These include __mixer__, __sequencer__, __dsp__, |
| |
|
404 |
and __audio__. |
| |
|
405 |
|
| |
|
406 |
|
| |
|
407 |
''pcaudio'' |
| |
|
408 |
|
| |
|
409 |
|
| |
|
410 |
Devices for the PC Speaker sound driver. These are |
| |
|
411 |
__pcmixer__. __pxsp__, and |
| |
|
412 |
__pcaudio__. |
| |
|
413 |
|
| |
|
414 |
|
| |
|
415 |
__Miscellaneous__ |
| |
|
416 |
|
| |
|
417 |
|
| |
|
418 |
''sg'' |
| |
|
419 |
|
| |
|
420 |
|
| |
|
421 |
Generic SCSI devices. The devices created are __sg0 through |
| |
|
422 |
sg7__. These allow arbitary commands to be sent to any |
| |
|
423 |
SCSI device. This allows for querying information about the |
| |
|
424 |
device, or controlling SCSI devices that are not one of |
| |
|
425 |
disk, tape or CDROM (e.g. scanner, writeable |
| |
|
426 |
CDROM). |
| |
|
427 |
|
| |
|
428 |
|
| |
|
429 |
''fd'' |
| |
|
430 |
|
| |
|
431 |
|
| |
|
432 |
To allow an arbitary program to be fed input from file |
| |
|
433 |
descriptor ''x'', use __/dev/fd/__''x'' as the file |
| |
|
434 |
name. This also creates BR /dev/stdin , BR /dev/stdout , and |
| |
|
435 |
BR /dev/stderr . (Note, these are just symlinks into |
| |
|
436 |
/proc/self/fd). |
| |
|
437 |
|
| |
|
438 |
|
| |
|
439 |
''ibcs2'' |
| |
|
440 |
|
| |
|
441 |
|
| |
|
442 |
Devices (and symlinks) needed by the IBCS2 |
| |
|
443 |
emulation. |
| |
|
444 |
|
| |
|
445 |
|
| |
|
446 |
''apm'' |
| |
|
447 |
|
| |
|
448 |
|
| |
|
449 |
Devices for power management. |
| |
|
450 |
|
| |
|
451 |
|
| |
|
452 |
''dcf'' |
| |
|
453 |
|
| |
|
454 |
|
| |
|
455 |
Driver for DCF-77 radio clock. |
| |
|
456 |
|
| |
|
457 |
|
| |
|
458 |
''helloworld'' |
| |
|
459 |
|
| |
|
460 |
|
| |
|
461 |
Kernel modules demonstration device. See the modules |
| |
|
462 |
source. |
| |
|
463 |
|
| |
|
464 |
|
| |
|
465 |
__Network Devices__ |
| |
|
466 |
|
| |
|
467 |
|
| |
|
468 |
Linux used to have devices in /dev for controlling network |
| |
|
469 |
devices, but that is no longer the case. To see what network |
| |
|
470 |
devices are known by the kernel, look at |
| |
|
471 |
/proc/net/dev. |
| |
|
472 |
!!SEE ALSO |
| |
|
473 |
|
| |
|
474 |
|
| |
|
475 |
Linux Allocated Devices, maintained by H. Peter Anvin, |
| |
|
476 |
!!AUTHOR |
| |
|
477 |
|
| |
|
478 |
|
| |
|
479 |
Nick Holloway, |
| |
|
480 |
---- |