Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions modules/hal_nxp/mcux/Kconfig.mcux
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,11 @@ config NXP_IEEE802154_MAC
If enabled, the NBU firmware used by the device will be use the 802.15.4
MAC interface.

config NXP_MULTICORE
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need a new kconfig? Can't we directly include the multicore manager in multicore.cmake based on the SoC/NBU kconfig?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I discussed this with @mmahadevan108, the idea is to avoid having to update multicore.cmake every time we add a new platform. Using a kconfig like this makes it transparent, the platform just has to select the kconfig.
I agree it's only half true, because we still have to select the multicore platform port depending on CONFIG_SOC_xxx, so still need to update multicore.cmake, but it's reduced maintenance (1 line to add).
Moreover, if we keep using the "based on SoC kconfig" approach, this file will just grow and duplicate the same logic for every platform (this applies to other middlewares too).

bool "NXP Multicore Manager support"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we have two separate configuration parameters, one for mcmgr and another one for rpmsg-lite?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I wasn't sure. I preferred going with the "reduced" approach since for now, the supported platforms will select both anyway (W71, W72). I would let @TomasGalbickaNXP split it if needed at some point.

help
Includes NXP Multicore Manager support.

endif # HAS_MCUX

config BT_NXP_PCM_PINS_DIR_REVERSE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,4 @@ add_subdirectory(${MCUX_SDK_NG_DIR}/middleware/usb
)

include(${CMAKE_CURRENT_LIST_DIR}/connectivity_framework.cmake)
include(${CMAKE_CURRENT_LIST_DIR}/multicore.cmake)
14 changes: 14 additions & 0 deletions modules/hal_nxp/mcux/mcux-sdk-ng/middleware/multicore.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
if(CONFIG_NXP_MULTICORE)
set(CONFIG_MCUX_COMPONENT_middleware.multicore.mcmgr ON)
set_variable_ifdef(CONFIG_SOC_MCXW716C CONFIG_MCUX_COMPONENT_middleware.multicore.mcmgr.mcxw716)
set_variable_ifdef(CONFIG_SOC_MCXW727C_CPU0 CONFIG_MCUX_COMPONENT_middleware.multicore.mcmgr.mcxw727)

set(CONFIG_MCUX_COMPONENT_middleware.multicore.rpmsg-lite ON)
set(CONFIG_MCUX_COMPONENT_middleware.multicore.rpmsg-lite.zephyr ON)
set_variable_ifdef(CONFIG_SOC_MCXW716C CONFIG_MCUX_COMPONENT_middleware.multicore.rpmsg-lite.mcxw71x)
set_variable_ifdef(CONFIG_SOC_MCXW727C_CPU0 CONFIG_MCUX_COMPONENT_middleware.multicore.rpmsg-lite.mcxw72x)

add_subdirectory(${MCUX_SDK_NG_DIR}/middleware/mcuxsdk-middleware-multicore
${CMAKE_CURRENT_BINARY_DIR}/mcuxsdk-middleware-multicore
)
endif()
8 changes: 8 additions & 0 deletions soc/nxp/mcx/mcxw/mcxw7xx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,11 @@ rsource "../../../common/Kconfig.nbu"
config MCUX_CORE_SUFFIX
default "_cm33_core0" if SOC_MCXW727C_CPU0
default "_cm33_core1" if SOC_MCXW727C_CPU1

config SOC_MCXW716C
bool
select NXP_MULTICORE if NXP_NBU

config SOC_MCXW727C_CPU0
bool
select NXP_MULTICORE if NXP_NBU
2 changes: 1 addition & 1 deletion west.yml
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ manifest:
groups:
- hal
- name: hal_nxp
revision: 0a0c1680179b286997f0bfec4cb89ca90f2b8685
revision: 26ab97dc6e55e01a43db486ace71b57b6ee3ff06
path: modules/hal/nxp
groups:
- hal
Expand Down