#include <linux/module.h>
#include <linux/init.h>
#include <linux/regmap.h>
#include <linux/spi/spi.h>
#include <asm/unaligned.h>
#include "adt7x10.h"
#define ADT7310_STATUS …
#define ADT7310_CONFIG …
#define ADT7310_TEMPERATURE …
#define ADT7310_ID …
#define ADT7310_T_CRIT …
#define ADT7310_T_HYST …
#define ADT7310_T_ALARM_HIGH …
#define ADT7310_T_ALARM_LOW …
static const u8 adt7310_reg_table[] = …;
#define ADT7310_CMD_REG_OFFSET …
#define ADT7310_CMD_READ …
#define AD7310_COMMAND(reg) …
static int adt7310_spi_read_word(struct spi_device *spi, u8 reg)
{ … }
static int adt7310_spi_write_word(struct spi_device *spi, u8 reg, u16 data)
{ … }
static int adt7310_spi_read_byte(struct spi_device *spi, u8 reg)
{ … }
static int adt7310_spi_write_byte(struct spi_device *spi, u8 reg, u8 data)
{ … }
static bool adt7310_regmap_is_volatile(struct device *dev, unsigned int reg)
{ … }
static int adt7310_reg_read(void *context, unsigned int reg, unsigned int *val)
{ … }
static int adt7310_reg_write(void *context, unsigned int reg, unsigned int val)
{ … }
static const struct regmap_config adt7310_regmap_config = …;
static int adt7310_spi_probe(struct spi_device *spi)
{ … }
static const struct spi_device_id adt7310_id[] = …;
MODULE_DEVICE_TABLE(spi, adt7310_id);
static struct spi_driver adt7310_driver = …;
module_spi_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;