This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DM6446 rootfs burning

We build a small DM6446 board, only DM6446 SoC, Flash, USB, UART, no other things. So I burn u-boot.bin via DVFlasher and download uImage via USB SD Card.

My sd card is 2G and formated into 2 partions. The first one is vfat(uImage), the second is ext2(rootfs). I  fatload the uImage and  start the whole system on rootfs in the second partition. After the system booted,  I mount the /dev/mtdblock/0 and tar xzf rootfs.tar.gz to the mount folder.

Then I change root=/dev/sda2 to flash on board, my questions:

  • nand_read_bbt: Bad block ....       //  messages after hardware reset, before u-boot bootm.  why? I'm sure it happened after I tar xzf rootfs.tar.gz to /dev/mtdblock/0
  • I can't boot the rootfs from root=/dev/mtdblock/0   or root=/dev/mtdblk0.     // It seems I should mknod /dev/mtdblk0 ?? 
  • could I make yaffs rootfs to a rootfs.yaffs as same as rootfs.jffs? If yes, I can erase  nand and nand write the rootfs.yaffs to flash directly  in u-boot

Thank you!

nand_read_bbt: Bad block at 0x03fd0000
nand_read_bbt: Bad block at 0x03fd4000
nand_read_bbt: Bad block at 0x03fd8000
nand_read_bbt: Bad block at 0x03fdc000
nand_read_bbt: Bad block at 0x03fe0000
nand_read_bbt: Bad block at 0x03fe4000
nand_read_bbt: Bad block at 0x03fe8000
nand_read_bbt: Bad block at 0x03fec000
nand_read_bbt: Bad block at 0x03ff0000
nand_read_bbt: Bad block at 0x03ff4000
nand_read_bbt: Bad block at 0x03ff8000
nand_read_bbt: Bad block at 0x03ffc000
In:    serial
Out:   serial
Err:   serial
Read from EEPROM @ 0x50 failed
Net:   No ETH PHY detected!!!

  • Richard said:
    nand_read_bbt: Bad block ....       //  messages after hardware reset, before u-boot bootm.  why? I'm sure it happened after I tar xzf rootfs.tar.gz to /dev/mtdblock/0

    These are normal, bad block messages are not actually errors or warnings, they are really just status messages. Most NAND devices out of the factory have some bad blocks much like most LCD displays have a couple of bad pixels, these bad blocks are detected and marked in a bad block table on the NAND. What is weird about the particular bad blocks you have here is that they look to be sequential after a 0x03fd0000, this makes me wonder if you are using the same flash from the EVM board which U-Boot is expecting?

    Richard said:
    I can't boot the rootfs from root=/dev/mtdblock/0   or root=/dev/mtdblk0.     // It seems I should mknod /dev/mtdblk0 ?? 

    What sort of error do you get when this happens? The same software on the EVM will do the node generation automatically, so if this is not happening there may be something more foundational going wrong here.

    Richard said:
    could I make yaffs rootfs to a rootfs.yaffs as same as rootfs.jffs? If yes, I can erase  nand and nand write the rootfs.yaffs to flash directly  in u-boot

    I suspect you could use YAFFS instead, though I have not tried it on the DM6446 EVM.

  • My boot problem is solved next day morning after my post.  The whole system is booted from the flash on board. Only problem is long~~ bad block report because of NAND  ECC error(I'm replying at home, so I can't paste print info in detail)

    Our NAND is good and OK, only after I wrote rootfs from USB SD card to /dev/mtdblock/0, the long~~ bak block report appear. (burn uImage and reboot, it won't happen, all is fine).

    we will use yaffs at this release, and I think rootfs.jffs is a good feature for yaffs if yaffs doesn't have.

     

  • I paste the whole long~ message here

    It seems that rootfs overwrite the "Bad block table"

    --------------------------------------------------------------------

    Bad block table found at page 131040, version 0x01
    Bad block table not found for chip 0                                           // ??
    nand_bbt: ECC error while reading bad block table
    nand_read_bbt: Bad block at 0x02004000
    nand_read_bbt: Bad block at 0x02008000
    nand_read_bbt: Bad block at 0x0200c000

    .........  

    nand_read_bbt: Bad block at 0x03fe4000
    nand_read_bbt: Bad block at 0x03fe8000
    nand_read_bbt: Bad block at 0x03fec000
    nand_read_bbt: Bad block at 0x03ff0000
    nand_read_bbt: Bad block at 0x03ff4000
    nand_read_bbt: Bad block at 0x03ff8000
    nand_read_bbt: Bad block at 0x03ffc000
    No space left to write bad block table
    In:    serial
    Out:   serial
    Err:   serial
    Read from EEPROM @ 0x50 failed
    Net:   No ETH PHY detected!!!