mb/starlabs/starbook: Add CFR option to use native panel resolution
For boards for which set the 'Fixed Mode at boot' flag in the VBT, add a CFR option to boot using the native panel resolution, rather than a fixed/scaled video mode. This option selects between two VBT files: one with the 'fixed mode' flag enabled, and one with it disabled. This feature is mainly a workaround to a GNOME-related bug which causes the creation of a 2nd display at the boot resolution. This 2nd display being a lower/different resolution than the native panel resolution causes severe flickering/artifacting rendering the display unusable unless this 2nd phantom display is disabled on every boot Change-Id: Ia75727f393744caf9062763e6118c1e2601512fa Signed-off-by: Matt DeVillier <matt.devillier@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/87493 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Sean Rhodes <sean@starlabs.systems> Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
This commit is contained in:
parent
8fa84d9111
commit
d13afbbbca
8 changed files with 29 additions and 0 deletions
|
|
@ -264,4 +264,9 @@ config BOARD_SUPPORTS_HOTPLUG
|
|||
default y if BOARD_STARLABS_STARBOOK_ADL
|
||||
default n
|
||||
|
||||
config BOARD_USES_FIXED_MODE_VBT
|
||||
bool
|
||||
default y if BOARD_STARLABS_STARBOOK_ADL_N || BOARD_STARLABS_STARBOOK_MTL
|
||||
default n
|
||||
|
||||
endif
|
||||
|
|
|
|||
|
|
@ -57,6 +57,9 @@ static struct sm_obj_form devices = {
|
|||
.ui_name = "Devices",
|
||||
.obj_list = (const struct sm_object *[]) {
|
||||
&card_reader,
|
||||
#if CONFIG(BOARD_USES_FIXED_MODE_VBT)
|
||||
&display_native_res,
|
||||
#endif
|
||||
#if CONFIG(BOARD_HAS_FPR)
|
||||
&fingerprint_reader,
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -209,4 +209,12 @@ static const struct sm_object bluetooth_rtd3 = SM_DECLARE_BOOL({
|
|||
.default_value = true,
|
||||
});
|
||||
|
||||
static const struct sm_object display_native_res = SM_DECLARE_BOOL({
|
||||
.opt_name = "display_native_res",
|
||||
.ui_name = "Display: Use Native Resolution",
|
||||
.ui_helptext = "Enabled: use the native panel resolution at boot.\n"
|
||||
"Disabled: use a fixed/scaled video mode at boot.",
|
||||
.default_value = false,
|
||||
});
|
||||
|
||||
#endif /* _STARBOOK_CFR_H_ */
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
|
||||
#include <device/device.h>
|
||||
#include <drivers/intel/gma/opregion.h>
|
||||
#include <soc/ramstage.h>
|
||||
#include <option.h>
|
||||
#include <variants.h>
|
||||
|
|
@ -25,3 +26,11 @@ static void init_mainboard(void *chip_info)
|
|||
struct chip_operations mainboard_ops = {
|
||||
.init = init_mainboard,
|
||||
};
|
||||
|
||||
const char *mainboard_vbt_filename(void)
|
||||
{
|
||||
if (CONFIG(BOARD_USES_FIXED_MODE_VBT) && get_uint_option("display_native_res", 0) == 1)
|
||||
return "vbt_native_res.bin";
|
||||
|
||||
return "vbt.bin";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,3 +8,5 @@ ramstage-y += devtree.c
|
|||
ramstage-y += gpio.c
|
||||
ramstage-y += hda_verb.c
|
||||
ramstage-y += ramstage.c
|
||||
|
||||
$(call add_vbt_to_cbfs, vbt_native_res.bin, data_native_res.vbt)
|
||||
|
|
|
|||
Binary file not shown.
|
|
@ -7,3 +7,5 @@ romstage-y += romstage.c
|
|||
ramstage-y += devtree.c
|
||||
ramstage-y += gpio.c
|
||||
ramstage-y += hda_verb.c
|
||||
|
||||
$(call add_vbt_to_cbfs, vbt_native_res.bin, data_native_res.vbt)
|
||||
|
|
|
|||
BIN
src/mainboard/starlabs/starbook/variants/mtl/data_native_res.vbt
Normal file
BIN
src/mainboard/starlabs/starbook/variants/mtl/data_native_res.vbt
Normal file
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue