Nico Huber has posted comments on this change. ( https://review.coreboot.org/20913 )
Change subject: [WIP]mb/lenovo/x200: Add ACPI methods to set battery thresholds
......................................................................
Patch Set 1:
(2 comments)
https://review.coreboot.org/#/c/20913/1/src/mainboard/lenovo/x200/acpi/bat_…
File src/mainboard/lenovo/x200/acpi/bat_thresh.asl:
PS1:
I think we agreed to keep the tree consistent in the old syntax
for the moment.
https://review.coreboot.org/#/c/20913/1/src/mainboard/lenovo/x200/acpi/bat_…
PS1, Line 32: 1
Why not place them below BAT0/BAT1? instead of numbering the
methods? (not to mention that it's weird to have a different
numbering, 1 based here, 0 based there)
--
To view, visit https://review.coreboot.org/20913
To unsubscribe, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ia049407cea7a60887ecba7b7c96e5000473865dd
Gerrit-Change-Number: 20913
Gerrit-PatchSet: 1
Gerrit-Owner: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Comment-Date: Tue, 08 Aug 2017 19:09:55 +0000
Gerrit-HasComments: Yes
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/20913 )
Change subject: [WIP]mb/lenovo/x200: Add ACPI methods to set battery thresholds
......................................................................
Patch Set 1:
Seems to work fine with acpi_call module.
--
To view, visit https://review.coreboot.org/20913
To unsubscribe, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ia049407cea7a60887ecba7b7c96e5000473865dd
Gerrit-Change-Number: 20913
Gerrit-PatchSet: 1
Gerrit-Owner: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Comment-Date: Tue, 08 Aug 2017 18:50:55 +0000
Gerrit-HasComments: No
Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/20913
Change subject: [WIP]mb/lenovo/x200: Add ACPI methods to set battery thresholds
......................................................................
[WIP]mb/lenovo/x200: Add ACPI methods to set battery thresholds
Change-Id: Ia049407cea7a60887ecba7b7c96e5000473865dd
Signed-off-by: Arthur Heymans <arthur(a)aheymans.xyz>
---
A src/mainboard/lenovo/x200/acpi/bat_thresh.asl
M src/mainboard/lenovo/x200/dsdt.asl
2 files changed, 60 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/13/20913/1
diff --git a/src/mainboard/lenovo/x200/acpi/bat_thresh.asl b/src/mainboard/lenovo/x200/acpi/bat_thresh.asl
new file mode 100644
index 0000000..6a30008
--- /dev/null
+++ b/src/mainboard/lenovo/x200/acpi/bat_thresh.asl
@@ -0,0 +1,59 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (c) 2017 Arthur Heymans <arthur(a)aheymans.xyz>
+ *
+ * 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.
+ */
+
+
+Scope(\_SB.PCI0.LPCB.EC)
+{
+ Field (ERAM, ByteAcc, NoLock, Preserve)
+ {
+ Offset (0x03),
+ , 2,
+ BSTP, 1, /* Battery start/stop threshold */
+ Offset (0x24),
+ TSH1, 8, /* Battery1 threshold */
+ Offset (0x25),
+ TSH2, 8 /* Battery2 threshold */
+ }
+
+ /* Set upper threshold on battery1 */
+ Method (SUT1, 1, NotSerialized)
+ {
+ BSTP = 1
+ Local0 = Arg0 | 0x80
+ TSH1 = Local0
+ }
+ /* Set lower threshold on battery1 */
+ Method (SLT1, 1, NotSerialized)
+ {
+ BSTP = 0
+ Local0 = Arg0 | 0x80
+ TSH1 = Local0
+ }
+
+ Method (SUT2, 1, NotSerialized)
+ {
+ BSTP = 1
+ Local0 = Arg0 | 0x80
+ TSH2 = Local0
+ }
+
+ Method (SLT2, 1, NotSerialized)
+ {
+ BSTP = 0
+ Local0 = Arg0 | 0x80
+ TSH2 = Local0
+ }
+}
\ No newline at end of file
diff --git a/src/mainboard/lenovo/x200/dsdt.asl b/src/mainboard/lenovo/x200/dsdt.asl
index 0706249..5705033 100644
--- a/src/mainboard/lenovo/x200/dsdt.asl
+++ b/src/mainboard/lenovo/x200/dsdt.asl
@@ -56,4 +56,5 @@
/* Dock support code */
#include "acpi/dock.asl"
+ #include "acpi/bat_thresh.asl"
}
--
To view, visit https://review.coreboot.org/20913
To unsubscribe, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ia049407cea7a60887ecba7b7c96e5000473865dd
Gerrit-Change-Number: 20913
Gerrit-PatchSet: 1
Gerrit-Owner: Arthur Heymans <arthur(a)aheymans.xyz>
Patrick Rudolph has posted comments on this change. ( https://review.coreboot.org/20907 )
Change subject: nb/intel/sandybridge/raminit: Add Kconfig option for fuses
......................................................................
Patch Set 1:
(2 comments)
https://review.coreboot.org/#/c/20907/1/src/northbridge/intel/sandybridge/r…
File src/northbridge/intel/sandybridge/raminit_common.c:
https://review.coreboot.org/#/c/20907/1/src/northbridge/intel/sandybridge/r…
PS1, Line 406: TCK_1333MHZ
> Is faster than both ivy and sandy can run but that's not an issue I suppose
Ivybridge supports this frequency, but there's no board in tree that does. At the end the value here doesn't matter, but I don't want to return 0...
https://review.coreboot.org/#/c/20907/1/src/northbridge/intel/sandybridge/r…
PS1, Line 443: if (cfg->max_mem_clock_mhz >= 1066)
: return TCK_1066MHZ;
> unrelated but should be adapted for ivy bridge since that one can run faste
Yes, at the moment only 666mhz and 933mhz is being used. As this commit removes 933 I don't care that much.
--
To view, visit https://review.coreboot.org/20907
To unsubscribe, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I35dd78a02bcaafce8ba522d253c795d7835bacae
Gerrit-Change-Number: 20907
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Alexander Couzens <lynxis(a)fe80.eu>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Reviewer: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Nicola Corna <nicola(a)corna.info>
Gerrit-Reviewer: Patrick Rudolph <siro(a)das-labor.org>
Gerrit-Reviewer: Philipp Deppenwiese <zaolin.daisuki(a)gmail.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Comment-Date: Tue, 08 Aug 2017 18:07:01 +0000
Gerrit-HasComments: Yes