明远智睿技术论坛

 找回密码
 立即注册
搜索
查看: 2814|回复: 1

imx6 4.1内核的uboot无法更新fdt,image,uboot

[复制链接]

8

主题

10

帖子

98

积分

注册会员

Rank: 2

积分
98
发表于 2018-8-22 13:59:25 | 显示全部楼层 |阅读模式
uboot 版本:U-Boot 2016.03-svn203 (Jul 31 2018 - 14:07:04 +0800)
通过pri查看部分信息如下:

update_fdt=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_dtb}; fatwrite mmc ${mmcdev}{mmcpart} ${loadaddr_def} ${file_dtb} 0x80000 else echo FAIL: Update device tree fail ...; fi;
update_kern=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_image}; fatwrite mmc ${mmcdev}{mmcpart} ${loadaddr_def} ${file_image} 0x600000 else echo FAIL: Update kernel fail ...; fi;
update_uboot=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_uboot}; then sf probe 0:1; sf erase 0 0x200000; sf write ${loadaddr_def} 0x400 0x80000; else echo FAIL: Update u-boot fail ...; fi;

run update_fdt 和 run update_kern 有语法错误无法运行
run update_uboot 无法成功更新uboot

试了几个svn版本都是这个情况

完整信息如下:
U-Boot 2016.03-svn203 (Jul 31 2018 - 14:07:04 +0800)
CPU:   Freescale i.MX6Q rev1.5 at 792MHz
CPU:   Industrial temperature grade (-40C to 105C) at 46C
Reset cause: POR
Board: MYZR i.MX6 Evaluation Kit
Model: MY-IMX6-EK200-6Q-1G
I2C:   ready
DRAM:  1 GiB
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
SF: Detected SST25VF016B with page size 256 Bytes, erase size 64 KiB, total 2 MiB
*** Warning - bad CRC, using default environment
No panel detected: default to MY-LVDS-WSVGA
Display: MY-LVDS-WSVGA (1024x600)
In:    serial
Out:   serial
Err:   serial
Net:   FEC [PRIME]
Normal Boot
Hit any key to stop autoboot:  0
=>
=>
=>
=> pri
baudrate=115200
bootargs_mfg=setenv bootargs console=ttymxc0,115200 rdinit=/linuxrc g_mass_storage.stall=0 g_mass_storage.removable=1 g_mass_storage.file=/fat g_mass_storage.ro=1 g_mass_storage.idVendor=0x066F g_mass_storage.idProduct=0x37FF g_mass_storage.iSerialNumber="" enable_wait_mode=off
bootargs_mmc=run set_disp; setenv bootargs console=${console},${baudrate} ${smp} root=${mmcroot} ${bootargs_disp}
bootargs_net=setenv bootargs console=${console},${baudrate} ${smp} root=/dev/nfs ip=dhcp nfsroot=${serverip}{nfsroot},v3,tcp
bootcmd=mmc dev ${mmcdev}; if mmc rescan; then run bootcmd_mmc; else run bootcmd_tftp; fi;
bootcmd_mfg=run bootargs_mfg; bootz ${loadaddr} ${initrd_addr} ${fdt_addr};
bootcmd_mmc=echo Booting from mmc ...; run bootargs_mmc; if run loadfdt; then if run loadimage; then bootz ${loadaddr} - ${fdt_addr}; else echo WARN: Cannot load zImage from mmc; fi; else echo WARN: Cannot load fdt from mmc; fi;
bootcmd_net=echo Booting from net ...; run bootargs_net; run set_net_cmd; if ${get_cmd} ${fdt_addr} ${file_dtb}; then if ${get_cmd} ${loadaddr} ${file_image}; then bootz ${loadaddr} - ${fdt_addr}; else echo WARN: Cannot load zImage from tftp; fi; else echo WARN: Cannot load fdt from tftp; fi;
bootcmd_tftp=echo Booting from tftp ...; run bootargs_mmc; run set_net_cmd; if ${get_cmd} ${fdt_addr} ${file_dtb}; then if ${get_cmd} ${loadaddr} ${file_image}; then bootz ${loadaddr} - ${fdt_addr}; else echo WARN: Cannot load zImage from tftp; fi; else echo WARN: Cannot load fdt from tftp; fi;
bootdelay=1
console=ttymxc0
disp_fb0_hdmi=video=mxcfb0:dev=hdmi,1920x1080M@60,if=RGB24
disp_fb0_lcd=video=mxcfb0:dev=lcd,SEIKO-WVGA,if=RGB24
disp_fb0_lvds0=video=mxcfb0:dev=ldb,if=RGB666 ldb=sin0
disp_fb0_lvds1=video=mxcfb0:dev=ldb,if=RGB666 ldb=sin1
disp_fb1_hdmi=video=mxcfb1:dev=hdmi,1920x1080M@60,if=RGB24
disp_fb1_lcd=video=mxcfb1:dev=lcd,SEIKO-WVGA,if=RGB24
disp_fb1_lvds0=video=mxcfb1:dev=ldb,if=RGB666 ldb=sin0
disp_fb1_lvds1=video=mxcfb1:dev=ldb,if=RGB666 ldb=sin1
disp_lvds_sync=video=mxcfb0:dev=ldb,if=RGB666 ldb=dul1
display=
ethact=FEC
ethaddr=1c:87:76:51:c0:6e
ethprime=FEC
fdt_addr=0x18000000
fdt_high=0xffffffff
file_dtb=myimx6ek200-6q.dtb
file_image=zImage-myimx6a9
file_uboot=uboot-myimx6ek200-6q.imx
initrd_addr=0x12C00000
initrd_high=0xffffffff
ip_dyn=no
ipaddr=192.168.137.81
loadaddr=0x12000000
loadfdt=fatload mmc ${mmcdev}{mmcpart} ${fdt_addr} ${file_dtb}
loadimage=fatload mmc ${mmcdev}{mmcpart} ${loadaddr} ${file_image}
mmcautodetect=yes
mmcdev=1
mmcpart=1
mmcroot=/dev/mmcblk3p2 rootwait rw
serverip=192.168.137.99
set_disp=setenv bootargs_disp ${display}
set_net_cmd=if test ${ip_dyn} = yes; then setenv get_cmd dhcp; else setenv get_cmd tftpboot; fi;
update_fdt=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_dtb}; fatwrite mmc ${mmcdev}{mmcpart} ${loadaddr_def} ${file_dtb} 0x80000 else echo FAIL: Update device tree fail ...; fi;
update_kern=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_image}; fatwrite mmc ${mmcdev}{mmcpart} ${loadaddr_def} ${file_image} 0x600000 else echo FAIL: Update kernel fail ...; fi;
update_uboot=run set_net_cmd; if ${get_cmd} ${loadaddr_def} ${file_uboot}; then sf probe 0:1; sf erase 0 0x200000; sf write ${loadaddr_def} 0x400 0x80000; else echo FAIL: Update u-boot fail ...; fi;
Environment size: 3383/8188 bytes
=> run set_net_cmd
=> setenv ipaddr 10.10.100.123
=> setenv serverip 10.10.100.200
=> saveenc
Unknown command 'saveenc' - try 'help'
=> saveenv
Saving Environment to SPI Flash...
SF: Detected SST25VF016B with page size 256 Bytes, erase size 64 KiB, total 2 MiB
Erasing SPI flash...Writing to SPI flash...done
=> run update_uboot
Using FEC device
TFTP from server 10.10.100.200; our IP address is 10.10.100.123
Filename 'uboot-myimx6ek200-6q.imx'.
Load address: 0x12000000
Loading: #############################
  1.4 MiB/s
done
Bytes transferred = 420864 (66c00 hex)
SF: Detected SST25VF016B with page size 256 Bytes, erase size 64 KiB, total 2 MiB
SF: 2097152 bytes @ 0x0 Erased: OK
device 0 offset 0x80000, size 0x180000
data abort
pc : [<4ff74898>]    lr : [<4ff74a64>]
reloc pc : [<1782b898>]    lr : [<1782ba64>]
sp : 4ef469f8  ip : 00104002  fp : 00000000
r10: 00104000  r9 : 4ef46eb8  r8 : 00000002
r7 : 00000002  r6 : 00000000  r5 : 02008000  r4 : 00000010
r3 : 00000002  r2 : 00104000  r1 : 00000000  r0 : 4f1bc708
Flags: Nzcv  IRQs off  FIQs off  Mode SVC_32
Resetting CPU ...
resetting ...


回复

使用道具 举报

4

主题

6

帖子

46

积分

新手上路

Rank: 1

积分
46
发表于 2018-9-17 13:53:57 | 显示全部楼层
我也遇到这样的问题,后来发现是脚本语法有误,需要if 与then 成对使用参照 update_u-boot
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|明远智睿  

GMT+8, 2024-12-12 09:42 , Processed in 0.061919 second(s), 22 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表