config/drivers.conf: which drivers are compiled in

y or n per optional driver (virtio-gpu, stdvga, e1000, rtl8139, native r8169, AC'97, AHCI, NVMe), all y except the native
r8169, overridable with make DRV_X=n. Only drivers nothing else calls can be optional; the registry #ifdefs them and the
Makefile leaves their objects out. Built with every one off (links, none of their symbols present), with r8169 on, and
by default.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EVRhxi9zpdW2uDUN4FVcao
This commit is contained in:
Nexoniarz 2026-10-26 08:59:55 +01:00
commit 1334f446cc
6 changed files with 139 additions and 16 deletions

View file

@ -9,6 +9,17 @@ Drivers that live in a process rather than in the kernel are described below
---
## Which drivers are compiled in
`config/drivers.conf` lists the drivers that can be left out of a kernel, `y` (compiled in and offered every device it can
drive) or `n` (not linked at all), all `y` unless a line says otherwise — the one exception is the native `r8169`, `n`
because Linux's runs in its place under LDLS. Override one for a build with `make DRV_E1000=n DRV_NVME=n`. A changed
choice rebuilds only `registry.o` and the link. The list is short on purpose: a driver is optional only if nothing else in
the kernel calls it (display: `vga_pci`, `virtio_gpu`; network: `e1000`, `rtl8139`, `r8169`; storage: `ahci`, `nvme`;
audio: `ac97`). `vga_fb`, the USB stack and the legacy PS/2, IDE and UART devices are always there, because the console, the
keyboard and the root disk can depend on them. A kernel with every optional driver off builds and links; whether such a
kernel is useful on any particular machine is the person who turned them off to say.
## What stays in the kernel, and what may leave
"Hybrid" is used to mean everything from "a monolith with a nice device model" to