lkml.org 
[lkml]   [2009]   [Jul]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC] tty (or char) bus?
Hello,

Janusz Krzysztofik, le Tue 14 Jul 2009 17:31:23 +0200, a écrit :
> In my attempt to add support for contols to a voice modem codec sound
> device driver, I found that in order to talk to the modem, it would be
> convenient if I can get access to a tty device from inside the kernel in
> a way similiar to that available form userspace.

I agree.

> AFAICS, even if tty lowlevel write() could be used unmodified, a
> convenient way of reading characters from a tty is missing and should
> be implemented in a line discipline. Please correct me if I am wrong.

Have you seen the receive_buf line discipline hook? Indeed it's not a
read() operation as from userland, but at least you can get the data
from the tty that way.

> OTOH, I found that some kind of abstraction layer for acccessing devices
> over a tty could be convenient. Instead of allocating a new line
> discipline for each specific device, sometimes found on a specific board
> only, why not just create a new bus type?

I'd tend to agree with you, as I also have a use case for that: braille
& speech synthesis devices. However for now I haven't found a really
convincing argument why line disciplines aren't enough.

Samuel
--
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/

\
 
 \ /
  Last update: 2009-07-17 19:57    [W:0.037 / U:8.620 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site