Kconfig 9.4 KB

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