17 #ifndef __ITS_FLASH_FS_H__
18 #define __ITS_FLASH_FS_H__
34 #define ITS_FLASH_FS_USER_FLAGS_MASK ((1U << 16) - 1)
37 #define ITS_FLASH_FS_WRITE_FLAGS_MASK ((1U << 24) - (1U << 16))
39 #define ITS_FLASH_FS_FLAG_CREATE (1U << 16)
41 #define ITS_FLASH_FS_FLAG_TRUNCATE (1U << 17)
138 const uint8_t *data);
psa_status_t its_flash_fs_file_exist(its_flash_fs_ctx_t *fs_ctx, const uint8_t *fid)
Checks if a file exists in the filesystem.
psa_status_t its_flash_fs_file_delete(its_flash_fs_ctx_t *fs_ctx, const uint8_t *fid)
Deletes file referenced by the file ID.
psa_status_t its_flash_fs_file_read(its_flash_fs_ctx_t *fs_ctx, const uint8_t *fid, size_t size, size_t offset, uint8_t *data)
Reads data from an existing file.
Standard error codes for the SPM and RoT Services.
psa_status_t its_flash_fs_prepare(its_flash_fs_ctx_t *fs_ctx, const struct its_flash_info_t *flash_info)
Prepares the filesystem to accept operations on the files.
psa_status_t its_flash_fs_file_write(its_flash_fs_ctx_t *fs_ctx, const uint8_t *fid, uint32_t flags, size_t max_size, size_t data_size, size_t offset, const uint8_t *data)
Writes data to a file.
psa_status_t its_flash_fs_file_get_info(its_flash_fs_ctx_t *fs_ctx, const uint8_t *fid, struct its_file_info_t *info)
Gets the file information referenced by the file ID.
psa_status_t its_flash_fs_validate_params(const struct its_flash_info_t *info)
Validates the configuration of the flash filesystem.
Structure to store the file information.
Structure containing the required information about a flash device to be used by the ITS Flash FS...
Structure to store the ITS flash file system context.
int32_t psa_status_t
Function return status.
psa_status_t its_flash_fs_wipe_all(its_flash_fs_ctx_t *fs_ctx)
Wipes all files from the filesystem.