Porting Plan 9 to the PowerPC Architecture Ian Friedman Ajay Surie Adam Wolbach.

Slides:



Advertisements
Similar presentations
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 3: Operating Systems Computer Science: An Overview Tenth Edition.
Advertisements

Khaled A. Al-Utaibi  Computers are Every Where  What is Computer Engineering?  Design Levels  Computer Engineering Fields  What.
DCM Embedded Software Infrastructure, Build Environment and Kernel Modules A.Norman (U.Virginia) 1 July '09 NOvA Collaboration Mtg.
CGS 3763 Operating Systems Concepts Spring 2013 Dan C. Marinescu Office: HEC 304 Office hours: M-Wd 11: :30 AM.
Chapter 6 Limited Direct Execution
INTRODUCTION OS/2 was initially designed to extend the capabilities of DOS by IBM and Microsoft Corporations. To create a single industry-standard operating.
Operating System Structure. Announcements Make sure you are registered for CS 415 First CS 415 project is up –Initial design documents due next Friday,
Home: Phones OFF Please Unix Kernel Parminder Singh Kang Home:
Advanced OS Chapter 3p2 Sections 3.4 / 3.5. Interrupts These enable software to respond to signals from hardware. The set of instructions to be executed.
Cs238 Lecture 3 Operating System Structures Dr. Alan R. Davis.
1 Last Class: Introduction Operating system = interface between user & architecture Importance of OS OS history: Change is only constant User-level Applications.
Pyxis Aaron Martin April Lewis Steve Sherk. September 5, 2005 Pyxis16002 General-purpose 16-bit RISC microprocessor bit registers 24-bit address.
Build an Operating System
Interrupt Mechanisms in the 74xx PowerPC Architecture Porting Plan 9 to the PowerPC Architecture Ajay Surie Adam Wolbach.
Lecture 7 Lecture 7: Hardware/Software Systems on the XUP Board ECE 412: Microcomputer Laboratory.
Xen and the Art of Virtualization Paul Barham, Boris Dragovic, Keir Fraser, Steven Hand, Tim Harris, Alex Ho, Rolf Neugebauer, Ian Pratt, Andrew Warfield.
Computer Organization and Assembly language
I/O Tanenbaum, ch. 5 p. 329 – 427 Silberschatz, ch. 13 p
CSE598C Virtual Machines and Their Applications Operating System Support for Virtual Machines Coauthored by Samuel T. King, George W. Dunlap and Peter.
Out-of-Order OpenRISC 2 semesters project Semester A: Implementation of OpenRISC on XUPV5 board Final A Presentation By: Vova Menis-Lurie Sonia Gershkovich.
What is Router? Router is a device which makes communication between two or more networks present in different geographical locations. Routers are data.
hardware and operating systems basics.
Out-of-Order OpenRISC 2 semesters project Semester A: Implementation of OpenRISC on XUPV5 board Midterm Presentation By: Vova Menis-Lurie Sonia Gershkovich.
VxWorks & Memory Management
1 Computer System Overview Chapter 1. 2 n An Operating System makes the computing power available to users by controlling the hardware n Let us review.
COMP 3438 – Part I - Lecture 4 Introduction to Device Drivers Dr. Zili Shao Department of Computing The Hong Kong Polytechnic Univ.
Three fundamental concepts in computer security: Reference Monitors: An access control concept that refers to an abstract machine that mediates all accesses.
1 Nios II Processor Architecture and Programming CEG 4131 Computer Architecture III Miodrag Bolic.
Computers organization & Assembly Language Chapter 0 INTRODUCTION TO COMPUTING Basic Concepts.
Cisco Router Hardware Software overview. In this lecture we will investigate an overview of Cisco router hardware and software. We will first turn our.
© Janice Regan, CMPT 300, May CMPT 300 Introduction to Operating Systems Operating Systems Overview Part 2: History (continued)
I/O management is a major component of operating system design and operation Important aspect of computer operation I/O devices vary greatly Various methods.
Plan 9 / PPC Virtual Memory Porting Plan 9 to the PowerPC 74xx Architecture Ajay Surie Adam Wolbach Operating Systems Practicum.
Computers Operating System Essentials. Operating Systems PROGRAM HARDWARE OPERATING SYSTEM.
2003 Dominic Swayne1 Microsoft Disk Operating System and PC DOS CS-550-1: Operating Systems Fall 2003 Dominic Swayne.
 Virtual machine systems: simulators for multiple copies of a machine on itself.  Virtual machine (VM): the simulated machine.  Virtual machine monitor.
Processes Introduction to Operating Systems: Module 3.
By Teacher Asma Aleisa Year 1433 H.   Goals of memory management  To provide a convenient abstraction for programming.  To allocate scarce memory.
Operating System Structure A key concept of operating systems is multiprogramming. –Goal of multiprogramming is to efficiently utilize all of the computing.
UNIX Unit 1- Architecture of Unix - By Pratima.
CSC414 “Introduction to UNIX/ Linux” Lecture 2. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Full and Para Virtualization
Implementation of Embedded OS Lab3 Porting μC/OS-II.
OSes: 2. Structs 1 Operating Systems v Objective –to give a (selective) overview of computer system architectures Certificate Program in Software Development.
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.
Lecture 5 Rootkits Hoglund/Butler (Chapters 1-3).
Part IVI/O Systems Chapter 13: I/O Systems. I/O Hardware a typical PCI bus structure 2.
Configuring a Router Module 3 Semester 2. Router Configuration Tasks Name a router Set passwords Examine show commands Configure a serial interface Configure.
CS 162 Discussion Section Week 6. Administrivia Project 2 Deadlines – Initial Design Due: 3/1 – Review Due: 3/5 – Code Due: 3/15.
Coreboot: the open source BIOS. Lennart Benschop Presentation at T-DOSE 2011 Sunday :00.
1 Free Electrons. Kernel, drivers and embedded Linux development, consulting, training and support. http//free-electrons.com Embedded Linux system development.
Introduction to Operating Systems Concepts
Introduction to Virtualization
Virtualization.
Kernel Design & Implementation
Chapter 8: Main Memory.
CS 140 Lecture Notes: Virtual Machines
OS Virtualization.
AT91RM9200 Boot strategies This training module describes the boot strategies on the AT91RM9200 including the internal Boot ROM and the U-Boot program.
Configuring a Router Module 3 Semester 2.
Basic Concepts Protection: Security:
Chapter 2: Operating-System Structures
Operating Systems Lecture 3.
CSE 451: Operating Systems Autumn 2003 Lecture 10 Paging & TLBs
CS703 - Advanced Operating Systems
Chapter 2: Operating-System Structures
Chapter 13: I/O Systems.
Chapter 13: I/O Systems “The two main jobs of a computer are I/O and [CPU] processing. In many cases, the main job is I/O, and the [CPU] processing is.
Presentation transcript:

Porting Plan 9 to the PowerPC Architecture Ian Friedman Ajay Surie Adam Wolbach

2 Plan 9 OS developed by Bell Labs in order to cost-effectively manage large, centralized resources to employees at cheap, less powerful terminals Key Features: –Centralized resources allow for efficient management/sharing –Local name space, regardless of the box in front of you –Everything is (theoretically) considered a file, including devices Thus, there exists a unique protocol that accesses everything –Cheap for large-scale implementations

3 Project Additions What We Won’t Change: –Fundamental operating system design Specification of OS remains the same, no new features What We Will Add: –Compatibility with 32-bit PowerPC architectures Booting with OpenFirmware and BootX/Yaboot Memory Management Device Support: Console I/O, Ethernet This is the type of PowerPC downstairs: 74xx (almost certain of this) –Compatibility with 64-bit PowerPC architectures with 32-bit emulation

4 Resources 412 Lab/Wean Hall 3508 Cluster 1 iMac G4 –744x Series PowerPC –Used for Testing 3 Linux “Boxes” –Made of miscellaneous parts off the CS pile –Reasonably fast –Used for Coding/Compiling/Debugging Everything we need has been provided

5 Code Base Plan 9 existing PowerPC code –C Code ~ 10,000 lines A lot of it is code for different PPC hardware (2 ethernet drivers, Saturn, 8260) Can use Plan 9 common kernel routines (i.e. main.c) and kernel interface to ethernet (~1000 lines) Probably don’t need to touch protocol code [TLS 1.0, SSL 3.0] – (~2000 lines) Can completely ignore flash related code (BLAST) and UART serial code (~2000 lines) –Plan 9 assembly code ~ 1100 lines Not sure how much will need to change

6 Booting Plan 9 OpenFirmware –Uses Forth as its command interface –Provides basic hardware support –Loads the kernel for us Can load kernel over TFTP! –Once the kernel is loaded, we still need to talk to OF for devices

7 Booting Plan 9 (cont’d) The Task at Hand: Figure out how to talk to OF for device support (console/ethernet) Investigating two possibilities: –Primary: BootX Darwin’s bootloader Not very well documented –Secondary/Backup: Yaboot Used by PPC linux distributions Also not very well documented

8 Memory Management (based on Using PowerPC 740/750 architecture specification (32-bit) 2 Memory Management Units –Distinctive behaviors for Data and Instruction fetches/translations Each have their own L1 cache Unified L2 cache Memory Support –Physical Memory: 64 Gigabytes (2 36 ) –Virtual Memory: 4 Pentabytes (2 52 )

9 Memory Address Translation 3 Address Translation Modes –Page Address Translation In other words, virtualization via segmentation –Translation from 32-bit effective address (EA), to 52-bit virtual address (VA) (by segment table), to 32-bit real/physical address (PA) (by page table) –Segment table comprised of 16 on-chip segment registers –Segmentation also used as memory-mapping for I/O devices –Block Address Translation EA translated to PA via BAT table lookup –Table is actually set of pairs of on-chip registers (limiting the number of possible “Blocks”), separate for Data and Instructions –Real Addressing Mode Effective Address = Physical Address (i.e., no virtualization)

10

11 Memory Management Documentation: –Actual specification: B20050FF C28E2/$file/7xx_um.pdf Google “PowerPC RISC Microprocessor” –IBM Overview: FBEAAB9F7A288ED787256AE /$file/PowerPC750FXmpf.pdf Google”powerpc 740/750 memory management unit” –Brief introduction to PPC architecture:

12 Lines of Code to Write Bootloader –Existing open source code available, may require minor modification Memory Management (~300 lines) Interrupts / Hardware specific (~350 lines) Device Drivers –Console (~200 lines – depending on available code for PPC) –Ethernet (~800 lines) –Clock / Timer (~100 lines) Total >= 1800 lines

13 Brief Schedule - Optimistic 14 weeks remaining in the semester Stage I (2 – 3 weeks) –Understand existing code / architecture Stage II (~4 weeks) –Open Firmware / Booting (~4 weeks) –Memory Management (4 – 6 weeks) Stage III (~3 weeks) –Console driver –Ethernet driver –Integration Stage IV (~2 weeks) –Debugging / making it work

14 Issues / Challenges Understanding existing code base –Poorly documented, module structure unclear (not the way we were taught in 410!) –Will probably require more time than we expect Understanding Plan 9 assembly Integrating new code – maintaining the “Plan 9 way” of kernel implementation Probably others we haven’t thought of…