Commit 56a446b4 authored by Fabio Baltieri's avatar Fabio Baltieri Committed by Fabio Baltieri
Browse files

modules: cmsis, cmsis_6: only add the intended cmsis module



The current code base is meant to use cmsis for Cortex A and R and
cmsis_6 for Cortex M, but the build system is configured to include the
path for both when Cortex M is selected. This leaves us exposed to PR
using the old headers, that would not get caught in CI but would fail
the build on a project using Cortex M that only has the cmsis_6 module.

Change the cmsis module setting to only include the module files in the
intended case.

Signed-off-by: default avatarFabio Baltieri <fabiobaltieri@google.com>
parent 8c81d657
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
# Copyright (c) 2023 Nordic Semiconductor ASA
# SPDX-License-Identifier: Apache-2.0

add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis)

if(CONFIG_CPU_AARCH32_CORTEX_A OR CONFIG_CPU_AARCH32_CORTEX_R)
  add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis)
  zephyr_include_directories(.)
endif()
+1 −2
Original line number Diff line number Diff line
# Copyright 2025 Arm Limited and/or its affiliates <open-source-office@arm.com>
# SPDX-License-Identifier: Apache-2.0

add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis_6)

if(CONFIG_CPU_CORTEX_M)
  add_subdirectory(${ZEPHYR_CURRENT_MODULE_DIR} cmsis_6)
  zephyr_include_directories(.)
endif()