Previous Page  58 / 84 Next Page
Information
Show Menu
Previous Page 58 / 84 Next Page
Page Background

mbedded systems usually fall

into one of two categories:

those that require hard real-time

performance and those that don’t.

In the past, we had to pick our

poison-the performance of our “go

to” real-time operating system or the

rich feature set of our favorite Linux

distribution-and then struggle with its

shortcomings.

Today, embedded developers no

longer need to choose between the

two. Asymmetric multiprocessing

(AMP) offers the best of both worlds.

Several modern system-on-chip (SoC)

product offerings integrate multiple

CPUs, a broad variety of standard

I/O peripherals and programmable

logic. The Xilinx® Zynq-7000®

All Programmable SoC family, for

example, includes a dual-core ARM®

Cortex™-A9, standard peripherals

(such as Gigabit Ethernet MACs, USB,

DMA, SD/MMC, SPI and CAN) and a

large programmable logic array.

We can use these SoC products

as the basis of a Linux/RTOS AMP

system that provides considerable

flexibility. In many ways, the typical

AMP configuration is similar to a PCI-

based system, with the Linux domain

functioning as the host, the RTOS

domain functioning as an adapter, and

one or more shared memory regions

used for communication between the

two domains.

Unlike PCI, however, an AMP

configuration can more conveniently-

and dynamically-assign resources

(both the standard peripherals and

custom logic) to one domain or the

other. In addition, a Linux/RTOS AMP

system can dynamically reconfigure

programmable logic based on runtime

requirements, such as the presence or

absence of various external devices.

This level of flexibility is often coupled

with concerns about complexity and

the degree of difficulty involved in

bringing up an AMP system. Rest

assured that the Linux development

community has introduced many

features into the kernel that greatly

simplify AMP configuration and use.

LINUX MULTIPROCESSING

IN A NUTSHELL

With respect to multiprocessing, the

Linux kernel comes in two flavors:

the uniprocessor (UP) kernel and

the symmetric multiprocessor (SMP)

kernel. The UP kernel can only run

on a single core, regardless of the

number of available cores. AMP

systems can incorporate two or more

instances of the uniprocessor kernel.

The SMP kernel, however, can run on

one core or simultaneously on multiple

cores (Figure 1). An optional kernel

command line parameter controls the

number of cores used by the SMP

kernel following system initialization.

Once the kernel is running, various

command line utilities control the

number of cores assigned to the

E

AMP up Your Next SoC Project

Harness real-time performance and the rich features of Linux

Scott McNutt, Senior Software Engineer

58 l New-Tech Magazine Europe