soc: remove unnecessary inclusions of devicetree.h

Many ARM SoCs included <devicetree.h> likely due to:

1. nvic.h not being self-contained
2. As a result of copy-paste

Some RISC-V SoCs had the same problem, in this case likely due to
copy-paste from ARM. The <devicetree.h> header has been removed using
the following command:

sed -i ':a;N;$!ba;s/#include <devicetree\.h>\n//g' soc/**/soc.h

soc.h files that make a legitimate usage of the API have not been
changed.

Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
This commit is contained in:
Gerard Marull-Paretas 2022-01-03 16:43:09 +01:00 committed by Carles Cufí
commit e5e73a70e9
59 changed files with 0 additions and 96 deletions

View file

@ -95,8 +95,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pins.h" #include "soc_pins.h"
#include "soc_power.h" #include "soc_power.h"

View file

@ -7,7 +7,6 @@
#ifndef _SOC_H_ #ifndef _SOC_H_
#define _SOC_H_ #define _SOC_H_
#include <devicetree.h>
#define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU #define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU

View file

@ -16,7 +16,6 @@
#endif #endif
#include <devicetree.h>
#include <soc_registers.h> #include <soc_registers.h>
extern void wakeup_cpu1(void); extern void wakeup_cpu1(void);

View file

@ -17,6 +17,5 @@
#define __MVE_FP 1U /* MVE floating point present */ #define __MVE_FP 1U /* MVE floating point present */
#endif #endif
#include <devicetree.h>
#endif /* _SOC_H_ */ #endif /* _SOC_H_ */

View file

@ -9,7 +9,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include "system_cmsdk_musca_b1.h" #include "system_cmsdk_musca_b1.h"
#include <devicetree.h>
#include <sys/util.h> #include <sys/util.h>
#endif #endif

View file

@ -9,7 +9,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include "system_cmsdk_musca_s1.h" #include "system_cmsdk_musca_s1.h"
#include <devicetree.h>
#include <sys/util.h> #include <sys/util.h>
#endif #endif

View file

@ -17,8 +17,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#define DONT_USE_CMSIS_INIT #define DONT_USE_CMSIS_INIT
#define DONT_USE_PREDEFINED_CORE_HANDLERS #define DONT_USE_PREDEFINED_CORE_HANDLERS

View file

@ -19,8 +19,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#define DONT_USE_CMSIS_INIT #define DONT_USE_CMSIS_INIT
#define DONT_USE_PREDEFINED_CORE_HANDLERS #define DONT_USE_PREDEFINED_CORE_HANDLERS

View file

@ -19,8 +19,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#define DONT_USE_CMSIS_INIT #define DONT_USE_CMSIS_INIT
#define DONT_USE_PREDEFINED_CORE_HANDLERS #define DONT_USE_PREDEFINED_CORE_HANDLERS

View file

@ -17,8 +17,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#define DONT_USE_CMSIS_INIT #define DONT_USE_CMSIS_INIT
#define DONT_USE_PREDEFINED_CORE_HANDLERS #define DONT_USE_PREDEFINED_CORE_HANDLERS

View file

@ -18,8 +18,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#define DONT_USE_CMSIS_INIT #define DONT_USE_CMSIS_INIT
#define DONT_USE_PREDEFINED_CORE_HANDLERS #define DONT_USE_PREDEFINED_CORE_HANDLERS

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAMD20E14) #if defined(CONFIG_SOC_PART_NUMBER_SAMD20E14)
#include <samd20e14.h> #include <samd20e14.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAMD21E15A) #if defined(CONFIG_SOC_PART_NUMBER_SAMD21E15A)
#include <samd21e15a.h> #include <samd21e15a.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAMD51G18A) #if defined(CONFIG_SOC_PART_NUMBER_SAMD51G18A)
#include <samd51g18a.h> #include <samd51g18a.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAME51J18A) #if defined(CONFIG_SOC_PART_NUMBER_SAME51J18A)
#include <same51j18a.h> #include <same51j18a.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAME53J18A) #if defined(CONFIG_SOC_PART_NUMBER_SAME53J18A)
#include <same53j18a.h> #include <same53j18a.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAME54N19A) #if defined(CONFIG_SOC_PART_NUMBER_SAME54N19A)
#include <same54n19a.h> #include <same54n19a.h>

View file

@ -13,8 +13,6 @@
#include <zephyr/types.h> #include <zephyr/types.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#if defined(CONFIG_SOC_PART_NUMBER_SAMR21E16A) #if defined(CONFIG_SOC_PART_NUMBER_SAMR21E16A)
#include <samr21e16a.h> #include <samr21e16a.h>

View file

@ -11,7 +11,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
/* Interrupt Number Definition */ /* Interrupt Number Definition */
typedef enum IRQn { typedef enum IRQn {

View file

@ -12,7 +12,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
/* Interrupt Number Definition */ /* Interrupt Number Definition */
typedef enum IRQn { typedef enum IRQn {

View file

@ -19,8 +19,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#include <cy_device_headers.h> #include <cy_device_headers.h>

View file

@ -8,7 +8,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
#include <gd32f3x0.h> #include <gd32f3x0.h>
#endif /* _ASMLANGUAGE */ #endif /* _ASMLANGUAGE */

View file

@ -13,7 +13,6 @@
#include <sys/util.h> #include <sys/util.h>
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
#include <gd32f403.h> #include <gd32f403.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -8,7 +8,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
#include <gd32f4xx.h> #include <gd32f4xx.h>
#endif /* _ASMLANGUAGE */ #endif /* _ASMLANGUAGE */

View file

@ -6,7 +6,5 @@
* *
*/ */
/* Add include for DTS generated information */
#include <devicetree.h>
#include <system_XMC4500.h> #include <system_XMC4500.h>
#include <XMC4500.h> #include <XMC4500.h>

View file

@ -11,8 +11,6 @@
#define __FPU_PRESENT CONFIG_CPU_HAS_FPU #define __FPU_PRESENT CONFIG_CPU_HAS_FPU
#define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU #define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU
/* Add include for DTS generated information */
#include <devicetree.h>
#include <reg/reg_access.h> #include <reg/reg_access.h>
#include <reg/reg_def.h> #include <reg/reg_def.h>

View file

@ -11,8 +11,6 @@
#define __FPU_PRESENT CONFIG_CPU_HAS_FPU #define __FPU_PRESENT CONFIG_CPU_HAS_FPU
#define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU #define __MPU_PRESENT CONFIG_CPU_HAS_ARM_MPU
/* Add include for DTS generated information */
#include <devicetree.h>
#include <reg/reg_access.h> #include <reg/reg_access.h>
#include <reg/reg_def.h> #include <reg/reg_def.h>

View file

@ -9,7 +9,6 @@
#define ZEPHYR_SOC_ARM_NUVOTON_M48X_SOC_H_ #define ZEPHYR_SOC_ARM_NUVOTON_M48X_SOC_H_
#include <sys/util.h> #include <sys/util.h>
#include <devicetree.h>
#include <NuMicro.h> #include <NuMicro.h>
#endif /* ZEPHYR_SOC_ARM_NUVOTON_M48X_SOC_H_*/ #endif /* ZEPHYR_SOC_ARM_NUVOTON_M48X_SOC_H_*/

View file

@ -13,8 +13,6 @@ extern "C" {
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
/* Add include for DTS generated information */
#include <devicetree.h>
#include <fsl_device_registers.h> #include <fsl_device_registers.h>

View file

@ -25,8 +25,6 @@
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -17,8 +17,6 @@ extern "C" {
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -13,8 +13,6 @@
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -15,8 +15,6 @@
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -17,8 +17,6 @@ extern "C" {
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -26,8 +26,6 @@
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -18,8 +18,6 @@
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <sys/util.h> #include <sys/util.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -19,8 +19,6 @@
#include <sys/util.h> #include <sys/util.h>
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -19,8 +19,6 @@
#include <sys/util.h> #include <sys/util.h>
#include <fsl_common.h> #include <fsl_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -9,7 +9,6 @@
#include <sys/util.h> #include <sys/util.h>
#include <eoss3_dev.h> #include <eoss3_dev.h>
#include <devicetree.h>
/* Available frequencies */ /* Available frequencies */
#define HSOSC_1MHZ 1024000 #define HSOSC_1MHZ 1024000

View file

@ -25,8 +25,6 @@ extern "C" {
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -22,8 +22,6 @@
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -20,8 +20,6 @@
#include <em_bus.h> #include <em_bus.h>
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -19,8 +19,6 @@
#include <em_common.h> #include <em_common.h>
/* Add include for DTS generated information */
#include <devicetree.h>
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"

View file

@ -22,8 +22,6 @@
#include "soc_pinmap.h" #include "soc_pinmap.h"
#include "../common/soc_gpio.h" #include "../common/soc_gpio.h"
/* Add include for DTS generated information */
#include <devicetree.h>
#endif /* !_ASMLANGUAGE */ #endif /* !_ASMLANGUAGE */

View file

@ -6,6 +6,5 @@
#ifndef _SOC_H_ #ifndef _SOC_H_
#define _SOC_H_ #define _SOC_H_
#include <devicetree.h>
#endif /* _SOC_H_ */ #endif /* _SOC_H_ */

View file

@ -11,7 +11,6 @@
#include <toolchain.h> #include <toolchain.h>
#ifndef _ASMLANGUAGE #ifndef _ASMLANGUAGE
#include <devicetree.h>
#endif /* _ASMLANGUAGE */ #endif /* _ASMLANGUAGE */
#define UART_REG_ADDR_INTERVAL 1 #define UART_REG_ADDR_INTERVAL 1

View file

@ -7,7 +7,6 @@
* *
*/ */
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
#define UART_REG_ADDR_INTERVAL 1 #define UART_REG_ADDR_INTERVAL 1

View file

@ -12,7 +12,6 @@
#define __RISCV_ANDES_AE350_SOC_H_ #define __RISCV_ANDES_AE350_SOC_H_
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
/* Machine timer memory-mapped registers */ /* Machine timer memory-mapped registers */
#define RISCV_MTIME_BASE 0xE6000000 #define RISCV_MTIME_BASE 0xE6000000

View file

@ -5,7 +5,6 @@
#define __RISCV32_MIV_SOC_H_ #define __RISCV32_MIV_SOC_H_
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
/* GPIO Interrupts */ /* GPIO Interrupts */
#define MIV_GPIO_0_IRQ (0) #define MIV_GPIO_0_IRQ (0)

View file

@ -8,7 +8,6 @@
#define RISCV_NEORV32_SOC_H #define RISCV_NEORV32_SOC_H
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
/* Machine System Timer (MTIME) registers */ /* Machine System Timer (MTIME) registers */
#define RISCV_MTIME_BASE 0xffffff90U #define RISCV_MTIME_BASE 0xffffff90U

View file

@ -12,7 +12,6 @@
#define __RISCV_SIFIVE_FREEDOM_SOC_H_ #define __RISCV_SIFIVE_FREEDOM_SOC_H_
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
#if defined(CONFIG_SOC_RISCV_SIFIVE_FREEDOM) #if defined(CONFIG_SOC_RISCV_SIFIVE_FREEDOM)

View file

@ -8,7 +8,6 @@
#define __RISCV_VIRT_SOC_H_ #define __RISCV_VIRT_SOC_H_
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
#define RISCV_MTIME_BASE 0x0200BFF8 #define RISCV_MTIME_BASE 0x0200BFF8
#define RISCV_MTIMECMP_BASE 0x02004000 #define RISCV_MTIMECMP_BASE 0x02004000

View file

@ -8,7 +8,6 @@
#define RISCV_TELINK_B91_SOC_H #define RISCV_TELINK_B91_SOC_H
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
/* Machine timer memory-mapped registers */ /* Machine timer memory-mapped registers */
#define RISCV_MTIME_BASE 0xE6000000 #define RISCV_MTIME_BASE 0xE6000000

View file

@ -8,7 +8,6 @@
#define __RISCV_VIRT_SOC_H_ #define __RISCV_VIRT_SOC_H_
#include <soc_common.h> #include <soc_common.h>
#include <devicetree.h>
#define SIFIVE_SYSCON_TEST 0x00100000 #define SIFIVE_SYSCON_TEST 0x00100000
#define RISCV_MTIME_BASE 0x0200BFF8 #define RISCV_MTIME_BASE 0x0200BFF8