Skip to content

Commit a8bc412

Browse files
committed
Release 6.2.1 on 08 Mar 2023. Expand to see details.
075bb4c Update patch version. a30e30b Update version and date for release. a6b42b2 Update owners 6a3e60b Add user extension in flash control block
1 parent 718fb51 commit a8bc412

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+457
-102
lines changed

common/inc/lx_api.h

Lines changed: 54 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
/* APPLICATION INTERFACE DEFINITION RELEASE */
2727
/* */
2828
/* lx_api.h PORTABLE C */
29-
/* 6.x */
29+
/* 6.2.1 */
3030
/* AUTHOR */
3131
/* */
3232
/* William E. Lamie, Microsoft Corporation */
@@ -75,9 +75,11 @@
7575
/* 10-31-2022 Xiuwen Cai Modified comment(s), and */
7676
/* updated product constants, */
7777
/* resulting in version 6.2.0 */
78-
/* xx-xx-xxxx Xiuwen Cai Modified comment(s), */
78+
/* 03-08-2023 Xiuwen Cai Modified comment(s), */
7979
/* modified NAND logic, */
80-
/* resulting in version 6.x */
80+
/* added new driver interface */
81+
/* and user extension, */
82+
/* resulting in version 6.2.1 */
8183
/* */
8284
/**************************************************************************/
8385

@@ -190,7 +192,7 @@ typedef unsigned long long ULONG64;
190192
#define AZURE_RTOS_LEVELX
191193
#define LEVELX_MAJOR_VERSION 6
192194
#define LEVELX_MINOR_VERSION 2
193-
#define LEVELX_PATCH_VERSION 0
195+
#define LEVELX_PATCH_VERSION 1
194196

195197

196198
/* Define general LevelX Constants. */
@@ -385,6 +387,14 @@ typedef struct LX_NAND_DEVICE_INFO_STRUCT
385387
ULONG lx_nand_device_info_base_erase_count;
386388
} LX_NAND_DEVICE_INFO;
387389

390+
391+
/* Determine if the flash control block has an extension defined. If not,
392+
define the extension to whitespace. */
393+
394+
#ifndef LX_NAND_FLASH_USER_EXTENSION
395+
#define LX_NAND_FLASH_USER_EXTENSION
396+
#endif
397+
388398
/* Define the NAND flash control block structure. */
389399

390400
typedef struct LX_NAND_FLASH_STRUCT
@@ -454,6 +464,22 @@ typedef struct LX_NAND_FLASH_STRUCT
454464
ULONG lx_nand_flash_diagnostic_block_erased_verifies;
455465
ULONG lx_nand_flash_diagnostic_page_erased_verifies;
456466

467+
#ifdef LX_NAND_ENABLE_CONTROL_BLOCK_FOR_DRIVER_INTERFACE
468+
UINT (*lx_nand_flash_driver_read)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, ULONG *destination, ULONG words);
469+
UINT (*lx_nand_flash_driver_write)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, ULONG *source, ULONG words);
470+
UINT (*lx_nand_flash_driver_block_erase)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG erase_count);
471+
UINT (*lx_nand_flash_driver_block_erased_verify)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block);
472+
UINT (*lx_nand_flash_driver_page_erased_verify)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page);
473+
UINT (*lx_nand_flash_driver_block_status_get)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, UCHAR *bad_block_flag);
474+
UINT (*lx_nand_flash_driver_block_status_set)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, UCHAR bad_block_flag);
475+
UINT (*lx_nand_flash_driver_extra_bytes_get)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, UCHAR *destination, UINT size);
476+
UINT (*lx_nand_flash_driver_extra_bytes_set)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, UCHAR *source, UINT size);
477+
UINT (*lx_nand_flash_driver_system_error)(struct LX_NAND_FLASH_STRUCT *nand_flash, UINT error_code, ULONG block, ULONG page);
478+
479+
UINT (*lx_nand_flash_driver_pages_read)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, UCHAR* main_buffer, UCHAR* spare_buffer, ULONG pages);
480+
UINT (*lx_nand_flash_driver_pages_write)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG block, ULONG page, UCHAR* main_buffer, UCHAR* spare_buffer, ULONG pages);
481+
UINT (*lx_nand_flash_driver_pages_copy)(struct LX_NAND_FLASH_STRUCT *nand_flash, ULONG source_block, ULONG source_page, ULONG destination_block, ULONG destination_page, ULONG pages, UCHAR* data_buffer);
482+
#else
457483
UINT (*lx_nand_flash_driver_read)(ULONG block, ULONG page, ULONG *destination, ULONG words);
458484
UINT (*lx_nand_flash_driver_write)(ULONG block, ULONG page, ULONG *source, ULONG words);
459485
UINT (*lx_nand_flash_driver_block_erase)(ULONG block, ULONG erase_count);
@@ -468,7 +494,7 @@ typedef struct LX_NAND_FLASH_STRUCT
468494
UINT (*lx_nand_flash_driver_pages_read)(ULONG block, ULONG page, UCHAR* main_buffer, UCHAR* spare_buffer, ULONG pages);
469495
UINT (*lx_nand_flash_driver_pages_write)(ULONG block, ULONG page, UCHAR* main_buffer, UCHAR* spare_buffer, ULONG pages);
470496
UINT (*lx_nand_flash_driver_pages_copy)(ULONG source_block, ULONG source_page, ULONG destination_block, ULONG destination_page, ULONG pages, UCHAR* data_buffer);
471-
497+
#endif
472498
UCHAR *lx_nand_flash_page_buffer;
473499
UINT lx_nand_flash_page_buffer_size;
474500

@@ -483,6 +509,10 @@ typedef struct LX_NAND_FLASH_STRUCT
483509
/* Define the NAND flash control block open next/previous pointers. */
484510
struct LX_NAND_FLASH_STRUCT *lx_nand_flash_open_next,
485511
*lx_nand_flash_open_previous;
512+
513+
/* Define the user extension in the flash control block. This
514+
is typically defined in lx_user.h. */
515+
LX_NAND_FLASH_USER_EXTENSION
486516

487517
} LX_NAND_FLASH;
488518

@@ -508,6 +538,13 @@ typedef struct LX_NOR_FLASH_EXTENDED_CACHE_ENTRY_STRUCT
508538
} LX_NOR_FLASH_EXTENDED_CACHE_ENTRY;
509539

510540

541+
/* Determine if the flash control block has an extension defined. If not,
542+
define the extension to whitespace. */
543+
544+
#ifndef LX_NOR_FLASH_USER_EXTENSION
545+
#define LX_NOR_FLASH_USER_EXTENSION
546+
#endif
547+
511548
/* Define the NOR flash control block structure. */
512549

513550
typedef struct LX_NOR_FLASH_STRUCT
@@ -553,11 +590,19 @@ typedef struct LX_NOR_FLASH_STRUCT
553590
ULONG lx_nor_flash_diagnostic_sector_not_free;
554591
ULONG lx_nor_flash_diagnostic_sector_data_not_free;
555592

593+
#ifdef LX_NOR_ENABLE_CONTROL_BLOCK_FOR_DRIVER_INTERFACE
594+
UINT (*lx_nor_flash_driver_read)(struct LX_NOR_FLASH_STRUCT *nor_flash, ULONG *flash_address, ULONG *destination, ULONG words);
595+
UINT (*lx_nor_flash_driver_write)(struct LX_NOR_FLASH_STRUCT *nor_flash, ULONG *flash_address, ULONG *source, ULONG words);
596+
UINT (*lx_nor_flash_driver_block_erase)(struct LX_NOR_FLASH_STRUCT *nor_flash, ULONG block, ULONG erase_count);
597+
UINT (*lx_nor_flash_driver_block_erased_verify)(struct LX_NOR_FLASH_STRUCT *nor_flash, ULONG block);
598+
UINT (*lx_nor_flash_driver_system_error)(struct LX_NOR_FLASH_STRUCT *nor_flash, UINT error_code);
599+
#else
556600
UINT (*lx_nor_flash_driver_read)(ULONG *flash_address, ULONG *destination, ULONG words);
557601
UINT (*lx_nor_flash_driver_write)(ULONG *flash_address, ULONG *source, ULONG words);
558602
UINT (*lx_nor_flash_driver_block_erase)(ULONG block, ULONG erase_count);
559603
UINT (*lx_nor_flash_driver_block_erased_verify)(ULONG block);
560604
UINT (*lx_nor_flash_driver_system_error)(UINT error_code);
605+
#endif
561606

562607
ULONG *lx_nor_flash_sector_buffer;
563608
UINT lx_nor_flash_sector_mapping_cache_enabled;
@@ -585,6 +630,10 @@ typedef struct LX_NOR_FLASH_STRUCT
585630
struct LX_NOR_FLASH_STRUCT *lx_nor_flash_open_next,
586631
*lx_nor_flash_open_previous;
587632

633+
/* Define the user extension in the flash control block. This
634+
is typically defined in lx_user.h. */
635+
LX_NOR_FLASH_USER_EXTENSION
636+
588637
} LX_NOR_FLASH;
589638

590639

common/inc/lx_user_sample.h

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
/* PORT SPECIFIC C INFORMATION RELEASE */
2727
/* */
2828
/* lx_user.h PORTABLE C */
29-
/* 6.x */
29+
/* 6.2.1 */
3030
/* */
3131
/* AUTHOR */
3232
/* */
@@ -48,9 +48,9 @@
4848
/* 06-02-2021 Bhupendra Naphade Modified comment(s), and */
4949
/* added standalone support, */
5050
/* resulting in version 6.1.7 */
51-
/* xx-xx-xxxx Xiuwen Cai Modified comment(s), and */
51+
/* 03-08-2023 Xiuwen Cai Modified comment(s), and */
5252
/* added new NAND options, */
53-
/* resulting in version 6.x */
53+
/* resulting in version 6.2.1 */
5454
/* */
5555
/**************************************************************************/
5656

@@ -113,7 +113,15 @@
113113

114114
/* #define LX_STANDALONE_ENABLE */
115115

116+
/* Define user extension for NOR flash control block. */
117+
/*
118+
#define LX_NOR_FLASH_USER_EXTENSION ????
119+
*/
116120

121+
/* Define user extension for NAND flash control block. */
122+
/*
123+
#define LX_NAND_FLASH_USER_EXTENSION ????
124+
*/
117125

118126
#endif
119127

common/src/fx_nand_flash_simulated_driver.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ VOID _fx_nand_flash_simulator_driver(FX_MEDIA *media_ptr);
7171
/* FUNCTION RELEASE */
7272
/* */
7373
/* _fx_nand_simulator_driver PORTABLE C */
74-
/* 6.x */
74+
/* 6.2.1 */
7575
/* AUTHOR */
7676
/* */
7777
/* William E. Lamie, Microsoft Corporation */
@@ -126,9 +126,9 @@ VOID _fx_nand_flash_simulator_driver(FX_MEDIA *media_ptr);
126126
/* resulting in version 6.1 */
127127
/* 06-02-2021 Bhupendra Naphade Modified comment(s), */
128128
/* resulting in version 6.1.7 */
129-
/* xx-xx-xxxx Xiuwen Cai Modified comment(s), */
129+
/* 03-08-2023 Xiuwen Cai Modified comment(s), */
130130
/* changed to use new API, */
131-
/* resulting in version 6.x */
131+
/* resulting in version 6.2.1 */
132132
/* */
133133
/**************************************************************************/
134134
VOID _fx_nand_flash_simulator_driver(FX_MEDIA *media_ptr)

common/src/lx_nand_flash_256byte_ecc_compute.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_256byte_ecc_compute PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* William E. Lamie, Microsoft Corporation */
@@ -77,9 +77,9 @@
7777
/* resulting in version 6.1 */
7878
/* 06-02-2021 Bhupendra Naphade Modified comment(s), */
7979
/* resulting in version 6.1.7 */
80-
/* xx-xx-xxxx Xiuwen Cai Modified comment(s), */
80+
/* 03-08-2023 Xiuwen Cai Modified comment(s), */
8181
/* inverted output, */
82-
/* resulting in version 6.x */
82+
/* resulting in version 6.2.1 */
8383
/* */
8484
/**************************************************************************/
8585
UINT _lx_nand_flash_256byte_ecc_compute(UCHAR *page_buffer, UCHAR *ecc_buffer)

common/src/lx_nand_flash_block_allocate.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_block_allocate PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* Xiuwen Cai, Microsoft Corporation */
@@ -70,7 +70,7 @@
7070
/* */
7171
/* DATE NAME DESCRIPTION */
7272
/* */
73-
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
73+
/* 03-08-2023 Xiuwen Cai Initial Version 6.2.1 */
7474
/* */
7575
/**************************************************************************/
7676
UINT _lx_nand_flash_block_allocate(LX_NAND_FLASH* nand_flash, ULONG* block)

common/src/lx_nand_flash_block_data_move.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_block_data_move PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* Xiuwen Cai, Microsoft Corporation */
@@ -83,7 +83,7 @@
8383
/* */
8484
/* DATE NAME DESCRIPTION */
8585
/* */
86-
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
86+
/* 03-08-2023 Xiuwen Cai Initial Version 6.2.1 */
8787
/* */
8888
/**************************************************************************/
8989
UINT _lx_nand_flash_block_data_move(LX_NAND_FLASH *nand_flash, ULONG new_block)

common/src/lx_nand_flash_block_find.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_block_find PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* Xiuwen Cai, Microsoft Corporation */
@@ -77,7 +77,7 @@
7777
/* */
7878
/* DATE NAME DESCRIPTION */
7979
/* */
80-
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
80+
/* 03-08-2023 Xiuwen Cai Initial Version 6.2.1 */
8181
/* */
8282
/**************************************************************************/
8383
UINT _lx_nand_flash_block_find(LX_NAND_FLASH *nand_flash, ULONG logical_sector, ULONG *block, USHORT *block_status)

common/src/lx_nand_flash_block_mapping_set.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_block_mapping_set PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* Xiuwen Cai, Microsoft Corporation */
@@ -71,7 +71,7 @@
7171
/* */
7272
/* DATE NAME DESCRIPTION */
7373
/* */
74-
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
74+
/* 03-08-2023 Xiuwen Cai Initial Version 6.2.1 */
7575
/* */
7676
/**************************************************************************/
7777
UINT _lx_nand_flash_block_mapping_set(LX_NAND_FLASH *nand_flash, ULONG logical_sector, ULONG block)

common/src/lx_nand_flash_block_status_set.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
/* FUNCTION RELEASE */
4141
/* */
4242
/* _lx_nand_flash_block_status_set PORTABLE C */
43-
/* 6.x */
43+
/* 6.2.1 */
4444
/* AUTHOR */
4545
/* */
4646
/* Xiuwen Cai, Microsoft Corporation */
@@ -71,7 +71,7 @@
7171
/* */
7272
/* DATE NAME DESCRIPTION */
7373
/* */
74-
/* xx-xx-xxxx Xiuwen Cai Initial Version 6.x */
74+
/* 03-08-2023 Xiuwen Cai Initial Version 6.2.1 */
7575
/* */
7676
/**************************************************************************/
7777
UINT _lx_nand_flash_block_status_set(LX_NAND_FLASH *nand_flash, ULONG block, ULONG block_status)

0 commit comments

Comments
 (0)