U-Boot移植(13)Warning - bad CRC or NAND, using default environment
接上面(5)在串口终端出现如下:
U-Boot 1.1.6 (Nov 25 2009 - 22:15:51)
DRAM: 64 MB Flash: 1 MB NAND: 64 MiB *** Warning - bad CRC, using default environment
还存在警告,这个警告不是错误,而是新的环境变量起作用,
只要在OPENJTAG但是我在下面输入saveenv、reset之后还存在警告。。。
网友henry.li说:估计是你的环境变量保存的位置不正确,环境变量实际上没有保存。 我想想还是很有道理的,否则不会保存不上。。。。也就是没有保存到nandflash上去。。。于是再利用韦东山的补丁u-boot-1.1.6_OpenJTAG_env_on_nand.patch又打上去。。。这个补丁就可保存变量到nandflash上去,这下再试下。。。第一次上电,在dnw下显示如下:
U-Boot 1.1.6 (Nov 27 2009 - 19:33:59)
DRAM: 64 MB
Flash: 0 kB
NAND: 64 MiB
*** Warning - bad CRC or NAND, using default environment
In: serial
Out: serial
Err: serial
UPLLVal [M:28h,P:1h,S:2h]
MPLLVal [M:5ch,P:4h,S:0h]
CLKDIVN:3h
+---------------------------------------------+
| S3C2440A USB Downloader ver R0.03 2004 Jan |
+---------------------------------------------+
USB: IN_ENDPOINT:1 OUT_ENDPOINT:3
FORMAT: +
NOTE: Power off/on or press the reset button for 1 sec
in order to get a valid USB device address.
Hit any key to stop autoboot: 0
Booting Linux ...
NAND read: device 0 offset 0x60000, size 0x200000
Reading data from 0x60000 -- 0ete.
Reading data from 0x65000 -- 1ete.
Reading data from 0x6a200 -- 2ete.
Reading data from 0x6f400 -- 3ete.
Reading data from 0x74600 -- 4ete.
Reading data from 0x79800 -- 5ete.
Reading data from 0x7ea00 -- 6ete.
Reading data from 0x83c00 -- 7ete.
Reading data from 0x88e00 -- 8ete.
Reading data from 0x8e000 -- 9ete.
Reading data from 0x93200 -- 10ete.
Reading data from 0x98400 -- 11ete.
Reading data from 0x9d600 -- 12ete.
Reading data from 0xa2800 -- 13ete.
Reading data from 0xa7a00 -- 14ete.
Reading data from 0xacc00 -- 15ete.
Reading data from 0xb1e00 -- 16ete.
Reading data from 0xb7000 -- 17ete.
Reading data from 0xbc200 -- 18ete.
Reading data from 0xc1400 -- 19ete.
Reading data from 0xc6600 -- 20ete.
Reading data from 0xcb800 -- 21ete.
Reading data from 0xd0a00 -- 22ete.
Reading data from 0xd5c00 -- 23ete.
Reading data from 0xdae00 -- 24ete.
Reading data from 0xdfe00 -- 25ete.
Reading data from 0xe5000 -- 26ete.
Reading data from 0xea200 -- 27ete.
Reading data from 0xef400 -- 28ete.
Reading data from 0xf4600 -- 29ete.
Reading data from 0xf9800 -- 30ete.
Reading data from 0xfea00 -- 31ete.
Reading data from 0x103c00 -- 32lete.
Reading data from 0x108e00 -- 33lete.
Reading data from 0x10e000 -- 34lete.
Reading data from 0x113200 -- 35lete.
Reading data from 0x118400 -- 36lete.
Reading data from 0x11d600 -- 37lete.
Reading data from 0x122800 -- 38lete.
Reading data from 0x127a00 -- 39lete.
Reading data from 0x12cc00 -- 40lete.
Reading data from 0x131e00 -- 41lete.
Reading data from 0x137000 -- 42lete.
Reading data from 0x13c200 -- 43lete.
Reading data from 0x141400 -- 44lete.
Reading data from 0x146600 -- 45lete.
Reading data from 0x14b800 -- 46lete.
Reading data from 0x150a00 -- 47lete.
Reading data from 0x155c00 -- 48lete.
Reading data from 0x15ae00 -- 49lete.
Reading data from 0x15fe00 -- 50lete.
Reading data from 0x165000 -- 51lete.
Reading data from 0x16a200 -- 52lete.
Reading data from 0x16f400 -- 53lete.
Reading data from 0x174600 -- 54lete.
Reading data from 0x179800 -- 55lete.
Reading data from 0x17ea00 -- 56lete.
Reading data from 0x183c00 -- 57lete.
Reading data from 0x188e00 -- 58lete.
Reading data from 0x18e000 -- 59lete.
Reading data from 0x193200 -- 60lete.
Reading data from 0x198400 -- 61lete.
Reading data from 0x19d600 -- 62lete.
Reading data from 0x1a2800 -- 63lete.
Reading data from 0x1a7a00 -- 64lete.
Reading data from 0x1acc00 -- 65lete.
Reading data from 0x1b1e00 -- 66lete.
Reading data from 0x1b7000 -- 67lete.
Reading data from 0x1bc200 -- 68lete.
Reading data from 0x1c1400 -- 69lete.
Reading data from 0x1c6600 -- 70lete.
Reading data from 0x1cb800 -- 71lete.
Reading data from 0x1d0a00 -- 72lete.
Reading data from 0x1d5c00 -- 73lete.
Reading data from 0x1dae00 -- 74lete.
Reading data from 0x1dfe00 -- 75lete.
Reading data from 0x1e5000 -- 76lete.
Reading data from 0x1ea200 -- 77lete.
Reading data from 0x1ef400 -- 78lete.
Reading data from 0x1f4600 -- 79lete.
Reading data from 0x1f9800 -- 80lete.
Reading data from 0x1fea00 -- 81lete.
Reading data from 0x203c00 -- 82lete.
Reading data from 0x208e00 -- 83lete.
Reading data from 0x20e000 -- 84lete.
Reading data from 0x213200 -- 85lete.
Reading data from 0x218400 -- 86lete.
Reading data from 0x21d600 -- 87lete.
Reading data from 0x222800 -- 88lete.
Reading data from 0x227a00 -- 89lete.
Reading data from 0x22cc00 -- 90lete.
Reading data from 0x231e00 -- 91lete.
Reading data from 0x237000 -- 92lete.
Reading data from 0x23c200 -- 93lete.
Reading data from 0x241400 -- 94lete.
Reading data from 0x246600 -- 95lete.
Reading data from 0x24b800 -- 96lete.
Reading data from 0x250a00 -- 97lete.
Reading data from 0x255c00 -- 98lete.
Reading data from 0x25ae00 -- 99lete.
Reading data from 0x25fe00 -- 100lete.
2097152 bytes read: OK
## Booting image at 30007fc0 ...
Bad Magic Number
##### 100ask Bootloader for OpenJTAG #####
[n] Download u-boot to Nand Flash
[k] Download Linux kernel uImage
[j] Download root_jffs2 image
[y] Download root_yaffs image
[d] Download to SDRAM & Run
[z] Download zImage into RAM
[g] Boot linux from RAM
[f] Format the Nand Flash
[s] Set the boot parameters
[b] Boot the system
[q] Quit from menu
Enter your selection: q
OpenJTAG> saveenv
Saving Environment to NAND...
Erasing Nand...Writing to Nand... done
接着再reset,显示如下:
OpenJTAG> reset
U-Boot 1.1.6 (Nov 27 2009 - 19:33:59)
DRAM: 64 MB
Flash: 0 kB
NAND: 64 MiB
In: serial
Out: serial
Err: serial
UPLLVal [M:28h,P:1h,S:2h]
MPLLVal [M:5ch,P:4h,S:0h]
CLKDIVN:3h
+---------------------------------------------+
| S3C2440A USB Downloader ver R0.03 2004 Jan |
+---------------------------------------------+
USB: IN_ENDPOINT:1 OUT_ENDPOINT:3
FORMAT: +
NOTE: Power off/on or press the reset button for 1 sec
in order to get a valid USB device address.
Hit any key to stop autoboot: 0
Booting Linux ...
NAND read: device 0 offset 0x60000, size 0x200000
Reading data from 0x60000 -- 0ete.
Reading data from 0x65000 -- 1ete.
Reading data from 0x6a200 -- 2ete.
Reading data from 0x6f400 -- 3ete.
Reading data from 0x74600 -- 4ete.
Reading data from 0x79800 -- 5ete.
Reading data from 0x7ea00 -- 6ete.
Reading data from 0x83c00 -- 7ete.
Reading data from 0x88e00 -- 8ete.
Reading data from 0x8e000 -- 9ete.
Reading data from 0x93200 -- 10ete.
Reading data from 0x98400 -- 11ete.
Reading data from 0x9d600 -- 12ete.
Reading data from 0xa2800 -- 13ete.
Reading data from 0xa7a00 -- 14ete.
Reading data from 0xacc00 -- 15ete.
Reading data from 0xb1e00 -- 16ete.
Reading data from 0xb7000 -- 17ete.
Reading data from 0xbc200 -- 18ete.
Reading data from 0xc1400 -- 19ete.
Reading data from 0xc6600 -- 20ete.
Reading data from 0xcb800 -- 21ete.
Reading data from 0xd0a00 -- 22ete.
Reading data from 0xd5c00 -- 23
Reading data from 0xdae00 -- 24ete.
Reading data from 0xdfe00 -- 25
Reading data from 0xe5000 -- 26ete.
Reading data from 0xea200 -- 27
Reading data from 0xef400 -- 28
Reading data from 0xf4600 -- 29ete.
Reading data from 0xf9800 -- 30ete.
Reading data from 0xfea00 -- 31ete.
Reading data from 0x103c00 -- 32lete.
Reading data from 0x108e00 -- 33lete.
Reading data from 0x10e000 -- 34
Reading data from 0x113200 -- 35lete.
Reading data from 0x118400 -- 36lete.
Reading data from 0x11d600 -- 37lete.
Reading data from 0x122800 -- 38lete.
Reading data from 0x127a00 -- 39lete.
Reading data from 0x12cc00 -- 40lete.
Reading data from 0x131e00 -- 41lete.
Reading data from 0x137000 -- 42lete.
Reading data from 0x13c200 -- 43lete.
Reading data from 0x141400 -- 44lete.
Reading data from 0x146600 -- 45lete.
Reading data from 0x14b800 -- 46lete.
Reading data from 0x150a00 -- 47lete.
Reading data from 0x155c00 -- 48
Reading data from 0x15ae00 -- 49lete.
Reading data from 0x15fe00 -- 50lete.
Reading data from 0x165000 -- 51lete.
Reading data from 0x16a200 -- 52lete.
Reading data from 0x16f400 -- 53lete.
Reading data from 0x174600 -- 54lete.
Reading data from 0x179800 -- 55lete.
Reading data from 0x17ea00 -- 56lete.
Reading data from 0x183c00 -- 57lete.
Reading data from 0x188e00 -- 58lete.
Reading data from 0x18e000 -- 59lete.
Reading data from 0x193200 -- 60lete.
Reading data from 0x198400 -- 61lete.
Reading data from 0x19d600 -- 62lete.
Reading data from 0x1a2800 -- 63lete.
Reading data from 0x1a7a00 -- 64
Reading data from 0x1acc00 -- 65
Reading data from 0x1b1e00 -- 66lete.
Reading data from 0x1b7000 -- 67lete.
Reading data from 0x1bc200 -- 68lete.
Reading data from 0x1c1400 -- 69lete.
Reading data from 0x1c6600 -- 70lete.
Reading data from 0x1cb800 -- 71lete.
Reading data from 0x1d0a00 -- 72lete.
Reading data from 0x1d5c00 -- 73lete.