devfs
[Top] [All Lists]

Re: ttyS1, S2, etc...

To: Richard Gooch <rgooch@xxxxxxxxxxxxxxx>
Subject: Re: ttyS1, S2, etc...
From: Jurgen Botz <jurgen@xxxxxxxx>
Date: Thu, 13 Apr 2000 00:32:49 -0700
Cc: tytso@xxxxxxx, devfs@xxxxxxxxxxx
In-reply-to: Your message of "Thu, 13 Apr 2000 00:58:17 MDT." <200004130658.e3D6wHw06466@vindaloo.ras.ucalgary.ca>
Sender: owner-devfs@xxxxxxxxxxx
Richard Gooch wrote:
> I don't see why you can't just have devfsd load the module when you
> attempt a lookup of /dev/ttyS.* or whatever. Then the existing rc
> scripts which do:
> # setserial /dev/ttyS0 ...
> # setserial /dev/ttyS1 ...
> # setserial /dev/ttyS2 ...
> # setserial /dev/ttyS3 ...

Richard, you're missing the point.  We aren't talking about the
system board serial ports, we're talking about additional serial
ports on dumb ISA multiport cards.  Devfs will not create the
devices for these because the driver, whether module or compiled-in,
doesn't know they exist until serserial is called!  You can 
currently compile the serial driver with options to be able to
handle these cards, but the actual configuration (whether, how 
many, what IRQ, etc.) is not compiled in and can't be auto-sensed.

So like I said originally, there's a chicken-and-egg problem...
devfs can't create the device because it doesn't know the port
exists, and setserial can't tell the driver that the port exists
because there is no device on which to do the ioctls that are
used to pass this info to the kernel.

The point is that because these boards can't be auto-sensed
we need to pass info to the kernel about the ports.  Prior to
devfs using ioctls on the devices made the most sense.  Now,
with devfs, the devices don't exist until we've talked to the
kernel.  So we need to find another way to pass the info to
the kernel.  module options and kernel command line are not
a good solution because it's too much info if there are a lot
of ports.

- Jürgen




<Prev in Thread] Current Thread [Next in Thread>