Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
ad5624r_spi.c File Reference
#include <linux/interrupt.h>
#include <linux/fs.h>
#include <linux/device.h>
#include <linux/kernel.h>
#include <linux/spi/spi.h>
#include <linux/slab.h>
#include <linux/sysfs.h>
#include <linux/regulator/consumer.h>
#include <linux/module.h>
#include <linux/iio/iio.h>
#include <linux/iio/sysfs.h>
#include "ad5624r.h"

Go to the source code of this file.

Macros

#define AD5624R_CHANNEL(_chan, _bits)
 
#define DECLARE_AD5624R_CHANNELS(_name, _bits)
 

Functions

 MODULE_DEVICE_TABLE (spi, ad5624r_id)
 
 module_spi_driver (ad5624r_driver)
 
 MODULE_AUTHOR ("Barry Song <[email protected]>")
 
 MODULE_DESCRIPTION ("Analog Devices AD5624/44/64R DAC spi driver")
 
 MODULE_LICENSE ("GPL v2")
 

Macro Definition Documentation

#define AD5624R_CHANNEL (   _chan,
  _bits 
)
Value:
{ \
.type = IIO_VOLTAGE, \
.indexed = 1, \
.output = 1, \
.channel = (_chan), \
.address = (_chan), \
.scan_type = IIO_ST('u', (_bits), 16, 16 - (_bits)), \
.ext_info = ad5624r_ext_info, \
}

Definition at line 172 of file ad5624r_spi.c.

#define DECLARE_AD5624R_CHANNELS (   _name,
  _bits 
)
Value:
const struct iio_chan_spec _name##_channels[] = { \
AD5624R_CHANNEL(0, _bits), \
AD5624R_CHANNEL(1, _bits), \
AD5624R_CHANNEL(2, _bits), \
AD5624R_CHANNEL(3, _bits), \
}

Definition at line 184 of file ad5624r_spi.c.

Function Documentation

MODULE_AUTHOR ( "Barry Song <[email protected]>"  )
MODULE_DESCRIPTION ( "Analog Devices AD5624/44/64R DAC spi driver"  )
MODULE_DEVICE_TABLE ( spi  ,
ad5624r_id   
)
MODULE_LICENSE ( "GPL v2 )
module_spi_driver ( ad5624r_driver  )