1 /* linux/arch/arm/plat-s3c24xx/dev-uart.c
3 * Copyright (c) 2004 Simtec Electronics
4 * Ben Dooks <ben@simtec.co.uk>
6 * Base S3C24XX UART resource and platform 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/serial_core.h>
18 #include <linux/platform_device.h>
20 #include <asm/mach/arch.h>
21 #include <asm/mach/map.h>
22 #include <asm/mach/irq.h>
23 #include <mach/hardware.h>
26 #include <plat/devs.h>
27 #include <plat/regs-serial.h>
29 /* Serial port registrations */
31 static struct resource s3c2410_uart0_resource
[] = {
33 .start
= S3C2410_PA_UART0
,
34 .end
= S3C2410_PA_UART0
+ 0x3fff,
35 .flags
= IORESOURCE_MEM
,
38 .start
= IRQ_S3CUART_RX0
,
39 .end
= IRQ_S3CUART_ERR0
,
40 .flags
= IORESOURCE_IRQ
,
44 static struct resource s3c2410_uart1_resource
[] = {
46 .start
= S3C2410_PA_UART1
,
47 .end
= S3C2410_PA_UART1
+ 0x3fff,
48 .flags
= IORESOURCE_MEM
,
51 .start
= IRQ_S3CUART_RX1
,
52 .end
= IRQ_S3CUART_ERR1
,
53 .flags
= IORESOURCE_IRQ
,
57 static struct resource s3c2410_uart2_resource
[] = {
59 .start
= S3C2410_PA_UART2
,
60 .end
= S3C2410_PA_UART2
+ 0x3fff,
61 .flags
= IORESOURCE_MEM
,
64 .start
= IRQ_S3CUART_RX2
,
65 .end
= IRQ_S3CUART_ERR2
,
66 .flags
= IORESOURCE_IRQ
,
70 static struct resource s3c2410_uart3_resource
[] = {
72 .start
= S3C2443_PA_UART3
,
73 .end
= S3C2443_PA_UART3
+ 0x3fff,
74 .flags
= IORESOURCE_MEM
,
77 .start
= IRQ_S3CUART_RX3
,
78 .end
= IRQ_S3CUART_ERR3
,
79 .flags
= IORESOURCE_IRQ
,
83 struct s3c24xx_uart_resources s3c2410_uart_resources
[] __initdata
= {
85 .resources
= s3c2410_uart0_resource
,
86 .nr_resources
= ARRAY_SIZE(s3c2410_uart0_resource
),
89 .resources
= s3c2410_uart1_resource
,
90 .nr_resources
= ARRAY_SIZE(s3c2410_uart1_resource
),
93 .resources
= s3c2410_uart2_resource
,
94 .nr_resources
= ARRAY_SIZE(s3c2410_uart2_resource
),
97 .resources
= s3c2410_uart3_resource
,
98 .nr_resources
= ARRAY_SIZE(s3c2410_uart3_resource
),