2015-05-21 00:40:39 +08:00
|
|
|
# Kconfig - x86 general configuration options
|
|
|
|
|
|
|
|
#
|
|
|
|
# Copyright (c) 2014-2015 Wind River Systems, Inc.
|
|
|
|
#
|
2015-10-07 00:00:37 +08:00
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
2015-05-21 00:40:39 +08:00
|
|
|
#
|
2015-10-07 00:00:37 +08:00
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
2015-05-21 00:40:39 +08:00
|
|
|
#
|
2015-10-07 00:00:37 +08:00
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
2015-05-21 00:40:39 +08:00
|
|
|
#
|
|
|
|
|
2015-10-09 18:20:52 +08:00
|
|
|
menu "x86 architecture"
|
|
|
|
depends on X86
|
2015-05-26 22:31:43 +08:00
|
|
|
|
2015-10-09 18:20:52 +08:00
|
|
|
config ARCH
|
|
|
|
default "x86"
|
2015-05-26 22:31:43 +08:00
|
|
|
|
2015-11-03 09:42:35 +08:00
|
|
|
config ARCH_DEFCONFIG
|
|
|
|
string
|
|
|
|
default "arch/x86/defconfig"
|
|
|
|
|
2015-09-29 22:08:59 +08:00
|
|
|
menu "X86 Platform Configuration options"
|
2015-06-10 22:25:07 +08:00
|
|
|
|
2015-10-15 03:46:41 +08:00
|
|
|
config RAM_SIZE
|
2015-11-22 12:15:45 +08:00
|
|
|
int "Amount of RAM given to the kernel (in kB)"
|
2015-10-15 03:46:41 +08:00
|
|
|
help
|
|
|
|
This option specifies the amount of RAM given to the kernel. It must
|
|
|
|
not exceed the amount available on the target. When running an XIP
|
|
|
|
kernel, it must be large enough to contain the data, bss and noinit
|
|
|
|
sections. When not running an XIP kernel, it must be large enough to
|
|
|
|
contain the full image.
|
|
|
|
|
|
|
|
The default value is specified by the platform.
|
|
|
|
|
|
|
|
config ROM_SIZE
|
2015-11-22 12:15:45 +08:00
|
|
|
int "Amount of ROM given to the kernel (in kB)" if XIP
|
2015-10-15 03:46:41 +08:00
|
|
|
help
|
|
|
|
This option specifies the amount of ROM given to the kernel. It must
|
|
|
|
not exceed the amount available on the target. It must also be large
|
|
|
|
enough to contain the full image.
|
|
|
|
|
|
|
|
The default value is specified by the platform.
|
|
|
|
|
2015-06-10 22:25:07 +08:00
|
|
|
choice
|
2015-07-24 22:36:18 +08:00
|
|
|
prompt "Platform Selection"
|
2015-07-24 22:29:17 +08:00
|
|
|
default PLATFORM_IA32_PCI
|
2015-09-25 22:03:08 +08:00
|
|
|
source "arch/x86/platforms/*/Kconfig.platform"
|
2015-07-24 22:36:18 +08:00
|
|
|
endchoice
|
2015-06-10 22:25:07 +08:00
|
|
|
|
|
|
|
choice
|
|
|
|
prompt "Intel Processor"
|
2015-07-11 02:17:56 +08:00
|
|
|
default CPU_MINUTEIA
|
2015-06-10 22:25:07 +08:00
|
|
|
|
2015-06-12 05:05:13 +08:00
|
|
|
config CPU_ATOM
|
|
|
|
bool "Atom"
|
2015-07-23 01:34:59 +08:00
|
|
|
select CMOV
|
2015-09-19 04:36:57 +08:00
|
|
|
select CPU_MIGHT_SUPPORT_CLFLUSH if CACHE_FLUSHING
|
2015-06-12 05:05:13 +08:00
|
|
|
help
|
|
|
|
This option signifies the use of a CPU from the Atom family.
|
|
|
|
|
2015-06-10 22:25:07 +08:00
|
|
|
config CPU_MINUTEIA
|
|
|
|
bool "Minute IA"
|
2015-09-19 04:36:57 +08:00
|
|
|
select CPU_MIGHT_SUPPORT_CLFLUSH if CACHE_FLUSHING
|
2015-06-10 22:25:07 +08:00
|
|
|
help
|
|
|
|
This option signifies the use of a CPU from the Minute IA family.
|
|
|
|
endchoice
|
|
|
|
|
2015-09-19 04:36:57 +08:00
|
|
|
config CACHE_FLUSHING
|
2015-06-10 22:25:07 +08:00
|
|
|
bool
|
|
|
|
default n
|
2015-09-19 04:36:57 +08:00
|
|
|
prompt "Enable cache flushing mechanism"
|
2015-06-10 22:25:07 +08:00
|
|
|
help
|
2015-09-19 04:36:57 +08:00
|
|
|
This links in the sys_cache_flush() function. A mechanism for flushing the
|
|
|
|
cache must be selected as well. By default, that mechanism is discovered at
|
|
|
|
runtime.
|
2015-06-10 22:25:07 +08:00
|
|
|
|
2015-07-30 01:59:01 +08:00
|
|
|
menu "Platform Capabilities"
|
2015-08-04 22:05:24 +08:00
|
|
|
config ADVANCED_IDLE_SUPPORTED
|
|
|
|
bool "Advanced Idle Supported"
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
This option signifies that the target supports the ADVANCED_IDLE
|
|
|
|
configuration option.
|
|
|
|
|
|
|
|
config NUM_DYNAMIC_STUBS
|
|
|
|
int "Number of dynamic int stubs"
|
|
|
|
default 0
|
|
|
|
help
|
|
|
|
This option specifies the number of interrupt handlers that can be
|
|
|
|
installed dynamically using irq_connect().
|
|
|
|
|
x86: remove dynamically generated IRQ and exception code
We are interested in supporting some XIP x86 platforms which are
unable to fetch CPU instructions from system RAM. This requires
refactoring our dynamic IRQ/exc code which currently synthesizes
assembly language instructions to create IRQ stubs on-the-fly.
Instead, a new approach is taken. Given that the configuration at
build time specifies the number of required stubs, use this
to generate a build time a set of tiny stub functions which simply
push a 'stub id' and then call common dynamic interrupt code.
The handler function and handler argument is saved in a table keyed by
this stub id.
CONFIG_EOI_HANDLER_SUPPORTED removed, the code hasn't been conditionally
compiled for some time and in all cases we call _loapic_eoi() when
finished with an interrupt.
Some other out-of-date verbiage in comments related to supporting
non-APIC removed.
Previously, when dynamic exceptions were created a pointer would
be passed in by the caller reserving ram for the stub code. Since
this is no longer feasible, two new Kconfig options have been added.
CONFIG_NUM_DYNAMIC_EXC_STUBS and CONFIG_NUM_DYNAMIC_EXC_NO_ERR_STUBS
control how many stubs are created for exceptions that push
an error code, and no error code, respectively.
SW Interrupts are no longer triggered by "int <vector>" hard-coded
assembly instructions. Instead this is done by sending a self-directed
inter-processor interrupt from the LOAPIC, using a new API
loapic_int_vect_trigger(). In this way we get rid of dynamically
generated code in irq_test_common.h.
All interrupts call _loapic_eoi() when finished, since this is now
the right thing to do for all IRQs, including SW interrupts.
_irq_handler_set() for x86 no longer requires the old function pointer
to be supplied.
Change-Id: I78993d3d00dd153c9051c518b417cce8d3acee9e
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2015-10-20 05:10:53 +08:00
|
|
|
config NUM_DYNAMIC_EXC_STUBS
|
|
|
|
int "Number of dynamic exception stubs"
|
|
|
|
default 0
|
|
|
|
help
|
|
|
|
This option specifies the maximum number of dynamically allocated
|
|
|
|
exception stubs that are to be used with exceptions that push an
|
|
|
|
error code onto the stack.
|
|
|
|
|
|
|
|
config NUM_DYNAMIC_EXC_NOERR_STUBS
|
|
|
|
int "Number of dynamic exception stubs"
|
|
|
|
default 0
|
|
|
|
help
|
|
|
|
This option specifies the maximum number of dynamically allocated
|
|
|
|
exception stubs that are to be used with exceptions that do not push
|
|
|
|
an error code onto the stack.
|
|
|
|
|
2015-09-10 02:25:04 +08:00
|
|
|
config PIC_DISABLE
|
|
|
|
bool "Disable PIC"
|
2015-08-04 22:05:24 +08:00
|
|
|
default n
|
|
|
|
help
|
|
|
|
This option disables all interrupts on the PIC
|
|
|
|
|
2015-11-18 06:08:45 +08:00
|
|
|
config IRQ_OFFLOAD
|
|
|
|
bool "Enable IRQ offload"
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
Enable irq_offload() API which allows functions to be synchronously
|
|
|
|
run in interrupt context. Uses one entry in the IDT. Mainly useful
|
|
|
|
for test cases.
|
|
|
|
|
2015-07-30 01:59:01 +08:00
|
|
|
endmenu
|
|
|
|
|
2015-08-04 22:59:37 +08:00
|
|
|
menu "Processor Capabilities"
|
2015-06-10 22:25:07 +08:00
|
|
|
|
|
|
|
config ISA_IA32
|
|
|
|
bool
|
2015-07-30 02:37:10 +08:00
|
|
|
default y
|
2015-06-10 22:25:07 +08:00
|
|
|
help
|
|
|
|
This option signifies the use of a CPU based on the Intel IA-32
|
|
|
|
instruction set architecture.
|
|
|
|
|
2015-09-23 20:00:05 +08:00
|
|
|
config IA32_LEGACY_IO_PORTS
|
|
|
|
bool
|
|
|
|
prompt "Support IA32 legacy IO ports"
|
|
|
|
default n
|
|
|
|
depends on ISA_IA32
|
|
|
|
help
|
|
|
|
This option enables IA32 legacy IO ports. Note these are much slower
|
|
|
|
than memory access, so they should be used in last resort.
|
|
|
|
|
2015-07-23 01:34:59 +08:00
|
|
|
config CMOV
|
|
|
|
def_bool n
|
2015-06-10 22:25:07 +08:00
|
|
|
help
|
2015-07-23 01:34:59 +08:00
|
|
|
This option signifies the use of an Intel CPU that supports
|
|
|
|
the CMOV instruction.
|
2015-06-10 22:25:07 +08:00
|
|
|
|
2015-09-19 04:36:57 +08:00
|
|
|
config CACHE_LINE_SIZE_DETECT
|
|
|
|
bool
|
|
|
|
prompt "Detect cache line size at runtime"
|
|
|
|
default y
|
|
|
|
help
|
|
|
|
This option enables querying the CPUID register for finding the cache line
|
|
|
|
size at the expense of taking more memory and code and a slightly increased
|
|
|
|
boot time.
|
|
|
|
|
|
|
|
If the CPU's cache line size is known in advance, disable this option and
|
|
|
|
manually enter the value for CACHE_LINE_SIZE.
|
|
|
|
|
2015-06-10 22:25:07 +08:00
|
|
|
config CACHE_LINE_SIZE
|
2015-09-19 04:36:57 +08:00
|
|
|
int
|
|
|
|
prompt "Cache line size" if !CACHE_LINE_SIZE_DETECT
|
|
|
|
default 0 if CACHE_LINE_SIZE_DETECT
|
2015-07-11 02:17:56 +08:00
|
|
|
default 64 if CPU_ATOM
|
2015-06-10 22:25:07 +08:00
|
|
|
default 0
|
|
|
|
help
|
|
|
|
Size in bytes of a CPU cache line.
|
|
|
|
|
2015-09-19 04:36:57 +08:00
|
|
|
Detect automatically at runtime by selecting CACHE_LINE_SIZE_DETECT.
|
|
|
|
|
|
|
|
config CPU_MIGHT_SUPPORT_CLFLUSH
|
|
|
|
bool
|
|
|
|
depends on CACHE_FLUSHING
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
If a platform uses a processor that possibly implements CLFLUSH, change
|
|
|
|
the default in that platform's config file.
|
|
|
|
|
|
|
|
config CLFLUSH_INSTRUCTION_SUPPORTED
|
|
|
|
bool
|
|
|
|
prompt "CLFLUSH instruction supported" if CPU_MIGHT_SUPPORT_CLFLUSH
|
|
|
|
depends on CPU_MIGHT_SUPPORT_CLFLUSH && !CLFLUSH_DETECT
|
|
|
|
default n
|
|
|
|
help
|
|
|
|
An implementation of sys_cache_flush() that uses CLFLUSH is made
|
|
|
|
available, instead of the one using WBINVD.
|
|
|
|
|
|
|
|
This option should only be enabled if it is known in advance that the
|
|
|
|
CPU supports the CLFLUSH instruction. It disables runtime detection of
|
|
|
|
CLFLUSH support thereby reducing both memory footprint and boot time.
|
|
|
|
|
|
|
|
config CLFLUSH_DETECT
|
|
|
|
bool
|
|
|
|
prompt "Detect support of CLFLUSH instruction at runtime"
|
|
|
|
depends on CPU_MIGHT_SUPPORT_CLFLUSH
|
|
|
|
default y
|
|
|
|
help
|
|
|
|
This option should be enabled if it is not known in advance whether the
|
|
|
|
CPU supports the CLFLUSH instruction or not.
|
|
|
|
|
|
|
|
The CPU is queried at boot time to determine which of the multiple
|
|
|
|
implementations of sys_cache_flush() linked into the image is the
|
|
|
|
correct one to use.
|
|
|
|
|
|
|
|
If the CPU's support (or lack thereof) of CLFLUSH is known in advance, then
|
|
|
|
disable this option and set CLFLUSH_INSTRUCTION_SUPPORTED as appropriate.
|
|
|
|
|
|
|
|
config ARCH_CACHE_FLUSH_DETECT
|
|
|
|
bool
|
|
|
|
default y
|
|
|
|
depends on CLFLUSH_DETECT
|
|
|
|
|
2015-06-10 22:25:07 +08:00
|
|
|
endmenu
|
|
|
|
|
2015-03-13 06:15:28 +08:00
|
|
|
menu "Floating Point Options"
|
|
|
|
|
|
|
|
config FLOAT
|
|
|
|
bool
|
2015-10-23 22:33:00 +08:00
|
|
|
prompt "Floating point registers"
|
2015-03-13 06:15:28 +08:00
|
|
|
default n
|
|
|
|
help
|
2015-10-23 22:33:00 +08:00
|
|
|
This option allows tasks and fibers to use the floating point registers.
|
|
|
|
By default, only a single task or fiber may use the registers, and only
|
|
|
|
the x87 FPU/MMX registers may be used.
|
2015-03-13 06:15:28 +08:00
|
|
|
|
|
|
|
Disabling this option means that any task or fiber that uses a
|
2015-10-23 22:33:00 +08:00
|
|
|
floating point register will get a fatal exception.
|
2015-03-13 06:15:28 +08:00
|
|
|
|
|
|
|
config FP_SHARING
|
|
|
|
bool
|
2015-10-23 22:33:00 +08:00
|
|
|
prompt "Floating point register sharing"
|
2015-03-13 06:15:28 +08:00
|
|
|
depends on FLOAT
|
|
|
|
default n
|
|
|
|
help
|
2015-10-23 22:33:00 +08:00
|
|
|
This option allows multiple tasks and fibers to use the floating point
|
|
|
|
registers. Any task that uses the floating point registers must provide
|
|
|
|
stack space where the kernel can save these registers during context
|
|
|
|
switches; a task that uses only the x87 FPU/MMX registers must provide
|
|
|
|
108 bytes of added stack space, while a task the uses the SSE registers
|
|
|
|
must provide 464 bytes of added stack space.
|
2015-03-13 06:15:28 +08:00
|
|
|
|
2015-08-01 04:52:22 +08:00
|
|
|
config SSE
|
|
|
|
bool
|
2015-10-23 22:33:00 +08:00
|
|
|
prompt "SSE registers"
|
2015-09-29 22:08:58 +08:00
|
|
|
depends on FLOAT
|
2015-08-01 04:52:22 +08:00
|
|
|
default n
|
|
|
|
help
|
2015-10-23 22:33:00 +08:00
|
|
|
This option enables the use of SSE registers by tasks and fibers.
|
2015-08-01 04:52:22 +08:00
|
|
|
|
|
|
|
config SSE_FP_MATH
|
|
|
|
bool
|
2015-09-29 22:08:58 +08:00
|
|
|
prompt "Compiler-generated SSEx instructions"
|
2015-08-01 04:52:22 +08:00
|
|
|
depends on SSE
|
2015-09-29 22:08:58 +08:00
|
|
|
default n
|
2015-08-01 04:52:22 +08:00
|
|
|
help
|
|
|
|
This option allows the compiler to generate SSEx instructions for
|
|
|
|
performing floating point math. This can greatly improve performance
|
|
|
|
when exactly the same operations are to be performed on multiple
|
|
|
|
data objects; however, it can also significantly reduce performance
|
|
|
|
when pre-emptive task switches occur because of the larger register
|
|
|
|
set that must be saved and restored.
|
|
|
|
|
|
|
|
Disabling this option means that the compiler utilizes only the
|
|
|
|
x87 instruction set for floating point operations.
|
|
|
|
|
2015-03-13 06:15:28 +08:00
|
|
|
config XIP
|
|
|
|
default n
|
|
|
|
|
|
|
|
endmenu
|
|
|
|
|
2015-06-20 22:38:01 +08:00
|
|
|
|
2015-07-30 01:59:01 +08:00
|
|
|
source "arch/x86/core/Kconfig"
|
|
|
|
|
|
|
|
endmenu
|
|
|
|
|
2015-09-25 22:03:08 +08:00
|
|
|
source "arch/x86/platforms/*/Kconfig"
|
2015-11-22 20:24:14 +08:00
|
|
|
|
2015-10-09 18:20:52 +08:00
|
|
|
endmenu
|