diff --git a/hal/src/peripherals/can.rs b/hal/src/peripherals/can.rs index 2f65e4c7324..d5ca132a3ce 100644 --- a/hal/src/peripherals/can.rs +++ b/hal/src/peripherals/can.rs @@ -13,7 +13,6 @@ use crate::{ clock::v2::{ ahb::{AhbClk, AhbId}, - gclk::Gclk0Id, pclk::{Pclk, PclkId, PclkSourceId}, types::Can0, Source, @@ -49,7 +48,7 @@ impl Dependencies( - gclk0: S, + gclk: S, pclk: Pclk, ahbclk: AhbClk, rx: RX, @@ -57,27 +56,27 @@ impl Dependencies (Self, S::Inc) where - S: Source + Increment, + S: Source + Increment, { ( Self { pclk, - host_freq: gclk0.freq(), + host_freq: gclk.freq(), ahbclk, rx, tx, can, }, - gclk0.inc(), + gclk.inc(), ) } /// Destroy an instance of `Dependencies` struct. /// /// Releases all enclosed objects back to the user. #[allow(clippy::type_complexity)] - pub fn free(self, gclk0: S) -> (Pclk, HertzU32, AhbClk, RX, TX, CAN, S::Dec) + pub fn free(self, gclk: S) -> (Pclk, HertzU32, AhbClk, RX, TX, CAN, S::Dec) where - S: Source + Decrement, + S: Source + Decrement, { let Self { pclk, @@ -87,7 +86,7 @@ impl Dependencies