[嵌入式]移植到純淨版本的uboot1.1.6過程–OK6410

來源:互聯網
上載者:User

學習OK6410時發現uboot1.1.6_256M中的檔案與uboot1.1.6源中的檔案配置變化很大,所以,我這裡自己在uboot1.1.6中添加,並且己經成功。

1. 主Makefile檔案

.........................
1.1 lib支援庫
在LIBS += drivers/nand_legacy/libnand_legacy.a下面
# add to support onenand. by scsuh
LIBS += drivers/onenand/libonenand.a
ifeq ($(CPU),mpc83xx)
LIBS += drivers/qe/qe.a
endif

1.2 交叉編譯工具
CROSS_COMPILE=/usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-
 
1.3 配置環境
smdk6410_config :unconfig
@$(MKCONFIG) $(@:_config=) arm s3c64xx smdk6410 samsung s3c6410

  可以得到ARCH=arm;CPU=s3c64xx;BOARD=smdk6410;vendor=samsung;soc=s3c6410;

1.4 mkconfig添加
if [ "$3" = "s3c64xx" ] ; then
rm -f regs.h
ln -s $6.h regs.h
rm -f asm-$2/arch
ln -s arch-$3 asm-$2/arch
fi

2.添加檔案
board/samsung/smdk6410/*;
include/configs/smdk6410.h; ->
cpu/s3c64xx/*;
include/s3c6410.h-->regs.h(linux shell: ln -s $6.h regs.h)
include/s3c64x0.h
include/s3c6400.h

include/asm-arm/arch-s3c64xx/*; ->通過mkconfig會建立連結檔案arch

修改檔案

include/linux/mtd/*;
include/linux/mmc/*;
include/movi.h
include/div64.h
drivers/mtd/*;
drivers/nand/*;
drivers/onenand/*;
drivers/qe/*;
common/cmd_nand.c
common/cmd_date.c
rtc/s3c64xx_rtc.c
lib_generic/div64.c

4.編譯

make smdk6410_config

make CROSS_COMPILE=/usr/local/arm/4.2.2-eabi/usr/bin/arm-linux-

附:有可能出現: undefined reference to 'raise'

就替換lib_arm/*;

5.啟動kernel
替換common檔案 12個新增
cmd_movi.c
cmd_onenand.c
cmd_usbd.c
cyclon2.c
env_movi.c
env_onenand.c
....
還須修改cmd_bootm.c

---------更新時間 2013-3-6

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.