From a82c125a840d09d30b2e9301e1aee4b18ad80f71 Mon Sep 17 00:00:00 2001 From: Dario Nieuwenhuis Date: Wed, 10 Aug 2022 19:28:23 +0200 Subject: [PATCH] Update to critical-section 1.0 --- Cargo.toml | 3 +-- src/usbd.rs | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 1934908..eb07f8c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -18,8 +18,7 @@ repository = "https://github.com/nrf-rs/nrf-usbd" cortex-m = "0.7.2" usb-device = "0.2.8" vcell = "0.1.3" -critical-section = "0.2.4" -bare-metal = "1.0.0" +critical-section = "1.0.0" [profile.dev] codegen-units = 1 diff --git a/src/usbd.rs b/src/usbd.rs index 24c324b..aacbb15 100644 --- a/src/usbd.rs +++ b/src/usbd.rs @@ -6,11 +6,10 @@ //! * Different events are used to initiate transfers. //! * No notification when the status stage is ACK'd. -use bare_metal::Mutex; use core::cell::Cell; use core::mem::MaybeUninit; use core::sync::atomic::{compiler_fence, Ordering}; -use critical_section::CriticalSection; +use critical_section::{CriticalSection, Mutex}; use usb_device::{ bus::{PollResult, UsbBus, UsbBusAllocator}, endpoint::{EndpointAddress, EndpointType},