hwmon: (mr75203) add VM active channel support
authorEliav Farber <farbere@amazon.com>
Thu, 8 Sep 2022 15:24:40 +0000 (15:24 +0000)
committerGuenter Roeck <linux@roeck-us.net>
Mon, 19 Sep 2022 13:17:06 +0000 (06:17 -0700)
commitb7f5ac92fe18cd920b8d3f7e56a83ae16f7ecfbc
tree42d6a38873b2d971742c664e41b110af4bc9d6be
parent09288b8fe1bd0d5336be4aa5d2eb3ba9ec76cca7
hwmon: (mr75203) add VM active channel support

Add active channel support per voltage monitor.
The number of active channels is read from the device-tree.
When absent in device-tree, all channels are assumed to be used.

This shall be useful to expose sysfs only for inputs that are connected
to a voltage source.

Setting number of active channels to 0, means that entire VM sensor is
not used.

Signed-off-by: Eliav Farber <farbere@amazon.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20220908152449.35457-13-farbere@amazon.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/mr75203.c