Johnny Lin has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/40234 )
Change subject: drivers/ipmi: Add IPMI KCS support in romstage
......................................................................
drivers/ipmi: Add IPMI KCS support in romstage
It's necessary to run IPMI commands in romstage for writing error SEL
such as memory initialization error SEL, and also for other usages
such as starting FRB2 timer, OEM commands, etc.
Change-Id: Ie3198965670454b123e570f9056673fdf515f52b
Signed-off-by: Johnny Lin <johnny_lin(a)wiwynn.com>
---
M src/drivers/ipmi/Kconfig
M src/drivers/ipmi/Makefile.inc
M src/drivers/ipmi/ipmi_kcs.h
A src/drivers/ipmi/ipmi_kcs_ops_premem.c
4 files changed, 129 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/34/40234/1
diff --git a/src/drivers/ipmi/Kconfig b/src/drivers/ipmi/Kconfig
index 37cfc0d..0304cb0 100644
--- a/src/drivers/ipmi/Kconfig
+++ b/src/drivers/ipmi/Kconfig
@@ -18,3 +18,10 @@
IPMB messages are limited to 32-bytes total. When the
data size is larger than this value, IPMI can complete
reading/writing the data over multiple commands.
+
+config IPMI_KCS_ROMSTAGE
+ bool
+ default n
+ depends on IPMI_KCS
+ help
+ IPMI KCS support in romstage.
diff --git a/src/drivers/ipmi/Makefile.inc b/src/drivers/ipmi/Makefile.inc
index 973fff8..06a3433 100644
--- a/src/drivers/ipmi/Makefile.inc
+++ b/src/drivers/ipmi/Makefile.inc
@@ -2,3 +2,6 @@
ramstage-$(CONFIG_IPMI_KCS) += ipmi_kcs_ops.c
ramstage-$(CONFIG_IPMI_KCS) += ipmi_ops.c
ramstage-$(CONFIG_IPMI_KCS) += ipmi_fru.c
+romstage-$(CONFIG_IPMI_KCS_ROMSTAGE) += ipmi_kcs_ops_premem.c
+romstage-$(CONFIG_IPMI_KCS_ROMSTAGE) += ipmi_kcs.c
+romstage-$(CONFIG_IPMI_KCS_ROMSTAGE) += ipmi_ops.c
diff --git a/src/drivers/ipmi/ipmi_kcs.h b/src/drivers/ipmi/ipmi_kcs.h
index 9a04377..5de77ed 100644
--- a/src/drivers/ipmi/ipmi_kcs.h
+++ b/src/drivers/ipmi/ipmi_kcs.h
@@ -40,6 +40,9 @@
const unsigned char *inmsg, int inlen,
unsigned char *outmsg, int outlen);
+/* Run basic IPMI init functions in romstage from the provided PnP device */
+void ipmi_kcs_premem_init(const u16 port, const u16 device);
+
struct ipmi_rsp {
uint8_t lun;
uint8_t cmd;
diff --git a/src/drivers/ipmi/ipmi_kcs_ops_premem.c b/src/drivers/ipmi/ipmi_kcs_ops_premem.c
new file mode 100644
index 0000000..e601041
--- /dev/null
+++ b/src/drivers/ipmi/ipmi_kcs_ops_premem.c
@@ -0,0 +1,116 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; version 2 of
+ * the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <console/console.h>
+
+#include <device/pnp.h>
+#include <delay.h>
+#include <timer.h>
+#include "ipmi_kcs.h"
+#include "chip.h"
+
+static int ipmi_get_bmc_self_test_result(const struct device *dev,
+ struct ipmi_selftest_rsp *rsp)
+{
+ int ret;
+
+ ret = ipmi_kcs_message(dev->path.pnp.port, IPMI_NETFN_APPLICATION, 0,
+ IPMI_BMC_GET_SELFTEST_RESULTS, NULL, 0, (u8 *)rsp,
+ sizeof(*rsp));
+
+ if (ret < sizeof(struct ipmi_rsp) || rsp->resp.completion_code) {
+ printk(BIOS_ERR, "IPMI: %s command failed (ret=%d resp=0x%x)\n",
+ __func__, ret, rsp->resp.completion_code);
+ return 1;
+ }
+ if (ret != sizeof(*rsp)) {
+ printk(BIOS_ERR, "IPMI: %s response truncated\n", __func__);
+ return 1;
+ }
+
+ return 0;
+}
+
+void ipmi_kcs_premem_init(const u16 port, const u16 device)
+{
+ const struct drivers_ipmi_config *conf = NULL;
+ struct ipmi_selftest_rsp selftestrsp;
+ uint8_t retry_count;
+ const struct device *dev;
+
+ /* Find IPMI pnp device from devicetree in romstage */
+ dev = dev_find_slot_pnp(port, device);
+
+ if (!dev) {
+ printk(BIOS_ERR, "IPMI: Cannot find pnp device port: %x, device %x\n",
+ port, device);
+ return;
+ }
+ if (!dev->enabled)
+ return;
+
+ printk(BIOS_DEBUG, "IPMI: romstage PNP KCS 0x%x\n", dev->path.pnp.port);
+ if (dev->chip_info)
+ conf = dev->chip_info;
+
+ if (conf && conf->wait_for_bmc && conf->bmc_boot_timeout) {
+ struct stopwatch sw;
+ stopwatch_init_msecs_expire(&sw, conf->bmc_boot_timeout * 1000);
+ printk(BIOS_INFO, "IPMI: Waiting for BMC...\n");
+
+ while (!stopwatch_expired(&sw)) {
+ if (inb(dev->path.pnp.port) != 0xff)
+ break;
+ mdelay(100);
+ }
+ if (stopwatch_expired(&sw)) {
+ printk(BIOS_INFO, "IPMI: Waiting for BMC timed out\n");
+ return;
+ }
+ }
+
+ printk(BIOS_INFO, "Get BMC self test result...");
+ for (retry_count = 0; retry_count < conf->bmc_boot_timeout; retry_count++) {
+ if (!ipmi_get_bmc_self_test_result(dev, &selftestrsp))
+ break;
+
+ mdelay(1000);
+ }
+
+ switch (selftestrsp.result) {
+ case IPMI_APP_SELFTEST_NO_ERROR: /* 0x55 */
+ printk(BIOS_DEBUG, "No Error\n");
+ break;
+ case IPMI_APP_SELFTEST_NOT_IMPLEMENTED: /* 0x56 */
+ printk(BIOS_DEBUG, "Function Not Implemented\n");
+ break;
+ case IPMI_APP_SELFTEST_ERROR: /* 0x57 */
+ printk(BIOS_ERR, "BMC: Corrupted or inaccessible data or device\n");
+ /* Don't write tables if communication failed */
+ break;
+ case IPMI_APP_SELFTEST_FATAL_HW_ERROR: /* 0x58 */
+ printk(BIOS_ERR, "BMC: Fatal Hardware Error\n");
+ /* Don't write tables if communication failed */
+ break;
+ case IPMI_APP_SELFTEST_RESERVED: /* 0xFF */
+ printk(BIOS_DEBUG, "Reserved\n");
+ break;
+
+ default: /* Other Device Specific Hardware Error */
+ printk(BIOS_ERR, "BMC: Device Specific Error\n");
+ /* Don't write tables if communication failed */
+ break;
+ }
+
+}
--
To view, visit https://review.coreboot.org/c/coreboot/+/40234
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ie3198965670454b123e570f9056673fdf515f52b
Gerrit-Change-Number: 40234
Gerrit-PatchSet: 1
Gerrit-Owner: Johnny Lin
Gerrit-MessageType: newchange
Hello build bot (Jenkins), Patrick Georgi, Angel Pons, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/42278
to look at the new patch set (#9).
Change subject: post_code: add defines for missing postcode values
......................................................................
post_code: add defines for missing postcode values
The change introduces new POST codes missing their respective defines
The newly added POST code sets are arranged in logical order of
coreboot stages. The change also is an effort to ensure the added
defines reflect postcodes at the entry of function.
Signed-off-by: Sindhoor Tilak <sindhoor(a)sin9yt.net>
Change-Id: I02d09d0b2bad3f9a93fff54d11a5ba5e53fadbcc
---
M src/include/console/post_codes.h
1 file changed, 304 insertions(+), 15 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/78/42278/9
--
To view, visit https://review.coreboot.org/c/coreboot/+/42278
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I02d09d0b2bad3f9a93fff54d11a5ba5e53fadbcc
Gerrit-Change-Number: 42278
Gerrit-PatchSet: 9
Gerrit-Owner: Sindhoor Tilak <sindhoor(a)sin9yt.net>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-MessageType: newpatchset
Jonas Löffelholz has uploaded a new patch set (#60) to the change originally created by Christian Walter. ( https://review.coreboot.org/c/coreboot/+/37441 )
Change subject: mb/supermicro/x11-lga1151v2-series: Add support for X11SCH-F
......................................................................
mb/supermicro/x11-lga1151v2-series: Add support for X11SCH-F
This commit adds initial support for the Supermicro X11SCH-F.
What is working:
* Aspeed AST2500 graphics output
* Serial console
* SuperIO devicetree config
* Boots into Linux 5.5
* Tested payload EDK II
* SATA slots
* USB slots
* IPMI KCS
* LinuxBoot
* No ACPI error in Windows/Linux
* Windows 10 support
* TPM Support (w/ patched IFD) - Patch IFD at 0x235=0x03 and 0x13E=0x84
Tested with Intel Xeon E-2186G and 64 GB ECC RAM.
Change-Id: I0ab1cb9462607b9af068bc2374508d99c60d0a30
Signed-off-by: Christian Walter <christian.walter(a)9elements.com>
---
M Documentation/mainboard/index.md
A Documentation/mainboard/supermicro/x11-lga1151v2-series/x11-lga1151v2-series.md
A Documentation/mainboard/supermicro/x11-lga1151v2-series/x11sch-f/x11sch-f.md
A Documentation/mainboard/supermicro/x11-lga1151v2-series/x11sch-f/x11sch-f_flash.jpg
M MAINTAINERS
A src/mainboard/supermicro/x11-lga1151v2-series/Kconfig
A src/mainboard/supermicro/x11-lga1151v2-series/Kconfig.name
A src/mainboard/supermicro/x11-lga1151v2-series/Makefile.inc
A src/mainboard/supermicro/x11-lga1151v2-series/board_info.txt
A src/mainboard/supermicro/x11-lga1151v2-series/bootblock.c
A src/mainboard/supermicro/x11-lga1151v2-series/devicetree.cb
A src/mainboard/supermicro/x11-lga1151v2-series/dsdt.asl
A src/mainboard/supermicro/x11-lga1151v2-series/memory.c
A src/mainboard/supermicro/x11-lga1151v2-series/ramstage.c
A src/mainboard/supermicro/x11-lga1151v2-series/romstage.c
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/Makefile.inc
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/board_info.txt
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/gpio.c
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/include/variant/gpio.h
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/include/variant/variants.h
A src/mainboard/supermicro/x11-lga1151v2-series/variants/x11sch-f/overridetree.cb
21 files changed, 1,006 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/41/37441/60
--
To view, visit https://review.coreboot.org/c/coreboot/+/37441
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I0ab1cb9462607b9af068bc2374508d99c60d0a30
Gerrit-Change-Number: 37441
Gerrit-PatchSet: 60
Gerrit-Owner: Christian Walter <christian.walter(a)9elements.com>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Christian Walter <christian.walter(a)9elements.com>
Gerrit-Reviewer: Guido Beyer @ Prodrive Technologies <guido.beyer(a)prodrive-technologies.com>
Gerrit-Reviewer: Justin van Son <justin.van.son(a)prodrive-technologies.com>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Patrick Rudolph <patrick.rudolph(a)9elements.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Philipp Deppenwiese <zaolin.daisuki(a)gmail.com>
Gerrit-Reviewer: Stef van Os <stef.van.os(a)prodrive-technologies.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Reviewer: wouter.eckhardt(a)prodrive-technologies.com
Gerrit-CC: Jonas Löffelholz
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-MessageType: newpatchset
Jamie Ryu has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/42282 )
Change subject: soc/intel/tgl: Disable hybrid storage mode in recovery mode
......................................................................
soc/intel/tgl: Disable hybrid storage mode in recovery mode
This is WA to initialize NVME with CSE Lite in recovery mode.
CSME Lite does not support hybrid storage dynamic configuration in RO.
Hence, hybrid storage mode is disabled in recovery mode for CSME Lite
until the functionality is supported by CSE Lite RO.
BUG=b:158643194
TEST=boot and verified with tglrvp and volteer in recovery mode
Cq-Depend: chrome-internal:3100721
Signed-off-by: Jamie Ryu <jamie.m.ryu(a)intel.com>
Change-Id: I5397cfc007069debe3701bf1e38e81bd17a29f0c
---
M src/soc/intel/tigerlake/fsp_params.c
1 file changed, 12 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/82/42282/1
diff --git a/src/soc/intel/tigerlake/fsp_params.c b/src/soc/intel/tigerlake/fsp_params.c
old mode 100644
new mode 100755
index 926d8eb..e931a22
--- a/src/soc/intel/tigerlake/fsp_params.c
+++ b/src/soc/intel/tigerlake/fsp_params.c
@@ -10,6 +10,7 @@
#include <intelblocks/lpss.h>
#include <intelblocks/xdci.h>
#include <intelpch/lockdown.h>
+#include <security/vboot/vboot_common.h>
#include <soc/gpio_soc_defs.h>
#include <soc/intel/common/vbt.h>
#include <soc/pci_devs.h>
@@ -251,7 +252,17 @@
params->Enable8254ClockGatingOnS3 = !CONFIG_USE_LEGACY_8254_TIMER;
/* Enable Hybrid storage auto detection */
- params->HybridStorageMode = config->HybridStorageMode;
+ if (CONFIG(SOC_INTEL_CSE_LITE_SKU) && vboot_recovery_mode_enabled()) {
+ /*
+ * Since CSME Lite SKU does not support hybrid storage dynamic
+ * configuration in recovery boot mode, dynamic configuration is
+ * disabled as a temporary WA until the fix is available.
+ */
+ printk(BIOS_DEBUG, "cse_lite: recovery mode enabled\n");
+ params->HybridStorageMode = 0;
+ } else {
+ params->HybridStorageMode = config->HybridStorageMode;
+ }
/* USB4/TBT */
for (i = 0; i < ARRAY_SIZE(params->ITbtPcieRootPortEn); i++) {
--
To view, visit https://review.coreboot.org/c/coreboot/+/42282
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I5397cfc007069debe3701bf1e38e81bd17a29f0c
Gerrit-Change-Number: 42282
Gerrit-PatchSet: 1
Gerrit-Owner: Jamie Ryu <jamie.m.ryu(a)intel.com>
Gerrit-MessageType: newchange
Patrick Georgi has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/43008 )
Change subject: Update vboot submodule to upstream master
......................................................................
Update vboot submodule to upstream master
Updating from commit id c531000f:
2020-05-18 20:55:55 +0000 - (vboot: Add recovery reason code for CSE Lite SKU errors)
to commit id 68de90c7:
2020-07-02 11:31:05 +0000 - (Allow building for non-CrOS environments)
This brings in 59 new commits.
Change-Id: I7f3c30511ff4acc60e3581bdab89d685dc7beaa5
Signed-off-by: Patrick Georgi <pgeorgi(a)google.com>
---
M 3rdparty/vboot
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/08/43008/1
diff --git a/3rdparty/vboot b/3rdparty/vboot
index c531000..68de90c 160000
--- a/3rdparty/vboot
+++ b/3rdparty/vboot
@@ -1 +1 @@
-Subproject commit c531000f851418520b6873f65c202d21f141eb84
+Subproject commit 68de90c7e2f4a27d3a76489199176d2ab8f56de1
--
To view, visit https://review.coreboot.org/c/coreboot/+/43008
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I7f3c30511ff4acc60e3581bdab89d685dc7beaa5
Gerrit-Change-Number: 43008
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-MessageType: newchange
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/42749 )
Change subject: util/inteltool: Support dumping more BARs on Skylake mobile SoCs
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit https://review.coreboot.org/c/coreboot/+/42749
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ic43d54ef189d500701872a56e67781a744990328
Gerrit-Change-Number: 42749
Gerrit-PatchSet: 2
Gerrit-Owner: Benjamin Doron <benjamin.doron00(a)gmail.com>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michael Niewöhner
Gerrit-Reviewer: Stefan Reinauer <stefan.reinauer(a)coreboot.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-CC: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Comment-Date: Fri, 03 Jul 2020 20:07:11 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment