nuttx/mm/kasan
leisiji 7253e70659 mm/kasan: fix build fail when CONFIG_MM_KASAN_GLOBAL and CONFIG_BUILD_KERNEL on
When CONFIG_MM_KASAN_GLOBAL is enabled, hook.c is also linked into
libmm.a. However, g_global_region (defined in global.c) is only
injected into the nuttx ELF by kasan_global.py — it does not process
the app binary. This causes undefined symbol errors when linking an
app against libmm.a.

Guard the inclusion of global.c with __KERNEL__ so that only kernel
builds pull in the global KASAN region, while app builds fall back
to the no-op stub.

Signed-off-by: leisiji <2265215145@qq.com>
2026-07-03 07:51:11 +02:00
..
CMakeLists.txt mm/kasan: Fix compile options applied to wrong target in SPLIT build 2026-06-08 16:03:21 +08:00
generic.c kasan: Fix assert judgment condition to correctly detect out-of-bounds causing trampling. 2025-07-01 09:04:03 -03:00
global.c mm/kasan: Kasan global support setting alignment length 2024-09-20 21:47:23 +08:00
hook.c mm/kasan: fix build fail when CONFIG_MM_KASAN_GLOBAL and CONFIG_BUILD_KERNEL on 2026-07-03 07:51:11 +02:00
hw_tags.c mte/kasan: Implementing KASAN memory protection for ARM64 hardware MTE 2025-06-30 18:19:38 +08:00
Kconfig kasan: Add configurable kasan initialization variable location 2025-06-30 18:19:38 +08:00
Make.defs kasan: Add configurable kasan initialization variable location 2025-06-30 18:19:38 +08:00
sw_tags.c kasan: Fix assert judgment condition to correctly detect out-of-bounds causing trampling. 2025-07-01 09:04:03 -03:00