News: 0001457633

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

Linus Torvalds Injects Tabs To Thwart Kconfig Parsers Not Correctly Handling Them

([Linux Kernel] 37 Minutes Ago Linux Kconfig)


Within yesterday's [1]Linux 6.9-rc4 release is an interesting little nugget by Linus Torvalds to battle Kconfig parsers that can't correctly handle tabs but rather just assume spaces for whitespace for this kernel configuration format.

Due to [2]a patch having been queued last week to replace a tab with a space character in the kernel tracing Kconfig file, Linus Torvalds decided to take matters into his own hand for Kconfig parsers that can't deal with tabs... Torvalds authored a patch to intentionally add some tabs of his own into Kconfig for throwing off any out-of-tree/third-party parsers that can't correctly handle them.

Torvalds added these intentional hidden tabs to the common Kconfig file for handling page sizes for the kernel. Thus sure to cause dramatic and noticeable breakage for any parsers not having tabs correctly. Torvalds wrote in [3]the patch :

"Commit d96c36004e31 ("tracing: Fix FTRACE_RECORD_RECURSION_SIZE Kconfig entry") removed a hidden tab because it apparently showed breakage in some third-party kernel config parsing tool.

It wasn't clear what tool it was, but let's make sure it gets fixed. Because if you can't parse tabs as whitespace, you should not be parsing the kernel Kconfig files.

In fact, let's make such breakage more obvious than some esoteric ftrace record size option. If you can't parse tabs, you can't have page sizes.

Yes, tab-vs-space confusion is sadly a traditional Unix thing, and 'make' is famous for being broken in this regard. But no, that does not mean that it's ok.

I'd add more random tabs to our Kconfig files, but I don't want to make things uglier than necessary. But it *might* be necessary if it turns out we see more of this kind of silly tooling."

Linus Torvalds can still get things done effectively for the Linux kernel without his once colorful language he was known for on the kernel mailing list.



[1] https://www.phoronix.com/news/Linux-6.9-rc4

[2] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/id=d96c36004e31

[3] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?utm_source=anzwix&id=d5cf50dafc9dd5faa1e61e7021e3496ddf7fd61e



phoronix

The less you know about computers the more you want Microsoft!
-- Microsoft ad campaign, circa 1996

(Proof that Microsoft's advertising _isn't_ dishonest!)