mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
tty/serial: Add support for Altera serial port
commit e06c93cacb
upstream.
Add support for Altera 8250/16550 compatible serial port.
Signed-off-by: Ley Foon Tan <lftan@altera.com>
[xr: Backported to 3.4: adjust filenames, context]
Signed-off-by: Rui Xiang <rui.xiang@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
7400ce7ee9
commit
85faa17c6a
4 changed files with 34 additions and 1 deletions
|
@ -10,6 +10,9 @@ Required properties:
|
|||
- "ns16850"
|
||||
- "nvidia,tegra20-uart"
|
||||
- "ibm,qpace-nwp-serial"
|
||||
- "altr,16550-FIFO32"
|
||||
- "altr,16550-FIFO64"
|
||||
- "altr,16550-FIFO128"
|
||||
- "serial" if the port type is unknown.
|
||||
- reg : offset and length of the register set for the device.
|
||||
- interrupts : should contain uart interrupt.
|
||||
|
|
|
@ -288,6 +288,27 @@ static const struct serial8250_config uart_config[] = {
|
|||
.tx_loadsz = 1024,
|
||||
.flags = UART_CAP_HFIFO,
|
||||
},
|
||||
[PORT_ALTR_16550_F32] = {
|
||||
.name = "Altera 16550 FIFO32",
|
||||
.fifo_size = 32,
|
||||
.tx_loadsz = 32,
|
||||
.fcr = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
|
||||
.flags = UART_CAP_FIFO | UART_CAP_AFE,
|
||||
},
|
||||
[PORT_ALTR_16550_F64] = {
|
||||
.name = "Altera 16550 FIFO64",
|
||||
.fifo_size = 64,
|
||||
.tx_loadsz = 64,
|
||||
.fcr = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
|
||||
.flags = UART_CAP_FIFO | UART_CAP_AFE,
|
||||
},
|
||||
[PORT_ALTR_16550_F128] = {
|
||||
.name = "Altera 16550 FIFO128",
|
||||
.fifo_size = 128,
|
||||
.tx_loadsz = 128,
|
||||
.fcr = UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
|
||||
.flags = UART_CAP_FIFO | UART_CAP_AFE,
|
||||
},
|
||||
};
|
||||
|
||||
#if defined(CONFIG_MIPS_ALCHEMY)
|
||||
|
|
|
@ -182,6 +182,12 @@ static struct of_device_id __devinitdata of_platform_serial_table[] = {
|
|||
{ .compatible = "ns16750", .data = (void *)PORT_16750, },
|
||||
{ .compatible = "ns16850", .data = (void *)PORT_16850, },
|
||||
{ .compatible = "nvidia,tegra20-uart", .data = (void *)PORT_TEGRA, },
|
||||
{ .compatible = "altr,16550-FIFO32",
|
||||
.data = (void *)PORT_ALTR_16550_F32, },
|
||||
{ .compatible = "altr,16550-FIFO64",
|
||||
.data = (void *)PORT_ALTR_16550_F64, },
|
||||
{ .compatible = "altr,16550-FIFO128",
|
||||
.data = (void *)PORT_ALTR_16550_F128, },
|
||||
#ifdef CONFIG_SERIAL_OF_PLATFORM_NWPSERIAL
|
||||
{ .compatible = "ibm,qpace-nwp-serial",
|
||||
.data = (void *)PORT_NWPSERIAL, },
|
||||
|
|
|
@ -48,7 +48,10 @@
|
|||
#define PORT_TEGRA 20 /* NVIDIA Tegra internal UART */
|
||||
#define PORT_XR17D15X 21 /* Exar XR17D15x UART */
|
||||
#define PORT_BRCM_TRUMANAGE 25
|
||||
#define PORT_MAX_8250 25 /* max port ID */
|
||||
#define PORT_ALTR_16550_F32 26 /* Altera 16550 UART with 32 FIFOs */
|
||||
#define PORT_ALTR_16550_F64 27 /* Altera 16550 UART with 64 FIFOs */
|
||||
#define PORT_ALTR_16550_F128 28 /* Altera 16550 UART with 128 FIFOs */
|
||||
#define PORT_MAX_8250 28 /* max port ID */
|
||||
|
||||
/*
|
||||
* ARM specific type numbers. These are not currently guaranteed
|
||||
|
|
Loading…
Reference in a new issue