1 /* 2 * Copyright (c) 2021 Nordic Semiconductor ASA 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 #ifndef __ZEPHYR_INCLUDE_DRIVERS__FLASH_SIMULATOR_H__ 7 #define __ZEPHYR_INCLUDE_DRIVERS__FLASH_SIMULATOR_H__ 8 9 #ifdef __cplusplus 10 extern "C" { 11 #endif 12 13 /** 14 * @file 15 * @brief Flash simulator specific API. 16 * 17 * Extension for flash simulator. 18 */ 19 20 /** 21 * @brief Obtain a pointer to the RAM buffer used but by the simulator 22 * 23 * This function allows the caller to get the address and size of the RAM buffer 24 * in which the flash simulator emulates its flash memory content. 25 * 26 * @param[in] dev flash simulator device pointer. 27 * @param[out] mock_size size of the ram buffer. 28 * 29 * @retval pointer to the ram buffer 30 */ 31 __syscall void *flash_simulator_get_memory(const struct device *dev, 32 size_t *mock_size); 33 #ifdef __cplusplus 34 } 35 #endif 36 37 #include <syscalls/flash_simulator.h> 38 39 #endif /* __ZEPHYR_INCLUDE_DRIVERS__FLASH_SIMULATOR_H__ */ 40