// ITS FOSS — LINUX & OPEN SOURCE
Linux Creator Linus Torvalds Just Used AI to Fix a Kernel Bug
Linus Torvalds just used AI to help fix a Linux kernel bug.
Let me tell you that this is a rare event. Not because Torvalds is using AI. Last Christmas holidays, Torvalds used AI for the first time for a personal, hobby project. He was averted to AI at first but made his peace with it, even for AI-assisted code contributions in the kernel project.
The event we are talking about is rare because Torvalds doesn't code on Linux kernel anymore. He is in the maintainer mode. He just reviews code and merges pull requests from various contributors to the kernel code.
So this is a rare occasion in recent time when he made a kernel patch himself. And he did that with the assistance of AI.
Don't scoff at "one-line" code change. Speak to any software developer and they will telly you that often the bugs are easy, few line code changes. It's the process of finding the root cause that takes time, effort, and skills.
The bug Torvalds dealt with was in the Intel Xe graphics driver for Battlemage G21 cards. It caused GDM, the display manager, to restart endlessly.
Tracking it down with AI required 24 debug patches (did he just use "printfs?) and 18 kernel boots. Ultimately, the culprit turned out to be a single line where round_up() should have been round_down().
The AI "did the grunt work" for Torvalds by adding debug instrumentation, running analysis, and even writing the final commit message. I can feel the commit message part, it's a boring but necessary task.
But this debugging session was not all smooth sailing. Torvalds didn't just add "don't make mistakes" to his prompts. On the contrary, the AI told Linus multiple times that the problem was "impossible and unsolvable." Torvalds refused.
This is what many people in the software industry understand. AI is just a tool and it is essentially useful when there is a capable human driving the process.