inv_icm42600_temp.h (693B)
1/* SPDX-License-Identifier: GPL-2.0-or-later */ 2/* 3 * Copyright (C) 2020 Invensense, Inc. 4 */ 5 6#ifndef INV_ICM42600_TEMP_H_ 7#define INV_ICM42600_TEMP_H_ 8 9#include <linux/iio/iio.h> 10 11#define INV_ICM42600_TEMP_CHAN(_index) \ 12 { \ 13 .type = IIO_TEMP, \ 14 .info_mask_separate = \ 15 BIT(IIO_CHAN_INFO_RAW) | \ 16 BIT(IIO_CHAN_INFO_OFFSET) | \ 17 BIT(IIO_CHAN_INFO_SCALE), \ 18 .scan_index = _index, \ 19 .scan_type = { \ 20 .sign = 's', \ 21 .realbits = 16, \ 22 .storagebits = 16, \ 23 }, \ 24 } 25 26int inv_icm42600_temp_read_raw(struct iio_dev *indio_dev, 27 struct iio_chan_spec const *chan, 28 int *val, int *val2, long mask); 29 30#endif