real time versions of linux operating system present by tr n duy th nh quách phát tài 1

29
Real Time Versions of Linux Operating System Present by Trần Duy Thịnh Quách Phát Tài 1

Upload: breana-sandles

Post on 29-Mar-2015

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Real Time Versions of Linux Operating System

Present byTrần Duy ThịnhQuách Phát Tài

1

Page 2: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Content

•1. Standard Linux•2. Real-time Linux

Implement core real-time Linux

•3. Open-Source Distributions•4. Commercial Distributions

Real-time versions

2

Page 3: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

1. Standard Linux• Memory

Management• Memory

Protection• Scheduling and

Task Management• Hardware

Interfaces• File

Management• Communication

: external, internal

3

Page 4: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2. Real-time Linux kernel

•Modifications that make Linux Real Time•Real-Time Patches to the Standard Kernel

4

Page 5: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2. Real-time Linux kernel

Modifications that make Linux Real Time

• Micro Kernel• Nano Kernel• Resource Kernel Extension• POSIX Real-time Extension

Real-Time Patches to the Standard Kernel

5

Page 6: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.1 Modification that make Linux Real-time

• Interrupt processing in standard kernel: 2 halves▫ The bottom-half task is the interrupt handler and reads data

from the physical device into a memory buffer.▫ The top-half task reads from the memory buffer and passes

the data to a kernel accessible buffer• In the standard kernel: without preemption, all

interrupts are disabled when the bottom-half task is running.

• All variants of real-time Linux have introduced modifications at the kernel level▫ reduce both the interrupt latency and jitter between

periodic interrupts▫ faster response to external events and higher resolution

timing

6

Page 7: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.1 Modification that make Linux Real-time

•Standard kernel preemption

•Higher priority kernel processes can preempt lower priority

•Linux version 2.5.4•latency and jitter is

around 1 millisecond

7

Page 8: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.2 Real-time Patches to the Standard Kernel ▫ adding a second, highly efficient, kernel to handle

real-time tasks Micro Kernel: RTLinux, RTAI Nano Kernel Resource Kernel Extension

▫ making changes directly to the standard kernel POSIX Real-Time Extensions: implement the timers,

signals, semaphores, process memory locking, shared memory,priority scheduling, synchronized and asynchronized I/O specied in IEEE 1003.1d KURT TimeSys Linux

8

Page 9: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.2.1 Micro Kernel• Victor Yodaiken

controls the execution of real-time tasks

• runs the standard Linux kernel as a background task

• RTLinux – New Mexico Tech

• RTAI - Politecnico di Milano

9

Page 10: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.2.2 Nano Kernel

•Adaptive Domain Environment for Operating Systems (ADEOS)

•similar to the micro kernel

•many operating systems

•can be run in parallel on top of the nano-kernel layer

10

Page 11: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.2.3 Resource Kernel Extension

• provides a gateway to resources such as file systems, serial and parallel ports, and network interfaces for both the normal kernel and also for user processes

• control the interrupt preemption issues for the standard kernel

• User-space can communicate directly

11

Page 12: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.2.4 POSIX Real-time Extensions Modify directly to the standard kernel Implement the timers, signals, semaphores, process memory

locking, shared memory,priority scheduling, synchronized and asynchronized I/O specied in IEEE 1003.1d

Two different approaches: KURT: The Kansas University Real-Time Linux (KURT)

distribution,▫ high resolution timers,▫ real-time scheduling improvements

TimeSys Linux ▫ making the standard kernel preemptable▫ including a kernel scheduler that provides scheduling for the

bottom-half kernel interrupt processing and for interrupts themselves

12

Page 13: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

2.3 Performance Comparison

13

Page 14: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Real-time versions of Linux

•Open-Source Distributions:▫Provide the source code and build scripts

so the user can understand, modify, and build the code

▫Documentation may be sparse and technical support nonexistent

•Commercial Distributions▫Make a profit to stay in business.▫Support and documentation.

14

Page 15: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

3. Open-Source Distribution

•ADEOS•KURT•RTAI•RTLinux•TimeSys Linux GPL

15

Page 16: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Open-Source: ADEOS

•Adaptive Domain Environment for Operating Systems

•2002•Is a hardware abstraction layer•Allow a real-time kernel and a general

purpose kernel to co-exist•Real-Time Mechanism nano-kernel

16

Page 17: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Open-Source: KURT

•Kansas University•1997•Implement the POSIX real-time

extensions to Linux•The patches implement the queued real-

time signals and the high-resolution timers.

•Real-Time Mechanism: POSIX timers and scheduling.

•10s of microseconds of latency and jitter

17

Page 18: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Open-Source: RTAI (Linux-RT)•Politecnico di Milano, Italy.•2000•Originally based on RTLinux•Evolved as a unique favor of real-time

Linux.•Real-Time Mechanism: micro kernel•< 10 microseconds latency and jitter

18

Page 19: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Open-Source: RTLinux

•Victor Yodaiken, New Mexico Institute of Technology

•1996•Covers the logic of running standard

Linux as a background thread to the real-time tasks

•Real-Time Mechanism: micro kernel•< 10 microseconds latency and jitter

19

Page 20: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Open-Source: TimeSys Linux GPL•TimeSys•1998•Provides a preemptable kernel and an

improved task scheduler•Real-Time Mechanism: Preemptable

Kernel•< 100 microseconds of latency and jitter

20

Page 21: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

4. Commercial Distribution

•RedHawk Linux•FSMLabs RTLinux•MontaVista Linux•QRTS•REDICE-Linux•Linux SMP •TimeSys

21

Page 22: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: RedHawk Linux

•Concurrent Computer Corporation•Packaged hardware/software solutions•Targeting the real time data acquisition,

video-on-demand, and simulation markets•Real-Time Mechanism Kernel: preemption

enhancements

22

Page 23: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: FSMLabs RTLinux

•Finite State Machine Labs•RTLinux version 3.0 offers developers the

option of using either Linux or netBSD as their general purpose OS, using the identical POSIX threads API

•Real-Time Mechanism: Micro kernel

23

Page 24: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: MontaVista Linux

•MontaVista Software Inc.•Tailor to the needs of embedded software

developers.•Real-Time Mechanism: Kernel pre-

emption enhancements

24

Page 25: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: QRTS

•Quality Real Time Systems•Develops applications for real-time

control and simulation.•Real-Time Mechanism: RTLinux micro

kernel

25

Page 26: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: REDICE-Linux

•REDSonic Inc.•Integrates the dual kernel approach and

the preemptable kernel to provide a hybrid solution

•Real-Time Mechanism: Micro kernel and Kernel Preemption.

26

Page 27: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: Linux SMP

•Synergy Microsystems Inc.•Support RTLinux as the operating system

on their PowerPC single-board computers.•Real-Time Mechanism: RTLinux micro

kernel

27

Page 28: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Commercial: TimeSys Linux/RealTime, TimeSys Linux/Net, TimeSys Linux/CPU•TimeSys Corporation•Adds three proprietary components into

an open-source preemptable kernel▫High-resolution timers and priority

inheritance.▫Guaranteed access to CPU resources,▫Guaranteed access to network resources.

•Real-Time Mechanism: Preemptable Kernel.

28

Page 29: Real Time Versions of Linux Operating System Present by Tr n Duy Th nh Quách Phát Tài 1

Thank you!

29