Path: blob/master/arch/arm/boot/compressed/head-sa1100.S
10819 views
/*1* linux/arch/arm/boot/compressed/head-sa1100.S2*3* Copyright (C) 1999 Nicolas Pitre <[email protected]>4*5* SA1100 specific tweaks. This is merged into head.S by the linker.6*7*/89#include <linux/linkage.h>10#include <asm/mach-types.h>1112.section ".start", "ax"1314__SA1100_start:1516@ Preserve r8/r7 i.e. kernel entry values17#ifdef CONFIG_SA1100_COLLIE18mov r7, #MACH_TYPE_COLLIE19#endif20#ifdef CONFIG_SA1100_SIMPAD21@ UNTIL we've something like an open bootldr22mov r7, #MACH_TYPE_SIMPAD @should be 8723#endif24mrc p15, 0, r0, c1, c0, 0 @ read control reg25ands r0, r0, #0x0d26beq 99f2728@ Data cache might be active.29@ Be sure to flush kernel binary out of the cache,30@ whatever state it is, before it is turned off.31@ This is done by fetching through currently executed32@ memory to be sure we hit the same cache.33bic r2, pc, #0x1f34add r3, r2, #0x4000 @ 16 kb is quite enough...351: ldr r0, [r2], #3236teq r2, r337bne 1b38mcr p15, 0, r0, c7, c10, 4 @ drain WB39mcr p15, 0, r0, c7, c7, 0 @ flush I & D caches4041@ disabling MMU and caches42mrc p15, 0, r0, c1, c0, 0 @ read control reg43bic r0, r0, #0x0d @ clear WB, DC, MMU44bic r0, r0, #0x1000 @ clear Icache45mcr p15, 0, r0, c1, c0, 04699:474849