From: Andrei Warkentin <andreiw@motorola.com>
To: linux-serial@vger.kernel.org
Subject: Re: Newbie question: setting baudrate / managing FIFO.
Date: Wed, 16 Feb 2011 13:07:12 -0600 [thread overview]
Message-ID: <AANLkTin7n0Uy3ypnibvExANmZmMBZmDi-UHXP_RfJZ7W@mail.gmail.com> (raw)
In-Reply-To: <AANLkTimdduXQaXJTuWPUKTFdQo9XOEYCkdNB_6RTVLFu@mail.gmail.com>
On Wed, Feb 16, 2011 at 4:51 AM, Andrei Warkentin <andreiw@motorola.com> wrote:
> Hi,
>
> I looked about the archives, but maybe I skipped something... When I
> am handling set_termios, what assumptions can I make regarding the
> TX/RX state? I didn't take a look at all the serial drivers, but the
> ones I did look did not bother flushing FIFOs and ensuring nothing can
> be present in the TX FIFO while updating LCR and divisors. Should I do
> the equivalent of stop_tx inside set_termios? Is that already ensured?
> The hardware I am looking at needs to have FIFO cleared after setting
> baud rate, and I was getting concerned over potential data loss
> scenarios...
>
> Thanks,
> A
>
I realize there are different versions of the TCSET - TCSETS,
TCSETF... i.e. if you wanted to flush the buffer you'd ask for it. So
it should be ok to just clear the FIFO and destroy anything in them,
right? Or should I still flush the FIFOs after disabling flow control
if it was on? After all you could have gotten data after you called
set_termios.
Thanks,
A
next prev parent reply other threads:[~2011-02-16 19:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-16 10:51 Newbie question: setting baudrate / managing FIFO Andrei Warkentin
2011-02-16 19:07 ` Andrei Warkentin [this message]
2011-02-18 20:15 ` Andrei Warkentin
2011-02-18 20:24 ` Grant Edwards
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=AANLkTin7n0Uy3ypnibvExANmZmMBZmDi-UHXP_RfJZ7W@mail.gmail.com \
--to=andreiw@motorola.com \
--cc=linux-serial@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;
as well as URLs for NNTP newsgroup(s).