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.

66AK2H U-boot booting from NAND

Other Parts Discussed in Thread: 66AK2H14

Hi,

I am trying to load u-boot on NAND for 66AK2H14 processor.

Currently, i am loading u-boot through CCS to MSMC RAM and executing it.I have made a minimal u-boot with only ddr and flash configuration. I could get the uboot prompt but its not able to detect NAND flash. This is same u-boot which is ported on EVMK2H kit and nand detect properly in it.

Below is the uboot log executed from MSMC RAM ,

U-Boot code: 0C001000 -> 0C053414  BSS: -> 0C0B730C
I2C:   ready
DDR3 PLL (PLL2) Setup ...
DDR3 PLL Setup complete, DDR3A clock now running at 400MHz.
DDR3A initialization complete

DDR config done
 DDR size 536870912
 init_async_emif done
 init_ddr3_ecc donemonitor len: 000B630C
ramsize: 20000000
TLB table from 9fff0000 to 9fff4000
Top of RAM usable for U-Boot at: 9fff0000
Reserving 728k for U-Boot at: 9ff39000
Reserving 2304k for malloc() at: 9fcf9000
Reserving 32 Bytes for Board Info at: 9fcf8fe0
Reserving 128 Bytes for Global Data at: 9fcf8f60
New Stack Pointer is: 9fcf8f50
gd->baudrate is: 115200
gd->bd->bi_baudrate is: 115200
RAM Configuration:
Bank #0: 80000000 512 MiB
relocation Offset is: 93f38000
monitor flash len: 0005BACC
Now running in RAM - U-Boot at: 9ff39000
NAND: NAND:  No NAND device found!!!   0 MiB

Warning: K2HK_EMAC using MAC address from net device
, K2HK_EMAC1, K2HK_EMAC2, K2HK_EMAC3
Initial value for argc=3
Final value for argc=3
### main_loop entered: bootdelay=3

Hit any key to stop autoboot:  0
K2HK EVM #

 

Should I need to do any configuration for EMIF to detect NAND.  ?

Please suggest,

  • Have you added the NAND configs (like CONFIG_NAND_DAVINCI) in K2H EVM defconfig file located at "u-boot-keystone/include/configs/ks2_evm.h" ?
    What is your MCSDK version ?

    This function "init_async_emif" should get callled in the following file.
    u-boot/board//ti/ks2_evm/board_k2hk.c

    Drivers location: (it should built *.o)
    drivers/mtd/nand/davinci_nand.c

    Are you working on custom board ?
    Did you use different NAND flash on your board ?
    If yes, have you modified the timings,bus width depends on your NAND HW changes...
  • HI,

    Thanks for your reply,

    Have you added the NAND configs (like CONFIG_NAND_DAVINCI) in K2H EVM defconfig file located at "u-boot-keystone/include/configs/ks2_evm.h" ?

    Yes

    What is your MCSDK version ?

    mcsdk_linux_3_00_03_15 

    This function "init_async_emif" should get callled in the following file.
    u-boot/board//ti/ks2_evm/board_k2hk.c

    Drivers location: (it should built *.o)
    drivers/mtd/nand/davinci_nand.c

    I have called this function in board_k2hk.c and also while building i could davinici_nand binary generated.

    Are you working on custom board ?

    Did you use different NAND flash on your board ?

    yes ours is customized board, but the flash is connected to 66AK2H in similar way that is connected in K2H EVM schematic. We are using the same flash chip

    (MT29F4G08ABBDAHC-IT)  used in k2h EVM .

    Since  Flash is same in both evm kit as well as in our customized board,i dint change in any of timings configuration.

    I am using uboot version (uboot-keystone-2013.01) and same is working when ported in EVM kit and not in our customized board.

    Please suggest,

     

     

  • Thanks.
    Can you please attach the log which you used to build the u-boot (and u-boot build log) ?
    Also attach the .h file of "include/configs/k2hk_evm.h"

  • Thanks Vidya.
    Let me investigate and reply AEAP.
  • Vidya,

    Have you run any diagnostics to check if your NAND flash is connected correctly. One way to test this would be to connect to the device using an emulator and test if the NAND read write operation is working on your custom board. The SDK provides a NAND writer that you can use to try to program your NAND flash. If the program fails to read the Manufacturer ID and NAND geometry from the flash over the EMIF16 interface, you might have some board level issue.

    Can you also confirm that the NAND flash is connected on the same EMIF Chip enable pin (CE) as the EVM.

    Regards,
    Rahul
  • I have checked those files, u-boot is building the NAND driver and NAND configs also enabled.

    As Rahul suggested, please look into HW validation on NAND side.

    You have to use the following location to import the CCS project & rebuild then run this NAND writer project, let us know what output log you are getting.
    C:\ti\mcsdk_bios_3_01_04_07\tools\writer\nand\evmk2h
  • Hi,

    I am trying to access NAND in u-boot and havnt tried with nand writer project through CCS. I try it and update the log.

    NAND Flash is connected to same chip enable pin as in EVM . Both EVM and our board connections are same, but only the wait state is different. In EVM, you have given wait state 0 but in our board we have given wait state 1. Will this make any difference ?
  • Thanks.
    I think, it won't help if you try to access the NAND flash since its not getting detected.
    Better to debug this particular NAND problem with simple bare-metal code (like NAND writer project)

    Also we have NAND based "platform test" project from PDK.

    C:\ti\pdk_keystone2_3_01_04_07\packages\ti\platform\evmk2h\platform_lib
    C:\ti\pdk_keystone2_3_01_04_07\packages\ti\platform\evmk2h\platform_lib\src\evm66x_nand.c
    C:\ti\pdk_keystone2_3_01_04_07\packages\ti\platform\evmk2h\platform_lib\src\platform.c

    If you import this project and rebuild it, and check whether your NAND flash is getting detected or not.
  • Hi,

    Can you confirm whether this u-boot version 2013-01 is the latest one for ARM 66AK2H processor.

    Like nand, i am facing issue in pci too.

    U-boot has given arm_pci_init funciton which inturn calls pci_init_board and this function doesnt seems to be defined for arm functionality.And there is no configuration for pci in K2HK header file too.

    Do i need add any patch for this or update to new uboot release.
    If so ,please guide me to which u-boot release i need to look into to fix this.
  • Hi ,

    Can confirm about about the wait state. That is the only difference with your evm schematic and ours.

    Do it makes any difference in performing nand read and write operation.
  • Sure Vidhya.
    If you want to get the latest u-boot then do the following.

    git clone git://git.ti.com/keystone-linux/u-boot.git u-boot-keystone
    cd u-boot-keystone
    git reset --hard <Release tag>
    Ex:
    git reset --hard K2_UBOOT_2013_01_15.07_01

    You can get the release tag from MCSDK release notes.
    downloads.ti.com/.../MCSDK_Release_Notes.pdf

    We can focus NAND issue here then we can debug the PCIe etc.,
    Please confirm that we don't have problem with NAND HW, then we can try to check with u-boot & Linux etc.,

    Try to run the NANDwriter project & platform test CCS projects then update to us.
  • Hi,

    Please find the attachment,


    I imported the project nand writer and try  to write sample application from DDR to nand memory. Project crashes with message "Bad block # detected, skipping block ... "

    arm-nand.txt

  • Hi Titus,

    Any inputs regarding NAND.

    I tried the nand writer and the platform test case but it shows bad block in all the sector. I have also attached log in my previous post.

    Please guide us to sort out this issue

  • Hi Titus,

    Hope the below information could help you to suggest us some ideas to sort it out.

    As you said, i downloaded the latest u-boot from site

    and in initial when i ported the u-boot, the result looks same . Nand was not detecting properly.But when i added delay after reset command in nand.c ,i could able to see 512MB NAND flash.

    -Boot# H¨H¨UIÔë&&LM7-00080-g68db1b0-dirty (Feb 16 2016 - 16:43:44 +0530)
    
    CPU: 66AK2Hx SR2.0
    I2C:   ready
    DRAM:  DDR3 PLL (PLL2) Setup ...
    DDR3 PLL Setup complete, DDR3A clock now running at 400MHz.
    DDR3A initialization complete
    NAND:
    *maf_id 0 *dev_id 0 ------------ delay which print wrong vendor/manufactor id for first read. 
    512 MiB ---------- detects Nand flash size correctly *** Warning - readenv() failed, using default environment Net: Phy 0 not found Phy 1 not found Phy 2 not found Phy 3 not found K2HK_EMAC Warning: K2HK_EMAC using MAC address from net device , K2HK_EMAC1 Error: K2HK_EMAC1 address not set. , K2HK_EMAC2 Error: K2HK_EMAC2 address not set. , K2HK_EMAC3 Error: K2HK_EMAC3 address not set. Hit any key to stop autoboot: 0 UBI: attaching mtd1 to ubi0 UBI: scanning is finished UBI: empty MTD device detected UBI init error 28 Error reading superblock on volume 'ubi:rootfs' errno=-19! ubifsmount - mount UBIFS volume Usage: ubifsmount <volume-name> - mount 'volume-name' volume U-Boot# U-Boot#

    Query:

    The u-boot source which i am using is same as the one ported in the your ti EVM Kit. In EVM kit, without any delay it is able to detect nand  but in our board for same chip , we have added delay to detect it.Why this delay difference ?

    The only difference with your and our schematic for NAND section is wait state. You have used wait_0 and we have connected to wait_1. Will this makes any difference ?

    Even if nand is detected, i am not able to perform any read or write operation to NAND, You could see the below screenshot,

    U-Boot# saveenv
    Saving Environment to NAND...
    Erasing NAND...
    Skipping bad block at  0x00100000
    Skipping bad block at  0x00120000
    Writing to NAND... FAILED!

    I have attached the nand flash dumps,

    Please suggest us to sort out this issue,

    -Boot# H�H�UI��&&LM7-00080-g68db1b0-dirty (Feb 16 2016 - 16:43:44 +0530)
    
    CPU: 66AK2Hx SR2.0
    I2C:   ready
    DRAM:  DDR3 PLL (PLL2) Setup ...
    DDR3 PLL Setup complete, DDR3A clock now running at 400MHz.
    DDR3A initialization complete
    NAND:
    *maf_id 0 *dev_id 0512 MiB
    *** Warning - readenv() failed, using default environment
    Net:   Phy 0 not found
    Phy 1 not found
    Phy 2 not found
    Phy 3 not found
    K2HK_EMAC
    Warning: K2HK_EMAC using MAC address from net device
    , K2HK_EMAC1
    Error: K2HK_EMAC1 address not set.
    , K2HK_EMAC2
    Error: K2HK_EMAC2 address not set.
    , K2HK_EMAC3
    Error: K2HK_EMAC3 address not set.
    
    Hit any key to stop autoboot:  0
    UBI: attaching mtd1 to ubi0
    UBI: scanning is finished
    UBI: empty MTD device detected
    UBI init error 28
    Error reading superblock on volume 'ubi:rootfs' errno=-19!
    ubifsmount - mount UBIFS volume
    
    Usage:
    ubifsmount <volume-name>
        - mount 'volume-name' volume
    U-Boot#
    U-Boot#
    
    U-Boot# nand info
    Device 0: nand0, sector size 128 KiB
      Page size       2048 b
      OOB size          64 b
      Erase size    131072 b
      subpagesize     2048 b
      options     0x40000200
      bbt options 0x   28000
    U-Boot#
    U-Boot#
    U-Boot# nand dump all
    Page 00000000 dump:
            00 00 00 00 ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
    U-Boot#
    
    
    U-Boot# saveenv
    Saving Environment to NAND...
    Erasing NAND...
    Skipping bad block at  0x00100000
    Skipping bad block at  0x00120000
    
    Writing to NAND... FAILED!
    

  • Thanks Vidya.
    Can you please do "nand scrub.chip" command in u-boot to erase the NAND flash completely and rewrite the BBT ?
    Also try "nand info" command to check the NAND informations.
  • Vidya,

    Can you see if the Uboot source is setting extended Wait polarity using the EMIF16 AWCRR register. The EMIF16 User guide mentions that programming the correct wait state is important. Here is text from the EMIF16 user guide.

    A chip select can be mapped to either of the two pins EMIFWAIT[1:0] by appropriately setting the CS2-5_WAIT fields in the Async Wait Cycle Config Register (AWCCR). It is also important to correctly set the active polarity of the EMIFWAIT pins by programming the WP0-1 bits in the AWCCR. A ‘0’ means EMIF16 will insert wait cycles when EMIFWAIT is low, and sampled high when polarity is set to 1.

    This would imply that you need to modify the code to use wait1 instead of wait0 and make sure that the signal is driven high. Since the EVM is using WAIT0, I suspect that they are driving the wait state low on wait1.

    Regards,
    Rahul

  • Hi Titus,

    I tried the both commands but still issue is same. I am not able to write to NAND memory.

    I tried to read data from NAND to DDR location(0x80000000)  and i used below command,

    U-Boot# nand read.raw 80000000 0 1
    
    NAND read:  2112 bytes read: OK
    

    and i could see the data in ddr memory.

    Similarly i tried to write data from DDR to NAND memory using below command ,

    U-Boot# nand write.raw 0x80000000 0 1
    
    NAND write: WARNING in drivers/mtd/nand/nand_base.c line 1027
    raw_access: error at offset 0, ret -5
     2112 bytes written: ERROR

    I could see the data in NAND using nand dump command but the data looks corrupted in between ,

    U-Boot# nand dump 0
    Page 00000000 dump:
            00 00 00 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 11 11 11 ff ff  ff ff ff ff ff ff 7f ff
            ff ff ff ff ff ff fb ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fe ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ef
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  df ff ff ff ff ff ff ff
            ff ff ff fe ff ff ff ff  ff ff ff ff df ff ff ff
            ff ff ff ff ff ff ff ff  ed ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff bf ff ff ff df  fc ff bf ff ff ff ff ff
            ff ff fe ff ff ef ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fd ff ff  ff ff ff ff ff ff ff f7
            ff ff ff ff ff ff ff ff  ff ff ff ff fb ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff fe ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ef
            ff ff ee ff ff ff ff ff  ff ff ff ff ff bf ff fe
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff 7f ff ff ff ff ff ff  ff ff ff ff ff ff 7b ff
            ff ff ff ff ff ff 7f fd  ff df ff fd ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff 7f
            ff ff ff ff df ff ff ff  ff ff ff ff ff ff ff ff
            7f ff ff ff ff ff ff ff  ff ff ff ff df ff 7f ff
            ff ff ff ff ff ff ff 7f  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fe ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff 7f ff ff f7 ff
            bf ff ff ff ff ff ff ff  ff ff ff ff fe ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff fd ff ff ff ff ff  ff ff ff df ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff ff bf ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff da ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff fb fe ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ef ff ff ff ff ff ff f7
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fb
            ff ff ff bf ff ff ff ff  ff ff ff ff ff ff ff ff
            7f ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ef ff ff ff ff ff ff  ff ff ff ff ff fd 97 ef
            fb ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff 7b ff
            ff ff ff ff fd ff fd ff  ff bf ff ff ff ff ff ff
            ff ff ff ff ff ff bf ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff 7f ff  ff ff ff ff fe ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff fa ff ff ff  ff ff ff ff ff ff ff 7e
            ff ff ff ff ff ef ff ff  ff ff ff ff ff ff fd ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fe ff  ff ff ff ff ff ff ff ff
            ff ff ff df ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff fe  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff f6
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff fb ff ff
            ff f7 ff ff ff ff ff ff
            fd ff ff ff ff ff ff fe
            ff ff ff ff ff ff db 7f
    U-Boot#

    Even if it writes, nand write command shows error at the end. Why is this happening. Any command syntax issue or nand is not configured properly ?

    Please suggest,

  • Hi Rahul,

    I checked the register AWCRR in u-boot once nand initalized,

    Its shows value 0xf0040080  which is been set wait state 1 for CS3_WAIT and with default MAX_EXT_WAIT and polarity state.

     U-Boot# md 21000a00

    21000a00: 40000205 f0040080 00000620 00000001    ...@.... .......
    21000a10: 3ffffffc 3ffffffd 3ffffffd 3ffffffd    ...?...?...?...?
    21000a20: 00000000 00000000 00000000 00000000    ................
    21000a30: 00000000 00000000 00000000 00000000    ................
    21000a40: 0000000c 00000000 00000000 00000000    ................
    21000a50: 00000000 00000000 00000000 00000400    ................
    21000a60: 00000001 00000003 fefefefe 00000000    ................
    21000a70: 00000000 00000000 00000000 00000000    ................
    21000a80: 00000000 00000000 00002091 00000000    ......... ......
    21000a90: 00000000 00000000 00000000 00000000    ................
    21000aa0: 00000000 00000000 00000000 00000000    ................
    21000ab0: 00000004 00000000 00000000 00000000    ................
    21000ac0: 00550322 003300e6 02c2019a 000f0320    ".U...3..... ...
    21000ad0: 00000000 00000000 00000000 00000000    ................
    21000ae0: 00000000 00000000 00000000 00000000    ................
    21000af0: 00000000 00000000 00000000 00000000    ................
    

    From U-boot command , i changed the value to 0xf0010080  which sets wait state 1 for CS2_WAIT. But still i faces issue in read and write.

    U-Boot# md 21000a00
    21000a00: 40000205 f0010080 00000620 00000001    ...@.... .......
    21000a10: 3ffffffc 3ffffffd 3ffffffd 3ffffffd    ...?...?...?...?
    21000a20: 00000000 00000000 00000000 00000000    ................
    21000a30: 00000000 00000000 00000000 00000000    ................
    21000a40: 0000000c 00000000 00000000 00000000    ................
    21000a50: 00000000 00000000 00000000 00000400    ................
    21000a60: 00000001 00000003 fefefefe 00000000    ................
    21000a70: 00000000 00000000 00000000 00000000    ................
    21000a80: 00000000 00000000 00002091 00000000    ......... ......
    21000a90: 00000000 00000000 00000000 00000000    ................
    21000aa0: 00000000 00000000 00000000 00000000    ................
    21000ab0: 00000004 00000000 00000000 00000000    ................
    21000ac0: 00550322 003300e6 02c2019a 000f0320    ".U...3..... ...
    21000ad0: 00000000 00000000 00000000 00000000    ................
    21000ae0: 00000000 00000000 00000000 00000000    ................
    21000af0: 00000000 00000000 00000000 00000000    ................

    Please find the nand log attached,

    U-Boot# nand info
    
    Device 0: nand0, sector size 128 KiB
      Page size       2048 b
      OOB size          64 b
      Erase size    131072 b
      subpagesize     2048 b
      options     0x     200
      bbt options 0x   28000
    U-Boot#
    U-Boot#
    U-Boot# nand dump all
    Page 00000000 dump:
            00 00 ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
    U-Boot#
    U-Boot# md 21000a00
    21000a00: 40000205 f0040080 00000620 00000001    ...@.... .......
    21000a10: 3ffffffc 3ffffffd 3ffffffd 3ffffffd    ...?...?...?...?
    21000a20: 00000000 00000000 00000000 00000000    ................
    21000a30: 00000000 00000000 00000000 00000000    ................
    21000a40: 0000000c 00000000 00000000 00000000    ................
    21000a50: 00000000 00000000 00000000 00000400    ................
    21000a60: 00000001 00000003 fefefefe 00000000    ................
    21000a70: 00000000 00000000 00000000 00000000    ................
    21000a80: 00000000 00000000 00002091 00000000    ......... ......
    21000a90: 00000000 00000000 00000000 00000000    ................
    21000aa0: 00000000 00000000 00000000 00000000    ................
    21000ab0: 00000004 00000000 00000000 00000000    ................
    21000ac0: 00550322 003300e6 02c2019a 000f0320    ".U...3..... ...
    21000ad0: 00000000 00000000 00000000 00000000    ................
    21000ae0: 00000000 00000000 00000000 00000000    ................
    21000af0: 00000000 00000000 00000000 00000000    ................
    U-Boot# nand write.raw 0x80000000 0 0
    
    NAND write:  0 bytes written: OK
    U-Boot# nand dump 0
    Page 00000000 dump:
            00 00 00 ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
    U-Boot#
    U-Boot# nand write.raw 0x80000000 0 1
    
    NAND write: WARNING in drivers/mtd/nand/nand_base.c line 1027
    raw_access: error at offset 0, ret -5
     2112 bytes written: ERROR
    U-Boot# nand dump 0
    Page 00000000 dump:
            00 00 00 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 22 22 22 22 22  22 22 22 22 22 22 22 22
            22 22 22 11 11 11 ff ff  ff ff ff ff ff ff 7f ff
            ff ff ff ff ff ff fb ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fe ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ef
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  df ff ff ff ff ff ff ff
            ff ff ff fe ff ff ff ff  ff ff ff ff df ff ff ff
            ff ff ff ff ff ff ff ff  ed ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff bf ff ff ff df  fc ff bf ff ff ff ff ff
            ff ff fe ff ff ef ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fd ff ff  ff ff ff ff ff ff ff f7
            ff ff ff ff ff ff ff ff  ff ff ff ff fb ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff fe ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ef
            ff ff ee ff ff ff ff ff  ff ff ff ff ff bf ff fe
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff 7f ff ff ff ff ff ff  ff ff ff ff ff ff 7b ff
            ff ff ff ff ff ff 7f fd  ff df ff fd ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff 7f
            ff ff ff ff df ff ff ff  ff ff ff ff ff ff ff ff
            7f ff ff ff ff ff ff ff  ff ff ff ff df ff 7f ff
            ff ff ff ff ff ff ff 7f  ff ff ff ff ff ff ff ff
            ff ff ff ff ff fe ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff 7f ff ff f7 ff
            bf ff ff ff ff ff ff ff  ff ff ff ff fe ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff fd ff ff ff ff ff  ff ff ff df ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fb ff  ff ff ff ff bf ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff da ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff fb fe ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ef ff ff ff ff ff ff f7
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fb
            ff ff ff bf ff ff ff ff  ff ff ff ff ff ff ff ff
            7f ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ef ff ff ff ff ff ff  ff ff ff ff ff fd 97 ef
            fb ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff 7b ff
            ff ff ff ff fd ff fd ff  ff bf ff ff ff ff ff ff
            ff ff ff ff ff ff bf ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff 7f ff  ff ff ff ff fe ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff fa ff ff ff  ff ff ff ff ff ff ff 7e
            ff ff ff ff ff ef ff ff  ff ff ff ff ff ff fd ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff fe ff  ff ff ff ff ff ff ff ff
            ff ff ff df ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff fe  ff ff ff ff ff ff ff ff
            fd ff ff ff ff ff ff ff  ff ff ff ff ff ff ff fd
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff f6
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff fb ff ff
            ff f7 ff ff ff ff ff ff
            fd ff ff ff ff ff ff fe
            ff ff ff ff ff ff db 7f
    U-Boot#
    

  • Thanks Vidya.

    Please erase the whole block and write.

    Can you please do the following commands and attach the log ?
    1)
    md 0x80000000
    mw.l 0x80000000 0xa5a5a5a5
    nand erase 0x100000 0x20000
    nand dump 0x100000
    nand write 0x80000000 0x100000 0x20000
    nand dump 0x100000

    2)
    md 0x80000000
    mw.l 0x80000000 0xa5a5a5a5
    nand erase 0 0xFF
    nand dump 0
    nand write.raw 0x80000000 0 0xFF

    Have you added the Inverted IC on EMIF OE pin as EVM used (U69) to solve the EMIF read/write issue ?

    Still you are not able to get the correct manufacturer ID and product ID ?
  • Hi,

    Please find the attachment,

    Have you added the Inverted IC on EMIF OE pin as EVM used (U69) to solve the EMIF read/write issue ?

    I understand U69 inverted IC in EVM is meant to access EMIF16 through edge connector(CN3).

    Is this inverter IC any way related in accessing NAND FLASH ?


    Still you are not able to get the correct manufacturer ID and product ID ?

    I am able to read the manufacturer and product ID after adding delay in nand.c file. Just added a printf as a delay.

     

    arm-ti2.txt

     


  • I am able to read the manufacturer and product ID after adding delay in nand.c file. Just added a printf as a delay.

    I've seen ID as 0x0 in your uboot log, that's why I asked you again on this.


    I understand U69 inverted IC in EVM is meant to access EMIF16 through edge connector(CN3).

    I checked completely, yes, you are right.
    Actually I've seen text that "Added Inverter U69 to solve EMIF and NAND read/write issue" in EVM schematics, that's why I asked you to check.
    Let me check with HW guy for further support.
  • Vidya,

    Please ensure all the hardware connections between the SoC and NAND are correct ?

    Are you seeing any activity on the CS when you run the uboot ?

    If possible, please share the NAND portion of your custom board schematics.

    Regards,
    Senthil
  • Hi,

    Are you seeing any activity on the CS when you run the uboot ?

    Yes.I am able to see CS when uboot tries to read or write to the nand. U-boot is able to successfully prints the NAND information and its size 512MB. which confirms NAND CS.

    If possible, please share the NAND portion of your custom board schematics.

    I have attached the EMIF to NAND connection. Please find the attachment,

    Please let us know if any changes to be done in HW,

  • Vidya,

    As you mentioned earlier, i see the only difference in your schematics is the wait signal. Can you probe the wait1 signal in your design and see if it is ready or busy ?

    Are you seeing the same behavior on NAND on other boards ?

    I would also suggest you check for any assembly issue of NAND device and try with other memory device with same part number.

    Regards,
    Senthil
  • Hi,

    Yes. Wait signal was the only change in both the schematic. I checked the nand behavior in both wait signal condition and the behavior looks same.

    Nand write and read is able to perform but it shows error on completion .

    nand write.raw 0x80000000 0 0xFF
    
    NAND write: WARNING in drivers/mtd/nand/nand_base.c line 1027
    raw_access: error at offset 0, ret -5
     538560 bytes written: ERROR

    This cannot be issue in assembly. Bcoz we are able to access the NAND and perform read/write but not to completely.

    Both screen shot shows error at offset 0 but it has written 538560 bytes.

    nand dump 0
    Page 00000000 dump:
    00 00 00 00 a5 a5 a5 a5  22 22 22 22 dd dd dd dd
    dd dd dd dd 44 44 44 44  44 44 44 44 bb bb bb bb
    bb bb bb bb 88 88 88 88  88 88 88 88 77 77 77 77
    77 77 77 77 11 11 11 11  11 11 11 11 ee ee ee ee
    ee ee ee ee 22 22 22 22  22 22 22 22 dd dd dd dd
    dd dd dd dd 44 44 44 44  44 44 44 44 bb bb bb bb
    bb bb bb bb 88 88 88 88  88 88 88 88 77 77 77 77
    77 77 77 77 00 00 00 00  00 00 00 00 00 00 00 00
    00 00 00 00 18 bb 49 78  bd 5f 4f 6b ca f4 4f 43
    f5 52 e1 1f c5 3e 25 6e  35 7c 7f 2a aa d9 6f 7f
    9c 19 7e ef b6 8d f5 d0  5f c1 69 ef 8c c9 74 62
    4d 7d dd e7 60 c6 22 c7  f1 fd ef 65 d9 c5 e7 a2
    16 3d cd 69 c7 50 2f 88  55 57 7a 1d d6 ae 46 cd
    95 75 bc 45 f3 34 bb b6  65 f5 9e dd 96 ce 38 ff
    d7 17 de ef 6f 7f 65 57  55 2a d5 ac 6d 5b d1 fd
    4f de ff e9 3b 71 6b 1e  65 7d ae d4 bc f7 ed 12
    f5 99 ed cf 35 b4 c5 98  5e 78 7d bb cd e4 29 f7
    55 ff d2 c8 7f 93 37 fd  df f3 57 17 59 bd f5 7b
    55 51 fb b2 5f 7e cf ef  77 c5 b5 df c1 12 58 f5
    df 95 49 40 98 5c 95 8d  75 e0 b3 27 eb e1 57 f7
    77 c7 ff f7 67 6a bf 2b  3b 6f dd 66 d7 35 7b e6
    6f 71 cb 0c 77 2f ad cf  f7 45 15 b7 4b ff ff d1
    5d 34 9a f8 63 99 51 c5  25 5e d3 79 d7 fe 59 cc
    77 11 71 79 44 7b 56 eb  57 d5 3b af df fd 45 dd
    7b d5 37 d3 c5 66 3b f6  de 4d 4c bc f7 d3 c5 73
    5f cf 4e 4b 4b 6c a6 69  5e c4 fc 3f 71 bd b4 10
    4d cd 72 20 df 5c 80 73  75 9d b2 cd b8 6f 74 d3
    97 bf 5b cd 06 3d dc d5  c5 d9 c7 1e 0d a5 85 7b
    55 d6 d5 58 9c 6d c1 fc  a1 d6 6b 76 4f b0 55 f3
    61 37 f9 5f 5f 63 5b cd  3c 66 5f fb ab 24 47 c1
    c0 ff 50 75 17 18 5b 5f  dd a9 9e 63 d7 51 30 c6
    f7 f1 b7 79 f2 3e 5d fe  f9 f5 f7 bf e7 1f 59 41
    d3 e2 5a a2 07 b4 c5 ff  6d 17 d7 e0 3e f1 59 c5
    e6 7d bf ba e8 bb ee 53  3d 65 bd 93 a3 74 4f 1d
    1e d7 af 35 1f f7 f6 34  c7 3d c2 fb 81 9e e6 16
    dc f0 f7 60 3b 7e 83 3b  d5 67 6a ce ae 45 f5 c6
    9b f2 7a 6f 7b 76 b1 d6  77 b3 af fd 37 0f c2 76
    3f 49 6d f1 dc 3f 7a ea  f4 5d b1 de e3 ed fb ec
    77 d7 d5 9f 67 83 26 54  57 72 67 e5 52 92 3a fb
    55 5b 59 54 91 39 d5 f1  04 43 fd 7c 42 6d dd f7
    f7 ca ab fc 14 b7 65 f4  f6 ff e3 1f f5 d7 16 19
    bb e9 f7 4e 33 f7 56 a9  d0 35 81 b7 3d dc d3 2f
    81 b7 5f 5f 53 af e2 3a  d5 d5 9d b5 9a 5d dc 1b
    0d 5f ff f5 54 5d 70 d7  51 d5 de bf 69 e9 ff 77
    ff 55 f0 3e 73 7c b0 29  23 f6 dc fb 8e 1b db f4
    7f de f5 45 36 a9 54 f7  8c 7d 94 f3 ef f5 74 d5
    99 73 ac 43 eb 3d bf 3d  cc df da 9d 7c a9 0c c3
    5f 19 eb 25 fb 9c 5f 6f  07 49 31 b9 25 77 63 8f
    7f 74 df bf 48 9a 9d 13  51 95 95 eb d5 75 67 ff
    5e fd be fb 64 59 33 cf  d6 d5 13 e0 79 48 1c dc
    f7 95 37 5e b7 5f 56 c9  8b c6 bb 54 d4 e3 d7 7d
    79 c7 75 4f de d9 5d 88  f9 76 78 57 ab 95 fc 9a
    3d d4 fe ef 89 6b 73 c9  de 99 db 0b 78 67 fc 0c
    f5 71 0e 7f bd 55 f6 e5  bf 53 df 6c 5c 5c cc d8
    a7 e5 ce fe f8 cb b6 24  79 5f d9 d1 4b ab 77 99
    d3 13 d3 db 6e e1 34 57  67 3f 5f d5 4c 6d 74 98
    5f d8 df 59 9f 47 b3 d0  76 dd bc b4 71 f5 bf ef
    0f 54 e4 d3 fe ef d1 1f  6f 1d f4 a7 d5 ea c7 b5
    0d 77 e7 b2 7a 12 d3 cd  5c 77 6d 5f b6 79 7f ef
    0e b5 5b ff 28 cb e0 a5  37 79 df 37 7c fd d7 fe
    9d de d7 13 bd c5 35 fd  4b c1 f1 59 1c 9b d5 1d
    d9 ac f5 d4 2f de dd 7d  5d 57 31 5a de b7 d7 a3
    fa f4 f1 a3 7f 51 f5 ea  1d d1 df 92 d5 e1 3f ec
    fd 73 ff be 55 56 72 6e  57 d9 fa ed 23 89 75 f4
    d9 ff 6e b6 d1 fd f2 8e  d7 2d e7 ed 6e 8f 88 96
    51 f9 fa 5f 32 df f9 f6  f7 bd 57 57 69 b5 1c a0
    f9 72 1f 65 7c 27 4c 70  f9 d4 6e 10 ba 5e 37 fa
    7b 14 ef 8a 55 d0 25 e4  77 93 d7 e3 d9 15 e1 7a
    58 b3 d8 ee 51 77 38 4d  9b 58 3e f7 a7 54 f4 3a
    6e 95 6f ec 51 34 74 87  75 54 f9 fb c5 65 e9 83
    4f ad 9f d5 93 15 37 7b  9d f7 27 1b d6 97 7d c7
    95 55 dd 5b ff f9 69 34  d4 74 ff 59 e6 1c ce 7a
    fd 45 f3 7c 71 55 52 71  51 5a b1 db b7 f6 38 db
    d5 ec bf 9e db e8 0d 2f  d5 5b f6 9b eb 54 a8 e9
    f6 b6 7f df d1 aa 44 1d  fc b4 80 43 30 de b8 d5
    51 4d 8c 17 23 fe 27 c5  d5 71 9e b7 2c 3e 78 de
    1f e5 a5 0a e8 1e 5b f7  7e 7d d5 58 06 d7 db ef
    df 35 1c de fe bf d3 fd  5f cf 37 1f 4c 86 b6 de
    bf 1d 5c 97 bd e3 6e fd  8a 77 7f fa f6 df f9 db
    59 ca 56 ee 8f 8e 7c 6b  54 67 77 d7 67 8e 8e b5
    dd e3 dd d4 3b 3d e5 36  f3 f4 a4 c2 77 c1 5f 51
    da ea 55 ad 7e b6 bf 7c  7f 17 ef ae 51 de ff d6
    51 5d f3 cf ae df 69 6b  07 6e 7e 4f 2e fd 73 e1
    d4 d3 ff 7f f4 fd f0 84  89 df fe 70 3f df ef e8
    75 d7 ca d7 77 64 09 4b  72 9f b0 17 fd fd 2d ed
    c2 0d fc dd 29 ad fd cc  7b 1f 91 23 b4 e4 b1 ed
    75 d7 ac bc 77 1f 57 f9  d4 43 f6 fb ab ea 8f 8c
    bd 76 ce 9b ef 11 d7 d7  37 e3 f0 bf 3f f8 fe 7e
    f6 fb 69 e0 57 c2 ec 08  15 f5 dd ae c5 40 f3 1f
    bc 95 77 b9 73 27 df 5d  55 04 ff af 6d 95 23 0d
    d7 45 65 71 f4 5f f5 5d  53 7d 5f 21 54 45 00 f6
    34 35 cf 39 68 4b 57 5f  55 70 82 b7 7b c7 dc 37
    fc 5c 74 1d 93 55 86 d5  76 70 39 ea be ba 69 4d
    55 dd cc ab 6f dd fe d5  63 51 ab fb 07 57 77 3d
    3d 74 df ec df 9c 96 a7  7d b6 c7 f5 55 05 55 d6
    5b 0d ff bd 57 bb dd 99  f5 16 ef 7e 4d 28 25 c2
    3d 1d ff 15 e7 55 7f c8  35 56 d7 e7 db 7a 2d 61
    f5 74 c1 15 cf 59 ff ae  f1 d4 2b 4d 57 1d 55 6f
    35 f6 19 9f c7 3c c7 5c  5f 03 23 f4 ac d1 1d d3
    d5 75 ef bf d5 a7 ff 75  75 6d 45 0b c8 99 b6 66
    b6 67 25 71 8f f8 39 e4  73 7e ed c7 ec ef 49 e5
    07 1d dd 89 f7 f6 7f fc  7c 7d 3d ff 09 d9 fe 6c
    bd 56 d9 96 e5 d9 0b 3c  76 15 bd a3 11 bb b2 3c
    4d 75 96 43 f1 ff e3 c2  17 55 15 07 1f 3f 6c 54
    94 5f f7 19 aa 37 78 ce  5f df 79 d4 dc 3f b7 e4
    c4 be b6 f5 cd f5 7f d9  69 d7 51 f3 2b 92 fc 8c
    d1 fc 0f 36 f7 a4 41 f7  f3 9f 57 4a 7f ce cb 8a
    28 5d 31 df 7f 9e d1 ef  1d d7 b7 13 ff 75 7c de
    dc 5d bb 9a a4 fb d2 83  d1 d5 51 50 7c fb ec dd
    fb f1 ec c2 2f 19 46 fb  5d f5 44 7d c7 1e 59 58
    52 97 08 4d 7f a6 df fd  55 cf 98 fe da 8d 5a a6
    f5 db fa d5 75 5e db 14  3c 63 fe d0 25 e5 6d 2c
    54 e6 95 9b 97 8f 49 f6  50 7b be be 2b 12 ff eb
    e5 d5 1e 4c 32 e7 f9 e7  78 57 d9 11 35 c4 17 df
    5d f7 b7 e7 16 4a c7 ab  2e fc 61 73 9f 21 47 56
    7d b5 77 28 55 df 67 f3  d5 3d f2 fc fb 9a cf 87
    5f 74 56 0c eb 53 f1 79  fb 9b b9 db 56 c1 1c 93
    ba bd b0 f2 50 0b 81 57  71 f3 7b 73 17 b7 bc fb
    57 18 07 f4 ca f2 f6 0d  04 7d d6 5d d7 60 11 77
    97 7d 7c d8 dc d7 51 21  4f d5 1d dd 7e e2 b7 53
    7b 5d fc e1 fe 77 d0 f4  ed 94 d2 38 fa 2a ff 17
    d5 50 1f c5 ed 92 55 37  a1 55 1c f4 77 ea 7e 1f
    dd e5 58 bd 86 8a 79 e5  df a6 e3 6a 1c bc 6c d9
    7f f7 b9 f5 cd 02 7d b7  56 7a bd a9 32 a8 ff 0b
    01 3e eb 76 eb 9b df 57  57 57 07 49 db f4 6f ed
    3f a9 6a 6a ee 1d ff f9  ad cb c4 59 2e 9a b3 57
    13 71 5f d5 bb ff f7 bf  d6 fd fb f1 ec b5 b8 45
    df 37 19 5f df 1b fd 3e  55 57 98 e7 c5 3d 57 7d
    OOB:
    d7 d3 6b fb 1d 78 07 df
    91 dc 1f bb 9b e5 79 66
    09 f3 bd 20 c2 2b 7b 67
    b5 1b 3d b4 7d 66 db fb
    bd 7a bb 6d f4 69 4f 25
    fb df f6 fb 1d e3 fb 7d
    f4 ff 7d de 35 22 73 2a
    7d 7f de 75 b1 79 d3 3c
    U-Boot# 


    Please suggest,






  • Vidya,

    Are you able to reproduce this issue in other custom board ? Have you tried changing the NAND device ?

    Regards,
    Senthil
  • Hi,

    We have used NAND chip of different part no.(MT29F1G08ABBDAHC-IT) in other custom boards and its working.

    We have connected wait state 0 to Nand chip as per your suggestion but still it dint help.

    Can you tell us how to read and write to the full Nand chip through u-boot command.

    I suspect writing to 0th location is creating error message.

  • Vidya,

    As the NAND chip on the other board is working fine, i suspect the problem with the NAND device or the electrical interface on the board you are debugging now.

    Titus would help you on read and write to the full Nand chip through u-boot command.

    Regards,
    Senthil
  • Dear Vidhya,
    Can you please try the following command and give you the log.

    md 0x80000000
    mw.l 0x80000000 0xa5a5a5a5
    nand erase 0x100000 0x20000
    nand dump 0x100000
    nand write 0x80000000 0x100000 0x20000
    nand dump 0x100000
  • Hi ,

    Sorry for delay response,

    As Senthil said, there might be defect in nand device.So we replaced the chip completely and placed new nand chip of same part number.

    Even in this case with wait state1 , we were not able to perform read and write. Then , we connected R/B signal to  wait state 0  and were able to perform read/write to nand flash without any errors.

    I was able to go through all steps as mentioned by titus.

    But i want to read and write to whole 512MB nand memory and confirm that whole nand chip is working fine.

    Please suggest,

  • Vidya,

    Glad to know that you have a working NAND with wait state 0. Since the EVM also using wait 0, this code should be working with wait 0 in your custom board without any modification.

    As Titus suggested in previous post, did you try the following commands to read and write whole NAND memory ?

    md 0x80000000
    mw.l 0x80000000 0xa5a5a5a5
    nand erase 0x100000 0x20000
    nand dump 0x100000
    nand write 0x80000000 0x100000 0x20000
    nand dump 0x100000

    Regards,
    Senthil
  • Hi,

    Yes i tried as Titus suggested. But that write command  fills only 128 Kb starting from 0x100000 location. How to fill whole nand memory of 512MB.

    Can i use below command to write into nand memory starting from 0 location like below ,

    nand write 0x80000000 0 0x20000000

    Will above command affects u-boot location ?


    Below is Titus commands log,

    U-Boot# md 0x80000000
    80000000: 00000000 22222222 dddddddd dddddddd    ....""""........
    80000010: 44444444 44444444 bbbbbbbb bbbbbbbb    DDDDDDDD........
    80000020: 88888888 88888888 77777777 77777777    ........wwwwwwww
    80000030: 11111111 11111111 eeeeeeee eeeeeeee    ................
    80000040: 22222222 22222222 dddddddd dddddddd    """"""""........
    80000050: 44444444 44444444 bbbbbbbb bbbbbbbb    DDDDDDDD........
    80000060: 88888888 88888888 77777777 77777777    ........wwwwwwww
    80000070: 00000000 00000000 00000000 00000000    ................
    80000080: 7008aa08 2b0d4fad 420ed4c2 9fc11ad5    ...p.O.+...B....
    80000090: 08241e85 287b6c35 356b9188 e65e189c    ..$.5l{(..k5..^.
    800000a0: d0d58d96 ee6cc157 2074c88c 47d41d4d    ....W.l...t M..G
    800000b0: 47028460 45efedf1 a06641c8 698d3c16    `..G...E.Af..<.i
    800000c0: 88271087 1d7a5455 8d4286c2 05b85594    ..'.UTz...B..U..
    800000d0: 94bb34c3 9d9ee565 eb104a16 67cc16d1    .4..e....J.....g
    800000e0: 41057b6f acd10a55 fd91514d c16fde4f    o{.AU...MQ..O.o.
    800000f0: 1c4b713b d4a43d65 02ad77b4 8fed99f5    ;qK.e=...w......
    U-Boot# mw.l 0x80000000 0xa5a5a5a5
    U-Boot# nand erase 0x100000 0x20000
    
    NAND erase: device 0 offset 0x100000, size 0x20000
    Erasing at 0x100000 -- 100% complete.
    OK
    U-Boot# nand dump 0x100000
    Page 00100000 dump:
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff  ff ff ff ff ff ff ff ff
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
    U-Boot# nand write 0x80000000 0x100000 0x20000
    
    NAND write: device 0 offset 0x100000, size 0x20000
     131072 bytes written: OK
    U-Boot# nand dump 0x100000
    Page 00100000 dump:
            a5 a5 a5 a5 22 22 22 22  dd dd dd dd dd dd dd dd
            44 44 44 44 44 44 44 44  bb bb bb bb bb bb bb bb
            88 88 88 88 88 88 88 88  77 77 77 77 77 77 77 77
            11 11 11 11 11 11 11 11  ee ee ee ee ee ee ee ee
            22 22 22 22 22 22 22 22  dd dd dd dd dd dd dd dd
            44 44 44 44 44 44 44 44  bb bb bb bb bb bb bb bb
            88 88 88 88 88 88 88 88  77 77 77 77 77 77 77 77
            00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00
            08 aa 08 70 ad 4f 0d 2b  c2 d4 0e 42 d5 1a c1 9f
            85 1e 24 08 35 6c 7b 28  88 91 6b 35 9c 18 5e e6
            96 8d d5 d0 57 c1 6c ee  8c c8 74 20 4d 1d d4 47
            60 84 02 47 f1 ed ef 45  c8 41 66 a0 16 3c 8d 69
            87 10 27 88 55 54 7a 1d  c2 86 42 8d 94 55 b8 05
            c3 34 bb 94 65 e5 9e 9d  16 4a 10 eb d1 16 cc 67
            6f 7b 05 41 55 0a d1 ac  4d 51 91 fd 4f de 6f c1
            3b 71 4b 1c 65 3d a4 d4  b4 77 ad 02 f5 99 ed 8f
            35 b2 c0 18 5e 08 7d 3b  4d 60 00 d6 15 f7 d2 c0
            67 93 16 e9 df f2 15 03  19 39 70 7b 05 51 eb 30
            1e 7e c7 4b 77 c4 b5 df  c1 12 18 f5 57 90 49 40
            98 0c 84 0d 55 60 30 25  e1 e1 14 67 37 87 ef 37
            47 40 bd 2b 3a 6f d5 26  95 04 73 a6 4f 71 c8 8c
            77 0d ad 8f 77 45 15 b7  03 a0 cf 81 4d 34 1a b8
            63 91 11 c0 25 1e d3 71  52 f8 59 0c 27 11 11 79
            40 50 56 49 16 15 13 2f  cb e5 45 5d 0b c5 36 d1
            85 02 32 f6 1a 49 4c bc  65 d2 c5 72 1d 47 48 4b
            4b 6c 26 41 5e 84 a8 2e  61 38 a4 00 44 c9 62 00
            53 54 00 72 75 95 f2 cd  10 6b 64 c3 17 9d 11 cd
            02 3c c8 c5 c5 19 c3 1c  0d 25 05 d1 55 86 d5 58
            8c 65 40 ec a1 d6 0b 76  0a a0 10 f3 60 13 f9 5f
            4e 23 48 4c 20 26 5f bb  ab 24 40 80 c0 f3 10 74
            06 08 52 0f dd 09 1e 63  57 10 30 c6 f5 f1 96 39
            02 0a 4d b6 e1 75 f6 b7  45 1b 58 41 d2 e2 5a a2
            07 b4 c1 7b 2d 17 d7 c0  3e 91 59 c5 c4 2d 37 a2
            e8 99 e8 53 3d 65 9d 93  a3 30 4b 1d 1c d7 2f 35
            1f f2 e6 14 c7 2d c2 7b  81 8e 22 06 d4 d0 f7 60
            39 56 82 3b 54 27 4a cc  8e 41 55 46 13 12 7a 67
            7b 56 15 52 77 b1 87 7c  03 0f c2 54 3d 49 6d 50
            d0 3f 3a e8 f4 5d b1 1e  e3 25 eb 0c f5 d7 d5 9c
            e4 03 24 64 46 70 67 65  52 92 20 b8 55 51 59 50
            81 39 05 a1 00 43 5d 34  42 2d 51 c6 f7 8a aa fc
            14 05 60 a4 f6 fb eb 1e  b1 d7 16 19 3b e9 77 4e
            33 d3 46 08 d0 27 81 b7  3c 54 93 0c 81 b7 5f 4f
            52 af e2 32 45 d1 9d b5  9a 54 dc 1b 0d 5f ff f5
            10 4c 70 d4 55 95 de bd  49 89 e6 75 ff 15 f0 2e
            73 70 b1 18 03 e6 1c fb  8a 13 db b4 4f 56 f5 45
            26 a9 00 f4 8c 79 94 f1  ec 75 44 55 19 72 a4 05
            eb 31 0e 2d cc df d8 9d  3c a9 04 83 5d 19 ea 05
            7b 94 5f 67 05 49 21 c9  25 54 62 8b 7f 74 5f 3e
            48 98 8e 13 40 05 84 eb  41 75 4f df 5e fd be fb
            64 19 20 c7 d4 54 03 e0  49 0c 18 dc d2 95 35 1a
            b7 5f 06 89 8b c6 db 10  80 43 57 7d 71 c7 45 45
            ce d9 45 80 b9 34 78 57  82 81 74 02 3d 50 ec e5
            89 6a 30 88 8a 98 da 08  58 65 f4 0c f1 74 0e 77
            98 51 b0 60 bf 57 9f 4c  5c 00 cc d8 a7 c4 ce fa
            68 cb a6 24 79 4f d8 41  49 09 76 19 d3 13 d3 cb
            64 80 34 55 65 1f 55 c4  44 0d 74 18 5d c8 df 11
            1e 47 33 90 76 9d bc 34  30 81 96 46 0f 44 e4 43
            2e 43 51 1f 6f 15 e0 23  d5 c8 c6 15 09 76 e6 b2
            68 12 13 cd 4c 46 6d 5f  32 61 7f c4 0a a4 5a bb
            00 8b 60 85 16 79 df 37  38 5c 51 d2 11 de d7 13
            9c c5 35 b9 4b c1 f1 51  04 9a d1 04 d1 8c f5 d0
            2a 9a d1 75 59 57 31 4a  90 16 95 01 fa b0 f0 a3
            3d 51 d4 ea 1d d1 de 92  c1 60 3d e8 e9 63 9f 96
            54 54 22 62 53 99 58 41  01 81 51 64 d9 ed 6e b6
            81 39 f0 88 97 21 e7 ed  4e 8e 88 12 41 b9 f8 5e
            10 9f b8 f6 f7 b5 57 45  49 31 0c 20 39 72 1f 64
            50 03 0c 50 f9 54 66 10  22 58 27 fa 3b 14 c7 8a
            15 70 05 64 77 93 d7 e0  58 01 e1 7a 58 b3 d8 ec
            11 76 10 45 9b 58 1c b7  a2 54 64 38 6a 91 4f a4
            11 14 64 81 65 14 d9 7f  c1 45 e8 03 4f 8d 9d d5
            82 15 01 6b 99 73 27 1b  40 07 1d c7 95 45 d5 53
            bd 29 49 30 d4 7c df 59  46 19 4e 28 fd 45 e2 7c
            40 10 02 50 51 52 b0 43  26 f4 30 5a d5 e8 bd 96
            d2 20 01 2f d5 53 e2 9b  e3 44 a8 c0 e6 b2 5f 9f
            d1 a8 40 41 dc b4 80 03  30 d6 a8 c5 41 4c 84 37
            23 b6 03 c5 d5 71 9e b3  2c 3a 58 ce 1f e5 85 0a
            e0 16 19 e2 6e 7d d5 48  02 d5 5b af df 31 0c de
            f2 87 91 d9 1d cf 37 1f  48 86 94 1c bf 1d 5c 93
            31 81 02 d9 82 75 7b fa  64 9e f8 59 19 40 46 ca
            09 8c 7c 03 40 67 54 d7  67 8a 8a b4 d5 67 dd d4
            2b 28 e4 34 f1 f0 a4 c2  36 c1 4b 71 58 68 15 8d
            3e b4 17 7c 7d 17 e7 ae  00 8c f7 d6 51 5d b0 cb
            8e ce 41 63 07 66 6c 03  2a 08 40 e1 d4 d3 6d 7c
            b0 e5 c0 84 00 1e 72 60  2d 5f c7 e0 64 d7 ca d7
            43 64 09 4b 70 91 10 17  7c e5 2d 2d c2 0c f8 45
            29 24 fd 00 71 19 91 23  34 e4 b1 ed 74 d7 2c 3c
            67 06 54 f9 54 41 76 7a  a9 e2 8d 0c ad 76 86 1b
            6f 00 54 97 35 e3 60 bb  33 68 fe 6e 92 f8 29 e8
            17 c0 e8 18 15 75 dd ac  81 40 a3 1c bc 95 77 b8
            31 23 8d 58 14 04 f7 ab  69 15 23 0c d7 45 65 31
            94 5f 71 5d 13 5d 5f 21  54 45 00 c6 34 31 cf 39
            68 43 50 5e 41 60 82 f7  5b 47 58 17 dc 5c 3c 1d
            13 55 82 90 76 70 11 e2  b6 98 61 49 55 8d cc aa
            6b d9 3a d1 62 51 8b f3  07 56 52 20 3d 64 5e ec
            46 9c 96 25 7c b6 c3 f5  15 05 10 d6 79 0d ff bd
            15 9b d5 99 75 14 ef 7a  4d 28 25 c0 35 1c b6 15
            a6 50 7d 08 35 52 d6 e4  db 7a 25 21 f1 44 c0 15
            cf 58 83 2a 31 d4 63 4c  57 18 55 03 35 f6 19 96
            c7 0c c5 00 5f 03 23 d4  8c d1 1d 03 d6 35 ef 2e
            85 a5 fe 35 55 6d 45 0b  88 09 b4 26 b6 27 25 70
            81 f0 38 e4 73 7e c5 c7  ac e6 49 e5 07 1d 5d 89
            b4 b4 3b ec 74 7c 7d 6f  01 c9 7e 4c bd 46 d9 96
            e5 d9 02 3c 56 1d b5 03  11 9b b1 0c 4d 74 97 43
            e1 98 61 c2 00 55 15 03  1f 1d 4c 54 94 5d f3 11
            aa 37 38 c6 5d df 79 d4  dc 3f 97 e4 c0 9a b6 f5
            89 f5 7f 59 69 c5 11 f1  03 10 bc 88 d1 7c 0f 32
            f3 24 41 e3 d0 9f 55 4a  6e 4e cb 0a 28 4d 31 5f
            57 0e 91 4a 1d c7 b7 13  df 74 7c ce 5c 5c b9 9a
            80 7b c2 83 91 55 51 d2  28 ca ec dc fb f1 ec c2
            0a 09 46 9b 11 f5 44 7c  c2 0c 58 58 52 97 09 4b
            73 a2 9e 48 51 8b 98 7e  d2 8d 5a a6 d0 db fa d4
            70 0a 9b 04 18 2a fc d0  25 e4 4c 2c 50 e6 94 9b
            97 8f 49 e6 50 7b ba bc  29 02 79 c0 c5 c4 0e 4c
            30 c3 f9 a6 78 56 d9 11  21 84 16 9e 55 67 37 e7
            16 4a c1 89 2c fc 61 73  98 00 46 52 75 91 77 28
            55 ca 45 d2 d5 15 f0 ec  32 9a ce 85 17 64 56 08
            cb 12 c1 19 d3 8b 39 4b  56 01 1c 02 ba b5 b0 92
            00 03 81 15 51 e3 23 53  15 37 b8 ea 15 18 04 94
            c8 10 36 05 04 55 d6 55  53 60 11 74 17 7d 5c d8
            98 d6 41 01 4b d5 14 1d  5a 22 a3 01 3b 4c fc c0
            76 37 c0 f4 ad 94 92 28  b8 2a 7f 03 d5 10 1b c5
            e0 92 41 33 81 11 14 f4  72 68 7a 1a dd e5 58 bd
            00 0a 19 a5 cf 22 e0 4a  14 3c 4c 19 7f 75 b9 e5
            89 02 01 b6 56 5a bd 89  32 a8 af 03 01 1e cb 66
            6b 8a ca 53 46 43 02 49  1b f4 6f e5 2a 88 6a 6a
            ae 4c ef 38 ac cb c4 59  2a 0a b3 57 03 71 5f 55
            bb fe e6 bf 94 f5 f3 f1  00 b5 b8 41 5f 17 11 1f
            5b 0b 78 2e 45 53 90 47  84 7d 57 65 d7 53 6b 3b
    OOB:
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            ff ff ff ff ff ff ff ff
            d4 5d 6f 7a 02 ae 40 62
            40 81 41 0e 64 dc a9 0e
            c5 7e 93 18 0e ef 9a 9a
            db bb 68 bd 2a 72 07 88
            bd 14 96 c2 ac 14 9b f2
    U-Boot#
    

  • Hi Titus,

    I want to know the u-boot build procedure to create image to boot it from NAND.

    I am using u-boot  version u-boot-2015.07+gitAUTOINC+5922e09363 and followed the procedure in board/ti/ks2_evm/README to build MLO image

    Supported image formats:
     - u-boot.bin: for loading and running u-boot.bin through Texas instruments
                   code composure studio (CCS)
     - u-boot-spi.gph: gpimage for programming SPI NOR flash for SPI NOR boot
     - MLO: gpimage for programming AEMIF NAND flash for NAND boot
    
    Build instructions:
    ===================
    Examples for k2hk, for k2e and k2l just replace k2hk prefix accordingly.
    Don't forget to add ARCH=arm and CROSS_COMPILE.
    
    To build u-boot.bin
      >make k2hk_evm_defconfig
      >make u-boot-spi.gph
    
    To build u-boot-spi.gph
      >make k2hk_evm_defconfig
      >make u-boot-spi.gph
    
    To build MLO
      >make k2hk_evm_defconfig
      >make MLO
    
    To build u-boot.bin
      >make k2hk_evm_defconfig
      >make u-boot.bin
    

    AEMIF NAND Flash programming instructions
    ======================================
    U-Boot image can be flashed to first 1024KB of the NAND flash using following
    instructions:
    
    1. Start CCS and run U-boot as described above.
    2. Suspend Target. Select Run -> Suspend from top level menu
       CortexA15_1 (Free Running)"
    3. Load MLO binary from build folder on to DDR address 0x87000000
       through CCS as described in step 2 of "Load and Run U-Boot on K2HK EVM
       using CCS", but using address 0x87000000.
    4. Free Run the target as described earlier (step 4) to get u-boot prompt
    5. At the U-Boot console type following to setup u-boot environment variables.
       setenv filesize <size in hex of MLO rounded to hex 0x10000>
       run burn_uboot_nand
       Once u-boot prompt is available, Power OFF the EVM. Set the SW1 dip switch
       to "ARM NAND Boot mode" as per instruction at
       processors.wiki.ti.com/.../*_Hardware_Setup.
    6. Power ON the EVM. The EVM now boots with u-boot image on the NAND flash.
    


    I tried the exact way as described above, but it dint work.

    Please guide,

  • Dear Vidhya,

    Building:
    cd u-boot-keystone
    make k2hk_evm_defconfig ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-
    make u-boot-spi.gph ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-
    make u-boot-nand.gph ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-

    Can you boot the u-boot on your K2H EVM (any boot method, NAND or SPI) ?
    If yes, its easy to update the u-boot from existing.

    NAND booting:
    ==============

    Boot switch : 0:0:0:0

    tftpboot 0x88000000 u-boot-nand.gph
    nand ecclayout set 1
    nand erase.part bootloader
    nand write 0x88000000 bootloader 0x60000
    nand ecclayout set 0

    SPI booting:
    =============
    Try to get u-boot shell when power up from any media (NAND or MSC MSRAM (CCS) etc., ) and do the following
    ------------------------------------------------------------------------------------------------------------
    tftpboot 0x88000000 u-boot-spi.gph
    sf probe
    sf erase 0 0x100000
    sf write 0x88000000 0 0x100000

    USB method:
    ----------------------
    fatload usb 0 0x88000000 u-boot-spi.gph
    sf probe
    sf erase 0 0x100000
    sf write 0x88000000 0 0x100000

    I've tried all the methods and get succeed.
    1) I've booted up the u-boot from CCS
    2) I've updated the u-boot on SPI
    3) I've updated the u-boot on NAND

    Please try this and update to me.
  • Hi,

    You have given me the step that has been used in u-boot version (uboot-keystone-2013.01) .In which below command  is been specified in Makefile to build the nand image.

    make u-boot-nand.gph 

    The u-boot version which i am using is u-boot-2015.07+gitAUTOINC+5922e09363 and they use differ command to build the u-boot for nand.

    I refereed READ-ME file in path  board/ti/ks2_evm/README and followed up the same procedure to build the nand ,

    To build MLO
      >make k2hk_evm_defconfig
      >make MLO
    
    Supported image formats:
     - u-boot.bin: for loading and running u-boot.bin through Texas instruments
                   code composure studio (CCS)
     - u-boot-spi.gph: gpimage for programming SPI NOR flash for SPI NOR boot
     - MLO: gpimage for programming AEMIF NAND flash for NAND boot

    and i ported the  MLO image in nand as per the instruction but it dint work.

    For booting through CCS,I followed up below commands

    make clean
    make k2hk_evm_defconfig ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-
    make u-boot.bin ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-

    and able to load the u-boot binary and get the prompt,

    
    

    Please suggest,


  • You have given me the step that has been used in u-boot version (uboot-keystone-2013.01) .In which below command is been specified in Makefile to build the nand image.

    make u-boot-nand.gph

    The u-boot version which i am using is u-boot-2015.07+gitAUTOINC+5922e09363 and they use differ command to build the u-boot for nand.

    I don't see any difference.

    Both are same.
    make u-boot-nand.gph

    make u-boot-nand.gph ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf

    We can also do like this to build the u-boot for NAND flash.
    export ARCH=arm
    export CROSS_COMPILE=arm-linux-gnueabihf-
    make u-boot-nand.gph

    We don't use MLO for our K2H EVM board. (for nand & spi based booting)

    You have to flash the "u-boot-nand.gph" for NAND flash and "u-boot-spi.gph" for SPI flash.

    What problem you are getting and what you want to do ?
    Want to boot NAND flash with (u-boot-2015.07+gitAUTOINC+5922e09363) u-boot ?

    Then you can get the u-boot prompt by loading u-boot.bin via CCS and then flash the u-boot-nand.gph by following command.
    tftpboot 0x88000000 u-boot-nand.gph
    nand ecclayout set 1
    nand erase.part bootloader
    nand write 0x88000000 bootloader 0x60000
    nand ecclayout set 0
  • Hi,

    I am getting this error when i compile using below command

     make u-boot-nand.gph ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-
    make: *** No rule to make target `u-boot-nand.gph'.  Stop.

    We dont have NOR in our customize board so only way to boot u-boot is through NAND.

    But i am not able to generate u-boot-nand.gph ,

    I have downloaded this u-boot from ti software downloads site as you suggest in our previous post conversation.

    Please guide,

  • Add the following entry in u-boot's Makefile.

    $(obj)u-boot-nand.gph: $(obj)u-boot.bin
    $(obj)tools/mkimage -A $(ARCH) -T gpimage -C none \
    -a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) \
    -n U-Boot -d $(obj)u-boot.bin $(obj)gph-u-boot.bin
    @dd if=/dev/zero of=$(obj)zero.bin bs=8 count=1 2>/dev/null
    @cat $(obj)gph-u-boot.bin $(obj)zero.bin > $@
    @rm $(obj)zero.bin

    Then try the following command.
    make u-boot-nand.gph ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-

    Without u-boot-nand.gph image, board will not boot from NAND flash.
    Please let me know how goes.
    I would like to suggest you to create a new post for your new request/problem.
  • Hi Titus,

    Thanks for your reply,

    I am able to compile u-boot for nand after adding script in Makefile. Have done some changes in script to compile and able to generate the image,

    u-boot-nand.gph:        u-boot.bin
                    $(objtree)/tools/mkimage -A $(ARCH) -T gpimage -C none \
                            -a $(CONFIG_SYS_TEXT_BASE) -e $(CONFIG_SYS_TEXT_BASE) \
                            -n U-Boot -d u-boot.bin gph-u-boot.bin
                    @dd if=/dev/zero of=$(obj)zero.bin bs=8 count=1 2>/dev/null
                    @cat $(obj)gph-u-boot.bin $(obj)zero.bin > $@
                    @rm $(obj)zero.bin

    Then followed below nand command to write image in nand and poweroff the board,

    nand erase.part bootloader
    nand write 0x82000000 bootloader 0x5cc30

    But when i powered on , u-boot dint get booted up from nand. In DEVSTAT register, i have selected nand boot mode but still dint work.

    I have no issues in  EVM u-boot booting.I compiled nand image in same manner and boot the image successfully. I compared the both image compiled from evm uboot and my latest u-boot -ver 2015 and it showed some difference.

    EVM U-BOOT
    
    U-Boot# md 82000000
    82000000: f0520500 0010000c ea000014 e59ff014    ..R.............
    82000010: e59ff014 e59ff014 e59ff014 e59ff014    ................
    82000020: e59ff014 e59ff014 0c0011a0 0c001200    ................
    82000030: 0c001260 0c0012c0 0c001320 0c001380    `....... .......
    82000040: 0c0013e0 12345678 0c001000 0004cd20    ....xV4..... ...
    82000050: 0004cd20 000afb08 000552f0 0badc0de     ........R......
    82000060: eb00003e e10f0000 e3c0001f e38000d3    >...............
    82000070: e129f000 ee110f10 e3c00a02 ee010f10    ..).............
    82000080: e59f03a8 ee0c0f10 eb00093b e1a04000    ........;....@..
    82000090: e1a05001 e1a06002 e24f0098 e1500006    .P...`....O...P.
    820000a0: 03a09000 0a000022 e1a01006 e51f3064    ....".......d0..
    820000b0: e0802003 e8b00600 e8a10600 e1500002    . ............P.
    820000c0: 3afffffb e51f0084 e0469000 e59fa06c    ...:......F.l...
    820000d0: e08aa000 e59f205c e0822000 e59f3058    ....\ ... ..X0..
    820000e0: e0833000 e5920000 e0800009 e5921004    .0..............
    820000f0: e20170ff e3570017 0a000007 e3570002    .p....W.......W.
    U-Boot#
    82000100: 0a000000 ea000006 e1a01221 e08a1001    ........!.......
    82000110: e5911004 e0811009 ea000001 e5901000    ................
    82000120: e0811009 e5801000 e2822008 e1520003    ......... ....R.
    82000130: 3affffeb e12fff1e 0004cd20 000551e0    ...:../. ....Q..
    82000140: 000551e0 ee070f15 ee070f9a ee070f95    .Q..............
    82000150: e59f02d8 e0800009 ee0c0f10 e12fff1e    ............../.
    82000160: e12fff1e e3a00000 ee080f17 ee070f15    ../.............
    82000170: ee070fd5 ee070f9a ee070f95 ee110f10    ................
    82000180: e3c00a02 e3c00007 e3800002 e3800b02    ................
    82000190: e3800a01 ee010f10 e1a0f00e e320f000    .............. .
    820001a0: e320f000 e320f000 e51fd154 e58de000    .. ... .T.......
    820001b0: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.
    820001c0: e1a0e00f e1b0f00e e24dd048 e88d1fff    ........H.M.....
    820001d0: e51f217c e892000c e28d0048 e28d5034    |!......H...4P..
    820001e0: e1a0100e e885000f e1a0000d fa000a6e    ............n...
    820001f0: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .

    u-boot-2015.07+gitAUTOINC+5922e09363
    
    U-Boot# md 82000000
    82000000: 20cc0500 0010000c ea0000be e59ff014    ... ............
    82000010: e59ff014 e59ff014 e59ff014 e59ff014    ................
    82000020: e59ff014 e59ff014 0c001060 0c0010c0    ........`.......
    82000030: 0c001120 0c001180 0c0011e0 0c001240     ...........@...
    82000040: 0c0012a0 deadbeef 0badc0de e320f000    .............. .
    82000050: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .
    82000060: e320f000 e320f000 e51fd028 e58de000    .. ... .(.......
    82000070: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.
    82000080: e1a0e00f e1b0f00e e24dd048 e88d1fff    ........H.M.....
    82000090: e51f2050 e892000c e28d0048 e28d5034    P ......H...4P..
    820000a0: e1a0100e e885000f e1a0000d fa00023b    ............;...
    820000b0: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .
    820000c0: e320f000 e320f000 e51fd088 e58de000    .. ... .........
    820000d0: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.
    820000e0: e1a0e00f e1b0f00e e24dd048 e88d1fff    ........H.M.....
    820000f0: e51f20b0 e892000c e28d0048 e28d5034    . ......H...4P..
    U-Boot#
    82000100: e1a0100e e885000f e1a0000d fa000229    ............)...
    82000110: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .
    82000120: e320f000 e320f000 e51fd0e8 e58de000    .. ... .........
    82000130: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.
    82000140: e1a0e00f e1b0f00e e24dd048 e88d1fff    ........H.M.....
    82000150: e51f2110 e892000c e28d0048 e28d5034    .!......H...4P..
    82000160: e1a0100e e885000f e1a0000d fa000217    ................
    82000170: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .
    82000180: e320f000 e320f000 e51fd148 e58de000    .. ... .H.......
    82000190: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.
    820001a0: e1a0e00f e1b0f00e e24dd048 e88d1fff    ........H.M.....
    820001b0: e51f2170 e892000c e28d0048 e28d5034    p!......H...4P..
    820001c0: e1a0100e e885000f e1a0000d fa000205    ................
    820001d0: e320f000 e320f000 e320f000 e320f000    .. ... ... ... .
    820001e0: e320f000 e320f000 e51fd1a8 e58de000    .. ... .........
    820001f0: e14fe000 e58de004 e3a0d013 e169f00d    ..O...........i.

    You could able to see the difference in both the screen shot. The initial value itself shows the difference.

    I suspect the compilation for nand image is not proper,

    Can you please clarify,

  • Vidhya,

    We recommend you to create new post for new issues. It is very difficult to keep track multiple issues in a post. Thank you for your understanding.
  • Hi Raja,

    The post and query is related to same issues wright from the starting.

    Our main issue is to boot uboot through nand and we started query on this and not yet got solved.

    It would be better if we continue on same posts because you know our history of issues we which faced and solved.

    Moving to new post makes us to start to explain wright from the beginning of the issue we faced and sorted out.

  • Vidya,
    I have suggested above as this thread has been answered with verified answers. Unfortunately, this thread has been addressed and followed up by "Titus" from the beginning and that may not be possible all the time. It will be difficult or may take more time to respond to this thread when he/she is not available.
    Thank you.
  • Hi Vidya,

    I have no issues in EVM u-boot booting.I compiled nand image in same manner and boot the image successfully. I compared the both image compiled from evm uboot and my latest u-boot -ver 2015 and it showed some difference.

    I would like to suggest to use the MCSDK's keystone u-boot source code.
    Have you tried TI released u-boot ?
  • Hi Titus,

    I would like to suggest to use the MCSDK's keystone u-boot source code.

    Initially i was working with EVM u-boot source code and it looked unstable for our board .When i mentioned about this during our initial posts,you recommend to download latest u-boot from ti site and check.

    I downloaded the latest u-boot from k2hk-evm-sdk-src-02.00.01.07.tar.gz (site software-dl.ti.com/.../index_FDS.html)

    Have you tried TI released u-boot ?

    I downloaded the latest u-boot from site

    Is this correct one ?

    Is th

  • Yes, its latest one and you downloaded correct one.
    With this SDK, you are able to build and run the u-boot on K2H EVM but not with your custom board ? Huh ?
  • Hi Vidya,
    Let me try the procesor SDK u-boot on K2HK EVM and update you.
  • Hi,


    I dint try this u-boot on K2H EVM.I started using it in our custom board directly.

  • Sorry, I've not tried latest processor SDK so far. yes I've seen the same behavior at my end too.
    Let me try the processor SDK u-boot on K2H EVM and update you.