#include <linux/hwmon.h>
#include "snet_vdpa.h"
#define SNET_MON_TMP0_IN_OFF …
#define SNET_MON_TMP0_MAX_OFF …
#define SNET_MON_TMP0_CRIT_OFF …
#define SNET_MON_TMP1_IN_OFF …
#define SNET_MON_TMP1_CRIT_OFF …
#define SNET_MON_CURR_IN_OFF …
#define SNET_MON_CURR_MAX_OFF …
#define SNET_MON_CURR_CRIT_OFF …
#define SNET_MON_PWR_IN_OFF …
#define SNET_MON_VOLT_IN_OFF …
#define SNET_MON_VOLT_CRIT_OFF …
#define SNET_MON_VOLT_LCRIT_OFF …
static void snet_hwmon_read_reg(struct psnet *psnet, u32 reg, long *out)
{ … }
static umode_t snet_howmon_is_visible(const void *data,
enum hwmon_sensor_types type,
u32 attr, int channel)
{ … }
static int snet_howmon_read(struct device *dev, enum hwmon_sensor_types type,
u32 attr, int channel, long *val)
{ … }
static int snet_hwmon_read_string(struct device *dev,
enum hwmon_sensor_types type, u32 attr,
int channel, const char **str)
{ … }
static const struct hwmon_ops snet_hwmon_ops = …;
static const struct hwmon_channel_info * const snet_hwmon_info[] = …;
static const struct hwmon_chip_info snet_hwmono_info = …;
void psnet_create_hwmon(struct pci_dev *pdev)
{ … }