Update on 18 Jan 2023. Expand to see details.

22299de Remove internal deprecated files.
2b9332f Fix ECC issues by new NAND logic
6a5eda1 Add a notice for not released file.
b756fb0 Upgrade to the latest Container Images.
This commit is contained in:
Xiuwen Cai
2023-01-18 08:37:32 +00:00
parent dbf4f90598
commit 27e3f5d915
43 changed files with 4075 additions and 4735 deletions
+7 -29
View File
@@ -40,7 +40,7 @@
/* FUNCTION RELEASE */
/* */
/* _lx_nand_flash_defragment PORTABLE C */
/* 6.1.7 */
/* 6.x */
/* AUTHOR */
/* */
/* William E. Lamie, Microsoft Corporation */
@@ -77,40 +77,18 @@
/* resulting in version 6.1 */
/* 06-02-2021 Bhupendra Naphade Modified comment(s), */
/* resulting in version 6.1.7 */
/* xx-xx-xxxx Xiuwen Cai Modified comment(s), */
/* deprecated this API, */
/* resulting in version 6.x */
/* */
/**************************************************************************/
UINT _lx_nand_flash_defragment(LX_NAND_FLASH *nand_flash)
{
ULONG i;
LX_PARAMETER_NOT_USED(nand_flash);
#ifdef LX_THREAD_SAFE_ENABLE
/* Obtain the thread safe mutex. */
tx_mutex_get(&nand_flash -> lx_nand_flash_mutex, TX_WAIT_FOREVER);
#endif
/* Loop for max number of blocks, while there are obsolete count. */
for (i = 0; i < nand_flash -> lx_nand_flash_total_blocks; i++)
{
/* Determine if there is any more defragment work. */
if (nand_flash -> lx_nand_flash_obsolete_pages == 0)
break;
/* Call the block reclaim function to defragment. */
_lx_nand_flash_block_reclaim(nand_flash);
}
#ifdef LX_THREAD_SAFE_ENABLE
/* Release the thread safe mutex. */
tx_mutex_put(&nand_flash -> lx_nand_flash_mutex);
#endif
/* Return successful completion. */
return(LX_SUCCESS);
/* Return not supported. */
return(LX_NOT_SUPPORTED);
}