Skip to content

Commit 9f65a9f

Browse files
committed
fix
1 parent 0fda76e commit 9f65a9f

File tree

4 files changed

+11
-8
lines changed

4 files changed

+11
-8
lines changed

src/fsmc_lcd/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ use core::marker::PhantomData;
6868
pub use self::pins::{AddressPins, ChipSelectPins, DataPins, LcdPins, Pins};
6969
pub use self::timing::{AccessMode, Timing};
7070

71-
use crate::pac::RCC;
7271
use crate::rcc::{Enable, Reset};
7372

7473
// Use the FMC or FSMC, whichever is available, and treat it like an FSMC

src/otg_fs.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,10 @@ unsafe impl UsbPeripheral for USB {
6464
fn enable() {
6565
cortex_m::interrupt::free(|_| {
6666
// Enable USB peripheral
67-
pac::OTG_FS_GLOBAL::enable_unchecked();
68-
pac::OTG_FS_GLOBAL::reset_unchecked();
67+
unsafe {
68+
pac::OTG_FS_GLOBAL::enable_unchecked();
69+
pac::OTG_FS_GLOBAL::reset_unchecked();
70+
}
6971
});
7072
}
7173

src/otg_hs.rs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,12 @@ unsafe impl UsbPeripheral for USB {
5656

5757
fn enable() {
5858
cortex_m::interrupt::free(|_| {
59-
// Enable USB peripheral
60-
pac::OTG_HS_GLOBAL::enable_unchecked();
61-
// Reset USB peripheral
62-
pac::OTG_HS_GLOBAL::reset_unchecked();
59+
unsafe {
60+
// Enable USB peripheral
61+
pac::OTG_HS_GLOBAL::enable_unchecked();
62+
// Reset USB peripheral
63+
pac::OTG_HS_GLOBAL::reset_unchecked();
64+
}
6365
});
6466
}
6567

src/sdio.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//! Sdio host
22
33
use crate::gpio::alt::sdio as alt;
4-
use crate::pac::{self, RCC, SDIO};
4+
use crate::pac::{self, SDIO};
55
use crate::rcc::{Clocks, Enable, Reset};
66
#[allow(unused_imports)]
77
use fugit::HertzU32 as Hertz;

0 commit comments

Comments
 (0)