Because of the Thanksgiving holiday in the U.S., TI E2E™ design support forum responses may be delayed from November 25 through December 2. Thank you for your patience.

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.

make the u-boot have UBI support, but not work

Other Parts Discussed in Thread: TMS320DM8168

I am using my custom board based on TMS320DM8168, I want to boot from Nand using UBIFS. And I did as the 

 said.At first I change the u-boot to support UBIFS.

I add the defines listed in the file, and make. unfortunately, it had errors.

And I change the other thing in the picture.

lucky,I make it. So I flash the u-boot.noxip.bin to the nand via u-boot and SD.

At last, the biggest problem come out. After the u-boot flashed into nand, and I can not reboot from nand. And I can see nothing from the uart.What should i do is booting from SD and erase the nand.

(I have tried to

#define (CONFIG_ENV_SIZE + (768 * 1024)) 

OR #define CONFIG_SYS_MALLOC_LEN (2 << 20) 

OR #define CONFIG_SYS_MALLOC_LEN (4 << 20)

they all not work.)

can you tell me how to do with the UBIFS?

  • Fire,

    You do not need to add UBI support in u-boot. To be able to use UBIFS as a root filesystem you need to enable UBIFS support in the linux kernel (which is made by default).

    See the below wiki pages:

    processors.wiki.ti.com/.../EZSDK_DM816x_Flashing_NAND
    processors.wiki.ti.com/.../EZSDK_Using_data_on_SD_and_filesystem_on_NAND
    processors.wiki.ti.com/.../Booting_Linux_kernel_using_U-Boot

    Regards,
    Pavel
  • Hi ,

    1) Even if you are not able to boot from NAND , if you change the switch position you can boot from SD card.

    2) Not sure if this can help , below is the steps + problem + solution i for NAND booting i faced when i was trying to get system
    up by NAND booting. ( i had used JFFS file system)
    e2e.ti.com/.../391866
  • hi,
    here is the html which told that we need to add the support in u-boot.
    processors.wiki.ti.com/index.php
  • Fire Lord said:
    here is the html which told that we need to add the support in u-boot.
    processors.wiki.ti.com/index.php

    This wiki provide you info how to enable UBI in u-boot, if you want to have UBI support in u-boot. To boot from NAND with UBIFS you do not need to add UBI support in u-boot. Could you please point me the exact place in this html document where it tolds you to add UBI support in u-boot, to be able to boot from NAND with UBIFS??

  • I am sorry that I confound UBI and UBIFS.
  • Pavel Botev said:

     Could you please point me the exact place in this html document where it tolds you to add UBI support in u-boot, to be able to boot from NAND with UBIFS??

    Here is the screenshot:

  • Pavel Botev said:

    To boot from NAND with UBIFS you do not need to add UBI support in u-boot. 

    I have tried to boot with default u-boot and kernel for UBIFS. But it stopped after "Uncompressing Linux... done, booting the kernel." Here is the boot log.

    ubi_failed.txt
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    MFI8168_uboot#mmc rescan 0
    raise: Signal # 8 caught
    MFI8168_uboot#nandecc hw 0
    HW ECC Hamming Code selected
    MFI8168_uboot#mw.b 0x81000000 0xFF 0x0C820000
    MFI8168_uboot#fatload mmc 0 81000000 ubi.img
    reading ubi.img
    
    19922944 bytes read
    MFI8168_uboot#nand erase clean 0x006C0000 0x0C820000
    
    NAND erase: device 0 offset 0x6c0000, size 0xc820000
    Skipping bad block at  0x0cd00000                                          
    Erasing at 0xcec0000 -- 100% complete. Cleanmarker written at 0xcec0000.
    OK
    MFI8168_uboot#nand write 0x81000000 0x006C0000 0x02120000
    
    NAND write: device 0 offset 0x6c0000, size 0x2120000
     34734080 bytes written: OK
    MFI8168_uboot#print
    bootdelay=3
    baudrate=115200
    autoload=no
    verify=yes
    bootfile=uImage
    ramdisk_file=ramdisk.gz
    loadaddr=0x81000000
    script_addr=0x80900000
    loadbootscript=fatload mmc 0 ${script_addr} boot.scr
    bootscript= echo Running bootscript from MMC/SD to set the ENV...; source ${script_addr}
    ethaddr=7c:66:9d:6e:23:84
    ethact=DaVinci EMAC
    bootcmd=nandecc hw 0;nand read 0x81000000 0x00280000 0x440000;bootm 0x81000000
    bootargs=console=ttyO0,115200n8 ip=off mem=256M rw ubi.mtd=3,2048 rootfstype=ubifs root=ubi0:rootfs
    ver=U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    filesize=1300000
    
    Environment size: 562/8188 bytes
    MFI8168_uboot#reset
    resetting ...
    
    
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    HW ECC Hamming Code selected
    
    NAND read: device 0 offset 0x280000, size 0x440000
     4456448 bytes read: OK
    ## Booting kernel from Legacy Image at 81000000 ...
       Image Name:   Linux-2.6.37
       Image Type:   ARM Linux Kernel Image (uncompressed)
       Data Size:    2414112 Bytes = 2.3 MiB
       Load Address: 80008000
       Entry Point:  80008000
       Verifying Checksum ... OK
       Loading Kernel Image ... OK
    OK
    
    Starting kernel ...
    
    Uncompressing Linux... done, booting the kernel.
    

  • Fire Lord said:
    Here is the screenshot:

    Let me explain for 3rd time in this e2e thread:

    You do not need to add UBI/UBIFS support in u-boot. To be able to use UBIFS as a root filesystem you need to enable UBIFS support in the linux kernel (which is made by default).

    This wiki provide you info how to enable UBI/UBIFS in u-boot, if you want to have UBI/UBIFS support in u-boot. To boot from NAND with UBIFS you do not need to add UBI/UBIFS support in u-boot.

  • Fire Lord said:
    I have tried to boot with default u-boot and kernel for UBIFS. But it stopped after "Uncompressing Linux... done, booting the kernel." Here is the boot log.

    Why you are using 1-bit HW ECC for UBIFS???

    Why you are using console=ttyO0???????

  • I think you are making terrifying mess up between JFFS2 settings and UBIFS settings.
  • hi,

    I have tried to BCH0 and BCH8 and SW.Here is the boot logs:

    ubi_hw2_failed.txt
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    HW ECC BCH8 Selected
    
    NAND read: device 0 offset 0x280000, size 0x440000
    ECC: uncorrectable.
    ECC: uncorrectable.
    ECC: uncorrectable.
    ECC: uncorrectable.
    ECC: uncorrectable.

    ubi_hw0_failed.txt
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    MFI8168_uboot#
    MFI8168_uboot#
    MFI8168_uboot#
    MFI8168_uboot#print
    bootdelay=3
    baudrate=115200
    autoload=no
    verify=yes
    bootfile=uImage
    ramdisk_file=ramdisk.gz
    loadaddr=0x81000000
    script_addr=0x80900000
    loadbootscript=fatload mmc 0 ${script_addr} boot.scr
    bootscript= echo Running bootscript from MMC/SD to set the ENV...; source ${script_addr}
    ethaddr=7c:66:9d:6e:23:84
    ethact=DaVinci EMAC
    filesize=1300000
    bootcmd=nandecc hw 2;nand read 0x81000000 0x00280000 0x440000;bootm 0x81000000
    bootargs=console=ttyO2,115200n8 ip=off mem=256M rw ubi.mtd=3,2048 rootfstype=ubifs root=ubi0:rootfs
    ver=U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    Environment size: 562/8188 bytes
    MFI8168_uboot#setenv bootcmd 'nandecc hw 0;nand read 0x81000000 0x00280000 0x440000;bootm 0x81000000'; setenv bootargs 'console=ttyO2,115200n8 ip=off mem=256M rw ubi.mtd=3,2048 rootfstype=ubifs root=ubi0:rootfs';saveenv
    Saving Environment to NAND...
    Erasing Nand...
    Warning: Erase size 0x00002000 smaller than one erase block 0x00020000
             Erasing 0x00020000 instead
    Erasing at 0x260000 -- 100% complete.
    Writing to Nand... done
    MFI8168_uboot#reset
    resetting ...
    
    
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    HW ECC Hamming Code selected
    
    NAND read: device 0 offset 0x280000, size 0x440000
     4456448 bytes read: OK
    ## Booting kernel from Legacy Image at 81000000 ...
       Image Name:   Linux-2.6.37
       Image Type:   ARM Linux Kernel Image (uncompressed)
       Data Size:    2414112 Bytes = 2.3 MiB
       Load Address: 80008000
       Entry Point:  80008000
       Verifying Checksum ... OK
       Loading Kernel Image ... OK
    OK
    
    Starting kernel ...
    
    Uncompressing Linux... done, booting the kernel.
    Linux version 2.6.37 (root@ubuntu) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-203) ) #2 Tue Mar 22 08:39:47 CST 2016
    CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c53c7f
    CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
    Machine: ti8168evm
    reserved size = 52428800 at 0x0
    FB: Reserving 52428800 bytes SDRAM for VRAM
    Memory policy: ECC disabled, Data cache writeback
    OMAP chip is TI8168 2.0
    Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 52224
    Kernel command line: console=ttyO2,115200n8 ip=off mem=256M rw ubi.mtd=3,2048 rootfstype=ubifs root=ubi0:rootfs
    PID hash table entries: 1024 (order: 0, 4096 bytes)
    Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
    Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
    Memory: 206MB = 206MB total
    Memory: 203476k/203476k available, 58668k reserved, 0K highmem
    Virtual kernel memory layout:
        vector  : 0xffff0000 - 0xffff1000   (   4 kB)
        fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
        DMA     : 0xffc00000 - 0xffe00000   (   2 MB)
        vmalloc : 0xd0800000 - 0xf8000000   ( 632 MB)
        lowmem  : 0xc0000000 - 0xd0000000   ( 256 MB)
        pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
        modules : 0xbf000000 - 0xbfe00000   (  14 MB)
          .init : 0xc0008000 - 0xc003c000   ( 208 kB)
          .text : 0xc003c000 - 0xc0493000   (4444 kB)
          .data : 0xc0494000 - 0xc04d5300   ( 261 kB)
    SLUB: Genslabs=11, HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    NR_IRQS:407
    IRQ: Found an INTC at 0xfa200000 (revision 5.0) with 128 interrupts
    Total of 128 interrupts on 1 active controller
    GPMC revision 6.0
    Trying to install interrupt handler for IRQ400
    Trying to install interrupt handler for IRQ401
    Trying to install interrupt handler for IRQ402
    Trying to install interrupt handler for IRQ403
    Trying to install interrupt handler for IRQ404
    Trying to install interrupt handler for IRQ405
    Trying to install interrupt handler for IRQ406
    Trying to install type control for IRQ407
    Trying to set irq flags for IRQ407
    OMAP clockevent source: GPTIMER1 at 27000000 Hz
    Console: colour dummy device 80x30
    Calibrating delay loop... 986.31 BogoMIPS (lpj=4931584)
    pid_max: default: 32768 minimum: 301
    Security Framework initialized
    Mount-cache hash table entries: 512
    CPU: Testing write buffer coherency: ok
    devtmpfs: initialized
    omap_voltage_early_init: voltage driver support not added
    regulator: core version 0.5
    regulator: dummy: 
    NET: Registered protocol family 16
    omap_voltage_domain_lookup: Voltage driver init not yet happened.Faulting!
    omap_voltage_add_dev: VDD specified does not exist!
    OMAP GPIO hardware version 0.1
    OMAP GPIO hardware version 0.1
    omap_mux_init: Add partition: #1: core, flags: 0
    _omap_mux_get_by_name: Could not find signal i2c2_scl.i2c2_scl
    _omap_mux_get_by_name: Could not find signal i2c2_sda.i2c2_sda
    NOR: Can't request GPMC CS
    registered ti816x_gpio_vr device
    registered ti816x_sr device
    pm_dbg_init: only OMAP3 supported
    registered ti81xx_vpss device
    registered ti81xx_vidout device
    registered ti81xx on-chip HDMI device
    registered ti81xx_fb device
    registered ti81xx_vin device
    ti81xx_pcie: Invoking PCI BIOS...
    ti81xx_pcie: Setting up Host Controller...
    ti81xx_pcie: Register base mapped @0xd0820000
    ti81xx_pcie: Starting PCI scan...
    PCI: bus0: Fast back to back transfers enabled
    bio: create slab <bio-0> at 0
    regulator: VFB: 800 <--> 1025 mV at 800 mV 
    vgaarb: loaded
    SCSI subsystem initialized
    USBSS revision 4ea20809
    registerd cppi-dma Intr @ IRQ 17
    Cppi41 Init Done
    omap_i2c omap_i2c.1: bus 1 rev4.0 at 100 kHz
    omap_i2c omap_i2c.2: bus 2 rev4.0 at 100 kHz
    Advanced Linux Sound Architecture Driver Version 1.0.23.
    Switching to clocksource gp timer
    musb-hdrc: version 6.0, peripheral, debug=0
    musb-hdrc musb-hdrc.0: dma type: dma-cppi41
    MUSB controller-0 revision 4ea20800
    musb-hdrc musb-hdrc.0: USB Peripheral mode controller at d081e000 using DMA, IRQ 18
    NET: Registered protocol family 2
    IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
    TCP established hash table entries: 8192 (order: 4, 65536 bytes)
    TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
    TCP: Hash tables configured (established 8192 bind 8192)
    TCP reno registered
    UDP hash table entries: 256 (order: 0, 4096 bytes)
    UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
    NET: Registered protocol family 1
    RPC: Registered udp transport module.
    RPC: Registered tcp transport module.
    RPC: Registered tcp NFSv4.1 backchannel transport module.
    NetWinder Floating Point Emulator V0.97 (double precision)
    PMU: registered new PMU device of type 0
    omap-iommu omap-iommu.0: ducati registered
    omap-iommu omap-iommu.1: sys registered
    JFFS2 version 2.2. (NAND) ? 2001-2006 Red Hat, Inc.
    msgmni has been set to 397
    io scheduler noop registered
    io scheduler deadline registered
    io scheduler cfq registered (default)
    Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
    omap_uart.0: ttyO0 at MMIO 0x48020000 (irq = 72) is a OMAP UART0
    omap_uart.1: ttyO1 at MMIO 0x48022000 (irq = 73) is a OMAP UART1
    omap_uart.2: ttyO2 at MMIO 0x48024000 (irq = 74) is a OMAP UART2
    console [ttyO2] enabled
    brd: module loaded
    loop: module loaded
    ahci ahci.0: forcing PORTS_IMPL to 0x3
    ahci ahci.0: AHCI 0001.0100 32 slots 2 ports 3 Gbps 0x3 impl platform mode
    ahci ahci.0: flags: ncq sntf pm led clo only pmp pio slum part ccc 
    scsi0 : ahci_platform
    scsi1 : ahci_platform
    ata1: SATA max UDMA/133 mmio [mem 0x4a140000-0x4a150fff] port 0x100 irq 16
    ata2: SATA max UDMA/133 mmio [mem 0x4a140000-0x4a150fff] port 0x180 irq 16
    omap2-nand driver initializing
    NAND device: Manufacturer ID: 0x2c, Chip ID: 0xcc (Micron )
    Creating 5 MTD partitions on "omap2-nand.0":
    0x000000000000-0x000000260000 : "U-Boot"
    0x000000260000-0x000000280000 : "U-Boot Env"
    0x000000280000-0x0000006c0000 : "Kernel"
    0x0000006c0000-0x00000cee0000 : "File System"
    0x00000cee0000-0x000020000000 : "Reserved"
    UBI: attaching mtd3 to ubi0
    UBI: physical eraseblock size:   131072 bytes (128 KiB)
    UBI: logical eraseblock size:    126976 bytes
    UBI: smallest flash I/O unit:    2048
    UBI: sub-page size:              512
    UBI: VID header offset:          2048 (aligned 2048)
    UBI: data offset:                4096
    ata1: SATA link down (SStatus 0 SControl 300)
    ata2: SATA link down (SStatus 0 SControl 300)
    UBI: max. sequence number:       0
    UBI error: vtbl_check: volume table check failed: record 0, error 9
    UBI error: ubi_init: cannot attach mtd3
    davinci_mdio davinci_mdio.0: davinci mdio revision 1.6
    davinci_mdio davinci_mdio.0: detected phy mask fffffffd
    davinci_mdio.0: probed
    davinci_mdio davinci_mdio.0: phy[1]: device 0:01, driver unknown
    g_ether gadget: using random self ethernet address
    g_ether gadget: using random host ethernet address
    usb0: MAC 06:04:05:15:65:86
    usb0: HOST MAC d2:e5:da:81:9d:d3
    g_ether gadget: Ethernet Gadget, version: Memorial Day 2008
    g_ether gadget: g_ether ready
    mice: PS/2 mouse device common for all mice
    omap_rtc omap_rtc: rtc core: registered omap_rtc as rtc0
    i2c /dev entries driver
    Linux video capture interface: v2.00
    OMAP Watchdog Timer Rev 0x00: initial timeout 60 sec
    asoc: tlv320aic3x-hifi <-> davinci-mcasp.2 mapping ok
    ALSA device list:
      #0: TI81XX EVM
    TCP cubic registered
    NET: Registered protocol family 17
    VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
    omap_voltage_late_init: Voltage driver support not added
    Power Management for TI81XX.
    smartreflex smartreflex: Driver initialized
    omap_rtc omap_rtc: setting system clock to 2000-01-01 00:00:00 UTC (946684800)
    VFS: Cannot open root device "ubi0:rootfs" or unknown-block(0,0)
    Please append a correct "root=" boot option; here are the available partitions:
    1f00            2432 mtdblock0  (driver?)
    1f01             128 mtdblock1  (driver?)
    1f02            4352 mtdblock2  (driver?)
    1f03          204928 mtdblock3  (driver?)
    1f04          312448 mtdblock4  (driver?)
    Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
    Backtrace: 
    [<c004abb8>] (dump_backtrace+0x0/0x110) from [<c036a5dc>] (dump_stack+0x18/0x1c)
     r7:cc814000 r6:c0072de8 r5:c002ebac r4:c04d5b50
    [<c036a5c4>] (dump_stack+0x0/0x1c) from [<c036a640>] (panic+0x60/0x17c)
    [<c036a5e0>] (panic+0x0/0x17c) from [<c00092b4>] (mount_block_root+0x1e0/0x220)
     r3:00000000 r2:00000000 r1:cc82bf78 r0:c041ddec
    [<c00090d4>] (mount_block_root+0x0/0x220) from [<c0009454>] (prepare_namespace+0x94/0x1d4)
    [<c00093c0>] (prepare_namespace+0x0/0x1d4) from [<c00087c4>] (kernel_init+0x114/0x154)
     r5:c00086b0 r4:c04d5300
    [<c00086b0>] (kernel_init+0x0/0x154) from [<c0072de8>] (do_exit+0x0/0x5e4)
     r5:c00086b0 r4:00000000

    ubi_sw_failed.txt
    U-Boot 2010.06 (Mar 17 2016 - 16:35:39)
    
    TI8168-GP rev 2.1
    
    ARM clk: 987MHz
    DDR clk: 796MHz
    
    I2C:   ready
    DRAM:  2 GiB
    NAND:  HW ECC Hamming Code selected
    512 MiB
    MMC:   OMAP SD/MMC: 0
    :,;;:;:;;;;;;;;r;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:,;;:;:;;;;;;;;:;;;;;;;;:,;;:;:
    ;,;:::;;;;r;;;rssiSiS552X5252525259GX2X9hX9X9XX2325S55252i5:,;;:;:;;;;;;;;:,;;:
    ;:;;;;;;;rrssSsS52S22h52299GGAAMHMM#BBH#B#HMM#HMBA&&XX2255S2S5Si:,;;:;:;;;;;;;;
    ;:;;r;;rsrrriiXS5S329&A&MH#BMB#A&9XXA252GXiSXX39AAMMMBB&G22S5i2SSiiiisi:,;;:;:;
    ;;;;;r;rr2iisiih393HB#B#AA99i22irrrX3X52AGsisss2Xii2299HBMA&X2S5S5iSiisSsi:,;;:
    r:r;rrsrsihXSi2&##MHB&Ahh3AGHGA9G9h&#H##@@@##MAMMXXX9SSS29&&HGGX2i5iisiiisisi:,
    ;;rrrrsSiiiA&ABH&A9GAGhAhBAMHA9HM@@@@@@@@@@@@@@@@@@@HHhAh2S2SX9&Gh22SSiisiiisii
    r:rrssisiS2XM##&h3AGAX&3GG3Ssr5H@M#HM2; ;2X&&&MHMB###GBB#B&XXSSs529XX55iSsisisi
    r;rsrisSi2XHAhX99A3XXG&&XS;:,rH#HGhAS   @@@@3rs2XBM@@A552&&AHA2XiisSS252SSsisSs
    r;issi5S22&&3iSSX292&hXsr;;:;h@&G339&S9@@@@2@MA&9&HB##Xris29ABMAAX2ir;rsSi5iss5
    rrsSi2XhG&9GXh399&X99i;;;;;;r#H&293H9X#@@@@@@@B&9GhAH@XrrsrsiXABHB&HG2rr;rrSiSi
    ;:rsisS599&AA9XG&3A35r;:::;,;BMh&&2iX5A@@@@@@@&392X5GB2;;;r;iSX393A##A&Xi:::rsi
    ;:rss552222X553&XHMhir;;::,:,h#HhGSXhG3#@@@@#AXXS2XAHA;::;;;;ss55XShBA3239r:,;;
    r;ii2S5SSi2i53hirsh2srr::,,,,;MMXX359&Ah3h&Si59SX99A#i:,::::;;sri2,.2r;:SGAr;,:
    ;:;rrrrssiriXGSi::shs;;;,,,:,,rBBA9h5s5h5iS5isi2SAHB5:,,,:::;rrs5&SrisSX5Srrr:,
    ;,r;;;;rsriSSrrrr;;5Xrr;;,:,,.,;9AA2SsisS5323XXXG9&i:.,,::;;r;;;srrrrrr;;:;::::
    :,;r;r;rrissrrr;:;::;s;;;;,:,,..,r293h222hXXAAGGGX;:,,,:,:,::;:;::,:,,,,...,,,,
    ;,;;;;rrrrrrrrirr;,.,,:::::::,,,,.,;SX&ABAB2hhXir:,,.,,.,,:,,,,..,,,..,..,,,..:
    :.:;:;;;:;;;;r;rrs;:.. ,,:::::,:,:,,.::rrsrr;;,,.......,..,....,,,,,,,...,.,,:,
    :.:::,::::::;;r;rrr;:.......,.,.,,:::,,...............,,::.,,,,:,::,,:,:,,,:,;:
    ,.::,:,,,,,;;;;;;;;r;;::,..............................;;;:;::::,:::::::,:,:,,,
    : ,,:,,,,,,,,,,,,,:;rrr;;:;,,,,,,,::,.,.:.,.,;s,:;;;;:;:;;;;;::::,:::,:::,:,:,:
    ,.,,,,,,,...,,.,,....................................:,............:,,,:,:,,,,,
    
    Net:   Detected MACID:7c:66:9d:6e:23:84
    Ethernet PHY: GENERIC @ 0x01
    DaVinci EMAC
    Hit any key to stop autoboot:  0 
    SW ECC selected
    
    NAND read: device 0 offset 0x280000, size 0x440000
    NAND read from offset 280000 failed -74
     4456448 bytes read: ERROR
    ## Booting kernel from Legacy Image at 81000000 ...
       Image Name:   Linux-2.6.37
       Image Type:   ARM Linux Kernel Image (uncompressed)
       Data Size:    2414112 Bytes = 2.3 MiB
       Load Address: 80008000
       Entry Point:  80008000
       Verifying Checksum ... Bad Data CRC
    ERROR: can't get kernel image!
    MFI8168_uboot#

  • ubi_hw2_failed.txt - I see "NAND: HW ECC Hamming Code selected" in the boot log
  • That is ecc schemas of U-boot, the ecc schemas of kernel should determined by the setting below "Hit any key to stop autoboot: 0 ". Do I get it?
  • No, you do not get it.

    The ECC schemes across ROM code, Uboot, Kernel and File System have been synchronised. We now support the same ECC scheme (which is 8-bit BCH) from end-to-end. For UBIFS, use 8-bit ECC from end-to-end.