Re: [PATCH 1/4] serial: mxs-auart: use mctrl_gpio helpers for handling modem signals (v2.2c)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Sep 26, 2014 at 02:59:18PM +0200, Janusz Użycki wrote:
> But serial8250_get_mctrl() in 8250_core.c calls serial8250_modem_status()
> which calls eg. uart_handle_cts_change() even if enable_ms() wasn't called.
> This is the difference.
> The serial8250_modem_status() is also called in the interrupt
> and, what I don't understand, in serial8250_console_write().

Reading the MSR register clears the interrupts.  So, whenever MSR is read,
you have to deal with any state changes which _would_ have been passed
to the interrupt function.

Plus, it's not quite as you make out above.

If enable_ms() is not called, then UART_IER_MSI will not be set in up->ier.
Hence, uart_handle_cts_change() will not be called.

The reason for the call in the console function is to account for the
state changes during console write with CTS flow control - this again
needs the MSR register to be read, and we have to account for MSR state
changes after the console write has completed.

-- 
FTTC broadband for 0.8mile line: currently at 9.5Mbps down 400kbps up
according to speedtest.net.
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux