강의

멘토링

로드맵

Inflearn brand logo image
Hardware

/

Embedded IoT

Linux Kernel Structure and Principles: Interrupts [Author's Direct Lecture Part 1-5]

The author of "Learning the Structure and Principles of the Linux Kernel through Debugging" properly explains the core interrupt concepts of the latest Linux kernel (v6.1), most used in system software.

(5.0) 5 reviews

221 learners

  • austinkim
저자 직강
임베디드리눅스
리눅스커널
인터럽트
Operating System
Linux
linux-kernel
ARM Architecture
interrupt

What you will learn!

  • Basic Concepts and Operating Principles of Interrupts

  • Interrupt handling from a device driver's perspective

  • Arm architecture interrupt handling

  • Data structure managing interrupts

<Notice>

1. Issue 30% discount coupon for 500 people 🙏

To celebrate the 500th person signing up for the Linux Kernel course, we are issuing a 30% discount coupon. Thank you. First 100 people.

-30% discount coupon link: https://inf.run/GmqK5

2. Roadmap Guide 🎯

This lecture <Structure and Principles of the Linux Kernel: Interrupt [Author's Direct Lecture Part 1-5]> is a roadmap 'Linux kernel - basic course for system software developers' This lecture is included in .

If you want to learn the main features that make up the Linux kernel systematically , we recommend using the roadmap ( 30% discount on all lectures ).

System semiconductors, automotive fields, etc.

Linux Kernel: A Must-Know for System Software Developers


What is the most used operating system in all IT devices? It is the Linux operating system. It is used in smart phones, digital TVs, aviation entertainment systems, and servers. System semiconductor companies use Linux (Linux device drivers) to control the hardware they design. Linux is also widely used in various components (infotainment, autonomous driving, telematics) that make up electric vehicles (Automotive).

The core of the Linux operating system is the Linux kernel. Along with the Armv8-A architecture, the Linux kernel can be considered the most essential foundational knowledge required in the current system software industry.

Attention Linux System Software Developers and Linux Embedded System (BSP) Programmers!

Junior developer in the Linux system software field, including system semiconductors and electric vehicles (autonomous driving, infotainment)

Job seekers who want to work in the Linux system software development field, such as system semiconductors and electric vehicles

Applicants for graduate school in the field of Linux system software (memory, file system, operating system)

Developers from other fields who want to transition their careers into Linux system software.

However, the Linux kernel is a huge barrier for beginners in the field of system software. Beginners may have given up several times while learning the Linux kernel. The difficult Linux kernel version is evolving more and more complex as it is upgraded. After 2024, the Linux kernel version will be upgraded to v6.6 or higher , which makes the entry barrier higher.

Linux system software developers who are deployed in various fields including system semiconductors and electric vehicles know that they need to know the Linux kernel well to improve their development capabilities. However, it is difficult to get a sense of how to learn the Linux kernel and, above all, what content they need to know well in practice.

Interrupts, the core of Linux device driver development

What do you do when you first start as a Linux system software developer? It depends on the nature and mission of the project, but most of you develop Linux device drivers. When developing Linux device drivers, one of the elements that you must implement and optimize is interrupts. Interrupts are also closely related to the main functions that make up the Linux kernel. They are closely related to the latter half of interrupt techniques, dynamic timers, preemptive scheduling, and signal behavior.

So, I explain interrupts in Chapter 5 of my book, 'The Structure and Principles of the Linux Kernel'. I structured it so that readers can learn about interrupts through ftrace debugging practice in various ways.

Differentiating Points of the Lecture

This lecture consists of content that has never been covered on YouTube or any other lecture platform before ! We will debug the interrupt operation method and related data structure through Linux kernel memory dump. Those who take this lecture can download the educational program (TRACE32) and practice it themselves.

1. Provides TRACE32 simulator program (for educational purposes) and 6 Linux kernel dumps.

The TRACE32 debugger and program are widely used throughout the development of Linux system software. The TRACE32 program requires a license to run. If you take this course, you can download the educational TRACE32 simulator program from 'Inflearn lecture materials' and directly use the TRACE32 simulator program to debug memory dumps. You can also download and practice 6 kernel memory dumps that can debug various interrupt operations (interrupt handler call, preemption).

2. Explain the basic concept of interrupts in an easy and detailed manner.

When learning the Linux kernel, you analyze the kernel source. However, you encounter many obstacles in the process of analyzing the kernel source. It is difficult to determine the flow in which the function is called, and what the actual values of the data structure of the routine being analyzed are. This lecture will dismantle all these obstacles.

We analyze the Linux kernel source related to interrupts with the call stack and detailed data structures of the TRACE32 program. You can learn interrupts much more efficiently than when you learn the Linux kernel on your own. We also analyze the ftrace messages extracted from the memory dump, so you can understand the interrupt operation principle in detail.

3. Introduction to debugging methods used by Linux kernel BSP developers at global system semiconductor companies

The system semiconductor industry is on the rise these days. How does Qualcomm, a global system semiconductor company with the best technology, debug Linux kernel drivers?

This is what we will cover in this lecture. We will use the TRACE32 simulator to debug the kernel data structures related to interrupts, and load the memory dump with crash-utility to analyze the kernel's main operations.

Learn about these things

First, we will explain how interrupts are handled and explain the flow of interrupt handling from various perspectives.

This section details the entire execution flow when an interrupt is triggered in the Linux kernel and user applications from the Armv8 architecture perspective.

We analyze the Armv8 exception vector table when an interrupt is triggered in the Linux kernel. We then analyze the exception handler routines that are processed in detail.

We analyze the Armv8 exception vector table when an interrupt is triggered in a user application. We then analyze the exception handler routine being processed in detail down to the assembly instruction level.

It breaks down the interrupt processing flow into a high-level view and details the functions executed in the IRQ subsystem (which is independent of the Arm architecture).

Analyze interrupt-related data structures using the TRACE32 and Crash-utility debugging programs.

Debug the interrupt handler bcm2835_mmc_irq() function with TRACE32. Analyze the interrupt handler source code in detail, along with the call stack and related data structures.

Introduces interrupt context and provides example code to check interrupt context.

We analyze the kernel source code that enables interrupt context. We explain why kernel functions that enter from sleep should not be called in interrupt context, and we introduce exception handling code when acquiring a mutex as an example.

We will explain in detail how Preemption works after the execution of the interrupt service routine is finished. We will also debug the operation when Preemption is done in detail using the TRACE32 debugging program.

Introduces how to set up ftrace events to trace the behavior of interrupts. It explains the execution flow of interrupt handlers and the conditions of the interrupt context while analyzing ftrace messages in detail.

We will closely examine the kernel source code that prints ftrace messages tracing the behavior of interrupts.

Provides educational TRACE32 program and 6 Linux kernel memory dumps

In this lecture, we will introduce how to debug Linux kernel memory dumps , the most advanced debugging method in the Linux system software industry - debugging by Linux kernel developers at Qualcomm, a world-class system semiconductor company . You can debug the main data structures of interrupts using debugging programs such as TRACE32 and Crash utility.

You can download the TRACE32 program (simulator version) for educational purposes from the course curriculum. Students can load the kernel memory dump provided in this course with the TRACE32 program and debug it while following along.

You can directly download Crash Utility, which is operated as an open source project, and load kernel memory dumps to debug them. You can directly debug kernel data structures and call stacks by utilizing various functions supported by Crash Utility.

Based on my experience writing books and giving lectures
More in-depth and detailed than anyone else!

The author of the book 'Linux Kernel' and 'Arm Architecture (Armv8-A, Armv7-A)', which is unprecedented in the domestic system software field! He is also a working developer who knows the latest system software trends (electric vehicles, system semiconductors - system software) the best, and an educator who is most active in spreading knowledge in the system software field.

  • Author of 'Learning the Structure and Principles of the Linux Kernel through Debugging' ( 2021, Korean Academy of Sciences Outstanding Book Award )

  • Author of 'Structure and Principles of Arm Architecture for System Software Development' ( 2024, Korean Academy of Sciences Outstanding Book Award )

  • 'Programmers Dev Course: Linux System and Kernel Expert' Main Instructor

  • June 2022, Korea Computer Conference (KCC2022) - Tutorial presentation [Conquering the Linux Kernel using ftrace]

  • LG Electronics 'Linux Kernel' and 'Armv8 Architecture' In-house Instructor ( including domestic and overseas developers ) - (2020~2024)


I can confidently say that I am the educator who can explain the major functions that make up the Linux kernel better than anyone else in the country.

Things to note before taking the class

Things to note when using the TRACE32 program

  • The TRACE32 training program can only be practiced in a Windows environment.

  • The TRACE32 educational program may only be used for 'educational purposes' and may not be modified or distributed for commercial purposes.

  • If you have any questions while using the TRACE32 training program in this lecture , be sure to ask the instructor .

Practical environment and lecture materials provided

  • Operating System and Version (OS): Raspberry Pi (Raspbian), Linux Kernel v6.1

  • TRACE32 Educational Program and Installation Guide Document (Lecture)

  • 6 Linux Kernel Memory Dumps (vmcore)

Player Knowledge and Notes

  • It would be good to have a general idea of how Linux works.

  • It would be best if you first listen to the lecture 'Structure and Principles of the Linux Kernel: Debugging - Basic [Author's Lecture Part 1-2]'.

  • If you know about operating systems and computer architecture, you will be able to take the class more easily.

  • No in-depth prior knowledge of the Linux kernel is required.

Recommended for
these people

Who is this course right for?

  • Junior developer aiming to grow capabilities in the system software field, including system semiconductors and electric vehicle sectors (autonomous driving, infotainment)

  • Aspiring system software developer in system semiconductor and electric vehicle fields.

  • Undergraduate student aiming for graduate school in system software (memory, file systems, operating systems)

  • A developer from another field looking to transition their career to system software

Need to know before starting?

  • C language

  • Computer Architecture

  • Operating System

Hello
This is

5,548

Learners

156

Reviews

85

Answers

4.9

Rating

21

Courses

글로벌 저자 & 리눅스 시스템 소프트웨어 개발자 (Arm, RISC-V 아키텍처)

국내 시스템 소프트웨어 분야에서 전무후무한! 'Arm 아키텍처(Armv8-A, Armv7-A)'와 '리눅스 커널' 책을 쓴 저자(2권의 책 모두 대한민국 학술원 우수도서에 선정)이며, 국내 최초로 해외 출판사(Packt)를 통해 "Reverse Engineering Armv8-A Systems" 책(영어)을 집필한 글로벌 저자입니다. 무엇보다 최신 시스템 소프트웨어 트렌드(전기자동차, 시스템 반도체- 시스템 소프트웨어)를 가장 잘 알고 있는 현업 개발자입니다. 또한 시스템 소프트웨어 분야에서 가장 지식 전파 활동을 활발하게 하는 교육자입니다. 

  • 'Reverse Engineering Armv8-A Systems: A practical guide to Kernel, Firmware, and TrustZone analysis' 책(영어) 저자, (Packt 출판사)

  • '시스템 소프트웨어 개발을 위한 Arm 아키텍처의 구조와 원리'(2024년, 대한민국 학술원 우수도서상) 저자

  • '디버깅을 통해 배우는 리눅스 커널의 구조와 원리' (2021년, 대한민국 학술원 우수도서상) 저자

  • '프로그래머스 데브 코스: 리눅스 시스템 및 커널 전문가' 메인 강사

  • 2022년 6월, 한국컴퓨터종합학술대회 (KCC2022) - 튜토리얼 발표 [ftrace를 이용해 리눅스 커널 정복하기]

  • LG전자 '리눅스 커널' 및 'Armv8 아키텍처' 사내 강사(국내 및 해외 개발자 포함) - (2020년~현재)

국내에서 어느 누구보다 리눅스 커널과 Arm 아키텍처(Armv8-A, Armv7-A)를 잘 설명할 수 있는 교육자라고 자신있게 말씀드릴 수 있습니다.

강의문의 : austindh.kim@gmail.com

주요 로드맵 🎯

'시스템 소프트웨어 개발자를 위한 Arm - basic course'

'시스템 소프트웨어 개발자를 위한 Arm - advanced course'

시스템 소프트웨어 개발자를 위한 Linux kernel - basic course

Curriculum

All

56 lectures ∙ (6hr 13min)

Course Materials:

Lecture resources
Published: 
Last updated: 

Reviews

All

5 reviews

5.0

5 reviews

  • ionia.kim님의 프로필 이미지
    ionia.kim

    Reviews 9

    Average Rating 4.9

    5

    100% enrolled

    • dlrbcnvk님의 프로필 이미지
      dlrbcnvk

      Reviews 19

      Average Rating 4.9

      5

      60% enrolled

      • 최영주님의 프로필 이미지
        최영주

        Reviews 2

        Average Rating 5.0

        5

        31% enrolled

        • sunny75님의 프로필 이미지
          sunny75

          Reviews 95

          Average Rating 5.0

          5

          100% enrolled

          2024/07/14/일 15:27 강의 정말 잘 들었습니다. 감사합니다.

          • 김경민님의 프로필 이미지
            김경민

            Reviews 1

            Average Rating 5.0

            5

            60% enrolled

            $42.90

            austinkim's other courses

            Check out other courses by the instructor!

            Similar courses

            Explore other courses in the same field!