rust: block: mq: use vertical import style

Convert `use` imports to vertical layout for better readability and
maintainability.

Reviewed-by: Onur Özkan <work@onurozkan.dev>
Signed-off-by: Alvin Sun <alvin.sun@linux.dev>
Link: https://msgid.link/20260521-miscdev-use-format-v3-4-56240ca70d0c@linux.dev
Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
Link: https://patch.msgid.link/20260929-rust-block-for-v7-4-rc1-b4-v1-1-642a4c1aebd7@kernel.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
Alvin Sun 2026-09-29 11:33:59 +02:00 committed by Jens Axboe
parent ce054fbe9a
commit 020185c5f4
4 changed files with 59 additions and 17 deletions

View File

@ -7,14 +7,27 @@
use crate::{
bindings,
block::mq::{Operations, TagSet},
error::{self, from_err_ptr, Result},
fmt::{self, Write},
block::mq::{
Operations,
TagSet, //
},
error::{
self,
from_err_ptr,
Result, //
},
fmt::{
self,
Write, //
},
prelude::*,
static_lock_class,
str::NullTerminatedFormatter,
sync::Arc,
types::{ForeignOwnable, ScopeGuard},
types::{
ForeignOwnable,
ScopeGuard, //
}, //
};
/// A builder for [`GenDisk`].

View File

@ -6,11 +6,20 @@
use crate::{
bindings,
block::mq::{request::RequestDataWrapper, Request},
error::{from_result, Result},
block::mq::{
request::RequestDataWrapper,
Request, //
},
error::{
from_result,
Result, //
},
prelude::*,
sync::{aref::ARef, Refcount},
types::ForeignOwnable,
sync::{
aref::ARef,
Refcount, //
},
types::ForeignOwnable, //
};
use core::marker::PhantomData;

View File

@ -9,13 +9,19 @@
block::mq::Operations,
error::Result,
sync::{
aref::{ARef, AlwaysRefCounted},
aref::{
ARef,
AlwaysRefCounted, //
},
atomic::Relaxed,
Refcount,
Refcount, //
},
types::Opaque,
types::Opaque, //
};
use core::{
marker::PhantomData,
ptr::NonNull, //
};
use core::{marker::PhantomData, ptr::NonNull};
/// A wrapper around a blk-mq [`struct request`]. This represents an IO request.
///

View File

@ -8,13 +8,27 @@
use crate::{
bindings,
block::mq::{operations::OperationsVTable, request::RequestDataWrapper, Operations},
error::{self, Result},
block::mq::{
operations::OperationsVTable,
request::RequestDataWrapper,
Operations, //
},
error::{
self,
Result, //
},
prelude::try_pin_init,
types::Opaque,
types::Opaque, //
};
use core::{
convert::TryInto,
marker::PhantomData, //
};
use pin_init::{
pin_data,
pinned_drop,
PinInit, //
};
use core::{convert::TryInto, marker::PhantomData};
use pin_init::{pin_data, pinned_drop, PinInit};
/// A wrapper for the C `struct blk_mq_tag_set`.
///