Skip to content

Commit 1b8f587

Browse files
committed
gpio: pl061: fix new clippy error
Without this fix, we get the following new clippy error: ``` error: deref which would be done by auto-deref --> drivers/gpio/gpio_pl061_rust.rs:285:75 | 285 | let gen_inner = unsafe { data.as_mut().map_unchecked_mut(|d| &mut (**d).inner) }; | ^^^^^ help: try this: `d` | ``` Signed-off-by: Wedson Almeida Filho <walmeida@microsoft.com>
1 parent 3dfc5eb commit 1b8f587

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/gpio/gpio_pl061_rust.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ impl amba::Driver for PL061Device {
282282
)?;
283283

284284
// SAFETY: General part of the data is pinned when `data` is.
285-
let gen_inner = unsafe { data.as_mut().map_unchecked_mut(|d| &mut (**d).inner) };
285+
let gen_inner = unsafe { data.as_mut().map_unchecked_mut(|d| &mut d.inner) };
286286
kernel::rawspinlock_init!(gen_inner, "PL061Data::inner");
287287

288288
let data = Arc::<DeviceData>::from(data);

0 commit comments

Comments
 (0)