This page describes different approaches that enable the Zynq AP SoC to simultaneously run multiple operating systems or bare-metal code on the two ARM processors.

Each of the solutions described below has different strengths and weaknesses with respect to requirements around code re-use, general purpose computing, real-time response, or isolation/separation of applications in order to meet safety or security concerns.

Readers may also refer to the Real-Time Linux page on this wiki.


Asymmetric Multi Processing (AMP) Configurations

The Zynq AP SoC can be configured to run independent software stacks on each of its processor cores. Such approaches can be configured as either unsupervised AMP (where one of the operating systems is responsible for system management and coordination), or as an AMP configuration created using ARM TrustZone architecture which provides a light weight virtual machine of sorts, on which Linux and RTOS code can independently execute.

Open Source or Freely Available Solutions

Below we describe those solutions that are currently (March 2013) available under open source licenses, and/or at no cost for development and deployment.

Linux / Bare-metal or RTOS AMP

Xilinx supports the OpenAMP project which defines mechanisms to manage the Life Cycle Management (load/start/stop) and Message passing between multiple cores.
Starting with release 2015.3 of Xilinx SDK, templates for Zynq-7000 AP SoC and Zynq Ultrascale+ MPSoC are provided to generate firmware for the remote processor.
Xilinx standard offering requires Petalinux to be installed and currently target a configuration with a Linux master and bare-metal or FreeRTOS remote processor(s).
Alternative solutions including support for OpenAMP are available from vendors such as Mentor, Micrium, Wind River and others.
As of May 2016, this project is actively being developed and getting support from the Multicore Association to guide and standardize the API.

See Xilinx OpenAMP Wiki for further details.

Linux / Bare-metal AMP

Xilinx provides an Application Note which includes both hardware and software designs necessary to run Linux on one processor core of the Zynq-7000 AP SoC, and bare-metal applications on the second core.
See our XAPP1078 Wiki page for additional details including usage on the ZC-706.


Linux-baremetal.JPG
Linux / Bare-Metal AMP


Bare-metal / Bare-metal AMP

Xilinx provides XAPP1079 which includes both software and hardware designs needed to run Linux on one processor core of the Zynq-7000 AP SoC, and bare-metal applications on the second core.

bare-metal-bare-metal-AMP2.JPG

Bare-Metal (Cortex A9) / Bare-metal (MicroBlaze) AMP

Xilinx provides an Application Note which includes both hardware and software designs necessary to run bare-metal application code on one processor core of the Zynq-7000 AP SoC, and bare-metal applications on a MicroBlaze instance deployed in the programmable logic. See our XAPP1093 for additional details.


Slide1.JPG
Bare-Metal (A9)/ Bare-Metal (MicroBlaze) AMP


PetaLinux

PetaLinux includes a board support package for the Xilinx ZC-702 Evaluation Kit which supports an AMP configuration consisting of Linux & FreeRTOS. Documentation accompanying this reference design can be downloaded here.

Unsupervised_AMP.JPG
Linux / FreeRTOS AMP





TOPPERS SafeG (Nagoya University)

The TOPPERS SafeG is an open source licensed RTOS/GPOS solution that leverages Zynq's TrustZone architecture. From a high level block diagram perspective, this solution looks very similar to the SierraTEE listed above however there are key differences in API and envisaged use case. A binary deployable image as well as source code for the Zynq example can be found from the TOPPERS Japanese language page The downloadable files include documentation in English as well as a large number of source code comments also written in English.

Complementing the SafeG information linked above, we suggest that you also refer to "Inside TOPPERS/ASP - A Real-Time Operating System for Embedded Systems" which provides details on the RTOS used within the SafeG configuration.


TrustZone-based.JPG
TrustZone-enforced Trusted Execution Environment



Nagoya University TOPPERS SafeG
Nagoya University TOPPERS SafeG






Xenomai (Open Source Solution)

Xenomai is a dual-kernel, open source real time solution for Linux. Though it uses a separate kernel (and separate API) for real-time tasks, real-time tasks can be deployed within Linux user-space or within a dedicated real-time kernel that exists outside of the memory context of Linux. Xenomai includes RTOS "skins" which are recreations of APIs for some traditional commercial RTOS offerings. Note that such RTOS skins are not supported by the original RTOS vendor, and they may be incomplete implementations of the original RTOS API.

Linux community developers have been successful in building and applying Xenomai patches to Linux kernels for Zynq provided from Xilinx GIT. Please find those instructions at our Xenomai for Zynq page.

Xenomai is also supported by Xilinx development partners including:




Xenomai2.JPG
Xenomai


Commercial Hypervisors

"Hypervisors" provide virtual machines on top of which disparate software stacks can execute. Compared to other approaches, hypervisors offer the following benefits:
  • Bi-directional software isolation and separation - each software stack is isolated from the others
  • Applicable to higher levels of safety and security certification
  • Ability to run more software stacks than physical processors
  • Small code base, running in supervisory mode from a certification perspective
  • Independent OS restart


Hypervisors.JPG
Simplified Hypervisor Diagram




General Dynamics Broadband (OK LABS)

General Dynamics Broadband (formerly known as OK Labs) offers the OKL4 microvisor which provides services and separation for safety and security.

OK L4 Microvisor
OK L4 Microvisor




SYSGO

SYSGO offers Safe and Secure virtualization with PikeOS providing a safety-certifiable (DO-178B, IEC 61508, EN 50 128) microkernel and hypervisor services for safety-critical and security-critical applications.

PikeOS.JPG
SYSGO PikeOS




Commercial User-Space Solutions


Enea Light Weight Run Time (LWRT)

Enea LWRT is a commercial solution offering user-space implementations of scheduling, message passing, and resource management, and unlike functionality provided by the kernel, the user-space implementation can be used without the overhead and indeterminism caused by context switches to supervisor mode.

Enea_LWRT_1.JPG
Enea LWRT solution - source http://www.enea.com/software/resources/whitepapers/Whitepapers/OSE/Enabling-Linux-for-Real-Time-on-Embedded-Multicore-Devices/


Enea_LWRT.JPG
Enea LWRT solution - source http://www.enea.com/software/resources/whitepapers/Whitepapers/OSE/Enabling-Linux-for-Real-Time-on-Embedded-Multicore-Devices/

This approach is reported to provide low latencies consistent with the preempt_rt patch while offering higher throughput on both the Linux and real-time sides, all with much less modification of the Linux kernel.
For more information see Enea's white paper or their 28 page presentation


User Space RTOS API Support in Linux


In summary, this type of solution simply extends Linux with APIs that are used by an RTOS. Such an approach is most applicable to cases where unmodified, or patched Linux see: Real-Time performance of Linux) provides acceptable real-time responsiveness.


Below we describe a couple of options for such user space RTOS API support. Please note that Xilinx has not validated any of these user-space solutions so we are providing them for informational purposes only.

v2Lin Project

v2Lin -is an open source project which forked from a project first started in 2001. The last code release from v2Lin was in 2007 so users can reasonably expect that some issues must be resolved prior to deployment on Zynq-7000 AP SoC.

Mapusoft OS Changer

Mapusoft - provides libraries supporting the execution of several different RTOS within the context of the host OS. Compilable for ARM Cortex - and expected to be functional with Zynq. OS Changer Datasheet



Related Links

  • Real-Time Systems Presentation - 2010 presentation offering additional technical information related to implementation of preempt_rt in Linux-based systems.
Zynq-7000 AP SoC and Zynq Ultrascale+ MPSoC.