Muen Policy & Toolchain

Slides:



Advertisements
Similar presentations
Network II.5 simulator ..
Advertisements

Chapter 3 Process Description and Control
Program Development Tools The GNU (GNU’s Not Unix) Toolchain The GNU toolchain has played a vital role in the development of the Linux kernel, BSD, and.
MODERN OPERATING SYSTEMS Third Edition ANDREW S. TANENBAUM Chapter 3 Memory Management Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall,
CMPT 300: Operating Systems I Dr. Mohamed Hefeeda
11/13/01CS-550 Presentation - Overview of Microsoft disk operating system. 1 An Overview of Microsoft Disk Operating System.
Introduction to Kernel
Home: Phones OFF Please Unix Kernel Parminder Singh Kang Home:
Chapter 13 Embedded Systems
Translation Buffers (TLB’s)
Memory Management 1 CS502 Spring 2006 Memory Management CS-502 Spring 2006.
CS-3013 & CS-502, Summer 2006 Memory Management1 CS-3013 & CS-502 Summer 2006.
MEMORY MANAGEMENT By KUNAL KADAKIA RISHIT SHAH. Memory Memory is a large array of words or bytes, each with its own address. It is a repository of quickly.
Processes and Resources
Using Two Queues. Using Multiple Queues Suspended Processes Processor is faster than I/O so all processes could be waiting for I/O Processor is faster.
Software Development and Software Loading in Embedded Systems.
Copyright Arshi Khan1 System Programming Instructor Arshi Khan.
An Introduction to Software Architecture
Eric Keller, Evan Green Princeton University PRESTO /22/08 Virtualizing the Data Plane Through Source Code Merging.
Three fundamental concepts in computer security: Reference Monitors: An access control concept that refers to an abstract machine that mediates all accesses.
6 Memory Management and Processor Management Management of Resources Measure of Effectiveness – On most modern computers, the operating system serves.
Chapter 1 : The Linux System Part 1 Lecture 1 10/21/
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
Computers Operating System Essentials. Operating Systems PROGRAM HARDWARE OPERATING SYSTEM.
© Janice Regan, CMPT 300, May CMPT 300 Introduction to Operating Systems Memory: Relocation.
By Teacher Asma Aleisa Year 1433 H.   Goals of memory management  To provide a convenient abstraction for programming.  To allocate scarce memory.
Hardware process When the computer is powered up, it begins to execute fetch-execute cycle for the program that is stored in memory at the boot strap entry.
10. Epilogue ENGI 3655 Lab Sessions.  We took control of the computer as early as possible, right after the end of the BIOS  Our multi-stage bootloader.
1 Process Description and Control Chapter 3. 2 Process A program in execution An instance of a program running on a computer The entity that can be assigned.
What is a Process ? A program in execution.
1 Computer System Overview Chapter 1. 2 Operating System Exploits the hardware resources of one or more processors Provides a set of services to system.
SQL Database Management
Introduction to the FPGA and Labs
Memory Management Chapter 3
Translation Lookaside Buffer
Introduction to Kernel
Memory Management By: Piyush Agarwal ( ) Akashdeep ( )
Basic Computer Organization and Design
Processes and threads.
Chapter 2 Memory and process management
CSCI-235 Micro-Computer Applications
Session 3 Memory Management
Operating System Structure
Review of computer processing and the basic of Operating system
Lecture 1 Runtime environments.
2P13 Week 2.
Page Replacement.
Background Program must be brought into memory and placed within a process for it to be run. Input queue – collection of processes on the disk that are.
Intro. To Operating Systems
COMPUTER SOFT WARE Software is a set of electronic instructions that tells the computer how to do certain tasks. A set of instructions is often called.
Main Memory Background Swapping Contiguous Allocation Paging
Process Description and Control
Analysis models and design models
CMP 131 Introduction to Computer Programming
An Introduction to Software Architecture
Translation Buffers (TLB’s)
Chapter 2: Operating-System Structures
Chapter 8: Memory Management strategies
CS IA: Procedural Programming CS IB: Object-Oriented Programming
Principles of Programming Languages
Translation Buffers (TLB’s)
Lecture 1 Runtime environments.
Translation Buffers (TLBs)
Computer components is a programmable machine that receives input, stores and manipulates data, and provides output in a useful format. Computer The computer.
Chapter 2: Operating-System Structures
COMP755 Advanced Operating Systems
Review What are the advantages/disadvantages of pages versus segments?
In Today’s Class.. General Kernel Responsibilities Kernel Organization
Page Main Memory.
Presentation transcript:

Muen Policy & Toolchain HABEEB P

Muen policy A policy is a description of the system running on top of the Muen Separation Kernel. It defines what hardware resources are present, how many active components (called subjects) the system is composed of, how they interact and which system resources they are allowed to access. The policy serves as a static description of a Muen system.

Muen policy The following properties are specified by the policy: Hardware resources Kernel diagnostics device Physical memory regions Events Communication channels Components Subjects Scheduling plans

Hardware Resources All available hardware resources of a target machine must be defined in the system policy in order to perform static resource allocation at integration time. Data required by a hardware description includes Amount of available physical memory Number of logical CPUs Hardware device resources

Kernel diagnostics device The Muen SK can be instructed to output debugging information during runtime. The kernel diagnostics device specifies which I/O device the kernel is to use for this purpose.

Physical Memory Regions This part of the policy specifies the physical memory layout of the system. Memory regions are defined by their size, caching, type and address. Muen Policy, Memory Regions

Events Subjects can use events to either deliver an interrupt or hand over execution to a target subject. The first kind of event provides a basic notification mechanism and enables the implementation of event-driven services. The second type facilitates suspension of execution of the source subject and switching to the target. Muen Events

Communication Channels Inter-subject communication is represented by channels. These channels represent directed information flows since they have a single writer and possibly multiple readers. Optionally a channel can have an associated notification event . Channels are declared globally and have an unique name to be unambiguous.

Communication Channels .. Muen Channel Example

Components A component is a piece of software executed by the SK. The description of a component specifies, The binary program file logical resources such communication channels Type of the component Muen Components Example

Subjects Subjects are instances of components. A subject specification references a component and maps the declared logical resources to physical resources provided by the system. subjects can specify extra resources such as device and memory mappings

Subjects Subjects Example

Scheduling plans The Muen SK performs scheduling of subjects in a fixed, cyclic and pre-emptive way according to users specification. Scheduling plans specify in what order subjects are executed on which logical CPU and for how long. A scheduling plan is specified in terms of frames Major Frame Minor Frame

Scheduling plans .. Major Frame Minor Frame Consists of a sequence of minor frames. Minor Frame A minor frame specifies a subject and a precise amount of time. This information is directly applied by the scheduler. Example of Major Frame

Example Scheduling Plan Scheduling plans .. An example of a scheduling plan for multiple logical CPUs Example Scheduling Plan

Scheduling plans .. Example Schedule <scheduling tickRate="10000"> <majorFrame> <cpu id="0"> <minorFrame subject="tau0" ticks="20"/> <minorFrame subject="vt" ticks="50"/> </cpu> <cpu id="1"> <minorFrame subject="nic_linux" ticks="20"/> <minorFrame subject="nic_linux" ticks="100"/> </majorFrame> </scheduling>

POLICY FORMAT

Policy format The system policy is specified in XML. To provide abstractions and a compact way for users three different policy formats are used: Source Format Format A Format B

Source Format The user-specified policy is written in the source format. Many XML elements and attributes are optional and will be filled in with default values during later steps of the policy compilation process. Kernel is not part of the source format since kernel automatically added by the policy expansion step.

Source Format .. XML type specification of System Element in source format

Format A Format A is a processed version of the source format where all includes are resolved. All implicit elements, such as for example automatically generated page table memory regions, are specified. The kernel configuration is also declared as part of format A. The only optional attributes are addresses of physical memory regions.

Format A XML type specification of System Element in source format XML type specification of System Element in format A

Format B Format B is equivalent to Format A except that all physical memory regions have a fixed location (i.e. their physical address is set).

BUILD PROCESS

Build process The build of a system is divided into the following steps: Policy compilation Policy validation Structure generation Image packaging

Build process Src: [1]

TOOLCHAIN

Merger The Merger combines user-provided system policy files into a single XML document. Input System policy in format source, platform specification, hardware description Output System policy in format source (merged)

Expander The expander completes the user-provided system policy by creating or deriving additional configuration elements. The Expander performs the following actions: Pre-check the system policy to make sure it is sound Expand channels Expand kernel sections Expand additional subject information Expand profile-specific information Post-check resulting policy

Allocator The Allocator is responsible to assign a physical address to all global memory regions. Allocator initializes the physical memory view of the system based on the physical memory blocks specified in the XML hardware section. Reserves memory that is occupied by pre-allocated memory elements (i.e. memory regions with a physical address or device memory). Finally it places all remaining memory regions in physical memory.

Validator The Validator performs additional checks that go beyond the basic restrictions imposed by the XML schema validation. Currently over 90 checks are performed. Examples of checks include: Assert that memory regions do not overlap Assert that no subject has access to system or kernel memory Assert that scheduling plan major frames have the same length on each CPU

Structure Generators These tools do not change the policy and use it read-only. Generate some structures by using policy file. Some Example structures include: Page tables I/O bitmaps for subjects MSR Bitmaps Linux Zero Pages

Page Tables Generate page tables for kernel(s) and subjects. These page tables are used to grant access to physical memory according to the virtual memory layout of the subject. An IA32-e page table is generated for each kernel running on a logical, active CPU. Depending on the subject profile either native 64- bit IA32-e or Extended Page Tables (EPT) are generated.

Packer The Packer tool assembles the final system image by first allocating a memory buffer which is initialized with zero. The size of the buffer is large enough to hold the complete system image, which consists of all file- backed memory regions specified in the policy: Kernel binary Kernel page tables I/O bitmaps Subject binaries Subject page tables ..

References [1]. Muen – Toolchain , Reto Buerki ,Adrian-Ken Rueegsegger, February 22, 2016 [2]. Muen - An x86/64 Separation Kernel for High Assurance Reto Buerki, Adrian-Ken Rueegsegger August 29, 2013

THANK YOU