Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Documentation/hwmon/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ Hardware Monitoring Kernel Drivers
tps53679
tps546d24
tsc1641
tvs-mpfs
twl4030-madc-hwmon
ucd9000
ucd9200
Expand Down
53 changes: 53 additions & 0 deletions Documentation/hwmon/tvs-mpfs.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
.. SPDX-License-Identifier: GPL-2.0

Kernel driver tvs-mpfs
======================

Supported chips:

* PolarFire SoC

Authors:

- Conor Dooley <conor.dooley@microchip.com>
- Lars Randers <lranders@mail.dk>

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

This driver implements support for the temperature and voltage sensors on
PolarFire SoC. The temperature reports how hot the die is, and the voltages are
the SoC's 1.05, 1.8 and 2.5 volt rails respectively.


Usage Notes
-----------

update_interval is in microseconds, with a permitted range of 0 to 8128.

Temperatures are read in millidegrees Celsius, but the hardware measures in
degrees Kelvin, storing the result as 11.4 fixed point data, for a maximum
value of 2047.9375 degrees Kelvin.

Voltages are read in millivolts. The hardware measures in millivolts, storing
the value as 12.3 fixed point data, for a maximum of 4095.875 millivolts.
The minimum value reportable by the driver is 0 volts, although the hardware
is capable of measuring negative values.

Sysfs entries
-------------

The following attributes are supported. update_interval is read-write, as are
the enables. All other attributes are read only.

======================= ====================================================
temp1_label Fixed name for channel.
temp1_input Measured temperature for channel.
temp1_enable Enable/disable for channel.

in[0-2]_label Fixed name for channel.
in[0-2]_input Measured voltage for channel.
in[0-2]_enable Enable/disable for channel.

update_interval The interval at which the chip will update readings.
======================= ====================================================
1 change: 1 addition & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -22983,6 +22983,7 @@ F: drivers/char/hw_random/mpfs-rng.c
F: drivers/clk/microchip/clk-mpfs*.c
F: drivers/firmware/microchip/mpfs-auto-update.c
F: drivers/gpio/gpio-mpfs.c
F: drivers/hwmon/tvs-mpfs.c
F: drivers/i2c/busses/i2c-microchip-corei2c.c
F: drivers/mailbox/mailbox-mpfs.c
F: drivers/pci/controller/plda/pcie-microchip-host.c
Expand Down
12 changes: 12 additions & 0 deletions drivers/hwmon/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -930,6 +930,18 @@ config SENSORS_JC42
This driver can also be built as a module. If so, the module
will be called jc42.

config SENSORS_POLARFIRE_SOC_TVS
tristate "PolarFire SoC (MPFS) temperature and voltage sensor"
depends on POLARFIRE_SOC_MAILBOX
help
This driver adds support for the PolarFire SoC (MPFS) Temperature and
Voltage Sensor.

To compile this driver as a module, choose M here. the
module will be called tvs-mpfs.

If unsure, say N.

config SENSORS_POWERZ
tristate "ChargerLAB POWER-Z USB-C tester"
depends on USB
Expand Down
1 change: 1 addition & 0 deletions drivers/hwmon/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,7 @@ obj-$(CONFIG_SENSORS_NZXT_SMART2) += nzxt-smart2.o
obj-$(CONFIG_SENSORS_PC87360) += pc87360.o
obj-$(CONFIG_SENSORS_PC87427) += pc87427.o
obj-$(CONFIG_SENSORS_PCF8591) += pcf8591.o
obj-$(CONFIG_SENSORS_POLARFIRE_SOC_TVS) += tvs-mpfs.o
obj-$(CONFIG_SENSORS_POWERZ) += powerz.o
obj-$(CONFIG_SENSORS_POWR1220) += powr1220.o
obj-$(CONFIG_SENSORS_PT5161L) += pt5161l.o
Expand Down
Loading
Loading