Path: blob/master/arch/h8300/platform/h8300h/generic/crt0_ram.S
10820 views
/*1* linux/arch/h8300/platform/h8300h/generic/crt0_ram.S2*3* Yoshinori Sato <[email protected]>4*5* Platform depend startup6* Target Archtecture: AE-3068 (aka. aki3068net)7* Memory Layout : RAM8*/910#define ASSEMBLY1112#include <asm/linkage.h>1314#if !defined(CONFIG_BLKDEV_RESERVE)15#if defined(CONFIG_GDB_DEBUG)16#define RAMEND (__ramend - 0xc000)17#else18#define RAMEND __ramend19#endif20#else21#define RAMEND CONFIG_BLKDEV_RESERVE_ADDRESS22#endif2324.global SYMBOL_NAME(_start)25.global SYMBOL_NAME(command_line)26.global SYMBOL_NAME(_platform_gpio_table)27.global SYMBOL_NAME(_target_name)2829.h8300h3031.section .text32.file "crt0_ram.S"3334/* CPU Reset entry */35SYMBOL_NAME_LABEL(_start)36mov.l #RAMEND,sp37ldc #0x80,ccr3839/* Peripheral Setup */4041#if defined(CONFIG_BLK_DEV_BLKMEM)42/* move romfs image */43jsr @__move_romfs44#endif4546/* .bss clear */47mov.l #__sbss,er548mov.l #__ebss,er449sub.l er5,er450shlr er451shlr er452sub.l er0,er0531:54mov.l er0,@er555adds #4,er556dec.l #1,er457bne 1b5859/* copy kernel commandline */60mov.l #COMMAND_START,er561mov.l #SYMBOL_NAME(command_line),er662mov.w #512,r463eepmov.w6465/* uClinux kernel start */66ldc #0x90,ccr /* running kernel */67mov.l #SYMBOL_NAME(init_thread_union),sp68add.l #0x2000,sp69jsr @_start_kernel70_exit:7172jmp _exit7374rts7576/* I/O port assign information */77__platform_gpio_table:78mov.l #gpio_table,er079rts8081gpio_table:82;; P1DDR83.byte 0x00,0x0084;; P2DDR85.byte 0x00,0x0086;; P3DDR87.byte 0x00,0x0088;; P4DDR89.byte 0x00,0x0090;; P5DDR91.byte 0x00,0x0092;; P6DDR93.byte 0x00,0x0094;; dummy95.byte 0x00,0x0096;; P8DDR97.byte 0x00,0x0098;; P9DDR99.byte 0x00,0x00100;; PADDR101.byte 0x00,0x00102;; PBDDR103.byte 0x00,0x00104105__target_name:106.asciz "generic"107108109