Merge tag 'iio-for-3.11a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-next
Jonathan writes:
First round of new IIO drivers and cleanups for the 3.11 cycle.
1) New driver for MCP3204/08 12 bit ADCs
2) Move the sysfs trigger out of staging. This has been pretty clean for a
long time so lets finally move it out.
3) New functionality for the ak8975 magnetometer (DT and data ready interrupt
handling)
4) Use devm_ioremap_resource in exynos_adc. We have 3 separate versions of
this patch proposed but this one got there first.
5) A couple of other tiny fixes.
Paul Bolle [Tue, 14 May 2013 09:05:00 +0000 (10:05 +0100)]
iio: STMicroelectronics: remove three useless selects
Drivers for STMicroelectronics accelerometers, gyroscopes, and
magnetometers were added in v3.9. They all have a (similar) select
statement in their Kconfig files for a non-existant Kconfig symbol.
These select statements can safely be removed.
Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Acked-by: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
iio:ak8975 Implement data ready interrupt handling
Implement "data ready" interrupt handling in addition to the
two existing read modes - DRDY GPIO polling and ST1 register
DRDY bit polling.
Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Add support for parsing 'gpios' property when initializing
from oftree.
This patch adds also the binding documentation file.
Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Oskar Andero [Fri, 3 May 2013 09:58:00 +0000 (10:58 +0100)]
iio: adc: add driver for MCP3204/08 12-bit ADC
This adds support for Microchip's 12 bit AD converters MCP3204 and
MCP3208. These chips communicates over SPI and supports single-ended
and pseudo-differential configurations.
Signed-off-by: Oskar Andero <oskar.andero@gmail.com> Reviewed-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
staging: comedi: usbduxsigma: use comedi_load_firmware()
Use comedi_load_firmware() instead of duplicating the code in a
private function.
Also, rename firmwareUpload() to have namespace associated with
the driver.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbduxsigma: move firmware request/upload into (*auto_attach)
The last step the usb_driver (*probe) does before handing off to the
comedi_driver (*auto_attach) is requesting and uploading the firmware.
Move the request/upload into the (*auto_attach) so we can use the
comedi_load_firmware() helper.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbduxsigma: consolidate the firmware upload
Absorb the usbduxsub_stop(), usbduxsub_upload(), and usbduxsub_start()
functions into firmwareUpload().
Each of them just do a usb_control_msg() to the device and output
an error message if it fails. A similar message is also output by
firmware_upload() so the extra messages are redundant.
We can also share the malloc'ed local buffer needed for the
usb_control_msg().
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Change the request_firmware_nowait() to a request_firmware() so
that the usb_driver (*probe) can continue with the comedi_driver
(*auto_attach).
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbdux: use comedi_load_firmware()
Use comedi_load_firmware() instead of duplicating the code in a
private function.
Also, rename firmware_upload() to have namespace associated with
the driver.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbdux: move firmware request/upload into (*auto_attach)
The last step the usb_driver (*probe) does before handing off to the
comedi_driver (*auto_attach) is requesting and uploading the firmware.
Move the request/upload into the (*auto_attach) so we can use the
comedi_load_firmware() helper.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbdux: consolidate the firmware upload
Absorb the usbdux_stop(), usbdux_upload(), and usbdux_start()
functions into firmware_upload().
Each of them just do a usb_control_msg() to the device and output
an error message if it fails. A similar message is also output by
firmware_upload() so the extra messages are redundant.
We can also share the malloc'ed local buffer needed for the
usb_control_msg().
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Change the request_firmware_nowait() to a request_firmware() so
that the usb_driver (*probe) can continue with the comedi_driver
(*auto_attach).
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbduxfast: use comedi_load_firmware()
Use comedi_load_firmware() instead of duplicating the code in a
private function.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Use the helper function to get a usb_device pointer from a
comedi_device pointer. This removes the need for also getting
the usb_interface pointer in some cases.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: vmk80xx: remove usb_interface from private data
This driver uses the comedi auto attach mechanism so the comedi_device
will always have an associated usb_interface and usb_device.
Remove the unnecessary checks if the comedi_device has a usb_interface
attached. This also allows removing the usb_interface from the private
data.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Use the helper function to get a usb_device pointer from a
comedi_device pointer. This removes the need carring the
usb_device pointer in the private data.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: vmk80xx: don't pass the private data directly
Instead of passing the private data to the internal functions. pass
the comedi_device pointer and get the private data from it.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: usbduxfast: use comedi_to_usb_dev()
Use the helper function to get a usb_device pointer from a
comedi_device pointer. This removes the need for also getting
the usb_interface pointer in some cases.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Introduce a helper function to get a usb_device pointer from a
comedi_device pointer.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Fabio Estevam [Tue, 21 May 2013 14:24:46 +0000 (11:24 -0300)]
imx-drm: parallel-display: Let device core handle pinctrl
Since commit ab78029 (drivers/pinctrl: grab default handles from device core)
we can rely on device core for handling pinctrl, so remove
devm_pinctrl_get_select_default() from the driver.
Fabio Estevam [Tue, 21 May 2013 14:24:45 +0000 (11:24 -0300)]
imx-drm: imx-tve: Let device core handle pinctrl
Since commit ab78029 (drivers/pinctrl: grab default handles from device core)
we can rely on device core for handling pinctrl, so remove
devm_pinctrl_get_select_default() from the driver.
Peter Huewe [Fri, 17 May 2013 21:51:58 +0000 (23:51 +0200)]
staging/btmtk_usb: Mark local functions as static
sparse complains about some local functions not being static:
drivers/staging/btmtk_usb/btmtk_usb.c:50:6:
warning: symbol 'hex_dump' was not declared. Should it be static?
drivers/staging/btmtk_usb/btmtk_usb.c:227:5:
warning: symbol 'checksume16' was not declared. Should it be static?
-> add the static keyword
Signed-off-by: Peter Huewe <peterhuewe@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This patch fixes the following checkpatch error and warning,
ERROR: space prohibited before open square bracket '['
WARNING: space prohibited before semicolon
Katja Collier [Fri, 17 May 2013 13:38:35 +0000 (15:38 +0200)]
staging: fixed spaces around parens in ft1000
Deleted extra spaces before and after parens, added a couple necessary
spaces before parens in
"/drivers/staging/ft1000/ft1000-usb/ft1000_debug.c" and
"/drivers/staging/ft1000/ft1000-usb/ft1000_ioctl.h".
Katja Collier [Fri, 17 May 2013 13:36:03 +0000 (15:36 +0200)]
staging: open braces in ft1000_debug.c and ioctl.h
Fixed open braces error in "/staging/ft1000/ft1000-usb/ft1000_ioctl.h"
and "/staging/ft1000/ft1000-usb/ft1000_debug.c" by moving braces to the
correct line.
Wei Yongjun [Fri, 17 May 2013 08:27:05 +0000 (16:27 +0800)]
staging: lustre: fix to use list_for_each_entry_safe() when delete items
Since we will remove items off the list using list_del_init() we need
to use a safe version of the list_for_each_entry() macro aptly named
list_for_each_entry_safe().
Wei Yongjun [Fri, 17 May 2013 08:43:15 +0000 (16:43 +0800)]
staging: wlags49_h2: fix error return code in wl_adapter_insert()
When return from wl_adapter_insert() in the register_netdev() error
handling case, 'ret' which is 0 is returned, but we should return a
negative error code instead, so fix to return the return value of
register_netdev().
Hema Prathaban [Fri, 17 May 2013 05:44:56 +0000 (11:14 +0530)]
staging: vt6655: Use alloc_etherdev() for kzalloc
Use alloc_etherdev() for kzalloc
Signed-off-by: Hema Prathaban <hemaklnce@gmail.com> Acked-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: ni_pcidio: use comedi_load_firmware()
Use comedi_load_firmware() instead of duplicating the code in a
private function.
This driver loads multiple firmware images to the device. Modify
comedi_load_firmware() to take a 'context' that is passed to the
firmware upload callback function.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Xenia Ragiadakou [Fri, 17 May 2013 17:38:25 +0000 (20:38 +0300)]
staging: ozwpan: fix access byteorder for wMaxPacketSize in ozhcd.c
This patch fixes the access byteorder of wMaxPacketSize
which is __le16, following the USB standard, and needs to
be converted into native cpu byteorder in order to be accessed.
Instead of using le16_to_cpu(hep->desc.wMaxPacketSize),
it was used the usb_endpoint_maxp() function, defined in
<uapi/linux/usb/ch9.h>
Xenia Ragiadakou [Tue, 14 May 2013 00:07:28 +0000 (03:07 +0300)]
rtl8192u: remove whitespace after '(' and before ')' in r8192U_dm.c
This patch fixes the following checkpatch errors, in r8192U_dm.c:
ERROR: space prohibited after that open parenthesis '('
ERROR: space prohibited before that close parenthesis ')'
Xenia Ragiadakou [Tue, 14 May 2013 00:07:26 +0000 (03:07 +0300)]
rtl8192u: remove whitespace after '(' and before ')' in r8192U.h
This patch fixes the following checkpatch errors:
ERROR: space prohibited after that open parenthesis '('
ERROR: space prohibited before that close parenthesis ')'
Xenia Ragiadakou [Tue, 14 May 2013 00:07:25 +0000 (03:07 +0300)]
rtl8192u: remove whitespace after '(' and before ')' in r8190_rtl8256.c
This patch fixes the following checkpatch errors, in r8190_rtl8256.c:
ERROR: space prohibited after that open parenthesis '('
ERROR: space prohibited before that close parenthesis ')'
staging: comedi: dt9812: do not allow attaching to unsupported devices
The DT9812 is part of the ECONseries of USB Data Acquisition Modules.
This driver only supports the DT9812-10V and DT9812-2.5V versions of
the module. Do not attach to the device if an unsupported module is
detected.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>