#include <linux/kernel.h>
#include <linux/device.h>
#include <linux/mutex.h>
#include <linux/pm_runtime.h>
#include <linux/regmap.h>
#include <linux/delay.h>
#include <linux/math64.h>
#include <linux/iio/buffer.h>
#include <linux/iio/common/inv_sensors_timestamp.h>
#include <linux/iio/iio.h>
#include <linux/iio/kfifo_buf.h>
#include "inv_icm42600.h"
#include "inv_icm42600_temp.h"
#include "inv_icm42600_buffer.h"
#define INV_ICM42600_GYRO_CHAN(_modifier, _index, _ext_info) …
enum inv_icm42600_gyro_scan { … };
static const struct iio_chan_spec_ext_info inv_icm42600_gyro_ext_infos[] = …;
static const struct iio_chan_spec inv_icm42600_gyro_channels[] = …;
struct inv_icm42600_gyro_buffer { … };
#define INV_ICM42600_SCAN_MASK_GYRO_3AXIS …
#define INV_ICM42600_SCAN_MASK_TEMP …
static const unsigned long inv_icm42600_gyro_scan_masks[] = …;
static int inv_icm42600_gyro_update_scan_mode(struct iio_dev *indio_dev,
const unsigned long *scan_mask)
{ … }
static int inv_icm42600_gyro_read_sensor(struct inv_icm42600_state *st,
struct iio_chan_spec const *chan,
int16_t *val)
{ … }
static const int inv_icm42600_gyro_scale[] = …;
static const int inv_icm42686_gyro_scale[] = …;
static int inv_icm42600_gyro_read_scale(struct iio_dev *indio_dev,
int *val, int *val2)
{ … }
static int inv_icm42600_gyro_write_scale(struct iio_dev *indio_dev,
int val, int val2)
{ … }
static const int inv_icm42600_gyro_odr[] = …;
static const int inv_icm42600_gyro_odr_conv[] = …;
static int inv_icm42600_gyro_read_odr(struct inv_icm42600_state *st,
int *val, int *val2)
{ … }
static int inv_icm42600_gyro_write_odr(struct iio_dev *indio_dev,
int val, int val2)
{ … }
static int inv_icm42600_gyro_calibbias[] = …;
static int inv_icm42600_gyro_read_offset(struct inv_icm42600_state *st,
struct iio_chan_spec const *chan,
int *val, int *val2)
{ … }
static int inv_icm42600_gyro_write_offset(struct inv_icm42600_state *st,
struct iio_chan_spec const *chan,
int val, int val2)
{ … }
static int inv_icm42600_gyro_read_raw(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan,
int *val, int *val2, long mask)
{ … }
static int inv_icm42600_gyro_read_avail(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan,
const int **vals,
int *type, int *length, long mask)
{ … }
static int inv_icm42600_gyro_write_raw(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan,
int val, int val2, long mask)
{ … }
static int inv_icm42600_gyro_write_raw_get_fmt(struct iio_dev *indio_dev,
struct iio_chan_spec const *chan,
long mask)
{ … }
static int inv_icm42600_gyro_hwfifo_set_watermark(struct iio_dev *indio_dev,
unsigned int val)
{ … }
static int inv_icm42600_gyro_hwfifo_flush(struct iio_dev *indio_dev,
unsigned int count)
{ … }
static const struct iio_info inv_icm42600_gyro_info = …;
struct iio_dev *inv_icm42600_gyro_init(struct inv_icm42600_state *st)
{ … }
int inv_icm42600_gyro_parse_fifo(struct iio_dev *indio_dev)
{ … }