[PATCH 67/79] block: rust: remove the `is_poll` parameter from `queue_rq`

Andreas Hindborg
2026-02-15T23:41:29Z

The information can now be obtained from `Request::is_poll`.

Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
---
drivers/block/rnull/rnull.rs | 1 -
rust/kernel/block/mq.rs | 1 -
rust/kernel/block/mq/operations.rs | 7 -------
3 files changed, 9 deletions(-)

diff --git a/drivers/block/rnull/rnull.rs b/drivers/block/rnull/rnull.rs
index 592fbf5790fd2..db856f03b78cb 100644
--- a/drivers/block/rnull/rnull.rs
+++ b/drivers/block/rnull/rnull.rs
@@ -907,7 +907,6 @@ fn queue_rq(
this: ArcBorrow<'_, Self>,
rq: Owned<mq::IdleRequest<Self>>,
is_last: bool,
- _is_poll: bool,
) -> BlkResult {
Ok(Self::queue_rq_internal(hw_data, this, rq, is_last)?)
}
diff --git a/rust/kernel/block/mq.rs b/rust/kernel/block/mq.rs
index 786c32f2cb56c..02d75acfddb3b 100644
--- a/rust/kernel/block/mq.rs
+++ b/rust/kernel/block/mq.rs
@@ -90,7 +90,6 @@
//! _queue_data: (),
//! rq: Owned<IdleRequest<Self>>,
//! _is_last: bool,
-//! is_poll: bool
//! ) -> BlkResult {
//! rq.start().end_ok();
//! Ok(())
diff --git a/rust/kernel/block/mq/operations.rs b/rust/kernel/block/mq/operations.rs
index e4de6db807e18..efead98767196 100644
--- a/rust/kernel/block/mq/operations.rs
+++ b/rust/kernel/block/mq/operations.rs
@@ -67,7 +67,6 @@ fn queue_rq(
queue_data: ForeignBorrowed<'_, Self::QueueData>,
rq: Owned<IdleRequest<Self>>,
is_last: bool,
- is_poll: bool,
) -> BlkResult;

/// Called by the kernel to queue a list of requests with the driver.
@@ -188,11 +187,6 @@ impl<T: Operations> OperationsVTable<T> {
// `into_foreign` in `Self::init_hctx_callback`.
let hw_data = unsafe { T::HwData::borrow((*hctx).driver_data) };

- let is_poll = u32::from(
- // SAFETY: `hctx` is valid as required by this function.
- unsafe { (*hctx).type_ },
- ) == bindings::hctx_type_HCTX_TYPE_POLL;
-
// SAFETY: `hctx` is valid as required by this function.
let queue_data = unsafe { (*(*hctx).queue).queuedata };

@@ -209,7 +203,6 @@ impl<T: Operations> OperationsVTable<T> {
// SAFETY: `bd` is valid as required by the safety requirement for
// this function.
unsafe { (*bd).last },
- is_poll,
);

if let Err(e) = ret {

--
2.51.2