aboutsummaryrefslogtreecommitdiff
path: root/src/config.h
AgeCommit message (Collapse)AuthorFilesLines
2017-09-22add serial console supportGerd Hoffmann1-1/+0
Redirect int10 calls to serial console output. Parse serial input and queue key events. The serial console can work both as primary display and in parallel to another vga display (splitmode). Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2016-04-06optionroms: Drop support for CONFIG_OPTIONROMS_DEPLOYEDKevin O'Connor1-2/+0
No modern software uses this option and it complicates the code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2015-08-04mptable: Don't create mptable if it is very largeKevin O'Connor1-0/+2
Very large mptable structures can fill up the space in the f-segment and cause other important f-segment allocations to fail. Limit the maximum size of the mptable to prevent this. On QEMU, with the current maximum size of 600 bytes, the mptable will not be created in configurations of ~20 cpus or more. The mptable is rarely used in modern OSes so this should not be a problem. Reported-by: Huaitong Han <huaitong.han@intel.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2015-05-21Implementation of the TCG BIOS extensionsStefan Berger1-0/+1
This patch implements the main part of the TCG BIOS extensions. It provides the following functionality: - initialization of the TCPA ACPI table used for logging of measurements - initialization of the TPM by sending a sequence of commands to it - proper setup of the TPM before the BIOS hands over control to the bootloader - support for S3 resume; BIOS sends TPM_Startup(ST_STATE) to TPM - enable configuration of SeaBIOS to be built with TCGBIOS extensions All TCG BIOS extensions are activated with CONFIG_TCGBIOS. Structures that are needed in subsequent patches are also included in tcgbios.h at this point. The effect of this patch is that it initialized the TPM upon VM start and S3 resume. Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2014-06-04smp: Replace QEMU SMP init assembler code with C; run only in 32bit mode.Kevin O'Connor1-0/+1
Change the multi-processor init code to trampoline into 32bit mode on each of the additional processors. Implement an atomic lock so that each processor performs its initialization serially. Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2014-06-04smm: Use a C struct to define the layout of the SMM area.Kevin O'Connor1-3/+2
Describe the memory layout using a struct instead of hard coded offsets. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2014-06-04smm: Replace SMI assembler code with C code.Kevin O'Connor1-0/+1
Convert the SMI handler from assembly to C. This makes the handler easier to understand and enhance. The new handler will use references to the reserved memory at 0xf0000-0x100000. If the physical memory in that range is modified at runtime, then the SMI handler will cease to function properly (and may allow unintended code to run in SMM mode). However, that area is marked as reserved and is normally made read-only at runtime, so there is little risk in relying on it. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2014-04-11Minor - replace some tab characters that slipped into the code.Kevin O'Connor1-1/+1
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2014-01-29Increase maximum size of permanent high memory area.Kevin O'Connor1-1/+1
Some XHCI controllers can request a significant chunk of reserved memory for scratch pad buffers. (At least one controller Intel Haswell based controller has been seen to request 64KiB.) Unused memory is returned after POST completes, so it should be okay to increase the maximum permanent high memory zone from 64K to 256K. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2013-03-18mptable: Use same PCI irqs as ACPI code.Kevin O'Connor1-0/+3
The ACPI code has a hardcoded list of PCI interrupts. Use that same list in the mptable code generation. This will ensure that both tables are in synch - it may also make the mptable easier to generate from QEMU. Also, move the irq0_override lookup outside of the irq loop. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2013-03-03Separate out 16bit PCI-BIOS entry point from regular int 0x1a entry point.Kevin O'Connor1-1/+1
The PCI-BIOS entry point can be called in 16bit protected mode, so separate its entry code from the legacy 0x1a code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2013-02-20Use CONFIG_ prefix for Kconfig variables; use BUILD_ for others.Kevin O'Connor1-14/+14
Rename remaining "build" settings in config.h that used the CONFIG_ prefix to use a BUILD_ prefix. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2013-02-19Eliminate separate BiosTableSpace[] space for f-segment allocations.Kevin O'Connor1-2/+0
The BiosTableSpace variable was used to ensure there was sufficient space in the f-segment for malloc_fseg() calls. However, it added 2K to the final image size to reserve that space. Update the build to determine where to put the f-segment allocations. In most cases (when code relocation is enabled) allocations can be done in the space free'd from the "init" sections and no additional space needs to be reserved in the final image. This also has the benefit of not fragmenting the f-segment allocation space. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2012-12-01seabios: make mttr UC area setup dynamicJason Baron1-1/+0
Set up the UC area of mtrr dynamically based on mtrr_base. This allows the bios to work for other chipsets that might want to set the mtrr. Since BUILD_MAX_HIGHMEM is no longer used we can remove the config parameter. This change reverses the order of pci_setup() and smm_init() with mtrr_setup(). Signed-off-by: Jason Baron <jbaron@redhat.com>
2012-08-01report real I/O APIC ID (0) on MADT and MP-table (v3)Eduardo Habkost1-0/+1
When resetting an I/O APIC, its ID is set to 0, and SeaBIOS doesn't change it, so report it correctly on the ACPI MADT table and MP-table. Some hardware may require the BIOS to initialize I/O APIC ID to an unique value, but SeaBIOS doesn't do that. This patch at least makes the tables reflect reality. Changes v2 -> v3: - Fix MP-table too, not just ACPI MADT table Changes v1 -> v2: - Cosmetic: whitespace change (removed extra newline) - New patch description Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
2012-05-21Allow optionroms and "low mem" to share space.Kevin O'Connor1-1/+0
Allow both optionroms and "low mem" allocations to use the e-segment. (Space is allocated on a "first come, first serve" basis). This allows more flexibility in resource assignment. Also, allow the "low mem" area to use a full 64K. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2012-05-20Add mechanism to declare variables as "low mem" and use for extra stack.Kevin O'Connor1-0/+1
Add a mechanism (VARLOW declaration) to make a variable reside in the low memory (e-segment) area. This is useful for runtime variables that need to be accessed from 16bit code and need to be modifiable during runtime. Move the 16bit "extra stack" from the EBDA to the low memory area using this declaration mechanism. Also increase the size of this stack from 512 bytes to 2048 bytes. This also reworks tools/layoutrom.py a bit. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2012-05-13Use the e-segment instead of the 9-segment for bios "low mem".Kevin O'Connor1-0/+1
Use the e-segment for ZoneLow allocations. There is plenty of e-segment space (there has been since SeaBIOS supported code relocation), while using the 9-segment space can impact old real-mode applications. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2012-04-26pciinit: Migrate 64bit entries to 64bit pci regionsAlexey Korolev1-0/+2
Migrate 64bit entries to 64bit pci regions if they do not fit in 32bit range. Signed-off-by: Alexey Korolev <alexey.korolev@endace.com>
2011-09-20Minor - move ACPI_HPET_ADDRESS definition to config.h.Kevin O'Connor1-8/+7
Move ACPI_HPET_ADDRESS to BUILD_HPET_ADDRESS in config.h so that it is listed with similar hardcoded addresses. Also, organize the BUILD_*_ADDRESS definitions in config.h. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
2011-08-03Allow allocation of SMBIOS table in f-segment if it is small.Kevin O'Connor1-0/+2
If the SMBIOS is small (less than 600 bytes) allow it to be allocated in the f-segment. This works around a bug in JunOS - it crashes on SMBIOS tables located in high memory.
2011-07-12pci: set BUILD_PCIMEM_START to 0xe0000000Gerd Hoffmann1-1/+1
... and make it match with the declarations in acpi-dsdt.dsl. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-07-12pci: cleanup config.hGerd Hoffmann1-14/+0
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2011-06-20Remove support for compiling in OPTIONROM_VENDEV_1/2.Kevin O'Connor1-7/+0
Passing in rom locations via absolute memory addresses hasn't been needed since coreboot adopted CBFS support (which as several years ago).
2011-01-30Expand user configurable parameters in Kconfig.Kevin O'Connor1-104/+0
Move most of the config settings in config.h to the Kconfig file. The remaining settings in config.h, are mostly build related.
2011-01-29Support non-local build directory - allow "make OUT=abc/" to work.Kevin O'Connor1-1/+1
Don't require the build directory to be the "out/" directory of the SeaBIOS source.
2011-01-29Start using Kconfig to configure SeaBIOS settings.Kevin O'Connor1-9/+2
Create autoconf.h during the build. Move a couple of config settings from config.h to Kconfig.
2010-12-05add ahci supportGerd Hoffmann1-0/+2
This patch adds AHCI support to seabios. Tested with virtual hardware only (upcoming ahci support in qemu). Coded by looking at the recommandations in the intel ahci specs, so I don't expect much trouble on real hardware. Tested booting fedora install from hard disk and a opensuse live iso from cdrom. [ v2: disable by default ] [ v2: add check for malloc failure ] [ v2: wind up disk write support ] Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2010-09-25Move the 32bit init code to high memory at runtime.Kevin O'Connor1-0/+2
Add support for moving the 32bit init code out of the e/f-segments and into temporary ram. Update the relocations in the code so that it can live at its new address. This frees up memory for other uses in the e/f segments.
2010-07-30Default bootsplash on (for coreboot users).Kevin O'Connor1-1/+1
2010-07-30Autodetect video mode based on bootsplash jpeg dimensions.Kevin O'Connor1-8/+0
Replace video mode settings in config.h with a system to auto-detect a video mode for the given bootsplash.jpg file.
2010-07-04seabios: pciinit: make pci bar assigner preferchable memory aware.Isaku Yamahata1-0/+17
Make pci bar assigner preferchable memory aware. This is needed for PCI bridge support because memory space and prefetchable memory space is filtered independently based on memory base/limit and prefetchable memory base/limit of pci bridge. On bus 0, such a distinction isn't necessary so keep existing behavior by checking bus=0. With this patch, pci mem assignment area has been decreased. To make seabios behave as before for compatible reason, define CONFIG_OLD_PCIMEM_ASSIGNMENT. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
2010-06-28Initial bootsplash support.Kevin O'Connor1-0/+10
Support displaying a jpeg file (stored in cbfs) during bootup. Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
2010-05-10Support for booting from virtio disksGleb Natapov1-0/+3
This patch adds native support for booting from virtio disks to Seabios. Signed-off-by: Gleb Natapov <gleb@redhat.com>
2010-05-01Add support for USB mice.Kevin O'Connor1-0/+2
Initial support for USB mice that follow the "boot" protocol.
2010-03-20Default CONFIG_COREBOOT_FLASH on; make depend on CONFIG_COREBOOT.Kevin O'Connor1-1/+1
Coreboot users will almost certainly want CBFS support, and non-coreboot users have no use for it. So, make that the default behaviour.
2010-03-09Add USB EHCI controller support.Kevin O'Connor1-0/+2
Initial support for EHCI high-speed USB controllers.
2010-02-28Dynamically allocate ata_channel info; introduce custom atadrive_s struct.Kevin O'Connor1-3/+0
Don't limit the number of ATA controllers supported - just dynamically allocate the structs. Create an atadrive_s struct that extends the standard 'struct drive_s' and have the new struct store a pointer to the ata channel info. Also, prefer storing drive_s pointers as 32bit "flat" pointers - adjust them as needed in the 16bit code.
2010-02-17Initial support for booting from USB drives.Kevin O'Connor1-0/+2
This patch adds initial support for USB Mass Storage Controllers. This includes support for bulk transfers on UHCI controllers. Code to detect a USB MSC device is added, and wrappers for sending "cdb" block commands over USB are added. The scsi "inquiry" command is also added.
2010-02-15Dynamically allocate each drive_g with malloc_fseg().Kevin O'Connor1-3/+1
This eliminates the limit on the number of available drives. It also allows for each driver to allocate additional custom fields.
2010-02-15Initial support for USB hubs.Kevin O'Connor1-0/+2
Add support for detecting, initializing, and enumerating USB hubs.
2010-01-28Go back to using 0xf0000000 for PCI memory start.Kevin O'Connor1-0/+1
Qemu/Kvm still has some dependencies on 0xe0000000, so go back until they are ready.
2010-01-17Add CONFIG_ATA_DMA option; default to off for now.Kevin O'Connor1-0/+2
Allow compile option to disable ATA DMA support. Turn it off by default for now - some coreboot users are seeing issues with it.
2010-01-01Implement native 32bit APM support.Kevin O'Connor1-0/+1
Add APM code to 32bit segmented code. Use 32bit APM code instead of jumping into 16bit mode.
2009-12-30Add support for 32bit PCI BIOS entry.Kevin O'Connor1-0/+1
Create a new code blob (code32seg) with support for 32bit functions that need to utilize explicit segment accesses. This code blob uses global variables relative to %gs and with a dynamic code offset (determined by get_global_offset()). Add BIOS32 structure and code. Add code for 32bit PCI BIOS code.
2009-12-23Add symbolic definitions for MTRR code.Kevin O'Connor1-0/+1
2009-12-18Disable CONFIG_OPTIONROMS_DEPLOYED by defaultAnthony Liguori1-1/+1
Since qemu now supports loading option roms through PCI Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-13Distinguish between debug reports for unimplemented vs invalid calls.Kevin O'Connor1-4/+7
Don't use "fail" in the debug output - as this confuses users. When reporting on an invalid parameter - use the word "invalid". When reporting on an unimplemented call - state it is unimplemented. Add separate debug levels for unimplemented vs invalid calls. Also, increase the debug level of several entry points.
2009-12-09Move ps2 specific keyboard and mouse code to ps2port.c.Kevin O'Connor1-1/+3
2009-12-09Add experimental feature to run vga optionrom in parallel with init.Kevin O'Connor1-1/+3
Add option (default disabled) that allows the vga rom to run while hardware init is still in progress.