v2.4.8 -> v2.4.8.1
[opensuse:kernel.git] / arch / arm / kernel / arch.c
1 /*
2  *  linux/arch/arm/kernel/arch.c
3  *
4  *  Architecture specific fixups.
5  */
6 #include <linux/config.h>
7 #include <linux/tty.h>
8 #include <linux/delay.h>
9 #include <linux/pm.h>
10 #include <linux/init.h>
11
12 #include <asm/elf.h>
13 #include <asm/setup.h>
14 #include <asm/mach-types.h>
15
16 #include <asm/mach/arch.h>
17 #include <asm/hardware/dec21285.h>
18
19 extern void genarch_init_irq(void);
20
21 unsigned int vram_size;
22
23 #ifdef CONFIG_ARCH_ACORN
24
25 unsigned int memc_ctrl_reg;
26 unsigned int number_mfm_drives;
27
28 static int __init parse_tag_acorn(const struct tag *tag)
29 {
30         memc_ctrl_reg = tag->u.acorn.memc_control_reg;
31         number_mfm_drives = tag->u.acorn.adfsdrives;
32
33         switch (tag->u.acorn.vram_pages) {
34         case 512:
35                 vram_size += PAGE_SIZE * 256;
36         case 256:
37                 vram_size += PAGE_SIZE * 256;
38         default:
39                 break;
40         }
41 #if 0
42         if (vram_size) {
43                 desc->video_start = 0x02000000;
44                 desc->video_end   = 0x02000000 + vram_size;
45         }
46 #endif
47         return 0;
48 }
49
50 __tagtable(ATAG_ACORN, parse_tag_acorn);
51
52 #ifdef CONFIG_ARCH_RPC
53 static void __init
54 fixup_riscpc(struct machine_desc *desc, struct param_struct *unusd,
55             char **cmdline, struct meminfo *mi)
56 {
57         /*
58          * RiscPC can't handle half-word loads and stores
59          */
60         elf_hwcap &= ~HWCAP_HALF;
61 }
62
63 extern void __init rpc_map_io(void);
64
65 MACHINE_START(RISCPC, "Acorn-RiscPC")
66         MAINTAINER("Russell King")
67         BOOT_MEM(0x10000000, 0x03000000, 0xe0000000)
68         BOOT_PARAMS(0x10000100)
69         DISABLE_PARPORT(0)
70         DISABLE_PARPORT(1)
71         FIXUP(fixup_riscpc)
72         MAPIO(rpc_map_io)
73         INITIRQ(genarch_init_irq)
74 MACHINE_END
75 #endif
76 #ifdef CONFIG_ARCH_ARC
77 MACHINE_START(ARCHIMEDES, "Acorn-Archimedes")
78         MAINTAINER("Dave Gilbert")
79         BOOT_PARAMS(0x0207c000)
80         INITIRQ(genarch_init_irq)
81 MACHINE_END
82 #endif
83 #ifdef CONFIG_ARCH_A5K
84 MACHINE_START(A5K, "Acorn-A5000")
85         MAINTAINER("Russell King")
86         BOOT_PARAMS(0x0207c000)
87         INITIRQ(genarch_init_irq)
88 MACHINE_END
89 #endif
90 #endif
91
92 #ifdef CONFIG_ARCH_L7200
93 extern void __init l7200_map_io(void);
94
95 static void __init
96 fixup_l7200(struct machine_desc *desc, struct param_struct *unused,
97              char **cmdline, struct meminfo *mi)
98 {
99         mi->nr_banks      = 1;
100         mi->bank[0].start = PHYS_OFFSET;
101         mi->bank[0].size  = (32*1024*1024);
102         mi->bank[0].node  = 0;
103
104         ROOT_DEV = MKDEV(RAMDISK_MAJOR,0);
105         setup_ramdisk( 1, 0, 0, CONFIG_BLK_DEV_RAM_SIZE);
106         setup_initrd( __phys_to_virt(0xf1000000), 0x005dac7b);
107
108         /* Serial Console COM2 and LCD */
109         strcpy( *cmdline, "console=tty0 console=ttyLU1,115200");
110
111         /* Serial Console COM1 and LCD */
112         //strcpy( *cmdline, "console=tty0 console=ttyLU0,115200");
113
114         /* Console on LCD */
115         //strcpy( *cmdline, "console=tty0");
116 }
117
118 MACHINE_START(L7200, "LinkUp Systems L7200")
119         MAINTAINER("Steve Hill / Scott McConnell")
120         BOOT_MEM(0xf0000000, 0x80040000, 0xd0000000)
121         FIXUP(fixup_l7200)
122         MAPIO(l7200_map_io)
123         INITIRQ(genarch_init_irq)
124 MACHINE_END
125 #endif
126
127 #ifdef CONFIG_ARCH_NEXUSPCI
128
129 extern void __init nexuspci_map_io(void);
130
131 MACHINE_START(NEXUSPCI, "FTV/PCI")
132         MAINTAINER("Philip Blundell")
133         BOOT_MEM(0x40000000, 0x10000000, 0xe0000000)
134         MAPIO(nexuspci_map_io)
135         INITIRQ(genarch_init_irq)
136 MACHINE_END
137 #endif
138 #ifdef CONFIG_ARCH_TBOX
139
140 extern void __init tbox_map_io(void);
141
142 MACHINE_START(TBOX, "unknown-TBOX")
143         MAINTAINER("Philip Blundell")
144         BOOT_MEM(0x80000000, 0x00400000, 0xe0000000)
145         MAPIO(tbox_map_io)
146         INITIRQ(genarch_init_irq)
147 MACHINE_END
148 #endif
149 #ifdef CONFIG_ARCH_CLPS7110
150 MACHINE_START(CLPS7110, "CL-PS7110")
151         MAINTAINER("Werner Almesberger")
152         INITIRQ(genarch_init_irq)
153 MACHINE_END
154 #endif
155 #ifdef CONFIG_ARCH_ETOILE
156 MACHINE_START(ETOILE, "Etoile")
157         MAINTAINER("Alex de Vries")
158         INITIRQ(genarch_init_irq)
159 MACHINE_END
160 #endif
161 #ifdef CONFIG_ARCH_LACIE_NAS
162 MACHINE_START(LACIE_NAS, "LaCie_NAS")
163         MAINTAINER("Benjamin Herrenschmidt")
164         INITIRQ(genarch_init_irq)
165 MACHINE_END
166 #endif
167 #ifdef CONFIG_ARCH_CLPS7500
168
169 extern void __init clps7500_map_io(void);
170
171 MACHINE_START(CLPS7500, "CL-PS7500")
172         MAINTAINER("Philip Blundell")
173         BOOT_MEM(0x10000000, 0x03000000, 0xe0000000)
174         MAPIO(clps7500_map_io)
175         INITIRQ(genarch_init_irq)
176 MACHINE_END
177 #endif