hwmon: (mlxreg-fan) Add support for fan drawers capability and present registers
authorVadim Pasternak <vadimp@nvidia.com>
Mon, 22 Mar 2021 17:22:37 +0000 (19:22 +0200)
committerGuenter Roeck <linux@roeck-us.net>
Tue, 20 Apr 2021 13:50:14 +0000 (06:50 -0700)
commitf7bf7eb2d734d25a5883a6832eeebc40d7816b3f
treee5b31dd15b2c133b581080dadae5cb10e62868cf
parentcb3d37b59012d8ed20864799ea8d0a2373967e69
hwmon: (mlxreg-fan) Add support for fan drawers capability and present registers

Add support for fan drawer's capability and present registers in order
to set mapping between the fan drawers and tachometers. Some systems
are equipped with fan drawers with one tachometer inside. Others with
fan drawers with several tachometers inside. Using present register
along with tachometer-to-drawer mapping allows to skip reading missed
tachometers and expose input for them as zero, instead of exposing
fault code returned by hardware.

Signed-off-by: Vadim Pasternak <vadimp@nvidia.com>
Link: https://lore.kernel.org/r/20210322172237.2213584-1-vadimp@nvidia.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/mlxreg-fan.c