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.

C6455 second stage bootloader about DDR

hello to all:

          I have some question about  C6455 second bootloader.

        when I first use C6455,I only used Memory with L2; So I can copy the L2's data to flash,  it can boot the date from flash to L2. it is success.

       now  I used the DDR in the code :

         #pragma DATA_SECTION(gBufferRcvPing, ".ddr");Uint8 gBufferRcvPing[1048576] = {0};

       I want to ask :

      (1)  whether I should copy the DDR'data used  to the flash when download the code ? and whether boot the data to the DDR in the bootloader code ?  why??

    (2) I  think  :   gBufferRcvPing in the DDR  is the data section,  whether it is necessary for the code run?   the code section is only use the  gBufferRcvPing's address, so I think even it is not  copy to DDR , the code should be run sucess,  but It is not run sucess ?   I want to Know why ???

    Thanks for your answer!!!


  • (2) I think : gBufferRcvPing in the DDR is the data section, whether it is necessary for the code run? the code section is only use the gBufferRcvPing's address, so I think even it is not copy to DDR , the code should be run sucess, but It is not run sucess ? I want to Know why ???



    The code seems "gBufferRcvPing" is a buffer to be used in code and not for booting purpose.

    If you want to boot from DDR then you may need to change the linker command file (.cmd) for .text and .code section etc.,

    Could you attach the old .cmd file that ran successfully earlier with L2 memory and newly modified for DDR2 which is not working.

    http://processors.wiki.ti.com/index.php/Pragmas_You_Can_Understand

  • Titusrathinaraj Stalin:
    Thanks for your answer. It is very useful for me .
    I use the same .cmd file for the old and new project.
    The quetion I want to know is that : whether it is necessary for the new project which use buffer -"gBufferRcvPing" in the code to boot "gBufferRcvPing" from flash to DDR. why? In the new project, I used the "gBufferRcvPing" in the DDR, I find it will not work when I don't boot the "gBufferRcvPing". I want know why .
    In my view, I think only the code section boot, the code should be run. the code only use the address of "gBufferRcvPing", so even I don't boot the value of gBufferRcvPing, the code should be ran successfully, I think.
    Could you tell me the necessary of booting the global array --- "gBufferRcvPing"?
    Thanks very much
  • What project are you working ?
    Is that from TI released or own code ?
  • It is my own code.
    could you answer my question? The only difference of gBufferRcvPing for boot is it setted is in L2 or DDR?
    whether it is necessary for the new project which use buffer -"gBufferRcvPing" in the code to boot "gBufferRcvPing" from flash to DDR.?
    In my view, I think only the code section boot, the code should be run. the code only use the address of "gBufferRcvPing", so even I don't boot the value of gBufferRcvPing, the code should be ran successfully, I think.
    Could you tell me the necessary of booting the global array --- "gBufferRcvPing"?
    Thanks very much
  • Sorry I was totally messed up. :-(

    I'm not able to guess what you are asking.

    Able to run your program successfully through CCS after modified the linker command file (.ddr) ?

    You would get the C6455 default linker command file in the following link.

    http://processors.wiki.ti.com/images/5/52/C6455.zip
    http://processors.wiki.ti.com/index.php/Linker_CMD_Files_for_CCS#C6000

    Sorry, I'm helpless if you are not shared the code (linker command file (.cmd)) and source code), because I don't know what is the "gBufferRcvPing" buffer and its purpose.

    We can change the program entry point by accessing the "c_init" (.text)
    http://processors.wiki.ti.com/index.php/Accessing_c_int00
  • my cmd is :

    -l trackcfg.cmd

    SECTIONS {

    .boot_load > BOOT
    .ddr > DDR2

    }


    The only difference of gBufferRcvPing for boot is it setted is in L2 or DDR.
  • Sorry for the delayed response on this.

    You mean that if you modified the .cmd file like below (not working case)  , you are not able to succeed. Is that correct ?

    Working:

    #pragma DATA_SECTION(gBufferRcvPing, ".l2");Uint8 gBufferRcvPing[1048576] = {0};

    -l trackcfg.cmd

    SECTIONS {

    .boot_load > BOOT

    .l2> L2

    }

    Not working:

    #pragma DATA_SECTION(gBufferRcvPing, ".ddr");Uint8 gBufferRcvPing[1048576] = {0};

    -l trackcfg.cmd

    SECTIONS {

    .boot_load > BOOT

    .ddr > DDR2

    }