lkml.org 
[lkml]   [2018]   [Sep]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V2 1/2] tty: serial: imx: add lock for registers save/restore
Hello,

On Wed, Sep 05, 2018 at 09:24:26AM +0800, Anson Huang wrote:
> In noirq suspend/resume stage with no_console_suspend enabled,
> imx_uart_console_write() may be called to print out log_buf
> message by printk(), so there will be race condition between
> imx_uart_console_write() and imx_uart_save/restore_context(),
> need to add lock to protect the registers save/restore operations.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/tty/serial/imx.c | 12 +++++++++++-
> 1 file changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
> index 239c0fa..c15332d 100644

Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

Thanks
Uwe

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

\
 
 \ /
  Last update: 2018-09-05 07:55    [W:0.066 / U:9.560 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site