Operating Systems · Cluster
Kernel Engineering
Modules, debugging, and portability.
- 01 How a Loadable Module Resolves Symbols Against the Kernel A module is an unlinked ELF object, not a program. How the loader binds its undefined names, why exported symbols carry version CRCs, and what vermagic refuses to load.
- 02 Kconfig Options and the Shape of the Compiled Kernel How a configuration symbol turns into preprocessor structure, why IS_ENABLED differs from #ifdef, and how a build-time option silently changes struct layout and the module ABI.
- 03 Kernel Logging: The Ring Buffer Behind printk Why kernel messages are written to a fixed circular buffer instead of a file, how records are framed, and what happens when the console cannot keep up with the producer.
- 04 Stack Unwinding in the Kernel Without Frame Pointers Walking a call stack whose compiler optimised away the frame pointer, the unwind tables that replace it, and why unwinding from an interrupt frame needs a different entry point.
- 05 Dynamic Tracing by Rewriting Instructions: ftrace and kprobes How a function is instrumented without recompiling it, what a five-byte jump patch implies for concurrent execution, and why probing an instruction needs a copy of it somewhere else.
- 06 Lockdep: Proving Lock Order Without Running the Deadlock How the kernel records which lock classes are taken while holding which others, why a cycle in that graph is a proof, and what the validator cannot see through.
- 07 Decoding a Kernel Fault Report What the register dump, the faulting address, and the call trace each establish, how to tell a null dereference from a use-after-free, and why a tainted kernel changes the reading.
- 08 Word Size, Endianness, and Structure Layout Across Architectures Why the same C source produces different bytes on a 32-bit and a 64-bit build, how endianness changes on-disk and on-wire structures, and where alignment padding hides.
- 09 kexec and Crash Dumps: Capturing a Dead Kernel Booting a second kernel from the first, reserving memory that survives the handover, and why the dump kernel must not touch the crashed one's state.
- 10 Live Patching a Running Kernel: The Consistency Problem Redirecting a function to a replacement is easy; deciding when no thread is still inside the old one is not. How quiescence is established and why stacks must be checked.