Skip to content

Commit dbcfcb2

Browse files
kuu-rtgroeck
authored andcommitted
hwmon: (dell-smm) Increment the number of fans
Some Alienware laptops that support the SMM interface, may have up to 4 fans. Tested on an Alienware x15 r1. Signed-off-by: Kurt Borja <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
1 parent 7953605 commit dbcfcb2

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

Documentation/hwmon/dell-smm-hwmon.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,12 @@ Temperature sensors and fans can be queried and set via the standard
3232
=============================== ======= =======================================
3333
Name Perm Description
3434
=============================== ======= =======================================
35-
fan[1-3]_input RO Fan speed in RPM.
36-
fan[1-3]_label RO Fan label.
37-
fan[1-3]_min RO Minimal Fan speed in RPM
38-
fan[1-3]_max RO Maximal Fan speed in RPM
39-
fan[1-3]_target RO Expected Fan speed in RPM
40-
pwm[1-3] RW Control the fan PWM duty-cycle.
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.
4141
pwm1_enable WO Enable or disable automatic BIOS fan
4242
control (not supported on all laptops,
4343
see below for details).
@@ -93,7 +93,7 @@ Again, when you find new codes, we'd be happy to have your patches!
9393
---------------------------
9494

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

9999
Module parameters

drivers/hwmon/dell-smm-hwmon.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
#define DELL_SMM_LEGACY_EXECUTE 0x1
7474

7575
#define DELL_SMM_NO_TEMP 10
76-
#define DELL_SMM_NO_FANS 3
76+
#define DELL_SMM_NO_FANS 4
7777

7878
struct smm_regs {
7979
unsigned int eax;
@@ -1074,11 +1074,14 @@ static const struct hwmon_channel_info * const dell_smm_info[] = {
10741074
HWMON_F_INPUT | HWMON_F_LABEL | HWMON_F_MIN | HWMON_F_MAX |
10751075
HWMON_F_TARGET,
10761076
HWMON_F_INPUT | HWMON_F_LABEL | HWMON_F_MIN | HWMON_F_MAX |
1077+
HWMON_F_TARGET,
1078+
HWMON_F_INPUT | HWMON_F_LABEL | HWMON_F_MIN | HWMON_F_MAX |
10771079
HWMON_F_TARGET
10781080
),
10791081
HWMON_CHANNEL_INFO(pwm,
10801082
HWMON_PWM_INPUT | HWMON_PWM_ENABLE,
10811083
HWMON_PWM_INPUT,
1084+
HWMON_PWM_INPUT,
10821085
HWMON_PWM_INPUT
10831086
),
10841087
NULL

0 commit comments

Comments
 (0)