Commit graph

4 commits

Author SHA1 Message Date
Christophe JAILLET
59882c7f67 hwmon: (gsc-hwmon) Switch to flexible array to simplify code
Using flexible array is more straight forward. It
  - saves 1 pointer in the 'gsc_hwmon_platform_data' structure
  - saves an indirection when using this array
  - saves some LoC and avoids some always spurious pointer arithmetic

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/61a23e1d642397cfcecc4ac3bb0ab485d257987d.1668936855.git.christophe.jaillet@wanadoo.fr
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2022-12-04 16:45:03 -08:00
Tim Harvey
7497d4a66c hwmon: (gsc-hwmon) add fan sensor
Add a fan sensor to report RPM's from a fan tach input.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2020-09-23 09:42:41 -07:00
Tim Harvey
a4872f7a4b hwmon: (gsc) add 16bit pre-scaled voltage mode
add a 16-bit pre-scaled voltage mode to adc and clarify that existing
pre-scaled mode is 24bit.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/1591714640-10332-3-git-send-email-tharvey@gateworks.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
2020-07-19 16:25:21 -07:00
Tim Harvey
3bce5377ef hwmon: Add Gateworks System Controller support
The Gateworks System Controller has a hwmon sub-component that exposes
up to 16 ADC's, some of which are temperature sensors, others which are
voltage inputs. The ADC configuration (register mapping and name) is
configured via device-tree and varies board to board.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2020-05-20 10:29:17 +01:00