Skip to content

Commit 43531e4

Browse files
wdfk-progRbb666
authored andcommitted
feat(littlefs): 添加LittleFS配置选项支持
添加了多个LittleFS日志和调试相关的配置选项,包括: - LFS_YES_TRACE: 启用详细跟踪日志 - LFS_NO_DEBUG: 禁用调试日志 - LFS_NO_WARN: 禁用警告日志 - LFS_NO_ERROR: 禁用错误日志 - LFS_NO_ASSERT: 禁用运行时断言 - LFS_NO_INTRINSICS: 禁用编译器内置函数 - LFS_NO_MALLOC: 禁用动态内存分配 这些配置项提供了更灵活的LittleFS行为控制选项。
1 parent 8451e9e commit 43531e4

1 file changed

Lines changed: 46 additions & 0 deletions

File tree

system/littlefs/Kconfig

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,52 @@ if PKG_USING_LITTLEFS
7070
int "disk block size"
7171
default 4096
7272

73+
config LFS_YES_TRACE
74+
bool "Enable LittleFS trace logs"
75+
default n
76+
help
77+
Enable verbose trace logging from LittleFS. This is very noisy
78+
and may impact performance.
79+
80+
config LFS_NO_DEBUG
81+
bool "Disable LittleFS debug logs"
82+
default y
83+
help
84+
Disable debug-level logging from LittleFS.
85+
86+
config LFS_NO_WARN
87+
bool "Disable LittleFS warning logs"
88+
default n
89+
help
90+
Disable warning-level logging from LittleFS.
91+
92+
config LFS_NO_ERROR
93+
bool "Disable LittleFS error logs"
94+
default n
95+
help
96+
Disable error-level logging from LittleFS.
97+
98+
config LFS_NO_ASSERT
99+
bool "Disable LittleFS runtime asserts"
100+
default n
101+
help
102+
Disable runtime assertions inside LittleFS. This reduces safety
103+
checks and is not recommended for debug builds.
104+
105+
config LFS_NO_INTRINSICS
106+
bool "Disable LittleFS compiler intrinsics"
107+
default n
108+
help
109+
Use generic C implementations instead of compiler intrinsics.
110+
Useful for debugging or toolchains without builtin support.
111+
112+
config LFS_NO_MALLOC
113+
bool "Disable LittleFS dynamic allocation"
114+
default n
115+
help
116+
Disallow dynamic allocation inside LittleFS. When enabled,
117+
operations that require allocation may fail with LFS_ERR_NOMEM.
118+
73119
if PKG_USING_LITTLEFS_V090 || PKG_USING_LITTLEFS_V170 || PKG_USING_LITTLEFS_V172
74120
config LFS_LOOKAHEAD
75121
int "lfs lookahead size"

0 commit comments

Comments
 (0)