Openmoko gta03 & smartq5 initi6410 bootloader Qi reading and analysis of enterprise-level bootloader (I)
(For more information, see the source. It cannot be used for commercial purposes)
(Welcome:Www.embed-training.com
/)
As openmoko & 0 xdroid's open-source man jserv said: the use of Qi is not limited to the openmoko freerunner hardware platform. The smart device changes the original openmoko gta03 bootloader code to its smartq series. The advantage is that it is used to burn the file system.
Qi wiki:
Http://wiki.openmoko.org/wiki/Qi
Smartq5 Qi source code tree:
Tommy @ tommy-desktop:/work2/project_study/qi-smartq-20090612 $ tree
.
| -- Makefile
| -- Readme
| -- Config. mk
| -- Gta02-qi.ocd
| -- Image
| -- Qi-s3c6410-20090612-SmartQ
| -- Qi-s3c6410-20090612-SmartQ.dis
| -- Qi-s3c6410-20090612-SmartQ.udfu
| '-- Start_qi_all-s3c6410
| -- Include
| -- Ext2.h
| -- Fat. h
| -- I2c-bitbang-s3c6410.h
| -- I2c-bitbang.h
| -- Image. h
| -- Qi-ctype.h
| -- QI. h
| -- 89c6410. h
| -- Serial-s3c64xx.h
| -- Setup. h
| -- Smdk6410.h
| '-- Utils. h
| -- Install-smartq-qi.sh
| -- SRC
| -- CPU
| '-- 89c6410
| -- I2c-bitbang-s3c6410.c
| -- I2c-bitbang-s3c6410.o
| -- QI. LDS
| -- Serial-s3c64xx.c
| -- Serial-s3c64xx.o
| -- Smartq. c
| -- Smartq. h
| -- Smartq. o
| -- Start. s
| -- Start. o
| -- Start_qi.c
| '-- Start_qi.o
| -- Crc32.c
| -- Crc32.o
| -- Ctype. c
| -- Ctype. o
| -- FS
| -- Dev. c
| -- Dev. o
| -- Ext2.c
| '-- Ext2.o
| -- Phase2.c
| -- Phase2.o
| -- Start. s
| -- Utils-phase2.c
| -- Utils-phase2.o
| -- Utils. c
| '-- Utils. o
'-- Tools
| -- Makefile
| -- Mkudfu
| -- Mkudfu. c
'-- Usb_dfu_trailer.h
7 directories, 53 files
Tommy @ tommy-desktop:/work2/project_study/qi-smartq-20090612 $
Config. mk is as follows, mainly used to set environment variables required for makefile compilation.
#
# Include the make variables (CC, Etc ...)
#
CPU = cloud6410
Cross_path =/usr/local/poky/Eabi-glibc/ARM
Cross_compile =$ {cross_path}/bin/ARM-poky-Linux-gnueabi-
Compiler_lib_path_pre =$ {cross_path}/lib/GCC/ARM-poky-Linux-gnueabi
Compiler_lib_path =$ {compiler_lib_path_pre}/'ls $ {compiler_lib_path_pre }'
As = $ (cross_compile)
LD = $ (cross_compile) LD
Cc = $ (cross_compile) GCC
Objcopy = $ (cross_compile) objcopy
Objdump = $ (cross_compile) objdump
Hostcc = gcc
# We need the mkudfu tool from U-boot build
# Mkudfu = ../uboot/U-boot/tools/mkudfu
Export cross_compile ad ld cc objcopy objdump mkudfu
The next section analyzes the main programs one by one.