вот что-то такое происходит
Код
[NiosII EDS]$ nios2-flash-programmer --base=0 --debug --erase-all
Using cable "USB-Blaster [USB-1]", device 1, instance 0x00
Resetting and pausing target processor: OK
Found CFI table in 16 bit mode
Raw CFI query table read from device:
0: 20 00 BB 88 00 00 FF FF FF FF FF FF FF FF FF FF ...............
10: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF ................
20: 51 00 52 00 59 00 03 00 00 00 35 00 00 00 00 00 Q.R.Y.....5.....
30: 00 00 00 00 00 00 27 00 36 00 B4 00 C6 00 04 00 ......'.6.......
40: 04 00 0A 00 00 00 05 00 05 00 03 00 00 00 16 00 ................
CFI query table read from device:
10: 51 52 59 03 00 35 00 00 00 00 00 27 36 B4 C6 04 QRY..5.....'6...
20: 04 0A 00 05 05 03 00 16 01 00 03 00 02 07 00 20 ...............
30: 00 3E 00 00 01 .>...
CFI extended table read from device:
0: 50 52 49 31 30 66 00 00 00 01 03 00 30 C0 01 80 PRI10f......0...
10: 00 03 03 FF FF FF FF FF FF FF FF FF FF FF FF FF ................
Read autoselect code 0020-88BB (in 16 bit mode)
No CFI override data for [FLASH-0020-88BB]
Target timeout loop runs 1504100 times/s
Timeout set to 771 loops
Device size is 4MByte
Erase regions are:
offset 0: 8 x 8K
offset 10000: 63 x 64K
Device supports Intel style programming algorithm
Multi-byte programming with 8 byte buffer
Sector erase timeout is 8s
Word program timeout is 512us
Buffer program timeout is 512us
: Checksumming existing contents
00000000 : Already erased
00002000 : Needs erasing
00004000 : Needs erasing
00006000 : Needs erasing
00008000 : Needs erasing
0000A000 : Needs erasing
0000C000 : Needs erasing
0000E000 : Needs erasing
00010000 : Needs erasing
00020000 : Needs erasing
00030000 : Already erased
......
Erase failed at offset 2000
Leaving target processor paused
Using cable "USB-Blaster [USB-1]", device 1, instance 0x00
Resetting and pausing target processor: OK
Found CFI table in 16 bit mode
Raw CFI query table read from device:
0: 20 00 BB 88 00 00 FF FF FF FF FF FF FF FF FF FF ...............
10: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF ................
20: 51 00 52 00 59 00 03 00 00 00 35 00 00 00 00 00 Q.R.Y.....5.....
30: 00 00 00 00 00 00 27 00 36 00 B4 00 C6 00 04 00 ......'.6.......
40: 04 00 0A 00 00 00 05 00 05 00 03 00 00 00 16 00 ................
CFI query table read from device:
10: 51 52 59 03 00 35 00 00 00 00 00 27 36 B4 C6 04 QRY..5.....'6...
20: 04 0A 00 05 05 03 00 16 01 00 03 00 02 07 00 20 ...............
30: 00 3E 00 00 01 .>...
CFI extended table read from device:
0: 50 52 49 31 30 66 00 00 00 01 03 00 30 C0 01 80 PRI10f......0...
10: 00 03 03 FF FF FF FF FF FF FF FF FF FF FF FF FF ................
Read autoselect code 0020-88BB (in 16 bit mode)
No CFI override data for [FLASH-0020-88BB]
Target timeout loop runs 1504100 times/s
Timeout set to 771 loops
Device size is 4MByte
Erase regions are:
offset 0: 8 x 8K
offset 10000: 63 x 64K
Device supports Intel style programming algorithm
Multi-byte programming with 8 byte buffer
Sector erase timeout is 8s
Word program timeout is 512us
Buffer program timeout is 512us
: Checksumming existing contents
00000000 : Already erased
00002000 : Needs erasing
00004000 : Needs erasing
00006000 : Needs erasing
00008000 : Needs erasing
0000A000 : Needs erasing
0000C000 : Needs erasing
0000E000 : Needs erasing
00010000 : Needs erasing
00020000 : Needs erasing
00030000 : Already erased
......
Erase failed at offset 2000
Leaving target processor paused
в 0 сектор пишет правильно
ну и во втором случае валится (я до опции --debug тогда не добрался, но тоже не сразу валится)