-
Notifications
You must be signed in to change notification settings - Fork 4
Cortex M0 remote processor
One thing that sets the NXP LPC43xx series apart from other Cortex-M based microcontrollers is the addition of one or more Cortex-M0 cores. The LPC436x and LPC437x have two M0 cores while all the others have a single M0.
Linux can support these extra cores with the remoteproc (remote processor) framework.
The connection between the M4 and the M0 cores are pretty simple on LPC43xx. The TXEV signal from the M4 core is connected to the interrupt controller (nvic) on each M0 core through a latch with a reset. To signal the M0 cores the M4 raises its TXEV signal by executing the SEV (send event) instruction. To support signalling from the M0 cores the TXEV signals are connected to the M4 nvic. Note that the each TXEV from the M0 are connected to a different M4 nvic interrupt so they are easy to distinguish between. These lines are also latched. Reset of a latched TXEV signal is done by writing to a dedicated register in CREG.
TODO: block diagram
The driver for LPC43xx remote processors is called lpc43xx_remoteproc.c and be found here: https://github.com/manabian/linux-lpc/blob/lpc18xx_43xx_devel/drivers/remoteproc/lpc43xx_remoteproc.c
Note that this driver is under development and is not tested at this time.
With kernel support in place next step is to develop some useful firmware for the M0 core. Currently there is no library for remoteproc functionality on LPC43xx, but there exist a library for Xilinx Zynq.
OpenAMP: https://github.com/OpenAMP/open-amp
Xilinx Zynq OpenAMP wiki: http://www.wiki.xilinx.com/MPSoC+OpenAMP
Blog post on Zynq: http://henryomd.blogspot.no/2015/02/zynq-amp-linux-on-cpu0-and-bare-metal.html
It is probably worth to attempt to port OpenAMP to LPC43xx and maybe integrate it with LPCOpen.
- Setup a simple development environment for bare metal Cortex-M0 firmware
- Test kernel driver with developed firmware
- Test rpmsg (communication between M4 and M0)
- Implement a virtio device on M0