Understanding the LINUX Kernel 2nd Ed.

From I/O Ports to Process Management

Daniel P. Bovet, Marco Cesati

Publisher: O'Reilly, 2003, 758 pages

ISBN: 0-596-00213-0

Keywords: Operating Systems

Last modified: May 10, 2021, 3:34 p.m.

In order to thoroughly understand what makes GNU/Linux tick and why it works so well on a wide variety of systems, you need to delve deep into the heart of operating system — that is, into the Linux kernel itself. The kernel handles all the requests or completed I/O operations and determines which programs will share its processing time, and in what order. Responsible for the sophisticated management of the whole system, the Linux kernel is the force behind the legendary Linux efficiency.

The new edition of Understanding the Linux Kernel takes you on a guided tour of the most significant data structures, algorithms, and programming tricks used in the kernel. Important Intel-specific features are discussed. But the book covers more than just the functioning of the code; it explains the theoretical underpinnings of why Linux does things the way it does.

This second edition of the book covers Version 2.4, focusing on the following topics:

  • Networking
  • Memory management, including file buffering, process swapping, and Direct memory Access (DMA)
  • The Virtual Filesystem layer and the Second and Third Extended Filesystems
  • Process creation and scheduling
  • Signals, interrupts, and the essential interfaces to device drivers
  • Timing
  • Synchronization within the kernel
  • Interprocess Communication (IPC)
  • Program execution

Understanding the Linux Kernel will acquaint you with all the inner workings of Linux, but it's not just an academic exercise. You'll learn what conditions bring out Linux's best performance, and you'll see how it meets the challenge of providing good system response during process scheduling, file access, and memory management in a wide variety of environments. Knowledge is power and this book will help you make the most of your Linux system.

  1. Introduction
    • Linux Versus Other Unix-Like Kernels
    • Hardware Dependency
    • Linux Versions
    • Basic Operating System Concepts
    • An Overview of the Unix Filesystem
    • An Overview of Unix Kernels
  2. Memory Addressing
    • Memory Addresses
    • Segmentation in Hardware
    • Segmentation in Linux
    • Paging in Hardware
    • Paging in Linux
  3. Processes
    • Processes, Lightweight Processes, and Threads
    • Process Descriptor
    • Process Switch
    • Creating Processes
    • Destroying Processes
  4. Interrupts and Exceptions
    • The Role of Interrupt Signals
    • Interrupts and Exceptions
    • Nested Execution of Exception and Interrupt Handlers
    • Initializing the Interrupt Descriptor Table
    • Exception Handling
    • Interrupt Handling
    • Softirqs, Tasklets, and Bottom Halves
    • Returning from Interrupts and Exceptions
  5. Kernel Synchronization
    • Kernel Control Paths
    • When Synchronization Is Not Necessary
    • Synchronization Primitives
    • Synchronizing Accesses to Kernel Data Structures
    • Examples of Race Condition Prevention
  6. Timing Measurements
    • Hardware Clocks
    • The Linux Timekeeping Architecture
    • CPU's Time Sharing
    • Updating the Time and Date
    • Updating System Statistics
    • Software Timers
    • System Calls Related to Timing Measurements
  7. Memory Management
    • Page Frame Management
    • Memory Area Management
    • Noncontiguous Memory Area Management
  8. Process Address Space
    • The Process's Address Space
    • The Memory Descriptor
    • Memory Regions
    • Page Fault Exception Handler
    • Creating and Deleting a Process Address Space
    • Managing the Heap
  9. System Calls
    • POSIX APIs and System Calls
    • System Call Handler and Service Routines
    • Kernel Wrapper Routines
  10. Signals
    • The Role of Signals
    • Generating a Signal
    • Delivering a Signal
    • System Calls Related to Signal Handling
  11. Process Scheduling
    • Scheduling Policy
    • The Scheduling Algorithm
    • System Calls Related to Scheduling
  12. The Virtual Filesystem
    • The Role of the Virtual Filesystem (VFS)
    • VFS Data Structures
    • Filesystem Types
    • Filesystem Mounting
    • Pathname Lookup
    • Implementations of VFS System Calls
    • File Locking
  13. Managing I/O Devices
    • I/O Architecture
    • Device Files
    • Device Drivers
    • Block Device Drivers
    • Character Device Drivers
  14. Disk Caches
    • The Page Cache
    • The Buffer Cache
  15. Accessing Files
    • Reading and Writing a File
    • Memory Mapping
    • Direct I/O Transfers
  16. Swapping: Methods for Freeing Memory
    • What Is Swapping?
    • Swap Area
    • The Swap Cache
    • Transferring Swap Pages
    • Swapping Out Pages
    • Swapping in Pages
    • Reclaiming Page Frame
  17. The Ext2 and Ext3 Filesystems
    • General Characteristics of Ext2
    • Ext2 Disk Data Structures
    • Ext2 Memory Data Structures
    • Creating the Ext2 Filesystem
    • Ext2 Methods
    • Managing Ext2 Disk Space
    • The Ext3 Filesystem
  18. Networking
    • Main Networking Data Structures
    • System Calls Related to Networking
    • Sending Packets to the Network Card
    • Receiving Packets from the Network Card
  19. Process Communication
    • Pipes
    • FIFOs
    • System V IPC
  20. Program Execution
    • Executable Files
    • Executable Formats
    • Execution Domains
    • The exec Functions
  1. System Startup
  2. Modules
  3. Source Code Structure


Understanding the LINUX Kernel

Reviewed by Roland Buresund

OK ***** (5 out of 10)

Last modified: May 21, 2007, 2:47 a.m.

A very good book. Introduces the Linux 2.4 kernel well and could probably be used as a teaching tool in CS classes as well. Of course, you need to be hard-core to read stuff like this…


There are currently no comments

New Comment


required (not published)