diff options
| author | Damien George <damien@micropython.org> | 2022-05-17 16:30:24 +1000 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2022-05-24 12:51:17 +1000 |
| commit | 115a23da2413e2161418864ad1f699aec8797062 (patch) | |
| tree | 1e5ba519edd0ad83a19f3f2afc9836a759427abe /lib/littlefs/lfs2_util.h | |
| parent | d42d35f56d836dca843de30df4c2d069911dc9da (diff) | |
lib/littlefs: Update littlefs2 to v2.5.0.
At commit 40dba4a556e0d81dfbe64301a6aa4e18ceca896c
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'lib/littlefs/lfs2_util.h')
| -rw-r--r-- | lib/littlefs/lfs2_util.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/littlefs/lfs2_util.h b/lib/littlefs/lfs2_util.h index 70bca717c..6a4c8ffb5 100644 --- a/lib/littlefs/lfs2_util.h +++ b/lib/littlefs/lfs2_util.h @@ -1,6 +1,7 @@ /* * lfs2 utility functions * + * Copyright (c) 2022, The littlefs authors. * Copyright (c) 2017, Arm Limited. All rights reserved. * SPDX-License-Identifier: BSD-3-Clause */ @@ -49,6 +50,7 @@ extern "C" // code footprint // Logging functions +#ifndef LFS2_TRACE #ifdef LFS2_YES_TRACE #define LFS2_TRACE_(fmt, ...) \ printf("%s:%d:trace: " fmt "%s\n", __FILE__, __LINE__, __VA_ARGS__) @@ -56,7 +58,9 @@ extern "C" #else #define LFS2_TRACE(...) #endif +#endif +#ifndef LFS2_DEBUG #ifndef LFS2_NO_DEBUG #define LFS2_DEBUG_(fmt, ...) \ printf("%s:%d:debug: " fmt "%s\n", __FILE__, __LINE__, __VA_ARGS__) @@ -64,7 +68,9 @@ extern "C" #else #define LFS2_DEBUG(...) #endif +#endif +#ifndef LFS2_WARN #ifndef LFS2_NO_WARN #define LFS2_WARN_(fmt, ...) \ printf("%s:%d:warn: " fmt "%s\n", __FILE__, __LINE__, __VA_ARGS__) @@ -72,7 +78,9 @@ extern "C" #else #define LFS2_WARN(...) #endif +#endif +#ifndef LFS2_ERROR #ifndef LFS2_NO_ERROR #define LFS2_ERROR_(fmt, ...) \ printf("%s:%d:error: " fmt "%s\n", __FILE__, __LINE__, __VA_ARGS__) @@ -80,13 +88,16 @@ extern "C" #else #define LFS2_ERROR(...) #endif +#endif // Runtime assertions +#ifndef LFS2_ASSERT #ifndef LFS2_NO_ASSERT #define LFS2_ASSERT(test) assert(test) #else #define LFS2_ASSERT(test) #endif +#endif // Builtin functions, these may be replaced by more efficient |
