Colibri iMX8X Torizon OS 7.3.0 - M4 memory issues

Hi, I’m the Toradex AI Assistant.

I might make mistakes or occasionally get you wrong. Our support team will step in if needed.


Memory Allocation for Cortex-M4 on Colibri iMX8X with Torizon OS 7.3.0

Understanding Reserved Memory Configuration

The /reserved-memory node you’re referencing is used to exclude specific memory regions from normal Linux usage, typically for dedicated hardware components like the Cortex-M4 core (1).

According to the Device Tree documentation, reserved memory regions are specified as nodes under the /reserved-memory node, and the operating system excludes this reserved memory from normal usage (1). Here’s the structure from the documentation:

reserved-memory {
    #address-cells = <2>;
    #size-cells = <2>;
    ranges;

    decoder_boot: decoder_boot@84000000 {
        no-map;
        reg = <0 0x84000000 0 0x2000000>;
    };
    ...
};

(1)

Device Tree Changes Between Versions

The differences you’re observing between Torizon OS 5.7.2 and 7.3.0 reflect changes in the underlying BSP and kernel versions. When working with different Torizon versions, the device tree branch corresponds to the Linux kernel branch name (2).

Recommended Approach

1. Verify Cortex-M4 Support

The Colibri iMX8X features heterogeneous multicore architecture that allows offloading critical real-time tasks to the Cortex-M4 processor (3). Toradex provides tooling and FreeRTOS to simplify development with this asymmetric multicore architecture (3).

2. Device Tree Customization Process

For device tree modifications, you should:

  • Choose the appropriate base device tree that matches your hardware platform (4)
  • Identify the specific hardware configurations your setup requires (4)
  • Follow the device tree customization workflow for compilation and deployment (4)

3. Memory Region Configuration

When regions within /reserved-memory need to be referenced by other device nodes, you can add a memory-region property to the relevant device node (1):

&vpu_core0 {
    memory-region = <&decoder_boot>, <&decoder_rpc>;
    reg = <0x2d080000 0x10000>;
    status = "okay";
};

(1)

Next Steps

Since the M4 core stops after Linux boot with your current configuration, I recommend:

  1. Check the current BSP documentation for Torizon OS 7.3.0 to understand the proper M4 memory allocation method
  2. Verify M4 firmware compatibility with the memory regions you’re trying to allocate
  3. Review the device tree binding documentation specific to your kernel version for the correct M4 configuration approach (4)

The device tree customization process involves selecting the base device tree, making modifications, compiling, and deploying the changes (4). Make sure your custom device tree reflects the specific hardware description and changes needed for your M4 memory allocation.

Best regards, Toradex AI Assistant.


Did you like my answer? :+1: :-1:

If I answered your question, please tick the “Solution” checkbox.

For follow-up questions to me, please use @ToradexAI in your post.