6#ifndef NEXUS_COMPONENTS_STORAGE_H
7#define NEXUS_COMPONENTS_STORAGE_H
49#define NX_STORAGE_HEADER_SIZE 32u
92 size_t offset,
size_t bank_size,
93 void* workspace,
size_t workspace_bytes);
nx_storage_status_t nx_storage_load(nx_storage_t *storage, void *output, size_t *size)
Load and validate the latest committed whole blob.
nx_storage_status_t
Storage errors expose retry/reopen/recovery decisions.
nx_storage_status_t nx_storage_save(nx_storage_t *storage, const void *data, size_t size)
Commit a complete blob to the inactive bank.
size_t nx_storage_capacity(const nx_storage_t *storage)
Query usable blob capacity without touching hardware.
nx_storage_status_t nx_storage_open(nx_storage_t *storage, const nx_storage_port_t *port, size_t offset, size_t bank_size, void *workspace, size_t workspace_bytes)
Open/recover two externally supplied uniform erase banks.
Synchronous settled persistent Flash port.
nx_storage_status_t(* program)(void *, size_t, const void *, size_t)
nx_storage_status_t(* read)(void *, size_t, void *, size_t)
nx_storage_status_t(* erase)(void *, size_t, size_t)
nx_storage_status_t(* sync)(void *)
Instance metadata with caller-sized workspace.