microblaze: Add support for run time relocation
[platform/kernel/u-boot.git] / arch / Kconfig
1 config ARCH_MAP_SYSMEM
2         depends on SANDBOX
3         def_bool y
4
5 config CREATE_ARCH_SYMLINK
6         bool
7
8 config HAVE_ARCH_IOREMAP
9         bool
10
11 config SYS_CACHE_SHIFT_4
12         bool
13
14 config SYS_CACHE_SHIFT_5
15         bool
16
17 config SYS_CACHE_SHIFT_6
18         bool
19
20 config SYS_CACHE_SHIFT_7
21         bool
22
23 config SYS_CACHELINE_SIZE
24         int
25         default 128 if SYS_CACHE_SHIFT_7
26         default 64 if SYS_CACHE_SHIFT_6
27         default 32 if SYS_CACHE_SHIFT_5
28         default 16 if SYS_CACHE_SHIFT_4
29         # Fall-back for MIPS
30         default 32 if MIPS
31
32 config LINKER_LIST_ALIGN
33         int
34         default 32 if SANDBOX
35         default 8 if ARM64 || X86
36         default 4
37         help
38           Force the each linker list to be aligned to this boundary. This
39           is required if ll_entry_get() is used, since otherwise the linker
40           may add padding into the table, thus breaking it.
41           See linker_lists.rst for full details.
42
43 choice
44         prompt "Architecture select"
45         default SANDBOX
46
47 config ARC
48         bool "ARC architecture"
49         select ARC_TIMER
50         select CLK
51         select DM
52         select HAVE_PRIVATE_LIBGCC
53         select SUPPORT_OF_CONTROL
54         select SYS_CACHE_SHIFT_7
55         select TIMER
56
57 config ARM
58         bool "ARM architecture"
59         select ARCH_SUPPORTS_LTO
60         select CREATE_ARCH_SYMLINK
61         select HAVE_PRIVATE_LIBGCC if !ARM64
62         select SUPPORT_ACPI
63         select SUPPORT_OF_CONTROL
64
65 config M68K
66         bool "M68000 architecture"
67         select HAVE_PRIVATE_LIBGCC
68         select NEEDS_MANUAL_RELOC
69         select SYS_BOOT_GET_CMDLINE
70         select SYS_BOOT_GET_KBD
71         select SYS_CACHE_SHIFT_4
72         select SUPPORT_OF_CONTROL
73
74 config MICROBLAZE
75         bool "MicroBlaze architecture"
76         select SUPPORT_OF_CONTROL
77         imply CMD_IRQ
78
79 config MIPS
80         bool "MIPS architecture"
81         select HAVE_ARCH_IOREMAP
82         select HAVE_PRIVATE_LIBGCC
83         select SUPPORT_OF_CONTROL
84         select SPL_SEPARATE_BSS if SPL
85
86 config NIOS2
87         bool "Nios II architecture"
88         select CPU
89         select DM
90         imply DM_EVENT
91         select OF_CONTROL
92         select SUPPORT_OF_CONTROL
93         imply CMD_DM
94
95 config PPC
96         bool "PowerPC architecture"
97         select HAVE_PRIVATE_LIBGCC
98         select SUPPORT_OF_CONTROL
99         select SYS_BOOT_GET_CMDLINE
100         select SYS_BOOT_GET_KBD
101
102 config RISCV
103         bool "RISC-V architecture"
104         select CREATE_ARCH_SYMLINK
105         select SUPPORT_OF_CONTROL
106         select OF_CONTROL
107         select DM
108         select SPL_SEPARATE_BSS if SPL
109         imply DM_SERIAL
110         imply DM_ETH
111         imply DM_EVENT
112         imply DM_MMC
113         imply DM_SPI
114         imply DM_SPI_FLASH
115         imply BLK
116         imply CLK
117         imply MTD
118         imply TIMER
119         imply CMD_DM
120         imply SPL_DM
121         imply SPL_OF_CONTROL
122         imply SPL_LIBCOMMON_SUPPORT
123         imply SPL_LIBGENERIC_SUPPORT
124         imply SPL_SERIAL
125         imply SPL_TIMER
126
127 config SANDBOX
128         bool "Sandbox"
129         select ARCH_SUPPORTS_LTO
130         select BOARD_LATE_INIT
131         select BZIP2
132         select CMD_POWEROFF
133         select DM
134         select DM_GPIO
135         select DM_I2C
136         select DM_KEYBOARD
137         select DM_MMC
138         select DM_SERIAL
139         select DM_SPI
140         select DM_SPI_FLASH
141         select GZIP_COMPRESSED
142         select HAVE_BLOCK_DEVICE
143         select LZO
144         select OF_BOARD_SETUP
145         select PCI_ENDPOINT
146         select SPI
147         select SUPPORT_OF_CONTROL
148         select SYSRESET_CMD_POWEROFF
149         select SYS_CACHE_SHIFT_4
150         select IRQ
151         select SUPPORT_EXTENSION_SCAN
152         select SUPPORT_ACPI
153         imply BITREVERSE
154         select BLOBLIST
155         imply LTO
156         imply CMD_DM
157         imply CMD_EXCEPTION
158         imply CMD_GETTIME
159         imply CMD_HASH
160         imply CMD_IO
161         imply CMD_IOTRACE
162         imply CMD_LZMADEC
163         imply CMD_SATA
164         imply CMD_SF
165         imply CMD_SF_TEST
166         imply CRC32_VERIFY
167         imply FAT_WRITE
168         imply FIRMWARE
169         imply HASH_VERIFY
170         imply LZMA
171         imply TEE
172         imply AVB_VERIFY
173         imply LIBAVB
174         imply CMD_AVB
175         imply PARTITION_TYPE_GUID
176         imply SCP03
177         imply CMD_SCP03
178         imply UDP_FUNCTION_FASTBOOT
179         imply VIRTIO_MMIO
180         imply VIRTIO_PCI
181         imply VIRTIO_SANDBOX
182         imply VIRTIO_BLK
183         imply VIRTIO_NET
184         imply DM_SOUND
185         imply PCI_SANDBOX_EP
186         imply PCH
187         imply PHYLIB
188         imply DM_MDIO
189         imply DM_MDIO_MUX
190         imply ACPI_PMC
191         imply ACPI_PMC_SANDBOX
192         imply CMD_PMC
193         imply CMD_CLONE
194         imply SILENT_CONSOLE
195         imply BOOTARGS_SUBST
196         imply PHY_FIXED
197         imply DM_DSA
198         imply CMD_EXTENSION
199         imply KEYBOARD
200         imply PHYSMEM
201         imply GENERATE_ACPI_TABLE
202         imply BINMAN
203
204 config SH
205         bool "SuperH architecture"
206         select HAVE_PRIVATE_LIBGCC
207         select SUPPORT_OF_CONTROL
208
209 config X86
210         bool "x86 architecture"
211         select SUPPORT_SPL
212         select SUPPORT_TPL
213         select CREATE_ARCH_SYMLINK
214         select DM
215         select HAVE_ARCH_IOMAP
216         select HAVE_PRIVATE_LIBGCC
217         select OF_CONTROL
218         select PCI
219         select SUPPORT_ACPI
220         select SUPPORT_OF_CONTROL
221         select SYS_CACHE_SHIFT_6
222         select TIMER
223         select USE_PRIVATE_LIBGCC
224         select X86_TSC_TIMER
225         select IRQ
226         imply HAS_ROM if X86_RESET_VECTOR
227         imply BLK
228         imply CMD_DM
229         imply CMD_FPGA_LOADMK
230         imply CMD_GETTIME
231         imply CMD_IO
232         imply CMD_IRQ
233         imply CMD_PCI
234         imply CMD_SF
235         imply CMD_SF_TEST
236         imply CMD_ZBOOT
237         imply DM_ETH
238         imply DM_EVENT
239         imply DM_GPIO
240         imply DM_KEYBOARD
241         imply DM_MMC
242         imply DM_RTC
243         imply DM_SCSI
244         imply DM_SERIAL
245         imply DM_SPI
246         imply DM_SPI_FLASH
247         imply DM_USB
248         imply DM_VIDEO
249         imply SYSRESET
250         imply SPL_SYSRESET
251         imply SYSRESET_X86
252         imply USB_ETHER_ASIX
253         imply USB_ETHER_SMSC95XX
254         imply USB_HOST_ETHER
255         imply PCH
256         imply PHYSMEM
257         imply RTC_MC146818
258         imply ACPIGEN if !QEMU && !EFI_APP
259         imply SYSINFO if GENERATE_SMBIOS_TABLE
260         imply SYSINFO_SMBIOS if GENERATE_SMBIOS_TABLE
261         imply TIMESTAMP
262
263         # Thing to enable for when SPL/TPL are enabled: SPL
264         imply SPL_DM
265         imply SPL_OF_LIBFDT
266         imply SPL_DRIVERS_MISC
267         imply SPL_GPIO
268         imply SPL_PINCTRL
269         imply SPL_LIBCOMMON_SUPPORT
270         imply SPL_LIBGENERIC_SUPPORT
271         imply SPL_SERIAL
272         imply SPL_SPI_FLASH_SUPPORT
273         imply SPL_SPI
274         imply SPL_OF_CONTROL
275         imply SPL_TIMER
276         imply SPL_REGMAP
277         imply SPL_SYSCON
278         # TPL
279         imply TPL_DM
280         imply TPL_DRIVERS_MISC
281         imply TPL_GPIO
282         imply TPL_PINCTRL
283         imply TPL_LIBCOMMON_SUPPORT
284         imply TPL_LIBGENERIC_SUPPORT
285         imply TPL_SERIAL
286         imply TPL_OF_CONTROL
287         imply TPL_TIMER
288         imply TPL_REGMAP
289         imply TPL_SYSCON
290
291 config XTENSA
292         bool "Xtensa architecture"
293         select CREATE_ARCH_SYMLINK
294         select SUPPORT_OF_CONTROL
295
296 endchoice
297
298 config SYS_ARCH
299         string
300         help
301           This option should contain the architecture name to build the
302           appropriate arch/<CONFIG_SYS_ARCH> directory.
303           All the architectures should specify this option correctly.
304
305 config SYS_CPU
306         string
307         help
308           This option should contain the CPU name to build the correct
309           arch/<CONFIG_SYS_ARCH>/cpu/<CONFIG_SYS_CPU> directory.
310
311           This is optional.  For those targets without the CPU directory,
312           leave this option empty.
313
314 config SYS_SOC
315         string
316         help
317           This option should contain the SoC name to build the directory
318           arch/<CONFIG_SYS_ARCH>/cpu/<CONFIG_SYS_CPU>/<CONFIG_SYS_SOC>.
319
320           This is optional.  For those targets without the SoC directory,
321           leave this option empty.
322
323 config SYS_VENDOR
324         string
325         help
326           This option should contain the vendor name of the target board.
327           If it is set and
328           board/<CONFIG_SYS_VENDOR>/common/Makefile exists, the vendor common
329           directory is compiled.
330           If CONFIG_SYS_BOARD is also set, the sources under
331           board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD> directory are compiled.
332
333           This is optional.  For those targets without the vendor directory,
334           leave this option empty.
335
336 config SYS_BOARD
337         string
338         help
339           This option should contain the name of the target board.
340           If it is set, either board/<CONFIG_SYS_VENDOR>/<CONFIG_SYS_BOARD>
341           or board/<CONFIG_SYS_BOARD> directory is compiled depending on
342           whether CONFIG_SYS_VENDOR is set or not.
343
344           This is optional.  For those targets without the board directory,
345           leave this option empty.
346
347 config SYS_CONFIG_NAME
348         string
349         help
350           This option should contain the base name of board header file.
351           The header file include/configs/<CONFIG_SYS_CONFIG_NAME>.h
352           should be included from include/config.h.
353
354 config SYS_DISABLE_DCACHE_OPS
355         bool
356         help
357          This option disables dcache flush and dcache invalidation
358          operations. For example, on coherent systems where cache
359          operatios are not required, enable this option to avoid them.
360          Note that, its up to the individual architectures to implement
361          this functionality.
362
363 config SYS_IMMR
364         hex "Address for the Internal Memory-Mapped Registers (IMMR) window"
365         depends on PPC || FSL_LSCH2 || FSL_LSCH3 || ARCH_LS1021A
366         default 0xFF000000 if MPC8xx
367         default 0xF0000000 if ARCH_MPC8313
368         default 0xE0000000 if MPC83xx && !ARCH_MPC8313
369         default 0x01000000 if ARCH_LS1021A || FSL_LSCH2 || FSL_LSCH3
370         default SYS_CCSRBAR_DEFAULT
371         help
372           Address for the Internal Memory-Mapped Registers (IMMR) window used
373           to configure the features of many Freescale / NXP SoCs.
374
375 config SKIP_LOWLEVEL_INIT
376         bool "Skip the calls to certain low level initialization functions"
377         depends on ARM || MIPS || RISCV
378         help
379           If enabled, then certain low level initializations (like setting up
380           the memory controller) are omitted and/or U-Boot does not relocate
381           itself into RAM.
382           Normally this variable MUST NOT be defined. The only exception is
383           when U-Boot is loaded (to RAM) by some other boot loader or by a
384           debugger which performs these initializations itself.
385
386 config SPL_SKIP_LOWLEVEL_INIT
387         bool "Skip the calls to certain low level initialization functions"
388         depends on SPL && (ARM || MIPS || RISCV)
389         help
390           If enabled, then certain low level initializations (like setting up
391           the memory controller) are omitted and/or U-Boot does not relocate
392           itself into RAM.
393           Normally this variable MUST NOT be defined. The only exception is
394           when U-Boot is loaded (to RAM) by some other boot loader or by a
395           debugger which performs these initializations itself.
396
397 config TPL_SKIP_LOWLEVEL_INIT
398         bool "Skip the calls to certain low level initialization functions"
399         depends on SPL && ARM
400         help
401           If enabled, then certain low level initializations (like setting up
402           the memory controller) are omitted and/or U-Boot does not relocate
403           itself into RAM.
404           Normally this variable MUST NOT be defined. The only exception is
405           when U-Boot is loaded (to RAM) by some other boot loader or by a
406           debugger which performs these initializations itself.
407
408 config SKIP_LOWLEVEL_INIT_ONLY
409         bool "Skip the call to lowlevel_init during early boot ONLY"
410         depends on ARM
411         help
412           This allows just the call to lowlevel_init() to be skipped. The
413           normal CP15 init (such as enabling the instruction cache) is still
414           performed.
415
416 config SPL_SKIP_LOWLEVEL_INIT_ONLY
417         bool "Skip the call to lowlevel_init during early boot ONLY"
418         depends on SPL && ARM
419         help
420           This allows just the call to lowlevel_init() to be skipped. The
421           normal CP15 init (such as enabling the instruction cache) is still
422           performed.
423
424 config TPL_SKIP_LOWLEVEL_INIT_ONLY
425         bool "Skip the call to lowlevel_init during early boot ONLY"
426         depends on TPL && ARM
427         help
428           This allows just the call to lowlevel_init() to be skipped. The
429           normal CP15 init (such as enabling the instruction cache) is still
430           performed.
431
432 source "arch/arc/Kconfig"
433 source "arch/arm/Kconfig"
434 source "arch/m68k/Kconfig"
435 source "arch/microblaze/Kconfig"
436 source "arch/mips/Kconfig"
437 source "arch/nios2/Kconfig"
438 source "arch/powerpc/Kconfig"
439 source "arch/sandbox/Kconfig"
440 source "arch/sh/Kconfig"
441 source "arch/x86/Kconfig"
442 source "arch/xtensa/Kconfig"
443 source "arch/riscv/Kconfig"
444
445 source "board/keymile/Kconfig"
446
447 if MIPS || MICROBLAZE
448
449 choice
450         prompt "Endianness selection"
451         help
452           Some MIPS boards can be configured for either little or big endian
453           byte order. These modes require different U-Boot images. In general there
454           is one preferred byteorder for a particular system but some systems are
455           just as commonly used in the one or the other endianness.
456
457 config SYS_BIG_ENDIAN
458         bool "Big endian"
459         depends on (SUPPORTS_BIG_ENDIAN && MIPS) || MICROBLAZE
460
461 config SYS_LITTLE_ENDIAN
462         bool "Little endian"
463         depends on (SUPPORTS_LITTLE_ENDIAN && MIPS) || MICROBLAZE
464
465 endchoice
466
467 endif