mini2440系統(tǒng)移植篇之kernel啟動流程
1.1.第1階段
arch/arm/kernel/vmlinux.lds
--------------------Makefile
2.1 arch/arm/boot/compressed/start.S 解壓代碼
2.2 arch/arm/kernel/head.S
2.2.1 __lookup_machine_type 機(jī)器ID
àMACH_START
àmachine_desc //放在__arch_info_begin…__arch_info_end
2.2.2 __create_page_tables 創(chuàng)建頁表
2.2.3 使能MMU
2.2.4 __switch_data
àb start_kernel 跳到C代碼
1.2.第2階段
2.3 init/main.c
2.3.1start_kernel
setup_arch(&command_line) 解析命令行參數(shù)
setup_processor();
setup_machine(machine_arch_type);
parse_tags(tags);
parse_cmdline(cmdline_p,from);
paging_init(mdesc);
devicemaps_init(mdesc);
mdesc->map_io()
setup_command_line(command_line)
parse_early_param()
do_early_param
init_IRQ()
console_init();
s3c24xx_serial_initconsole
reset_init()
kernel_init
prepare_namespace
mount_root 掛接文件系統(tǒng)
init_post