Kconfig 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360
  1. menu "RT-Thread Kernel"
  2. config RT_NAME_MAX
  3. int "The maximal size of kernel object name"
  4. range 2 32
  5. default 8
  6. help
  7. Each kernel object, such as thread, timer, semaphore etc, has a name,
  8. the RT_NAME_MAX is the maximal size of this object name.
  9. config RT_USING_ARCH_DATA_TYPE
  10. bool "Use the data types defined in ARCH_CPU"
  11. default n
  12. help
  13. For the data type like, `rt_uint8/int8_t, rt_uint16/int16_t, rt_uint32/int32_t`,
  14. BSP can define these basic data types in ARCH_CPU level.
  15. Please re-define these data types in rtconfig_project.h file.
  16. config RT_USING_SMP
  17. bool "Enable SMP(Symmetric multiprocessing)"
  18. default n
  19. help
  20. This option should be selected by machines which have an SMP-
  21. capable CPU.
  22. The only effect of this option is to make the SMP-related
  23. options available to the user for configuration.
  24. config RT_CPUS_NR
  25. int "Number of CPUs"
  26. default 2
  27. depends on RT_USING_SMP
  28. help
  29. Number of CPUs in the system
  30. config RT_ALIGN_SIZE
  31. int "Alignment size for CPU architecture data access"
  32. default 4
  33. help
  34. Alignment size for CPU architecture data access
  35. choice
  36. prompt "The maximal level value of priority of thread"
  37. default RT_THREAD_PRIORITY_32
  38. config RT_THREAD_PRIORITY_8
  39. bool "8"
  40. config RT_THREAD_PRIORITY_32
  41. bool "32"
  42. config RT_THREAD_PRIORITY_256
  43. bool "256"
  44. endchoice
  45. config RT_THREAD_PRIORITY_MAX
  46. int
  47. default 8 if RT_THREAD_PRIORITY_8
  48. default 32 if RT_THREAD_PRIORITY_32
  49. default 256 if RT_THREAD_PRIORITY_256
  50. config RT_TICK_PER_SECOND
  51. int "Tick frequency, Hz"
  52. range 10 1000
  53. default 100
  54. help
  55. System's tick frequency, Hz.
  56. config RT_USING_OVERFLOW_CHECK
  57. bool "Using stack overflow checking"
  58. default y
  59. help
  60. Enable thread stack overflow checking. The stack overflow is checking when
  61. each thread switch.
  62. config RT_USING_HOOK
  63. bool "Enable system hook"
  64. default y
  65. select RT_USING_IDLE_HOOK
  66. help
  67. Enable the hook function when system running, such as idle thread hook,
  68. thread context switch etc.
  69. config RT_USING_IDLE_HOOK
  70. bool "Enable IDLE Task hook"
  71. default y if RT_USING_HOOK
  72. if RT_USING_IDLE_HOOK
  73. config RT_IDLE_HOOK_LIST_SIZE
  74. int "The max size of idle hook list"
  75. default 4
  76. range 1 16
  77. help
  78. The system has a hook list. This is the hook list size.
  79. endif
  80. config IDLE_THREAD_STACK_SIZE
  81. int "The stack size of idle thread"
  82. default 256
  83. config RT_USING_TIMER_SOFT
  84. bool "Enable software timer with a timer thread"
  85. default y
  86. help
  87. the timeout function context of soft-timer is under a high priority timer
  88. thread.
  89. if RT_USING_TIMER_SOFT
  90. config RT_TIMER_THREAD_PRIO
  91. int "The priority level value of timer thread"
  92. default 4
  93. config RT_TIMER_THREAD_STACK_SIZE
  94. int "The stack size of timer thread"
  95. default 512
  96. endif
  97. menu "kservice optimization"
  98. config RT_KSERVICE_USING_STDLIB
  99. bool "Enable kservice to use standard C library"
  100. default n
  101. config RT_KSERVICE_USING_TINY_SIZE
  102. bool "Enable kservice to use tiny size"
  103. default n
  104. endmenu
  105. menuconfig RT_DEBUG
  106. bool "Enable debugging features"
  107. default y
  108. if RT_DEBUG
  109. config RT_DEBUG_COLOR
  110. bool "Enable color debugging log"
  111. default n
  112. config RT_DEBUG_INIT_CONFIG
  113. bool "Enable debugging of components initialization"
  114. default n
  115. config RT_DEBUG_INIT
  116. int
  117. default 1 if RT_DEBUG_INIT_CONFIG
  118. config RT_DEBUG_THREAD_CONFIG
  119. bool "Enable debugging of Thread State Changes"
  120. default n
  121. config RT_DEBUG_THREAD
  122. int
  123. default 1 if RT_DEBUG_THREAD_CONFIG
  124. config RT_DEBUG_SCHEDULER_CONFIG
  125. bool "Enable debugging of Scheduler"
  126. default n
  127. config RT_DEBUG_SCHEDULER
  128. int
  129. default 1 if RT_DEBUG_SCHEDULER_CONFIG
  130. config RT_DEBUG_IPC_CONFIG
  131. bool "Enable debugging of IPC"
  132. default n
  133. config RT_DEBUG_IPC
  134. int
  135. default 1 if RT_DEBUG_IPC_CONFIG
  136. config RT_DEBUG_TIMER_CONFIG
  137. bool "Enable debugging of Timer"
  138. default n
  139. config RT_DEBUG_TIMER
  140. int
  141. default 1 if RT_DEBUG_TIMER_CONFIG
  142. config RT_DEBUG_IRQ_CONFIG
  143. bool "Enable debugging of IRQ(Interrupt Request)"
  144. default n
  145. config RT_DEBUG_IRQ
  146. int
  147. default 1 if RT_DEBUG_IRQ_CONFIG
  148. config RT_DEBUG_MEM_CONFIG
  149. bool "Enable debugging of Small Memory Algorithm"
  150. default n
  151. config RT_DEBUG_MEM
  152. int
  153. default 1 if RT_DEBUG_MEM_CONFIG
  154. config RT_DEBUG_SLAB_CONFIG
  155. bool "Enable debugging of SLAB Memory Algorithm"
  156. default n
  157. config RT_DEBUG_SLAB
  158. int
  159. default 1 if RT_DEBUG_SLAB_CONFIG
  160. config RT_DEBUG_MEMHEAP_CONFIG
  161. bool "Enable debugging of Memory Heap Algorithm"
  162. default n
  163. config RT_DEBUG_MEMHEAP
  164. int
  165. default 1 if RT_DEBUG_MEMHEAP_CONFIG
  166. config RT_DEBUG_MODULE_CONFIG
  167. bool "Enable debugging of Application Module"
  168. default n
  169. config RT_DEBUG_MODULE
  170. int
  171. default 1 if RT_DEBUG_MODULE_CONFIG
  172. endif
  173. menu "Inter-Thread communication"
  174. config RT_USING_SEMAPHORE
  175. bool "Enable semaphore"
  176. default y
  177. config RT_USING_MUTEX
  178. bool "Enable mutex"
  179. default y
  180. config RT_USING_EVENT
  181. bool "Enable event flag"
  182. default y
  183. config RT_USING_MAILBOX
  184. bool "Enable mailbox"
  185. default y
  186. config RT_USING_MESSAGEQUEUE
  187. bool "Enable message queue"
  188. default y
  189. config RT_USING_SIGNALS
  190. bool "Enable signals"
  191. select RT_USING_MEMPOOL
  192. default n
  193. help
  194. A signal is an asynchronous notification sent to a specific thread
  195. in order to notify it of an event that occurred.
  196. endmenu
  197. menu "Memory Management"
  198. config RT_USING_MEMPOOL
  199. bool "Using memory pool"
  200. default y
  201. help
  202. Using static memory fixed partition
  203. config RT_USING_MEMHEAP
  204. bool "Using memory heap object"
  205. default n
  206. help
  207. Using memory heap object to manage dynamic memory heap.
  208. choice
  209. prompt "Dynamic Memory Management"
  210. default RT_USING_SMALL_MEM
  211. config RT_USING_NOHEAP
  212. bool "Disable Heap"
  213. config RT_USING_SMALL_MEM
  214. bool "Small Memory Algorithm"
  215. config RT_USING_SLAB
  216. bool "SLAB Algorithm for large memory"
  217. if RT_USING_MEMHEAP
  218. config RT_USING_MEMHEAP_AS_HEAP
  219. bool "Use all of memheap objects as heap"
  220. endif
  221. config RT_USING_USERHEAP
  222. bool "Use user heap"
  223. help
  224. If this option is selected, please implement these functions:
  225. rt_malloc(), rt_malloc_sethook()
  226. rt_free(), rt_free_sethook()
  227. rt_calloc(), rt_realloc()
  228. rt_system_heap_init()
  229. And if FinSH is used at the same time, please implement list_mem()
  230. endchoice
  231. config RT_USING_MEMTRACE
  232. bool "Enable memory trace"
  233. default n
  234. help
  235. When enable RT_USING_MEMTRACE with shell, developer can call cmd:
  236. 1. memtrace
  237. to dump memory block information.
  238. 2. memcheck
  239. to check memory block to avoid memory overwritten.
  240. And developer also can call memcheck() in each of scheduling
  241. to check memory block to find which thread has wrongly modified
  242. memory.
  243. config RT_USING_HEAP
  244. bool
  245. default n if RT_USING_NOHEAP
  246. default y if RT_USING_SMALL_MEM
  247. default y if RT_USING_SLAB
  248. default y if RT_USING_MEMHEAP_AS_HEAP
  249. default y if RT_USING_USERHEAP
  250. endmenu
  251. menu "Kernel Device Object"
  252. config RT_USING_DEVICE
  253. bool "Using device object"
  254. default y
  255. config RT_USING_DEVICE_OPS
  256. bool "Using ops for each device object"
  257. default n
  258. config RT_USING_INTERRUPT_INFO
  259. bool "Enable additional interrupt trace information"
  260. default n
  261. help
  262. Add name and counter information for interrupt trace.
  263. config RT_USING_CONSOLE
  264. bool "Using console for rt_kprintf"
  265. default y
  266. if RT_USING_CONSOLE
  267. config RT_CONSOLEBUF_SIZE
  268. int "the buffer size for console log printf"
  269. default 128
  270. config RT_CONSOLE_DEVICE_NAME
  271. string "the device name for console"
  272. default "uart"
  273. endif
  274. endmenu
  275. config RT_VER_NUM
  276. hex
  277. default 0x40004
  278. help
  279. RT-Thread version number
  280. endmenu