Tech
Kconfirm Is On A Quest To Clean Up The Linux Kernel’s Configuration System
New tooling being worked on for possible mainline Linux kernel inclusion is Kconfirm as a new tool for detecting misusage and efforts stemming from Kconfig, the configuration system for kernel builds.
Initially presented on the Linux kernel mailing list in April and now sent out this weekend as a second set of patches requesting comments, the Kconfirm tool detects dead code, constant conditions, and invalid ranges among other issues with Linux kernel Kconfig usage. Plus there are extras like checking for dead web links in the help text messages.
This tool has already proven useful in detecting dead code in Kconfig files throughout the kernel source tree. Kconfirm also detected hundreds (700+) duplicate dependencies in Linux 7.0.
Kconfirm strives for zero false-positives and as of Linux 7.1-rc2 is raising 489 alarms confirming from all the default set of checks or 1,789 alarms if enabling the additional checks.
This Kconfirm tool for help cleaning up the Linux kernel’s Kconfig system is written in the Rust programming language. Those wanting to learn more about Kconfirm can do so via the RFC v2 patch series posted today to the Linux kernel mailing list.