Skip to content

Commit 7e0677a

Browse files
add ACPI methods for setting fan speeds
Change-Id: Ief47d46856369a8a66207b85b01a08833ceb242b
1 parent f1caea8 commit 7e0677a

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

src/ec/system76/ec/acpi/s76.asl

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,24 @@ Device (S76D) {
143143
Return ((Local1 << 8) | Local0)
144144
}
145145

146+
// Set Fan speed
147+
Method (SFD0, 1, Serialized) {
148+
If (^^PCI0.LPCB.EC0.ECOK) {
149+
^^PCI0.LPCB.EC0.FDAT = Zero
150+
^^PCI0.LPCB.EC0.FBUF = Arg0
151+
^^PCI0.LPCB.EC0.FCMD = 0xCE
152+
}
153+
}
154+
#if CONFIG(EC_SYSTEM76_EC_DGPU)
155+
Method (SFD1, 1, Serialized) {
156+
If (^^PCI0.LPCB.EC0.ECOK) {
157+
^^PCI0.LPCB.EC0.FDAT = Zero
158+
^^PCI0.LPCB.EC0.FBUF = Arg0
159+
^^PCI0.LPCB.EC0.FCMD = 0xCF
160+
}
161+
}
162+
#endif // CONFIG(EC_SYSTEM76_EC_DGPU)
163+
146164
// Temperature names
147165
Method (NTMP, 0, Serialized) {
148166
Return (Package (2) {

0 commit comments

Comments
 (0)