aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* pci: only migrate large 64bit bars above 4Gpci-4g-mapGerd Hoffmann2019-03-201-0/+2
| | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* vga: add ati bios tablesGerd Hoffmann2019-03-152-0/+46
| | | | | | | Needed to make drivers happy which try to gather informations from these tables. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* vga: add atiext driverGerd Hoffmann2019-03-155-1/+271
| | | | | | | | | | | | Supports qemu emulated ati cards. They have been added in qemu 4.0. Acceleration support (in qemu) is pretty rough still. A simple framebuffer works fine though. Available models: * ati rage 128 pro * ati rv100 Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* vga: make memcpy_high() publicGerd Hoffmann2019-03-142-2/+2
| | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* vga: move modelist from bochsvga.c to new svgamodes.cGerd Hoffmann2019-03-144-87/+109
| | | | | | So other drivers can simply use the same list too. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* tcgbios: Implement TPM 2.0 menu item to activate and deactivate PCR banksStefan Berger2019-02-042-0/+240
| | | | | | | | | | | | | | | | | | Implement a TPM 2.0 menu item that allows a user to toggle the activation of PCR banks of the TPM 2.0. After successful activation we shut down the TPM 2.0 and reset the machine. Background: A TPM 2.0 may have multiple PCR banks, such as for SHA1, SHA256, SHA384, SHA512, and SM3-256. One or multiple of those banks may be active (by factory for example) and modifying the set of active PCR banks is only possible while in the firmware since it requires platform authorization. Platform authorization is not possible for a user when in the OS since the firmware generates a random password for the platform authorization before booting the system and it throws that password away. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
* tcgbios: Use table to convert hash to buffer sizeStefan Berger2019-02-041-13/+28
| | | | | | Use a table to convert the hash to the buffer size it needs. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
* usb-ehci: Clear pipe token on pipe reallocateKevin O'Connor2019-02-041-0/+1
| | | | | | | Make sure to clear the token before reuse as it may otherwise have an incorrect toggle setting. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* bootsplash: Added support for 16/24/32bpp in one functionJoseph Pacheco-Corwin2019-02-043-14/+13
| | | | | | | | | | | | | | | | | | | Specifically added support for 16 and 32bpp files, in addition to 24bpp. The function bmp_show() in bmp.c has had the hardcoded check for 24bpp replaced with a general bpp check that uses a % to check for remainder, and returns 1 if the remainder is >0. The previous method for adjusting the BMP data (raw_data_format_adjust_24bpp) relied on a preset 3*bytes_per_line_src, this has been changed and the multiplication is now performed in the function's arguments. This change still allows someone else to reuse the same function for 1/2/4bpp support if necessary. The file util.h has been modified to reflect this decision. The changes to raw_data_format_adjust() is based on an abandoned patch by Gert Menke (submitted March 14, 2017), credit to them for that change and the addition of *bpp to bmp_get_info(). Signed-off-by: Joseph S. Pacheco-Corwin <hammersamatom@gmail.com>
* docs: Fix cut-and-paste error in Mailinglist.md archive linkKevin O'Connor2019-01-211-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* docs: Update mailing list archive linksKevin O'Connor2019-01-201-6/+12
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* output: Avoid thunking to 16bit mode in printf() if no vgabiosKevin O'Connor2018-12-171-0/+3
| | | | | | | | | It is not necessary to call the vgabios if no vgabios has been installed. This reduces the amount of hardware accesses on qemu when the bios is not initializing the display hardware, and it can reduce the boot time by a couple of milliseconds. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* qemu: avoid debug prints if debugcon is not enabledStefano Garzarella2018-12-104-2/+21
| | | | | | | | | | | | In order to speed up the boot phase, we can check the QEMU debugcon device, and disable the writes if it is not recognized. This patch allow us to save around 10 msec (time measured between SeaBIOS entry point and "linuxboot" entry point) when CONFIG_DEBUG_LEVEL=1 and debugcon is not enabled. Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* pvscsi: ring_desc do not have to be page alignedLiran Alon2018-11-271-1/+1
| | | | | | | | | | In contrast to other allocations made by pvscsi_init_rings(), ring_desc is only used internally by SeaBIOS (not passed to device-controller) and there is not restriction which force it to be page aligned. Reviewed-by: Mark Kanda <mark.kanda@oracle.com> Signed-off-by: Liran Alon <liran.alon@oracle.com>
* tpm: Check for TPM related ACPI tables before attempting hw probeStephen Douthit2018-11-271-7/+7
| | | | Signed-off-by: Stephen Douthit <stephend@silicom-usa.com>
* docs: Note v1.12.0 releaseKevin O'Connor2018-11-171-0/+21
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* shadow: Rework bios copy code to prevent gcc array-bounds warningKevin O'Connor2018-11-101-5/+6
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* pvscsi: Scan all 64 possible targetsShmuel Eiderman2018-11-101-1/+1
| | | | | | | | | | | | | The max number of targets per PVSCSI controller is 64, not 7. This can easily be seen in QEMU PVSCSI emulation code (hw/scsi/vmw_pvscsi.c) as PVSCSI_MAX_DEVS, which defines the number of targets, have value of 64. Fixes: 83d60b3c474b ("Add pvscsi boot support") Reviewed-by: Liran Alon <liran.alon@oracle.com> Reviewed-by: Mark Kanda <mark.kanda@oracle.com> Signed-off-by: Shmuel Eiderman <shmuel.eiderman@oracle.com>
* pretty boot menu entry for cdrom drivesGerd Hoffmann2018-10-053-0/+57
| | | | | | Show the volume label of bootable cdroms. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* SeaVGABios/cbvga: Fix bpp for coreboot framebufferMatt DeVillier2018-09-181-2/+8
| | | | | | | | | | | | | | | | Commit 4b42cc4 [SeaVGABios/cbvga: Advertise correct pixel format] neglected to wrap the cbfb mask size components in GET_FARVAR(), which resulted in a bogus value for bpp, breaking output on most/all devices. Fix this by adding GET_FARVAR() as appropriate. Additionally, some newer ChromeOS devices still fail even with this fix, so fall back to using the coreboot reported bit depth if the calculated valid is invalid. TEST: build/boot a variety of devices (google/[reef,eve], purism/librem_skl) using coreboot framebuffer init, verify SeaBIOS boot menu prompt visible. Signed-off-by: Matt DeVillier <matt.devillier@puri.sm>
* pci: recognize RH PCI legacy bridge resource reservation capabilityJing Liu2018-09-052-21/+30
| | | | | | | | | | | | Enable the firmware recognizing RedHat legacy PCI bridge device ID, so QEMU can reserve additional PCI bridge resource capability. Change the debug level lower to 3 when it is non-QEMU bridge. Signed-off-by: Jing Liu <jing2.liu@linux.intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Marcel Apfelbaum<marcel.apfelbaum@gmail.com> Message-id: 1535100781-3910-4-git-send-email-jing2.liu@linux.intel.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* pci: clean up the debug message for pci capability foundJing Liu2018-09-051-1/+3
| | | | | | | | | | Improve the debug message when QEMU resource reserve cap is not found and when the vendor-id or device-id does't match REDHAT special ones. Signed-off-by: Jing Liu <jing2.liu@linux.intel.com> Message-id: 1535100781-3910-3-git-send-email-jing2.liu@linux.intel.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* pci: fix the return value for truncated capabilityJing Liu2018-09-051-0/+1
| | | | | | | | Return zero when finding truncated capability. Signed-off-by: Jing Liu <jing2.liu@linux.intel.com> Message-id: 1535100781-3910-2-git-send-email-jing2.liu@linux.intel.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* sdcard: Increase SDHCI_POWER_ON_TIME to 5msKevin O'Connor2018-09-031-1/+1
| | | | | | | | It appears some sd cards need additional time to initialize after power on. Reported-by: Chris <coderight@gmail.com>. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* nvme: fix I/O queue length calculation overflowMatt DeVillier2018-08-231-2/+2
| | | | | | | | | | | | | | | | Commit cd47172 changed the I/O queue length calculation to use the Maximum Queue Entries Supported (MQES) value from the capabilities register, plus one, with a maximum value of NVME_PAGE_SIZE. An unintended effect from this is that due to length being an unsigned 16-bit int, a MQES value of 0xFFFF yields a length of zero, resulting in the queue allocation failing. Fix this by changing length to a u32. TEST: build/boot on a Purism Librem13v2 with a MyDigitalSSD BPX NVMe drive, which reports a MQES of 0xFFFF. Verify NVMe drive present in boot menu and OS boots successfully. Signed-off-by: Matt DeVillier <matt.devillier@puri.sm>
* docs: Update download file linkKevin O'Connor2018-08-091-1/+1
| | | | | | Released versions are now at: https://www.seabios.org/downloads/ Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* ssdt: Fix building of legacy acpi tables on current iasl compilerKevin O'Connor2018-07-152-2/+2
| | | | | | | | | | | | | Recent versions of the iasl compiler raise an error if the table id is longer than 8 characters. Older versions of iasl would silently truncate the table id to 8 characters. Change the ssdt-misc and ssdt-pcihp files to use an 8 character id - this should not directly impact the generated aml code as the table id was already being truncated - but may help those wishing to manually compile the tables. Reported by Michael Tokarev, Vivia Nikolaidou, and several others. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* cbvga_set_mode: refine clear display logicGerd Hoffmann2018-06-261-8/+10
| | | | | | | There is no need to skip text mode clearing. Clearing the framebuffer should be safe on legacy calls too. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* qemu: add qemu ramfb supportGerd Hoffmann2018-06-225-14/+189
| | | | | | | | | | | | | | | | | Add support for qemu ramfb. This is a simple boot framebuffer device, with normal ram being used to back the framebuffer and fw_cfg being used to configure the device. Use case (on x86): boot display for vgpu devices (which neither emulate vga nor have a vgabios). Sharing fw_cfg code with seabios turned out to be difficuilt due to various dependencies the code has on infrastructure which only seabios has. So include a copy of the code here, with those dependencies removed and also stripped down because we don't need a non-dma fallback here. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* vgasrc: add allocate_pmm()Gerd Hoffmann2018-06-222-16/+33
| | | | | | Factor out pmm allocation function from stack allocator. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* pmm: use tmp zone on oomGerd Hoffmann2018-06-221-0/+13
| | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* bochs_display_setup: return error on failureGerd Hoffmann2018-06-221-1/+1
| | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* cbvga_set_mode: disable clearmem in windows x86 emulator.Gerd Hoffmann2018-06-221-1/+9
| | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* cbvga_list_modes: don't list current mode twiceGerd Hoffmann2018-06-221-1/+5
| | | | | | | In case we've already added the framebuffer video mode to the list do not add number 0x140. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* cbvga_setup_modes: use real mode number instead of 0x140Gerd Hoffmann2018-06-221-0/+5
| | | | | | | In case the framebuffer size matches one of the cbvga video modes just use that mode number instead of 0x140. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* qemu: add bochs-display supportGerd Hoffmann2018-06-225-14/+95
| | | | | | | | | | Use coreboot text mode emulation to also support the qemu bochs-display device. This is a new display device supporting simple linear framebuffers, using the bochs register interface. No support for legacy vga (text modes, planar modes, cga modes, 8bpp palette modes all dropped). The bochs interface is compatible with the qemu stdvga. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* cbvga: factor out cbvga_setup_modes()Gerd Hoffmann2018-06-222-25/+33
| | | | | | Factor out generic data structure setup code from cbvga_setup(). Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* optionrom: enable non-vga display devicesGerd Hoffmann2018-06-221-1/+28
| | | | | | In case no VGA device was found look for other display devices. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* docs: Update Download.md to use git clone via httpsKevin O'Connor2018-06-111-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* tpm: Request access to locality 0Stefan Berger2018-04-121-0/+2
| | | | | | | The CRB driver has to request access to locality 0. Our QEMU CRB model will enforce that as well. Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: when CRB is active, select, lock it, and check addressesStefan Berger2018-03-211-3/+1
| | | | | | | | Do not just indicate that the probing for the CRB interface was successful if we find it active. Instead, select it, lock it, and test the addresses for whether they can be used (must be 32 bit). Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: revert return values for successful/failed CRB probingStefan Berger2018-03-211-3/+3
| | | | | | | The return values for successful/failed CRB probing were reverted. Fix it. Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: Wait for tpmRegValidSts flag on CRB interface before probingStefan Berger2018-03-211-0/+10
| | | | | | | | | | | Wait for the tpmRegValidSts flag on the TPM_LOC_STATE_x register to be set; we expect the locAssigned flag to not be set. Real hardware seems to set the tpmRegValidSts flag without for example requesting access to a locality. Tested-by: Stephen Douthit <stephend@silicom-usa.com> Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: Handle unimplemented TIS_REG_IFACE_ID in tis_get_tpm_version()Stephen Douthit2018-03-021-5/+15
| | | | | | | | | | If a device reports 0xf in the InterfaceType field of the TPM_INTERFACE_ID, then the rest of the fields are invalid, and the InterfaceVersion field of the TPM_INTF_CAPABILITY register must be checked instead. Signed-off-by: Stephen Douthit <stephend@silicom-usa.com> Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: Wait for interface startup when probingStephen Douthit2018-03-021-1/+12
| | | | | | | | This is based on wait_startup() from the Linux tpm_tis driver. Signed-off-by: Stephen Douthit <stephend@silicom-usa.com> Tested-by: Stephen Douthit <stephend@silicom-usa.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: Refactor duplicated wait code in tis_wait_sts() & crb_wait_reg()Stephen Douthit2018-03-021-47/+33
| | | | | | Signed-off-by: Stephen Douthit <stephend@silicom-usa.com> Tested-by: Stephen Douthit <stephend@silicom-usa.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: add TPM CRB device supportMarc-André Lureau2018-02-272-1/+221
| | | | | | | | | | | | | | | | The CRB device was introduced with TPM 2.0 to be physical-bus agnostic and defined in TCG PC Client Platform TPM Profile (PTP) Specification Family “2.0” Level 00 Revision 01.03 v22 It seems to be required with Windows 10. It is also a simpler device than FIFO/TIS. This patch only support locality 0 since also the CRB device in QEMU only supports this locality. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: use get_tpm_version() callbackMarc-André Lureau2018-02-271-1/+2
| | | | | | | | As originally intended. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* tpm: generalize init_timeout()Marc-André Lureau2018-02-271-10/+15
| | | | | | | | | It seems both TIS & CRB devices share the same timeout. Make initialization function generic now. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
* x86: add readq()Marc-André Lureau2018-02-271-0/+5
| | | | | | Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Stefan Berger <stefanb@linux.vnet.ibm.com> Tested-by: Stefan Berger <stefanb@linux.vnet.ibm.com>