-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge tag 'iio-for-4.12d' of git://git.kernel.org/pub/scm/linux/kerne…
…l/git/jic23/iio into staging-next Jonathan writes: Fourth set of IIO new device support, features and cleanups for the 4.12 cycle New device support * max1117, 1118 and 1119 - new ADC driver * max9611 - new ADC driver * pm8xxx hk/xoadc - new driver with some shared features broken out from the SPMI vadc. * sun4i-gpadc - A33 thermal sensor support (with associated rework) * stm32-dac - new driver and bindings * stm32 trigger - enable support of quadrature encoder device and counter modes Features * apds9960 - use the runtime pm for normal suspend * stm32-adc - add opition to sest resolution via devicetree * xoadc - augment DT bindings to deal with some weird mux cases Cleanups * ad5933 - protect direct mode using claim and release helpers * ade7759 - S_IRUGO and friends to octal in two goes * adis16203 - drop unnecessary brackets * hid-sensor - fix unbalanced pm_runtieme_enable error when probing after remove * lsm6dsx - use actual part numbers for device name when known - simplify data read pin parsing * mpu3050 - avoid double reporting errors
- Loading branch information
Showing
35 changed files
with
3,709 additions
and
444 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
What: /sys/bus/iio/devices/iio:deviceX/in_power_shunt_resistor | ||
Date: March 2017 | ||
KernelVersion: 4.12 | ||
Contact: linux-iio@vger.kernel.org | ||
Description: The value of the shunt resistor used to compute power drain on | ||
common input voltage pin (RS+). In Ohms. | ||
|
||
What: /sys/bus/iio/devices/iio:deviceX/in_current_shunt_resistor | ||
Date: March 2017 | ||
KernelVersion: 4.12 | ||
Contact: linux-iio@vger.kernel.org | ||
Description: The value of the shunt resistor used to compute current flowing | ||
between RS+ and RS- voltage sense inputs. In Ohms. | ||
|
||
These attributes describe a single physical component, exposed as two distinct | ||
attributes as it is used to calculate two different values: power load and | ||
current flowing between RS+ and RS- inputs. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
* MAX1117/MAX1118/MAX1119 8-bit, dual-channel ADCs | ||
|
||
Required properties: | ||
- compatible: Should be one of | ||
* "maxim,max1117" | ||
* "maxim,max1118" | ||
* "maxim,max1119" | ||
- reg: spi chip select number for the device | ||
- (max1118 only) vref-supply: The regulator supply for ADC reference voltage | ||
|
||
Recommended properties: | ||
- spi-max-frequency: Definition as per | ||
Documentation/devicetree/bindings/spi/spi-bus.txt | ||
|
||
Example: | ||
adc@0 { | ||
compatible = "maxim,max1118"; | ||
reg = <0>; | ||
vref-supply = <&vdd_supply>; | ||
spi-max-frequency = <1000000>; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
* Maxim max9611/max9612 current sense amplifier with 12-bits ADC interface | ||
|
||
Maxim max9611/max9612 is an high-side current sense amplifier with integrated | ||
12-bits ADC communicating over I2c bus. | ||
The device node for this driver shall be a child of a I2c controller. | ||
|
||
Required properties | ||
- compatible: Should be "maxim,max9611" or "maxim,max9612" | ||
- reg: The 7-bits long I2c address of the device | ||
- shunt-resistor-micro-ohms: Value, in micro Ohms, of the current sense shunt | ||
resistor | ||
|
||
Example: | ||
|
||
&i2c4 { | ||
csa: adc@7c { | ||
compatible = "maxim,max9611"; | ||
reg = <0x7c>; | ||
|
||
shunt-resistor-micro-ohms = <5000>; | ||
}; | ||
}; | ||
|
||
This device node describes a current sense amplifier sitting on I2c4 bus | ||
with address 0x7c (read address is 0xf9, write address is 0xf8). | ||
A sense resistor of 0,005 Ohm is installed between RS+ and RS- current-sensing | ||
inputs. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
61 changes: 61 additions & 0 deletions
61
Documentation/devicetree/bindings/iio/dac/st,stm32-dac.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
STMicroelectronics STM32 DAC | ||
|
||
The STM32 DAC is a 12-bit voltage output digital-to-analog converter. The DAC | ||
may be configured in 8 or 12-bit mode. It has two output channels, each with | ||
its own converter. | ||
It has built-in noise and triangle waveform generator and supports external | ||
triggers for conversions. The DAC's output buffer allows a high drive output | ||
current. | ||
|
||
Contents of a stm32 dac root node: | ||
----------------------------------- | ||
Required properties: | ||
- compatible: Must be "st,stm32h7-dac-core". | ||
- reg: Offset and length of the device's register set. | ||
- clocks: Must contain an entry for pclk (which feeds the peripheral bus | ||
interface) | ||
- clock-names: Must be "pclk". | ||
- vref-supply: Phandle to the vref+ input analog reference supply. | ||
- #address-cells = <1>; | ||
- #size-cells = <0>; | ||
|
||
Optional properties: | ||
- resets: Must contain the phandle to the reset controller. | ||
- A pinctrl state named "default" for each DAC channel may be defined to set | ||
DAC_OUTx pin in mode of operation for analog output on external pin. | ||
|
||
Contents of a stm32 dac child node: | ||
----------------------------------- | ||
DAC core node should contain at least one subnode, representing a | ||
DAC instance/channel available on the machine. | ||
|
||
Required properties: | ||
- compatible: Must be "st,stm32-dac". | ||
- reg: Must be either 1 or 2, to define (single) channel in use | ||
- #io-channel-cells = <1>: See the IIO bindings section "IIO consumers" in | ||
Documentation/devicetree/bindings/iio/iio-bindings.txt | ||
|
||
Example: | ||
dac: dac@40007400 { | ||
compatible = "st,stm32h7-dac-core"; | ||
reg = <0x40007400 0x400>; | ||
clocks = <&clk>; | ||
clock-names = "pclk"; | ||
vref-supply = <®_vref>; | ||
pinctrl-names = "default"; | ||
pinctrl-0 = <&dac_out1 &dac_out2>; | ||
#address-cells = <1>; | ||
#size-cells = <0>; | ||
|
||
dac1: dac@1 { | ||
compatible = "st,stm32-dac"; | ||
#io-channels-cells = <1>; | ||
reg = <1>; | ||
}; | ||
|
||
dac2: dac@2 { | ||
compatible = "st,stm32-dac"; | ||
#io-channels-cells = <1>; | ||
reg = <2>; | ||
}; | ||
}; |
Oops, something went wrong.