Kyösti Mälkki has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/31342
Change subject: cpu/intel/common: Use common tsc_freq_mhz()
......................................................................
cpu/intel/common: Use common tsc_freq_mhz()
Change-Id: I0e7159039751a88d86b6c343be5f085e6e15570a
Signed-off-by: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
---
M src/cpu/intel/common/fsb.c
M src/cpu/intel/haswell/Makefile.inc
D src/cpu/intel/haswell/tsc_freq.c
M src/cpu/intel/model_2065x/Makefile.inc
D src/cpu/intel/model_2065x/tsc_freq.c
M src/cpu/intel/model_206ax/Makefile.inc
D src/cpu/intel/model_206ax/tsc_freq.c
7 files changed, 12 insertions(+), 90 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/42/31342/1
diff --git a/src/cpu/intel/common/fsb.c b/src/cpu/intel/common/fsb.c
index d06739c..f53baa0 100644
--- a/src/cpu/intel/common/fsb.c
+++ b/src/cpu/intel/common/fsb.c
@@ -13,6 +13,7 @@
#include <cpu/cpu.h>
#include <cpu/x86/msr.h>
+#include <cpu/x86/tsc.h>
#include <cpu/intel/speedstep.h>
#include <cpu/intel/fsb.h>
#include <console/console.h>
@@ -105,3 +106,14 @@
printk(BIOS_ERR, "FSB not supported or not found\n");
return -1;
}
+
+unsigned long tsc_freq_mhz(void)
+{
+ int ret, fsb, ratio;
+
+ ret = get_fsb_tsc(&fsb, &ratio);
+ if (ret < 0)
+ die("TSC frequency not known\n");
+
+ return 100 * DIV_ROUND_CLOSEST(ratio * fsb, 100);
+}
diff --git a/src/cpu/intel/haswell/Makefile.inc b/src/cpu/intel/haswell/Makefile.inc
index c317c09..87da59b 100644
--- a/src/cpu/intel/haswell/Makefile.inc
+++ b/src/cpu/intel/haswell/Makefile.inc
@@ -1,7 +1,5 @@
ramstage-y += haswell_init.c
-ramstage-y += tsc_freq.c
romstage-y += romstage.c
-romstage-y += tsc_freq.c
romstage-y += ../car/romstage.c
ramstage-y += acpi.c
@@ -12,7 +10,6 @@
postcar-$(CONFIG_CACHE_RELOCATED_RAMSTAGE_OUTSIDE_CBMEM) += stage_cache.c
smm-$(CONFIG_HAVE_SMI_HANDLER) += finalize.c
-smm-$(CONFIG_HAVE_SMI_HANDLER) += tsc_freq.c
ifneq ($(CONFIG_TSC_MONOTONIC_TIMER),y)
ramstage-y += monotonic_timer.c
diff --git a/src/cpu/intel/haswell/tsc_freq.c b/src/cpu/intel/haswell/tsc_freq.c
deleted file mode 100644
index b05cae5..0000000
--- a/src/cpu/intel/haswell/tsc_freq.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright (C) 2013 Google, Inc.
- *
- * 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 <stdint.h>
-#include <cpu/x86/msr.h>
-#include <cpu/x86/tsc.h>
-#include "cpu/intel/haswell/haswell.h"
-
-unsigned long tsc_freq_mhz(void)
-{
- msr_t platform_info;
-
- platform_info = rdmsr(MSR_PLATFORM_INFO);
- return HASWELL_BCLK * ((platform_info.lo >> 8) & 0xff);
-}
diff --git a/src/cpu/intel/model_2065x/Makefile.inc b/src/cpu/intel/model_2065x/Makefile.inc
index ec8643a..b8e474d 100644
--- a/src/cpu/intel/model_2065x/Makefile.inc
+++ b/src/cpu/intel/model_2065x/Makefile.inc
@@ -10,9 +10,6 @@
subdirs-y += ../smm/gen1
subdirs-y += ../common
-ramstage-y += tsc_freq.c
-romstage-y += tsc_freq.c
-smm-$(CONFIG_HAVE_SMI_HANDLER) += tsc_freq.c
ramstage-y += acpi.c
diff --git a/src/cpu/intel/model_2065x/tsc_freq.c b/src/cpu/intel/model_2065x/tsc_freq.c
deleted file mode 100644
index 041785b..0000000
--- a/src/cpu/intel/model_2065x/tsc_freq.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright (C) 2013 Google, Inc.
- *
- * 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 <stdint.h>
-#include <cpu/x86/msr.h>
-#include <cpu/x86/tsc.h>
-#include "model_2065x.h"
-
-unsigned long tsc_freq_mhz(void)
-{
- msr_t platform_info;
-
- platform_info = rdmsr(MSR_PLATFORM_INFO);
- return NEHALEM_BCLK * ((platform_info.lo >> 8) & 0xff);
-}
diff --git a/src/cpu/intel/model_206ax/Makefile.inc b/src/cpu/intel/model_206ax/Makefile.inc
index d193e60..6339ba0 100644
--- a/src/cpu/intel/model_206ax/Makefile.inc
+++ b/src/cpu/intel/model_206ax/Makefile.inc
@@ -17,9 +17,6 @@
romstage-y += common.c
smm-$(CONFIG_HAVE_SMI_HANDLER) += common.c
-ramstage-y += tsc_freq.c
-romstage-y += tsc_freq.c
-smm-$(CONFIG_HAVE_SMI_HANDLER) += tsc_freq.c
smm-$(CONFIG_HAVE_SMI_HANDLER) += finalize.c
diff --git a/src/cpu/intel/model_206ax/tsc_freq.c b/src/cpu/intel/model_206ax/tsc_freq.c
deleted file mode 100644
index 545ca5f..0000000
--- a/src/cpu/intel/model_206ax/tsc_freq.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright (C) 2013 Google, Inc.
- *
- * 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 <stdint.h>
-#include <cpu/x86/msr.h>
-#include <cpu/x86/tsc.h>
-#include "model_206ax.h"
-
-unsigned long tsc_freq_mhz(void)
-{
- msr_t platform_info;
-
- platform_info = rdmsr(MSR_PLATFORM_INFO);
- return SANDYBRIDGE_BCLK * ((platform_info.lo >> 8) & 0xff);
-}
--
To view, visit https://review.coreboot.org/c/coreboot/+/31342
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I0e7159039751a88d86b6c343be5f085e6e15570a
Gerrit-Change-Number: 31342
Gerrit-PatchSet: 1
Gerrit-Owner: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
Gerrit-MessageType: newchange
Bill XIE has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/31631
Change subject: mb/lenovo/t430s: Open PCIe port #5 for Thunderbolt controller
......................................................................
mb/lenovo/t430s: Open PCIe port #5 for Thunderbolt controller
Some T430s variants has a Thunderbolt controller wired to PCIe
port #5, so it had better be left on for T430s. (T431s do not have
that)
The controller hotplugs itself to the chipset when a downstream device
is hotplugged into it, so the hotplug capability should be enabled on
PCIe port #5.
Change-Id: I61f41db100f398069e50e2da8a378b3a8d1c84bf
Signed-off-by: Bill XIE <persmule(a)gmail.com>
---
M src/mainboard/lenovo/t430s/variants/t430s/overridetree.cb
1 file changed, 5 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/31/31631/1
diff --git a/src/mainboard/lenovo/t430s/variants/t430s/overridetree.cb b/src/mainboard/lenovo/t430s/variants/t430s/overridetree.cb
index ff30702..ee94979 100644
--- a/src/mainboard/lenovo/t430s/variants/t430s/overridetree.cb
+++ b/src/mainboard/lenovo/t430s/variants/t430s/overridetree.cb
@@ -1,6 +1,11 @@
chip northbridge/intel/sandybridge
device domain 0 on
chip southbridge/intel/bd82x6x # Intel Series 7 Panther Point PCH
+ # Enable hotplug on Port 5 for Thunderbolt controller
+ register "pcie_hotplug_map" = "{ 0, 0, 1, 0, 1, 0, 0, 0 }"
+ device pci 1c.4 on
+ subsystemid 0x17aa 0x21fb
+ end # PCIe Port #5 Thunderbolt controller
device pci 1f.0 on
chip ec/lenovo/h8
register "has_bdc_detection" = "1"
--
To view, visit https://review.coreboot.org/c/coreboot/+/31631
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I61f41db100f398069e50e2da8a378b3a8d1c84bf
Gerrit-Change-Number: 31631
Gerrit-PatchSet: 1
Gerrit-Owner: Bill XIE <persmule(a)gmail.com>
Gerrit-MessageType: newchange
Kyösti Mälkki has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/31075
Change subject: [WIP] binaryPI: Drop PSP Secure OS from build
......................................................................
[WIP] binaryPI: Drop PSP Secure OS from build
For pcengines/apu2 variants we do not even send
DRAM ready message to PSP.
Possibly some GFX/DRM depends of running PSP but
these devices are headless. And we don't support
fTPM inside PSP either.
Reduces blob footprint in SPI from 466 KiB to 234KiB.
Change-Id: I803722171cba9b3601fb0b4a2c0e984566f435ab
Signed-off-by: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
---
M src/southbridge/amd/pi/hudson/Makefile.inc
1 file changed, 7 insertions(+), 8 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/75/31075/1
diff --git a/src/southbridge/amd/pi/hudson/Makefile.inc b/src/southbridge/amd/pi/hudson/Makefile.inc
index e990f9d..81fe7ff 100644
--- a/src/southbridge/amd/pi/hudson/Makefile.inc
+++ b/src/southbridge/amd/pi/hudson/Makefile.inc
@@ -85,13 +85,12 @@
FIRMWARE_TYPE=
PSPBTLDR_FILE=$(top)/$(FIRMWARE_LOCATE)/PspBootLoader.Bypass.sbin
-PSPRCVR_FILE=$(top)/$(FIRMWARE_LOCATE)/PspRecovery.sbin
-PSPSCUREOS_FILE=$(top)/$(FIRMWARE_LOCATE)/PspSecureOs.sbin
-PSPTRUSTLETS_FILE=$(top)/$(FIRMWARE_LOCATE)/trustlets.bin
-TRUSTLETKEY_FILE=$(top)/$(FIRMWARE_LOCATE)/Trustlet.tkn.cert
+#PSPRCVR_FILE=$(top)/$(FIRMWARE_LOCATE)/PspRecovery.sbin
+#PSPSCUREOS_FILE=$(top)/$(FIRMWARE_LOCATE)/PspSecureOs.sbin
+#PSPTRUSTLETS_FILE=$(top)/$(FIRMWARE_LOCATE)/trustlets.bin
+#TRUSTLETKEY_FILE=$(top)/$(FIRMWARE_LOCATE)/Trustlet.tkn.cert
endif
-
ifeq ($(CONFIG_CPU_AMD_PI_00660F01), y)
FIRMWARE_LOCATE=$(dir $(call strip_quotes, $(CONFIG_AMD_PUBKEY_FILE)))
FIRMWARE_TYPE=CZ
@@ -104,12 +103,12 @@
SMUFIRMWARE2_FILE=$(top)/$(FIRMWARE_LOCATE)/SmuFirmware2_prod_CZ.sbin
endif
-PUBSIGNEDKEY_FILE=$(top)/$(FIRMWARE_LOCATE)/RtmPubSigned$(FIRMWARE_TYPE).key
-PSPNVRAM_FILE=$(top)/$(FIRMWARE_LOCATE)/PspNvram$(FIRMWARE_TYPE).bin
+#PUBSIGNEDKEY_FILE=$(top)/$(FIRMWARE_LOCATE)/RtmPubSigned$(FIRMWARE_TYPE).key
+#PSPNVRAM_FILE=$(top)/$(FIRMWARE_LOCATE)/PspNvram$(FIRMWARE_TYPE).bin
SMUFWM_FILE=$(top)/$(FIRMWARE_LOCATE)/SmuFirmware$(FIRMWARE_TYPE).sbin
SMUFWM_FN_FILE=$(top)/$(FIRMWARE_LOCATE)/SmuFirmware$(FIRMWARE_TYPE)_FN.sbin
SMUSCS_FILE=$(top)/$(FIRMWARE_LOCATE)/SmuScs$(FIRMWARE_TYPE).bin
-PSPSECUREDEBUG_FILE=$(top)/$(FIRMWARE_LOCATE)/PspSecureDebug$(FIRMWARE_TYPE).Key
+#PSPSECUREDEBUG_FILE=$(top)/$(FIRMWARE_LOCATE)/PspSecureDebug$(FIRMWARE_TYPE).Key
endif
--
To view, visit https://review.coreboot.org/c/coreboot/+/31075
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I803722171cba9b3601fb0b4a2c0e984566f435ab
Gerrit-Change-Number: 31075
Gerrit-PatchSet: 1
Gerrit-Owner: Kyösti Mälkki <kyosti.malkki(a)gmail.com>
Gerrit-MessageType: newchange