Commit Graph

29465 Commits

Author SHA1 Message Date
Pavel Sayekat 40dc75efcb util/superiotool/nuvoton.c: Minor tag update/removal
Signed-off-by: Pavel Sayekat <pavelsayekat@gmail.com>
Change-Id: Ic193f31b9776683849578bf9009c51bf22d1dae6
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33910
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2019-07-01 08:30:44 +00:00
Kyösti Mälkki 6bdaaefb30 intel/fsp_rangeley: Use fixed FSB/BCLK value 100 MHz
Prior to commit
  d731a24 src/cpu/intel: Set get_ia32_fsb function common

value of 200 was silently used as a default for fsp_rangeley
(model_406dx) in cpu/x86/lapic/apic_timer:set_timer_fsb().

After the commit, get_ia32_fsb() returns -2, eventually
resulting with divide-by-zero in timer_monotonic_get(), as
get_timer_fsb() returns 0.

Add Rangeley CPUID model 0x4d to get_ia32_fsb() as a fix,
using BCLK = 100 MHz based on the comments in
  northbridge/intel/fsp_rangeley/udelay.c

Change-Id: I306f85dba9b1e91539fc0ecc9b2ae9d54f82be6c
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33822
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
2019-07-01 04:18:41 +00:00
Subrata Banik 86dbe0f307 Kconfig: Enable RAMPAYLOAD for x86
This patch makes CONFIG_RAMPAYLOAD default enable upon selection
of HAVE_RAMPAYLOAD kconfig from mainboard for x86 platform.

Without this CL, CONFIG_RAMPAYLOAD is still disabled although
mainboard has selected CONFIG_HAVE_RAMPAYLOAD.

Change-Id: I40308bbf970a0dbe5f7e2086ed8a7a70c2a3a32c
Signed-off-by: Subrata Banik <subrata.banik@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33859
Reviewed-by: ron minnich <rminnich@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-07-01 02:27:38 +00:00
Marshall Dawson ab0ab966f5 pci_ids.h: Add AMD Picasso IDs
Change-Id: I4ac67d1577229e63424dd7fd0ff84d1acfe826c3
Signed-off-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33748
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Martin Roth <martinroth@google.com>
Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
2019-06-30 18:40:13 +00:00
Julius Werner ce4d39d2d7 libpayload: cbgfx: Run cbgfx_init() before we need it for draw_box()
calculate_color() uses the 'fbinfo' global that is initialized by
cbgfx_init(), so we need to run the latter before we can run the former
or we get a null pointer access.

Change-Id: I73ca8e20ca36f64d699379d504fd41dc2084f157
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33855
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
2019-06-29 00:31:14 +00:00
Jacob Garber c22ebc9339 sb/amd/sb{700,800}: Clean up index manipulations
It looks like in days gone by that these switches were once parts of
loops that incremented 'index' as they went along. However, we don't
have any loops anymore, so remove the needless increments and streamline
the rest of the assignments.

Change-Id: Iaabee984333c273af7810f9c11ed26bbb2a995d1
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: scan-build 8.0.0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33774
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-06-28 19:36:11 +00:00
Jacob Garber 464f4d6ee2 device: Tidy up add_more_links()
- Add documentation comment
- Use 'unsigned int' to make checkpatch happy
- Return early if no more links need to be added
- Add error handling if malloc fails
- Clean up whitespace

Change-Id: I70976ee2539b058721d0ae3c15edf279253cd9b7
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: Coverity CID 1229634
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33238
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-28 19:32:18 +00:00
Jacob Garber f77f7cdf89 device,nb/amd: Deduplicate add_more_links()
This function is duplicated in many AMD northbridge files, and all
the definitions have started to diverge somewhat. This moves a single
copy into device utils and deletes the rest. The function definition
from nb/amd/amdfam10 was chosen to be kept, since it contains several
fixes from commit 59d609217b (AMD fam10: Fix add_more_links) that
the others don't have.

For the ease of diffing, the checkpatch lints and other small cleanups
will be done in a follow-up patch.

Change-Id: I5ea73126092449db3f18e19ac0660439313072de
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33237
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-28 19:30:09 +00:00
Jacob Garber d10680bbbf nb/intel/pineview: Remove unused code
All the clocks are switched on anyway, so this series of if statements
isn't needed.

Change-Id: I654043fd6736caa6890fd697015c577ddaa7cd41
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: Coverity CID 13473{27-30}
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33408
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-06-28 19:27:15 +00:00
Jacob Garber 93064ff7cd device/dram: Inline value into print statement
By default printram() expands to nothing in normal builds, and so
scan-build thinks that the assignment to reg8 is unused. Inline the
value of reg8 into the print statement to silence the warning.

Change-Id: I921fe08949c4135367bee9646b3b365097fab19e
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: scan-build 8.0.0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33744
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-06-28 19:24:55 +00:00
Jacob Garber 70f6d82614 cpu/amd/family_10h-family_15h: Remove dead assignment
Pstate_num is initialized later when it is used as a loop index, so this
duplicate assignment can be removed.

Change-Id: I71429bd3306139a823ed39e751d779e4d874f657
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: scan-build 8.0.0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33745
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-06-28 19:23:21 +00:00
Jacob Garber 8a443b9ade sb/amd/rs780: Remove dead assignment
We return immediately after, so this assignment can be removed.

Change-Id: I2a317ada0132a40b623402055b3b995bde80ddf5
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Found-by: scan-build 8.0.0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33773
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-06-28 19:21:42 +00:00
Evgeny Zinoviev 09bf63eacf MAINTAINERS: Add myself as a maintainer for apple boards
Change-Id: I33bf45c81cc4be157ea71806900a545ee68ecee8
Signed-off-by: Evgeny Zinoviev <me@ch1p.io>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33148
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2019-06-28 19:20:47 +00:00
Elyes HAOUAS e5845bfb2d {soc,northbridge}/Kconfig: Remove unused CACHE_MRC_SIZE_KB
Change-Id: Ie922832bc7641a44a53c0cda8d808579c66420b5
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33743
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2019-06-28 19:20:09 +00:00
Matt DeVillier 85d3b40a19 soc/intel/cannonlake: fix use of legacy 8254 timer
FSP sets the use of the 8254 timer via the Enable8254ClockGating
UPD, which defaults to enabled, overriding what is set by coreboot.
Per the FSP integration guide, this UPD needs to be disabled when
a legacy OS is booted (ie, when SeaBIOS is used as the payload).

Add a Kconfig option to set the UPD properly based on payload
selection, and remove the existing coreboot code in lpc.c since
it is either ineffective or being overridden by FSP.

Test: build/boot out-of-tree WHL board with both SeaBIOS and
Tianocore, ensure 8254 timer usage set correctly for each.

Signed-off-by: Matt DeVillier <matt.devillier@puri.sm>
Change-Id: I0e888bf754cb72093f14fc02f39bddcd6d288203
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33512
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2019-06-28 19:11:03 +00:00
Mike Banon 16a70c3d40 asus/am1i-a: Enable UART according to CONFIG_UART_FOR_CONSOLE
It has been observed by me and Elisenda Cuadros / Gergely Kiss [1] that
the boot process of this board is super slow when UART 0 is being used -
even if nothing is connected to it. Enable UART according to
CONFIG_UART_FOR_CONSOLE - and, if UART 0 is selected, it will be initialized
at romstage and this problem will not happen.

[1] https://mail.coreboot.org/pipermail/coreboot/2018-February/086132.html

Signed-off-by: Mike Banon <mikebdp2@gmail.com>
Change-Id: I6579aa8fd092da84f8afdcc33496db45c582919f
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33796
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
2019-06-28 18:01:51 +00:00
Seunghwan Kim 479637d8a2 mb/google/kohaku: Correct trackpad i2c address
Correct i2c address of trackpad. It should be 0x20.

BUG=None
BRANCH=None
TEST=Verified trackpad works on pre-evt system

Change-Id: I7ded21ce8ff9e907e436777a27edb4273512011d
Signed-off-by: Seunghwan Kim <sh_.kim@samsung.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33798
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Shelley Chen <shchen@google.com>
2019-06-28 16:18:32 +00:00
Patrick Rudolph 6033bdca8d payloads/external/LinuxBoot: Update x86_64 defconfig
* Add support for Linux 5.x
** Select PCI, which isn't the default anymore with 5.x
** Select google firmware driver, which wasn't build any more
* Add support for Intel LPSS uart
** Select MFD and MFD_INTEL_LPSS_PCI
** Increase console count to 32
* Add support for coreboot framebuffer
** Select FB_SIMPLE
* Add support for eMMC/SDHCI
** Select MMC_SDHCI_*
* Add support for u-root's localboot
** Select KEXEC_FILE_LOAD
** Select FIRMWARE_MEMMAP

Stats:
* Kernel size 1.9MiB
* U-root (core + systemboot) 4.6MiB

Tested on Intel APL Up² board:
* Fixes non working console on APL Up2 board and eMMC bootmedia shows up.
* Allows to boot GNU/Linux from eMMC using 'localboot'

Change-Id: Ib5bd33531741e588ac7d5ff6a02b0482f6655ddf
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33581
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
2019-06-28 14:27:34 +00:00
Nico Huber 7eb009a2ef lib/gnat: Enable -Werror
We want to catch warnings as early as possible.

Change-Id: Ifdb2ff8f7973d557a437ac127e073306f76ca6f6
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33848
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-28 08:42:16 +00:00
Nico Huber e06e9197b8 lib/gnat: Use ADAFLAGS instead of CFLAGS
Commit 6d7564cdfe (Move -Wlogical-op into xcompile) introduced
GCC_ADAFLAGS_<arch> but forgot to use them for libgnat. Fix that.

Change-Id: Ia9079f01bb3c2a08296a3d3cc32fdf4ae5bb60c7
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33847
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-28 08:41:51 +00:00
Patrick Rudolph efc39cbec7 mb/emulation/qemu-riscv: Use generic 8250 uart driver
Drop hacked uart code and use the generic 8250 uart driver for ns16550a.

Tested on qemu-system-riscv64:
* The UART is still working.

Change-Id: I6efda913fa39e0cfa466b52c570572aca90dacdf
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33735
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Philipp Hug <philipp@hug.cx>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-28 07:36:03 +00:00
Patrick Rudolph 7be4f30c5a arch/riscv/mcall: Drop debug code
The printk has no effect as console_init() hasn't been called.
Also drop unused variables and headers.

Change-Id: I5bf5a8822c69bbcc3de1de460d19585b8330649f
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33786
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-by: Philipp Hug <philipp@hug.cx>
2019-06-28 07:35:56 +00:00
Julius Werner 096fd0a64b qualcomm: qclib: Ensure interface table entry name is terminated
This string is printed in dump_te_table() so we should make sure it's
properly null-terminated.

This fixes Coverity issue 1401305.

Change-Id: I45827f552c2d8a4e01b50a699ac88ee457043282
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33375
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
2019-06-28 06:25:43 +00:00
Prudhvi Yarlagadda 5399f80848 libpayload: Re-initialize UART RX
UART RX needs to be re-initialized in libpayload
as it is getting reset at the end of coreboot.

Change-Id: I7820bd7afd2e5f81e21a43f330ed42d3a732d577
Signed-off-by: Prudhvi Yarlagadda <pyarlaga@codeaurora.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33424
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
2019-06-27 16:40:19 +00:00
Vlado Cibic 2bf6a301d3 mainboard: Add support for ASUS P8Z77-M PRO desktop mainboard
Add support for ASUS P8Z77-M PRO desktop mainboard

Working:

- Tianocore and SeaBIOS boot
- PS/2 keyboard and mouse
- Audio
- S3 Suspend, shutdown and reboot
- USB2 / USB3
- Gigabit Ethernet
- SATA3, SATA2 and eSATA
- NVME
- CPU Temp sensors
- TPM
- Native raminit and also MRC
- PCIe GPU in all PCIe slots (16x/8x/4x) (linux)
- Integrated graphics with both libgfxinit and Intel Video OpROM
  (all connectors VGA/DVI-D/HDMI)

Signed-off-by: Vlado Cibic <vladocb@protonmail.com>
Change-Id: I47d24ac8b236f929c3160f9a769b971d83710f9d
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33328
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-27 16:17:04 +00:00
Felix Singer b91b173f3d mb/upsquared: Align partitions to 4KiB
This fixes warnings while booting coreboot.

Change-Id: If1e99b74ded5f743a3ad4fc829ae9747276c483a
Signed-off-by: Felix Singer <felix.singer@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33784
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-27 11:54:08 +00:00
Maxim Polyakov e6a491e782 mb/asrock/h110m: set serirq_mode to continuous mode
By default, the LPC SIRQ mode is set to Quiet mode. Therefore, COM-port
from the SurerIO chip don't work correctly after the LPC controller (PCI
0:1f.0) initialization. Console output is broken. The patch fixes this
bug by overriding the serirq_mode option in the devicetree.cb to set
Continuous SIRQ mode

Change-Id: I37e26b271fb61f6c0343d6bf65c029924df82caf
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33801
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-27 10:20:02 +00:00
Tsung Ho Wu 804a0433e0 drivers/pc80/tpm: add support for TPM emulator SwTPM 2.0 module
Add software TPM 2.0 emulator to tpm device probe list.
SwTPM: https://github.com/stefanberger/swtpm

Tested on qemu q35 with MAINBOARD_HAS_LPC_TPM and MAINBOARD_HAS_TPM2
set in qemu-q35 Kconfig.
Qemu: see qemu flags at
https://s3hh.wordpress.com/2018/06/03/tpm-2-0-in-qemu/

How to see it work.
Ubuntu 18.04:
1. Install SwTPM from https://github.com/stefanberger/swtpm

2. Add MAINBOARD_HAS_LPC_TPM and MAINBOARD_HAS_TPM2 to
src/mainboard/emulation/qemu-q35/Kconfig and rebuild
coreboot.rom

3. mkdir -p swtpm0

4. swtpm socket --tpmstate dir=swtpm0 --tpm2 --ctrl \
type=unixio,path=swtpm0/swtpm-sock --log level=20 &

5. qemu-system-x86_64 -machine q35 -m 2G \
-chardev socket,id=chrtpm,path=swtpm0/swtpm-sock \
-tpmdev emulator,id=tpm0,chardev=chrtpm -device \
tpm-tis,tpmdev=tpm0 -pflash build/coreboot.rom \
-serial $(tty) -display none

6. Check boot log and search 'Found TPM'.

Change-Id: I5f58d2c117afbd057bb91697912db826db1d67a1
Signed-off-by: Tsung Ho Wu <tsungho.wu@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33302
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-27 10:04:17 +00:00
Patrick Rudolph 1b35295ec2 security: Add memory subfolder
Add files to introduce a memory clearing framework.
Introduce Kconfig PLATFORM_HAS_DRAM_CLEAR that is to be selected by
platforms, that are able to clear all DRAM.

Introduce Kconfig SECURITY_CLEAR_DRAM_ON_REGULAR_BOOT that is user
selectable to always clear DRAM on non S3 boot.

The function security_clear_dram_request tells the calling platform when
to wipe all DRAM. Will be extended by TEE frameworks.

Add Documentation for the new security API.

Change-Id: Ifba25bfdd1057049f5cbae8968501bd9be487110
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31548
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
Reviewed-by: Christian Walter <christian.walter@9elements.com>
2019-06-27 10:02:04 +00:00
Joel Kitching eb20320d7b vboot: remove vboot_handoff step
Depthcharge no longer reads this data structure, and uses
the vboot workbuf in vboot_working_data instead.

Since vboot2 downstream migration is not yet completed, the
vboot2 -> vboot1 migration code is still required, but has
been relocated to depthcharge.

BUG=b:124141368, b:124192753
TEST=make clean && make runtests
BRANCH=none

Change-Id: I769abbff79695b38d11fb6a93c2b42f64d4bafde
Signed-off-by: Joel Kitching <kitching@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33535
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-27 04:36:59 +00:00
Philip Chen 80604cdf03 mb/google/hatch: Add a GPIO to enable/disable FPMCU power
A FPMCU power-control pin (GPP_C11) is added to the latest
hatch reference schematic.

Even though this is not implemented in hatch rev1 board, the future
hatch family boards with FPMCU should all have this control pin.

On the old boards without this control pin, GPP_C11 is a floating TP,
and thus this patch should be backward-compatible.

BUG=b:130307667, b:135216932
TEST=build

Signed-off-by: Philip Chen <philipchen@google.com>
Change-Id: I6a84eeb6aab562258e749a8a5d09dadfa0e43587
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33655
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
2019-06-26 19:03:00 +00:00
Furquan Shaikh 6f7f39e96b mb/google/hatch: Remove pulls on NC pads
There is no need to add internal termination (PU/PD) on the
not-connected pads. This change gets rid of the terminations on the NC
pads.

Change-Id: I3df538d7127e5ef75e6e6ff9db3524e26f0450ed
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33570
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Reviewed-by: Aamir Bohra <aamir.bohra@intel.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2019-06-26 15:13:25 +00:00
Sumeet Pawnikar 755a0131be mb/google/hatch/variants/baseboard: Update PL2 power limit value
Update PL2 power limit value from 44W to 64W.

BUG=None
BRANCH=None
TEST=Build and Boot hatch EVT

Change-Id: I3f4b5ab8bf0ce9464c322c148843f5a3e8d706d9
Signed-off-by: Sumeet Pawnikar <sumeet.r.pawnikar@intel.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33662
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Shelley Chen <shchen@google.com>
2019-06-26 15:04:57 +00:00
Arthur Heymans c8db633852 soc/intel/cannonlake/Kconfig: Don't have all variants select SOC_INTEL_CANNONLAKE
This allows to use Kconfig options to differentiate between SOC
variants.

Change-Id: Ica11c68377e3d0dc8a8f48198e01a74d7bebe642
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33559
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-26 09:20:12 +00:00
Joel Kitching b4a1981289 cbfstool/fit: need inttypes.h for PRIx64
This is causing coreboot build in Chromium OS to fail.

BUG=None
TEST=emerge-eve coreboot
BRANCH=none

Change-Id: I4faa140b3046651b4ed0a9aeefe437048c6ef0da
Signed-off-by: Joel Kitching <kitching@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33780
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2019-06-26 09:19:00 +00:00
Felix Singer 2ae3f51fa0 mb/up/squared: Remove unnecessary code
This patch removes unnecessary code which configures
default FSP values.

Change-Id: If7dae4f24a9fcb01d2d47063dd3a0f4ce6c120d2
Signed-off-by: Felix Singer <felix.singer@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33136
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
2019-06-26 09:17:58 +00:00
Caveh Jalali 23e1202e35 atlas: enable GEO_SAR
BUG=b:131634035
BRANCH=none
TEST=verified SAR data shows up in ACPI SSDT table.

Change-Id: I65ef59c9616b1cae3fa4c4b18bbfe4ed098d2891
Signed-off-by: Caveh Jalali <caveh@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33791
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
2019-06-25 23:14:00 +00:00
Kyösti Mälkki c32a92e5a0 intel/945 boards: Use smp_write_pci_intsrc()
Radically reduces line lengths and splits '(bus<<2) | INT'
to separate parameters.

Change-Id: I0cfd714da3d2773affdb34d1dab2ac32879e2cfd
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/30740
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-25 18:48:43 +00:00
Patrick Havelange 88164787ee soc/intel/dnv: Fix value of B_PCH_GPIO_RX_SCI_ROUTE
The value for that macro should be 1<<19. This is confirmed by the
Intel doc and also by N_PCH_GPIO_RX_SCI_ROUTE.
See Intel Atom® Processor C3000 Product Family Datasheet
(February 2018) :
https://www.intel.com/content/www/us/en/products/docs/processors/atom/c-series/c3000-family-datasheet.html

Signed-off-by: Patrick Havelange <patrick.havelange@essensium.com>
Change-Id: I808d9131032a9796d837e00ad6fb3369b792e597
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33573
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: David Guckian
Reviewed-by: Nico Huber <nico.h@gmx.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-25 16:09:05 +00:00
Frans Hendriks 3b42683790 mainboard/facebook/fbg1701: Set CBFS_SIZE to 0x600000
CBFS_SIZE equals size of whole SPI device.
The descriptor and ME need to be placed in bottom part.
Reduce the CBFS_SIZE to maximum avalaible size.

BUG=N/A
TEST=Boot Embedded Linux 4.20 on Facebook FBG-1701

Change-Id: Iecfae4573100c6787b6e8b1c4f2583a7fb3d95a3
Signed-off-by: Frans Hendriks <fhendriks@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33484
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
2019-06-25 16:08:17 +00:00
Frans Hendriks 8b040c0730 mainboard/facebook/fbg1701: Use LCD Panel type for name of tables
tc348860_table contains the eDP to MIPI Bridge controller type.
b101uan08_table used the LCD Panel type.
Use LCD Panel type for name of tables.

Remove the incomplete resolution comments and specify the resolution at
the start of the table to 1200x1920.

BUG=N/A
TEST=Config eDP and verify LCD panels are working on Facebook FBG-1701

Change-Id: Ic152ea1f95f155ab76638b57a259d37ce6f43037
Signed-off-by: Frans Hendriks <fhendriks@eltan.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33736
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2019-06-25 11:10:07 +00:00
Peter Lemenkov bc15cc3e86 mb/lenovo/z61t: Remove `fn_ctrl_swap` option
It seems that the EC on t60/x60/z61t doesn't support it. This wasn't
even introduced in z61t so let's remove the remaining bits.

This commit follows up on commit a5fcc2e4 with Change-Id
Id2964002406a5fcf992f0ffc3627e3f66a2bb13f ("mb/lenovo/x60/t60: Remove
`fn_ctrl_swap` option").

Tested on a real hardware.

Change-Id: Ifd5e7823af305cc4a0194ee2097a749e43680c55
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33364
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Andrey Korolyov <andrey@xdel.ru>
2019-06-25 07:58:43 +00:00
Joel Kitching 393c71c213 add ctype.h header
Sometimes coreboot needs to compile external code (e.g.
vboot_reference) using its own set of system header files.  When
these headers don't line up with C Standard Library, it causes
problems.

Create ctype.h header file.  Relocate ctype.h functions from
string.h into ctype.h.  Update source files which call ctype.h
functions accordingly.

Note that ctype.h still lacks five functions which are not used
in coreboot source:
  isalnum, isalpha, iscntrl, isgraph, ispunct

BUG=b:124141368
TEST=make clean && make test-abuild
BRANCH=none

Change-Id: I31b5e8af49956ec024a392a73c3c9024b9a9c194
Signed-off-by: Joel Kitching <kitching@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33525
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2019-06-24 21:15:14 +00:00
Piotr Kleinschmidt 2d6ed31cbd Documentation: Add PC Engines apu2
Describe how to run coreboot on the PC Engines apu2 mainboard.

Change-Id: Id1d553c7f7485358960d92e714d50ba0f75b3581
Signed-off-by: Piotr Kleinschmidt <piotr.kleinschmidt@3mdeb.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33146
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-06-24 12:29:52 +00:00
Piotr Kleinschmidt fd666ed0b5 Documentation: Add PC Engines apu1
Describe how to run coreboot on the PC Engines apu1 mainboard.

Change-Id: If79693e893c4afe52bf1c9aa8017ac6f650a96e4
Signed-off-by: Piotr Kleinschmidt <piotr.kleinschmidt@3mdeb.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/32907
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
2019-06-24 12:28:52 +00:00
Angel Pons c6b44cd7ce mb/gigabyte/ga-h61ma-d3v: Add new mainboard as variant
Tested with SeaBIOS as a payload, booting Arch Linux with
a Linux kernel. The new code is based on autoport and the
existing GA-H61M-S2PV code.

The GA-H61M-S2PV has been boot-tested too, it still boots.

Working:
 - S3 suspend/resume
 - USB ports and headers (Intel USB2 and EtronTech USB3)
 - Gigabit Ethernet
 - Integrated DVI/VGA graphics (libgfxinit)
 - PCIe x16 graphics
 - PCIe x1 ports
 - PS/2 port with a keyboard
 - SATA controllers (Intel SATA2 and Marvell SATA3)
 - User-space fan control (fancontrol on Linux)
 - Native raminit (4+4GB DDR3-1333)
 - flashrom, using the internal programmer. Tested with coreboot,
   as well as with the vendor firmware. Backup chip is untested.

Untested:
 - VGA BIOS for integrated graphics init
 - Audio: Only front/read outputs has been tested.
 - Non-Linux OSes
 - ACPI thermal zone and OS-independent fan control

Not working:
 - Default IFD defines the BIOS region as the entire flash chip.
   Using 'flashrom --ifd -i bios' is asking for a failed flash!

Change-Id: I37928de158bb8fbb47fbda5d1ccd4efba7edab26
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31832
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2019-06-24 12:13:46 +00:00
Elyes HAOUAS 741000d31b util/cbfstool/flashmap: Correct local includes
Change-Id: I78ba7afd2085c7e9c93e892470111bfee154bb04
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/33733
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
2019-06-24 10:52:53 +00:00
Patrick Rudolph 9ab80a33a5 cbfstool: Drop update-fit option
The ifittool is used instead. Drop old code.

Change-Id: I70fec5fef9ffd1ba3049badb398783f31aefb02f
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31496
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
2019-06-24 09:45:00 +00:00
Patrick Rudolph 5e3b92a924 Makefile: Use ifittool to update FIT
Depend on ifittool and use it to update FIT instead cbfstool FIT code.

Move the TOPSWAP / microcode handling out of cbfstool and implement it
in the Makefile.

The new FIT looks like the old one and has been tested on Broadwell-DE.

The TOPSWAP / microcode code path needs test on real hardware.

Change-Id: I687469d62557f81e9d88398cfc93182164fdac95
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31495
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
Reviewed-by: Christian Walter <christian.walter@9elements.com>
2019-06-24 09:42:52 +00:00
Philipp Deppenwiese 5ada0023d1 cbfstool: Add ifittool
Add the IntelFirmwareInterfaceTable-tool to modify the FIT.
As cbfstool is overloaded with arguments, introduce a new tool
to only modify FIT, which brings it's own command line syntax.

Provide clean interface to:
* Clear FIT
* Add entry to CBFS file
* Add entry to REGION
* Delete entries
* Add support for types other than 1
* Add support to dump current table
* Add support for top-swap
* Sort entries by type

Most code is reused from existing cbfstool and functionality of cbfstool
is kept. It will be removed once the make system uses only ifittool.

Based on "Intel Trusted Execution Technology (Intel TXT) LAB Handout"
and https://github.com/slimbootloader/slimbootloader .

Change-Id: I0fe8cd70611d58823aca1147d5b830722ed72bd5
Signed-off-by: Patrick Rudolph <patrick.rudolph@9elements.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/31493
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Philipp Deppenwiese <zaolin.daisuki@gmail.com>
2019-06-24 09:42:31 +00:00