Commit Graph

45159 Commits

Author SHA1 Message Date
Felix Held 09f7303518 soc/amd/common/block/acpimmio/print_reset_status: add missing status bit
Both the Picasso PPR #55570 Rev 3.18 and the Cezanne PPR #56569 Rev 3.03
define bit 9 of the PM_RST_STATUS register as internal Thermal Trip
reset status bit.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ida8b13fe62b16c18fc9924520b83220e73eca624
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60184
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Jason Glenesk <jason.glenesk@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-18 02:06:28 +00:00
Angel Pons f5dfe248ce soc/intel/denverton_ns: Use `popcnt()` helper
Use the `popcnt()` helper instead of manually counting the number of set
bits in the first `CONFIG_MAX_CPUS` bits with a loop. Also, use unsigned
types to store the number of active/total cores.

Change-Id: Iae6b16991fcf07c9ad67d2b737e490212b8deedd
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/58912
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2021-12-17 21:41:39 +00:00
Kevin Chiu 4aaea85044 mb/google/guybrush/var/nipperkin: config eSPI as dedicated alert
Setup eSPI to dedicated alert per the latest schematic changes.
DUT won't hang up at power on boot due to eSPI alert is triggerred
unexpectedly.

BUG=b:199458949,b:203446084
BRANCH=guybrush
TEST=emerge-guybrush coreboot chromeos-bootimage
     test power on/reboot on DUT (6 units) each 10 loops->pass

Change-Id: I55cda7a1af22e555a4f55285cb7e337a69e6c234
Signed-off-by: Kevin Chiu <kevin.chiu@quantatw.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60082
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Rob Barnes <robbarnes@google.com>
2021-12-17 14:44:57 +00:00
Yunlong Jia d3c0fb86be google/trogdor: Enable Parade ps8640 edp bridge for pazquel
BRANCH=none
BUG=b:201478528
TEST=build and boot

Change-Id: I6130ee00a0e6f469142f5416627e38c7b5076071
Signed-off-by: Yunlong Jia <yunlong.jia@ecs.corp-partner.google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60130
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2021-12-17 00:47:34 +00:00
Jakub Czapiga 6df286ee19 MAINTAINERS: Add libpayload unit-tests to TESTS section
Change-Id: I09aca01d9bb2624983e0d62628aef617c10eba9c
Signed-off-by: Jakub Czapiga <jacz@semihalf.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60138
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by:  Felix Singer <felixsinger@posteo.net>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2021-12-16 23:46:23 +00:00
Eric Lai 3ca82e2d78 mb/google/brya/var/felwinter: Add stylus probe for garage
Felwinter has non-stylus sku. Add a FW_CONFIG field to indicate
stylus presence and add a probe statement to the devicetree for the
corresponding device.

BUG=b:208937710
TEST=non-stylus doesn't register garage driver.

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: I06a2c125f2b5a73f9f7c27bf1b20ff8712664809
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60073
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-16 23:46:06 +00:00
Tim Wawrzynczak 39dea9310b Revert "security/vboot: Add NVRAM counter for TPM 2.0"
This reverts commit 7dce190808.

Reason for revert: Unable to boot in factory mode

Change-Id: I1b51010080164c6e28d77a932f77c10006fd4153
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60030
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2021-12-16 20:58:30 +00:00
Zheng Bao 6fff2497b1 amdfwtool: Upgrade "relative address" to four address modes
Address Mode 0: Physical Address, bit 63~56: 0x00
Address Mode 1: Relative Address to entire BIOS image, bit 63~56: 0x40
Address Mode 2: Relative Address to PSP/BIOS directory, bit 63~56: 0x80
Address Mode 3: Relative Address to slot N, bit 63~56: 0xC0

It is the expanding mode for simple relative address mode, for which
address_mode equals 1.

Only mode 2 is added. We need to record current table base address and
calculate the offset. The ctx.current_table is zero outside the
table. When it goes into the function to integrate the table, it
should backup the old value and get current table base. Before it goes
out the function, it should restore the value.

If the table address mode is 2, the address in each entry should be
also add address mode information. If not, the address mode in entry
is meanless.

The old mode 0,1 should be back compatible.

Change-Id: I29a03f4381cd0507e2b2e3b359111e3375a73de1
Signed-off-by: Zheng Bao <fishbaozi@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59308
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2021-12-16 14:35:52 +00:00
Kenneth Chan 8ad94770e2 mb/google/guybrush/var/dewatt: Add audio codec
Add ALC5682I-VD and ALC1019 for dewatt.

BUG=b:208172493
TEST=emerge-guybrush coreboot chromeos-bootimage; Tested with proto build.

Signed-off-by: Kenneth Chan <kenneth.chan@quanta.corp-partner.google.com>
Change-Id: Ie4d21a11377c73b913a8f79a92d5869ea70f4394
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60021
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Rob Barnes <robbarnes@google.com>
2021-12-16 14:18:51 +00:00
Kevin Chiu 2649f5a518 mb/google/brya/var/vell: update overridetree
Init basic override devicetree based on initial schematics

BUG=b:205908918
TEST=emerge-brya coreboot

Change-Id: Ibaa910eb1c5584197907963781258035c668298e
Signed-off-by: Kevin Chiu <Kevin.Chiu@quantatw.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59304
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-16 14:18:21 +00:00
Paul Menzel 1ca8b6e3c3 Documentation/releases: Improve CSME section
1.  Fix typo in *based*
2.  Use official spelling for Alder Lake
3.  Mention *Converged Security*
4.  Capitalize CMOS

Change-Id: I36eac6f017229a3e9261e0eb84371421927e1cae
Fixes: 941239d54d (Documentation/releases: Update 4.16 release notes)
Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60133
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-16 14:17:55 +00:00
Paul Menzel 7f5a1eeb24 Spell *Boot Guard* with a space for official spelling
See for example Intel document *Secure the Network Infrastructure –
Secure Boot Methodologies* [1].

Change all occurrences with the command below:

    $ git grep -l BootGuard | xargs sed -i 's/BootGuard/Boot Guard/g'

[1]: https://builders.intel.com/docs/networkbuilders/secure-the-network-infrastructure-secure-boot-methodologies.pdf

Change-Id: I69fb64b525fb4799bcb9d75624003c0d59b885b5
Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60136
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-16 14:17:36 +00:00
Raul E Rangel 74d2218cc7 lib/cbfs: Disable cbfs_preload in romstage when VBOOT_STARTS_IN_ROMSTAGE
Preloading files before vboot runs and using them after vboot has
finished will result in the wrong files getting used. Disable
cbfs_preload to avoid this behavior.

BUG=b:179699789
TEST=none

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I7698b481a73fb24eecf4c810ff8be8b6826528ca
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59876
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2021-12-15 23:26:06 +00:00
Raul E Rangel d8f07c1f35 rules.h, thread.h, lib/cbfs: Add ENV_STAGE_SUPPORTS_COOP
This change consolidates the COOP rules. Co-op in theory works in all
x86 stages now, but it hasn't been enabled yet.

BUG=b:179699789
TEST=Boot guybrush to OS and verify preloads still work

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
Change-Id: I1197406d1d36391998b08e3076146bb2fff59d00
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59550
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2021-12-15 23:25:32 +00:00
Felix Singer af54d7d0dd mb/google/fizz/Kconfig: Select board-specific options per board
Move board-specific selects out of common configuration and add them to
each board where necessary.

Change-Id: I2b8a9906671b327bec249f3d16cba3ba80a95669
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60064
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 23:24:24 +00:00
Felix Singer a825170966 mb/google/fizz: Move selects from Kconfig.name to Kconfig
Move selects from Kconfig.name to Kconfig so that the configuration is
at one place and not distributed over two files.

Change-Id: I9201b5bcbf53422cefc6027a0d67fcf2201b14a4
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60063
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 23:23:57 +00:00
Felix Singer 6f81c8698e mb/google/fizz: Restore alphabetical order on Kconfig selects
Change-Id: Iaaca82aad3c687939291c051f203b58a9c8cdb70
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60062
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 23:23:33 +00:00
Felix Singer 1329d58a94 mb/google/glados/Kconfig: Select board-specific options per board
Move board-specific selects out of common configuration and add them to
each board where necessary.

Change-Id: I70ab37588a6b08a0cc194469fd2642b3cfefe301
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60061
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 23:23:15 +00:00
Felix Singer a169c74088 mb/google/glados: Move selects from Kconfig.name to Kconfig
Move selects from Kconfig.name to Kconfig so that the configuration is
at one place and not distributed over two files.

Change-Id: Ifccf2b3521d84f6a678872bbccf9bf390c25ce37
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60060
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 23:22:52 +00:00
Krishna Prasad Bhat e3fd52a802 mb/intel/adlrvp_n: Add initial code for adl-n variant board
This patch adds the following list of changes:
1. Create a new devicetree for adlrvp-n and copy contents of adlrvp-p
devictree.
2. Add support for 2 mainboards as ADL-N board with default EC (Windows
SKU) and Chrome EC (Chrome SKU) and copy overridetree contents from
adlrvp-p.
3. Add mainboard Kconfig to Kconfig.name file
4. Handle mainboard names in Kconfig file for ADLRVP N
5. Add config options to pick the adlrvp_n devicetree

Change-Id: I4abf3bf62ec0398ae75e21575a2fab0d44b5c7ad
Signed-off-by: Usha P <usha.p@intel.com>
Signed-off-by: Krishna Prasad Bhat <krishna.p.bhat.d@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59915
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-15 23:20:10 +00:00
Felix Held fc373c7dac soc/amd/common/block/psp: move psp_notify_dram to psp_gen1.c
The MBOX_BIOS_CMD_DRAM_INFO PSP mailbox command is only available on the
first generation of PSP mailbox interface and not on the second
generation. The second generation of the PSP mailbox interface was
introduced with the AMD family 17h SoCs on which the DRAM is already
initialized before the x86 cores are released from reset.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I97b29fdc4a71d6493ec63fa60f580778f026ec0b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60124
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2021-12-15 22:40:08 +00:00
Felix Held 55dce1d55d drivers/spi/spi-generic: document SPI_CNTRLR_DEDUCT_CMD_LEN better
This should make it a bit clearer what the differences between
SPI_CNTRLR_DEDUCT_OPCODE_LEN and SPI_CNTRLR_DEDUCT_CMD_LEN and the
corresponding functionality in spi_crop_chunk are.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I809adebb182fc0866b93372b5b486117176da388
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60122
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:39:21 +00:00
Felix Held e3ae755575 drivers/spi/spi-generic: fix edge case in spi_crop_chunk
In the case of deduct_cmd_len being set and the adjusted cmd_len >=
ctrlr_max, ctrlr_max wasn't being adjusted and still had the value of
ctrlr->max_xfer_size. Handle this edge case (which we should never run
into) by setting ctrlr_max to 0 and printing a warning to the console.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I9941b2947bb0a44dfae8ee69f509795dfb0cb241
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60121
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:39:07 +00:00
Felix Held 856d6bc6d3 soc/amd/common/block/spi/fch_spi_ctrl: improve printk messages
Replace FCH_SC with FCH SPI in the printk messages to make those a bit
clearer and also remove an unneeded line break in another printk call.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I6ff02163e6a48a2cc8b7fe89b15826e154715d29
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60120
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:38:53 +00:00
Felix Held 1105fe8913 soc/amd/common/block/spi/fch_spi_ctrl: handle failure in execute_command
When wait_for_ready returned a timeout, execute_command still ended up
returning success. Fix this be returning a failure in this case.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Id012e74e26065c12d003793322dcdd448df758b0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60119
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:38:31 +00:00
Felix Held a3930dafd4 soc/amd/common/block/spi/fch_spi_ctrl: rework dump_state
Introduce and use enum spi_dump_state_phase to indicate from which phase
of the SPI transfer dump_state gets called to print the relevant debug
information for that phase.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I2f54d4a7eb2f3b9756b77a01533f7c99e8597bfa
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60118
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:38:04 +00:00
Felix Held 6b0f45199c soc/amd/common/include/spi: add Cezanne-specific comment
The Cezanne PPR #56569 Rev 3.03 has one more SPI FIFO bytes defined
compared to the previous generations. It is unclear if adding some
special handling for Cezanne would be worth the effort, since the
current code just doesn't use the last byte which should be safe to do,
since this only affects the maximum number of bytes that can be used for
one SPI transaction. Having another byte to use on Cezanne wouldn't
reduce the number of SPI transactions to write a 256 byte data block.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: Ic730f4fe838f59066120c811833995c132c84c1c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60117
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:37:50 +00:00
Felix Held 601a971545 soc/amd/common/include/spi: fix SPI_FIFO_LAST_BYTE define
The last byte of the SPI FIFO SPI_FIFO_LAST_BYTE is at offset 0xc6 of
the SPI controller's MMIO region for Stoneyridge and Picasso. Both
SPI_FIFO_LAST_BYTE and SPI_FIFO_DEPTH had an off-by-one error that ended
up cancelling out each other, so the resulting value for SPI_FIFO_DEPTH
isn't changed.

TEST=Timeless build results in identical image for Mandolin.

Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I1676be902ccf57e2e9f69d81251b4315866a0628
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60116
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-15 22:37:42 +00:00
Jakub Czapiga 19ad39b7f2 tests/lib/lzma-test: Fix uninitialized array error
Change-Id: I5b10eef3dd82068f97d4d875f3da813a5aca07a7
Signed-off-by: Jakub Czapiga <jacz@semihalf.com>
Reported-by: Paul Fagerburg <pfagerburg@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60112
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-15 17:07:27 +00:00
Rob Barnes a1430c340e mb/google/guybrush: Set TPM to to be kernel power managed.
Set TPM power_managed_mode to TPM_KERNEL_POWER_MANAGED. This will cause
the TPM kernel driver to send a shutdown command before s0i3 entry. This
change depends on S0i3 verstage running and reinitializing the TPM.

BUG=b:200578885
BRANCH=None
TEST=TPM shutdown sent during s0i3 entry on guybrush

Change-Id: I206022cc2a29690186206966c5d45bd55c303248
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60081
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2021-12-15 17:07:14 +00:00
Dtrain Hsu 540951e374 mb/google/dedede/var/madoo: Generate new SPD ID for new memory parts
Add new memory parts in the mem_list_variant.txt and generate the
SPD ID for the parts. The memory parts being added are:
1. Micron MT53E512M32D1NP-046 WT:B
2. Samsung K4U6E3S4AB-MGCL
3. Hynix H54G46CYRBX267

BUG=b:209889645
BRANCH=dedede
TEST=FW_NAME=madoo emerge-dedede coreboot chromeos-bootimage

Signed-off-by: Dtrain Hsu <dtrain_hsu@compal.corp-partner.google.com>
Change-Id: I0b2f447a610a0a857e819ede257ac89cfd817018
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59991
Reviewed-by: Shou-Chieh Hsu <shouchieh@google.com>
Reviewed-by: Henry Sun <henrysun@google.com>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-15 17:06:58 +00:00
Angel Pons bc62891378 Denverton-NS boards: Drop useless `thermal.asl`
The code in these files is meaningless, and can be dropped.

Change-Id: I11571885059e8d5f930f741172c74b25faa09a15
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60103
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by:  Felix Singer <felixsinger@posteo.net>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2021-12-15 15:55:49 +00:00
Casper Chang 0ccb7b2d48 mb/google/brya/var/primus{4es}: Configure Acoustic noise mitigation
- Enable Acoustic noise mitigation
- Set slow slew rate VCCIA and VCCGT to 8

BUG=b:204844399
TEST=USE="project_primus emerge-brya coreboot" and verified
     the setting meets the audible noise specification

Signed-off-by: Casper Chang <casper_chang@wistron.corp-partner.google.com>
Change-Id: I0e0baf78a841278efda912cc5e4e9970329aacf6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60071
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 15:55:31 +00:00
Sean Rhodes 1b66bbaf83 mainboard/starlabs/labtop: Hook up Thunderbolt to CMOS
Hook up Thunderbolt and related settings to CMOS value of `thunderbolt`.
Changes TcssXhciEn, UsbTcPortEn and the relevant PCI devices.

Signed-off-by: Sean Rhodes <sean@starlabs.systems>
Change-Id: Ibadc7464831242ae51982610b410ccf0a6811edd
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59705
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Andy Pont <andy.pont@sdcsystems.com>
2021-12-15 15:55:09 +00:00
Kevin Chiu 5e59f169ec mb/google/guybrush/var/nipperkin: update LPDDR4X DRAM table
add Hynix H54G56CYRBX247 support

BUG=b:210365851
BRANCH=guybrush
TEST=emerge-guybrush coreboot chromeos-bootimage
     power on successfully

Change-Id: I99bed32025d10f62e63ace8f7f23e7cc3a740e93
Signed-off-by: Kevin Chiu <kevin.chiu@quantatw.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60075
Reviewed-by: Rob Barnes <robbarnes@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-15 15:54:30 +00:00
Joey Peng cddded2f58 mb/google/brya/var/taniks: Configure DRIVER_TPM_I2C_BUS
Add I2C bus for taniks in Kconfig

BUG=b:210390520
TEST=emerge-brya coreboot and can boot to OS.

Signed-off-by: Joey Peng <joey.peng@lcfc.corp-partner.google.com>
Change-Id: I9b1719c3140c13f67e7cb0e6a69257774884bd4d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60077
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 15:54:16 +00:00
Joey Peng 44633997d8 mb/google/brya/variant/taniks: Add memory settings
Based on the Taniks's schematic, generate memory settings.
Schematic version is G570_MB_CHROME_1207_1630_ADC.

BUG=b:209531192,b:209553289
TEST=FW_NAME=taniks emerge-brya coreboot chromeos-bootimage

Signed-off-by: Joey Peng <joey.peng@lcfc.corp-partner.google.com>
Change-Id: I0c0794fb94d1f6271de604835ae1d2b20696ee70
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59947
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-15 15:53:53 +00:00
Joey Peng 88efeafa66 mb/google/brya/variants/taniks: Configure GPIOs according to schematics
Add initial gpio configuration for taniks according to schematics
G570_MB_CHROME_1207_1630_ADC. The schematics reserved HPS and FP but
taniks doesn't use them, so set FP and HPS related pins to NC.

BUG=b:209492408, b:209553289
TEST=FW_NAME=taniks emerge-brya coreboot

Signed-off-by: Joey Peng <joey.peng@lcfc.corp-partner.google.com>
Change-Id: Ic5c4ead4ad59137e1764e1226415ab6041c68aab
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59938
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2021-12-15 15:53:33 +00:00
Kyösti Mälkki 3990da0bfe soc/intel/denverton_ns: Fix MRC_RW_CACHE
It is required to set WPD (Write Protect Disable) bit
to make it possible to use MRC_RW_CACHE region with
CACHE_MRC_SETTINGS=y.

Change-Id: Iacab44b00d08c9bdc18bc3bdcb88833634c0b02e
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60091
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-15 12:11:04 +00:00
Kyösti Mälkki fd13fb54ac soc/intel/denverton_ns: Use common SMBus support code
Change-Id: I233d198b894f10fbf0042a5023ae8a9c14136513
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59469
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-15 12:10:22 +00:00
Dmitry Ponamorev ccc27d2cca soc/intel/baytrail,denverton_ns: Call setup_lapic()
A custom board with soc/intel/denverton_ns does not respond to
the keyboard and does not boot from the sata/USB disks.
Last post code 0x7b and the last line that is displayed at log
from SeaBIOS is:
   All threads complete.

The issue is gone when adding setup_lapic() call to configure
EXTINT delivery of i8259 originated interrupts for the LAPIC.
Replicate call from other soc/ and make the call for both BSP
and AP CPUs.

Similar change was done for soc/intel/braswell in
commit b4f57bb3ca.

Signed-off-by: Dmitry Ponamorev <dponamorev@gmail.com>
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Change-Id: Iafbfb733d0be546e0e2fba937fd1d262785aa54d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/57668
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2021-12-15 12:10:02 +00:00
Rex-BC Chen add2e93050 mb/google/corsola: move USB3 HUB reset funtion to bootblock
To save the S3 power, USB3_HUB_RST_L is externally pulled up to a weak
resistor, so we have to reset the hub as early as possible.
Otherwise the USB3 hub may be not usable. Therefore, move USB3 HUB
reset function to bootblock.

BUG=b:210065282
TEST=build pass

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: I92feb2316302fda32478b24c014bcd380d0ac55d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60088
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-15 07:52:34 +00:00
Julius Werner 0fd072d3f2 cbfstool: Clean up remnants of locate action
`cbfstool locate` and the associated -T switch were removed a looong
time ago (2015 in CB:11671). However, getopt and the help text weren't
cleaned up correctly. Fix that.

Signed-off-by: Julius Werner <jwerner@chromium.org>
Change-Id: Ib098278d68df65d348528fbfd2496b5737ca6246
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60085
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-14 21:45:32 +00:00
Julius Werner 772714d3b3 cbfstool: Use converted buffer size for do_cbfs_locate()
The whole point of moving do_cbfs_locate() later (CB:59877) was that it
could use the file size that is actually going to be inserted into CBFS,
rather than the on-disk file size. Unfortunately, after all that work I
forgot to actually make it do that. This patch fixes that.

Since there is no more use case for do_cbfs_locate() having to figure
out the file size on its own, and that generally seems to be a bad idea
(as the original issue shows), also remove that part of it completely
and make the data_size parameter mandatory.

Signed-off-by: Julius Werner <jwerner@chromium.org>
Change-Id: I1af35e8e388f78aae3593c029afcfb4e510d2b8f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60084
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
2021-12-14 21:45:27 +00:00
Felix Singer 58ea2819ba mb/google/glados: Restore alphabetical order on Kconfig selects
Change-Id: I736234b9a960c58193fcf7bc9184c9581c6c953b
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60059
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
2021-12-14 19:56:40 +00:00
Rex-BC Chen ee56998a37 mb/google/corsola: set up open-drain ChromeOS pins
Set open-drain GPIOs for ChromeOS as input and high-z mode.
After applying this patch, we can measure these pins from 1.0V to
correct voltage (1.8V) to prevent wrong judgement of low/high.

Reference document:
MT8186_SoC_Pinmux_V1_1

BUG=b:209342636
TEST=measure pins voltage 1.8V on kingler board

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: Ib55a773bb63404a1b952f7e7645eb7aba6638b00
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60002
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-14 17:06:24 +00:00
Rex-BC Chen ac6070a79f soc/mediatek/mt8186: add tracker dump
Tracker is a debugging tool, and MT8186 only supports AP tracker.
When bus timeout occurs, the system reboots and latches some values
which could be used for debugging.

This function will be triggered only when it encounters the bug
hanging issue.

BUG=b:202871018
TEST=range of registers are dumped as expected.

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: Ie023de2a6f7421a16b2516baa0bf0bf6fff589e2
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59990
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
2021-12-14 17:06:12 +00:00
Zheng Bao da83d2c97f amdfwtool: Use relative address for EFS gen2
The second generation EFS (offset 0x24[0]=0) uses "binary relative"
offsets and not "x86 physical MMIO address" like gen1.

The field additional_info in table header can tell if the absolute or
relative address is used.

Chips like Cezanne can run in both cases, so no problem
comes up so far.

The related change in psp_verstage has been uploaded.
https://review.coreboot.org/c/coreboot/+/58316

The relative mode is the mode 1 of four address modes. The absolute
mode is the mode 0. Later we will implement mode 2. Not sure if mode 3
is needed.

It needs to be simple to work with psp_verstage change to make SOC
Cezanne work quickly. This patch is defacto a subset of
    https://review.coreboot.org/c/coreboot/+/59308
which implements the framework of address mode and covers mode
0,1,2. Some hardcode value like 29 can be removed in 59308.

BUG=b:188754219
Test=Majolica (Cezanne)

Change-Id: I7701c7819f03586d4ecab3d744056c8c902b630f
Signed-off-by: Zheng Bao <fishbaozi@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/56438
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kangheui Won <khwon@chromium.org>
Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
2021-12-14 16:15:52 +00:00
Bill XIE d85cee8310 payloads/U-Boot: Fix various build errors
1. Fix the inconsistence of the target path of U-Boot payload
   between Kconfig and Makefile.inc.

2. Perform full clone (to the destined commit) in order to get
   tags.

3. Move stable commit id of U-Boot payload from Makefile to
   Kconfig, and make prompt consistent with it.

Change-Id: Ic0f11c16274456a452a0422e19fab0c61d8b5d5b
Signed-off-by: Bill XIE <persmule@hardenedlinux.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60028
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
2021-12-14 16:13:06 +00:00
Rex-BC Chen 2efb6142ca soc/mediatek: add support for tracker version one
There are two versions for tracker system:
Version 1 for MT8186, and version 2 for MT8192 and MT8195.

Reference document:
MT8169_bus_dbg_tracker_cfg_reg.xls from MediaTek internal.

BUG=b:202871018
TEST=build pass

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: Idb146974da118b1cf5a349370bf7b2fa13f1aba8
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59989
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2021-12-14 16:11:28 +00:00