Linux-world-2012-January->16(mini2440 uboot201103 系统移植)->2

来源:互联网 发布:udp socket编程 编辑:程序博客网 时间:2024/06/01 16:50

U-Boot参数设置 .

1)网络启动参数设置

setenv serverip 192.168.7.103                  // Ubuntu的ip地址 

setenv ipaddr  192.168.7.163                    // 开发板ip地址

setenv gatewayip 192.168.7.1                  // 设置网关

setenv ethaddr 08:00:3e:26:0a:03            // 设置MAC地址

1、setenv bootcmd tftp 30800000 uImage \; bootm           //   设置倒计时后的第一条命令  (二选一

                                                                                                          //   (cp u-boot-2010.03/tools/mkimge /usr/bin/,用来生成uImage,注意权限)

2、setenv bootcmd tftp 33000000 zImage \; go 33000000

setenv bootargs console=ttySAC0,115200 init=/linuxrc root=/dev/nfs nfsroot=192.168.7.103:/opt/filesystem ip=192.168.7.163           // uboot传给内核的参数(关键)


/******************************************************************/

nand分区文件所在:

u-boot:include/configs/fs2410.h

kernel:/linux-2.6.35/arch/arm/plat-s3c24xx/ common-smdk.c

/******************************************************************/



2)烧写内核

tftp 33000000uImage

nand erase 100000 400000

nand write 33000000 100000 400000

setenv bootcmd nand read 33000000 100000400000 \; bootm 33000000



3)烧写 jffs2 文件系统

tftp 30008000 filesystem.jffs2

nand erase 500000 800000

nand write 30008000 400000实际大小

setenv bootargs root=/dev/mtdblock2 init=/linuxrc rootfstype=jffs2 rw console=ttySAC0,115200



4)烧写 yaffs2 文件系统

tftp 30008000 filesystem.yaffs2

nand erase 500000 800000

nand write.yaffs2 30008000 500000实际大小

setenv bootargs root=/dev/mtdblock2 init=/linuxrc rootfstype=yaffs2 rw console=ttySAC0,115200