Commit graph

60,075 commits

Author SHA1 Message Date
Hope Wang
94686e581a mb/google/skywalker: Add DVFS support in romstage
Add the initialization in romstage.

BUG=b:410763782
BRANCH=none
TEST=Check the CPU frequencies are changing and not fixed values by
using the following commands in kernel:
1) set policy*/scaling_governor as "ondemand"
"echo ondemand > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor"
"echo ondemand > /sys/devices/system/cpu/cpufreq/policy6/scaling_governor"
2) Check the CPU frequencies by repeating the command
"grep . /sys/devices/system/cpu/cpufreq/policy*/scaling_cur_freq"
The result is like
/sys/devices/system/cpu/cpufreq/policy0/scaling_cur_freq:650000
/sys/devices/system/cpu/cpufreq/policy6/scaling_cur_freq:2350000

Signed-off-by: Hope Wang <hope.wang@mediatek.corp-partner.google.com>
Change-Id: Ie64ebd1b78096c38c4398572cbed3e2e9ac6b8b6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87917
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2025-06-04 06:05:59 +00:00
Hope Wang
8ede4bc67b soc/mediatek/mt8189: Add DVFS driver
Add the initialization code for CPU Dynamic Voltage and Frequency
Scaling (DVFS) for MCUPM.

BUG=b:410763782
BRANCH=none
TEST=Check the CPU frequencies are changing and not fixed values by
using the following commands in kernel:
1) set policy*/scaling_governor as "ondemand"
"echo ondemand > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor"
"echo ondemand > /sys/devices/system/cpu/cpufreq/policy6/scaling_governor"
2) Check the CPU frequencies by repeating the command
"grep . /sys/devices/system/cpu/cpufreq/policy*/scaling_cur_freq"
The result is like
/sys/devices/system/cpu/cpufreq/policy0/scaling_cur_freq:650000
/sys/devices/system/cpu/cpufreq/policy6/scaling_cur_freq:2350000

Signed-off-by: Hope Wang <hope.wang@mediatek.corp-partner.google.com>
Change-Id: I001d7a02d86892478b456f1c5ab3a6433434a19b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87916
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2025-06-04 06:05:52 +00:00
Hope Wang
096ce4b244 soc/mediatek/mt8196: Move dvfs_init() declaration to dvfs_common.h
To promote code reuse and maintainability, move dvfs_init() declaration
to dvfs_common.h.

BUG=b:410763782
BRANCH=none
TEST=Build pass.

Signed-off-by: Hope Wang <hope.wang@mediatek.corp-partner.google.com>
Change-Id: If9778a13a4664bdaf4cad65c8daa78c10748466d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87915
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-06-04 06:05:46 +00:00
lizheng
0b1bc3df2c mb/trulo/var/pujjocento: Support x32 memory configuration
Use the GPP_E13 level to determine whether x32 memory configuration
is supported.

BUG=b:422001335
BRANCH=firmware-trulo-15217.771.B
TEST=emerge-nissa coreboot chromeos-bootimage

Change-Id: If1dcffaeb358093f06c4c349a83152a2bdcc16f6
Signed-off-by: lizheng <lizheng@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87925
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
2025-06-04 02:27:58 +00:00
Sean Rhodes
7690442d88 mb/starlabs/byte_adl: Tidy the Kconfig selections
This are a bit illogical, so tidy them up.

Change-Id: Idd4f616181949780c042142344b3bbbccc4f15f6
Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87894
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-06-03 20:57:29 +00:00
Felix Singer
ab8339770e 3rdparty/fsp: Update submodule to upstream master
Updating from commit id 04728fbd192f:
2025-05-07 15:20:18 +0800 - (Edge Platforms ADL-S IPU 2025.3 (6073_02) FSP)

to commit id cc36ae2b5775:
2025-05-28 10:49:43 +0800 - (Edge Platforms RPL-S/RPL-S Refresh IPU 2025.3 (6073_04) FSP)

This brings in 1 new commits:
cc36ae2b5775 Edge Platforms RPL-S/RPL-S Refresh IPU 2025.3 (6073_04) FSP

Change-Id: Ia7d7de0db0669a52890442b3e54ebb1043880ef7
Signed-off-by: Felix Singer <felix.singer@secunet.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87914
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
2025-06-03 16:43:12 +00:00
Yu-Ping Wu
8e3adf778b soc/mediatek: Add data_version to ddr_base_info struct
To sync with the dramc_param_common.h change [1] from MediaTek's DRAM
blob, change the u32 config_dvfs field to u16 and add a new field
data_version. As all MediaTek SoCs using the structure are little endian
and currently only bit 0 is used for the config_dvfs field, this change
is backward compatible. Therefore, each SoC's DRAMC_PARAM_HEADER_VERSION
doesn't need to be bumped.

[1] commit a39b473a0a7d ("common/cros: Support storing data version in
    full-k cached data")

FIXED=415715491
TEST=emerge-skywalker coreboot
BRANCH=none

Change-Id: Ifcda7d360aefe083fc08c974e6dc62d1c9c12b5e
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87912
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-06-03 11:10:16 +00:00
Luca Lai
0cdd4125be mb/trulo/var/pujjolo: Fix touchscreen function and boot up issue
1. Add serial_io_i2c_mode to fix can not boot up to OS issue.
2. Change level from low to high to fix parade touchscreen issue.

BUG=b:395763555
BRANCH=none
TEST=Build and boot to pujjolo. Verify functions work.

Change-Id: Ic0a02daa39f4d1d0287115ecab12f45201704227
Signed-off-by: Luca Lai <luca.lai@lcfc.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87909
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-06-03 03:10:40 +00:00
Subrata Banik
99e0484000 mb/google/bluey: Increase bootblock size to 120KB
The bootblock size for the Google Bluey mainboard has been increased
from 96KB to 120KB.

This change is necessary to accommodate the growing size of the
bootblock image, which now exceeds the previous 96KB limit. This
expansion ensures that the complete bootblock code, including critical
initialization routines and potentially new features, fits within its
allocated flash region.

TEST=Able to build google/quenbi.

Change-Id: I7bf2c8c6c540327f1b4233ee5ba4e0703d1200f9
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87903
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-06-03 01:44:48 +00:00
Kun Liu
1840fb49e0 mb/google/trulo/var/pujjocento: Update gpio setting for DDI-B
Modify according to the hardware schematic(MB-0529A) as follows:

GPP_A20 ---> GPP_A18
GPP_E20 ---> GPP_H15
GPP_E21 ---> GPP_H17

BUG=b:409254508
BRANCH=none
TEST=emerge-nissa coreboot chromeos-bootimage.

Change-Id: I61ef761df7936fb42d4fe68a2b5cd2fa649b7b33
Signed-off-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87900
Reviewed-by: Eric Lai <ericllai@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2025-06-03 01:44:32 +00:00
Rui Zhou
69a067a9d6 mb/google/skywalker: Add RT1019 support for beep sound
Derive the audio amplifier from FW_CONFIG, and set up I2C and I2S for
RT1019.RT1019 and RT9123 use the same GPIOs on the Skywalker reference
design, so the same function is used to improve code reusability. Also
pass the corresponding GPIO to the payload.

BUG=b:417083722
BRANCH=none
TEST=Build pass and test with Depthcharge change:
https://chromium-review.googlesource.com/c/chromiumos/platform/depthcharge/+/6437675
Check audio cmd in depthcharge with:
firmware-shell: AUDIO CMD=audio 500 100 1

Change-Id: I512cd5c8635d08c6b6c54f04d11bf87c64d1b843
Signed-off-by: Rui Zhou <zhourui@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87887
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2025-05-31 13:30:52 +00:00
Cyril Chao
4caf5131b9 mb/google/skywalker: Add ALC5645 support for beep sound
Derive the audio amplifier from FW_CONFIG, and set up I2C and I2S
for ALC5645. Also pass the corresponding GPIO to the payload.

BUG=b:359705470
BRANCH=none
TEST=build ok and test audio cmd ok
AUDIO CMD=audio 500 100 1

Signed-off-by: Cyril Chao <cyril.chao@mediatek.corp-partner.google.com>
Change-Id: Ib53175f559eecb3d8b5104b12dabfd4793f65d08
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87886
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2025-05-31 13:30:42 +00:00
Cyril Chao
623caa537f mb/google/skywalker: Add RT9123 support for beep sound
Derive the audio amplifier from FW_CONFIG, and set up I2S for RT9123.
Also pass the corresponding GPIO to the payload.

BUG=b:359705470
BRANCH=none
TEST=Build pass and test with Depthcahrge change:
https://chromium-review.googlesource.com/c/chromiumos/platform/depthcharge/+/6437675
https://chromium-review.googlesource.com/c/chromiumos/platform/depthcharge/+/6437676
Check audio cmd in depthcharge with:
firmware-shell: AUDIO CMD=audio 500 100 1

Signed-off-by: Cyril Chao <cyril.chao@mediatek.corp-partner.google.com>
Change-Id: I3b9b347ad8b754cbc02d942da9a7b0886c4c3cc4
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87885
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2025-05-31 13:30:34 +00:00
Mengqi Zhang
16ff3b33ce mb/google/skywalker: Add SD card configurations
Pass SD card detect GPIO to payloads for SD card detection and configure
SD card in ramstage. Currently, only Skywalker supports the SD card.

BUG=b:379008996
BRANCH=none
TEST=Build pass. Check storage in depthcharge.
firmware-shell: storage init
*  0: UFS LUN 0
   1: removable mtk_mmc

Signed-off-by: Mengqi Zhang <mengqi.zhang@mediatek.corp-partner.google.com>
Change-Id: I3b198d5e237006c299581ab4a5da8577dbcca7a6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87884
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-31 13:30:25 +00:00
Kun Liu
3b68408693 mb/google/trulo/var/pujjocento: Configure USB related settings
Modify USB related settings according to the proto schematic diagram.

BUG=b:409254508
BRANCH=none
TEST=emerge-nissa coreboot chromeos-bootimage,tested USBA and TYPEC function is ok.

Change-Id: I48ec269b612602578b35eeaedffd1a3d311bb97e
Signed-off-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87834
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-30 04:21:59 +00:00
Subrata Banik
6c87853a83 mb/google/bluey: Implement board and SKU ID retrieval
This commit populates the `board_id()` and `sku_id()` functions
for the Google Bluey mainboard, replacing the previous placeholder
implementations.

- The Board ID (`board_id()`) is now determined by reading a set of
  four GPIO pins (GPIO138 as MSB, GPIO137, GPIO136, GPIO135 as LSB)
  and interpreting their states as a base-3 encoded value using
  the `gpio_base3_value()` helper.

- The SKU ID (`sku_id()`) is retrieved from the Google ChromeEC
  by calling `google_chromeec_get_board_sku()` when a ChromeEC
  is configured (`CONFIG(EC_GOOGLE_CHROMEEC)`).

Both ID values are cached after their initial determination to
avoid redundant reads.

BUG=b:404985109
TEST=Able to build google/bluey

Change-Id: Ic5a084e35b33a82fef76f33c2663aba7a48c16a7
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87861
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Pranava Y N <pranavayn@google.com>
2025-05-30 04:21:40 +00:00
Subrata Banik
830a887ecb mb/google/bluey: Add WLAN and SSD PCI devices to devicetree
This commit updates the devicetree for the Google Bluey mainboard
to include entries for the WLAN and SSD PCI devices.

These devices are located on the x1p42100 SoC's PCI domain 0:
- WLAN: device pci 04.0
- SSD:  device pci 06.0

BUG=b:404985109
TEST=Able to build google/bluey.

Change-Id: If0a9491f4178ee9a44c04aea1330b6522dfd9bf0
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87859
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-30 04:21:34 +00:00
Subrata Banik
891c208835 soc/qualcomm/x1p42100: Enable basic PCIe support
This commit introduces initial support for PCI Express on the
Qualcomm x1p42100 SoC.

Key changes include:
- Selecting `CONFIG_PCI` in Kconfig to enable general PCI subsystem
  support for this SoC.
- Selecting `CONFIG_NO_ECAM_MMCONF_SUPPORT`, indicating that this
  platform will not use the standard MMCONFIG ECAM for PCI
  configuration space access. An alternative mechanism will be required.
- Adding `../common/pcie_common.c` to the ramstage build if `CONFIG_PCI`
  is enabled, incorporating common PCIe helper functions.

BUG=b:404985109
TEST=Able to build google/bluey.

Change-Id: I53e8bb3ce8551e8fa8c4b1cd39d89e12226c32f1
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87858
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Pranava Y N <pranavayn@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-30 04:21:29 +00:00
Subrata Banik
a5d99a814a soc/qc/x1p42100: Perform soc_mmu_init inside early bootblock init
This commit introduces `bootblock_soc_early_init` API for early SoC
initialization sequence in the bootblock.

- `bootblock_soc_early_init()`: This function now handles very early
  initialization steps (before console init), specifically
  `soc_mmu_init()` when the bootblock is not compressed.

- `bootblock_soc_init()`: This function retains the subsequent
  initialization tasks including `clock_init()`, `quadspi_init()`,
  and `qupv3_fw_init()`.

This change ensures MMU setup to occur before other peripheral and
clock initializations.

TEST=Able to get bootblock console log in proper.

Change-Id: I8bbcdb9c39e13fac81ef6a34647c4f343a619561
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87857
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Pranava Y N <pranavayn@google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2025-05-30 04:21:22 +00:00
Subrata Banik
481001e13b soc/qualcomm/x1p42100: Add placeholder for early clock initialization
This commit adds the `clock_init()` function for the Qualcomm x1p42100
SoC. This function is now called at the beginning of
`bootblock_soc_init()` to enable SoC-specific clock setup early in the
boot process.

The `clock_init()` function definition is currently a placeholder
and will be populated with the required clock configurations in
subsequent changes.

BUG=b:404985109
TEST=Able to build google/bluey

Change-Id: Ifb856ea4132def9cd3a36b081d24037a1a4efaba
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87850
Reviewed-by: Pranava Y N <pranavayn@google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-30 04:21:18 +00:00
Momoko Hattori
77c6104645 Revert "mb/google/rex: Enable use_gpio_for_status for touchscreen"
This reverts commit 81f396ec2f.

Reason for revert: Reported to have broken touchscreen for screebo.

BUG=b:420550351
BUG=b:397355818
TEST=FW_NAME=screebo cros build-packages --board=rex chromeos-bootimage
TEST=FW_NAME=karis cros build-packages --board=rex chromeos-bootimage
TEST=karis boots successfully and touchscreen remains to work.

Change-Id: I75dad8cd07c900f963888b0a34bf18d893f20d71
Signed-off-by: Momoko Hattori <momohatt@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87893
Reviewed-by: YH Lin <yueherngl@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-29 15:32:21 +00:00
Mac Chiang
715e7e51c5 mb/google/fatcat/var/francka: Add support for DMIC0
This patch enables DMIC_CLK0 and DMIC_DATA0 for
internal board DMIC recording.

BUG=b:392007428
TEST=emerge-fatcat coreboot

Change-Id: Idcc18a6a605694bc5c1a2994453717887814e897
Signed-off-by: Mac Chiang <mac.chiang@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/86699
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2025-05-29 14:20:30 +00:00
Jeremy Compostella
c16891ecbd soc/intel/meteorlake: Use CACHE_TMP_RAMTOP for TME exclusion range
This commit updates the fill_tme_params() function to utilize the
CACHE_TMP_RAMTOP constant instead of hardcoded values for calculating
the TME exclusion range.

Change-Id: I199182de8b8b219b0c45b27746b7415527cb9976
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87868
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2025-05-29 14:20:11 +00:00
Bora Guvendik
394dfcaa7b mb/intel/ptlrvp: Handle GPIO support for DDR5 configuration
This commit addresses the GPIO configuration for DDR5 on Intel's
PTLRVP mainboard. Specifically, it extends support for the DDR5
configuration by adding a case for PTLP_DDR5_RVP in the GPIO
differential table function. This modification ensures proper handling
of GPIO settings when DDR5 memory is configured, thereby improving
system stability and compatibility.

BUG=none
TEST=Boot with DDR5 configuration.

Change-Id: I3745c0a25e84a0f41dced44613cfd638c12fb1d3
Signed-off-by: Bora Guvendik <bora.guvendik@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87872
Reviewed-by: Jérémy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Jamie Ryu <jamie.m.ryu@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Zhixing Ma <zhixing.ma@intel.com>
2025-05-29 14:19:15 +00:00
Matt DeVillier
58165618da mb/google/byra/var/craask: Add VBT for HDMI variant
Extracted from coreboot-Google_Craask.15217-841-0.bin

Change-Id: I07d4e7fe63ff6ad43806d73d9e31ffe0aa8807c5
Signed-off-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87867
Reviewed-by: Eric Lai <ericllai@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-29 14:18:58 +00:00
Matt DeVillier
ab160ca301 mb/google/byra/var/teliks: Add default VBT
Extracted from coreboot-Google_Teliks.15217.734.0.bin

Change-Id: Ib9f077cdd0536e6315b05775337bf30555562cc8
Signed-off-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87866
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <ericllai@google.com>
2025-05-29 14:18:54 +00:00
Nick Vaccaro
4d5b32f7f7 mb/google/ocelot/var/ocelot: remove unused gpios
Remove GPP_D16, GPP_D17, and GPP_B25 as they aren't used in ocelot.

Change GPP_A08 polarity in gpio_table and rom_gpio_table.

BUG=b:412736286
BRANCH=None
TEST=`emerge-ocelot coreboot` and verify it compiles without error.

Change-Id: Ife444cef816ca2b69db466661c63935f72836554
Signed-off-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87870
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Avi Uday <aviuday@google.com>
2025-05-29 14:18:40 +00:00
Kun Liu
0e5757bfa7 mb/google/trulo/var/pujjocento: Update DTT settings for thermal control
The DPTF parameters were defined by the thermal team.
Based on thermal table in b:419161631#comment1

BUG=b:419161631
TEST=emerge-nissa coreboot chromeos-bootimage

Change-Id: If79e58fa52ecb4626fdd6a25e8e3bf6e3c556c6b
Signed-off-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87878
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-29 14:18:19 +00:00
Vince Liu
c34baacc72 soc/mediatek/common: Add UFS2.2 and eMMC definitions to storage.h
Add support for projects with UFS2.2 and eMMC storage.

BUG=b:379008996
BRANCH=none
TEST=build pass

Signed-off-by: Vince Liu <vince-wl.liu@mediatek.corp-partner.google.com>
Change-Id: Ie8d76920417c7708117e3492152d3d4e87dd87ca
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87864
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2025-05-29 12:12:46 +00:00
Mengqi Zhang
f325409784 soc/mediatek/mt8189: Add SD card support
Add GPIO configuration of SD card.

BUG=b:379008996
BRANCH=none
TEST=build pass

Signed-off-by: Mengqi Zhang <mengqi.zhang@mediatek.corp-partner.google.com>
Change-Id: If34841dddeb93a8622dda8e011cd1f29ec9c541d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87863
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2025-05-29 12:12:39 +00:00
Mengqi Zhang
ae435c014c soc/mediatek/mt8189: Configure and early initialize eMMC
Some eMMCs need 80+ms for CMD1 to complete. And the payload may need to
access eMMC in the very early stage (for example, depthcharge needs it
20ms after started) so we have to start initialization in coreboot.

BUG=b:379008996
BRANCH=none
TEST=build pass and run "storage init" in depthcharge shell on MTK EVB
firmware-shell: storage init
*  0: mtk_mmc
1 devices total

Signed-off-by: Mengqi Zhang <mengqi.zhang@mediatek.corp-partner.google.com>
Change-Id: I82f2a155b810a8b9608d70fe0c015e6054d0be00
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87862
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2025-05-29 12:12:32 +00:00
Luca Lai
91ebbb8d35 mb/trulo/var/pujjolo: Modify pujjolo variant
Modify pujjolo vairant codes for type-c port1 display, parade
touch screen, especially for gpio to fit Trulo. Follow the setting of pujjocento.

BUG=b:395763555
BRANCH=none
TEST=Build and boot to pujjolo. Verify functions work.

Change-Id: I285cd33de6e18a2ffb30eb6401c03f6a4b20dc4a
Signed-off-by: Luca Lai <luca.lai@lcfc.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87843
Reviewed-by: Talal Sadak <tsadak@google.com>
Reviewed-by: Dinesh Gehlot <digehlot@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-29 06:59:53 +00:00
Zhaoxiong Lv
aea05e51a7 mb/google/trulo/var/pujjocento: Enable WWAN function
WWAN_FCPO == GPP_D6
WWAN_RST == GPP_E17
spec reuqest: 0 < toff <10ms

LTE is controlled by bits 14 and 15 in fw_config, and P sensor
and LTE modules exist at the same time, so we use the same bit
to control whether to load the driver.

BUG=b:419325064,b:417105553
TEST=Confirm the measured WWAN power sequence

Change-Id: Ia978aef2cc721b65618ac78c13930447d1557797
Signed-off-by: Zhaoxiong Lv <lvzhaoxiong@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87841
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-28 14:32:54 +00:00
Zhaoxiong Lv
47133a716d mb/google/trulo/var/pujjocento: Add P-sensor support
Apply DRIVERS_I2C_SX9324
Apply DRIVERS_I2C_SX9324_SUPPORT_LEGACY_LINUX_DRIVER

GPIO changes:
GPP_B7	==>	I2C_P_SENSOR_SDA
GPP_B8	==>	I2C_P_SENSOR_SCL
GPP_H19	==>	P_SENSOR_INT_L

BUG=b:417176908
TEST=Build and verify on pujjocento

Device list:
cat /sys/bus/iio/devices/iio\:device0/name
sx9324

The value of register 01 when away:
i2cget -f -y 13 0x28 01
0x00

The value of register 01 when approaching:
i2cget -f -y 13 0x28 01
0x01

Change-Id: Ie5543f592876c1ebfbb39049f00fe7fe171c8e2f
Signed-off-by: Zhaoxiong Lv <lvzhaoxiong@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87743
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
2025-05-28 14:32:18 +00:00
Zhigang Qin
04c0527aba soc/mediatek/mt8189: Support different PMIC soluitons for MT8189(G/H)
The MT8189 chipset comes in two variants: MT8189G and MT8189H. The
MT8189G variant uses a single PMIC IC (MT6315), whereas the MT8189H
variant uses two PMIC ICs. To ensure driver compatibility, we utilize
the CPU ID and segment ID to accurately determine the required number
of SPMIF instances.

BUG=b:379008996
BRANCH=none
TEST=build pass and boot up normally.

Signed-off-by: Zhigang Qin <zhigang.qin@mediatek.corp-partner.google.com>
Change-Id: I07bc21a2026803e76861b27a178d229deca2090a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87854
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2025-05-28 08:37:24 +00:00
Vince Liu
80149f55f7 soc/mediatek/common: Convert spmi_dev_cnt to a function
In some SoCs, such as MT8189G/H, different numbers of PMICs are
required. To ensure code reusability and compatibility, it is
necessary to dynamically set this variable. Therefore, spmi_dev_cnt
is changed to a function.

BUG=b:379008996
BRANCH=none
TEST=build passed

Signed-off-by: Vince Liu <vince-wl.liu@mediatek.corp-partner.google.com>
Change-Id: Ib8d6306a81c276dceb021ddadec40803fd85019b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87853
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2025-05-28 08:37:12 +00:00
Wen Zhang
dcf403e43a mb/google/skywalker: Configure fingerprint pins
There is no powering-on control in the fingerprint kernel driver.
Follow Rauru to power-on FP MCU in the FW.

BUG=b:401396071
BRANCH=none
TEST=ectool --name=cros_fp version can get the FP FW version.

Signed-off-by: Haikun Zhou <zhouhaikun5@huaqin.corp-partner.google.com>
Change-Id: I20ff175ee4874c4188b7d07ee57330a9275dcb3d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87852
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Yidi Lin <yidilin@google.com>
2025-05-28 08:37:01 +00:00
Yu-Ping Wu
508d910ed4 libpayload/arch/mock: Select ARCH_HAS_NDELAY for ARCH_MOCK
Unit tests should always use a mock ndelay() defined within each test.
Therefore, select ARCH_HAS_NDELAY for ARCH_MOCK.

Change-Id: I2680e37034d4d13058b3e778d72e63fc6ed18313
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87855
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2025-05-28 00:15:29 +00:00
Stephen Douthit
96ac0224ab pci: Add support for assigning resources to SR-IOV VF BARs
This ensures that bridge windows allocate enough space to cover
SR-IOV BARs. Without this Linux will print messages, these messages
may differ depending on the kernel version used.

Debian GNU/Linux 12 (kernel 6.1.0-28-amd64):
pci 0000:06:00.0: BAR 7: no space for [mem size 0x00200000 64bit pref]
pci 0000:06:00.0: BAR 7: failed to assign [mem size 0x00200000 64bit
pref]

Ubuntu 22.04.5 LTS (kernel 6.8.0-52-generic):
pci 0000:06:00.0: VF BAR 0 [mem size 0x00200000 64bit pref]: can't
assign; no space
pci 0000:06:00.0: VF BAR 0 [mem size 0x00200000 64bit pref]: failed to
assign

TEST=Raptorlake-P

Change-Id: Ib169efe5a6b998a8342a895f1456a280669c719d
Signed-off-by: Stephen Douthit <stephend@silicom-usa.com>
Signed-off-by: Harrie Paijmans <hpaijmans@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/34620
Reviewed-by: Frans Hendriks <fhendriks@eltan.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-27 15:10:48 +00:00
Zhixing Ma
ba8be19122 mb/intel/ptlrvp: Update Kconfig for PTLRVP_CHROMEEC
Update the MAINBOARD_PART_NUMBER config to support PTLRVP_CHROMEEC
variant.

BUG=NONE
TEST=boot ptlrvp_chromeec variant and verify correct mainboard name
in depthcharge.

Change-Id: Ic8208b4ee2c9055671d426cb4b4fdc2a494ad2d8
Signed-off-by: Zhixing Ma <zhixing.ma@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87688
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jérémy Compostella <jeremy.compostella@intel.com>
Reviewed-by: Wonkyu Kim <wonkyu.kim@intel.com>
Reviewed-by: Jamie Ryu <jamie.m.ryu@intel.com>
2025-05-27 15:10:12 +00:00
Felix Singer
7cbbf786cc update_submodules: Use relative paths to submodules
There doesn't seem to be much reason to use absolute paths to the
submodules, other than that it's not needed to change to the original
directory.

In preparation for CB:87824, make use of relative paths and change to
the original directory at the start of each iteration.

Change-Id: Ic74b589d933e6acd882fb9a09461bf7c01952a6f
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87823
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
2025-05-27 15:09:51 +00:00
Tongtong Pan
dcc8400e27 mb/google/fatcat/var/felino: Modify GPIOs config
Make some GPIOs corrections, refer to the schematic revision
 NB7501A_WSCH_MB_V4P_0427.

disable MIPI config
disable ISH
modify HW_ID config
nc some strap pin to default
modify sx related pins

BUG=NONE
TEST=emerge-fatcat coreboot

Change-Id: I075efda3044ffe45d7db3d225b10e96e084483aa
Signed-off-by: Tongtong Pan <pantongtong@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87806
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2025-05-27 15:09:40 +00:00
Matt DeVillier
99af85ad36 mb/google/puff: Add VBTs for Moonbuggy and Scout variants
These variants were missing VBTs necessary for display init, so add
them. VBT files taken from the stock firmware images:
coreboot-Google_Moonbuggy.13324.803.0.bin
coreboot-Google_Scout.13324.645.0.bin

Since all variants now have VBTs, move the selection of
INTEL_GMA_HAVE_VBT to the baseboard.

TEST=build/boot various puff variants, including scout.

Change-Id: I2bb06894fc4df358cc38a4627de9f95289c2c5e0
Signed-off-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87779
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <ericllai@google.com>
2025-05-27 15:09:25 +00:00
Angel Pons
4ae9a79d8d Haswell NRI: Remove unused SPD_LEN define
This was kept around to avoid build issues back when the NRI patches
were awaiting review. It is no longer used and to-be-upstreamed code
does not use this define either, so now is a good time to get rid of
it.

Change-Id: Id10d81774b0d679b54d5dc4a15dab5996e3a68c5
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87832
Reviewed-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-27 15:09:11 +00:00
Angel Pons
0c5286ba34 Haswell NRI: Tidy up REUT subsequence programming
The REUT subsequence control register had a different layout in the
Haswell A0 stepping, so it was initially programmed using bitmasks.
However, NRI does not implement support for the A0 stepping because
it is early pre-production silicon that no one should be using, but
the code kept using the bitmasks approach. But we can do better.

Introduce a bitfield for the REUT subsequence control register, and
use it instead of bitmasks. Put the enum for subsequence types next
to the code using it (no reason to have it in the common header, it
is not used anywhere else). And make a helper function that encodes
the number of cachelines in the format expected by the REUT (7 bits
of value, 1 bit for exponential/linear).

Change-Id: I1609ad010e714b0fc47403df7a71e5fc5ae0f5ac
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87829
Reviewed-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-27 15:08:30 +00:00
Angel Pons
7766228798 Haswell NRI: Deduplicate PCODE mailbox functions
Now that the CPU code exports these PCODE mailbox functions, there is no
reason to retain a copy of them in NRI.

Change-Id: Ic9853cfd6793ecdadf8d2bd15b268f9cf95ba32d
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87828
Reviewed-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-27 15:07:40 +00:00
Angel Pons
ae68ef3684 cpu/intel/haswell: Export PCODE mailbox functions
The PCODE mailbox is primarily used by CPU code in ramstage. However,
it is also used as part of enabling DDR 2x refresh rate, which is now
implemented in coreboot as part of NRI (native RAM init).

The PCODE mailbox functions in CPU code were not exported at the time
NRI was being developed, so I chose to temporarily copy the functions
into NRI code to make it easier to rebase NRI patches since it avoids
potential merge conflicts. After a few years of rebasing patches, NRI
finally got submitted, so there's no reason to keep duplicate code in
the tree anymore.

Put the relevant PCODE functions into a new file, which gets compiled
for both ramstage (CPU init) and romstage (NRI). The BCLK calibration
function is only used in ramstage so there's no need to move it.

Change-Id: I340625fabc072139b8def254f1ce6b19f360adcd
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87827
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2025-05-27 15:07:25 +00:00
Angel Pons
ddce240d34 cpu/intel/haswell: Clean up Makefile
Group entries by stage and sort groups by stage execution order.

Change-Id: I6e2a53d6555700b48fd3aececdfdb8983554a75a
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87826
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Patrick Rudolph <patrick.rudolph@9elements.com>
2025-05-27 15:07:04 +00:00
Avi Uday
2117ed850f mb/google/ocelot/var/ocelot: fix storage configs for ocelot
Ocelot does not support GEN5 NVME Storage. However since ocelot code
was forked from fatcat, these configs exist in coreboot.

Furthermore, the GEN4 NVME GPIOs have changed for ocelot -
1. GPP_B10 to GPP_H18 - GEN4_SSD_PWREN renamed to EN_PP3300_SSD
2. GPP_B09 to GPP_A08 - M2_GEN4_SSD_RESET_N renamed to SSD_PERST_L

BUG=b:419731962

Change-Id: I005d1188138ac7b4bbffa1437bba9aea39aff117
Signed-off-by: Avi Uday <aviuday@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87804
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Pranava Y N <pranavayn@google.com>
2025-05-27 15:06:31 +00:00
Nick Vaccaro
c5488c0d6d mb/google/ocelot/var/ocelot: update gpios
Update gpio configuration for GPP_A08, GPP_E17, and GPP_F18 to
match ocelot schematic.

Change GPP_H16 (WWAN_PWR_EN) to GPP_E01 (EN_WWAN_PWR) in fw_config.c.

Change GPP_V06 and GPP_V11 to "No Connect" as they are test points.

Change trace names from "SNDW3_" to "SDW3_" to match names on ocelot
schematic.

BUG=b:412736286
BRANCH=None
TEST=`emerge-ocelot coreboot` and verify it compiles without error.

Change-Id: I8996dc1b2b0f85490d55a86dc2ca6a90c1604638
Signed-off-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/87750
Reviewed-by: Pranava Y N <pranavayn@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2025-05-27 15:05:41 +00:00