MOXA linux-2.6.x / linux-2.6.9-uc0 from sdlinux-moxaart.tgz
[linux-2.6.9-moxart.git] / arch / arm / mach-sa1100 / freebird.c
blobabd27aef72f90237641085e348d05176fd1490c4
1 /*
2 * linux/arch/arm/mach-sa1100/freebird.c
3 */
5 #include <linux/config.h>
6 #include <linux/module.h>
7 #include <linux/init.h>
8 #include <linux/kernel.h>
9 #include <linux/tty.h>
11 #include <asm/hardware.h>
12 #include <asm/mach-types.h>
13 #include <asm/setup.h>
15 #include <asm/mach/arch.h>
16 #include <asm/mach/map.h>
17 #include <asm/mach/serial_sa1100.h>
19 #include "generic.h"
22 unsigned long BCR_value = BCR_DB1110;
23 EXPORT_SYMBOL(BCR_value);
25 static void freebird_backlight_power(int on)
27 #error FIXME
28 if (on) {
29 BCR_set(BCR_FREEBIRD_LCD_PWR | BCR_FREEBIRD_LCD_DISP);
30 /* Turn on backlight, Chester */
31 BCR_set(BCR_FREEBIRD_LCD_BACKLIGHT);
32 } else {
33 BCR_clear(BCR_FREEBIRD_LCD_PWR | BCR_FREEBIRD_LCD_DISP
34 /* | BCR_FREEBIRD_LCD_BACKLIGHT */);
38 static void freebird_lcd_power(int on)
42 static int __init freebird_init(void)
44 if (machine_is_freebird()) {
45 sa1100fb_backlight_power = freebird_backlight_power;
46 sa1100fb_lcd_power = freebird_lcd_power;
48 return 0;
51 arch_initcall(freebird_init);
53 static struct map_desc freebird_io_desc[] __initdata = {
54 /* virtual physical length type */
55 { 0xf0000000, 0x12000000, 0x00100000, MT_DEVICE }, /* Board Control Register */
56 { 0xf2000000, 0x19000000, 0x00100000, MT_DEVICE }
59 static void __init freebird_map_io(void)
61 sa1100_map_io();
62 iotable_init(freebird_io_desc, ARRAY_SIZE(freebird_io_desc));
64 sa1100_register_uart(0, 3);
65 sa1100_register_uart(1, 1);
67 /* Set up sleep mode registers */
68 PWER = 0x1;
69 PGSR = 0x0;
70 PCFR = PCFR_OPDE | PCFR_FP | PCFR_FS;
73 MACHINE_START(FREEBIRD, "Freebird-HPC-1.1")
74 BOOT_MEM(0xc0000000,0x80000000, 0xf8000000)
75 #ifdef CONFIG_SA1100_FREEBIRD_NEW
76 BOOT_PARAMS(0xc0000100)
77 #endif
78 MAPIO(freebird_map_io)
79 INITIRQ(sa1100_init_irq)
80 INITTIME(sa1100_init_time)
81 MACHINE_END