|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
Caller-owned private state for a caching block device. More...
#include <ra8_io_blockdev_cache.h>
Data Fields | |
| const ra8_io_blockdev_t * | under |
| Wrapped backend (private). | |
| uint8_t * | data |
| n_slots * 512 cache bytes. | |
| ra8_io_blockdev_cache_slot_t * | slots |
| n_slots metadata entries. | |
| uint32_t | n_slots |
| Number of cached sectors. | |
| uint32_t | clock |
| Monotonic LRU access counter. | |
| uint32_t | hits |
| Read cache hits so far. | |
| uint32_t | misses |
| Read cache misses so far. | |
Caller-owned private state for a caching block device.
Zero-initialise and pass to ra8_io_blockdev_cache_init. The underlying device, data buffer, and slot array must out-live it.
Definition at line 77 of file ra8_io_blockdev_cache.h.
| uint32_t ra8_io_blockdev_cache_state_t::clock |
Monotonic LRU access counter.
Definition at line 82 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_read_block(), internal_cache_state_init(), and internal_cache_write_block().
| uint8_t* ra8_io_blockdev_cache_state_t::data |
n_slots * 512 cache bytes.
Definition at line 79 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_read_block(), internal_cache_state_init(), and internal_cache_write_block().
| uint32_t ra8_io_blockdev_cache_state_t::hits |
Read cache hits so far.
Definition at line 83 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_read_block(), internal_cache_state_init(), and ra8_io_blockdev_cache_stats().
| uint32_t ra8_io_blockdev_cache_state_t::misses |
Read cache misses so far.
Definition at line 84 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_read_block(), internal_cache_state_init(), and ra8_io_blockdev_cache_stats().
| uint32_t ra8_io_blockdev_cache_state_t::n_slots |
Number of cached sectors.
Definition at line 81 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_erase(), internal_cache_find(), internal_cache_pick_victim(), internal_cache_read_block(), internal_cache_state_init(), and internal_cache_write_block().
| ra8_io_blockdev_cache_slot_t* ra8_io_blockdev_cache_state_t::slots |
n_slots metadata entries.
Definition at line 80 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_erase(), internal_cache_find(), internal_cache_pick_victim(), internal_cache_read_block(), internal_cache_state_init(), and internal_cache_write_block().
| const ra8_io_blockdev_t* ra8_io_blockdev_cache_state_t::under |
Wrapped backend (private).
Definition at line 78 of file ra8_io_blockdev_cache.h.
Referenced by internal_cache_erase(), internal_cache_get_caps(), internal_cache_read_block(), internal_cache_state_init(), internal_cache_sync(), and internal_cache_write_block().