| |
| |
Preface | |
| |
| |
| |
An Introduction to the Linux Kernel | |
| |
| |
The Role of the Driver Writer | |
| |
| |
Splitting the Kernel | |
| |
| |
Classes of Devices and Modules | |
| |
| |
Security Issues | |
| |
| |
Version Numbering | |
| |
| |
License Terms | |
| |
| |
Overview of the Book | |
| |
| |
| |
Building and Running Modules | |
| |
| |
Modules Versus Applications | |
| |
| |
Compiling and Loading | |
| |
| |
The Kernel Symbol Table | |
| |
| |
Initialization and Shutdown | |
| |
| |
Using Resources | |
| |
| |
Automatic and Manual Configuration | |
| |
| |
Doing It in User Space | |
| |
| |
Quick Reference | |
| |
| |
| |
Char Drivers | |
| |
| |
The Design of scull | |
| |
| |
Major and Minor Numbers | |
| |
| |
File Operations | |
| |
| |
The file Structure | |
| |
| |
Open and Close | |
| |
| |
Scull's Memory Usage | |
| |
| |
Read and Write | |
| |
| |
Playing with the New Devices | |
| |
| |
Quick Reference | |
| |
| |
| |
Debugging Techniques | |
| |
| |
Debugging by Printing | |
| |
| |
Debugging by Querying | |
| |
| |
Debugging by Watching | |
| |
| |
Debugging System Faults | |
| |
| |
Using a Debugger | |
| |
| |
| |
Enhanced Char Driver Operations | |
| |
| |
ioctl | |
| |
| |
Blocking I/O | |
| |
| |
Select | |
| |
| |
Asynchronous Notification | |
| |
| |
Seeking a Device | |
| |
| |
Access Control on a Device File | |
| |
| |
Quick Reference | |
| |
| |
| |
Flow of Time | |
| |
| |
Time Intervals in the Kernel | |
| |
| |
Knowing the Current Time | |
| |
| |
Delaying Execution | |
| |
| |
Task Queues | |
| |
| |
Kernel Timers | |
| |
| |
Quick Reference | |
| |
| |
| |
Getting Hold of Memory | |
| |
| |
The Real Story of kmalloc | |
| |
| |
get_free_page and Friends | |
| |
| |
vmalloc and Friends | |
| |
| |
Playing Dirty | |
| |
| |
Quick Reference | |
| |
| |
| |
Hardware Management | |
| |
| |
Using I/O Ports | |
| |
| |
Using the Parallel Port | |
| |
| |
Accessing Memory on Device Boards | |
| |
| |
Accessing the Text-Mode Video Buffer | |
| |
| |
Quick Reference | |
| |
| |
| |
Interrupt Handling | |
| |
| |
Preparing the Parallel Port | |
| |
| |
Installing an Interrupt Handler | |
| |
| |
Implementing a Handler | |
| |
| |
Bottom Halves | |
| |
| |
Interrupt Sharing | |
| |
| |
Interrupt-Driven I/O | |
| |
| |
Race Conditions | |
| |
| |
Version Dependencies of IRQ Handling | |
| |
| |
Quick Reference | |
| |
| |
| |
Judicious Use of Data Types | |
| |
| |
Use of Standard C Types | |
| |
| |
Assigning an Explicit Size to Data Items | |
| |
| |
Interface-Specific Types | |
| |
| |
Other Portability Issues | |
| |
| |
Quick Reference | |
| |
| |
| |
Kerneld and Advanced Modularization | |
| |
| |
Loading Modules on Demand | |
| |
| |
Version Control in Modules | |
| |
| |
Persistent Storage Across Unload/Load | |
| |
| |
Quick Reference | |
| |
| |
| |
Loading Block Drivers | |
| |
| |
Registering the Driver | |
| |
| |
The Header File blk.h | |
| |
| |
Handling Requests | |
| |
| |
How Mounting Works | |
| |
| |
The ioctl Method | |
| |
| |
Removable Devices | |
| |
| |
Partitionable Devices | |
| |
| |
Interrupt-Driven Block Drivers | |
| |
| |
Quick Reference | |
| |
| |
| |
Mmap and DMA | |
| |
| |
Memory Management in Linux | |
| |
| |
The mmap Device Operation | |
| |
| |
Direct Memory Access | |
| |
| |
Quick Reference | |
| |
| |
| |
Network Drivers | |
| |
| |
How snull Is Designed | |
| |
| |
Connecting to the Kernel | |
| |
| |
The device Structure in Detail | |
| |
| |
Opening and Closing | |
| |
| |
Packet Transmission | |
| |
| |
Packet Reception | |
| |
| |
Interrupt-Driven Operation | |
| |
| |
The Socket Buffers | |
| |
| |
Address Resolution | |
| |
| |
Load-Time Configuration | |
| |
| |
Run-Time Configuration | |
| |
| |
Custom ioctl Commands | |
| |
| |
Statistical Information | |
| |
| |
Multicasting | |
| |
| |
Quick Reference | |
| |
| |
| |
Overview of Peripheral Buses | |
| |
| |
The PCI Interface | |
| |
| |
A Look Back: ISA | |
| |
| |
Other PC Buses | |
| |
| |
Sbus | |
| |
| |
Quick Reference | |
| |
| |
| |
Physical Layout of the Kernel Source | |
| |
| |
Booting the Kernel | |
| |
| |
Before Booting | |
| |
| |
The Init Process | |
| |
| |
The kernel Directory | |
| |
| |
The mm Directory | |
| |
| |
The fs Directory | |
| |
| |
Networking | |
| |
| |
IPC and lib Functions | |
| |
| |
Drivers | |
| |
| |
Architecture Dependencies | |
| |
| |
| |
Recent Developments | |
| |
| |
Modularization | |
| |
| |
File Operations | |
| |
| |
Accessing User Space | |
| |
| |
Task Queues | |
| |
| |
Interrupt Management | |
| |
| |
Bit Operations | |
| |
| |
Conversion Functions | |
| |
| |
vremap | |
| |
| |
Virtual Memory | |
| |
| |
Handling Kernel-Space Faults | |
| |
| |
Other Changes | |
| |
| |
Index | |