- 04 1月, 2013 1 次提交
-
-
由 Greg Kroah-Hartman 提交于
CONFIG_HOTPLUG is going away as an option. As a result, the __dev* markings need to be removed. This change removes the use of __devinit, __devexit_p, and __devexit from these drivers. Based on patches originally written by Bill Pemberton, but redone by me in order to handle some of the coding style issues better, by hand. Cc: Bill Pemberton <wfp5p@virginia.edu> Cc: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 30 11月, 2012 4 次提交
-
-
由 Thierry Reding 提交于
Add support for reading conversion results from the ADC and provide them through a single IIO channel. A proper scaling factor is also exported based on the reference voltage provided by a regulator. Signed-off-by: NThierry Reding <thierry.reding@avionic-design.de> Reviewed-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The ad7796 and ad7797 are similar to the ad7792 and ad7793 but only have a single differential input instead of two. Also some other features are missing like the programmable gain amplifier and also not all sampling frequencies supported by the ad7792/ad7793 are supported by the ad7796/ad7797. This patch adds new feature flags for the features not present in the ad7796/ad7797. The patch also adds a struct iio_info field to the chip_info struct, this becomes necessary since the ad7796/ad7797 needs a special set of sysfs attributes. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The ad7798 and ad7799 are similar to the ad7792 and ad7793 but are missing some features like the temperature sensor, being able to use an external clocksource and a few other things. This patch adds a new 'flags' fields to the chip_info struct which allows to specify which features a certain chip variant supports. The setup code will then ignore any platform data fields which are related to non supported features. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The driver does not expose any custom API to userspace and none of the standard static code checker tools report any issues, so move it out of staging. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 22 11月, 2012 1 次提交
-
-
由 Jonathan Cameron 提交于
These buffers are a little interesting in that their content may have variable endianness, but all but one element will definitely be big endian. Reported-by: Nkbuild test robot <fengguang.wu@intel.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org> Acked-by: NLars-Peter Clausen <lars@metafoo.de>
-
- 20 11月, 2012 2 次提交
-
-
由 Lars Poeschel 提交于
This adds the mfd cell to use the adc part of the Nano River Technologies viperboard. Signed-off-by: NLars Poeschel <poeschel@lemonage.de> Reviewed-by: NLars-Peter Clausen <lars@metafoo.de> Acked-by: NJonathan Cameron <jic23@kernel.org> Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
-
由 Lars-Peter Clausen 提交于
The driver does not expose any custom API to userspace and none of the standard static code checker tools report any issues, so move it out of staging. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 10 11月, 2012 2 次提交
-
-
由 Jonathan Cameron 提交于
Now this driver is using kfifo we can move it out of staging. Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Jonathan Cameron 提交于
Route all buffer writes through the demux. Addition or removal of a buffer results in tear down and setup of all the buffers for a given device. Signed-off-by: NJonathan Cameron <jic23@kernel.org> Tested-by: Nsrinivas pandruvada <srinivas.pandruvada@intel.com>
-
- 06 11月, 2012 2 次提交
-
-
由 Patil, Rachna 提交于
This patch adds support for TI's ADC driver. This is a multifunctional device. Analog input lines are provided on which voltage measurements can be carried out. You can have upto 8 input lines. Signed-off-by: NPatil, Rachna <rachna@ti.com> Acked-by: NJonathan Cameron <jic23@kernel.org> Signed-off-by: NSamuel Ortiz <sameo@linux.intel.com>
-
由 Lars-Peter Clausen 提交于
The driver does not expose any custom API to userspace and none of the standard static code checker tools report any issues, so move it out of staging. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 31 10月, 2012 1 次提交
-
-
由 Axel Lin 提交于
This reverts commit 45259859. This fixes build error because devm_kcalloc does not exist in current tree. Signed-off-by: NAxel Lin <axel.lin@ingics.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 20 10月, 2012 1 次提交
-
-
由 Lars-Peter Clausen 提交于
Use dev_kcalloc instead of devm_kzalloc to allocate arrays since it is semantically more appropriate. While we are at it the patch also fixes the following coccinelle warning: drivers/iio/adc/at91_adc.c:277:25-31: ERROR: application of sizeof to pointer Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Acked-By: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 19 10月, 2012 2 次提交
-
-
由 Peter Meerwald 提交于
Signed-off-by: NPeter Meerwald <pmeerw@pmeerw.net> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Peter Meerwald 提交于
irq_enabled is only set, but never read Signed-off-by: NPeter Meerwald <pmeerw@pmeerw.net> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 22 9月, 2012 1 次提交
-
-
由 Kim, Milo 提交于
TI LP8788 PMU provides regulators, battery charger, ADC, RTC, backlight driver and current sinks. This patch enables the LP8788 ADC functions. The LP8788 ADC has several ADC input selection and supports 12bit resolution. Internal operation of getting ADC is access to registers of LP8788. The LP8788 ADC uses exported functions for accessing these registers. (exported by LP8788 MFD device driver) This driver supports IIO_CHAN_INFO_RAW and SCALE. So the IIO consumer can calculate the value with raw and scale. The unit of scale is micro. (ADC Input Selection) Voltage: battery voltage (MAX 5.0, 5.5 and 6.0V) charger input voltage four general ADC inputs coin cell voltage Current: battery charging current Temperature: IC temperature (The IIO map for the IIO consumer) The ADC input is configurable in the platform side. Even though this platform data is not defined, the default IIO map is created for supporting the power supply driver. The battery voltage and temperature are used inside this driver. (History) Patch v6. (a) Fix scale value for each ADC input selection Voltage and current type are mili unit and temperature is degree. To calculate the IC temperature, temp = raw * scaleint + (raw * scalepart)/ 1000000, scaleint is always 0. = raw * 0.061050, raw: 0 ~ 4095 Then range of IC temperature(ADC result) is 0 ~ 250'C (b) Reorganization of the IIO channel Spec Remove address, scan_type and scan_index and rollback the datasheet name. The reason why 'address' field is unnecessary is no relation with each channel. Moreover, to get the raw ADC value, the address info is not only one register but also several registers. Therefore specific function(lp8788_get_adc_result) is called rather than using one 'address' field. (c) Fix coding style Remove duplicated checking routine while unregistering the IIO map. Fix code for space and parenthesis. Patch v5. Fix default consumer name as 'lp8788-charger'. Add mutex for ADC read operation. Reorganization on lp8788_adc_read_raw(). Patch v4. Fix adc_raw function: support RAW and SCALE channel info. Change LP8788 ADC platform data - iio map. Enables the default IIO map. Patch v3. Fix wrong size of allocating iio private data. Fix coding styles. Patch v2. Support RAW and SCALE interface for IIO consumer. Clean up the iio channel spec macro. Signed-off-by: NMilo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 18 9月, 2012 1 次提交
-
-
由 Lars-Peter Clausen 提交于
Add support for the ad7091r 12 bit ADC to the ad7476 driver. Although the ad7091r is not really related to any of the other devices supported by this driver, luckily for us there are not so many ways (which are not totally insane) how sampling a single channel ADC via SPI can be implemented and support for the ad7091r can be added to the driver with just a few adjustments. The ad7091r requires an external "conversion start" pulse to start a sample conversion. After the conversion has finished the result can be read via SPI. We depend on a IIO trigger to generate this signal, as a result only sampling in buffered mode and not in manual mode is available. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 15 9月, 2012 4 次提交
-
-
由 Lars-Peter Clausen 提交于
The ad7276/ad7277/ad7278 are similar to the ad7476/ad7477/ad7478 but have the same number of leading zeros as the ad7940. The ad7273/ad7274 have a extra pin for VREF where as for the ad7276/ad7277/ad7278 VREF is taken from VDD, but otherwise they are compatible to the ad7276/ad7277. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The AD7940 is a single channel 14 bit ADC similar to the ADCs already supported by the ad7476 driver, but it does have a different shift factor. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The ad7910/ad7920 are software compatible to the ad7467/ad7466. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
The ad7476 driver is a driver for simple single channel ADCs. The driver does not export any experimental or custom ABI files nor do the static code check tools report any issues, so move the driver out of staging. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 08 9月, 2012 2 次提交
-
-
由 Lars-Peter Clausen 提交于
This patch adds support for the Analog Devices AD7787, AD7788, AD7789, AD7790 and AD7791 Sigma Delta Analog-to-Digital converters. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
Drop timestamp parameter from buffer store_to callback and subsequently from iio_push_to_buffer. The timestamp parameter is unused and it seems likely that it will stay unused in the future, so it should be safe to remove it. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 04 9月, 2012 1 次提交
-
-
由 Julia Lawall 提交于
Clk_prepare_enable and clk_disable_unprepare combine clk_prepare and clk_enable, and clk_disable and clk_unprepare. They make the code more concise, and ensure that clk_unprepare is called when clk_enable fails. A simplified version of the semantic patch that introduces calls to these functions is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression e; @@ - clk_prepare(e); - clk_enable(e); + clk_prepare_enable(e); @@ expression e; @@ - clk_disable(e); - clk_unprepare(e); + clk_disable_unprepare(e); // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 28 8月, 2012 2 次提交
-
-
由 Julia Lawall 提交于
Change the call to PTR_ERR to access the value just tested by IS_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression e,e1; @@ ( if (IS_ERR(e)) { ... PTR_ERR(e) ... } | if (IS_ERR(e=e1)) { ... PTR_ERR(e) ... } | *if (IS_ERR(e)) { ... * PTR_ERR(e1) ... } ) // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
由 Lars-Peter Clausen 提交于
Most devices from the Analog Devices Sigma Delta family use a similar scheme for communication with the device. This includes register access, as well as trigger handling. But each device sub-family has different features and different register layouts (some even have no registers at all) and thus it is impractical to try to support all of the devices by the same driver. This patch adds a common base library for Sigma Delta converter devices. It will be used by individual drivers. This code is mostly based on the three existing Sigma Delta drivers the AD7192, AD7780 and AD7793, but has been improved for more robustness and flexibility. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 17 8月, 2012 1 次提交
-
-
由 Julia Lawall 提交于
The various devm_ functions allocate memory that is released when a driver detaches. This patch uses these functions for data that is allocated in the probe function of a platform device and is only freed in the remove function. The call to platform_get_resource(pdev, IORESOURCE_MEM, 0) is moved coser to the call to devm_request_and_ioremap, which is th first use of the result of platform_get_resource. This does not use devm_request_irq to ensure that free_irq is executed before its idev argument is freed. Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Reviewed-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 30 6月, 2012 1 次提交
-
-
由 Lars-Peter Clausen 提交于
This patch adds support for the Analog Devices AD7265 and AD7266 Analog-to-Digital converters. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Signed-off-by: NJonathan Cameron <jic23@kernel.org>
-
- 27 6月, 2012 1 次提交
-
-
由 Lars-Peter Clausen 提交于
This issue was reported by the mini_lock.cocci coccinelle semantic patch. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Acked-by: NJonathan Cameron <jic23@kernel.org> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 19 6月, 2012 1 次提交
-
-
由 Lars-Peter Clausen 提交于
Use the new triggered buffer setup helper function to allocate and register buffer and pollfunc. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Acked-by: NJonathan Cameron <jic23@kernel.org> Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 15 5月, 2012 2 次提交
-
-
由 Maxime Ripard 提交于
Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Acked-by: NNicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Maxime Ripard 提交于
Add the ADC driver for Atmel's AT91SAM9G20-EK, AT91SAM9M10G45-EK and AT91SAM9X5 family boards. It has support for both software and hardware triggers. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Acked-by: NNicolas Ferre <nicolas.ferre@atmel.com> Acked-by: NJonathan Cameron <jic23@kernel.org> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-