Commit Graph

30722 Commits

Author SHA1 Message Date
Elyes HAOUAS 86b683a888 SMBIOS (Type 17): Add HBM device type and DIE form factor value
Add High Bandwidth Memory, High Bandwidth Memory Generation 2 and new
form factor value (Die).

Change-Id: Ia174e09bffdadeed4a18d443f75e2386d756e9bf
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35893
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-09 10:40:56 +00:00
Elyes HAOUAS 5d0942baa2 SMBIOS: (Type 9) Add PCI Express Gen 4 values
Change-Id: I616a435d80715bee6f7530d7318319556a7580e7
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35890
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2019-10-09 10:39:26 +00:00
Felix Held 6c244bd4dd superio/it8772f: use pnp_ops.h for pnp register access
Change-Id: I983249fb54b6fbccc4339c955cb5041848b21cf8
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35860
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-08 18:09:39 +00:00
Felix Held 08abfa3814 superio/winbond/w83627*: use hwm5_conf.h for HWM setup
Change-Id: Id78042606f02e02035dc917d162d0c98c9de38a4
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35862
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-08 18:08:52 +00:00
Felix Held 4a0899fe52 intel/dcp847ske: use functions from hwm5_conf.h for HWM setup
Change-Id: I67de5260a756fc7b1cf0ec1903bee0058a2dcb06
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35861
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-08 18:08:19 +00:00
Felix Held fa120eb2af superio/it8772f: use HWM access functionality from hwm5_conf.h
Change-Id: I12ac8dd0503f3c46fdb50e49df60c01387128b55
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35859
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-08 18:07:18 +00:00
Felix Held 166b55ced1 superio/hwm5_conf: factor out HWM access from ITE env_ctrl
Nuvoton and Winbond use the same off-by-5 indirect address space to
access their hardware monitor/environment controller in the SIO chip, so
move this to a common location and replace the inb/outb calls with the
corresponding inline functions from device/pnp.h

Change-Id: I20606313d0cc9cf74be7dca30bc4550059125fe1
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35858
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-08 18:06:56 +00:00
Kyösti Mälkki 2f8192bc6b asus/f2a85m_pro: Fix superio type in devicetree
The superio driver that was linked in is nct6779d but static
devicetree expected symbol superio_nuvoton_nct5572d_ops.

Change-Id: I648b7680bb39b9ff5b38cc3bd5147bd336e0b282
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35855
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2019-10-08 16:42:16 +00:00
Nico Huber 51b75ae50a device: Use scan_static_bus() over scan_lpc_bus()
Devices behind LPC can expose more buses (e.g. I2C on a super-i/o).
So we should scan buses on LPC devices, too.

Change-Id: I0eb005e41b9168fffc344ee8e666d43b605a30ba
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/29474
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-08 12:59:56 +00:00
Nico Huber a89c82e402 device/root_device: Consolidate common _scan_bus() functions
scan_usb_bus() and root_dev_scan_bus() had the very same implementation.
So rename the latter to scan_static_bus() and use that for both cases.

Change-Id: If0aba9c690b23e3716f2d47ff7a8c3e8f6d82679
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31901
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-08 12:59:37 +00:00
Arthur Heymans c70af6530c arch/x86: Don't allow separate verstage to boot from romcc bootblock
CONFIG_VBOOT_SEPARATE_VERSTAGE has a dependency on
C_ENVIRONMENT_BOOTBLOCK so Kconfig already guards against this.

Change-Id: I8f963a27f9023fd4c6ebc418059d57e00e4dfb4c
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35824
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-08 11:41:06 +00:00
Arthur Heymans 6010eb27c9 arch/x86: Add a choice for selecting normal/fallback cbfs prefix
Setting the cbfs prefix is prone to error. Therefore add a Kconfig
choice for 2 common values, fallback and normal, while still keeping
the ability to specify an arbitrary value.

Change-Id: I04222120bd1241c3b0996afa27dcc35ac42fbbc8
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35822
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2019-10-08 11:40:25 +00:00
Elyes HAOUAS 2a0fbe34ba device/dram/ddr4: Check spd_bytes_total and spd_bytes_used values
The value stored to 'spd_bytes_total' is never read. Now it is fixed.
This is spotted using clang-tool v9.
Also add a check if spd_bytes_used and/or spd_bytes_total are reserved
and make sure that spd_bytes_used is not greater than spd_bytes_total.

Change-Id: I426a7e64cc4c0bcced91d03387e02c8d965a21dc
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35558
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2019-10-08 11:03:26 +00:00
Peter Lemenkov c1dc2d5e68 mb/lenovo/t60: Switch to override tree
Change-Id: I13c0134b22e2203e6cee6ecafda0dae89e086aff
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/34779
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-08 09:17:16 +00:00
Peter Lemenkov c71093b21a mb/lenovo/{t60,z61t}: Convert to variant board
Change-Id: I0a3076780ac5cf183235f06e4c56d0707bf5e6ca
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/34123
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
2019-10-08 09:17:05 +00:00
Werner Zeh b7f1c2d2f1 Revert "site-local: Allow to read Makefile.inc w/o .config"
This reverts commit 275f2e22a1.
Since in this commit the inclusion of site-local/Makefile.inc was moved
outside of the guard 'ifeq ($(NOCOMPILE),1)', this Makefile.inc will be
included always here (what seems to be the intention of this commit).

As we have a second place where site-local/Makefile.inc is included
(top-level Makefile.inc via subdirs-y class) this unconditional include
leads to a double included site-local/Makefile.inc. Therefore one will
get errors if a separate rule is used in site-local/Makefile.inc.

Change-Id: I0a693c1d793b978c8023e4f107dce139d537d8db
Signed-off-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35786
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-10-08 05:54:30 +00:00
Hung-Te Lin dafb66142e device/mmio.h: Add more bit field helpers
For fields with single bit, it's easier to declare as

 DEFINE_BIT(name, bit)

Change-Id: If20e6b1809073b2c0dc84190edc25b207bf332b7
Signed-off-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35787
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2019-10-08 05:54:10 +00:00
Frank Wu 2431a707d3 mb/google/drallion: Add detect pin for Wacom touchscreen
Add the missing detect pin to fix Wacom touchscreen function.

BUG=b:140415892,b:138082886
BRANCH=N/A
TEST=N/A

Change-Id: I8a1b48d4d502945b88e38393383512d30b684fa4
Signed-off-by: Frank Wu <frank_wu@compal.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35790
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-08 05:53:45 +00:00
Seunghwan Kim 34d306ab18 mb/google/kohaku: Assign GPP_A19 as reset_gpio of stylus
Applying reset_gpio config of stylus for kohaku. GPP_A19 has been assigned in
the latest schematics.

We would keep GPP_A10 as output high for old revision devices temporarily.

BUG=b:141914474
BRANCH=none
TEST=verified stylus works internally
Signed-off-by: Seunghwan Kim <sh_.kim@samsung.com>

Change-Id: I61f0f9a4378f47bf455f0726d44beeaf2f67197b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35748
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Shelley Chen <shchen@google.com>
2019-10-08 05:37:17 +00:00
Shelley Chen 62e79d2c1e mb/google/hatch: Preserve MRC training data across FW update
Add PRESERVE to UNIFIED_MRC_CACHE so that we don't retain the memory
training data upon a FW update unless we need to.  We have had users
complaining that a 15 second memory training upon update makes them
believe that their device is not booting, thus many of them hard
resetting before bootup.

BUG=b:142084637
BRANCH=None
TEST=flash RW_SECTION_A, RW_SECTION_B, and WP_RO sections and make
     sure memory training doesn't occur on following bootup.

Change-Id: Ia5eb228b1f665a8371982544723dab3dfc40d401
Signed-off-by: Shelley Chen <shchen@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35803
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-07 23:12:51 +00:00
John Su 4e07adbb86 mb/google/octopus/variants/fleex: Adjust I2C0 CLK to meet spec
After adjustment on Grob360S
I2C0 CLK: 389.9 KHz

BUG=b:141729962
BRANCH=master
TEST=emerge-octopus coreboot chromeos-bootimage
     measure by scope with Grob360S.

Change-Id: I6a30257b7978cc8899a55f9fd6ffffe01cb2a851
Signed-off-by: John Su <john_su@compal.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35788
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Justin TerAvest <teravest@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
2019-10-07 19:23:21 +00:00
Elyes HAOUAS 495bb66541 src: Capitalize Super I/O
Change-Id: I9ad9294dd2ae3e4a8a9069ac6464ad753af65ea5
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35541
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2019-10-07 19:18:36 +00:00
Nico Huber f7ed3d4df8 device: Rename scan_static_bus() -> enable_static_devices()
The new name should reflect better what this function does, as that
is only one specific step of the scanning.

Change-Id: I9c9dc437b6117112bb28550855a2c38044dfbfa5
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31900
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-07 19:06:38 +00:00
Patrick Georgi 64c14b5dcf Documentation/RFC: Drop obsolete doc
The format was retired 10 years ago when we moved to the new build
system, kconfig and sconfig. Retire the doc as well.

Change-Id: Ica1c353a80d411845b92038521d85ad5f3d359bc
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35818
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:08:55 +00:00
Patrick Georgi 11b3d2123f Documentation: Add our issue tracker to services
Change-Id: Ib249d5c6f2431336a01850f4a8d708795983e7d3
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35806
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
2019-10-07 01:08:40 +00:00
Patrick Georgi 0df412d8cc Documentation/mb: Link AMD mainboards directly in the big list
Fixes an issue with amd/index.md not being part of a toctree

Change-Id: Id419695d24a49951afb844c81cc0951d6920e0d2
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35817
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:08:26 +00:00
Patrick Georgi ad1fb31318 Documentation/mb/amd/padmelon: Fix relative link
Change-Id: I132aed69107153785c5e824108677e60243483ce
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35816
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:08:10 +00:00
Patrick Georgi 6a303185ef Documentation: remove invalid fragment type specifier
Change-Id: I1a07180532c6fa7c7ac487e39632438eef3b34e7
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35815
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:07:47 +00:00
Patrick Georgi f3df6fa9a7 Documentation: Fix typo
Change-Id: I832ff41a322081d3bae80df463659ec6ffffcd34
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35814
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:07:21 +00:00
Patrick Georgi 2528b9b4bf Documentation: start documenting our services
Change-Id: I4d687d13e8d47e3e3e6f319b9117d3c4f31caa78
Signed-off-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35805
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
2019-10-07 01:07:06 +00:00
Patrick Georgi e0f150b171 Documentation: Update list of release notes
Change-Id: I963be1536be5155a114eef1149fdd8c5a067eff8
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35811
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-10-07 01:06:49 +00:00
Arthur Heymans c73c92368f sb/intel/nm10: Fix enabling HPET
RCBA_HPTC needs to be read back to consistently enable HPET.
This ought to fix raminit failing sometimes and SeaBIOS endlessly
waiting for user input.

TESTED on Intel D510MO, Fixes SeaBIOS waiting for input, without a
timeout.

Change-Id: I20a25fd97cd09fedb70469262c64d8d3828bb684
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35758
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 22:11:32 +00:00
Jingle Hsu 1609a20381 mb/ocp/monolake: Add GPIO table to initialize custom configs
Add a GPIO table for Monolake to initialize GPIOs with custom board
configurations.

Tested on Monolake.

Change-Id: I74906bf9395a333be6250ffbd181da536e016f30
Signed-off-by: Jingle Hsu <jingle_hsu@wiwynn.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35367
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
2019-10-06 17:09:52 +00:00
Nico Huber 061b90507d device/pci: Enable full 16-bit VGA port i/o decoding
So, the PCI to PCI bridge specification had a pitfall for us:
Originally, when decoding i/o ports for legacy VGA cycles, bridges
should only consider the 10 least significant bits of the port address.
This means all VGA registers were aliased every 1024 ports!
    e.g. 0x3b0 was also decoded as 0x7b0, 0xbb0 etc.

However, it seems, we never reserved the aliased ports, resulting in
silent conflicts we preallocated resources. We neither use much
external VGA nor many i/o ports these days, so nobody noticed.

To avoid this mess, a bridge control bit (VGA16) was introduced in
2003 to enable decoding of 16-bit port addresses. As older systems
seem rather safe and well tested, and newer systems should support
this bit, we'll use it if possible and only warn if not.

With old (AGP era) hardware one will likely encounter a warning like
this:

    found VGA at PCI: 06:00.0
    A bridge on the path doesn't support 16-bit VGA decoding!

This is not generally fatal, but makes unnoticed resource conflicts
more likely.

Change-Id: Id7a07f069dd54331df79f605c6bcda37882a602d
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35516
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Michael Niewöhner
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 14:33:54 +00:00
Arthur Heymans 2a468d25fc cpu/intel/model_2065x/bootblock: Remove dead code
This codepath is never takes as it checks if the CPU is at least
ivybridge.

Change-Id: Id064385f0c8bb0b094714129df6d8ba36c87a307
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35810
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-10-06 10:15:55 +00:00
Arthur Heymans 9f3fd694f0 mb/{lenovo/x201,packardbell/ms2290}: Remove unused ACPI symbols
Change-Id: I3a3174cf20cea60d8b2c4d0311a48ce9ffe1a8a1
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35804
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-10-06 10:15:42 +00:00
Arthur Heymans 38750f88fc nb/intel/nehalem: Don't run graphic init on S3 resume
The assumption is made that an ACPI aware an OS does not rely on
firmware to initialize the display.

TESTED on a Lenovo Thinkpad X201 with Linux 5.2, display still works
after S3, more than 200ms in time saved (dropped from 411ms to 182ms
in total in one test).

Change-Id: I36219e6d04db561d4f2ddb6e962166c598d5bc4f
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35773
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
2019-10-06 10:15:30 +00:00
Arthur Heymans 3b452e0a79 nb/intel/nehalem: Move PCH init to sb/intel/ibexpeak
This change does the following:
- Move PCH init code from the common romstage to sb code, this allows
  for easier reuse in bootblock
- Provide a common minimal LPC io decode setup, mainboards can
  override this in the mainboard_lpc_init if required
- Set up LPC generic IO decode up in romstage based on devicetree
  settings
- Remove the ramstage LPC generic IO decode from ramstage as this is
  now done in romstage.c
- Get rid of unneeded setup of spi_read configuration in BIOS_CNTL as
  this is already done in the bootblock.

Change-Id: I3f448ad1fdc445c4c1fedbc8497e1025af111412
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35772
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-10-06 10:15:16 +00:00
Arthur Heymans cea4fd9bb0 nb/intel/nehalem: Move romstage boilerplate to a common location
Move the mainboard_romstage_entry to a common location and provide
mainboard specific callbacks.

Change-Id: Ia827053617cead5d2cf8e9f06cb68c2cbb668ca9
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35771
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-10-06 10:15:05 +00:00
Arthur Heymans 896a2430d8 nb/intel/nehalem: Don't link walkcbfs.S in romstage
Change-Id: I5bb0c38353d340cc5d356fba299a4460e3f5bddc
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35770
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:14:53 +00:00
Arthur Heymans 3a46e02964 sb/intel/ibexpeak: Don't clear PMBASE regs in romstage
X201 boots fine without it.

Change-Id: I20a8e598b07bf0a059dcb47651d1a26456863673
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35769
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:14:43 +00:00
Arthur Heymans 39f8a1aaf9 sb/intel/ibexpeak: Implement USB current settings
This is based on the sandybridge settings.
The current lookup table comes from the x201 vendor lookup table.

Tested: USB mouse and webcam still work and current registers are the
same as before. USB IR are not but the code follows EDS instead of the
register replay.

Change-Id: Icea9673623a62e7039d5700100a2ee238478abd1
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35762
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:14:22 +00:00
Arthur Heymans d9ceb9deb4 intel/ibexpeak boards: Remove undocumented reset defaults from RCBA replay
The values read back in those ranges are identical before and after
this change and the Lenovo Thinkpad X201 still boots fine.

Change-Id: I406510e0573ac97003da7d97181abdfbfd2a872f
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35760
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:14:10 +00:00
Arthur Heymans 126f9e51fb intel/ibexpeak boards: Remove handled RCBA entries from replay
The RCBA registers 0x3400-0x3500 are all handled elsewhere
in the code, so no need to have a 'replay' of those.

The remainder now consist of USB setup and undocumented bits
that should likely not be touched at all.

Change-Id: I69fc8a5e16f7cf0e1068d0d2ed678a6c2f6e70a9
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35440
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-10-06 10:13:55 +00:00
Arthur Heymans 37e1d93ca0 sb/intel/ibexpeak: Fix enabling HPET
RCBA_HPTC needs to be read back to properly work.

This fixes SeaBIOS endlessly waiting for input instead of booting the
default entry. Linux already fixes this itself.

Change-Id: I22b8b34924f2add2185ec46470c1559bf2fb6d58
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35757
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:13:32 +00:00
Arthur Heymans d0310faa3b sb/intel/ibexpeak: Implement PCH function disable in chip_ops
This does the following:
- implement a PCH disable function that will be called by the PCI
  drivers as part of their chip_ops
- removes the iobp_x calls as those don't exist on ibexpeak
- complete the devicetree with to be disabled PCI devices for the
  chip_ops to be called
- Clean up some code copied from bd82x6x

Change-Id: I78d25ffe9af482c77d397a9fdb4f0127e40baddc
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35753
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-10-06 10:13:21 +00:00
Arthur Heymans f266dc6174 nb/intel/nehalem: Remove bogus GT PM init
This was simply copied from sandybridge/gma.c.
All these registers read back 0xffffffff or 0 or don't respond to
reads.

Change-Id: I094e7caa889a3175477aa78b91545ca804d423c8
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35746
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:13:05 +00:00
Arthur Heymans 28bca0546b nb/intel/nehalem: Disable PEG and IGD based on devicetree
Tested on Thinkpad X201: PEG device hidden.

Change-Id: Ib378458a55e18cc02fc49b3e6d6939d31dd4aa65
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35744
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-10-06 10:12:53 +00:00
Arthur Heymans 6d13a0a78a nb/nehalem: Remove bogus MCHBAR writes
On these CPUs the MCHBAR window is 16KiB large. This code was just
copied from SNB.

Change-Id: I263cfc678a2eb8eeee8ab9157c749359064a9be8
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35743
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-10-06 10:11:20 +00:00
Arthur Heymans f503b60bb9 sb/intel/ibexpeak: Add CIR initialization
This properly sets up the chipset initialization registers, instead of
replaying an RCBA dump.

The information is taken from the EDS and from the thinkpad x201
vendor BIOS disassembly and from an HP UEFI.

TESTED on Thinkpad X201. Seems stable at booting, rebooting and resume
from S3.

Change-Id: I21c2beaf70da27dbe6a56e2612df2c257c05fc62
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/35439
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-10-06 10:11:00 +00:00