xref: /linux/arch/csky/Kconfig (revision daac95e70f482e7add3305ee5e38f00dca505268)
1c32e64e8SGuo Renconfig CSKY
2c32e64e8SGuo Ren	def_bool y
3942fa985SYury Norov	select ARCH_32BIT_OFF_T
4c32e64e8SGuo Ren	select ARCH_HAS_SYNC_DMA_FOR_CPU
5c32e64e8SGuo Ren	select ARCH_HAS_SYNC_DMA_FOR_DEVICE
6c32e64e8SGuo Ren	select ARCH_USE_BUILTIN_BSWAP
7c32e64e8SGuo Ren	select ARCH_USE_QUEUED_RWLOCKS if NR_CPUS>2
8c32e64e8SGuo Ren	select COMMON_CLK
9c32e64e8SGuo Ren	select CLKSRC_MMIO
10c32e64e8SGuo Ren	select CLKSRC_OF
11f04b951fSChristoph Hellwig	select DMA_DIRECT_REMAP
12c32e64e8SGuo Ren	select IRQ_DOMAIN
13c32e64e8SGuo Ren	select HANDLE_DOMAIN_IRQ
14c32e64e8SGuo Ren	select DW_APB_TIMER_OF
15c32e64e8SGuo Ren	select GENERIC_LIB_ASHLDI3
16c32e64e8SGuo Ren	select GENERIC_LIB_ASHRDI3
17c32e64e8SGuo Ren	select GENERIC_LIB_LSHRDI3
18c32e64e8SGuo Ren	select GENERIC_LIB_MULDI3
19c32e64e8SGuo Ren	select GENERIC_LIB_CMPDI2
20c32e64e8SGuo Ren	select GENERIC_LIB_UCMPDI2
21c32e64e8SGuo Ren	select GENERIC_ALLOCATOR
22c32e64e8SGuo Ren	select GENERIC_ATOMIC64
23c32e64e8SGuo Ren	select GENERIC_CLOCKEVENTS
24c32e64e8SGuo Ren	select GENERIC_CPU_DEVICES
25c32e64e8SGuo Ren	select GENERIC_IRQ_CHIP
26c32e64e8SGuo Ren	select GENERIC_IRQ_PROBE
27c32e64e8SGuo Ren	select GENERIC_IRQ_SHOW
28c32e64e8SGuo Ren	select GENERIC_IRQ_MULTI_HANDLER
29c32e64e8SGuo Ren	select GENERIC_SCHED_CLOCK
30c32e64e8SGuo Ren	select GENERIC_SMP_IDLE_THREAD
31c32e64e8SGuo Ren	select HAVE_ARCH_TRACEHOOK
322f7932b0SGuo Ren	select HAVE_ARCH_AUDITSYSCALL
3328bb030fSGuo Ren	select HAVE_DYNAMIC_FTRACE
34230c77a5SGuo Ren	select HAVE_FUNCTION_TRACER
35d7950be1SGuo Ren	select HAVE_FUNCTION_GRAPH_TRACER
3628bb030fSGuo Ren	select HAVE_FTRACE_MCOUNT_RECORD
37c32e64e8SGuo Ren	select HAVE_KERNEL_GZIP
38c32e64e8SGuo Ren	select HAVE_KERNEL_LZO
39c32e64e8SGuo Ren	select HAVE_KERNEL_LZMA
40f50fd2d8SGuo Ren	select HAVE_PERF_EVENTS
41*daac95e7SMao Han	select HAVE_PERF_REGS
42*daac95e7SMao Han	select HAVE_PERF_USER_STACK_DUMP
43c32e64e8SGuo Ren	select HAVE_DMA_API_DEBUG
44c32e64e8SGuo Ren	select HAVE_DMA_CONTIGUOUS
452f7932b0SGuo Ren	select HAVE_SYSCALL_TRACEPOINTS
46c32e64e8SGuo Ren	select MAY_HAVE_SPARSE_IRQ
47c32e64e8SGuo Ren	select MODULES_USE_ELF_RELA if MODULES
48c32e64e8SGuo Ren	select OF
49c32e64e8SGuo Ren	select OF_EARLY_FLATTREE
50f50fd2d8SGuo Ren	select PERF_USE_VMALLOC if CPU_CK610
51c32e64e8SGuo Ren	select RTC_LIB
52c32e64e8SGuo Ren	select TIMER_OF
53c32e64e8SGuo Ren	select USB_ARCH_HAS_EHCI
54c32e64e8SGuo Ren	select USB_ARCH_HAS_OHCI
55c32e64e8SGuo Ren
56c32e64e8SGuo Renconfig CPU_HAS_CACHEV2
57c32e64e8SGuo Ren	bool
58c32e64e8SGuo Ren
59c32e64e8SGuo Renconfig CPU_HAS_FPUV2
60c32e64e8SGuo Ren	bool
61c32e64e8SGuo Ren
62c32e64e8SGuo Renconfig CPU_HAS_HILO
63c32e64e8SGuo Ren	bool
64c32e64e8SGuo Ren
65c32e64e8SGuo Renconfig CPU_HAS_TLBI
66c32e64e8SGuo Ren	bool
67c32e64e8SGuo Ren
68c32e64e8SGuo Renconfig CPU_HAS_LDSTEX
69c32e64e8SGuo Ren	bool
70c32e64e8SGuo Ren	help
71c32e64e8SGuo Ren	  For SMP, CPU needs "ldex&stex" instrcutions to atomic operations.
72c32e64e8SGuo Ren
73c32e64e8SGuo Renconfig CPU_NEED_TLBSYNC
74c32e64e8SGuo Ren	bool
75c32e64e8SGuo Ren
76c32e64e8SGuo Renconfig CPU_NEED_SOFTALIGN
77c32e64e8SGuo Ren	bool
78c32e64e8SGuo Ren
79c32e64e8SGuo Renconfig CPU_NO_USER_BKPT
80c32e64e8SGuo Ren	bool
81c32e64e8SGuo Ren	help
82c32e64e8SGuo Ren	  For abiv2 we couldn't use "trap 1" as user space bkpt in gdbserver, because
83c32e64e8SGuo Ren	  abiv2 is 16/32bit instruction set and "trap 1" is 32bit.
84c32e64e8SGuo Ren	  So we need a 16bit instruction as user space bkpt, and it will cause an illegal
85c32e64e8SGuo Ren	  instruction exception.
86c32e64e8SGuo Ren	  In kernel we parse the *regs->pc to determine whether to send SIGTRAP or not.
87c32e64e8SGuo Ren
88c32e64e8SGuo Renconfig GENERIC_CALIBRATE_DELAY
89c32e64e8SGuo Ren	def_bool y
90c32e64e8SGuo Ren
91c32e64e8SGuo Renconfig GENERIC_CSUM
92c32e64e8SGuo Ren	def_bool y
93c32e64e8SGuo Ren
94c32e64e8SGuo Renconfig GENERIC_HWEIGHT
95c32e64e8SGuo Ren	def_bool y
96c32e64e8SGuo Ren
97c32e64e8SGuo Renconfig MMU
98c32e64e8SGuo Ren	def_bool y
99c32e64e8SGuo Ren
100c32e64e8SGuo Renconfig RWSEM_GENERIC_SPINLOCK
101c32e64e8SGuo Ren	def_bool y
102c32e64e8SGuo Ren
1030ea2dc7cSGuo Renconfig STACKTRACE_SUPPORT
1040ea2dc7cSGuo Ren	def_bool y
1050ea2dc7cSGuo Ren
106c32e64e8SGuo Renconfig TIME_LOW_RES
107c32e64e8SGuo Ren	def_bool y
108c32e64e8SGuo Ren
109c32e64e8SGuo Renconfig TRACE_IRQFLAGS_SUPPORT
110c32e64e8SGuo Ren	def_bool y
111c32e64e8SGuo Ren
112c32e64e8SGuo Renconfig CPU_TLB_SIZE
113c32e64e8SGuo Ren	int
114c32e64e8SGuo Ren	default "128"	if (CPU_CK610 || CPU_CK807 || CPU_CK810)
115c32e64e8SGuo Ren	default "1024"	if (CPU_CK860)
116c32e64e8SGuo Ren
117c32e64e8SGuo Renconfig CPU_ASID_BITS
118c32e64e8SGuo Ren	int
119c32e64e8SGuo Ren	default "8"	if (CPU_CK610 || CPU_CK807 || CPU_CK810)
120c32e64e8SGuo Ren	default "12"	if (CPU_CK860)
121c32e64e8SGuo Ren
122c32e64e8SGuo Renconfig L1_CACHE_SHIFT
123c32e64e8SGuo Ren	int
124c32e64e8SGuo Ren	default "4"	if (CPU_CK610)
125c32e64e8SGuo Ren	default "5"	if (CPU_CK807 || CPU_CK810)
126c32e64e8SGuo Ren	default "6"	if (CPU_CK860)
127c32e64e8SGuo Ren
128c32e64e8SGuo Renmenu "Processor type and features"
129c32e64e8SGuo Ren
130c32e64e8SGuo Renchoice
131c32e64e8SGuo Ren	prompt "CPU MODEL"
132c32e64e8SGuo Ren	default CPU_CK807
133c32e64e8SGuo Ren
134c32e64e8SGuo Renconfig CPU_CK610
135c32e64e8SGuo Ren	bool "CSKY CPU ck610"
136c32e64e8SGuo Ren	select CPU_NEED_TLBSYNC
137c32e64e8SGuo Ren	select CPU_NEED_SOFTALIGN
138c32e64e8SGuo Ren	select CPU_NO_USER_BKPT
139c32e64e8SGuo Ren
140c32e64e8SGuo Renconfig CPU_CK810
141c32e64e8SGuo Ren	bool "CSKY CPU ck810"
142c32e64e8SGuo Ren	select CPU_HAS_HILO
143c32e64e8SGuo Ren	select CPU_NEED_TLBSYNC
144c32e64e8SGuo Ren
145c32e64e8SGuo Renconfig CPU_CK807
146c32e64e8SGuo Ren	bool "CSKY CPU ck807"
147c32e64e8SGuo Ren	select CPU_HAS_HILO
148c32e64e8SGuo Ren
149c32e64e8SGuo Renconfig CPU_CK860
150c32e64e8SGuo Ren	bool "CSKY CPU ck860"
151c32e64e8SGuo Ren	select CPU_HAS_TLBI
152c32e64e8SGuo Ren	select CPU_HAS_CACHEV2
153c32e64e8SGuo Ren	select CPU_HAS_LDSTEX
154c32e64e8SGuo Ren	select CPU_HAS_FPUV2
155c32e64e8SGuo Renendchoice
156c32e64e8SGuo Ren
157c32e64e8SGuo Renchoice
158f50fd2d8SGuo Ren	prompt "C-SKY PMU type"
159f50fd2d8SGuo Ren	depends on PERF_EVENTS
160f50fd2d8SGuo Ren	depends on CPU_CK807 || CPU_CK810 || CPU_CK860
161f50fd2d8SGuo Ren
162f50fd2d8SGuo Renconfig CPU_PMU_NONE
163f50fd2d8SGuo Ren	bool "None"
164f50fd2d8SGuo Ren
165f50fd2d8SGuo Renconfig CSKY_PMU_V1
166f50fd2d8SGuo Ren	bool "Performance Monitoring Unit Ver.1"
167f50fd2d8SGuo Ren
168f50fd2d8SGuo Renendchoice
169f50fd2d8SGuo Ren
170f50fd2d8SGuo Renchoice
171c32e64e8SGuo Ren	prompt "Power Manager Instruction (wait/doze/stop)"
172c32e64e8SGuo Ren	default CPU_PM_NONE
173c32e64e8SGuo Ren
174c32e64e8SGuo Renconfig CPU_PM_NONE
175c32e64e8SGuo Ren	bool "None"
176c32e64e8SGuo Ren
177c32e64e8SGuo Renconfig CPU_PM_WAIT
178c32e64e8SGuo Ren	bool "wait"
179c32e64e8SGuo Ren
180c32e64e8SGuo Renconfig CPU_PM_DOZE
181c32e64e8SGuo Ren	bool "doze"
182c32e64e8SGuo Ren
183c32e64e8SGuo Renconfig CPU_PM_STOP
184c32e64e8SGuo Ren	bool "stop"
185c32e64e8SGuo Renendchoice
186c32e64e8SGuo Ren
187c32e64e8SGuo Renconfig CPU_HAS_VDSP
188c32e64e8SGuo Ren	bool "CPU has VDSP coprocessor"
189c32e64e8SGuo Ren	depends on CPU_HAS_FPU && CPU_HAS_FPUV2
190c32e64e8SGuo Ren
191c32e64e8SGuo Renconfig CPU_HAS_FPU
192c32e64e8SGuo Ren	bool "CPU has FPU coprocessor"
193c32e64e8SGuo Ren	depends on CPU_CK807 || CPU_CK810 || CPU_CK860
194c32e64e8SGuo Ren
195c32e64e8SGuo Renconfig CPU_HAS_TEE
196c32e64e8SGuo Ren	bool "CPU has Trusted Execution Environment"
197c32e64e8SGuo Ren	depends on CPU_CK810
198c32e64e8SGuo Ren
199c32e64e8SGuo Renconfig SMP
200c32e64e8SGuo Ren	bool "Symmetric Multi-Processing (SMP) support for C-SKY"
201c32e64e8SGuo Ren	depends on CPU_CK860
202c32e64e8SGuo Ren	default n
203c32e64e8SGuo Ren
204c32e64e8SGuo Renconfig NR_CPUS
205c32e64e8SGuo Ren	int "Maximum number of CPUs (2-32)"
206c32e64e8SGuo Ren	range 2 32
207c32e64e8SGuo Ren	depends on SMP
208c32e64e8SGuo Ren	default "2"
209c32e64e8SGuo Ren
210c32e64e8SGuo Renconfig HIGHMEM
211c32e64e8SGuo Ren	bool "High Memory Support"
212c32e64e8SGuo Ren	depends on !CPU_CK610
213c32e64e8SGuo Ren	default y
214c32e64e8SGuo Ren
215c32e64e8SGuo Renconfig FORCE_MAX_ZONEORDER
216c32e64e8SGuo Ren	int "Maximum zone order"
217c32e64e8SGuo Ren	default "11"
218c32e64e8SGuo Ren
219c32e64e8SGuo Renconfig RAM_BASE
220c32e64e8SGuo Ren	hex "DRAM start addr (the same with memory-section in dts)"
221c32e64e8SGuo Ren	default 0x0
222c32e64e8SGuo Ren
223859e5f45SGuo Renconfig HOTPLUG_CPU
224859e5f45SGuo Ren	bool "Support for hot-pluggable CPUs"
225859e5f45SGuo Ren	select GENERIC_IRQ_MIGRATION
226859e5f45SGuo Ren	depends on SMP
227859e5f45SGuo Ren	help
228859e5f45SGuo Ren	  Say Y here to allow turning CPUs off and on. CPUs can be
229859e5f45SGuo Ren	  controlled through /sys/devices/system/cpu/cpu1/hotplug/target.
230859e5f45SGuo Ren
231859e5f45SGuo Ren	  Say N if you want to disable CPU hotplug.
232c32e64e8SGuo Renendmenu
233c32e64e8SGuo Ren
234c32e64e8SGuo Rensource "kernel/Kconfig.hz"
235