Real-Time Operating Systems

Total Page:16

File Type:pdf, Size:1020Kb

Real-Time Operating Systems Real-Time Operating Systems Heechul Yun 1 What is an OS? 2 Operating Systems • A program that acts as an intermediary between users and the computer hardware Applications Operating System Computer Hardware 3 Common OS Services • Task (process) management • Inter process communication (IPC) • Virtual memory • Demand paging • Filesystem • Hardware interface and I/O handling • Protection, error handling, security 4 Real-Time Operating System • OS for real-time systems • Real-time systems – correctness depends on not only logical correctness but also temporal one. • Common requirements – Bounded interrupt latency – Bounded scheduling latency – Bounded WCETs of system-calls – Support for real-time scheduling policies 5 RTOS • Commercial – VxWorks – QNX – Nucleus – .. • Free – FreeRTOS – NuttX – ... 6 Common RTOS Services • Task (process) management • Inter process communication (IPC) • Virtual memory (▲) • Demand paging (X) • Filesystem • Hardware interface and I/O handling • Protection, error handling, security 7 RTOS with Partitioning • RTOS with time and space partitioning – E.g., VxWorks 653, Integrity-178 • Time partitioning – A partition’s access time to a shared resource (e.g., CPU) must be guaranteed regardless of others • Space partitioning – A partition’s memory cannot be corrupted by other partitions 8 VxWorks 653 9 Integrity-178 10 Linux as RTOS • Mainline Linux – Pretty good real-time support these days – RT schedulers: SCHED_FIFO, RR, DEADLINE – Memory locking and other techniques • Problems – Kernel used to be non-preemptible (not anymore) – Still suffer long interrupt/scheduling latencies – Due to many long non-preemptible code sections 11 Linux-RT (PREEMPT-RT patchset) • Reduce non-preemptible code sections in various kernel code paths – Preemptible spin-locks (rtmutexes) – Interrupts are handled by kernel threads (preemptible) 12 Scheduling Latency Comparison (*) Figure source: A Comparison of Scheduling Latency in Linux, PREEMPT RT, and LITMUS-RT, OSPERT 2013 • w/o vs. w/ PREEMPT_RT patch • I/O heavy background tasks 13 Dual-Kernel Approach • Linux runs on top of an RTOS – RTLinux – RTAI – Xenomai – L4/Linux 14 This Week • SCHEDULING AND LOCKING IN MULTIPROCESSOR REAL-TIME OPERATING SYSTEMS. Chapter 3.3. The Design and Implementation of LITMUSRT. Bj¨orn B. Brandenburg, PhD Thesis, 2011 – LITMUS-RT • GPUSync: A Framework for Real-Time GPU Management, RTAS’13 • Real-Time Multi-Core Virtual Machine Scheduling in Xen, EMSOFT'14 15.
Recommended publications
  • Wind River Vxworks Platforms 3.8
    Wind River VxWorks Platforms 3.8 The market for secure, intelligent, Table of Contents Build System ................................ 24 connected devices is constantly expand- Command-Line Project Platforms Available in ing. Embedded devices are becoming and Build System .......................... 24 VxWorks Edition .................................2 more complex to meet market demands. Workbench Debugger .................. 24 New in VxWorks Platforms 3.8 ............2 Internet connectivity allows new levels of VxWorks Simulator ....................... 24 remote management but also calls for VxWorks Platforms Features ...............3 Workbench VxWorks Source increased levels of security. VxWorks Real-Time Operating Build Configuration ...................... 25 System ...........................................3 More powerful processors are being VxWorks 6.x Kernel Compatibility .............................3 considered to drive intelligence and Configurator ................................. 25 higher functionality into devices. Because State-of-the-Art Memory Host Shell ..................................... 25 Protection ..................................3 real-time and performance requirements Kernel Shell .................................. 25 are nonnegotiable, manufacturers are VxBus Framework ......................4 Run-Time Analysis Tools ............... 26 cautious about incorporating new Core Dump File Generation technologies into proven systems. To and Analysis ...............................4 System Viewer ........................
    [Show full text]
  • Comparison of Contemporary Real Time Operating Systems
    ISSN (Online) 2278-1021 IJARCCE ISSN (Print) 2319 5940 International Journal of Advanced Research in Computer and Communication Engineering Vol. 4, Issue 11, November 2015 Comparison of Contemporary Real Time Operating Systems Mr. Sagar Jape1, Mr. Mihir Kulkarni2, Prof.Dipti Pawade3 Student, Bachelors of Engineering, Department of Information Technology, K J Somaiya College of Engineering, Mumbai1,2 Assistant Professor, Department of Information Technology, K J Somaiya College of Engineering, Mumbai3 Abstract: With the advancement in embedded area, importance of real time operating system (RTOS) has been increased to greater extent. Now days for every embedded application low latency, efficient memory utilization and effective scheduling techniques are the basic requirements. Thus in this paper we have attempted to compare some of the real time operating systems. The systems (viz. VxWorks, QNX, Ecos, RTLinux, Windows CE and FreeRTOS) have been selected according to the highest user base criterion. We enlist the peculiar features of the systems with respect to the parameters like scheduling policies, licensing, memory management techniques, etc. and further, compare the selected systems over these parameters. Our effort to formulate the often confused, complex and contradictory pieces of information on contemporary RTOSs into simple, analytical organized structure will provide decisive insights to the reader on the selection process of an RTOS as per his requirements. Keywords:RTOS, VxWorks, QNX, eCOS, RTLinux,Windows CE, FreeRTOS I. INTRODUCTION An operating system (OS) is a set of software that handles designed known as Real Time Operating System (RTOS). computer hardware. Basically it acts as an interface The motive behind RTOS development is to process data between user program and computer hardware.
    [Show full text]
  • Industrial Control Via Application Containers: Migrating from Bare-Metal to IAAS
    Industrial Control via Application Containers: Migrating from Bare-Metal to IAAS Florian Hofer, Student Member, IEEE Martin A. Sehr Antonio Iannopollo, Member, IEEE Faculty of Computer Science Corporate Technology EECS Department Free University of Bolzano-Bozen Siemens Corporation University of California Bolzano, Italy Berkeley, CA 94704, USA Berkeley, CA 94720, USA fl[email protected] [email protected] [email protected] Ines Ugalde Alberto Sangiovanni-Vincentelli, Fellow, IEEE Barbara Russo Corporate Technology EECS Department Faculty of Computer Science Siemens Corporation University of California Free University of Bolzano-Bozen Berkeley, CA 94704, USA Berkeley, CA 94720, USA Bolzano, Italy [email protected] [email protected] [email protected] Abstract—We explore the challenges and opportunities of control design full authority over the environment in which shifting industrial control software from dedicated hardware to its software will run, it is not straightforward to determine bare-metal servers or cloud computing platforms using off the under what conditions the software can be executed on cloud shelf technologies. In particular, we demonstrate that executing time-critical applications on cloud platforms is viable based on computing platforms due to resource virtualization. Yet, we a series of dedicated latency tests targeting relevant real-time believe that the principles of Industry 4.0 present a unique configurations. opportunity to explore complementing traditional automation Index Terms—Industrial Control Systems, Real-Time, IAAS, components with a novel control architecture [3]. Containers, Determinism We believe that modern virtualization techniques such as application containerization [3]–[5] are essential for adequate I. INTRODUCTION utilization of cloud computing resources in industrial con- Emerging technologies such as the Internet of Things and trol systems.
    [Show full text]
  • AMNESIA 33: How TCP/IP Stacks Breed Critical Vulnerabilities in Iot
    AMNESIA:33 | RESEARCH REPORT How TCP/IP Stacks Breed Critical Vulnerabilities in IoT, OT and IT Devices Published by Forescout Research Labs Written by Daniel dos Santos, Stanislav Dashevskyi, Jos Wetzels and Amine Amri RESEARCH REPORT | AMNESIA:33 Contents 1. Executive summary 4 2. About Project Memoria 5 3. AMNESIA:33 – a security analysis of open source TCP/IP stacks 7 3.1. Why focus on open source TCP/IP stacks? 7 3.2. Which open source stacks, exactly? 7 3.3. 33 new findings 9 4. A comparison with similar studies 14 4.1. Which components are typically flawed? 16 4.2. What are the most common vulnerability types? 17 4.3. Common anti-patterns 22 4.4. What about exploitability? 29 4.5. What is the actual danger? 32 5. Estimating the reach of AMNESIA:33 34 5.1. Where you can see AMNESIA:33 – the modern supply chain 34 5.2. The challenge – identifying and patching affected devices 36 5.3. Facing the challenge – estimating numbers 37 5.3.1. How many vendors 39 5.3.2. What device types 39 5.3.3. How many device units 40 6. An attack scenario 41 6.1. Other possible attack scenarios 44 7. Effective IoT risk mitigation 45 8. Conclusion 46 FORESCOUT RESEARCH LABS RESEARCH REPORT | AMNESIA:33 A note on vulnerability disclosure We would like to thank the CERT Coordination Center, the ICS-CERT, the German Federal Office for Information Security (BSI) and the JPCERT Coordination Center for their help in coordinating the disclosure of the AMNESIA:33 vulnerabilities.
    [Show full text]
  • Evidence Company Description …And Future Challenges
    1 Evidence Company description …and future challenges Paolo Gai, [email protected] IWES Workshop Pisa, 21 September 2016 2 The company Founded in 2002 as spin-off company of the Real-Time Systems Lab at Scuola Superiore S.Anna ~20 qualified people with an average age of 34 years 10+ years of experience in academic and industrial projects One third of the company has a PhD degree Our Mission : design and development software for small electronic devices 3 The company Partner in several European and Italian research projects (FP6, FP7, Ind.2015, Reg. Tuscany, H2020) Founded SSG Srl in November 2011 http://www.ssginnovation.com/ - (link to SSG slides) Evidence won the first prize at Start Cup Pisa 2005 March 12, 2007 - selected by ”Corriere della Sera ” as one of the most innovative Italian young entrepreneurs 4 (some) customers OSEK, microcontrollers, schedulability analysis, code generation Linux, SW devel. Listed as 3 rd party 5 products and services RTOS , Firmware, Embedded Linux Model-based design • OSEK/VDX, • Matlab/Simulink/Stateflow AUTOSAR, device drivers • Embedded Linux: 8 Yrs experience • National Instruments custom BSPs, GCC, U-Boot, LabView Kernel drivers • Initial developers of the • E4Coder toolset for code SCHED_DEADLINE patch generation • QEMU and emulators • UML/SYSML/Ecore/ Application Development Eclipse/Acceleo 6 Something about ERIKA Enterprise http://erika.tuxfamily.org • ERIKA Enterprise is an RTOS OSEK/VDX certified • ERIKA Enterprise implements an API inspired to a subset of the AUTOSAR API • open-source license
    [Show full text]
  • Porting Embedded Systems to Uclinux
    Porting Embedded Systems to uClinux António José da Silva Instituto Superior Técnico Av. Rovisco Pais 1049-001 Lisboa, Portugal [email protected] ABSTRACT Concerning response times, computer systems can be di- The emergence of embedded computing in our daily lives vided in soft and hard real time[26]. In soft real time sys- has made the design and development of embedded applica- tems, missing a deadline only degrades performance, unlike tions into one of the crucial factors for embedded systems. in hard real time systems. In hard real time systems, miss- Given the diversity of currently available applications, not ing a time constraint before giving an answer may be worse only for embedded, but also for general purpose systems, it than having no answer at all. An example of a soft real time will be important to easily reuse part, if not all, of these ap- system is a common DVD player. While good performance plications in future and current products. The widespread is desirable, missing time constraints in this type of system interest and enthusiasm generated by Linux's successful use only results in some frame loss, or some quirks in the user in a number of embedded systems has made it into a strong interface, but the system can continue to operate. This is candidate for defining a common development basis for em- not the case for hard real time systems. Missing a deadline bedded applications. In this paper, a detailed porting guide in a pace maker or in a nuclear plant's cooling system, for to uClinux using the XTran-3[20] board, an embedded sys- example, can lead to catastrophic scenarios! tem designed by Tecmic, is presented.
    [Show full text]
  • RT-ROS: a Real-Time ROS Architecture on Multi-Core Processors
    Future Generation Computer Systems 56 (2016) 171–178 Contents lists available at ScienceDirect Future Generation Computer Systems journal homepage: www.elsevier.com/locate/fgcs RT-ROS: A real-time ROS architecture on multi-core processors Hongxing Wei a,1, Zhenzhou Shao b, Zhen Huang a, Renhai Chen d, Yong Guan b, Jindong Tan c,1, Zili Shao d,∗,1 a School of Mechanical Engineering and Automation, Beihang University, Beijing, 100191, PR China b College of Information Engineering, Capital Normal University, Beijing, 100048, PR China c Department of Mechanical, Aerospace, and Biomedical Engineering, The University of Tennessee, Knoxville, TN, 37996-2110, USA d Department of Computing, The Hong Kong Polytechnic University, Hong Kong, China article info a b s t r a c t Article history: ROS, an open-source robot operating system, is widely used and rapidly developed in the robotics Received 6 February 2015 community. However, running on Linux, ROS does not provide real-time guarantees, while real-time tasks Received in revised form are required in many robot applications such as robot motion control. This paper for the first time presents 20 April 2015 a real-time ROS architecture called RT-RTOS on multi-core processors. RT-ROS provides an integrated Accepted 12 May 2015 real-time/non-real-time task execution environment so real-time and non-real-time ROS nodes can be Available online 9 June 2015 separately run on a real-time OS and Linux, respectively, with different processor cores. In such a way, real-time tasks can be supported by real-time ROS nodes on a real-time OS, while non-real-time ROS nodes Keywords: Real-time operating systems on Linux can provide other functions of ROS.
    [Show full text]
  • Blackberry QNX Multimedia Suite
    PRODUCT BRIEF QNX Multimedia Suite The QNX Multimedia Suite is a comprehensive collection of media technology that has evolved over the years to keep pace with the latest media requirements of current-day embedded systems. Proven in tens of millions of automotive infotainment head units, the suite enables media-rich, high-quality playback, encoding and streaming of audio and video content. The multimedia suite comprises a modular, highly-scalable architecture that enables building high value, customized solutions that range from simple media players to networked systems in the car. The suite is optimized to leverage system-on-chip (SoC) video acceleration, in addition to supporting OpenMAX AL, an industry open standard API for application-level access to a device’s audio, video and imaging capabilities. Overview Consumer’s demand for multimedia has fueled an anywhere- o QNX SDK for Smartphone Connectivity (with support for Apple anytime paradigm, making multimedia ubiquitous in embedded CarPlay and Android Auto) systems. More and more embedded applications have require- o Qt distributions for QNX SDP 7 ments for audio, video and communication processing capabilities. For example, an infotainment system’s media player enables o QNX CAR Platform for Infotainment playback of content, stored either on-board or accessed from an • Support for a variety of external media stores external drive, mobile device or streamed over IP via a browser. Increasingly, these systems also have streaming requirements for Features at a Glance distributing content across a network, for instance from a head Multimedia Playback unit to the digital instrument cluster or rear seat entertainment units. Multimedia is also becoming pervasive in other markets, • Software-based audio CODECs such as medical, industrial, and whitegoods where user interfaces • Hardware accelerated video CODECs are increasingly providing users with a rich media experience.
    [Show full text]
  • Performance Study of Real-Time Operating Systems for Internet Of
    IET Software Research Article ISSN 1751-8806 Performance study of real-time operating Received on 11th April 2017 Revised 13th December 2017 systems for internet of things devices Accepted on 13th January 2018 E-First on 16th February 2018 doi: 10.1049/iet-sen.2017.0048 www.ietdl.org Rafael Raymundo Belleza1 , Edison Pignaton de Freitas1 1Institute of Informatics, Federal University of Rio Grande do Sul, Av. Bento Gonçalves, 9500, CP 15064, Porto Alegre CEP: 91501-970, Brazil E-mail: [email protected] Abstract: The development of constrained devices for the internet of things (IoT) presents lots of challenges to software developers who build applications on top of these devices. Many applications in this domain have severe non-functional requirements related to timing properties, which are important concerns that have to be handled. By using real-time operating systems (RTOSs), developers have greater productivity, as they provide native support for real-time properties handling. Some of the key points in the software development for IoT in these constrained devices, like task synchronisation and network communications, are already solved by this provided real-time support. However, different RTOSs offer different degrees of support to the different demanded real-time properties. Observing this aspect, this study presents a set of benchmark tests on the selected open source and proprietary RTOSs focused on the IoT. The benchmark results show that there is no clear winner, as each RTOS performs well at least on some criteria, but general conclusions can be drawn on the suitability of each of them according to their performance evaluation in the obtained results.
    [Show full text]
  • Blackberry Playbook OS 2.0 Performs. Best in Class Communications
    BlackBerry PlayBook OS 2.0 Performs. Best in class communications. Powerful productivity. Performance powerhouse. What’s new and exciting about PlayBook™ OS 2.0 A proven performance powerhouse PlayBook OS 2.0 builds on proven performance through powerful hardware and intuitive, easy to use gestures. BlackBerry® PlayBook™ packs a blazing fast dual core processor, two HD 1080p video cameras, and 1 GB of RAM for a high performance experience that is up to the task – whatever it may be. The best of BlackBerry® comes built-in The BlackBerry PlayBook now gives you the BlackBerry communications experience you love, built for a tablet. PlayBook OS 2.0 introduces built-in email that lets you create, edit and format messages, and built-in contacts app and social calendar that connect to your social networks to give you a complete profile ™ of your contacts, including recent status updates. So, seize the BlackBerry App World moment and share it with the power of BlackBerry. The BlackBerry PlayBook has all your favorite apps and thousands more. Games like Angry Birds and Cut The Rope, BlackBerry® Bridge™ Technology social networking sites like Facebook, and even your favorite books from Kobo - the apps you want are here for you to New BlackBerry® Bridge™ features let your BlackBerry® smartphone discover in the BlackBerry AppWorld™ storefront. act as a keyboard and mouse for your BlackBerry PlayBook, giving you wireless remote control of your tablet. Perfect for pausing a movie when your BlackBerry PlayBook is connected to your TV with An outstanding web experience an HDMI connection. Plus, if you’re editing a document or browsing BlackBerry PlayBook puts the power of the real Internet at your a webpage on your BlackBerry smartphone and want to see it on a fingertips with a blazing fast Webkit engine supporting HTML5 larger display, BlackBerry Bridge lets you switch screens to view on and Adobe® Flash® 11.1.
    [Show full text]
  • Rtlinux and Embedded Programming
    RTLinux and embedded programming Victor Yodaiken Finite State Machine Labs (FSM) RTLinux – p.1/33 Who needs realtime? How RTLinux works. Why RTLinux works that way. Free software and embedded. Outline. The usual: definitions of realtime. RTLinux – p.2/33 How RTLinux works. Why RTLinux works that way. Free software and embedded. Outline. The usual: definitions of realtime. Who needs realtime? RTLinux – p.2/33 Why RTLinux works that way. Free software and embedded. Outline. The usual: definitions of realtime. Who needs realtime? How RTLinux works. RTLinux – p.2/33 Free software and embedded. Outline. The usual: definitions of realtime. Who needs realtime? How RTLinux works. Why RTLinux works that way. RTLinux – p.2/33 Realtime software: switch between different tasks in time to meet deadlines. Realtime versus Time Shared Time sharing software: switch between different tasks fast enough to create the illusion that all are going forward at once. RTLinux – p.3/33 Realtime versus Time Shared Time sharing software: switch between different tasks fast enough to create the illusion that all are going forward at once. Realtime software: switch between different tasks in time to meet deadlines. RTLinux – p.3/33 Hard realtime 1. Predictable performance at each moment in time: not as an average. 2. Low latency response to events. 3. Precise scheduling of periodic tasks. RTLinux – p.4/33 Soft realtime Good average case performance Low deviation from average case performance RTLinux – p.5/33 The machine tool generally stops the cut as specified. The power almost always shuts off before the turbine explodes. Traditional problems with soft realtime The chips are usually placed on the solder dots.
    [Show full text]
  • QNX Neutrino® Realtime Operating System
    PRODUCT BRIEF QNX Neutrino® Realtime Operating System QNX Neutrino® is a full-featured and robust operating system designed to enable the next-generation of products for automotive, medical and industrial embedded systems. Microkernel design and modular architecture enable customers to create highly optimized and reliable systems with low total cost of ownership. With QNX Neutrino®, embedded systems designers can create compelling, safe and secure devices built on a highly reliable operating system software foundation that helps guard against system malfunctions, malware and cyber security breaches. For over 35 years, thousands of companies have deployed and The QNX Neutrino microkernel memory-protected architecture trusted QNX realtime technology to ensure the best combination provides a foundation to build safety-critical systems. QNX of performance, security and reliability in the world’s most Neutrino® is 100% API compatible with QNX pre-certified mission-critical systems. software products that address compliance with safety certifica- tions in automotive (ISO 26262), industrial safety (IEC 61508) and Built-in mission critical reliability medical devices (IEC 62304). Time-tested and field-proven, the QNX Neutrino® is built on a true microkernel architecture. Under this system, every driver, Maximize software investments application, protocol stack, and filesystem runs outside the kernel QNX Neutrino® provides a common software platform that can be in the safety of memory-protected user space. Virtually any deployed for safety certified and non-certified projects across a component can fail and be automatically restarted without broad range of hardware platforms. Organizations can reduce aecting other components or the kernel. No other commercial duplication, costs and risks associated with the deployment of RTOS provides such a high level of fault containment and recovery.
    [Show full text]