From c6ccd77e4ee7b679524b31ebc8a494ae6ca6d0f7 Mon Sep 17 00:00:00 2001 From: Robin Krahl Date: Fri, 18 Nov 2022 15:15:41 +0100 Subject: [PATCH] Remove unnecessary as_ref call --- src/drivers/sha.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/drivers/sha.rs b/src/drivers/sha.rs index 0902efe..435bc10 100644 --- a/src/drivers/sha.rs +++ b/src/drivers/sha.rs @@ -128,7 +128,7 @@ impl Sha<'_, Size> { fn process_block(peripheral: &mut Hashcrypt, input: &GenericArray) { // input must be word-aligned let input: Aligned> = Aligned(input.clone()); - let addr: u32 = &input.as_ref()[0] as *const _ as _; + let addr: u32 = &input[0] as *const _ as _; assert_eq!(addr & 0x3, 0); while peripheral.raw.status.read().waiting().is_not_waiting() { continue;