Commit Graph

53382 Commits

Author SHA1 Message Date
Won Chung 902575f9d3 mb/google/brya/var/skolas: Add new GFX devices with custom _PLD
Add new GFX devices for DDI and TCP with custom _PLD to describe the
corresponding ports.

BUG=b:277629750
TEST=emerge-brya coreboot

Signed-off-by: Won Chung <wonchung@google.com>
Change-Id: I889db739d6e006c1753eb8c0d208cf471d09f18d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/74368
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2023-07-10 14:17:17 +00:00
Mac Chiang 538bcf54c6 mb/google/brya: put Bluetooth VPGIOs overridable
The BT VGPIOs pad config in variant of gpio.c won't be overwritten on board eventually because no matched gpios existed here.

Put BT VGPIOs in gpio_table, ensure that these were able to be overwritten.

The fix included crota and omnigul BT offload work successfully.

BUG=b:264834572
TEST=test Bluetooth offload playback/capture in SCO profile.

Change-Id: I62cecf26abd0411f7cbb0a56b8b8f0a25d370c69
Signed-off-by: Mac Chiang <mac.chiang@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76247
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Derek Huang <derekhuang@google.com>
2023-07-10 06:28:41 +00:00
Kyösti Mälkki 6739a6a89f vboot: Fix S3 resume with stage_cache
In VBOOT_STARTS_IN_ROMSTAGE=y case, vboot_run_logic() did not
get called when postcar was loaded from TSEG stage cache on
ACPI S3 resume path. Resume failed as MP init attempts to
access microcode update from unverified FW_MAIN_A/B section.

In a similar fashion, for POSTCAR=n, loading ramstage from
TSEG stage cache would bypass the call to vboot_run_logic().

TEST=samsung/lumpy with VBOOT_STARTS_IN_ROMSTAGE=y is able
to complete S3 resume.

Change-Id: I77fe86d5fd89d22b5ef6f43e65a85a4ccd3259d9
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76209
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2023-07-10 04:43:05 +00:00
David Wu 72d7181e4f mb/google/brya/var/kuldax: Add fw_config and configurate AUX pin
Add fw_config and configurate AUX pin for MB USB Type-C.
MB USB3 doesn't have re-timer, thus have to configurate the AUX pin.

BUG=b:275335023
TEST=build pass

Change-Id: I1334dcbaec6de1707c6892efbebaf8d460ba8648
Signed-off-by: David Wu <david_wu@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76348
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Bob Moragues <moragues@google.com>
Reviewed-by: Ren Kuo <ren.kuo@quanta.corp-partner.google.com>
2023-07-10 00:08:37 +00:00
Nico Huber a959f0ad76 allocator_v4: Disable top-down allocation for EDK2
EDK2 seems to have problems at least with the resource allocation for
Intel's IGD. While the investigation is ongoing, disable top-down
allocation by default if the payload is known to be EDK2.

Change-Id: I771d8a3b74b54a043624843a00498225d1f509ad
Signed-off-by: Nico Huber <nico.h@gmx.de>
Ticket: https://ticket.coreboot.org/issues/499
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76373
Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sean Rhodes <sean@starlabs.systems>
2023-07-08 20:03:07 +00:00
Kyösti Mälkki 0834b222c9 cpu/x86/lapic: Fix regression with X2APIC_LATE_WORKAROUND
This patch fixes the boot hang due to commit 053a45bcdb ("cpu/x86/lapic: Fix X2APIC_ONLY regression") on platform which selects X2APIC_LATE_WORKAROUND config.

 [EMERG]  Switching from X2APIC to XAPIC mode is not implemented.

Without this patch: Boot gets stuck inside at BS_WRITE_TABLES when enable_lapic() gets called after X2APIC mode has been enabled. The fix is to change enable_lapic() to track when late enablement for X2APIC mode happens with X2APIC_LATE_WORKAROUND.

TEST=Able to build and boot google/rex to chromeos.

Change-Id: I41e72380e9cfb59721d0df607ad875d7b6546974
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76384
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-08 18:54:24 +00:00
Subrata Banik 3c1b7b485b cpu: Enable per-CPUID microcode loading in CBFS
The current design of the `ucode-<variant>.bin` file combines all
possible microcode per cpuid into a unified blob. This model increases
the microcode loading time from RW CBFS due to higher CBFS verification
time (the bigger the CBFS binary the longer the verification takes).

This patch creates a provision to pack individual microcodes (per CPUID)
into the CBFS (RO and RWs). Implementation logic introduces
CPU_INTEL_MICROCODE_CBFS_SPLIT_BINS config which relies on converting
Intel CPU microcode INC file into the binary file as per format
specified as in `cpu_microcode_$(CPUID).bin`.

For example: Intel CPU microcode `m506e3.inc` to convert into
`cpu_microcode_506e3.bin` binary file for coreboot to integrate if
CPU_INTEL_MICROCODE_CBFS_SPLIT_BINS config is enabled.

Another config named CPU_INTEL_UCODE_SPLIT_BINARIES is used to specify
the directory name (including path) that holds the split microcode
binary files per CPUID for each coreboot variants.

For example: if google/kunimitsu had built with Intel SkyLake processor
with CPUID `506e3` and `506e4` then CPU_INTEL_UCODE_SPLIT_BINARIES
refers to the directory path that holds the split microcode binary
files aka cpu_microcode_506e3.bin and cpu_microcode_506e4.bin.

Refer to the file representation below:
|---3rdparty
|   |--- blobs
|   |    |--- mainboard
|   |    |   |--- google
|   |    |   |    |--- kunimitsu
|   |    |   |    |    |--- microcode_inputs
|   |    |   |    |    |    |--- kunimitsu
|   |    |   |    |    |    |    |--- cpu_microcode_506e3.bin
|   |    |   |    |    |    |    |--- cpu_microcode_506e4.bin

Users of this config option requires to manually place the microcode
binary files per CPUIDs as per the given format
(`cpu_microcode_$(CPUID).bin`) in a directory. Finally specify the
microcode binary directory path using CPU_UCODE_SPLIT_BINARIES config.

Additionally, modified the `find_cbfs_microcode()` logic to search
microcode from CBFS by CPUID. This change will improve the microcode
verification time from the CBFS, and will make it easier to update
individual microcodes.

BUG=b:242473942
TEST=emerge-rex sys-firmware/mtl-ucode-firmware-private
coreboot-private-files-baseboard-rex coreboot

Able to optimize ~10ms of boot time while loading microcode using
below configuration.

CONFIG_CPU_MICROCODE_CBFS_SPLIT_BINS=y
CONFIG_CPU_UCODE_SPLIT_BINARIES="3rdparty/blobs/mainboard/
               $(CONFIG_MAINBOARD_DIR)/microcode_inputs"

Without this patch:

  10:start of ramstage           1,005,139 (44)
  971:loading FSP-S              1,026,619 (21,479)

> RO/RW-A/RW-B CBFS contains unified cpu_microcode_blob.bin

  Name                           Offset     Type           Size   Comp
  ...
  cpu_microcode_blob.bin         0x1f740    microcode      273408 none
  intel_fit                      0x623c0    intel_fit          80 none
  ...
  ...
  bootblock                      0x3ee200   bootblock       32192 none

With this patch:

  10:start of ramstage           997,495 (43)
  971:loading FSP-S              1,010,148 (12,653)

> RO/RW-A/B CBFS that stores split microcode files per CPUID

  FMAP REGION: FW_MAIN_A
  Name                           Offset     Type           Size   Comp
  fallback/romstage              0x0        stage          127632 none
  cpu_microcode_a06a1.bin        0x1f340    microcode      137216 none
  cpu_microcode_a06a2.bin        0x40bc0    microcode      136192 none
  ...
  ...
  ecrw                           0x181280   raw            327680 none
  fallback/payload               0x1d1300   simple elf     127443 none

At reset, able to load the correct microcode using FIT table (RO CBFS)

  [NOTE ]  coreboot-coreboot-unknown.9999.3ad3153 Sat May 20 12:29:19
           UTC 2023 x86_32 bootblock starting (log level: 8)...
  [DEBUG]  CPU: Genuine Intel(R) 0000
  [DEBUG]  CPU: ID a06a1, MeteorLake A0, ucode: 00000016

Able to find `cpu_microcode_a06a1.bin` on google/rex with ES1 CPU
stepping (w/ CPUID 0xA06A1) (from RW CBFS)

  localhost ~ # cbmem -c -1 | grep microcode
  [DEBUG]  microcode: sig=0xa06a1 pf=0x80 revision=0x16
  [INFO ]  CBFS: Found 'cpu_microcode_a06a1.bin' @0x407c0 size 0x21800 in
           mcache @0x75c0d0e0
  [INFO ]  microcode: Update skipped, already up-to-date

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: Ic7db73335ffa25399869cfb0d59129ee118f1012
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75357
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
2023-07-08 12:06:00 +00:00
Subrata Banik 325664f021 cpu/intel/microcode: Avoid Pre-RAM microcode update if FIT enable
This patch changes the default behaviour of the MICROCODE_UPDATE_PRE_RAM
config for the platform with FIT (CPU_INTEL_FIRMWARE_INTERFACE_TABLE)
enabled. If FIT is enabled then microcode update will be taken care of
by FIT at pre-cpu reset hence, microcode update at pre-ram phase can be
skipped.

BUG=b:242473942
TEST=Able to build and boot google/rex with MICROCODE_UPDATE_PRE_RAM
remains disabled. No functional impact.

Without this patch:
  CONFIG_MICROCODE_UPDATE_PRE_RAM=y

With this patch:
  CONFIG_MICROCODE_UPDATE_PRE_RAM is not set

Change-Id: I603e064115869aba2bffa5589ffe47a44a90b848
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76234
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2023-07-08 12:05:36 +00:00
Yunlong Jia b333c6a35f mb/google/skyrim/var/crystaldrift: Override SPI flash bus speed
Add configuration to bump up the SPI flash bus speed from 66 MHz to 100
MHz for starting next phase.

BUG=b:270500631
BRANCH=None
TEST=emerge-skyrim coreboot

Signed-off-by: Yunlong Jia <yunlong.jia@ecs.corp-partner.google.com>
Change-Id: I0915d9b10dbfae7fff4e8874011951d1690de870
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75884
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Reviewed-by: Chao Gui <chaogui@google.com>
2023-07-07 21:19:12 +00:00
Felix Held f3180f07b5 soc/amd/*/globalnvs,nvs: remove deprecated & unused CBMC field from GNVS
Commit cde4f3b279 ("acpi/gnvs.c: Drop unused pointer to the cbmem
console") removed writing the coreboot memory console pointer to the
GNVS and kept the CBMC field as reserved. Since those fields aren't
needed any more and there are no dependencies on the absolute position
of the different fields in GNVS as long as both GNVS definitions on the
C and the ASL side match, remove the deprecated and unused CBMC field
from the GNVS structs.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Iadfaf5a4ec1401b027dbfb6a7c6ce74a1dcecdfa
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76351
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2023-07-07 14:49:42 +00:00
Hsuan Ting Chen 8f4b015759 lib: Adjust the log levels in ux_locales.c
The function ux_locales_get_text() should expect to have a correct
preram_locales region to read, hence we need to adjust the log levels
inside lib/ux_locales.c:ux_locales_get_text():
* If the region does not exist or is not in a correct format, we should
  print in BIOS_ERR
* If the arguments are not correct but we have a good workaround (e.g.
  the lang_id from vboot API seems weird), we should print in
  BIOS_WARNING.

Also change some minor syntax issues.

BUG=b:264666392, b:289995591
BRANCH=brya
TEST=emerge-brya coreboot chromeos-bootimage

Signed-off-by: Hsuan Ting Chen <roccochen@chromium.org>
Change-Id: Ic8a8856c883f6ca78fed69542a7d388f57c5c508
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76316
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2023-07-07 13:56:42 +00:00
Johnny Lin 908be4f6ed soc/intel/xeon_sp/spr: Fix upd_display.c build error
Fix below build error after DISPLAY_UPD_DATA is selected:
src/soc/intel/xeon_sp/spr/upd_display.c:131:29: error: variable 'old' set but not used [-Werror=unused-but-set-variable]
  131 |         const FSP_S_CONFIG *old;
      |                             ^~~
src/soc/intel/xeon_sp/spr/upd_display.c:130:29: error: variable 'new' set but not used [-Werror=unused-but-set-variable]
  130 |         const FSP_S_CONFIG *new;

Change-Id: I43ed5fadab58e0d4dc824457c7a1bdf48511198e
Signed-off-by: Johnny Lin <johnny_lin@wiwynn.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76342
Reviewed-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-07 13:56:02 +00:00
Ronak Kanabar 222c44796c drivers/intel/fsp2_0: Remove BUILD_TIME_STAMP_SIZE macro
Remove BUILD_TIME_STAMP_SIZE macro from coreboot because FSP 3223
version have BUILD_TIME_STAMP_SIZE macro defined as part of
`FspProducerDataHeader.h`.

Ref change:
9c28ab1d1a vc/intel/fsp/mtl: Update header files from 3194_81 to 3223.80

BUG=b:285110116
TEST=Able to build google/rex.

Change-Id: I52707adf1aa6dadca8dcf82102f76916a0cfe346
Signed-off-by: Ronak Kanabar <ronak.kanabar@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76341
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
2023-07-07 13:55:16 +00:00
Fred Reitberger e66ce2f418 soc/amd/*/Makefile.inc: Use _tohex instead of printf
Use the _tohex function to convert values to hex instead of 'shell
printf'

TEST=timeless builds identical for grunt,dalboz,guybrush,chausie,birman

Signed-off-by: Fred Reitberger <reitbergerfred@gmail.com>
Change-Id: Ic7f7d1b764479088cc0980b208d8d603bc712832
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76314
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
2023-07-07 12:50:15 +00:00
Morris Hsu 8b42a05fed mb/google/brya/var/constitution: Update overridetree
constitution only has one TBT port, remove tcss_dma1.

BUG=None
TEST=emerge-constitution coreboot

Change-Id: Ia4eb4371eb20e75a0f464e2b087fd2fe59569537
Signed-off-by: Morris Hsu <morris-hsu@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76336
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: David Wu <david_wu@quanta.corp-partner.google.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Pablo Ceballos <pceballos@google.com>
2023-07-07 06:43:42 +00:00
Rob Barnes d6b58d5c76 util/apcb: Add apcb edit tool for phoenix
Add a new apcb edit tool, apcb_v3a_edit.py, that injects SPDs into
an APCB for phoenix platform.

The tool makes several assumptions:
 * Each SPD only uses blocks 0, 1, 3 and 5. All other blocks are zero.
 * Each block is 64 bytes.
 * Dimm and socket are always 0
 * Unused SPD entries are zero'd

BUG=b:281983434
BRANCH=None
TEST=build, flash, boot myst

Change-Id: Ifb50287de77138170714a702ab87d56427aacfef
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76188
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-06 17:46:08 +00:00
Grzegorz Bernacki 7758b47e3b drivers/tpm: Move tis_plat_irq_status to cr50 driver
tis_plat_irq_status() function is used only by Google TPM. It should
be moved to drivers/tpm/cr50.c. The name of the function was changed
to cr50_plat_irq_status().

BUG=b:277787305
TEST=Build all affected platforms

Change-Id: I78dc39f2c7b44232b06947d3dfe6afa52807ced8
Signed-off-by: Grzegorz Bernacki <bernacki@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75917
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2023-07-06 16:16:43 +00:00
Sean Rhodes 15d75aa999 payloads/edk2: Fix typo in Make command
The Makefile was passing `CONFIG_SMMSTORE_v2` which doesn't exist.

Correct this to `CONFIG_SMMSTORE_V2`.

Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: I984d2155143c14cb4a347ed24688b9ea492f7f8b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76317
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
2023-07-06 15:05:16 +00:00
Kyösti Mälkki 0bcdd40d78 acpi/acpi.c: Fix regression with DSDT
Fix regression introduced with commit 01af0f8ac8 ("acpi/acpi.c: Reduce boilerplate").

DSDT table is not to be listed within RSDT/XSDT, ACPICA and/or OSPM may
try load it twice raising conflicts in the namespace and effectively ignoring all or most of the AML.

Change-Id: I0e6d07b35522f2bf9a51cef0a7e3181b15087d88
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76321
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
Reviewed-by: Sean Rhodes <sean@starlabs.systems>
2023-07-06 14:58:04 +00:00
Fred Reitberger e8696e1b07 mb/amd/birman/Kconfig: Select SPI_FLASH_EXIT_4_BYTE_ADDR_MODE
Always exit 4-byte addressing mode to prevent errors when the spi flash
is not left in 4-byte addressing mode.

TEST=boot with PSP releases that leave the flash in both 4-byte
     and 3-byte mode and verify flash writes

Signed-off-by: Fred Reitberger <reitbergerfred@gmail.com>
Change-Id: I9884b85bc3b0a9b654a2cb91fb314b0869abd622
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76094
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-06 13:56:21 +00:00
Mario Scheithauer 0ec7a9f174 mb/siemens/mc_ehl4: Make DRAM population depending on GPIO GPP_B5
GPIO GPP_B5 is used as input on this mainboard. For a full-populated
DRAM configuration, the input signal is connected to ground and for a
half-populated configuration it is connected to 3.3 V.

BUG=none
TEST=Use different HW configurations and check coreboot log

GPP_B5 = 0:
[DEBUG]  2 DIMMs found

GPP_B5 = 1:
[INFO ]  meminit_channels: DRAM half-populated
[DEBUG]  1 DIMMs found

Change-Id: I48b4a3bea7f1ff804b78b7c648a7ea1925627b8a
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76245
Reviewed-by: Jan Samek <jan.samek@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-06 13:55:43 +00:00
Mario Scheithauer 81fb981e8e mb/siemens/mc_ehl: Make DRAM population configurable
There can be mainboard variants, which are only equipped with
half-populated DRAM. For this reason, the meminit parameter for
populatation should be adjustable. The default setting remains at
full-populated DRAM. At mainboard variant level a different selection
via individual input paths can be made.

Change-Id: I390bbfa680b5505bb2230fa0740720bd9dd1fafb
Signed-off-by: Mario Scheithauer <mario.scheithauer@siemens.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76244
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Jan Samek <jan.samek@siemens.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-06 13:55:21 +00:00
Kyösti Mälkki 6aaa4f9198 emulation/qemu-q35: Enable ECAM earlier
Align implementation with real hardwares, such that ECAM
(PCI configuration via MMIO) is available for use when
console is initialised.

Change-Id: I288991f31d3f1678132aa4315168c09eabbbe98d
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76206
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nicholas Chin <nic.c3.14@gmail.com>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2023-07-06 13:54:45 +00:00
Arthur Heymans cde4f3b279 acpi/gnvs.c: Drop unused pointer to the cbmem console
Change-Id: I7e2018dbccead15fcd84e34df8207120d3a0c57c
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/64303
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-by: Tim Wawrzynczak <inforichland@gmail.com>
2023-07-06 13:54:30 +00:00
Kyösti Mälkki a52b93b262 cpu/x86: Add some notes about XAPIC/X2APIC
At the time of writing SMM runtime does not make register
accesses to LAPIC registers, but such breakage has been
reported.

S3 resume failure, where OS switched back from X2APIC
to XAPIC mode, can be reproduced with a sandybridge SKU
that has VT-d disabled.

Change-Id: I300ba87c3d8fde548dbaf95703bd7e2fe54cff57
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76196
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2023-07-06 13:54:20 +00:00
Kyösti Mälkki 053a45bcdb cpu/x86/lapic: Fix X2APIC_ONLY regression
Some ancient CPUs may have had LAPIC disabled at power-up, so
semantically enable_lapic() should always come before attempting
to access the register banks.

With X2APIC_ONLY option it is necessary to ensure enable_lapic()
is called prior to any other lapic register space accesses,
since the XAPIC mode MMIO accessors are optimised away build-time
and CPU's do not yet initialise for X2APIC mode at reset.

Change-Id: I96eaa5c43108c802375e184e0c68b5091ca0198f
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76195
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2023-07-06 13:53:49 +00:00
Arthur Heymans 0b5802449d emulation/{i440fx,q35}: Don't use PCI driver to set root PCI dev ops
This devices is always present so hooking up the ops in devicetree makes
more sense.

Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Change-Id: I369129e365ce8596cad25b97d12168bb08e3ed0e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76241
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-06 13:53:29 +00:00
Sean Rhodes edf1ffef9f mainboard/starlabs/*: Remove the power_on_after_fail option
None of these boards have an RTC battery, so this option has no
effect. Remove it.

Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: I9a55227f74c0b9ae9b56bdef4b8f53b2425b331c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75450
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-06 10:28:01 +00:00
Sean Rhodes 374a382edc mainboard/starlabs/starbook: Unselect RESIZABLE_BARS
It is not needed, so remove it.

Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: I606d0a76926e90e4ce321163400aa50ea961c2a0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75342
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Lean Sheng Tan <sheng.tan@9elements.com>
2023-07-06 10:27:28 +00:00
Kilari Raasi 9c28ab1d1a vc/intel/fsp/mtl: Update header files from 3194_81 to 3223.80
Update header files for FSP for Meteor Lake platform to version 3223_80,
previous version being 3194_81.

FSPM:
1. Add 'ROWHAMMER','RhSelect','McRefreshRate','Lfsr0Mask','Lfsr1Mask'
   UPDs
2. Add 'TmeExcludeBase','TmeExcludeSize','GenerateNewTmeKey' UPDs
3. Address offset changes

BUG=b:287890130
TEST=Able to build and boot google/rex to ChromeOS.

Change-Id: I4b8d0a3a87be7dc0d899298eb8e4e48905090e71
Signed-off-by: Kilari Raasi <kilari.raasi@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75916
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-06 06:10:13 +00:00
John Su c08b645ffc mb/google/brya/var/mithrax: Generate SPD ID for supported parts
Add new memory parts in the mem_parts_used.txt and generate the
SPD ID for the parts. The memory parts being added are:

1. K4U6E3S4AB-MGCL (Samsung)
2. K4UBE3D4AB-MGCL (Samsung)

BUG=b:289873670
BRANCH=brya
TEST=emerge-brya coreboot chromeos-bootimage

Signed-off-by: John Su <john_su@compal.corp-partner.google.com>
Change-Id: I7a262ac62c24cfb43c0283c9730c177a242342e6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76240
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-06 00:57:29 +00:00
Fred Reitberger dbf1b63b11 soc/amd/phoenix/Makefile.inc: Refactor repeated lines to a variable
Rather than repeat the same line multiple times, save it in a variable
once and use that variable in the rest of the file.

TEST=timeless birman build identical

Signed-off-by: Fred Reitberger <reitbergerfred@gmail.com>
Change-Id: I4eb262adb3bbda04add79b2e2b8bee9a609a1e5b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76197
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-05 19:00:21 +00:00
Fred Reitberger 41a162b7a8 soc/amd/phoenix/Makefile.inc: Pass APOB_NV address as offset
Pass the APOB NV address as a flash offset instead of x86 address.

TEST=boot birman and verify APOB_NV is working

Signed-off-by: Fred Reitberger <reitbergerfred@gmail.com>
Change-Id: I0f710f12cc5d933a75840dbce1c4bad0c2ea04cc
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76162
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-05 18:59:53 +00:00
Stefan Reinauer 37c1f51c7c Update libhwbase submodule to upstream master
Updating from commit id 8be5a82:
2022-10-04 14:01:00 +0000 - (Fix "unnecessary with of ancestor [-gnatwr]")

to commit id 95ad8c5:
2022-12-22 15:32:38 +0000 - (hw-debug: Place global variables in the .bss section)

This brings in 1 new commits:
95ad8c5 hw-debug: Place global variables in the .bss section

Change-Id: Ib28dbcdf14f313cbfeab03e98e05fffe16a1b708
Signed-off-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/75794
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2023-07-05 18:06:54 +00:00
Felix Singer 70b00b061a Update fsp submodule to upstream master
Updating from commit id 6f2f17f:
2022-12-14 12:36:46 -0700 - (Deleted old Release Notes and Integration Guides)

to commit id 3beceb0:
2023-06-30 14:45:10 +0800 - (IoT ADL-S MR5 (4081_05) FSP)

This brings in 24 new commits:
3beceb0 IoT ADL-S MR5 (4081_05) FSP
6076e6a IoT ADL-S MR4 (4021_00) FSP
d3f81b8 Merge branch 'master' of https://github.com/intel/FSP
ebe9a91 IoT ADL-P MR4 (4081_04) FSP
63ee94d Tiger Lake - IoT FSP 6033_00_MR8
0012fe4 Delete FspInfoHob.h
99ed823 Tiger Lake - IoT FSP 6033_00_MR8
78ad3c7 Tiger Lake - IoT FSP 6033_00_MR8
2fea9a2 Delete TigerLakeFspPcds.dsc
4818990 Delete TigerLakeFspBinPkg.dec
458c639 Delete GpioConfig.h
a7ecf36 Delete FusaInfoHob.h
cfdf71d Tiger Lake - IoT FSP 6033_00_MR8
cf40b9e IoT ADL-P MR3 (4021_00) FSP
72b10be IoT RPL-S PV (3492_03) FSP
3ae8ca8 Elkhart Lake MR6 FSP
95f32b7 Alder Lake FSP C.1.75.10
8759e77 Alder Lake FSP C.0.75.10
f130444 IoT ADL-PS MR2 (4022_00) FSP
244f852 Merge branch 'master' of https://github.com/intel/FSP
7882623 IoT ADL-N PV (4031_00)
d85493d Whitley 4.2.0.2A
9ff1570 Merge branch 'master' of https://github.com/intel/FSP
fe92019 Updated for Tiger Lake - IoT FSP 5505_01_MR7

Change-Id: I3b5208e3508476fffca73a09da7aa3c5b53ba1ba
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76220
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
2023-07-05 17:24:09 +00:00
Kyösti Mälkki d7542cb338 arch/x86: Ensure LAPIC mode for exception handler
Attempting to use X2APIC MSRs before the call to enable_lapic()
is made raises exception and double-faults.

Change-Id: Ib97889466af0fbe639bec2be730784acc015b525
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76194
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
2023-07-05 15:59:31 +00:00
Felix Singer 47d61a7c14 Update intel-microcode submodule to upstream master
Updating from commit id 2be47ed:
2023-02-14 17:52:48 -0600 - (microcode-20230214 Release)

to commit id 6f36ebd:
2023-06-13 16:09:19 -0600 - (microcode-20230613 Release)

This brings in 5 new commits:
6f36ebd microcode-20230613 Release
390edfb microcode-20230512-rev2 Release
9660518 microcode-20230516a Release
05f5ca0 microcode-20230516 Release
752cd0a microcode-20230512 Release

Change-Id: Ibf557a4ac2e5757dbd07031eb13f59ddbeaca487
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76216
Reviewed-by: Elyes Haouas <ehaouas@noos.fr>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-05 12:58:37 +00:00
Felix Singer d486fc3706 soc/intel/alderlake: Increase default CBFS size to 4MB
Updating some submodule pointers to their latest commit causes some
builds with default configuration to fail since all required components
don't fit into 2MB anymore. Specifically, this has been experienced with
the microcode and FSP submodules.

So, increase the default CBFS size to 4MB to make sure builds succeed
with updated submodules.

Change-Id: I2fc16240bef36c057608acadf3cb7c65e7f0d244
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76217
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
2023-07-05 12:56:44 +00:00
Michał Żygowski f646077880 mb/protectli/vault_ehl: Set DIMM_MAX to 1
VP2420 (vault_ehl) has only 1 DIMM slot present. Set the DIMM_MAX to 1
to optimize the common libraries to not attempt to read and parse more
SPD than needed.

TEST=Boot Protectli VP2420 (vault_ehl) with different DIMMs and see
FSP is retraining the memory properly and fastboot is working.

Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Change-Id: I29a99f387ffe2df1060547e0818c5c5b66a27061
Reviewed-on: https://review.coreboot.org/c/coreboot/+/73819
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Michał Kopeć <michal.kopec@3mdeb.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-05 12:55:56 +00:00
Sumeet Pawnikar 8d0a063810 soc/intel/meteorlake: Set TCC to 90°C
Set tcc_offset value to 20 in chipset for Thermal Control
Circuit (TCC) activation feature for meteorlake silicon.
Also, remove tcc_offset default value from rex baseboard
and variants.

BUG=b:270664854
BRANCH=None
TEST=Build FW and test on rex board

Change-Id: Ieec1b7e0873eef46a56e612ed1d9445019b1f4a9
Signed-off-by: Sumeet Pawnikar <sumeet.r.pawnikar@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76232
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2023-07-05 12:54:13 +00:00
Zhongtian Wu 969a2a9a30 mb/google/rex/var/screebo: Update touchpad I2C timing
Change i2c[3] parameter to meet below timing:
t-HIGH > 600ns;
900ns > Thd:dat > 300ns.

BUG=b:286030723
BRANCH=none
TEST=Test success by EE.

Change-Id: I4b2d958a5a0d41e2cfa1087f5cb94cc83bbb1739
Signed-off-by: Zhongtian Wu <wuzhongtian@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76169
Reviewed-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-05 12:53:33 +00:00
Subrata Banik 35ef2e5606 mb/google/rex/var/ovis: Set TCC to 100°C
Set tcc_offset value to 10 in devicetree for Thermal Control
Circuit (TCC) activation feature for ovis.

BUG=b:270664854
TEST=Build and boot google/ovis.

Change-Id: I0ef626f6cc460f1b460297804b97038705efaf4c
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76230
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sumeet R Pawnikar <sumeet.r.pawnikar@intel.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-05 10:36:33 +00:00
Sumeet Pawnikar 6ce1391d1c soc/intel/meteorlake: add power limits for 28W SKU
Add power limit values for Meteor Lake 28W SKU.

Reference: Intel MTL-UH_Power_Map_Rev1p2, doc: 640982

BRANCH=None
BUG=b:289854108
TEST=Build FW

Change-Id: I0b4741185278913d11d902d53345ae8ccebb18f8
Signed-off-by: Sumeet Pawnikar <sumeet.r.pawnikar@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76239
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2023-07-05 10:36:09 +00:00
Sumeet Pawnikar 33c6171bde soc/intel/meteoerlake: add support for 28W SKU
Add power limits support for 28W SKU.

BRANCH=None
BUG=b:289854108
TEST=Build FW

Change-Id: I83deb1e574990cb70f9aac5d5eb46fbb710a6170
Signed-off-by: Sumeet Pawnikar <sumeet.r.pawnikar@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76238
Reviewed-by: Subrata Banik <subratabanik@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-05 10:35:57 +00:00
Subrata Banik 3d4ff8498c mb/google/rex/var/ovis: Add Power Limit for 28W
This patch adds a power limit for Ovis with 28W Intel Meteor Lake
silicon.

Reference: Intel MTL-UH_Power_Map_Rev1p2, doc: 640982

BUG=b:289854108
TEST=Able to boot google/ovis with power limit being overridden as
appropriate to 28W.

Change-Id: I312c70720fd89261c53d5bd4f45236e829d6c790
Signed-off-by: Subrata Banik <subratabanik@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76229
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Sumeet R Pawnikar <sumeet.r.pawnikar@intel.com>
2023-07-05 10:35:34 +00:00
Kapil Porwal 8c551cbe72 mb/google/rex: Temporarily disable the crashlog
Currently, boards with ES2 silicon are unable to boot with crashlog
enabled because crashlog driver is unable to handle invalid data.

Temporarily disable the crashlog to unblock development until the issue
is fixed.

BUG=b:289749310
TEST=Able to boot to the OS on Screebo

Signed-off-by: Kapil Porwal <kapilporwal@google.com>
Change-Id: Ic63cf9cf5bfa2c92d8f2c5b13df2f23dc118b389
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76231
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Jakub Czapiga <jacz@semihalf.com>
2023-07-05 04:23:14 +00:00
Zhongtian Wu 28d18ade43 mb/google/rex/var/screebo: Update touchscreen I2C timing
Change i2c[0] parameter to meet touchscreen timing.
Thd:dat > 100ns.

BUG=b:287898252
BRANCH=none
TEST=Test success by EE.

Change-Id: I30e7c87d788f7f144276c45e8475af65f1f132ae
Signed-off-by: Zhongtian Wu <wuzhongtian@huaqin.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76190
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Kun Liu <liukun11@huaqin.corp-partner.google.com>
Reviewed-by: Kapil Porwal <kapilporwal@google.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-05 01:55:02 +00:00
Felix Held c32df9aa16 soc/amd/common/block/acpi/ivrs: use IOMMU PCI register definitions
Use IOMMU_CAP_BASE_[LO,HI] instead of magic values.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I7032d9f032a22649951ef1535f39b918eb8bd539
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76223
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Fred Reitberger <reitbergerfred@gmail.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
2023-07-04 17:51:26 +00:00
Felix Held e54e141d6c soc/amd/common/block/iommu: factor out PCI register definitions
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ie155cab1f659e9f7b64cd87ba8a77260056656d8
Reviewed-on: https://review.coreboot.org/c/coreboot/+/76222
Reviewed-by: Fred Reitberger <reitbergerfred@gmail.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-04 17:50:50 +00:00
Sergii Dmytruk 6da62684de util/cbmem: add parsing of TPM logs per specs
CBMEM can contain log in different forms (at most one is present):
 - coreboot-specific format (CBMEM_ID_TPM_CB_LOG exported as
   LB_TAG_TPM_CB_LOG)
 - TPM1.2 format (CBMEM_ID_TCPA_TCG_LOG)
 - TPM2 format (CBMEM_ID_TPM2_TCG_LOG)

The last two follow specifications by Trusted Computing Group, but until
now cbmem couldn't print them.  These formats were added not so long ago
in:
 - commit 4191dbf0c9 ("security/tpm: add TPM log format as per 1.2
   spec")
 - commit 53db677586 ("security/tpm: add TPM log format as per 2.0
   spec")

These changes make cbmem utility check for existence of TPM1.2/TPM2 logs
in CBMEM and add code necessary for parsing and printing of their
entries.

TEST=`cbmem -L` for CONFIG_TPM1=y case
TCPA log:
	Specification: 1.21
	Platform class: PC Client
TCPA log entry 1:
	PCR: 2
	Event type: Action
	Digest: 5622416ea417186aa1ac32b32c527ac09009fb5e
	Event data: FMAP: FMAP

TEST=`cbmem -L` for CONFIG_TPM2=y case
TPM2 log:
	Specification: 2.00
	Platform class: PC Client
TPM2 log entry 1:
	PCR: 2
	Event type: Action
	Digests:
		 SHA256: 68d27f08cb261463a6d004524333ac5db1a3c2166721785a6061327b6538657c
	Event data: FMAP: FMAP

Change-Id: Ib76dc7dec56dd1789a219539a1ac05a958f47a5c
Ticket: https://ticket.coreboot.org/issues/425
Signed-off-by: Krystian Hebel <krystian.hebel@3mdeb.com>
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Signed-off-by: Sergii Dmytruk <sergii.dmytruk@3mdeb.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/68749
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2023-07-04 13:07:13 +00:00