]> rtime.felk.cvut.cz Git - l4.git/blob - kernel/fiasco/src/kern/arm/bsp/imx/kernel_uart-arm-imx.cpp
update
[l4.git] / kernel / fiasco / src / kern / arm / bsp / imx / kernel_uart-arm-imx.cpp
1 INTERFACE:
2
3 // On ARM the MMIO for the uart is accessible before the MMU is fully up
4 EXTENSION class Kernel_uart { enum { Bsp_init_mode = Init_before_mmu }; };
5
6 IMPLEMENTATION [arm && imx21 && serial]:
7
8 #include "mem_layout.h"
9
10 IMPLEMENT
11 bool Kernel_uart::startup(unsigned port, int /*irq*/)
12 {
13   if(port!=3) return false;
14   return Uart::startup(Mem_layout::Uart_base, 20);
15 }
16
17 IMPLEMENTATION [arm && imx35 && serial]:
18
19 #include "mem_layout.h"
20
21 IMPLEMENT
22 bool Kernel_uart::startup(unsigned port, int /*irq*/)
23 {
24   if(port!=3) return false;
25   // uart-1: 45
26   // uart-2: 32
27   // uart-3: 18
28   return Uart::startup(Mem_layout::Uart_base, 45);
29 }
30
31 IMPLEMENTATION [arm && imx51 && serial]:
32
33 #include "mem_layout.h"
34
35 IMPLEMENT
36 bool Kernel_uart::startup(unsigned port, int /*irq*/)
37 {
38   if(port!=3) return false;
39   return Uart::startup(Mem_layout::Uart_base, 31);
40 }