Skip to content

Commit 3b87828

Browse files
dleach02nordicjm
authored andcommitted
soc: nxp: convert LPC SOC family to hardware model V2
Move LPC family to HWMv2 Signed-off-by: David Leach <[email protected]> soc: nxp: convert LPC SOC family to hardware model V2 Move LPC family to HWMv2 Signed-off-by: David Leach <[email protected]>
1 parent 93c935f commit 3b87828

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+517
-543
lines changed

soc/nxp/lpc/Kconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Copyright 2017,2024 NXP
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config SOC_FAMILY_LPC
5+
select HAS_SEGGER_RTT if ZEPHYR_SEGGER_MODULE
6+
select CLOCK_CONTROL
7+
select ARM
8+
9+
if SOC_FAMILY_LPC
10+
rsource "*/Kconfig"
11+
12+
endif # SOC_FAMILY_LPC

soc/nxp/lpc/Kconfig.defconfig

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Copyright 2017,2024 NXP
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
if SOC_FAMILY_LPC
5+
6+
config SERIAL_INIT_PRIORITY
7+
default 55 if SERIAL
8+
9+
config BUILD_WITH_TFM
10+
default y if TRUSTED_EXECUTION_NONSECURE
11+
12+
rsource "*/Kconfig.defconfig"
13+
14+
endif # SOC_FAMILY_LPC

soc/nxp/lpc/Kconfig.soc

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Copyright 2017,2024 NXP
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config SOC_FAMILY_LPC
5+
bool
6+
7+
config SOC_FAMILY
8+
default "lpc" if SOC_FAMILY_LPC
9+
10+
rsource "*/Kconfig.soc"
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
#
2-
# Copyright (c) 2017, NXP
2+
# Copyright 2017, 2024 NXP
33
#
44
# SPDX-License-Identifier: Apache-2.0
55
#
66

7+
zephyr_include_directories(.)
8+
79
set(SOC_LINKER_SCRIPT ${ZEPHYR_BASE}/include/zephyr/arch/arm/cortex_m/scripts/linker.ld CACHE INTERNAL "")
Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
11
# LPC LPC11U6X MCU line
2-
2+
#
33
# Copyright (c) 2020, Seagate
4+
# Copyright 2024 NXP
5+
#
46
# SPDX-License-Identifier: Apache-2.0
7+
#
58

69
config SOC_SERIES_LPC11U6X
7-
bool "LPC LPC11U6X Series MCU"
810
select ARM
911
select CPU_CORTEX_M0PLUS
1012
select CPU_CORTEX_M_HAS_SYSTICK
11-
select SOC_FAMILY_LPC
1213
select PINCTRL
1314
select CLOCK_CONTROL
14-
help
15-
Enable support for LPC LPC11U6X MCU series

soc/soc_legacy/arm/nxp_lpc/lpc11u6x/Kconfig.defconfig.series renamed to soc/nxp/lpc/lpc11u6x/Kconfig.defconfig

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
1-
# LPC11U6X series configuration options
2-
1+
# LPC LPC11U6X MCU line
2+
#
33
# Copyright (c) 2020, Seagate
4+
# Copyright 2024 NXP
5+
#
46
# SPDX-License-Identifier: Apache-2.0
7+
#
58

69
if SOC_SERIES_LPC11U6X
710

8-
source "soc/soc_legacy/arm/nxp_lpc/lpc11u6x/Kconfig.defconfig.lp*"
9-
10-
config SOC_SERIES
11-
default "lpc11u6x"
12-
1311
config NUM_IRQS
1412
# must be >= the highest interrupt number used
1513
default 40

soc/soc_legacy/arm/nxp_lpc/lpc11u6x/Kconfig.soc renamed to soc/nxp/lpc/lpc11u6x/Kconfig.soc

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,34 @@
1-
# LPC LPC11U6x MCU line
1+
# NXP LPC11U6x series
22

3-
# Copyright (c) 2020, Seagate
3+
# Copyright 2024 NXP
4+
5+
#
46
# SPDX-License-Identifier: Apache-2.0
7+
#
8+
9+
config SOC_SERIES_LPC11U6X
10+
bool
11+
select SOC_FAMILY_LPC
512

6-
choice
7-
prompt "LPC LPC11U6X MCU Selection"
8-
depends on SOC_SERIES_LPC11U6X
13+
config SOC_SERIES
14+
default "lpc11u6x" if SOC_SERIES_LPC11U6X
915

1016
config SOC_LPC11U68
11-
bool "SOC_LPC11U68"
17+
bool
18+
select SOC_SERIES_LPC11U6X
1219

1320
config SOC_LPC11U67
14-
bool "SOC_LPC11U67"
21+
bool
22+
select SOC_SERIES_LPC11U6X
1523

1624
config SOC_LPC11U66
17-
bool "SOC_LPC11U66"
18-
19-
endchoice
25+
bool
26+
select SOC_SERIES_LPC11U6X
2027

21-
if SOC_SERIES_LPC11U6X
28+
config SOC
29+
default "lpc11u66" if SOC_LPC11U66
30+
default "lpc11u67" if SOC_LPC11U67
31+
default "lpc11u68" if SOC_LPC11U68
2232

2333
config SOC_PART_NUMBER_LPC11U66JBD48
2434
bool
@@ -35,18 +45,11 @@ config SOC_PART_NUMBER_LPC11U68JBD64
3545
config SOC_PART_NUMBER_LPC11U68JBD100
3646
bool
3747

38-
config SOC_PART_NUMBER_LPC11U6X
39-
string
48+
config SOC_PART_NUMBER
4049
default "LPC11U66JBD48" if SOC_PART_NUMBER_LPC11U66JBD48
4150
default "LPC11U67JBD48" if SOC_PART_NUMBER_LPC11U67JBD48
4251
default "LPC11U67JBD64" if SOC_PART_NUMBER_LPC11U67JBD64
4352
default "LPC11U67JBD100" if SOC_PART_NUMBER_LPC11U67JBD100
4453
default "LPC11U68JBD48" if SOC_PART_NUMBER_LPC11U68JBD48
4554
default "LPC11U68JBD64" if SOC_PART_NUMBER_LPC11U68JBD64
4655
default "LPC11U68JBD100" if SOC_PART_NUMBER_LPC11U68JBD100
47-
48-
help
49-
This string holds the full part number of the SoC. It is a hidden
50-
option that you should not set directly. The part number selection
51-
choice defines the default value for this string.
52-
endif # SOC_SERIES_LPC11U6X

0 commit comments

Comments
 (0)