1# Microchip MEC172X MCU core series
2
3# Copyright (c) 2021 Microchip Technology Inc.
4# SPDX-License-Identifier: Apache-2.0
5
6config SOC_SERIES_MEC172X
7	select ARM
8	select CPU_CORTEX_M4
9	select CPU_CORTEX_M_HAS_DWT
10	select CPU_HAS_FPU
11	select CPU_HAS_ARM_MPU
12	select HAS_SWO
13	select HAS_PM
14	select SOC_EARLY_INIT_HOOK
15
16if SOC_SERIES_MEC172X
17
18config RTOS_TIMER
19	bool "MEC172x RTOS Timer(32KHz) as kernel timer"
20
21choice
22	prompt "MEC172x debug interface general configuration"
23	default SOC_MEC172X_DEBUG_WITHOUT_TRACING
24	depends on SOC_SERIES_MEC172X
25	help
26	  Select Debug SoC interface support for MEC172X SoC family
27
28	config SOC_MEC172X_DEBUG_DISABLED
29		bool "Disable debug support"
30		help
31		  Debug port is disabled, JTAG/SWD cannot be enabled. JTAG_RST#
32		  pin is ignored. All other JTAG pins can be used as GPIOs
33		  or other non-JTAG alternate functions.
34
35	config SOC_MEC172X_DEBUG_WITHOUT_TRACING
36		bool "Debug support via Serial wire debug"
37		help
38		  JTAG port in SWD mode. I2C09 and ADC00-03 can be used.
39
40	config SOC_MEC172X_DEBUG_AND_TRACING
41		bool "Debug support via Serial wire debug with tracing enabled"
42		help
43		  JTAG port is enabled in SWD mode. Refer to tracing options
44		  to see if ADC00-03 can be used or not.
45endchoice
46
47choice
48	prompt "MEC172X debug interface trace configuration"
49	default SOC_MEC172X_DEBUG_AND_ETM_TRACING
50	depends on SOC_MEC172X_DEBUG_AND_TRACING
51	help
52	  Select tracing mode for debug interface
53
54	config SOC_MEC172X_DEBUG_AND_ETM_TRACING
55		bool "Debug support via Serial wire debug"
56		help
57		  JTAG port in SWD mode and ETM as tracing method.
58		  I2C09 can be used, but ADC00-03 cannot.
59
60	config SOC_MEC172X_DEBUG_AND_SWV_TRACING
61		bool "debug support via Serial Wire Debug and Viewer"
62		help
63		  JTAG port in SWD mode and SWV as tracing method.
64		  I2C09 cannot be used. ADC00-03 can be used.
65endchoice
66
67# GPIO initialization depends on ECIA initialization, which happen at
68# CONFIG_KERNEL_INIT_PRIORITY_DEFAULT, so GPIO_INIT_PRIORITY needs to be
69# higher than that.
70if GPIO
71
72config GPIO_INIT_PRIORITY
73	default 41
74
75endif # GPIO
76
77endif # SOC_SERIES_MEC172X
78