tty/serial: Add explicit PORT_TEGRA type
commit4539c24fe4f92c09ee668ef959d3e8180df619b9
authorStephen Warren <swarren@nvidia.com>
Tue, 17 May 2011 22:12:36 +0000 (17 16:12 -0600)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 19 May 2011 23:51:01 +0000 (19 16:51 -0700)
treed198ea0f07a6f6ba697747d6243ce6b89c319091
parentee4f6b4b89665b92ead67deaa2e5d2ffa1af2b5f
tty/serial: Add explicit PORT_TEGRA type

Tegra's UART is currently auto-detected as PORT_XSCALE due to register
bit UART_IER.UUE being writable. However, the Tegra documentation states
that this register bit is reserved. Hence, we should not program it.

Instead, the documentation specifies that the UART is 16550 compatible.
However, Tegra does need register bit UART_IER.RTOIE set, which is not
enabled by any 16550 port type. This was not noticed before, since
PORT_XSCALE enables CAP_UUE, which conflates both UUE and RTOIE bit
programming.

This change defines PORT_TEGRA that doesn't set UART_CAP_UUE, but does
set UART_CAP_RTOIE, which is a new capability indicating that the RTOIE
bit needs to be enabled.

Based-on-code-by: Laxman Dewangan <ldewangan@nvidia.com>
Cc: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/tty/serial/8250.c
drivers/tty/serial/8250.h
include/linux/serial_core.h
include/linux/serial_reg.h