Many Linux developers and users know that Bootloader boots Linux Kernel which starts Userspace.
But what is behind that?
Linux Boot process is very similar to the Big Bang which happened in our world: from singularity to the whole beautiful Universe of running Linux processes. What do you think is a black hole equivalent in the Linux? Come to hear about all of that from an engineer who worked on a new processors and boards bringup, Linux boot process modifications and did boot time optimization many times.
Embedded Fest 2019. Wei Fu. Linux on RISC-V--Fedora and Firmware in practiceEmbeddedFest
Summarize Fedora on RISC-V development including the little history, current status and some simple steps describing how to run Fedora on QEMU,FPGA board or the SiFive RV64 development board. Meanwhile, provide the status of current Specs and firmware(OpenSBI/UEFI/uboot) for RISC-V and the kernel development status.
Kernel Recipes 2013 - Easy rootfs using BuildrootAnne Nicolas
The Linux kernel is an exciting world. But if you want to get a working system, it is still essential to provide our kernel a root filesystem. The kernel developers often struggle to find a simple rootfs, adapted to their architecture, together with the tools that fits properly.
We will present how Buildroot, a tool for building embedded Linux systems, can meet the needs of kernel developers in the build of minimal rootfs for their developments.
Kernel Recipes 2013 - ARM support in the Linux kernelAnne Nicolas
Over the past two years, the support of the platforms based on ARM processor in the Linux kernel has evolved considerably. Between the use of the Device Tree, moving drivers in many features like clock management or multiplexing of pines, the platform mechanism, the changes have been numerous.
Through the experience of the speaker about the addition to the core support for ARM Marvell Armada 370/XP processors, this intervention will provide an overview of these changes in order to better understand the new organization of the code for ARM architecture in the kernel.
This talk is intended to be useful both for developers who want to add support for a new ARM processor in the kernel, but also to those wishing to understand the ARM code for porting Linux to a new card, or just the curious one.
OSDC 2014: Nat Morris - Open Network Install EnvironmentNETWAYS
ONIE defines an open source “install environment” that runs on this management subsystem utilizing facilities in a Linux/BusyBox environment. This environment allows end-users and channel partners to install the target network OS as part of data center provisioning, in the fashion that servers are provisioned.
ONIE enables switch hardware suppliers, distributors and resellers to manage their operations based on a small number of hardware SKUs. This in turn creates economies of scale in manufacturing, distribution, stocking, and RMA enabling a thriving ecosystem of both network hardware and operating system alternatives.
Embedded Fest 2019. Wei Fu. Linux on RISC-V--Fedora and Firmware in practiceEmbeddedFest
Summarize Fedora on RISC-V development including the little history, current status and some simple steps describing how to run Fedora on QEMU,FPGA board or the SiFive RV64 development board. Meanwhile, provide the status of current Specs and firmware(OpenSBI/UEFI/uboot) for RISC-V and the kernel development status.
Kernel Recipes 2013 - Easy rootfs using BuildrootAnne Nicolas
The Linux kernel is an exciting world. But if you want to get a working system, it is still essential to provide our kernel a root filesystem. The kernel developers often struggle to find a simple rootfs, adapted to their architecture, together with the tools that fits properly.
We will present how Buildroot, a tool for building embedded Linux systems, can meet the needs of kernel developers in the build of minimal rootfs for their developments.
Kernel Recipes 2013 - ARM support in the Linux kernelAnne Nicolas
Over the past two years, the support of the platforms based on ARM processor in the Linux kernel has evolved considerably. Between the use of the Device Tree, moving drivers in many features like clock management or multiplexing of pines, the platform mechanism, the changes have been numerous.
Through the experience of the speaker about the addition to the core support for ARM Marvell Armada 370/XP processors, this intervention will provide an overview of these changes in order to better understand the new organization of the code for ARM architecture in the kernel.
This talk is intended to be useful both for developers who want to add support for a new ARM processor in the kernel, but also to those wishing to understand the ARM code for porting Linux to a new card, or just the curious one.
OSDC 2014: Nat Morris - Open Network Install EnvironmentNETWAYS
ONIE defines an open source “install environment” that runs on this management subsystem utilizing facilities in a Linux/BusyBox environment. This environment allows end-users and channel partners to install the target network OS as part of data center provisioning, in the fashion that servers are provisioned.
ONIE enables switch hardware suppliers, distributors and resellers to manage their operations based on a small number of hardware SKUs. This in turn creates economies of scale in manufacturing, distribution, stocking, and RMA enabling a thriving ecosystem of both network hardware and operating system alternatives.
Kernel Recipes 2013 - Conditional bootAnne Nicolas
When booting the same Linux Kernel over various hardware setups, it could necessary to add some arguements on the command line. Usually, people solve this issue by adding a new boot entry which features the necessary arguments.
This lightning talk will be demontrating how Syslinux can add dynamically arguments to the command line or even choose a different kernel regarding some hardware properties.
Using open source software to build an industrial grade embedded linux platfo...SZ Lin
Building an embedded Linux platform is like a puzzle; placing the suitable software components in the right positions will constitute an optimal platform. However, selecting suitable components is difficult since it depends on different application scenarios. The essential components of an embedded Linux platform include the bootloader, Linux kernel, toolchain, root filesystem; it also needs the tools for image generation, upgrades, and testing. There are abundant resources in the Linux ecosystem with these components and tools; however, selecting the suitable modules and tools is still a key challenge for system designers.
Long-term Maintenance Model of Embedded Industrial Linux DistributionSZ Lin
To introduce a robust, secure and reliable platform for the industrial environments is a key challenge; moreover, the platform needs to survive for a long time (more than 10+ years). There are many good solutions aiming to meet these requirements, such as LTSI (Long Term Support Initiative) and CIP (Civil Infrastructure Platform). However, it still needs a high amount of maintenance and development costs in handling SoC/ hardware board in-house patch, non-upstream driver and keep source code consistent with different SoC and platform afterwards.
In this presentation, SZ Lin will introduce how to operate long-term maintenance model of embedded industrial Linux distribution. In addition, he will also address the building, deploying and testing architecture and workflow for producing a robust, secure and reliable platform.
Kernel Recipes 2015: Kernel packet capture technologiesAnne Nicolas
Sniffing through the ages
Capturing packets running on the wire to send them to a software doing analysis seems at first sight a simple tasks. But one has not to forget that with current network this can means capturing 30M packets per second. The objective of this talk is to show what methods and techniques have been implemented in Linux and how they have evolved over time.
The talk will cover AF_PACKET capture as well as PF_RING, dpdk and netmap. It will try to show how the various evolution of hardware and software have had an impact on the design of these technologies. Regarding software a special focus will be made on Suricata IDS which is implementing most of these capture methods.
Eric Leblond, Stamus Networks
Linux Kernel Platform Development: Challenges and InsightsGlobalLogic Ukraine
This presentation is about the main tasks which Linux kernel platform engineers take care of. The talk includes real-life cases which help understand the role of respective specialists and might be helpful to those who consider such change in their careers.
The talk was delivered by Sam Protsenko (Software Engineer, Consultant, GlobalLogic) at GlobalLogic Embedded Career Day #2 on February 10, 2018.
More about GlobalLogic Embedded Career Day #2: https://www.globallogic.com/ua/events/globallogic-kyiv-embedded-career-day-2-materials
Yocto - Embedded Linux Distribution MakerSherif Mousa
Yocto is an Embedded Linux distribution maker.
This presentation is a quick start guide for Yocto buildsystem to get familiar with the tool and how to start building your own custom Linux system for a specific hardware target.
Linux is changing the way embedded systems are put together even faster than it is influencing data centres and desktops. I gave this talk at Embedded Linux Conference Europe 2012 in Barcelona
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...Anne Nicolas
This talk will go into the latest statistics for the development of the Linux kernel.
It will describe how the many thousand developers all work together and are able to release a stable kernel every 3 months with no planning.
Greg Kroah-Hartman, Linux Foundation
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generatorAnne Nicolas
A toolchain is an essential component in a software development project. It will compile, assemble and link the code that is being developed, and thus is a very sensitive piece of any build system. Toolchains are made of different, complex pieces of software, requiring specially crafted options to build and work seamlessly.
Crosstool-NG allows to easily configure and build cross-toolchains, based on the standard FLOSS components, and targetting many of the classical architectures. After an overview of the tool and a quick sample usage session, we’ll have a look at the inside, and how easy it is to add new components. Finally, we’ll see where crosstool-NG has come up to, and the short-term and longer-term goals will be presented.
Relax and Recover (ReaR) is an open source bare metal disaster recovery solution for Linux (http://rear.sf.net). This session will introduce you to advanced Linux disaster recovery concepts and will feature a live demonstration on how to automatically recover a failed system with ReaR. Finally, this session will cover common best practice usage scenarios of ReaR and introduce you to basic setup and configuration for ReaR.
Kernel Recipes 2013 - Conditional bootAnne Nicolas
When booting the same Linux Kernel over various hardware setups, it could necessary to add some arguements on the command line. Usually, people solve this issue by adding a new boot entry which features the necessary arguments.
This lightning talk will be demontrating how Syslinux can add dynamically arguments to the command line or even choose a different kernel regarding some hardware properties.
Using open source software to build an industrial grade embedded linux platfo...SZ Lin
Building an embedded Linux platform is like a puzzle; placing the suitable software components in the right positions will constitute an optimal platform. However, selecting suitable components is difficult since it depends on different application scenarios. The essential components of an embedded Linux platform include the bootloader, Linux kernel, toolchain, root filesystem; it also needs the tools for image generation, upgrades, and testing. There are abundant resources in the Linux ecosystem with these components and tools; however, selecting the suitable modules and tools is still a key challenge for system designers.
Long-term Maintenance Model of Embedded Industrial Linux DistributionSZ Lin
To introduce a robust, secure and reliable platform for the industrial environments is a key challenge; moreover, the platform needs to survive for a long time (more than 10+ years). There are many good solutions aiming to meet these requirements, such as LTSI (Long Term Support Initiative) and CIP (Civil Infrastructure Platform). However, it still needs a high amount of maintenance and development costs in handling SoC/ hardware board in-house patch, non-upstream driver and keep source code consistent with different SoC and platform afterwards.
In this presentation, SZ Lin will introduce how to operate long-term maintenance model of embedded industrial Linux distribution. In addition, he will also address the building, deploying and testing architecture and workflow for producing a robust, secure and reliable platform.
Kernel Recipes 2015: Kernel packet capture technologiesAnne Nicolas
Sniffing through the ages
Capturing packets running on the wire to send them to a software doing analysis seems at first sight a simple tasks. But one has not to forget that with current network this can means capturing 30M packets per second. The objective of this talk is to show what methods and techniques have been implemented in Linux and how they have evolved over time.
The talk will cover AF_PACKET capture as well as PF_RING, dpdk and netmap. It will try to show how the various evolution of hardware and software have had an impact on the design of these technologies. Regarding software a special focus will be made on Suricata IDS which is implementing most of these capture methods.
Eric Leblond, Stamus Networks
Linux Kernel Platform Development: Challenges and InsightsGlobalLogic Ukraine
This presentation is about the main tasks which Linux kernel platform engineers take care of. The talk includes real-life cases which help understand the role of respective specialists and might be helpful to those who consider such change in their careers.
The talk was delivered by Sam Protsenko (Software Engineer, Consultant, GlobalLogic) at GlobalLogic Embedded Career Day #2 on February 10, 2018.
More about GlobalLogic Embedded Career Day #2: https://www.globallogic.com/ua/events/globallogic-kyiv-embedded-career-day-2-materials
Yocto - Embedded Linux Distribution MakerSherif Mousa
Yocto is an Embedded Linux distribution maker.
This presentation is a quick start guide for Yocto buildsystem to get familiar with the tool and how to start building your own custom Linux system for a specific hardware target.
Linux is changing the way embedded systems are put together even faster than it is influencing data centres and desktops. I gave this talk at Embedded Linux Conference Europe 2012 in Barcelona
Kernel Recipes 2014 - The Linux Kernel, how fast it is developed and how we s...Anne Nicolas
This talk will go into the latest statistics for the development of the Linux kernel.
It will describe how the many thousand developers all work together and are able to release a stable kernel every 3 months with no planning.
Greg Kroah-Hartman, Linux Foundation
Kernel Recipes 2013 - Crosstool-NG, a cross-toolchain generatorAnne Nicolas
A toolchain is an essential component in a software development project. It will compile, assemble and link the code that is being developed, and thus is a very sensitive piece of any build system. Toolchains are made of different, complex pieces of software, requiring specially crafted options to build and work seamlessly.
Crosstool-NG allows to easily configure and build cross-toolchains, based on the standard FLOSS components, and targetting many of the classical architectures. After an overview of the tool and a quick sample usage session, we’ll have a look at the inside, and how easy it is to add new components. Finally, we’ll see where crosstool-NG has come up to, and the short-term and longer-term goals will be presented.
Relax and Recover (ReaR) is an open source bare metal disaster recovery solution for Linux (http://rear.sf.net). This session will introduce you to advanced Linux disaster recovery concepts and will feature a live demonstration on how to automatically recover a failed system with ReaR. Finally, this session will cover common best practice usage scenarios of ReaR and introduce you to basic setup and configuration for ReaR.
This presentation provides an brief introduction about the Embedded LInux using NXP I.MX6 Processor. This gives information about embedded linux architecture & components.
A talk and practical hands-on demonstrating how The Yocto Project provides tooling that can help you with evaluating, testing, tweaking, configuring, and modifying Linux kernels for your embedded project.
Introduction to Linux Kernel by Quontra SolutionsQUONTRASOLUTIONS
Course Duration: 30-35 hours Training + Assignments + Actual Project Based Case Studies
Training Materials: All attendees will receive,
Assignment after each module, Video recording of every session
Notes and study material for examples covered.
Access to the Training Blog & Repository of Materials
Pre-requisites:
Basic Computer Skills and knowledge of IT.
Training Highlights
* Focus on Hands on training.
* 30 hours of Assignments, Live Case Studies.
* Video Recordings of sessions provided.
* One Problem Statement discussed across the whole training program.
* Resume prep, Interview Questions provided.
WEBSITE: www.QuontraSolutions.com
Contact Info: Phone +1 404-900-9988(or) Email - info@quontrasolutions.com
Embedded Fest 2019. Віталій Нужний. The Mobility Revolution: the Software tha...EmbeddedFest
- The Future of Automotive: Autonomous, Connected, Electric, and Shared
- Unique Challenges on the Automotive Electronics Road
- Evolving from Hardware to Software: Changing to Stay Ahead of the Curve for Tier-1 Businesses
- Auto 2.0: What this Means for Suppliers
Embedded Fest 2019. Игорь Опанюк. Das U-boot v2019: a look under the hoodEmbeddedFest
Das U-Boot - це універсальний бутлоадер з відкритим кодом, який фактично є стандартом де-факто в світі Embedded Linux. Його використовують провідні виробники SoC у своїх продуктах протягом останнього десятиліття. У цій презентації ми детально розглянемо процес завантаження Linux та роль U-boot у ньому, висвітлимо його архітектуру (включаючи всі оновлення до версії v2019.10) та коротко розглянемо процес апстрімінгу ваших патчів в open-source ком'юніті.
Embedded Fest 2019. Константин Белоусов. Исключения и прерывания на amd64: ка...EmbeddedFest
Доклад расскажет о том, как операционные системы (в частности, FreeBSD) управляют выполнением программ. О том, как исключительные ситуации, которые в действительности не слишком исключительные, дают ядру возможность контролировать исполнение пользовательского кода.
Embedded Fest 2019. Володимир Шанойло. High FIVE: Samsung integrity protectio...EmbeddedFest
Доповідь представить рішення з безпеки під назвою FIVE від компанії Samsung. Метою FIVE є моніторинг цілісності процесів Android та детектування зловмисних спроб модифікації оригінальних додатків та системних компонентів.
Ми поговоримо про можливі сценарії атак, спрямованих на цілісність додатків, зануримось у процес встановлення Java-додатків та розкажемо про проблеми, пов'язані з підрахунком та подальшою перевіркою цілісності нативних та Java програм. Наостанок ми покажемо, як саме FIVE захищає цілісність Android-додатків на телефонах Samsung.
Embedded Fest 2019. Dov Nimratz. Artificial Intelligence in Small Embedded Sy...EmbeddedFest
Majority of IoT solutions use data analysis at the Cloud level, collecting a huge amount of raw data from many thousands of peripherals. What if I told you that you can move from raw data collection to knowledge aggregation by implementing Artificial Intelligence into IoT systems?
During the talk, I will show the benefits of introducing AI at the earliest possible stages, applying the concept of moving from Cloud computing to Fog computing. The basic principle of constructing AIoT systems is the use of the node logic, where a node of the system has to process the provided information in a form of abstract concepts, but not in a form of raw information.
Further, the experience of one device learning and the history of its life cycle can be applied to new models, automatically programming their production cycles for the most efficient use. Actually, IoT solutions should apply AI components at each level of data transfer. Following this approach, the whole system becomes self-optimizing.
Also, during the talk, I will present related case studies and demonstrate a working stand.
Embedded Fest 2019. Антон Волошин. Connected Mobility: from Vehicle to CloudEmbeddedFest
Vehicle connection with the outside world is one of the modern trends of automotive industry development. The key element of connected vehicle is telematics control unit (TCU). From the one hand telematics unit interacts with electronic control units (ECUs) in vehicle, such as Head Unit, Board Control Module, etc. over CAN or Automotive Ethernet, from the other hand – with the cloud services via modem and CDMA\GSM\LTE networks. TCU provides a wide range of useful features: remote commands, remote diagnostics, Wi-Fi hotspot, car positioning, online traffic and hazard information besides the basic emergency call functionality. Telematics essentials and architecture, as well as features implementation in detail, will be presented. Integration and homologation testing specifics will also be discussed.
Embedded Fest 2019. Игорь Таненков и Игорь Успеньев. Action Recognition from ...EmbeddedFest
Action Recognition system for video surveillance. Description of integration computer vision module based on Deep learning and analytical models into production. Challenges and approaches. How we handle multiple video streams and reduce false positives. Also we will explain how to deal with lack of datasets for action recognition.
Embedded Fest 2019. Іван Пустовіт. From AOSP to Android powered deviceEmbeddedFest
На даний момент Android є найпопулярнішою ОС для мобільних пристроїв. Він працює на різних платформах з різною конфігурацією обладнання. Потрібно багато інженерних зусиль, щоб створити Android BSP, що повністю відповідає потребам кінцевого користувача.
Я розповім, як шматок скла та металу стає пристроєм, що працює на Android.
Я проведу вас основними фазами розробки компонентів Android, поясню різницю між Android та AOSP, і розповім про процес сертифікації Google.
How to Make a Field invisible in Odoo 17Celine George
It is possible to hide or invisible some fields in odoo. Commonly using “invisible” attribute in the field definition to invisible the fields. This slide will show how to make a field invisible in odoo 17.
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
The Roman Empire A Historical Colossus.pdfkaushalkr1407
The Roman Empire, a vast and enduring power, stands as one of history's most remarkable civilizations, leaving an indelible imprint on the world. It emerged from the Roman Republic, transitioning into an imperial powerhouse under the leadership of Augustus Caesar in 27 BCE. This transformation marked the beginning of an era defined by unprecedented territorial expansion, architectural marvels, and profound cultural influence.
The empire's roots lie in the city of Rome, founded, according to legend, by Romulus in 753 BCE. Over centuries, Rome evolved from a small settlement to a formidable republic, characterized by a complex political system with elected officials and checks on power. However, internal strife, class conflicts, and military ambitions paved the way for the end of the Republic. Julius Caesar’s dictatorship and subsequent assassination in 44 BCE created a power vacuum, leading to a civil war. Octavian, later Augustus, emerged victorious, heralding the Roman Empire’s birth.
Under Augustus, the empire experienced the Pax Romana, a 200-year period of relative peace and stability. Augustus reformed the military, established efficient administrative systems, and initiated grand construction projects. The empire's borders expanded, encompassing territories from Britain to Egypt and from Spain to the Euphrates. Roman legions, renowned for their discipline and engineering prowess, secured and maintained these vast territories, building roads, fortifications, and cities that facilitated control and integration.
The Roman Empire’s society was hierarchical, with a rigid class system. At the top were the patricians, wealthy elites who held significant political power. Below them were the plebeians, free citizens with limited political influence, and the vast numbers of slaves who formed the backbone of the economy. The family unit was central, governed by the paterfamilias, the male head who held absolute authority.
Culturally, the Romans were eclectic, absorbing and adapting elements from the civilizations they encountered, particularly the Greeks. Roman art, literature, and philosophy reflected this synthesis, creating a rich cultural tapestry. Latin, the Roman language, became the lingua franca of the Western world, influencing numerous modern languages.
Roman architecture and engineering achievements were monumental. They perfected the arch, vault, and dome, constructing enduring structures like the Colosseum, Pantheon, and aqueducts. These engineering marvels not only showcased Roman ingenuity but also served practical purposes, from public entertainment to water supply.
This is a presentation by Dada Robert in a Your Skill Boost masterclass organised by the Excellence Foundation for South Sudan (EFSS) on Saturday, the 25th and Sunday, the 26th of May 2024.
He discussed the concept of quality improvement, emphasizing its applicability to various aspects of life, including personal, project, and program improvements. He defined quality as doing the right thing at the right time in the right way to achieve the best possible results and discussed the concept of the "gap" between what we know and what we do, and how this gap represents the areas we need to improve. He explained the scientific approach to quality improvement, which involves systematic performance analysis, testing and learning, and implementing change ideas. He also highlighted the importance of client focus and a team approach to quality improvement.
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdfTechSoup
In this webinar you will learn how your organization can access TechSoup's wide variety of product discount and donation programs. From hardware to software, we'll give you a tour of the tools available to help your nonprofit with productivity, collaboration, financial management, donor tracking, security, and more.
Operation “Blue Star” is the only event in the history of Independent India where the state went into war with its own people. Even after about 40 years it is not clear if it was culmination of states anger over people of the region, a political game of power or start of dictatorial chapter in the democratic setup.
The people of Punjab felt alienated from main stream due to denial of their just demands during a long democratic struggle since independence. As it happen all over the word, it led to militant struggle with great loss of lives of military, police and civilian personnel. Killing of Indira Gandhi and massacre of innocent Sikhs in Delhi and other India cities was also associated with this movement.
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptxEduSkills OECD
Andreas Schleicher presents at the OECD webinar ‘Digital devices in schools: detrimental distraction or secret to success?’ on 27 May 2024. The presentation was based on findings from PISA 2022 results and the webinar helped launch the PISA in Focus ‘Managing screen time: How to protect and equip students against distraction’ https://www.oecd-ilibrary.org/education/managing-screen-time_7c225af4-en and the OECD Education Policy Perspective ‘Students, digital devices and success’ can be found here - https://oe.cd/il/5yV
Palestine last event orientationfvgnh .pptxRaedMohamed3
An EFL lesson about the current events in Palestine. It is intended to be for intermediate students who wish to increase their listening skills through a short lesson in power point.
Instructions for Submissions thorugh G- Classroom.pptxJheel Barad
This presentation provides a briefing on how to upload submissions and documents in Google Classroom. It was prepared as part of an orientation for new Sainik School in-service teacher trainees. As a training officer, my goal is to ensure that you are comfortable and proficient with this essential tool for managing assignments and fostering student engagement.
2. 2
Who am I?
• 10+ years background in Embedded Systems
development
• Texas Instruments, Marvell, Cisco
• OpenSource contributor and enthusiast
0295 E4A8 BEA7 3111 24B8 E490 0A02 52FB 7C55 614B
3. 3
How Linux is booting?
BIOS/UEFI/
ROM
Bootloader Linux Kernel Userspace
5. 5
Questions
• Why so many steps?
• Why bootloader is needed?
• How multiple CPU cores are started?
• When Virtual Memory appears in the system?
• How first process starts?
• What Linux Kernel is doing after starting userspace?
7. 7
What is “Linux Boot”?
• Boot is short for bootstrap
• A self-starting process to init HW and prepare SW
• Power on, wait - and universe is ready
8. 8
How Linux is booting?
BIOS/UEFI/
ROM
Bootloader Linux Kernel Userspace
Initial HW startup
Fetch and execute
bootloader
Low-level HW init
Fetch and execute
Linux Kernel
System initialization
Preparation for
UserSpace
execution
Starting processes.
System initialization
from UserSpace
22. 22
I've got the power!
• x86 - BIOS/UEFI
– RAM detection
– Hardware detection/Initialization
– Boot sequence
• BIOS: loads a 512 byte from the MBR and jumps into it
• UEFI: loads UEFI application from a partition on a GPT boot device
23. 23
I've got the power!
• ARM - ROM
– Very minimal init (varies)
– Load first-stage bootloader (SD, FLASH, UART)
27. 27
Bootloader
• Is a program that does:
– Low-level hardware initialization
– Fetch Linux Kernel image (disk, network, etc) and put it to the RAM
– Prepare system for kernel boot (CPUs, caches, MMU, interrupts)
– Jump into first kernel instruction
BIOS/UEFI/
ROM
Bootloader Linux Kernel Userspace
28. 28
Bootloaders
• GRUB (GRand Unified Bootloader)
– x86/x86-64
• LILO (Linux Loader)
• U-Boot (“the Universal Boot Loader”)
– ARM and other embedded systems
29. 29
Bootloader
• ARM64 bootloader requirements (minimal)
– Setup and initialise the RAM
– Setup the device tree
– Decompress the kernel image (if needed)
– Call the kernel image
30. 30
ARM64 Kernel starting conditions
• Following conditions must be met by bootloader:
– Quiesce all DMA capable devices
– All interrupts disabled (IRQ, FIQ, Debug, SError)
– The MMU must be off
– Same coherency domain on all CPUs
– Primary (boot) CPU jumps directly to the kernel
– Secondary CPUs a either disabled or spinning outside of Kernel
33. 33
Linux Kernel compression
• Saves disk space
• Faster to decompress in RAM than load full uncompressed image
Kernel Image Type Decompressor
vmlinux NA (raw ELF file)
Image Not compressed
Image.gz Bootloader
zImage Kernel
(self-decompressing)
34. 34
Linux Kernel compression (ARM example)
vmlinux Image
piggy_data
piggy.S
piggy.o
head.o
decompress.o
misc.o
...
vmlinux zImage
Raw kernel
executable
(ELF)
Stripped
binary
vmlinux
gzip-ped
Image
included into
piggy.S
Combined with
decompressor and
bootstrapping part
Combined
kernel image
(ELF)
Stripped
binary
vmlinux
40. 40
Linux kernel start
vmlinux
head.o
main.o
Architecture-dependent low-level initialization:
- check CPU type and capabilities
- enable MMU and virtual memory
- call start_kernel() from main.o
Initialization of all the kernel features
(a lot of them!)
Rest of the kernel binary
jmp
44. 44
Linux init/main.c
• kernel_init()
– smp_init()
– do_initcalls() /* drivers initialization */
– prepare_namespace() /* mount initrd if needed */
– free_initmem()
– try to run init process:
if (!try_to_run_init_process("/sbin/init") ||
!try_to_run_init_process("/etc/init") ||
!try_to_run_init_process("/bin/init") ||
!try_to_run_init_process("/bin/sh"))
return 0;
45. 45
Linux initrd
• Problem
– need to mount root filesystem, but
driver for it lives in root fs
– chicken and egg issue
• Solution
– bootloader loads small filesystem with
needed drivers to RAM
– Kernel mounts it as root fs
– initrd does all needed initialization
– initrd switches root to actual root
filesystem
pivot_root
bootloader
kernel initrd
/dev/sda2
Load
drivers
46. 46
Linux initrd - typical boot sequence
• bootloader loads the kernel and the initial RAM disk
• kernel converts initrd into a “normal” RAM disk
• root device (initrd) is mounted
• /sbin/init is executed
• init mounts the “real” root file system
• init switches to the “real” root fs using pivot_root system call
• init execs the /sbin/init on the new root filesystem
– important: PID 1 is preserved
• the initrd file system is removed
50. 50
Init process
• The first process that is
executed once the Linux
kernel loads
• Does system initialization
on userspace level
• Runs all other processes
(bootstraps userspace)
• Handles processes
whose parent died
(“zombie”)
Kernel
initialization
time
init (PID 0)
User Space
process 1
process 2
process 3
process n
51. 51
Typical Init system tasks
• Desktop systems
– find init configuration files/scripts
– check and mount filesystems
– run daemons (background tasks)
– setup networking
– run display manager
• Embedded systems
– depends on Embedded system purpose
– often similar to desktop, but without graphics
52. 52
Init process
• Popular init systems
– SysVinit
• survived from UNIX System V days
– systemd
• modern init system aimed to address the limitations of SysVinit
– OpenRC
• Gentoo users
– busybox
• simple, for small/embedded systems
53. 53
Run levels / Targets
SysV Runlevel systemd Target Description
0 poweroff.target Shut down the system.
1, s, single rescue.target Single user mode.
2, 4 multi-user.target User-defined/Site-specific runlevels. By default,
identical to 3.
3 multi-user.target Multi-user, non-graphical. Users can usually login via
multiple consoles or via the network.
5 graphical.target Multi-user, graphical. Usually has all the services of
runlevel 3 plus a graphical login.
6 reboot.target Reboot
emergency emergency.target Emergency shell