forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag 'hwmon-for-v5.15' of git://git.kernel.org/pub/scm/linux/ker…
…nel/git/groeck/linux-staging Pull hwmon updates from Guenter Roeck: "New drivers for: - Aquacomputer D5 Next - SB-RMI power module Added chip support to existing drivers: - Support for various Zen2 and Zen3 APUs and for Yellow Carp (SMU v13) added to k10temp driver - Support for Silicom n5010 PAC added to intel-m10-bmc driver - Support for BPD-RS600 added to pmbus/bpa-rs600 driver Other notable changes: - In k10temp, do not display Tdie on Zen CPUs if there is no difference between Tdie and Tctl - Converted adt7470 and dell-smm drivers to use devm_hwmon_device_register_with_info API - Support for temperature/pwm tables added to axi-fan-control driver - Enabled fan control for Dell Precision 7510 in dell-smm driver Various other minor improvements and fixes in several drivers" * tag 'hwmon-for-v5.15' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: (41 commits) hwmon: add driver for Aquacomputer D5 Next hwmon: (adt7470) Convert to devm_hwmon_device_register_with_info API hwmon: (adt7470) Convert to use regmap hwmon: (adt7470) Fix some style issues hwmon: (k10temp) Add support for yellow carp hwmon: (k10temp) Rework the temperature offset calculation hwmon: (k10temp) Don't show Tdie for all Zen/Zen2/Zen3 CPU/APU hwmon: (k10temp) Add additional missing Zen2 and Zen3 APUs hwmon: remove amd_energy driver in Makefile hwmon: (dell-smm) Rework SMM function debugging hwmon: (dell-smm) Mark i8k_get_fan_nominal_speed as __init hwmon: (dell-smm) Mark tables as __initconst hwmon: (pmbus/bpa-rs600) Add workaround for incorrect Pin max hwmon: (pmbus/bpa-rs600) Don't use rated limits as warn limits hwmon: (axi-fan-control) Support temperature vs pwm points hwmon: (axi-fan-control) Handle irqs in natural order hwmon: (axi-fan-control) Make sure the clock is enabled hwmon: (pmbus/ibm-cffps) Fix write bits for LED control hwmon: (w83781d) Match on device tree compatibles dt-bindings: hwmon: Add bindings for Winbond W83781D ...
- Loading branch information
Showing
25 changed files
with
2,276 additions
and
1,177 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) | ||
%YAML 1.2 | ||
--- | ||
$id: http://devicetree.org/schemas/hwmon/amd,sbrmi.yaml# | ||
$schema: http://devicetree.org/meta-schemas/core.yaml# | ||
|
||
title: > | ||
Sideband Remote Management Interface (SB-RMI) compliant | ||
AMD SoC power device. | ||
maintainers: | ||
- Akshay Gupta <[email protected]> | ||
|
||
description: | | ||
SB Remote Management Interface (SB-RMI) is an SMBus compatible | ||
interface that reports AMD SoC's Power (normalized Power) using, | ||
Mailbox Service Request and resembles a typical 8-pin remote power | ||
sensor's I2C interface to BMC. The power attributes in hwmon | ||
reports power in microwatts. | ||
properties: | ||
compatible: | ||
enum: | ||
- amd,sbrmi | ||
|
||
reg: | ||
maxItems: 1 | ||
description: | | ||
I2C bus address of the device as specified in Section SBI SMBus Address | ||
of the SoC register reference. The SB-RMI address is normally 78h for | ||
socket 0 and 70h for socket 1, but it could vary based on hardware | ||
address select pins. | ||
\[open source SoC register reference\] | ||
https://www.amd.com/en/support/tech-docs?keyword=55898 | ||
required: | ||
- compatible | ||
- reg | ||
|
||
additionalProperties: false | ||
|
||
examples: | ||
- | | ||
i2c0 { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
sbrmi@3c { | ||
compatible = "amd,sbrmi"; | ||
reg = <0x3c>; | ||
}; | ||
}; | ||
... |
41 changes: 41 additions & 0 deletions
41
Documentation/devicetree/bindings/hwmon/winbond,w83781d.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) | ||
%YAML 1.2 | ||
--- | ||
|
||
$id: http://devicetree.org/schemas/hwmon/winbond,w83781d.yaml# | ||
$schema: http://devicetree.org/meta-schemas/core.yaml# | ||
|
||
title: Winbond W83781 and compatible hardware monitor IC | ||
|
||
maintainers: | ||
- Linus Walleij <[email protected]> | ||
|
||
properties: | ||
compatible: | ||
enum: | ||
- winbond,w83781d | ||
- winbond,w83781g | ||
- winbond,w83782d | ||
- winbond,w83783s | ||
- asus,as99127f | ||
|
||
reg: | ||
maxItems: 1 | ||
|
||
required: | ||
- compatible | ||
- reg | ||
|
||
additionalProperties: false | ||
|
||
examples: | ||
- | | ||
i2c { | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
temperature-sensor@28 { | ||
compatible = "winbond,w83781d"; | ||
reg = <0x28>; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
.. SPDX-License-Identifier: GPL-2.0-or-later | ||
Kernel driver aquacomputer-d5next | ||
================================= | ||
|
||
Supported devices: | ||
|
||
* Aquacomputer D5 Next watercooling pump | ||
|
||
Author: Aleksa Savic | ||
|
||
Description | ||
----------- | ||
|
||
This driver exposes hardware sensors of the Aquacomputer D5 Next watercooling | ||
pump, which communicates through a proprietary USB HID protocol. | ||
|
||
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 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. | ||
|
||
Usage notes | ||
----------- | ||
|
||
The pump communicates via HID reports. The driver is loaded automatically by | ||
the kernel and supports hotswapping. | ||
|
||
Sysfs entries | ||
------------- | ||
|
||
============ ============================================= | ||
temp1_input Coolant temperature (in millidegrees Celsius) | ||
fan1_input Pump speed (in RPM) | ||
fan2_input Fan speed (in RPM) | ||
power1_input Pump power (in micro Watts) | ||
power2_input Fan power (in micro Watts) | ||
in0_input Pump voltage (in milli Volts) | ||
in1_input Fan voltage (in milli Volts) | ||
in2_input +5V rail voltage (in milli Volts) | ||
curr1_input Pump current (in milli Amperes) | ||
curr2_input Fan current (in milli Amperes) | ||
============ ============================================= | ||
|
||
Debugfs entries | ||
--------------- | ||
|
||
================ =============================================== | ||
serial_number Serial number of the pump | ||
firmware_version Version of installed firmware | ||
power_cycles Count of how many times the pump was powered on | ||
================ =============================================== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
.. SPDX-License-Identifier: GPL-2.0-or-later | ||
Kernel driver sbrmi | ||
=================== | ||
|
||
Supported hardware: | ||
|
||
* Sideband Remote Management Interface (SB-RMI) compliant AMD SoC | ||
device connected to the BMC via the APML. | ||
|
||
Prefix: 'sbrmi' | ||
|
||
Addresses scanned: This driver doesn't support address scanning. | ||
|
||
To instantiate this driver on an AMD CPU with SB-RMI | ||
support, the i2c bus number would be the bus connected from the board | ||
management controller (BMC) to the CPU. | ||
The SMBus address is really 7 bits. Some vendors and the SMBus | ||
specification show the address as 8 bits, left justified with the R/W | ||
bit as a write (0) making bit 0. Some vendors use only the 7 bits | ||
to describe the address. | ||
As mentioned in AMD's APML specification, The SB-RMI address is | ||
normally 78h(0111 100W) or 3Ch(011 1100) for socket 0 and 70h(0111 000W) | ||
or 38h(011 1000) for socket 1, but it could vary based on hardware | ||
address select pins. | ||
|
||
Datasheet: The SB-RMI interface and protocol along with the Advanced | ||
Platform Management Link (APML) Specification is available | ||
as part of the open source SoC register reference at: | ||
|
||
https://www.amd.com/en/support/tech-docs?keyword=55898 | ||
|
||
Author: Akshay Gupta <[email protected]> | ||
|
||
Description | ||
----------- | ||
|
||
The APML provides a way to communicate with the SB Remote Management interface | ||
(SB-RMI) module from the external SMBus master that can be used to report socket | ||
power on AMD platforms using mailbox command and resembles a typical 8-pin remote | ||
power sensor's I2C interface to BMC. | ||
|
||
This driver implements current power with power cap and power cap max. | ||
|
||
sysfs-Interface | ||
--------------- | ||
Power sensors 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 ``sbrmi``) | ||
|
||
================ ===== ======================================================== | ||
Name Perm Description | ||
================ ===== ======================================================== | ||
power1_input RO Current Power consumed | ||
power1_cap RW Power limit can be set between 0 and power1_cap_max | ||
power1_cap_max RO Maximum powerlimit calculated and reported by the SMU FW | ||
================ ===== ======================================================== | ||
|
||
The following example show how the 'Power' attribute from the i2c-addresses | ||
can be monitored using the userspace utilities like ``sensors`` binary:: | ||
|
||
# sensors | ||
sbrmi-i2c-1-38 | ||
Adapter: bcm2835 I2C adapter | ||
power1: 61.00 W (cap = 225.00 W) | ||
|
||
sbrmi-i2c-1-3c | ||
Adapter: bcm2835 I2C adapter | ||
power1: 28.39 W (cap = 224.77 W) | ||
# | ||
|
||
Also, Below shows how get and set the values from sysfs entries individually:: | ||
# cat /sys/class/hwmon/hwmon1/power1_cap_max | ||
225000000 | ||
|
||
# echo 180000000 > /sys/class/hwmon/hwmon1/power1_cap | ||
# cat /sys/class/hwmon/hwmon1/power1_cap | ||
180000000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1316,6 +1316,13 @@ L: [email protected] | |
S: Maintained | ||
F: drivers/media/i2c/aptina-pll.* | ||
|
||
AQUACOMPUTER D5 NEXT PUMP SENSOR DRIVER | ||
M: Aleksa Savic <[email protected]> | ||
L: [email protected] | ||
S: Maintained | ||
F: Documentation/hwmon/aquacomputer_d5next.rst | ||
F: drivers/hwmon/aquacomputer_d5next.c | ||
|
||
AQUANTIA ETHERNET DRIVER (atlantic) | ||
M: Igor Russkikh <[email protected]> | ||
L: [email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.