2 * linux/arch/arm/kernel/head-armo.S
4 * Copyright (C) 1994-2000 Russell King
6 * 26-bit kernel startup code
8 #include <linux/config.h>
9 #include <linux/linkage.h>
10 #include <asm/mach-types.h>
12 .globl SYMBOL_NAME(swapper_pg_dir)
13 .equ SYMBOL_NAME(swapper_pg_dir), 0x0207d000
18 .section ".text.init",#alloc,#execinstr
21 __entry: cmp pc, #0x02000000
22 ldrlt pc, LC0 @ if 0x01800000, call at 0x02080000
23 teq r0, #0 @ Check for old calling method
24 blne oldparams @ Move page if old
26 ldmib r0, {r2-r5, sp} @ Setup stack
28 1: cmp r2, r3 @ Clear BSS
38 b SYMBOL_NAME(start_kernel)
40 LC0: .word SYMBOL_NAME(_stext)
41 .word SYMBOL_NAME(__bss_start) @ r2
42 .word SYMBOL_NAME(_end) @ r3
43 .word SYMBOL_NAME(processor_id) @ r4
44 .word SYMBOL_NAME(__machine_arch_type) @ r5
45 .word SYMBOL_NAME(init_task_union)+8192 @ sp
46 arm2_id: .long 0x41560200
47 arm250_id: .long 0x41560250
50 oldparams: mov r4, #0x02000000
51 add r3, r4, #0x00080000
52 add r4, r4, #0x0007c000
53 1: ldmia r0!, {r5 - r12}
60 * We need some way to automatically detect the difference between
61 * these two machines. Unfortunately, it is not possible to detect
62 * the presence of the SuperIO chip, because that will hang the old
63 * Archimedes machines solid.
65 /* DAG: Outdated, these have been combined !!!!!!! */
67 #if defined(CONFIG_ARCH_ARC)
68 mov r0, #MACH_TYPE_ARCHIMEDES
69 #elif defined(CONFIG_ARCH_A5K)
70 mov r0, #MACH_TYPE_A5K
76 mov r2, #0xea000000 @ Point undef instr to continuation
78 orr r0, r2, r0, lsr #2
82 swp r2, r2, [r1] @ check for swp (ARM2 can't)
84 mrc 15, 0, r3, c0, c0 @ check for CP#15 (ARM250 can't)
86 continue: mov r2, #0xeb000000 @ Make undef vector loop