Kconfig 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237
  1. menu "DFS: device virtual file system"
  2. config RT_USING_DFS
  3. bool "DFS: device virtual file system"
  4. select RT_USING_MUTEX
  5. default y
  6. help
  7. The device file system is a light weight virtual file system.
  8. if RT_USING_DFS
  9. config DFS_USING_POSIX
  10. bool "Using posix-like functions, open/read/write/close"
  11. default y
  12. config DFS_USING_WORKDIR
  13. bool "Using working directory"
  14. default y
  15. if RT_USING_DFS_V1
  16. config RT_USING_DFS_MNTTABLE
  17. bool "Using mount table for file system"
  18. default n
  19. help
  20. User can use mount table for automatically mount, for example:
  21. const struct dfs_mount_tbl mount_table[] =
  22. {
  23. {"flash0", "/", "elm", 0, 0},
  24. {0}
  25. };
  26. The mount_table must be terminated with NULL.
  27. endif
  28. config DFS_FD_MAX
  29. int "The maximal number of opened files"
  30. default 16
  31. choice
  32. prompt "The version of DFS"
  33. default RT_USING_DFS_V1
  34. default RT_USING_DFS_V2 if RT_USING_SMART
  35. config RT_USING_DFS_V1
  36. bool "DFS v1.0"
  37. config RT_USING_DFS_V2
  38. bool "DFS v2.0"
  39. endchoice
  40. if RT_USING_DFS_V1
  41. config DFS_FILESYSTEMS_MAX
  42. int "The maximal number of mounted file system"
  43. default 4
  44. config DFS_FILESYSTEM_TYPES_MAX
  45. int "The maximal number of file system type"
  46. default 4
  47. endif
  48. config RT_USING_DFS_ELMFAT
  49. bool "Enable elm-chan fatfs"
  50. default n
  51. help
  52. FatFs is a generic FAT/exFAT file system module for small embedded systems.
  53. if RT_USING_DFS_ELMFAT
  54. menu "elm-chan's FatFs, Generic FAT Filesystem Module"
  55. config RT_DFS_ELM_CODE_PAGE
  56. int "OEM code page"
  57. default 437
  58. config RT_DFS_ELM_WORD_ACCESS
  59. bool "Using RT_DFS_ELM_WORD_ACCESS"
  60. default y
  61. choice
  62. prompt "Support long file name"
  63. default RT_DFS_ELM_USE_LFN_3
  64. config RT_DFS_ELM_USE_LFN_0
  65. bool "0: LFN disable"
  66. config RT_DFS_ELM_USE_LFN_1
  67. bool "1: LFN with static LFN working buffer"
  68. config RT_DFS_ELM_USE_LFN_2
  69. bool "2: LFN with dynamic LFN working buffer on the stack"
  70. config RT_DFS_ELM_USE_LFN_3
  71. bool "3: LFN with dynamic LFN working buffer on the heap"
  72. endchoice
  73. config RT_DFS_ELM_USE_LFN
  74. int
  75. default 0 if RT_DFS_ELM_USE_LFN_0
  76. default 1 if RT_DFS_ELM_USE_LFN_1
  77. default 2 if RT_DFS_ELM_USE_LFN_2
  78. default 3 if RT_DFS_ELM_USE_LFN_3
  79. choice
  80. prompt "Support unicode for long file name"
  81. default RT_DFS_ELM_LFN_UNICODE_0
  82. config RT_DFS_ELM_LFN_UNICODE_0
  83. bool "0: ANSI/OEM in current CP (TCHAR = char)"
  84. config RT_DFS_ELM_LFN_UNICODE_1
  85. bool "1: Unicode in UTF-16 (TCHAR = WCHAR)"
  86. config RT_DFS_ELM_LFN_UNICODE_2
  87. bool "2: Unicode in UTF-8 (TCHAR = char)"
  88. config RT_DFS_ELM_LFN_UNICODE_3
  89. bool "3: Unicode in UTF-32 (TCHAR = DWORD)"
  90. endchoice
  91. config RT_DFS_ELM_LFN_UNICODE
  92. int
  93. default 0 if RT_DFS_ELM_LFN_UNICODE_0
  94. default 1 if RT_DFS_ELM_LFN_UNICODE_1
  95. default 2 if RT_DFS_ELM_LFN_UNICODE_2
  96. default 3 if RT_DFS_ELM_LFN_UNICODE_3
  97. config RT_DFS_ELM_MAX_LFN
  98. int "Maximal size of file name length"
  99. range 12 255
  100. default 255
  101. config RT_DFS_ELM_DRIVES
  102. int "Number of volumes (logical drives) to be used."
  103. default 2
  104. config RT_DFS_ELM_MAX_SECTOR_SIZE
  105. int "Maximum sector size to be handled."
  106. default 512
  107. help
  108. If you use some spi nor flash for fatfs, please set this the erase sector size, for example 4096.
  109. config RT_DFS_ELM_USE_ERASE
  110. bool "Enable sector erase feature"
  111. default n
  112. config RT_DFS_ELM_REENTRANT
  113. bool "Enable the reentrancy (thread safe) of the FatFs module"
  114. default y
  115. config RT_DFS_ELM_MUTEX_TIMEOUT
  116. int "Timeout of thread-safe protection mutex"
  117. range 0 1000000
  118. default 3000
  119. depends on RT_DFS_ELM_REENTRANT
  120. config RT_DFS_ELM_USE_EXFAT
  121. bool "Enable RT_DFS_ELM_USE_EXFAT"
  122. default n
  123. depends on RT_DFS_ELM_USE_LFN >= 1
  124. endmenu
  125. endif
  126. config RT_USING_DFS_DEVFS
  127. bool "Using devfs for device objects"
  128. default y
  129. config RT_USING_DFS_ROMFS
  130. bool "Enable ReadOnly file system on flash"
  131. default n
  132. config RT_USING_DFS_CROMFS
  133. bool "Enable ReadOnly compressed file system on flash"
  134. default n
  135. # select PKG_USING_ZLIB
  136. if RT_USING_DFS_V1
  137. config RT_USING_DFS_RAMFS
  138. bool "Enable RAM file system"
  139. select RT_USING_MEMHEAP
  140. default n
  141. endif
  142. config RT_USING_DFS_TMPFS
  143. bool "Enable TMP file system"
  144. default n
  145. config RT_USING_DFS_MQUEUE
  146. bool "Enable MQUEUE file system"
  147. select RT_USING_DEV_BUS
  148. default n
  149. if RT_USING_DFS_V1
  150. config RT_USING_DFS_NFS
  151. bool "Using NFS v3 client file system"
  152. depends on RT_USING_LWIP
  153. default n
  154. if RT_USING_DFS_NFS
  155. config RT_NFS_HOST_EXPORT
  156. string "NFSv3 host export"
  157. default "192.168.1.5:/"
  158. endif
  159. endif
  160. if RT_USING_DFS_V2
  161. config RT_USING_PAGECACHE
  162. bool "Enable page cache"
  163. default n
  164. if RT_USING_PAGECACHE
  165. menu "page cache config"
  166. config RT_PAGECACHE_COUNT
  167. int "page cache max total pages."
  168. default 4096
  169. config RT_PAGECACHE_ASPACE_COUNT
  170. int "aspace max active pages."
  171. default 1024
  172. config RT_PAGECACHE_PRELOAD
  173. int "max pre load pages."
  174. default 4
  175. config RT_PAGECACHE_HASH_NR
  176. int "page cache hash size."
  177. default 1024
  178. config RT_PAGECACHE_GC_WORK_LEVEL
  179. int "page cache gc work trigger min percentage, default 90%."
  180. default 90
  181. config RT_PAGECACHE_GC_STOP_LEVEL
  182. int "page cache gc to min percentage, default 70%."
  183. default 70
  184. endmenu
  185. endif
  186. endif
  187. endif
  188. endmenu