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
+104
View File
@@ -0,0 +1,104 @@
/**************************************************************************/
/* */
/* Copyright (c) Microsoft Corporation. All rights reserved. */
/* */
/* This software is licensed under the Microsoft Software License */
/* Terms for Microsoft Azure RTOS. Full text of the license can be */
/* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */
/* and in the root directory of this software. */
/* */
/**************************************************************************/
/**************************************************************************/
/**************************************************************************/
/** */
/** LevelX Component */
/** */
/** NAND Flash */
/** */
/**************************************************************************/
/**************************************************************************/
#define LX_SOURCE_CODE
/* Disable ThreadX error checking. */
#ifndef LX_DISABLE_ERROR_CHECKING
#define LX_DISABLE_ERROR_CHECKING
#endif
/* Include necessary system files. */
#include "lx_api.h"
/**************************************************************************/
/* */
/* FUNCTION RELEASE */
/* */
/* _lx_nand_flash_sectors_release PORTABLE C */
/* 6.x */
/* AUTHOR */
/* */
/* Xiuwen Cai, Microsoft Corporation */
/* */
/* DESCRIPTION */
/* */
/* This function releases multiple logical sectors from being managed */
/* in the NAND flash. */
/* */
/* INPUT */
/* */
/* nand_flash NAND flash instance */
/* logical_sector Logical sector number */
/* sector_count Number of sector to release */
/* */
/* OUTPUT */
/* */
/* return status */
/* */
/* CALLS */
/* */
/* _lx_nand_flash_sector_release Release one sector */
/* */
/* CALLED BY */
/* */
/* Application Code */
/* */
/* RELEASE HISTORY */
/* */
/* DATE NAME DESCRIPTION */
/* */
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
/* */
/**************************************************************************/
UINT _lx_nand_flash_sectors_release(LX_NAND_FLASH *nand_flash, ULONG logical_sector, ULONG sector_count)
{
UINT status = LX_SUCCESS;
UINT i;
/* Loop to release all the sectors. */
for (i = 0; i < sector_count; i++)
{
/* Release one sector. */
status = _lx_nand_flash_sector_release(nand_flash, logical_sector + i);
/* Check return status. */
if (status)
{
/* Error, break the loop. */
break;
}
}
/* Return status. */
return(status);
}