Angel Pons has posted comments on this change. ( https://review.coreboot.org/29670 )
Change subject: util/board_status: run dmesg with sudo
......................................................................
Patch Set 1: Code-Review+2
Some distros allow non-root to access the kernel log buffer (e.g. Arch Linux), some others do not (e.g. Debian).
--
To view, visit https://review.coreboot.org/29670
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I654422992e5ba1e98a786f65d50289efbcd46602
Gerrit-Change-Number: 29670
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Sat, 17 Nov 2018 16:44:39 +0000
Gerrit-HasComments: No
Gerrit-HasLabels: Yes
Nico Huber has posted comments on this change. ( https://review.coreboot.org/29451 )
Change subject: util/abuild: Use absolute paths for (failed|passed)_boards
......................................................................
Patch Set 4:
(1 comment)
https://review.coreboot.org/#/c/29451/4/util/abuild/abuild
File util/abuild/abuild:
https://review.coreboot.org/#/c/29451/4/util/abuild/abuild@22
PS4, Line 22: TOP
> any reason why you couldn't just derive the full paths from $TOP?
Don't know what $TOP is used for at all. The original problem,
{failed,passed}_boards, is relative to $TARGET so that can't work.
(now that I looked, half of the script seems to use $TOP as root
of the coreboot tree, the other half $ROOT and assumes abuild might
be called from somewhere else)
Maybe it could be used for some paths that I normalized to use
abspath(). Idk, for somebody who didn't wrote this script, it's
hard to grasp in which directory it is at which point. Some of
the calls to `pwd` on the LHS might be unnecessary, who knows?
--
To view, visit https://review.coreboot.org/29451
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ief00e28e09a4714b0106c35ad4f4e9c696f6aad4
Gerrit-Change-Number: 29451
Gerrit-PatchSet: 4
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
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: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Sat, 17 Nov 2018 16:25:47 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
Patrick Georgi has uploaded this change for review. ( https://review.coreboot.org/29670
Change subject: util/board_status: run dmesg with sudo
......................................................................
util/board_status: run dmesg with sudo
Newer kernels only allow root to access the kernel log buffer.
In another case (cbmem) we use sudo to get past that, so we can
expect sudo to be available here, too.
Change-Id: I654422992e5ba1e98a786f65d50289efbcd46602
Signed-off-by: Patrick Georgi <patrick(a)georgi.software>
---
M util/board_status/board_status.sh
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/70/29670/1
diff --git a/util/board_status/board_status.sh b/util/board_status/board_status.sh
index 4acbb6c..bba3d1f 100755
--- a/util/board_status/board_status.sh
+++ b/util/board_status/board_status.sh
@@ -381,7 +381,7 @@
cmd_nonfatal $REMOTE "$cbmem_cmd -t" "${tmpdir}/${results}/coreboot_timestamps.txt"
echo "Getting remote dmesg"
- cmd $REMOTE dmesg "${tmpdir}/${results}/kernel_log.txt"
+ cmd $REMOTE sudo dmesg "${tmpdir}/${results}/kernel_log.txt"
else
echo "Verifying that CBMEM is available"
if [ $(id -u) -ne 0 ]; then
--
To view, visit https://review.coreboot.org/29670
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I654422992e5ba1e98a786f65d50289efbcd46602
Gerrit-Change-Number: 29670
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Georgi <pgeorgi(a)google.com>
Nico Huber has uploaded this change for review. ( https://review.coreboot.org/29669
Change subject: cpu/intel/sandybridge: Add `hyper_threading` option
......................................................................
cpu/intel/sandybridge: Add `hyper_threading` option
More and more people request an option to disable HT. To implement that
we have to toggle a bit in a `soft reset` register in the PCH that can
override certain default settings of the CPU when it comes out of reset.
The `soft reset` register is already used for other settings. So we have
to take care that all settings are gathered before we issue the reset.
Note, the current code using `soft reset` for flex ratio selection seems
incomplete.
Change-Id: I2b73e32ff5af8ea64a47e8aa706e27648aaf0993
Signed-off-by: Nico Huber <nico.h(a)gmx.de>
---
M src/cpu/intel/model_206ax/bootblock.c
M src/mainboard/lenovo/t430/cmos.layout
M src/southbridge/intel/bd82x6x/pch.h
3 files changed, 46 insertions(+), 19 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/69/29669/1
diff --git a/src/cpu/intel/model_206ax/bootblock.c b/src/cpu/intel/model_206ax/bootblock.c
index 670b097..929c6dc 100644
--- a/src/cpu/intel/model_206ax/bootblock.c
+++ b/src/cpu/intel/model_206ax/bootblock.c
@@ -19,6 +19,8 @@
#include <cpu/x86/msr.h>
#include <cpu/x86/mtrr.h>
#include <arch/io.h>
+#include <option_table.h>
+#include <pc80/mc146818rtc.h>
#include <halt.h>
#include <cpu/intel/microcode/microcode.c>
@@ -61,34 +63,29 @@
wrmsr(MTRR_DEF_TYPE_MSR, msr);
}
-static void set_flex_ratio_to_tdp_nominal(void)
+static u32 set_flex_ratio_to_tdp_nominal(u32 soft_reset)
{
msr_t flex_ratio, msr;
- u32 soft_reset;
u8 nominal_ratio;
/* Minimum CPU revision for configurable TDP support */
if (cpuid_eax(1) < IVB_CONFIG_TDP_MIN_CPUID)
- return;
+ return soft_reset;
/* Check for Flex Ratio support */
flex_ratio = rdmsr(MSR_FLEX_RATIO);
if (!(flex_ratio.lo & FLEX_RATIO_EN))
- return;
+ return soft_reset;
/* Check for >0 configurable TDPs */
msr = rdmsr(MSR_PLATFORM_INFO);
if (((msr.hi >> 1) & 3) == 0)
- return;
+ return soft_reset;
/* Use nominal TDP ratio for flex ratio */
msr = rdmsr(MSR_CONFIG_TDP_NOMINAL);
nominal_ratio = msr.lo & 0xff;
- /* See if flex ratio is already set to nominal TDP ratio */
- if (((flex_ratio.lo >> 8) & 0xff) == nominal_ratio)
- return;
-
/* Set flex ratio to nominal TDP ratio */
flex_ratio.lo &= ~0xff00;
flex_ratio.lo |= nominal_ratio << 8;
@@ -97,24 +94,52 @@
/* Set flex ratio in soft reset data register bits 11:6.
* RCBA region is enabled in southbridge bootblock */
- soft_reset = RCBA32(SOFT_RESET_DATA);
soft_reset &= ~(0x3f << 6);
soft_reset |= (nominal_ratio & 0x3f) << 6;
- RCBA32(SOFT_RESET_DATA) = soft_reset;
+ return soft_reset;
+}
- /* Set soft reset control to use register value */
+static u32 set_hyperthreading_option(u32 soft_reset)
+{
+ int ht_requested;
+
+ ht_requested = read_option(hyper_threading, 1);
+
+ soft_reset &= ~1;
+ soft_reset |= !ht_requested; /* Bit 0 is ht disable */
+ return soft_reset;
+}
+
+static void soft_reset_settings(void)
+{
+ int need_reset;
+ u32 soft_reset;
+
+ soft_reset = RCBA32(SOFT_RESET_DATA);
+ soft_reset = set_flex_ratio_to_tdp_nominal(soft_reset);
+ soft_reset = set_hyperthreading_option(soft_reset);
+
+ /* Check if we didn't already request these settings */
+ need_reset = !(RCBA32(SOFT_RESET_CTRL) & 1) ||
+ RCBA32(SOFT_RESET_DATA) != soft_reset;
+
+ /* Set current requests */
+ RCBA32(SOFT_RESET_DATA) = soft_reset;
+ /* Use them instead of defaults */
RCBA32_OR(SOFT_RESET_CTRL, 1);
- /* Issue warm reset, will be "CPU only" due to soft reset data */
- outb(0x0, 0xcf9);
- outb(0x6, 0xcf9);
- halt();
+ if (need_reset) {
+ outb(0x2, 0xcf9);
+ outb(0x6, 0xcf9);
+ halt();
+ } else {
+ RCBA32_OR(SOFT_RESET_LOCK, 1);
+ }
}
static void bootblock_cpu_init(void)
{
- /* Set flex ratio and reset if needed */
- set_flex_ratio_to_tdp_nominal();
+ soft_reset_settings();
enable_rom_caching();
intel_update_microcode_from_cbfs();
}
diff --git a/src/mainboard/lenovo/t430/cmos.layout b/src/mainboard/lenovo/t430/cmos.layout
index 1b50e7f..9517482 100644
--- a/src/mainboard/lenovo/t430/cmos.layout
+++ b/src/mainboard/lenovo/t430/cmos.layout
@@ -72,7 +72,8 @@
422 2 e 10 backlight
# coreboot config options: cpu
-#424 8 r 0 unused
+424 1 e 1 hyper_threading
+#425 7 r 0 unused
# coreboot config options: northbridge
432 3 e 11 gfx_uma_size
diff --git a/src/southbridge/intel/bd82x6x/pch.h b/src/southbridge/intel/bd82x6x/pch.h
index bb0d5c4..7aab77a 100644
--- a/src/southbridge/intel/bd82x6x/pch.h
+++ b/src/southbridge/intel/bd82x6x/pch.h
@@ -391,6 +391,7 @@
#define D22IR 0x315c /* 16bit */
#define D20IR 0x3160 /* 16bit */
#define OIC 0x31fe /* 16bit */
+#define SOFT_RESET_LOCK 0x38f0
#define SOFT_RESET_CTRL 0x38f4
#define SOFT_RESET_DATA 0x38f8
--
To view, visit https://review.coreboot.org/29669
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2b73e32ff5af8ea64a47e8aa706e27648aaf0993
Gerrit-Change-Number: 29669
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Hello Angel Pons, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/29668
to look at the new patch set (#4).
Change subject: nb/intel/sandybridge/acpi: Add RMRR entry for iGPU
......................................................................
nb/intel/sandybridge/acpi: Add RMRR entry for iGPU
The iGPU always needs access to its stolen memory. For proper IOMMU
support, we have to make the OS aware of that.
Directly below TOLUD lies the data stolen memory (BDSM) followed by
the GTT stolen memory (BGSM), the iGPU needs access to both.
Change-Id: I391d0a5f1ea14bc90fbacabce41dddfa12b5bb0d
Signed-off-by: Nico Huber <nico.h(a)gmx.de>
---
M src/northbridge/intel/sandybridge/acpi.c
1 file changed, 18 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/68/29668/4
--
To view, visit https://review.coreboot.org/29668
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I391d0a5f1ea14bc90fbacabce41dddfa12b5bb0d
Gerrit-Change-Number: 29668
Gerrit-PatchSet: 4
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Angel Pons <th3fanbus(a)gmail.com>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>