Skip to contentSkip to conversation

UART: add CSR SiRFprimaII SoC on-chip uart drivers

PATCH New Barry Song 5 participants 8 messages Oct 14, 2011 – Oct 28, 2011 TTY layer and serial drivers

lore
Share & tools
lore

Barry Song

author
#0 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

From: Rong Wang <[email protected]>

SiRFprimaII is the latest generation application processor from CSR?s multi-function SoC product family.
The SoC support codes are in arch/arm/mach-prima2 from Linux mainline 3.0.

There are three dedicated UARTs in system. This patch adds basic driver support for them.

It has used the newest pinmux subsystem from Linus Walleij.

---
-v2:

 rename device name from ttyS to ttySiRF;

use dynamic device major and minor;
support non-Bxxx baudrate;
fix other minor issues Alan Cox required.

 drivers/tty/serial/Kconfig        |   21 +
 drivers/tty/serial/Makefile       |    1 +
 drivers/tty/serial/sirfsoc_uart.c |  783 +++++++++++++++++++++++++++++++++++++
 drivers/tty/serial/sirfsoc_uart.h |  185 +++++++++
 4 files changed, 990 insertions(+), 0 deletions(-)
 create mode 100644 drivers/tty/serial/sirfsoc_uart.c
 create mode 100644 drivers/tty/serial/sirfsoc_uart.h
drivers/tty/serial/Kconfig +21 -0
index 4dcb37b..f9d90bd 100644
@@ -528,6 +528,27 @@ config SERIAL_S5PV210
 	help
 	  Serial port support for Samsung's S5P Family of SoC's
 
+config SERIAL_SIRFSOC
+        tristate "SiRF SoC Platform Serial port support"
+        depends on ARM && ARCH_PRIMA2
+        select SERIAL_CORE
+        help
+          Support for the on-chip UART on the CSR SiRFprimaII series,
+          providing /dev/ttyS0, 1 and 2 (note, some machines may not
+          provide all of these ports, depending on how the serial port
+          pins are configured.
+
+config SERIAL_SIRFSOC_CONSOLE
+        bool "Support for console on SiRF SoC serial port"
+        depends on SERIAL_SIRFSOC=y
+        select SERIAL_CORE_CONSOLE
+        help
+          Even if you say Y here, the currently visible virtual console
+          (/dev/tty0) will still be used as the system console by default, but
+          you can alter that using a kernel command line option such as
+          "console=ttySiRFx". (Try "man bootparam" or see the documentation of
+          your boot loader about how to pass options to the kernel at
+          boot time.)
 
 config SERIAL_MAX3100
 	tristate "MAX3100 support"
drivers/tty/serial/Makefile +1 -0
index 83b4da6..5ca170d 100644
@@ -94,3 +94,4 @@ obj-$(CONFIG_SERIAL_MSM_SMD)	+= msm_smd_tty.o
 obj-$(CONFIG_SERIAL_MXS_AUART) += mxs-auart.o
 obj-$(CONFIG_SERIAL_LANTIQ)	+= lantiq.o
 obj-$(CONFIG_SERIAL_XILINX_PS_UART) += xilinx_uartps.o
+obj-$(CONFIG_SERIAL_SIRFSOC) += sirfsoc_uart.o
drivers/tty/serial/sirfsoc_uart.c new file +783 -0

783 lines not on this page · raw message

drivers/tty/serial/sirfsoc_uart.h new file +185 -0

185 lines not on this page · raw message

Signature · 6 lines
1.7.1



Member of the CSR plc group of companies. CSR plc registered in England and Wales, registered number 4187346, registered office Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, United Kingdom
More information can be found at www.csr.com. Follow CSR on Twitter at http://twitter.com/CSR_PLC and read our blog at www.csr.com/blog
#1 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

2011/10/14 Barry Song <[email protected]>:

Quoted 11 lines

From: Rong Wang <[email protected]>

SiRFprimaII is the latest generation application processor from CSR?s multi-function SoC product family.
The SoC support codes are in arch/arm/mach-prima2 from Linux mainline 3.0.

There are three dedicated UARTs in system. This patch adds basic driver support for them.

It has used the newest pinmux subsystem from Linus Walleij.

Hi Alan, it means this patch doesn't compile until pinmux tree of Linus Walleij is merged into mainline.
Now it is a linux next tree.

Quoted 5 lines
Quoted 7 lines

---
?-v2:
?rename device name from ttyS to ttySiRF;
?use dynamic device major and minor;
?support non-Bxxx baudrate;
?fix other minor issues Alan Cox required.

-barry

#2 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

Quoted 8 lines · Barry Song

2011/10/14 Barry Song <[email protected]>:

Quoted 7 lines

From: Rong Wang <[email protected]>

SiRFprimaII is the latest generation application processor from CSR?s multi-function SoC product family.
The SoC support codes are in arch/arm/mach-prima2 from Linux mainline 3.0.

Quoted 8 lines
Quoted 4 lines

There are three dedicated UARTs in system. This patch adds basic driver support for them.

It has used the newest pinmux subsystem from Linus Walleij.

Hi Alan, it means this patch doesn't compile until pinmux tree of Linus Walleij is merged into mainline.
Now it is a linux next tree.

So should it go through the pinmux tree? Or do you want to wait for the 3.3 kernel release to get this merged?

thanks,

greg k-h

#3 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

2011/10/19 Greg KH <[email protected]>:

Quoted 12 lines · Barry Song
Quoted 11 lines

2011/10/14 Barry Song <[email protected]>:

Quoted 10 lines

From: Rong Wang <[email protected]>

SiRFprimaII is the latest generation application processor from CSR?s multi-function SoC product family.
The SoC support codes are in arch/arm/mach-prima2 from Linux mainline 3.0.

There are three dedicated UARTs in system. This patch adds basic driver support for them.

Quoted 8 lines
Quoted 5 lines
Quoted 1 line

It has used the newest pinmux subsystem from Linus Walleij.

Hi Alan, it means this patch doesn't compile until pinmux tree of Linus Walleij is merged into mainline.
Now it is a linux next tree.

So should it go through the pinmux tree? ?Or do you want to wait for the 3.3 kernel release to get this merged?

i think we can go ahead through Linux W's pinmux tree. Linus, would you like to take care once Alan ack this.

Quoted 4 lines

thanks,

greg k-h

-barry

#4 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

Quoted 3 lines

i think we can go ahead through Linux W's pinmux tree. Linus, would you like to take care once Alan ack this.

Fine by me

#5 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

In reply to Barry Song

2011/10/19 Barry Song <[email protected]>:

Quoted 6 lines

2011/10/19 Greg KH <[email protected]>:

Quoted 2 lines

So should it go through the pinmux tree? ?Or do you want to wait for the 3.3 kernel release to get this merged?

i think we can go ahead through Linux W's pinmux tree. Linus, would you like to take care once Alan ack this.

It's a bit late, and I don't know if Torvalds will pull my pin control tree yet, that's uncertain since it's an all new subsystem. It's stabilizing for the merge window.

I would suggest that you see if my tree gets pulled in the merge window, and if and when it does, send the patch as a single patch directly to Torvalds with Alan's ACK and explain the situation with cross-dependence and all.

Linus Walleij

#6 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

2011/10/20 Linus Walleij <[email protected]>:

Quoted 8 lines

2011/10/19 Barry Song <[email protected]>:

Quoted 6 lines

2011/10/19 Greg KH <[email protected]>:

Quoted 2 lines

So should it go through the pinmux tree? ?Or do you want to wait for the 3.3 kernel release to get this merged?

i think we can go ahead through Linux W's pinmux tree. Linus, would you like to take care once Alan ack this.

Quoted 8 lines

It's a bit late, and I don't know if Torvalds will pull my pin control tree yet, that's uncertain since it's an all new subsystem. It's stabilizing for the merge window.

I would suggest that you see if my tree gets pulled in the merge window, and if and when it does, send the patch as a single patch directly to Torvalds with Alan's ACK and explain the situation with cross-dependence and all.

thanks. that is ok to me. i suppose Torvalds will pull your tree in this merge window or next.

if this window, i will send that to Torvalds, if next, i'd like to go through this tree and get merged in 3.3 together with your pinmux.

Quoted 3 lines

Linus Walleij

-barry

#7 lore raw

PATCH v2 1/1 UART: add CSR SiRFprimaII SoC on-chip uart drivers

In reply to Linus Walleij

2011/10/20 Linus Walleij <[email protected]>:

Quoted 8 lines

2011/10/19 Barry Song <[email protected]>:

Quoted 6 lines

2011/10/19 Greg KH <[email protected]>:

Quoted 2 lines

So should it go through the pinmux tree? ?Or do you want to wait for the 3.3 kernel release to get this merged?

i think we can go ahead through Linux W's pinmux tree. Linus, would you like to take care once Alan ack this.

Quoted 8 lines

It's a bit late, and I don't know if Torvalds will pull my pin control tree yet, that's uncertain since it's an all new subsystem. It's stabilizing for the merge window.

I would suggest that you see if my tree gets pulled in the merge window, and if and when it does, send the patch as a single patch directly to Torvalds with Alan's ACK and explain the situation with cross-dependence and all.

i am glad to find your pinctrl tree has been merged by Torvalds. so i will send this uart driver patch depending on your tree to Linus Torvalds directly.

Quoted 3 lines

Linus Walleij

thanks
barry