From 816d63211f762b3be5bdd2633ff0154217dc01b1 Mon Sep 17 00:00:00 2001 From: Dmitry Date: Fri, 9 Mar 2018 09:17:32 +0300 Subject: [PATCH] Structure size updated to the 16 bytes * N --- components/wear_levelling/private_include/WL_Config.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/wear_levelling/private_include/WL_Config.h b/components/wear_levelling/private_include/WL_Config.h index cec5cca5ad..203c15a5e1 100644 --- a/components/wear_levelling/private_include/WL_Config.h +++ b/components/wear_levelling/private_include/WL_Config.h @@ -21,7 +21,7 @@ * */ typedef struct WL_Config_s { - size_t start_addr; /*!< start address in the flash*/ + size_t start_addr; /*!< start address in the flash*/ uint32_t full_mem_size; /*!< Amount of memory used to store data in bytes*/ uint32_t page_size; /*!< One page size in bytes. Page could be more then memory block. This parameter must be page_size >= N*block_size.*/ uint32_t sector_size; /*!< size of flash memory sector that will be erased and stored at once (erase)*/ @@ -29,12 +29,12 @@ typedef struct WL_Config_s { uint32_t wr_size; /*!< Minimum amount of bytes per one block at write operation: 1...*/ uint32_t version; /*!< A version of current implementatioon. To erase and reallocate complete memory this ID must be different from id before.*/ size_t temp_buff_size; /*!< Size of temporary allocated buffer to copy from one flash area to another. The best way, if this value will be equal to sector size.*/ - uint32_t reserved[3]; /*!< dummy array to make wl_config_t size compatible with flash encryption (divided by 16)*/ + uint32_t reserved[6]; /*!< dummy array to make wl_config_t size compatible with flash encryption (divided by 16)*/ uint32_t crc; /*!< CRC for this config*/ public: WL_Config_s() { - for (int i=0 ; i< 3 ; i++) this->reserved[i] = 0; + for (int i=0 ; i< 6 ; i++) this->reserved[i] = 0; } } wl_config_t;