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.

Firmware loading question

Hi, All!

On my custom board I changed memory map for 512MB systems, as stated in: http://processors.wiki.ti.com/index.php/EZSDK_Memory_Map

While loading firmware I see this messages:

Loading HDVICP2 Firmware :FIRMWARE: I2cInit will be done by M3
FIRMWARE: memory map bin file: /usr/share/ti/ti-media-controller-utils/mm_dm81xxbm_512M.bin
FIRMWARE: isI2cInitRequiredOnM3: 1
MemCfg: DCMM (Dynamically Configurable Memory Map) Version : 2.1.2.1
*** ElfLoader_load: Failed to write args! (ensure .args section is big enough)
Error [0x0] at Line no: 1938 in file /home/karak/ezsdk_5_04_00_11/component-sources/syslink_2_10_03_20/packages/ti/syslink/utils/hlos/knl/Linux/../../../../../../ti/syslink/procMgr/cc
FIRMWARE: Memory Configuration status : In Progress
FIRMWARE: 1 start Successful
Loading HDVPSS Firmware :FIRMWARE: I2cInit will be done by M3
FIRMWARE: memory map bin file: /usr/share/ti/ti-media-controller-utils/mm_dm81xxbm_512M.bin
FIRMWARE: isI2cInitRequiredOnM3: 1
MemCfg: DCMM (Dynamically Configurable Memory Map) Version : 2.1.2.1
*** ElfLoader_load: Failed to write args! (ensure .args section is big enough)
Error [0x0] at Line no: 1938 in file /home/karak/ezsdk_5_04_00_11/component-sources/syslink_2_10_03_20/packages/ti/syslink/utils/hlos/knl/Linux/../../../../../../ti/syslink/procMgr/cc
FIRMWARE: Memory Configuration status : In Progress
FIRMWARE: 2 start Successful

What does it mean this messages (selected bold font)?

How I can correct my system to solve this problem?

Thank you.

P.S. Sorry for my English.

  • I see the same error on the ti814x board with the 1G memory map.  Can somebody please help?

    Thanks,

  • Those error messages indicate that the ELF loader was not able to write argc/argv to the static .args section target memory.

    The ELF loader, when passed non-zero argc, will write argc and argv into the .args section in target memory, which will then be passed to main().  This message indicates that your .args section isn't big enough for the argc int and argv[] pointers.  If you want to check yourself, you can run the following command and look at the output for the .args section:
        % readelf  --sections <elf_executable_name>

    You can set the size of your .args section in your .cfg file:
        Program.argSize = 0x200;

    Here's a link to the relevant twiki documentation at RTSCpedia: http://rtsc.eclipse.org/cdoc-tip/xdc/cfg/Program.html#arg.Size

    Newer SYS/BIOS releases will default to a 0-size .args section.

    Regards,

    - Rob

     

  • Thank you very much for explaining.  I don't not which .cfg to change, can you give me the exact file name or which package it belong to?

    I will try to change it in a few place in the mean while.

    Thanks again.

    -Johny.

  • Johny Bui said:
    I don't not which .cfg to change, can you give me the exact file name or which package it belong to?

    Johny,

    I am not familiar with the layout of the EZSDK, so I don't know what .cfg file is used.  Can you post a new thread with this question?  Hopefully someone familiar with the EZSDK will respond.  It will help if you can provide the version of the EZSDK in that query.

    Regards,

    - Rob

  • Hi Robert!

    Thank you for your answer.

    In EZSDK all firmware files are prebuilt and I can't compile their (as I understood). In this documents http://processors.wiki.ti.com/index.php/EZSDK_Memory_Map and related files I can't found any useful information about .args section (using context search with .args) in all EZSDK files.

  • Hi,

    Anyone who might know about how to modify a remote executable's .args section size has long since stopped paying attention to this thread, so I can only recommend that you start a new thread, possibly with the title "How can I modify EZSDK firmware files".

    The firmware files are loaded by SysLink's ProcMgr module.  If a non-zero argc and non-NULL argv are passed to ProcMgr_load() then there needs to be space allocated to the .args section of the remote exectuable in which to write the argc/argv[].  The only way to successfully load a remote executable with a zero-sized (or too-small-sized) .args section is to pass argc=0 (or argc/argv with storage requirements less than the size of the .args section).

    FYI, I don't expect you to know how your Linux application uses the argc/argv that's passed to ProcMgr_load(), but if there's any way you can affect that (such as through application command line arguments, some of which might be targeted for the remote core exectuable) then you might be able to avoid the issue.

    If the EZSDK comes packaged with a prebuilt firmware executable with a 0-size .args section and an application that requires .args space, then it would seem to be a broken deliverable from the EZSDK team.  At this point we're not even sure that the problem lies with a 0-sized .args section, and my "readelf" suggestion would either prove or disprove that assumption (I'm assuming you can at least find the firmware executable that fails to load).

    Regards,

    - Rob