Skip to content

Commit

Permalink
Merge tag 'hwmon-for-v6.1' of git://git.kernel.org/pub/scm/linux/kern…
Browse files Browse the repository at this point in the history
…el/git/groeck/linux-staging

Pull hwmon updates from Guenter Roeck:
 "New drivers:

   - Driver for MAX31760 fan speed controller

   - Driver for TEXAS TPS546D24 Buck Converter

   - Driver for EMC2301/2/3/5 RPM-based PWM Fan Speed Controller

  Removed drivers:

   - Drop obsolete asus_wmi_ec_sensors driver

  Cleanups, affecting various drivers:

   - Use DEFINE_SIMPLE_DEV_PM_OPS where appropriate

   - Remove forward declarations

   - Move from strlcpy with unused retval to strscpy

   - Make use of devm_clk_get_enabled()

   - Drop devm_of_pwm_get()

  Other notable cleanup and improvements:

   - Support for additional USB devide ID and support for reporting of
     rail mode via debugfs added to corsair-psu driver

   - Support for aditional USB ID in nzxt-smart2 driver

   - Support for Aquacomputer High Flow Next in aquacomputer_d5next
     driver

   - Major cleanup of pwm-fan driver

   - Major cleanup of mr75203 driver, and added support for new device
     revision

  And various other minor fixes and cleanups"

* tag 'hwmon-for-v6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: (86 commits)
  hwmon: (corsair-psu) add USB id of new revision of the HX1000i psu
  hwmon: (pmbus/mp2888) Fix sensors readouts for MPS Multi-phase mp2888 controller
  dt-bindings: hwmon: sensirion,shtc1: Clean up spelling mistakes and grammar
  hwmon: (nct6683) remove unused variable in nct6683_create_attr_group
  hwmon: w83627hf: Reorder symbols to get rid of a few forward declarations
  hwmon: (ina3221) Use DEFINE_RUNTIME_DEV_PM_OPS() and pm_ptr()
  hwmon: (w83627ehf) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (tmp108) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (tmp103) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (tmp102) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (pwm-fan) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (nct6775) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (max6639) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (max31730) witch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (max31722) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (ltc2947) Switch to EXPORT_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (lm90) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (it87) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (gpio-fan) Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  hwmon: (adt7x10) Switch to EXPORT_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr()
  ...
  • Loading branch information
torvalds committed Oct 5, 2022
2 parents b86406d + 0cf46a6 commit 0baf6dc
Show file tree
Hide file tree
Showing 125 changed files with 6,122 additions and 4,759 deletions.
42 changes: 42 additions & 0 deletions Documentation/devicetree/bindings/hwmon/adi,max31760.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/hwmon/adi,max31760.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Analog Devices MAX31760 Fan-Speed Controller

maintainers:
- Ibrahim Tilki <Ibrahim.Tilki@analog.com>

description: |
Analog Devices MAX31760 Fan-Speed Controller
https://datasheets.maximintegrated.com/en/ds/MAX31760.pdf
properties:
compatible:
enum:
- adi,max31760

reg:
description: I2C address of slave device.
minimum: 0x50
maximum: 0x57

required:
- compatible
- reg

additionalProperties: false

examples:
- |
i2c {
#address-cells = <1>;
#size-cells = <0>;
fan-controller@50 {
reg = <0x50>;
compatible = "adi,max31760";
};
};
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ properties:

clocks:
items:
- description: AHB reference clock
- description: System reference clock

'#thermal-sensor-cells':
const: 0
Expand All @@ -40,5 +40,5 @@ examples:
compatible = "microchip,sparx5-temp";
reg = <0x10508110 0xc>;
#thermal-sensor-cells = <0>;
clocks = <&ahb_clk>;
clocks = <&sys_clk>;
};
96 changes: 95 additions & 1 deletion Documentation/devicetree/bindings/hwmon/moortec,mr75203.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,32 @@ title: Moortec Semiconductor MR75203 PVT Controller bindings
maintainers:
- Rahul Tanwar <rtanwar@maxlinear.com>

description: |
A Moortec PVT (Process, Voltage, Temperature) monitoring logic design can
include many different units.
Such a design will usually consists of several Moortec's embedded analog IPs,
and a single Moortec controller (mr75203) to configure and control the IPs.
Some of the Moortec's analog hard IPs that can be used in a design:
*) Temperature Sensor (TS) - used to monitor core temperature (e.g. mr74137).
*) Voltage Monitor (VM) - used to monitor voltage levels (e.g. mr74138).
*) Process Detector (PD) - used to assess silicon speed (e.g. mr74139).
*) Delay Chain - ring oscillator connected to the PD, used to measure IO
based transistors (e.g. mr76008 ring oscillator at 1.1V, mr76007 ring
oscillator at 1.8V).
*) Pre Scaler - provides divide-by-X scaling of input voltage, which can then
be presented for VM for measurement within its range (e.g. mr76006 -
divide by 2 pre-scaler).
TS, VM & PD also include a digital interface, which consists of configuration
inputs and measurement outputs.
Some of the units have number of series, each series can have slightly
different characteristics.
The mr75203 binding describes configuration for the controller unit, but also
for some of the analog IPs.
properties:
compatible:
const: moortec,mr75203
Expand Down Expand Up @@ -44,12 +70,76 @@ properties:
"#thermal-sensor-cells":
const: 1

moortec,vm-active-channels:
description:
Defines the number of channels per VM that are actually used and are
connected to some input source.
Maximum number of items - number of VMs.
Maximum value of each item - number of channels.
Minimum value of each item - 0 (which means entire VM sensor is not used).
$ref: /schemas/types.yaml#/definitions/uint8-array

moortec,vm-pre-scaler-x2:
description:
Defines the channels that use a mr76006 pre-scaler to divide the input
source by 2.
The pre-scaler is used for input sources that exceed the VM input range.
The driver uses this information to present to the user with the actual
value of the voltage source.
For channels that are not listed, no pre-scaler is assumed.
Maximum number of items - total number of channels in all VMs.
Each channel should not appear more than once.
$ref: /schemas/types.yaml#/definitions/uint8-array

moortec,ts-series:
description:
Definition of the temperature equation and coefficients that shall be
used to convert the digital output to value in milli-Celsius.
minimum: 5
maximum: 6
default: 5
$ref: /schemas/types.yaml#/definitions/uint32

moortec,ts-coeff-g:
description:
G coefficient for temperature equation.
Default for series 5 = 60000
Default for series 6 = 57400
multipleOf: 1000
minimum: 1000
$ref: /schemas/types.yaml#/definitions/uint32

moortec,ts-coeff-h:
description:
H coefficient for temperature equation.
Default for series 5 = 200000
Default for series 6 = 249400
multipleOf: 1000
minimum: 1000
$ref: /schemas/types.yaml#/definitions/uint32

moortec,ts-coeff-cal5:
description:
cal5 coefficient for temperature equation.
Default for series 5 = 4094
Default for series 6 = 4096
minimum: 1
$ref: /schemas/types.yaml#/definitions/uint32

moortec,ts-coeff-j:
description:
J coefficient for temperature equation.
Default for series 5 = -100
Default for series 6 = 0
multipleOf: 1000
maximum: 0
$ref: /schemas/types.yaml#/definitions/int32

required:
- compatible
- reg
- reg-names
- clocks
- resets
- "#thermal-sensor-cells"

additionalProperties: false
Expand All @@ -66,5 +156,9 @@ examples:
intel,vm-map = [03 01 04 ff ff];
clocks = <&osc0>;
resets = <&rcu0 0x40 7>;
moortec,vm-active-channels = /bits/ 8 <0x10 0x05>;
moortec,vm-pre-scaler-x2 = /bits/ 8 <5 6 20>;
moortec,ts-coeff-g = <61400>;
moortec,ts-coeff-h = <253700>;
#thermal-sensor-cells = <1>;
};
8 changes: 4 additions & 4 deletions Documentation/devicetree/bindings/hwmon/sensirion,shtc1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ maintainers:
- Christopher Ruehl chris.ruehl@gtsys.com.hk

description: |
The SHTC1, SHTW1 and SHTC3 are digital humidity and temperature sensor
The SHTC1, SHTW1 and SHTC3 are digital humidity and temperature sensors
designed especially for battery-driven high-volume consumer electronics
applications.
For further information refere to Documentation/hwmon/shtc1.rst
Expand All @@ -31,13 +31,13 @@ properties:
sensirion,blocking-io:
$ref: /schemas/types.yaml#/definitions/flag
description:
If set, the driver hold the i2c bus until measurement is finished.
If set, the driver holds the i2c bus until the measurement is finished.

sensirion,low-precision:
$ref: /schemas/types.yaml#/definitions/flag
description:
If set, the sensor aquire data with low precision (not recommended).
The driver aquire data with high precision by default.
If set, the sensor acquires data with low precision (not recommended).
The driver acquires data with high precision by default.

required:
- compatible
Expand Down
2 changes: 2 additions & 0 deletions Documentation/devicetree/bindings/vendor-prefixes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -819,6 +819,8 @@ patternProperties:
description: MNT Research GmbH
"^modtronix,.*":
description: Modtronix Engineering
"^moortec,.*":
description: Moortec Semiconductor Ltd.
"^mosaixtech,.*":
description: Mosaix Technologies, Inc.
"^motorola,.*":
Expand Down
1 change: 0 additions & 1 deletion Documentation/driver-api/driver-model/devres.rst
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,6 @@ POWER

PWM
devm_pwm_get()
devm_of_pwm_get()
devm_fwnode_pwm_get()

REGULATOR
Expand Down
3 changes: 1 addition & 2 deletions Documentation/driver-api/pwm.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ after usage with pwm_free().

New users should use the pwm_get() function and pass to it the consumer
device or a consumer name. pwm_put() is used to free the PWM device. Managed
variants of the getter, devm_pwm_get(), devm_of_pwm_get(),
devm_fwnode_pwm_get(), also exist.
variants of the getter, devm_pwm_get() and devm_fwnode_pwm_get(), also exist.

After being requested, a PWM has to be configured using::

Expand Down
37 changes: 24 additions & 13 deletions Documentation/hwmon/aquacomputer_d5next.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Supported devices:
* Aquacomputer Farbwerk 360 RGB controller
* Aquacomputer Octo fan controller
* Aquacomputer Quadro fan controller
* Aquacomputer High Flow Next sensor

Author: Aleksa Savic

Expand All @@ -20,25 +21,35 @@ This driver exposes hardware sensors of listed Aquacomputer devices, which
communicate through proprietary USB HID protocols.

For the D5 Next pump, available sensors are pump and fan speed, power, voltage
and current, as well as coolant temperature. Also available through debugfs are
the serial number, firmware version and power-on count. Attaching a fan to it is
optional and allows it to be controlled using temperature curves directly from the
pump. If it's not connected, the fan-related sensors will report zeroes.
and current, as well as coolant temperature and eight virtual temp sensors. Also
available through debugfs are the serial number, firmware version and power-on
count. Attaching a fan to it is optional and allows it to be controlled using
temperature curves directly from the pump. If it's not connected, the fan-related
sensors will report zeroes.

The pump can be configured either through software or via its physical
interface. Configuring the pump through this driver is not implemented, as it
seems to require sending it a complete configuration. That includes addressable
RGB LEDs, for which there is no standard sysfs interface. Thus, that task is
better suited for userspace tools.

The Octo exposes four temperature sensors and eight PWM controllable fans, along
with their speed (in RPM), power, voltage and current.
The Octo exposes four physical and sixteen virtual temperature sensors, as well as
eight PWM controllable fans, along with their speed (in RPM), power, voltage and
current.

The Quadro exposes four temperature sensors, a flow sensor and four PWM controllable
fans, along with their speed (in RPM), power, voltage and current.
The Quadro exposes four physical and sixteen virtual temperature sensors, a flow
sensor and four PWM controllable fans, along with their speed (in RPM), power,
voltage and current.

The Farbwerk and Farbwerk 360 expose four temperature sensors. Depending on the device,
not all sysfs and debugfs entries will be available.
The Farbwerk and Farbwerk 360 expose four temperature sensors. Additionally,
sixteen virtual temperature sensors of the Farbwerk 360 are exposed.

The High Flow Next exposes +5V voltages, water quality, conductivity and flow readings.
A temperature sensor can be connected to it, in which case it provides its reading
and an estimation of the dissipated/absorbed power in the liquid cooling loop.

Depending on the device, not all sysfs and debugfs entries will be available.
Writing to virtual temperature sensors is not currently supported.

Usage notes
-----------
Expand All @@ -49,14 +60,14 @@ the kernel and supports hotswapping.
Sysfs entries
-------------

================ ==============================================
temp[1-4]_input Temperature sensors (in millidegrees Celsius)
================ ==============================================================
temp[1-20]_input Physical/virtual temperature sensors (in millidegrees Celsius)
fan[1-8]_input Pump/fan speed (in RPM) / Flow speed (in dL/h)
power[1-8]_input Pump/fan power (in micro Watts)
in[0-7]_input Pump/fan voltage (in milli Volts)
curr[1-8]_input Pump/fan current (in milli Amperes)
pwm[1-8] Fan PWM (0 - 255)
================ ==============================================
================ ==============================================================

Debugfs entries
---------------
Expand Down
38 changes: 0 additions & 38 deletions Documentation/hwmon/asus_wmi_ec_sensors.rst

This file was deleted.

7 changes: 4 additions & 3 deletions Documentation/hwmon/corsair-psu.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Supported devices:

Corsair HX850i

Corsair HX1000i
Corsair HX1000i (revision 1 and 2)

Corsair HX1200i

Expand Down Expand Up @@ -86,8 +86,9 @@ Debugfs entries
---------------

======================= ========================================================
uptime Current uptime of the psu
ocpmode Single or multi rail mode of the PCIe power connectors
product Product name of the psu
uptime Session uptime of the psu
uptime_total Total uptime of the psu
vendor Vendor name of the psu
product Product name of the psu
======================= ========================================================
Loading

0 comments on commit 0baf6dc

Please sign in to comment.