Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * AD5415, AD5426, AD5429, AD5432, AD5439, AD5443, AD5449 Digital to Analog
0004  * Converter driver.
0005  *
0006  * Copyright 2012 Analog Devices Inc.
0007  *  Author: Lars-Peter Clausen <lars@metafoo.de>
0008  */
0009 
0010 #ifndef __LINUX_PLATFORM_DATA_AD5449_H__
0011 #define __LINUX_PLATFORM_DATA_AD5449_H__
0012 
0013 /**
0014  * enum ad5449_sdo_mode - AD5449 SDO pin configuration
0015  * @AD5449_SDO_DRIVE_FULL: Drive the SDO pin with full strength.
0016  * @AD5449_SDO_DRIVE_WEAK: Drive the SDO pin with not full strength.
0017  * @AD5449_SDO_OPEN_DRAIN: Operate the SDO pin in open-drain mode.
0018  * @AD5449_SDO_DISABLED: Disable the SDO pin, in this mode it is not possible to
0019  *          read back from the device.
0020  */
0021 enum ad5449_sdo_mode {
0022     AD5449_SDO_DRIVE_FULL = 0x0,
0023     AD5449_SDO_DRIVE_WEAK = 0x1,
0024     AD5449_SDO_OPEN_DRAIN = 0x2,
0025     AD5449_SDO_DISABLED = 0x3,
0026 };
0027 
0028 /**
0029  * struct ad5449_platform_data - Platform data for the ad5449 DAC driver
0030  * @sdo_mode: SDO pin mode
0031  * @hardware_clear_to_midscale: Whether asserting the hardware CLR pin sets the
0032  *          outputs to midscale (true) or to zero scale(false).
0033  */
0034 struct ad5449_platform_data {
0035     enum ad5449_sdo_mode sdo_mode;
0036     bool hardware_clear_to_midscale;
0037 };
0038 
0039 #endif