diff --git a/src/export.rs b/src/export.rs index d6b2fc0406..bfd0f6dda1 100644 --- a/src/export.rs +++ b/src/export.rs @@ -237,7 +237,7 @@ pub unsafe fn lock( let current = basepri::read(); basepri::write(logical2hw(ceiling, nvic_prio_bits)); let r = f(&mut *ptr); - basepri::write(logical2hw(current, nvic_prio_bits)); + basepri::write(current); r } }