[PATCH 0/4] rust: wmi: add MVP of WMI abstractions
From: Nick Dowsett via B4 Relay
Date: Sat Nov 21 2026 - 23:28:43 EST
Hi there; new to the LKML here, long time Rustacean and Linux user.
I have implemented this series to add an MVP of Rust abstractions for the
WMI subsystem with the bare-minimum implemented to support an in-tree
user, a Clevo laptop keyboard backlight driver
(`https://github.com/nick42d/linux/pull/4`).
Patches to follow for the driver. Note it has two other dependencies:
Markus Probst's LED classdev abstractions (v28) and basic DMI matching
abstractions.
This was not directly influenced by Ilya Gladyshev's previous attempt as
I was not aware of it, upon review, the key difference is that I have
used the newer buffer-based interface (no `acpi_object`), and implemented
less functionality/callbacks.
What's covered is driver probe, registration and unregistration, device
id table, and a safe implementation of `wmidev_invoke_method` that
returns an owned RAII buffer.
Signed-off-by: Nick Dowsett <nick42d@xxxxxxxxx>
---
Nick Dowsett (4):
rust: wmi: add basic WMI device abstraction
rust: wmi: add DeviceId and wmi_device_table! macro
rust: wmi: add Driver trait, Adapter and implement RegistrationOps
rust: wmi: add Buffer and Device::invoke_method()
MAINTAINERS | 1 +
rust/bindings/bindings_helper.h | 1 +
rust/kernel/lib.rs | 2 +
rust/kernel/wmi.rs | 361 ++++++++++++++++++++++++++++++++++++++++
4 files changed, 365 insertions(+)
---
base-commit: 4843f6873f7c4835e62f2c73ba0fd538e57a2f22
change-id: 20261119-rust-wmi-c6b0e0fe97a7
Best regards,
--
Nick Dowsett <nick42d@xxxxxxxxx>