linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] serial/8250: Add LPC3220 standard UART type
@ 2012-05-29  9:09 Roland Stigge
  2012-05-29  9:09 ` [PATCH 2/2] serial/of-serial: Add LPC3220 standard UART compatible string Roland Stigge
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Roland Stigge @ 2012-05-29  9:09 UTC (permalink / raw)
  To: linux-arm-kernel

LPC32xx has "Standard" UARTs that are actually 16550A compatible but have
bigger FIFOs. Since the already supported 16X50 line still doesn't match here,
we agreed on adding a new type.

Signed-off-by: Roland Stigge <stigge@antcom.de>

---
Applies to v3.4

 drivers/tty/serial/8250/8250.c |    8 ++++++++
 include/linux/serial_core.h    |    3 ++-
 2 files changed, 10 insertions(+), 1 deletion(-)

--- linux-2.6.orig/drivers/tty/serial/8250/8250.c
+++ linux-2.6/drivers/tty/serial/8250/8250.c
@@ -282,6 +282,14 @@ static const struct serial8250_config ua
 		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
 		.flags		= UART_CAP_FIFO | UART_CAP_AFE | UART_CAP_EFR,
 	},
+	[PORT_LPC3220] = {
+		.name		= "LPC3220",
+		.fifo_size	= 64,
+		.tx_loadsz	= 32,
+		.fcr		= UART_FCR_DMA_SELECT | UART_FCR_ENABLE_FIFO |
+				  UART_FCR_R_TRIG_00 | UART_FCR_T_TRIG_00,
+		.flags		= UART_CAP_FIFO,
+	},
 };
 
 #if defined(CONFIG_MIPS_ALCHEMY)
--- linux-2.6.orig/include/linux/serial_core.h
+++ linux-2.6/include/linux/serial_core.h
@@ -47,7 +47,8 @@
 #define PORT_U6_16550A	19	/* ST-Ericsson U6xxx internal UART */
 #define PORT_TEGRA	20	/* NVIDIA Tegra internal UART */
 #define PORT_XR17D15X	21	/* Exar XR17D15x UART */
-#define PORT_MAX_8250	21	/* max port ID */
+#define PORT_LPC3220	22	/* NXP LPC32xx SoC "Standard" UART */
+#define PORT_MAX_8250	22	/* max port ID */
 
 /*
  * ARM specific type numbers.  These are not currently guaranteed

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 2/2] serial/of-serial: Add LPC3220 standard UART compatible string
  2012-05-29  9:09 [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Roland Stigge
@ 2012-05-29  9:09 ` Roland Stigge
  2012-05-29 10:04 ` [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Alan Cox
  2012-05-29 15:39 ` Arnd Bergmann
  2 siblings, 0 replies; 4+ messages in thread
From: Roland Stigge @ 2012-05-29  9:09 UTC (permalink / raw)
  To: linux-arm-kernel

This patch adds a "compatible" string for the new 8250 UART type PORT_LPC3220.

Signed-off-by: Roland Stigge <stigge@antcom.de>

---
Applies to v 3.4

 Documentation/devicetree/bindings/tty/serial/of-serial.txt |    1 +
 drivers/tty/serial/of_serial.c                             |    1 +
 2 files changed, 2 insertions(+)

--- linux-2.6.orig/Documentation/devicetree/bindings/tty/serial/of-serial.txt
+++ linux-2.6/Documentation/devicetree/bindings/tty/serial/of-serial.txt
@@ -9,6 +9,7 @@ Required properties:
 	- "ns16750"
 	- "ns16850"
 	- "nvidia,tegra20-uart"
+	- "nxp,lpc3220-uart"
 	- "ibm,qpace-nwp-serial"
 	- "serial" if the port type is unknown.
 - reg : offset and length of the register set for the device.
--- linux-2.6.orig/drivers/tty/serial/of_serial.c
+++ linux-2.6/drivers/tty/serial/of_serial.c
@@ -182,6 +182,7 @@ static struct of_device_id __devinitdata
 	{ .compatible = "ns16750",  .data = (void *)PORT_16750, },
 	{ .compatible = "ns16850",  .data = (void *)PORT_16850, },
 	{ .compatible = "nvidia,tegra20-uart", .data = (void *)PORT_TEGRA, },
+	{ .compatible = "nxp,lpc3220-uart", .data = (void *)PORT_LPC3220, },
 #ifdef CONFIG_SERIAL_OF_PLATFORM_NWPSERIAL
 	{ .compatible = "ibm,qpace-nwp-serial",
 		.data = (void *)PORT_NWPSERIAL, },

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/2] serial/8250: Add LPC3220 standard UART type
  2012-05-29  9:09 [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Roland Stigge
  2012-05-29  9:09 ` [PATCH 2/2] serial/of-serial: Add LPC3220 standard UART compatible string Roland Stigge
@ 2012-05-29 10:04 ` Alan Cox
  2012-05-29 15:39 ` Arnd Bergmann
  2 siblings, 0 replies; 4+ messages in thread
From: Alan Cox @ 2012-05-29 10:04 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 29 May 2012 11:09:29 +0200
Roland Stigge <stigge@antcom.de> wrote:

> LPC32xx has "Standard" UARTs that are actually 16550A compatible but have
> bigger FIFOs. Since the already supported 16X50 line still doesn't match here,
> we agreed on adding a new type.
> 
> Signed-off-by: Roland Stigge <stigge@antcom.de>

Acked-by: Alan Cox <alan@linux.intel.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/2] serial/8250: Add LPC3220 standard UART type
  2012-05-29  9:09 [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Roland Stigge
  2012-05-29  9:09 ` [PATCH 2/2] serial/of-serial: Add LPC3220 standard UART compatible string Roland Stigge
  2012-05-29 10:04 ` [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Alan Cox
@ 2012-05-29 15:39 ` Arnd Bergmann
  2 siblings, 0 replies; 4+ messages in thread
From: Arnd Bergmann @ 2012-05-29 15:39 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday 29 May 2012, Roland Stigge wrote:
> 
> LPC32xx has "Standard" UARTs that are actually 16550A compatible but have
> bigger FIFOs. Since the already supported 16X50 line still doesn't match here,
> we agreed on adding a new type.
> 
> Signed-off-by: Roland Stigge <stigge@antcom.de>
> 

Acked-by: Arnd Bergmann <arnd@arndb.de>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-05-29 15:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-29  9:09 [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Roland Stigge
2012-05-29  9:09 ` [PATCH 2/2] serial/of-serial: Add LPC3220 standard UART compatible string Roland Stigge
2012-05-29 10:04 ` [PATCH 1/2] serial/8250: Add LPC3220 standard UART type Alan Cox
2012-05-29 15:39 ` Arnd Bergmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).