http://downloads.netgear.com/files/GPL/GPL_Source_V361j_DM111PSP_series_consumer_rele...
[bcm963xx.git] / kernel / linux / arch / arm / mach-omap / board-generic.c
1 /*
2  * linux/arch/arm/mach-omap/board-generic.c
3  *
4  * Modified from board-innovator1510.c
5  *
6  * Code for generic OMAP board. Should work on many OMAP systems where
7  * the device drivers take care of all the necessary hardware initialization.
8  * Do not put any board specific code to this file; create a new machine
9  * type if you need custom low-level initializations.
10  *
11  * This program is free software; you can redistribute it and/or modify
12  * it under the terms of the GNU General Public License version 2 as
13  * published by the Free Software Foundation.
14  */
15
16 #include <linux/kernel.h>
17 #include <linux/init.h>
18 #include <linux/device.h>
19
20 #include <asm/hardware.h>
21 #include <asm/mach-types.h>
22 #include <asm/mach/arch.h>
23 #include <asm/mach/map.h>
24
25 #include <asm/arch/clocks.h>
26 #include <asm/arch/gpio.h>
27 #include <asm/arch/mux.h>
28
29 #include "common.h"
30
31 static void __init omap_generic_init_irq(void)
32 {
33         omap_init_irq();
34 }
35
36 /*
37  * Muxes the serial ports on
38  */
39 static void __init omap_early_serial_init(void)
40 {
41         omap_cfg_reg(UART1_TX);
42         omap_cfg_reg(UART1_RTS);
43
44         omap_cfg_reg(UART2_TX);
45         omap_cfg_reg(UART2_RTS);
46
47         omap_cfg_reg(UART3_TX);
48         omap_cfg_reg(UART3_RX);
49 }
50
51 static void __init omap_generic_init(void)
52 {
53         /*
54          * Make sure the serial ports are muxed on at this point.
55          * You have to mux them off in device drivers later on
56          * if not needed.
57          */
58         if (cpu_is_omap1510()) {
59                 omap_early_serial_init();
60         }
61 }
62
63 static void __init omap_generic_map_io(void)
64 {
65         omap_map_io();
66 }
67
68 static void __init omap_generic_init_time(void)
69 {
70         omap_init_time();
71 }
72
73 MACHINE_START(OMAP_GENERIC, "Generic OMAP-1510/1610/1710")
74         MAINTAINER("Tony Lindgren <tony@atomide.com>")
75         BOOT_MEM(0x10000000, 0xfff00000, 0xfef00000)
76         BOOT_PARAMS(0x10000100)
77         MAPIO(omap_generic_map_io)
78         INITIRQ(omap_generic_init_irq)
79         INIT_MACHINE(omap_generic_init)
80         INITTIME(omap_generic_init_time)
81 MACHINE_END
82