d486bd3cfe
Add build assert to make sure _RETARGETABLE_LOCKING is enabled in toolchain, When _RETARGETABLE_LOCKING is enabled, "_LOCK_T" is "__lock" pointer type, otherwise "_LOCK_T" is "int" type, so there will be the following compile warnings when toolchain doesn't enable _RETARGETABLE_LOCKING: zephyr/lib/libc/newlib/libc-hooks.c:416:13: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] 416 | k_sem_take((struct k_sem *)lock, K_FOREVER); | ^ zephyr/lib/libc/newlib/libc-hooks.c: In function '__retarget_lock_acquire _recursive': zephyr/lib/libc/newlib/libc-hooks.c:423:15: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] 423 | k_mutex_lock((struct k_mutex *)lock, K_FOREVER); | ^ ... Signed-off-by: Jiafei Pan <Jiafei.Pan@nxp.com> |
||
---|---|---|
.. | ||
libc | ||
open-amp | ||
os | ||
posix | ||
smf | ||
util | ||
CMakeLists.txt | ||
Kconfig |