From 6d8266b91d7c8338350f7f8b81c21d10c97aceb6 Mon Sep 17 00:00:00 2001 From: Nico Huber Date: Sat, 20 May 2017 16:46:01 +0200 Subject: Kconfig: Add choice of framebuffer mode Rename `FRAMEBUFFER_KEEP_VESA_MODE` to `LINEAR_FRAMEBUFFER` and put it together with new `VGA_TEXT_FRAMEBUFFER` into a choice. There are two versions of `LINEAR_FRAMEBUFFER` that differ only in the prompt and help text (one for `HAVE_VBE_LINEAR_FRAMEBUFFER` and one for `HAVE_LINEAR_FRAMEBUFFER`). Due to `kconfig_lint` we have to model that with additional symbols. Change-Id: I9144351491a14d9bb5e650c14933b646bc83fab0 Signed-off-by: Nico Huber Reviewed-on: https://review.coreboot.org/19804 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin --- src/device/Kconfig | 42 +++++++++++++++++++++++++++++++++++------- 1 file changed, 35 insertions(+), 7 deletions(-) (limited to 'src/device/Kconfig') diff --git a/src/device/Kconfig b/src/device/Kconfig index 04d8d817b2..c727fba854 100644 --- a/src/device/Kconfig +++ b/src/device/Kconfig @@ -63,7 +63,7 @@ config MAINBOARD_USE_LIBGFXINIT select HAVE_VGA_TEXT_FRAMEBUFFER select HAVE_LINEAR_FRAMEBUFFER select RAMSTAGE_LIBHWBASE - select VGA if !FRAMEBUFFER_KEEP_VESA_MODE + select VGA if VGA_TEXT_FRAMEBUFFER select NO_EDID_FILL_FB default n help @@ -539,16 +539,44 @@ config FRAMEBUFFER_VESA_MODE default 0x11B if FRAMEBUFFER_VESA_MODE_11B default 0x117 if FRAMEBUFFER_VESA_MODE_USER -config FRAMEBUFFER_KEEP_VESA_MODE - prompt "Keep VESA framebuffer" - bool - depends on HAVE_VGA_TEXT_FRAMEBUFFER && (HAVE_VBE_LINEAR_FRAMEBUFFER || HAVE_LINEAR_FRAMEBUFFER) +choice + prompt "Framebuffer mode" + default VGA_TEXT_FRAMEBUFFER + +config VGA_TEXT_FRAMEBUFFER + bool "Legacy VGA text mode" + depends on HAVE_VGA_TEXT_FRAMEBUFFER + help + If this option is enabled, coreboot will initialize graphics in + legacy VGA text mode or, if a VGA BIOS is used and a VESA mode set, + switch to text mode before handing control to a payload. + +config VBE_LINEAR_FRAMEBUFFER + bool "VESA framebuffer" + depends on HAVE_VBE_LINEAR_FRAMEBUFFER help This option keeps the framebuffer mode set after coreboot finishes execution. If this option is enabled, coreboot will pass a framebuffer entry in its coreboot table and the payload will need a - framebuffer driver. If this option is disabled, coreboot will switch - back to text mode before handing control to a payload. + compatible driver. + +config GENERIC_LINEAR_FRAMEBUFFER + bool "Linear \"high-resolution\" framebuffer" + depends on HAVE_LINEAR_FRAMEBUFFER + help + This option enables a high-resolution, linear framebuffer. If this + option is enabled, coreboot will pass a framebuffer entry in its + coreboot table and the payload will need a compatible driver. + +endchoice + +# Workaround to have LINEAR_FRAMEBUFFER set in both cases +# VBE_LINEAR_FRAMEBUFFER and GENERIC_LINEAR_FRAMEBUFFER. +# `kconfig_lint` doesn't let us use the same name with +# different texts in the choice above. +config LINEAR_FRAMEBUFFER + def_bool y + depends on VBE_LINEAR_FRAMEBUFFER || GENERIC_LINEAR_FRAMEBUFFER config BOOTSPLASH prompt "Show graphical bootsplash" -- cgit v1.2.3