
Ship Out-of-Tree Kernel Modules With DKMS
Package an out-of-tree kernel module with DKMS: write dkms.conf, add, build and install, rebuild on kernel upgrades automatically and sign for Secure Boot.
Tag
71 posts

Package an out-of-tree kernel module with DKMS: write dkms.conf, add, build and install, rebuild on kernel upgrades automatically and sign for Secure Boot.

Compare a module's vermagic string with uname -r using modinfo to see why insmod says Invalid module format, and what the version magic and CRC checks protect.

Pass parameters to a Linux kernel module with module_param: types, permissions, MODULE_PARM_DESC, insmod and modprobe.d usage, and /sys/module values.

insmod loads one .ko by path, and modprobe loads by name with dependencies from modules.dep and modprobe.d. See how each works, what fails and which to use.

Write, build and load your first Linux kernel module in C: the init and exit functions, MODULE_LICENSE, a Makefile and insmod, with the exact dmesg output.

Browse Linux source online with Elixir and index a local tree with cscope and make cscope, so you can find a symbol's definition and every caller in seconds.

A guided map of the Linux 6.12 kernel source tree, from arch/ to mm/ and net/, with when each top-level directory is worth opening and when it is not.

Monolithic, microkernel and hybrid kernels differ in how much runs at top privilege; this compares Linux, MINIX 3, seL4 and Windows NT with a decision table.

User space and kernel space are two privilege levels and two address ranges; code in one reaches the other only through system calls, faults and interrupts.

A kernel schedules processes, manages memory, drives devices and exposes system calls, and everything else on a Linux machine sits on those four jobs.

Decode a real x86-64 NULL pointer oops from a module, one line at a time: fault address, error code, RIP, registers, call trace and taint flags.

Send kernel messages as UDP packets to another host with netconsole, set it up at boot or run time, and receive crash logs that never reach disk.