1. 程式人生 > >系統啟動過程(基於三星s5p6818 uboot)

系統啟動過程(基於三星s5p6818 uboot)

    總結下手中開發板的啟動過程,uboot版本為2014.07,參考S5P6818 Application Processor User's Manual。

    首先,我們應該知道為什麼需要uboot,而不是隻知其然,不知其所以然。一言以概之:在我們能夠在作業系統下執行程式之前,所有的努力都是為了能夠讓系統能夠被搬運到記憶體中執行。有了這樣的目的性,我們分析理解起來就簡單多了。

    其實,高階的ARM晶片並不和STM32等Cortex-M系的ARM晶片相差很多,只是主頻更高,核心增多,外設更豐富了。附圖吧:


    IROM:

    和大部分ARM晶片一樣,S5P6818內部也自帶了RAM和ROM,分別為64K和20K。若官方提供下載器的話,我們也可以像STM32一樣,讓程式碼在ROM中執行,RAM中儲存堆疊變數等資訊,但那就大材小用了。顯然,為了能夠跑起linux,光是晶片內的這點空間是完全不夠的,好在高階晶片強就強在能夠帶動大容量的外部RAM和ROM。所以我們一般會將系統存放在外部的SD卡或EMMC中。所以我們此時我們的目的也很明確,檢查外部的儲存中是否包含合法的內容。

    因此,在系統上電後,晶片首先會執行片內20KB ROM中的程式碼,此ROM一般為NOR FLASH。相對於外部儲存經常使用的NAND FLASH,其優勢在於程式碼可以晶片內執行,所以不需要像NAND FLASH一樣將程式碼搬運到記憶體中。內部ROM地址一般即為0地址處,其作用是檢測引腳的配置情況,確定外部儲存器啟動的優先順序,選擇對應的外部儲存進行初始化,再將其中的前56K程式碼搬運到內部RAM中(因內部RAM只有64KB,且ROM自身會用掉一部分RAM),當搬運了512位元組之後會進行Boot Header的檢查,檢視簽名是否為0x4849534E。若是,則為正確程式碼,跳轉到內部RAM即地址0xFFFF0000處執行;否則,選擇下一個外部儲存器進行判斷測試。


    如圖,若想系統首先從SDMMC啟動,則須將RST_CFG[2:0]這三位設定為5,這三位對應於原理圖為SD2,SD1和SD0,從原理圖可以看出我們確實是這樣設定了。


    之後還可以通過SD3和CAM1_D3進行從哪一個SDMMC進行啟動,共有三個埠可選。接下來就是從SD卡中複製程式碼到內部RAM中並跳轉運行了,如圖。


2ndboot:

    現在的狀態是外部儲存器可以讀取使用了,但外部的大容量SDRAM還是不能使用,而我們最終的目的是要將程式碼放入到SDRAM中執行的,這裡講講SRAM和DRAM的區別。S和D分別代表靜態和動態重新整理,SRAM在上電後只要不斷電資料就一直存在,而DRAM需要在上電後過一段時間進行充電重新整理,這樣資料才能夠保持不變,雖然相比SRAN變麻煩了,但價格降低,容量卻提升了。這就是S5P6818內部採用小容量SRAM,外面掛接DDR3這樣的SDRAM的原因,這裡的S為序列的意思。所以現在很明確載入到內部SRAM中程式碼所需要做的事了:1、初始化晶片的記憶體控制器 2、初始化外部SDRAM 3、將SD卡中uboot搬運到記憶體中執行。

    當然除此之外,還有包括設定中斷向量表,設定PLL,設定堆疊,初始化串列埠等,這就是s5p6818提供的2ndboot的內容,燒寫在SD卡的block1~block64共32K位元組的位置。

    以往這部分內容也有是在uboot中進行完成的,在接下來的uboot講解中會有提到,把這部分初始化的內容提煉提煉出來的好處就是減少了uboot的自搬運過程。

uboot:

    2ndboot最後的動作便是將uboot從SD卡的第65塊block搬運到記憶體0x42C00000的位置,接下來便會跳轉到外部SDRAM進行uboot的執行。

    首先檢視生成的uboot連結檔案uboot.lds:


可知此uboot程式程式碼起始的執行位置為arch/arm/cpuslsiap/s5p6818/start.o的_stext處。

/*
 *************************************************************************
 *
 * Exception vectors as described in ARM reference manuals
 *
 * replace arm/lib/vectors.S
 *
 *************************************************************************
 */
	.globl	_stext
_stext:
	b 	reset
	ldr	pc, _undefined_instruction
	ldr	pc, _software_interrupt
	ldr	pc, _prefetch_abort
	ldr	pc, _data_abort
	ldr	pc, _not_used
	ldr	pc, _irq
	ldr	pc, _fiq

_undefined_instruction:	.word undefined_instruction
_software_interrupt:	.word software_interrupt
_prefetch_abort:	.word prefetch_abort
_data_abort:		.word data_abort
_not_used:		.word not_used
_irq:			.word irq
_fiq:			.word fiq

	.balignl 16,0xdeadbeef

首先定義_stext為一個全域性標號,接下來就是一句跳轉,跳轉到reset標號處執行,下面的為異常處理,當系統反生異常時,會跳轉到對應的地址執行,最後一句用一個魔數強制了16位元組對齊。

/*
 *************************************************************************
 *
 * Reset handling
 *
 *************************************************************************
 */

	.globl reset

reset:
	bl	save_boot_params
	/*
	 * set the cpu to SVC32 mode
	 */
	mrs	r0, cpsr
	bic	r0, r0, #0x1f
	orr	r0, r0, #0xd3
	msr	cpsr,r0

	/* the mask ROM code should have PLL and others stable */
#ifndef CONFIG_SKIP_LOWLEVEL_INIT
	bl	cpu_init_cp15
	bl	cpu_init_crit
#endif

    reset首先會將當前的模式設定為SVC32管理模式,接下來是兩個函式cpu_init_cp15和cpu_init_crit,第一個函式設定了ARM中重要的暫存器cp15協處理器,通過這個暫存器我們便可對TLB(快表),I-cache(指令快取),D-cache(資料快取),MMU(記憶體管理單元)等進行使能和失能。而cpu_init_crit則會呼叫lowlevel_init.S中的lowlevel_init函式。以往若沒有2ndboot,則會在此函式中進行pll,外部SDRAM等的初始化。因為這部分我們已經在2ndboot中做了,所以此處只是進行了簡單的cpu型號讀取和設定多核SMP等,之後便返回到start.S繼續執行。

     接下來是一個自搬運的函式,r0指向uboot執行的地址,r1指向需要搬運到的記憶體地址為0x42C00000。若此時uboot執行在flash中則會將uboot搬運到0x42C00000處執行,否則跳過搬運過程,將BSS段中的資料清零,設定棧的位置和uboot中大名鼎鼎的gd位置,之後便會跳轉到common/board_f.c中的board_init_f函式執行。

#ifdef CONFIG_RELOC_TO_TEXT_BASE
relocate_to_text:
	/*
	 * relocate u-boot code on memory to text base
	 * for nexell arm core (add by jhkim)
	 */
	adr	r0, _stext				/* r0 <- current position of code   */
	ldr	r1, TEXT_BASE			/* test if we run from flash or RAM */
	cmp r0, r1              	/* don't reloc during debug         */
	beq clear_bss

	ldr	r2, _bss_start_ofs
	add	r2, r0, r2				/* r2 <- source end address         */

copy_loop_text:
	ldmia	r0!, {r3-r10}		/* copy from source address [r0]    */
	stmia	r1!, {r3-r10}		/* copy to   target address [r1]    */
	cmp	r0, r2					/* until source end addreee [r2]    */
	ble	copy_loop_text

	ldr	r1, TEXT_BASE			/* restart at text base */
	mov pc, r1

設定棧和gd位置:

	ldr	sp, =(CONFIG_SYS_INIT_SP_ADDR)
	bic	sp, sp, #7					/* 8-byte alignment for ABI compliance */
	sub	sp, #GD_SIZE				/* allocate one GD above SP */
	bic	sp, sp, #7					/* 8-byte alignment for ABI compliance */
	mov	r9, sp						/* GD is above SP */
	mov	r0, #0
	bl	board_init_f

board_init_f函式:

    執行前置的(front)初始化工作,若此時全域性變數未能使用,則通過定義區域性變數,在棧中建立並設定gd:

#ifdef CONFIG_SYS_GENERIC_GLOBAL_DATA
	/*
	 * For some archtectures, global data is initialized and used before
	 * calling this function. The data should be preserved. For others,
	 * CONFIG_SYS_GENERIC_GLOBAL_DATA should be defined and use the stack
	 * here to host global data until relocation.
	 */
	gd_t data;

	gd = &data;

	/*
	 * Clear global data before it is accessed at debug print
	 * in initcall_run_list. Otherwise the debug print probably
	 * get the wrong vaule of gd->have_console.
	 */
	zero_global_data();
#endif

    呼叫各個初始化函式,初始化串列埠,輸出uboot,CPU,RAM等資訊,初始化全域性變數區:

static init_fnc_t init_sequence_f[] = {
#ifdef CONFIG_SANDBOX
	setup_ram_buf,
#endif
	setup_mon_len,
	setup_fdt,
	trace_early_init,
#if defined(CONFIG_MPC85xx) || defined(CONFIG_MPC86xx)
	/* TODO: can this go into arch_cpu_init()? */
	probecpu,
#endif
	arch_cpu_init,		/* basic arch cpu dependent setup */
#ifdef CONFIG_X86
	cpu_init_f,		/* TODO([email protected]): remove */
# ifdef CONFIG_OF_CONTROL
	find_fdt,		/* TODO([email protected]): remove */
# endif
#endif
	mark_bootstage,
#ifdef CONFIG_OF_CONTROL
	fdtdec_check_fdt,
#endif
#if defined(CONFIG_BOARD_EARLY_INIT_F)
	board_early_init_f,
#endif
	/* TODO: can any of this go into arch_cpu_init()? */
#if defined(CONFIG_PPC) && !defined(CONFIG_8xx_CPUCLK_DEFAULT)
	get_clocks,		/* get CPU and bus clocks (etc.) */
#if defined(CONFIG_TQM8xxL) && !defined(CONFIG_TQM866M) \
		&& !defined(CONFIG_TQM885D)
	adjust_sdram_tbs_8xx,
#endif
	/* TODO: can we rename this to timer_init()? */
	init_timebase,
#endif
#if defined(CONFIG_ARM) || defined(CONFIG_MIPS)
	timer_init,		/* initialize timer */
#endif
#ifdef CONFIG_SYS_ALLOC_DPRAM
#if !defined(CONFIG_CPM2)
	dpram_init,
#endif
#endif
#if defined(CONFIG_BOARD_POSTCLK_INIT)
	board_postclk_init,
#endif
#ifdef CONFIG_FSL_ESDHC
	get_clocks,
#endif
	env_init,		/* initialize environment */
#if defined(CONFIG_8xx_CPUCLK_DEFAULT)
	/* get CPU and bus clocks according to the environment variable */
	get_clocks_866,
	/* adjust sdram refresh rate according to the new clock */
	sdram_adjust_866,
	init_timebase,
#endif
	init_baud_rate,		/* initialze baudrate settings */
	serial_init,		/* serial communications setup */
	console_init_f,		/* stage 1 init of console */
#ifdef CONFIG_SANDBOX
	sandbox_early_getopt_check,
#endif
#ifdef CONFIG_OF_CONTROL
	fdtdec_prepare_fdt,
#endif
	display_options,	/* say that we are here */
	display_text_info,	/* show debugging info if required */
#if defined(CONFIG_MPC8260)
	prt_8260_rsr,
	prt_8260_clks,
#endif /* CONFIG_MPC8260 */
#if defined(CONFIG_MPC83xx)
	prt_83xx_rsr,
#endif
#ifdef CONFIG_PPC
	checkcpu,
#endif
	print_cpuinfo,		/* display cpu info (and speed) */
#if defined(CONFIG_MPC5xxx)
	prt_mpc5xxx_clks,
#endif /* CONFIG_MPC5xxx */
#if defined(CONFIG_DISPLAY_BOARDINFO)
	checkboard,		/* display board info */
#endif
	INIT_FUNC_WATCHDOG_INIT
#if defined(CONFIG_MISC_INIT_F)
	misc_init_f,
#endif
	INIT_FUNC_WATCHDOG_RESET
#if defined(CONFIG_HARD_I2C) || defined(CONFIG_SYS_I2C)
	init_func_i2c,
#endif
#if defined(CONFIG_HARD_SPI)
	init_func_spi,
#endif
#ifdef CONFIG_X86
	dram_init_f,		/* configure available RAM banks */
	calculate_relocation_address,
#endif
	announce_dram_init,
	/* TODO: unify all these dram functions? */
#ifdef CONFIG_ARM
	dram_init,		/* configure available RAM banks */
#endif
#if defined(CONFIG_MIPS) || defined(CONFIG_PPC)
	init_func_ram,
#endif
#ifdef CONFIG_POST
	post_init_f,
#endif
	INIT_FUNC_WATCHDOG_RESET
#if defined(CONFIG_SYS_DRAM_TEST)
	testdram,
#endif /* CONFIG_SYS_DRAM_TEST */
	INIT_FUNC_WATCHDOG_RESET

#ifdef CONFIG_POST
	init_post,
#endif
	INIT_FUNC_WATCHDOG_RESET
	/*
	 * Now that we have DRAM mapped and working, we can
	 * relocate the code and continue running from DRAM.
	 *
	 * Reserve memory at end of RAM for (top down in that order):
	 *  - area that won't get touched by U-Boot and Linux (optional)
	 *  - kernel log buffer
	 *  - protected RAM
	 *  - LCD framebuffer
	 *  - monitor code
	 *  - board info struct
	 */
	setup_dest_addr,
#if defined(CONFIG_LOGBUFFER) && !defined(CONFIG_ALT_LB_ADDR)
	reserve_logbuffer,
#endif
#ifdef CONFIG_PRAM
	reserve_pram,
#endif
	reserve_round_4k,
#if !(defined(CONFIG_SYS_ICACHE_OFF) && defined(CONFIG_SYS_DCACHE_OFF)) && \
		defined(CONFIG_ARM)
	reserve_mmu,
#endif
#ifdef CONFIG_LCD
	reserve_lcd,
#endif
	reserve_trace,
	/* TODO: Why the dependency on CONFIG_8xx? */
#if defined(CONFIG_VIDEO) && (!defined(CONFIG_PPC) || defined(CONFIG_8xx)) \
		&& !defined(CONFIG_ARM) && !defined(CONFIG_X86)
	reserve_video,
#endif
	reserve_uboot,
#ifndef CONFIG_SPL_BUILD
	reserve_malloc,
	reserve_board,
#endif
	setup_machine,
	reserve_global_data,
	reserve_fdt,
	reserve_stacks,
	setup_dram_config,
	show_dram_config,
#ifdef CONFIG_PPC
	setup_board_part1,
	INIT_FUNC_WATCHDOG_RESET
	setup_board_part2,
#endif
	display_new_sp,
#ifdef CONFIG_SYS_EXTBDINFO
	setup_board_extra,
#endif
	INIT_FUNC_WATCHDOG_RESET
	reloc_fdt,
	setup_reloc,
#if !defined(CONFIG_ARM) && !defined(CONFIG_SANDBOX)
	jump_to_copy,
#endif
	NULL,
};
if (initcall_run_list(init_sequence_f))
		hang();

    當然這裡也會有dram_init對外部DRAM進行初始化,若沒有2ndboot的話,在這裡使用者可以實現dram_init來對外部DRAM初始化,再跳回start.S進行relocation操作,將u-boot自搬運到DRAM中。board_init_f之後又會返回到start.S,呼叫gdt_reset函式,引數為新的棧地址和gd地址,更改gdt中對應的地址內容。接下來便會呼叫到board_init_r進行後置的板級初始化。

board_init_r函式:

    /common/board_r.c進行後置的(rear)板級初始化工作,在運行了之前board_init_f後,全域性變數區,BSS段,堆疊等C的執行環境才建立起來。這裡使用和board_init_f同樣的方法定義一個函式指標陣列,依次遍歷其中的元素,進行各項初始化,包括使能cache,初始化malloc,重新初始化串列埠,使能中斷,外設初始化(LED,LCD),網路初始化等,最終呼叫run_main_loop,進入到uboot的命令列。

init_fnc_t init_sequence_r[] = {
	initr_trace,
	initr_reloc,
	/* TODO: could x86/PPC have this also perhaps? */
#ifdef CONFIG_ARM
	initr_caches,
	board_init,	/* Setup chipselects */
#endif
	/*
	 * TODO: printing of the clock inforamtion of the board is now
	 * implemented as part of bdinfo command. Currently only support for
	 * davinci SOC's is added. Remove this check once all the board
	 * implement this.
	 */
#ifdef CONFIG_CLOCKS
	set_cpu_clk_info, /* Setup clock information */
#endif
	initr_reloc_global_data,
	initr_serial,
	initr_announce,
	INIT_FUNC_WATCHDOG_RESET
#ifdef CONFIG_PPC
	initr_trap,
#endif
#ifdef CONFIG_ADDR_MAP
	initr_addr_map,
#endif
#if defined(CONFIG_BOARD_EARLY_INIT_R)
	board_early_init_r,
#endif
	INIT_FUNC_WATCHDOG_RESET
#ifdef CONFIG_LOGBUFFER
	initr_logbuffer,
#endif
#ifdef CONFIG_POST
	initr_post_backlog,
#endif
	INIT_FUNC_WATCHDOG_RESET
#ifdef CONFIG_SYS_DELAYED_ICACHE
	initr_icache_enable,
#endif
#if defined(CONFIG_SYS_INIT_RAM_LOCK) && defined(CONFIG_E500)
	initr_unlock_ram_in_cache,
#endif
#if defined(CONFIG_PCI) && defined(CONFIG_SYS_EARLY_PCI_INIT)
	/*
	 * Do early PCI configuration _before_ the flash gets initialised,
	 * because PCU ressources are crucial for flash access on some boards.
	 */
	initr_pci,
#endif
#ifdef CONFIG_WINBOND_83C553
	initr_w83c553f,
#endif
	initr_barrier,
	initr_malloc,
	bootstage_relocate,
#ifdef CONFIG_DM
	initr_dm,
#endif
#ifdef CONFIG_ARCH_EARLY_INIT_R
	arch_early_init_r,
#endif
	power_init_board,
#ifndef CONFIG_SYS_NO_FLASH
	initr_flash,
#endif
	INIT_FUNC_WATCHDOG_RESET
#if defined(CONFIG_PPC) || defined(CONFIG_X86)
	/* initialize higher level parts of CPU like time base and timers */
	cpu_init_r,
#endif
#ifdef CONFIG_PPC
	initr_spi,
#endif
#if defined(CONFIG_X86) && defined(CONFIG_SPI)
	init_func_spi,
#endif
#ifdef CONFIG_CMD_NAND
	initr_nand,
#endif
#ifdef CONFIG_CMD_ONENAND
	initr_onenand,
#endif
#ifdef CONFIG_GENERIC_MMC
	initr_mmc,
#endif
#ifdef CONFIG_HAS_DATAFLASH
	initr_dataflash,
#endif
	initr_env,
	INIT_FUNC_WATCHDOG_RESET
	initr_secondary_cpu,
#ifdef CONFIG_SC3
	initr_sc3_read_eeprom,
#endif
#ifdef	CONFIG_HERMES
	initr_hermes,
#endif
#if defined(CONFIG_ID_EEPROM) || defined(CONFIG_SYS_I2C_MAC_OFFSET)
	mac_read_from_eeprom,
#endif
	INIT_FUNC_WATCHDOG_RESET
#if defined(CONFIG_PCI) && !defined(CONFIG_SYS_EARLY_PCI_INIT)
	/*
	 * Do pci configuration
	 */
	initr_pci,
#endif
	stdio_init,
	initr_jumptable,
#ifdef CONFIG_API
	initr_api,
#endif
	console_init_r,		/* fully init console as a device */
#ifdef CONFIG_DISPLAY_BOARDINFO_LATE
	show_model_r,
#endif
#ifdef CONFIG_ARCH_MISC_INIT
	arch_misc_init,		/* miscellaneous arch-dependent init */
#endif
#ifdef CONFIG_MISC_INIT_R
	misc_init_r,		/* miscellaneous platform-dependent init */
#endif
#ifdef CONFIG_HERMES
	initr_hermes_start,
#endif
	INIT_FUNC_WATCHDOG_RESET
#ifdef CONFIG_CMD_KGDB
	initr_kgdb,
#endif
#ifdef CONFIG_X86
	board_early_init_r,
#endif
	interrupt_init,
#if defined(CONFIG_ARM) || defined(CONFIG_x86)
	initr_enable_interrupts,
#endif
#ifdef CONFIG_X86
	timer_init,		/* initialize timer */
#endif
#if defined(CONFIG_STATUS_LED) && defined(STATUS_LED_BOOT)
	initr_status_led,
#endif
	/* PPC has a udelay(20) here dating from 2002. Why? */
#ifdef CONFIG_CMD_NET
	initr_ethaddr,
#endif
#ifdef CONFIG_BOARD_LATE_INIT
	board_late_init,
#endif
#ifdef CONFIG_CMD_SCSI
	INIT_FUNC_WATCHDOG_RESET
	initr_scsi,
#endif
#ifdef CONFIG_CMD_DOC
	INIT_FUNC_WATCHDOG_RESET
	initr_doc,
#endif
#ifdef CONFIG_BITBANGMII
	initr_bbmii,
#endif
#ifdef CONFIG_CMD_NET
	INIT_FUNC_WATCHDOG_RESET
	initr_net,
#endif
#ifdef CONFIG_POST
	initr_post,
#endif
#if defined(CONFIG_CMD_PCMCIA) && !defined(CONFIG_CMD_IDE)
	initr_pcmcia,
#endif
#if defined(CONFIG_CMD_IDE)
	initr_ide,
#endif
#ifdef CONFIG_LAST_STAGE_INIT
	INIT_FUNC_WATCHDOG_RESET
	/*
	 * Some parts can be only initialized if all others (like
	 * Interrupts) are up and running (i.e. the PC-style ISA
	 * keyboard).
	 */
	last_stage_init,
#endif
#ifdef CONFIG_CMD_BEDBUG
	INIT_FUNC_WATCHDOG_RESET
	initr_bedbug,
#endif
#if defined(CONFIG_PRAM) || defined(CONFIG_LOGBUFFER)
	initr_mem,
#endif
#ifdef CONFIG_PS2KBD
	initr_kbd,
#endif
	run_main_loop,
};

    此後若未在bootdelay時間內按下任意鍵,則會呼叫bootm或者後來的booti將核心、檔案系統、裝置樹等拷貝到記憶體中,並執行相應的操作。自此,linux便在記憶體中跑起來了。

總結:

    uboot將程式程式碼分成晶片級和板級,分別進行操作。晶片級最重要的莫過於start.S和lowlevel_init.S,其中包含關鍵的cp15協處理器設定,SDRAM初始化,以後uboot的重定位,這些需要根據特定的晶片進行設定。板級則是更多的和板型相關的部分,通過board_init_f和board_init_r兩個板級的初始化介面,使用者可以實現其中的包括串列埠、SDRAM、LED等外設的初始化,最終將linux拷貝到記憶體中執行。

相關推薦

系統啟動過程基於三星s5p6818 uboot

    總結下手中開發板的啟動過程,uboot版本為2014.07,參考S5P6818 Application Processor User's Manual。    首先,我們應該知道為什麼需要uboot,而不是隻知其然,不知其所以然。一言以概之:在我們能夠在作業系統下執行

linux啟動啟動過程基於MBR

前言: 因為uefi的出現,bios分為legacy bios和uefi bios,下文中,我們不做這個劃分,統一叫做bios。 這篇文章先說基於MBR的啟動過程,然後再說基於比較新的GPT的啟動過程,linux啟動啟動過程(基於GPT)。 第一步:電腦上電,執行bios程式(這段程式是

硬碟分割槽、定址和系統啟動過程

前言筆記: 為了遮蔽複雜的硬體細節,現代的磁碟普遍使用一種叫做LBA(Logical Block Address)的方式,即整個磁碟中所有的扇區從0開始編號,一直到最後一個扇區,這個扇區編號叫做邏輯扇區號。邏輯扇區號拋棄了所有複雜的磁軌、盤面之類的概念。當我們給出一個邏

linux系統啟動過程具體解釋-開機加電後發生了什麽 --linux內核剖析

界面 種類 system pos 放置 nlog 提示 mar .com 本文參考了例如以下文章 深入理解linux啟動過程 mbr (主引導記錄(Master Boot Record)) 電腦從開機加電到操作系統main函數之前執行的過程

為什麽要有uboot?帶你全面分析嵌入式linux系統啟動過程uboot的作用

統一 一次 fail 進入 是我 臺式機 平板 配置 webp 1.為什麽要有uboot 1.1、計算機系統的主要部件 (1)計算機系統就是以CPU為核心來運行的系統。典型的計算機系統有:PC機(臺式機+筆記本)、嵌入式設備(手機、平板電腦、遊戲機)、單片機(家用電器像

Android系統啟動流程解析init進程啟動過程

option 寫入 android change failed miss 通知 target sna 前言 作為“Android框架層”這個大系列中的第一個系列,我們首先要了解的是Android系統啟動流程,在這個流程中會涉及到很多重要的知識點,這個系列我們就來一一講解它們

操作系統學習系統啟動過程

中斷向量 初始化 地址 I/O 向量 錯誤 cpu 系統初始 系統初始化 一、操作系統啟動部分主要執行流程 當PC電源打開後,80x86結構的CPU將自動進入實時模式。並從地址0xFFFF0 (FFFF:0) 開始自動執行程序代碼,這個地址通常是是ROM-BIOS中的地址

為什麼要有uboot?帶你全面分析嵌入式linux系統啟動過程uboot的作用

為什麼要有uboot?帶你全面分析嵌入式linux系統啟動過程中uboot的作用 2017-08-24 18:19作業系統 1.為什麼要有uboot 1.1、計算機系統的主要部件 (1)計算機系統就是以CPU為核心來執行的系統。典型的計算機系統有:PC機(桌上型電腦+筆記

Android系統啟動流程解析init程序啟動過程

前言 作為“Android框架層”這個大系列中的第一個系列,我們首先要了解的是Android系統啟動流程,在這個流程中會涉及到很多重要的知識點,這個系列我們就來一一講解它們,這一篇我們就來學習init程序。 1.init簡介 init程序是An

Android系統啟動過程-uBoot+Kernel+Android

轉載自:http://www.cnblogs.com/pngcui/p/4665106.html 摘要:本文是參考大量網上資源在結合自己檢視原始碼總結出來的,讓自己同時也讓大家加深對Android系統啟動過程有一個更加深入的瞭解!再次強調,本文的大多數功勞應

Android系統啟動流程解析Zygote程序啟動過程

前言 上一篇文章我們分析了init程序的啟動過程,啟動過程中主要做了三件事,其中一件就是建立了Zygote程序,那麼Zygote程序是什麼,它做了哪些事呢?這篇文章會給你這些問題的答案。 1.Zygote簡介 在Android系統中,DVM(D

Android系統啟動流程Launcher啟動過程系統啟動流程

相關文章  Android系統架構與系統原始碼目錄  Android系統啟動流程(一)解析init程序啟動過程  Android系統啟動流程(二)解析Zygote程序啟動過程  Android系統啟動流程(三)解析SyetemServer程序啟動過程 前言

Android系統啟動流程解析SyetemServer程序啟動過程

相關文章  Android系統架構與系統原始碼目錄  Android系統啟動流程(一)解析init程序啟動過程  Android系統啟動流程(二)解析Zygote程序啟動過程 前言 上一篇我們學習了Zygote程序,並且知道Zygote程序啟動了SyetemServ

Buildroot製作根檔案系統過程基於MYD-AM335X開發板

buildroot的功能很強大,可以利用它製作交叉編譯工具鏈、根檔案系統,甚至可以構建多種嵌入式平臺的bootloader、linux。下面以米爾科技的MYD-AM335X平臺為例展示如何利用buildroot製作自己所需的根檔案系統。一、到官網下載原始碼:http://b

Android 的 ramdisk.img、system.img、userdata.img 作用說明,以及UBoot 系統啟動過程

一個分割槽影像檔案,它會在kernel 啟動的時候,以只讀的方式被 mount , 這個檔案中只是包含了 /init 以及一些配置檔案,這個ramdisk 被用來呼叫init,以及把真正的root file system mount 起來。 #其實ramdisk.img的內容就是/out/target/pro

個性化推薦系統原理介紹基於內容過濾/協同過濾/關聯規則/序列模式

信息 來講 行為記錄 鏈接 方程 機器學習 沒有 比較 graph 個性化推薦根據用戶興趣和行為特點,向用戶推薦所需的信息或商品,幫助用戶在海量信息中快速發現真正所需的商品,提高用戶黏性,促進信息點擊和商品銷售。推薦系統是基於海量數據挖掘分析的商業智能平臺,推薦主要基

springboot啟動過程1-初始化

好的 事件監聽 spa 兩個 包括 servlet 實例對象 ice 機制 1 springboot啟動時,[email protected]/* */函數,執行SpringApplication.run(DemoApplication.class, arg

u-boot-201611 啟動過程分析——基於smdk2410

u-bootu-boot-201611 啟動過程分析——基於smdk2410

linux 系統啟動過程分析

系統root 密碼丟失故障 linux啟動順序主板BIOS加電自檢 檢查硬件--> 讀取硬盤引導扇區(MBR)--> 啟動引導程序(grub)--> 選擇系統--> 加載系統內核(kernel shell)--> 啟動系統讀取相應的默認設置(環境變量,運行級別)--

linux系統啟動過程

字符 tty 我們 變量 默認 終端 .... 用戶 關聯 初始化進程 會根據字符終端設備,打開getty程序,並關聯在字符終端設備上tty0上 getty打開login 進程 login會讀取用戶信息,查詢出登陸shell 登陸成功,啟動shell,開始讀取shell啟動