-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
boards: Add support for the NXP MIMXRT595 DSP core
Add board and soc files for the audio DSP in NXP MIMXRT595. Signed-off-by: Dmitry Lukyantsev <[email protected]>
- Loading branch information
Dmitry Lukyantsev
committed
Aug 9, 2023
1 parent
352ece1
commit 7fcc0f3
Showing
17 changed files
with
940 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
DT_ADSP_RESET_MEM := $(dt_nodelabel_path,adsp_reset) | ||
DT_ADSP_DATA_MEM := $(dt_nodelabel_path,adsp_data) | ||
DT_ADSP_TEXT_MEM := $(dt_nodelabel_path,adsp_text) | ||
|
||
if BOARD_NXP_ADSP_RT595 | ||
|
||
config RT595_ADSP_STACK_SIZE | ||
hex "Boot time stack size" | ||
default 0x1000 | ||
help | ||
Stack space is reserved at the end of the RT595_ADSP_DATA_MEM | ||
region, starting at RT595_ADSP_DATA_MEM_ADDR - RT595_ADSP_STACK_SIZE | ||
|
||
config RT595_ADSP_RESET_MEM_ADDR | ||
hex | ||
default $(dt_node_reg_addr_hex,$(DT_ADSP_RESET_MEM)) | ||
|
||
config RT595_ADSP_RESET_MEM_SIZE | ||
hex | ||
default $(dt_node_reg_size_hex,$(DT_ADSP_RESET_MEM)) | ||
|
||
config RT595_ADSP_DATA_MEM_ADDR | ||
hex | ||
default $(dt_node_reg_addr_hex,$(DT_ADSP_DATA_MEM)) | ||
|
||
config RT595_ADSP_DATA_MEM_SIZE | ||
hex | ||
default $(dt_node_reg_size_hex,$(DT_ADSP_DATA_MEM)) | ||
|
||
config RT595_ADSP_TEXT_MEM_ADDR | ||
hex | ||
default $(dt_node_reg_addr_hex,$(DT_ADSP_TEXT_MEM)) | ||
|
||
config RT595_ADSP_TEXT_MEM_SIZE | ||
hex | ||
default $(dt_node_reg_size_hex,$(DT_ADSP_TEXT_MEM)) | ||
|
||
endif # BOARD_NXP_ADSP_RT595 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config BOARD_NXP_ADSP_RT595 | ||
bool "NXP ADSP RT595" | ||
depends on SOC_SERIES_NXP_RT595 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
if BOARD_NXP_ADSP_RT595 | ||
|
||
config BOARD | ||
default "nxp_adsp_rt595" | ||
|
||
endif # BOARD_NXP_ADSP_RT595 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
/* | ||
* Copyright (c) 2023 Google LLC. | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
/dts-v1/; | ||
#include <mem.h> | ||
#include <xtensa/xtensa.dtsi> | ||
|
||
/ { | ||
model = "nxp_adsp_rt595"; | ||
compatible = "nxp"; | ||
|
||
soc { | ||
cpus { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
cpu0: cpu@0 { | ||
device_type = "cpu"; | ||
compatible = "cdns,tensilica-xtensa-lx6"; | ||
reg = <0>; | ||
}; | ||
}; | ||
|
||
sram0: memory@0 { | ||
#address-cells = <1>; | ||
#size-cells = <1>; | ||
device_type = "memory"; | ||
compatible = "mmio-sram"; | ||
/* Reserve first 512kB of shared memory for ADSP. */ | ||
reg = <0x0 DT_SIZE_K(512)>; | ||
/* Reset section must always be at 0 and at least 1kB. */ | ||
adsp_reset: memory@0 { | ||
reg = <0x0 DT_SIZE_K(1)>; | ||
}; | ||
/* Code and data sections can be moved around and resized if needed. */ | ||
adsp_text: memory@400 { | ||
reg = <0x400 DT_SIZE_K(255)>; | ||
}; | ||
adsp_data: memory@40000 { | ||
reg = <0x40000 DT_SIZE_K(256)>; | ||
}; | ||
}; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
CONFIG_SOC_SERIES_NXP_RT595=y | ||
CONFIG_SOC_NXP_RT595=y | ||
CONFIG_BOARD_NXP_ADSP_RT595=y | ||
|
||
CONFIG_GEN_ISR_TABLES=y | ||
CONFIG_GEN_IRQ_VECTOR_TABLE=n | ||
CONFIG_XTENSA_SMALL_VECTOR_TABLE_ENTRY=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,26 @@ | ||
# NXP i.MX8 SoC family CMake file | ||
# NXP i.MX8/RT SoC family CMake file | ||
# | ||
# Copyright (c) 2021 NXP | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
if(CONFIG_SOC_SERIES_NXP_RT595) | ||
zephyr_compile_definitions(CPU_MIMXRT595SFFOC_dsp) | ||
endif() | ||
|
||
add_subdirectory(common) | ||
|
||
# west sign | ||
if(CONFIG_NXP_ADSP_SIGN_IMAGE) | ||
# west sign | ||
|
||
# See detailed comments in soc/xtensa/intel_adsp/common/CMakeLists.txt | ||
add_custom_target(zephyr.ri ALL | ||
DEPENDS ${CMAKE_BINARY_DIR}/zephyr/zephyr.ri | ||
) | ||
# See detailed comments in soc/xtensa/intel_adsp/common/CMakeLists.txt | ||
add_custom_target(zephyr.ri ALL | ||
DEPENDS ${CMAKE_BINARY_DIR}/zephyr/zephyr.ri | ||
) | ||
|
||
add_custom_command( | ||
OUTPUT ${CMAKE_BINARY_DIR}/zephyr/zephyr.ri | ||
COMMENT "west sign --if-tool-available --tool rimage ..." | ||
COMMAND west sign --if-tool-available --tool rimage --build-dir ${CMAKE_BINARY_DIR} ${WEST_SIGN_OPTS} | ||
DEPENDS ${CMAKE_BINARY_DIR}/zephyr/${KERNEL_ELF_NAME} | ||
) | ||
add_custom_command( | ||
OUTPUT ${CMAKE_BINARY_DIR}/zephyr/zephyr.ri | ||
COMMENT "west sign --if-tool-available --tool rimage ..." | ||
COMMAND west sign --if-tool-available --tool rimage --build-dir ${CMAKE_BINARY_DIR} ${WEST_SIGN_OPTS} | ||
DEPENDS ${CMAKE_BINARY_DIR}/zephyr/${KERNEL_ELF_NAME} | ||
) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,17 @@ | ||
# NXP i.MX8 SoC family default configuration options | ||
# NXP i.MX8/RT SoC family default configuration options | ||
# | ||
# Copyright (c) 2021 NXP | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
source "soc/xtensa/nxp_adsp/*/Kconfig.defconfig.series" | ||
|
||
config CACHE_MANAGEMENT | ||
def_bool y | ||
default y | ||
|
||
config XTENSA_TIMER | ||
default y | ||
|
||
# To prevent test uses TEST_LOGGING_MINIMAL | ||
config TEST_LOGGING_DEFAULTS | ||
default n | ||
depends on TEST |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
if SOC_SERIES_NXP_RT595 | ||
|
||
config SOC_SERIES | ||
string | ||
default "rt595" | ||
|
||
config SOC_TOOLCHAIN_NAME | ||
string | ||
default "nxp_rt595" | ||
|
||
config SOC | ||
string | ||
default "nxp_rt595" | ||
|
||
config SOC_PART_NUMBER | ||
string | ||
default "MIMXRT595SFFOC_dsp" if SOC_NXP_RT595 | ||
|
||
config SYS_CLOCK_HW_CYCLES_PER_SEC | ||
default 198000000 | ||
|
||
config SYS_CLOCK_TICKS_PER_SEC | ||
default 1000 | ||
|
||
config DYNAMIC_INTERRUPTS | ||
default n | ||
|
||
config CACHE | ||
default n | ||
|
||
config DCACHE | ||
default n | ||
|
||
config CACHE_MANAGEMENT | ||
default n | ||
|
||
config LOG | ||
default n | ||
|
||
config NXP_ADSP_SIGN_IMAGE | ||
default n | ||
|
||
endif # SOC_SERIES_NXP_RT595 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config SOC_SERIES_NXP_RT595 | ||
bool "NXP RT595 Series" | ||
select SOC_FAMILY_NXP_ADSP | ||
select XTENSA | ||
select XTENSA_HAL if ("$(ZEPHYR_TOOLCHAIN_VARIANT)" != "xcc" && "$(ZEPHYR_TOOLCHAIN_VARIANT)" != "xt-clang") | ||
select XTENSA_RESET_VECTOR | ||
select XTENSA_USE_CORE_CRT1 | ||
help | ||
NXP RT595 ADSP Series |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Copyright (c) 2023 Google LLC. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
choice | ||
prompt "NXP RT595 ADSP SoC Selection" | ||
|
||
config SOC_NXP_RT595 | ||
bool "NXP RT595" | ||
depends on SOC_SERIES_NXP_RT595 | ||
endchoice |
Oops, something went wrong.