1 /* Boot entry point for a compressed MN10300 kernel
3 * Copyright (C) 2007 Red Hat, Inc. All Rights Reserved.
4 * Written by David Howells (dhowells@redhat.com)
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public Licence
8 * as published by the Free Software Foundation; either version
9 * 2 of the Licence, or (at your option) any later version.
15 #include <linux/linkage.h>
16 #include <asm/cpu-regs.h>
20 # first save off parameters from bootloader
21 mov param_save_area,a0
27 mov decomp_stack+0x2000-4,a0
30 # invalidate and enable both of the caches
33 movhu d0,(a0) # turn off first
34 mov CHCTR_ICINV|CHCTR_DCINV,d0
38 btst CHCTR_ICBUSY|CHCTR_DCBUSY,d0 # wait till not busy
40 mov CHCTR_ICEN|CHCTR_DCEN|CHCTR_DCWTMD,d0 # writethru dcache
41 movhu d0,(a0) # enable
55 # decompress the kernel
56 call decompress_kernel[],0
58 # disable caches again
64 btst CHCTR_ICBUSY|CHCTR_DCBUSY,d0 # wait till not busy
67 mov param_save_area,a0
73 mov CONFIG_KERNEL_TEXT_ADDRESS,a0