aboutsummaryrefslogtreecommitdiff
path: root/src/mainboard/lenovo/t400/romstage.c
diff options
context:
space:
mode:
authorArthur Heymans <arthur@aheymans.xyz>2018-09-16 18:55:28 +0200
committerPatrick Georgi <pgeorgi@google.com>2019-05-21 09:25:41 +0000
commit03180212b7295d288bd79c5756d9355c55bd2193 (patch)
tree1b44688f380b101a6b17012e4e9f3f01694272d4 /src/mainboard/lenovo/t400/romstage.c
parent86fa2792b98cabd0b8604342a44e099d8ade5a77 (diff)
mb/lenovo/r500: Add mainboard
Tested: - Ethernet NIC - Wifi RFKill - USB - LVDS, VGA with libgfxinit - Booting with dock attached (COM1) - Keyboard, trackpoint - SeaBIOS 1.12 - S3 resume - Tested in descriptor mode, with vendor FD and ME - Add VBT to ACPI OPregion Untested: - SATA (likely works) - Trackpad (my cable is broken, likely works) - Displayport (likely works) - Descriptorless mode - DVD drive - Extra battery - model with ATI GPU Does not work: - Dock hotplug - Quad core CPU (hangs during AP init, probably needs hardware mod) - Hotplugging the expresscard slot (works with 'echo 1 | sudo tee /sys/bus/pci/rescan') TODO: - proper dock support - documentation note: This board was hard to flash, I had to desolder the flash. TESTED: on a R500 with an Intel iGPU, SeaBIOS 1.12, Debian 9, Linux 4.9 from USB Change-Id: I9e129b2e916acdf2b8534fa9d8d2cfc8f64f5815 Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/28644 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Diffstat (limited to 'src/mainboard/lenovo/t400/romstage.c')
-rw-r--r--src/mainboard/lenovo/t400/romstage.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/mainboard/lenovo/t400/romstage.c b/src/mainboard/lenovo/t400/romstage.c
index 6b03ad0ad8..43d6088788 100644
--- a/src/mainboard/lenovo/t400/romstage.c
+++ b/src/mainboard/lenovo/t400/romstage.c
@@ -75,7 +75,21 @@ void mb_pre_raminit_setup(sysinfo_t *sysinfo)
else
dock_info();
- hybrid_graphics_init(sysinfo);
+ if (CONFIG(BOARD_LENOVO_R500)) {
+ int use_integrated = get_gpio(21);
+ printk(BIOS_DEBUG, "R500 variant found with an %s GPU\n",
+ use_integrated ? "integrated" : "discrete");
+ if (use_integrated) {
+ sysinfo->enable_igd = 1;
+ sysinfo->enable_peg = 0;
+ } else {
+ sysinfo->enable_igd = 0;
+ sysinfo->enable_peg = 1;
+ }
+ } else {
+ hybrid_graphics_init(sysinfo);
+ }
+
}
void mb_post_raminit_setup(void)