Re: [PATCH 4/6] drivers:misc: sources for Init manager module

From: Pavan Savoy
Date: Wed Mar 24 2010 - 13:33:00 EST


--- On Wed, 24/3/10, Alan Cox <alan@xxxxxxxxxxxxxxxxxxx> wrote:

> From: Alan Cox <alan@xxxxxxxxxxxxxxxxxxx>
> Subject: Re: [PATCH 4/6] drivers:misc: sources for Init manager module
> To: "Pavan Savoy" <pavan_savoy@xxxxxxxxxxx>
> Cc: "Marcel Holtmann" <marcel@xxxxxxxxxxxx>, "Greg KH" <gregkh@xxxxxxx>, "PavanSavoy" <pavan_savoy@xxxxxx>, "linux-kernel@xxxxxxxxxxxxxxx" <linux-kernel@xxxxxxxxxxxxxxx>
> Date: Wednesday, 24 March, 2010, 10:56 PM
> > Isn't there a mechanism for the
> tty_set_ldisc to do what _open does ?
> > I mean there might be plenty of devices on UART which
> might not need /dev/tty at all ? i.e An App need not open
> for a ldisc to be installed.
>
> There is no mechanism to have an open tty without having an
> open file
> attached to it - and changing that would be very very non
> trivial. Plus
> you still need a way to tell the kernel you want the device
> in question
> active. That probably should get addressed some day but its
> not a quick
> fix up!

Which puts me back to square 1, the requirement is TTY device should be open, only when either BT, FM or GPS would want to use it.
[with your patch one of the steps of installing ldisc would be reduced upon opening].

Now from kernel-space which is the first to get notification about requirement of BT/FM or GPS, I somehow have to communicate it to user-space, without the much disliked sysfs entry method.

How do I tell the user-space when I want the TTY device to be opened ?
Actually why do I even need a TTY device in this case - right ?
ldisc driver can do the tty->ops->write and tty_read and put it up on different interfaces like eth0/hci0 or /dev/radio0 etc..

That would mean, a device can be on UART, a ldisc driver attached to it, and doesn't require a user-space daemon to maintain the device node.

>
> Alan
>


Your Mail works best with the New Yahoo Optimized IE8. Get it NOW! http://downloads.yahoo.com/in/internetexplorer/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/