Skip to content

Commit

Permalink
Add new RMW storage implementation
Browse files Browse the repository at this point in the history
Despite it looks little bit low-level but it works well with unaligned access.
I/O operations optimized by splitting it to stages:

- Not aligned start
- Aligned middle
- Not Aligned end

Each stage may or may not be needed depending from memory offset and data
length.

Also the data checked to determine that erase and/or write needed or not.
  • Loading branch information
katyo committed May 26, 2023
1 parent db8da46 commit 5a52e9d
Show file tree
Hide file tree
Showing 3 changed files with 485 additions and 167 deletions.
64 changes: 0 additions & 64 deletions src/iter.rs

This file was deleted.

8 changes: 0 additions & 8 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,9 @@
#![deny(missing_docs)]
#![deny(unsafe_code)]

/// Currently contains [`OverlapIterator`]
pub mod iter;
/// Technology specific traits for NOR Flashes
pub mod nor_flash;

/// A region denotes a contiguous piece of memory between two addresses.
pub trait Region {
/// Check if `address` is contained in the region of `Self`
fn contains(&self, address: u32) -> bool;
}

/// Transparent read only storage trait
pub trait ReadStorage {
/// An enumeration of storage errors
Expand Down
Loading

0 comments on commit 5a52e9d

Please sign in to comment.