我试图从 U-boot 对 SPI Flash NVRAM (S25FL064A) 进行编程,但它不允许写入:
tftp 0x80000100 nvram.bin
cp.b 0x80000100 0x007b0000 0x00050000
cp.b 命令后没有显示错误,只是不允许写入。可能是什么问题?闪存结构,来自 U-Boot 1.2.0 printenv:
Serial Flash [Bus:0 CS:0] : s25fl064a 8192KB, 128 sectors each 64KB
7 cmdlinepart partitions found on MTD device spansion
partitions[0] = {.name = U-Boot, .offset = 0x00000000,.size = 0x00020000 (128K) }
partitions[1] = {.name = env1, .offset = 0x00020000,.size = 0x00010000 (64K) }
partitions[2] = {.name = env2, .offset = 0x00030000,.size = 0x00010000 (64K) }
partitions[3] = {.name = firmware_EH, .offset = 0x004a0000,.size = 0x002d0000 (2880K) }
partitions[4] = {.name = nvram, .offset = 0x007b0000,.size = 0x00050000 (320K) }
partitions[5] = {.name = UBFI1, .offset = 0x00040000,.size = 0x003b0000 (3776K) }
partitions[6] = {.name = UBFI2, .offset = 0x003f0000,.size = 0x003b0000 (3776K) }
Creating 7 MTD partitions on "spansion":
0x00000000-0x00020000 : "U-Boot"
0x00020000-0x00030000 : "env1"
0x00030000-0x00040000 : "env2"
0x004a0000-0x00770000 : "firmware_EH"
0x007b0000-0x00800000 : "nvram"
0x00040000-0x003f0000 : "UBFI1"
0x003f0000-0x007a0000 : "UBFI2"