Kconfig 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264
  1. menu "Memory management options"
  2. config QUICKLIST
  3. def_bool y
  4. config MMU
  5. bool "Support for memory management hardware"
  6. depends on !CPU_SH2
  7. default y
  8. help
  9. Some SH processors (such as SH-2/SH-2A) lack an MMU. In order to
  10. boot on these systems, this option must not be set.
  11. On other systems (such as the SH-3 and 4) where an MMU exists,
  12. turning this off will boot the kernel on these machines with the
  13. MMU implicitly switched off.
  14. config PAGE_OFFSET
  15. hex
  16. default "0x80000000" if MMU && SUPERH32
  17. default "0x20000000" if MMU && SUPERH64
  18. default "0x00000000"
  19. config MEMORY_START
  20. hex "Physical memory start address"
  21. default "0x08000000"
  22. ---help---
  23. Computers built with Hitachi SuperH processors always
  24. map the ROM starting at address zero. But the processor
  25. does not specify the range that RAM takes.
  26. The physical memory (RAM) start address will be automatically
  27. set to 08000000. Other platforms, such as the Solution Engine
  28. boards typically map RAM at 0C000000.
  29. Tweak this only when porting to a new machine which does not
  30. already have a defconfig. Changing it from the known correct
  31. value on any of the known systems will only lead to disaster.
  32. config MEMORY_SIZE
  33. hex "Physical memory size"
  34. default "0x04000000"
  35. help
  36. This sets the default memory size assumed by your SH kernel. It can
  37. be overridden as normal by the 'mem=' argument on the kernel command
  38. line. If unsure, consult your board specifications or just leave it
  39. as 0x04000000 which was the default value before this became
  40. configurable.
  41. # Physical addressing modes
  42. config 29BIT
  43. def_bool !32BIT
  44. depends on SUPERH32
  45. config 32BIT
  46. bool
  47. default y if CPU_SH5
  48. config PMB
  49. bool "Support 32-bit physical addressing through PMB"
  50. depends on MMU && EXPERIMENTAL && (CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785)
  51. select 32BIT
  52. default y
  53. help
  54. If you say Y here, physical addressing will be extended to
  55. 32-bits through the SH-4A PMB. If this is not set, legacy
  56. 29-bit physical addressing will be used.
  57. config X2TLB
  58. bool "Enable extended TLB mode"
  59. depends on (CPU_SHX2 || CPU_SHX3) && MMU && EXPERIMENTAL
  60. help
  61. Selecting this option will enable the extended mode of the SH-X2
  62. TLB. For legacy SH-X behaviour and interoperability, say N. For
  63. all of the fun new features and a willingless to submit bug reports,
  64. say Y.
  65. config VSYSCALL
  66. bool "Support vsyscall page"
  67. depends on MMU && (CPU_SH3 || CPU_SH4)
  68. default y
  69. help
  70. This will enable support for the kernel mapping a vDSO page
  71. in process space, and subsequently handing down the entry point
  72. to the libc through the ELF auxiliary vector.
  73. From the kernel side this is used for the signal trampoline.
  74. For systems with an MMU that can afford to give up a page,
  75. (the default value) say Y.
  76. config NUMA
  77. bool "Non Uniform Memory Access (NUMA) Support"
  78. depends on MMU && SYS_SUPPORTS_NUMA && EXPERIMENTAL
  79. default n
  80. help
  81. Some SH systems have many various memories scattered around
  82. the address space, each with varying latencies. This enables
  83. support for these blocks by binding them to nodes and allowing
  84. memory policies to be used for prioritizing and controlling
  85. allocation behaviour.
  86. config NODES_SHIFT
  87. int
  88. default "3" if CPU_SUBTYPE_SHX3
  89. default "1"
  90. depends on NEED_MULTIPLE_NODES
  91. config ARCH_FLATMEM_ENABLE
  92. def_bool y
  93. depends on !NUMA
  94. config ARCH_SPARSEMEM_ENABLE
  95. def_bool y
  96. select SPARSEMEM_STATIC
  97. config ARCH_SPARSEMEM_DEFAULT
  98. def_bool y
  99. config MAX_ACTIVE_REGIONS
  100. int
  101. default "6" if (CPU_SUBTYPE_SHX3 && SPARSEMEM)
  102. default "2" if SPARSEMEM && (CPU_SUBTYPE_SH7722 || \
  103. CPU_SUBTYPE_SH7785)
  104. default "1"
  105. config ARCH_POPULATES_NODE_MAP
  106. def_bool y
  107. config ARCH_SELECT_MEMORY_MODEL
  108. def_bool y
  109. config ARCH_ENABLE_MEMORY_HOTPLUG
  110. def_bool y
  111. depends on SPARSEMEM && MMU
  112. config ARCH_ENABLE_MEMORY_HOTREMOVE
  113. def_bool y
  114. depends on SPARSEMEM && MMU
  115. config ARCH_MEMORY_PROBE
  116. def_bool y
  117. depends on MEMORY_HOTPLUG
  118. choice
  119. prompt "Kernel page size"
  120. default PAGE_SIZE_8KB if X2TLB
  121. default PAGE_SIZE_4KB
  122. config PAGE_SIZE_4KB
  123. bool "4kB"
  124. depends on !MMU || !X2TLB
  125. help
  126. This is the default page size used by all SuperH CPUs.
  127. config PAGE_SIZE_8KB
  128. bool "8kB"
  129. depends on !MMU || X2TLB
  130. help
  131. This enables 8kB pages as supported by SH-X2 and later MMUs.
  132. config PAGE_SIZE_16KB
  133. bool "16kB"
  134. depends on !MMU
  135. help
  136. This enables 16kB pages on MMU-less SH systems.
  137. config PAGE_SIZE_64KB
  138. bool "64kB"
  139. depends on !MMU || CPU_SH4 || CPU_SH5
  140. help
  141. This enables support for 64kB pages, possible on all SH-4
  142. CPUs and later.
  143. endchoice
  144. config ENTRY_OFFSET
  145. hex
  146. default "0x00001000" if PAGE_SIZE_4KB
  147. default "0x00002000" if PAGE_SIZE_8KB
  148. default "0x00004000" if PAGE_SIZE_16KB
  149. default "0x00010000" if PAGE_SIZE_64KB
  150. default "0x00000000"
  151. choice
  152. prompt "HugeTLB page size"
  153. depends on HUGETLB_PAGE && (CPU_SH4 || CPU_SH5) && MMU
  154. default HUGETLB_PAGE_SIZE_1MB if PAGE_SIZE_64KB
  155. default HUGETLB_PAGE_SIZE_64K
  156. config HUGETLB_PAGE_SIZE_64K
  157. bool "64kB"
  158. depends on !PAGE_SIZE_64KB
  159. config HUGETLB_PAGE_SIZE_256K
  160. bool "256kB"
  161. depends on X2TLB
  162. config HUGETLB_PAGE_SIZE_1MB
  163. bool "1MB"
  164. config HUGETLB_PAGE_SIZE_4MB
  165. bool "4MB"
  166. depends on X2TLB
  167. config HUGETLB_PAGE_SIZE_64MB
  168. bool "64MB"
  169. depends on X2TLB
  170. config HUGETLB_PAGE_SIZE_512MB
  171. bool "512MB"
  172. depends on CPU_SH5
  173. endchoice
  174. source "mm/Kconfig"
  175. endmenu
  176. menu "Cache configuration"
  177. config SH7705_CACHE_32KB
  178. bool "Enable 32KB cache size for SH7705"
  179. depends on CPU_SUBTYPE_SH7705
  180. default y
  181. config SH_DIRECT_MAPPED
  182. bool "Use direct-mapped caching"
  183. default n
  184. help
  185. Selecting this option will configure the caches to be direct-mapped,
  186. even if the cache supports a 2 or 4-way mode. This is useful primarily
  187. for debugging on platforms with 2 and 4-way caches (SH7750R/SH7751R,
  188. SH4-202, SH4-501, etc.)
  189. Turn this option off for platforms that do not have a direct-mapped
  190. cache, and you have no need to run the caches in such a configuration.
  191. choice
  192. prompt "Cache mode"
  193. default CACHE_WRITEBACK if CPU_SH2A || CPU_SH3 || CPU_SH4 || CPU_SH5
  194. default CACHE_WRITETHROUGH if (CPU_SH2 && !CPU_SH2A)
  195. config CACHE_WRITEBACK
  196. bool "Write-back"
  197. config CACHE_WRITETHROUGH
  198. bool "Write-through"
  199. help
  200. Selecting this option will configure the caches in write-through
  201. mode, as opposed to the default write-back configuration.
  202. Since there's sill some aliasing issues on SH-4, this option will
  203. unfortunately still require the majority of flushing functions to
  204. be implemented to deal with aliasing.
  205. If unsure, say N.
  206. config CACHE_OFF
  207. bool "Off"
  208. endchoice
  209. endmenu