/* Function for calculating the tail area size in number of 32-bit words.  */
static void tail_word_size_calculate(pstorage_size_t cmd_end_of_storage_address, pstorage_size_t end_of_storage_address)
/* Function for calculating the tail area size in number of 32-bit words.  */
static void tail_word_size_calculate(pstorage_size_t cmd_end_of_storage_address, pstorage_size_t end_of_storage_address)
{
    const uint32_t end_of_storage_area_page         = end_of_storage_address     / 
                                                      PSTORAGE_FLASH_PAGE_SIZE;
    const uint32_t command_end_of_storage_area_page = cmd_end_of_storage_address / 
                                                      PSTORAGE_FLASH_PAGE_SIZE;
    if (end_of_storage_area_page == command_end_of_storage_area_page)
    {
        m_tail_word_size = (end_of_storage_address - cmd_end_of_storage_address) / sizeof(uint32_t);                                           
    }
    else
    {
        m_tail_word_size = (PSTORAGE_FLASH_PAGE_SIZE - 
                           (cmd_end_of_storage_address % PSTORAGE_FLASH_PAGE_SIZE)) / 
                           sizeof(uint32_t);               
    }            
}