aboutsummaryrefslogtreecommitdiff
path: root/src/device
diff options
context:
space:
mode:
Diffstat (limited to 'src/device')
-rw-r--r--src/device/Kconfig10
-rw-r--r--src/device/pci_device.c9
2 files changed, 19 insertions, 0 deletions
diff --git a/src/device/Kconfig b/src/device/Kconfig
index 0e5de456ae..421ad66fea 100644
--- a/src/device/Kconfig
+++ b/src/device/Kconfig
@@ -117,6 +117,16 @@ config NO_GFX_INIT
endchoice
+config PRE_GRAPHICS_DELAY
+ int "Graphics initialization delay in ms"
+ default 0
+ depends on VGA_ROM_RUN
+ help
+ On some systems, coreboot boots so fast that connected monitors
+ (mostly TVs) won't be able to wake up fast enough to talk to the
+ VBIOS. On those systems we need to wait for a bit before executing
+ the VBIOS.
+
config ONBOARD_VGA_IS_PRIMARY
bool "Use onboard VGA as primary video device"
default n
diff --git a/src/device/pci_device.c b/src/device/pci_device.c
index 66f5447126..cd98f07605 100644
--- a/src/device/pci_device.c
+++ b/src/device/pci_device.c
@@ -732,6 +732,12 @@ static int should_load_oprom(struct device *dev)
return 0;
}
+static void oprom_pre_graphics_stall(void)
+{
+ if (CONFIG_PRE_GRAPHICS_DELAY)
+ mdelay(CONFIG_PRE_GRAPHICS_DELAY);
+}
+
/** Default handler: only runs the relevant PCI BIOS. */
void pci_dev_init(struct device *dev)
{
@@ -760,6 +766,9 @@ void pci_dev_init(struct device *dev)
if (!should_run_oprom(dev, rom))
return;
+ /* Wait for any configured pre-graphics delay */
+ oprom_pre_graphics_stall();
+
run_bios(dev, (unsigned long)ram);
gfx_set_init_done(1);