]> Git Repo - linux.git/blob - include/linux/platform_data/gsc_hwmon.h
enetc: Migrate to PHYLINK and PCS_LYNX
[linux.git] / include / linux / platform_data / gsc_hwmon.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _GSC_HWMON_H
3 #define _GSC_HWMON_H
4
5 enum gsc_hwmon_mode {
6         mode_temperature,
7         mode_voltage_24bit,
8         mode_voltage_raw,
9         mode_voltage_16bit,
10         mode_max,
11 };
12
13 /**
14  * struct gsc_hwmon_channel - configuration parameters
15  * @reg:  I2C register offset
16  * @mode: channel mode
17  * @name: channel name
18  * @mvoffset: voltage offset
19  * @vdiv: voltage divider array (2 resistor values in milli-ohms)
20  */
21 struct gsc_hwmon_channel {
22         unsigned int reg;
23         unsigned int mode;
24         const char *name;
25         unsigned int mvoffset;
26         unsigned int vdiv[2];
27 };
28
29 /**
30  * struct gsc_hwmon_platform_data - platform data for gsc_hwmon driver
31  * @channels:   pointer to array of gsc_hwmon_channel structures
32  *              describing channels
33  * @nchannels:  number of elements in @channels array
34  * @vreference: voltage reference (mV)
35  * @resolution: ADC bit resolution
36  * @fan_base: register base for FAN controller
37  */
38 struct gsc_hwmon_platform_data {
39         const struct gsc_hwmon_channel *channels;
40         int nchannels;
41         unsigned int resolution;
42         unsigned int vreference;
43         unsigned int fan_base;
44 };
45 #endif
This page took 0.035045 seconds and 4 git commands to generate.