[coreboot-gerrit] Change in coreboot[master]: drivers/intel/gma/vbt.c: Add GENERAL DEFINITIONS block to fake vbt
Arthur Heymans (Code Review)
gerrit at coreboot.org
Thu Sep 7 20:43:52 CEST 2017
Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/21448
Change subject: drivers/intel/gma/vbt.c: Add GENERAL DEFINITIONS block to fake vbt
......................................................................
drivers/intel/gma/vbt.c: Add GENERAL DEFINITIONS block to fake vbt
This is needed for Linux (at least 4.12) to know on which DDC gmbus to
probe for VGA edid.
TESTED on dg43gt: Use NGI with a payload like grub that doesn't
override VBT (seavgabios) with a DVI-I to VGA adapter and observe that
Linux can properly modeset the display.
Change-Id: I5bce00d2e37d77c27cf0022c7dab3444c3699dcf
Signed-off-by: Arthur Heymans <arthur at aheymans.xyz>
---
M src/drivers/intel/gma/vbt.c
1 file changed, 15 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/48/21448/1
diff --git a/src/drivers/intel/gma/vbt.c b/src/drivers/intel/gma/vbt.c
index c908eb4..ffb56e9 100644
--- a/src/drivers/intel/gma/vbt.c
+++ b/src/drivers/intel/gma/vbt.c
@@ -69,6 +69,21 @@
ptr += sizeof (*genfeat);
+ *ptr++ = BDB_GENERAL_DEFINITIONS;
+ *ptr++ = sizeof(struct bdb_general_definitions);
+ *ptr++ = sizeof(struct bdb_general_definitions) >> 8;
+ struct bdb_general_definitions *const gendef =
+ (struct bdb_general_definitions *)ptr;
+ if (IS_ENABLED(CONFIG_GFX_GMA_ANALOG_I2C_HDMI_B))
+ gendef->crt_ddc_gmbus_pin = GMBUS_PORT_DPB;
+ else if (IS_ENABLED(CONFIG_GFX_GMA_ANALOG_I2C_HDMI_C))
+ gendef->crt_ddc_gmbus_pin = GMBUS_PORT_DPC;
+ else if (IS_ENABLED(CONFIG_GFX_GMA_ANALOG_I2C_HDMI_D))
+ gendef->crt_ddc_gmbus_pin = GMBUS_PORT_DPD;
+ else
+ gendef->crt_ddc_gmbus_pin = GMBUS_PORT_VGADDC;
+ ptr += sizeof(*gendef);
+
bdb_head->bdb_size = ptr - (u8 *)bdb_head;
head->vbt_size = ptr - (u8 *)head;
head->vbt_checksum = 0;
--
To view, visit https://review.coreboot.org/21448
To unsubscribe, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I5bce00d2e37d77c27cf0022c7dab3444c3699dcf
Gerrit-Change-Number: 21448
Gerrit-PatchSet: 1
Gerrit-Owner: Arthur Heymans <arthur at aheymans.xyz>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20170907/0459d114/attachment.html>
More information about the coreboot-gerrit
mailing list