Commit graph

59,336 commits

Author SHA1 Message Date
Julius Werner
bcced7caea commonlib/device_tree: Make END token part of struct_size
According to the FDT specification the FDT_END token is supposed to be
the last token in the structure block, not a free-floating token
immediately outside of it. That means we're supposed to count it in
struct_size. It seems that the kernel never cared about this, but some
FDT parsing utilities like `fdtgrep` do.

Change-Id: Icdeadbeefcafed00dbabefeed1337c0debc86836
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85462
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 22:23:39 +00:00
Maxim Polyakov
8ad1ee9b0a util/intelp2m: Print the current project version
Print the current project version in the console and in the generated
file with the pad configuration. This makes support easier, since we
know which version of the utility was used and whether we need to
re-generate the configuration file if an error was made in the latest
changes in the code. The version string includes several parts:

  {major}.{minor}-{last commit in the intelp2m directory}-{?dirty}

The major is incremented if a new platform is added, minor - if changes
in functionality are made. Add dirty if the changes were not taken into
account using git.

Use the following command to print the version:

  make version

Change-Id: Id2fd0757c003004af976309a44dbbfff0eb517a7
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67321
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 18:17:40 +00:00
Maxim Polyakov
1b9c312273 intelp2m/patform/sunrise: Add unit tests
- The generated map of long and short macros should correspond to the
  reference ones for all pads (INTEL-SUNRISE-PCH/PAD-MAP). The test
  suite is based on the generated macros of a real platform.
- generated field macros should correspond to the RO_FIELDS mask
  (INTEL-SUNRISE-PCH/MASK);
- macros generated from the zero values bits of the DW registers should
  correspond to the reference ones (INTEL-SUNRISE-PCH/EMRTY).

Use the following command in the console to run all the tests in the
project:

make test

Change-Id: I15c7483f120a330849d4bad036427be205b0911c
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67132
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com>
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
2024-12-04 18:16:16 +00:00
Maxim Polyakov
2394795279 intelp2m/patform/lewisburg: Add unit tests
- The generated map of long and short macros should correspond to the
  reference ones for all pads (INTEL-LEWISBURG-PCH/PAD-MAP). The test
  suite is based on the generated macros of a real platform.
- generated field macros should correspond to the RO_FIELDS mask
  (INTEL-LEWISBURG-PCH/MASK);
- macros generated from the zero values bits of the DW registers should
  correspond to the reference ones (INTEL-LEWISBURG-PCH/EMRTY).

Change-Id: Iec18462be8428c3f37d546332211a730ee589a2d
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67133
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com>
2024-12-04 18:16:00 +00:00
Maxim Polyakov
bce3363412 intelp2m/patform/apollolake: Add unit tests
- The generated map of long and short macros should correspond to
  the reference ones for all pads (INTEL-APOLLO-PCH/PAD-MAP). The
  test suite is based on the generated macros of a real platform.
- generated field macros should correspond to the RO_FIELDS mask
  (INTEL-APOLLO-PCH/MASK);
- macros generated from the zero values bits of the DW registers
  should correspond to the reference ones (INTEL-APOLLO-PCH/EMRTY).

Change-Id: I1c47edb31d24930068486c74147c5fbc9b18b4b6
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67134
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 18:15:44 +00:00
Maxim Polyakov
6abf66c8f3 util/intelp2m/parser/template: Add unit test
Change-Id: I1612a7d18bf53479cbe53ca0ba761b67e795c16b
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/67135
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 18:15:10 +00:00
Yuchi Chen
6b43e4ba33 MAINTAINERS: Add Yuchi and Vasiliy for Intel Atom Snow Ridge SoC
Change-Id: Id27099e55a4e8e6f62569533fcf6cc31d52e0308
Signed-off-by: Yuchi Chen <yuchi.chen@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85359
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 11:06:57 +00:00
Yuchi Chen
5cedebf874 soc/intel/xeon_xp: Remove 1 bytes losing in lower DRAM
Generally the base address of FSP output is already aligned so there is
no need to minus 1. The current code loses 1 byte in the lower DRAM
address space.

Change-Id: Ia8147702aad496c431cf10b896d68a826c9e45b1
Signed-off-by: Yuchi Chen <yuchi.chen@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85434
Reviewed-by: Jincheng Li <jincheng.li@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Shuo Liu <shuo.liu@intel.com>
2024-12-04 11:06:39 +00:00
John Su
cd30d94ae5 mb/google/brya/var/uldrenite: Generate RAM ID and SPD file
Add the support RAM parts for uldrenite.
Here is the ram part number list:
DRAM Part Name                 ID to assign
H9JCNNNBK3MLYR-N6E             0 (0000)
K3KL6L60GM-MGCT                1 (0001)
K3KL8L80CM-MGCT                2 (0010)
MT62F1G32D2DS-026 WT:B         2 (0010)
H58G56CK8BX146                 3 (0011)

BUG=b:380789023
BRANCH=None
TEST=emerge-nissa coreboot

Change-Id: I8003f693e1d8fa049a0e508078ce29b5bb39f2ef
Signed-off-by: John Su <john_su@compal.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85447
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Dtrain Hsu <dtrain_hsu@compal.corp-partner.google.com>
2024-12-04 08:54:55 +00:00
Roger Wang
cda1e7e553 mb/google/nissa: Create pujjogatwin variant
Create the pujjogatwin variant of nissa reference board by copying the
pujjoga files to a new directory named for the variant.

The difference between pujjoga and pujjogatwin is that pujjogatwin use
Twin Lake CPU and firmware config, so copying the pujjoga setting files
to create new variant.

BUG=b:381152086
TEST=util/abuild/abuild -p none -t google/brya -x -a
make sure the build includes GOOGLE_PUJJOGATWIN

Change-Id: I345ce463699840b10016555bb104a16968e7a8c1
Signed-off-by: Roger Wang <roger2.wang@lcfc.corp-partner.google.com>
Signed-off-by: Luca Lai <luca.lai@lcfc.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85329
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Eric Lai <ericllai@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 07:53:41 +00:00
Yu-Ping Wu
c0ccace4d5 .checkpatch.conf: Set max line length to 96
Linux upstream's checkpatch.pl has a default max line length of 100.
Since coreboot uses 96, add --max-line-length=96 to the config file.

Change-Id: I7737f3d2e0d016b0f0dd82df2865a6b51b667066
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85435
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 07:36:22 +00:00
Yu-Ping Wu
6f2a8ee8cc soc/mediatek/mt8196: Require DRAM blob to exist
The SoC won't be able to boot without dram.elf. Therefore, we should
always expect the file to exist in build time.

BUG=none
TEST=emerge-rauru coreboot
BRANCH=none

Change-Id: Ib902dc4778f34a144dddf847c283fe77d4c776f6
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85441
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-04 07:36:04 +00:00
Yu-Ping Wu
850cf7d07a Update blobs submodule to upstream main
Updating from commit id 45f1b757402f:
2024-08-29 11:51:27 +0200 - (soc/intel/raptorlake: Add microcode for 06-b7-01)

to commit id 14f8fcc1b426:
2024-11-28 05:07:49 +0000 - (soc/mediatek/mt8196: Update SSPM firmware to v2.0)

This brings in 8 new commits:
14f8fcc1b426 soc/mediatek/mt8196: Update SSPM firmware to v2.0
754f7ad6c808 soc/mediatek/mt8196: Add dram.elf version 0.3.0 for DRAM calibration
612f93620740 3rdparty/blobs/mb/google/guybrush: Update signed PSP verstage binaries
3180f6d462a0 3rdparty/blobs/mb/google/zork: Update signed PSP verstage binaries
eb48279e69eb 3rdparty/blobs/mb/google/zork: Update PSP signing token
002ee2ca6e04 soc/mediatek/mt8196: Add MCUPM firmware v1.0
ce5fcc5a745e soc/mediatek/mt8196: Add dpm.pm and dpm.dm version 1.0
ae17d7f52c68 soc/mediatek/mt8196: Add SSPM firmware v1.0

Change-Id: Ia9bf331e4482d7b2a231f4b67552eea80207018e
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85444
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2024-12-04 07:35:58 +00:00
Felix Held
75424efdc4 soc/amd/common/psp/psp_def.h: increase P2C_BUFFER_MAXSIZE
This matches the size used in the reference code and required by the
corresponding document #55758 Rev. 2.04. This doesn't seem to make any
difference in runtime behavior, but I'd rather waste a kilobyte of SMM
RAM, than debugging possible problems caused from not following the
corresponding specification.

Change-Id: I2ee30d6d1255317efcd3960016069dfe50885aa7
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85357
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2024-12-03 17:41:58 +00:00
Felix Held
179945291c soc/amd/common/psp/rpmc: fix printk format string
While gcc didn't seem to care about that mismatch, clang didn't like
that '%ld' was used in the printk format string to print a size_t
variable. Replace the correct '%zu' instead of '%ld' to fix that.

Change-Id: I32bc584abe835c9c1d732c12311881345b8f0cdf
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85251
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-03 17:41:46 +00:00
Felix Held
9b308f4d54 soc/amd/common/psp/psp_smi: report errors in 'handle_psp_command'
To see if things went wrong in the 'handle_psp_command' function, print
the status code in case it's not MBOX_PSP_SUCCESS.

Change-Id: I8c02e8e29ab5619282e5b864a8cea6f0703f6ef2
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85238
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-03 17:41:33 +00:00
Felix Held
5613f209c7 soc/amd/common/psp_smi_flash: implement SPI flash RPMC command handling
Extend the 'psp_smi_spi_rpmc_inc_mc' and 'psp_smi_spi_rpmc_req_mc'
function stubs that now implement the actual functionality by calling
'spi_flash_rpmc_increment' and 'spi_flash_rpmc_request' after doing some
sanity checks.

TEST=When selecting both 'SOC_AMD_COMMON_BLOCK_PSP_RPMC' and
'SOC_AMD_COMMON_BLOCK_PSP_SMI' Kconfig options on a board with an RPMC-
capable SPI flash, the PSP SMI handler can successfully service not only
the already working SPI flash write command, but also the increment
monotonic counter RPMC command:

[NOTE ]  coreboot-[...] x86_32 smm starting (log level: 8)...

[SPEW ]  SMI# #0
[SPEW ]  PSP: SPI write request
[DEBUG]  FMAP: area PSP_NVRAM found @ f20000 (131072 bytes)
[SPEW ]  PSP: SPI write 0x400 bytes at 0x0

[NOTE ]  coreboot-[...] x86_32 smm starting (log level: 8)...

[SPEW ]  SMI# #0
[SPEW ]  PSP: SPI write request
[DEBUG]  FMAP: area PSP_NVRAM found @ f20000 (131072 bytes)
[SPEW ]  PSP: SPI write 0x400 bytes at 0x400

[NOTE ]  coreboot-[...] x86_32 smm starting (log level: 8)...

[SPEW ]  SMI# #8
[SPEW ]  PSP: SPI write request
[DEBUG]  FMAP: area PSP_NVRAM found @ f20000 (131072 bytes)
[SPEW ]  PSP: SPI write 0x310 bytes at 0x800

[NOTE ]  coreboot-[...] x86_32 smm starting (log level: 8)...

[SPEW ]  SMI# #1
[SPEW ]  PSP: SPI write request
[DEBUG]  FMAP: area PSP_RPMC_NVRAM found @ f40000 (262144 bytes)
[SPEW ]  PSP: SPI write 0x70 bytes at 0x100

[NOTE ]  coreboot-[...] x86_32 smm starting (log level: 8)...

[SPEW ]  SMI# #0
[SPEW ]  PSP: SPI RPMC increment monotonic counter request

This requires the PSP_RPMC_NVRAM FMAP section to have the correct size
which in case of Renoir is 256 kByte. Having this large enough size also
makes the PSP report that the PSP RPMC NVRAM is healthy which wasn't the
case in previous tests when the region was too small.

Change-Id: I20e4f60d4e35d33e560fc43212b320e817e13004
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84906
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2024-12-03 17:41:20 +00:00
Felix Held
b1f954bc6c soc/amd/common/block/psp/psp_smi_flash.h: fix struct element types
Commit ee93b35bc3 ("soc/amd/common/psp_smi_flash: add RPMC command-
specific data structures") added the 'psp_spi_rpmc_inc_mc' and
'psp_smi_rpmc_req_mc' structs, but added the counter data as uint32_t
while it should have been an array of 4 uint8_t, since the bytes in that
buffer are already in the order in which they need to be sent over to
the SPI flash which is different than the byte order of a uint32_t. This
was only noticed after getting the code that uses these structs was
tested.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I6c290535a1896c080b74d892cb289e6e122d4525
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85236
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-03 17:41:02 +00:00
Felix Held
ce01117aa5 drivers/spi: add RPMC support
Add functions to send the RPMC-related commands to a RPMC-capable SPI
flash to provision the root key, update the HMAC key, increment the
monotonic counter, and request the monotonic counter data. To talk to
the flash chip, the command bytes and polling mechanism described in the
SFDP data structure of the flash are used.

The JESD260 specification was used as a reference.

Some of inspiration was taken from
github.com/teslamotors/coreboot/tree/tesla-4.12-amd

TEST=When used with the later patch that calls some of the functions
added in this patch, sending the RPMC increment monotonic counter
command to the RPMC-capable SPI flash, in this case W74M12JW, is
successful.

Change-Id: Ia9bd69d0105c66bf5ecb6c90e8c782a81912bd40
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84837
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-03 17:40:39 +00:00
Nicolas Kochlowski
78270ef3f1 Documentation/tutorial/managing_local_additions.md: Add symlink info
Add information about how the symlink target can be used
to develop and test additions to the coreboot tree from
site-local.

Change-Id: I75f9e9575005e9ee2f255848a21c5e57c30e9e72
Signed-off-by: Nicolas Kochlowski <nickkochlowski@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84740
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Ana Carolina Cabral
Reviewed-by: Nicholas Chin <nic.c3.14@gmail.com>
2024-12-03 14:06:46 +00:00
Yu-Ping Wu
0a7c3ed514 soc/mediatek/mt8195: Fix SCP register address
The parentheses are missing in the mtk_scp macro definition.

The only usage is

 SET32_BITFIELDS(&mtk_scp->scp_clk_on_ctrl,
                 SCP_CLK_ON_CTRL, 1);

I guess that bit is already set by default, so there's no ULPOSC clock
issue found so far.

BUG=none
TEST=none
BRANCH=cherry

Change-Id: I2dbb5c465ee60f0c4dce8ff77b8d3a39db42e4f5
Signed-off-by: Yu-Ping Wu <yupingso@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85436
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2024-12-03 10:20:39 +00:00
Jarried Lin
4c8547704f mb/google/rauru: Add 2nd source TAS2563 amps to support beep
Derive the audio amplifier from FW_CONFIG, and set up I2C and I2S for
TAS2563. Also pass the corresponding GPIO(s) to the payload.

TEST=build pass and driver init ok
BUG=b:357969183

Change-Id: I10cba7964d3847f2a74341b3130ff1e7bfd8d37a
Signed-off-by: Darren Ye <darren.ye@mediatek.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85360
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2024-12-03 09:35:40 +00:00
Jarried Lin
ac83b48cba soc/mediatek/mt8196: Add audio base address definition
Add audio base address definition.

TEST=build pass
BUG=b:357969183

Change-Id: I07d272fddfe50e73adc6f4c7d401f3391b0c145d
Signed-off-by: Darren Ye <darren.ye@mediatek.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85361
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2024-12-03 08:54:15 +00:00
Yidi Lin
c661933a24 soc/mediatek/common: Add read16/write16 support for PMIF
This patch is prepared for MT8196 PMIF driver.

BUG=none
TEST=emerge-corsola coreboot; emerge-geralt coreboot

Change-Id: I3adbbaaf247a8bbd99627cf089b5b55fcf4fb115
Signed-off-by: Yidi Lin <yidilin@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84774
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2024-12-03 07:17:08 +00:00
Subrata Banik
c107755701 vc/intel/fsp: Update PTL FSP headers from 2382_01 to 2431.00
Update generated FSP headers for Panther Lake from 2431.00

Changes include:
- Update in FspmUpd.h : Adjusted offsets and updated comments.
- FspsUpd.h: added ThcInterruptPinMuxing, ThcMode and ThcWakeOnTouch
  UPDs
- MemInfoHob.h : Updated comments

BUG=b:378789201
TEST=Able to build google/fatcat

Change-Id: I1c1fed8f7ba9d25fdce5bbac3a9687800db33613
Signed-off-by: alokagar <alok.agarwal@intel.com>
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85149
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: <srinivas.kulkarni@intel.com>
Reviewed-by: Jayvik Desai <jayvik@google.com>
Reviewed-by: Dinesh Gehlot <digehlot@google.com>
2024-12-03 06:48:28 +00:00
Jeremy Compostella
a417acdfbc mb/google/fatcat: Remove unnecessary prototype
BUG=b:377798581
TEST=fatcat board build is successful

Change-Id: I5d71e9edde0ecbd7aaf316cd754a6ebcff9da77a
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85442
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-by: Pranava Y N <pranavayn@google.com>
2024-12-03 05:58:35 +00:00
Maximilian Brune
d095f1ea45 soc/amd/glinda: Update MCA banks
source:
PPR 57254 Rev 1.59 Table "Non-core MCA Bank to Block Mapping"

Change-Id: I16f5f9db08ab3232caa64fcdc90b8fc062869fcc
Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/84374
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2024-12-02 18:17:03 +00:00
Crystal Guo
8df4eefd44 soc/mediatek/mt8196: Reserve DRAM buffers for HW TX TRACKING
HW TX tracking works by writing a pattern to the designated DRAM buffer
and then reading it back automatically to calculate the appropriate TX
time delay. To avoid writing the pattern to system-used memory, we need
to permanently reserve last 64KB memory on each rank for the HW TX
tracking feature.

BUG=b:317009620
TEST=Reserve memory ok
Firmware shows the following log with 12GB DDR board:
00000001ffff0000-00000001ffffffff: RESERVED
000000037fff0000-000000037fffffff: RESERVED

Change-Id: I042a74c7fbdc0d3dc19dd6bfd2bf021fe1c2b5fc
Signed-off-by: Crystal Guo <crystal.guo@mediatek.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85124
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yidi Lin <yidilin@google.com>
2024-12-02 04:24:55 +00:00
Jonathon Hall
5c766bc150 mb/purism/librem_cnl: Add ramtop to cmos.layout for librem_mini
Since commit e633d370 (soc/intel/cometlake: Enable early caching of
RAMTOP region), cmos.layout for Cannon Lake boards must have a ramtop
entry, add it.

Change-Id: I2bf71f2dd79f2e1e2e13f62a3e08103336bbad61
Signed-off-by: Jonathon Hall <jonathon.hall@puri.sm>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/77670
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-12-02 01:03:48 +00:00
Nicholas Chin
2007792b08 mb/purism/librem_l1um_v2/ramstage.c: Use DEV_PTR macro
Use the DEV_PTR macro to resolve devicetree aliases instead of using the
autogenerated reference names from sconfig directly.

TEST=Timeless build did not change

Change-Id: I4ff06bb3a8256d5fe215cab659f33ec404264e21
Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85093
Reviewed-by: Jonathon Hall <jonathon.hall@puri.sm>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
2024-12-01 22:16:11 +00:00
Nicholas Chin
7f54139a81 Docs/mb/starlabs/labtop_cml.md: Fix footnote syntax
Fix the syntax [1] for the footnote about the onboard memory
configuration so that it renders properly in the generated html.
This also fixes a "Unknown target name" error when building with
newer versions of Sphinx (tested with 8.1.3).

[1] https://myst-parser.readthedocs.io/en/latest/syntax/typography.html#footnotes

Change-Id: I07a85b854a181794f82d8e6a739063d66378d2c7
Signed-off-by: Nicholas Chin <nic.c3.14@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85412
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2024-12-01 05:43:25 +00:00
Roger Wang
9992a98c67 spd/lp5: Add Hynix memory part
Add Micron memory part H58G56CK8BX146 to LP5 global list.
And Regenerate the SPD files for the SoC. The specification
is attached in issue tracker.

BUG=b:367841051
TEST=util/spd_tools/bin/spd_gen spd/lp5/memory_parts.json lp5

Change-Id: I2a003aad32bca9ae5438973ecf0d7872481fee20
Signed-off-by: Roger Wang <roger2.wang@lcfc.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85371
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2024-11-30 05:03:59 +00:00
Maxim Polyakov
36f4390ef0 MAINTAINERS: Add Maxim Polyakov as IMB-1222 maintainer
ASRock IMB-1222 motherboard [1, 2].

[1] https://www.asrockind.com/en-gb/IMB-1222
[2] commit c1caa33a2d

Change-Id: Ifa5763e19f917c720bd6b92465eeca04bf09db0c
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85364
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
2024-11-30 04:44:32 +00:00
Martin Roth
c91553d3a3 Treewide: Remove unused header files
These header files do not seem to be used in coreboot. Presumably
they're left over after the code that used them was removed.

Signed-off-by: Martin Roth <gaumless@gmail.com>
Change-Id: Ide70239c7c2e93fff548d989735450396308c62b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85370
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2024-11-30 04:44:06 +00:00
Mario Scheithauer
932b507907 mb/siemens/mc_ehl5: Use clrsetbits macro for register access
The code is simplified by using the mmio.h macros clrsetbits.

Change-Id: Iab71ab4d6e8b6c38e07641dae3b38093690543e8
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85325
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-29 08:52:01 +00:00
Mario Scheithauer
7906bc6576 mb/siemens/mc_ehl5: Limit eMMC speed mode to DDR50
Due to layout restrictions on mc_ehl5, the eMMC interface is limited to
operate in DDR50 mode. The alternative modes SDR104 and SDR50 are not
supported. Limit the capabilities in the eMMC controller to DDR50 mode
only so that the eMMC driver in OS will choose the right mode for
operation even if the attached eMMC card supports higher modes.

BUG=none
TEST=Boot into Linux and check dmesg output for mmc modes

Change-Id: Ie3214bc3e25e7af706a5c96244d0be50f4bb3094
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85314
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
2024-11-29 08:51:55 +00:00
Mario Scheithauer
7749088de7 mb/siemens/mc_ehl5: Provide static function for disabling SDR modes
As the functionality is required for other devices, it makes sense to
provide a function for this.

Change-Id: If1f070eebd365de93d4bce13d5201045d3306b17
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85324
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
2024-11-29 08:51:49 +00:00
Mario Scheithauer
2d9a82cf8a mb/siemens/mc_ehl5: Rename SDIO converge layer register defines
As the registers for SD-Card and eMMC are identical, the names of the
register defines should also be kept more general. Therefore change the
defines from 'SD_' to 'MMC_'.

Change-Id: I2e0839a00f1b097f92f4f7774d973196d2d0e9a3
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85313
Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Reviewed-by: Uwe Poeche <uwe.poeche@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-29 08:51:44 +00:00
Jarried Lin
758174c61b soc/mediatek/mt8196: Reserve 70 MB memory for OP-TEE
Reserve 70MB memory space for running the OP-TEE image.

BUG=b:317009620
TEST=build pass

Change-Id: I6f75870bdd76e89866508d351b04a0921f30fe4d
Signed-off-by: Jarried Lin <jarried.lin@mediatek.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85249
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Reviewed-by: Yidi Lin <yidilin@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-29 07:08:50 +00:00
Tongtong Pan
605c76bd9c mb/google/fatcat: Modify the kconfig file in felino variant
kconfig incorrectly builds fatcat instead of feilino.
Modify the kconfig file to successfully compile felino.

BUG=b:379797598
TEST=1. util/abuild/abuild -p none -t google/fatcat -x -a
        make sure the build includes GOOGLE_FELINO
     2. Run part_id_gen tool without any errors

Change-Id: Icd76fa97b9879d8f90ae9ee13998b6667f10b39c
Signed-off-by: Tongtong Pan <pantongtong@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85315
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Weimin Wu <wuweimin@huaqin.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Pranava Y N <pranavayn@google.com>
2024-11-29 04:07:57 +00:00
Tongtong Pan
ee485d82fd mb/google/fatcat/var/felino: Modify the overridetree file
Modify overridetree based on the schematics revision 20241120.

BUG=b:379797598
TEST=abuild -v -a -x -c max -p none -t google/fatcat -b felino

Change-Id: I40362b5c823144b6ab0acb878e58b4f5a295bbdd
Signed-off-by: Tongtong Pan <pantongtong@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85321
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2024-11-29 04:07:46 +00:00
Subrata Banik
4724cd4a5f mb/google/fatcat/var/fatcat: Remove TcssAuxOri override
The TCSS configuration now relying on the PD<->PMC communication
for the fatcat board.

This removes the need to override the `TcssAuxOri` UPD setting.

TEST=Booted fatcat successfully. Verified USB-C device detection and
      functionality on both TCSS#0 and TCSS#1 ports.

Change-Id: I37d5c6fe68ad529b4da46aad460e5c1bf92179a8
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85356
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Pranava Y N <pranavayn@google.com>
2024-11-29 02:49:14 +00:00
Jon Murphy
4f2c280e1d mb/google/zork: Update FP enable
Add/update FP enable/disable based on SKU ID. This is meant
to resolve a UMA issue with devices that had the FPMCU populated on
non-fp devices.  Since the FPMCU is present, and the firmware enables
the power GPIO's based on variant, not SKU, the devices were reporting
data on fingerprint errantly.  Specify the SKUs which should not have a
FP sensor and default to true to maintain the legacy behavior for
undefined devices and limit risk.  Variants which do not have FP SKUs
will be unaffected.

BUG=b:354769653
TEST=Flash to zork, test FP.
Disable test SKU, flash on zork, test FP.

To test, run `ectool --name=cros_fp version` in the shell
When enabled, the fpmcu fw version should be displayed.
When disabled, an error should be displayed because the fpmcu
is inaccessible.

Change-Id: Ic6dc71013a1c0d5ee5263109eed87a1b31800232
Signed-off-by: Jon Murphy <jpmurphy@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85294
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-28 18:35:19 +00:00
Maximilian Brune
0b617c9300 arch/riscv: Refactor SMP code
Currently only a fixed number of harts/cores can be detected.

This patch adds a Kconfig option which allows to detect the number of
harts at runtime if a SOC or mainboard has a scheme to do so.
As part of that patch SMP logic has been mostly moved to smp_resume,
since it is easier to debug issues at the time smp_resume is called
than it is at smp_pause, since the serial is usually not present at the
time of the first smp_pause call.

Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com>
Change-Id: Icc53185991fed4dbed032a52e51ff71d085ad587
Reviewed-on: https://review.coreboot.org/c/coreboot/+/81082
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: David Hendricks <david.hendricks@gmail.com>
2024-11-28 13:59:34 +00:00
Maximilian Brune
6c063250b5 arch/riscv: Allow adding OpenSBI as external blob
The reasoning is that even though vendors currently tend to open source
their OpenSBI implementation, they often do so in their own repository.
So instead of adding all possible source repositories as submodules, we
shall allow specifying a path to an already compiled OpenSBI ELF file.
This is similar of what we currently do on ARM64 with the BL31 binary.

Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com>
Change-Id: I6592ad90a254ca4ac9a6cee89404ad49274f0dea
Reviewed-on: https://review.coreboot.org/c/coreboot/+/83284
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Alicja Michalska <ahplka19@gmail.com>
Reviewed-by: ron minnich <rminnich@gmail.com>
2024-11-28 13:57:54 +00:00
Yidi Lin
7f36241461 soc/mediatek: Eliminate redundant calls to get_pmif_controller()
It is unnecessary to look up PMIF controller by mstid in multiple
functions. Just pass `arb` to these functions in order to avoid
redundant calls to get_pmif_controller().

BUG=none
TEST=compiled

Change-Id: I907d6ff029827e4afe4f1d05e39c8dd662c7c45e
Signed-off-by: Yidi Lin <yidilin@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85327
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-28 13:41:40 +00:00
Tyler Wang
f8e4cdd058 mb/google/rex/var/kanix: Set GPP_V14 to NC
Follow schematic(ver.1122A), set GPP_V14 to NC.

BUG=b:380218793, b:366291025
TEST=emerge-rex coreboot pass

Change-Id: I91abc4e07836abb163c8bb28d54a711d2b25375d
Signed-off-by: Tyler Wang <tyler.wang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85352
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2024-11-28 09:10:38 +00:00
Tyler Wang
57346fadf5 mb/google/rex/var/kanix: Add LAN RTL8125BG related settings
Add LAN RTL8125BG related settings based on schematic(ver.1122A).

BUG=b:380218793, b:366291025
TEST=emerge-rex coreboot pass

Change-Id: Icc24f00406d5f91e38725588109c61b7bad099c3
Signed-off-by: Tyler Wang <tyler.wang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85322
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-28 09:10:05 +00:00
Tyler Wang
3923753485 mb/google/rex/var/kanix: Update fw_config settings
Update following fw_config settings:
+-----------+-------------------------+----------------------------+
| Bit 0-1   | DB_USB                  | 0 --> DB_USB_UNKNOWN       |
|           |                         | 1 --> DB_2USBA             |
+-----------+-------------------------+----------------------------+
| Bit 2-3   | RETIMER                 | 0 --> INTEL_HAYDEN_BRIDGE  |
+-----------+-------------------------+----------------------------+
| Bit 4-6   | AUDIO                   | 0 --> ALC5682I_ALC1019     |
+-----------+-------------------------+----------------------------+
| Bit 7-8   | FAN                     | 0 --> ABSENT               |
|           |                         | 1 --> PRESENT              |
+-----------+-------------------------+----------------------------+
| Bit 9-10  | MIPI_CAM                | 0 --> UF_CAM_HI556         |
+-----------+-------------------------+----------------------------+
| Bit 11-12 | FP_MCU                  | 0 --> FP_MCU_ABSENT        |
|           |                         | 1 --> FP_MCU_NUVOTON       |
+-----------+-------------------------+----------------------------+
| Bit 13    | WIFI_TYPE               | 0 --> WIFI_CNVI            |
|           |                         | 1 --> WIFI_PCIE            |
+-----------+-------------------------+----------------------------+
| Bit 14    | KB_TYPE                 | 0 --> KB_TYPE_DEFAULT      |
|           |                         | 1 --> KB_TYPE_CA           |
+-----------+-------------------------+----------------------------+
| Bit 15    | PANEL_PWRSEQ_EC_CONTROL | 0 --> WIFI_CNVI            |
|           |                         | 1 --> DISABLE              |
+-----------+-------------------------+----------------------------+
| Bit 16    | KB_BACKLIGHT            | 0 --> KB_BACKLIGHT_ABSENT  |
|           |                         | 1 --> KB_BACKLIGHT_PRESENT |
+-----------+-------------------------+----------------------------+

BUG=b:377377766
TEST=emerge-rex coreboot pass

Change-Id: Ic6ab99a05cd6d995dc71b39e002c8ad5b1dafc4a
Signed-off-by: Tyler Wang <tyler.wang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85293
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
2024-11-28 09:10:00 +00:00
Tyler Wang
973f291ce1 mb/google/rex/var/kanix: Update GPIO settings
BUG=b:366291025
TEST=emerge-rex coreboot pass

Change-Id: I8a9de4098739cbcdc09f2ec685c374bee3c236a7
Signed-off-by: Tyler Wang <tyler.wang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/85248
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-11-28 09:09:52 +00:00