Hello Duan huayang,
I'd like you to do a code review. Please visit
https://review.coreboot.org/c/coreboot/+/39097
to review the following change.
Change subject: soc/mediatek/mt8183: Add get dram type API at ATF
......................................................................
soc/mediatek/mt8183: Add get dram type API at ATF
DVFS module need know the dram type at ATF for loading the correct spm binary.
BRANCH=kukui
BUG=none
TEST=bootup pass
Change-Id: I20afc00c4c671abcbb6f36eb8e3e364529e9389c
Signed-off-by: Huayang Duan <huayang.duan(a)mediatek.com>
---
M src/mainboard/google/kukui/mainboard.c
1 file changed, 11 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/97/39097/1
diff --git a/src/mainboard/google/kukui/mainboard.c b/src/mainboard/google/kukui/mainboard.c
index 844496d..da39c1c 100644
--- a/src/mainboard/google/kukui/mainboard.c
+++ b/src/mainboard/google/kukui/mainboard.c
@@ -184,8 +184,19 @@
.gpio = { .polarity = ARM_TF_GPIO_LEVEL_HIGH },
};
+ /* use .polarity to save dram type value */
+ static struct bl_aux_param_gpio param_dram_type = {
+ .h = { .type = BL_AUX_PARAM_MTK_DRAM_TYPE },
+#if CONFIG(MT8183_DRAM_EMCP)
+ .gpio = { .polarity = DRAMC_CONFIG_EMCP },
+#else
+ .gpio = { .polarity = 0 },
+#endif
+ };
+
param_reset.gpio.index = GPIO_RESET.id;
register_bl31_aux_param(¶m_reset.h);
+ register_bl31_aux_param(¶m_dram_type.h);
}
static void mainboard_init(struct device *dev)
--
To view, visit https://review.coreboot.org/c/coreboot/+/39097
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I20afc00c4c671abcbb6f36eb8e3e364529e9389c
Gerrit-Change-Number: 39097
Gerrit-PatchSet: 1
Gerrit-Owner: huayang duan <huayangduan(a)gmail.com>
Gerrit-Reviewer: Duan huayang <huayang.duan(a)mediatek.com>
Gerrit-MessageType: newchange
Sridhar Siricilla has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/37283 )
Change subject: soc/intel/common/block/cse: Modify handling of HMRFPO_ENABLE command
......................................................................
soc/intel/common/block/cse: Modify handling of HMRFPO_ENABLE command
Below changes have been done in the send_hmrfpo_enable_msg():
1. Allow execution of HMRFPO_ENABLE command only when CSE's
operation mode is Temp Disable Mode.
2. Add check for response status.
3. Add description for the send_hmrfpo_enable_msg()
The HMRFPO (Host ME Region Flash Protection Override) mode prevents CSE to
execute SPI I/O cycles to CSE region, and unlocks the CSE region to perfom
updates to it.This command is only valid before EOP.
When MRP feature is enabled, procedure to place CSE in HMRFPO mode:
1. Ensure CSE to boot from BP1. When CSE boots from BP1, it will have
opmode: Temp Disable Mode.
2. Send HMRFPO_ENABLE command to CSE.
Then, CSE enters HMRFPO mode.
The MRP feature enables CSE FW to support redundant boot partitions, and
allow CSE to operate with 'Temporary Disable Mode'. The feature is
enabled through FIT settings during build phase. Also, CSE can boot from
either BP1 or BP2.
CSE Image Layout with MRP enabled:
= [RO] + [RW + DATA PART] = [BP1] + [BP2 + BP3 + DATA PART]
Here, BP1 is replica of BP2, and the BP1 will be CSE's RO partition and
[BP2 + BP3 + DATA PART] together will represent CSE's RW partition.
Existing CSE Image Layout without MRP feature:
= BP2 + BP3 + DATA PART
Change-Id: I7c87998fa105947e5ba4638a8e68625e46703448
Signed-off-by: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
---
M src/soc/intel/common/block/cse/cse.c
M src/soc/intel/common/block/include/intelblocks/cse.h
2 files changed, 24 insertions(+), 8 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/83/37283/1
diff --git a/src/soc/intel/common/block/cse/cse.c b/src/soc/intel/common/block/cse/cse.c
index 46ad8ce..b60d888 100644
--- a/src/soc/intel/common/block/cse/cse.c
+++ b/src/soc/intel/common/block/cse/cse.c
@@ -659,15 +659,13 @@
printk(BIOS_DEBUG, "HECI: Send HMRFPO Enable Command\n");
hfs1.data = me_read_config32(PCI_ME_HFSTS1);
+
/*
* This command can be run only if:
- * - Working state is normal and
- * - Operation mode is normal or temporary disable mode.
+ * - Operation mode is temporary disable mode.
*/
- if (hfs1.fields.working_state != ME_HFS_CWS_NORMAL ||
- (hfs1.fields.operation_mode != ME_HFS_MODE_NORMAL &&
- hfs1.fields.operation_mode != ME_HFS_MODE_TEMP_DISABLE)) {
- printk(BIOS_ERR, "HECI: ME not in required Mode\n");
+ if (hfs1.fields.operation_mode != ME_HFS_MODE_TEMP_DISABLE) {
+ printk(BIOS_ERR, "HECI: ME is not in expected mode/state(0x%x)\n", hfs1.data);
goto failed;
}
@@ -679,6 +677,12 @@
printk(BIOS_ERR, "HECI: Resp Failed:%d\n", resp.hdr.result);
goto failed;
}
+
+ if (resp.status) {
+ printk(BIOS_ERR, "HECI: Enable Failed, resp status:%d\n", resp.status);
+ goto failed;
+ }
+
return 1;
failed:
diff --git a/src/soc/intel/common/block/include/intelblocks/cse.h b/src/soc/intel/common/block/include/intelblocks/cse.h
index 3c00b87..53f5493 100644
--- a/src/soc/intel/common/block/include/intelblocks/cse.h
+++ b/src/soc/intel/common/block/include/intelblocks/cse.h
@@ -128,8 +128,20 @@
int send_heci_reset_req_message(uint8_t rst_type);
/*
- * Send HMRFPO_ENABLE command.
- * returns 0 on failure and 1 on success.
+ * Sends HMRFPO_ENABLE command.
+ * HMRFPO - Host ME Region Flash Protection Override.
+ * When MRP feature is enabled, procedure to place CSE in HMRFPO (SECOVER_MEI_MSG) mode:
+ * 1. Ensure CSE boots from BP1(RO).
+ * - Send set_next_boot_partition(BP1)
+ * - Issue CSE Only Reset
+ * 2. Send HMRFPO_ENABLE command to CSE. Further, no reset is required.
+ *
+ * The HMRFPO mode prevents CSE to execute SPI I/O cycles to CSE region, and unlocks
+ * the CSE region to perfom updates to it.
+ * This command is only valid before EOP.
+ *
+ * Returns 0 on failure to send heci command and to enable hmrfpo mode, and 1 on success.
+ *
*/
int send_hmrfpo_enable_msg(void);
--
To view, visit https://review.coreboot.org/c/coreboot/+/37283
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I7c87998fa105947e5ba4638a8e68625e46703448
Gerrit-Change-Number: 37283
Gerrit-PatchSet: 1
Gerrit-Owner: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
Gerrit-MessageType: newchange
Angel Pons has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/38942 )
Change subject: treewide: Replace uses of "Nehalem"
......................................................................
treewide: Replace uses of "Nehalem"
The code in coreboot is actually for the Arrandale processors, which
are a MCM (Multi-Chip Module) with two different dies:
- Hillel: 32nm Westmere dual-core CPU
- Ironlake: 45nm northbridge with integrated graphics
This has nothing to do with the older, single-die Nehalem processors.
Therefore, replace the references to Nehalem with the correct names.
Change-Id: I8c10a2618c519d2411211b9b8f66d24f0018f908
Signed-off-by: Angel Pons <th3fanbus(a)gmail.com>
---
M src/cpu/intel/common/fsb.c
M src/cpu/intel/model_2065x/acpi.c
M src/cpu/intel/model_2065x/model_2065x.h
M src/drivers/intel/gma/Kconfig
M src/include/cpu/intel/em64t101_save_state.h
M src/northbridge/intel/ironlake/northbridge.c
M src/security/tpm/Kconfig
7 files changed, 9 insertions(+), 9 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/42/38942/1
diff --git a/src/cpu/intel/common/fsb.c b/src/cpu/intel/common/fsb.c
index 726ab1c..3dfcd0b 100644
--- a/src/cpu/intel/common/fsb.c
+++ b/src/cpu/intel/common/fsb.c
@@ -48,7 +48,7 @@
*fsb = core2_fsb[rdmsr(MSR_FSB_FREQ).lo & 7];
*ratio = (rdmsr(IA32_PERF_STATUS).hi >> 8) & 0x1f;
break;
- case 0x25: /* Nehalem BCLK fixed at 133MHz */
+ case 0x25: /* Arrandale BCLK fixed at 133MHz */
*fsb = 133;
*ratio = (rdmsr(MSR_PLATFORM_INFO).lo >> 8) & 0xff;
break;
diff --git a/src/cpu/intel/model_2065x/acpi.c b/src/cpu/intel/model_2065x/acpi.c
index 1868876..af2606c 100644
--- a/src/cpu/intel/model_2065x/acpi.c
+++ b/src/cpu/intel/model_2065x/acpi.c
@@ -338,5 +338,5 @@
}
struct chip_operations cpu_intel_model_2065x_ops = {
- CHIP_NAME("Intel Nehalem CPU")
+ CHIP_NAME("Intel Arrandale CPU")
};
diff --git a/src/cpu/intel/model_2065x/model_2065x.h b/src/cpu/intel/model_2065x/model_2065x.h
index 730ab35..0a07f3c 100644
--- a/src/cpu/intel/model_2065x/model_2065x.h
+++ b/src/cpu/intel/model_2065x/model_2065x.h
@@ -15,7 +15,7 @@
#ifndef _CPU_INTEL_MODEL_2065X_H
#define _CPU_INTEL_MODEL_2065X_H
-/* Nehalem bus clock is fixed at 133MHz */
+/* Arrandale bus clock is fixed at 133MHz */
#define IRONLAKE_BCLK 133
#define MSR_CORE_THREAD_COUNT 0x35
diff --git a/src/drivers/intel/gma/Kconfig b/src/drivers/intel/gma/Kconfig
index 87889d3..c35e44e 100644
--- a/src/drivers/intel/gma/Kconfig
+++ b/src/drivers/intel/gma/Kconfig
@@ -39,7 +39,7 @@
To be set by northbridge or mainboard Kconfig. For most platforms,
there is no choice, i.e. for i945 and gm45 the SSC reference always
differs from the display reference clock (i945: 66Mhz SSC vs. 48MHz
- DREF; gm45: 100MHz SSC vs. 96Mhz DREF), for Nehalem and newer, it's
+ DREF; gm45: 100MHz SSC vs. 96Mhz DREF), for Arrandale and newer, it's
the same frequency for SSC/non-SSC (120MHz). The only, currently
supported platform with a choice seems to be Pineview, where the
alternative is 100MHz vs. the default 96MHz.
diff --git a/src/include/cpu/intel/em64t101_save_state.h b/src/include/cpu/intel/em64t101_save_state.h
index 7493c85..5d3f9ed 100644
--- a/src/include/cpu/intel/em64t101_save_state.h
+++ b/src/include/cpu/intel/em64t101_save_state.h
@@ -20,7 +20,7 @@
/* Intel Revision 30101 SMM State-Save Area
* The following processor architectures use this:
- * - Nehalem
+ * - Westmere
* - SandyBridge
* - IvyBridge
* - Haswell
diff --git a/src/northbridge/intel/ironlake/northbridge.c b/src/northbridge/intel/ironlake/northbridge.c
index fe8eed3..91bcc11 100644
--- a/src/northbridge/intel/ironlake/northbridge.c
+++ b/src/northbridge/intel/ironlake/northbridge.c
@@ -263,10 +263,10 @@
.ops_pci = &intel_pci_ops,
};
-static const struct pci_driver mc_driver_44 __pci_driver = {
+static const struct pci_driver mc_driver_ard __pci_driver = {
.ops = &mc_ops,
.vendor = PCI_VENDOR_ID_INTEL,
- .device = 0x0044, /* Nehalem */
+ .device = 0x0044, /* Arrandale DRAM controller */
};
static struct device_operations cpu_bus_ops = {
@@ -288,7 +288,7 @@
}
struct chip_operations northbridge_intel_ironlake_ops = {
- CHIP_NAME("Intel i7 (Nehalem) integrated Northbridge")
+ CHIP_NAME("Intel i7 (Arrandale) integrated Northbridge")
.enable_dev = enable_dev,
.init = ironlake_init,
};
diff --git a/src/security/tpm/Kconfig b/src/security/tpm/Kconfig
index 95c0bb9..fbe1735 100644
--- a/src/security/tpm/Kconfig
+++ b/src/security/tpm/Kconfig
@@ -99,7 +99,7 @@
Select this to ignore POSTINIT INVALID return codes on TPM
startup. This is useful on platforms where a previous stage
issued a TPM startup. Examples of use cases are Intel TXT
- or VBOOT on the Intel Nehalem northbridge which issues a
+ or VBOOT on the Intel Arrandale processor, which issues a
CPU-only reset during the romstage.
endmenu # Trusted Platform Module (tpm)
--
To view, visit https://review.coreboot.org/c/coreboot/+/38942
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I8c10a2618c519d2411211b9b8f66d24f0018f908
Gerrit-Change-Number: 38942
Gerrit-PatchSet: 1
Gerrit-Owner: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-MessageType: newchange
Sridhar Siricilla has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/39023 )
Change subject: soc/intel/common: Log CSE's RO and RW versions
......................................................................
soc/intel/common: Log CSE's RO and RW versions
Since CSE FW Custom SKU has RO and RW partitions and each can have
different versions, so skip sending GET_FW_VERSION command which
fetches version of CSE RW.
Instead call cse_print_boot_partition_info() which logs CSE's RO(BP1)
and RW(BP2) versions. The cse_print_boot_partition_info() function sends
GET_BOOT_PARTITION_INFO HECI command to CSE.
TEST=Verified on hatch
Change-Id: Iffd2986adaecf24590e635deaa9794ad85a24115
Signed-off-by: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
---
M src/soc/intel/common/block/cse/cse.c
1 file changed, 3 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/23/39023/1
diff --git a/src/soc/intel/common/block/cse/cse.c b/src/soc/intel/common/block/cse/cse.c
index bf2ae3f..e0f42d4 100644
--- a/src/soc/intel/common/block/cse/cse.c
+++ b/src/soc/intel/common/block/cse/cse.c
@@ -834,8 +834,10 @@
* Ignore if ME Firmware SKU type is custom since
* print_boot_partition_info() logs RO(BP1) and RW(BP2) versions.
*/
- if (cse_is_hfs3_fw_sku_custom())
+ if (cse_is_hfs3_fw_sku_custom()) {
+ cse_print_boot_partition_info();
return;
+ }
/*
* Prerequisites:
--
To view, visit https://review.coreboot.org/c/coreboot/+/39023
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Iffd2986adaecf24590e635deaa9794ad85a24115
Gerrit-Change-Number: 39023
Gerrit-PatchSet: 1
Gerrit-Owner: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Sridhar Siricilla <sridhar.siricilla(a)intel.com>
Gerrit-MessageType: newchange