linux/drivers/iio/pressure/dlhl60d.c

// SPDX-License-Identifier: GPL-2.0
/*
 * All Sensors DLH series low voltage digital pressure sensors
 *
 * Copyright (c) 2019 AVL DiTEST GmbH
 *   Tomislav Denis <[email protected]>
 *
 * Datasheet: https://www.allsensors.com/cad/DS-0355_Rev_B.PDF
 */

#include <linux/module.h>
#include <linux/delay.h>
#include <linux/i2c.h>
#include <linux/iio/iio.h>
#include <linux/iio/buffer.h>
#include <linux/iio/trigger_consumer.h>
#include <linux/iio/triggered_buffer.h>
#include <asm/unaligned.h>

/* Commands */
#define DLH_START_SINGLE

/* Status bits */
#define DLH_STATUS_OK

/* DLH  data format */
#define DLH_NUM_READ_BYTES
#define DLH_NUM_DATA_BYTES
#define DLH_NUM_PR_BITS
#define DLH_NUM_TEMP_BITS

/* DLH  timings */
#define DLH_SINGLE_DUT_MS

enum dhl_ids {};

struct dlh_info {};

struct dlh_state {};

static struct dlh_info dlh_info_tbl[] =;


static int dlh_cmd_start_single(struct dlh_state *st)
{}

static int dlh_cmd_read_data(struct dlh_state *st)
{}

static int dlh_start_capture_and_read(struct dlh_state *st)
{}

static int dlh_read_direct(struct dlh_state *st,
	unsigned int *pressure, unsigned int *temperature)
{}

static int dlh_read_raw(struct iio_dev *indio_dev,
	struct iio_chan_spec const *channel, int *value,
	int *value2, long mask)
{}

static const struct iio_info dlh_info =;

static const struct iio_chan_spec dlh_channels[] =;

static irqreturn_t dlh_trigger_handler(int irq, void *private)
{}

static irqreturn_t dlh_interrupt(int irq, void *private)
{
	struct iio_dev *indio_dev = private;
	struct dlh_state *st = iio_priv(indio_dev);

	complete(&st->completion);

	return IRQ_HANDLED;
};

static int dlh_probe(struct i2c_client *client)
{}

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

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

static struct i2c_driver dlh_driver =;
module_i2c_driver();

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