On Mon, 27 Jul 2026 23:24:41 -0600 Cihan Karadag wrote: > Per selftests documentation [1], every generated test binary must be > added to gitignore to prevent leaving untracked files in the kernel > tree. > > This is an easy mistake to make when adding a new test. In fact, a > search of selftests history turns up dozens of standalone follow-up > patches with titles like "add missing gitignore for <binary>", each > needed only because the original patch adding a new test > didn't also update gitignore. > > Add a SELFTESTS_GITIGNORE check that warns about gitignore coverage > whenever a patch adds a new file under tools/testing/selftests/, the > same way FILE_PATH_CHANGES warns about MAINTAINERS on any added, > moved, or deleted file.
What percentage of changes to selftests from last 2 releases will false-positive trigger this? Would be good to know, checkpatch has a tendency of generating false positives which is quite counter productive. In netdev CI at least we build the selftests and check if there are any untracked files after.

