All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Brown <davidb@codeaurora.org>
To: Stephen Boyd <sboyd@codeaurora.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-serial@vger.kernel.org
Subject: Re: [PATCH 1/4] msm_serial: Fix NUL byte output on UARTDM
Date: Wed, 24 Jul 2013 13:29:44 -0700	[thread overview]
Message-ID: <20130724202944.GB10926@codeaurora.org> (raw)
In-Reply-To: <1374691051-28544-2-git-send-email-sboyd@codeaurora.org>

On Wed, Jul 24, 2013 at 11:37:28AM -0700, Stephen Boyd wrote:
>UARTDM serial devices require us to wait for the entire TX fifo
>to drain before we can change the contents of the NCF_TX
>register. Furthermore, if we write any characters to the TX fifo
>within the same clock cycle of changing the NCF_TX register the
>NCF_TX register won't latch properly.
>
>To fix these issues we should read back the NCF_TX register to
>delay any TX fifo accesses by a clock cycle and we should wait
>for the TX fifo to drain (instead of just waiting for the fifo to
>be ready to receive more characters). Failure to do so leads to
>random NUL bytes interspersed in the output.
>
>Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
>---
> drivers/tty/serial/msm_serial.c | 14 +++++++++-----
> drivers/tty/serial/msm_serial.h |  1 +
> 2 files changed, 10 insertions(+), 5 deletions(-)

Acked-by: David Brown <davidb@codeaurora.org>

-- 
sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation

WARNING: multiple messages have this Message-ID (diff)
From: davidb@codeaurora.org (David Brown)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] msm_serial: Fix NUL byte output on UARTDM
Date: Wed, 24 Jul 2013 13:29:44 -0700	[thread overview]
Message-ID: <20130724202944.GB10926@codeaurora.org> (raw)
In-Reply-To: <1374691051-28544-2-git-send-email-sboyd@codeaurora.org>

On Wed, Jul 24, 2013 at 11:37:28AM -0700, Stephen Boyd wrote:
>UARTDM serial devices require us to wait for the entire TX fifo
>to drain before we can change the contents of the NCF_TX
>register. Furthermore, if we write any characters to the TX fifo
>within the same clock cycle of changing the NCF_TX register the
>NCF_TX register won't latch properly.
>
>To fix these issues we should read back the NCF_TX register to
>delay any TX fifo accesses by a clock cycle and we should wait
>for the TX fifo to drain (instead of just waiting for the fifo to
>be ready to receive more characters). Failure to do so leads to
>random NUL bytes interspersed in the output.
>
>Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
>---
> drivers/tty/serial/msm_serial.c | 14 +++++++++-----
> drivers/tty/serial/msm_serial.h |  1 +
> 2 files changed, 10 insertions(+), 5 deletions(-)

Acked-by: David Brown <davidb@codeaurora.org>

-- 
sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
hosted by The Linux Foundation

  reply	other threads:[~2013-07-24 20:29 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-24 18:37 [PATCH 0/4] msm_serial fixes and improvements Stephen Boyd
2013-07-24 18:37 ` Stephen Boyd
2013-07-24 18:37 ` [PATCH 1/4] msm_serial: Fix NUL byte output on UARTDM Stephen Boyd
2013-07-24 18:37   ` Stephen Boyd
2013-07-24 20:29   ` David Brown [this message]
2013-07-24 20:29     ` David Brown
2013-07-24 18:37 ` [PATCH 2/4] msm_serial: Fix sparse warnings Stephen Boyd
2013-07-24 18:37   ` Stephen Boyd
2013-07-24 20:30   ` David Brown
2013-07-24 20:30     ` David Brown
2013-07-24 18:37 ` [PATCH 3/4] msm_serial: Make baud_code detection more dynamic Stephen Boyd
2013-07-24 18:37   ` Stephen Boyd
2013-07-24 20:30   ` David Brown
2013-07-24 20:30     ` David Brown
2013-07-26  4:30   ` Bjorn Andersson
2013-07-26  4:30     ` Bjorn Andersson
2013-07-26 17:05     ` Stephen Boyd
2013-07-26 17:05       ` Stephen Boyd
2013-07-24 18:37 ` [PATCH 4/4] msm_serial: Send more than 1 character at a time on UARTDM Stephen Boyd
2013-07-24 18:37   ` Stephen Boyd
2013-07-24 20:31   ` David Brown
2013-07-24 20:31     ` David Brown
2013-07-24 20:31 ` [PATCH 0/4] msm_serial fixes and improvements David Brown
2013-07-24 20:31   ` David Brown
2013-07-29  9:31 ` Ivan T. Ivanov
2013-07-29  9:31   ` Ivan T. Ivanov

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=20130724202944.GB10926@codeaurora.org \
    --to=davidb@codeaurora.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=sboyd@codeaurora.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.