linux/drivers/iio/dac/lpc18xx_dac.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 * IIO DAC driver for NXP LPC18xx DAC
 *
 * Copyright (C) 2016 Joachim Eastwood <[email protected]>
 *
 * UNSUPPORTED hardware features:
 *  - Interrupts
 *  - DMA
 */

#include <linux/clk.h>
#include <linux/err.h>
#include <linux/iio/iio.h>
#include <linux/iio/driver.h>
#include <linux/io.h>
#include <linux/iopoll.h>
#include <linux/module.h>
#include <linux/mod_devicetable.h>
#include <linux/mutex.h>
#include <linux/platform_device.h>
#include <linux/regulator/consumer.h>

/* LPC18XX DAC registers and bits */
#define LPC18XX_DAC_CR
#define LPC18XX_DAC_CR_VALUE_SHIFT
#define LPC18XX_DAC_CR_VALUE_MASK
#define LPC18XX_DAC_CR_BIAS
#define LPC18XX_DAC_CTRL
#define LPC18XX_DAC_CTRL_DMA_ENA

struct lpc18xx_dac {};

static const struct iio_chan_spec lpc18xx_dac_iio_channels[] =;

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

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

static const struct iio_info lpc18xx_dac_info =;

static int lpc18xx_dac_probe(struct platform_device *pdev)
{}

static void lpc18xx_dac_remove(struct platform_device *pdev)
{}

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

static struct platform_driver lpc18xx_dac_driver =;
module_platform_driver();

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