]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
rust: pci: use `kernel::fmt`
authorTamir Duberstein <tamird@gmail.com>
Sat, 18 Oct 2025 19:16:29 +0000 (15:16 -0400)
committerMiguel Ojeda <ojeda@kernel.org>
Mon, 20 Oct 2025 02:04:23 +0000 (04:04 +0200)
Reduce coupling to implementation details of the formatting machinery by
avoiding direct use for `core`'s formatting traits and macros.

This backslid in commit ed78a01887e2 ("rust: pci: provide access to PCI
Class and Class-related items").

Acked-by: Danilo Krummrich <dakr@kernel.org>
Signed-off-by: Tamir Duberstein <tamird@gmail.com>
Link: https://patch.msgid.link/20251018-cstr-core-v18-8-9378a54385f8@gmail.com
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
rust/kernel/pci/id.rs

index 7f2a7f57507f24e148ed5bd927d36a7de6961083..5f5d59ff49fca052e661eb006874378d5b37cefe 100644 (file)
@@ -4,8 +4,7 @@
 //!
 //! This module contains PCI class codes, Vendor IDs, and supporting types.
 
-use crate::{bindings, error::code::EINVAL, error::Error, prelude::*};
-use core::fmt;
+use crate::{bindings, error::code::EINVAL, error::Error, fmt, prelude::*};
 
 /// PCI device class codes.
 ///