← Documents Documentation/hwmon/dell-smm-hwmon.rst GitHub 원문 ↗

Linux 6.18.37 · Hardware Monitoring

Kernel driver dell-smm-hwmon

Dell laptop SMM BIOS의 fan·temperature hwmon ABI, automatic control, transport와 firmware workaround입니다.

Source pathDocumentation/hwmon/dell-smm-hwmon.rst
Source versionLinux v6.18.37
TranslationDUJINLABS 전문 번역 + 해설

요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.

1. 요약·해설

원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.

요약·해설

dell-smm-hwmon.rst:1-407

Dell SMM driver가 BIOS의 fan·temperature 정보를 표준 hwmon과 thermal framework에 연결하고, 장치별 fan control code와 firmware bug를 다루는 방법을 설명합니다.

문서 개요
항목
SourceDocumentation/hwmon/dell-smm-hwmon.rst
분량407 source lines
Hwmon namedell_smm
Fan최대 4개
Temperature최대 10개
SMM transportLegacy ioport 또는 ACPI WMI

원문 분량과 핵심 interface입니다.

핵심 흐름
SMM transport 탐지Fan·temperature command 실행Hwmon attribute 게시Whitelist에 따른 control enableThermal governor·resume 상태 복원

BIOS SMM에서 thermal fan 제어까지의 경로입니다.

2. 영어 원문 전체

번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.

원문 전체 펼치기
1 .. SPDX-License-Identifier: GPL-2.0-or-later
2
3 .. include:: <isonum.txt>
4
5 Kernel driver dell-smm-hwmon
6 ============================
7
8 :Copyright: |copy| 2002-2005 Massimo Dal Zotto <dz@debian.org>
9 :Copyright: |copy| 2019 Giovanni Mascellani <gio@debian.org>
10
11 Description
12 -----------
13
14 On many Dell laptops the System Management Mode (SMM) BIOS can be
15 queried for the status of fans and temperature sensors. Userspace
16 utilities like ``sensors`` can be used to return the readings. The
17 userspace suite `i8kutils`__ can also be used to read the sensors and
18 automatically adjust fan speed (please notice that it currently uses
19 the deprecated ``/proc/i8k`` interface).
20
21 __ https://github.com/vitorafsr/i8kutils
22
23 ``sysfs`` interface
24 -------------------
25
26 Temperature sensors and fans can be queried and set via the standard
27 ``hwmon`` interface on ``sysfs``, under the directory
28 ``/sys/class/hwmon/hwmonX`` for some value of ``X`` (search for the
29 ``X`` such that ``/sys/class/hwmon/hwmonX/name`` has content
30 ``dell_smm``). A number of other attributes can be read or written:
31
32 =============================== ======= =======================================
33 Name Perm Description
34 =============================== ======= =======================================
35 fan[1-4]_input RO Fan speed in RPM.
36 fan[1-4]_label RO Fan label.
37 fan[1-4]_min RO Minimal Fan speed in RPM
38 fan[1-4]_max RO Maximal Fan speed in RPM
39 fan[1-4]_target RO Expected Fan speed in RPM
40 pwm[1-4] RW Control the fan PWM duty-cycle.
41 pwm[1-4]_enable RW/WO Enable or disable automatic BIOS fan
42 control (not supported on all laptops,
43 see below for details).
44 temp[1-10]_input RO Temperature reading in milli-degrees
45 Celsius.
46 temp[1-10]_label RO Temperature sensor label.
47 =============================== ======= =======================================
48
49 Due to the nature of the SMM interface, each pwmX attribute controls
50 fan number X.
51
52 Enabling/Disabling automatic BIOS fan control
53 ---------------------------------------------
54
55 There exist two methods for enabling/disabling automatic BIOS fan control:
56
57 1. Separate SMM commands to enable/disable automatic BIOS fan control for all fans.
58
59 2. A special fan state that enables automatic BIOS fan control for a individual fan.
60
61 The driver cannot reliably detect what method should be used on a given
62 device, so instead the following heuristic is used:
63
64 - use fan state 3 for enabling BIOS fan control if the maximum fan state
65 setable by the user is smaller than 3 (default setting).
66
67 - use separate SMM commands if device is whitelisted to support them.
68
69 When using the first method, each fan will have a standard ``pwmX_enable``
70 sysfs attribute. Writing ``1`` into this attribute will disable automatic
71 BIOS fan control for the associated fan and set it to maximum speed. Enabling
72 BIOS fan control again can be achieved by writing ``2`` into this attribute.
73 Reading this sysfs attributes returns the current setting as reported by
74 the underlying hardware.
75
76 When using the second method however, only the ``pwm1_enable`` sysfs attribute
77 will be available to enable/disable automatic BIOS fan control globaly for all
78 fans available on a given device. Additionally, this sysfs attribute is write-only
79 as there exists no SMM command for reading the current fan control setting.
80
81 If no ``pwmX_enable`` attributes are available, then it means that the driver
82 cannot use the first method and the SMM codes for enabling and disabling automatic
83 BIOS fan control are not whitelisted for your device. It is possible that codes
84 that work for other laptops actually work for yours as well, or that you have to
85 discover new codes.
86
87 Check the list ``i8k_whitelist_fan_control`` in file
88 ``drivers/hwmon/dell-smm-hwmon.c`` in the kernel tree: as a first
89 attempt you can try to add your machine and use an already-known code
90 pair. If, after recompiling the kernel, you see that ``pwm1_enable``
91 is present and works (i.e., you can manually control the fan speed),
92 then please submit your finding as a kernel patch, so that other users
93 can benefit from it. Please see
94 :ref:`Documentation/process/submitting-patches.rst <submittingpatches>`
95 for information on submitting patches.
96
97 If no known code works on your machine, you need to resort to do some
98 probing, because unfortunately Dell does not publish datasheets for
99 its SMM. You can experiment with the code in `this repository`__ to
100 probe the BIOS on your machine and discover the appropriate codes.
101
102 __ https://github.com/clopez/dellfan/
103
104 Again, when you find new codes, we'd be happy to have your patches!
105
106 ``thermal`` interface
107 ---------------------------
108
109 The driver also exports the fans as thermal cooling devices with
110 ``type`` set to ``dell-smm-fan[1-4]``. This allows for easy fan control
111 using one of the thermal governors.
112
113 Module parameters
114 -----------------
115
116 * force:bool
117 Force loading without checking for supported
118 models. (default: 0)
119
120 * ignore_dmi:bool
121 Continue probing hardware even if DMI data does not
122 match. (default: 0)
123
124 * restricted:bool
125 Allow fan control only to processes with the
126 ``CAP_SYS_ADMIN`` capability set or processes run
127 as root when using the legacy ``/proc/i8k``
128 interface. In this case normal users will be able
129 to read temperature and fan status but not to
130 control the fan. If your notebook is shared with
131 other users and you don't trust them you may want
132 to use this option. (default: 1, only available
133 with ``CONFIG_I8K``)
134
135 * power_status:bool
136 Report AC status in ``/proc/i8k``. (default: 0,
137 only available with ``CONFIG_I8K``)
138
139 * fan_mult:uint
140 Factor to multiply fan speed with. (default:
141 autodetect)
142
143 * fan_max:uint
144 Maximum configurable fan speed. (default:
145 autodetect)
146
147 Legacy ``/proc`` interface
148 --------------------------
149
150 .. warning:: This interface is obsolete and deprecated and should not
151 used in new applications. This interface is only
152 available when kernel is compiled with option
153 ``CONFIG_I8K``.
154
155 The information provided by the kernel driver can be accessed by
156 simply reading the ``/proc/i8k`` file. For example::
157
158 $ cat /proc/i8k
159 1.0 A17 2J59L02 52 2 1 8040 6420 1 2
160
161 The fields read from ``/proc/i8k`` are::
162
163 1.0 A17 2J59L02 52 2 1 8040 6420 1 2
164 | | | | | | | | | |
165 | | | | | | | | | +------- 10. buttons status
166 | | | | | | | | +--------- 9. AC status
167 | | | | | | | +-------------- 8. fan0 RPM
168 | | | | | | +------------------- 7. fan1 RPM
169 | | | | | +--------------------- 6. fan0 status
170 | | | | +----------------------- 5. fan1 status
171 | | | +-------------------------- 4. temp0 reading (Celsius)
172 | | +---------------------------------- 3. Dell service tag (later known as 'serial number')
173 | +-------------------------------------- 2. BIOS version
174 +------------------------------------------ 1. /proc/i8k format version
175
176 A negative value, for example -22, indicates that the BIOS doesn't
177 return the corresponding information. This is normal on some
178 models/BIOSes.
179
180 For performance reasons the ``/proc/i8k`` doesn't report by default
181 the AC status since this SMM call takes a long time to execute and is
182 not really needed. If you want to see the ac status in ``/proc/i8k``
183 you must explictitly enable this option by passing the
184 ``power_status=1`` parameter to insmod. If AC status is not
185 available -1 is printed instead.
186
187 The driver provides also an ioctl interface which can be used to
188 obtain the same information and to control the fan status. The ioctl
189 interface can be accessed from C programs or from shell using the
190 i8kctl utility. See the source file of ``i8kutils`` for more
191 information on how to use the ioctl interface.
192
193 SMM Interface
194 -------------
195
196 .. warning:: The SMM interface was reverse-engineered by trial-and-error
197 since Dell did not provide any Documentation,
198 please keep that in mind.
199
200 The driver uses the SMM interface to send commands to the system BIOS.
201 This interface is normally used by Dell's 32-bit diagnostic program or
202 on newer notebook models by the buildin BIOS diagnostics.
203 The SMM may cause short hangs when the BIOS code is taking too long to
204 execute.
205
206 The SMM handler inside the system BIOS looks at the contents of the
207 ``eax``, ``ebx``, ``ecx``, ``edx``, ``esi`` and ``edi`` registers.
208 Each register has a special purpose:
209
210 =============== ==================================
211 Register Purpose
212 =============== ==================================
213 eax Holds the command code before SMM,
214 holds the first result after SMM.
215 ebx Holds the arguments.
216 ecx Unknown, set to 0.
217 edx Holds the second result after SMM.
218 esi Unknown, set to 0.
219 edi Unknown, set to 0.
220 =============== ==================================
221
222 The SMM handler can signal a failure by either:
223
224 - setting the lower sixteen bits of ``eax`` to ``0xffff``
225 - not modifying ``eax`` at all
226 - setting the carry flag (legacy SMM interface only)
227
228 Legacy SMM Interface
229 --------------------
230
231 When using the legacy SMM interface, a SMM is triggered by writing the least significant byte
232 of the command code to the special ioports ``0xb2`` and ``0x84``. This interface is not
233 described inside the ACPI tables and can thus only be detected by issuing a test SMM call.
234
235 WMI SMM Interface
236 -----------------
237
238 On modern Dell machines, the SMM calls are done over ACPI WMI:
239
240 ::
241
242 #pragma namespace("\\\\.\\root\\dcim\\sysman\\diagnostics")
243 [WMI, Provider("Provider_DiagnosticsServices"), Dynamic, Locale("MS\\0x409"),
244 Description("RunDellDiag"), guid("{F1DDEE52-063C-4784-A11E-8A06684B9B01}")]
245 class LegacyDiags {
246 [key, read] string InstanceName;
247 [read] boolean Active;
248
249 [WmiMethodId(1), Implemented, read, write, Description("Legacy Method ")]
250 void Execute([in, out] uint32 EaxLen, [in, out, WmiSizeIs("EaxLen") : ToInstance] uint8 EaxVal[],
251 [in, out] uint32 EbxLen, [in, out, WmiSizeIs("EbxLen") : ToInstance] uint8 EbxVal[],
252 [in, out] uint32 EcxLen, [in, out, WmiSizeIs("EcxLen") : ToInstance] uint8 EcxVal[],
253 [in, out] uint32 EdxLen, [in, out, WmiSizeIs("EdxLen") : ToInstance] uint8 EdxVal[]);
254 };
255
256 Some machines support only the WMI SMM interface, while some machines support both interfaces.
257 The driver automatically detects which interfaces are present and will use the WMI SMM interface
258 if the legacy SMM interface is not present. The WMI SMM interface is usually slower than the
259 legacy SMM interface since ACPI methods need to be called in order to trigger a SMM.
260
261 SMM command codes
262 -----------------
263
264 =============== ======================= ================================================
265 Command Code Command Name Description
266 =============== ======================= ================================================
267 ``0x0025`` Get Fn key status Returns the Fn key pressed after SMM:
268
269 - 9th bit in ``eax`` indicates Volume up
270 - 10th bit in ``eax`` indicates Volume down
271 - both bits indicate Volume mute
272
273 ``0xa069`` Get power status Returns current power status after SMM:
274
275 - 1st bit in ``eax`` indicates Battery connected
276 - 3th bit in ``eax`` indicates AC connected
277
278 ``0x00a3`` Get fan state Returns current fan state after SMM:
279
280 - 1st byte in ``eax`` holds the current
281 fan state (0 - 2 or 3)
282
283 ``0x01a3`` Set fan state Sets the fan speed:
284
285 - 1st byte in ``ebx`` holds the fan number
286 - 2nd byte in ``ebx`` holds the desired
287 fan state (0 - 2 or 3)
288
289 ``0x02a3`` Get fan speed Returns the current fan speed in RPM:
290
291 - 1st byte in ``ebx`` holds the fan number
292 - 1st word in ``eax`` holds the current
293 fan speed in RPM (after SMM)
294
295 ``0x03a3`` Get fan type Returns the fan type:
296
297 - 1st byte in ``ebx`` holds the fan number
298 - 1st byte in ``eax`` holds the
299 fan type (after SMM):
300
301 - 5th bit indicates docking fan
302 - 1 indicates Processor fan
303 - 2 indicates Motherboard fan
304 - 3 indicates Video fan
305 - 4 indicates Power supply fan
306 - 5 indicates Chipset fan
307 - 6 indicates other fan type
308
309 ``0x04a3`` Get nominal fan speed Returns the nominal RPM in each fan state:
310
311 - 1st byte in ``ebx`` holds the fan number
312 - 2nd byte in ``ebx`` holds the fan state
313 in question (0 - 2 or 3)
314 - 1st word in ``eax`` holds the nominal
315 fan speed in RPM (after SMM)
316
317 ``0x05a3`` Get fan speed tolerance Returns the speed tolerance for each fan state:
318
319 - 1st byte in ``ebx`` holds the fan number
320 - 2nd byte in ``ebx`` holds the fan state
321 in question (0 - 2 or 3)
322 - 1st byte in ``eax`` returns the speed
323 tolerance
324
325 ``0x10a3`` Get sensor temperature Returns the measured temperature:
326
327 - 1st byte in ``ebx`` holds the sensor number
328 - 1st byte in ``eax`` holds the measured
329 temperature (after SMM)
330
331 ``0x11a3`` Get sensor type Returns the sensor type:
332
333 - 1st byte in ``ebx`` holds the sensor number
334 - 1st byte in ``eax`` holds the
335 temperature type (after SMM):
336
337 - 1 indicates CPU sensor
338 - 2 indicates GPU sensor
339 - 3 indicates SODIMM sensor
340 - 4 indicates other sensor type
341 - 5 indicates Ambient sensor
342 - 6 indicates other sensor type
343
344 ``0xfea3`` Get SMM signature Returns Dell signature if interface
345 is supported (after SMM):
346
347 - ``eax`` holds 1145651527
348 (0x44494147 or "DIAG")
349 - ``edx`` holds 1145392204
350 (0x44454c4c or "DELL")
351
352 ``0xffa3`` Get SMM signature Same as ``0xfea3``, check both.
353 =============== ======================= ================================================
354
355 There are additional commands for enabling (``0x31a3`` or ``0x35a3``) and
356 disabling (``0x30a3`` or ``0x34a3``) automatic fan speed control.
357 The commands are however causing severe sideeffects on many machines, so
358 they are not used by default.
359
360 On several machines (Inspiron 3505, Precision 490, Vostro 1720, ...), the
361 fans supports a 4th "magic" state, which signals the BIOS that automatic
362 fan control should be enabled for a specific fan.
363 However there are also some machines who do support a 4th regular fan state too,
364 but in case of the "magic" state, the nominal RPM reported for this state is a
365 placeholder value, which however is not always detectable.
366
367 Firmware Bugs
368 -------------
369
370 The SMM calls can behave erratic on some machines:
371
372 ======================================================= =================
373 Firmware Bug Affected Machines
374 ======================================================= =================
375 Reading of fan states return spurious errors. Precision 490
376
377 OptiPlex 7060
378
379 Reading of fan types causes erratic fan behaviour. Studio XPS 8000
380
381 Studio XPS 8100
382
383 Inspiron 580
384
385 Inspiron 3505
386
387 Fan-related SMM calls take too long (about 500ms). Inspiron 7720
388
389 Vostro 3360
390
391 XPS 13 9333
392
393 XPS 15 L502X
394 ======================================================= =================
395
396 In case you experience similar issues on your Dell machine, please
397 submit a bugreport on bugzilla to we can apply workarounds.
398
399 Limitations
400 -----------
401
402 The SMM calls can take too long to execute on some machines, causing
403 short hangs and/or audio glitches.
404 Also the fan state needs to be restored after suspend, as well as
405 the automatic mode settings.
406 When reading a temperature sensor, values above 127 degrees indicate
407 a BIOS read error or a deactivated sensor.
408

3. 한국어 전문 번역

영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.

Dell SMM fan·temperature driver 개요

1-25

이 문서는 GPL-2.0-or-later 라이선스의 `dell-smm-hwmon` 커널 드라이버를 설명합니다. 저작권은 2002~2005년 Massimo Dal Zotto와 2019년 Giovanni Mascellani에게 있습니다.

많은 Dell laptop에서는 System Management Mode(SMM) BIOS에 질의해 fan과 temperature sensor 상태를 얻을 수 있습니다. Userspace의 `sensors`가 측정값을 표시할 수 있고, `i8kutils` suite도 sensor를 읽고 fan speed를 자동 조절할 수 있습니다.

다만 `i8kutils`는 현재 deprecated된 `/proc/i8k` interface를 사용합니다. 프로젝트 주소는 `https://github.com/vitorafsr/i8kutils`입니다.

Dell SMM 감시 경로
계층역할
Dell BIOSSMM command로 fan·temperature 정보 제공
dell-smm-hwmonSMM 응답을 hwmon ABI로 변환
sensors표준 sysfs 측정값 표시
i8kutilsLegacy /proc/i8k로 읽기·fan 자동 조절

BIOS SMM 값을 표준 hwmon과 legacy 도구가 소비합니다.

측정값 조회
Fan·sensor 식별SMM BIOS command 실행Kernel driver가 응답 해석Hwmon sysfs attribute 게시sensors가 값 표시

SMM call부터 userspace 표시까지의 흐름입니다.

.. SPDX-License-Identifier: GPL-2.0-or-later

.. include:: <isonum.txt>

Kernel driver dell-smm-hwmon
============================

:Copyright: |copy| 2002-2005 Massimo Dal Zotto <dz@debian.org>
:Copyright: |copy| 2019 Giovanni Mascellani <gio@debian.org>

Description
-----------

On many Dell laptops the System Management Mode (SMM) BIOS can be
queried for the status of fans and temperature sensors.  Userspace
utilities like ``sensors`` can be used to return the readings. The
userspace suite `i8kutils`__ can also be used to read the sensors and
automatically adjust fan speed (please notice that it currently uses
the deprecated ``/proc/i8k`` interface).

 __ https://github.com/vitorafsr/i8kutils

``sysfs`` interface
-------------------

표준 hwmon sysfs ABI

26-51

Temperature sensor와 fan은 표준 hwmon sysfs interface로 질의하고 설정할 수 있습니다. 경로는 `/sys/class/hwmon/hwmonX`이며, `/sys/class/hwmon/hwmonX/name`의 내용이 `dell_smm`인 `X`를 찾아야 합니다.

`fan[1-4]_input`은 RPM, `fan[1-4]_label`은 fan label, `fan[1-4]_min`·`max`는 최소·최대 RPM, `fan[1-4]_target`은 예상 RPM을 read-only로 제공합니다.

`pwm[1-4]`는 read-write PWM duty-cycle control입니다. `pwm[1-4]_enable`은 BIOS automatic fan control을 enable 또는 disable하며 read-write 또는 write-only입니다. 모든 laptop에서 지원되지는 않습니다.

`temp[1-10]_input`은 millidegree Celsius 측정값, `temp[1-10]_label`은 sensor label을 read-only로 제공합니다. SMM interface의 성격상 각 `pwmX` attribute는 fan number `X`를 제어합니다.

dell_smm sysfs attribute
Name권한설명
fan[1-4]_inputROFan speed in RPM
fan[1-4]_labelROFan label
fan[1-4]_minROMinimum fan RPM
fan[1-4]_maxROMaximum fan RPM
fan[1-4]_targetROExpected fan RPM
pwm[1-4]RWPWM duty-cycle control
pwm[1-4]_enableRW/WOAutomatic BIOS fan control
temp[1-10]_inputROTemperature in millidegree Celsius
temp[1-10]_labelROTemperature sensor label

Fan 4개와 temperature sensor 10개의 표준 ABI입니다.

Hwmon fan 제어
name=dell_smm인 hwmonX 검색fanX_input·target 읽기pwmX_enable mode 확인pwmX duty-cycle 설정tempX_input 감시

동일한 번호의 pwm과 fan이 직접 대응합니다.

Temperature sensors and fans can be queried and set via the standard
``hwmon`` interface on ``sysfs``, under the directory
``/sys/class/hwmon/hwmonX`` for some value of ``X`` (search for the
``X`` such that ``/sys/class/hwmon/hwmonX/name`` has content
``dell_smm``). A number of other attributes can be read or written:

=============================== ======= =======================================
Name                                Perm        Description
=============================== ======= =======================================
fan[1-4]_input                  RO      Fan speed in RPM.
fan[1-4]_label                  RO      Fan label.
fan[1-4]_min                    RO      Minimal Fan speed in RPM
fan[1-4]_max                    RO      Maximal Fan speed in RPM
fan[1-4]_target                 RO      Expected Fan speed in RPM
pwm[1-4]                        RW      Control the fan PWM duty-cycle.
pwm[1-4]_enable                 RW/WO   Enable or disable automatic BIOS fan
                                        control (not supported on all laptops,
                                        see below for details).
temp[1-10]_input                RO      Temperature reading in milli-degrees
                                        Celsius.
temp[1-10]_label                RO      Temperature sensor label.
=============================== ======= =======================================

Due to the nature of the SMM interface, each pwmX attribute controls
fan number X.

Automatic BIOS fan control 선택과 whitelist

52-108

Automatic BIOS fan control을 enable·disable하는 방식은 두 가지입니다. 하나는 모든 fan에 대해 automatic control을 켜고 끄는 별도 SMM command이고, 다른 하나는 개별 fan의 automatic control을 enable하는 특수 fan state입니다.

Driver는 장치마다 어떤 방식을 써야 하는지 신뢰성 있게 탐지할 수 없습니다. 그래서 사용자가 설정할 수 있는 최대 fan state가 3보다 작으면 기본적으로 fan state 3을 BIOS fan control enable에 사용하고, 별도 SMM command 지원 장치로 whitelist되어 있으면 그 command를 사용합니다.

문서가 첫 번째 방식이라고 설명하는 경우 각 fan에 표준 `pwmX_enable`이 생깁니다. 여기에 `1`을 쓰면 해당 fan의 automatic BIOS control을 disable하고 maximum speed로 설정합니다. `2`를 쓰면 BIOS control을 다시 enable합니다. 읽으면 hardware가 보고한 현재 설정을 반환합니다.

문서가 두 번째 방식이라고 설명하는 경우에는 장치의 모든 fan을 전역 enable·disable하는 `pwm1_enable`만 제공됩니다. 현재 fan control setting을 읽는 SMM command가 없으므로 이 attribute는 write-only입니다.

`pwmX_enable`이 전혀 없으면 driver가 첫 번째 방식을 사용할 수 없고 automatic BIOS fan control enable·disable용 SMM code도 해당 장치에 whitelist되지 않았다는 뜻입니다. 다른 laptop의 code가 동작할 수도 있고 새 code를 찾아야 할 수도 있습니다.

Kernel tree의 `drivers/hwmon/dell-smm-hwmon.c`에 있는 `i8k_whitelist_fan_control`을 확인하십시오. 우선 machine을 추가하고 기존 code pair를 시험할 수 있습니다. Kernel 재컴파일 뒤 `pwm1_enable`이 나타나고 수동 fan 제어가 동작하면 다른 사용자도 쓸 수 있도록 kernel patch를 제출해야 합니다. 제출 절차는 `Documentation/process/submitting-patches.rst`를 참조합니다.

알려진 code가 작동하지 않으면 Dell이 SMM datasheet를 공개하지 않으므로 probing이 필요합니다. `https://github.com/clopez/dellfan/`의 code로 BIOS를 probe해 맞는 code를 찾을 수 있으며, 새 code를 찾으면 patch 제출이 권장됩니다.

Automatic fan control 방식
조건·방식노출 ABI동작
Maximum user fan state < 3pwmX_enableState 3을 BIOS automatic mode로 사용
Separate SMM commands whitelistpwm1_enable 또는 장치 방식Global BIOS control command 사용
Readable per-fan attributepwmX_enable RW1=manual maximum, 2=BIOS automatic
Global command without readbackpwm1_enable WO모든 fan을 전역 enable·disable
지원 정보 없음Attribute 없음Whitelist 또는 새 code 필요

Driver가 fan state와 whitelist를 선택하는 heuristic입니다.

새 Dell model 검증
i8k_whitelist_fan_control 확인Machine DMI entry와 기존 code pair 추가Kernel 재컴파일pwm1_enable·manual fan 제어 검증동작 결과를 kernel patch로 제출

기존 code를 안전하게 시험하고 upstream에 공유합니다.

Enabling/Disabling automatic BIOS fan control
---------------------------------------------

There exist two methods for enabling/disabling automatic BIOS fan control:

1. Separate SMM commands to enable/disable automatic BIOS fan control for all fans.

2. A special fan state that enables automatic BIOS fan control for a individual fan.

The driver cannot reliably detect what method should be used on a given
device, so instead the following heuristic is used:

- use fan state 3 for enabling BIOS fan control if the maximum fan state
  setable by the user is smaller than 3 (default setting).

- use separate SMM commands if device is whitelisted to support them.

When using the first method, each fan will have a standard ``pwmX_enable``
sysfs attribute. Writing ``1`` into this attribute will disable automatic
BIOS fan control for the associated fan and set it to maximum speed. Enabling
BIOS fan control again can be achieved by writing ``2`` into this attribute.
Reading this sysfs attributes returns the current setting as reported by
the underlying hardware.

When using the second method however, only the ``pwm1_enable`` sysfs attribute
will be available to enable/disable automatic BIOS fan control globaly for all
fans available on a given device. Additionally, this sysfs attribute is write-only
as there exists no SMM command for reading the current fan control setting.

If no ``pwmX_enable`` attributes are available, then it means that the driver
cannot use the first method and the SMM codes for enabling and disabling automatic
BIOS fan control are not whitelisted for your device. It is possible that codes
that work for other laptops actually work for yours as well, or that you have to
discover new codes.

Check the list ``i8k_whitelist_fan_control`` in file
``drivers/hwmon/dell-smm-hwmon.c`` in the kernel tree: as a first
attempt you can try to add your machine and use an already-known code
pair. If, after recompiling the kernel, you see that ``pwm1_enable``
is present and works (i.e., you can manually control the fan speed),
then please submit your finding as a kernel patch, so that other users
can benefit from it. Please see
:ref:`Documentation/process/submitting-patches.rst <submittingpatches>`
for information on submitting patches.

If no known code works on your machine, you need to resort to do some
probing, because unfortunately Dell does not publish datasheets for
its SMM. You can experiment with the code in `this repository`__ to
probe the BIOS on your machine and discover the appropriate codes.

 __ https://github.com/clopez/dellfan/

Again, when you find new codes, we'd be happy to have your patches!

``thermal`` interface
---------------------------

Thermal cooling device와 module parameter

109-146

Driver는 fan을 `type`이 `dell-smm-fan[1-4]`인 thermal cooling device로도 export합니다. 따라서 thermal governor 중 하나로 fan을 쉽게 제어할 수 있습니다.

`force:bool`은 지원 model 확인 없이 강제로 load하며 기본값은 0입니다. `ignore_dmi:bool`은 DMI data가 일치하지 않아도 hardware probing을 계속하며 기본값은 0입니다.

`restricted:bool`은 legacy `/proc/i8k` interface에서 `CAP_SYS_ADMIN` capability가 있는 process 또는 root만 fan을 제어하게 합니다. 일반 사용자는 temperature와 fan status는 읽을 수 있지만 fan은 제어할 수 없습니다. 공유 notebook에서 다른 사용자를 신뢰하지 않을 때 유용합니다. 기본값은 1이며 `CONFIG_I8K`에서만 제공됩니다.

`power_status:bool`은 `/proc/i8k`에 AC status를 보고합니다. 기본값은 0이고 `CONFIG_I8K`에서만 사용할 수 있습니다. `fan_mult:uint`는 fan speed에 곱할 factor, `fan_max:uint`는 설정 가능한 maximum fan speed이며 둘 다 기본값은 autodetect입니다.

dell-smm-hwmon module parameter
Parameter기본값효과
force:bool0지원 model 확인 없이 load
ignore_dmi:bool0DMI mismatch에도 probe 계속
restricted:bool1Fan control을 CAP_SYS_ADMIN/root로 제한, CONFIG_I8K 전용
power_status:bool0/proc/i8k AC status 보고, CONFIG_I8K 전용
fan_mult:uintautodetectFan speed multiplier
fan_max:uintautodetectMaximum configurable fan speed

Load 정책, 권한, legacy 출력과 fan scaling을 제어합니다.

Thermal governor 연동
SMM fan 발견dell-smm-fanX cooling device 등록Thermal governor가 cooling state 선택Driver가 fan state 적용RPM과 temperature feedback 확인

Hwmon fan을 cooling device로 thermal framework에 연결합니다.

The driver also exports the fans as thermal cooling devices with
``type`` set to ``dell-smm-fan[1-4]``. This allows for easy fan control
using one of the thermal governors.

Module parameters
-----------------

* force:bool
                   Force loading without checking for supported
                   models. (default: 0)

* ignore_dmi:bool
                   Continue probing hardware even if DMI data does not
                   match. (default: 0)

* restricted:bool
                   Allow fan control only to processes with the
                   ``CAP_SYS_ADMIN`` capability set or processes run
                   as root when using the legacy ``/proc/i8k``
                   interface. In this case normal users will be able
                   to read temperature and fan status but not to
                   control the fan.  If your notebook is shared with
                   other users and you don't trust them you may want
                   to use this option. (default: 1, only available
                   with ``CONFIG_I8K``)

* power_status:bool
                   Report AC status in ``/proc/i8k``. (default: 0,
                   only available with ``CONFIG_I8K``)

* fan_mult:uint
                   Factor to multiply fan speed with. (default:
                   autodetect)

* fan_max:uint
                   Maximum configurable fan speed. (default:
                   autodetect)

Deprecated /proc/i8k와 ioctl

147-192

경고: `/proc/i8k` interface는 obsolete·deprecated 상태이며 새 application에서 사용하면 안 됩니다. Kernel이 `CONFIG_I8K` option으로 compile된 경우에만 제공됩니다.

Kernel driver 정보는 `/proc/i8k`를 읽어 접근할 수 있습니다. 예시 출력은 `1.0 A17 2J59L02 52 2 1 8040 6420 1 2`입니다.

10개 field는 순서대로 `/proc/i8k` format version, BIOS version, Dell service tag(후에는 serial number로 알려짐), `temp0` Celsius, `fan1` status, `fan0` status, `fan1` RPM, `fan0` RPM, AC status, button status입니다. 원문의 ASCII 좌표는 아래 구조화 표로 같은 대응 관계를 표시했습니다.

`-22` 같은 negative value는 BIOS가 해당 정보를 반환하지 않았다는 뜻이며 일부 model·BIOS에서는 정상입니다. `/proc/i8k`는 성능상 기본적으로 AC status를 보고하지 않습니다. 이 SMM call은 실행 시간이 길고 보통 필요하지 않기 때문입니다.

AC status를 보려면 insmod에 `power_status=1`을 명시해야 합니다. AC status를 얻을 수 없으면 `-1`을 출력합니다.

Driver는 같은 정보를 얻고 fan status를 제어하는 ioctl interface도 제공합니다. C program에서 접근하거나 shell의 `i8kctl` utility를 사용할 수 있으며, 자세한 사용법은 `i8kutils` source를 참조합니다.

/proc/i8k field 좌표
번호예시의미
11.0/proc/i8k format version
2A17BIOS version
32J59L02Dell service tag / serial number
452temp0 reading, Celsius
52fan1 status
61fan0 status
78040fan1 RPM
86420fan0 RPM
91AC status
102Buttons status

ASCII 연결선이 나타낸 10개 field의 순서를 구조화했습니다.

Legacy 정보 접근
CONFIG_I8K로 interface 활성화/proc/i8k 한 줄 읽기10개 positional field 해석Negative value를 미지원 정보로 처리필요하면 ioctl·i8kctl로 fan 제어

Deprecated proc 또는 ioctl 경로로 같은 SMM 정보를 사용합니다.

Legacy ``/proc`` interface
--------------------------

.. warning:: This interface is obsolete and deprecated and should not
             used in new applications. This interface is only
             available when kernel is compiled with option
             ``CONFIG_I8K``.

The information provided by the kernel driver can be accessed by
simply reading the ``/proc/i8k`` file. For example::

    $ cat /proc/i8k
    1.0 A17 2J59L02 52 2 1 8040 6420 1 2

The fields read from ``/proc/i8k`` are::

    1.0 A17 2J59L02 52 2 1 8040 6420 1 2
    |   |   |       |  | | |    |    | |
    |   |   |       |  | | |    |    | +------- 10. buttons status
    |   |   |       |  | | |    |    +--------- 9.  AC status
    |   |   |       |  | | |    +-------------- 8.  fan0 RPM
    |   |   |       |  | | +------------------- 7.  fan1 RPM
    |   |   |       |  | +--------------------- 6.  fan0 status
    |   |   |       |  +----------------------- 5.  fan1 status
    |   |   |       +-------------------------- 4.  temp0 reading (Celsius)
    |   |   +---------------------------------- 3.  Dell service tag (later known as 'serial number')
    |   +-------------------------------------- 2.  BIOS version
    +------------------------------------------ 1.  /proc/i8k format version

A negative value, for example -22, indicates that the BIOS doesn't
return the corresponding information. This is normal on some
models/BIOSes.

For performance reasons the ``/proc/i8k`` doesn't report by default
the AC status since this SMM call takes a long time to execute and is
not really needed.  If you want to see the ac status in ``/proc/i8k``
you must explictitly enable this option by passing the
``power_status=1`` parameter to insmod. If AC status is not
available -1 is printed instead.

The driver provides also an ioctl interface which can be used to
obtain the same information and to control the fan status. The ioctl
interface can be accessed from C programs or from shell using the
i8kctl utility. See the source file of ``i8kutils`` for more
information on how to use the ioctl interface.

SMM register, legacy ioport와 ACPI WMI

193-260

경고: Dell이 문서를 제공하지 않았기 때문에 SMM interface는 trial-and-error로 reverse engineering되었습니다.

Driver는 SMM interface로 system BIOS에 command를 보냅니다. 이 interface는 보통 Dell 32-bit diagnostic program이 사용하고 newer notebook에서는 built-in BIOS diagnostic이 사용합니다. BIOS code 실행이 오래 걸리면 SMM이 짧은 hang을 일으킬 수 있습니다.

System BIOS의 SMM handler는 `eax`, `ebx`, `ecx`, `edx`, `esi`, `edi` register 내용을 봅니다. `eax`는 SMM 전 command code와 SMM 후 첫 result, `ebx`는 argument, `edx`는 두 번째 result를 담습니다. `ecx`, `esi`, `edi`의 용도는 알려지지 않아 0으로 설정합니다.

SMM handler는 `eax` 하위 16-bit를 `0xffff`로 설정하거나, `eax`를 전혀 변경하지 않거나, legacy SMM interface에서 carry flag를 설정해 failure를 알릴 수 있습니다.

Legacy interface는 command code의 least significant byte를 special ioport `0xb2`와 `0x84`에 써서 SMM을 trigger합니다. ACPI table에 기술되지 않으므로 test SMM call을 실행해야만 탐지할 수 있습니다.

Modern Dell machine은 ACPI WMI의 `LegacyDiags` class와 GUID `{F1DDEE52-063C-4784-A11E-8A06684B9B01}`을 통해 SMM call을 실행합니다. `Execute` method는 `EaxVal`, `EbxVal`, `EcxVal`, `EdxVal` byte array와 각 length를 in·out parameter로 전달합니다.

일부 machine은 WMI SMM만 지원하고 일부는 두 interface를 모두 지원합니다. Driver는 존재하는 interface를 자동 탐지하고 legacy가 없으면 WMI를 사용합니다. WMI는 SMM trigger에 ACPI method call이 필요해 보통 legacy보다 느립니다.

SMM register 역할
Register용도
eaxCommand code before SMM, first result after SMM
ebxArguments
ecxUnknown, set to 0
edxSecond result after SMM
esiUnknown, set to 0
ediUnknown, set to 0
Failureeax low 16-bit=0xffff, eax unchanged, or legacy carry flag

SMM 전후 register contract와 failure 표시입니다.

SMM transport 선택
Register argument 구성Legacy ioport test callLegacy가 없으면 ACPI WMI 탐지선택한 transport로 SMM triggereax·edx result와 failure 조건 확인

탐지 결과에 따라 legacy 또는 WMI 경로로 register를 전달합니다.

SMM Interface
-------------

.. warning:: The SMM interface was reverse-engineered by trial-and-error
             since Dell did not provide any Documentation,
             please keep that in mind.

The driver uses the SMM interface to send commands to the system BIOS.
This interface is normally used by Dell's 32-bit diagnostic program or
on newer notebook models by the buildin BIOS diagnostics.
The SMM may cause short hangs when the BIOS code is taking too long to
execute.

The SMM handler inside the system BIOS looks at the contents of the
``eax``, ``ebx``, ``ecx``, ``edx``, ``esi`` and ``edi`` registers.
Each register has a special purpose:

=============== ==================================
Register        Purpose
=============== ==================================
eax             Holds the command code before SMM,
                holds the first result after SMM.
ebx             Holds the arguments.
ecx             Unknown, set to 0.
edx             Holds the second result after SMM.
esi             Unknown, set to 0.
edi             Unknown, set to 0.
=============== ==================================

The SMM handler can signal a failure by either:

- setting the lower sixteen bits of ``eax`` to ``0xffff``
- not modifying ``eax`` at all
- setting the carry flag (legacy SMM interface only)

Legacy SMM Interface
--------------------

When using the legacy SMM interface, a SMM is triggered by writing the least significant byte
of the command code to the special ioports ``0xb2`` and ``0x84``. This interface is not
described inside the ACPI tables and can thus only be detected by issuing a test SMM call.

WMI SMM Interface
-----------------

On modern Dell machines, the SMM calls are done over ACPI WMI:

::

 #pragma namespace("\\\\.\\root\\dcim\\sysman\\diagnostics")
 [WMI, Provider("Provider_DiagnosticsServices"), Dynamic, Locale("MS\\0x409"),
  Description("RunDellDiag"), guid("{F1DDEE52-063C-4784-A11E-8A06684B9B01}")]
 class LegacyDiags {
  [key, read] string InstanceName;
  [read] boolean Active;

  [WmiMethodId(1), Implemented, read, write, Description("Legacy Method ")]
  void Execute([in, out] uint32 EaxLen, [in, out, WmiSizeIs("EaxLen") : ToInstance] uint8 EaxVal[],
               [in, out] uint32 EbxLen, [in, out, WmiSizeIs("EbxLen") : ToInstance] uint8 EbxVal[],
               [in, out] uint32 EcxLen, [in, out, WmiSizeIs("EcxLen") : ToInstance] uint8 EcxVal[],
               [in, out] uint32 EdxLen, [in, out, WmiSizeIs("EdxLen") : ToInstance] uint8 EdxVal[]);
 };

Some machines support only the WMI SMM interface, while some machines support both interfaces.
The driver automatically detects which interfaces are present and will use the WMI SMM interface
if the legacy SMM interface is not present. The WMI SMM interface is usually slower than the
legacy SMM interface since ACPI methods need to be called in order to trigger a SMM.

SMM command code와 magic fan state

261-366

`0x0025` Get Fn key status는 SMM 뒤 `eax` 9th bit가 Volume up, 10th bit가 Volume down, 두 bit가 모두 설정되면 Volume mute를 뜻합니다. `0xa069` Get power status는 `eax` 1st bit가 battery connected, 3th bit가 AC connected를 뜻합니다.

`0x00a3` Get fan state는 SMM 뒤 `eax` 1st byte에 현재 fan state 0~2 또는 3을 반환합니다. `0x01a3` Set fan state는 `ebx` 1st byte에 fan number, 2nd byte에 원하는 state 0~2 또는 3을 넣습니다.

`0x02a3` Get fan speed는 `ebx` 1st byte로 fan number를 지정하고 SMM 뒤 `eax` 1st word에 RPM을 반환합니다. `0x03a3` Get fan type은 `ebx` 1st byte로 fan을 지정하고 `eax` 1st byte에 type을 반환합니다. 5th bit는 docking fan이며 type 1은 Processor, 2 Motherboard, 3 Video, 4 Power supply, 5 Chipset, 6 other입니다.

`0x04a3` Get nominal fan speed는 `ebx` 1st byte fan number와 2nd byte state를 받아 `eax` 1st word에 해당 state의 nominal RPM을 반환합니다. `0x05a3` Get fan speed tolerance도 같은 fan·state argument를 받고 `eax` 1st byte에 tolerance를 반환합니다.

`0x10a3` Get sensor temperature는 `ebx` 1st byte로 sensor number를 지정하고 `eax` 1st byte에 measured temperature를 반환합니다. `0x11a3` Get sensor type은 같은 방식으로 type을 반환하며 1 CPU, 2 GPU, 3 SODIMM, 4 other, 5 Ambient, 6 other입니다.

`0xfea3` Get SMM signature는 지원되는 interface라면 `eax=1145651527`(`0x44494147`, `DIAG`)과 `edx=1145392204`(`0x44454c4c`, `DELL`)를 반환합니다. `0xffa3`도 같은 signature command이므로 둘 다 확인합니다.

Automatic fan speed control enable command `0x31a3` 또는 `0x35a3`, disable command `0x30a3` 또는 `0x34a3`도 있습니다. 그러나 많은 machine에서 심각한 side effect를 일으켜 기본적으로 사용하지 않습니다.

Inspiron 3505, Precision 490, Vostro 1720 등 여러 machine은 특정 fan에서 BIOS automatic control을 enable하라는 의미의 네 번째 magic state를 지원합니다. 네 번째 regular fan state를 지원하는 machine도 있으며, magic state의 nominal RPM은 placeholder이지만 항상 탐지 가능한 것은 아닙니다.

Dell SMM command code
CodeCommandArgument·result
0x0025Get Fn key statuseax bit 9=up, bit 10=down, both=mute
0xa069Get power statuseax bit 1=battery, bit 3=AC
0x00a3Get fan stateeax byte 1=state 0-2 or 3
0x01a3Set fan stateebx byte 1=fan, byte 2=state
0x02a3Get fan speedebx byte 1=fan, eax word 1=RPM
0x03a3Get fan typeebx byte 1=fan, eax byte 1=type
0x04a3Get nominal fan speedebx fan·state, eax word 1=nominal RPM
0x05a3Get fan speed toleranceebx fan·state, eax byte 1=tolerance
0x10a3Get sensor temperatureebx byte 1=sensor, eax byte 1=temperature
0x11a3Get sensor typeebx byte 1=sensor, eax byte 1=type
0xfea3Get SMM signatureeax=DIAG, edx=DELL
0xffa3Get SMM signature0xfea3과 동일, 둘 다 확인

Command와 핵심 input·result register를 보존한 표입니다.

Fan state command
Get fan type·stateNominal RPM·tolerance 조회Set fan state command 실행Get fan speed로 RPM 확인Magic state면 BIOS automatic mode 확인

Fan 식별부터 RPM feedback까지의 SMM sequence입니다.

SMM command codes
-----------------

=============== ======================= ================================================
Command Code    Command Name            Description
=============== ======================= ================================================
``0x0025``      Get Fn key status       Returns the Fn key pressed after SMM:

                                        - 9th bit in ``eax`` indicates Volume up
                                        - 10th bit in ``eax`` indicates Volume down
                                        - both bits indicate Volume mute

``0xa069``      Get power status        Returns current power status after SMM:

                                        - 1st bit in ``eax`` indicates Battery connected
                                        - 3th bit in ``eax`` indicates AC connected

``0x00a3``      Get fan state           Returns current fan state after SMM:

                                        - 1st byte in ``eax`` holds the current
                                          fan state (0 - 2 or 3)

``0x01a3``      Set fan state           Sets the fan speed:

                                        - 1st byte in ``ebx`` holds the fan number
                                        - 2nd byte in ``ebx`` holds the desired
                                          fan state (0 - 2 or 3)

``0x02a3``      Get fan speed           Returns the current fan speed in RPM:

                                        - 1st byte in ``ebx`` holds the fan number
                                        - 1st word in ``eax`` holds the current
                                          fan speed in RPM (after SMM)

``0x03a3``      Get fan type            Returns the fan type:

                                        - 1st byte in ``ebx`` holds the fan number
                                        - 1st byte in ``eax`` holds the
                                          fan type (after SMM):

                                          - 5th bit indicates docking fan
                                          - 1 indicates Processor fan
                                          - 2 indicates Motherboard fan
                                          - 3 indicates Video fan
                                          - 4 indicates Power supply fan
                                          - 5 indicates Chipset fan
                                          - 6 indicates other fan type

``0x04a3``      Get nominal fan speed   Returns the nominal RPM in each fan state:

                                        - 1st byte in ``ebx`` holds the fan number
                                        - 2nd byte in ``ebx`` holds the fan state
                                          in question (0 - 2 or 3)
                                        - 1st word in ``eax`` holds the nominal
                                          fan speed in RPM (after SMM)

``0x05a3``      Get fan speed tolerance Returns the speed tolerance for each fan state:

                                        - 1st byte in ``ebx`` holds the fan number
                                        - 2nd byte in ``ebx`` holds the fan state
                                          in question (0 - 2 or 3)
                                        - 1st byte in ``eax`` returns the speed
                                          tolerance

``0x10a3``      Get sensor temperature  Returns the measured temperature:

                                        - 1st byte in ``ebx`` holds the sensor number
                                        - 1st byte in ``eax`` holds the measured
                                          temperature (after SMM)

``0x11a3``      Get sensor type         Returns the sensor type:

                                        - 1st byte in ``ebx`` holds the sensor number
                                        - 1st byte in ``eax`` holds the
                                          temperature type (after SMM):

                                          - 1 indicates CPU sensor
                                          - 2 indicates GPU sensor
                                          - 3 indicates SODIMM sensor
                                          - 4 indicates other sensor type
                                          - 5 indicates Ambient sensor
                                          - 6 indicates other sensor type

``0xfea3``      Get SMM signature       Returns Dell signature if interface
                                        is supported (after SMM):

                                        - ``eax`` holds 1145651527
                                          (0x44494147 or "DIAG")
                                        - ``edx`` holds 1145392204
                                          (0x44454c4c or "DELL")

``0xffa3``      Get SMM signature       Same as ``0xfea3``, check both.
=============== ======================= ================================================

There are additional commands for enabling (``0x31a3`` or ``0x35a3``) and
disabling (``0x30a3`` or ``0x34a3``) automatic fan speed control.
The commands are however causing severe sideeffects on many machines, so
they are not used by default.

On several machines (Inspiron 3505, Precision 490, Vostro 1720, ...), the
fans supports a 4th "magic" state, which signals the BIOS that automatic
fan control should be enabled for a specific fan.
However there are also some machines who do support a 4th regular fan state too,
but in case of the "magic" state, the nominal RPM reported for this state is a
placeholder value, which however is not always detectable.

Firmware bug 표와 제약

367-407

일부 machine에서는 SMM call이 불규칙하게 동작합니다. Fan state 읽기가 spurious error를 반환하는 model은 Precision 490과 OptiPlex 7060입니다.

Fan type 읽기가 불규칙한 fan behavior를 일으키는 model은 Studio XPS 8000, Studio XPS 8100, Inspiron 580, Inspiron 3505입니다.

Fan 관련 SMM call이 약 500ms로 너무 오래 걸리는 model은 Inspiron 7720, Vostro 3360, XPS 13 9333, XPS 15 L502X입니다. 비슷한 문제를 겪으면 workaround를 적용할 수 있도록 bugzilla에 bug report를 제출해야 합니다.

일부 machine에서는 SMM call이 너무 오래 걸려 짧은 hang이나 audio glitch가 생길 수 있습니다. Suspend 뒤에는 fan state와 automatic mode setting을 복원해야 합니다. Temperature sensor를 읽을 때 127 degree를 넘는 값은 BIOS read error 또는 deactivated sensor를 뜻합니다.

알려진 firmware bug
증상Affected machines
Fan state read의 spurious errorPrecision 490, OptiPlex 7060
Fan type read가 erratic behavior 유발Studio XPS 8000/8100, Inspiron 580/3505
Fan SMM call 약 500msInspiron 7720, Vostro 3360, XPS 13 9333, XPS 15 L502X
Temperature >127 degreesBIOS read error 또는 deactivated sensor

증상별 영향 model과 운영상 의미입니다.

오류·복귀 처리
SMM call latency 감시Spurious error와 model workaround 적용127 초과 temperature를 invalid 처리Suspend 전 fan·automatic mode 저장Resume 뒤 상태 복원

느린 firmware와 suspend 이후 상태를 보수적으로 다룹니다.

Firmware Bugs
-------------

The SMM calls can behave erratic on some machines:

======================================================= =================
Firmware Bug                                            Affected Machines
======================================================= =================
Reading of fan states return spurious errors.           Precision 490

                                                        OptiPlex 7060

Reading of fan types causes erratic fan behaviour.      Studio XPS 8000

                                                        Studio XPS 8100

                                                        Inspiron 580

                                                        Inspiron 3505

Fan-related SMM calls take too long (about 500ms).      Inspiron 7720

                                                        Vostro 3360

                                                        XPS 13 9333

                                                        XPS 15 L502X
======================================================= =================

In case you experience similar issues on your Dell machine, please
submit a bugreport on bugzilla to we can apply workarounds.

Limitations
-----------

The SMM calls can take too long to execute on some machines, causing
short hangs and/or audio glitches.
Also the fan state needs to be restored after suspend, as well as
the automatic mode settings.
When reading a temperature sensor, values above 127 degrees indicate
a BIOS read error or a deactivated sensor.