linux/drivers/staging/iio
Lars-Peter Clausen cae329e04a staging:iio:dac:ad5446: Consolidate store_sample and store_pwr_down functions
The devices supported by this drivers only have a single shift register, which
contains both the power down mode and the output sample. So writing the power
down mode and the output sample can be done by the same function. Call this
function prepare_write as it will prepare the spi message for a write. Also
introduce a small helper function which performs the whole write by calling the
chip the specific prepare function followed by a spi_sync.

The two power down bits are always placed ontop of the msb of the output sample,
so we can easily calculate their position by adding the channels shift to the
channels realbits.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-04-25 10:57:20 -07:00
..
accel staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
adc staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
addac staging:iio: Use dev_pm_ops 2012-02-24 12:11:13 -08:00
cdc staging:iio: drop procesed_val element of chan_spec. 2012-04-18 16:38:21 -07:00
dac staging:iio:dac:ad5446: Consolidate store_sample and store_pwr_down functions 2012-04-25 10:57:20 -07:00
dds staging:iio:dds:ad9834 unwind use of is_visible for attrs. 2012-02-09 10:06:05 -08:00
Documentation staging: iio: add TAOS tsl2x7x driver 2012-04-24 11:47:09 -07:00
gyro staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
impedance-analyzer staging:iio:impedance-analyser make use of iio_sw_buffer_preenable 2012-04-24 11:23:38 -07:00
imu staging:iio: add caching of the number of bytes in a scan. 2012-04-24 11:23:37 -07:00
light staging: iio: tsl2x7x: bugfixes 2012-04-24 16:13:10 -07:00
magnetometer staging:iio:magnetometer Add IIO_CHAN_INFO_RAW entries to all drivers. 2012-04-18 16:38:20 -07:00
meter staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
resolver staging:iio:resolver Add IIO_CHAN_INFO_RAW entries to all drivers. 2012-04-18 16:38:20 -07:00
trigger staging: iio: Convert platform_drivers to use module_platform_driver 2012-03-02 16:35:39 -08:00
buffer.h staging:iio: scan_index_timestamp move to iio_dev from buffer 2012-04-24 11:23:37 -07:00
consumer.h staging:iio:core add in kernel interface mapping and getting IIO channels. 2012-02-24 12:10:02 -08:00
driver.h staging:iio:core add in kernel interface mapping and getting IIO channels. 2012-02-24 12:10:02 -08:00
events.h staging:iio: Add missing event code extract macros 2012-02-13 20:10:32 -08:00
iio_core_trigger.h staging:iio:triggers Remove unecessary existence checks and return val 2011-11-26 16:30:30 -08:00
iio_core.h staging:iio:iio_core.h make less dependent on other included headers 2012-04-13 10:59:38 -07:00
iio_dummy_evgen.c drivers:staging:iio Fix typos and comments in staging iio. 2012-03-02 16:33:52 -08:00
iio_dummy_evgen.h staging:iio:dummy Add event support + fake event generator 2011-10-17 15:36:30 -07:00
iio_hwmon.c staging:iio::hwmon interface client driver. 2012-02-24 12:10:03 -08:00
iio_simple_dummy_buffer.c staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
iio_simple_dummy_events.c staging:iio: header reorganization 2011-11-26 16:35:04 -08:00
iio_simple_dummy.c staging:iio: Add IIO_CHAN_INFO_RAW entries to the dummy driver 2012-04-18 16:38:21 -07:00
iio_simple_dummy.h staging:iio:dummy Add buffered reading support 2011-10-17 15:36:30 -07:00
iio.h staging:iio: Add caching of scan_timestamp to the core as well as buffers. 2012-04-24 11:23:38 -07:00
industrialio-buffer.c staging:iio: pull out demux cleanup for a particular buffer. 2012-04-24 11:23:38 -07:00
industrialio-core.c staging:iio: drop procesed_val element of chan_spec. 2012-04-18 16:38:21 -07:00
industrialio-event.c staging:iio:events: Remove obsolete documentation 2012-02-13 20:10:32 -08:00
industrialio-trigger.c Merge branch 'staging-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging 2012-01-09 12:18:17 -08:00
inkern.c staging:iio:core add in kernel interface mapping and getting IIO channels. 2012-02-24 12:10:02 -08:00
Kconfig drivers:staging:iio Fix typos and comments in staging iio. 2012-03-02 16:33:52 -08:00
kfifo_buf.c staging:iio: Setup buffer access functions when allocating the buffer 2012-02-09 10:03:51 -08:00
kfifo_buf.h staging:iio: Setup buffer access functions when allocating the buffer 2012-02-09 10:03:51 -08:00
machine.h staging:iio:core add in kernel interface mapping and getting IIO channels. 2012-02-24 12:10:02 -08:00
Makefile staging:iio::hwmon interface client driver. 2012-02-24 12:10:03 -08:00
ring_hw.h staging:iio: replacing term ring with buffer in the IIO core. 2011-09-26 17:31:53 -07:00
ring_sw.c drivers:staging:iio Fix typos and comments in staging iio. 2012-03-02 16:33:52 -08:00
ring_sw.h staging:iio: Setup buffer access functions when allocating the buffer 2012-02-09 10:03:51 -08:00
sysfs.h staging:iio: header reorganization 2011-11-26 16:35:04 -08:00
TODO staging: iio: add ADI info to TODO 2010-11-09 15:46:32 -08:00
trigger_consumer.h staging:iio: treewide rename iio_triggered_ring_* to iio_triggered_buffer_* 2011-09-26 17:31:52 -07:00
trigger.h staging:iio: iio_trigger contains defunct owner field. Remove it. 2011-12-16 10:56:26 -08:00
types.h staging:iio: move iio data return types into types.h for use by inkern 2012-02-24 12:10:03 -08:00