Frans Hendriks has uploaded this change for review. ( https://review.coreboot.org/29660
Change subject: drivers/intel/fsp1_1: Add post console init functions for C bootblock
......................................................................
drivers/intel/fsp1_1: Add post console init functions for C bootblock
The console post init functions are not executed in C_ENVIRONMENT_BOOTBLOCK
mode.
Add car_XXXX_post_console_init functions to romstage_c_entry().
BUG=NA
TEST=Portwell PQ7-M107
Change-Id: I12e613147e5203022cd453693a115fca002ce480
Signed-off-by: Frans Hendriks <fhendriks(a)eltan.com>
---
M src/drivers/intel/fsp1_1/car.c
1 file changed, 10 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/60/29660/1
diff --git a/src/drivers/intel/fsp1_1/car.c b/src/drivers/intel/fsp1_1/car.c
index 4016ba1..4569454 100644
--- a/src/drivers/intel/fsp1_1/car.c
+++ b/src/drivers/intel/fsp1_1/car.c
@@ -2,6 +2,7 @@
* This file is part of the coreboot project.
*
* Copyright 2015 Google Inc.
+ * Copyright 2018 Eltan B.V.
*
* 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
@@ -67,7 +68,10 @@
return cache_as_ram_stage_main(car_params->fih);
}
-/* Entry point taken when romstage is called after a separate verstage. */
+/*
+ * Entry point taken when romstage is called after a separate verstage or
+ * when the C_ENVIRONMENT_BOOTBLOCK is enabled
+ */
asmlinkage void *romstage_c_entry(void)
{
/* Need to locate the current FSP_INFO_HEADER. The cache-as-ram
@@ -77,6 +81,11 @@
console_init();
+ if (IS_ENABLED(CONFIG_C_ENVIRONMENT_BOOTBLOCK)) {
+ car_soc_post_console_init();
+ car_mainboard_post_console_init();
+ }
+
if (prog_locate(&fsp)) {
fih = NULL;
printk(BIOS_ERR, "Unable to locate %s\n", prog_name(&fsp));
--
To view, visit https://review.coreboot.org/29660
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: I12e613147e5203022cd453693a115fca002ce480
Gerrit-Change-Number: 29660
Gerrit-PatchSet: 1
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/29431 )
Change subject: util/cbsftool: allow enabling verbose make output
......................................................................
util/cbsftool: allow enabling verbose make output
Sometimes it is necessary to be able to see exact command lines used
when compiling and linking. Use the same scheme as some other
Makefile's - enable verbose output when variable V is set to 1.
TEST=tried building cbfstool with V=1, observed verbose output.
Change-Id: Iff25439aabff79e69d1d94a2c51c60bb0e0d7b80
Signed-off-by: Vadim Bendebury <vbendeb(a)chromium.org>
Reviewed-on: https://review.coreboot.org/29431
Tested-by: build bot (Jenkins) <no-reply(a)coreboot.org>
Reviewed-by: Patrick Georgi <pgeorgi(a)google.com>
---
M util/cbfstool/Makefile
1 file changed, 2 insertions(+), 0 deletions(-)
Approvals:
build bot (Jenkins): Verified
Patrick Georgi: Looks good to me, approved
diff --git a/util/cbfstool/Makefile b/util/cbfstool/Makefile
index ba8fdff..f4dca3f 100644
--- a/util/cbfstool/Makefile
+++ b/util/cbfstool/Makefile
@@ -51,6 +51,8 @@
$(INSTALL) ifwitool $(DESTDIR)$(BINDIR)
$(INSTALL) cbfs-compression-tool $(DESTDIR)$(BINDIR)
+ifneq ($(V),1)
.SILENT:
+endif
include Makefile.inc
--
To view, visit https://review.coreboot.org/29431
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Iff25439aabff79e69d1d94a2c51c60bb0e0d7b80
Gerrit-Change-Number: 29431
Gerrit-PatchSet: 3
Gerrit-Owner: Vadim Bendebury <vbendeb(a)chromium.org>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Vadim Bendebury <vbendeb(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Patrick Georgi has posted comments on this change. ( https://review.coreboot.org/29431 )
Change subject: util/cbsftool: allow enabling verbose make output
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit https://review.coreboot.org/29431
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: Iff25439aabff79e69d1d94a2c51c60bb0e0d7b80
Gerrit-Change-Number: 29431
Gerrit-PatchSet: 2
Gerrit-Owner: Vadim Bendebury <vbendeb(a)chromium.org>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: Vadim Bendebury <vbendeb(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Fri, 16 Nov 2018 12:59:06 +0000
Gerrit-HasComments: No
Gerrit-HasLabels: Yes
Patrick Georgi 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?
--
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: Fri, 16 Nov 2018 12:58:29 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
Patrick Georgi has posted comments on this change. ( https://review.coreboot.org/29483 )
Change subject: util/abuild: Ensure .xcompile exists
......................................................................
Patch Set 1:
> Patch Set 1:
>
> Is there a trick that makes it available on the builders? I get this
> when I run `docker-what-jenkins-does`:
>
> /tmp/GmyYXllJ:1: .xcompile: No such file or directory
> make[1]: *** No rule to make target '.xcompile'. Stop.
>
> I don't see it in actual logs on the builders.
Makefile:145 should ensure that the file is around. What issue are you trying to solve with this commit?
--
To view, visit https://review.coreboot.org/29483
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: Ib485e7741b7700fa241c192e60900ae5f1d977f5
Gerrit-Change-Number: 29483
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
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: Fri, 16 Nov 2018 12:56:00 +0000
Gerrit-HasComments: No
Gerrit-HasLabels: No
Hello build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/29659
to look at the new patch set (#4).
Change subject: mb/lenovo: Unify thermal threshold handling
......................................................................
mb/lenovo: Unify thermal threshold handling
Unify thermal handling across Lenovo boards (except g505, which is
different). Namely, do the following:
* Move thermal levels from acpi_tables to thermal.h (and create if
necessary).
* Don't use board-specific ifdef guards.
* Set thermal levels using dedicated acpi_update_thermal_table function
as almost all Lenovo boards do.
* Update list of authors in comments. Merge all author's entries.
* Minor whitespace and formatting.
This makes diff -ruw between the Lenovo borders smaller.
Change-Id: If569f67c932b7fbf14893b890a5588df4994daeb
Signed-off-by: Peter Lemenkov <lemenkov(a)gmail.com>
---
M src/mainboard/lenovo/l520/acpi_tables.c
M src/mainboard/lenovo/l520/thermal.h
M src/mainboard/lenovo/s230u/acpi_tables.c
A src/mainboard/lenovo/s230u/thermal.h
M src/mainboard/lenovo/t400/acpi_tables.c
A src/mainboard/lenovo/t400/thermal.h
M src/mainboard/lenovo/t420/thermal.h
M src/mainboard/lenovo/t420s/thermal.h
M src/mainboard/lenovo/t430/thermal.h
M src/mainboard/lenovo/t430s/thermal.h
M src/mainboard/lenovo/t520/acpi_tables.c
M src/mainboard/lenovo/t520/thermal.h
M src/mainboard/lenovo/t530/acpi_tables.c
M src/mainboard/lenovo/t530/thermal.h
M src/mainboard/lenovo/t60/acpi_tables.c
A src/mainboard/lenovo/t60/thermal.h
M src/mainboard/lenovo/x131e/thermal.h
M src/mainboard/lenovo/x1_carbon_gen1/thermal.h
M src/mainboard/lenovo/x200/acpi_tables.c
A src/mainboard/lenovo/x200/thermal.h
M src/mainboard/lenovo/x201/acpi_tables.c
A src/mainboard/lenovo/x201/thermal.h
M src/mainboard/lenovo/x220/thermal.h
M src/mainboard/lenovo/x230/thermal.h
M src/mainboard/lenovo/x60/acpi_tables.c
A src/mainboard/lenovo/x60/thermal.h
M src/mainboard/lenovo/z61t/acpi_tables.c
A src/mainboard/lenovo/z61t/thermal.h
28 files changed, 402 insertions(+), 115 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/59/29659/4
--
To view, visit https://review.coreboot.org/29659
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: If569f67c932b7fbf14893b890a5588df4994daeb
Gerrit-Change-Number: 29659
Gerrit-PatchSet: 4
Gerrit-Owner: Peter Lemenkov <lemenkov(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Hello build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/29659
to look at the new patch set (#3).
Change subject: mb/lenovo: Unify thermal threshold handling
......................................................................
mb/lenovo: Unify thermal threshold handling
Unify thermal handling across Lenovo boards. Namely, do the following:
* Move thermal levels from acpi_tables to thermal.h (and create if
necessary).
* Don't use board-specific ifdef guards.
* Set thermal levels using dedicated acpi_update_thermal_table function
as almost all Lenovo boards do.
* Update list of authors in comments. Merge all author's entries.
* Minor whitespace and formatting.
This makes diff -ruw between the Lenovo borders smaller.
Change-Id: If569f67c932b7fbf14893b890a5588df4994daeb
Signed-off-by: Peter Lemenkov <lemenkov(a)gmail.com>
---
M src/mainboard/lenovo/l520/acpi_tables.c
M src/mainboard/lenovo/l520/thermal.h
M src/mainboard/lenovo/s230u/acpi_tables.c
A src/mainboard/lenovo/s230u/thermal.h
M src/mainboard/lenovo/t400/acpi_tables.c
A src/mainboard/lenovo/t400/thermal.h
M src/mainboard/lenovo/t420/thermal.h
M src/mainboard/lenovo/t420s/thermal.h
M src/mainboard/lenovo/t430/thermal.h
M src/mainboard/lenovo/t430s/thermal.h
M src/mainboard/lenovo/t520/acpi_tables.c
M src/mainboard/lenovo/t520/thermal.h
M src/mainboard/lenovo/t530/acpi_tables.c
M src/mainboard/lenovo/t530/thermal.h
M src/mainboard/lenovo/t60/acpi_tables.c
A src/mainboard/lenovo/t60/thermal.h
M src/mainboard/lenovo/x131e/thermal.h
M src/mainboard/lenovo/x1_carbon_gen1/thermal.h
M src/mainboard/lenovo/x200/acpi_tables.c
A src/mainboard/lenovo/x200/thermal.h
M src/mainboard/lenovo/x201/acpi_tables.c
A src/mainboard/lenovo/x201/thermal.h
M src/mainboard/lenovo/x220/thermal.h
M src/mainboard/lenovo/x230/thermal.h
M src/mainboard/lenovo/x60/acpi_tables.c
A src/mainboard/lenovo/x60/thermal.h
M src/mainboard/lenovo/z61t/acpi_tables.c
A src/mainboard/lenovo/z61t/thermal.h
28 files changed, 402 insertions(+), 115 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/59/29659/3
--
To view, visit https://review.coreboot.org/29659
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: If569f67c932b7fbf14893b890a5588df4994daeb
Gerrit-Change-Number: 29659
Gerrit-PatchSet: 3
Gerrit-Owner: Peter Lemenkov <lemenkov(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Peter Lemenkov has uploaded a new patch set (#2). ( https://review.coreboot.org/29659 )
Change subject: mb/lenovo: Unify thermal threshold handling
......................................................................
mb/lenovo: Unify thermal threshold handling
Unify thermal handling across Lenovo boards. Namely, do the following:
* Move thermal levels from acpi_tables to thermal.h (and create if
necessary).
* Don't use board-specific ifdef guards.
* Set thermal levels using dedicated acpi_update_thermal_table function
as almost all Lenovo boards do.
* Update list of authors in comments. Merge all author's entries.
* Minor whitespace and formatting.
This makes diff -ruw between the Lenovo borders smaller.
Change-Id: If569f67c932b7fbf14893b890a5588df4994daeb
Signed-off-by: Peter Lemenkov <lemenkov(a)gmail.com>
---
M src/mainboard/lenovo/l520/acpi_tables.c
M src/mainboard/lenovo/l520/thermal.h
M src/mainboard/lenovo/s230u/acpi_tables.c
A src/mainboard/lenovo/s230u/thermal.h
M src/mainboard/lenovo/t400/acpi_tables.c
A src/mainboard/lenovo/t400/thermal.h
M src/mainboard/lenovo/t420/thermal.h
M src/mainboard/lenovo/t420s/thermal.h
M src/mainboard/lenovo/t430/thermal.h
M src/mainboard/lenovo/t430s/thermal.h
M src/mainboard/lenovo/t520/acpi_tables.c
M src/mainboard/lenovo/t520/thermal.h
M src/mainboard/lenovo/t530/acpi_tables.c
M src/mainboard/lenovo/t530/thermal.h
M src/mainboard/lenovo/t60/acpi_tables.c
A src/mainboard/lenovo/t60/thermal.h
M src/mainboard/lenovo/x131e/thermal.h
M src/mainboard/lenovo/x1_carbon_gen1/thermal.h
M src/mainboard/lenovo/x200/acpi_tables.c
A src/mainboard/lenovo/x200/thermal.h
M src/mainboard/lenovo/x201/acpi_tables.c
A src/mainboard/lenovo/x201/thermal.h
M src/mainboard/lenovo/x220/thermal.h
M src/mainboard/lenovo/x230/thermal.h
M src/mainboard/lenovo/x60/acpi_tables.c
A src/mainboard/lenovo/x60/thermal.h
M src/mainboard/lenovo/z61t/acpi_tables.c
A src/mainboard/lenovo/z61t/thermal.h
28 files changed, 395 insertions(+), 112 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/59/29659/2
--
To view, visit https://review.coreboot.org/29659
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: If569f67c932b7fbf14893b890a5588df4994daeb
Gerrit-Change-Number: 29659
Gerrit-PatchSet: 2
Gerrit-Owner: Peter Lemenkov <lemenkov(a)gmail.com>
Peter Lemenkov has uploaded this change for review. ( https://review.coreboot.org/29659
Change subject: mb/lenovo: Unify thermal threshold handling
......................................................................
mb/lenovo: Unify thermal threshold handling
Unify thermal handling across Lenovo boards. Namely, do the following:
* Move thermal levels to thermal.h (and create if necessary).
* Don't use board-specific ifded guards.
* Set thermal levels using dedicated acpi_update_thermal_table function.
* Update list of authors in comments. Merge all author entries.
* Minor whitespace and formatting.
This makes diff -ruw between the Lenovo borders smaller.
Change-Id: If569f67c932b7fbf14893b890a5588df4994daeb
Signed-off-by: Peter Lemenkov <lemenkov(a)gmail.com>
---
M src/mainboard/lenovo/l520/acpi_tables.c
M src/mainboard/lenovo/l520/thermal.h
M src/mainboard/lenovo/s230u/acpi_tables.c
A src/mainboard/lenovo/s230u/thermal.h
M src/mainboard/lenovo/t400/acpi_tables.c
A src/mainboard/lenovo/t400/thermal.h
M src/mainboard/lenovo/t420/thermal.h
M src/mainboard/lenovo/t420s/thermal.h
M src/mainboard/lenovo/t430/thermal.h
M src/mainboard/lenovo/t430s/thermal.h
M src/mainboard/lenovo/t520/acpi_tables.c
M src/mainboard/lenovo/t520/thermal.h
M src/mainboard/lenovo/t530/acpi_tables.c
M src/mainboard/lenovo/t530/thermal.h
M src/mainboard/lenovo/t60/acpi_tables.c
A src/mainboard/lenovo/t60/thermal.h
M src/mainboard/lenovo/x131e/thermal.h
M src/mainboard/lenovo/x1_carbon_gen1/thermal.h
M src/mainboard/lenovo/x200/acpi_tables.c
A src/mainboard/lenovo/x200/thermal.h
M src/mainboard/lenovo/x201/acpi_tables.c
A src/mainboard/lenovo/x201/thermal.h
M src/mainboard/lenovo/x220/thermal.h
M src/mainboard/lenovo/x230/thermal.h
M src/mainboard/lenovo/x60/acpi_tables.c
A src/mainboard/lenovo/x60/thermal.h
M src/mainboard/lenovo/z61t/acpi_tables.c
A src/mainboard/lenovo/z61t/thermal.h
28 files changed, 395 insertions(+), 112 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/59/29659/1
diff --git a/src/mainboard/lenovo/l520/acpi_tables.c b/src/mainboard/lenovo/l520/acpi_tables.c
index b861864..31f41e7 100644
--- a/src/mainboard/lenovo/l520/acpi_tables.c
+++ b/src/mainboard/lenovo/l520/acpi_tables.c
@@ -35,7 +35,6 @@
gnvs->s5u0 = 0;
gnvs->s5u1 = 0;
-
// the lid is open by default.
gnvs->lids = 1;
diff --git a/src/mainboard/lenovo/l520/thermal.h b/src/mainboard/lenovo/l520/thermal.h
index a2007ff..72953fd 100644
--- a/src/mainboard/lenovo/l520/thermal.h
+++ b/src/mainboard/lenovo/l520/thermal.h
@@ -2,7 +2,10 @@
* This file is part of the coreboot project.
*
* Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
* Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
@@ -15,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef L520_THERMAL_H
-#define L520_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif /* L520_THERMAL_H */
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/s230u/acpi_tables.c b/src/mainboard/lenovo/s230u/acpi_tables.c
index 21fce85..8d6d93f 100644
--- a/src/mainboard/lenovo/s230u/acpi_tables.c
+++ b/src/mainboard/lenovo/s230u/acpi_tables.c
@@ -14,6 +14,13 @@
*/
#include <southbridge/intel/bd82x6x/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -28,6 +35,5 @@
/* The LID is open by default */
gnvs->lids = 1;
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
diff --git a/src/mainboard/lenovo/s230u/thermal.h b/src/mainboard/lenovo/s230u/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/s230u/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t400/acpi_tables.c b/src/mainboard/lenovo/t400/acpi_tables.c
index 2893d39..6645438 100644
--- a/src/mainboard/lenovo/t400/acpi_tables.c
+++ b/src/mainboard/lenovo/t400/acpi_tables.c
@@ -24,6 +24,13 @@
#include <device/pci.h>
#include <device/pci_ids.h>
#include <southbridge/intel/i82801ix/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -35,9 +42,7 @@
gnvs->cmap = 0x01;
gnvs->cmbp = 0x01;
- /* Set thermal levels */
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
unsigned long acpi_fill_madt(unsigned long current)
diff --git a/src/mainboard/lenovo/t400/thermal.h b/src/mainboard/lenovo/t400/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/t400/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t420/thermal.h b/src/mainboard/lenovo/t420/thermal.h
index 6ca5b2a..72953fd 100644
--- a/src/mainboard/lenovo/t420/thermal.h
+++ b/src/mainboard/lenovo/t420/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,8 +18,8 @@
* GNU General Public License for more details.
*/
-#ifndef T420_THERMAL_H
-#define T420_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
/* Temperature which OS will shutdown at */
#define CRITICAL_TEMPERATURE 100
@@ -23,4 +27,4 @@
/* Temperature which OS will throttle CPU */
#define PASSIVE_TEMPERATURE 90
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t420s/thermal.h b/src/mainboard/lenovo/t420s/thermal.h
index c7803e5..72953fd 100644
--- a/src/mainboard/lenovo/t420s/thermal.h
+++ b/src/mainboard/lenovo/t420s/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef T420S_THERMAL_H
-#define T420S_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t430/thermal.h b/src/mainboard/lenovo/t430/thermal.h
index e3e49f5..6c1b41b 100644
--- a/src/mainboard/lenovo/t430/thermal.h
+++ b/src/mainboard/lenovo/t430/thermal.h
@@ -14,8 +14,8 @@
* GNU General Public License for more details.
*/
-#ifndef _LENOVO_T430_THERMAL_H
-#define _LENOVO_T430_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
/* Config TDP Sensor ID */
#define CTDP_SENSOR_ID 0 /* PECI */
@@ -37,4 +37,4 @@
/* Tj_max value for calculating PECI CPU temperature */
#define MAX_TEMPERATURE 105
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t430s/thermal.h b/src/mainboard/lenovo/t430s/thermal.h
index 1d55584..72953fd 100644
--- a/src/mainboard/lenovo/t430s/thermal.h
+++ b/src/mainboard/lenovo/t430s/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,8 +18,8 @@
* GNU General Public License for more details.
*/
-#ifndef T430S_THERMAL_H
-#define T430S_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
/* Temperature which OS will shutdown at */
#define CRITICAL_TEMPERATURE 100
@@ -23,4 +27,4 @@
/* Temperature which OS will throttle CPU */
#define PASSIVE_TEMPERATURE 90
-#endif /* T430S_THERMAL_H */
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t520/acpi_tables.c b/src/mainboard/lenovo/t520/acpi_tables.c
index a3b0894..279674d 100644
--- a/src/mainboard/lenovo/t520/acpi_tables.c
+++ b/src/mainboard/lenovo/t520/acpi_tables.c
@@ -32,7 +32,6 @@
gnvs->s5u0 = 0;
gnvs->s5u1 = 0;
-
// the lid is open by default.
gnvs->lids = 1;
diff --git a/src/mainboard/lenovo/t520/thermal.h b/src/mainboard/lenovo/t520/thermal.h
index 60721bf..72953fd 100644
--- a/src/mainboard/lenovo/t520/thermal.h
+++ b/src/mainboard/lenovo/t520/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef T520_THERMAL_H
-#define T520_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif /* T520_THERMAL_H */
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t530/acpi_tables.c b/src/mainboard/lenovo/t530/acpi_tables.c
index a3b0894..279674d 100644
--- a/src/mainboard/lenovo/t530/acpi_tables.c
+++ b/src/mainboard/lenovo/t530/acpi_tables.c
@@ -32,7 +32,6 @@
gnvs->s5u0 = 0;
gnvs->s5u1 = 0;
-
// the lid is open by default.
gnvs->lids = 1;
diff --git a/src/mainboard/lenovo/t530/thermal.h b/src/mainboard/lenovo/t530/thermal.h
index 0b24ea8..72953fd 100644
--- a/src/mainboard/lenovo/t530/thermal.h
+++ b/src/mainboard/lenovo/t530/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef T530_THERMAL_H
-#define T530_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif /* T530_THERMAL_H */
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/t60/acpi_tables.c b/src/mainboard/lenovo/t60/acpi_tables.c
index 183b7fe..bd10a0e 100644
--- a/src/mainboard/lenovo/t60/acpi_tables.c
+++ b/src/mainboard/lenovo/t60/acpi_tables.c
@@ -16,6 +16,13 @@
#include <stdint.h>
#include <southbridge/intel/i82801gx/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -23,7 +30,5 @@
gnvs->cmap = 0x01;
gnvs->cmbp = 0x01;
- /* Set thermal levels */
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
diff --git a/src/mainboard/lenovo/t60/thermal.h b/src/mainboard/lenovo/t60/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/t60/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x131e/thermal.h b/src/mainboard/lenovo/x131e/thermal.h
index ff92869..72953fd 100644
--- a/src/mainboard/lenovo/x131e/thermal.h
+++ b/src/mainboard/lenovo/x131e/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
* Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,15 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef X131E_THERMAL_H
-#define X131E_THERMAL_H
-
-/* Active Thermal and fans are controlled by the EC. */
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
/* Temperature which OS will shutdown at */
-#define CRITICAL_TEMPERATURE 100
+#define CRITICAL_TEMPERATURE 100
/* Temperature which OS will throttle CPU */
-#define PASSIVE_TEMPERATURE 90
+#define PASSIVE_TEMPERATURE 90
-#endif /* X131E_THERMAL_H */
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x1_carbon_gen1/thermal.h b/src/mainboard/lenovo/x1_carbon_gen1/thermal.h
index 199c27e..72953fd 100644
--- a/src/mainboard/lenovo/x1_carbon_gen1/thermal.h
+++ b/src/mainboard/lenovo/x1_carbon_gen1/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef X230_THERMAL_H
-#define X230_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x200/acpi_tables.c b/src/mainboard/lenovo/x200/acpi_tables.c
index 2893d39..6645438 100644
--- a/src/mainboard/lenovo/x200/acpi_tables.c
+++ b/src/mainboard/lenovo/x200/acpi_tables.c
@@ -24,6 +24,13 @@
#include <device/pci.h>
#include <device/pci_ids.h>
#include <southbridge/intel/i82801ix/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -35,9 +42,7 @@
gnvs->cmap = 0x01;
gnvs->cmbp = 0x01;
- /* Set thermal levels */
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
unsigned long acpi_fill_madt(unsigned long current)
diff --git a/src/mainboard/lenovo/x200/thermal.h b/src/mainboard/lenovo/x200/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/x200/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x201/acpi_tables.c b/src/mainboard/lenovo/x201/acpi_tables.c
index e412503..82991b2 100644
--- a/src/mainboard/lenovo/x201/acpi_tables.c
+++ b/src/mainboard/lenovo/x201/acpi_tables.c
@@ -17,10 +17,15 @@
#include <stdint.h>
#include <southbridge/intel/ibexpeak/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t * gnvs)
{
- /* Set thermal levels */
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
diff --git a/src/mainboard/lenovo/x201/thermal.h b/src/mainboard/lenovo/x201/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/x201/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x220/thermal.h b/src/mainboard/lenovo/x220/thermal.h
index 82df303..72953fd 100644
--- a/src/mainboard/lenovo/x220/thermal.h
+++ b/src/mainboard/lenovo/x220/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef X220_THERMAL_H
-#define X220_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x230/thermal.h b/src/mainboard/lenovo/x230/thermal.h
index 199c27e..72953fd 100644
--- a/src/mainboard/lenovo/x230/thermal.h
+++ b/src/mainboard/lenovo/x230/thermal.h
@@ -1,12 +1,16 @@
/*
* This file is part of the coreboot project.
*
+ * Copyright (C) 2008-2009 coresystems GmbH
* Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
* Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
*
- * 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 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
@@ -14,13 +18,13 @@
* GNU General Public License for more details.
*/
-#ifndef X230_THERMAL_H
-#define X230_THERMAL_H
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
- /* Temperature which OS will shutdown at */
- #define CRITICAL_TEMPERATURE 100
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
- /* Temperature which OS will throttle CPU */
- #define PASSIVE_TEMPERATURE 90
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
-#endif
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/x60/acpi_tables.c b/src/mainboard/lenovo/x60/acpi_tables.c
index 183b7fe..bd10a0e 100644
--- a/src/mainboard/lenovo/x60/acpi_tables.c
+++ b/src/mainboard/lenovo/x60/acpi_tables.c
@@ -16,6 +16,13 @@
#include <stdint.h>
#include <southbridge/intel/i82801gx/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -23,7 +30,5 @@
gnvs->cmap = 0x01;
gnvs->cmbp = 0x01;
- /* Set thermal levels */
- gnvs->tcrt = 100;
- gnvs->tpsv = 90;
+ acpi_update_thermal_table(gnvs);
}
diff --git a/src/mainboard/lenovo/x60/thermal.h b/src/mainboard/lenovo/x60/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/x60/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
diff --git a/src/mainboard/lenovo/z61t/acpi_tables.c b/src/mainboard/lenovo/z61t/acpi_tables.c
index 3e9a810..bd10a0e 100644
--- a/src/mainboard/lenovo/z61t/acpi_tables.c
+++ b/src/mainboard/lenovo/z61t/acpi_tables.c
@@ -16,6 +16,13 @@
#include <stdint.h>
#include <southbridge/intel/i82801gx/nvs.h>
+#include "thermal.h"
+
+static void acpi_update_thermal_table(global_nvs_t *gnvs)
+{
+ gnvs->tcrt = CRITICAL_TEMPERATURE;
+ gnvs->tpsv = PASSIVE_TEMPERATURE;
+}
void acpi_create_gnvs(global_nvs_t *gnvs)
{
@@ -23,4 +30,5 @@
gnvs->cmap = 0x01;
gnvs->cmbp = 0x01;
+ acpi_update_thermal_table(gnvs);
}
diff --git a/src/mainboard/lenovo/z61t/thermal.h b/src/mainboard/lenovo/z61t/thermal.h
new file mode 100644
index 0000000..72953fd
--- /dev/null
+++ b/src/mainboard/lenovo/z61t/thermal.h
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2008-2009 coresystems GmbH
+ * Copyright (C) 2011 The Chromium OS Authors. All rights reserved.
+ * Copyright (C) 2014 Vladimir Serbinenko
+ * Copyright (C) 2016 Patrick Rudolph <siro(a)das-labor.org>
+ * Copyright (C) 2017 James Ye <jye836(a)gmail.com>
+ *
+ * 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.
+ */
+
+#ifndef MAINBOARD_THERMAL_H
+#define MAINBOARD_THERMAL_H
+
+/* Temperature which OS will shutdown at */
+#define CRITICAL_TEMPERATURE 100
+
+/* Temperature which OS will throttle CPU */
+#define PASSIVE_TEMPERATURE 90
+
+#endif /* MAINBOARD_THERMAL_H */
--
To view, visit https://review.coreboot.org/29659
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: If569f67c932b7fbf14893b890a5588df4994daeb
Gerrit-Change-Number: 29659
Gerrit-PatchSet: 1
Gerrit-Owner: Peter Lemenkov <lemenkov(a)gmail.com>
Frans Hendriks has posted comments on this change. ( https://review.coreboot.org/29655 )
Change subject: soc/intel/braswell: Disable OS use of HPET
......................................................................
Patch Set 3:
(1 comment)
> Patch Set 2: Code-Review+1
>
> (1 comment)
https://review.coreboot.org/#/c/29655/2/src/soc/intel/braswell/acpi/lpc.asl
File src/soc/intel/braswell/acpi/lpc.asl:
https://review.coreboot.org/#/c/29655/2/src/soc/intel/braswell/acpi/lpc.asl…
PS2, Line 6: * Copyright (C) 2018 Eltan B.V.
> the only change to this file?
Add new patch to disable HPET device in this file
--
To view, visit https://review.coreboot.org/29655
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: Ie9a78dcc736eb057c040a0a303c812adb1f76f3c
Gerrit-Change-Number: 29655
Gerrit-PatchSet: 3
Gerrit-Owner: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Frans Hendriks <fhendriks(a)eltan.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)gmail.com>
Gerrit-Reviewer: Michał Żygowski <michal.zygowski(a)3mdeb.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Fri, 16 Nov 2018 12:28:31 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No