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.

AM6442: Yocto custom machine.conf

Part Number: AM6442


Hello

I trying to create custom machine.conf based on am64xx-evm.conf. Unfortunately when I try to build image error occurs:

"MACHINE=puma-k3r5 is invalid. Please set a valid MACHINE in your local.conf, environment or other configuration file"

It seems that something append suffix "-k3r5" because my machine is named "puma".

I found that in meta-ti-bsp/conf/multiconfig/k3r5.conf there is line MACHINE:append = "-k3r5" so I try to force MACHINE value in my puma.conf file, but same error still appears.

My questions are:

1. How to solve this issue?

2. What is the purpose of this mystery suffix "-k3r5"?

puma.conf

require meta-ti/meta-ti-bsp/conf/machine/am64xx-evm.conf
MACHINE := "puma"

Thank you for help

BR,

Jakub

  • Jakub,

    if you look at the example of am62xx and am64xx you see there are several config files needed for a given machine.

    a0797059@dasso:~/tisdk/am62xx-evm/sources/meta-ti (HEAD detached at 08.04.01.005)
    $ ll conf/machine/am64xx-evm*
    -rw-rw-r-- 1 a0797059 a0797059 178 Oct 12 15:01 conf/machine/am64xx-evm.conf
    -rw-rw-r-- 1 a0797059 a0797059 575 Oct 12 15:01 conf/machine/am64xx-evm-k3r5-gp.conf
    -rw-rw-r-- 1 a0797059 a0797059 403 Oct 12 15:01 conf/machine/am64xx-evm-k3r5-sr2-hs-fs.conf
    -rw-rw-r-- 1 a0797059 a0797059 627 Oct 12 15:01 conf/machine/am64xx-evm-k3r5-sr2-hs-se.conf
    
    a0797059@dasso:~/tisdk/am62xx-evm/sources/meta-ti (HEAD detached at 08.04.01.005)
    $ ll conf/machine/am62xx-evm*
    -rw-rw-r-- 1 a0797059 a0797059 359 Oct 12 15:01 conf/machine/am62xx-evm.conf
    -rw-rw-r-- 1 a0797059 a0797059 254 Oct 12 15:01 conf/machine/am62xx-evm-k3r5.conf

    In fact the minimum is 2 files, which is why I listed am62xx as an example, even you were asking about am64xx. On TI K3 devices (all AM6xxx) there are multiple architectures at play during a Linux boot as follows:

    1. 32-bit ARM -> Cortex-R5 for the initial part of the system boot. Specifically, U-Boot SPL.
    2. aarch64 ARM -> Cortex-A53 for later stages of the boot (another variant of U-Boot SPL but this time running on A53, plus U-Boot proper) and for use as the main system (Linux) processor

    This is being reflected in the Yocto build done by using the multi-configuration features Yocto offers. See here for an intro on this https://elinux.org/images/a/a5/002-1500-SLIDES-multiconfig_inception.pdf but you can find the details in the official Yocto configuration. This multi-configuration results in config files always being used as a pair. One without the mysterious "-k3r5" suffix, and at least one with that suffix. The "-k3r5" suffix points to the configuration used to build whatever is needed for the Cortex-R5 CPU. In practical terms this configuration is pretty much only needed to build the very first state of the boot image.

    If you want to create a custom machine for AM64, I would create a copy of the am64xx-evm.conf config and depending which device and silicon revision you have (GP or HS-FS on SR2 at the moment) another copy of the appropriate am64xx-evm-k3r5-*.conf file with your new machine name, and then customize these files. If you can tell me what specific device you are using I can try creating/testing those files so you have a known-good starting point.

    Regards, Andreas

  • Hello Andreas,

    Sorry for late response.

    Ok, so I created to files:

    puma.conf

    require conf/machine/am64xx-evm.conf

    and puma-k3r5.conf

    require conf/machine/am64xx-evm-k3r5.conf

    but during build error show up:

    ERROR: _exec_cmd: install -m 0644 -D /home/grad/YOCTO_workspace/texas-rt/build/tmp/deploy/images/puma/tiboot3.bin /home/grad/YOCTO_workspace/texas-rt/build/tmp/work/puma-poky-linux/texas-image/1.0-r0/tmp-wic/hdd/boot/tiboot3.bin returned '1' instead of 0
    | output: install: cannot stat '/home/grad/YOCTO_workspace/texas-rt/build/tmp/deploy/images/puma/tiboot3.bin': No such file or directory

    Maybe somewhere I should edit variable COMPATIBLE_MACHINE end add machine puma? Could you point me right place in meta-ti?

    BR

    Jakub

  • Hello Andreas,

    Sorry for late response.

    Ok, so I created to files:

    puma.conf

    require conf/machine/am64xx-evm.conf

    and puma-k3r5.conf

    require conf/machine/am64xx-evm-k3r5.conf

    but during build error show up:

    ERROR: _exec_cmd: install -m 0644 -D /home/grad/YOCTO_workspace/texas-rt/build/tmp/deploy/images/puma/tiboot3.bin /home/grad/YOCTO_workspace/texas-rt/build/tmp/work/puma-poky-linux/texas-image/1.0-r0/tmp-wic/hdd/boot/tiboot3.bin returned '1' instead of 0
    | output: install: cannot stat '/home/grad/YOCTO_workspace/texas-rt/build/tmp/deploy/images/puma/tiboot3.bin': No such file or directory

    Maybe somewhere I should edit variable COMPATIBLE_MACHINE end add machine puma? Could you point me right place in meta-ti?

    BR

    Jakub

  • Hi Jakub,

    while I have on my short list to experiment with this and come up with a clean way to do what you are trying to do  there are a few other things I need to work first and also next week is US holiday week. I'm afraid I won't have bandwidth to experiment/look into this more deeply until after Thanksgiving (US).

    Regards, Andreas