1 /* linux/arch/arm/plat-s5p/dev-uart.c
3 * Copyright (c) 2009 Samsung Electronics Co., Ltd.
4 * http://www.samsung.com/
6 * Base S5P UART resource and device definitions
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License version 2 as
10 * published by the Free Software Foundation.
13 #include <linux/kernel.h>
14 #include <linux/types.h>
15 #include <linux/interrupt.h>
16 #include <linux/list.h>
17 #include <linux/platform_device.h>
19 #include <asm/mach/arch.h>
20 #include <asm/mach/irq.h>
21 #include <mach/hardware.h>
24 #include <plat/devs.h>
26 /* Serial port registrations */
28 static struct resource s5p_uart0_resource[] = {
30 .start = S5P_PA_UART0,
31 .end = S5P_PA_UART0 + S5P_SZ_UART - 1,
32 .flags = IORESOURCE_MEM,
37 .flags = IORESOURCE_IRQ,
41 static struct resource s5p_uart1_resource[] = {
43 .start = S5P_PA_UART1,
44 .end = S5P_PA_UART1 + S5P_SZ_UART - 1,
45 .flags = IORESOURCE_MEM,
50 .flags = IORESOURCE_IRQ,
54 static struct resource s5p_uart2_resource[] = {
56 .start = S5P_PA_UART2,
57 .end = S5P_PA_UART2 + S5P_SZ_UART - 1,
58 .flags = IORESOURCE_MEM,
63 .flags = IORESOURCE_IRQ,
67 static struct resource s5p_uart3_resource[] = {
68 #if CONFIG_SERIAL_SAMSUNG_UARTS > 3
70 .start = S5P_PA_UART3,
71 .end = S5P_PA_UART3 + S5P_SZ_UART - 1,
72 .flags = IORESOURCE_MEM,
77 .flags = IORESOURCE_IRQ,
82 static struct resource s5p_uart4_resource[] = {
83 #if CONFIG_SERIAL_SAMSUNG_UARTS > 4
85 .start = S5P_PA_UART4,
86 .end = S5P_PA_UART4 + S5P_SZ_UART - 1,
87 .flags = IORESOURCE_MEM,
92 .flags = IORESOURCE_IRQ,
97 static struct resource s5p_uart5_resource[] = {
98 #if CONFIG_SERIAL_SAMSUNG_UARTS > 5
100 .start = S5P_PA_UART5,
101 .end = S5P_PA_UART5 + S5P_SZ_UART - 1,
102 .flags = IORESOURCE_MEM,
107 .flags = IORESOURCE_IRQ,
112 struct s3c24xx_uart_resources s5p_uart_resources[] __initdata = {
114 .resources = s5p_uart0_resource,
115 .nr_resources = ARRAY_SIZE(s5p_uart0_resource),
118 .resources = s5p_uart1_resource,
119 .nr_resources = ARRAY_SIZE(s5p_uart1_resource),
122 .resources = s5p_uart2_resource,
123 .nr_resources = ARRAY_SIZE(s5p_uart2_resource),
126 .resources = s5p_uart3_resource,
127 .nr_resources = ARRAY_SIZE(s5p_uart3_resource),
130 .resources = s5p_uart4_resource,
131 .nr_resources = ARRAY_SIZE(s5p_uart4_resource),
134 .resources = s5p_uart5_resource,
135 .nr_resources = ARRAY_SIZE(s5p_uart5_resource),