soc: arm: do not include kernel headers in soc.h
We shall not include core kernel headers in soc.h header of ARM SoCs. We should try to only include the vendor headers and auto-generated board header from DTS. This commit implements this policy for the SoCs, whose builds have shown to fail due to header inclusion cycles. Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
This commit is contained in:
parent
cfa2fb278f
commit
affddef4cf
6 changed files with 24 additions and 30 deletions
|
@ -12,6 +12,8 @@
|
|||
#ifndef _ARM_BEETLE_SOC_H_
|
||||
#define _ARM_BEETLE_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
#include "CMSDK_BEETLE.h"
|
||||
#endif
|
||||
|
@ -93,11 +95,8 @@
|
|||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#include "soc_pins.h"
|
||||
#include "soc_power.h"
|
||||
|
|
|
@ -13,6 +13,8 @@
|
|||
#ifndef _ATMEL_SAME70_SOC_H_
|
||||
#define _ATMEL_SAME70_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
#define DONT_USE_CMSIS_INIT
|
||||
|
@ -64,11 +66,8 @@
|
|||
#include "../common/soc_pmc.h"
|
||||
#include "../common/soc_gpio.h"
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#endif /* _ASMLANGUAGE */
|
||||
|
||||
|
|
|
@ -18,15 +18,14 @@
|
|||
#ifndef _STM32F4_SOC_H_
|
||||
#define _STM32F4_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
#include <stm32f4xx.h>
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#ifdef CONFIG_EXTI_STM32
|
||||
#include <stm32f4xx_ll_exti.h>
|
||||
|
|
|
@ -17,15 +17,14 @@
|
|||
#ifndef _STM32F7_SOC_H_
|
||||
#define _STM32F7_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
#include <stm32f7xx.h>
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#ifdef CONFIG_EXTI_STM32
|
||||
#include <stm32f7xx_ll_exti.h>
|
||||
|
|
|
@ -19,16 +19,15 @@
|
|||
#ifndef _STM32L4X_SOC_H_
|
||||
#define _STM32L4X_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
#include <autoconf.h>
|
||||
#include <stm32l4xx.h>
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#ifdef CONFIG_EXTI_STM32
|
||||
#include <stm32l4xx_ll_exti.h>
|
||||
|
|
|
@ -17,15 +17,14 @@
|
|||
#ifndef _STM32WBX_SOC_H_
|
||||
#define _STM32WBX_SOC_H_
|
||||
|
||||
#include <sys/util.h>
|
||||
|
||||
#ifndef _ASMLANGUAGE
|
||||
|
||||
#include <stm32wbxx.h>
|
||||
|
||||
/* ARM CMSIS definitions must be included before kernel_includes.h.
|
||||
* Therefore, it is essential to include kernel_includes.h after including
|
||||
* core SOC-specific headers.
|
||||
*/
|
||||
#include <kernel_includes.h>
|
||||
/* Add include for DTS generated information */
|
||||
#include <generated_dts_board.h>
|
||||
|
||||
#ifdef CONFIG_GPIO_STM32
|
||||
#include <stm32wbxx_ll_gpio.h>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue