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.

AM5718: What is the relationship between the two:CMEM & CMA

Part Number: AM5718

What is the relationship between the two:CMEM & CMA?

in   http://www.ti.com/lit/an/sprac60/sprac60.pdf ,I saw that:

Typically, the IPC application puts text, data, and heap sections in the CMA pool with entry TYPE_CARVOUT. Ensure the total size of these sections with the entry TYPE_CARVEOUT in the resource table is less than the CMA pool defined in the Linux device tree. For example, DSP_MEM_TEXT_SIZE in the following code snippet must be less than the size of cmem_block_mem_0.

Since the DSP using CMA to alloc memory,why DSP_MEM_TEXT_SIZE need to less than the size of cmem_block_mem_0?

  • The second question:

    I saw this picture:

    1. Is Vring used for IPC/Rpmsg to transfer data,such as MessageQ_get/MessageQ_put?

    2.What is mailbox in picture?

    3.in big-data-ipc is cmem used for big data transfer?

    Thanks,

    I've been struggling for a long time...

  • Hi,

    Linux Continuous Memory Allocator (CMA) is a framework [1], and the TI CMEM driver handles the actual memory allocation within the defined CMA region.  Hopefully that helps clarify the distinction.

    To answer your other questions:

    1)  Is Vring used for IPC/Rpmsg to transfer data,such as MessageQ_get/MessageQ_put? Yes, this is correct. Note there is a size limitation on each buffer that can be somewhat restrictive for applications that demand large data transfers.  You would want to look at the "Big Data IPC Example" if you need to transfer large chunks of data.

    2) What is mailbox in picture?  These are actually on the silicon that provide a means to send notifications that data is ready.  The device TRM has a section about mailboxes.

    3) in big-data-ipc is cmem used for big data transfer?  CMEM is used to allocate the memory that holds the buffers, yes.  CMEM itself is not doing the data transfer. 

    Regards,
    Mike

    [1] https://lwn.net/Articles/396657