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.

AM3352: U-Boot configuration

Part Number: AM3352

Hello,

We are using am3352 in our design with kernel 4.14.67 from TI SDK. We were using a previous U-Boot version and now we moved to 2019.01 from TI.

Porting is done to our board and it is working fine, but we have a problem with the default start-up.

In the previous version default start-up was showing some traces and login/password on serial console (ttyO4) .

In this new version only "U-Boot 2019.01-1.0.11+ (Apr 07 2020 - 10:02:31 +0200)" is shown and it is not possible to login on serial console.

But, if we stop at u-boot prompt and run "boot" command then serial console is again ready for login into the system.

Could you please help us to find what we need to change to set the serial console as dafault to login into the system?

Best regards and thank you

Angel

  • Hi Angel,

    Angel Falcon said:

    In this new version only "U-Boot 2019.01-1.0.11+ (Apr 07 2020 - 10:02:31 +0200)" is shown and it is not possible to login on serial console.

    But, if we stop at u-boot prompt and run "boot" command then serial console is again ready for login into the system.

    I don't understand what you are describing. First, U-Boot only shows one line and it is not possible to login? But then, you can somehow stop at the U-Boot prompt and use the console?? Can you please share some logs and provide some more details...

    Thanks, Andreas

  • Hi Andreas,

    Sorry If you don't understand the question, I will try to give more details.

    1. I connect the board to the serial port, switch it on and press " " (space bar) to stop execution at u-boot prompt, so I can send commands to u-boot

    U-Boot 2019.01+ (Apr 15 2020 - 08:34:35 +0200)

    => version
    U-Boot 2019.01+ (Apr 15 2020 - 08:34:35 +0200)

    arm-linux-gnueabihf-8.3-gcc (GNU Toolchain for the A-profile Architecture 8.3-2019.03 (arm-rel-8.36)) 8.3.0
    GNU ld (GNU Toolchain for the A-profile Architecture 8.3-2019.03 (arm-rel-8.36)) 2.32.0.20190321
    => printenv bootcmd
    bootcmd=run nandboot

    2. Now, If I want to load the linux system I just send commnad "boot", system is loaded and I can login into the system

    => boot
    Booting from nand ...

    NAND read: device 0 offset 0x200000, size 0x80000
     524288 bytes read: OK

    NAND read: device 0 offset 0x480000, size 0x480000
     4718592 bytes read: OK
    ## Flattened Device Tree blob at 88000000
       Booting using the fdt blob at 0x88000000
       Loading Device Tree to 8fff4000, end 8fffff5b ... OK

    Starting kernel ...

    [    0.000215] timer_probe: no matching timers found
    .
    .
    .
    .
    .
    .
    [    2.931406] davinci_evm sound: ASoC: CODEC DAI tlv320aic31xx-hifi not registered
    [    2.939183] davinci_evm sound: snd_soc_register_card failed (-517)
    [    6.318380] wlan: Loading MWLAN driver
    [    6.379935] wlan: Driver loaded successfully

    Debian GNU/Linux 9 A108H8 ttyO4

    default username:password is [debian:temppwd]

    A108H8 login: root
    Password:
    Last login: Wed Apr 15 08:30:46 CEST 2020 on ttyO4
    Linux A108H8 4.14.67-1.0.8+ #105 SMP PREEMPT Wed Jan 29 12:01:54 CET 2020 armv7l

    The programs included with the Debian GNU/Linux system are free software;
    the exact distribution terms for each program are described in the
    individual files in /usr/share/doc/*/copyright.

    Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
    permitted by applicable law.
    root@A108H8:~#

    3. But, If I connect the board to the serial port, switch it on and I do not press " " (space bar) to stop execution at u-boot prompt, system seems to start in non-interactive mode, no traces are shown and It is not possible to login into the system. It is only shown:

    U-Boot 2019.01+ (Apr 15 2020 - 08:34:35 +0200)

    4. I have checked config files and environment variables but they seem to be the same I have when I run the previous u-boot version I was using up to now.

    5. I would like the u-boot always to start in the way I can login into the system.

    I hope this can clarify this issue.

    Best regards and thank you

    Angel

  • Angel,

    where does your ENV reside?

    Try resetting & saving it and then restart your board:

    env default -f -a
    env save

    If this doesn't help, what did you do to port your default ENV from the old to the new U-Boot (in the device-specific config header under include/configs that you added/modified)? Can you cross check the contents (especially related to ENV settings) against the TI template at include/configs/am335x_evm.h?

    Regards, Andreas

  • Hello Andreas,

    Thank you for your answer. Our ENV is saved in NAND flash.

    I found why new u-boot version is working different than the old one. I will try to explain.

    1. This issue happens when CONFIG_SILENT_CONSOLE is enabled and "silent=0" is set in the environment variables. But in both u-boot versions our configuration is the same.

    2. During start-up "silent" variable is read first in console_init_f() function and then in initr_env() function.

    3. In the new u-boot version it is also read in console_init_r() function, and this makes that this version works different.

    4. Anyway, I think there is a mistake when reading this variable in console_init_f() and now also in console_init_r(). These functions test that "silent" is present, but they do not check if its value is set to 0 or 1 ( sorce code in initr_env() is correct and is testing both things)

    5. Changing this and checking if "silent" is set to 0 or 1 solves the problem.

    I hope this can help.

    Best regards and thank you

    Angel

  • Angel,

    thanks for spending time analyzing this further and sharing your findings here. U-Boot is under constant development (for example we'll soon be releasing our SDKs based on U-Boot v2020.01). Generally speaking migrating to a new version of U-Boot usually contains a few surprises, some of which can be avoided by always starting out from whatever the current officially released and TI-tested implementation is for a given board and re-doing the custom board port based on that.

    Regards, Andreas