[KLUG Members] usb modems and hylafax

Peter Buxton members@kalamazoolinux.org
Wed, 28 Jan 2004 00:41:42 -0500


I see in the other mails that you're talking to the ISDN modem.

On Tue, Jan 27, 2004 at 10:56:04AM +0100, Bert was only escaped
   alone to tell thee:

> I did: ln -s /dev/ttyACM0 /dev/modem
> minicom
> minicom: cannot open /dev/modem : No such device
> 
> also tried linking without the -s, but no difference.

The '-s' option is the difference between a hard link and a symbolic
link.  Just go ahead and use '-s', because that's what everything else
uses.

ObRant: When Alan Cox was busy on that kernel for ludicrously under-
powered machines (FOLKS, right?), he was surprised to note that the code
to implement symlinks roughly doubled the size of the generic FS code. A
sure sign that symlinks are a Bad Thing (but not the only one).

> I also added with mknod some devices with minor numbers as the address
> the device is mounted on. No success either. I suppose that that is
> how it works, the address is the minor device number? right?

No. Major number 180 is for USB devices, but the minor number defines
different subtypes of devices.

Device numbers are arbitrary values that define a 'namespace' for
devices. It's a three-part system:

 Device type: block or character
Major number: Major divisions of devices (SCSI, IDE, ttys)
Minor number: individual devices or sections, sometimes different devices

Note that:

mknod /dev/THING c 2 0
mknod /dev/THONG b 2 0

creates two different devices: one is a BSD-style psuedo-tty, the other
is a floppy disk.

brw-rw----    1 root     floppy     2,   0 Mar 14  2002 /dev/fd0
brw-rw----    1 root     floppy     2,   4 Mar 14  2002 /dev/fd0d360
brw-rw----    1 root     floppy     2,   8 Mar 14  2002 /dev/fd0h1200
brw-rw----    1 root     floppy     2,  12 Mar 14  2002 /dev/fd0u360
brw-rw----    1 root     floppy     2,  16 Mar 14  2002 /dev/fd0u720
....

Note how the minor number is used to distinguish between size and
density.


brw-rw----    1 root     cdrom      3,   0 Mar 14  2002 /dev/hda

Major number 3 is the first IDE adapter.

brw-rw----    1 root     disk      33,   0 Mar 14  2002 /dev/hde
brw-rw----    1 root     disk      33,   1 Mar 14  2002 /dev/hde1
brw-rw----    1 root     disk      33,   2 Mar 14  2002 /dev/hde2
brw-rw----    1 root     disk      33,   3 Mar 14  2002 /dev/hde3
brw-rw----    1 root     disk      33,   4 Mar 14  2002 /dev/hde4

33 is the third IDE adapter, 0 is the disk and 1-4 are the partitions.


Someday soon, all these arbitrary numbers will go away. Device numbers
will be like file descriptors: arbitrary handles generated on the fly.
Device names will be left as the prime device identifiers, and udev(8)
or something like it will create them on the fly, at boot and as devices
are added (i.e., digital cameras).

Linux Assigned Names And Numbers Authority: www.lanana.org .

2.4 kernels have devfs, which is like udev but kernel resident. It also
uses a daemon to update /dev. If you have the option of running it, I
recommend it highly. You would be past all these "Which device"
questions and onto device configuration by now.

-- 
Black Ops. Silent, undetected and above all
*untraceable* acts of system administration.