lkml.org 
[lkml]   [2010]   [Feb]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/2] serial: Add driver for the Altera JTAG UART
> > Use tty_termios_copy_hw() to copy the old termios hardware settings back
> > so that the caller sees it cannot set them.
>
> Would the following be sufficient?
>
> if (old)
> tty_termios_copy_hw(termios, old);

That will do the trick yes.

> spin_lock(&port->lock);
>
> if (isr & ALTERA_JTAGUART_CONTROL_RE_MSK)
> altera_jtaguart_rx_chars(pp);
> if (isr & ALTERA_JTAGUART_CONTROL_WE_MSK)
> altera_jtaguart_tx_chars(pp);
>
> spin_unlock(&port->lock);

Yes - that stops ->tty becoming NULL while your handler is running

Alan


\
 
 \ /
  Last update: 2010-02-26 12:25    [W:0.808 / U:1.792 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site