Re: [PATCH v25 2/4] rust: leds: add Mode trait
From: sashiko-bot@kernel.org
Date: 2026-09-13 16:21:58
Also in:
linux-pci
Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider: - [Low] The `core` import uses horizontal formatting instead of the required vertical format. - [Low] The commit message description is not capitalized, violating the LED subsystem guidelines. -- commit fc494e48581e40fa3f62db639a08746b74e239f2 Author: Markus Probst [off-list ref] rust: leds: add Mode trait This commit adds the Mode trait to allow for other types of led class devices in LedOps.
rust: leds: add Mode trait
[Severity: Low] This isn't a bug, but the commit message description is not capitalized, violating the LED subsystem guidelines. The global review guidelines for the LED subsystem mandate that the description following the commit message prefix must be capitalized. Should the description start with a capital letter, as in "rust: leds: Add Mode trait"? [ ... ]
quoted hunk ↗ jump to hunk
diff --git a/rust/kernel/led.rs b/rust/kernel/led.rs index deda8cc548a8c..7cd8f0504649a 100644 --- a/rust/kernel/led.rs +++ b/rust/kernel/led.rs@@ -4,11 +4,7 @@ //! //! C header: [`include/linux/leds.h`](srctree/include/linux/leds.h) -use core::{ - marker::PhantomData, - mem::transmute, - ptr::NonNull, // -}; +use core::{marker::PhantomData, mem::transmute, ops::Deref, ptr::NonNull};
[Severity: Low] This isn't a bug, but does this import for the core crate use horizontal formatting instead of the required vertical format? The kernel Rust coding guidelines explicitly require using the vertical import style for non-vendored crates. The commit replaces a multi-line vertical import block with a single-line horizontal block. Should this be changed back to the vertical format? -- Sashiko AI review · https://sashiko.dev/#/patchset/20260913-rust_leds-v25-0-1a10371d78c3@posteo.de?part=2