Re: devfs + PCI serial card = no extra serial ports

David Woodhouse (dwmw2@infradead.org)
14 Mar 2003 15:23:50 +0000


On Mon, 2003-03-10 at 18:25, Bryan Whitehead wrote:
> [snip]
> > There is nothing in devfs that prevents you from registering
> > devfs devices even if they are not yet bound to specific hardware
> > (you do not need a sysfs mapping, for example). So, you should be
> > able to register /dev/tts/0..N at initialization, where N is the
> > maximum number of serial devices you want to support.
>
> are you saying there is a way to force devfs to make more entries in
> /dev/tts/ without any hardware being attached to the entries? Then i can
> use setserial? so on boot I'd have 4 entries in /dev/tts ?

Don't do this. The whole concept of opening a device node for a device
which is _absent_, then doing magic ioctls on it to make the driver
probe for the hardware, is utterly bogus.

Fix it properly instead -- disallow opening of a /dev/ttySx node with
uart type unknown, and implement a proper way to tell the serial driver
'please look for a device _here_', via sysfs or something.

-- 
dwmw2

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/