samples: ipc: static_vrings add NXP boards support

This commit adds support for these NXP Multi-core boards for
IPC static_vrings sample using OpenAmp lib:
 - lpcxpresso55s69
 - mimxrt1160_evk
 - mimxrt1170_evk
 - mimxrt1170_evkb

Signed-off-by: Tomas Galbicka <tomas.galbicka@nxp.com>
This commit is contained in:
Tomas Galbicka 2024-02-07 18:14:33 +01:00 committed by Alberto Escolar
parent bd699d0d50
commit 950382cb17
22 changed files with 777 additions and 4 deletions

View file

@ -1,5 +1,6 @@
#
# Copyright (c) 2021 Carlo Caione <ccaione@baylibre.com>
# Copyright 2024 NXP
#
# SPDX-License-Identifier: Apache-2.0
#
@ -8,12 +9,24 @@ cmake_minimum_required(VERSION 3.20.0)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
if(NOT CONFIG_BOARD_NRF5340DK_NRF5340_CPUAPP)
set(REMOTE_ZEPHYR_DIR ${CMAKE_CURRENT_BINARY_DIR}/../remote/zephyr)
if(NOT (CONFIG_BOARD_NRF5340DK_NRF5340_CPUAPP OR
CONFIG_BOARD_LPCXPRESSO55S69_LPC55S69_CPU0 OR
CONFIG_BOARD_MIMXRT1160_EVK_MIMXRT1166_CM7 OR
CONFIG_BOARD_MIMXRT1170_EVK_MIMXRT1176_CM7
)
)
message(FATAL_ERROR "${BOARD} is not supported for this sample")
endif()
project(ipc_service)
if(CONFIG_INCLUDE_REMOTE_DIR)
target_include_directories(zephyr_interface
INTERFACE ${REMOTE_ZEPHYR_DIR}/include/public)
endif()
target_sources(app PRIVATE src/main.c)
include(ExternalProject)

View file

@ -0,0 +1,11 @@
# Copyright 2024 NXP
#
# SPDX-License-Identifier: Apache-2.0
source "Kconfig.zephyr"
config INCLUDE_REMOTE_DIR
bool "Include remote core header directory"
help
Include remote build header files. Can be used if primary image
needs to be aware of size or base address of secondary image

View file

@ -1,4 +1,5 @@
# Copyright 2023 Nordic Semiconductor ASA
# Copyright 2024 NXP
#
# SPDX-License-Identifier: Apache-2.0
@ -7,3 +8,7 @@ source "share/sysbuild/Kconfig"
config NET_CORE_BOARD
string
default "nrf5340dk/nrf5340/cpunet" if $(BOARD) = "nrf5340dk"
default "lpcxpresso55s69/lpc55s69/cpu1" if $(BOARD) = "lpcxpresso55s69"
default "mimxrt1160_evk/mimxrt1166/cm4" if $(BOARD) = "mimxrt1160_evk"
default "mimxrt1170_evk/mimxrt1176/cm4" if $(BOARD) = "mimxrt1170_evk"
default "mimxrt1170_evkb/mimxrt1176/cm4" if $(BOARD) = "mimxrt1170_evkb"

View file

@ -20,6 +20,42 @@ Building the application for nrf5340dk/nrf5340/cpuapp
:goals: debug
:west-args: --sysbuild
Building the application for lpcxpresso55s69/lpc55s69/cpu0
**********************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/ipc_service/static_vrings
:board: lpcxpresso55s69/lpc55s69/cpu0
:goals: debug
:west-args: --sysbuild
Building the application for mimxrt1160_evk/mimxrt1166/cm7
**********************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/ipc_service/static_vrings
:board: mimxrt1160_evk/mimxrt1166/cm7
:goals: debug
:west-args: --sysbuild
Building the application for mimxrt1170_evk/mimxrt1176/cm7
**********************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/ipc_service/static_vrings
:board: mimxrt1170_evk/mimxrt1176/cm7
:goals: debug
:west-args: --sysbuild
Building the application for mimxrt1170_evk@B/mimxrt1176/cm7
************************************************************
.. zephyr-app-commands::
:zephyr-app: samples/subsys/ipc/ipc_service/static_vrings
:board: mimxrt1170_evk@B/mimxrt1176/cm7
:goals: debug
:west-args: --sysbuild
Open a serial terminal (minicom, putty, etc.) and connect the board with the
following settings:

View file

@ -0,0 +1 @@
CONFIG_SECOND_CORE_MCUX=y

View file

@ -0,0 +1,74 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
sram4_ipc0: memory@20040000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x20040000 DT_SIZE_K(8)>;
zephyr,memory-region="SRAM4_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
sram4_ipc1: memory@20042000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x20042000 DT_SIZE_K(8)>;
zephyr,memory-region="SRAM4_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/* Delete IPM Driver node nxp,lpc-mailbox */
/delete-node/ mailbox@8b000;
/* Attach MBOX driver to Mailbox Unit */
mbox:mailbox0@5008b000 {
compatible = "nxp,mbox-mailbox";
reg = <0x5008b000 0xEC>;
interrupts = <31 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&sram4_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "tx", "rx";
role = "host";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&sram4_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "tx", "rx";
role = "host";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};

View file

@ -0,0 +1,3 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_SECOND_CORE_MCUX=y
CONFIG_INCLUDE_REMOTE_DIR=y

View file

@ -0,0 +1,76 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
zephyr,console = &lpuart1;
zephyr,shell-uart = &lpuart1;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c48000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c48000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c48000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "tx", "rx";
role = "host";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "tx", "rx";
role = "host";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};

View file

@ -0,0 +1,3 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_SECOND_CORE_MCUX=y
CONFIG_INCLUDE_REMOTE_DIR=y

View file

@ -0,0 +1,76 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
zephyr,console = &lpuart1;
zephyr,shell-uart = &lpuart1;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c48000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c48000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c48000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "tx", "rx";
role = "host";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "tx", "rx";
role = "host";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};

View file

@ -0,0 +1,3 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_SECOND_CORE_MCUX=y
CONFIG_INCLUDE_REMOTE_DIR=y

View file

@ -0,0 +1,76 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
zephyr,console = &lpuart1;
zephyr,shell-uart = &lpuart1;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c48000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c48000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c48000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "tx", "rx";
role = "host";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "tx", "rx";
role = "host";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};

View file

@ -0,0 +1,2 @@
CONFIG_SECOND_CORE_MCUX=y
CONFIG_BUILD_OUTPUT_HEX=y

View file

@ -0,0 +1,74 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
sram4_ipc0: memory@20040000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x20040000 DT_SIZE_K(8)>;
zephyr,memory-region="SRAM4_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
sram4_ipc1: memory@20042000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x20042000 DT_SIZE_K(8)>;
zephyr,memory-region="SRAM4_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/* Delete IPM Driver node nxp,lpc-mailbox */
/delete-node/ mailbox@8b000;
/* Attach MBOX driver to Mailbox Unit */
mbox:mailbox0@5008b000 {
compatible = "nxp,mbox-mailbox";
reg = <0x5008b000 0xEC>;
interrupts = <31 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&sram4_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "rx", "tx";
role = "remote";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&sram4_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "rx", "tx";
role = "remote";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};

View file

@ -0,0 +1,4 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_BUILD_OUTPUT_INFO_HEADER=y
CONFIG_BUILD_OUTPUT_HEX=y
CONFIG_SECOND_CORE_MCUX=y

View file

@ -0,0 +1,98 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
zephyr,flash = &ocram;
zephyr,console = &lpuart2;
zephyr,shell-uart = &lpuart2;
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/delete-node/ gpt@400f0000;
/* Replace GPT2 with another GPT kernel timer */
gpt2_hw_timer:gpt@400f0000 {
compatible = "nxp,gpt-hw-timer";
reg = <0x400f0000 0x4000>;
interrupts = <120 0>;
status = "okay";
};
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c4c000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c4c000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c4c000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "rx", "tx";
role = "remote";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "rx", "tx";
role = "remote";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};
/* Enable secondary LPUART */
&lpuart2 {
status = "okay";
current-speed = <115200>;
};
/* Disable primary GPT timer */
&gpt_hw_timer {
status = "disabled";
};

View file

@ -0,0 +1,4 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_BUILD_OUTPUT_INFO_HEADER=y
CONFIG_BUILD_OUTPUT_HEX=y
CONFIG_SECOND_CORE_MCUX=y

View file

@ -0,0 +1,98 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
zephyr,flash = &ocram;
zephyr,console = &lpuart2;
zephyr,shell-uart = &lpuart2;
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/delete-node/ gpt@400f0000;
/* Replace GPT2 with another GPT kernel timer */
gpt2_hw_timer:gpt@400f0000 {
compatible = "nxp,gpt-hw-timer";
reg = <0x400f0000 0x4000>;
interrupts = <120 0>;
status = "okay";
};
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c4c000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c4c000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c4c000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "rx", "tx";
role = "remote";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "rx", "tx";
role = "remote";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};
/* Enable secondary LPUART */
&lpuart2 {
status = "okay";
current-speed = <115200>;
};
/* Disable primary GPT timer */
&gpt_hw_timer {
status = "disabled";
};

View file

@ -0,0 +1,4 @@
CONFIG_MBOX_NXP_IMX_MU=y
CONFIG_BUILD_OUTPUT_INFO_HEADER=y
CONFIG_BUILD_OUTPUT_HEX=y
CONFIG_SECOND_CORE_MCUX=y

View file

@ -0,0 +1,98 @@
/*
* Copyright 2024 NXP
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/ipc_service/static_vrings.h>
#include <zephyr/dt-bindings/memory-attr/memory-attr-arm.h>
/ {
chosen {
zephyr,flash = &ocram;
zephyr,console = &lpuart2;
zephyr,shell-uart = &lpuart2;
/* Delete ipc chosen property where old IPM mailbox driver bellow is
* configured.
*/
/delete-property/ zephyr,ipc;
/delete-property/ zephyr,ipc_shm;
};
/* Define memory regions for IPC
* Note that shared memory must have specific MPU attributes set.
*/
ocram2_ipc0: memory@202c0000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c0000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC0";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
ocram2_ipc1: memory@202c8000{
compatible = "zephyr,memory-region", "mmio-sram";
reg = <0x202c8000 DT_SIZE_K(32)>;
zephyr,memory-region="OCRAM2_IPC1";
zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO))>;
};
soc {
/delete-node/ gpt@400f0000;
/* Replace GPT2 with another GPT kernel timer */
gpt2_hw_timer:gpt@400f0000 {
compatible = "nxp,gpt-hw-timer";
reg = <0x400f0000 0x4000>;
interrupts = <120 0>;
status = "okay";
};
/* Delete IPM Driver node nxp,imx-mu */
/delete-node/ mailbox@40c4c000;
/* Attach MBOX driver to MU Unit */
mbox:mbox@40c4c000 {
compatible = "nxp,mbox-imx-mu";
reg = <0x40c4c000 0x4000>;
interrupts = <118 0>;
rx-channels = <4>;
#mbox-cells = <1>;
status = "okay";
};
};
ipc {
/delete-node/ ipc0;
ipc0: ipc0 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc0>;
mboxes = <&mbox 0>, <&mbox 1>;
mbox-names = "rx", "tx";
role = "remote";
status = "okay";
};
ipc1: ipc1 {
compatible = "zephyr,ipc-openamp-static-vrings";
memory-region = <&ocram2_ipc1>;
mboxes = <&mbox 2>, <&mbox 3>;
mbox-names = "rx", "tx";
role = "remote";
zephyr,priority = <1 PRIO_COOP>;
zephyr,buffer-size = <128>;
status = "okay";
};
};
};
/* Enable secondary LPUART */
&lpuart2 {
status = "okay";
current-speed = <115200>;
};
/* Disable primary GPT timer */
&gpt_hw_timer {
status = "disabled";
};

View file

@ -2,7 +2,12 @@ sample:
name: IPC Service example integration (OpenAMP static_vrings backend)
tests:
sample.ipc.static_vrings:
platform_allow: nrf5340dk/nrf5340/cpuapp
platform_allow:
- nrf5340dk/nrf5340/cpuapp
- lpcxpresso55s69/lpc55s69/cpu0
- mimxrt1160_evk/mimxrt1166/cm7
- mimxrt1170_evk/mimxrt1176/cm7
- mimxrt1170_evk@B/mimxrt1176/cm7
integration_platforms:
- nrf5340dk/nrf5340/cpuapp
tags: ipc

View file

@ -1,4 +1,5 @@
# Copyright (c) 2023 Nordic Semiconductor ASA
# Copyright 2024 NXP
# SPDX-License-Identifier: Apache-2.0
if("${SB_CONFIG_NET_CORE_BOARD}" STREQUAL "")
@ -7,8 +8,16 @@ if("${SB_CONFIG_NET_CORE_BOARD}" STREQUAL "")
"There is no remote board selected in Kconfig.sysbuild")
endif()
set(REMOTE_APP remote)
ExternalZephyrProject_Add(
APPLICATION remote
SOURCE_DIR ${APP_DIR}/remote
APPLICATION ${REMOTE_APP}
SOURCE_DIR ${APP_DIR}/${REMOTE_APP}
BOARD ${SB_CONFIG_NET_CORE_BOARD}
)
# Add dependencies so that the remote sample will be built first
# This is required because some primary cores need information from the
# remote core's build, such as the output image's LMA
add_dependencies(${DEFAULT_IMAGE} ${REMOTE_APP})
sysbuild_add_dependencies(CONFIGURE ${DEFAULT_IMAGE} ${REMOTE_APP})