summaryrefslogtreecommitdiff
path: root/src/ec/starlabs/merlin/variants/tgl/events.asl
blob: ba09c8a3f47cdc1bec1f49888895d685501ff291 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
/* SPDX-License-Identifier: GPL-2.0-only */

Method (_Q0D, 0, NotSerialized)			// Event: Lid Opened
{
	\LIDS = LSTE
	Notify (LID0, 0x80)
}

Method (_Q0C, 0, NotSerialized)			// Event: Lid Closed
{
	\LIDS = LSTE
	Notify (LID0, 0x80)
}

Method (_Q0A, 0, NotSerialized)			// Event: AC Power Connected
{
	Notify (BAT0, 0x81)
	Notify (ADP1, 0x80)
}

Method (_Q0B, 0, NotSerialized)			// Event: AC Power Disconnected
{
	Notify (BAT0, 0x81)
	Notify (BAT0, 0x80)
}

Method (_Q05, 0, NotSerialized)			// Event: Backlight Brightness Down
{
	^^^^HIDD.HPEM (20)
}

Method (_Q06, 0, NotSerialized)			// Event: Backlight Brightness Up
{
	^^^^HIDD.HPEM (19)
}

Method (_Q87, 0, NotSerialized)			// Event: Function Lock
{
	FLKS = FLKA
}

Method (_Q88, 0, NotSerialized)			// Event: Trackpad Lock
{
	TPLS = TPLA
}
Method (_Q11)					// Event: Keyboard Backlight Brightness
{
	KLBC = KLBE
}

Method (_Q99, 0, NotSerialized)			// Event: Airplane Mode
{
	^^^^HIDD.HPEM (8)
}

Method (_QD5, 0, NotSerialized)			// Event: 10 Second Power Button Pressed
{
	Notify (HIDD, 0xCE)
}

Method (_QD6, 0, NotSerialized)			// Event: 10 Second Power Button Released
{
	Notify (HIDD, 0xCF)
}

Method (_Q22, 0, NotSerialized)			// Event: CHARGER_T
{
	Store ("EC: CHARGER_T", Debug)
}

Method (_Q40, 0, NotSerialized)			// Event: AC and DC Power
{
	SMB2 = 0xC6
}

Method (_Q41, 0, NotSerialized)			// Event: Battery Charge between 0% and 20%
{
	SMB2 = 0xC7
}

Method (_Q42, 0, NotSerialized)			// Event: Battery Charge between 20% and 60%
{
	SMB2 = 0xC8
}

Method (_Q43, 0, NotSerialized)			// Event: Battery Charge between 60% and 100%
{
	SMB2 = 0xC9
}

Method (_Q44, 0, NotSerialized)			// Event: AC Power Only
{
	SMB2 = 0xCA
}

Method (_Q80, 0, NotSerialized)			// Event: Volume Up
{
	Store ("EC: VOLUME_UP", Debug)
}

Method (_Q81, 0, NotSerialized)			// Event: Volume Down
{
	Store ("EC: VOLUME_DOWN", Debug)
}

Method (_Q54, 0, NotSerialized)			// Event: Power Button Press
{
	Store ("EC: PWRBTN", Debug)
}

Method (_QF0, 0, NotSerialized)			// Event: Temperature Report
{
	Store ("EC: Temperature Report", Debug)
}

Method (_QF1, 0, NotSerialized)			// Event: Temperature Trigger
{
	// Notify (SEN3, 0x90)
}

/*
 * The below events are unique to this platform.
 */

Method (_Q79, 0, NotSerialized)			// Event: USB Type-C
{
	Store ("EC: USB Type-C", Debug)
	UCEV()
}

Method (_Q85, 0, NotSerialized)			// Event: HOME
{
	Store ("EC: HOME", Debug)
}

Method (_Q01, 0, NotSerialized)			// Event: F1 Hot Key
{
	Store ("EC: F1", Debug)
}

Method (_Q02, 0, NotSerialized)			// Event: F2 Hot Key
{
	Store ("EC: F2", Debug)
}

Method (_Q03, 0, NotSerialized)			// Event: F3 Hot Key
{
	Store ("EC: F3", Debug)
}

Method (_Q04, 0, NotSerialized)			// Event: F4 Hot Key
{
	Store ("EC: F4", Debug)
}

Method (_Q08, 0, NotSerialized)			// Event: F5 Hot Key
{
	Store ("EC: F5", Debug)
}

Method (_Q09, 0, NotSerialized)			// Event: F6 Hot Key
{
	Store ("EC: F6", Debug)
}

Method (_Q07, 0, NotSerialized)			// Event: F7 Hot Key
{
	Store ("EC: F7", Debug)
}

Method (_Q10, 0, NotSerialized)			// Event: F10 Hot Key
{
	Store ("EC: F10", Debug)
}

Method (_Q12, 0, NotSerialized)			// Event: F12 Hot Key
{
	Store ("EC: F6", Debug)
}

Method (_Q0E, 0, NotSerialized)			// Event: SLEEP
{
	Store ("EC: SLEEP", Debug)
}

Method (_Q13, 0, NotSerialized)			// Event: BRIGHTNESS
{
	Store ("EC: BRIGHTNESS", Debug)
}

Method (_Q20, 0, NotSerialized)			// Event: CPU_T
{
	Store ("EC: CPU_T", Debug)
}

Method (_Q21, 0, NotSerialized)			// Event: SKIN_T
{
	Store ("EC: SKIN_T", Debug)
}

Method (_Q30, 0, NotSerialized)			// Event: THROT_OFF
{
	Store ("EC: THROT_OFF", Debug)
}

Method (_Q31, 0, NotSerialized)			// Event: THROT_LV1
{
	Store ("EC: THROT_LV1", Debug)
}

Method (_Q32, 0, NotSerialized)			// Event: THROT_LV2
{
	Store ("EC: THROT_LV2", Debug)
}

Method (_Q33, 0, NotSerialized)			// Event: THROT_LV3
{
	Store ("EC: THROT_LV3", Debug)
}

Method (_Q34, 0, NotSerialized)			// Event: THROT_LV4
{
	Store ("EC: THROT_LV4", Debug)
}

Method (_Q35, 0, NotSerialized)			// Event: THROT_LV5
{
	Store ("EC: THROT_LV5", Debug)
}

Method (_Q36, 0, NotSerialized)			// Event: THROT_LV6
{
	Store ("EC: THROT_LV6", Debug)
}

Method (_Q37, 0, NotSerialized)			// Event: THROT_LV7
{
	Store ("EC: THROT_LV7", Debug)
}

Method (_Q38, 0, NotSerialized)			// Event: CPU_DN_SPEED
{
	Store ("EC: CPU_DN_SPEED", Debug)
}

Method (_Q3C, 0, NotSerialized)			// Event: CPU_UP_SPEED
{
	Store ("EC: CPU_UP_SPEED", Debug)
}

Method (_Q3D, 0, NotSerialized)			// Event: CPU_TURBO_OFF
{
	Store ("EC: CPU_TURBO_OFF", Debug)
}

Method (_Q3E, 0, NotSerialized)			// Event: CPU_TURBO_ON
{
	Store ("EC: CPU_TURBO_ON", Debug)
}

Method (_Q3F, 0, NotSerialized)			// Event: SHUTDOWN
{
	Store ("EC: SHUTDOWN", Debug)
}

Method (_Q45, 0, NotSerialized)			// Event: SENSOR_T76
{
	SMB2 = 0xCB
}

Method (_Q48, 0, NotSerialized)			// Event: Fan Turbo On
{
	Store ("EC: Fan Turbo On", Debug)
}

Method (_Q49, 0, NotSerialized)			// Event: Fan Turbo Off
{
	Store ("EC: Fan Turbo Off", Debug)
}