[U-Boot] ubi part failing on NAND
Jeff Angielski
jeff at theptrgroup.com
Thu Dec 17 22:09:03 CET 2009
The "ubi part" command is failing for me on my PowerPC 85xx board. I am
not trying to do anything special, just create the partitions and
volumes so that I can try writing an ubi.img. It spits out enough
information that it looks like it did work but it prints out an error
nonetheless.
And of course there is the long standing issue of the reported MTD
number not making any sense. But previous posts have discounted this as
an issue.
Here is the snippet of the error:
UBI error: ubi_init: cannot attach mtd2
UBI: mtd2 is detached from ubi0
UBI error: ubi_init: UBI error: cannot initialize UBI, error -17
UBI init error -17
Here is a cleaned up version of the session log:
=> mtdparts
device nor0 <f8000000.nor>, # parts = 8
#: name size offset mask_flags
0: config 0x00020000 0x00000000 0
1: kernel 0x00260000 0x00020000 0
2: fdt 0x00020000 0x00280000 0
3: tinyfs 0x00600000 0x002a0000 0
4: rootfs 0x076a0000 0x008a0000 0
5: u-boot-env-r 0x00020000 0x07f40000 1
6: u-boot-env 0x00020000 0x07f60000 1
7: u-boot 0x00080000 0x07f80000 1
device nand0 <f4000000.nand>, # parts = 2
#: name size offset mask_flags
0: fs1 0x20000000 0x00000000 0
1: fs2 0x20000000 0x20000000 0
=> nand erase 0x0 0x40000000
NAND erase: device 0 whole chip
Skipping bad block at 0x01200000
Skipping bad block at 0x0e880000
Skipping bad block at 0x1cd80000
Skipping bad block at 0x2b300000
Skipping bad block at 0x323c0000
Skipping bad block at 0x364c0000
Skipping bad block at 0x37cc0000
Erasing at 0x3ffc0000 -- 100% complete.
OK
=> ubi part fs1
Creating 1 MTD partitions on "nand0":
0x000000000000-0x000020000000 : "mtd=0"
UBI: attaching mtd2 to ubi0
UBI: physical eraseblock size: 262144 bytes (256 KiB)
UBI: logical eraseblock size: 253952 bytes
UBI: smallest flash I/O unit: 4096
UBI: VID header offset: 4096 (aligned 4096)
UBI: data offset: 8192
UBI: empty MTD device detected
UBI: create volume table (copy #1)
UBI: create volume table (copy #2)
UBI: attached mtd2 to ubi0
UBI: MTD device name: "mtd=0"
UBI: MTD device size: 512 MiB
UBI: number of good PEBs: 2045
UBI: number of bad PEBs: 3
UBI: max. allowed volumes: 128
UBI: wear-leveling threshold: 4096
UBI: number of internal volumes: 1
UBI: number of user volumes: 0
UBI: available PEBs: 2021
UBI: total number of reserved PEBs: 24
UBI: number of PEBs reserved for bad PEB handling: 20
UBI: max/mean erase counter: 0/0
UBI error: ubi_init: cannot attach mtd2
UBI: mtd2 is detached from ubi0
UBI error: ubi_init: UBI error: cannot initialize UBI, error -17
UBI init error -17
exit not allowed from main input shell.
My last sync with the denx git was when 2.6.31 was released. Here is my
version:
=> ver
U-Boot 2009.08-00213-gfdf80f7 (Dec 17 2009 - 12:57:07)
Jeff Angielski
The PTR Group
www.theptrgroup.com
More information about the U-Boot
mailing list