8
$\begingroup$

I'm considering using the i.MX 7 processor for a new design. The overall architecture appears to be similar to the i.MX 6, at least from comparing the block diagrams.

What mechanisms exist for communication between the Cortex-M4 core and the Cortex-A7 core(s)? Does the stock Linux kernel provide any such mechanisms (which likely would assume a specific RTOS or firmware running on the M4), or is this custom firmware for both processors in Freescale's offerings? The processors appear to share pretty much everything, so I would imagine you could implement a shared memory buffer with an atomic semaphore, or something along those lines.

Ideally, I would like to have the M4 firmware "take over" some peripherals while the A7 processor is in a low-power mode (i.e. manage periodic communication transfers or some data analysis until something "interesting" happens that requires the A7 to do something). From the block diagrams and the i.MX 6 SoloX reference manual, it appears the hardware doesn't preclude this.

$\endgroup$

1 Answer 1

6
$\begingroup$

The generic term for multi-core systems that run different kernels (or bare metal code) on different cores is Asymmetric multi-processing (AMP). Other related terms are Heterogeneous Computing, which refers to multiple cores of different types in the same system, and Multiprocessor System-on-Chip (MPSoC).

Freescale happens to have an overview document (PDF) discussing some of the terminology and design issues relating to such systems, which may be good background, though it is discussing a different OS (QNX) and product line (PowerPC). A frequently discussed free software combination is Linux on a processor an FreeRTOS on the microcontroller. Several existing chips both from Freescale and other vendors have architectures similar to the i.MX7, such as TI's OMAP 4/5. There is also a lot of discussion of and example code for AMP on Xilinx's dual-core Zynq ARM+FPGA chips.

Since 2012 or so the mainline Linux kernel has had optional support for the Remote Processor (remoteproc) and Remote Processor Messaging (rpmsg) frameworks. remoteproc is a generic interface for the Linux kernel to control the "remote" core (power on/off, load firmware). rpmsg is the generic interface for sending messages between cores. The linked documentation pages detail their APIs and give more context. A developer would need to write a custom application-specific Linux kernel driver using this framework to expose I/O to userspace, and then need to write, eg, FreeRTOS firmware that "speaks" rpmsg. The rpmsg framework generally seems to use shared memory to actually implement communication between the cores.

If one does not exist already, I assume Freescale will soon release documentation and examples specific to AMP with the i.MX7 and Linux. You might want to keep an eye on the Freescale Linux git repositories as they implement i.MX7 support; these branches will presumably be merged into mainline in due time.

$\endgroup$
2
  • $\begingroup$ I'm really curious whether this actually the best practice for this specific hardware, and what alternatives there are. Please update if you run in to any problems (eg, throughput or latency) or learn of better interfaces! $\endgroup$
    – bnewbold
    Aug 5, 2015 at 0:30
  • 1
    $\begingroup$ It's "asymmetric", not "asynchronous" $\endgroup$
    – user253751
    Oct 21, 2021 at 14:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.