Thomas Gleixner | d2912cb | 2019-06-04 10:11:33 +0200 | [diff] [blame] | 1 | # SPDX-License-Identifier: GPL-2.0-only |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 2 | # |
| 3 | # Copyright (C) 2004, 2007-2010, 2011-2012 Synopsys, Inc. (www.synopsys.com) |
| 4 | # |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 5 | |
| 6 | config ARC |
| 7 | def_bool y |
Vineet Gupta | c4c9a04 | 2016-10-31 13:46:38 -0700 | [diff] [blame] | 8 | select ARC_TIMERS |
Anshuman Khandual | c2280be | 2021-05-04 18:38:09 -0700 | [diff] [blame] | 9 | select ARCH_HAS_CACHE_LINE_SIZE |
Anshuman Khandual | 399145f | 2020-06-04 16:47:15 -0700 | [diff] [blame] | 10 | select ARCH_HAS_DEBUG_VM_PGTABLE |
Christoph Hellwig | f73c904 | 2019-06-14 16:26:41 +0200 | [diff] [blame] | 11 | select ARCH_HAS_DMA_PREP_COHERENT |
Vineet Gupta | c27d0e9 | 2018-08-16 10:20:33 -0700 | [diff] [blame] | 12 | select ARCH_HAS_PTE_SPECIAL |
Christoph Hellwig | 347cb6a | 2019-01-07 13:36:20 -0500 | [diff] [blame] | 13 | select ARCH_HAS_SETUP_DMA_OPS |
Christoph Hellwig | 6c3e71d | 2018-05-18 15:41:32 +0200 | [diff] [blame] | 14 | select ARCH_HAS_SYNC_DMA_FOR_CPU |
| 15 | select ARCH_HAS_SYNC_DMA_FOR_DEVICE |
Vineet Gupta | 2a44016 | 2015-08-08 17:51:58 +0530 | [diff] [blame] | 16 | select ARCH_SUPPORTS_ATOMIC_RMW if ARC_HAS_LLSC |
Yury Norov | 942fa98 | 2018-05-16 11:18:49 +0300 | [diff] [blame] | 17 | select ARCH_32BIT_OFF_T |
Shile Zhang | 1091670 | 2019-12-04 08:46:31 +0800 | [diff] [blame] | 18 | select BUILDTIME_TABLE_SORT |
Vineet Gupta | 4adeefe | 2013-01-18 15:12:18 +0530 | [diff] [blame] | 19 | select CLONE_BACKWARDS |
Noam Camus | 69fbd09 | 2016-01-14 12:20:08 +0530 | [diff] [blame] | 20 | select COMMON_CLK |
Christoph Hellwig | f73c904 | 2019-06-14 16:26:41 +0200 | [diff] [blame] | 21 | select DMA_DIRECT_REMAP |
Vineet Gupta | ce63652 | 2015-07-27 17:23:28 +0530 | [diff] [blame] | 22 | select GENERIC_ATOMIC64 if !ISA_ARCV2 || !(ARC_HAS_LL64 && ARC_HAS_LLSC) |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 23 | select GENERIC_FIND_FIRST_BIT |
| 24 | # for now, we don't need GENERIC_IRQ_PROBE, CONFIG_GENERIC_IRQ_CHIP |
| 25 | select GENERIC_IRQ_SHOW |
Joao Pinto | c1678ff | 2016-03-10 14:44:13 -0600 | [diff] [blame] | 26 | select GENERIC_PCI_IOMAP |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 27 | select GENERIC_PENDING_IRQ if SMP |
Alexey Brodkin | bf28760 | 2018-11-19 14:29:17 +0300 | [diff] [blame] | 28 | select GENERIC_SCHED_CLOCK |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 29 | select GENERIC_SMP_IDLE_THREAD |
Mischa Jonker | f46121b | 2013-01-18 15:12:24 +0530 | [diff] [blame] | 30 | select HAVE_ARCH_KGDB |
Vineet Gupta | 547f112 | 2013-01-18 15:12:22 +0530 | [diff] [blame] | 31 | select HAVE_ARCH_TRACEHOOK |
Anshuman Khandual | e8003bf6 | 2021-05-04 18:38:29 -0700 | [diff] [blame] | 32 | select HAVE_ARCH_TRANSPARENT_HUGEPAGE if ARC_MMU_V4 |
Vineet Gupta | c27d0e9 | 2018-08-16 10:20:33 -0700 | [diff] [blame] | 33 | select HAVE_DEBUG_STACKOVERFLOW |
Eugeniy Paltsev | 9fbea0b | 2019-11-19 18:26:15 +0300 | [diff] [blame] | 34 | select HAVE_DEBUG_KMEMLEAK |
Vineet Gupta | 5464d03 | 2017-09-29 14:46:50 -0700 | [diff] [blame] | 35 | select HAVE_FUTEX_CMPXCHG if FUTEX |
Gilad Ben-Yossef | 4368902 | 2013-01-22 16:48:45 +0530 | [diff] [blame] | 36 | select HAVE_IOREMAP_PROT |
Vineet Gupta | c27d0e9 | 2018-08-16 10:20:33 -0700 | [diff] [blame] | 37 | select HAVE_KERNEL_GZIP |
| 38 | select HAVE_KERNEL_LZMA |
Vineet Gupta | 4d86dfb | 2013-01-22 17:03:59 +0530 | [diff] [blame] | 39 | select HAVE_KPROBES |
| 40 | select HAVE_KRETPROBES |
Vineet Gupta | eb1357d | 2017-01-16 10:48:09 -0800 | [diff] [blame] | 41 | select HAVE_MOD_ARCH_SPECIFIC |
Vineet Gupta | 9c57564 | 2013-01-18 15:12:24 +0530 | [diff] [blame] | 42 | select HAVE_PERF_EVENTS |
Vineet Gupta | 1b0ccb8 | 2016-01-01 15:12:54 +0530 | [diff] [blame] | 43 | select HANDLE_DOMAIN_IRQ |
Vineet Gupta | 999159a | 2013-01-22 17:00:52 +0530 | [diff] [blame] | 44 | select IRQ_DOMAIN |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 45 | select MODULES_USE_ELF_RELA |
Vineet Gupta | 999159a | 2013-01-22 17:00:52 +0530 | [diff] [blame] | 46 | select OF |
| 47 | select OF_EARLY_FLATTREE |
Christoph Hellwig | 20f1b79 | 2018-11-15 20:05:34 +0100 | [diff] [blame] | 48 | select PCI_SYSCALL if PCI |
Vineet Gupta | 8238573 | 2016-09-28 11:53:17 -0700 | [diff] [blame] | 49 | select PERF_USE_VMALLOC if ARC_CACHE_VIPT_ALIASING |
Eugeniy Paltsev | f091d5a | 2019-11-08 19:20:22 +0300 | [diff] [blame] | 50 | select HAVE_ARCH_JUMP_LABEL if ISA_ARCV2 && !CPU_ENDIAN_BE32 |
Christoph Hellwig | 5e6e985 | 2020-09-03 16:22:35 +0200 | [diff] [blame] | 51 | select SET_FS |
Masahiro Yamada | 4aae683 | 2021-07-31 14:22:32 +0900 | [diff] [blame^] | 52 | select TRACE_IRQFLAGS_SUPPORT |
Vineet Gupta | 0dafafc | 2013-09-06 14:18:17 +0530 | [diff] [blame] | 53 | |
| 54 | config LOCKDEP_SUPPORT |
| 55 | def_bool y |
| 56 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 57 | config SCHED_OMIT_FRAME_POINTER |
| 58 | def_bool y |
| 59 | |
| 60 | config GENERIC_CSUM |
| 61 | def_bool y |
| 62 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 63 | config ARCH_FLATMEM_ENABLE |
| 64 | def_bool y |
| 65 | |
| 66 | config MMU |
| 67 | def_bool y |
| 68 | |
Uwe Kleine-König | ce816fa | 2014-04-07 15:39:19 -0700 | [diff] [blame] | 69 | config NO_IOPORT_MAP |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 70 | def_bool y |
| 71 | |
| 72 | config GENERIC_CALIBRATE_DELAY |
| 73 | def_bool y |
| 74 | |
| 75 | config GENERIC_HWEIGHT |
| 76 | def_bool y |
| 77 | |
Vineet Gupta | 44c8bb9 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 78 | config STACKTRACE_SUPPORT |
| 79 | def_bool y |
| 80 | select STACKTRACE |
| 81 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 82 | menu "ARC Architecture Configuration" |
| 83 | |
Vineet Gupta | 93ad700 | 2013-01-22 16:51:50 +0530 | [diff] [blame] | 84 | menu "ARC Platform/SoC/Board" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 85 | |
Christian Ruppert | 072eb69 | 2013-04-12 08:40:59 +0200 | [diff] [blame] | 86 | source "arch/arc/plat-tb10x/Kconfig" |
Alexey Brodkin | 556cc1c | 2014-01-27 14:51:34 +0100 | [diff] [blame] | 87 | source "arch/arc/plat-axs10x/Kconfig" |
Alexey Brodkin | a518d63 | 2017-08-15 21:13:55 +0300 | [diff] [blame] | 88 | source "arch/arc/plat-hsdk/Kconfig" |
Vineet Gupta | 93ad700 | 2013-01-22 16:51:50 +0530 | [diff] [blame] | 89 | |
Vineet Gupta | 53d9895 | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 90 | endmenu |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 91 | |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 92 | choice |
| 93 | prompt "ARC Instruction Set" |
Kevin Hilman | b7cc40c | 2018-11-30 15:51:56 +0300 | [diff] [blame] | 94 | default ISA_ARCV2 |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 95 | |
| 96 | config ISA_ARCOMPACT |
| 97 | bool "ARCompact ISA" |
Zhaoxiu Zeng | fff7fb0 | 2016-05-20 17:03:57 -0700 | [diff] [blame] | 98 | select CPU_NO_EFFICIENT_FFS |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 99 | help |
| 100 | The original ARC ISA of ARC600/700 cores |
| 101 | |
Vineet Gupta | 65bfbcd | 2015-03-09 14:01:08 +0530 | [diff] [blame] | 102 | config ISA_ARCV2 |
| 103 | bool "ARC ISA v2" |
Vineet Gupta | c4c9a04 | 2016-10-31 13:46:38 -0700 | [diff] [blame] | 104 | select ARC_TIMERS_64BIT |
Vineet Gupta | 65bfbcd | 2015-03-09 14:01:08 +0530 | [diff] [blame] | 105 | help |
| 106 | ISA for the Next Generation ARC-HS cores |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 107 | |
| 108 | endchoice |
| 109 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 110 | menu "ARC CPU Configuration" |
| 111 | |
| 112 | choice |
| 113 | prompt "ARC Core" |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 114 | default ARC_CPU_770 if ISA_ARCOMPACT |
| 115 | default ARC_CPU_HS if ISA_ARCV2 |
| 116 | |
| 117 | if ISA_ARCOMPACT |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 118 | |
| 119 | config ARC_CPU_750D |
| 120 | bool "ARC750D" |
Vineet Gupta | 14a0abf | 2015-06-26 12:42:53 +0530 | [diff] [blame] | 121 | select ARC_CANT_LLSC |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 122 | help |
| 123 | Support for ARC750 core |
| 124 | |
| 125 | config ARC_CPU_770 |
| 126 | bool "ARC770" |
Vineet Gupta | 742f8af | 2013-11-07 14:47:16 +0530 | [diff] [blame] | 127 | select ARC_HAS_SWAPE |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 128 | help |
| 129 | Support for ARC770 core introduced with Rel 4.10 (Summer 2011) |
| 130 | This core has a bunch of cool new features: |
| 131 | -MMU-v3: Variable Page Sz (4k, 8k, 16k), bigger J-TLB (128x4) |
Enrico Weigelt, metux IT consult | 9a18b5a | 2019-03-11 14:57:59 +0100 | [diff] [blame] | 132 | Shared Address Spaces (for sharing TLB entries in MMU) |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 133 | -Caches: New Prog Model, Region Flush |
| 134 | -Insns: endian swap, load-locked/store-conditional, time-stamp-ctr |
| 135 | |
Enrico Weigelt, metux IT consult | 9a18b5a | 2019-03-11 14:57:59 +0100 | [diff] [blame] | 136 | endif #ISA_ARCOMPACT |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 137 | |
| 138 | config ARC_CPU_HS |
| 139 | bool "ARC-HS" |
| 140 | depends on ISA_ARCV2 |
| 141 | help |
| 142 | Support for ARC HS38x Cores based on ARCv2 ISA |
| 143 | The notable features are: |
Randy Dunlap | a5760db | 2020-01-31 17:49:33 -0800 | [diff] [blame] | 144 | - SMP configurations of up to 4 cores with coherency |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 145 | - Optional L2 Cache and IO-Coherency |
| 146 | - Revised Interrupt Architecture (multiple priorites, reg banks, |
| 147 | auto stack switch, auto regfile save/restore) |
| 148 | - MMUv4 (PIPT dcache, Huge Pages) |
| 149 | - Instructions for |
| 150 | * 64bit load/store: LDD, STD |
| 151 | * Hardware assisted divide/remainder: DIV, REM |
| 152 | * Function prologue/epilogue: ENTER_S, LEAVE_S |
| 153 | * IRQ enable/disable: CLRI, SETI |
| 154 | * pop count: FFS, FLS |
| 155 | * SETcc, BMSKN, XBFU... |
| 156 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 157 | endchoice |
| 158 | |
Eugeniy Paltsev | 0bdd6e7 | 2020-06-04 20:39:24 +0300 | [diff] [blame] | 159 | config ARC_TUNE_MCPU |
| 160 | string "Override default -mcpu compiler flag" |
| 161 | default "" |
| 162 | help |
| 163 | Override default -mcpu=xxx compiler flag (which is set depending on |
| 164 | the ISA version) with the specified value. |
| 165 | NOTE: If specified flag isn't supported by current compiler the |
| 166 | ISA default value will be used as a fallback. |
| 167 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 168 | config CPU_BIG_ENDIAN |
| 169 | bool "Enable Big Endian Mode" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 170 | help |
| 171 | Build kernel for Big Endian Mode of ARC CPU |
| 172 | |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 173 | config SMP |
Vineet Gupta | 82fea5a | 2014-09-10 19:05:38 +0530 | [diff] [blame] | 174 | bool "Symmetric Multi-Processing" |
Vineet Gupta | 82fea5a | 2014-09-10 19:05:38 +0530 | [diff] [blame] | 175 | select ARC_MCIP if ISA_ARCV2 |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 176 | help |
Vineet Gupta | 82fea5a | 2014-09-10 19:05:38 +0530 | [diff] [blame] | 177 | This enables support for systems with more than one CPU. |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 178 | |
| 179 | if SMP |
| 180 | |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 181 | config NR_CPUS |
Noam Camus | 3aa4f80 | 2013-06-03 15:19:59 +0300 | [diff] [blame] | 182 | int "Maximum number of CPUs (2-4096)" |
| 183 | range 2 4096 |
Vineet Gupta | 82fea5a | 2014-09-10 19:05:38 +0530 | [diff] [blame] | 184 | default "4" |
| 185 | |
Vineet Gupta | 3971cdc | 2015-10-09 11:26:12 +0530 | [diff] [blame] | 186 | config ARC_SMP_HALT_ON_RESET |
| 187 | bool "Enable Halt-on-reset boot mode" |
Vineet Gupta | 3971cdc | 2015-10-09 11:26:12 +0530 | [diff] [blame] | 188 | help |
| 189 | In SMP configuration cores can be configured as Halt-on-reset |
| 190 | or they could all start at same time. For Halt-on-reset, non |
Randy Dunlap | a5760db | 2020-01-31 17:49:33 -0800 | [diff] [blame] | 191 | masters are parked until Master kicks them so they can start off |
Vineet Gupta | 3971cdc | 2015-10-09 11:26:12 +0530 | [diff] [blame] | 192 | at designated entry point. For other case, all jump to common |
| 193 | entry point and spin wait for Master's signal. |
| 194 | |
Enrico Weigelt, metux IT consult | 9a18b5a | 2019-03-11 14:57:59 +0100 | [diff] [blame] | 195 | endif #SMP |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 196 | |
Vineet Gupta | 3ce0fef | 2016-09-29 10:00:14 -0700 | [diff] [blame] | 197 | config ARC_MCIP |
| 198 | bool "ARConnect Multicore IP (MCIP) Support " |
| 199 | depends on ISA_ARCV2 |
| 200 | default y if SMP |
| 201 | help |
| 202 | This IP block enables SMP in ARC-HS38 cores. |
| 203 | It provides for cross-core interrupts, multi-core debug |
| 204 | hardware semaphores, shared memory,.... |
| 205 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 206 | menuconfig ARC_CACHE |
| 207 | bool "Enable Cache Support" |
| 208 | default y |
| 209 | |
| 210 | if ARC_CACHE |
| 211 | |
| 212 | config ARC_CACHE_LINE_SHIFT |
| 213 | int "Cache Line Length (as power of 2)" |
| 214 | range 5 7 |
| 215 | default "6" |
| 216 | help |
| 217 | Starting with ARC700 4.9, Cache line length is configurable, |
| 218 | This option specifies "N", with Line-len = 2 power N |
| 219 | So line lengths of 32, 64, 128 are specified by 5,6,7, respectively |
| 220 | Linux only supports same line lengths for I and D caches. |
| 221 | |
| 222 | config ARC_HAS_ICACHE |
| 223 | bool "Use Instruction Cache" |
| 224 | default y |
| 225 | |
| 226 | config ARC_HAS_DCACHE |
| 227 | bool "Use Data Cache" |
| 228 | default y |
| 229 | |
| 230 | config ARC_CACHE_PAGES |
| 231 | bool "Per Page Cache Control" |
| 232 | default y |
| 233 | depends on ARC_HAS_ICACHE || ARC_HAS_DCACHE |
| 234 | help |
| 235 | This can be used to over-ride the global I/D Cache Enable on a |
| 236 | per-page basis (but only for pages accessed via MMU such as |
| 237 | Kernel Virtual address or User Virtual Address) |
| 238 | TLB entries have a per-page Cache Enable Bit. |
| 239 | Note that Global I/D ENABLE + Per Page DISABLE works but corollary |
| 240 | Global DISABLE + Per Page ENABLE won't work |
| 241 | |
Vineet Gupta | 4102b53 | 2013-05-09 21:54:51 +0530 | [diff] [blame] | 242 | config ARC_CACHE_VIPT_ALIASING |
| 243 | bool "Support VIPT Aliasing D$" |
Vineet Gupta | d1f317d | 2015-04-06 17:23:57 +0530 | [diff] [blame] | 244 | depends on ARC_HAS_DCACHE && ISA_ARCOMPACT |
Vineet Gupta | 4102b53 | 2013-05-09 21:54:51 +0530 | [diff] [blame] | 245 | |
Enrico Weigelt, metux IT consult | 9a18b5a | 2019-03-11 14:57:59 +0100 | [diff] [blame] | 246 | endif #ARC_CACHE |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 247 | |
Vineet Gupta | 8b5850f | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 248 | config ARC_HAS_ICCM |
| 249 | bool "Use ICCM" |
| 250 | help |
| 251 | Single Cycle RAMS to store Fast Path Code |
Vineet Gupta | 8b5850f | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 252 | |
| 253 | config ARC_ICCM_SZ |
| 254 | int "ICCM Size in KB" |
| 255 | default "64" |
| 256 | depends on ARC_HAS_ICCM |
| 257 | |
| 258 | config ARC_HAS_DCCM |
| 259 | bool "Use DCCM" |
| 260 | help |
| 261 | Single Cycle RAMS to store Fast Path Data |
Vineet Gupta | 8b5850f | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 262 | |
| 263 | config ARC_DCCM_SZ |
| 264 | int "DCCM Size in KB" |
| 265 | default "64" |
| 266 | depends on ARC_HAS_DCCM |
| 267 | |
| 268 | config ARC_DCCM_BASE |
| 269 | hex "DCCM map address" |
| 270 | default "0xA0000000" |
| 271 | depends on ARC_HAS_DCCM |
| 272 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 273 | choice |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 274 | prompt "MMU Version" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 275 | default ARC_MMU_V3 if ARC_CPU_770 |
| 276 | default ARC_MMU_V2 if ARC_CPU_750D |
Vineet Gupta | d7a512b | 2015-04-06 17:22:39 +0530 | [diff] [blame] | 277 | default ARC_MMU_V4 if ARC_CPU_HS |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 278 | |
Vineet Gupta | c583ee4f | 2015-09-29 16:01:13 +0530 | [diff] [blame] | 279 | if ISA_ARCOMPACT |
| 280 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 281 | config ARC_MMU_V1 |
| 282 | bool "MMU v1" |
| 283 | help |
| 284 | Orig ARC700 MMU |
| 285 | |
| 286 | config ARC_MMU_V2 |
| 287 | bool "MMU v2" |
| 288 | help |
Masanari Iida | 83fc61a | 2017-09-26 12:47:59 +0900 | [diff] [blame] | 289 | Fixed the deficiency of v1 - possible thrashing in memcpy scenario |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 290 | when 2 D-TLB and 1 I-TLB entries index into same 2way set. |
| 291 | |
| 292 | config ARC_MMU_V3 |
| 293 | bool "MMU v3" |
| 294 | depends on ARC_CPU_770 |
| 295 | help |
| 296 | Introduced with ARC700 4.10: New Features |
| 297 | Variable Page size (1k-16k), var JTLB size 128 x (2 or 4) |
| 298 | Shared Address Spaces (SASID) |
| 299 | |
Vineet Gupta | c583ee4f | 2015-09-29 16:01:13 +0530 | [diff] [blame] | 300 | endif |
| 301 | |
Vineet Gupta | d7a512b | 2015-04-06 17:22:39 +0530 | [diff] [blame] | 302 | config ARC_MMU_V4 |
| 303 | bool "MMU v4" |
| 304 | depends on ISA_ARCV2 |
| 305 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 306 | endchoice |
| 307 | |
| 308 | |
| 309 | choice |
| 310 | prompt "MMU Page Size" |
| 311 | default ARC_PAGE_SIZE_8K |
| 312 | |
| 313 | config ARC_PAGE_SIZE_8K |
| 314 | bool "8KB" |
| 315 | help |
| 316 | Choose between 8k vs 16k |
| 317 | |
| 318 | config ARC_PAGE_SIZE_16K |
| 319 | bool "16KB" |
Alexey Brodkin | 450ed0d | 2015-07-16 21:45:17 +0300 | [diff] [blame] | 320 | depends on ARC_MMU_V3 || ARC_MMU_V4 |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 321 | |
| 322 | config ARC_PAGE_SIZE_4K |
| 323 | bool "4KB" |
Alexey Brodkin | 450ed0d | 2015-07-16 21:45:17 +0300 | [diff] [blame] | 324 | depends on ARC_MMU_V3 || ARC_MMU_V4 |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 325 | |
| 326 | endchoice |
| 327 | |
Vineet Gupta | 37eda9d | 2016-02-10 06:52:07 +0530 | [diff] [blame] | 328 | choice |
| 329 | prompt "MMU Super Page Size" |
| 330 | depends on ISA_ARCV2 && TRANSPARENT_HUGEPAGE |
| 331 | default ARC_HUGEPAGE_2M |
| 332 | |
| 333 | config ARC_HUGEPAGE_2M |
| 334 | bool "2MB" |
| 335 | |
| 336 | config ARC_HUGEPAGE_16M |
| 337 | bool "16MB" |
| 338 | |
| 339 | endchoice |
| 340 | |
Vineet Gupta | 4788a59 | 2013-01-18 15:12:22 +0530 | [diff] [blame] | 341 | config ARC_COMPACT_IRQ_LEVELS |
Vineet Gupta | f45ba2b | 2020-01-17 15:04:03 -0800 | [diff] [blame] | 342 | depends on ISA_ARCOMPACT |
Vineet Gupta | 60f2b4b | 2016-05-30 19:21:22 +0530 | [diff] [blame] | 343 | bool "Setup Timer IRQ as high Priority" |
Vineet Gupta | 41195d2 | 2013-01-18 15:12:23 +0530 | [diff] [blame] | 344 | # if SMP, LV2 enabled ONLY if ARC implementation has LV2 re-entrancy |
Vineet Gupta | 60f2b4b | 2016-05-30 19:21:22 +0530 | [diff] [blame] | 345 | depends on !SMP |
Vineet Gupta | 4788a59 | 2013-01-18 15:12:22 +0530 | [diff] [blame] | 346 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 347 | config ARC_FPU_SAVE_RESTORE |
| 348 | bool "Enable FPU state persistence across context switch" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 349 | help |
Vineet Gupta | f45ba2b | 2020-01-17 15:04:03 -0800 | [diff] [blame] | 350 | ARCompact FPU has internal registers to assist with Double precision |
| 351 | Floating Point operations. There are control and stauts registers |
| 352 | for floating point exceptions and rounding modes. These are |
| 353 | preserved across task context switch when enabled. |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 354 | |
Vineet Gupta | fbf8e13 | 2013-03-30 15:07:47 +0530 | [diff] [blame] | 355 | config ARC_CANT_LLSC |
| 356 | def_bool n |
| 357 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 358 | config ARC_HAS_LLSC |
| 359 | bool "Insn: LLOCK/SCOND (efficient atomic ops)" |
| 360 | default y |
Vineet Gupta | 14a0abf | 2015-06-26 12:42:53 +0530 | [diff] [blame] | 361 | depends on !ARC_CANT_LLSC |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 362 | |
| 363 | config ARC_HAS_SWAPE |
| 364 | bool "Insn: SWAPE (endian-swap)" |
| 365 | default y |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 366 | |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 367 | if ISA_ARCV2 |
| 368 | |
Eugeniy Paltsev | 7655146 | 2019-01-30 19:32:41 +0300 | [diff] [blame] | 369 | config ARC_USE_UNALIGNED_MEM_ACCESS |
| 370 | bool "Enable unaligned access in HW" |
| 371 | default y |
| 372 | select HAVE_EFFICIENT_UNALIGNED_ACCESS |
| 373 | help |
| 374 | The ARC HS architecture supports unaligned memory access |
| 375 | which is disabled by default. Enable unaligned access in |
| 376 | hardware and use software to use it |
| 377 | |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 378 | config ARC_HAS_LL64 |
| 379 | bool "Insn: 64bit LDD/STD" |
| 380 | help |
| 381 | Enable gcc to generate 64-bit load/store instructions |
| 382 | ISA mandates even/odd registers to allow encoding of two |
| 383 | dest operands with 2 possible source operands. |
| 384 | default y |
| 385 | |
Alexey Brodkin | d05a76a | 2015-07-16 21:45:38 +0300 | [diff] [blame] | 386 | config ARC_HAS_DIV_REM |
| 387 | bool "Insn: div, divu, rem, remu" |
| 388 | default y |
| 389 | |
Vineet Gupta | 3d5e801 | 2017-04-20 15:36:51 -0700 | [diff] [blame] | 390 | config ARC_HAS_ACCL_REGS |
Eugeniy Paltsev | 4827d0c | 2020-03-05 23:02:50 +0300 | [diff] [blame] | 391 | bool "Reg Pair ACCL:ACCH (FPU and/or MPY > 6 and/or DSP)" |
Vineet Gupta | af1fc5b | 2018-07-17 15:21:56 -0700 | [diff] [blame] | 392 | default y |
Vineet Gupta | 3d5e801 | 2017-04-20 15:36:51 -0700 | [diff] [blame] | 393 | help |
| 394 | Depending on the configuration, CPU can contain accumulator reg-pair |
| 395 | (also referred to as r58:r59). These can also be used by gcc as GPR so |
| 396 | kernel needs to save/restore per process |
| 397 | |
Eugeniy Paltsev | 4827d0c | 2020-03-05 23:02:50 +0300 | [diff] [blame] | 398 | config ARC_DSP_HANDLED |
| 399 | def_bool n |
| 400 | |
Eugeniy Paltsev | 7321e2e | 2020-03-05 23:02:51 +0300 | [diff] [blame] | 401 | config ARC_DSP_SAVE_RESTORE_REGS |
| 402 | def_bool n |
| 403 | |
Eugeniy Paltsev | 4827d0c | 2020-03-05 23:02:50 +0300 | [diff] [blame] | 404 | choice |
| 405 | prompt "DSP support" |
| 406 | default ARC_DSP_NONE |
| 407 | help |
| 408 | Depending on the configuration, CPU can contain DSP registers |
| 409 | (ACC0_GLO, ACC0_GHI, DSP_BFLY0, DSP_CTRL, DSP_FFT_CTRL). |
| 410 | Bellow is options describing how to handle these registers in |
| 411 | interrupt entry / exit and in context switch. |
| 412 | |
| 413 | config ARC_DSP_NONE |
| 414 | bool "No DSP extension presence in HW" |
| 415 | help |
| 416 | No DSP extension presence in HW |
| 417 | |
| 418 | config ARC_DSP_KERNEL |
| 419 | bool "DSP extension in HW, no support for userspace" |
| 420 | select ARC_HAS_ACCL_REGS |
| 421 | select ARC_DSP_HANDLED |
| 422 | help |
| 423 | DSP extension presence in HW, no support for DSP-enabled userspace |
| 424 | applications. We don't save / restore DSP registers and only do |
| 425 | some minimal preparations so userspace won't be able to break kernel |
Eugeniy Paltsev | 7321e2e | 2020-03-05 23:02:51 +0300 | [diff] [blame] | 426 | |
| 427 | config ARC_DSP_USERSPACE |
| 428 | bool "Support DSP for userspace apps" |
| 429 | select ARC_HAS_ACCL_REGS |
| 430 | select ARC_DSP_HANDLED |
| 431 | select ARC_DSP_SAVE_RESTORE_REGS |
| 432 | help |
| 433 | DSP extension presence in HW, support save / restore DSP registers to |
| 434 | run DSP-enabled userspace applications |
Eugeniy Paltsev | f09d317 | 2020-03-05 23:02:52 +0300 | [diff] [blame] | 435 | |
| 436 | config ARC_DSP_AGU_USERSPACE |
| 437 | bool "Support DSP with AGU for userspace apps" |
| 438 | select ARC_HAS_ACCL_REGS |
| 439 | select ARC_DSP_HANDLED |
| 440 | select ARC_DSP_SAVE_RESTORE_REGS |
| 441 | help |
| 442 | DSP and AGU extensions presence in HW, support save / restore DSP |
| 443 | and AGU registers to run DSP-enabled userspace applications |
Eugeniy Paltsev | 4827d0c | 2020-03-05 23:02:50 +0300 | [diff] [blame] | 444 | endchoice |
| 445 | |
Vineet Gupta | e494239 | 2018-06-06 10:20:37 -0700 | [diff] [blame] | 446 | config ARC_IRQ_NO_AUTOSAVE |
| 447 | bool "Disable hardware autosave regfile on interrupts" |
| 448 | default n |
| 449 | help |
| 450 | On HS cores, taken interrupt auto saves the regfile on stack. |
| 451 | This is programmable and can be optionally disabled in which case |
| 452 | software INTERRUPT_PROLOGUE/EPILGUE do the needed work |
| 453 | |
Eugeniy Paltsev | 10011f7 | 2020-06-04 20:39:25 +0300 | [diff] [blame] | 454 | config ARC_LPB_DISABLE |
| 455 | bool "Disable loop buffer (LPB)" |
| 456 | help |
| 457 | On HS cores, loop buffer (LPB) is programmable in runtime and can |
| 458 | be optionally disabled. |
| 459 | |
Enrico Weigelt, metux IT consult | 9a18b5a | 2019-03-11 14:57:59 +0100 | [diff] [blame] | 460 | endif # ISA_ARCV2 |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 461 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 462 | endmenu # "ARC CPU Configuration" |
| 463 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 464 | config LINUX_LINK_BASE |
Eugeniy Paltsev | 9ed6878 | 2017-08-15 21:13:54 +0300 | [diff] [blame] | 465 | hex "Kernel link address" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 466 | default "0x80000000" |
| 467 | help |
| 468 | ARC700 divides the 32 bit phy address space into two equal halves |
| 469 | -Lower 2G (0 - 0x7FFF_FFFF ) is user virtual, translated by MMU |
| 470 | -Upper 2G (0x8000_0000 onwards) is untranslated, for kernel |
| 471 | Typically Linux kernel is linked at the start of untransalted addr, |
| 472 | hence the default value of 0x8zs. |
| 473 | However some customers have peripherals mapped at this addr, so |
| 474 | Linux needs to be scooted a bit. |
| 475 | If you don't know what the above means, leave this setting alone. |
Vineet Gupta | ff1c0b6 | 2015-12-15 13:57:16 +0530 | [diff] [blame] | 476 | This needs to match memory start address specified in Device Tree |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 477 | |
Eugeniy Paltsev | 9ed6878 | 2017-08-15 21:13:54 +0300 | [diff] [blame] | 478 | config LINUX_RAM_BASE |
| 479 | hex "RAM base address" |
| 480 | default LINUX_LINK_BASE |
| 481 | help |
| 482 | By default Linux is linked at base of RAM. However in some special |
| 483 | cases (such as HSDK), Linux can't be linked at start of DDR, hence |
| 484 | this option. |
| 485 | |
Vineet Gupta | 45890f6 | 2015-03-09 18:53:49 +0530 | [diff] [blame] | 486 | config HIGHMEM |
| 487 | bool "High Memory Support" |
Mike Rapoport | 050b2da | 2020-12-14 19:10:04 -0800 | [diff] [blame] | 488 | select HAVE_ARCH_PFN_VALID |
Thomas Gleixner | 39cac19 | 2020-11-03 10:27:21 +0100 | [diff] [blame] | 489 | select KMAP_LOCAL |
Vineet Gupta | 45890f6 | 2015-03-09 18:53:49 +0530 | [diff] [blame] | 490 | help |
| 491 | With ARC 2G:2G address split, only upper 2G is directly addressable by |
| 492 | kernel. Enable this to potentially allow access to rest of 2G and PAE |
| 493 | in future |
| 494 | |
Vineet Gupta | 5a364c2 | 2015-02-06 18:44:57 +0300 | [diff] [blame] | 495 | config ARC_HAS_PAE40 |
| 496 | bool "Support for the 40-bit Physical Address Extension" |
Vineet Gupta | 5a364c2 | 2015-02-06 18:44:57 +0300 | [diff] [blame] | 497 | depends on ISA_ARCV2 |
Alexey Brodkin | cf4100d | 2017-05-05 23:20:29 +0300 | [diff] [blame] | 498 | select HIGHMEM |
Christoph Hellwig | d4a451d | 2018-04-03 16:24:20 +0200 | [diff] [blame] | 499 | select PHYS_ADDR_T_64BIT |
Vineet Gupta | 5a364c2 | 2015-02-06 18:44:57 +0300 | [diff] [blame] | 500 | help |
| 501 | Enable access to physical memory beyond 4G, only supported on |
| 502 | ARC cores with 40 bit Physical Addressing support |
| 503 | |
Noam Camus | 15ca68a | 2014-09-07 22:52:33 +0300 | [diff] [blame] | 504 | config ARC_KVADDR_SIZE |
Masanari Iida | 83fc61a | 2017-09-26 12:47:59 +0900 | [diff] [blame] | 505 | int "Kernel Virtual Address Space size (MB)" |
Noam Camus | 15ca68a | 2014-09-07 22:52:33 +0300 | [diff] [blame] | 506 | range 0 512 |
| 507 | default "256" |
| 508 | help |
| 509 | The kernel address space is carved out of 256MB of translated address |
| 510 | space for catering to vmalloc, modules, pkmap, fixmap. This however may |
| 511 | not suffice vmalloc requirements of a 4K CPU EZChip system. So allow |
| 512 | this to be stretched to 512 MB (by extending into the reserved |
| 513 | kernel-user gutter) |
| 514 | |
Vineet Gupta | 080c374 | 2013-02-11 19:52:57 +0530 | [diff] [blame] | 515 | config ARC_CURR_IN_REG |
| 516 | bool "Dedicate Register r25 for current_task pointer" |
| 517 | default y |
| 518 | help |
| 519 | This reserved Register R25 to point to Current Task in |
| 520 | kernel mode. This saves memory access for each such access |
| 521 | |
Vineet Gupta | 2e651ea | 2013-01-23 16:30:36 +0530 | [diff] [blame] | 522 | |
Vineet Gupta | 1736a56 | 2014-09-08 11:18:15 +0530 | [diff] [blame] | 523 | config ARC_EMUL_UNALIGNED |
Vineet Gupta | 2e651ea | 2013-01-23 16:30:36 +0530 | [diff] [blame] | 524 | bool "Emulate unaligned memory access (userspace only)" |
Vineet Gupta | 2e651ea | 2013-01-23 16:30:36 +0530 | [diff] [blame] | 525 | select SYSCTL_ARCH_UNALIGN_NO_WARN |
| 526 | select SYSCTL_ARCH_UNALIGN_ALLOW |
Vineet Gupta | 1f6ccff | 2013-05-13 18:30:41 +0530 | [diff] [blame] | 527 | depends on ISA_ARCOMPACT |
Vineet Gupta | 2e651ea | 2013-01-23 16:30:36 +0530 | [diff] [blame] | 528 | help |
| 529 | This enables misaligned 16 & 32 bit memory access from user space. |
| 530 | Use ONLY-IF-ABS-NECESSARY as it will be very slow and also can hide |
| 531 | potential bugs in code |
| 532 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 533 | config HZ |
| 534 | int "Timer Frequency" |
| 535 | default 100 |
| 536 | |
Vineet Gupta | cbe056f | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 537 | config ARC_METAWARE_HLINK |
| 538 | bool "Support for Metaware debugger assisted Host access" |
Vineet Gupta | cbe056f | 2013-01-18 15:12:25 +0530 | [diff] [blame] | 539 | help |
| 540 | This options allows a Linux userland apps to directly access |
| 541 | host file system (open/creat/read/write etc) with help from |
| 542 | Metaware Debugger. This can come in handy for Linux-host communication |
| 543 | when there is no real usable peripheral such as EMAC. |
| 544 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 545 | menuconfig ARC_DBG |
| 546 | bool "ARC debugging" |
| 547 | default y |
| 548 | |
Vineet Gupta | aa6083e | 2014-11-07 10:45:28 +0530 | [diff] [blame] | 549 | if ARC_DBG |
| 550 | |
Vineet Gupta | 854a0d9 | 2013-01-22 17:03:19 +0530 | [diff] [blame] | 551 | config ARC_DW2_UNWIND |
| 552 | bool "Enable DWARF specific kernel stack unwind" |
Vineet Gupta | 854a0d9 | 2013-01-22 17:03:19 +0530 | [diff] [blame] | 553 | default y |
| 554 | select KALLSYMS |
| 555 | help |
| 556 | Compiles the kernel with DWARF unwind information and can be used |
| 557 | to get stack backtraces. |
| 558 | |
| 559 | If you say Y here the resulting kernel image will be slightly larger |
| 560 | but not slower, and it will give very useful debugging information. |
| 561 | If you don't debug the kernel, you can say N, but we may not be able |
| 562 | to solve problems without frame unwind information |
| 563 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 564 | config ARC_DBG_TLB_PARANOIA |
| 565 | bool "Paranoia Checks in Low Level TLB Handlers" |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 566 | |
Eugeniy Paltsev | f091d5a | 2019-11-08 19:20:22 +0300 | [diff] [blame] | 567 | config ARC_DBG_JUMP_LABEL |
| 568 | bool "Paranoid checks in Static Keys (jump labels) code" |
| 569 | depends on JUMP_LABEL |
| 570 | default y if STATIC_KEYS_SELFTEST |
| 571 | help |
| 572 | Enable paranoid checks and self-test of both ARC-specific and generic |
| 573 | part of static keys (jump labels) related code. |
Vineet Gupta | aa6083e | 2014-11-07 10:45:28 +0530 | [diff] [blame] | 574 | endif |
| 575 | |
Vineet Gupta | 999159a | 2013-01-22 17:00:52 +0530 | [diff] [blame] | 576 | config ARC_BUILTIN_DTB_NAME |
| 577 | string "Built in DTB" |
| 578 | help |
| 579 | Set the name of the DTB to embed in the vmlinux binary |
| 580 | Leaving it blank selects the minimal "skeleton" dtb |
| 581 | |
Vineet Gupta | cfdbc2e | 2013-01-18 15:12:20 +0530 | [diff] [blame] | 582 | endmenu # "ARC Architecture Configuration" |
| 583 | |
Vineet Gupta | 37eda9d | 2016-02-10 06:52:07 +0530 | [diff] [blame] | 584 | config FORCE_MAX_ZONEORDER |
| 585 | int "Maximum zone order" |
| 586 | default "12" if ARC_HUGEPAGE_16M |
| 587 | default "11" |
| 588 | |
Alexey Brodkin | 996bad6 | 2014-10-29 15:26:25 +0300 | [diff] [blame] | 589 | source "kernel/power/Kconfig" |