1# Copyright (c) 2018 Intel Corporation
2# SPDX-License-Identifier: Apache-2.0
3
4config CMSIS_RTOS_V2
5	bool "CMSIS RTOS v2 API"
6	depends on POLL
7	depends on THREAD_NAME
8	depends on THREAD_STACK_INFO
9	depends on THREAD_MONITOR
10	depends on INIT_STACKS
11	depends on NUM_PREEMPT_PRIORITIES >= 56
12	help
13	  This enables CMSIS RTOS v2 API support. This is an OS-integration
14	  layer which allows applications using CMSIS RTOS V2 APIs to build
15	  on Zephyr.
16
17if CMSIS_RTOS_V2
18config CMSIS_V2_THREAD_MAX_COUNT
19	int "Maximum thread count in CMSIS RTOS V2 application"
20	default 15
21	range 0 255
22	help
23	  Mention max number of threads in CMSIS RTOS V2 compliant application.
24	  There's a limitation on the number of threads due to memory
25	  related constraints.
26
27config CMSIS_V2_THREAD_DYNAMIC_MAX_COUNT
28	int "Maximum dynamic thread count in CMSIS RTOS V2 application"
29	default 0
30	range 0 255
31	help
32	  Mention max number of dynamic threads in CMSIS RTOS V2 compliant
33	  application. There's a limitation on the number of threads due to memory
34	  related constraints. Dynamic threads are a subset of all other CMSIS
35	  threads i.e. they also count towards that maximum too.
36
37config CMSIS_V2_THREAD_MAX_STACK_SIZE
38	int "Max stack size threads can be allocated in CMSIS RTOS V2 application"
39	default 4096 if COVERAGE_GCOV
40	default 512
41	help
42	  Mention max stack size threads can be allocated in CMSIS RTOS V2 application.
43
44config CMSIS_V2_THREAD_DYNAMIC_STACK_SIZE
45	int "Dynamic stack size threads are allocated in CMSIS RTOS V2 application"
46	default 4096 if COVERAGE_GCOV
47	default 512
48	help
49	  Mention dynamic stack size threads are allocated in CMSIS RTOS V2 application.
50
51config CMSIS_V2_TIMER_MAX_COUNT
52	int "Maximum timer count in CMSIS RTOS V2 application"
53	default 5
54	range 0 255
55	help
56	  Mention maximum number of timers in CMSIS RTOS V2 compliant application.
57
58config CMSIS_V2_MUTEX_MAX_COUNT
59	int "Maximum mutex count in CMSIS RTOS V2 application"
60	default 5
61	range 0 255
62	help
63	  Mention max number of mutexes in CMSIS RTOS V2 compliant application.
64
65config CMSIS_V2_SEMAPHORE_MAX_COUNT
66	int "Maximum semaphore count in CMSIS RTOS V2 application"
67	default 5
68	range 0 255
69	help
70	  Mention max number of semaphores in CMSIS RTOS V2 compliant application.
71
72config CMSIS_V2_MEM_SLAB_MAX_COUNT
73	int "Maximum mem slab count in CMSIS RTOS V2 application"
74	default 5
75	range 0 255
76	help
77	  Mention maximum number of memory slabs in CMSIS RTOS V2 compliant application.
78
79config CMSIS_V2_MEM_SLAB_MAX_DYNAMIC_SIZE
80	int "Maximum dynamic mem slab/pool size in CMSIS RTOS V2 application"
81	default 0
82	help
83	  Mention maximum dynamic size of memory slabs/pools in CMSIS RTOS V2 compliant application.
84
85config CMSIS_V2_MSGQ_MAX_COUNT
86	int "Maximum message queue count in CMSIS RTOS V2 application"
87	default 5
88	range 0 255
89	help
90	  Mention maximum number of message queues in CMSIS RTOS V2 compliant application.
91
92config CMSIS_V2_MSGQ_MAX_DYNAMIC_SIZE
93	int "Maximum dynamic message queue size in CMSIS RTOS V2 application"
94	default 0
95	help
96	  Mention maximum dynamic size of message queues in CMSIS RTOS V2 compliant application.
97
98config CMSIS_V2_EVT_FLAGS_MAX_COUNT
99	int "Maximum event flags count in CMSIS RTOS V2 application"
100	default 5
101	range 0 255
102	help
103	  Mention maximum number of event flags in CMSIS RTOS V2 compliant application.
104endif
105