-
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.
soc: esp32: rework soc and dts structure
Apply to ESP32, ESP32S2, ESP32S3. Signed-off-by: Marek Matej <marek.matej@espressif.com>
- Loading branch information
Marek Matej
committed
May 30, 2023
1 parent
147d406
commit 390f93d
Showing
103 changed files
with
1,586 additions
and
201 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
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 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
/* placeholder - this is part used in SiP modules | ||
* and on some boards - flash/psram size needs to | ||
* be specified on board level | ||
*/ |
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 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x00000000 DT_SIZE_M(2)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x00000000 DT_SIZE_M(4)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x0 DT_SIZE_M(8)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x0 DT_SIZE_M(4)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x0 DT_SIZE_M(4)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x0 DT_SIZE_M(4)>; | ||
}; |
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,11 @@ | ||
/* | ||
* Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
#include "esp32.dtsi" | ||
|
||
&flash0 { | ||
reg = <0x0 DT_SIZE_M(4)>; | ||
}; |
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 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
add_subdirectory(${SOC_SERIES}) | ||
#add_subdirectory(common) | ||
#zephyr_include_directories(common) |
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,16 @@ | ||
# Copyright (c) 2023 Espressif | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config SOC_FAMILY_ESP32 | ||
bool | ||
|
||
if SOC_FAMILY_ESP32 | ||
|
||
config SOC_FAMILY | ||
string | ||
default "espressif_esp32" | ||
|
||
source "soc/riscv/espressif_esp32/*/Kconfig.soc" | ||
|
||
endif # SOC_FAMILY_ESP32 | ||
|
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,3 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
source "soc/arm/st_stm32/*/Kconfig.defconfig.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,6 @@ | ||
# ST Microelectronics STM32 MCU line | ||
|
||
# Copyright (c) 2016 Open-RnD Sp. z o.o. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
source "soc/arm/st_stm32/*/Kconfig.series" |
File renamed without changes.
File renamed without changes.
50 changes: 50 additions & 0 deletions
50
soc/riscv/espressif_esp32/esp32c3/Kconfig.defconfig.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,50 @@ | ||
# Copyright (c) 2021 NXP | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
if SOC_SERIES_NXP_IMX8 | ||
|
||
config SOC_SERIES | ||
string | ||
default "imx8" | ||
|
||
config SOC_TOOLCHAIN_NAME | ||
string | ||
default "nxp_imx_adsp" | ||
|
||
config SOC | ||
string | ||
default "nxp_imx8" | ||
|
||
config SMP | ||
default n | ||
|
||
config XTENSA_TIMER | ||
default y | ||
|
||
config SYS_CLOCK_HW_CYCLES_PER_SEC | ||
default 666000000 if XTENSA_TIMER | ||
|
||
config SYS_CLOCK_TICKS_PER_SEC | ||
default 50000 | ||
|
||
config KERNEL_ENTRY | ||
default "__start" | ||
|
||
config MULTI_LEVEL_INTERRUPTS | ||
default n | ||
|
||
config 2ND_LEVEL_INTERRUPTS | ||
default n | ||
|
||
config DYNAMIC_INTERRUPTS | ||
default y | ||
|
||
config LOG | ||
default y | ||
|
||
# To prevent test uses TEST_LOGGING_MINIMAL | ||
config TEST_LOGGING_DEFAULTS | ||
default n | ||
depends on TEST | ||
|
||
endif # SOC_SERIES_NXP_IMX8 |
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,13 @@ | ||
# Copyright (c) 2021 NXP | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config SOC_SERIES_NXP_IMX8 | ||
bool "NXP i.MX8" | ||
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 | ||
select ATOMIC_OPERATIONS_BUILTIN | ||
help | ||
NXP i.MX8 |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
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,5 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
add_subdirectory(${SOC_SERIES}) | ||
add_subdirectory(common) |
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,15 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
config SOC_FAMILY_ESP32 | ||
bool | ||
|
||
if SOC_FAMILY_ESP32 | ||
|
||
config SOC_FAMILY | ||
string | ||
default "espressif_esp32" | ||
|
||
source "soc/xtensa/espressif_esp32/*/Kconfig.soc" | ||
|
||
endif # SOC_FAMILY_ESP32 |
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,4 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
source "soc/xtensa/espressif_esp32/*/Kconfig.defconfig.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,4 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
source "soc/xtensa/espressif_esp32/*/Kconfig.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 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_include_directories(.) | ||
|
||
#zephyr_sources(stm32cube_hal.c) | ||
#zephyr_linker_sources_ifdef(CONFIG_STM32_CCM SECTIONS ccm.ld) | ||
#zephyr_linker_sources_ifdef(CONFIG_STM32_BACKUP_SRAM SECTIONS stm32_backup_sram.ld) | ||
#zephyr_sources_ifdef(CONFIG_STM32_BACKUP_SRAM stm32_backup_sram.c) | ||
#zephyr_sources(soc_config.c) |
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
16 changes: 16 additions & 0 deletions
16
soc/xtensa/espressif_esp32/esp32/Kconfig.defconfig.esp32d0wd
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,16 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
#ESP32-D0WD-V3 | ||
#flash 0 | ||
#psram 0 | ||
#gpio 34 | ||
#used_gpio 6,7,8,9,10,11 | ||
#cert BT_SIG | ||
|
||
if SOC_ESP32D0WD | ||
|
||
config SOC | ||
default "esp32d0wd" | ||
|
||
endif # SOC_ESP32D0WD config |
37 changes: 37 additions & 0 deletions
37
soc/xtensa/espressif_esp32/esp32/Kconfig.defconfig.esp32d0wdr2
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,37 @@ | ||
# Copyright (c) 2023 Espressif Systems (Shanghai) Co., Ltd. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
#ESP32-D0WDR2 | ||
#flash 0 | ||
#psram 2 | ||
#gpio 34 | ||
#used_gpio 6,7,8,9,10,11 | ||
|
||
if SOC_ESP32D0WDR2 | ||
|
||
config SOC | ||
default "esp32d0wdr2" | ||
|
||
#config ESP_SPIRAM | ||
# default y | ||
# | ||
#config SPIRAM_TYPE_ESPPSRAM16 | ||
# default y | ||
# | ||
#config D0WD_PSRAM_CLK_IO | ||
# int "PSRAM CLK IO number" | ||
# range 0 33 | ||
# default 17 | ||
# help | ||
# The PSRAM CLOCK IO can be any unused GPIO, user can config it based on hardware design. If user use | ||
# 1.8V flash and 1.8V psram, this value can only be one of 6, 7, 8, 9, 10, 11, 16, 17. | ||
# | ||
#config D0WD_PSRAM_CS_IO | ||
# int "PSRAM CS IO number" | ||
# range 0 33 | ||
# default 16 | ||
# help | ||
# The PSRAM CS IO can be any unused GPIO, user can config it based on hardware design. If user use | ||
# 1.8V flash and 1.8V psram, this value can only be one of 6, 7, 8, 9, 10, 11, 16, 17. | ||
|
||
endif # SOC_ESP32D0WDR2 config |
Oops, something went wrong.