summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1/serial.c
diff options
context:
space:
mode:
authorTony Lindgren <tony@atomide.com>2009-10-16 18:53:00 +0200
committerTony Lindgren <tony@atomide.com>2009-10-16 18:53:00 +0200
commit84f90c9cc81d8db172d4f768fc4010f508897366 (patch)
tree22dc6c2d0ea698e4e16651f14840e409fa7da5d5 /arch/arm/mach-omap1/serial.c
parentMerge branch 'omap7xx-fortony-rc3' of git://robotfuzz.com/linwizard-kernel in... (diff)
downloadlinux-84f90c9cc81d8db172d4f768fc4010f508897366.tar.xz
linux-84f90c9cc81d8db172d4f768fc4010f508897366.zip
omap: Change low-level serial init to use ioremap
Change low-level serial init to use ioremap Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap1/serial.c')
-rw-r--r--arch/arm/mach-omap1/serial.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/arch/arm/mach-omap1/serial.c b/arch/arm/mach-omap1/serial.c
index ed07af109f00..cab41713fce2 100644
--- a/arch/arm/mach-omap1/serial.c
+++ b/arch/arm/mach-omap1/serial.c
@@ -64,7 +64,6 @@ static void __init omap_serial_reset(struct plat_serial8250_port *p)
static struct plat_serial8250_port serial_platform_data[] = {
{
- .membase = OMAP1_IO_ADDRESS(OMAP_UART1_BASE),
.mapbase = OMAP_UART1_BASE,
.irq = INT_UART1,
.flags = UPF_BOOT_AUTOCONF,
@@ -73,7 +72,6 @@ static struct plat_serial8250_port serial_platform_data[] = {
.uartclk = OMAP16XX_BASE_BAUD * 16,
},
{
- .membase = OMAP1_IO_ADDRESS(OMAP_UART2_BASE),
.mapbase = OMAP_UART2_BASE,
.irq = INT_UART2,
.flags = UPF_BOOT_AUTOCONF,
@@ -82,7 +80,6 @@ static struct plat_serial8250_port serial_platform_data[] = {
.uartclk = OMAP16XX_BASE_BAUD * 16,
},
{
- .membase = OMAP1_IO_ADDRESS(OMAP_UART3_BASE),
.mapbase = OMAP_UART3_BASE,
.irq = INT_UART3,
.flags = UPF_BOOT_AUTOCONF,
@@ -126,6 +123,14 @@ void __init omap_serial_init(void)
for (i = 0; i < OMAP_MAX_NR_PORTS; i++) {
unsigned char reg;
+ /* Static mapping, never released */
+ serial_platform_data[i].membase =
+ ioremap(serial_platform_data[i].mapbase, SZ_2K);
+ if (!serial_platform_data[i].membase) {
+ printk(KERN_ERR "Could not ioremap uart%i\n", i);
+ continue;
+ }
+
switch (i) {
case 0:
uart1_ck = clk_get(NULL, "uart1_ck");