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.

Building uboot with device tree support & verifying on BBB

Dear E2E Community,

Am using ti-sdk-am335x-evm-07.00.00.00 BSP's but am trying to build u-boot-2014.07 (which has verified boot feature, ie., from  http://lists.denx.de/pipermail/u-boot/2014-June/180845.html Step 1: Build U-Boot ),  instead of u-boot-2013.10-ti2013.12.01 which is in ti-sdk-am335x-evm-07.00.00.00

Could anybody please let me know  whether u-boot-2014.07 has BBB support in it, If so please let me know how this can be built with uboot device tree support & Flashed into the SD card along with uboot device tree with detailed procedure steps

As of now I replaced only MLO & uboot.img of  u-boot-2013.10-ti2013.12.01 with u-boot-2014.07 but am facing the below errors I think it might be expecting the same ie., FDT of uboot

U-Boot SPL 2014.07 (Nov 07 2014 - 14:23:11)
reading u-boot.img
reading u-boot.img
No valid FDT found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>
initcall sequence 80851108 failed at call 80833f84
### ERROR ### Please RESET the board ###

Could anybody please do the needful in resolving the above issue @ the earliest because am stuck with this from past 2 days

Kindly do the needful,

Awaiting for your replies,

Many Thanks in advance,

  • I think SPL is expecting dtb appended with u-boot.

    To start with following portion of u-boot readme might help you,

    Device tree:
                    CONFIG_OF_CONTROL
                    If this variable is defined, U-Boot will use a device tree
                    to configure its devices, instead of relying on statically
                    compiled #defines in the board file. This option is
                    experimental and only available on a few boards. The device
                    tree is available in the global data as gd->fdt_blob.
    
                    U-Boot needs to get its device tree from somewhere. This can
                    be done using one of the two options below:
    
                    CONFIG_OF_EMBED
                    If this variable is defined, U-Boot will embed a device tree
                    binary in its image. This device tree file should be in the
                    board directory and called <soc>-<board>.dts. The binary file
                    is then picked up in board_init_f() and made available through
                    the global data structure as gd->blob.
    
                    CONFIG_OF_SEPARATE
                    If this variable is defined, U-Boot will build a device tree
                    binary. It will be called u-boot.dtb. Architecture-specific
                    code will locate it at run-time. Generally this works by:
    
                            cat u-boot.bin u-boot.dtb >image.bin
    
                    and in fact, U-Boot does this for you, creating a file called
                    u-boot-dtb.bin which is useful in the common case. You can
                    still use the individual files if you need something more
                    exotic.

  • Thanks a lot for your replies Ankur,

    But I have compiled u-boot-2014.07 using the following command

    appusony@appusony-laptop:~/ti-sdk-am335x-evm-07.00.00.00/board-support/u-boot-2014.07$ make O=b/am335x_boneblack_vboot ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- am335x_boneblack_vboot_config all

    After compiling I got the binaries as below

    appusony@appusony-laptop:~/te/TUNSTALL/board-support/u-boot-2014.07/b/am335x_boneblack_vboot$ ls
    arch   common  drivers  examples  include  Makefile  net      spl         test   u-boot      u-boot.dtb      u-boot-dtb.img  u-boot.lds  u-boot.srec
    board  disk    dts      fs        lib      MLO       scripts  System.map  tools  u-boot.bin  u-boot-dtb.bin  u-boot.img      u-boot.map

    Because previously I just replaced the MLO & uboot.img of u-boot-2013.10-ti2013.12.01 with u-boot-2014.07 because of which it resulted  in the below error

    U-Boot SPL 2014.07 (Nov 07 2014 - 14:23:11)
    reading u-boot.img
    reading u-boot.img
    No valid FDT found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>
    initcall sequence 80851108 failed at call 80833f84
    ### ERROR ### Please RESET the board ###

    No Could you please let me know How & what are all the images of u-boot-2014.07(which has device tree support) needs to flashed onto the SD card inorder to get the uboot prompt with detailed procedure & can be verified the same on the target ie., Beaglebone black

    Awaiting for your replies,

    Many Thanks in Advance,

  • Hi Srini

    reading u-boot.img
    No valid FDT found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>
    initcall sequence 80851108 failed at call 80833f84
    ### ERROR ### Please RESET the board ###

    Have you used "u-boot-dtb.bin"  as said warning message instead of u-boot.img or both ?

    If done already and what about the results ?

    Or else try to embedded the "dtb" settings in u-boot itself as warning message said 'CONFIG_OF_EMBED",

  • Hi Srini,

    I haven't used u-boot 2014 so i am not sure about error you are facing :(
    Apart from what Titus as suggested you can compare 2013 configuration and 2014 u-boot configuration.
    And remove unnecessary changes.

    Thank you,

    Regards,
    Ankur

  • Hi Titus

     yes.. I have used both use u-boot-dtb.bin & uboot.img  & I have tried with only u-boot-dtb.bin as well by placing it in the /media/boot/  folder still the result is same

    reading u-boot.img
    No valid FDT found - please append one to U-Boot binary, use u-boot-dtb.bin or define CONFIG_OF_EMBED. For sandbox, use -d <file.dtb>
    initcall sequence 80851108 failed at call 80833f84
    ### ERROR ### Please RESET the board ###

    Am using u-boot-2014.07 not the u-boot-2013.10-ti2013.12.01 which is in SDK

    Could you please let me know where to embedd CONFIG_OF_EMBED in which file (ie., board configuration file for beaglebone black)of u-boot-2014.07 source code so that I do the same changes here & verify it here, Apart from these we need to include  CONFIG_OF_CONTROL as well (as per the link , http://www.denx-cs.de/doku/?q=m28verifiedboot inorder to implement my verified boot feature)

    So could you also please verify & let me know from your end, if it works from your end please let me know the steps

     

    Many Many Thanks in advance for your support so far

    Awaiting for your replies,

     

     

  • Hi Srini,

    You need to define 'CONFIG_OF_EMBED' in board configuration file located at "include/configs"

    Actually I don't have BBB board (AM335x GPEVM too)with me and given to some other team.

    So, I'm helpless and sorry.

  • Hi Titus,

    Thanks a lot for your support & replies,

    Could you please confirm the following

    1. Atleast whether all beaglebone black related BSP support whatever that is avialable in u-boot-2013.10-ti2013.12.01 is available in u-boot-2014.07 or do we need to explicity port beaglebone black features available in u-boot-2013.10-ti2013.12.01 to u-boot-2014.07

    2. And am trying to modify in /u-boot-2014.07/include/configs$ vi am335x_evm.h ie., I am trying to define the flag as shown below

    #ifndef CONFIG_SPL_BUILD
    # define CONFIG_FIT
    # define CONFIG_TIMESTAMP
    # define CONFIG_LZO
    # ifdef CONFIG_ENABLE_VBOOT
    # define CONFIG_OF_EMBED
    # define CONFIG_OF_CONTROL
    # define CONFIG_OF_SEPARATE
    # define CONFIG_DEFAULT_DEVICE_TREE am335x-boneblack
    # define CONFIG_FIT_SIGNATURE
    # define CONFIG_RSA
    # endif
    #endif

    Could you please confirm whether this is the correct place for defining the flag

    Could you please confirm  regarding the above two points mentioned as early as possible

    Many Thanks in advance again

  • Thanks a lot Titus w.r.t the above issue , The above issue is resolved, now am able to get the uboot prompt after defining the flag as shown above

    Many thanks again for your support w.r.t this issue

  • Hi Srini,

    Sounds good.

    Thanks for your update.

    I'm glad that you able to solve the problem.

    I would like to help other too by briefing about your fix.