Commit Graph

37942 Commits

Author SHA1 Message Date
Nico Huber bc2c12c728 libpayload/x86: Try to discover invariant TSC rate
We can skip the PIT-based TSC calibration if we can derive the invariant
TSC rate from CPUID/MSR data. This is necessary if the PIT is disabled,
which is the default, for instance, on Coffee Lake CPUs.

This implementation should cover all Intel Core i processors at least.
For older processors, we fall back to the PIT calibration.

Change-Id: Ic6607ee2a8b41c2be9dc1bb4f1e23e652bb33889
Signed-off-by: Nico Huber <nico.huber@secunet.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/34170
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
2020-11-02 06:24:33 +00:00
Nico Huber 5c9d82bd73 libpayload/x86: Add enumeration of Intel family 6 models
The list is incomplete and only contains what we need in the follow-up
commit. It can be extended at will.

Change-Id: Ibf8ddaf510eb513ee74af3e78da46b04802a91b9
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47059
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2020-11-02 06:24:10 +00:00
Tim Crawford d0d445564c mb/system76/lemp9: Enable battery charging thresholds
Change-Id: I5131cf350d5b8c2a45f8d8245c0df26742c0d732
Signed-off-by: Tim Crawford <tcrawford@system76.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/45533
Reviewed-by: Jeremy Soller <jeremy@system76.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:23:50 +00:00
Tim Crawford a4e75ab0cd ec/system76/ec: Add battery charging thresholds
System76 EC firmware supports setting charging thresholds for a single
battery.

Change-Id: I3d656291c096f320d469274677e9fe6c74819d25
Signed-off-by: Tim Crawford <tcrawford@system76.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/45532
Reviewed-by: Jeremy Soller <jeremy@system76.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:23:36 +00:00
Elyes HAOUAS f8051e7c8b ec/system76/ec: Convert to ASL 2.0 syntax
Change-Id: I83a4a3ad8a9fcb6071e0c700bf2be1676847aa9e
Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46107
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jeremy Soller <jeremy@system76.com>
2020-11-02 06:23:13 +00:00
Michael Niewöhner d5fc04bdc9 include/acpi: add defines for CPPC versions 1-3
Change-Id: I6abbf98398057b9774fcfd9046ba933b5286e4cd
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46986
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
2020-11-02 06:22:56 +00:00
Frank Chu 5b10ec4361 mb/google/volteer/variants/delbin: Update DPTF parameters for delbin
Configure board specific DPTF parameters for delbin

BUG=b:168958222
BRANCH=volteer
TEST=build and verify by thermal team

Signed-off-by: Frank Chu <frank_chu@pegatron.corp-partner.google.com>
Change-Id: I69aa6046fdc90a2cf59ea3a13fdb15c8bc0d29a2
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46676
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:22:05 +00:00
David Wu 397b46c172 volteer: Create voema variant
Create the voema variant of the volteer reference board by copying
the template files to a new directory named for the variant.

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

BUG=b:171755775
BRANCH=None
TEST=util/abuild/abuild -p none -t google/volteer -x -a
make sure the build includes GOOGLE_VOEMA

Signed-off-by: David Wu <david_wu@quanta.corp-partner.google.com>
Change-Id: I4e1872d1ebff6fefdfb232f1ff82fce95a1ec643
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47007
Reviewed-by: YH Lin <yueherngl@google.com>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:21:51 +00:00
Kenneth Chan 914a568ec4 mb/google/octopus/variants/dood: Add G2Touch touchscreen support
Add G2Touch touchscreen support for dood.

BUG=b:171526389
BRANCH=octopus
TEST=emerge-octopus coreboot chromeos-bootimage, and check touchscreen
work.

Signed-off-by: Kenneth Chan <kenneth.chan@quanta.corp-partner.google.com>
Change-Id: Ica7d893de285c2dd1efcd43ac74919bdd5d5ac17
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46675
Reviewed-by: Marco Chen <marcochen@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:21:07 +00:00
Arthur Heymans f3d65e4998 cpu/x86/smm: Pass smm.ld through src-to-obj
This allows for ccopts symbols and preprocessor to be used inside the
smm.ld linker script.

Change-Id: I4262c09ca52c1fca43c1c115530efe489a722c32
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/44321
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:20:53 +00:00
Eric Lai a9a48b6839 mb/google/zork/var/vilboz: Update touch screen power sequence
Add ELAN touch support and update Goodix settings.

BUG=b:157265632
BRANCH=zork
TEST=emerge coreboot and check both touch screen are workable.

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: Icfc2421061e8b3163d7d5108673351bc17df20ec
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46929
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Martin Roth <martinroth@google.com>
2020-11-02 06:18:12 +00:00
Arthur Heymans fe9d2119a6 soc/intel/fsp-car: Use the coreboot defined stack
The stack needs to be in the coreboot defined region to not collide
with other symbols.

Change-Id: I02a379d2ac73ae30239bd45859c3f09de1a9d0e0
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37278
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Subrata Banik <subrata.banik@intel.com>
2020-11-02 06:17:41 +00:00
Arthur Heymans 087fe9fe27 soc/intel/xeon_sp/bootblock.c: Report the FSP-T output
Change-Id: I03841f8263203ee306f83b8f8e859ec03edc3bd3
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46885
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:16:53 +00:00
Arthur Heymans 5a66334911 drivers/intel/fsp2_0: Add function to report FSP-T output
This allows to compare the FSP-T output in %ecx and %edx to coreboot's
CAR symbols:

Change-Id: I8d79f97f8c12c63ce215935353717855442a8290
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46884
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
2020-11-02 06:16:37 +00:00
Furquan Shaikh d7388d13f7 soc/intel/common/cse: Add dependency on SOC_INTEL_CSE_LITE_SKU
This change adds the dependency on SOC_INTEL_CSE_LITE_SKU for the
following configs:
1. SOC_INTEL_CSE_FMAP_NAME
2. SOC_INTEL_CSE_RW_CBFS_NAME
3. SOC_INTEL_CSE_RW_FILE

These configs aren't really useful for platforms not using CSE Lite
SKU.

Change-Id: Id48ab36b7e75301d50122916d153f494d755ae77
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46905
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:16:23 +00:00
Furquan Shaikh 160fc4736b drivers/wifi/generic: Use is_dev_enabled() instead of dev->enabled
This change replaces the checks for dev->enabled with the helper
function `is_dev_enabled()`.

Change-Id: Iacceda396c9300bbfa124e76fb9c99d86313ea0f
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46904
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:15:41 +00:00
Furquan Shaikh cbe2fd351c wifi: Drop PCI IDs for JfP and HrP
This change drops the PCI IDs for Jefferson Peak and Harrison Peak
CNVi modules from wifi/generic drivers as well as pci_ids.h. These IDs
actually represent the CNVi WiFi controller PCI IDs and are now
supported by intel/common/block/cnvi driver.

The only ID that is being dropped without adding support in
intel/common/block/cnvi driver is
PCI_DEVICE_ID_HrP_6SERIES_WIFI(0x2720) since this was not found in the
list of PCI IDs for any SoC.

Change-Id: I82857a737b65a6baa94fb3c2588fe723412a7830
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46866
Reviewed-by: Subrata Banik <subrata.banik@intel.com>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:15:27 +00:00
Furquan Shaikh edac4ef6d4 mb, soc/intel: Reorganize CNVi device entries in devicetree
This change reorganizes the CNVi device entries in mainboard
devicetree/overridetree and SoC chipset tree to make it consistent
with how other SoC internal PCI devices are represented i.e. without a
chip driver around the SoC controller itself.

Before:
chip drivers/wifi/generic
	register "wake" = "..."
	device pci xx.y on end
end

After:
device pci xx.y on
	chip drivers/wifi/generic
		register "wake" = "..."
		device generic 0 on end
	end
end

Change-Id: I22660047a3afd5994400341de0ca461bbc0634e2
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46865
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:15:06 +00:00
Furquan Shaikh 23e88135bb soc/intel: Add a driver for CNVi WiFi/BT controllers
This change adds a common block driver for CNVi WiFi/BT controllers in
Intel SoCs. This driver uses the common PCI dev operations in addition
to generating ACPI device node and returning ACPI name for the
controller device.

This change also selects this driver for CML, GLK, ICL, JSL and TGL.

Change-Id: I69a832be918d4b9f4fbe3a40913d4542a457a77c
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46864
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:14:38 +00:00
Furquan Shaikh 9e1fab0076 pci_ids: Add PCI IDs for CNVi WiFi/BT controllers
This change adds PCI IDs for CNVi WiFi/BT controllers for CML, GLK,
ICL, JSL and TGL.

Change-Id: Id45f65d0ef5a7782c08ddd70eb22b26072c8ef4b
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46863
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:14:24 +00:00
Furquan Shaikh d4367505f1 drivers/wifi/generic: Add support for CNVi dummy device ops
This change reorganizes drivers/wifi/generic to add a new
device_operations structure for dummy CNVi device. This is done to
make the organization of CNVi PCI device in devicetree consistent
with all the other internal PCI devices of the SoC i.e. without a chip
around the PCI device.

Thus, with this change, CNVi entry in devicetree can be changed from:
```
chip drivers/wifi/generic
	register "wake" = "xxyyzz"
	device pci xx.y on end # CNVi PCI device
end
```

to:

```
device pci xx.y on
	chip drivers/wifi/generic
		register "wake" = "xxyyzz"
		device generic 0 on end # Dummy CNVi device
	end
end # CNVi PCI device
```

The helper functions for ACPI/SMBIOS generation are also accordingly
updated to include _pcie_ and _cnvi_ in the function name.

Change-Id: Ib3cb9ed9b81ff8d6ac85a9aaf57b641caaa2f907
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46862
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:14:12 +00:00
Furquan Shaikh 6017abbc2c drivers/wifi/generic: Split wifi_generic_fill_ssdt into two functions
This change splits `wifi_generic_fill_ssdt()` into following two
functions:
1. `wifi_ssdt_write_device()`: This function writes the device, its
address, _UID and _DDN.

2. `wifi_ssdt_write_properties()`: This function writes the properties
for WiFi device like _PRW, regulatory domain and SAR.

This split is done so that the device write can be skipped for
CNVi devices in follow-up CLs. It will allow the SoC controller
representation for CNVi PCI device to be consistent with other
internal PCI devices in the device tree i.e. not requiring a
chip driver for the PCI device.

Because of this change, _PRW and SAR will be seen in a separate
block in SSDT disassembly, but it does not result in any functional
change.

Observed difference:
Before:
Scope (\_SB.PCI0.PBR1)
{
	Device (WF00)
	{
		Name (_UID, 0xAA6343DC)
		Name (_DDN, "WIFI Device")
		Name (_ADR, 0x0000000000000000)

		Name (_PRW, Package() { 0x08, 0x03 })
	}
}

After:
Device (\_SB.PCI0.PBR1.WF00)
{
	Name (_UID, 0xAA6343DC)
	Name (_DDN, "WIFI Device")
	Name (_ADR, 0x0000000000000000)
}

Scope (\_SB.PCI0.PBR1.WF00)
{
	Name (_PRW, Package() { 0x08, 0x03 })
}

Change-Id: I8ab5e4684492ea3b1cf749e5b9e2008e7ec8fa28
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46861
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:13:54 +00:00
Furquan Shaikh 2736c82956 drivers/wifi/generic: Move ACPI functions to a separate file
This change reorganizes the WiFi generic driver to move the ACPI
functions to a separate file. This change is done to reduce the noise
in generic.c file and improve readability of the file.

Change-Id: If5fafb5452fb5bad327be730fcfc43d8a5d3b8ec
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46860
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:13:10 +00:00
Furquan Shaikh 507a98b689 drivers/wifi/generic: Move SMBIOS functions to a separate file
This change reorganizes the WiFi generic driver to move the SMBIOS
functions to a separate file. This change is done to reduce the noise
in generic.c file and improve readability of the file.

Change-Id: I38ed46f5ae1594945d2078b00e8315d9234f36d7
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46859
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:12:57 +00:00
Furquan Shaikh 2b5be8857b drivers/wifi/generic: Use acpigen_write_ADR_pci_device
This change uses the helper function `acpigen_write_ADR_pci_device()`
to write _ADR object for the WiFi device.

Change-Id: I3ba38f3ec4d8024209840e93bebf2d39bbef7685
Signed-off-by: Furquan Shaikh <furquan@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46858
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
2020-11-02 06:12:42 +00:00
Martin Roth 89815c96a6 soc/amd/picasso: Put transfer buffer into common ld file
Instead of having the same linker layout for the transfer buffer between
the x86 & PSP linker layout scripts, put the common layout into a file
shared between the other linker scripts.

BUG=None
TEST=Boot zork board, verify the buffers are aligned.
BRANCH=Zork

Signed-off-by: Martin Roth <martinroth@chromium.org>
Change-Id: Ib9d9d8b046bc9e9e7a4ee939324960bfc44c3508
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46900
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Julius Werner <jwerner@chromium.org>
2020-11-02 06:12:11 +00:00
David Wu 0d76194a1b mb/google/volteer: Disable DPTF active policy for terrador and todor
Terrador and Todor are fanless design, so disable DPTF active policy.

BUG=b:171019363,b:170699797
BRANCH=volteer
TEST=build and verify by thermal team

Signed-off-by: David Wu <david_wu@quanta.corp-partner.google.com>
Change-Id: I53a33b8706d7a7d4013a2a5627a620223fcffc3e
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46874
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:11:21 +00:00
Iru Cai a568d605e9 ec/hp/kbc1126: Support using a different GPE
HP EliteBook Folio 9480m uses the HP KBC1126 EC ACPI interface, but
with a different GPE, so add a Kconfig option to support using a
different GPE.

Change-Id: I3b78567e1387c96bf173e4370aa3c836bbddac0b
Signed-off-by: Iru Cai <mytbk920423@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/45576
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 06:08:54 +00:00
Srinidhi N Kaushik b57f22fc5b vendorcode/intel/fsp: Update Tiger Lake FSP Headers for FSP v3425
Update FSP headers for Tiger Lake platform generated based on FSP
version 3425. Previous version was 3373.

BUG=b:172045149
BRANCH=none
TEST=build and boot delbin

Cq-Depend:chrome-internal:3373431
Signed-off-by: Srinidhi N Kaushik <srinidhi.n.kaushik@intel.com>
Change-Id: I58d165d452c8c6ae2eec92524109a568f7e581a9
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47041
Reviewed-by: Dossym Nurmukhanov <dossym@google.com>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-11-02 04:43:39 +00:00
Matt DeVillier 184c794086 docs/librem_mini: update CPU, known issues section
Both 8565U and 8665U CPUs are used in the Librem Mini.

SATA issue updated based on addition of HSIO PHY tuning params
and resulting changes.

Change-Id: I33a093ccfea077402e1b3651f9ca5d6d8a2818f8
Signed-off-by: Matt DeVillier <matt.devillier@puri.sm>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46983
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
2020-10-31 21:46:06 +00:00
Patrick Georgi 8aa087ece6 .gitignore: Ignore .test/.dependencies globally
These were originally ignored only inside util/ but these files
shouldn't be tracked anywhere.

Change-Id: Ie0846bd8bdd6e52f420f9dd2e72a8a922102ff90
Signed-off-by: Patrick Georgi <patrick@georgi.software>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47012
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
2020-10-31 18:21:36 +00:00
Martin Roth 09e032e59f Makefile: Remove possibly illegal characters from doxyplatform
The CONFIG_MAINBOARD_PART_NUMBER string can have characters in it that
don't work in the doxyplatform make script under sh, so change any
non-alphanumeric characters to an underscore.

Also strip all the quotes - they aren't needed.

The spaces in the "QEMU x86 i440fx/piix4" platform are one example of
this.

Signed-off-by: Martin Roth <martin@coreboot.org>
Change-Id: I10bc6a8a245a34e89c859ff46835bde35aaa4286
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46287
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
2020-10-31 18:21:06 +00:00
Felix Held 215ac3bc40 cpu/x86/lapic: rename virtual wire mode initialization function
Clarify what the function does by renaming it from do_lapic_init() to
lapic_virtual_wire_mode_init().

Change-Id: Ie4430bf0f6c6bf0081b6aaeace351092bcf7f4ac
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/47020
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2020-10-31 18:01:38 +00:00
Angel Pons f5dd7b6eb9 {cpu,nb}/intel/haswell: Drop unnecessary `UL` suffix
Tested with BUILD_TIMELESS=1, Google Wolf does not change.

Change-Id: I029ab0dccbf7b61d641cccf79b491fabf97ab74a
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46720
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-31 10:08:59 +00:00
Angel Pons 8963f7d40b sb/intel/lynxpoint: Drop unnecessary `UL` suffix
With BUILD_TIMELESS=1, Asrock B85M Pro4 and Google Wolf do not change.

Change-Id: I9ba4097cd82c4ff68315a40e1e955e4ed9a43862
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46719
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-31 10:08:35 +00:00
Angel Pons 2d35cf8689 sb/intel/lynxpoint: Use common code to generate HPET table
There's no need to reinvent the wheel.

Change-Id: If6b90c9a7a00af0322c6dd15d2c4ecf2c513d0cc
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46977
Reviewed-by: Michael Niewöhner <foss@mniewoehner.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-31 10:07:52 +00:00
Michael Niewöhner cbd4ee73d7 cpu/intel/common: correct MSR for the Nominal Performance in CPPC
The "Nominal Performance" is not the same as the "Guaranteed
Performance", but is defined as the performance a processor can deliver
continously under ideal environmental conditions.

According to edk2, this is the "Maximum Non-Turbo Ratio", which needs to
be read from MSR_PLATFORM_INFO instead of IA32_HWP_CAPABILITIES.

Correct the entry in the CPPC package.

Test: dumped SSDT from Supermicro X11SSM-F and checked decompiled
version

Change-Id: Ic2c27fd3e14af18aa4101c0acd7a5ede15d1f3a9
Signed-off-by: Michael Niewöhner <foss@mniewoehner.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46464
Reviewed-by: Subrata Banik <subrata.banik@intel.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-31 00:04:45 +00:00
Daniel Kang 1b940d17a8 mb/google/volteer: Remove RIPTO support for camera
GPIO D4 was used for camera reset for both front and rear cameras
(RCAM_RST_L/FCAM_RST_L) in RIPTO. For later volteer versions,
GPIO F15 is dedicated to the rear camera reset (RCAM_RST_L).

Before, BOARD_GOOGLE_VOLTEER flag was used for setting the right
RCAM_RST_L per volteer version. However, we don't support RIPTO
anymore. Also using flags for different volteer version support can
be error-prone. Removing RIPTO support.

BUG=b:171726823
BRANCH=none
TEST=Build and boot volteer proto2 or later version. Camera should
work without an issue.

Signed-off-by: Daniel Kang <daniel.h.kang@intel.com>
Change-Id: I961fc17092887b4807c12c95f7139bb7e7b33e91
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46826
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 22:36:46 +00:00
Jacob Garber 1627e2f158 cpu/x86/sipi_vector.S: Use correct suffix for bts
The assembler is warning that the bts instruction is ambiguous, so use
the correct suffix btsl.  See also commit 693315160e
(cpu/x86/sipi_vector.S: Use correct op suffix)

Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Change-Id: I2eded0af1258e90926009544683b23961d99887b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46928
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
2020-10-30 21:40:01 +00:00
Nico Huber 1fa72d5fe1 x86: Add a minimal example SoC along with a board
The min86 example SoC code along with the example mainboard
should serve as a minimal example how a buildable x86 SoC code
base can look like.

This can serve, for instance, as a basis to add new SoCs to
coreboot. Starting with a buildable commit should help with
the review of the actual code, and also avoid any regressions
when common coreboot code changes.

As the example code itself is build-tested, it should advance
with coreboot and can't rot like documentation might. It also
serves as a check what APIs need to be implemented with the
default Kconfig settings.

Change-Id: Id76ab15fe77ae3e405c43f9c8677694f178be112
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/45710
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 21:34:18 +00:00
Daniel Kang 8661fe220d mb/google/volteer: Separate power resource for VCM
The camera privacy LED blinks during the boot and this gives a wrong
impression to the users that the camera is being used during the power
up. The blink happens when the camera module is probed and a series of
kernel patches and coreboot patches are being submitted to resolve the
issue.

The kernel patches are submitted to the chromium gerrit.

https://chromium-review.googlesource.com/2403386
https://chromium-review.googlesource.com/2403387
https://chromium-review.googlesource.com/2403385
https://chromium-review.googlesource.com/2403384
https://chromium-review.googlesource.com/2403383
https://chromium-review.googlesource.com/2403382
https://chromium-review.googlesource.com/2403381
https://chromium-review.googlesource.com/2403380

This is to separate the power resource for the VCM so that it can be
controlled by the driver and suppress the LED turn on.

BUG=b:169049942
BRANCH=none
TEST=Build and boot volteer board. Monitor camera privacy LED
and check if it blinks. It should not blink.

Signed-off-by: Daniel Kang <daniel.h.kang@intel.com>
Change-Id: Id51c98e42c5f20e231d8096c9d2d98deebc7c968
Reviewed-on: https://review.coreboot.org/c/coreboot/+/45159
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Tomasz Figa <tfiga@google.com>
2020-10-30 20:25:13 +00:00
Eric Lai b3e9aaf62b mb/google/octopus/var/fleex: Disable XHCI LFPS power management by sku
LTE module Fibocom L850-GL is lost after idle overnight,
with this workaround, host will not initiate U3 wakeup
at the same time with device, which will avoid the race condition.

If this option is set in the devicetree, the bits[7:4] in XHCI MMIO BAR +
offset 0x80A4 (PMCTRL_REG) will be updated from default 9 to 0.

BUG=b:169645448
BRANCH=octopus
TEST=build coreboot with DisableXhciLfpsPM being set to 1 and flash
     the image to the device. Run following command to check if
     bits[7:4] is set 0:
     >iotools mmio_read32 "XHCI MMIO BAR + 0x80A4"

Signed-off-by: Eric Lai <ericr_lai@compal.corp-partner.google.com>
Change-Id: I3a04320b0e2441dce540a5afdc461f12de45c41b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46868
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Marco Chen <marcochen@google.com>
2020-10-30 20:20:47 +00:00
Marc Jones 70907b00e6 soc/intel/xeon_sp: Call common soc_get_num_cpus()
Use a common function to get the number of CPUs for each soc. This
removes a #if for different function names in the common code.

Change-Id: I3348d37fcae72247731e465ec2a65d9583a2f180
Signed-off-by: Marc Jones <marcjones@sysproconsulting.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46970
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
2020-10-30 18:55:58 +00:00
Marc Jones 444fda4528 soc/intel/xeon_xp: Combine cpx and skx acpi.c
Prepare for common ACPI. Combine cpx and skx acpi.c into a single
file in xeon_sp. This is almost the last step in using common/block
acpi.

Change-Id: I5f40eb7909bb796907682c548219c7515f2ae4d1
Signed-off-by: Marc Jones <marcjones@sysproconsulting.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46600
Reviewed-by: Jay Talbott <JayTalbott@sysproconsulting.com>
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 18:55:42 +00:00
Marc Jones d49c8cfbf1 soc/intel/xeon_sp/skx/acpi.c: Update with cpx changes
Prepare for common ACPI. This primarily makes the skx madt table
generation match cpx. There are a few other small changes to remove
unused code and make the files match.

Change-Id: I71a59181226d79c40a4af405653c50c970fb720b
Signed-off-by: Marc Jones <marcjones@sysproconsulting.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46599
Reviewed-by: Jay Talbott <JayTalbott@sysproconsulting.com>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Jonathan Zhang <jonzhang@fb.com>
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 18:54:10 +00:00
Jonathan Zhang cbbce66baf cpu/x86: increase timeout for CPUs to check in after 2nd SIPI
Increase timeout for CPUs to check in after 2nd SIPI completion
from 10ms to 100ms.

Update logging level for mp init failure cases from BIOS_DEBUG
to BIOS_ERR.

Without this patch, "mp initialization failure" happens on some
reboots on DeltaLake server. As consequence, not all 52 cpus
come up in Linux:
[root@localhost ~]# lscpu
...
CPU(s):                40

Also following Hardware Errors are seen:
[    4.365762] mce: [Hardware Error]: Machine check events logged
[    4.366565] mce: [Hardware Error]: CPU 0: Machine Check: 0 Bank 9: ee2000000003110a
[    4.367561] mce: [Hardware Error]: TSC 0 ADDR fe9e0000 MISC 228aa040101086
[    4.368563] mce: [Hardware Error]: PROCESSOR 0:5065b TIME 948438164 SOCKET 0 APIC 0 microcode 700001d

With this patch, no such failure is observed with 370 reboots.

Signed-off-by: Tim Chu <Tim.Chu@quantatw.com>
Signed-off-by: Jonathan Zhang <jonzhang@fb.com>
Change-Id: Iab10f116dd4af152c24d5d8f999928c038a5b208
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46898
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 18:53:20 +00:00
Duncan Laurie 2e9315c4c6 soc/intel/tigerlake: Enable TCSS XHCI device and define port aliases
Enable the USB4 XHCI driver and remove the ACPI name entry from the
SOC level function.

Define aliases for the USB2/3 ports on north and south XHCI devices in
chipset.cb so they can be referenced in the mainboard devicetree.

BUG=b:151731851
TEST=define usb ports by reference in volteer devicetree and ensure
they get properties added in SSDT for both north and south XHCI device.

Signed-off-by: Duncan Laurie <dlaurie@google.com>
Change-Id: I724ca874d3a3f6a2b43a700b0b10f77f25c53ee0
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46852
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
2020-10-30 18:34:30 +00:00
Duncan Laurie 0f5a17e980 soc/intel/common/block/usb4: Add TCSS XHCI driver for SSDT generation
In order to generate ACPI entries for USB devices attached to the
USB4/TBT/TCSS/North XHCI device it needs to have a driver that will
enumerate static devices on the bus.  This driver does that and nothing
else.

BUG=b:151731851
TEST=boot on volteer and check for USB devices on \_SB.PCI0.TXHC.RHUB

Signed-off-by: Duncan Laurie <dlaurie@google.com>
Change-Id: I5a2ff1cd1bed557e793d45119232cf87032ddd7b
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46851
Reviewed-by: Furquan Shaikh <furquan@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-10-30 18:34:19 +00:00
Marc Jones 53b465d1c1 soc/intel/xeon_sp: Move read_msr_ppin() to common util.c
Move CPX and SKX read_msr_ppin() to common util.c file.
Update drivers/ocp/smbios #include to match.

Change-Id: I4c4281d2d5ce679f5444a502fa88df04de9f2cd8
Signed-off-by: Marc Jones <marcjones@sysproconsulting.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46479
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jay Talbott <JayTalbott@sysproconsulting.com>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
2020-10-30 17:13:53 +00:00
Marc Jones 1f500845b4 soc/intel/xeon_sp: Move common chip.c code
Move common CPX and SKX chip.c code to chip_common.c.

Change-Id: I158882ab15659858c2b13b4a3e02a26ef8d4ed3c
Signed-off-by: Marc Jones <marcjones@sysproconsulting.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46478
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Jay Talbott <JayTalbott@sysproconsulting.com>
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
2020-10-30 17:13:31 +00:00