Professional Linux Kernel Architecture

Book description

Find an introduction to the architecture, concepts and algorithms of the Linux kernel in Professional Linux Kernel Architecture, a guide to the kernel sources and large number of connections among subsystems. Find an introduction to the relevant structures and functions exported by the kernel to userland, understand the theoretical and conceptual aspects of the Linux kernel and Unix derivatives, and gain a deeper understanding of the kernel. Learn how to reduce the vast amount of information contained in the kernel sources and obtain the skills necessary to understand the kernel sources.

Table of contents

  1. Cover
  2. Title Page
  3. Copyright
  4. About the Author
  5. Credits
  6. Acknowledgments
  7. Introduction
    1. What This Book Covers
  8. Chapter 1: Introduction and Overview
    1. 1.1 Tasks of the Kernel
    2. 1.2 Implementation Strategies
    3. 1.3 Elements of the Kernel
    4. 1.4 Why the Kernel Is Special
    5. 1.5 Some Notes on Presentation
    6. 1.6 Summary
  9. Chapter 2: Process Management and Scheduling
    1. 2.1 Process Priorities
    2. 2.2 Process Life Cycle
    3. 2.3 Process Representation
    4. 2.4 Process Management System Calls
    5. 2.5 Implementation of the Scheduler
    6. 2.6 The Completely Fair Scheduling Class
    7. 2.7 The Real-Time Scheduling Class
    8. 2.8 Scheduler Enhancements
    9. 2.9 Summary
  10. Chapter 3: Memory Management
    1. 3.1 Overview
    2. 3.2 Organization in the (N)UMA Model
    3. 3.3 Page Tables
    4. 3.4 Initialization of Memory Management
    5. 3.5 Management of Physical Memory
    6. 3.6 The Slab Allocator
    7. 3.7 Processor Cache and TLB Control
    8. 3.8 Summary
  11. Chapter 4: Virtual Process Memory
    1. 4.1 Introduction
    2. 4.2 Virtual Process Address Space
    3. 4.3 Principle of Memory Mappings
    4. 4.4 Data Structures
    5. 4.5 Operations on Regions
    6. 4.6 Address Spaces
    7. 4.7 Memory Mappings
    8. 4.8 Reverse Mapping
    9. 4.9 Managing the Heap
    10. 4.10 Handling of Page Faults
    11. 4.11 Correction of Userspace Page Faults
    12. 4.12 Kernel Page Faults
    13. 4.13 Copying Data between Kernel and Userspace
    14. 4.14 Summary
  12. Chapter 5: Locking and Interprocess Communication
    1. 5.1 Control Mechanisms
    2. 5.2 Kernel Locking Mechanisms
    3. 5.3 System V Interprocess Communication
    4. 5.4 Other IPC Mechanisms
    5. 5.5 Summary
  13. Chapter 6: Device Drivers
    1. 6.1 I/O Architecture
    2. 6.2 Access to Devices
    3. 6.3 Association with the Filesystem
    4. 6.4 Character Device Operations
    5. 6.5 Block Device Operations
    6. 6.6 Resource Reservation
    7. 6.7 Bus Systems
    8. 6.8 Summary
  14. Chapter 7: Modules
    1. 7.1 Overview
    2. 7.2 Using Modules
    3. 7.3 Inserting and Deleting Modules
    4. 7.4 Automation and Hotplugging
    5. 7.5 Version Control
    6. 7.6 Summary
  15. Chapter 8: The Virtual Filesystem
    1. 8.1 Filesystem Types
    2. 8.2 The Common File Model
    3. 8.3 Structure of the VFS
    4. 8.4 Working with VFS Objects
    5. 8.5 Standard Functions
    6. 8.6 Summary
  16. Chapter 9: The Extended Filesystem Family
    1. 9.1 Introduction
    2. 9.2 Second Extended Filesystem
    3. 9.3 Third Extended Filesystem
    4. 9.4 Summary
  17. Chapter 10: Filesystems without Persistent Storage
    1. 10.1 The proc Filesystem
    2. 10.2 Simple Filesystems
    3. 10.3 Sysfs
    4. 10.4 Summary
  18. Chapter 11: Extended Attributes and Access Control Lists
    1. 11.1 Extended Attributes
    2. 11.2 Access Control Lists
    3. 11.3 Summary
  19. Chapter 12: Networks
    1. 12.1 Linked Computers
    2. 12.2 ISO/OSI and TCP/IP Reference Model
    3. 12.3 Communication via Sockets
    4. 12.4 The Layer Model of Network Implementation
    5. 12.5 Networking Namespaces
    6. 12.6 Socket Buffers
    7. 12.7 Network Access Layer
    8. 12.8 Network Layer
    9. 12.9 Transport Layer
    10. 12.10 Application Layer
    11. 12.11 Networking from within the Kernel
    12. 12.12 Summary
  20. Chapter 13: System Calls
    1. 13.1 Basics of System Programming
    2. 13.2 Available System Calls
    3. 13.3 Implementation of System Calls
    4. 13.4 Summary
  21. Chapter 14: Kernel Activities
    1. 14.1 Interrupts
    2. 14.2 Software Interrupts
    3. 14.3 Tasklets
    4. 14.4 Wait Queues and Completions
    5. 14.5 Summary
  22. Chapter 15: Time Management
    1. 15.1 Overview
    2. 15.2 Implementation of Low-Resolution Timers
    3. 15.3 Generic Time Subsystem
    4. 15.4 High-Resolution Timers
    5. 15.5 Dynamic Ticks
    6. 15.6 Broadcast Mode
    7. 15.7 Implementing Timer-Related System Calls
    8. 15.8 Managing Process Times
    9. 15.9 Summary
  23. Chapter 16: Page and Buffer Cache
    1. 16.1 Structure of the Page Cache
    2. 16.2 Structure of the Buffer Cache
    3. 16.3 Address Spaces
    4. 16.4 Implementation of the Page Cache
    5. 16.5 Implementation of the Buffer Cache
    6. 16.6 Summary
  24. Chapter 17: Data Synchronization
    1. 17.1 Overview
    2. 17.2 The pdflush Mechanism
    3. 17.3 Starting a New Thread
    4. 17.4 Thread Initialization
    5. 17.5 Performing Actual Work
    6. 17.6 Periodic Flushing
    7. 17.7 Associated Data Structures
    8. 17.8 Central Control
    9. 17.9 Superblock Synchronization
    10. 17.10 Inode Synchronization
    11. 17.11 Congestion
    12. 17.12 Forced Writeback
    13. 17.13 Laptop Mode
    14. 17.14 System Calls for Synchronization Control
    15. 17.15 Full Synchronization
    16. 17.16 Summary
  25. Chapter 18: Page Reclaim and Swapping
    1. 18.1 Overview
    2. 18.2 Page Reclaim and Swapping in the Linux Kernel
    3. 18.3 Managing Swap Areas
    4. 18.4 The Swap Cache
    5. 18.5 Writing Data Back
    6. 18.6 Page Reclaim
    7. 18.7 The Swap Token
    8. 18.8 Handling Swap-Page Faults
    9. 18.9 Initiating Memory Reclaim
    10. 18.10 Shrinking Other Caches
    11. 18.11 Summary
  26. Chapter 19: Auditing
    1. 19.1 Overview
    2. 19.2 Audit Rules
    3. 19.3 Implementation
    4. 19.4 Summary
  27. Appendix A: Architecture Specifics
    1. A.1 Overview
    2. A.2 Data Types
    3. A.3 Alignment
    4. A.4 Memory Pages
    5. A.5 System Calls
    6. A.6 String Processing
    7. A.7 Thread Representation
    8. A.8 Bit Operations and Endianness
    9. A.9 Page Tables
    10. A.10 Miscellaneous
    11. A.11 Summary
  28. Appendix B: Working with the Source Code
    1. B.1 Organization of the Kernel Sources
    2. B.2 Configuration with Kconfig
    3. B.3 Compiling the Kernel with Kbuild
    4. B.4 Useful Tools
    5. B.5 Debugging and Analyzing the Kernel
    6. B.6 User-Mode Linux
    7. B.7 Summary
  29. Appendix C: Notes on C
    1. C.1 How the GNU C Compiler Works
    2. C.2 Standard Data Structures and Techniques of the Kernel
    3. C.3 Summary
  30. Appendix D: System Startup
    1. D.1 Architecture-Specific Setup on IA-32 Systems
    2. D.2 High-Level Initialization
    3. D.3 Summary
  31. Appendix E: The ELF Binary Format
    1. E.1 Layout and Structure
    2. E.2 Data Structures in the Kernel
    3. E.3 Summary
  32. Appendix F: The Kernel Development Process
    1. F.1 Introduction
    2. F.2 Kernel Trees and the Structure of Development
    3. F.3 The Structure of Patches
    4. F.4 Linux and Academia
    5. F.5 Summary
  33. References
  34. Advertisement

Product information

  • Title: Professional Linux Kernel Architecture
  • Author(s): Wolfgang Mauerer
  • Release date: October 2008
  • Publisher(s): Wrox
  • ISBN: 9780470343432