{{{#!html

  1. Ventana Memory
    1. Memory Performance
    2. Linux Contiguous Memory Allocator (CMA)
    3. Linux Coherent memory

Ventana Memory

The Freescale IMX6 Multi-Mode DDR Controller (MMDC) is what interfaces the ARM cpu cores with the shared main memory.

All Ventana products use DDR3 SDRAM and the Secondary Program Loader (SPL) (also built from U-Boot code) that pre-ceeds the actual U-Boot bootloader is in charge of configuring the MMDC and DDR3. While the IMX6 MMDC has 2 32bit channels that can be used together for a 64bit memory architecture, each Ventana model differs because

Baseboard width chip arrangement Max Addressible1
GW54xx/GW53xx 64bit 4x 16bit chips 4GB
GW51xx/GW52xx/GW552x/GW553x 32bit 2x 16bit chips 2GB
GW551x 16bit 1x 16bit chips 1GB
  1. Max Addressible is the maximum possible memory assuming today's DDR3 density - contact sales@… for information on available board models.

Memory Performance

The Freescale MMDC has some profiling support built in that can allow you to examine memory utilization at a per hardware-block level. A simple user application exists called mmdc2 that can be used to gather and analyze the counters and provide some feedback on current memory utilization.

By default the mmdc2 application is installed on the Gateworks Yocto BSP gateworks-image-multimedia and gateworks-image-gui images. It is available in the imx-test package and located in /unit_tests/mmdc2.

Example usage:

The meaning of some of the results is as follows:

For more information see also:

Linux Contiguous Memory Allocator (CMA)

Some devices and device-drivers require big chunks of physically contiguous memory. A perfect example is the IMX6 GPU which needs CMA for certain applications. The kernel must reserve CMA memory and thus it is not available from the general pool for other applications. The amount of CMA memory reserved by the kernel defaults to 0 (in the Gateworks kernel) and can be specified by the 'cma' kernel cmdline argument.

An example of devices that require CMA would be video display devices/drivers, video capture devies/drivers, or GPU devices/drivers.

The Yocto and Android BSP's have a bootscript that among other things comes up with a default cma allocation by looking at the total board memory available. If you find you need to alter this number (ie you do not want 'any' allocated) you can set the mem bootloader paramater to disable the auto-configuration performed by the bootscript.

For more information see also:

Linux Coherent memory

Similar to CMA a special pool of coherent memory for atomic dma allocations is made available by the kernel. By default this is set to 256K but can be changed by setting the 'coheremet_pool' kernel parameter. This is typically used for DMA capable devices such as PCI radio or video capture devices.

}}}