diff --git a/embassy-stm32/build.rs b/embassy-stm32/build.rs index 5b845780..223e93ff 100644 --- a/embassy-stm32/build.rs +++ b/embassy-stm32/build.rs @@ -496,6 +496,7 @@ fn main() { let match_arms: TokenStream = rcc_enumm .variants .iter() + .filter(|v| v.name != "DISABLE") .map(|v| { let variant_name = format_ident!("{}", v.name); diff --git a/embassy-stm32/src/rcc/h.rs b/embassy-stm32/src/rcc/h.rs index 86392dc2..b82dc37e 100644 --- a/embassy-stm32/src/rcc/h.rs +++ b/embassy-stm32/src/rcc/h.rs @@ -618,10 +618,8 @@ pub(crate) unsafe fn init(config: Config) { #[cfg(stm32h5)] mux_rcc_pclk4: None, #[cfg(stm32h5)] - mux_hse: None, + mux_hse: hse, - #[cfg(stm32h5)] - mux_disable: None, #[cfg(stm32h5)] mux_hsi48: None, }); diff --git a/embassy-stm32/src/rcc/mod.rs b/embassy-stm32/src/rcc/mod.rs index abd8402c..85583e0f 100644 --- a/embassy-stm32/src/rcc/mod.rs +++ b/embassy-stm32/src/rcc/mod.rs @@ -184,8 +184,6 @@ pub struct Clocks { #[cfg(stm32h5)] pub mux_hse: Option, - #[cfg(stm32h5)] - pub mux_disable: Option, #[cfg(stm32h5)] pub mux_hsi48: Option, }