diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-09-28 17:40:39 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-09-28 17:40:39 -0400 |
commit | ebdea46fecae40c4d7effcd33f40918a37a1df4b (patch) | |
tree | e4312bf7f1f3d184738963a0ec300aa9fdfd55c1 /arch/arm/mach-iop33x/uart.c | |
parent | fecf3404f4aba6d0edeba31eeb018cbb6326dff2 (diff) | |
parent | 250d375d1da45a5e08ab8baf5eaa7eb258afd82b (diff) |
Merge branch 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (130 commits)
[ARM] 3856/1: Add clocksource for Intel IXP4xx platforms
[ARM] 3855/1: Add generic time support
[ARM] 3873/1: S3C24XX: Add irq_chip names
[ARM] 3872/1: S3C24XX: Apply consistant tabbing to irq_chips
[ARM] 3871/1: S3C24XX: Fix ordering of EINT4..23
[ARM] nommu: confirms the CR_V bit in nommu mode
[ARM] nommu: abort handler fixup for !CPU_CP15_MMU cores.
[ARM] 3870/1: AT91: Start removing static memory mappings
[ARM] 3869/1: AT91: NAND support for DK and KB9202 boards
[ARM] 3868/1: AT91 hardware header update
[ARM] 3867/1: AT91 GPIO update
[ARM] 3866/1: AT91 clock update
[ARM] 3865/1: AT91RM9200 header updates
[ARM] 3862/2: S3C2410 - add basic power management support for AML M5900 series
[ARM] kthread: switch arch/arm/kernel/apm.c
[ARM] Off-by-one in arch/arm/common/icst*
[ARM] 3864/1: Refactore sharpsl_pm
[ARM] 3863/1: Add Locomo SPI Device
[ARM] 3847/2: Convert LOMOMO to use struct device for GPIOs
[ARM] Use CPU_CACHE_* where possible in asm/cacheflush.h
...
Diffstat (limited to 'arch/arm/mach-iop33x/uart.c')
-rw-r--r-- | arch/arm/mach-iop33x/uart.c | 105 |
1 files changed, 105 insertions, 0 deletions
diff --git a/arch/arm/mach-iop33x/uart.c b/arch/arm/mach-iop33x/uart.c new file mode 100644 index 000000000000..ac297cd0276c --- /dev/null +++ b/arch/arm/mach-iop33x/uart.c | |||
@@ -0,0 +1,105 @@ | |||
1 | /* | ||
2 | * arch/arm/mach-iop33x/uart.c | ||
3 | * | ||
4 | * Author: Dave Jiang (dave.jiang@intel.com) | ||
5 | * Copyright (C) 2004 Intel Corporation. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | */ | ||
11 | |||
12 | #include <linux/mm.h> | ||
13 | #include <linux/init.h> | ||
14 | #include <linux/major.h> | ||
15 | #include <linux/fs.h> | ||
16 | #include <linux/platform_device.h> | ||
17 | #include <linux/serial.h> | ||
18 | #include <linux/tty.h> | ||
19 | #include <linux/serial_8250.h> | ||
20 | #include <asm/io.h> | ||
21 | #include <asm/pgtable.h> | ||
22 | #include <asm/page.h> | ||
23 | #include <asm/mach/map.h> | ||
24 | #include <asm/setup.h> | ||
25 | #include <asm/system.h> | ||
26 | #include <asm/memory.h> | ||
27 | #include <asm/hardware.h> | ||
28 | #include <asm/hardware/iop3xx.h> | ||
29 | #include <asm/mach-types.h> | ||
30 | #include <asm/mach/arch.h> | ||
31 | |||
32 | #define IOP33X_UART_XTAL 33334000 | ||
33 | |||
34 | static struct plat_serial8250_port iop33x_uart0_data[] = { | ||
35 | { | ||
36 | .membase = (char *)IOP33X_UART0_VIRT, | ||
37 | .mapbase = IOP33X_UART0_PHYS, | ||
38 | .irq = IRQ_IOP33X_UART0, | ||
39 | .uartclk = IOP33X_UART_XTAL, | ||
40 | .regshift = 2, | ||
41 | .iotype = UPIO_MEM, | ||
42 | .flags = UPF_SKIP_TEST, | ||
43 | }, | ||
44 | { }, | ||
45 | }; | ||
46 | |||
47 | static struct resource iop33x_uart0_resources[] = { | ||
48 | [0] = { | ||
49 | .start = IOP33X_UART0_PHYS, | ||
50 | .end = IOP33X_UART0_PHYS + 0x3f, | ||
51 | .flags = IORESOURCE_MEM, | ||
52 | }, | ||
53 | [1] = { | ||
54 | .start = IRQ_IOP33X_UART0, | ||
55 | .end = IRQ_IOP33X_UART0, | ||
56 | .flags = IORESOURCE_IRQ, | ||
57 | }, | ||
58 | }; | ||
59 | |||
60 | struct platform_device iop33x_uart0_device = { | ||
61 | .name = "serial8250", | ||
62 | .id = PLAT8250_DEV_PLATFORM, | ||
63 | .dev = { | ||
64 | .platform_data = iop33x_uart0_data, | ||
65 | }, | ||
66 | .num_resources = 2, | ||
67 | .resource = iop33x_uart0_resources, | ||
68 | }; | ||
69 | |||
70 | |||
71 | static struct resource iop33x_uart1_resources[] = { | ||
72 | [0] = { | ||
73 | .start = IOP33X_UART1_PHYS, | ||
74 | .end = IOP33X_UART1_PHYS + 0x3f, | ||
75 | .flags = IORESOURCE_MEM, | ||
76 | }, | ||
77 | [1] = { | ||
78 | .start = IRQ_IOP33X_UART1, | ||
79 | .end = IRQ_IOP33X_UART1, | ||
80 | .flags = IORESOURCE_IRQ, | ||
81 | }, | ||
82 | }; | ||
83 | |||
84 | static struct plat_serial8250_port iop33x_uart1_data[] = { | ||
85 | { | ||
86 | .membase = (char *)IOP33X_UART1_VIRT, | ||
87 | .mapbase = IOP33X_UART1_PHYS, | ||
88 | .irq = IRQ_IOP33X_UART1, | ||
89 | .uartclk = IOP33X_UART_XTAL, | ||
90 | .regshift = 2, | ||
91 | .iotype = UPIO_MEM, | ||
92 | .flags = UPF_SKIP_TEST, | ||
93 | }, | ||
94 | { }, | ||
95 | }; | ||
96 | |||
97 | struct platform_device iop33x_uart1_device = { | ||
98 | .name = "serial8250", | ||
99 | .id = PLAT8250_DEV_PLATFORM1, | ||
100 | .dev = { | ||
101 | .platform_data = iop33x_uart1_data, | ||
102 | }, | ||
103 | .num_resources = 2, | ||
104 | .resource = iop33x_uart1_resources, | ||
105 | }; | ||