lkml.org 
[lkml]   [2007]   [Feb]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: serial and tty driver
On Sun, Feb 18, 2007 at 11:52:58AM +0300, Mockern wrote:
> Thank you for you respond.
>
> I asked this question since I have one problem with my tty driver.
> It based on serial_core.c. It works well except Linux cat operation:(.
> (e.g. cat < ttyS10). I thought in tty driver there is no function
> for this operation and I wanted to know that maybe serial driver has it.
>
> Could it be the reason that cat operation in tty driver does not work
> (but I can write and read from user space application!)?
> Or maybe I need to implement a special function in my tty driver to support Linux
> cat operation?

If you do something like "cat < ttyS10" it will work by opening the
device just like a user space application --- but the shell, which is
opening /dev/ttyS10, won't use any of the special flags that a user
space application might use to not wait for the carrier detect line to
go high, for example.

I'd have to see the sources of the driver and your user space
application to be sure, but one thing you should try is "stty -F
/dev/ttyS10 clocal" and see if that allows "cat < /dev/ttyS10" to
work.

Regards,

- Ted
-
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: 2007-02-18 14:07    [W:0.047 / U:0.988 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site