Release 6.1.9

This commit is contained in:
Yuxin Zhou
2021-10-13 06:50:30 +00:00
parent 61f92c00c7
commit fdf7799991
6 changed files with 90 additions and 70 deletions
+7 -25
View File
@@ -40,7 +40,7 @@
/* FUNCTION RELEASE */
/* */
/* _lx_nand_flash_block_reclaim PORTABLE C */
/* 6.1.8 */
/* 6.1.9 */
/* AUTHOR */
/* */
/* William E. Lamie, Microsoft Corporation */
@@ -91,6 +91,10 @@
/* 08-02-2021 Bhupendra Naphade Modified comment(s), updated */
/* obselete page count check, */
/* resulting in version 6.1.8 */
/* 10-15-2021 Bhupendra Naphade Modified comment(s), */
/* removed multiple write */
/* to page 0, */
/* resulting in version 6.1.9 */
/* */
/**************************************************************************/
UINT _lx_nand_flash_block_reclaim(LX_NAND_FLASH *nand_flash)
@@ -218,22 +222,11 @@ UINT status;
}
/* Now store the erase count. */
page_word_ptr[0] = (erase_count | LX_BLOCK_ERASED);
page_word_ptr[0] = (erase_count);
/* Write the erase count for the block. */
status = _lx_nand_flash_driver_write(nand_flash, erase_block, 0, page_word_ptr, LX_NAND_ERASE_COUNT_WRITE_SIZE);
/* Check the status. */
if (status == LX_SUCCESS)
{
/* Now store the erase count. */
page_word_ptr[0] = erase_count;
/* Write the erase count for the block. */
status = _lx_nand_flash_driver_write(nand_flash, erase_block, 0, page_word_ptr, LX_NAND_ERASE_COUNT_WRITE_SIZE);
}
/* Check for an error from flash driver. */
if (status)
{
@@ -578,21 +571,10 @@ UINT status;
}
/* Now store the erase count. */
page_word_ptr[0] = (erase_count | LX_BLOCK_ERASED);
page_word_ptr[0] = (erase_count);
/* Write the erase count for the block. */
status = _lx_nand_flash_driver_write(nand_flash, erase_block, 0, page_word_ptr, LX_NAND_ERASE_COUNT_WRITE_SIZE);
/* Determine if the write was successful. */
if (status == LX_SUCCESS)
{
/* Now store the erase count. */
page_word_ptr[0] = erase_count;
/* Write the erase count for the block. */
status = _lx_nand_flash_driver_write(nand_flash, erase_block, 0, page_word_ptr, LX_NAND_ERASE_COUNT_WRITE_SIZE);
}
/* Check for an error from flash driver. */
if (status)