|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
Caller-owned store handle. More...
#include <ra8_cache_store.h>
Data Fields | |
| struct LX_NOR_FLASH_STRUCT * | flash |
| LevelX control block (borrowed). | |
| ra8_cache_store_entry_t * | index |
| Caller-owned index slot array. | |
| uint8_t * | staging |
| Caller-owned >=1-sector scratch. | |
| uint16_t | index_cap |
| Number of index slots. | |
| uint16_t | checkpoint_dirs |
| Directory sectors for the checkpoint. | |
| uint32_t | logical_sectors |
| Usable LevelX logical-sector span. | |
| uint32_t | log_start |
| First append-log sector. | |
| uint32_t | data_capacity |
| Overprovisioned live-sector budget. | |
| uint32_t | live_sectors |
| Sectors currently held by live entries. | |
| uint32_t | next_seq |
| Monotonic append sequence number. | |
| uint8_t | flash_state |
| RAM shadow of sector 0 (dirty/clean). | |
| bool | inited |
| True between init and close. | |
Caller-owned store handle.
Treat every field as private.
Zero-initialise (= {}) and pass to ra8_cache_store_init. The handle out-lives every call and every ra8_cache_store_reader_t derived from it.
Definition at line 156 of file ra8_cache_store.h.
| uint16_t ra8_cache_store_t::checkpoint_dirs |
Directory sectors for the checkpoint.
Definition at line 161 of file ra8_cache_store.h.
Referenced by internal_dir_load(), internal_geometry(), and priv_cache_store_dir_save().
| uint32_t ra8_cache_store_t::data_capacity |
Overprovisioned live-sector budget.
Definition at line 164 of file ra8_cache_store.h.
Referenced by internal_geometry(), internal_put_check(), and priv_cache_store_super_write().
| struct LX_NOR_FLASH_STRUCT* ra8_cache_store_t::flash |
LevelX control block (borrowed).
Definition at line 157 of file ra8_cache_store.h.
Referenced by internal_init_fields(), internal_open_levelx(), priv_cache_store_sector_read(), priv_cache_store_sector_release(), priv_cache_store_sector_write(), and ra8_cache_store_close().
| uint8_t ra8_cache_store_t::flash_state |
RAM shadow of sector 0 (dirty/clean).
Definition at line 167 of file ra8_cache_store.h.
Referenced by internal_checkpoint(), internal_mark_dirty(), and internal_recover().
| ra8_cache_store_entry_t* ra8_cache_store_t::index |
Caller-owned index slot array.
Definition at line 158 of file ra8_cache_store.h.
Referenced by internal_dir_pack_sector(), internal_index_used(), internal_init_fields(), internal_run_free(), priv_cache_store_index_add(), priv_cache_store_index_find(), priv_cache_store_super_write(), ra8_cache_store_evict(), ra8_cache_store_get(), and ra8_cache_store_pin().
| uint16_t ra8_cache_store_t::index_cap |
Number of index slots.
Definition at line 160 of file ra8_cache_store.h.
Referenced by internal_dir_load(), internal_dir_pack_sector(), internal_index_used(), internal_init_fields(), internal_put_check(), internal_run_free(), priv_cache_store_index_add(), priv_cache_store_index_find(), and priv_cache_store_super_write().
| bool ra8_cache_store_t::inited |
True between init and close.
Definition at line 168 of file ra8_cache_store.h.
Referenced by internal_checkpoint(), internal_mark_dirty(), internal_put_check(), internal_release_run(), ra8_cache_store_close(), ra8_cache_store_evict(), ra8_cache_store_get(), ra8_cache_store_init(), ra8_cache_store_pin(), and ra8_cache_store_sync().
| uint32_t ra8_cache_store_t::live_sectors |
Sectors currently held by live entries.
Definition at line 165 of file ra8_cache_store.h.
Referenced by internal_dir_load(), internal_dir_unpack_sector(), internal_init_fields(), internal_put_check(), internal_scan_accept(), internal_scan_log(), priv_cache_store_super_write(), ra8_cache_store_evict(), and ra8_cache_store_put().
| uint32_t ra8_cache_store_t::log_start |
First append-log sector.
Definition at line 163 of file ra8_cache_store.h.
Referenced by internal_alloc_run(), internal_geometry(), internal_scan_log(), and priv_cache_store_super_write().
| uint32_t ra8_cache_store_t::logical_sectors |
Usable LevelX logical-sector span.
Definition at line 162 of file ra8_cache_store.h.
Referenced by internal_alloc_run(), internal_geometry(), internal_hdr_read(), internal_scan_log(), and priv_cache_store_super_write().
| uint32_t ra8_cache_store_t::next_seq |
Monotonic append sequence number.
Definition at line 166 of file ra8_cache_store.h.
Referenced by internal_init_fields(), internal_recover(), internal_scan_log(), priv_cache_store_super_write(), and ra8_cache_store_put().
| uint8_t* ra8_cache_store_t::staging |
Caller-owned >=1-sector scratch.
Definition at line 159 of file ra8_cache_store.h.
Referenced by internal_dir_load(), internal_hdr_read(), internal_init_fields(), internal_mount(), internal_read_at(), internal_scan_log(), internal_super_read(), internal_write_entry(), priv_cache_store_dir_save(), and priv_cache_store_super_write().