State of Lenovo Notebooks Running Coreboot Who Am I
Total Page:16
File Type:pdf, Size:1020Kb
State of Lenovo notebooks running coreboot Who am I B.Sc. Electrical Engineering coreboot developer since 2015 privately motivated Maintaining Lenovo devices from day zero Working at 9eSec as Hardware- and Softwareengineer Contact: [email protected] Why are Lenovo's so awesome? Community driven Wide variety of platforms First class support Actively maintained by community BLOB free Cheap Easy to buy rugged case Good documentation Overview Past Statistics Current state Future Significant changes over the last years Significant changes 2015 General TPM 1.2 support Fix infinite notification loop on shutdown ACPI warnings fixed X60/T60 Native graphics init Brightness control T400/T500 Hybrid graphic support T430s/x220/x230/T530 ACPI code for hybrid graphics ACPI Improved native raminit HDA verb fixes USB3 support X200 Enable PEG device Support disabled IGD Pen support in tablet mode Basic IOMMU support Fixed panel flickering Picture by Infineon Press Photo, https://www.infineon.com/export/sites/default/media/press/Image/press_photo/TPM_SLB9635.jpg Picture by http://www.usb.org, https://de.wikipedia.org/wiki/Universal_Serial_Bus#/media/Datei:SuperSpeed_USB.svg Significant changes 2016 General X200/T400 Don't configure EC on ACPI S3 Enable C4 CPU pstates Fix non working keyboard on boot C T430s/x220/x230/T530 Make use of common GPIO driver First version of shared hybrid graphics driver Allow the use of VGA option ROMs Initial support for dual GPU support Fixed eSATA port Split SandyBridge / IvyBridge native raminit X220/X201 Huge amount of native raminit fixes Postcar stage support Support "Yellow USB Always on" libgfxinit support libgfxinit support T60/X60 Add HDA verb table C libgfxinit Improved docking code Ada SPARK Pictures by Patrick Rudolph Significant changes 2017 General Improved thermal management through ACPI BDC detection support Support for "USB always on AC only" mode T400/T500 LED control for "thinkpad_acpi" Correctly report tabled mode Rewrite copy&pasted docking code Wait for keyboard in SeaBios Support dock button Fixed CMOS layout C Support dock LEDs Better panel & backlight detection X201 X230/T420/T430/X220/T430s ThinkLight support USB Always On support T500/T400/T420/T520/T430/T530 Share a single hybrid graphics driver Pictures by Patrick Rudolph Significant changes 2018 C General T400/T500/W500 Remove unneeded includes Improved docking detection and initialisation Link c files instead of headers Unified variants in a single board folder Removed preprocessor guards Added various VBTs T430s/x220/x230/T530 Unified TPM stack More use of src/intel/southbridge/common ACPI functions for "thinkpad_acpi" Support for "Dual Graphics" dGPU power handling in "Single Graphics" X201 mode Automatic WWAN detection Removed "C" native graphics init C X200/X201/T500/T400/W500 C Libgfxinit support libgfxinit Ada SPARK Picture by Infineon Press Photo: https://www.infineon.com/export/sites/default/media/press/Image/press_photo/TPM_SLB9635.jpg Significant changes 2019 General T400/X131e ACPI cleanups SMBIOS Got rid of unused headers Added VBT Set "Family" field in SMBIOS tables Add SMBIOS type 9 for "Express Card" slot T430s/x220/x230/T530 ACPI methods to set battery theshold Dual graphics fix Droped useless SMI handler code X201 Droped differentiation between Sandy / Ivy Bridge Removed unused C-states Disable unused devices to save power Removed duplicated HW init C Removed "C" native graphics init X1 carbon(gen1) X60/z61/z61t Support USB always on Parallel MP init support (26msec less boot time) Deduplicate romstage.c / devicetree.cb Statistics Statistics supported boards 2015 2016 2017 2018 2019 now 11 boards 16 boards 30 boards 14 boards 22 boards 31 boards R500 T430 T430s T500 s230u L520 T431s X201i T420 X1 W500 Pictures by Patrick Rudolph R500 W520 W530 Statistics commits in src/mainboard/lenovo 200 100 0 Pictures by Patrick Rudolph Statistics files in src/mainboard/lenovo Picture by Patrick Rudolph Statistics source types in src/mainboard/lenovo Mainboard source file type ads asl c ASL cb default fmd h hex inc layout name h txt vbt C devicetree Work in Progress Verified Boot Originally only used on ChromeBooks Ported to Lenovo DONE Fn key as recovery boot switch FMAP/Kconfig on Lenovo "Sandy Bridge" WIP Protect RO partition using SPI controller protected regions FMAP/Kconfig on Lenovo "Ivy Bridge" TODO Gerrit change: Port to Intel Nehalem, Haswell, GM45, i945 #32617 Add vboot support to payloads Pictures by Patrick Rudolph Nvidia Optimus "Only" ACPI code No spec is available Lenovo uses SMM, difficult to reverse engineer Using "nouveau" as reference DONE Basic implementation works on T520 WIP Needs tests on more platforms Gerrit change: Needs tests under regular use cases #28380 TODO Port to Intel Nehalem and Intel Haswell Picture by Nvidia, http://www.pcgameshardware.de/screenshots/medium/2010/02/Nvidia_Optimus-Logo.png Code deduplication C Convert hardware configuration from C code to devicetree Share code between boards Some boards use the "variant" scheme, most do not DONE Migrated LPC gendec code to devicetree.cb WIP Move complete MRC configuration into devicetree.cb Gerrit change: Needs tests on "MRC only" boards #32070 TODO Move GPIO config and HDA verbs to devicetree.cb Share "MRC configuration" with native raminit Merge old boards with new variant scheme Lenovo T440p First Haswell board Last board without Intel BootGuard Not BLOB free, requires mrc.bin DONE Basic board support WIP Analysing new EC space Gerrit change: #34359 TODO #34639 Find the serial number in EC Dual Graphics support Optimus support Improved ACPI support Picture by Lenovo, https://www.lenovo.com/us/en/laptops/thinkpad/t-series/t440p/ Comparison feature coreboot vendor FOSS (BLOB free) EOL firmware updates Nvidia Optimus Dual Graphics Verified & Measured Boot debugging capabilities EC firmware updates Possible Future Work T480 support Requires a device without "Intel Boot Guard" All devices have "Intel Boot Guard" enabled Uses Intel FSP 2.0 Thunderbolt and "Fn keys" doesn't work yet Thinkpad E495 AMD Ryzen™ 3 3200U Processor Up to 32 GB DDR4 2400 MHz Picasso SoC support by Google for ChromeBooks 16 MiB flash Picture by Lenovo, https://www.lenovo.com/us/en/laptops/thinkpad/thinkpad-e-series/E495/p/22TP2TEE495 Hardware-reduced ACPI Aims to get rid of legacy hardware functionality Would allow to remove some (legacy) code Probably faster boot times Easier to maintain Picture by UEFI, https://commons.wikimedia.org/wiki/File:Uefi_logo.svg FWUPd automatic generation of coreboot builds FOSS platforms as license is compatible Starting with VBOOT enabled boards Requires libflashrom shiped by distros fwupd firmware updater Picture by FWUPd, https://github.com/fwupd/fwupd/blob/master/data/org.freedesktop.fwupd.svg Windows 10 support Windows 10 needs additional ACPI quirks Thinkpad daemon expects certain ACPI functions Nvidia Optimus support? Picture by Microsoft, https://www.microsoft.com/en-us/windows Questions?.