#include <linux/init.h>
#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/mutex.h>
#include <linux/err.h>
#include <linux/spi/spi.h>
#include <linux/iio/iio.h>
#include <linux/iio/sysfs.h>
#include <linux/iio/trigger.h>
#include <linux/iio/buffer.h>
#include <linux/iio/triggered_buffer.h>
#include <linux/iio/trigger_consumer.h>
#define MAXIM_THERMOCOUPLE_DRV_NAME …
enum { … };
static const char maxim_tc_types[] = …;
static const struct iio_chan_spec max6675_channels[] = …;
static const struct iio_chan_spec max31855_channels[] = …;
static const unsigned long max31855_scan_masks[] = …;
struct maxim_thermocouple_chip { … };
static const struct maxim_thermocouple_chip maxim_thermocouple_chips[] = …;
struct maxim_thermocouple_data { … };
static int maxim_thermocouple_read(struct maxim_thermocouple_data *data,
struct iio_chan_spec const *chan, int *val)
{ … }
static irqreturn_t maxim_thermocouple_trigger_handler(int irq, void *private)
{ … }
static int maxim_thermocouple_read_raw(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan,
int *val, int *val2, long mask)
{ … }
static const struct iio_info maxim_thermocouple_info = …;
static int maxim_thermocouple_probe(struct spi_device *spi)
{ … }
static const struct spi_device_id maxim_thermocouple_id[] = …;
MODULE_DEVICE_TABLE(spi, maxim_thermocouple_id);
static const struct of_device_id maxim_thermocouple_of_match[] = …;
MODULE_DEVICE_TABLE(of, maxim_thermocouple_of_match);
static struct spi_driver maxim_thermocouple_driver = …;
module_spi_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;