Skip to content

Commit 4173cf6

Browse files
committed
Merge tag 'hwmon-for-v6.4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging
Pull hwmon updates from Guenter Roeck: "New drivers - Driver for Acbel FSB032 power supply - Driver for StarFive JH71x0 temperature sensor Added support to existing drivers: - aquacomputer_d5next: Support for Aquacomputer Aquastream XT - nct6775: Added various ASUS boards to list of boards supporting WMI - asus-ec-sensors: ROG STRIX Z390-F GAMING, ProArt B550-Creator, Notable improvements: - Regulator event and sysfs notification support for PMBus drivers Notable cleanup: - Constified pointers to hwmon_channel_info .. and various other minor bug fixes and improvements" * tag 'hwmon-for-v6.4' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: (131 commits) hwmon: lochnagar: Remove the unneeded include <linux/i2c.h> hwmon: (pmbus/fsp-3y) Fix functionality bitmask in FSP-3Y YM-2151E hwmon: (adt7475) Use device_property APIs when configuring polarity hwmon: (aquacomputer_d5next) Add support for Aquacomputer Aquastream XT hwmon: (it87) Disable/enable SMBus access for IT8622E chipset hwmon: (it87) Add calls to smbus_enable/smbus_disable as required hwmon: (it87) Test for error in it87_update_device hwmon: (it87) Disable SMBus access for environmental controller registers. docs: hwmon: Add documentaion for acbel-fsg032 PSU hwmon: (pmbus/acbel-fsg032) Add Acbel power supply dt-bindings: trivial-devices: Add acbel,fsg032 dt-bindings: vendor-prefixes: Add prefix for acbel hwmon: (sfctemp) Simplify error message hwmon: (pmbus/ibm-cffps) Use default debugfs attributes and lock function hwmon: (pmbus/core) Add lock and unlock functions hwmon: (pmbus/core) Request threaded interrupt with IRQF_ONESHOT hwmon: (nct6775) update ASUS WMI monitoring list A620/B760/W790 hwmon: ina2xx: add optional regulator support dt-bindings: hwmon: ina2xx: add supply property dt-bindings: hwmon: pwm-fan: Convert to DT schema ...
2 parents 3361e9a + 1c19ac7 commit 4173cf6

110 files changed

Lines changed: 2126 additions & 572 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 1 addition & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1 @@
1-
Bindings for a fan connected to the PWM lines
2-
3-
Required properties:
4-
- compatible : "pwm-fan"
5-
- pwms : the PWM that is used to control the PWM fan
6-
- cooling-levels : PWM duty cycle values in a range from 0 to 255
7-
which correspond to thermal cooling states
8-
9-
Optional properties:
10-
- fan-supply : phandle to the regulator that provides power to the fan
11-
- interrupts : This contains an interrupt specifier for each fan
12-
tachometer output connected to an interrupt source.
13-
The output signal must generate a defined number of
14-
interrupts per fan revolution, which require that
15-
it must be self resetting edge interrupts. See
16-
interrupt-controller/interrupts.txt for the format.
17-
- pulses-per-revolution : define the number of pulses per fan revolution for
18-
each tachometer input as an integer (default is 2
19-
interrupts per revolution). The value must be
20-
greater than zero.
21-
22-
Example:
23-
fan0: pwm-fan {
24-
compatible = "pwm-fan";
25-
#cooling-cells = <2>;
26-
pwms = <&pwm 0 10000 0>;
27-
cooling-levels = <0 102 170 230>;
28-
};
29-
30-
thermal-zones {
31-
cpu_thermal: cpu-thermal {
32-
thermal-sensors = <&tmu 0>;
33-
polling-delay-passive = <0>;
34-
polling-delay = <0>;
35-
trips {
36-
cpu_alert1: cpu-alert1 {
37-
temperature = <100000>; /* millicelsius */
38-
hysteresis = <2000>; /* millicelsius */
39-
type = "passive";
40-
};
41-
};
42-
cooling-maps {
43-
map0 {
44-
trip = <&cpu_alert1>;
45-
cooling-device = <&fan0 0 1>;
46-
};
47-
};
48-
};
49-
50-
Example 2:
51-
fan0: pwm-fan {
52-
compatible = "pwm-fan";
53-
pwms = <&pwm 0 40000 0>;
54-
fan-supply = <&reg_fan>;
55-
interrupt-parent = <&gpio5>;
56-
interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
57-
pulses-per-revolution = <2>;
58-
};
59-
60-
Example 3:
61-
fan0: pwm-fan {
62-
compatible = "pwm-fan";
63-
pwms = <&pwm1 0 25000 0>;
64-
interrupts-extended = <&gpio1 1 IRQ_TYPE_EDGE_FALLING>,
65-
<&gpio2 5 IRQ_TYPE_EDGE_FALLING>;
66-
pulses-per-revolution = <2>, <1>;
67-
};
1+
This file has moved to pwm-fan.yaml.
Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/hwmon/pwm-fan.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Fan connected to PWM lines
8+
9+
maintainers:
10+
- Jean Delvare <jdelvare@suse.com>
11+
- Guenter Roeck <linux@roeck-us.net>
12+
13+
properties:
14+
compatible:
15+
const: pwm-fan
16+
17+
cooling-levels:
18+
description: PWM duty cycle values corresponding to thermal cooling states.
19+
$ref: /schemas/types.yaml#/definitions/uint32-array
20+
items:
21+
maximum: 255
22+
23+
fan-supply:
24+
description: Phandle to the regulator that provides power to the fan.
25+
26+
interrupts:
27+
description:
28+
This contains an interrupt specifier for each fan tachometer output
29+
connected to an interrupt source. The output signal must generate a
30+
defined number of interrupts per fan revolution, which require that
31+
it must be self resetting edge interrupts.
32+
maxItems: 1
33+
34+
pulses-per-revolution:
35+
description:
36+
Define the number of pulses per fan revolution for each tachometer
37+
input as an integer.
38+
$ref: /schemas/types.yaml#/definitions/uint32
39+
minimum: 1
40+
maximum: 4
41+
default: 2
42+
43+
pwms:
44+
description: The PWM that is used to control the fan.
45+
maxItems: 1
46+
47+
"#cooling-cells": true
48+
49+
required:
50+
- compatible
51+
- pwms
52+
53+
additionalProperties: false
54+
55+
examples:
56+
- |
57+
pwm-fan {
58+
compatible = "pwm-fan";
59+
cooling-levels = <0 102 170 230>;
60+
pwms = <&pwm 0 10000 0>;
61+
#cooling-cells = <2>;
62+
};
63+
64+
thermal-zones {
65+
cpu_thermal: cpu-thermal {
66+
thermal-sensors = <&tmu 0>;
67+
polling-delay-passive = <0>;
68+
polling-delay = <0>;
69+
70+
trips {
71+
cpu_alert1: cpu-alert1 {
72+
temperature = <100000>; /* millicelsius */
73+
hysteresis = <2000>; /* millicelsius */
74+
type = "passive";
75+
};
76+
};
77+
78+
cooling-maps {
79+
map0 {
80+
trip = <&cpu_alert1>;
81+
cooling-device = <&fan0 0 1>;
82+
};
83+
};
84+
};
85+
};
86+
87+
- |
88+
#include <dt-bindings/interrupt-controller/irq.h>
89+
90+
pwm-fan {
91+
compatible = "pwm-fan";
92+
pwms = <&pwm 0 40000 0>;
93+
fan-supply = <&reg_fan>;
94+
interrupt-parent = <&gpio5>;
95+
interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
96+
pulses-per-revolution = <2>;
97+
};
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/hwmon/starfive,jh71x0-temp.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: StarFive JH71x0 Temperature Sensor
8+
9+
maintainers:
10+
- Emil Renner Berthing <kernel@esmil.dk>
11+
12+
description: |
13+
StarFive Technology Co. JH71x0 embedded temperature sensor
14+
15+
properties:
16+
compatible:
17+
enum:
18+
- starfive,jh7100-temp
19+
- starfive,jh7110-temp
20+
21+
reg:
22+
maxItems: 1
23+
24+
clocks:
25+
minItems: 2
26+
maxItems: 2
27+
28+
clock-names:
29+
items:
30+
- const: "sense"
31+
- const: "bus"
32+
33+
'#thermal-sensor-cells':
34+
const: 0
35+
36+
resets:
37+
minItems: 2
38+
maxItems: 2
39+
40+
reset-names:
41+
items:
42+
- const: "sense"
43+
- const: "bus"
44+
45+
required:
46+
- compatible
47+
- reg
48+
- clocks
49+
- clock-names
50+
- resets
51+
- reset-names
52+
53+
additionalProperties: false
54+
55+
examples:
56+
- |
57+
#include <dt-bindings/clock/starfive-jh7100.h>
58+
#include <dt-bindings/reset/starfive-jh7100.h>
59+
60+
temperature-sensor@124a0000 {
61+
compatible = "starfive,jh7100-temp";
62+
reg = <0x124a0000 0x10000>;
63+
clocks = <&clkgen JH7100_CLK_TEMP_SENSE>,
64+
<&clkgen JH7100_CLK_TEMP_APB>;
65+
clock-names = "sense", "bus";
66+
#thermal-sensor-cells = <0>;
67+
resets = <&rstgen JH7100_RSTN_TEMP_SENSE>,
68+
<&rstgen JH7100_RSTN_TEMP_APB>;
69+
reset-names = "sense", "bus";
70+
};

Documentation/devicetree/bindings/hwmon/ti,ina2xx.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,10 @@ properties:
5757
$ref: /schemas/types.yaml#/definitions/uint32
5858
enum: [1, 2, 4, 8]
5959

60+
vs-supply:
61+
description: phandle to the regulator that provides the VS supply typically
62+
in range from 2.7 V to 5.5 V.
63+
6064
required:
6165
- compatible
6266
- reg
@@ -73,5 +77,6 @@ examples:
7377
compatible = "ti,ina220";
7478
reg = <0x44>;
7579
shunt-resistor = <1000>;
80+
vs-supply = <&vdd_3v0>;
7681
};
7782
};

Documentation/devicetree/bindings/hwmon/ti,tmp464.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ $schema: http://devicetree.org/meta-schemas/core.yaml#
77
title: TMP464 and TMP468 temperature sensors
88

99
maintainers:
10-
- Agathe Porte <agathe.porte@nokia.com>
10+
- Guenter Roeck <linux@roeck-us.net>
1111

1212
description: |
1313
±0.0625°C Remote and Local temperature sensor

Documentation/devicetree/bindings/trivial-devices.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ properties:
2929
compatible:
3030
items:
3131
- enum:
32+
# Acbel fsg032 power supply
33+
- acbel,fsg032
3234
# SMBus/I2C Digital Temperature Sensor in 6-Pin SOT with SMBus Alert and Over Temperature Pin
3335
- ad,ad7414
3436
# ADM9240: Complete System Hardware Monitor for uProcessor-Based Systems

Documentation/devicetree/bindings/vendor-prefixes.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ patternProperties:
3737
description: Abracon Corporation
3838
"^abt,.*":
3939
description: ShenZhen Asia Better Technology Ltd.
40+
"^acbel,.*":
41+
description: Acbel Polytech Inc.
4042
"^acer,.*":
4143
description: Acer Inc.
4244
"^acme,.*":
Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
Kernel driver acbel-fsg032
2+
==========================
3+
4+
Supported chips:
5+
6+
* ACBEL FSG032-00xG power supply.
7+
8+
Author: Lakshmi Yadlapati <lakshmiy@us.ibm.com>
9+
10+
Description
11+
-----------
12+
13+
This driver supports ACBEL FSG032-00xG Power Supply. This driver
14+
is a client to the core PMBus driver.
15+
16+
Usage Notes
17+
-----------
18+
19+
This driver does not auto-detect devices. You will have to instantiate the
20+
devices explicitly. Please see Documentation/i2c/instantiating-devices.rst for
21+
details.
22+
23+
Sysfs entries
24+
-------------
25+
26+
The following attributes are supported:
27+
28+
======================= ======================================================
29+
curr1_crit Critical maximum current.
30+
curr1_crit_alarm Input current critical alarm.
31+
curr1_input Measured output current.
32+
curr1_label "iin"
33+
curr1_max Maximum input current.
34+
curr1_max_alarm Maximum input current high alarm.
35+
curr1_rated_max Maximum rated input current.
36+
curr2_crit Critical maximum current.
37+
curr2_crit_alarm Output current critical alarm.
38+
curr2_input Measured output current.
39+
curr2_label "iout1"
40+
curr2_max Maximum output current.
41+
curr2_max_alarm Output current high alarm.
42+
curr2_rated_max Maximum rated output current.
43+
44+
45+
fan1_alarm Fan 1 warning.
46+
fan1_fault Fan 1 fault.
47+
fan1_input Fan 1 speed in RPM.
48+
fan1_target Set fan speed reference.
49+
50+
in1_alarm Input voltage under-voltage alarm.
51+
in1_input Measured input voltage.
52+
in1_label "vin"
53+
in1_rated_max Maximum rated input voltage.
54+
in1_rated_min Minimum rated input voltage.
55+
in2_crit Critical maximum output voltage.
56+
in2_crit_alarm Output voltage critical high alarm.
57+
in2_input Measured output voltage.
58+
in2_label "vout1"
59+
in2_lcrit Critical minimum output voltage.
60+
in2_lcrit_alarm Output voltage critical low alarm.
61+
in2_rated_max Maximum rated output voltage.
62+
in2_rated_min Minimum rated output voltage.
63+
64+
power1_alarm Input fault or alarm.
65+
power1_input Measured input power.
66+
power1_label "pin"
67+
power1_max Input power limit.
68+
power1_rated_max Maximum rated input power.
69+
power2_crit Critical output power limit.
70+
power2_crit_alarm Output power crit alarm limit exceeded.
71+
power2_input Measured output power.
72+
power2_label "pout"
73+
power2_max Output power limit.
74+
power2_max_alarm Output power high alarm.
75+
power2_rated_max Maximum rated output power.
76+
77+
temp[1-3]_input Measured temperature.
78+
temp[1-2]_max Maximum temperature.
79+
temp[1-3]_rated_max Temperature high alarm.
80+
======================= ======================================================

0 commit comments

Comments
 (0)