]> rtime.felk.cvut.cz Git - l4.git/blob - kernel/fiasco/src/Kconfig
4510c52cfc634cc6b72bc3c59b88fb8027dc0e8f
[l4.git] / kernel / fiasco / src / Kconfig
1
2
3 mainmenu "Fiasco configuration"
4
5 config KERNELVERSION
6         string
7         option env="KERNELVERSION"
8
9 config INCLUDE_PPC32
10         bool
11         option env="INCLUDE_PPC32"
12         help
13           Use "INCLUDE_PPC32=y make config" to include ppc32 options.
14
15 menu "Target configuration"
16
17 choice
18         prompt "Architecture"
19         default IA32
20
21 config IA32
22         bool "Intel IA-32 processor family"
23
24 config AMD64
25         bool "AMD64 processor family"
26         select CONTEXT_4K
27
28 config ARM
29         bool "ARM processor family"
30         
31 config PPC32
32         bool "PowerPC 32 processor family (Caution: INCOMPLETE!)"
33         depends on EXPERIMENTAL && INCLUDE_PPC32
34         help
35           PPC32 testing version, mainly for MPC5200 (603e). Currently,
36           there is no support whatsoever.
37         select CONTEXT_4K
38         select BIG_ENDIAN
39
40 endchoice
41
42 config BIG_ENDIAN
43         bool
44
45 choice
46         prompt "Platform"
47         default PF_INTEGRATOR if ARM
48         default PF_PC         if IA32
49         default PF_PC         if AMD64
50         default PF_MP52CXX    if PPC32
51
52 config PF_PC
53         bool "PC platform"
54         depends on IA32 || AMD64
55
56 config PF_UX
57         bool "Linux Usermode Platform"
58         depends on IA32
59         select JDB
60
61 # PF_CHOICE
62         
63 endchoice
64
65 # PF_INCLUDE
66
67 config ABI_VF
68         def_bool y
69
70 config PF_ARM_MP_CAPABLE
71         bool
72         default y if ARM_MPCORE || ARM_CORTEX_A9
73
74 config CAN_ARM_CPU_SA1100
75         bool
76
77 config CAN_ARM_CPU_XSCALE
78         bool
79
80 config CAN_ARM_CPU_920T
81         bool
82
83 config CAN_ARM_CPU_926
84         bool
85
86 config CAN_ARM_CPU_1176
87         bool
88
89 config CAN_ARM_CPU_MPCORE
90         bool
91
92 config CAN_ARM_CPU_CORTEX_A8
93         bool
94
95 config CAN_ARM_CPU_CORTEX_A9
96         bool
97
98
99 choice
100         prompt "CPU"
101         default IA32_686   if IA32
102         default ARM_926    if ARM
103         default AMD64_K8   if AMD64
104         default PPC32_603e if PPC32
105
106 config ARM_PXA
107         bool "Intel XScale"
108         depends on PF_XSCALE
109
110 config ARM_SA
111         bool "Intel StrongARM"
112         depends on PF_SA1100
113
114 config ARM_920T
115         bool "ARM 920T Processor"
116         depends on PF_S3C2410
117
118 config ARM_926
119         bool "ARM 926 Processor"
120         depends on CAN_ARM_CPU_926
121
122 config ARM_1176
123         bool "ARM 1176 CPU"
124         depends on CAN_ARM_CPU_1176
125
126 config ARM_MPCORE
127         bool "ARM MPCore CPU"
128         depends on CAN_ARM_CPU_MPCORE
129
130 config ARM_CORTEX_A8
131         bool "ARM Cortex-A8 CPU"
132         depends on CAN_ARM_CPU_CORTEX_A8
133
134 config ARM_CORTEX_A9
135         bool "ARM Cortex-A9 CPU"
136         depends on CAN_ARM_CPU_CORTEX_A9
137
138 config IA32_486
139         bool "Intel 80486"
140         depends on IA32
141         help
142           Choose this if you have an Intel 80486 or equivalent CPU (i486).
143
144 config IA32_586
145         bool "Intel Pentium / AMD K5"
146         depends on IA32
147         help
148           Choose this if you have an Intel Pentium or compatible i586 CPU.
149
150 config IA32_686
151         bool "Intel Pentium Pro"
152         depends on IA32
153         help
154           Choose this if you have an Intel Pentium Pro or compatible i686 CPU.
155
156 config IA32_P2
157         bool "Intel Pentium II / Celeron II"
158         depends on IA32
159         help
160           Choose this if you have an Intel Pentium II or Pentium II based Celeron.
161
162 config IA32_P3
163         bool "Intel Pentium III / Celeron III"
164         depends on IA32
165         help
166           Choose this if you have an Intel Pentium III or Pentium III based Celeron.
167
168 config IA32_P4
169         bool "Intel Pentium 4 / Celeron 4"
170         depends on IA32
171         help
172           Choose this if you have an Intel Pentium 4 or Pentium 4 based Celeron.
173
174 config IA32_PM
175         bool "Intel Pentium M"
176         depends on IA32
177         help
178           Choose this if you have an Intel Pentium M.
179
180 config IA32_CORE2
181         bool "Intel Core 2"
182         depends on IA32
183         help
184           Choose this if you have an Intel Core 2.
185
186 config IA32_ATOM
187         bool "Intel Atom"
188         depends on IA32
189         help
190           Choose this if you have an Intel Atom.
191
192 config IA32_K6
193         bool "AMD K6 / K6-II / K6-III"
194         depends on IA32
195         help
196           Choose this if you have an AMD K6 CPU.
197
198 config IA32_K7
199         bool "AMD Athlon / Duron"
200         depends on IA32
201         help
202           Choose this if you have an AMD Athlon or Duron CPU.
203
204 config IA32_K8
205         bool "AMD Opteron / Athlon64"
206         depends on IA32
207         help
208           Choose this if you have an AMD Opteron or Athlon64 CPU.
209
210 config IA32_K10
211         bool "AMD Barcelona (K10)"
212         depends on IA32
213         help
214           Choose this if you have an AMD Barcelona based CPU.
215
216
217 config AMD64_K8
218         bool "AMD Opteron / Athlon64"
219         depends on AMD64
220         help
221           Choose this if you have an AMD Opteron or Athlon64 CPU.
222
223 config AMD64_CORE2
224         bool "Intel Core 2"
225         depends on AMD64
226         help
227           Choose this if you have an Intel Core 2.
228
229 config AMD64_ATOM
230         bool "Intel Atom"
231         depends on AMD64
232         help
233           Choose this if you have an Intel Atom.
234
235 config AMD64_K10
236         bool "AMD Barcelona (K10)"
237         depends on AMD64
238         help
239           Choose this if you have an AMD Barcelona based CPU.
240
241
242 config PPC32_603e
243         bool "PowerPC 603e"
244         depends on PPC32
245         help
246           Choose this if you have an PowerPC 603e CPU.
247
248 endchoice
249
250
251
252 config CPU_VIRT
253         bool "Enable CPU virtualization (SVM and VT)"
254         depends on PF_PC
255         help
256           Support virtualization extensions that comes with x86 CPUs,
257           including nested paging. This feature allows you to run a virtual
258           machine monitor (VMM) on top of Fiasco.
259
260 config ARM_ALIGNMENT_CHECK
261         bool "Enable alignment check"
262         depends on ARM
263         help
264           Enable if you want to have alignment check enabled.
265
266 config ARM_TZ
267         bool "Enable ARM TrustZone support"
268         depends on (ARM_1176 || ARM_CORTEX_A8 || ARM_CORTEX_A9) && EXPERIMENTAL
269         help
270           Support ARM TrustZone security extension.
271
272 config ARM_CA9_ENABLE_SWP
273         bool "Enable the deprecated 'swp' instruction"
274         depends on ARM_CORTEX_A9
275         help
276           Enabling this option enables the deprecated 'swp' instruction.
277           Avoid to enable it.
278
279 choice
280         prompt "Timer tick source"
281         depends on PF_PC || PF_UX
282         default SCHED_PIT
283
284 config SCHED_PIT
285         bool "Use PIT for scheduling"
286         depends on (PF_PC || PF_UX) && !MP
287         help
288           Normally, Fiasco uses the RTC at IRQ8 for scheduling. This can be
289           disadvantageous in certain circumstances, e.g. VMWare doesn't seem
290           to emulate the RTC good enough so that not enough timer interrupts
291           are produced. The PIT mode (using IRQ0) seems to work better in
292           this case.  It is generally safe to use this option, so if you are
293           unsure, say 'Y'.
294
295           Consider that the interrupt priorities change: Using RTC, IRQ8 has
296           the highest priority. Using PIT, IRQ0 has the highest priority.
297           The only case where PIT scheduling does not work is with
298           profiling. If profiling is enabled the PIT is used for generating
299           the profiling interrupts.
300
301 config SCHED_RTC
302         bool "Use RTC for scheduling"
303         depends on PF_PC && !MP
304         help
305           'Yes' is the standard for this option. If this option is set
306           Fiasco uses the RTC on IRQ 8 for scheduling.  This can be
307           disadvantageous in certain circumstances, e.g. VMWare doesn't seem
308           to emulate the RTC good enough so that not enough timer interrupts
309           are produced.  The PIT (8254) mode (say 'no' here), seems to work
310           better in this case. It is generally safe to use the PIT, so if
311           you are unsure, say 'no'.
312           Consider that the interrupt priorities change: Using RTC, IRQ8 has
313           the highest priority. Using PIT, IRQ0 has the highest priority.
314           The only case where PIT scheduling does not work is with
315           profiling. If profiling is enabled the PIT is used for generating
316           the profiling interrupts and the RTC must be used for scheduling.
317           In the case where profiling shall be used within VMWare the
318           SLOW_RTC option must be set, so that the timer resolution of
319           Fiasco is reduced to 100Hz.
320
321 config SCHED_APIC
322         bool "Use APIC timer for scheduling"
323         depends on PF_PC
324         help
325           Use the Local APIC for scheduling.
326
327 config SCHED_HPET
328         bool "Use HPET timer for scheduling (EXPERIMENTAL)"
329         depends on PF_PC && !MP && EXPERIMENTAL
330         help
331           Use the HPET timer for scheduling.
332
333 endchoice
334
335 config WORKAROUND_AMD_FPU_LEAK
336         bool "Enables workaroud for AMD FPU security leak"
337         depends on PF_PC
338         help
339           If you use Fiasco for high assurance, high security and use AMD
340           CPUs you should enable this option. In any other case it is no
341           harm to disable it.
342
343 config REGPARM3
344         bool "Compile with regparm=3"
345         default y
346         depends on IA32 && PF_PC
347         help
348           Compile Fiasco with -mregparm=3. This uses a different ABI and
349           passes the first three arguments of a function call in registers.
350
351 config FPU
352         bool "Enable FPU co-processor"
353         depends on ARM
354         help
355           Enable this if your platform has hardware floating point support.
356
357 config ARM_1176_CACHE_ALIAS_FIX
358         bool "Use cache restriction to supress aliasing issue on ARM1176"
359         depends on ARM_1176
360         help
361           The ARM1176 processor might have a memory aliasing problem when
362           using cache sizes of more than 16kB cache. Enabling this option
363           enables the workaround of reducing the cache size to 16kB.
364
365 endmenu # target
366
367 menu "Kernel options"
368
369 config HANDLE_SEGMENTS
370         bool "Handle and preserve segments"
371         depends on (PF_PC || PF_UX) && !AMD64
372         help
373           This function preserves the values of segment registers across
374           thread and task switches and allows to configure segments for user
375           programs.
376
377 config MP
378         bool "Enable multi processor support"
379         depends on EXPERIMENTAL && (PF_PC || PF_UX || PF_ARM_MP_CAPABLE)
380         help
381           Enable support for machines with multiple processors.
382
383 config MP_MAX_CPUS
384         int "Maximal supported number of CPUs"
385         depends on MP
386         range 1 32 if BIT32
387         range 1 64 if BIT64
388         default 4
389         help
390           The maximum number of CPUs the kernel supports.
391
392 #config ASSEMBLER_IPC_SHORTCUT
393 #       bool "Assembler IPC shortcut"
394 #       default y
395 #       depends on (PF_PC || PF_UX) && !MP
396 #       help
397 #         Use the assembler IPC shortcut to get even better short IPC
398 #         performance in the common case.
399
400 config CONTEXT_4K
401         bool #"TCB size of 4k"
402         default y
403         help
404           Use this option to use 4K kernel stacks. Only disable this option
405           when you know what you're doing.
406
407 config IO_PROT
408         bool "Enable I/O port protection"
409         default y
410         depends on PF_PC
411         help
412           Enabling this option adds I/O port protection to the kernel. That
413           means that every thread starts running at IOPL 0 which means that
414           only the kernel has full access to all I/O ports. This includes
415           the right to set and clear the interrupt flags (that is using cli
416           and sti). Access rights to I/O ports can be mapped like memory. If
417           a task has access to the whole I/O port space, its IOPL is raised
418           to 3 allowing the task to use cli and sti.
419
420 config IO_PROT_IOPL_3
421         bool "Enable CLI/STI (IOPL 3)"
422         depends on PF_PC && IO_PROT
423         help
424           Enable IOPL 3 for tasks with access to all I/O ports, this is the
425           old behavior.
426
427 config SLOW_RTC
428         bool "Use RTC with 100 ticks per second"
429         depends on SCHED_RTC
430         help
431           This option should be enabled if you use VMWare and no PIT
432           scheduling. The timer resolution is lowered to 100 ticks per
433           second.
434
435 config ONE_SHOT
436         bool "Use scheduling timer in one-shot mode"
437         depends on SCHED_APIC && SYNC_TSC
438         help
439           More costly than periodic but more fine-granular scheduling
440           possible.  EXPERIMENTAL!
441
442 config SYNC_TSC
443         bool "Synchronize KIP time with time-stamp counter"
444         depends on PF_PC && IA32
445         help
446           Synchronize the internal kernel clock with the CPU time stamp
447           counter.
448
449 config FINE_GRAINED_CPUTIME
450         bool "Fine-grained CPU time"
451         help
452           Measure CPU time consumed by a thread from switching to the thread
453           until switching to another thread. Induces an overhead during each
454           thread switch, so only activate it for debugging.
455
456 config UX_CON
457         bool "Graphical console (requires SDL library!)"
458         depends on PF_UX
459         help
460           Fiasco-UX can supply a graphical console for the L4 program it is
461           running.  Enabling this option will build the additional program
462           but needs the SDL library including development header files
463           installed.
464
465 config UX_NET
466         bool "Network support"
467         depends on PF_UX
468         help
469           Enabling this option makes Fiasco-UX provide network support for
470           L4 programs.
471
472 choice 
473         prompt "Scheduler"
474         default FIXED_PRIO
475
476 config SCHED_FIXED_PRIO
477         bool "Fixed priority scheduler"
478         help
479           Choose this for the standard fixed priority scheduler with
480           256 priority levels.
481
482 config SCHED_WFQ
483         bool "Weighted fair queueing scheduler"
484         depends on EXPERIMENTAL
485         help
486           Choose this scheduler for a weighted fair queueing scheduler
487           running with dynamic priorities.
488
489 config SCHED_FP_WFQ
490         bool "Combined fixed priority RT and WFQ scheduler"
491         depends on EXPERIMENTAL
492         help
493           Combination of Fixed priority and weighted fair queueing
494           scheduler.
495
496 endchoice
497
498 config DISABLE_VIRT_OBJ_SPACE
499         bool "No virtually mapped array for cap tables"
500         depends on (PF_PC || ARM) &&  EXPERIMENTAL
501         default n
502
503 endmenu # kernel options
504
505 menu "Debugging"
506
507 config INLINE
508         bool "Generate inline code"
509         default y
510         help
511           Inlining specifies that it is desirable for the compiler to
512           integrate functions declared 'inline' into the calling routine.
513           This usually leads to faster code, so unless you want to debug the
514           kernel you should say 'Y' here.
515
516 config NDEBUG
517         bool "Do not compile assertions"
518         help
519           Don't insert assertions into the code. Should be enabled for
520           kernels which are used for measurements.
521
522 config PROFILE
523         bool #"Compile with profiling support"
524         depends on EXPERIMENTAL && PF_PC && IA32 && !ASSEMBLER_IPC_SHORTCUT && SCHED_RTC && !NO_FRAME_PTR
525         help
526           This option enables support for kernel profiling. This implies
527           that a special CPU lock is used, because profiling IRQ must be
528           enabled even in cases where a CPU lock is locked. So the
529           cpu_lock-pic module is used as implementation for the lock.
530           Further this option does not work with PIT scheduling
531           (CONFIG_SCHED_PIT) because the PIT is used for generating
532           profiling IRQs.
533
534 config NO_FRAME_PTR
535         bool "Compile without frame pointer"
536         default y
537         help
538           Enabling this option optimizes for speed but makes debugging more
539           difficult.
540
541 config STACK_DEPTH
542         bool "Measure stack depth of threads"
543         help
544           When this option is enabled, each thread control block is marked
545           with magic numbers while creation. The function ``show thread
546           lists'' scans the TCB for these magic numbers and shows the
547           currently used depth of each thread.
548
549 config ALLOW_RO_TEXT
550         bool "Read-Only Kernel Text and Data"
551         default false
552         depends on IA32 || AMD64
553         help
554           Enable this option to enable read-only mappings for kernel code
555           and ro data. To really map things read only '-rotext' needs to be
556           given to the kernel command line.
557           NOTE: This may significantly increase the memory footprint of the
558                 kernel. The use of '-rotext' with extendet logging results in
559                 kernel crashes.
560
561 config LIST_ALLOC_SANITY
562         bool "Sanity checks in low level allocator"
563         help
564           When this option is enabled the low level memory allocator does
565           extra sanity checks on its data structures before and after every
566           operation. This can halp detect  flaws like double frees or memory
567           corruption by other means.
568
569           These tests are very expensive so only enable them if a problem
570           with memory allocation is expected.
571
572 config BEFORE_IRET_SANITY
573         bool "Sanity checks at syscall entry/exit"
574         depends on PF_PC
575         help
576           Perform the following additional sanity checks before returning to
577           usermode:
578             - Does the thread hold any locks?
579             - Is the thread locked by any other thread?
580             - Does the thread have the right state:
581               * Thread_ready must be set.
582               * Thread_cancel and Thread_fpu_owner might be set.
583               * Any other state bit must not be set.
584           Don't use Fiasco compiled with this option for performance analysis!
585
586 config GSTABS
587         bool "Compile with gstabs+ debugging information"
588         depends on n
589         help
590           Enabling this option includes the debugging information using the
591           older gstabs+ format into the kernel image. This is necessary to
592           access line number information of the kernel from JDB.
593
594 config IRQ_SPINNER
595         bool "Display IRQ activity on VGA screen"
596         depends on PF_PC
597         help
598           Display IRQ activity on VGA screen.
599
600 config WATCHDOG
601         bool "Enable Watchdog support"
602         default y
603         depends on PF_PC
604         help
605           Enable support for watchdog using the builtin Local APIC and a
606           performance counter. The watchdog can be enabled using the
607           -watchdog command line option.
608
609 config SERIAL
610         bool "Support for debugging over serial line"
611         depends on PF_PC || ARM || PPC32
612         default y
613         help
614           This option enables support for input/output over serial interface.
615
616 menuconfig JDB
617         bool "JDB kernel debugger"
618         default y
619         help
620           The powerful Fiasco kernel debugger.
621
622 if JDB
623
624 config JDB_LOGGING
625         bool "JDB extended logging"
626         help
627           There are two classes of logging events: Basic events don't
628           consume any time if they are disabled (ipc, ipc result,
629           pagefaults, unmap). Extended logging events add an additional
630           overhead of most probably less than 10 cycles if they are
631           disabled. These events can be activated/deactivated by the 'O'
632           command in jdb.
633
634           Should be disabled for kernels which are used for measurements.
635
636 config JDB_DISASM
637         bool "JDB disassembler"
638         default n if ARM
639         default y
640         help
641           Add support for disassembly. Increases memory foot-print, only
642           enable when needed.
643
644 config JDB_GZIP
645         bool "GZIP compressed dumps"
646         default n if ARM
647         default y
648         help
649           Add supprt for gzip compressed dumps of the trace buffer.
650           Increases memory foot-print, only enabled when needed.
651
652 config JDB_ACCOUNTING
653         bool "JDB accounting"
654         depends on IA32
655         help
656           Enable accounting information about IPCs, context switches, page
657           faults, and other events. The counters are accessible from
658           userland through the tbuf status page.
659
660           Should be disabled for kernels which are used for measurements.
661
662 config JDB_MISC
663         bool "Miscellaneous JDB modules"
664         depends on PF_UX || PF_PC
665
666 endif # JDB
667
668
669 config VMEM_ALLOC_TEST
670         bool "Run test for Vmem_alloc allocator"
671         depends on ARM
672
673 config DEBUG_KERNEL_PAGE_FAULTS
674         bool "Debugging of kernel page-faults"
675         depends on ARM
676         help
677           This option enables logging of kernel page-faults (aka page faults
678           from kernel mode). The page faults are logged to the normal
679           console in the format *KP[pfa, error_code, ip].
680
681 config POWERSAVE_GETCHAR
682         bool "Save power in getchar()"
683         default y
684         depends on PF_PC
685         help
686           This option uses a processor HALT in getchar() to save power and
687           prevent some P4 processors from being overheated. This option
688           requires a working timer IRQ to wakeup getchar periodically.
689
690 choice
691         prompt "Warn levels"
692         default WARN_WARNING
693
694 config WARN_NONE
695         bool "Do not show show any kernel warning"
696
697 config WARN_WARNING
698         bool "Show messages of warning level"
699
700 config WARN_ANY
701         bool "Show all kernel warnings"
702
703 endchoice # warn levels
704
705 endmenu # debugging
706
707 menu "Compiling"
708
709 config CC
710         string "C compiler"
711         default "gcc"
712         help
713           Use this option to override the default C compiler (gcc).
714
715 config CXX
716         string "C++ compiler"
717         default "g++"
718         help
719           Use this option to override the default C++ compiler (g++).
720
721 config HOST_CC
722         string "C host compiler"
723         default "gcc"
724         help
725           Use this option to override the default C host compiler (gcc).
726
727 config HOST_CXX
728         string "C++ host compiler"
729         default "g++"
730         help
731           Use this option to override the default C++ host compiler (g++).
732
733 config VERBOSE
734         bool "Verbose build process"
735         help
736           When enabled, this config option allows you to see more details of
737           the build process.
738
739 config MAINTAINER_MODE
740         bool "Do additional checks at build time"
741         help
742           This enables the circular dependency and initcall checks.
743           Say 'Yes' here if you do kernel hacking.
744
745 config LABEL
746         string "Configuration label"
747         help
748           Text string with a name for this configuration. To be displayed in
749           the kernel boot-up.
750
751 endmenu
752
753 config EXPERIMENTAL
754         bool "Prompt for experimental features"
755         help
756           Experimental features are available when enabling this option.
757           Enabling these features might be less than fully secure and may
758           disrupt the stability of your kernel.
759
760           Use with caution!
761
762 config PERF_CNT
763         def_bool y if JDB && (IA32 || AMD64 || ARM)
764
765 config BIT32
766         def_bool y if ARM || IA32 || PPC32
767
768 config BIT64
769         def_bool y if AMD64
770
771 config ARM_V6
772         def_bool y if ARM_1176 || ARM_MPCORE
773
774 config ARM_V7
775         def_bool y if ARM_CORTEX_A8 || ARM_CORTEX_A9
776
777 config ARM_V6PLUS
778         def_bool y if ARM_V6 || ARM_V7
779
780 config WARN_LEVEL
781         int
782         default 2 if WARN_ANY
783         default 1 if WARN_WARNING
784         default 0 if WARN_NONE
785
786 config XARCH
787         string
788         default "arm" if ARM
789         default "ux" if PF_UX
790         default "amd64" if AMD64 && PF_PC
791         default "ia32" if IA32 && PF_PC
792         default "ppc32" if PPC32
793
794 config IA32_TARGET
795         string
796         default "Intel 80486" if IA32_486
797         default "Intel Pentium" if IA32_586
798         default "Intel Pentium Pro" if IA32_686
799         default "Intel Pentium II" if IA32_P2
800         default "Intel Pentium III" if IA32_P3
801         default "Intel Pentium 4" if IA32_P4
802         default "Pentium M" if IA32_PM
803         default "AMD K6" if IA32_K6
804         default "AMD Athlon" if IA32_K7
805         default "Intel Core2" if IA32_CORE2 || AMD64_CORE2
806         default "Intel Atom" if IA32_ATOM || AMD64_ATOM
807         default "AMD Opteron" if IA32_K8 || AMD64_K8 || AMD64_K10 || IA32_K10
808
809 config ABI
810         string
811         default "vf"