All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maarten Brock <m.brock@vanmierlo.com>
To: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Cc: linux-serial@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, gregkh@linuxfoundation.org,
	michal.simek@xilinx.com,
	Raviteja Narayanam <raviteja.narayanam@xilinx.com>,
	linux-serial-owner@vger.kernel.org
Subject: Re: [PATCH v4 2/2] serial: uartps: Add TACTIVE check in cdns_uart_tx_empty function
Date: Sat, 21 Mar 2020 11:07:10 +0100	[thread overview]
Message-ID: <afd6fd6bc3413692ee91123fc3028583@vanmierlo.com> (raw)
In-Reply-To: <e2514818af5973be291cc117d07739f068b71639.1584610774.git.shubhrajyoti.datta@xilinx.com>

On 2020-03-19 10:44, Shubhrajyoti Datta wrote:
> From: Raviteja Narayanam <raviteja.narayanam@xilinx.com>
> 
> Make sure that all bytes are transmitted out of Uart by monitoring
> CDNS_UART_SR_TACTIVE bit as well.
> 
> Signed-off-by: Raviteja Narayanam <raviteja.narayanam@xilinx.com>
> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> ---
>  drivers/tty/serial/xilinx_uartps.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/tty/serial/xilinx_uartps.c
> b/drivers/tty/serial/xilinx_uartps.c
> index 662b8ab..38cb76a9 100644
> --- a/drivers/tty/serial/xilinx_uartps.c
> +++ b/drivers/tty/serial/xilinx_uartps.c
> @@ -663,8 +663,8 @@ static unsigned int cdns_uart_tx_empty(struct
> uart_port *port)
>  	unsigned int status;
> 
>  	status = readl(port->membase + CDNS_UART_SR) &
> -				CDNS_UART_SR_TXEMPTY;
> -	return status ? TIOCSER_TEMT : 0;
> +		       (CDNS_UART_SR_TXEMPTY | CDNS_UART_SR_TACTIVE);
> +	return (status == CDNS_UART_SR_TXEMPTY) ? TIOCSER_TEMT : 0;
>  }
> 
>  /**

Acked-by: Maarten Brock <m.brock@vanmierlo.com>


WARNING: multiple messages have this Message-ID (diff)
From: Maarten Brock <m.brock@vanmierlo.com>
To: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
Cc: Raviteja Narayanam <raviteja.narayanam@xilinx.com>,
	linux-serial@vger.kernel.org, gregkh@linuxfoundation.org,
	michal.simek@xilinx.com, linux-serial-owner@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v4 2/2] serial: uartps: Add TACTIVE check in cdns_uart_tx_empty function
Date: Sat, 21 Mar 2020 11:07:10 +0100	[thread overview]
Message-ID: <afd6fd6bc3413692ee91123fc3028583@vanmierlo.com> (raw)
In-Reply-To: <e2514818af5973be291cc117d07739f068b71639.1584610774.git.shubhrajyoti.datta@xilinx.com>

On 2020-03-19 10:44, Shubhrajyoti Datta wrote:
> From: Raviteja Narayanam <raviteja.narayanam@xilinx.com>
> 
> Make sure that all bytes are transmitted out of Uart by monitoring
> CDNS_UART_SR_TACTIVE bit as well.
> 
> Signed-off-by: Raviteja Narayanam <raviteja.narayanam@xilinx.com>
> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> ---
>  drivers/tty/serial/xilinx_uartps.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/tty/serial/xilinx_uartps.c
> b/drivers/tty/serial/xilinx_uartps.c
> index 662b8ab..38cb76a9 100644
> --- a/drivers/tty/serial/xilinx_uartps.c
> +++ b/drivers/tty/serial/xilinx_uartps.c
> @@ -663,8 +663,8 @@ static unsigned int cdns_uart_tx_empty(struct
> uart_port *port)
>  	unsigned int status;
> 
>  	status = readl(port->membase + CDNS_UART_SR) &
> -				CDNS_UART_SR_TXEMPTY;
> -	return status ? TIOCSER_TEMT : 0;
> +		       (CDNS_UART_SR_TXEMPTY | CDNS_UART_SR_TACTIVE);
> +	return (status == CDNS_UART_SR_TXEMPTY) ? TIOCSER_TEMT : 0;
>  }
> 
>  /**

Acked-by: Maarten Brock <m.brock@vanmierlo.com>


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-03-21 10:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-19  9:44 [PATCH v4 0/2] serial: uartps: Add TACTIVE check Shubhrajyoti Datta
2020-03-19  9:44 ` Shubhrajyoti Datta
2020-03-19  9:44 ` [PATCH v4 1/2] serial: uartps: Remove unconditional wait inside set_termios Shubhrajyoti Datta
2020-03-19  9:44   ` Shubhrajyoti Datta
2020-03-19  9:44 ` [PATCH v4 2/2] serial: uartps: Add TACTIVE check in cdns_uart_tx_empty function Shubhrajyoti Datta
2020-03-19  9:44   ` Shubhrajyoti Datta
2020-03-21 10:07   ` Maarten Brock [this message]
2020-03-21 10:07     ` Maarten Brock

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=afd6fd6bc3413692ee91123fc3028583@vanmierlo.com \
    --to=m.brock@vanmierlo.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-serial-owner@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=michal.simek@xilinx.com \
    --cc=raviteja.narayanam@xilinx.com \
    --cc=shubhrajyoti.datta@xilinx.com \
    /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.