aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-03-15 18:00:26 +1300
committerSimon Glass <sjg@chromium.org>2021-03-27 15:04:30 +1300
commitbcac36185b49eaaab437a8db196d804380872c5c (patch)
treef3b674abc129b4f41c24017e0cb11a85e74db9d0 /drivers
parent907bcd3a33253515cb1bdc01077e127c6735f74b (diff)
downloadu-boot-bcac36185b49eaaab437a8db196d804380872c5c.zip
u-boot-bcac36185b49eaaab437a8db196d804380872c5c.tar.gz
u-boot-bcac36185b49eaaab437a8db196d804380872c5c.tar.bz2
video: Fix video on coreboot with the copy buffer
The copy buffer, if enabled, prevents booting from coreboot correctly, since no memory is allocated for it. Allow it to fall back to disabled in this situation. This ensures that a console is displayed, even if it is slow. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/pci/pci_rom.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/pci/pci_rom.c b/drivers/pci/pci_rom.c
index a14a4db..7bad4c8 100644
--- a/drivers/pci/pci_rom.c
+++ b/drivers/pci/pci_rom.c
@@ -349,13 +349,10 @@ int vbe_setup_video_priv(struct vesa_mode_info *vesa,
}
/* Use double buffering if enabled */
- if (IS_ENABLED(CONFIG_VIDEO_COPY)) {
- if (!plat->base)
- return log_msg_ret("copy", -ENFILE);
+ if (IS_ENABLED(CONFIG_VIDEO_COPY) && plat->base)
plat->copy_base = vesa->phys_base_ptr;
- } else {
+ else
plat->base = vesa->phys_base_ptr;
- }
log_debug("base = %lx, copy_base = %lx\n", plat->base, plat->copy_base);
plat->size = vesa->bytes_per_scanline * vesa->y_resolution;