hwmon: (i5k_amb) Convert to use devm_ functions

Convert to use devm_ functions to reduce code size and simplify the code.

Cc: Darrick J. Wong <djwong@us.ibm.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (ibmaem) Convert to use devm_ functions

Convert to use devm_ functions to reduce code size and simplify the code.

Cc: Darrick J. Wong <djwong@us.ibm.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (w83627hf) Add support for suspend

On suspend some register values are lost, most notably the Value RAM
areas but also other limits. Restore them on resume. On top of that,
some fixups are needed to work around BIOS bugs, in particular when
the BIOS omits running the same initialization sequence on resume
that it does after boot. In that case we have to carry initialization
over suspend.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (w83627ehf) Add support for suspend

On suspend some register values are lost, most notably the Value RAM
areas but also other limits and settings. Restore them on resume.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: Driver for Nuvoton NCT6775F, NCT6776F, and NCT6779D

This driver will replace the w83627ehf driver for NCT6775F and NCT6776F,
and provides support for NCT6779D.

This patch provides support for voltage monitor attributes.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add case open detection

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for temperature sensors

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for fan speed attributes

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for fanX_pulses sysfs attribute

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for fan debounce module parameter

If set, fan debounce is enabled when loading the driver.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add power management support

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for pwm, pwm_mode, and pwm_enable

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (nct6775) Add support for automatic fan control

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (pmbus) Add support for word status register

Not all PMBus devices support the byte status register at 0x78.
Try to use the word status register at 0x79 instead if that is the case.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (max34440) Add support for MAX34460 and MAX34461

MAX34460 is a PMBus 12-Channel Voltage Monitor & Sequencer.
MAX34461 is a PMBus 16-Channel Voltage Monitor & Sequencer.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (zl6100) Add support for VMON/VDRV

Some of the ZL6100 compatible chips support monitoring a separate voltage pin,
VMON (ZL2004) or VDRV (ZL91xx). Report it as in3 / vout2.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (w83627ehf) Use fixed attributes for SYSTIN, CPUTIN, and AUXTIN on NCT6775/NCT6776

So far the code used dynamic temperature attributes for SYSTIN, CPUTIN, and
AUXTIN on NCT6775/NCT6776. That has the disadvantage that the mapping of
tempX_type and tempX_offset does not necessarily match reality, and code
complexity is increased.

To avoid mapping problems and simplify the code, use fixed mapping instead, and
use temp[4-9] for additional temperature sources.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (w83627ehf) Detect current and voltage mode for thermal diodes

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: (w83627ehf) Add support for SmartFanIV mode on W83667HG-B

SmartFan IV mode is supported on W83667HG-B, but configured differently than
on other chips and not detected. As a result, changing the fan control mode
was impossible if SmartFan IV mode is selected.

Detect SmartFan IV mode and make it configurable if was configured at system
startup.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>
hwmon: Driver for Texas Instruments INA209

Add support for the TI / Burr-Brown INA209 voltage / current / power
monitor.

Cc: Paul Hays <haysp@magma.net>
Cc: Ira W. Snyder <iws@ovro.caltech.edu>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>