sparse: add an address space and a __sparse_force annotation
We want to use a sparse address space to identify invalid conversions between cached and uncached address aliases. This patch adds a __sparse_cache sparse annotation for that. Where those conversions must be done that has to be supported by using the __sparse_force sparse attribute. To avoid compiler complains about unknown attributes we add a -Wno-attributes flag when building with sparse support. Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
This commit is contained in:
parent
41a77be91c
commit
17eb313a1b
3 changed files with 26 additions and 5 deletions
|
@ -269,6 +269,8 @@ endif()
|
|||
|
||||
if("${SPARSE}" STREQUAL "y")
|
||||
list(APPEND TOOLCHAIN_C_FLAGS -D__CHECKER__)
|
||||
# Avoid compiler "attribute directive ignored" warnings
|
||||
list(APPEND TOOLCHAIN_C_FLAGS -Wno-attributes)
|
||||
endif()
|
||||
|
||||
zephyr_compile_options(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue