-
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.
Adding documentation for adgs1408/1409 multiplexer. The bindings follow the standard SPI and mux bindings and do not require any additional custom properties. Signed-off-by: Mircea Caprioru <mircea.caprioru@analog.com> Reviewed-by: Rob Herring <robh@kernel.org> [peda: reword idle-state to non-array for singular mux controller] Signed-off-by: Peter Rosin <peda@axentia.se> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
- Loading branch information
Mircea Caprioru
authored and
Greg Kroah-Hartman
committed
Aug 2, 2018
1 parent
5720863
commit 94aea0c
Showing
2 changed files
with
54 additions
and
0 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,48 @@ | ||
Bindings for Analog Devices ADGS1408/1409 8:1/Dual 4:1 Mux | ||
|
||
Required properties: | ||
- compatible : Should be one of | ||
* "adi,adgs1408" | ||
* "adi,adgs1409" | ||
* Standard mux-controller bindings as described in mux-controller.txt | ||
|
||
Optional properties for ADGS1408/1409: | ||
- gpio-controller : if present, #gpio-cells is required. | ||
- #gpio-cells : should be <2> | ||
- First cell is the GPO line number, i.e. 0 to 3 | ||
for ADGS1408 and 0 to 4 for ADGS1409 | ||
- Second cell is used to specify active high (0) | ||
or active low (1) | ||
|
||
Optional properties: | ||
- idle-state : if present, the state that the mux controller will have | ||
when idle. The special state MUX_IDLE_AS_IS is the default and | ||
MUX_IDLE_DISCONNECT is also supported. | ||
|
||
States 0 through 7 correspond to signals S1 through S8 in the datasheet. | ||
For ADGS1409 only states 0 to 3 are available. | ||
|
||
Example: | ||
|
||
/* | ||
* One mux controller. | ||
* Mux state set to idle as is (no idle-state declared) | ||
*/ | ||
&spi0 { | ||
mux: mux-controller@0 { | ||
compatible = "adi,adgs1408"; | ||
reg = <0>; | ||
spi-max-frequency = <1000000>; | ||
#mux-control-cells = <0>; | ||
}; | ||
} | ||
|
||
adc-mux { | ||
compatible = "io-channel-mux"; | ||
io-channels = <&adc 1>; | ||
io-channel-names = "parent"; | ||
mux-controls = <&mux>; | ||
|
||
channels = "out_a0", "out_a1", "test0", "test1", | ||
"out_b0", "out_b1", "testb0", "testb1"; | ||
}; |
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