]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
ARM: OMAP: Cleanup OMAP24XX serial code
authorKyungmin Park <kyungmin.park@samsung.com>
Tue, 18 Sep 2007 04:25:58 +0000 (21:25 -0700)
committerTony Lindgren <tony@atomide.com>
Mon, 1 Oct 2007 18:58:26 +0000 (11:58 -0700)
Define the OMAP24XX_BASE_BAUD.
Remove one-line curly brace.

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
arch/arm/mach-omap2/serial.c
include/asm-arm/arch-omap/serial.h

index e9c367fc9f613c96723820cc7e0fd10d7fde421f..c9697a49e0610707df3cd8003d126c25173c1921 100644 (file)
@@ -38,7 +38,7 @@ static struct plat_serial8250_port serial_platform_data[] = {
                .flags          = UPF_BOOT_AUTOCONF,
                .iotype         = UPIO_MEM,
                .regshift       = 2,
-               .uartclk        = OMAP16XX_BASE_BAUD * 16,
+               .uartclk        = OMAP24XX_BASE_BAUD * 16,
        }, {
                .membase        = (char *)IO_ADDRESS(OMAP_UART2_BASE),
                .mapbase        = (unsigned long)OMAP_UART2_BASE,
@@ -46,7 +46,7 @@ static struct plat_serial8250_port serial_platform_data[] = {
                .flags          = UPF_BOOT_AUTOCONF,
                .iotype         = UPIO_MEM,
                .regshift       = 2,
-               .uartclk        = OMAP16XX_BASE_BAUD * 16,
+               .uartclk        = OMAP24XX_BASE_BAUD * 16,
        }, {
                .membase        = (char *)IO_ADDRESS(OMAP_UART3_BASE),
                .mapbase        = (unsigned long)OMAP_UART3_BASE,
@@ -54,7 +54,7 @@ static struct plat_serial8250_port serial_platform_data[] = {
                .flags          = UPF_BOOT_AUTOCONF,
                .iotype         = UPIO_MEM,
                .regshift       = 2,
-               .uartclk        = OMAP16XX_BASE_BAUD * 16,
+               .uartclk        = OMAP24XX_BASE_BAUD * 16,
        }, {
                .flags          = 0
        }
@@ -87,7 +87,7 @@ static inline void __init omap_serial_reset(struct plat_serial8250_port *p)
        serial_write_reg(p, UART_OMAP_SYSC, (0x02 << 3) | (1 << 2) | (1 << 0));
 }
 
-void __init omap_serial_init()
+void __init omap_serial_init(void)
 {
        int i;
        const struct omap_uart_config *info;
@@ -98,8 +98,7 @@ void __init omap_serial_init()
         * if not needed.
         */
 
-       info = omap_get_config(OMAP_TAG_UART,
-                              struct omap_uart_config);
+       info = omap_get_config(OMAP_TAG_UART, struct omap_uart_config);
 
        if (info == NULL)
                return;
@@ -118,46 +117,40 @@ void __init omap_serial_init()
                        uart1_ick = clk_get(NULL, "uart1_ick");
                        if (IS_ERR(uart1_ick))
                                printk("Could not get uart1_ick\n");
-                       else {
+                       else
                                clk_enable(uart1_ick);
-                       }
 
                        uart1_fck = clk_get(NULL, "uart1_fck");
                        if (IS_ERR(uart1_fck))
                                printk("Could not get uart1_fck\n");
-                       else {
+                       else
                                clk_enable(uart1_fck);
-                       }
                        break;
                case 1:
                        uart2_ick = clk_get(NULL, "uart2_ick");
                        if (IS_ERR(uart2_ick))
                                printk("Could not get uart2_ick\n");
-                       else {
+                       else
                                clk_enable(uart2_ick);
-                       }
 
                        uart2_fck = clk_get(NULL, "uart2_fck");
                        if (IS_ERR(uart2_fck))
                                printk("Could not get uart2_fck\n");
-                       else {
+                       else
                                clk_enable(uart2_fck);
-                       }
                        break;
                case 2:
                        uart3_ick = clk_get(NULL, "uart3_ick");
                        if (IS_ERR(uart3_ick))
                                printk("Could not get uart3_ick\n");
-                       else {
+                       else
                                clk_enable(uart3_ick);
-                       }
 
                        uart3_fck = clk_get(NULL, "uart3_fck");
                        if (IS_ERR(uart3_fck))
                                printk("Could not get uart3_fck\n");
-                       else {
+                       else
                                clk_enable(uart3_fck);
-                       }
                        break;
                }
 
index f1bd9d1c4d2b7d64573c5e959cc1f159030ed632..b6771b4403102512b96deb38f9c4b905ea6829fb 100644 (file)
@@ -30,6 +30,7 @@
 #define OMAP_MAX_NR_PORTS      3
 #define OMAP1510_BASE_BAUD     (12000000/16)
 #define OMAP16XX_BASE_BAUD     (48000000/16)
+#define OMAP24XX_BASE_BAUD     (48000000/16)
 
 #define is_omap_port(p)        ({int __ret = 0;                        \
                        if (p == IO_ADDRESS(OMAP_UART1_BASE) || \