Peter Lemenkov has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/37297 )
Change subject: mb/lenovo/x220/devicetree: Use subsystemid inheritance
......................................................................
mb/lenovo/x220/devicetree: Use subsystemid inheritance
Change-Id: Ia9367d03b6f97f1eb8c35045fd7bb79e5f45b535
Signed-off-by: Peter Lemenkov <lemenkov(a)gmail.com>
---
M src/mainboard/lenovo/x220/devicetree.cb
1 file changed, 15 insertions(+), 42 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/97/37297/1
diff --git a/src/mainboard/lenovo/x220/devicetree.cb b/src/mainboard/lenovo/x220/devicetree.cb
index 26fa1a4..5ae1427 100644
--- a/src/mainboard/lenovo/x220/devicetree.cb
+++ b/src/mainboard/lenovo/x220/devicetree.cb
@@ -37,13 +37,11 @@
register "pci_mmio_size" = "1024"
device domain 0 on
- device pci 00.0 on
- subsystemid 0x17aa 0x21db
- end # host bridge
+ subsystemid 0x17aa 0x21db inherit
+
+ device pci 00.0 on end # host bridge
device pci 01.0 off end # PCIe Bridge for discrete graphics
- device pci 02.0 on
- subsystemid 0x17aa 0x21db
- end # vga controller
+ device pci 02.0 on end # vga controller
chip southbridge/intel/bd82x6x # Intel Series 6 Cougar Point PCH
# GPI routing
@@ -80,49 +78,29 @@
device pci 19.0 on
subsystemid 0x17aa 0x21ce
end # Intel Gigabit Ethernet
- device pci 1a.0 on
- subsystemid 0x17aa 0x21db
- end # USB2 EHCI #2
- device pci 1b.0 on
- subsystemid 0x17aa 0x21db
- end # High Definition Audio
- device pci 1c.0 on
- subsystemid 0x17aa 0x21db
- end # PCIe Port #1
- device pci 1c.1 on
- subsystemid 0x17aa 0x21db
- end # PCIe Port #2 (wlan)
- device pci 1c.2 on
- subsystemid 0x17aa 0x21db
- end # PCIe Port #3
+ device pci 1a.0 on end # USB2 EHCI #2
+ device pci 1b.0 on end # High Definition Audio
+ device pci 1c.0 on end # PCIe Port #1
+ device pci 1c.1 on end # PCIe Port #2 (wlan)
+ device pci 1c.2 on end # PCIe Port #3
device pci 1c.3 on
- subsystemid 0x17aa 0x21db
smbios_slot_desc "7" "3" "ExpressCard Slot" "8"
end # PCIe Port #4
device pci 1c.4 on
- subsystemid 0x17aa 0x21db
chip drivers/ricoh/rce822
register "sdwppol" = "1"
register "disable_mask" = "0x87"
- device pci 00.0 on
- subsystemid 0x17aa 0x21fa
- end
+ device pci 00.0 on end
end
end # PCIe Port #5 (SD)
device pci 1c.5 off end # PCIe Port #6
- device pci 1c.6 on
- subsystemid 0x17aa 0x21db
- end # PCIe Port #7
+ device pci 1c.6 on end # PCIe Port #7
device pci 1c.7 off end # PCIe Port #8
- device pci 1d.0 on
- subsystemid 0x17aa 0x21db
- end # USB2 EHCI #1
+ device pci 1d.0 on end # USB2 EHCI #1
device pci 1e.0 off end # PCI bridge
device pci 1f.0 on #LPC bridge
- subsystemid 0x17aa 0x21db
chip ec/lenovo/pmh7
- device pnp ff.1 on # dummy
- end
+ device pnp ff.1 on end # dummy
register "backlight_enable" = "0x01"
register "dock_event_enable" = "0x01"
end
@@ -172,11 +150,8 @@
register "wwan_gpio_lvl" = "0"
end
end # LPC bridge
- device pci 1f.2 on
- subsystemid 0x17aa 0x21db
- end # SATA Controller 1
+ device pci 1f.2 on end # SATA Controller 1
device pci 1f.3 on
- subsystemid 0x17aa 0x21db
# eeprom, 8 virtual devices, same chip
chip drivers/i2c/at24rf08c
device i2c 54 on end
@@ -190,9 +165,7 @@
end
end # SMBus
device pci 1f.5 off end # SATA Controller 2
- device pci 1f.6 on
- subsystemid 0x17aa 0x21db
- end # Thermal
+ device pci 1f.6 on end # Thermal
end
end
end
--
To view, visit https://review.coreboot.org/c/coreboot/+/37297
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ia9367d03b6f97f1eb8c35045fd7bb79e5f45b535
Gerrit-Change-Number: 37297
Gerrit-PatchSet: 1
Gerrit-Owner: Peter Lemenkov <lemenkov(a)gmail.com>
Gerrit-Reviewer: Alexander Couzens <lynxis(a)fe80.eu>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Peter Lemenkov <lemenkov(a)gmail.com>
Gerrit-MessageType: newchange
Jacob Garber has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/40815 )
Change subject: [TEST] Enable link time optimization
......................................................................
[TEST] Enable link time optimization
Enable LTO to shake out the bugs.
Current problems:
- GCC does not track symbol origins when using LTO, so it must be
disabled for AGESA so it can be excluded from the illegal_globals check.
- GCC segfaults when compiling ARMV7
- Most of the Google boards do not compile because of a missing
reference to _watchdog_tombstone
Change-Id: I37474d4adbf653729bb2e631a1ff812b4319c17a
Signed-off-by: Jacob Garber <jgarber1(a)ualberta.ca>
---
M src/Kconfig
M src/vendorcode/amd/agesa/Makefile.inc
2 files changed, 7 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/15/40815/1
diff --git a/src/Kconfig b/src/Kconfig
index e4821e8..375bca2 100644
--- a/src/Kconfig
+++ b/src/Kconfig
@@ -116,7 +116,7 @@
config LTO
bool "Use link time optimization (LTO)"
- default n
+ default y
depends on COMPILER_GCC
help
Compile with link time optimization. This can often decrease the
diff --git a/src/vendorcode/amd/agesa/Makefile.inc b/src/vendorcode/amd/agesa/Makefile.inc
index b96af84..3e4a53c 100644
--- a/src/vendorcode/amd/agesa/Makefile.inc
+++ b/src/vendorcode/amd/agesa/Makefile.inc
@@ -14,6 +14,12 @@
AGESA_CFLAGS := -march=k8-sse3 -mtune=k8-sse3 -fno-strict-aliasing
+# GCC currently does not track symbol origins when using LTO, so
+# AGESA gets caught in the illegal_globals check. Disable for now.
+ifeq ($(CONFIG_LTO),y)
+AGESA_CFLAGS += -fno-lto
+endif
+
CFLAGS_x86_32 += $(AGESA_CFLAGS)
CFLAGS_x86_64 += $(AGESA_CFLAGS)
--
To view, visit https://review.coreboot.org/c/coreboot/+/40815
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I37474d4adbf653729bb2e631a1ff812b4319c17a
Gerrit-Change-Number: 40815
Gerrit-PatchSet: 1
Gerrit-Owner: Jacob Garber <jgarber1(a)ualberta.ca>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-MessageType: newchange
Subrata Banik has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/44014 )
Change subject: src/soc/intel/common/block: Mark only TSEG range as IO_CACHEABLE
......................................................................
src/soc/intel/common/block: Mark only TSEG range as IO_CACHEABLE
This patch ensures that the TSEG region is only mapped as cacheable so
that one can perform SMRAM relocation faster.
Ideally don't need to mark the entire TOP_OF_RAM till BGSM range (used for
ME stolen memory, PTT, DPR, PRMRR, TSEG etc) as cacheable as no executable code
exist there except TSEG region. Hence only mark TSEG range as cacheable (+ reserved)
and other ranges as reserve alone.
TEST=Able to build and boot ICL, TGL RVP.
Without this CL:
PCI: 00:00.0 resource base 77000000 size 4800000 align 0 gran 0 limit 0 flags f0004200 index 9
PCI: 00:00.0 resource base 7b800000 size 4400000 align 0 gran 0 limit 0 flags f0000200 index a
With this CL:
PCI: 00:00.0 resource base 77000000 size 4000000 align 0 gran 0 limit 0 flags f0000200 index 9
PCI: 00:00.0 resource base 7b000000 size 800000 align 0 gran 0 limit 0 flags f0004200 index a
PCI: 00:00.0 resource base 7b800000 size 4400000 align 0 gran 0 limit 0 flags f0000200 index b
Change-Id: I64c14b14caf0a53219fdc02ec6bbd375955a0c8e
Signed-off-by: Subrata Banik <subrata.banik(a)intel.com>
---
M src/soc/intel/common/block/systemagent/systemagent.c
1 file changed, 6 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/14/44014/1
diff --git a/src/soc/intel/common/block/systemagent/systemagent.c b/src/soc/intel/common/block/systemagent/systemagent.c
index e12e07c..b15ca01 100644
--- a/src/soc/intel/common/block/systemagent/systemagent.c
+++ b/src/soc/intel/common/block/systemagent/systemagent.c
@@ -173,8 +173,13 @@
sa_get_mem_map(dev, &sa_map_values[0]);
- /* top_of_ram -> BGSM */
+ /* top_of_ram -> TSEG */
base_k = top_of_ram;
+ size_k = sa_map_values[SA_TSEG_REG] - base_k;
+ mmio_resource(dev, index++, base_k / KiB, size_k / KiB);
+
+ /* TSEG -> BGSM */
+ base_k = sa_map_values[SA_TSEG_REG];
size_k = sa_map_values[SA_BGSM_REG] - base_k;
reserved_ram_resource(dev, index++, base_k / KiB, size_k / KiB);
--
To view, visit https://review.coreboot.org/c/coreboot/+/44014
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I64c14b14caf0a53219fdc02ec6bbd375955a0c8e
Gerrit-Change-Number: 44014
Gerrit-PatchSet: 1
Gerrit-Owner: Subrata Banik <subrata.banik(a)intel.com>
Gerrit-MessageType: newchange
Duncan Laurie has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/48682 )
Change subject: soc/intel/common/block/pcie/rtd3: Make changes to support S3
......................................................................
soc/intel/common/block/pcie/rtd3: Make changes to support S3
The RTD3 ACPI _ON method will unconditionally attempt to re-initialize
the device, setting up GPIOs, clocks, and the L23 ready exit flow.
When using S3 instead of S0ix this work is not needed and instead
results in the device disappearing and the resume failing in the OS.
BUG=b:174776411
TEST=test S3 and S0ix on volteer device with both NVMe and SD using
the RTD3 driver to ensure suspend/resume works in both cases.
Change-Id: I6bd7d001890939850381858fe663366472aacefc
---
M src/soc/intel/common/block/pcie/rtd3/rtd3.c
1 file changed, 36 insertions(+), 20 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/82/48682/1
diff --git a/src/soc/intel/common/block/pcie/rtd3/rtd3.c b/src/soc/intel/common/block/pcie/rtd3/rtd3.c
index be412e7..52a7d03 100644
--- a/src/soc/intel/common/block/pcie/rtd3/rtd3.c
+++ b/src/soc/intel/common/block/pcie/rtd3/rtd3.c
@@ -74,12 +74,46 @@
acpigen_write_store_int_to_namestr(1, ACPI_REG_PCI_L23_SAVE_STATE);
}
+static void pcie_rtd3_check_gpio(const struct soc_intel_common_block_pcie_rtd3_config *config)
+{
+ const struct acpi_gpio *gpio;
+
+ /* Use enable GPIO for status if provided, otherwise use reset GPIO. */
+ if (config->enable_gpio.pin_count)
+ gpio = &config->enable_gpio;
+ else
+ gpio = &config->reset_gpio;
+
+ /* Read current GPIO value into Local0. */
+ acpigen_get_tx_gpio(gpio);
+
+ /* Ensure check works for both active low and active high GPIOs. */
+ acpigen_write_store_int_to_op(gpio->active_low, LOCAL1_OP);
+
+ acpigen_write_if_lequal_op_op(LOCAL0_OP, LOCAL1_OP);
+ acpigen_write_store_int_to_op(0, LOCAL0_OP);
+ acpigen_pop_len(); /* If */
+ acpigen_write_else();
+ acpigen_write_store_int_to_op(1, LOCAL0_OP);
+ acpigen_pop_len(); /* Else */
+}
+
static void
pcie_rtd3_acpi_method_on(unsigned int pcie_rp,
const struct soc_intel_common_block_pcie_rtd3_config *config)
{
acpigen_write_method_serialized("_ON", 0);
+ /*
+ * Exit early if device status GPIOs indicate device is already in the on/ready state.
+ * This will happen if S3 resume is used instead of S0ix resume where coreboot has
+ * already re-initalized the device and the ACPI code does not need to run.
+ */
+ pcie_rtd3_check_gpio(config);
+ acpigen_write_if_lequal_op_int(LOCAL0_OP, 1);
+ acpigen_write_return_op(ZERO_OP);
+ acpigen_pop_len(); /* If */
+
/* Assert enable GPIO to turn on device power. */
if (config->enable_gpio.pin_count) {
acpigen_enable_tx_gpio(&config->enable_gpio);
@@ -140,28 +174,10 @@
pcie_rtd3_acpi_method_status(int pcie_rp,
const struct soc_intel_common_block_pcie_rtd3_config *config)
{
- const struct acpi_gpio *gpio;
-
acpigen_write_method("_STA", 0);
- /* Use enable GPIO for status if provided, otherwise use reset GPIO. */
- if (config->enable_gpio.pin_count)
- gpio = &config->enable_gpio;
- else
- gpio = &config->reset_gpio;
-
- /* Read current GPIO value into Local0. */
- acpigen_get_tx_gpio(gpio);
-
- /* Ensure check works for both active low and active high GPIOs. */
- acpigen_write_store_int_to_op(gpio->active_low, LOCAL1_OP);
-
- acpigen_write_if_lequal_op_op(LOCAL0_OP, LOCAL1_OP);
- acpigen_write_return_op(ZERO_OP);
- acpigen_pop_len(); /* If */
- acpigen_write_else();
- acpigen_write_return_op(ONE_OP);
- acpigen_pop_len(); /* Else */
+ pcie_rtd3_check_gpio(config);
+ acpigen_write_return_op(LOCAL0_OP);
acpigen_pop_len(); /* Method */
}
--
To view, visit https://review.coreboot.org/c/coreboot/+/48682
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I6bd7d001890939850381858fe663366472aacefc
Gerrit-Change-Number: 48682
Gerrit-PatchSet: 1
Gerrit-Owner: Duncan Laurie <dlaurie(a)chromium.org>
Gerrit-MessageType: newchange