A recent discussion on the Linux kernel mailing list considers whether machine learning could assist kernel subsystems. Viacheslav Dubeyko, an IBM engineer, proposed creating a generic infrastructure to enable kernel subsystems to interact with machine learning models operating entirely in user space.
The proposal centers on a lightweight “ML proxy” within the kernel. This proxy would expose structured data from kernel subsystems, such as internal state or performance metrics, and receive recommendations from a user-space ML model. Training, model execution, and experimentation would remain outside the kernel, ensuring the kernel retains full control over the application of recommendations.
And since ML immediately brings to mind AI, I want to make the following point clear. The idea does not involve embedding AI or ML code inside the kernel. Instead, kernel subsystems would expose data to the user space, where machine-learning models normally run, and receive optional recommendations in return.
The kernel would remain fully deterministic and in control, deciding whether to apply, test, or ignore suggestions, with all training and inference performed outside kernel space. Existing mechanisms such as sysfs, character devices, FUSE, or eBPF are identified as possible transport and execution layers.
Dubeyko also proposes a feedback loop in which the kernel evaluates the applied recommendations and reports efficiency metrics to the user space. This information could be used to refine or retrain models without affecting kernel performance or determinism. The proposal emphasizes that human-written kernel logic remains the baseline, with ML serving only as an advisory layer.
An early proof-of-concept implementation of the proposed ML library has been published, and an RFC patch series has been posted to the Linux kernel mailing list for discussion. The patches are explicitly marked as experimental and are intended to gather feedback rather than seek inclusion.
The patches have not been merged into the mainline kernel, as the work remains exploratory. Whether ML-assisted kernel subsystems will progress beyond experimentation remains an open question.
For more information, see the proposal itself on the kernel’s mailing list.
