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.

TDA4VM: RootFilesystem format for flashing using dfu tool

Part Number: TDA4VM

Hi TI Team,

I want to flash root file system from Ubuntu PC to EVM's eMMC memory using dfu utility. I found below command for flashing it:

sudo dfu-util -c 1 -i 0 -a 1 -D <rootfs>

But, don't know what is the format of the root file system (.jffs2 or ext4, .img etc...).

Can you please let me know, what should be the format of rootfile system here and also the command for creating the suitable format of rootfs, for flashing to the eMMC.

Thanks in advance.

Best Regards,

Sainath

PS) I am able to flash upto bootloaders and also able to boot it from eMMC. Only thing is not able to flash rootfs.

  • Hi,

    I was able to flash the rootfilesystem by creating a .ext4 type image from existing minimal root filesystem.

    The size of the root file system which I have flashed is 260MB.

    But, If I try to flash a rootfilesystem.ext4 whose size is aroung 2.5GB, the host side dfu tool is giving an error that "File size is too big".

    Can anyone please tell me the file size limit of dfu-util tool?

    Is there any way to increase this limit?

    Thankyou.

    Regards,

    Sainath

  • Hi,

    This could be related to CONFIG_SYS_DFU_DATA_BUF_SIZE setting of u-boot. Snippet below from README file of u-boot.
    Try experimenting with dfu_bufsiz u-boot environment variable.

                    CONFIG_SYS_DFU_DATA_BUF_SIZE
                    Dfu transfer uses a buffer before writing data to the
                    raw storage device. Make the size (in bytes) of this buffer
                    configurable. The size of this buffer is also configurable
                    through the "dfu_bufsiz" environment variable.
    

    Regards,
    Vishal

  • Hi Vishal,

    Thanks for the reply. 

    I have changed the buff size but still the issues remains the same.

    I am facing with below problem on the host side.

    I think changing the 'dfu_bufsiz' size on the target side cannot fix this issue (just an assumption). Because, the problem is on the host side.

    The size of the file is around: 2.5GB

    Can you please suggest what we can do on the host side.

    Thank you.

    Sainath

  • Hi Sainath,

    Looks like it's a tool limitation, you can see the dfu-util source (git.code.sf.net/p/dfu-util/dfu-util) where they are limiting the size.

                    offset = lseek(f, 0, SEEK_END);
    
                    if ((int)offset < 0 || (int)offset != offset)
                            err(EX_IOERR, "File size is too big");

    Regards,
    Vishal

  • Hi Vishal,

    Thank you very much for your effort.

    It helped to finally found the problem. And we are able to fix this by doing some code changes to accommodate large file size.

    Thank you.

    Best Regards,

    Sainath