Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1736999

Re: [PATCH v3 5/6] serial: imx: update the stop rx,tx procedures

From Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Newsgroups linux.kernel
Subject Re: [PATCH v3 5/6] serial: imx: update the stop rx,tx procedures
Date 2017-09-21 20:30 +0200
Message-ID <useox-4rm-15@gated-at.bofh.it> (permalink)
References <uscmJ-3iX-3@gated-at.bofh.it> <uscmJ-3iX-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Sep 21, 2017 at 05:18:16PM +0100, Martyn Welch wrote:
> From: Nandor Han <nandor.han@ge.com>
> 
> According to "Documentation/serial/driver" both procedures should stop
> receiving or sending data. Based on this the procedures should stop the
> activity regardless if DMA is enabled or not.
> 
> This commit updates both imx_stop_{rx|tx} procedures to stop the
> activity and disable the interrupts related to that.
> 
> Signed-off-by: Nandor Han <nandor.han@ge.com>
> Signed-off-by: Romain Perier <romain.perier@collabora.com>
> Signed-off-by: Martyn Welch <martyn.welch@collabora.co.uk>
> ---
>  drivers/tty/serial/imx.c | 36 +++++++++++++++++-------------------
>  1 file changed, 17 insertions(+), 19 deletions(-)
> 
> diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
> index ed02783..256b128 100644
> --- a/drivers/tty/serial/imx.c
> +++ b/drivers/tty/serial/imx.c
> @@ -388,15 +388,14 @@ static void imx_stop_tx(struct uart_port *port)
>  	struct imx_port *sport = (struct imx_port *)port;
>  	unsigned long temp;
>  
> -	/*
> -	 * We are maybe in the SMP context, so if the DMA TX thread is running
> -	 * on other cpu, we have to wait for it to finish.
> -	 */

did you understand this comment you're removing here? I admit I don't
but unless it is non-sensical you're doing something wrong.

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH v3 5/6] serial: imx: update the stop rx,tx procedures Martyn Welch <martyn.welch@collabora.co.uk> - 2017-09-21 18:20 +0200
  Re: [PATCH v3 5/6] serial: imx: update the stop rx,tx procedures Uwe Kleine-König          <u.kleine-koenig@pengutronix.de> - 2017-09-21 20:30 +0200

csiph-web