diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-08-17 13:17:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-08-17 13:17:03 -0400 |
commit | 557e2e2eef90d7d3d4ee5396c1ecee873c3dd46e (patch) | |
tree | 0564981d2766e8b4f9b7bbf7eff12e4ad9b82e97 /drivers/iio/light | |
parent | c83917976fad1e66689f2e4f632841ed2b2dbe2b (diff) | |
parent | 3a491aeae86577e0f23cd094f3e16351b6061209 (diff) |
Merge tag 'staging-3.6-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging
Pull staging fixes from Greg Kroah-Hartman:
"Here are some staging driver fixes (and iio driver fixes, they get
lumped in with the staging stuff due to dependancies) for your 3.6-rc3
tree.
Nothing major, just a bunch of fixes that people have reported.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>"
* tag 'staging-3.6-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (26 commits)
iio: lm3533-als: Fix build warnings
staging:iio:ad7780: Mark channels as unsigned
staging:iio:ad7192: Report offset and scale for temperature channel
staging:iio:ad7192: Report channel offset
staging:iio:ad7192: Mark channels as unsigned
staging:iio:ad7192: Fix setting ACX
staging:iio:ad7192: Add missing break in switch statement
staging:iio:ad7793: Fix internal reference value
staging:iio:ad7793: Follow new IIO naming spec
staging:iio:ad7793: Fix temperature scale and offset
staging:iio:ad7793: Report channel offset
staging:iio:ad7793: Mark channels as unsigned
staging:iio:ad7793: Add missing break in switch statement
iio/adjd_s311: Fix potential memory leak in adjd_s311_update_scan_mode()
iio: frequency: ADF4350: Fix potential reference div factor overflow.
iio: staging: ad7298_ring: Fix maybe-uninitialized warning
staging: comedi: usbduxfast: Declare MODULE_FIRMWARE usage
staging: comedi: usbdux: Declare MODULE_FIRMWARE usage
staging: comedi: usbduxsigma: Declare MODULE_FIRMWARE usage
staging: csr: add INET dependancy
...
Diffstat (limited to 'drivers/iio/light')
-rw-r--r-- | drivers/iio/light/adjd_s311.c | 7 | ||||
-rw-r--r-- | drivers/iio/light/lm3533-als.c | 4 |
2 files changed, 6 insertions, 5 deletions
diff --git a/drivers/iio/light/adjd_s311.c b/drivers/iio/light/adjd_s311.c index 1cbb449b319a..9a99f43094f0 100644 --- a/drivers/iio/light/adjd_s311.c +++ b/drivers/iio/light/adjd_s311.c | |||
@@ -271,9 +271,10 @@ static int adjd_s311_update_scan_mode(struct iio_dev *indio_dev, | |||
271 | const unsigned long *scan_mask) | 271 | const unsigned long *scan_mask) |
272 | { | 272 | { |
273 | struct adjd_s311_data *data = iio_priv(indio_dev); | 273 | struct adjd_s311_data *data = iio_priv(indio_dev); |
274 | data->buffer = krealloc(data->buffer, indio_dev->scan_bytes, | 274 | |
275 | GFP_KERNEL); | 275 | kfree(data->buffer); |
276 | if (!data->buffer) | 276 | data->buffer = kmalloc(indio_dev->scan_bytes, GFP_KERNEL); |
277 | if (data->buffer == NULL) | ||
277 | return -ENOMEM; | 278 | return -ENOMEM; |
278 | 279 | ||
279 | return 0; | 280 | return 0; |
diff --git a/drivers/iio/light/lm3533-als.c b/drivers/iio/light/lm3533-als.c index c3e7bac13123..e45712a921ce 100644 --- a/drivers/iio/light/lm3533-als.c +++ b/drivers/iio/light/lm3533-als.c | |||
@@ -404,7 +404,7 @@ out: | |||
404 | return ret; | 404 | return ret; |
405 | } | 405 | } |
406 | 406 | ||
407 | static int show_thresh_either_en(struct device *dev, | 407 | static ssize_t show_thresh_either_en(struct device *dev, |
408 | struct device_attribute *attr, | 408 | struct device_attribute *attr, |
409 | char *buf) | 409 | char *buf) |
410 | { | 410 | { |
@@ -424,7 +424,7 @@ static int show_thresh_either_en(struct device *dev, | |||
424 | return scnprintf(buf, PAGE_SIZE, "%u\n", enable); | 424 | return scnprintf(buf, PAGE_SIZE, "%u\n", enable); |
425 | } | 425 | } |
426 | 426 | ||
427 | static int store_thresh_either_en(struct device *dev, | 427 | static ssize_t store_thresh_either_en(struct device *dev, |
428 | struct device_attribute *attr, | 428 | struct device_attribute *attr, |
429 | const char *buf, size_t len) | 429 | const char *buf, size_t len) |
430 | { | 430 | { |