blob: b49d5e033e297ab73c60773081674cdb95996ded [file] [log] [blame]
Greg Kroah-Hartmanb2441312017-11-01 15:07:57 +01001# SPDX-License-Identifier: GPL-2.0
Linus Torvalds1da177e2005-04-16 15:20:36 -07002config SUPERH
Paul Mundtea0e1a92007-11-21 15:58:01 +09003 def_bool y
Christoph Hellwig582dc532020-07-14 14:18:48 +02004 select ARCH_32BIT_OFF_T
Mark Brown7563bbf2012-04-15 10:52:54 +01005 select ARCH_HAVE_CUSTOM_GPIO_H
Huang Yingdf013ff2011-07-13 13:14:22 +08006 select ARCH_HAVE_NMI_SAFE_CMPXCHG if (GUSA_RB || CPU_SH4A)
Christoph Hellwig582dc532020-07-14 14:18:48 +02007 select ARCH_HAS_BINFMT_FLAT if !MMU
8 select ARCH_HAS_GIGANTIC_PAGE
Riku Voipio957e3fa2014-12-12 16:57:44 -08009 select ARCH_HAS_GCOV_PROFILE_ALL
Christoph Hellwig582dc532020-07-14 14:18:48 +020010 select ARCH_HAS_PTE_SPECIAL
11 select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
12 select ARCH_HIBERNATION_POSSIBLE if MMU
13 select ARCH_MIGHT_HAVE_PC_PARPORT
Will Deaconc1d7e012012-07-30 14:42:46 -070014 select ARCH_WANT_IPC_PARSE_VERSION
Christoph Hellwig582dc532020-07-14 14:18:48 +020015 select CLKDEV_LOOKUP
16 select CPU_NO_EFFICIENT_FFS
17 select DMA_DECLARE_COHERENT
Paul Mundtf01789c2009-06-17 10:43:13 +090018 select GENERIC_ATOMIC64
Anna-Maria Gleixner8cf200d2012-05-18 16:45:53 +000019 select GENERIC_CMOS_UPDATE if SH_SH03 || SH_DREAMCAST
Christoph Hellwig582dc532020-07-14 14:18:48 +020020 select GENERIC_IDLE_POLL_SETUP
21 select GENERIC_IRQ_SHOW
Christoph Hellwigeb01d422018-11-15 20:05:32 +010022 select GENERIC_PCI_IOMAP if PCI
Rich Felkerb46ed372016-05-26 22:18:52 +000023 select GENERIC_SCHED_CLOCK
Paul Mundt0e100e12012-05-25 13:02:48 +090024 select GENERIC_STRNCPY_FROM_USER
Paul Mundtcba8df42012-06-04 15:46:05 +090025 select GENERIC_STRNLEN_USER
Christoph Hellwig582dc532020-07-14 14:18:48 +020026 select GENERIC_SMP_IDLE_THREAD
Christoph Hellwig3c9b9ac2019-07-11 20:57:00 -070027 select GUP_GET_PTE_LOW_HIGH if X2TLB
Christoph Hellwig582dc532020-07-14 14:18:48 +020028 select HAVE_ARCH_AUDITSYSCALL
29 select HAVE_ARCH_KGDB
Michael Karcher0bb605c2020-07-23 01:13:21 +020030 select HAVE_ARCH_SECCOMP_FILTER
Christoph Hellwig582dc532020-07-14 14:18:48 +020031 select HAVE_ARCH_TRACEHOOK
Christian Braunere1cc9d82020-06-23 01:43:23 +020032 select HAVE_COPY_THREAD_TLS
Christoph Hellwig582dc532020-07-14 14:18:48 +020033 select HAVE_DEBUG_BUGVERBOSE
34 select HAVE_DEBUG_KMEMLEAK
35 select HAVE_DYNAMIC_FTRACE
36 select HAVE_FAST_GUP if MMU
37 select HAVE_FUNCTION_GRAPH_TRACER
38 select HAVE_FUNCTION_TRACER
39 select HAVE_FUTEX_CMPXCHG if FUTEX
40 select HAVE_FTRACE_MCOUNT_RECORD
41 select HAVE_HW_BREAKPOINT
42 select HAVE_IDE if HAS_IOPORT_MAP
43 select HAVE_IOREMAP_PROT if MMU && !X2TLB
44 select HAVE_KERNEL_BZIP2
45 select HAVE_KERNEL_GZIP
46 select HAVE_KERNEL_LZMA
47 select HAVE_KERNEL_LZO
48 select HAVE_KERNEL_XZ
Chris Smithd39f5452008-09-05 17:15:39 +090049 select HAVE_KPROBES
50 select HAVE_KRETPROBES
Frederic Weisbecker01027522010-04-11 18:55:56 +020051 select HAVE_MIXED_BREAKPOINTS_REGS
Christoph Hellwig582dc532020-07-14 14:18:48 +020052 select HAVE_MOD_ARCH_SPECIFIC if DWARF_UNWINDER
53 select HAVE_NMI
54 select HAVE_OPROFILE
55 select HAVE_PATA_PLATFORM
56 select HAVE_PERF_EVENTS
57 select HAVE_REGS_AND_STACK_ACCESS_API
58 select HAVE_UID16
Thomas Gleixnercd1a41c2021-02-10 00:40:52 +010059 select HAVE_SOFTIRQ_ON_OWN_STACK if IRQSTACKS
Masahiro Yamadad148eac2018-06-14 19:36:45 +090060 select HAVE_STACKPROTECTOR
Christoph Hellwig582dc532020-07-14 14:18:48 +020061 select HAVE_SYSCALL_TRACEPOINTS
62 select IRQ_FORCED_THREADING
63 select MAY_HAVE_SPARSE_IRQ
64 select MODULES_USE_ELF_RELA
65 select NEED_SG_DMA_LENGTH
Christoph Hellwigcd57d072020-07-14 14:18:55 +020066 select NO_DMA if !MMU && !DMA_COHERENT
Christoph Hellwig582dc532020-07-14 14:18:48 +020067 select NO_GENERIC_PCI_IOPORT_MAP if PCI
68 select OLD_SIGACTION
69 select OLD_SIGSUSPEND
70 select PCI_DOMAINS if PCI
71 select PERF_EVENTS
72 select PERF_USE_VMALLOC
73 select RTC_LIB
Christoph Hellwig5e6e9852020-09-03 16:22:35 +020074 select SET_FS
Christoph Hellwig582dc532020-07-14 14:18:48 +020075 select SPARSE_IRQ
Arnd Bergmann37744fe2020-04-20 11:37:12 +020076 help
77 The SuperH is a RISC processor targeted for use in embedded systems
78 and consumer electronics; it was also used in the Sega Dreamcast
79 gaming console. The SuperH port has a home page at
80 <http://www.linux-sh.org/>.
Paul Mundt39d28a22007-11-08 18:39:33 +090081
Paul Mundtfa691512007-03-08 19:41:21 +090082config GENERIC_BUG
83 def_bool y
Arnd Bergmann37744fe2020-04-20 11:37:12 +020084 depends on BUG
Paul Mundt3767f3f2009-06-15 00:00:42 +090085
Akinobu Mitae2268c72006-03-26 01:39:35 -080086config GENERIC_HWEIGHT
Harvey Harrisond7ef4fb2007-12-11 13:49:35 +090087 def_bool y
Akinobu Mitae2268c72006-03-26 01:39:35 -080088
Linus Torvalds1da177e2005-04-16 15:20:36 -070089config GENERIC_CALIBRATE_DELAY
Paul Mundtcf204fa2008-09-08 20:47:42 +090090 bool
Linus Torvalds1da177e2005-04-16 15:20:36 -070091
Paul Mundtbdcab872008-08-04 14:09:15 +090092config GENERIC_LOCKBREAK
93 def_bool y
Thomas Gleixner7be60cc2019-10-15 21:18:05 +020094 depends on SMP && PREEMPTION
Paul Mundtbdcab872008-08-04 14:09:15 +090095
Magnus Dammaf998a92008-12-04 22:45:12 +090096config ARCH_SUSPEND_POSSIBLE
97 def_bool n
98
99config ARCH_HIBERNATION_POSSIBLE
100 def_bool n
Paul Mundt357d5942007-06-11 15:32:07 +0900101
Paul Mundt0a9b0db2007-01-24 21:56:20 +0900102config SYS_SUPPORTS_APM_EMULATION
103 bool
Magnus Dammaf998a92008-12-04 22:45:12 +0900104 select ARCH_SUSPEND_POSSIBLE
Paul Mundt357d5942007-06-11 15:32:07 +0900105
Paul Mundtffb4a732009-10-27 07:22:37 +0900106config SYS_SUPPORTS_HUGETLBFS
107 bool
108
Paul Mundt357d5942007-06-11 15:32:07 +0900109config SYS_SUPPORTS_SMP
110 bool
111
112config SYS_SUPPORTS_NUMA
113 bool
114
Paul Mundtafbfb522006-12-04 18:17:28 +0900115config STACKTRACE_SUPPORT
Harvey Harrisond7ef4fb2007-12-11 13:49:35 +0900116 def_bool y
Paul Mundtafbfb522006-12-04 18:17:28 +0900117
118config LOCKDEP_SUPPORT
Harvey Harrisond7ef4fb2007-12-11 13:49:35 +0900119 def_bool y
Paul Mundtafbfb522006-12-04 18:17:28 +0900120
David Howellsf0d1b0b2006-12-08 02:37:49 -0800121config ARCH_HAS_ILOG2_U32
Harvey Harrisond7ef4fb2007-12-11 13:49:35 +0900122 def_bool n
David Howellsf0d1b0b2006-12-08 02:37:49 -0800123
124config ARCH_HAS_ILOG2_U64
Harvey Harrisond7ef4fb2007-12-11 13:49:35 +0900125 def_bool n
David Howellsf0d1b0b2006-12-08 02:37:49 -0800126
Uwe Kleine-Königce816fa2014-04-07 15:39:19 -0700127config NO_IOPORT_MAP
Paul Mundt37b7a972010-11-01 09:49:04 -0400128 def_bool !PCI
Geert Uytterhoeven8a8e5462020-06-17 08:55:38 +0200129 depends on !SH_SH4202_MICRODEV && !SH_SHMIN && !SH_HP6XX && \
130 !SH_SOLUTION_ENGINE
Paul Mundt86e4dd52010-05-25 20:06:13 +0900131
Magnus Damme7cc9a72008-02-07 20:18:21 +0900132config IO_TRAPPED
133 bool
134
Paul Mundtb7e68d62012-03-29 16:05:10 +0900135config SWAP_IO_SPACE
136 bool
137
Paul Mundt01be5d62009-10-27 10:35:02 +0900138config DMA_COHERENT
139 bool
140
141config DMA_NONCOHERENT
Christoph Hellwigcd57d072020-07-14 14:18:55 +0200142 def_bool !NO_DMA && !DMA_COHERENT
Christoph Hellwig6dfdf672020-07-14 14:18:56 +0200143 select ARCH_HAS_DMA_PREP_COHERENT
Christoph Hellwig6fa1d282018-05-11 08:36:53 +0200144 select ARCH_HAS_SYNC_DMA_FOR_DEVICE
Christoph Hellwig6dfdf672020-07-14 14:18:56 +0200145 select DMA_DIRECT_REMAP
Paul Mundt01be5d62009-10-27 10:35:02 +0900146
Kirill A. Shutemov69543d62015-04-14 15:46:02 -0700147config PGTABLE_LEVELS
148 default 3 if X2TLB
149 default 2
150
Linus Torvalds1da177e2005-04-16 15:20:36 -0700151menu "System type"
152
Paul Mundtb5f42db2007-11-08 18:38:14 +0900153#
154# Processor families
155#
156config CPU_SH2
157 bool
Geert Uytterhoeven049d2802014-08-20 15:39:22 +0200158 select SH_INTC
Paul Mundtb5f42db2007-11-08 18:38:14 +0900159
160config CPU_SH2A
161 bool
162 select CPU_SH2
Paul Mundte2fcf742010-11-04 12:32:24 +0900163 select UNCACHED_MAPPING
Paul Mundtb5f42db2007-11-08 18:38:14 +0900164
Rich Felker5a846ab2016-03-17 23:09:37 +0000165config CPU_J2
166 bool
167 select CPU_SH2
168 select OF
169 select OF_EARLY_FLATTREE
170
Paul Mundtb5f42db2007-11-08 18:38:14 +0900171config CPU_SH3
172 bool
173 select CPU_HAS_INTEVT
174 select CPU_HAS_SR_RB
Geert Uytterhoeven049d2802014-08-20 15:39:22 +0200175 select SH_INTC
Magnus Dammfbfa8932014-02-20 12:54:47 +0100176 select SYS_SUPPORTS_SH_TMU
Paul Mundtb5f42db2007-11-08 18:38:14 +0900177
178config CPU_SH4
179 bool
180 select CPU_HAS_INTEVT
181 select CPU_HAS_SR_RB
Paul Mundtb5f42db2007-11-08 18:38:14 +0900182 select CPU_HAS_FPU if !CPU_SH4AL_DSP
Geert Uytterhoeven049d2802014-08-20 15:39:22 +0200183 select SH_INTC
Magnus Dammfbfa8932014-02-20 12:54:47 +0100184 select SYS_SUPPORTS_SH_TMU
Paul Mundtffb4a732009-10-27 07:22:37 +0900185 select SYS_SUPPORTS_HUGETLBFS if MMU
Paul Mundtb5f42db2007-11-08 18:38:14 +0900186
187config CPU_SH4A
188 bool
189 select CPU_SH4
190
191config CPU_SH4AL_DSP
192 bool
193 select CPU_SH4A
194 select CPU_HAS_DSP
195
196config CPU_SHX2
197 bool
198
199config CPU_SHX3
200 bool
Paul Mundt01be5d62009-10-27 10:35:02 +0900201 select DMA_COHERENT
Paul Mundt4b478ee2010-05-11 15:24:04 +0900202 select SYS_SUPPORTS_SMP
203 select SYS_SUPPORTS_NUMA
Paul Mundtb5f42db2007-11-08 18:38:14 +0900204
Paul Mundtdc65a972009-03-10 16:26:29 +0900205config ARCH_SHMOBILE
206 bool
Magnus Damm77594912009-03-13 15:23:04 +0000207 select ARCH_SUSPEND_POSSIBLE
Rafael J. Wysocki464ed182014-12-19 15:37:54 +0100208 select PM
Paul Mundtdc65a972009-03-10 16:26:29 +0900209
Matt Fleming86c8c042010-09-10 20:36:23 +0100210config CPU_HAS_PMU
211 depends on CPU_SH4 || CPU_SH4A
212 default y
213 bool
214
Paul Mundtb5f42db2007-11-08 18:38:14 +0900215choice
216 prompt "Processor sub-type selection"
217
218#
219# Processor subtypes
220#
221
222# SH-2 Processor Support
223
224config CPU_SUBTYPE_SH7619
225 bool "Support SH7619 processor"
226 select CPU_SH2
Magnus Dammfbfa8932014-02-20 12:54:47 +0100227 select SYS_SUPPORTS_SH_CMT
Paul Mundtb5f42db2007-11-08 18:38:14 +0900228
Rich Felker5a846ab2016-03-17 23:09:37 +0000229config CPU_SUBTYPE_J2
230 bool "Support J2 processor"
231 select CPU_J2
Rich Felkerb4214e42016-02-15 18:36:13 +0000232 select SYS_SUPPORTS_SMP
233 select GENERIC_CLOCKEVENTS_BROADCAST if SMP
Rich Felker5a846ab2016-03-17 23:09:37 +0000234
Paul Mundtb5f42db2007-11-08 18:38:14 +0900235# SH-2A Processor Support
236
Peter Griffin28259992008-11-28 22:48:20 +0900237config CPU_SUBTYPE_SH7201
238 bool "Support SH7201 processor"
239 select CPU_SH2A
240 select CPU_HAS_FPU
Magnus Dammfbfa8932014-02-20 12:54:47 +0100241 select SYS_SUPPORTS_SH_MTU2
Peter Griffin28259992008-11-28 22:48:20 +0900242
Paul Mundt6d01f512007-11-26 18:17:21 +0900243config CPU_SUBTYPE_SH7203
244 bool "Support SH7203 processor"
245 select CPU_SH2A
Paul Mundt74d99a52007-11-26 20:38:36 +0900246 select CPU_HAS_FPU
Magnus Dammfbfa8932014-02-20 12:54:47 +0100247 select SYS_SUPPORTS_SH_CMT
248 select SYS_SUPPORTS_SH_MTU2
Laurent Pinchartb768ecbc2012-12-15 23:51:05 +0100249 select PINCTRL
Paul Mundt6d01f512007-11-26 18:17:21 +0900250
Paul Mundtb5f42db2007-11-08 18:38:14 +0900251config CPU_SUBTYPE_SH7206
252 bool "Support SH7206 processor"
253 select CPU_SH2A
Magnus Dammfbfa8932014-02-20 12:54:47 +0100254 select SYS_SUPPORTS_SH_CMT
255 select SYS_SUPPORTS_SH_MTU2
Paul Mundtb5f42db2007-11-08 18:38:14 +0900256
Paul Mundta8f67f42007-11-26 19:54:02 +0900257config CPU_SUBTYPE_SH7263
258 bool "Support SH7263 processor"
259 select CPU_SH2A
Paul Mundt74d99a52007-11-26 20:38:36 +0900260 select CPU_HAS_FPU
Magnus Dammfbfa8932014-02-20 12:54:47 +0100261 select SYS_SUPPORTS_SH_CMT
262 select SYS_SUPPORTS_SH_MTU2
Paul Mundta8f67f42007-11-26 19:54:02 +0900263
Phil Edworthy51ce3062012-05-09 07:59:27 +0100264config CPU_SUBTYPE_SH7264
265 bool "Support SH7264 processor"
266 select CPU_SH2A
267 select CPU_HAS_FPU
Magnus Dammfbfa8932014-02-20 12:54:47 +0100268 select SYS_SUPPORTS_SH_CMT
269 select SYS_SUPPORTS_SH_MTU2
Laurent Pinchart5946e7b2012-12-15 23:51:06 +0100270 select PINCTRL
Phil Edworthy51ce3062012-05-09 07:59:27 +0100271
Phil Edworthy0b25b7c2012-05-10 09:26:52 +0100272config CPU_SUBTYPE_SH7269
273 bool "Support SH7269 processor"
274 select CPU_SH2A
275 select CPU_HAS_FPU
Magnus Dammfbfa8932014-02-20 12:54:47 +0100276 select SYS_SUPPORTS_SH_CMT
277 select SYS_SUPPORTS_SH_MTU2
Laurent Pinchartfb872fc2012-12-15 23:51:07 +0100278 select PINCTRL
Phil Edworthy0b25b7c2012-05-10 09:26:52 +0100279
Paul Mundt2ad69902008-03-13 12:52:44 +0900280config CPU_SUBTYPE_MXG
281 bool "Support MX-G processor"
282 select CPU_SH2A
Magnus Dammfbfa8932014-02-20 12:54:47 +0100283 select SYS_SUPPORTS_SH_MTU2
Paul Mundt2ad69902008-03-13 12:52:44 +0900284 help
285 Select MX-G if running on an R8A03022BG part.
286
Paul Mundtb5f42db2007-11-08 18:38:14 +0900287# SH-3 Processor Support
288
289config CPU_SUBTYPE_SH7705
290 bool "Support SH7705 processor"
291 select CPU_SH3
292
293config CPU_SUBTYPE_SH7706
294 bool "Support SH7706 processor"
295 select CPU_SH3
296 help
297 Select SH7706 if you have a 133 Mhz SH-3 HD6417706 CPU.
298
299config CPU_SUBTYPE_SH7707
300 bool "Support SH7707 processor"
301 select CPU_SH3
302 help
303 Select SH7707 if you have a 60 Mhz SH-3 HD6417707 CPU.
304
305config CPU_SUBTYPE_SH7708
306 bool "Support SH7708 processor"
307 select CPU_SH3
308 help
309 Select SH7708 if you have a 60 Mhz SH-3 HD6417708S or
310 if you have a 100 Mhz SH-3 HD6417708R CPU.
311
312config CPU_SUBTYPE_SH7709
313 bool "Support SH7709 processor"
314 select CPU_SH3
315 help
316 Select SH7709 if you have a 80 Mhz SH-3 HD6417709 CPU.
317
318config CPU_SUBTYPE_SH7710
319 bool "Support SH7710 processor"
320 select CPU_SH3
321 select CPU_HAS_DSP
322 help
323 Select SH7710 if you have a SH3-DSP SH7710 CPU.
324
325config CPU_SUBTYPE_SH7712
326 bool "Support SH7712 processor"
327 select CPU_SH3
328 select CPU_HAS_DSP
329 help
330 Select SH7712 if you have a SH3-DSP SH7712 CPU.
331
332config CPU_SUBTYPE_SH7720
333 bool "Support SH7720 processor"
334 select CPU_SH3
335 select CPU_HAS_DSP
Magnus Dammfbfa8932014-02-20 12:54:47 +0100336 select SYS_SUPPORTS_SH_CMT
Paul Mundt7b61ca52011-06-30 15:04:38 +0900337 select USB_OHCI_SH if USB_OHCI_HCD
Laurent Pinchart85db6bf2012-12-15 23:51:08 +0100338 select PINCTRL
Paul Mundtb5f42db2007-11-08 18:38:14 +0900339 help
340 Select SH7720 if you have a SH3-DSP SH7720 CPU.
341
Yoshihiro Shimoda31a49c42007-12-26 11:45:06 +0900342config CPU_SUBTYPE_SH7721
343 bool "Support SH7721 processor"
344 select CPU_SH3
345 select CPU_HAS_DSP
Magnus Dammfbfa8932014-02-20 12:54:47 +0100346 select SYS_SUPPORTS_SH_CMT
Paul Mundt7b61ca52011-06-30 15:04:38 +0900347 select USB_OHCI_SH if USB_OHCI_HCD
Yoshihiro Shimoda31a49c42007-12-26 11:45:06 +0900348 help
349 Select SH7721 if you have a SH3-DSP SH7721 CPU.
350
Paul Mundtb5f42db2007-11-08 18:38:14 +0900351# SH-4 Processor Support
352
353config CPU_SUBTYPE_SH7750
354 bool "Support SH7750 processor"
355 select CPU_SH4
356 help
357 Select SH7750 if you have a 200 Mhz SH-4 HD6417750 CPU.
358
359config CPU_SUBTYPE_SH7091
360 bool "Support SH7091 processor"
361 select CPU_SH4
362 help
363 Select SH7091 if you have an SH-4 based Sega device (such as
364 the Dreamcast, Naomi, and Naomi 2).
365
366config CPU_SUBTYPE_SH7750R
367 bool "Support SH7750R processor"
368 select CPU_SH4
369
370config CPU_SUBTYPE_SH7750S
371 bool "Support SH7750S processor"
372 select CPU_SH4
373
374config CPU_SUBTYPE_SH7751
375 bool "Support SH7751 processor"
376 select CPU_SH4
377 help
378 Select SH7751 if you have a 166 Mhz SH-4 HD6417751 CPU,
379 or if you have a HD6417751R CPU.
380
381config CPU_SUBTYPE_SH7751R
382 bool "Support SH7751R processor"
383 select CPU_SH4
384
385config CPU_SUBTYPE_SH7760
386 bool "Support SH7760 processor"
387 select CPU_SH4
388
389config CPU_SUBTYPE_SH4_202
390 bool "Support SH4-202 processor"
391 select CPU_SH4
392
393# SH-4A Processor Support
394
Paul Mundt178dd0c2008-04-09 17:56:18 +0900395config CPU_SUBTYPE_SH7723
396 bool "Support SH7723 processor"
397 select CPU_SH4A
398 select CPU_SHX2
Paul Mundtdc65a972009-03-10 16:26:29 +0900399 select ARCH_SHMOBILE
Paul Mundt178dd0c2008-04-09 17:56:18 +0900400 select ARCH_SPARSEMEM_ENABLE
Magnus Dammfbfa8932014-02-20 12:54:47 +0100401 select SYS_SUPPORTS_SH_CMT
Laurent Pinchart16941a82012-12-15 23:51:10 +0100402 select PINCTRL
Paul Mundt178dd0c2008-04-09 17:56:18 +0900403 help
404 Select SH7723 if you have an SH-MobileR2 CPU.
405
Kuninori Morimoto0207a2e2009-04-16 14:40:56 +0900406config CPU_SUBTYPE_SH7724
407 bool "Support SH7724 processor"
408 select CPU_SH4A
409 select CPU_SHX2
Paul Mundt59fe7002009-04-16 15:43:42 +0900410 select ARCH_SHMOBILE
Kuninori Morimoto0207a2e2009-04-16 14:40:56 +0900411 select ARCH_SPARSEMEM_ENABLE
Magnus Dammfbfa8932014-02-20 12:54:47 +0100412 select SYS_SUPPORTS_SH_CMT
Laurent Pinchart18ebd222012-12-15 23:51:11 +0100413 select PINCTRL
Kuninori Morimoto0207a2e2009-04-16 14:40:56 +0900414 help
415 Select SH7724 if you have an SH-MobileR2R CPU.
416
Nobuhiro Iwamatsufea88a02012-04-12 15:45:32 +0900417config CPU_SUBTYPE_SH7734
418 bool "Support SH7734 processor"
419 select CPU_SH4A
420 select CPU_SHX2
Laurent Pinchart2c172182012-12-15 23:51:12 +0100421 select PINCTRL
Nobuhiro Iwamatsufea88a02012-04-12 15:45:32 +0900422 help
423 Select SH7734 if you have a SH4A SH7734 CPU.
424
Yoshihiro Shimodac01f0f12009-08-21 16:30:28 +0900425config CPU_SUBTYPE_SH7757
426 bool "Support SH7757 processor"
427 select CPU_SH4A
428 select CPU_SHX2
Laurent Pincharteb61b772012-12-15 23:51:13 +0100429 select PINCTRL
Yoshihiro Shimodac01f0f12009-08-21 16:30:28 +0900430 help
431 Select SH7757 if you have a SH4A SH7757 CPU.
432
Yoshihiro Shimoda7d740a02008-01-07 14:40:07 +0900433config CPU_SUBTYPE_SH7763
434 bool "Support SH7763 processor"
435 select CPU_SH4A
Paul Mundt7b61ca52011-06-30 15:04:38 +0900436 select USB_OHCI_SH if USB_OHCI_HCD
Yoshihiro Shimoda7d740a02008-01-07 14:40:07 +0900437 help
438 Select SH7763 if you have a SH4A SH7763(R5S77631) CPU.
439
Paul Mundtb5f42db2007-11-08 18:38:14 +0900440config CPU_SUBTYPE_SH7770
441 bool "Support SH7770 processor"
442 select CPU_SH4A
443
444config CPU_SUBTYPE_SH7780
445 bool "Support SH7780 processor"
446 select CPU_SH4A
447
448config CPU_SUBTYPE_SH7785
449 bool "Support SH7785 processor"
450 select CPU_SH4A
451 select CPU_SHX2
452 select ARCH_SPARSEMEM_ENABLE
453 select SYS_SUPPORTS_NUMA
Laurent Pinchart77bd27b2012-12-15 23:51:14 +0100454 select PINCTRL
Paul Mundtb5f42db2007-11-08 18:38:14 +0900455
Kuninori Morimoto55ba99e2009-03-03 15:40:25 +0900456config CPU_SUBTYPE_SH7786
457 bool "Support SH7786 processor"
458 select CPU_SH4A
Paul Mundt37042fb2009-03-03 15:57:02 +0900459 select CPU_SHX3
Paul Mundt8263a672009-03-17 17:49:49 +0900460 select CPU_HAS_PTEAEX
Paul Mundt2eb2a432009-06-19 16:00:00 +0900461 select GENERIC_CLOCKEVENTS_BROADCAST if SMP
Paul Mundt7b61ca52011-06-30 15:04:38 +0900462 select USB_OHCI_SH if USB_OHCI_HCD
Paul Mundt7b61ca52011-06-30 15:04:38 +0900463 select USB_EHCI_SH if USB_EHCI_HCD
Laurent Pinchartc0fdbff2012-12-15 23:51:15 +0100464 select PINCTRL
Kuninori Morimoto55ba99e2009-03-03 15:40:25 +0900465
Paul Mundtb5f42db2007-11-08 18:38:14 +0900466config CPU_SUBTYPE_SHX3
467 bool "Support SH-X3 processor"
468 select CPU_SH4A
469 select CPU_SHX3
Paul Mundt58402632008-09-05 15:36:39 +0900470 select GENERIC_CLOCKEVENTS_BROADCAST if SMP
Linus Walleijfdcfdfa2016-04-19 13:26:08 +0200471 select GPIOLIB
Laurent Pinchart3e347f02012-12-15 23:51:16 +0100472 select PINCTRL
Paul Mundtb5f42db2007-11-08 18:38:14 +0900473
474# SH4AL-DSP Processor Support
475
476config CPU_SUBTYPE_SH7343
477 bool "Support SH7343 processor"
478 select CPU_SH4AL_DSP
Paul Mundtdc65a972009-03-10 16:26:29 +0900479 select ARCH_SHMOBILE
Magnus Dammfbfa8932014-02-20 12:54:47 +0100480 select SYS_SUPPORTS_SH_CMT
Paul Mundtb5f42db2007-11-08 18:38:14 +0900481
482config CPU_SUBTYPE_SH7722
483 bool "Support SH7722 processor"
484 select CPU_SH4AL_DSP
485 select CPU_SHX2
Paul Mundtdc65a972009-03-10 16:26:29 +0900486 select ARCH_SHMOBILE
Paul Mundtb5f42db2007-11-08 18:38:14 +0900487 select ARCH_SPARSEMEM_ENABLE
488 select SYS_SUPPORTS_NUMA
Magnus Dammfbfa8932014-02-20 12:54:47 +0100489 select SYS_SUPPORTS_SH_CMT
Laurent Pinchartef97c3c2012-12-15 23:51:09 +0100490 select PINCTRL
Paul Mundtb5f42db2007-11-08 18:38:14 +0900491
Magnus Damm9109a302008-02-08 17:31:24 +0900492config CPU_SUBTYPE_SH7366
493 bool "Support SH7366 processor"
494 select CPU_SH4AL_DSP
495 select CPU_SHX2
Paul Mundtdc65a972009-03-10 16:26:29 +0900496 select ARCH_SHMOBILE
Magnus Damm9109a302008-02-08 17:31:24 +0900497 select ARCH_SPARSEMEM_ENABLE
498 select SYS_SUPPORTS_NUMA
Magnus Dammfbfa8932014-02-20 12:54:47 +0100499 select SYS_SUPPORTS_SH_CMT
Magnus Damm9109a302008-02-08 17:31:24 +0900500
Paul Mundt3cc000b2009-04-11 08:39:27 +0900501endchoice
502
Paul Mundtcad82442006-01-16 22:14:19 -0800503source "arch/sh/mm/Kconfig"
Paul Mundt939a24a2008-07-29 21:41:37 +0900504
Paul Mundt4690bdc2007-11-09 13:45:42 +0900505source "arch/sh/Kconfig.cpu"
Paul Mundtcad82442006-01-16 22:14:19 -0800506
Paul Mundt939a24a2008-07-29 21:41:37 +0900507source "arch/sh/boards/Kconfig"
Paul Mundtf3d22292007-05-14 17:29:12 +0900508
Paul Mundt32351a22007-03-12 14:38:59 +0900509menu "Timer and clock configuration"
510
Paul Mundtcad82442006-01-16 22:14:19 -0800511config SH_PCLK_FREQ
512 int "Peripheral clock frequency (in Hz)"
Paul Mundt8152a742009-12-29 11:09:30 +0900513 depends on SH_CLK_CPG_LEGACY
Yoshinori Sato9d4436a2006-11-05 15:40:13 +0900514 default "31250000" if CPU_SUBTYPE_SH7619
Paul Mundt8152a742009-12-29 11:09:30 +0900515 default "33333333" if CPU_SUBTYPE_SH7770 || \
516 CPU_SUBTYPE_SH7760 || \
517 CPU_SUBTYPE_SH7705 || \
518 CPU_SUBTYPE_SH7203 || \
519 CPU_SUBTYPE_SH7206 || \
520 CPU_SUBTYPE_SH7263 || \
Paul Mundt43a18392010-01-19 19:37:14 +0900521 CPU_SUBTYPE_MXG
Paul Mundt05627482007-05-15 16:25:47 +0900522 default "60000000" if CPU_SUBTYPE_SH7751 || CPU_SUBTYPE_SH7751R
Paul Mundtcad82442006-01-16 22:14:19 -0800523 default "66000000" if CPU_SUBTYPE_SH4_202
Paul Mundt05627482007-05-15 16:25:47 +0900524 default "50000000"
Paul Mundtcad82442006-01-16 22:14:19 -0800525 help
526 This option is used to specify the peripheral clock frequency.
527 This is necessary for determining the reference clock value on
528 platforms lacking an RTC.
529
Paul Mundt36aa1e32009-05-22 14:00:34 +0900530config SH_CLK_CPG
531 def_bool y
532
Paul Mundt253b0882009-05-13 17:38:11 +0900533config SH_CLK_CPG_LEGACY
Paul Mundt36aa1e32009-05-22 14:00:34 +0900534 depends on SH_CLK_CPG
Paul Mundt43a18392010-01-19 19:37:14 +0900535 def_bool y if !CPU_SUBTYPE_SH7785 && !ARCH_SHMOBILE && \
Phil Edworthy51ce3062012-05-09 07:59:27 +0100536 !CPU_SHX3 && !CPU_SUBTYPE_SH7757 && \
Paul Mundtbcb86e02012-05-10 17:20:56 +0900537 !CPU_SUBTYPE_SH7734 && !CPU_SUBTYPE_SH7264 && \
538 !CPU_SUBTYPE_SH7269
Paul Mundt253b0882009-05-13 17:38:11 +0900539
Paul Mundt32351a22007-03-12 14:38:59 +0900540endmenu
541
Paul Mundtcad82442006-01-16 22:14:19 -0800542menu "CPU Frequency scaling"
Paul Mundtcad82442006-01-16 22:14:19 -0800543source "drivers/cpufreq/Kconfig"
Paul Mundtcad82442006-01-16 22:14:19 -0800544endmenu
545
Paul Mundt9f5e8ee2006-11-24 11:22:57 +0900546source "arch/sh/drivers/Kconfig"
547
Paul Mundtcad82442006-01-16 22:14:19 -0800548endmenu
549
Paul Mundtcad82442006-01-16 22:14:19 -0800550menu "Kernel features"
551
Masahiro Yamada8636a1f2018-12-11 20:01:04 +0900552source "kernel/Kconfig.hz"
Paul Mundt91b91d02006-09-27 18:08:33 +0900553
Paul Mundtcad82442006-01-16 22:14:19 -0800554config KEXEC
555 bool "kexec system call (EXPERIMENTAL)"
Arnd Bergmann37744fe2020-04-20 11:37:12 +0200556 depends on MMU
Dave Young2965faa2015-09-09 15:38:55 -0700557 select KEXEC_CORE
Paul Mundtcad82442006-01-16 22:14:19 -0800558 help
559 kexec is a system call that implements the ability to shutdown your
560 current kernel, and to start another kernel. It is like a reboot
Matt LaPlante1f1332f2006-06-29 01:32:47 -0400561 but it is independent of the system firmware. And like a reboot
Paul Mundtcad82442006-01-16 22:14:19 -0800562 you can start any kernel with it, not just Linux.
563
Matt LaPlante1f1332f2006-06-29 01:32:47 -0400564 The name comes from the similarity to the exec system call.
Paul Mundtcad82442006-01-16 22:14:19 -0800565
566 It is an ongoing process to be certain the hardware in a machine
567 is properly shutdown, so do not be surprised if this code does not
Geert Uytterhoevenbf220692013-08-20 21:38:03 +0200568 initially work for you. As of this writing the exact hardware
569 interface is strongly in flux, so no good recommendation can be
570 made.
Paul Mundtcad82442006-01-16 22:14:19 -0800571
Paul Mundt4d5ade52007-04-27 11:25:57 +0900572config CRASH_DUMP
573 bool "kernel crash dumps (EXPERIMENTAL)"
Arnd Bergmann37744fe2020-04-20 11:37:12 +0200574 depends on BROKEN_ON_SMP
Paul Mundt4d5ade52007-04-27 11:25:57 +0900575 help
576 Generate crash dump after being started by kexec.
577 This should be normally only set in special crash dump kernels
578 which are loaded in the main kernel with kexec-tools into
579 a specially reserved region and then later executed after
580 a crash by kdump/kexec. The crash dump kernel must be compiled
581 to a memory address not used by the main kernel using
Simon Hormane66ac3f2011-09-15 20:13:00 +0900582 PHYSICAL_START.
Paul Mundt4d5ade52007-04-27 11:25:57 +0900583
Mauro Carvalho Chehab330d4812019-06-13 15:21:39 -0300584 For more details see Documentation/admin-guide/kdump/kdump.rst
Paul Mundt4d5ade52007-04-27 11:25:57 +0900585
Magnus Dammb7cf6dd2009-03-18 08:51:29 +0000586config KEXEC_JUMP
587 bool "kexec jump (EXPERIMENTAL)"
Arnd Bergmann37744fe2020-04-20 11:37:12 +0200588 depends on KEXEC && HIBERNATION
Magnus Dammb7cf6dd2009-03-18 08:51:29 +0000589 help
590 Jump between original kernel and kexeced kernel and invoke
591 code via KEXEC
592
Simon Hormane66ac3f2011-09-15 20:13:00 +0900593config PHYSICAL_START
594 hex "Physical address where the kernel is loaded" if (EXPERT || CRASH_DUMP)
595 default MEMORY_START
Masahiro Yamadaa7f7f622020-06-14 01:50:22 +0900596 help
Simon Hormane66ac3f2011-09-15 20:13:00 +0900597 This gives the physical address where the kernel is loaded
598 and is ordinarily the same as MEMORY_START.
599
600 Different values are primarily used in the case of kexec on panic
601 where the fail safe kernel needs to run at a different address
602 than the panic-ed kernel.
603
Linus Torvalds1da177e2005-04-16 15:20:36 -0700604config SMP
605 bool "Symmetric multi-processing support"
Paul Mundt357d5942007-06-11 15:32:07 +0900606 depends on SYS_SUPPORTS_SMP
Masahiro Yamadaa7f7f622020-06-14 01:50:22 +0900607 help
Linus Torvalds1da177e2005-04-16 15:20:36 -0700608 This enables support for systems with more than one CPU. If you have
Robert Graffham4a474152014-01-23 15:55:29 -0800609 a system with only one CPU, say N. If you have a system with more
610 than one CPU, say Y.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700611
Robert Graffham4a474152014-01-23 15:55:29 -0800612 If you say N here, the kernel will run on uni- and multiprocessor
Linus Torvalds1da177e2005-04-16 15:20:36 -0700613 machines, but will use only one CPU of a multiprocessor machine. If
614 you say Y here, the kernel will run on many, but not all,
Robert Graffham4a474152014-01-23 15:55:29 -0800615 uniprocessor machines. On a uniprocessor machine, the kernel
Linus Torvalds1da177e2005-04-16 15:20:36 -0700616 will run faster if you say N here.
617
618 People using multiprocessor machines who say Y here should also say
619 Y to "Enhanced Real Time Clock Support", below.
620
Mauro Carvalho Chehab4f4cfa62019-06-27 14:56:51 -0300621 See also <file:Documentation/admin-guide/lockup-watchdogs.rst> and the SMP-HOWTO
Alexander A. Klimov91194e92020-07-12 13:11:18 +0200622 available at <https://www.tldp.org/docs.html#howto>.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700623
624 If you don't know what to do here, say N.
625
626config NR_CPUS
627 int "Maximum number of CPUs (2-32)"
628 range 2 32
629 depends on SMP
Paul Mundt2eb2a432009-06-19 16:00:00 +0900630 default "4" if CPU_SUBTYPE_SHX3
Linus Torvalds1da177e2005-04-16 15:20:36 -0700631 default "2"
632 help
633 This allows you to specify the maximum number of CPUs which this
634 kernel will support. The maximum supported value is 32 and the
635 minimum value which makes sense is 2.
636
637 This is purely to save memory - each supported CPU adds
638 approximately eight kilobytes to the kernel image.
639
Paul Mundt763142d2010-04-26 19:08:55 +0900640config HOTPLUG_CPU
641 bool "Support for hot-pluggable CPUs (EXPERIMENTAL)"
Stephen Rothwell40b31362013-05-21 13:49:35 +1000642 depends on SMP
Paul Mundt763142d2010-04-26 19:08:55 +0900643 help
644 Say Y here to experiment with turning CPUs off and on. CPUs
645 can be controlled through /sys/devices/system/cpu.
646
Paul Mundt83662462007-09-28 16:04:49 +0900647config GUSA
648 def_bool y
Arnd Bergmann37744fe2020-04-20 11:37:12 +0200649 depends on !SMP
Paul Mundt83662462007-09-28 16:04:49 +0900650 help
651 This enables support for gUSA (general UserSpace Atomicity).
652 This is the default implementation for both UP and non-ll/sc
653 CPUs, and is used by the libc, amongst others.
654
655 For additional information, design information can be found
656 in <http://lc.linux.or.jp/lc2002/papers/niibe0919p.pdf>.
657
658 This should only be disabled for special cases where alternate
659 atomicity implementations exist.
660
Stuart Menefy1efe4ce2007-11-30 16:12:36 +0900661config GUSA_RB
662 bool "Implement atomic operations by roll-back (gRB) (EXPERIMENTAL)"
663 depends on GUSA && CPU_SH3 || (CPU_SH4 && !CPU_SH4A)
664 help
665 Enabling this option will allow the kernel to implement some
Matt LaPlante692105b2009-01-26 11:12:25 +0100666 atomic operations using a software implementation of load-locked/
Stuart Menefy1efe4ce2007-11-30 16:12:36 +0900667 store-conditional (LLSC). On machines which do not have hardware
668 LLSC, this should be more efficient than the other alternative of
Matt LaPlante692105b2009-01-26 11:12:25 +0100669 disabling interrupts around the atomic sequence.
Stuart Menefy1efe4ce2007-11-30 16:12:36 +0900670
Matt Fleming86c8c042010-09-10 20:36:23 +0100671config HW_PERF_EVENTS
672 bool "Enable hardware performance counter support for perf events"
673 depends on PERF_EVENTS && CPU_HAS_PMU
674 default y
675 help
676 Enable hardware performance counter support for perf events. If
677 disabled, perf events will use software events only.
678
Paul Mundt43b87742010-04-13 14:43:03 +0900679source "drivers/sh/Kconfig"
680
Paul Mundtcad82442006-01-16 22:14:19 -0800681endmenu
682
683menu "Boot options"
684
Rich Felker190fe192016-03-26 01:24:30 +0000685config USE_BUILTIN_DTB
686 bool "Use builtin DTB"
687 default n
688 depends on SH_DEVICE_TREE
689 help
690 Link a device tree blob for particular hardware into the kernel,
691 suppressing use of the DTB pointer provided by the bootloader.
692 This option should only be used with legacy bootloaders that are
693 not capable of providing a DTB to the kernel, or for experimental
694 hardware without stable device tree bindings.
695
696config BUILTIN_DTB_SOURCE
697 string "Source file for builtin DTB"
698 default ""
699 depends on USE_BUILTIN_DTB
700 help
701 Base name (without suffix, relative to arch/sh/boot/dts) for the
702 a DTS file that will be used to produce the DTB linked into the
703 kernel.
704
Paul Mundtcad82442006-01-16 22:14:19 -0800705config ZERO_PAGE_OFFSET
Paul Mundtb412a49a2009-05-10 01:23:25 +0900706 hex
707 default "0x00010000" if PAGE_SIZE_64KB || SH_RTS7751R2D || \
708 SH_7751_SOLUTION_ENGINE
709 default "0x00004000" if PAGE_SIZE_16KB || SH_SH03
Paul Mundt7a847f82006-12-26 15:29:19 +0900710 default "0x00002000" if PAGE_SIZE_8KB
Paul Mundtcad82442006-01-16 22:14:19 -0800711 default "0x00001000"
Linus Torvalds1da177e2005-04-16 15:20:36 -0700712 help
Paul Mundtcad82442006-01-16 22:14:19 -0800713 This sets the default offset of zero page.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700714
Paul Mundtcad82442006-01-16 22:14:19 -0800715config BOOT_LINK_OFFSET
Paul Mundtb412a49a2009-05-10 01:23:25 +0900716 hex
717 default "0x00210000" if SH_SHMIN
Paul Mundtb412a49a2009-05-10 01:23:25 +0900718 default "0x00810000" if SH_7780_SOLUTION_ENGINE
719 default "0x009e0000" if SH_TITAN
720 default "0x01800000" if SH_SDK7780
721 default "0x02000000" if SH_EDOSK7760
Paul Mundtcad82442006-01-16 22:14:19 -0800722 default "0x00800000"
Linus Torvalds1da177e2005-04-16 15:20:36 -0700723 help
Paul Mundtcad82442006-01-16 22:14:19 -0800724 This option allows you to set the link address offset of the zImage.
725 This can be useful if you are on a board which has a small amount of
726 memory.
Linus Torvalds1da177e2005-04-16 15:20:36 -0700727
Paul Mundtb412a49a2009-05-10 01:23:25 +0900728config ENTRY_OFFSET
729 hex
730 default "0x00001000" if PAGE_SIZE_4KB
731 default "0x00002000" if PAGE_SIZE_8KB
732 default "0x00004000" if PAGE_SIZE_16KB
733 default "0x00010000" if PAGE_SIZE_64KB
734 default "0x00000000"
735
Magnus Damm4705b2e2010-05-18 14:43:15 +0000736config ROMIMAGE_MMCIF
737 bool "Include MMCIF loader in romImage (EXPERIMENTAL)"
Kees Cook0d57af12013-01-16 18:53:26 -0800738 depends on CPU_SUBTYPE_SH7724
Magnus Damm4705b2e2010-05-18 14:43:15 +0000739 help
740 Say Y here to include experimental MMCIF loading code in
741 romImage. With this enabled it is possible to write the romImage
742 kernel image to an MMC card and boot the kernel straight from
743 the reset vector. At reset the processor Mask ROM will load the
744 first part of the romImage which in turn loads the rest the kernel
745 image to RAM using the MMCIF hardware block.
746
Pawel Molld724a9c2009-08-24 16:25:38 +0900747choice
748 prompt "Kernel command line"
749 optional
750 default CMDLINE_OVERWRITE
751 help
752 Setting this option allows the kernel command line arguments
753 to be set.
754
755config CMDLINE_OVERWRITE
756 bool "Overwrite bootloader kernel arguments"
757 help
758 Given string will overwrite any arguments passed in by
759 a bootloader.
760
761config CMDLINE_EXTEND
762 bool "Extend bootloader kernel arguments"
763 help
764 Given string will be concatenated with arguments passed in
765 by a bootloader.
766
767endchoice
Linus Torvalds1da177e2005-04-16 15:20:36 -0700768
Paul Mundtcad82442006-01-16 22:14:19 -0800769config CMDLINE
Pawel Molld724a9c2009-08-24 16:25:38 +0900770 string "Kernel command line arguments string"
771 depends on CMDLINE_OVERWRITE || CMDLINE_EXTEND
Paul Mundtcad82442006-01-16 22:14:19 -0800772 default "console=ttySC1,115200"
Linus Torvalds1da177e2005-04-16 15:20:36 -0700773
774endmenu
775
Paul Mundtcad82442006-01-16 22:14:19 -0800776menu "Bus options"
Linus Torvalds1da177e2005-04-16 15:20:36 -0700777
Paul Mundtcad82442006-01-16 22:14:19 -0800778config SUPERHYWAY
779 tristate "SuperHyway Bus support"
780 depends on CPU_SUBTYPE_SH4_202
Linus Torvalds1da177e2005-04-16 15:20:36 -0700781
Adrian McMenamin17be2d22007-09-21 15:55:55 +0900782config MAPLE
Paul Mundte16038a2009-01-09 15:12:30 +0900783 bool "Maple Bus support"
784 depends on SH_DREAMCAST
785 help
786 The Maple Bus is SEGA's serial communication bus for peripherals
787 on the Dreamcast. Without this bus support you won't be able to
788 get your Dreamcast keyboard etc to work, so most users
789 probably want to say 'Y' here, unless you are only using the
790 Dreamcast with a serial line terminal or a remote network
791 connection.
Adrian McMenamin17be2d22007-09-21 15:55:55 +0900792
Linus Torvalds1da177e2005-04-16 15:20:36 -0700793endmenu
794
Andriy Skulysh3aa770e2006-09-27 16:20:22 +0900795menu "Power management options (EXPERIMENTAL)"
Johannes Bergf4cb5702007-12-08 02:14:00 +0100796
Magnus Dammc6f17cb2008-12-04 22:45:20 +0900797source "kernel/power/Kconfig"
798
799source "drivers/cpuidle/Kconfig"
Andriy Skulysh3aa770e2006-09-27 16:20:22 +0900800
Andriy Skulysh3aa770e2006-09-27 16:20:22 +0900801endmenu