From: Timur Tabi <timur@freescale.com>
To: Greg KH <gregkh@suse.de>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: How important is it that tty_write_room doesn't lie?
Date: Wed, 23 Feb 2011 14:48:18 -0600 [thread overview]
Message-ID: <4D657292.6000106@freescale.com> (raw)
In-Reply-To: <20110223202915.GB9081@suse.de>
Greg KH wrote:
> I think that people don't normally hit this as the console code isn't
> used as a tty and a console at the same time, right?
That's another thing I never understood. It's rare for a driver to support both
the console and tty layers. The serial core driver does that, but I can't find
any other examples. I would think that a driver would support both interfaces,
because both are needed. Simplistically, printk --> console, and printf -->
tty. When would ever want user-space support but not kernel support?
> How big is your buffer in your FIFO?
The FIFO can vary, but it's probably at least 2KB it size. At least, we hope to
able to set it to that size in the field. Currently, we set it to 4KB.
> Can you always just say you have a
> smaller ammount in order to try to work around the tty layer trying to
> send you a few extra bytes at times?
How many bytes extra? I don't even have any hard evidence that this is actually
happening, but a customer is reporting lost characters and this the only thing
we could come up with.
The serial drivers seem to have a software FIFO for the TTY interface, but none
for the console interface. uart_write() puts the data into an internal circular
buffer, and then calls uart_start(). serial8250_console_write(), however,
writes directly to the hardware. Is this what I should be doing?
--
Timur Tabi
Linux kernel developer at Freescale
next prev parent reply other threads:[~2011-02-23 20:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-23 19:56 How important is it that tty_write_room doesn't lie? Timur Tabi
2011-02-23 20:29 ` Greg KH
2011-02-23 20:48 ` Timur Tabi [this message]
2011-02-23 22:57 ` Ted Ts'o
2011-02-24 12:34 ` Theodore Tso
2011-02-23 23:17 ` Greg KH
2011-02-24 11:29 ` Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4D657292.6000106@freescale.com \
--to=timur@freescale.com \
--cc=gregkh@suse.de \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox