Commit Graph

38609 Commits

Author SHA1 Message Date
Usha P 8f2df280e1 soc/intel/common: Include Alder Lake-N device IDs
Add Alder Lake-N System Agent, PCIE, UFS, IPU and CNVI device IDs.
Document: Alder Lake N Platform EDS Volume 1 (Doc# 645548)

Signed-off-by: Usha P <usha.p@intel.com>
Change-Id: I0a383816f818b794cf1211766c27937b3b8daa31
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61161
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Kangheui Won <khwon@chromium.org>
2022-01-25 16:10:46 +00:00
Lean Sheng Tan 7760fe4645 soc/intel/elkhartlake: Add PSE TSN support
Enable PSE GBE with following changes:
1. Configure PCH GBE related FSP UPD flags
2. Add PSE GBE ACPI devices
3. Refactor PCH GBE FSP-S code and merge it together
   with PSE GBE code

Signed-off-by: Lean Sheng Tan <lean.sheng.tan@intel.com>
Change-Id: If3807ff5a4578be7b2c67064525fa5099950986a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/56633
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
2022-01-25 16:09:56 +00:00
Lean Sheng Tan 5cd7579ee5 soc/intel/elkhartlake: Introduce Intel PSE
The Intel® Programmable Services Engine (Intel® PSE) is a
dedicated offload engine for IoT functions powered by an ARM
Cortex-M7 microcontroller. It provides independent, low-DMIPS
computing and low-speed I/Os for IoT applications, plus
dedicated services for real-time computing and time-sensitive
synchronization.

The PSE hosts new functions, including remote out-of-band
device management, network proxy, embedded controller lite
and sensor hub.

This CL enables the user to provide the base address of the
PSE FW blob which will then be loaded by the FSP-S onto the
ARM controller. PSE FW will do the initialization work of
PSE controller and its peripherals. The loading of PSE FW
should have negligible impact on boot time unless PSE
controller could not locate the PSE FW and FSP will attempt to
redo PSE FW loading and wait for PSE handshake until it times
out. Once PSE controller locate the PSE FW, it will do
initialization concurrently by itself with coreboot booting.

It also adds PSE related FSP-S UPD settings which enable the
setup of peripheral ownership (assigned to the PSE or x86
subsystem) and interrupts. These assignments need to take
place at a given point in the boot process and cannot be
changed later.

To verify if PSE FW is loaded properly, the user could enable
PchPseShellEnabled flag and the log will be printed at PSE UART
2.

For further info please refer to doc #611825 (for HW overview)
and #614110 (for PSE EDS).

Signed-off-by: Lean Sheng Tan <lean.sheng.tan@intel.com>
Change-Id: Ifea08fb82fea18ef66bab04b3ce378e79a0afbf7
Reviewed-on: https://review.coreboot.org/c/coreboot/+/55367
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
2022-01-25 16:09:18 +00:00
Keith Hui 36425312ee mainboard/asus/p8x7x-series: Add new variant P8Z77-M
Constructed out of a mix of autoport results, p8z77-m_pro, and
tool dumps.

Working:

- Core i7-3770K CPU
- SeaBIOS 1.13.0 boot to Linux 5.4.24 and Windows 10 1903
  (all further tests are under these versions)
- USB2 / USB3
- SATA
- Gigabit ethernet
- CPU temp sensors (memtest86+ 5.0.1)
- Hardware monitoring under Linux
- Native and MRC raminit
- PCIe GPU in both "PCIEX16" slots (16x/4x, nVidia Quadro 600)
- Integrated graphics with Intel OpROM and libgfxinit (all ports)
- Serial port
- Windows with libgfxinit framebuffer
- 2ch sound playback, Linux and Windows

Not working:

- PS/2 mouse
- 6ch analog audio out
- PCI POST card in PCI slot

Untested:

- PS/2 keyboard
- Internal USB3 ports
- Digital audio out

Change-Id: If756e791ddce747cb1706414be8e41e83f88922b
Signed-off-by: Keith Hui <buurin@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/38988
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-25 10:27:11 +00:00
Xi Chen f4bb77bd9e soc/mediatek: Save dramc_param header to mrc_cache
Fast-k flow may need to re-init header because mrc_cache doesn't
store header. Storing header together with dparam data is better
for data consistancy.

TEST=fast calibration pass on Corsola
BUG=b:204226005

Signed-off-by: Xi Chen <xixi.chen@mediatek.corp-partner.google.com>
Change-Id: I22982923dce06c9e770aa4f20f3dcd2f33685d84
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61294
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2022-01-25 09:42:29 +00:00
Prashant Malani 20f836bfdf ec/google/chromeec: Add checks before creating Type C device
Check for situations where a Type C device isn't useful and avoid
creating one for those scenarios.

BUG=b:215199976
TEST=Tested on brya; verified that USBC device is created.

Signed-off-by: Prashant Malani <pmalani@chromium.org>
Tested-by: Alyssa Ross <hi@alyssa.is>
Change-Id: I5e1598bd637ec9f50e7bf8dab9e3c757a30b9848
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61262
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-by: Matt DeVillier <matt.devillier@gmail.com>
2022-01-25 03:52:00 +00:00
Felix Held a27d1fa175 soc/amd/sabrina/include/aoac_defs: add additional UARTs
Compared to Cezanne there are 3 more UARTs controllers.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Id98767197a21cb1a61f54fc9b256b10a9506c791
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61082
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:51:33 +00:00
Felix Held 1f0eb6b0db soc/amd/sabrina/include/iomap: update MMIO device mappings
Compared to Cezanne there are 3 more UARTs with DMA controllers.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I3a3d255bb4976a55623f3a161e791e80f1d01c69
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61081
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:51:10 +00:00
Raul E Rangel 9d93b16487 soc/amd/cezanne: Increase PRERAM_CBMEM_CONSOLE_SIZE to 0x2000
Let's increase this to avoid losing any logs.

BUG=b:213828947
TEST=Boot guybrush and no longer see
   *** Pre-CBMEM romstage console overflowed, log truncated!

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I3258145e352af3a75893c7cc96f36eb238c99abb
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61100
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
2022-01-25 03:26:44 +00:00
Felix Held af356d313d soc/amd/sabrina: use correct PCI IDs
Replace the Renoir/Cezanne PCI IDs with the Sabrina ones that were added
in commit 27b02c2eee (include/device/
pci_ids.h: add PCI IDs for AMD Family 17h Model A0h SoC).

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I427df6f8e8c08fb47ae8513b6cf1085d4294e28f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61080
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:19:24 +00:00
Felix Held a8d7c043f6 mb/amd/chausie: add mainboard as copy of mb/amd/majolica
To have the new AMD Sabrina SoC code tested, add the AMD Chausie
mainboard as a copy of Majolica. This patch also changes the name from
Majolica to Chausie, selects the Sabrina SoC instead of the Cezanne SoC
and comments out the APCB_SOURCES since those aren't available in the
3rdparty/blobs repository yet.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ic7b18f7a6ae5b8365234dd1227e0b1f7f37279da
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61079
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:19:15 +00:00
Felix Held 421c7d1a99 soc/amd/common/block/include/psp_efs: update defines for sabrina
Document #55758 Rev. 1.13 says that family 17h models 30h-3Fh and later
use the spi_readmode_f17_mod_30_3f struct element for SPI_MODE_FIELD and
spi_fastspeed_f17_mod_30_3f for SPI_SPEED_FIELD, so also use this for
The AMD Sabrina SoC which is family 17h models A0h-AFh.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I336f9ea4a0defdf34e1af4b6d568cfe46488f75e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61078
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:18:58 +00:00
Felix Held 3c44c6227e soc/amd/sabrina: add new SoC as copy of soc/amd/cezanne
The Cezanne SoC code was initially started as a copy of example/min86
which only provides enough code to make the SoC code build. Then the
different parts of the real SoC support was brought in patch by patch
which also helped cleaning up and untangling the code. Since the Cezanne
SoC code is now in a rather good shape and the Sabrina SoC is similar to
the Cezanne SoC from the coreboot side, the new SoC support is started
with a copy of the Cezanne code and all the needed changes will be
applied on top of that. In order for the build not to fail due to
duplicate files, this patch does not only copy the directory, but also
replaces most instances of the Cezanne name with Sabrina. Since the
needed blobs aren't available in the 3rdparty/amd_blobs repository yet,
the Cezanne blobs are used for now so that the build will succeed. As
soon as the proper blobs will be available in that repository, the code
will be switched over to use them.

As suggested by Nico, I added a "TODO: Check if this is still correct"
comment to the beginning of every copied file and all SOC_AMD_COMMON_*
Kconfig option selects which will be removed after re-verifying that
each file and each selected common code block is still correct for the
new SoC.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I978ddbdbfd70863acac17d98732936ec2be8fe3c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61077
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:18:47 +00:00
Felix Held 6abaccf13d vc/amd/fsp/sabrina: add as a copy of vc/amd/fsp/cezanne
The AMD Sabrina SoC will be using the FSP driver to call into the
corresponding FSP binary to do its part of for the silicon
initialization, so we need an initial set of FSP headers for the AMD
Sabrina SoC code to build. Since the FSP interface for this SoC won't be
too different from the Cezanne FSP interface, we'll start with a copy of
the Cezanne FSP headers and update/replace them as soon as the proper
FSP headers for Sabrina will be available.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ib3bf50598efe60673b81cf99da491866fb5dc121
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61076
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2022-01-25 03:16:52 +00:00
Ivy Jian dd68649fe0 mb/google/brya/var/banshee: Configure TPM I2C BUS
Add I2C bus for banshee in Kconfig

BUG=b:214871796
TEST=emerge-brya coreboot

Signed-off-by: Ivy Jian <ivy_jian@compal.corp-partner.google.com>
Change-Id: I67592051b367d5a5715f8d1253ea0c11d2deb1c1
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61312
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: YH Lin <yueherngl@google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
2022-01-24 21:39:04 +00:00
Ivy Jian 48eb9aa6d2 mb/google/brya/var/banshee: update overridetree
Update override devicetree based on schematics

BUG=b:214871796
TEST=emerge-brya coreboot

Signed-off-by: Ivy Jian <ivy_jian@compal.corp-partner.google.com>
Change-Id: I05b63ebcded2f37dfb0f6c428e1fb993f476006a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61269
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
2022-01-24 21:38:53 +00:00
Tim Wawrzynczak 672e844692 device: constify pciexp_find_extended_cap()
The object pointed to by the struct device * argument is not modified,
therefore it can be made const.

Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Change-Id: I300d2a59eb0513ddd08d4f1d2a3c6eb829e3f836
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61214
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-24 17:28:39 +00:00
Tim Wawrzynczak 1b57537530 mb/google/brya: Alphabetize BOARD_GOOGLE_* in Kconfig.name
Change-Id: I624dd67b6ce9b87a6031b5467eacb9a8d7cda1cd
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61216
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-24 17:27:55 +00:00
Joey Peng 4337349883 mb/google/brya/var/{taeko, taeko4es}: Modify touchpad i2c signal
Modify i2c signal to meet touchpad vendor spec.
Please see issue tracker for more details.

BUG=b:215487482
TEST=emerge-brya coreboot and check measured waveform in spec

Signed-off-by: Joey Peng <joey.peng@lcfc.corp-partner.google.com>
Change-Id: Ib3797d4e232654ada97092d9f2742ca040d0f0e4
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61271
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-24 17:09:07 +00:00
Tim Crawford 83c30a9cf1 mb/system76/lemp10: Remove incorrect SPD address 0x50
The Lemur Pro, with its mixed memory topology, only has a DIMM at
address 0x52.

Change-Id: Iecea8c70c7fd40943d86f8918f8e3b384538b5c3
Fixes: 4dcee4f21d ("mb/system76/lemp10: Add System76 Lemur Pro 10")
Signed-off-by: Tim Crawford <tcrawford@system76.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60779
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jeremy Soller <jeremy@system76.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-24 17:07:03 +00:00
Tim Wawrzynczak b3cd55b224 soc/intel/common/block/pcie/rtd3: Fix PMC IPC method for CPU PCIe RP
When calling get_pcie_rp_pmc_idx(), the following code checked the
return value to see if it was negative or `> CONFIG_MAX_ROOT_PORTS`.
However, the expected return value for CPU PCIe RPs is above
MAX_ROOT_PORTS. Since the static, local function is intended to return
-1 or a valid value, drop the check for `> CONFIG_MAX_ROOT_PORTS`.

Change-Id: I2039273ad246884cd8736a7f0355e621a706a526
Fixes: b6a15a7 ("soc/intel/common/block/pcie/rtd3: Update ACPI Update
ACPI methods for CPU PCIe RPs")
Tested-by: Tim Crawford <tcrawford@system76.com>
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61280
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Tim Crawford <tcrawford@system76.com>
2022-01-24 16:28:12 +00:00
Zheng Bao 6dfa528af9 soc/amd/common: Make the function in cpu.c available in romstage
Change-Id: I909f74853a37a783582471e05071bc3d07e3dcf8
Signed-off-by: Zheng Bao <fishbaozi@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61310
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2022-01-24 15:50:47 +00:00
Zheng Bao 0d7eaba0d6 mb/google/guybrush: Change DDI settings for guybrush variants
Like the variant function to change DXIO settings, add a similar weak
function to modify the DDI settings.

Currently we follow the old way. Later we will find out a better way
to avoid using weak function.

Change-Id: I9898d717bc3025ea1ddc3b0db41325083324ed57
Signed-off-by: Zheng Bao <fishbaozi@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61140
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Chris Wang <chris.wang@amd.corp-partner.google.com>
2022-01-24 15:50:30 +00:00
Xi Chen 426ea9670f soc/mediatek: Extract dramc_param_header to a common header
To be shared with different SOCs, move the dramc_param_header struct
as well DRAMC_PARAM_FLAG and DRAMC_PARAM_CONFIG enums to a common
header file dramc_param_common.h.

TEST=fast calibration pass
BUG=b:204226005

Signed-off-by: Xi Chen <xixi.chen@mediatek.corp-partner.google.com>
Change-Id: I087971799803e47e34c30063b2b0bd0cfc5795ac
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61132
Reviewed-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-24 01:54:28 +00:00
Paul Menzel 63b53561e1 Makefile.inc: Add `-fno-pie` to `ADAFLAGS_common`
Building libgfxinit with Debian’s toolchain – latest test with *gnat-11*
11.2.0-13 from Debian sid/unstable – the build fails with the error
below.

    E: Invalid reloc type: 10
    E: Unable to create rmodule from 'build/cbfs/fallback/ramstage.debug'.

Debian’s toolchain is built without enabling PIE by default.

So, explicitly pass `-fno-pie` to `ADAFLAGS_common` to be independent
from how the toolchain was built.

TEST=*gnat* 11.2.0-13 successfully. builds
     purism/librem_cnl/variants/librem_mini with libgfxint.

     With the coreboot toolchain `make BUILD_TIMELESS=1` produces the
     same `build/coreboot.rom` for `BOARD_PURISM_LIBREM_MINI_V2=y` on
     top of commit 50251400d2 (sb/intel/common/firmware: Reword
     me_cleaner warning) with and without the change.
Change-Id: I6661937906d95c130c6099f598d61b21e958fd85
Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/43759
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2022-01-23 18:55:16 +00:00
Raul E Rangel 86302a806c soc/amd/{common,cezanne,picasso}: Add PRE_X86_CBMEM_CONSOLE_SIZE
This change splits the size of the console transfer region and size of
the bootblock/romstage Pre-RAM console region. This allows having a
larger Pre-RAM console while not impacting the size of the PSP verstage
console.

Instead of directly using the PRE_X86_CBMEM_CONSOLE_SIZE symbol in
`setup_cbmem_console`, I chose to use the offsets provided in the
transfer buffer. It would be nice to eventually do this for all the
fields in the transfer buffer.

BUG=b:213828947
TEST=Boot guybrush and verify verstage logs are no longer truncated

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I8b8cc46600192a7db00f5c1f24c3c8304c4db31d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61189
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
2022-01-23 16:42:48 +00:00
Raul E Rangel 1e1aa0ca4d lib/cbmem_console: Add cbmemc_copy_in function
When running in verstage before bootblock, the PSP (ARM co-processor) is
running with limited SRAM. It needs to stash the verstage console data
internally until DRAM is brought up. Once DRAM is brought up the data is
stashed in a "transfer buffer" region. In the current design, we are
using the same region for the transfer buffer and the
preram_cbmem_console region. This has the following downsides:

1) The pre-x86 buffer needs to be large enough to hold all the
   verstage, bootblock and romstage console logs.
2) On AMD platforms, the PSP verstage is signed. Changing the size of
   preram_cbmem_console after the fact will result in a mismatch of the
   transfer buffer between verstage and bootblock.

This CL adds a new method that allows SoC specific code to copy the
CBMEM console in the transfer buffer to the active CBMEM console.

BUG=b:213828947
TEST=Boot guybrush and no longer see
   *** Pre-CBMEM romstage console overflowed, log truncated!

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Idc0ab8090db740e0d1b3d21d8968f26471f2e930
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61099
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2022-01-23 16:42:38 +00:00
Jeremy Soller 5be92e6f33 mb/system76/lemp9: Make GPIO for touchpad interrupt level triggered
Fixes commit 6bcaf6f (mb/system76/lemp9: Configure IRQs as level
triggered for HID over I2C), which changed the interrupt configuration
in the device tree but not in the GPIO definitions. Tested on a
System76 Lemur Pro (lemp9), multi-touch I2C-HID was working.

Signed-off-by: Jeremy Soller <jeremy@system76.com>
Change-Id: I7f0559675a65453a1ad071f96049549a2dc21378
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61302
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
2022-01-22 22:27:30 +00:00
Kevin Chiu c067e4a6e5 mb/google/guybrush/var/nipperkin: turn on WLAN ASPM L1ss
BUG=b:198258604
BRANCH=guybrush
TEST=emerge-guybrush coreboot
     WLAN works properly in OS

Change-Id: Ie1f295eaa57af7c2942e1807b3a0c4dcd89cd696
Signed-off-by: Kevin Chiu <kevin.chiu.17802@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60265
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2022-01-22 18:25:44 +00:00
Usha P 36871dbdb7 mb/intel/adlrvp: Add missing CAM1 RST GPIO for ADL-N
Signed-off-by: Usha P <usha.p@intel.com>
Change-Id: I79f2206bee5403c3fb1c999918fbd2177d0d07ab
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61163
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
2022-01-22 02:01:37 +00:00
Sridhar Siricilla 23e2cde597 soc/intel/alderlake: Implement get_soc_cpu_type helper function
The patch implements get_soc_cpu_type() helper function which
determines whether the executing CPU is a small or a big core. This is
the SoC-specific callback that must be implemented for SoCs that select
SOC_INTEL_COMMON_BLOCK_ACPI_CPU_HYBRID. It will be called from
set_cpu_type().

TEST=verified on Brya

Signed-off-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
Change-Id: Icd0d7e8a42c4b20d3e1d34998bca6321509df2d8
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61075
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-22 02:01:04 +00:00
Bora Guvendik 1587324a0d commonlib: Add new "CSME ROM started execution" TS
BUG=b:182575295
TEST=Boot to OS, check cbmem -t

 990:CSME ROM started execution                        0
 944:CSE sent 'Boot Stall Done' to PMC                 80,408
 945:CSE started to handle ICC configuration           80,408 (0)
 946:CSE sent 'Host BIOS Prep Done' to PMC             82,408 (2,000)
 947:CSE received 'CPU Reset Done Ack sent' from PMC   242,408 (160,000)
   0:1st timestamp                                     331,797 (89,389)
  11:start of bootblock                                359,484 (27,686)
  12:end of bootblock                                  377,417 (17,932)

Signed-off-by: Bora Guvendik <bora.guvendik@intel.com>
Change-Id: I9e4ccd0b8c301e4eec1a09ee8919a577ade938ea
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61168
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-21 22:43:30 +00:00
Bora Guvendik bf73c498d4 timestamp: Allow timestamp_add to accept a negative number
Change timestamp_add to accept negative values for events that took
place before coreboot started executing.

TEST=Boot to OS, check cbmem -t

Signed-off-by: Bora Guvendik <bora.guvendik@intel.com>
Change-Id: I90afc13a8e92693d86e3358f05e0a0cb7cdbca9b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59554
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-21 22:42:19 +00:00
Bora Guvendik f33c9bf79a soc/intel/common/cse: Add support to get CSME timestamps
This command retrieves a set of boot performance timestamps
CSME collected during the platform's last boot flow.

BUG=b:182575295
TEST=Verify CSME timestamps after S3 and boot.

Signed-off-by: Bora Guvendik <bora.guvendik@intel.com>
Change-Id: Ic6f7962c49b38d458680d51ee1cd709805f73b66
Reviewed-on: https://review.coreboot.org/c/coreboot/+/58993
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-21 22:41:57 +00:00
Raul Rangel 03b1d3ef48 Revert "lib/cbmem_console: Move copy_console_buffer up in the file"
This reverts commit 6a3bdf9aa5.

Reason for revert: Oops, I thought I abandoned this. It's been replaced by https://review.coreboot.org/c/coreboot/+/61099/3

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Id18e8e69481bdd78fdd70116940ea435922a9e77
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60853
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Rob Barnes <robbarnes@google.com>
2022-01-21 20:45:22 +00:00
Tim Crawford c7018cc009 mb/system76/*: Enable measured boot
Tested by checking PCR-2 data is recorded in cbmem log.

Change-Id: I70cb9a93de44e75f3a3ed24979c243fccea1213d
Signed-off-by: Tim Crawford <tcrawford@system76.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59963
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jeremy Soller <jeremy@system76.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-21 18:19:08 +00:00
Lean Sheng Tan 203e6c2ed3 mb/prodrive/atlas: Configure GPIO as per Atlas board
Update GPIO settings as per schematics v3.

Signed-off-by: Lean Sheng Tan <sheng.tan@9elements.com>
Change-Id: I685d0b7274e3a6e707fec37d051f4818860169ed
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61116
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-21 17:25:45 +00:00
Tim Crawford 5fe3032e06 mb/system76/gaze15: Set _UID for touchpad devices
The _UID must be unique as these devices use the same _HID. Fixes BSOD
when booting Windows 10.

Change-Id: I67fda892a496dc9e5a6fa5e133ff0b35cde8fce7
Signed-off-by: Tim Crawford <tcrawford@system76.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61210
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jeremy Soller <jeremy@system76.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-21 17:25:28 +00:00
Scott Chao e24b006ee4 mb/google/brya/var/gimble{4es}: Decrease touchscreen T3 timing to 200ms
We set T3 as 300ms to meet Elan's spec, but the resume/suspend times
are greater than 500ms, which is the spec for Chromebooks.
The actual kernel timing has been measured, and given the ACPI delay
after deasserting reset in addition to the delay until the kernel
driver accesses the device, delaying only 200ms in the ACPI method is
also sufficient to meet the 300ms requirement.

BUG=b:210772498
BRANCH=none
TEST=build and test touchscreen function on DUT.
TEST=suspend, wake DUT and check touchscreen function.

Signed-off-by: Scott Chao <scott_chao@wistron.corp-partner.google.com>
Change-Id: I4bb4eda09686cb59b6e19c741aa2b78d84332d2a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60270
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
2022-01-21 16:29:13 +00:00
Subrata Banik 25387927c0 soc/intel/common/gpio: Add PCH `Pad Configuration Lock` options
This patch provides the possible options for PCH to allow `Pad
Configuration Lock`.

`SOC_INTEL_COMMON_BLOCK_GPIO_LOCK_USING_SBI` config is for Tiger Lake
Point (TGP) and Alder Lake Point (ADP) PCH.

BUG=b:211573253, b:211950520
TEST=None

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I7cf35893ab613b154a1073060081a09e561ffe56
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60964
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Maulik V Vaghela <maulik.v.vaghela@intel.com>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
2022-01-21 16:10:46 +00:00
Subrata Banik 6a4f5739c8 soc/intel/common/gpio: Use const variable to get gpio bitmask
This patch introduces a `const bit_mask` variable to hold the gpio
PAD mask value prior to sending the lock configuration command using
the sideband interface.

Additionally, this patch fixes the PAD lock overridden issue as below:

Without this code change every consecutive PAD lock operation resets
other bits in that register as below:

After Locking pad 2 , pcr_read=0x4
After Locking pad 3 , pcr_read=0x8
After Locking pad 4 , pcr_read=0x10
After Locking pad 5 , pcr_read=0x20
After Locking pad 6 , pcr_read=0x40
After Locking pad 7 , pcr_read=0x80
After Locking pad 8 , pcr_read=0x100

With this code change all previous lock bits are getting preserved as
below:

After Locking pad 2 , pcr_read=0x4
After Locking pad 3 , pcr_read=0xc
After Locking pad 4 , pcr_read=0x1c
After Locking pad 5 , pcr_read=0x3c
After Locking pad 6 , pcr_read=0x7c
After Locking pad 7 , pcr_read=0xfc
After Locking pad 8 , pcr_read=0x1fc

BUG=b:211573253, b:211950520

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I342a666aa2d34bcc8ba33460396d1248f0c0f89f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60999
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-by: Maulik V Vaghela <maulik.v.vaghela@intel.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-21 16:08:13 +00:00
Curtis Chen 38fcf40330 soc/intel/alderlake: Add ADL-P 2+8+2 (28W) VR config
ADL-P 2+8+2 (28W) would have a match PD to ADL-P 4+8+2 (28W). Group them
into the same group core "ADL_P_282_482_28W_CORE".

BUG=b:211365920
TEST=Build and check fsp log to confirm the settings are set properly.

Signed-off-by: Curtis Chen <curtis.chen@intel.com>
Change-Id: I3f92c0f5d717dd33ac478fbaa883f3e972e7a7de
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61196
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-21 16:06:26 +00:00
Jim Lai 77426ffa6c mb/google/brya/var/kano: Prevent camera LED blinking during boot
Camera LED blinks as sensor is being probed during kernel boot,
which misleads user to belive camera has been turned on.

Configure _DSC to ACPI_DEVICE_SLEEP_D3_COLD so that driver skips
initial probe during kernel boot and prevent privacy LED blink.

BUG=b:214155527
TEST=Build and boot Kano to OS. Verify entries in SSDT and monitor LED
during boot.

Signed-off-by: Jim Lai <jim.lai@intel.com>
Change-Id: I92f1e88d0fcce49660a95d4402c8c4161e320168
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61109
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-21 16:06:11 +00:00
Tony Huang dc0eb656eb mb/google/puff/var/dooly: Add fw_config probe for ALC5682-VD/ALC5682-VS
ALC5682-VD/ALC5682-VS use different kernel driver by different hid name.
Update hid name depending on the AUDIO_CODEC_SOURCE field of fw_config.

ALC5682-VD: _HID = "10EC5682"
ALC5682I-VS: _HID = "RTL5682"

BUG=b:210501484
BRANCH=puff
TEST=build

Change-Id: I84bc378d6b00828366309be7dbf56a61702a14da
Signed-off-by: Tony Huang <tony-huang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61191
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sam McNally <sammc@google.com>
2022-01-21 16:04:44 +00:00
Raul E Rangel 6a3bdf9aa5 lib/cbmem_console: Move copy_console_buffer up in the file
This will make the method available earlier. This is needed for the next
CL.

BUG=b:213828947
TEST=Build guybrush

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Iee911a2debcfbf4309d2e866401b74f2a6c18feb
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61188
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2022-01-21 16:04:29 +00:00
Subrata Banik 6fb126773f soc/intel/ehl: Replace dt `HeciEnabled` by `HECI1 disable` config
The only option to make HECI1 function disable on Elkhart Lake SoC
platform is using SBI under SMM mode.

List of changes:
1. Drop `HeciEnabled` from dt and dt chip configuration.
2. Replace all logic that disables HECI1 based on the `HeciEnabled`
chip config with `DISABLE_HECI1_AT_PRE_BOOT` config.

Mainboards that choose to make HECI1 enable during boot don't override
`heci1 disable` config.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I76c625e6221fdef1343599e7dbc7739caa91bf98
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60727
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sheng Lean Tan <sheng.tan@9elements.com>
2022-01-21 16:02:34 +00:00
Subrata Banik cef6770a0b soc/intel/icl: Rework on HECI1 disable configs
The only option to make HECI1 function disable on Ice Lake SoC
platform is using SBI under SMM mode. Hence, this patch makes
DISABLE_HECI1_AT_PRE_BOOT=y default and selects
`HECI_DISABLE_USING_SMM` config for Ice Lake.

Also, drop `HeciEnabled` from chip configuration and guard
heci_disable() using DISABLE_HECI1_AT_PRE_BOOT config.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: If4155e5c7eeb019f7dce59acd5b82720baddcb43
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60732
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-21 16:01:54 +00:00
Felix Held 0ddb47048d soc/amd/picasso/bootblock: drop unused includes
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I837e1f8727adefb9227ac7df2ff715245957be2c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61258
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-20 22:29:01 +00:00
Felix Held 21bc2ca5d5 soc/amd/cezanne,picasso: factor out common early non-car cache setup
This implementation is the same for all SoC that select
SOC_AMD_COMMON_BLOCK_NONCAR, so factor it out to the common AMD non-CAR
CPU support code folder.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I53528f0bb75e9d945740ad5065c75e7de7b5878f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61257
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-20 22:28:50 +00:00
Felix Held cf4bba82cb soc/amd/cezanne/include/espi.h: add missing include guards
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I393feab8550a7124ab2982ff3d256e3491d27b4b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61213
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2022-01-20 22:28:16 +00:00
Raul E Rangel 3b589c8148 soc/amd/common/vboot: Verify the size of the transfer buffer
This will verify that signed verstage binaries and the bootblock code
executing agree on the transfer buffer struct size.

BUG=b:213828947
TEST=Boot guybrush to OS

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I597e38fe0a37416ffd3bc01fd974fa8f6610a88c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61187
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
2022-01-20 18:06:48 +00:00
Ivy Jian 3625a12625 mb/google/brya/var/banshee: update gpio settings
Configure GPIOs according to schematics

BUG=b:214871796
TEST=emerge-brya coreboot

Signed-off-by: Ivy Jian <ivy_jian@compal.corp-partner.google.com>
Change-Id: Id6862ff442310953b4749cef7880814f3c3f6d60
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61201
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
2022-01-20 16:27:09 +00:00
Eric Lai 85f691ab8d mb/google/brya/var/banshee: Add SODIMM support
Banshee will use SODIMM. Add memory.c to override baseboard.

BUG=b:208910227
BRANCH=None
TEST=util/abuild/abuild -p none -t google/brya -x -a

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: I4d2fe986b786b3553b67910b589fce12647ee69a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61192
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-20 16:25:03 +00:00
Eric Lai 47486b92ce mb/google/brya: Add MEMORY_SODIMM and MEMORY_SOLDERDOWN config
MEMORY_SOLDERDOWN puts SPD in cbfs and read part number from CBI.
MEMORY_SODIMM puts SPD cache in FMAP.

BUG=b:208910227
BRANCH=None
TEST=util/abuild/abuild -p none -t google/brya -x -a

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: Idab48293fb5b584ecb4c8f270d2c376456954553
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61193
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-20 16:21:56 +00:00
Ivy Jian 1c5cc56acc mb/google/brya: Create banshee variant
Create the banshee variant of the brya0 reference board by copying
the template files to a new directory named for the variant.

(Auto-Generated by create_coreboot_variant.sh version 4.5.0).

BUG=b:214871796
BRANCH=None
TEST=util/abuild/abuild -p none -t google/brya -x -a
make sure the build includes GOOGLE_BANSHEE

Signed-off-by: Ivy Jian <ivy_jian@compal.corp-partner.google.com>
Change-Id: Ib4f943a109f945204a9b0a8de9b99580bf01c87e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61176
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
2022-01-20 16:21:32 +00:00
Anil Kumar 8a4a89fdcb efi_datatype: Add typedef for EFI_PHYSICAL_ADDRESS
Signed-off-by: Anil Kumar <anil.kumar.k@intel.com>
Change-Id: Ie09e337ee1790a06689681fca087edcfd89d215f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60778
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-20 04:54:32 +00:00
Sridahr Siricilla cd1cd8d117 soc/intel/alderlake: Add method to determine the cpu type
set_cpu_type(): It determines the CPU type (big or small) that
is executing the function, and marks the global_cpu_type's array slot
which is corresponds to the executing CPU's index if the CPU type is
big core.

get_cpu_index(): It determines the index from LAPIC Ids. This is
required to expose CPPC3 package in ascending order of CPUs' LAPIC ids.
So, the function returns CPU's position from the ascending order list
of LAPIC ids.

TEST=Tested CPU index calculation, core type determination on Brya

Signed-off-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
Change-Id: If4ceb24d9bb1e808750bf618c29b2b9ea6d4191b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59360
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-19 21:01:13 +00:00
Kevin Chang cdd0252028 mb/google/brya/var/{taeko, taeko4es}: Add gpio.c in romstage
Add file gpio.c in romstage.

BUG=b:213828931
TEST=Build FW and system can power on normally.

Signed-off-by: Kevin Chang <kevin.chang@lcfc.corp-partner.google.com>
Change-Id: Ie868fe7ada9deb8918d6c7ba538332cbe539ee44
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61173
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: YH Lin <yueherngl@google.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-19 19:29:59 +00:00
Kyösti Mälkki 4ac35707d9 arch/riscv: Fix some SMP related headers
Change-Id: I58419450dbe34741b4f5b4920f435fdb91e9df22
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61143
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2022-01-19 19:29:42 +00:00
Elyes HAOUAS 0767da9fc9 src: Remove unused <stdbool>
Change-Id: I8567a567d979bcc0c1c710f6f231d7ecdc82b126
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61058
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-19 15:15:50 +00:00
Subrata Banik 56ab8e2aae soc/intel/common/cpu: Use SoC overrides to get CPU privilege level
This patch implements a SoC overrides to check CPU privilege level
as the MSR is not consistent across platforms.

For example: On APL/GLK/DNV, it's MSR 0x120 and CNL onwards it's MSR
0x151.

BUG=b:211573253, b:211950520

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I515f0a3548bc5d6250e30f963d46f28f3c1b90b3
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60900
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-19 09:57:47 +00:00
Subrata Banik 6ac5dc2ca6 soc/intel/alderlake: Rework the GPIO PAD Pin numbers
This patch creates a `relative increment by 1` macro to let SoC
gpio pad configuration to be more flexible while adding support
for newer PCH SoC.

With this changes adding GPIO controller support for PCH-N would
become really simple without too much of code duplication.

For example: ADL-N has added `GPP_I` pins into community 1 hence,
the additional code for `PCH-N` whould appear incremetal to ADL-P.

> #define GPP_B			0x0
> #define GPP_T			INC(GPP_B)
> #define GPP_A			INC(GPP_T)
> #define GPP_R			INC(GPP_A)
> #define GPD			INC(GPP_R)
> #define GPP_S			INC(GPD)
> if CONFIG(SOC_INTEL_ALDERLAKE_PCH_N)
> #define GPP_I			INC(GPP_S)
> #define GPP_H			INC(GPP_I)
> #else
> #define GPP_H			INC(GPP_S)
> #endif
> #define GPP_D			INC(GPP_H)

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: Ie3b2183381b877da0a6e5a27f5176f0e21e0c9fd
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61165
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
2022-01-19 09:57:13 +00:00
Kevin Chiu a727d54536 mb/google/cherry: add configuration for dojo
BUG=b:211528578
TEST=emerge-cherry coreboot

Signed-off-by: Kevin Chiu <kevin.chiu.17802@gmail.com>
Change-Id: I3bd9803b4e47882df9fe351229478e4cb1630363
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60313
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2022-01-19 05:52:16 +00:00
Seunghwan Kim 58b2d86bb9 mb/google/dedede/var/bugzzy: Add SAR sensor
Present the Semtech SX9360 SAR sensor that protects the LTE antenna.
The sensor is connected to i2c bus I2C1.

BUG=b:194318328
BRANCH=dedede
TEST=emerge-dedede coreboot

Signed-off-by: Seunghwan Kim <sh_.kim@samsung.corp-partner.google.com>
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I9feef9d132c60738bafb22ceb7d3468c798fab9b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59609
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-19 03:12:10 +00:00
Seunghwan Kim 14a1c2778f driver/i2c: Add sx9360 driver
Add driver for setting up Semtech sx9360 SAR sensor.
The driver is based on sx9310.c. The core of the driver is the same, but
the bindings are slightly different.

Registers are documented in the kernel tree:
Documentation/devicetree/bindings/iio/proximity/semtech,sx9360.yaml
[https://patchwork.kernel.org/project/linux-iio/patch/20211213024057.3824985-4-gwendal@chromium.org/]

Signed-off-by: Seunghwan Kim <sh_.kim@samsung.corp-partner.google.com>
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I0a912f184e6f3501f894cca24c0d71a2c3087516
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59608
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-19 03:11:57 +00:00
Raul E Rangel b1a0fcefe4 soc/amd/{picasso,cezanne}: Enable CBMEM_PRINT_PRE_BOOTBLOCK_CONTENTS
This will help debugging verstage failures.

BUG=b:213828947
TEST=Boot guybrush and verify verstage logs are printed before bootblock
messages.

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: Ia60991b3e81c19c24ceb69193840dde873ef3346
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61013
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2022-01-18 17:33:17 +00:00
Krishna Prasad Bhat ba9183245f mb/intel/adlrvp: Add wake events for AC connect/disconnect
Enable S3/S0ix wake events for AC connect/disconnect on Alder Lake RVP.

BUG=None
BRANCH=None
TEST=Verify board wakes from S0ix on AC connect/disconnect.

Change-Id: Iaf92821fd69a59624e58cb8af3896e2b6998723f
Signed-off-by: Krishna Prasad Bhat <krishna.p.bhat.d@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60897
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-18 16:18:12 +00:00
Krishna Prasad Bhat dbe92ead87 soc/intel/alderlake: Add eMMC device into chipset.cb
Add eMMC device into chipset.cb and keep it `off` by default.
eMMC device is applicable only for Alder Lake N SOC.

Change-Id: I2bc38ee5814688409feb7e4531c1daa5b54953c0
Signed-off-by: Krishna Prasad Bhat <krishna.p.bhat.d@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61065
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Kangheui Won <khwon@chromium.org>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
2022-01-18 16:15:26 +00:00
Krishna Prasad Bhat eed82d181b soc/intel/common: Add Alder Lake N eMMC device ID
Add eMMC device ID for Alder Lake N SOC.
Reference: Alder Lake N Platform EDS Volume 1 (Doc# 645548)

Change-Id: Id35ec2d508bec8ff7d6f1c5fbfaf209d42b25c72
Signed-off-by: Krishna Prasad Bhat <krishna.p.bhat.d@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61124
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
2022-01-18 16:15:06 +00:00
Krishna Prasad Bhat 9a14fab340 mb/intel/adlrvp_n: Configure EC in RW GPIO
EC_IN_RW signal from EC GPIO is connected to GPIO E7 of SOC. This GPIO
can be used to check EC status trusted (LOW: in RO) or untrusted (HIGH:
in RW).

BRANCH=None
BUG=None
TEST=Issue manual recovery and confirm DUT is entering recovery mode.

Change-Id: Ib8b6be9fcda24bd2bb479b5b6c01f24a6e9c7b1f
Signed-off-by: Krishna Prasad Bhat <krishna.p.bhat.d@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60896
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Rizwan Qureshi <rizwan.qureshi@intel.com>
2022-01-18 16:14:47 +00:00
Sridhar Siricilla 0fd734046a src/include/acpi: Move CPPC_PACKAGE_NAME macro definition
The patch moves the CPPC_PACKAGE_NAME macro definition from file
acpi/acpigen.c to include/acpi/acpigen.h file since the
CPPC_PACKAGE_NAME method will get called from cpu/intel/common
in a later patch.

TEST=Built the code for Brya

Signed-off-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
Change-Id: Ic547445cdbe2b1a3efe44390bd127f577386e7fc
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59358
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-18 16:13:28 +00:00
Alan Huang db8afc70ba mb/google/brya/var/brask: Turn on I2C1 for TPM
The latest schematics changes the TPM I2C from I2C3 to I2C1. This patch
turns on I2C1 and turns off I2C3.

BUG=b:211886429
TEST=Test if proto 1 can boot into Chrome OS successfully.

Signed-off-by: Alan Huang <alan-huang@quanta.corp-partner.google.com>
Change-Id: I0e94c900b48adf10880aae2abb47e08d1bd9e19b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61135
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Zhuohao Lee <zhuohao@google.com>
2022-01-18 16:13:10 +00:00
Kane Chen 415eadb90b soc/intel/{adl,common}: Support alderlake host device id 0x4619
Host device id 0x4619 is missed in few coreboot tables so that
coreboot can't recognize and config it properly.

Document Number: 690222
BUG🅱️214665785, b:214680767

Change-Id: I95908bdc0a736bafedb328dda2a00b5473de3d88
Signed-off-by: Kane Chen <kane.chen@intel.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61134
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-18 04:35:06 +00:00
Angel Pons 50251400d2 sb/intel/common/firmware: Reword me_cleaner warning
That vendor firmware still works after applying `me_cleaner` doesn't
mean that coreboot will also work with the same broken ME firmware.
Instead, one should first test coreboot with the original, unmodified ME
firmware to make sure coreboot works properly, and only then consider
using `me_cleaner` with coreboot. Otherwise, one would end up with a
non-booting or otherwise misbehaving system when trying to use coreboot
and `me_cleaner` without having tested coreboot with the original ME
firmware beforehand, which is hard to diagnose as the problem may only
happen when the ME isn't running normally.

Change-Id: I1626d747a99969faf7db37c10cf7d87e3977744a
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60942
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2022-01-17 17:14:20 +00:00
Tim Wawrzynczak 3e95cadacc mb/google/auron: Remove addition of EC firmware to build
In https://crrev.com/c/3069716, the samus EC firmware was removed from
the `main` branch, therefore in order to update the `chromeec` 3rdparty
submodule, the automatic build and inclusion of samus EC firmware into
coreboot's `master` branch has to be dropped as well.

Change-Id: I6fcdd3b7925b6ec33ba48892ed750c29bb60634c
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61118
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Bora Guvendik <bora.guvendik@intel.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-17 15:55:02 +00:00
Rob Barnes 5a8b9c94a6 cr50: Increase cr50 i2c probe timeout
Turns out 150ms isn't enough in the worst reset conditions. On guybrush
the TPM is reset in S0i3 and the CR50 is allowed to hibernate. The CR50
is woken up and initialized early during S0i3 resume. Occasionally the
CR50 isn't ready before the probe times out.

BUG=b:213828947
BRANCH=None
TEST=suspend_stress_test -c 1000

Change-Id: Ifda438080cf1ad2796c7061223a6a97b8e6e9987
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61104
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Reviewed-by: Keith Short <keithshort@chromium.org>
2022-01-17 15:54:03 +00:00
Anil Kumar 57309d362c drivers/intel/fsp2_0: Add FSP 2.3 support
FSP 2.3 specification introduces following changes:

1. FSP_INFO_HEADER changes
   Updated SpecVersion from 0x22 to 0x23
   Updated HeaderRevision from 5 to 6
   Added ExtendedImageRevision
   FSP_INFO_HEADER length changed to 0x50

2. Added FSP_NON_VOLATILE_STORAGE_HOB2

Following changes are implemented in the patch to support FSP 2.3:

- Add Kconfig option
- Update FSP build binary version info based on ExtendedImageRevision
  field in header
- New NV HOB related changes will be pushed as part of another patch

Signed-off-by: Anil Kumar <anil.kumar.k@intel.com>
Change-Id: Ica1bd004286c785aa8a431f39d8efc69982874c1
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59324
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Werner Zeh <werner.zeh@siemens.com>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-17 15:53:28 +00:00
Tracy Wu ec877d633d mb/google/brya/variants/*: Add cpu pcie rp flags
Along with commit f94405219c (soc/intel/alderlake: Hook up FSP-S CPU
PCIe UPDs), we need to set cpu pcie rp flags in devicetree now.

This CL is to add proper cpu pcie flags (PCIE_RP_LTR and PCIE_RP_AER) in
all intel projects or system will be blocked at PKGC2R with root port
LTR not enable.

BUG=b:214009181
TEST=Build and DUT (Kano) can enter deeper PKGC state normally.

Signed-off-by: Tracy Wu <tracy.wu@intel.corp-partner.google.com>
Change-Id: I0d8721bf1454448b7fc14655f0e4513001469a18
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61073
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-17 15:52:33 +00:00
Kevin Chang c89be7ae42 mb/google/brya/var/taeko4es: Enable Bayhub LV2 driver
Some SKUs of google/taeko4es have a Bayhub LV2 card reader chip,
therefore enable the corresponding driver for the mainboard.

BUG=b:204343849
TEST=Build FW and checking SD card reader register is correct.

Signed-off-by: Kevin Chang <kevin.chang@lcfc.corp-partner.google.com>
Change-Id: I3d2ea3db9df38e7b0cac4c32e1fca579ff43e5bf
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61115
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-17 15:51:42 +00:00
Seunghwan Kim 9341920453 mb/google/dedede/var/bugzzy: Set core display clock to 172.8 MHz
When using the default initial core display clock frequency (648MHz),
Jasper Lake board might have a rare stability issue where the startup
of Chrome OS in secure mode may hang during re-initializing display in
kernel graphic driver.

Bugzzy didn't show this problem so far, but Intel recommends slowing
the initial core display clock frequency down to 172.8 MHz to prevent
this potential problem.

Depend on CL: https://review.coreboot.org/c/coreboot/+/60009
The CdClock=0xff is set in dedede baseboard, and we overwrite it as 0x0
(172.8 MHz) for bugzzy.

BUG=None
BRANCH=dedede
TEST=Build firmware and check the DUTs can boot up in secure mode well.

Change-Id: I592b2d7c814881074bd2fef9906f2450326c1fcd
Signed-off-by: Seunghwan Kim <sh_.kim@samsung.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61022
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2022-01-17 15:51:27 +00:00
Jeff Daly 2a81cab066 pci_ids.h: Make Denverton IDs consistent with other Intel SoCs
Align Denverton PCI ID define names with other Intel SoCs. Also,
update the names in SoC code accordingly.

Signed-off-by: Jeff Daly <jeffd@silicom-usa.com>
Change-Id: Id4b4d971ef8f4b3ec5920209d345edbbcfae4dec
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60879
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-17 15:50:52 +00:00
Subrata Banik 805956bce3 soc/intel/cnl: Use Kconfig to disable HECI1
This patch makes DISABLE_HECI1_AT_PRE_BOOT=y default for Cannon Lake
and ensures disable_heci1() is guarded against this config.

Also, makes dt CSE PCI device `on` by default.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: Idd57d2713fe83de5fb93e399734414ca99977d0c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60725
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2022-01-17 15:49:24 +00:00
Teddy Shih 53c7453ba1 Revert "mb/google/dedede/var/beadrix: Remove SD controller"
This reverts commit bcd7873ea8.

Reason for revert: It makes beadrix can't boot to os without depthcharge change. The depthcharge change related with fw_config and will effect other variants.
================ error log ================
...
Starting depthcharge on Beadrix...
src/vboot/util/flag.c:50 flag_install(): Gpio already set up for flag 5.
===========================================

BUG=b:204882915
BRANCH=None
TEST=Build and boot into OS.

Signed-off-by: Teddy Shih <teddyshih@ami.corp-partner.google.com>
Change-Id: Id5e76fc78a56d30caf9f805a8a430f176a653bbe
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60849
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Raymond Chung <raymondchung@ami.corp-partner.google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Reviewed-by: Henry Sun <henrysun@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-17 15:48:51 +00:00
Teddy Shih 2746649dea mb/google/dedede/var/beadrix: Add memory part and generate DRAM ID
This change adds memory part used by variant beadrix to
mem_part_used.txt and generates DRAM ID allocated to the part.

BUG=b:204882915, b:210123929
BRANCH=None
TEST=Run part_id_gen to generate SPD id

Signed-off-by: Teddy Shih <teddyshih@ami.corp-partner.google.com>
Change-Id: Ibff150bb4e742f32641da661cfca6594d18c52e9
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60242
Reviewed-by: Raymond Chung <raymondchung@ami.corp-partner.google.com>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-17 15:48:34 +00:00
Tony Huang 0f9c7c009f mb/google/brya/var/agah: update gpio override
Configure GPIOs according to schematics

BUG=b:210970640
TEST=emerge-brya coreboot

Change-Id: Icfd1e09761e51aca9c23f3ab340adac7a66a3ada
Signed-off-by: Tony Huang <tony-huang@quanta.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60891
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-17 15:47:16 +00:00
Raul E Rangel 80a7f4e7b6 console: Add Kconfig to dump pre-bootblock cbmem contents
Pre-bootblock stages (i.e., VBOOT_STARTS_BEFORE_BOOTBLOCK) might not
have the ability to log to the UART, so their console messages are
inaccessible until the boot processes gets into the payload or OS.
This makes it difficult to debug verstage.

This feature will dump the pre-bootblock CBMEM console immediately
after the bootblock console is initialized. I chose to do this in
console_init instead of bootblock_soc_init because I wanted to have the
pre-bootblock contents dumped before the coreboot bootblock starting
message is printed.

BUG=b:213828947
TEST=Boot guybrush with PSP verstage and verify verstage logs are dumped
to the UART.

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I363c93ef3ee6c5c303a6a68f88a622e2aa62594c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61012
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-17 15:46:35 +00:00
Raul E Rangel bf993110b3 console/cbmem: Add cbmem_dump_console
This function is similar to cbmem_dump_console_to_uart except it uses
the normally configured consoles. A console_paused flag was added to
prevent the cbmem console from writing to itself.

BUG=b:213828947
TEST=Boot guybrush

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I3fe0f666e2e15c88b4568377923ad447c3ecf27e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61011
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2022-01-17 15:39:16 +00:00
Elyes HAOUAS 2abb826312 src: Remove unused <cbfs.h>
Found using:
diff <(git grep -l '<cbfs.h>' -- src/) <(git grep -l 'cbfs_allocator_t\|cbfs_load\|cbfs_ro_load\|cbfs_type_load\|cbfs_ro_type_load\|cbfs_unverified_area_load\|cbfs_map\|cbfs_ro_map\|cbfs_type_map\|cbfs_ro_type_map\|cbfs_unverified_area_map\|cbfs_alloc\|cbfs_ro_alloc\|cbfs_type_alloc\|cbfs_ro_type_alloc\|cbfs_unverified_area_alloc\|cbfs_cbmem_alloc\|cbfs_ro_cbmem_alloc\|cbfs_type_cbmem_alloc\|cbfs_ro_type_cbmem_alloc\|cbfs_unverified_area_cbmem_alloc\|cbfs_preload\|cbfs_unmap\|cbfs_prog_stage_load\|cbfs_get_size\|cbfs_ro_get_size\|cbfs_get_type\|cbfs_ro_get_type\|cbfs_type\|cbfs_file_exists\|cbfs_ro_file_exists\|mem_pool\|cbfs_cache\|cbfs_boot_device\|cbfs_boot_device_find_mcache\|cbfs_boot_device\|cbfs_get_boot_device\|cbfs_init_boot_device\|cbfs_boot_lookup\|cbfs_alloc\|cbfs_unverified_area_alloc\|cbfs_default_allocator_arg\|cbfs_default_allocator\|cbfs_cbmem_allocator\|cbfs_alloc\|cbfs_ro_alloc\|cbfs_type_alloc\|cbfs_ro_type_alloc\|cbfs_unverified_area_alloc\|cbfs_map\|cbfs_ro_map\|cbfs_type_map\|cbfs_ro_type_map\|cbfs_unverified_area_map\|cbfs_load\|cbfs_type_load\|cbfs_ro_load\|cbfs_ro_type_load\|cbfs_unverified_area_load\|cbfs_cbmem_alloc\|cbfs_ro_cbmem_alloc\|cbfs_type_cbmem_alloc\|cbfs_ro_type_cbmem_alloc\|cbfs_unverified_area_cbmem_alloc\|cbfs_get_size\|cbfs_ro_get_size\|cbfs_get_type\|cbfs_ro_get_type\|cbfs_file_exists\|cbfs_ro_file_exists\|cbfs_mdata\|cbfs_find_attr\|cbfs_file_hash' -- src/)|grep "<"

Change-Id: Ib4dca6da1eb66bbba5b6e94fd623f4fcfc2f0741
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61068
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-17 15:38:54 +00:00
Arthur Heymans 0bb6383f59 drivers/i2c/tpm/Kconfig: Reduce visibility of some configs
I2C bus and address of the TPM are typically fixed on hardware so
there is no need to be able to configure this in menuconfig.

Change-Id: I1b6afa68fe753fb76348e0461209d218b14df7cb
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59802
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-17 13:50:44 +00:00
Arthur Heymans d2e423fc8d oprom/yabel/io.c: Fix building for ENV_X86_64
Unknown if yabel works for X86_64 but now it builds.

Change-Id: Iacdb9fde91a992b5010120f5824383ca4aebdd1a
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59661
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2022-01-17 13:43:34 +00:00
Arthur Heymans 15c9c78057 oprom/realmode/x86.c: Fix building for ENV_X86_64
Not tested on hardware.

Change-Id: I8ce8d56da326aeff5ff9b400ded02d4309372519
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59660
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2022-01-17 13:43:27 +00:00
Subrata Banik e74ebcde38 soc/intel/common/cse: Add helper API for CSE SPI Protection Mode
This patch checks if CSE's spi protection mode is protected or
unprotected. Returns true if CSE's spi protection mode is protected,
otherwise false.

BUG=b:211954778
TEST=Able to build and boot brya with this change. Calling
`cse_is_hfs1_spi_protected()` in coreboot is able to provide
the SPI protection status.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I23f1a1c4b55d8da6e6fd0cf84bef86f49ce80cca
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60403
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: EricR Lai <ericr_lai@compal.corp-partner.google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2022-01-16 13:34:19 +00:00
Subrata Banik a0d9ad322f soc/intel/skl: Replace dt `HeciEnabled` by `HECI1 disable` config
List of changes:

1. Drop `HeciEnabled` from dt and dt chip configuration.
2. Replace all logic that disables HECI1 based on the `HeciEnabled`
chip config with `DISABLE_HECI1_AT_PRE_BOOT` config.
3. Make dt CSE PCI device `on` by default.
4. Mainboards set DISABLE_HECI1_AT_PRE_BOOT=y to make Heci1
function disable at pre-boot instead of the dt policy that uses
`HeciEnabled = 0`.

Mainboards that choose to make HECI1 enable during boot don't override
`heci1 disable` config.

Signed-off-by: Subrata Banik <subratabanik@google.com>
Change-Id: I5c13fe4a78be44403a81c28b1676aecc26c58607
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60722
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-16 13:33:14 +00:00
John Zhao 98ce39dce4 soc/intel/common: Abstract the sideband access
The existing Sideband access is with the PCH P2SB. There will be future
platforms which access the TCSS registers through SBI other than the PCH
P2SB. This change abstracts the SBI with common API.

BUG=b:213574324
TEST=Build platforms coreboot images successfully.

Signed-off-by: John Zhao <john.zhao@intel.com>
Change-Id: Ia6201762fe92801ce6b4ed97d0eac23ac71ccd37
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60978
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2022-01-16 13:20:16 +00:00
John Zhao 0f76a18c3a soc/intel/denverton_ns: Add the Primary to Sideband Bridge definition
This change adds the Primary to Sideband Bridge(B0, D31, F1)
definition for the platform in order to maintain the common block
API build.

BUG=b:213574324
TEST=Build platforms coreboot images successfully.

Signed-off-by: John Zhao <john.zhao@intel.com>
Change-Id: I1c4ddfce6cc6e41b2c63f99990d105b4bbb6f175
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61074
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-16 13:20:06 +00:00
Arthur Heymans ac24a96579 arch/x86/spinlock.h: Support systems with >128 cores
Each time the spinlock is acquired a byte is decreased and then the
sign of the byte is checked. If there are more than 128 cores the sign
check will overflow. An easy fix is to increase the word size of the
spinlock acquiring and releasing.

TEST: See that serialized SMM relocation is still serialized on
systems with >128 cores.

Change-Id: I76afaa60669335090743d99381280e74aa9fb5b1
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60539
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2022-01-15 14:48:46 +00:00
Wisley Chen e565f75221 mb/google/brya/var/redrix{4es}: Add host device event support
Adding this host event to the EC SCI event and wake masks allows
the system to generate an SCI and/or wake when this event happens.

BUG=b:206012072
TEST=build

Signed-off-by: Wisley Chen <wisley.chen@quanta.corp-partner.google.com>
Change-Id: I4f48244a4fca750a9de2ecc20f24786034d45b8a
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61072
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-14 17:56:08 +00:00
Wisley Chen dc6071d2ce mb/google/brya/var/redrix{4es}: Set tcc_offset value to 3
The redrix thermal team has determined that the TCC circuit trip
temperature should be set to 97C, therefore, because the offset
is subtracted from 100C, set the `tcc_offset` register in the
devicetree to 3.

BUG=b:200134784
TEST=build and verified by thermal team

Signed-off-by: Wisley Chen <wisley.chen@quanta.corp-partner.google.com>
Change-Id: Ifb63d63bc741b2a402328f256b43bc83e0a88a9e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61003
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-14 17:54:48 +00:00
Wisley Chen c98df1478b mb/google/brya/var/anahera{4es}: Set tcc_offset value to 3
The anahera thermal team has determined that the TCC circuit trip
temperature should be set to 97C, therefore, because the offset
is subtracted from 100C, set the `tcc_offset` register in the
devicetree to 3.

BUG=b:214088543
TEST=build and verified by thermal team

Signed-off-by: Wisley Chen <wisley.chen@quanta.corp-partner.google.com>
Change-Id: I25b8a3d9e5fe28e9497b735c50a09994092b2243
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61002
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2022-01-14 17:54:27 +00:00
Eric Lai a99355376b mb/google/brya/var/felwinter: Update USB Type-C PLD
After kernel change landed on Chromium tree.
https://lore.kernel.org/r/20210407065555.88110-5-heikki.krogerus@linux.intel.com
USB driver will use PLD to match the Type-C port. PLD needs to start
from 1.

BUG=b:214460183
TEST=boot into OS without kernel panic.

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: I1493e46f8881b2f688f41f32755d4cf5a87e7656
Reviewed-on: https://review.coreboot.org/c/coreboot/+/61108
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Subrata Banik <subratabanik@google.com>
2022-01-14 17:13:45 +00:00