|
Nexus Embedded Platform 1.0.0
Statically assembled reusable embedded mechanisms
|
Native persistent file Flash model with fault injection. More...
#include "nexus/components/storage.h"Go to the source code of this file.
Data Structures | |
| struct | nx_file_flash_t |
Functions | |
| nx_storage_status_t | nx_file_flash_open (nx_file_flash_t *flash, const char *path, size_t size, size_t erase_size, size_t program_size) |
| Open an exclusively locked persistent host Flash model. | |
| void | nx_file_flash_close (nx_file_flash_t *flash) |
| Close the host file after all store users have quiesced. | |
| void | nx_file_flash_fail_after (nx_file_flash_t *flash, int64_t events) |
| Set an explicit model interruption boundary. | |
Native persistent file Flash model with fault injection.
Definition in file file_flash.h.
| void nx_file_flash_close | ( | nx_file_flash_t * | flash | ) |
Close the host file after all store users have quiesced.
| [in,out] | flash | Open serialized model |
| void nx_file_flash_fail_after | ( | nx_file_flash_t * | flash, |
| int64_t | events ) |
Set an explicit model interruption boundary.
| [in,out] | flash | Serialized open model |
| [in] | events | Programmed/erased bytes and sync attempts permitted; negative disables |
| nx_storage_status_t nx_file_flash_open | ( | nx_file_flash_t * | flash, |
| const char * | path, | ||
| size_t | size, | ||
| size_t | erase_size, | ||
| size_t | program_size ) |
Open an exclusively locked persistent host Flash model.
| [out] | flash | Unused caller-owned storage |
| [in] | path | Regular-file path; symlink traversal rejected |
| [in] | size | Exact persistent byte size |
| [in] | erase_size | Uniform erase block bytes |
| [in] | program_size | Aligned program bytes, 1..256 |