Commit Graph

45075 Commits

Author SHA1 Message Date
Kevin Chang acb17fec34 mb/google/brya/var/taeko: Fix PLD group order (W/A)
In commit 667471b8d8 (ec/google/chromeec: Add PLD to EC conn in ACPI 
table), PLD is added to ACPI table. It causes the DUT to not boot into
the OS. So fix the USB3/USB2 Type-C Port C2 PLD group order from 3 to 2
to solve this issue.

Fixes: 667471b8d8 ("ec/google/chromeec: Add PLD to EC conn in ACPI table")
BUG=b:209723556
BRANCH=none
TEST=build coreboot and boot into OS.

Signed-off-by: Kevin Chang <kevin.chang@lcfc.corp-partner.google.com>
Change-Id: Ia4cf2d735de524ae721800600536923d1d47f04b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59973
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-10 15:57:00 +00:00
Angel Pons 92226dc6c3 soc/intel/{skylake/cannonlake}: Fix bug in vr_config
The `cpu_get_power_max()` function returns the TDP in milliwatts, but
the vr_config code interprets the value in watts. Divide the value by
1000 to fix this.

This also fixes an integer overflow when `cpu_get_power_max()` returns
a value greater than 65535 (UINT16_MAX).

Change-Id: Ibe9e0db6762eee5cc363f8b371c8538eb92f6308
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60001
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Felix Singer <felixsinger@posteo.net>
2021-12-10 14:30:12 +00:00
Werner Zeh dbd2362caa mb/siemens/mc_ehl: Enable TPM in bootblock
Enable TPM init in bootblock so that all further stages and other CBFS
files are directly measured into PCRs immediately instead of being
logged into a buffer and replayed to the TPM in ramstage.

Change-Id: Ib3ac29aa72abe8e967660ae7e8416aeb8812de26
Signed-off-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60008
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Mario Scheithauer <mario.scheithauer@siemens.com>
2021-12-10 14:29:41 +00:00
Subrata Banik 362dac6d6d vendorcode/intel: Rework UDK binding Kconfig
coreboot code currently supports different UDK binding as per
underlying FSP requirement, example: ICL and TGL uses
UDK_2017_BINDING while ADL uses UDK_202005_BINDING Kconfig.

These UDK binding Kconfigs are being used to choose the correct
UDK_VERSION.

This patch introduces `UDK_BASE` Kconfig option so UDK_VERSION
if clause don't need to add specific UDK binding Kconfig everytime with
introduction of newer UDK bindings in future.

Tested with BUILD_TIMELESS=1, Hatch remains identical.

Change-Id: I64c51aa06a14f0ce541537363870ac3925b79a68
Signed-off-by: Subrata Banik <subi.banik@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59985
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-10 04:48:57 +00:00
Subrata Banik de6b489ec5 mb/intel/adlrvp: Add support for external clock buffer
ADL-P silicon can support 7 SRC CLK's and 10 CLKREQ signals. Out of 7
SRCCLK's 3 will be used for CPU, the rest are for PCH. If more than 4
PCH devices are connected on the platform, an external differential
buffer chip needs to be placed at the platform level.

A mainboard designer can choose to add an external clock chip, and
select the SRC CLK using CONFIG_CLKSRC_FOR_EXTERNAL_BUFFER.

CONFIG_CLKSRC_FOR_EXTERNAL_BUFFER provides the CLKSRC that feed clock to
discrete buffer for further distribution to platform.

TEST=Able to detect SD card connected at x4 PCIe Gen 3 Slot.

localhost ~ # dmesg | grep mmc
[    4.997840] mmc0: SDHCI controller on PCI [0000:ae:00.0] using ADMA
[    5.460902] mmc0: new ultra high speed DDR50 SDHC card at address aaaa
[    5.473555] mmcblk0: mmc0:aaaa SS08G 7.40 GiB
[    5.494268]  mmcblk0: p1

Change-Id: I21f1155374049c90aa45db25d4128b39aa5898bb
Signed-off-by: Subrata Banik <subi.banik@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59976
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-10 04:48:27 +00:00
Mark Hsieh 18dfed5e8e mb/var/gimble4es: Set PsysPmax to 143 W
This patch adds the setting of PsysPmax to 143 W according to
gimble board design.

BUG=b:206990759
TEST=emerge-brya coreboot chromeos-bootimage & ensure the value is
passed to FSP by enabling FSP log & Boot into the OS

Signed-off-by: Mark Hsieh <mark_hsieh@wistron.corp-partner.google.com>
Change-Id: I851e0871461a9a9769c6b84f7d8287d989c23f06
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59950
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-10 00:58:13 +00:00
Ravindra N 07092189c1 soc/intel/cse: config to enable oem key manifest
CB change will enable the CSE region sub-partition OEMP,
where the OEMP binary will be stitched. OEM KM has Audio FW's key hash.
So, CSE uses this information to authenticate Audio FW.

BUG=b:207820413
TEST: Boot to kernel and check for the audio authentication
is successful
localhost ~ # aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: sofrt5682 [sof-rt5682], device 0: max357a-spk (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: sofrt5682 [sof-rt5682], device 1: Headset (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: sofrt5682 [sof-rt5682], device 2: HDMI1 (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: sofrt5682 [sof-rt5682], device 3: HDMI2 (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: sofrt5682 [sof-rt5682], device 4: HDMI3 (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: sofrt5682 [sof-rt5682], device 5: HDMI4 (*) []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

Cq-Depend: chrome-internal:4286038
Signed-off-by: Ravindra N <ravindra@intel.corp-partner.google.com>
Change-Id: I3620adb2898efc002104e0ba8b2afd219c31f230
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59895
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
Reviewed-by: Krishna P Bhat D <krishna.p.bhat.d@intel.com>
2021-12-10 00:57:27 +00:00
Karthikeyan Ramasubramanian c591d9c7ab mb/google/guybrush/var/nipperkin: Configure Smart Card in normal mode
As per the schematics, smart card is expected to operate in normal mode
by default. So configure the SOC_SC_PWRSV gpio accordingly.

BUG=b:202992077
TEST=Build and boot to OS in Nipperkin board version 2.

Signed-off-by: Karthikeyan Ramasubramanian <kramasub@google.com>
Change-Id: I8e12600ad45734b144a30c868f0e4f323aa056f6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59984
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Jon Murphy <jpmurphy@google.com>
Reviewed-by: Rob Barnes <robbarnes@google.com>
2021-12-09 23:29:06 +00:00
Karthikeyan Ramasubramanian 642c8d4c08 mb/google/guybrush/var/nipperkin: Override SPI fast speed
After assessing the signal integrity, 100 MHz SPI fast speed can be
enabled for SPI ROM.

BUG=None
TEST=Build and boot to OS in Nipperkin board version 2. Perform 250
iterations of warm and cold reset each.

Signed-off-by: Karthikeyan Ramasubramanian <kramasub@google.com>
Change-Id: Id973acb939b69e0beda26252e57a278892f2f57d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59983
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Jon Murphy <jpmurphy@google.com>
Reviewed-by: Rob Barnes <robbarnes@google.com>
2021-12-09 23:28:36 +00:00
YH Lin 83cf3333a2 mb/google/brya4es: sync change from brya0 (CB:58374)
CB:58374 (for mb/google/brya0) was merged before brya4es is
available (CB:59728). And since brya4es is forked from brya0, brya0's
change need to be brought into brya4es as well.

BUG=b:203014972
TEST=build

Signed-off-by: YH Lin <yueherngl@google.com>
Change-Id: I97489343b8f7a5b9457cd6f4a61cc37cd10ab450
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59935
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 23:25:12 +00:00
Felix Singer 2aa1ff4eea soc/intel/tigerlake: Hook up DPTF device to devicetree
Hook up `Device4Enable` FSP setting to devicetree state and drop its
redundant devicetree setting `Device4Enable`.

The following mainboards enable the DPTF device in the devicetree
despite `Device4Enable` is not being set.

  * google/deltaur

Thus, set it to off to keep the current state unchanged.

Change-Id: Ic7636fc4f63d4beab92e742a6882ac55af2565bc
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59886
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 22:00:23 +00:00
Felix Singer 8474f4dc9b soc/intel/tigerlake: Drop unused SataEnable setting
`SataEnable` is set by some boards, but it doesn't have any effect since
its related FSP option is hooked up to the devicetree state. Thus, drop
it.

Change-Id: Id645bfcade7ca1d495fb8df538113b3d10392a82
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59884
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-09 21:53:58 +00:00
Sean Rhodes 83d54c30fa mb/starlabs/labtop: Enable SMBus in Device Tree
Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: I8bc3025331bb25b02712b5d2b654f7997f0aba4a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59926
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Singer <felixsinger@posteo.net>
2021-12-09 21:52:51 +00:00
Felix Singer 715b787fd3 soc/intel/tigerlake: Hook up SMBus device to devicetree
Hook up `SmbusEnable` FSP setting to devicetree state and drop its
redundant devicetree setting `SmbusEnable`.

The following mainboards enable the SMBus device in the devicetree
despite `SmbusEnable` is not being set.

  * google/deltaur
  * starlabs/laptop

Thus, set it to off to keep the current state unchanged.

Change-Id: I0789af20beb147fc1a6a7d046cdcea15cb44ce4c
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59883
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 21:52:13 +00:00
Alan Huang 2bf2e6d1cc mb/google/brya/var/brask: Configure the ISOLATE pin of LAN
1. Copy the default configuration from Puff.
2. Update the 'stop_gpio' to GPP_H22.

BUG=b:193750191
BRANCH=None
TEST=Update kernel for 8125 outbox driver and test with
     command suspend_stress_test.

Change-Id: I2e82dbc1e6c68cbd84b603adc7fdc3ee1d4d3392
Signed-off-by: Alan Huang <alan-huang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/58105
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 21:10:54 +00:00
YH Lin b0db75563a mb/google/brya/var/redrix4es: sync change from redrix
The original change was for mb/google/redrix (commit 0167f5adbb),

"The ChromeOS kernel platform driver is adding support for a ChromeOS
privacy screen device, and in order to locate that device, the driver
uses the GOOG0010 reserved HID for this"

But it was merged before redrix4es is available. As redrix4es is forked
from redrix, relevant change in redrix need to be brought into
redrix4es as well.

BUG=b:206850071
TEST=build

Signed-off-by: YH Lin <yueherngl@google.com>
Change-Id: I5ac90c249273bf4e75cccb5889844a7f196f56fc
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59987
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 20:56:34 +00:00
Frans Hendriks 0dcdfd3561 configs/config.facebook_fbg1701: Remove CONFIG_ONBOARD_SAMSUNG_MEM
CONFIG_ONBOARD_SAMSUMG_MEM was used to force Samsung memory.

CPLD is used to determine the memory type leaving CONFIG_ONBOARD_SAMSUNG_MEM unused.
Remove this config.

BUG = N/A
TEST = Boot Facebook FBG1701 Rev 1.0 - 1.4

Change-Id: I60626552f2e2338cf5cbaaf4dca1b1eb2756d8df
Signed-off-by: Frans Hendriks <fhendriks@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59755
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-09 20:54:24 +00:00
Frans Hendriks e6ffdb47cd mb/facebook/fbg1701: Remove ONBOARD_SAMSUNG_MEM
CONFIG_ONBOARD_SAMSUMG_MEM was used to force Samsung memory.

CPLD returns different values for every board revision. Use this value
to determine the memory type.

BUG = N/A
TEST = Boot Facebook FBG1701 Rev 1.0 - 1.4

Change-Id: I21b5ddc430410a1e8b3e9012d0c07d278880ff47
Signed-off-by: Frans Hendriks <fhendriks@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59754
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2021-12-09 20:54:15 +00:00
Tim Wawrzynczak 26e384bf34 soc/intel/alderlake: Fix value of SA_DEVFN_CPU_PCIE1_0
The macro was defined using PCH_DEV_SLOT_CPU_1, which doesn't exist,
so replace it with the correct value of SA_DEV_SLOT_CPU_1.

Change-Id: If6d294d681907c51ac5678c9251364d4d6df4329
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59981
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subrata.banik@intel.com>
2021-12-09 20:52:43 +00:00
YH Lin 3f5f1b5bff mb/google/brya: keep the same TPM I2C for 4ES variants
Since 4ES variants were forked from their own original variants,
use the same TPM I2C as well.

BRANCH=none
BUG=b:201767461
TEST=emerge-brya coreboot and check the artifacts

Signed-off-by: YH Lin <yueherngl@google.com>
Change-Id: Iddd6d8c22a181aba596b836f20392f76539b8549
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59849
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-09 19:27:48 +00:00
Michał Kopeć 09ca258349 cpu/amd/agesa/Kconfig: select NO_SMM for Family 14h
Move the SMM Kconfig options to the specific agesa cpu families.
Select NO_SMM for family14 since since no Fam14h platform uses SMM.
Leave SMM_ASEG enabled for family15tn and family16kb for now.

TEST=Boot Debian 11 on PC Engines apu1

Signed-off-by: Michał Kopeć <michal.kopec@3mdeb.com>
Change-Id: I09bbe036a88dada847219606ec79c68e7ca8e5cc
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59809
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com>
2021-12-09 18:53:10 +00:00
Felix Held 3d523635e8 soc/amd/stoneyridge: use common fch_spi_early_init
All SPI interface setup related functionality that Stoneyridge
implemented in its southbridge code is already present in the common AMD
SoC code, so use that code instead.

The common fch_spi_early_init function requires the SPI controller's
base address to be set, so call lpc_set_spibase(SPI_BASE_ADDRESS) right
before it. fch_spi_early_init then calls lpc_enable_spi_rom and
lpc_enable_spi_prefetch which can be removed from the board code now.
Next it calls fch_spi_configure_4dw_burst which does the same as the now
removed sb_disable_4dw_burst function when
SOC_AMD_COMMON_BLOCK_SPI_4DW_BURST is set to n which is the default.
This option can also only be set to y for SoCs that aren't Stoneyridge.
Finally fch_spi_early_init calls fch_spi_config_modes which configures
the SPI mode and speed settings according to the Kconfig settings and
the settings in the amdfw part. On Kahlee this was done by calls to
sb_read_mode and sb_set_spi100 before. The previous patch added the
remaining Kconfig settings, so the resulting register values don't
change in the non-EM100 case. In the EM100 case the TPM speed is changed
from 64 to 16 MHz.

TEST=Both the non-EM100 mode with a real SPI flash and the EM100 mode
with a first-generation EM100 results in Google/Barla reaching the
payload and the show_spi_speeds_and_modes call in bootblock prints the
expected settings:

relevant bootblock console output in non-EM100 case:

SPI normal read speed: 33.33 MHz
SPI fast read speed: 66.66 Mhz
SPI alt read speed: 66.66 Mhz
SPI TPM read speed: 66.66 Mhz
SPI100: Enabled
SPI Read Mode: Dual IO (1-2-2)

relevant bootblock console output in EM100 case:

SPI normal read speed: 16.66 MHz
SPI fast read speed: 16.66 MHz
SPI alt read speed: 16.66 MHz
SPI TPM read speed: 16.66 MHz
SPI100: Enabled
SPI Read Mode: Normal Read (up to 33M)

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I8f37a3b040808d6a5a8e07d39b6d4a1e1981355c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59968
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-09 14:43:24 +00:00
Felix Held b33f351a59 mb/google/kahlee/Kconfig: add remaining SPI speed settings
Before this patch only the SPI settings that will also end up in the
amdfw part of the firmware were specified in the board's Kconfig. This
patch adds the settings from Kahlee's bootblock.c to the Kconfig file
which will be needed in subsequent patches. Also add a comment about the
EM100 case.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ie42feb9b41f435c329bf1c78471e65ef5a3fb783
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59967
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-09 14:42:45 +00:00
Felix Held 5af890d666 soc/amd/common/block/psp: add psp_efs.c to build for both PSP GEN1&2
The PSP EFS code to get the SPI mode and speed from the amdfw part of
the firmware image also works for Stoneyridge which is the one SoC that
selects SOC_AMD_COMMON_BLOCK_PSP_GEN1. Also amdblocks/psp_efs.h already
handles the SOC_AMD_STONEYRIDGE case.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ibddd3f9237e561d9f0f6b4ad70f59cce1f956986
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59966
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-09 14:42:27 +00:00
Martin Roth 2a8de6dafb SeaBIOS: Update stable release to 1.15.0
SeaBIOS 1.15.0 was released on December 2nd.  This updates the stable
version from 1.14.0 to 1.15.0

Signed-off-by: Martin Roth <martin@coreboot.org>
Change-Id: Ibc526fbddf8a13e7b00e963f9c2e73a9863c9daa
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59957
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by:  Felix Singer <felixsinger@posteo.net>
2021-12-09 12:19:11 +00:00
Rex-BC Chen 64f1319702 mb/google/corsola: Pass reset gpio parameter to BL31
To support gpio reset SoC, we need to pass the reset gpio parameter to
BL31.

TEST=build pass
BUG=b:202871018

Cq-Depend: chromium:3188686
Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I48d8d004ea92e950d0040a11133c57c121b86af3
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59824
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-09 11:55:58 +00:00
Rex-BC Chen 5bb9227845 soc/mediatek/mt8186: Enable ARM Trusted Firmware integration
Enable configuration to build with MT8186 arm-trusted-firmware drivers.

TEST=build pass
BUG=b:202871018

Cq-Depend: chromium:3189573
Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: Ib23b112a0bf3d056b932a87b86aaff79508ef50c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59823
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-09 11:55:17 +00:00
Rex-BC Chen 76c426ab28 mb/google/corsola: correct NOR flash configuration in GPIO set
The reference design has changed to use GPIO SET1 for NOR flash.
There are no devices already built using SET0 so we can safely
change the implementation without conditional configs.

Reference document:
kingler_mt8186_mt6366_lpddr4x_e.pdf, page 11.
crab_proto 0_2021112.pdf, page 11.

BUG=b:202871018
TEST=flash verify pass on kingler on bootblock stage

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I031686ccddcf789f3fa966d113ee48949e454b8f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59945
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-09 11:55:03 +00:00
Rex-BC Chen 9f6805afe8 mb/google/corsola: get SKU ID
Retrieve the SKU ID for Corsola via CBI interface.
If that failed (or no data found), fallback to ADC channels for SKU ID.

TEST=build pass
BUG=b:202871018

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I2888190d498df28b5ae13cf92cc41d088e8f8ee7
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59944
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-09 01:51:45 +00:00
Yu-Ping Wu 7edea1b790 Update arm-trusted-firmware submodule to upstream master
Updating from commit id 586aafa3a:
2021-07-19 05:36:18 +0200 - (Merge "errata: workaround for Neoverse V1 errata 1791573" into integration)

to commit id 73193689c:
2021-12-06 16:47:33 +0100 - (Merge changes I7c9f8490,Ia92c6d19 into integration)

This brings in 684 new commits.

Change-Id: I4173f3cb646839ad12c4e43e8c50b0be53364f04
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59955
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
2021-12-09 01:51:01 +00:00
Jingle Hsu 693556e0ba soc/intel/common/pch: Fix return value documentation for CHIPSET_LOCKDOWN
Fixed according to the declaration in
soc/intel/common/block/include/intelblocks/cfg.h.

Change-Id: I50dbc00806fefda8f4dac8bfa21dc714a9504566
Signed-off-by: Jingle Hsu <jingle_hsu@wiwynn.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59857
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Johnny Lin <Johnny_Lin@wiwynn.com>
Reviewed-by: Jonathan Zhang <jonzhang@fb.com>
Reviewed-by:  Felix Singer <felixsinger@posteo.net>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-08 22:29:52 +00:00
Tyler Wang 3c1ee4b9ac mb/google/dedede/var/magolor: Add fw_config probe for multi codec and
amplifier

Compatible headphone codec "ALC5682I-VS" and speaker amplifier "ALC1015Q-VB"

BUG=b:208912135
TEST=ALC5682I-VD and ALC1015Q-VB can work normally

Signed-off-by: Tyler Wang <tyler.wang@quanta.corp-partner.google.com>
Change-Id: Id661280061ede3fbb63c962dee8fb18a2053ad66
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59865
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2021-12-08 20:30:19 +00:00
Paul Fagerburg 18dd6b8a9a util/testing: combine code coverage data
As part of the `what-jenkins-does` target, combine the code coverage
data from all unit tests (currently just coreboot and libpayload).

BUG=b:203800199
TEST=`make what-jenkins-does && ls -l coreboot-builds/coverage.info`

Signed-off-by: Paul Fagerburg <pfagerburg@google.com>
Change-Id: Id99615ca8279f80a402d5371221b8fd36fb91d55
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59959
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Georgi <patrick@coreboot.org>
2021-12-08 20:29:55 +00:00
Rob Barnes d5ea920785 mb/google/guybrush: Combine mem_parts_used.txt
Combine guybrush mem_parts_used.txt across guybrush variants. Guybrush
reference memory parts is used as the base, then Nipperkin memory
parts were appended, followed by DeWatt memory parts. Duplicates were
removed.

The memory id mapping was not affected on guybrush reference and
Nipperkin. DeWatt memory id mapping was affected, DeWatt boards will
need to be adjusted.

This works around a limitation in APCB, which currently only supports
one set of memory SPDs.

BUG=b:209486790, b:204151079
BRANCH=None
TEST=Boot guybrush and nipperkin

Change-Id: Ie17025e092f2b9397afea33fce285e80ef5dc995
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59923
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2021-12-08 20:29:15 +00:00
Raul E Rangel 59d64f06be soc/amd/{cezanne,picasso,stoney,common}: Don't clear PM1 on resume
According to https://uefi.org/specs/ACPI/6.4/04_ACPI_Hardware_Specification/ACPI_Hardware_Specification.html#pm1-event-grouping

> For ACPI/legacy systems, when transitioning from the legacy to the G0
> working state this register is cleared by platform firmware prior to
> setting the SCI_EN bit (and thus passing control to OSPM). For ACPI
> only platforms (where SCI_EN is always set), when transitioning from
> either the mechanical off (G3) or soft-off state to the G0 working
> state this register is cleared prior to entering the G0 working state.

This means we don't want to clear the PM1 register on resume. By
clearing it the linux kernel can't correctly increment the wake count
when the power button is pressed. The AMD platforms implement the _SWS
ACPI methods, but the linux kernel doesn't actually use these methods.

BUG=b:172021431
TEST=suspend zork and push power button and verify power button
wake_count increments. Verified other wake sources still work.

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Iaa886540d90f4751d14837c1485ef50ceca48561
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59929
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2021-12-08 20:25:33 +00:00
Felix Held 105495f37e soc/amd/stoneyridge/southbridge: drop ENV_X86 check
Stoneyridge selects ARCH_X86 unconditionally and all coreboot code will
run on the x86 cores. On Picasso and later, the Chromebooks run verstage
on the PSP which is an ARM V7 core which needs some special handling
cases in the code, but this doesn't apply to Stoneyridge.

TEST=Timeless build results in an identical image for Google/Careena.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I013efd13b56c0191af034a8c4b58e9b26a31c6e9
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59960
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-08 17:53:21 +00:00
Raul E Rangel c7ab9f410c soc/amd/{cezanne,picasso,stoney}: Clear PM/GPE when enabling ACPI
According to https://uefi.org/specs/ACPI/6.4/16_Waking_and_Sleeping/sleeping-states.html?highlight=power%20states#

> For ACPI/legacy systems, when transitioning from the legacy to the G0
> working state this register is cleared by platform firmware prior to
> setting the SCI_EN bit.

This change makes sure we clear the PM/GPE blocks are cleared before
enabling the SCI_EN bit.

BUG=b:172021431
TEST=Boot guybrush and morphius to OS and verify suspend resume still
works.

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Icc6f542185dc520f8d181423961b74481c0b5506
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59928
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2021-12-08 17:52:03 +00:00
Scott Chao 9a185e5bfe mb/google/brya/var/primus: Fix PLD group order
In ec/google/chromeec: Add PLD to EC conn in ACPI table(667471b8d8), PLD is added to ACPI table. It causes the DUT to not boot into the OS. So fix the USB3/USB2 Type-C Port C2 PLD group order from 3 to 2 to solve this issue.

BUG=b:209568644
BRANCH=none
TEST=build coreboot and system boot into OS.

Signed-off-by: Scott Chao <scott_chao@wistron.corp-partner.google.com>
Change-Id: If5ce6ca061d9d56ba0bbb1f157b2ba278d3fa9c3
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59953
Reviewed-by: YH Lin <yueherngl@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-08 16:05:55 +00:00
Jakub Czapiga 289e2f6a64 libpayload/Makefile: Improve object files list creation
This patch ports some parts of main coreboot Makefile to the libpayload
Makefile in order to improve object files creation.

Moreover, the coreboot source files are now accessible an will be
correctly compiled under libpayload build directory.

Change-Id: If1280c0a3f7e99aad2ecf8a0379a98af31ccefc3
Signed-off-by: Jakub Czapiga <jacz@semihalf.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59843
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Georgi <patrick@coreboot.org>
2021-12-08 14:42:25 +00:00
Jakub Czapiga 0b25e00ab1 libpayload: Add include/commonlib/bsd to installed headers
Copy header files from the main commonlib/bsd to libpayload output
installation directory.

Change-Id: Idc7175240f3077ec98280331f9a952310aae4341
Signed-off-by: Jakub Czapiga <jacz@semihalf.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59916
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Georgi <patrick@coreboot.org>
2021-12-08 14:42:02 +00:00
Felix Held 0365fc8186 sb/amd/pi/hudson/early_init: fix setting SPI_USE_SPI100 in SPI100_ENABLE
Use a read modify write sequence when setting the SPI_USE_SPI100 bit in
the SPI100_ENABLE register. This avoids clearing other bits in the
register which might cause instabilities. Haven't checked the reference
code, but the register descriptions suggested that the register in
Mullins behaves similar to the one in Stoneyridge. Right now this code
is unused, but it's probably still a good idea to fix it.

TEST=Booting Debian 11 with kernel 5.10 on apu2 still works when adding
a call to hudson_set_spi100 with this patch applied.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ifbd960a9509542b28f03326a3066995540260bef
Tested-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59934
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com>
2021-12-08 13:48:32 +00:00
Felix Held 688f09f97a soc/amd/stoneyridge/southbridge: fix setting SPI_USE_SPI100
Use a read modify write sequence when setting the SPI_USE_SPI100 bit in
the SPI100_ENABLE register. This avoids clearing other bits in the
register which might cause instabilities of the SPI interface. The
reference code for Stoneyrige also only sets the SPI_USE_SPI100 bit and
doesn't zero out the other bits.

TEST=None

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I4d32fc2084bb34ea57924bae68511c6836587790
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59933
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-08 13:44:27 +00:00
Felix Held 09cdecec9c soc/amd/common/block/spi: fix setting SPI_USE_SPI100 in SPI100_ENABLE
Use a read modify write sequence when setting the SPI_USE_SPI100 bit in
the SPI100_ENABLE register. This avoids clearing other bits in the
register which might cause instabilities of the SPI interface. The
reference code for both Picasso and Cezanne also only sets the
SPI_USE_SPI100 bit and doesn't zero out the other bits.

TEST=Verified that Mandolin still boots. It didn't show any signs of
possibly related instabilities before though, so this test doesn't say
much.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I71c2ec1729d5cb4cdff6444b637af29caaa6f1c0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59932
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-08 13:44:20 +00:00
Felix Held 9bfbcd2127 soc/amd/common/block/include/spi: update fch_spi_early_init description
commit 90ac882a32 (soc/amd/common/block/
spi: introduce SOC_AMD_COMMON_BLOCK_SPI_4DW_BURST) introduced a Kconfig
option to enable/disable the 4DW burst support in the SPI flash data
prefetcher, but missed to update the documentation above the
fch_spi_early_init prototype, so update the outdated documentation now.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I07c4b0b02251da63d34a172e2636894e99845d6b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59931
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-08 13:43:53 +00:00
Rex-BC Chen 858481e814 mb/google/corsola: Configure TPM
Initialize SPI bus 2 for TPM control.

TEST=build pass
BUG=b:202871018

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I8ede68d6eb594890195e8464151c1c0f88aeee43
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59943
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-08 11:33:39 +00:00
Rex-BC Chen e96861f5c7 mb/google/corsola: implement get_ec_is_trusted
Set VB2_CONTEXT_EC_TRUSTED in verstage_main.

TEST=build pass
BUG=b:202871018

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: If2837f5db52f91f5418d222d4dcd1af2aebcc105
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59942
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-08 11:32:49 +00:00
Rex-BC Chen 9f01bbf410 mb/google/corsola: Enable Chrome EC
Initialize SPI bus 1 for Chrome EC control.

TEST=build pass
BUG=b:202871018

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I7d032d595f7ca1dbed3de4dfe308ff4be64333cd
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59941
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-08 11:32:37 +00:00
Rex-BC Chen eb102ccbd6 soc/mediatek/mt8186: Correct SPI_HZ for PLL
The SPI speed is 218.4MHz, so correct the value of SPI_HZ.

BUG=b:202871018
TEST=build pass

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I6e8ba10a851e1507405cdd41939a176462734487
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59939
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-08 11:32:14 +00:00
Rex-BC Chen d22e921178 soc/mediatek/mt8186: revise SPI NOR GPIO selection
The setting of SPI NOR GPIOs should be:
CS: pull up.
CLK/IO0/IO1: pull down.

BUG=b:202871018
TEST=build pass

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: Ideacb797a1dc9999ab6ba00cf33adbbbc24213dc
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59940
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-08 11:32:02 +00:00
Michał Kopeć c5432ec098 cpu/amd/pi/Kconfig: select NO_SMM
Disable SMM_ASEG and select NO_SMM since the platforms do not use SMM.

TEST=Boot Debian 11 on PC Engines apu3

Signed-off-by: Michał Kopeć <michal.kopec@3mdeb.com>
Change-Id: I47237421c3dd5bd043447831263d72c9956cdaf4
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59810
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-08 01:05:29 +00:00