linux/drivers/hwmon/tmp103.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * Texas Instruments TMP103 SMBus temperature sensor driver
 * Copyright (C) 2014 Heiko Schocher <[email protected]>
 *
 * Based on:
 * Texas Instruments TMP102 SMBus temperature sensor driver
 *
 * Copyright (C) 2010 Steven King <[email protected]>
 */

#include <linux/module.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/i2c.h>
#include <linux/hwmon.h>
#include <linux/hwmon-sysfs.h>
#include <linux/err.h>
#include <linux/mutex.h>
#include <linux/device.h>
#include <linux/jiffies.h>
#include <linux/regmap.h>

#define TMP103_TEMP_REG
#define TMP103_CONF_REG
#define TMP103_TLOW_REG
#define TMP103_THIGH_REG

#define TMP103_CONF_M0
#define TMP103_CONF_M1
#define TMP103_CONF_LC
#define TMP103_CONF_FL
#define TMP103_CONF_FH
#define TMP103_CONF_CR0
#define TMP103_CONF_CR1
#define TMP103_CONF_ID
#define TMP103_CONF_SD
#define TMP103_CONF_SD_MASK

#define TMP103_CONFIG
#define TMP103_CONFIG_MASK

static inline int tmp103_reg_to_mc(s8 val)
{}

static inline u8 tmp103_mc_to_reg(int val)
{}

static int tmp103_read(struct device *dev, enum hwmon_sensor_types type,
		       u32 attr, int channel, long *temp)
{}

static int tmp103_write(struct device *dev, enum hwmon_sensor_types type,
			u32 attr, int channel, long temp)
{}

static umode_t tmp103_is_visible(const void *data, enum hwmon_sensor_types type,
				 u32 attr, int channel)
{}

static const struct hwmon_channel_info * const tmp103_info[] =;

static const struct hwmon_ops tmp103_hwmon_ops =;

static const struct hwmon_chip_info tmp103_chip_info =;

static bool tmp103_regmap_is_volatile(struct device *dev, unsigned int reg)
{}

static const struct regmap_config tmp103_regmap_config =;

static int tmp103_probe(struct i2c_client *client)
{}

static int tmp103_suspend(struct device *dev)
{}

static int tmp103_resume(struct device *dev)
{}

static DEFINE_SIMPLE_DEV_PM_OPS(tmp103_dev_pm_ops, tmp103_suspend, tmp103_resume);

static const struct i2c_device_id tmp103_id[] =;
MODULE_DEVICE_TABLE(i2c, tmp103_id);

static const struct of_device_id __maybe_unused tmp103_of_match[] =;
MODULE_DEVICE_TABLE(of, tmp103_of_match);

static struct i2c_driver tmp103_driver =;

module_i2c_driver();

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();