xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v6 0/5] Add UART support and arch timer initialization for OMAP5
@ 2013-08-09  2:20 Chen Baozi
  2013-08-09  2:20 ` [PATCH v6 1/6] xen: rename ns16550-uart.h to 8250-uart.h and fix some typos Chen Baozi
                   ` (5 more replies)
  0 siblings, 6 replies; 17+ messages in thread
From: Chen Baozi @ 2013-08-09  2:20 UTC (permalink / raw)
  To: Ian Campbell, Julien Grall; +Cc: Chen Baozi, Xen Developer List

Since OMAP UART has a few distinct features than common 8250 UART, I
re-implemented its driver rather than porting it based on ns16550.c.
There are mainly two big differences between the implementations. First,
OMAP UART introduces the concept of register access mode, which divides
the register map into seperated space. Switching the access mode is then
necessary when configuring it. Second, THRE interrupt needs to be disable
after finished transmission and enabled once transmission started. This
is because the semantic of THRE interrupt differs from common 8250 in TI's
implementation, which would be generated if TX FIFO below trigger level
and cannot be cleared by simply write to THR once.

Besides UART driver, arch timer initialization for OMAP5432 platform
is also done in this patch series.

v6 <- v5:
- Add EARLY_UART_REG_SHIFT and remove REG_SHIFT in 8250-uart.h
- Define REG_SHIFT in omap-uart.c rather than 8250-uart.h, since Linux
  also uses hardcoded regshift in omap-uart driver and there is no
  reg-shift of UART defined in OMAP5's DT.
- Separate dt_property_read_u32 introduction into a single patch.
- Fix some typos.

v5 <- v4:
- Separate dt specified arch_timer clkfrq setup into patch #4.

v4 <- v3:
- Merege #4 and #5 in v3 into one patch.
- Fix some coding-style and comments.

v3 <- v2:
- [3/5] Use bool_t as the return type of dt_property_read_u32.
- [3/5] Use sizeof(*out_value) instead of hardcoded value in dt_property_read_u32.
- [3/5] Fix some coding-style problems and some typos.

v2 <- v1:
- [2/5] Add early printk support for sun6i.

- [3/5] Introduce dt_property_read_u32() helper to get clock-frequency.
- [3/5] Use ioreadl/iowritel instead of uart->regs[...] in OMAP UART driver.
- [3/5] Change do-while structure to while in OMAP UART interrupt handler.
- [3/5] Use hardcoded value when setting up OMAP UART.
- [3/5] Won't enable IRQ if setup failed in init_postirq().
- [3/5] Fix coding-style problems and some typos.
- [3/5] Remove unnecessary define.

- [4/5] Remove the macros that would be used in future.

- [5/5] Use dt_property_read_u32() helper to get clock-frequency.
- [5/5] Remove unused define.

Chen Baozi (6):
  xen: rename ns16550-uart.h to 8250-uart.h and fix some typos
  xen/arm: add 8250 compatible UART support for early_printk
  xen: Introduce a helper to read a u32 property in device tree.
  xen/arm: Add the new OMAP UART driver.
  xen/arm: Add support for device tree specified arch_timer clock
    frequency.
  xen/arm: Platform recognition and initialize arch_timer for the OMAP5

 config/arm32.mk                                 |   1 +
 docs/misc/arm/early-printk.txt                  |   3 +
 xen/arch/arm/Rules.mk                           |  16 ++
 xen/arch/arm/arm32/debug-8250.inc               |  41 +++
 xen/arch/arm/platforms/Makefile                 |   1 +
 xen/arch/arm/platforms/omap5.c                  | 117 ++++++++
 xen/arch/arm/time.c                             |   7 +-
 xen/common/device_tree.c                        |  15 +
 xen/drivers/char/Makefile                       |   1 +
 xen/drivers/char/ns16550.c                      |   2 +-
 xen/drivers/char/omap-uart.c                    | 354 ++++++++++++++++++++++++
 xen/include/asm-arm/platforms/omap5.h           |  25 ++
 xen/include/xen/{ns16550-uart.h => 8250-uart.h} |  69 ++++-
 xen/include/xen/device_tree.h                   |  11 +
 14 files changed, 652 insertions(+), 11 deletions(-)
 create mode 100644 xen/arch/arm/arm32/debug-8250.inc
 create mode 100644 xen/arch/arm/platforms/omap5.c
 create mode 100644 xen/drivers/char/omap-uart.c
 create mode 100644 xen/include/asm-arm/platforms/omap5.h
 rename xen/include/xen/{ns16550-uart.h => 8250-uart.h} (63%)

-- 
1.8.1.4

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

end of thread, other threads:[~2013-08-13  9:39 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-09  2:20 [PATCH v6 0/5] Add UART support and arch timer initialization for OMAP5 Chen Baozi
2013-08-09  2:20 ` [PATCH v6 1/6] xen: rename ns16550-uart.h to 8250-uart.h and fix some typos Chen Baozi
2013-08-09  2:20 ` [PATCH v6 2/6] xen/arm: add 8250 compatible UART support for early_printk Chen Baozi
2013-08-12 15:16   ` Julien Grall
2013-08-13  1:50     ` Chen Baozi
2013-08-09  2:20 ` [PATCH v6 3/6] xen: Introduce a helper to read a u32 property in device tree Chen Baozi
2013-08-12 15:19   ` Julien Grall
2013-08-12 22:19     ` Julien Grall
2013-08-13  1:32       ` Chen Baozi
2013-08-09  2:20 ` [PATCH v6 4/6] xen/arm: Add the new OMAP UART driver Chen Baozi
2013-08-12 22:21   ` Julien Grall
2013-08-13  2:35     ` Chen Baozi
2013-08-13  9:39       ` Julien Grall
2013-08-13  3:37     ` Chen Baozi
2013-08-13  7:07       ` Chen Baozi
2013-08-09  2:20 ` [PATCH v6 5/6] xen/arm: Add support for device tree specified arch_timer clock frequency Chen Baozi
2013-08-09  2:20 ` [PATCH v6 6/6] xen/arm: Platform recognition and initialize arch_timer for the OMAP5 Chen Baozi

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).