From ddf13a32561c2cb6adaa1ab8c01316cfc81e172d Mon Sep 17 00:00:00 2001 From: Christian Taedcke Date: Thu, 26 Nov 2020 10:14:10 +0100 Subject: [PATCH] soc: arm: nxp: Add LPC55S28 support Add initial support for NXP LPC55S28. Signed-off-by: Christian Taedcke --- .../lpc55xxx/Kconfig.defconfig.lpc55S28 | 39 +++++++++++++++++++ soc/arm/nxp_lpc/lpc55xxx/Kconfig.soc | 17 ++++++++ soc/arm/nxp_lpc/lpc55xxx/soc.c | 3 +- 3 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 soc/arm/nxp_lpc/lpc55xxx/Kconfig.defconfig.lpc55S28 diff --git a/soc/arm/nxp_lpc/lpc55xxx/Kconfig.defconfig.lpc55S28 b/soc/arm/nxp_lpc/lpc55xxx/Kconfig.defconfig.lpc55S28 new file mode 100644 index 0000000000..a4bd0851be --- /dev/null +++ b/soc/arm/nxp_lpc/lpc55xxx/Kconfig.defconfig.lpc55S28 @@ -0,0 +1,39 @@ +# NXP LPC55S28 platform configuration options + +# Copyright (c) 2020 Lemonbeat GmbH +# SPDX-License-Identifier: Apache-2.0 + +if SOC_LPC55S28 + +config SOC + default "lpc55S28" + +config PINMUX_MCUX_LPC + default y + depends on PINMUX + +config GPIO_MCUX_LPC + default y + depends on GPIO + +config UART_MCUX_FLEXCOMM + default y + depends on SERIAL + +config SOC_FLASH_MCUX + default y + depends on FLASH + +config WDT_MCUX_WWDT + default y + depends on WATCHDOG + +config ADC_MCUX_LPADC + default y + depends on ADC + +config DMA_MCUX_LPC + default y + depends on DMA + +endif # SOC_LPC55S28 diff --git a/soc/arm/nxp_lpc/lpc55xxx/Kconfig.soc b/soc/arm/nxp_lpc/lpc55xxx/Kconfig.soc index 53eafb6c24..f2a3f0f1b3 100644 --- a/soc/arm/nxp_lpc/lpc55xxx/Kconfig.soc +++ b/soc/arm/nxp_lpc/lpc55xxx/Kconfig.soc @@ -18,6 +18,19 @@ config SOC_LPC55S16 select CLOCK_CONTROL select HAS_MCUX_IAP if !TRUSTED_EXECUTION_NONSECURE +config SOC_LPC55S28 + bool "SOC_LPC55S28 M33" + select CPU_CORTEX_M33 + select CPU_HAS_ARM_SAU + select CPU_HAS_ARM_MPU + select CPU_HAS_FPU + select ARMV8_M_DSP + select ARM_TRUSTZONE_M + select CLOCK_CONTROL + select HAS_MCUX_IAP + select HAS_MCUX_LPADC + select HAS_MCUX_LPC_DMA + config SOC_LPC55S69_CPU0 bool "SOC_LPC55S69 M33 [CPU 0]" select CPU_CORTEX_M33 @@ -42,6 +55,9 @@ if SOC_SERIES_LPC55XXX config SOC_PART_NUMBER_LPC55S16JBD100 bool +config SOC_PART_NUMBER_LPC55S28JBD100 + bool + config SOC_PART_NUMBER_LPC55S69JBD100 bool @@ -51,6 +67,7 @@ config SOC_PART_NUMBER_LPC55S69JET98 config SOC_PART_NUMBER_LPC55XXX string default "LPC55S16JBD100" if SOC_PART_NUMBER_LPC55S16JBD100 + default "LPC55S28JBD100" if SOC_PART_NUMBER_LPC55S28JBD100 default "LPC55S69JBD100" if SOC_PART_NUMBER_LPC55S69JBD100 default "LPC55S69JET98" if SOC_PART_NUMBER_LPC55S69JET98 diff --git a/soc/arm/nxp_lpc/lpc55xxx/soc.c b/soc/arm/nxp_lpc/lpc55xxx/soc.c index 1b3ab052bc..6ecfafb280 100644 --- a/soc/arm/nxp_lpc/lpc55xxx/soc.c +++ b/soc/arm/nxp_lpc/lpc55xxx/soc.c @@ -36,7 +36,8 @@ static ALWAYS_INLINE void clock_init(void) { -#if defined(CONFIG_SOC_LPC55S16) || defined(CONFIG_SOC_LPC55S69_CPU0) +#if defined(CONFIG_SOC_LPC55S16) || defined(CONFIG_SOC_LPC55S28) || \ + defined(CONFIG_SOC_LPC55S69_CPU0) /*!< Set up the clock sources */ /*!< Configure FRO192M */ /*!< Ensure FRO is on */