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.

Compact Optomized SRIO Boot loader for 6455



Trying to optmize the 6455 SRIO Bootloader to reduce its size to ~20KB, please offer suggestions.

Thanks,

  • Herb was trying to post the question from me as a favor and the question got a little garbled in translation. What really is needed is a smaller TCP/IP stack for a TFTP bootloader. We are using a 6455 evm and trying to boot the mezzanine by TFTP, however the I2C ROM is only 128KB which is a tad smaller than our bootloader which came out to about 174KB. After removing some unnecessary functions (HTTP, Telnet) we got the code size down to 169 KB (still too large…). We were wondering if there was example code for something like this? Or size optimized NDK libraries so we could get our bootloader shrunk down. Another option is to boot from SRIO if it will fit in 128KB.

    Thanks!

  • Tim,

    Let me make sure I understand the question...

    So to test your desired TFTP boot, you are using a C6455 EVM (DSK board + mezzanine), where the mezzanine is bootstrapped to do an initial I2C boot  to load a secondary bootloader that contains the NDK software.  Once this secondary bootloader is loaded into the DSP, you want to boot your image through the ethernet port of the mezzanine card using the desired TFTP protocol.  Is that correct?  And the problem is that the secondary bootloader containing the NDK software is too big to put in the mezzanine's I2C ROM? The first question is, did you use the -ms3 compile option, to optimize for code size?  If not, that should help out.  Assuming you've tried that, we don't really have any canned examples or optimized NDK libraries to support only one type of communication protocol.  Since we are supplying the NDK source code, we leave that up to the user to strip out anything that is not needed.  I believe that  the TFTP is one of the basic protocols, so most of the other components should be removeable.  I'll ask around to see what NDK bare-bone components are required for TFTP, maybe we can help identify these.  I'll let you know.

    The other option for testing out your TFTP bootloader code, might be to simply load this secondary bootloader via the emulator, then perform the boot via the TFTP through the ethernet.  Also, as you mention, SRIO is an option.  With SRIO, you could use one of the native SRIO bootmodes and never even use the I2C.

    Regards,

    Travis

  • Tim,

     

    Here is the response I received....

    *****************

    NDK used to support multiple libraries at one time with different variants. For example: There was IPv4 core, IPv4 core + PPP, IPv4 core + NAT, etc.

    Some time during release 2.0 it was decided that we would only release 1 library which was IPv6 core + IPv4 core. You can easily rebuild out all the IPv6 support by ensuring that the _INCLUDE_IPv6_CODE is not defined in the compiler options. This will reduce the size of the library significantly.

    This will basically reduce the library to only the core IPv4.  TFTP needs Sockets, UDP, IPv4, ARP, NIMU (Driver Interface). So basically the only thing additional you can get rid of is TCP. I am not sure its worth all the effort but I think this is what they will need from the ndk\src\stack:
    bind
    fdt
    ip
    nimu
    node
    res
    route
    rtc
    sock
    udp
    utils

    The OS & NETCTRL directory would require everything. In the NETTOOLS directory you will only need to build the files in the TFTP directory. Everything else can be removed.
    ************************


    Hope that helps,

    Travis