12#ifndef ZEPHYR_INCLUDE_RETENTION_
13#define ZEPHYR_INCLUDE_RETENTION_
int(* retention_write_api)(const struct device *dev, off_t offset, const uint8_t *buffer, size_t size)
Definition retention.h:39
int retention_write(const struct device *dev, off_t offset, const uint8_t *buffer, size_t size)
Writes data to the retention area (underlying data does not need to be cleared prior to writing),...
int(* retention_read_api)(const struct device *dev, off_t offset, uint8_t *buffer, size_t size)
Definition retention.h:37
ssize_t(* retention_size_api)(const struct device *dev)
Definition retention.h:35
int retention_read(const struct device *dev, off_t offset, uint8_t *buffer, size_t size)
Reads data from the retention area.
int(* retention_clear_api)(const struct device *dev)
Definition retention.h:41
int retention_is_valid(const struct device *dev)
Checks if the underlying data in the retention area is valid or not.
int retention_clear(const struct device *dev)
Clears all data in the retention area (sets it to 0)
int(* retention_is_valid_api)(const struct device *dev)
Definition retention.h:36
ssize_t retention_size(const struct device *dev)
Returns the size of the retention area.
__SIZE_TYPE__ ssize_t
Definition types.h:28
__INTPTR_TYPE__ off_t
Definition types.h:36
__UINT8_TYPE__ uint8_t
Definition stdint.h:88
Runtime device structure (in ROM) per driver instance.
Definition device.h:403
Definition retention.h:43
retention_write_api write
Definition retention.h:47
retention_is_valid_api is_valid
Definition retention.h:45
retention_clear_api clear
Definition retention.h:48
retention_size_api size
Definition retention.h:44
retention_read_api read
Definition retention.h:46
static ZTEST_BMEM char buffer[8]
Definition test_mbox_api.c:433