Align examples

This commit is contained in:
Rasmus Melchior Jacobsen
2023-05-30 14:03:31 +02:00
parent c2aca45b8d
commit 36e00caf4d
18 changed files with 108 additions and 65 deletions

View File

@ -42,7 +42,9 @@ impl<ACTIVE: NorFlash, DFU: NorFlash, STATE: NorFlash, const BUFFER_SIZE: usize>
/// # Safety
///
/// This modifies the stack pointer and reset vector and will run code placed in the active partition.
pub unsafe fn load(&mut self, start: u32) -> ! {
pub unsafe fn load(self, start: u32) -> ! {
core::mem::drop(self.boot);
trace!("Loading app at 0x{:x}", start);
#[allow(unused_mut)]
let mut p = cortex_m::Peripherals::steal();