linux/drivers/iio/temperature/max30208.c

// SPDX-License-Identifier: GPL-2.0-only

/*
 * Copyright (c) Rajat Khandelwal <[email protected]>
 *
 * Maxim MAX30208 digital temperature sensor with 0.1°C accuracy
 * (7-bit I2C slave address (0x50 - 0x53))
 */

#include <linux/bitops.h>
#include <linux/delay.h>
#include <linux/iio/iio.h>
#include <linux/i2c.h>
#include <linux/module.h>
#include <linux/types.h>

#define MAX30208_STATUS
#define MAX30208_STATUS_TEMP_RDY
#define MAX30208_INT_ENABLE
#define MAX30208_INT_ENABLE_TEMP_RDY

#define MAX30208_FIFO_OVF_CNTR
#define MAX30208_FIFO_DATA_CNTR
#define MAX30208_FIFO_DATA

#define MAX30208_FIFO_CONFIG
#define MAX30208_FIFO_CONFIG_RO

#define MAX30208_SYSTEM_CTRL
#define MAX30208_SYSTEM_CTRL_RESET

#define MAX30208_TEMP_SENSOR_SETUP
#define MAX30208_TEMP_SENSOR_SETUP_CONV

struct max30208_data {};

static const struct iio_chan_spec max30208_channels[] =;

/**
 * max30208_request() - Request a reading
 * @data: Struct comprising member elements of the device
 *
 * Requests a reading from the device and waits until the conversion is ready.
 */
static int max30208_request(struct max30208_data *data)
{}

static int max30208_update_temp(struct max30208_data *data)
{}

/**
 * max30208_config_setup() - Set up FIFO configuration register
 * @data: Struct comprising member elements of the device
 *
 * Sets the rollover bit to '1' to enable overwriting FIFO during overflow.
 */
static int max30208_config_setup(struct max30208_data *data)
{}

static int max30208_read(struct iio_dev *indio_dev,
			 struct iio_chan_spec const *chan,
			 int *val, int *val2, long mask)
{}

static const struct iio_info max30208_info =;

static int max30208_probe(struct i2c_client *i2c)
{}

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

static const struct acpi_device_id max30208_acpi_match[] =;
MODULE_DEVICE_TABLE(acpi, max30208_acpi_match);

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

static struct i2c_driver max30208_driver =;
module_i2c_driver();

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