[PATCH] rust: cpufreq: fix clippy::double_parens warning in Policy doctest

From: John Hubbard

Date: Wed Mar 04 2026 - 14:54:08 EST


Clippy reports:
warning: consider removing unnecessary double parentheses
--> rust/kernel/cpufreq.rs:410:60
|
410 | pr_info!("The policy details are: {:?}\n", (policy.cpu(), policy.cur()));
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Fix this by using separate format arguments.

Fixes: 6ebdd7c93177 ("rust: cpufreq: Extend abstractions for policy and driver ops")
Signed-off-by: John Hubbard <jhubbard@xxxxxxxxxx>
---
rust/kernel/cpufreq.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rust/kernel/cpufreq.rs b/rust/kernel/cpufreq.rs
index 76faa1ac8501..e94a17731557 100644
--- a/rust/kernel/cpufreq.rs
+++ b/rust/kernel/cpufreq.rs
@@ -407,7 +407,7 @@ pub fn to_table(mut self) -> Result<TableBox> {
/// .set_fast_switch_possible(true)
/// .set_transition_latency_ns(DEFAULT_TRANSITION_LATENCY_NS);
///
-/// pr_info!("The policy details are: {:?}\n", (policy.cpu(), policy.cur()));
+/// pr_info!("The policy details are: cpu={:?}, cur={:?}\n", policy.cpu(), policy.cur());
/// }
/// ```
#[repr(transparent)]

base-commit: ecc64d2dc9ff9738d2a896beb68e02c2feaf9a02
--
2.53.0