summaryrefslogtreecommitdiffstats
path: root/drivers/staging/iio
Commit message (Collapse)AuthorAgeFilesLines
* staging: Use GFP_ATOMIC when a lock is heldJulia Lawall2010-06-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In each case, the containing function is only called from one place, where a spin lock is held. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @gfp exists@ identifier fn; position p; @@ fn(...) { ... when != spin_unlock when any GFP_KERNEL@p ... when any } @locked@ identifier gfp.fn; @@ spin_lock(...) ... when != spin_unlock fn(...) @depends on locked@ position gfp.p; @@ - GFP_KERNEL@p + GFP_ATOMIC // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Cc: Jonathan Cameron <jic23@cam.ac.uk> Cc: Marek Lindner <lindner_marek@yahoo.de> Cc: Martyn Welch <martyn.welch@ge.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Staging: iio-utils: fix memory overflow for dynamically allocateded memory ↵Barry Song2010-06-041-2/+1
| | | | | | | | | to hold filename Signed-off-by: Barry Song <21cnbao@gmail.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* i2c: Remove all i2c_set_clientdata(client, NULL) in driversWolfram Sang2010-06-032-4/+0
| | | | | | | | | | | | | | | | | | | | | I2C drivers can use the clientdata-pointer to point to private data. As I2C devices are not really unregistered, but merely detached from their driver, it used to be the drivers obligation to clear this pointer during remove() or a failed probe(). As a couple of drivers forgot to do this, it was agreed that it was cleaner if the i2c-core does this clearance when appropriate, as there is no guarantee for the lifetime of the clientdata-pointer after remove() anyhow. This feature was added to the core with commit e4a7b9b04de15f6b63da5ccdd373ffa3057a3681 to fix the faulty drivers. As there is no need anymore to clear the clientdata-pointer, remove all current occurrences in the drivers to simplify the code and prevent confusion. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Acked-by: Richard Purdie <rpurdie@linux.intel.com> Acked-by: Dmitry Torokhov <dtor@mail.ru> Signed-off-by: Jean Delvare <khali@linux-fr.org>
* Merge staging-next tree into Linus's latest versionGreg Kroah-Hartman2010-05-2166-1054/+10767
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: drivers/staging/arlan/arlan-main.c drivers/staging/comedi/drivers/cb_das16_cs.c drivers/staging/cx25821/cx25821-alsa.c drivers/staging/dt3155/dt3155_drv.c drivers/staging/hv/hv.c drivers/staging/netwave/netwave_cs.c drivers/staging/wavelan/wavelan.c drivers/staging/wavelan/wavelan_cs.c drivers/staging/wlags49_h2/wl_cs.c This required a bit of hand merging due to the conflicts that happened in the later .34-rc releases, as well as some staging driver changing coming in through other trees (v4l and pcmcia). Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16350 and similar IMU driverBarry Song2010-05-186-0/+1355
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This version has the right part number in the commit message. Whilst technically the part I listed last time is also supported by the driver, the commit message might have caused confusion. Another driver from Barry at Analog. Again, I've lifted if from the blackfin tree and done the usual sparse and checkpatch fixes + the abi changes. I actually have one of these, so am particularly pleased to see it supported! Signed-off-by: Barry Song <Barry.Song@analog.com> Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: max1363 Fix two bugs in single_channel_from_ringJonathan Cameron2010-05-181-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch contains fixes for the two bugs Michael pointed out last week. As the other suggestion Michael made is not a bug fix (just a much more sensible way of handling things), I'll do that as a separate patch soon. The bugs were introduced with the abi changes. Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Reported-by: Michael Hennerich <Michael.Hennerich@analog.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: adis16220 extract bin_attribute structures from stateJonathan Cameron2010-05-182-53/+56
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: adis16220 vibration sensor driverBarry Song2010-05-185-0/+830
| | | | | | | | | | | | Signed-off-by: Barry Song <Barry.Song@analog.com> Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16260 digital gyro driverBarry Song2010-05-149-0/+1240
| | | | | | | | | | | | Signed-off-by: Barry Song <Barry.Song@analog.com> Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16240 driverBarry Song2010-05-116-0/+1208
| | | | | | | | | | | | Signed-off-by: Barry Song <Barry.Song@analog.com> Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16209 driverBarry Song2010-05-116-0/+1211
| | | | | | | | | | | | Signed-off-by: Barry Song <Barry.Song@analog.com> Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16400 clean out some unused codeJonathan Cameron2010-05-112-61/+3
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: Documentation update to add incli and switch to magnJonathan Cameron2010-05-111-1/+10
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: adis16300 clean out some unused codeJonathan Cameron2010-05-112-77/+2
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: Break up gyro.h and move to new abiJonathan Cameron2010-05-115-58/+47
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: Documentation fixesJonathan Cameron2010-05-111-3/+3
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: industrialio-trigger.c: minor fixupsGreg Kroah-Hartman2010-05-111-6/+7
| | | | | | | | | | | | | | | | | | | | We needed to include a header file that declared the functions that are being exported in this file. Also fix up an indentation problem, and some sparse warnings. Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: ring_sw.c: fix up sparse warningsGreg Kroah-Hartman2010-05-111-14/+13
| | | | | | | | | | | | | | NULL usage, static stuff, etc. Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: industrialio-ring.c: fix up sparse warningsGreg Kroah-Hartman2010-05-111-7/+5
| | | | | | | | | | Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: accel: fix up some sparse warnings.Greg Kroah-Hartman2010-05-112-6/+5
| | | | | | | | | | | | | | Minor stuff (static, NULL, etc.) Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: trigger: fix up some global variablesGreg Kroah-Hartman2010-05-112-4/+4
| | | | | | | | | | | | | | These should be static. Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: light: tsl2563: fix static sparse warningGreg Kroah-Hartman2010-05-111-1/+1
| | | | | | | | | | Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: adc: max1363_ring.c: fix up sparse warningsGreg Kroah-Hartman2010-05-111-1/+1
| | | | | | | | | | Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: max1363_core: fix bug in kzalloc callGreg Kroah-Hartman2010-05-111-3/+2
| | | | | | | | | | | | | | The operands were switched around :( Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: adc: max1363_core: fix up some sparse warningsGreg Kroah-Hartman2010-05-111-8/+7
| | | | | | | | | | | | | | Also fix a minor coding style issue. Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: light trivial whitespace fixJonathan Cameron2010-05-111-1/+1
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: accelerometers trivial checkpatch related fixesJonathan Cameron2010-05-112-8/+7
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: Trivial - remove pointless semi colon (checkpatch found)Jonathan Cameron2010-05-111-1/+1
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:imu ADIS16400 and ADIS16405 driverBarry Song2010-05-117-0/+1504
| | | | | | | | | | | | | | Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de> Signed-off-by: Barry Song <Barry.Song@analog.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:imu ADIS16300 driverBarry Song2010-05-1110-0/+1497
| | | | | | | | | | | | Signed-off-by: Barry Song <Barry.Song@analog.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:Documentation: Rewrite example for new abi.Jonathan Cameron2010-05-112-198/+313
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:tsl2563 add a name attribute under the iioJonathan Cameron2010-05-111-0/+12
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:ring_sw: Fix incorrect test on successful read of last value, ↵Jonathan Cameron2010-05-111-1/+1
| | | | | | | | | | | | | | causes infinite loop Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:max1363 add support for 8 bit equivalent devices, max1036-9, ↵Jonathan Cameron2010-05-113-17/+161
| | | | | | | | | | | | | | max11600-5 Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:max1363 add support for max11606-max11617Jonathan Cameron2010-05-112-2/+218
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Remove naming via IDR's where no longer necessary under new abi.Jonathan Cameron2010-05-115-40/+16
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:tsl2563: change lux to illuminance0_input to match new abiJonathan Cameron2010-05-111-2/+2
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Directory name changes to match new ABI.Jonathan Cameron2010-05-113-7/+13
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: ABI documentation (partial)Jonathan Cameron2010-05-111-0/+285
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Documentation, update iio_utils.h for the move to a busJonathan Cameron2010-05-111-1/+30
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio:max1363 move to new abi.Jonathan Cameron2010-05-115-404/+548
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Clean out unused IIO_SCAN_EL and add IIO_SCAN_NAMED_EL_CJonathan Cameron2010-05-111-21/+15
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Move event attributes into the event[n] device in sysfsJonathan Cameron2010-05-111-13/+12
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging: iio: Move from class to busJonathan Cameron2010-05-115-21/+15
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Support functions for scan mask matchingJonathan Cameron2010-05-111-4/+41
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * iio:staging:accelerometers move towards the new abiJonathan Cameron2010-05-119-232/+262
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Add new attrs for sampling frequency available and temp_rawJonathan Cameron2010-05-111-1/+11
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * staging:iio: Add new in_raw definitions for adc channels.Jonathan Cameron2010-05-112-0/+15
| | | | | | | | | | Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: Fix remaining code style issuesRoel Van Nyen2010-05-112-3/+2
| | | | | | | | | | | | | | | | fix code style issues Signed-of-by: Roel Van Nyen <roel.vannyen@gmail.com> Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * Staging: iio: iio_trigger_find_by_name: Skip trailing newline if availableMichael Hennerich2010-05-111-0/+3
| | | | | | | | | | | | | | | | Skip trailing newline if available. Signed-off-by: Michael Hennerich <Michael.Hennerich@analog.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>