SlideShare ist ein Scribd-Unternehmen logo
1 von 39
Downloaden Sie, um offline zu lesen
Qi - Lightweight Boot Loader
                    Applied in
           Mobile and Embedded Devices

                        Jim Huang (jserv) &
                             Matt Hsu
                            from 0xlab

                                    FreedomHEC 2009, Taipei
                                             June 10, 2009

                                                                 1
0xlab – connect your device to application – http://0xlab.org/
Rights to copy
                                                                       © Copyright 2009 0xlab.org
                                                                               contact@0xlab.org
                                                                 Corrections, suggestions, contributions and
                                                                                  translations are welcome!
                                                                                Latest update: Jun 10, 2009

   Attribution – ShareAlike 3.0
   You are free
      to copy, distribute, display, and perform the work
      to make derivative works
      to make commercial use of the work
   Under the following conditions
         Attribution. You must give the original author credit.
         Share Alike. If you alter, transform, or build upon this work, you may distribute the
         resulting work only under a license identical to this one.
      For any reuse or distribution, you must make clear to others the license terms of this
      work.
      Any of these conditions can be waived if you get permission from the copyright holder.
   Your fair use and other rights are in no way affected by the above.
   License text: http://creativecommons.org/licenses/by-sa/3.0/legalcode
                                                                                                               2
0xlab – connect your device to application – http://0xlab.org/
Our Background

    We are Taiwanese engineers who are always enthusiastic in
    modern technologies and open source software development.
        Jim Huang (jserv) <jserv@0xlab.org>
              0xlab co-founder, Openmoko coreteam, LXDE co-founder,
              Kaffe/Free Java developer
              Involved in design/implementation for consumer electronics, such
              as mobile phone, GPS/PND, Digital TV, mobile TV, etc.
        Matt Hsu <matt@0xlab.org>
              0xlab kernel maintainer, Openmoko kernel developer
              {u-boot,kernel}-{hxd8,gta02,gta03/3d7k}
              Dash Express (the first two-way, Internet-connected GPS navigation system)



                                                                                           3
0xlab – connect your device to application – http://0xlab.org/
Agenda

           Evolution of Boot Loader
                The “function” of boot loaders
                      Our experience from Openmoko project
                Applied in PC and Embedded Systems
           Overview of Qi
                Principal: KISS (Keep It Simple and Stupid)
           Practical Qi
                Real examples following the idea behind Qi
           Future Perspectives




                                                                 4
0xlab – connect your device to application – http://0xlab.org/
Evolution of Boot Loader
                The “function” of boot loaders
                  Our experience from Openmoko project
                Applied in PC and Embedded Systems
           Overview of Qi
                Principal: KISS (Keep It Simple and Stupid)
           Practical Qi
                Real examples following the idea behind Qi
           Future Perspectives



                                                                 5
0xlab – connect your device to application – http://0xlab.org/
Linux Bootstraping



             Boot Loader for GNU/Linux
             Boot Loader for GNU/Linux                            GNU/Linux


                                                                       /usr/sbin/httpd
                                                                        /usr/sbin/httpd

                                                                  /bin/ls
          BIOS                     Bootloader                      /bin/ls
                                                         GRUB
                                                         GRUB
                                                         Stage2
                                                         Stage2
       ROT                        GRUB
                                  GRUB                                  Linux
                                             GRUB
                                             GRUB                        Linux
                                  Stage1
                                  Stage1                                Kernel
                                             Stage1.5
                                             Stage1.5                   Kernel
        CRTM
        CRTM       POST
                   POST           (MBR)
                                   (MBR)




                                                                                          6
0xlab – connect your device to application – http://0xlab.org/
Linux on PC
                                                                          Memory

         #
         #
         #hello world :-(                     PC                        User Apps
         #
         #


           Keybo                                                          Kernel
                ard

                                                             IO
                                                           Devices
          Disk File                                                        File System
           System
                                                                     File system on disk   7
0xlab – connect your device to application – http://0xlab.org/
Linux on Embedded



                                                                     Memory

                                                                   User Apps
                                  CPU                  IO
                                                                      Kernel
                    RAM              ROM


                                                                     File System


                                                                 File system on chip

                                                                                       8
0xlab – connect your device to application – http://0xlab.org/
Originally made by Compaq (now HP)
           iPAQ 3650 launched in 2000
           Runs Windows CE 3.0/PocketPC
           bootldr from handhelds.org started.




                                                                 9
0xlab – connect your device to application – http://0xlab.org/
User Interaction on PC


                                        printf                      scanf


 Kernel
                                                    Kernel
   Device
   Driver            Display Adaptor                             Keyboard Driver


                             #
                             #                                     Keybo
                             #hello world :-(                            ard
                             #
                             #

                                                                                   10
0xlab – connect your device to application – http://0xlab.org/
User Interaction on Embedded


                                        printf                      scanf


 Kernel
                                                    Kernel
   Device
   Driver            Display Adaptor                             Keyboard Driver




                           Any Output                            Any Input
                             Device                               Device
                                                                                   11
0xlab – connect your device to application – http://0xlab.org/
Embedded with Hardware



                                        LCD                                  Button

                                                                             Touch
                                       UART
      Replacing                                                  Replacing   screen
      Displayer                                                  Keyboard
                                         LED                                 UART


                                     Network                                 Network


                                                                                       12
0xlab – connect your device to application – http://0xlab.org/
Hardware

                                                                                           ROM



                                                    Address Bus

                                                                  Data Bus

                                                                             Control Bus
                  CPU                                                                      RAM



                                                                                                 13
0xlab – connect your device to application – http://0xlab.org/
Bootloader
                                                                 Kernel
                                       ROM
                                                             Rootdisk




                                        RAM


   System Memory Usage
   System Memory Usage
                 (static)
                 (static)                                                 14
0xlab – connect your device to application – http://0xlab.org/
Bootloader
                                                                  Kernel
                                            ROM
                                                                 Rootdisk



                                                                  Kernel




                                                                 Rootdisk
                                             RAM


                                                                  User
   System Memory Usage
   System Memory Usage
                                                                 Memory
               (running)
               (running)                                                      15
0xlab – connect your device to application – http://0xlab.org/
Linux
                                                                   kernel



                                         RAM

                                                                 RAM Disk




                                            0x0xffe00000

                                                                   u-boot
                                                                 Zipped Linux
      Local Booting
      Local Booting                      ROM                        kernel

    (u-boot, famous in
    (u-boot, famous in                                           Zipped root
     embedded world)
     embedded world)                                                image
                                                                                16
0xlab – connect your device to application – http://0xlab.org/
Remote Booting (u-boot)
                           Zipped Linux
                             Linux
                              kernel
                                                                           192.168.0.3


                             kernel
                                                                                   DHCP server

      RAM
                                                                                    TFTP server
                                                                                     Zipped kernel
                                                                                      Linux image
                                                                                (/home/TFTPdir/uImage)



                                                                                     NFS server
         0x0xffe00000

                              u-boot          MyIP: 192.168.0.253                    Root Image for
                                              Server IP: 192.168.0.3                  MPC860 Linux
      ROM                                     Kernel Name: uImage                    (/home/NFSdir/)
                                              NFS position: /home/NFSdir

                                                                                                         17
0xlab – connect your device to application – http://0xlab.org/
Functions!
                                                                       Bootloader
                                                                        Kernel
                                                                 ROM
          Initialize Board                                             Rootdisk
                Also enable basic debugging
                function
          Loading Kernel
                From ROM or From Remote Server
          Load Root Image
          Starting Kernel
                                                                 RAM




                                                                                    18
0xlab – connect your device to application – http://0xlab.org/
Boot Loader is No More Simple Now

           u-boot is proud of rich feature/functions:
           SD/MMC card + FAT file system
           Autoboot
           OS loading commands
           Upgrade itself
           Networking
           Environment variables
           NOR/NAND Flash
           Self-testing
           ...


                                                                 19
0xlab – connect your device to application – http://0xlab.org/
We even hacked more in u-boot
                         Openmoko hackers improved u-boot as the following:
                         http://wiki.openmoko.org/wiki/U-boot

                         Graphical menu for multiple boot (Yes, UI is usable.)
                         usbtty (Yes, you can make phone call via boot loader.)
                         Changeable boot screen (Yes, it comes with personal style.)
                         Control GSM modem directly (Yes, you can even digg firmware.)
                         Integrate tiny window system (Yes, we were crazy.)
                         … (too many) ...




                                                                                         20
0xlab – connect your device to application – http://0xlab.org/
Hacking is Fun, but...

     Both grub and u-boot are relatively complex and hard to
     improve/debug.
         Grub runs in 80386 protected mode in order to perform
         multiboot. (We hate software!)
         Grub can access several file systems, which implies huge
         code implementation.
         u-boot “stole” some device drivers (mainly NIC) from Linux
         kernel, but the performance is poor and somehow buggy.
         u-boot is single threaded (no tasks), and you have to handle
         interrupts very carefully.
         Painful programming always.



                                                                        21
0xlab – connect your device to application – http://0xlab.org/
Practical Reasons to Modify boot loader

           For consumer electronics, we modify boot loaders in
           embedded devices because...
           Make sure Linux can be safely booted under the proper
           DC battery voltage.
           Couple with charger before Linux is able to work.
           Rescue mode, Engineering mode, Field trial mode, …
           Firmware upgrade (including boot loader itself, Linux
           kernel, ramdisk, root file system, data, ...)
           Protect the firmware (encrypt system software
           information)                                Ethernet

           Flexible remote booting

                                                                          22
0xlab – connect your device to application – http://0xlab.org/    RS232
People tried to eliminate the efforts.

           Concepts: Linux itself can be used as Boot Loader.
           (2003) Joshua Wise, LAB (Linux As Bootloader) a.k.a.
           “bootldr-ng” for iPAQ.
           Linux has many commonly used features that
           would be beneficial to a bootloader, however
           difficult to port properly:
                USB, MMC/SD, Filesystem, ...
           (2005) Werner Almesberger, quot;kboot - A Boot
           Loader Based on Kexecquot;, Linux-Kongress
           (2007) “HTTPFUSE PS3Linux: Internet boot
           framework using HTTP”

  Qi leverages the above ideas to build up totally new one.       23
0xlab – connect your device to application – http://0xlab.org/
Evolution of Boot Loader
                The “function” of boot loaders
                      Our experience from Openmoko project
                Applied in PC and Embedded Systems

           Overview of Qi
                Principal: KISS (Keep It Simple and Stupid)
           Practical Qi
                Real examples following the idea behind Qi
           Future Perspectives




                                                                 24
0xlab – connect your device to application – http://0xlab.org/
Prerequisite

           Before introducing Qi, let us touch the
           background knowledge.
                                                                 1. Copy debug
           kexec system call in Linux Kernel 2.6                 kernel to reserved
                                                                                      Standard kernel
                                                                 RAM                    2. kernel
                Linux kernel warm-restart                                               panic, kexec
                kexec makes it possible to call a new                                   debug kernel
                kernel, without rebooting and going                  3. Analyze
                through the BIOS / firmware.                         crashed          Debug kernel
                                                                     kernel RAM
           kboot
                a boot loader based on kexec
                Basic idea: Without working up a
                sweat
                Extended project: PS3-Linux
                                                                                      Regular RAM

                                                                                                    25
0xlab – connect your device to application – http://0xlab.org/
kboot in Action




                                                                 26
0xlab – connect your device to application – http://0xlab.org/
With kboot, it s fairly simple
     With kboot, it s fairly simple
 to construct Graphical and Fancy
 to construct Graphical and Fancy
            Boot Loader.
            Boot Loader.




                                                                 27
0xlab – connect your device to application – http://0xlab.org/
Qi bootloader

        Openmoko planned to implement kboot and adopt it on
        GTA0x series. (Hint: Openmoko system architect, Werner Almesberger
        is the author of lilo and kboot as well.)

        But kboot is a second stage bootloader, we still need a
        legacy bootloader.
        Why it called “Qi”?
                   Umm quot;Qiquot; - not really a flower but if I remember my
                   Chinese mythology its the breath that brings things to life ?

                                          – Alan Cox
        Similar idea as kboot
              Not reinvent the wheel anymore, avoiding cutting and
              pasting drivers into u-boot
                                                                                   28
0xlab – connect your device to application – http://0xlab.org/
Qi in a nutshell

        Licensed under GNU GPL.
        Current status
              Openmoko does not maintain this project anymore
              Andy Green (ex-Openmoko kernel maintainer) continues
              contributing to Qi.
              http://git.warmcat.com/cgi-bin/cgit/qi/log/?h=txtr
        Qi supports few platforms at present.
              Samsung S3C24xx/S3C6410, Freescale iMX31
        Very small footprint
              ~28 kb size
         Fast boot time
              Comparing to u-boot, it's reduced about 28% boot time (time-to-
              desktop)
                                                                                29
0xlab – connect your device to application – http://0xlab.org/
Qi in a nutshell
                               Test report from SHR distribution running on FreeRunner/GTA02
                               Test report from SHR distribution running on FreeRunner/GTA02
        Booting SHR image with                                   Booting identical setup with Qi
        uBoot:                                                   flashed over uBoot:
        0:00 power button held down                              0:00 power button held down
        0:07 splash screen appears                               0:06 backlit black
                                                                  0:13 please wait booting... (only
                                                                 this text on console for next 38
        0:15 drops to console showing                            seconds)
        kernel messages scrolling by for
        ~1 minute                                                 0:51 Angstrom console message
                                                                 (at the end of kernel output with
                                                                 uBoot, but ONLY text display to
                                                                 appear throughout this stage with
                                                                 Qi)
        1:18 Openmoko 'please wait'
        splash                                                    0:54 Openmoko 'please wait'
                                                                 splash
                                                                 1:05 desktop animated splash
        1:31 desktop animated splash
                                                                 1:54 finished booting          Faster
         2:38 finished booting                                                                           30
0xlab – connect your device to application – http://0xlab.org/
Qi Architecture


                      Board level support
                                          - board dependent kernel command            Memory
                                                                                       Test
                                          - Multiple partition to boot


 2nd stage

                           SMDK6410
                                                 GTA02           GTA01   iMX-Lite31
                            GTA03


                                    Initialize - CPU
                                               - Memory
                                               - Console (UART)                      Passing
                                    - board detection                            Point of resume
  1st stage             CPU support - IO port init
                                    - Necessary devices to init
                                                                                                   31
0xlab – connect your device to application – http://0xlab.org/
KISS: Keep It Simple and Stupid
                             struct board_api {
                                ........
                                const struct board_variant
                                const * (*get_board_variant)(void);
                                int (*is_this_board)(void);
                                void (*early_port_init)(void);
                                void (*port_init)(void);
                                void (*post_serial_init)(void);
                                char * (*append_device_specific_cmdline)
                                         (char *);
                                void (*putc)(char);
                                ...
                                struct kernel_source kernel_source[4];
                             };
const struct board_api *boards[] = {
   &board_api_om_3d7k,
   &board_api_smdk6410,
   NULL /* always last */
};
                                                this_board = boards[board];
                                                 while (!flag && this_board)
                                                     /* check if it is the right board... */
                                                     if (this_board->is_this_board())
                                                         flag = 1;
Misc:
Misc:                                                else
straightforward boot config                              this_board = boards[board++];
straightforward boot config                                                                    32
0xlab – connect your device to application – http://0xlab.org/
Limitations of Qi

        Required an approach to update boot loader if device could not
        support booting from SD
              NOR boot, JTAG
        No boot menu support
        FAT partitions are ignored




                                                                         33
0xlab – connect your device to application – http://0xlab.org/
Evolution of Boot Loader
                The “function” of boot loaders
                      Our experience from Openmoko project
                Applied in PC and Embedded Systems
           Overview of Qi
                Principal: KISS (Keep It Simple and Stupid)

           Practical Qi
                Real examples following the idea behind Qi
           Future Perspectives




                                                                 34
0xlab – connect your device to application – http://0xlab.org/
Case Study

         Mass production for HXD8 (hardware name for Dash Express)
         project at Openmoko.
               There are two systems to diagnose hardware.
                     u-boot
                     customized kernel for production
               Duplicated test commands
               Maintenance is a nightmare
         Hardware verification in early stage
                                                                                 rsync

                                                                        Final stage:
              DM1:                              DM2:
           Diagnose the                     Diagnose after       Program GPS map database
          Board level stuff                   Assembly                 Into NAND flash

               u-boot
               u-boot                  customized kernel
                                       customized kernel           customized kernel
                                                                   customized kernel        35
0xlab – connect your device to application – http://0xlab.org/
Future Perspectives

           For mobile and embedded devices, boot sequence is changing.
           Qi is not only a boot loader project but a new approach to comply
           with the diverse requirements of various consumer electric
           devices/products.
           What consumers expect
                Faster boot time
                Personalization
                Secure data (client security solution)
           What manufacturers expect
                Firmware protection
                Robust system software


                                                                           36
0xlab – connect your device to application – http://0xlab.org/
Reference

        U-boot – the universal boot loader
              http://www.denx.de/wiki/U-Boot
        Qi boot loader wiki
              http://wiki.openmoko.org/wiki/Qi
        GNU GRUB – multiboot boot loader
              http://www.gnu.org/software/grub/
        Samsung S3C6410 Mobile Processor
              http://www.samsung.com/global/business/semiconductor/supp
              ort/brochures/downloads/systemlsi/s3c6410_datasheet_2008
              04.pdf
        Openmoko wiki – http://wiki.openmoko.org/
        Dash Express – http://dash.net/
                                                                          37
0xlab – connect your device to application – http://0xlab.org/
Thanks!

   We appreciate the great sponsorship from AzureWave
   Technologies, Inc. ( http://www.azurewave.com/ )
       Providing WiFi module
       Providing ARM development board




                                                                 38
0xlab – connect your device to application – http://0xlab.org/
0xlab                                            About 0xlab
Our focus is to strengthen the connection        http://0xlab.org
between hardware device manufacturers and
open source software communities and to
become the integrated solution provider
bringing more devices powered by open
source for daily use.



                                                 0xlab is founded by a group of engineers
                                                 enthusiastic in modern technologies and open
                                                 source software development.


                                                 0xlab is an open organization. We appreciate
                                                 anyone's participation in our projects and
                                                 planning to contribute to the free software
                                                 community.


We support open source.
  We open up our development process and
 results as much as possible.

 We will always be an open organization.
 Everyone can join for discussion, testing and
 development.

Weitere ähnliche Inhalte

Was ist angesagt?

Shorten Device Boot Time for Automotive IVI and Navigation Systems
Shorten Device Boot Time for Automotive IVI and Navigation SystemsShorten Device Boot Time for Automotive IVI and Navigation Systems
Shorten Device Boot Time for Automotive IVI and Navigation SystemsNational Cheng Kung University
 
Android Booting Sequence
Android Booting SequenceAndroid Booting Sequence
Android Booting SequenceJayanta Ghoshal
 
Android crash debugging
Android crash debuggingAndroid crash debugging
Android crash debuggingAshish Agrawal
 
F9: A Secure and Efficient Microkernel Built for Deeply Embedded Systems
F9: A Secure and Efficient Microkernel Built for Deeply Embedded SystemsF9: A Secure and Efficient Microkernel Built for Deeply Embedded Systems
F9: A Secure and Efficient Microkernel Built for Deeply Embedded SystemsNational Cheng Kung University
 
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)Toshiharu Harada, Ph.D
 
Learning AOSP - Android Booting Process
Learning AOSP - Android Booting ProcessLearning AOSP - Android Booting Process
Learning AOSP - Android Booting ProcessNanik Tolaram
 
Develop Your Own Operating Systems using Cheap ARM Boards
Develop Your Own Operating Systems using Cheap ARM BoardsDevelop Your Own Operating Systems using Cheap ARM Boards
Develop Your Own Operating Systems using Cheap ARM BoardsNational Cheng Kung University
 
Workshop su Android Kernel Hacking
Workshop su Android Kernel HackingWorkshop su Android Kernel Hacking
Workshop su Android Kernel HackingDeveler S.r.l.
 
Userspace drivers-2016
Userspace drivers-2016Userspace drivers-2016
Userspace drivers-2016Chris Simmonds
 
Introduction to Android by Demian Neidetcher
Introduction to Android by Demian NeidetcherIntroduction to Android by Demian Neidetcher
Introduction to Android by Demian NeidetcherMatthew McCullough
 

Was ist angesagt? (20)

Xvisor: embedded and lightweight hypervisor
Xvisor: embedded and lightweight hypervisorXvisor: embedded and lightweight hypervisor
Xvisor: embedded and lightweight hypervisor
 
Android Booting Scenarios
Android Booting ScenariosAndroid Booting Scenarios
Android Booting Scenarios
 
Shorten Device Boot Time for Automotive IVI and Navigation Systems
Shorten Device Boot Time for Automotive IVI and Navigation SystemsShorten Device Boot Time for Automotive IVI and Navigation Systems
Shorten Device Boot Time for Automotive IVI and Navigation Systems
 
Android Booting Sequence
Android Booting SequenceAndroid Booting Sequence
Android Booting Sequence
 
Android crash debugging
Android crash debuggingAndroid crash debugging
Android crash debugging
 
淺談探索 Linux 系統設計之道
淺談探索 Linux 系統設計之道 淺談探索 Linux 系統設計之道
淺談探索 Linux 系統設計之道
 
Android Internals
Android InternalsAndroid Internals
Android Internals
 
Improve Android System Component Performance
Improve Android System Component PerformanceImprove Android System Component Performance
Improve Android System Component Performance
 
F9: A Secure and Efficient Microkernel Built for Deeply Embedded Systems
F9: A Secure and Efficient Microkernel Built for Deeply Embedded SystemsF9: A Secure and Efficient Microkernel Built for Deeply Embedded Systems
F9: A Secure and Efficient Microkernel Built for Deeply Embedded Systems
 
Android Custom Kernel/ROM design
Android Custom Kernel/ROM designAndroid Custom Kernel/ROM design
Android Custom Kernel/ROM design
 
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)
Learning, Analyzing and Protecting Android with TOMOYO Linux (JLS2009)
 
Guides To Analyzing WebKit Performance
Guides To Analyzing WebKit PerformanceGuides To Analyzing WebKit Performance
Guides To Analyzing WebKit Performance
 
Learning AOSP - Android Booting Process
Learning AOSP - Android Booting ProcessLearning AOSP - Android Booting Process
Learning AOSP - Android Booting Process
 
Applied Computer Science Concepts in Android
Applied Computer Science Concepts in AndroidApplied Computer Science Concepts in Android
Applied Computer Science Concepts in Android
 
Accelerated Android Development with Linaro
Accelerated Android Development with LinaroAccelerated Android Development with Linaro
Accelerated Android Development with Linaro
 
Develop Your Own Operating Systems using Cheap ARM Boards
Develop Your Own Operating Systems using Cheap ARM BoardsDevelop Your Own Operating Systems using Cheap ARM Boards
Develop Your Own Operating Systems using Cheap ARM Boards
 
TOMOYO Linux on Android
TOMOYO Linux on AndroidTOMOYO Linux on Android
TOMOYO Linux on Android
 
Workshop su Android Kernel Hacking
Workshop su Android Kernel HackingWorkshop su Android Kernel Hacking
Workshop su Android Kernel Hacking
 
Userspace drivers-2016
Userspace drivers-2016Userspace drivers-2016
Userspace drivers-2016
 
Introduction to Android by Demian Neidetcher
Introduction to Android by Demian NeidetcherIntroduction to Android by Demian Neidetcher
Introduction to Android by Demian Neidetcher
 

Andere mochten auch

Andere mochten auch (11)

Ams Led73
Ams Led73Ams Led73
Ams Led73
 
Day 1-1-intro-sw-vuls
Day 1-1-intro-sw-vulsDay 1-1-intro-sw-vuls
Day 1-1-intro-sw-vuls
 
Linux introduction Class 02
Linux introduction Class 02Linux introduction Class 02
Linux introduction Class 02
 
Linux-without-a-bootloader
Linux-without-a-bootloaderLinux-without-a-bootloader
Linux-without-a-bootloader
 
Implementing Lightweight Networking
Implementing Lightweight NetworkingImplementing Lightweight Networking
Implementing Lightweight Networking
 
Android Boot Time Optimization
Android Boot Time OptimizationAndroid Boot Time Optimization
Android Boot Time Optimization
 
Game Programming By J2me
Game Programming By J2meGame Programming By J2me
Game Programming By J2me
 
J2ME
J2MEJ2ME
J2ME
 
Android power management
Android power managementAndroid power management
Android power management
 
Memory management in linux
Memory management in linuxMemory management in linux
Memory management in linux
 
Linux Memory Management
Linux Memory ManagementLinux Memory Management
Linux Memory Management
 

Ähnlich wie Qi -- Lightweight Boot Loader Applied in Mobile and Embedded Devices

Kernel Recipes 2013 - Easy rootfs using Buildroot
Kernel Recipes 2013 - Easy rootfs using BuildrootKernel Recipes 2013 - Easy rootfs using Buildroot
Kernel Recipes 2013 - Easy rootfs using BuildrootAnne Nicolas
 
BUD17-104: Scripting Languages in IoT: Challenges and Approaches
BUD17-104: Scripting Languages in IoT: Challenges and ApproachesBUD17-104: Scripting Languages in IoT: Challenges and Approaches
BUD17-104: Scripting Languages in IoT: Challenges and ApproachesLinaro
 
0xdroid -- community-developed Android distribution by 0xlab
0xdroid -- community-developed Android distribution by 0xlab0xdroid -- community-developed Android distribution by 0xlab
0xdroid -- community-developed Android distribution by 0xlabNational Cheng Kung University
 
Shared Object images in Docker: What you need is what you want.
Shared Object images in Docker: What you need is what you want.Shared Object images in Docker: What you need is what you want.
Shared Object images in Docker: What you need is what you want.Workhorse Computing
 
A Tour of Open Source on the Mainframe
A Tour of Open Source on the MainframeA Tour of Open Source on the Mainframe
A Tour of Open Source on the MainframeAll Things Open
 
Linux on System z Update: Current & Future Linux on System z Technology
Linux on System z Update: Current & Future Linux on System z TechnologyLinux on System z Update: Current & Future Linux on System z Technology
Linux on System z Update: Current & Future Linux on System z TechnologyIBM India Smarter Computing
 
Kernel init
Kernel initKernel init
Kernel initgowell
 
stackconf 2022: It’s Time to Debloat the Cloud with Unikraft
stackconf 2022: It’s Time to Debloat the Cloud with Unikraftstackconf 2022: It’s Time to Debloat the Cloud with Unikraft
stackconf 2022: It’s Time to Debloat the Cloud with UnikraftNETWAYS
 
Be Free Be Linux
Be Free Be LinuxBe Free Be Linux
Be Free Be Linuxaboelnour
 
Iz Pack
Iz PackIz Pack
Iz PackInria
 
Run Qt on Linux embedded systems using Yocto
Run Qt on Linux embedded systems using YoctoRun Qt on Linux embedded systems using Yocto
Run Qt on Linux embedded systems using YoctoMarco Cavallini
 
Crafting GNU/Linux distributions for Embedded target from Scratch/Source
Crafting GNU/Linux distributions for Embedded target from Scratch/SourceCrafting GNU/Linux distributions for Embedded target from Scratch/Source
Crafting GNU/Linux distributions for Embedded target from Scratch/SourceSourabh Singh Tomar
 
DEF CON 20 - Botnets Die Hard - Owned and Operated
DEF CON 20 - Botnets Die Hard - Owned and OperatedDEF CON 20 - Botnets Die Hard - Owned and Operated
DEF CON 20 - Botnets Die Hard - Owned and OperatedAditya K Sood
 

Ähnlich wie Qi -- Lightweight Boot Loader Applied in Mobile and Embedded Devices (20)

Kernel Recipes 2013 - Easy rootfs using Buildroot
Kernel Recipes 2013 - Easy rootfs using BuildrootKernel Recipes 2013 - Easy rootfs using Buildroot
Kernel Recipes 2013 - Easy rootfs using Buildroot
 
olibc: Another C Library optimized for Embedded Linux
olibc: Another C Library optimized for Embedded Linuxolibc: Another C Library optimized for Embedded Linux
olibc: Another C Library optimized for Embedded Linux
 
Foss Presentation
Foss PresentationFoss Presentation
Foss Presentation
 
BUD17-104: Scripting Languages in IoT: Challenges and Approaches
BUD17-104: Scripting Languages in IoT: Challenges and ApproachesBUD17-104: Scripting Languages in IoT: Challenges and Approaches
BUD17-104: Scripting Languages in IoT: Challenges and Approaches
 
0xdroid -- community-developed Android distribution by 0xlab
0xdroid -- community-developed Android distribution by 0xlab0xdroid -- community-developed Android distribution by 0xlab
0xdroid -- community-developed Android distribution by 0xlab
 
Arm 1-overview-090720075211-phpapp01
Arm 1-overview-090720075211-phpapp01Arm 1-overview-090720075211-phpapp01
Arm 1-overview-090720075211-phpapp01
 
Linux internals v4
Linux internals v4Linux internals v4
Linux internals v4
 
Shared Object images in Docker: What you need is what you want.
Shared Object images in Docker: What you need is what you want.Shared Object images in Docker: What you need is what you want.
Shared Object images in Docker: What you need is what you want.
 
JAVA CORE
JAVA COREJAVA CORE
JAVA CORE
 
A Tour of Open Source on the Mainframe
A Tour of Open Source on the MainframeA Tour of Open Source on the Mainframe
A Tour of Open Source on the Mainframe
 
Linux on System z Update: Current & Future Linux on System z Technology
Linux on System z Update: Current & Future Linux on System z TechnologyLinux on System z Update: Current & Future Linux on System z Technology
Linux on System z Update: Current & Future Linux on System z Technology
 
Universal Userland
Universal UserlandUniversal Userland
Universal Userland
 
Kernel init
Kernel initKernel init
Kernel init
 
stackconf 2022: It’s Time to Debloat the Cloud with Unikraft
stackconf 2022: It’s Time to Debloat the Cloud with Unikraftstackconf 2022: It’s Time to Debloat the Cloud with Unikraft
stackconf 2022: It’s Time to Debloat the Cloud with Unikraft
 
Be Free Be Linux
Be Free Be LinuxBe Free Be Linux
Be Free Be Linux
 
Iz Pack
Iz PackIz Pack
Iz Pack
 
Run Qt on Linux embedded systems using Yocto
Run Qt on Linux embedded systems using YoctoRun Qt on Linux embedded systems using Yocto
Run Qt on Linux embedded systems using Yocto
 
1061 (m2)
1061 (m2)1061 (m2)
1061 (m2)
 
Crafting GNU/Linux distributions for Embedded target from Scratch/Source
Crafting GNU/Linux distributions for Embedded target from Scratch/SourceCrafting GNU/Linux distributions for Embedded target from Scratch/Source
Crafting GNU/Linux distributions for Embedded target from Scratch/Source
 
DEF CON 20 - Botnets Die Hard - Owned and Operated
DEF CON 20 - Botnets Die Hard - Owned and OperatedDEF CON 20 - Botnets Die Hard - Owned and Operated
DEF CON 20 - Botnets Die Hard - Owned and Operated
 

Mehr von National Cheng Kung University

PyPy's approach to construct domain-specific language runtime
PyPy's approach to construct domain-specific language runtimePyPy's approach to construct domain-specific language runtime
PyPy's approach to construct domain-specific language runtimeNational Cheng Kung University
 
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明National Cheng Kung University
 
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明National Cheng Kung University
 
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明National Cheng Kung University
 
Lecture notice about Embedded Operating System Design and Implementation
Lecture notice about Embedded Operating System Design and ImplementationLecture notice about Embedded Operating System Design and Implementation
Lecture notice about Embedded Operating System Design and ImplementationNational Cheng Kung University
 
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學National Cheng Kung University
 
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明National Cheng Kung University
 

Mehr von National Cheng Kung University (20)

PyPy's approach to construct domain-specific language runtime
PyPy's approach to construct domain-specific language runtimePyPy's approach to construct domain-specific language runtime
PyPy's approach to construct domain-specific language runtime
 
Making Linux do Hard Real-time
Making Linux do Hard Real-timeMaking Linux do Hard Real-time
Making Linux do Hard Real-time
 
2016 年春季嵌入式作業系統課程說明
2016 年春季嵌入式作業系統課程說明2016 年春季嵌入式作業系統課程說明
2016 年春季嵌入式作業系統課程說明
 
Interpreter, Compiler, JIT from scratch
Interpreter, Compiler, JIT from scratchInterpreter, Compiler, JIT from scratch
Interpreter, Compiler, JIT from scratch
 
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明
進階嵌入式作業系統設計與實做 (2015 年秋季 ) 課程說明
 
Construct an Efficient and Secure Microkernel for IoT
Construct an Efficient and Secure Microkernel for IoTConstruct an Efficient and Secure Microkernel for IoT
Construct an Efficient and Secure Microkernel for IoT
 
The Internals of "Hello World" Program
The Internals of "Hello World" ProgramThe Internals of "Hello World" Program
The Internals of "Hello World" Program
 
How A Compiler Works: GNU Toolchain
How A Compiler Works: GNU ToolchainHow A Compiler Works: GNU Toolchain
How A Compiler Works: GNU Toolchain
 
Virtual Machine Constructions for Dummies
Virtual Machine Constructions for DummiesVirtual Machine Constructions for Dummies
Virtual Machine Constructions for Dummies
 
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明
給自己更好未來的 3 個練習:嵌入式作業系統設計、實做,與移植 (2015 年春季 ) 課程說明
 
從線上售票看作業系統設計議題
從線上售票看作業系統設計議題從線上售票看作業系統設計議題
從線上售票看作業系統設計議題
 
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明
進階嵌入式系統開發與實做 (2014 年秋季 ) 課程說明
 
Making Linux do Hard Real-time
Making Linux do Hard Real-timeMaking Linux do Hard Real-time
Making Linux do Hard Real-time
 
Implement Runtime Environments for HSA using LLVM
Implement Runtime Environments for HSA using LLVMImplement Runtime Environments for HSA using LLVM
Implement Runtime Environments for HSA using LLVM
 
Priority Inversion on Mars
Priority Inversion on MarsPriority Inversion on Mars
Priority Inversion on Mars
 
Lecture notice about Embedded Operating System Design and Implementation
Lecture notice about Embedded Operating System Design and ImplementationLecture notice about Embedded Operating System Design and Implementation
Lecture notice about Embedded Operating System Design and Implementation
 
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學
中輟生談教育: 完全用開放原始碼軟體進行 嵌入式系統教學
 
Open Source from Legend, Business, to Ecosystem
Open Source from Legend, Business, to EcosystemOpen Source from Legend, Business, to Ecosystem
Open Source from Legend, Business, to Ecosystem
 
Summer Project: Microkernel (2013)
Summer Project: Microkernel (2013)Summer Project: Microkernel (2013)
Summer Project: Microkernel (2013)
 
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明
進階嵌入式系統開發與實作 (2013 秋季班 ) 課程說明
 

Kürzlich hochgeladen

DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 

Kürzlich hochgeladen (20)

DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 

Qi -- Lightweight Boot Loader Applied in Mobile and Embedded Devices

  • 1. Qi - Lightweight Boot Loader Applied in Mobile and Embedded Devices Jim Huang (jserv) & Matt Hsu from 0xlab FreedomHEC 2009, Taipei June 10, 2009 1 0xlab – connect your device to application – http://0xlab.org/
  • 2. Rights to copy © Copyright 2009 0xlab.org contact@0xlab.org Corrections, suggestions, contributions and translations are welcome! Latest update: Jun 10, 2009 Attribution – ShareAlike 3.0 You are free to copy, distribute, display, and perform the work to make derivative works to make commercial use of the work Under the following conditions Attribution. You must give the original author credit. Share Alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under a license identical to this one. For any reuse or distribution, you must make clear to others the license terms of this work. Any of these conditions can be waived if you get permission from the copyright holder. Your fair use and other rights are in no way affected by the above. License text: http://creativecommons.org/licenses/by-sa/3.0/legalcode 2 0xlab – connect your device to application – http://0xlab.org/
  • 3. Our Background We are Taiwanese engineers who are always enthusiastic in modern technologies and open source software development. Jim Huang (jserv) <jserv@0xlab.org> 0xlab co-founder, Openmoko coreteam, LXDE co-founder, Kaffe/Free Java developer Involved in design/implementation for consumer electronics, such as mobile phone, GPS/PND, Digital TV, mobile TV, etc. Matt Hsu <matt@0xlab.org> 0xlab kernel maintainer, Openmoko kernel developer {u-boot,kernel}-{hxd8,gta02,gta03/3d7k} Dash Express (the first two-way, Internet-connected GPS navigation system) 3 0xlab – connect your device to application – http://0xlab.org/
  • 4. Agenda Evolution of Boot Loader The “function” of boot loaders Our experience from Openmoko project Applied in PC and Embedded Systems Overview of Qi Principal: KISS (Keep It Simple and Stupid) Practical Qi Real examples following the idea behind Qi Future Perspectives 4 0xlab – connect your device to application – http://0xlab.org/
  • 5. Evolution of Boot Loader The “function” of boot loaders Our experience from Openmoko project Applied in PC and Embedded Systems Overview of Qi Principal: KISS (Keep It Simple and Stupid) Practical Qi Real examples following the idea behind Qi Future Perspectives 5 0xlab – connect your device to application – http://0xlab.org/
  • 6. Linux Bootstraping Boot Loader for GNU/Linux Boot Loader for GNU/Linux GNU/Linux /usr/sbin/httpd /usr/sbin/httpd /bin/ls BIOS Bootloader /bin/ls GRUB GRUB Stage2 Stage2 ROT GRUB GRUB Linux GRUB GRUB Linux Stage1 Stage1 Kernel Stage1.5 Stage1.5 Kernel CRTM CRTM POST POST (MBR) (MBR) 6 0xlab – connect your device to application – http://0xlab.org/
  • 7. Linux on PC Memory # # #hello world :-( PC User Apps # # Keybo Kernel ard IO Devices Disk File File System System File system on disk 7 0xlab – connect your device to application – http://0xlab.org/
  • 8. Linux on Embedded Memory User Apps CPU IO Kernel RAM ROM File System File system on chip 8 0xlab – connect your device to application – http://0xlab.org/
  • 9. Originally made by Compaq (now HP) iPAQ 3650 launched in 2000 Runs Windows CE 3.0/PocketPC bootldr from handhelds.org started. 9 0xlab – connect your device to application – http://0xlab.org/
  • 10. User Interaction on PC printf scanf Kernel Kernel Device Driver Display Adaptor Keyboard Driver # # Keybo #hello world :-( ard # # 10 0xlab – connect your device to application – http://0xlab.org/
  • 11. User Interaction on Embedded printf scanf Kernel Kernel Device Driver Display Adaptor Keyboard Driver Any Output Any Input Device Device 11 0xlab – connect your device to application – http://0xlab.org/
  • 12. Embedded with Hardware LCD Button Touch UART Replacing Replacing screen Displayer Keyboard LED UART Network Network 12 0xlab – connect your device to application – http://0xlab.org/
  • 13. Hardware ROM Address Bus Data Bus Control Bus CPU RAM 13 0xlab – connect your device to application – http://0xlab.org/
  • 14. Bootloader Kernel ROM Rootdisk RAM System Memory Usage System Memory Usage (static) (static) 14 0xlab – connect your device to application – http://0xlab.org/
  • 15. Bootloader Kernel ROM Rootdisk Kernel Rootdisk RAM User System Memory Usage System Memory Usage Memory (running) (running) 15 0xlab – connect your device to application – http://0xlab.org/
  • 16. Linux kernel RAM RAM Disk 0x0xffe00000 u-boot Zipped Linux Local Booting Local Booting ROM kernel (u-boot, famous in (u-boot, famous in Zipped root embedded world) embedded world) image 16 0xlab – connect your device to application – http://0xlab.org/
  • 17. Remote Booting (u-boot) Zipped Linux Linux kernel 192.168.0.3 kernel DHCP server RAM TFTP server Zipped kernel Linux image (/home/TFTPdir/uImage) NFS server 0x0xffe00000 u-boot MyIP: 192.168.0.253 Root Image for Server IP: 192.168.0.3 MPC860 Linux ROM Kernel Name: uImage (/home/NFSdir/) NFS position: /home/NFSdir 17 0xlab – connect your device to application – http://0xlab.org/
  • 18. Functions! Bootloader Kernel ROM Initialize Board Rootdisk Also enable basic debugging function Loading Kernel From ROM or From Remote Server Load Root Image Starting Kernel RAM 18 0xlab – connect your device to application – http://0xlab.org/
  • 19. Boot Loader is No More Simple Now u-boot is proud of rich feature/functions: SD/MMC card + FAT file system Autoboot OS loading commands Upgrade itself Networking Environment variables NOR/NAND Flash Self-testing ... 19 0xlab – connect your device to application – http://0xlab.org/
  • 20. We even hacked more in u-boot Openmoko hackers improved u-boot as the following: http://wiki.openmoko.org/wiki/U-boot Graphical menu for multiple boot (Yes, UI is usable.) usbtty (Yes, you can make phone call via boot loader.) Changeable boot screen (Yes, it comes with personal style.) Control GSM modem directly (Yes, you can even digg firmware.) Integrate tiny window system (Yes, we were crazy.) … (too many) ... 20 0xlab – connect your device to application – http://0xlab.org/
  • 21. Hacking is Fun, but... Both grub and u-boot are relatively complex and hard to improve/debug. Grub runs in 80386 protected mode in order to perform multiboot. (We hate software!) Grub can access several file systems, which implies huge code implementation. u-boot “stole” some device drivers (mainly NIC) from Linux kernel, but the performance is poor and somehow buggy. u-boot is single threaded (no tasks), and you have to handle interrupts very carefully. Painful programming always. 21 0xlab – connect your device to application – http://0xlab.org/
  • 22. Practical Reasons to Modify boot loader For consumer electronics, we modify boot loaders in embedded devices because... Make sure Linux can be safely booted under the proper DC battery voltage. Couple with charger before Linux is able to work. Rescue mode, Engineering mode, Field trial mode, … Firmware upgrade (including boot loader itself, Linux kernel, ramdisk, root file system, data, ...) Protect the firmware (encrypt system software information) Ethernet Flexible remote booting 22 0xlab – connect your device to application – http://0xlab.org/ RS232
  • 23. People tried to eliminate the efforts. Concepts: Linux itself can be used as Boot Loader. (2003) Joshua Wise, LAB (Linux As Bootloader) a.k.a. “bootldr-ng” for iPAQ. Linux has many commonly used features that would be beneficial to a bootloader, however difficult to port properly: USB, MMC/SD, Filesystem, ... (2005) Werner Almesberger, quot;kboot - A Boot Loader Based on Kexecquot;, Linux-Kongress (2007) “HTTPFUSE PS3Linux: Internet boot framework using HTTP” Qi leverages the above ideas to build up totally new one. 23 0xlab – connect your device to application – http://0xlab.org/
  • 24. Evolution of Boot Loader The “function” of boot loaders Our experience from Openmoko project Applied in PC and Embedded Systems Overview of Qi Principal: KISS (Keep It Simple and Stupid) Practical Qi Real examples following the idea behind Qi Future Perspectives 24 0xlab – connect your device to application – http://0xlab.org/
  • 25. Prerequisite Before introducing Qi, let us touch the background knowledge. 1. Copy debug kexec system call in Linux Kernel 2.6 kernel to reserved Standard kernel RAM 2. kernel Linux kernel warm-restart panic, kexec kexec makes it possible to call a new debug kernel kernel, without rebooting and going 3. Analyze through the BIOS / firmware. crashed Debug kernel kernel RAM kboot a boot loader based on kexec Basic idea: Without working up a sweat Extended project: PS3-Linux Regular RAM 25 0xlab – connect your device to application – http://0xlab.org/
  • 26. kboot in Action 26 0xlab – connect your device to application – http://0xlab.org/
  • 27. With kboot, it s fairly simple With kboot, it s fairly simple to construct Graphical and Fancy to construct Graphical and Fancy Boot Loader. Boot Loader. 27 0xlab – connect your device to application – http://0xlab.org/
  • 28. Qi bootloader Openmoko planned to implement kboot and adopt it on GTA0x series. (Hint: Openmoko system architect, Werner Almesberger is the author of lilo and kboot as well.) But kboot is a second stage bootloader, we still need a legacy bootloader. Why it called “Qi”? Umm quot;Qiquot; - not really a flower but if I remember my Chinese mythology its the breath that brings things to life ? – Alan Cox Similar idea as kboot Not reinvent the wheel anymore, avoiding cutting and pasting drivers into u-boot 28 0xlab – connect your device to application – http://0xlab.org/
  • 29. Qi in a nutshell Licensed under GNU GPL. Current status Openmoko does not maintain this project anymore Andy Green (ex-Openmoko kernel maintainer) continues contributing to Qi. http://git.warmcat.com/cgi-bin/cgit/qi/log/?h=txtr Qi supports few platforms at present. Samsung S3C24xx/S3C6410, Freescale iMX31 Very small footprint ~28 kb size Fast boot time Comparing to u-boot, it's reduced about 28% boot time (time-to- desktop) 29 0xlab – connect your device to application – http://0xlab.org/
  • 30. Qi in a nutshell Test report from SHR distribution running on FreeRunner/GTA02 Test report from SHR distribution running on FreeRunner/GTA02 Booting SHR image with Booting identical setup with Qi uBoot: flashed over uBoot: 0:00 power button held down 0:00 power button held down 0:07 splash screen appears 0:06 backlit black 0:13 please wait booting... (only this text on console for next 38 0:15 drops to console showing seconds) kernel messages scrolling by for ~1 minute 0:51 Angstrom console message (at the end of kernel output with uBoot, but ONLY text display to appear throughout this stage with Qi) 1:18 Openmoko 'please wait' splash 0:54 Openmoko 'please wait' splash 1:05 desktop animated splash 1:31 desktop animated splash 1:54 finished booting Faster 2:38 finished booting 30 0xlab – connect your device to application – http://0xlab.org/
  • 31. Qi Architecture Board level support - board dependent kernel command Memory Test - Multiple partition to boot 2nd stage SMDK6410 GTA02 GTA01 iMX-Lite31 GTA03 Initialize - CPU - Memory - Console (UART) Passing - board detection Point of resume 1st stage CPU support - IO port init - Necessary devices to init 31 0xlab – connect your device to application – http://0xlab.org/
  • 32. KISS: Keep It Simple and Stupid struct board_api { ........ const struct board_variant const * (*get_board_variant)(void); int (*is_this_board)(void); void (*early_port_init)(void); void (*port_init)(void); void (*post_serial_init)(void); char * (*append_device_specific_cmdline) (char *); void (*putc)(char); ... struct kernel_source kernel_source[4]; }; const struct board_api *boards[] = { &board_api_om_3d7k, &board_api_smdk6410, NULL /* always last */ }; this_board = boards[board]; while (!flag && this_board) /* check if it is the right board... */ if (this_board->is_this_board()) flag = 1; Misc: Misc: else straightforward boot config this_board = boards[board++]; straightforward boot config 32 0xlab – connect your device to application – http://0xlab.org/
  • 33. Limitations of Qi Required an approach to update boot loader if device could not support booting from SD NOR boot, JTAG No boot menu support FAT partitions are ignored 33 0xlab – connect your device to application – http://0xlab.org/
  • 34. Evolution of Boot Loader The “function” of boot loaders Our experience from Openmoko project Applied in PC and Embedded Systems Overview of Qi Principal: KISS (Keep It Simple and Stupid) Practical Qi Real examples following the idea behind Qi Future Perspectives 34 0xlab – connect your device to application – http://0xlab.org/
  • 35. Case Study Mass production for HXD8 (hardware name for Dash Express) project at Openmoko. There are two systems to diagnose hardware. u-boot customized kernel for production Duplicated test commands Maintenance is a nightmare Hardware verification in early stage rsync Final stage: DM1: DM2: Diagnose the Diagnose after Program GPS map database Board level stuff Assembly Into NAND flash u-boot u-boot customized kernel customized kernel customized kernel customized kernel 35 0xlab – connect your device to application – http://0xlab.org/
  • 36. Future Perspectives For mobile and embedded devices, boot sequence is changing. Qi is not only a boot loader project but a new approach to comply with the diverse requirements of various consumer electric devices/products. What consumers expect Faster boot time Personalization Secure data (client security solution) What manufacturers expect Firmware protection Robust system software 36 0xlab – connect your device to application – http://0xlab.org/
  • 37. Reference U-boot – the universal boot loader http://www.denx.de/wiki/U-Boot Qi boot loader wiki http://wiki.openmoko.org/wiki/Qi GNU GRUB – multiboot boot loader http://www.gnu.org/software/grub/ Samsung S3C6410 Mobile Processor http://www.samsung.com/global/business/semiconductor/supp ort/brochures/downloads/systemlsi/s3c6410_datasheet_2008 04.pdf Openmoko wiki – http://wiki.openmoko.org/ Dash Express – http://dash.net/ 37 0xlab – connect your device to application – http://0xlab.org/
  • 38. Thanks! We appreciate the great sponsorship from AzureWave Technologies, Inc. ( http://www.azurewave.com/ ) Providing WiFi module Providing ARM development board 38 0xlab – connect your device to application – http://0xlab.org/
  • 39. 0xlab About 0xlab Our focus is to strengthen the connection http://0xlab.org between hardware device manufacturers and open source software communities and to become the integrated solution provider bringing more devices powered by open source for daily use. 0xlab is founded by a group of engineers enthusiastic in modern technologies and open source software development. 0xlab is an open organization. We appreciate anyone's participation in our projects and planning to contribute to the free software community. We support open source. We open up our development process and results as much as possible. We will always be an open organization. Everyone can join for discussion, testing and development.