|
1 | 1 | /*************************************************************************** |
2 | | - * Copyright (c) 2024 Microsoft Corporation |
3 | | - * |
| 2 | + * Copyright (c) 2024 Microsoft Corporation |
| 3 | + * Copyright (c) 2026-present Eclipse ThreadX contributors |
| 4 | + * |
4 | 5 | * This program and the accompanying materials are made available under the |
5 | 6 | * terms of the MIT License which is available at |
6 | 7 | * https://opensource.org/licenses/MIT. |
7 | | - * |
| 8 | + * |
8 | 9 | * SPDX-License-Identifier: MIT |
9 | 10 | **************************************************************************/ |
10 | 11 |
|
|
39 | 40 | /* Note that all the defines in this file may also be made on the */ |
40 | 41 | /* command line when building LevelX library and application objects. */ |
41 | 42 | /* */ |
42 | | -/* RELEASE HISTORY */ |
43 | | -/* */ |
44 | | -/* DATE NAME DESCRIPTION */ |
45 | | -/* */ |
46 | | -/* 11-09-2020 William E. Lamie Initial Version 6.1.2 */ |
47 | | -/* 06-02-2021 Bhupendra Naphade Modified comment(s), and */ |
48 | | -/* added standalone support, */ |
49 | | -/* resulting in version 6.1.7 */ |
50 | | -/* 03-08-2023 Xiuwen Cai Modified comment(s), and */ |
51 | | -/* added new NAND options, */ |
52 | | -/* resulting in version 6.2.1 */ |
53 | | -/* 10-31-2023 Xiuwen Cai Modified comment(s), */ |
54 | | -/* added options for mapping , */ |
55 | | -/* bitmap cache and obsolete */ |
56 | | -/* count cache, */ |
57 | | -/* resulting in version 6.3.0 */ |
58 | | -/* */ |
59 | 43 | /**************************************************************************/ |
60 | 44 |
|
61 | 45 | #ifndef LX_USER_H |
62 | 46 | #define LX_USER_H |
63 | 47 |
|
64 | 48 |
|
65 | 49 |
|
66 | | -/* Defined, this option bypasses the NOR flash driver read routine in favor or reading |
67 | | - the NOR memory directly, resulting in a significant performance increase. |
| 50 | +/* Defined, this option bypasses the NOR flash driver read routine in favor or reading |
| 51 | + the NOR memory directly, resulting in a significant performance increase. |
68 | 52 | */ |
69 | 53 | /* |
70 | 54 | #define LX_DIRECT_READ |
71 | 55 | */ |
72 | 56 |
|
73 | 57 |
|
74 | | -/* Defined, this causes the LevelX NOR instance open logic to verify free NOR |
| 58 | +/* Defined, this causes the LevelX NOR instance open logic to verify free NOR |
75 | 59 | sectors are all ones. |
76 | 60 | */ |
77 | 61 | /* |
78 | | -#define LX_FREE_SECTOR_DATA_VERIFY |
| 62 | +#define LX_FREE_SECTOR_DATA_VERIFY |
79 | 63 | */ |
80 | 64 |
|
81 | | -/* By default this value is 4, which represents a maximum of 4 blocks that |
| 65 | +/* By default this value is 4, which represents a maximum of 4 blocks that |
82 | 66 | can be allocated for metadata. |
83 | 67 | */ |
84 | 68 | /* |
|
90 | 74 | #define LX_NOR_DISABLE_EXTENDED_CACHE |
91 | 75 | */ |
92 | 76 |
|
93 | | -/* By default this value is 8, which represents a maximum of 8 sectors that |
| 77 | +/* By default this value is 8, which represents a maximum of 8 sectors that |
94 | 78 | can be cached in a NOR instance. |
95 | 79 | */ |
96 | 80 | /* |
97 | | -#define LX_NOR_EXTENDED_CACHE_SIZE 8 |
| 81 | +#define LX_NOR_EXTENDED_CACHE_SIZE 8 |
98 | 82 | */ |
99 | 83 |
|
100 | 84 |
|
101 | | -/* By default this value is 16 and defines the logical sector mapping cache size. |
102 | | - Large values improve performance, but cost memory. The minimum size is 8 and all |
| 85 | +/* By default this value is 16 and defines the logical sector mapping cache size. |
| 86 | + Large values improve performance, but cost memory. The minimum size is 8 and all |
103 | 87 | values must be a power of 2. |
104 | 88 | */ |
105 | 89 | /* |
106 | 90 | #define LX_NOR_SECTOR_MAPPING_CACHE_SIZE 16 |
107 | 91 | */ |
108 | 92 |
|
109 | | -/* Defined, this makes LevelX thread-safe by using a ThreadX mutex object |
| 93 | +/* Defined, this makes LevelX thread-safe by using a ThreadX mutex object |
110 | 94 | throughout the API. |
111 | 95 | */ |
112 | 96 | /* |
|
118 | 102 | /* #define LX_STANDALONE_ENABLE */ |
119 | 103 |
|
120 | 104 | /* Define user extension for NOR flash control block. User extension is placed at the end of flash control block and it is not cleared on opening flash. */ |
121 | | -/* |
| 105 | +/* |
122 | 106 | #define LX_NOR_FLASH_USER_EXTENSION ???? |
123 | 107 | */ |
124 | 108 |
|
125 | 109 | /* Define user extension for NAND flash control block. User extension is placed at the end of flash control block and it is not cleared on opening flash. */ |
126 | | -/* |
| 110 | +/* |
127 | 111 | #define LX_NAND_FLASH_USER_EXTENSION ???? |
128 | 112 | */ |
129 | 113 |
|
130 | | -/* Determine if logical sector mapping bitmap should be enabled in extended cache. |
| 114 | +/* Determine if logical sector mapping bitmap should be enabled in extended cache. |
131 | 115 | Cache memory will be allocated to sector mapping bitmap first. One bit can be allocated for each physical sector. */ |
132 | | -/* |
| 116 | +/* |
133 | 117 | #define LX_NOR_ENABLE_MAPPING_BITMAP |
134 | 118 | */ |
135 | 119 |
|
136 | | -/* Determine if obsolete count cache should be enabled in extended cache. |
137 | | - Cache memory will be allocated to obsolete count cache after the mapping bitmap if enabled, |
| 120 | +/* Determine if obsolete count cache should be enabled in extended cache. |
| 121 | + Cache memory will be allocated to obsolete count cache after the mapping bitmap if enabled, |
138 | 122 | and the rest of the cache memory is allocated to sector cache. */ |
139 | | -/* |
| 123 | +/* |
140 | 124 | #define LX_NOR_ENABLE_OBSOLETE_COUNT_CACHE |
141 | 125 | */ |
142 | 126 |
|
143 | 127 | /* Defines obsolete count cache element size. If number of sectors per block is greater than 256, use USHORT instead of UCHAR. */ |
144 | | -/* |
| 128 | +/* |
145 | 129 | #define LX_NOR_OBSOLETE_COUNT_CACHE_TYPE UCHAR |
146 | 130 | */ |
147 | 131 |
|
148 | | -/* Define the logical sector size for NOR flash. The sector size is in units of 32-bit words. |
| 132 | +/* Define the logical sector size for NOR flash. The sector size is in units of 32-bit words. |
149 | 133 | This sector size should match the sector size used in file system. */ |
150 | 134 | /* |
151 | 135 | #define LX_NOR_SECTOR_SIZE (512/sizeof(ULONG)) |
|
0 commit comments