Skip to content

Commit 303ba85

Browse files
committed
Merge tag 'spi-v6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi
Pull spi updates from Mark Brown: "This is quite a quiet release for SPI. The one new core feature here is support for configuring the state of the MOSI pin when the bus is idle, there are some devices which are very fragile in this regard even when the chip select signal is not asserted. Otherwise we have some new driver support, a bunch of small fixes and some general cleanup work. - Support for configuring the state of the MOSI pin when the the bus is idle - Add the Elgin JG0309-01 in spidev - Support for Marvell xSPI, Mediatek MTK7981, Microchip PIC64GX, NXP i.MX8ULP, and Rockchip RK3576 controllers I also accidentally pulled in an IIO DT bindings update due to a typo when applying the MOSI idle state patches" * tag 'spi-v6.12' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi: (65 commits) spi: geni-qcom: Use devm functions to simplify code spi: remove spi_controller_is_slave() and spi_slave_abort() platform/olpc: olpc-xo175-ec: switch to use spi_target_abort(). spi: slave-mt27xx: switch to use target_abort spi: spidev: switch to use spi_target_abort() spi: slave-system-control: switch to use spi_target_abort() spi: slave-time: switch to use spi_target_abort() spi: switch to use spi_controller_is_target() spi: fspi: add support for imx8ulp spi: fspi: involve lut_num for struct nxp_fspi_devtype_data dt-bindings: spi: nxp-fspi: add imx8ulp support spi: spidev_fdx: Fix the wrong format specifier spi: mxs: Switch to RUNTIME/SYSTEM_SLEEP_PM_OPS() spi: dt-bindings: Add rockchip,rk3576-spi compatible spi: Revert "spi: Insert the missing pci_dev_put()before return" spi: zynq-qspi: Replace kzalloc with kmalloc for buffer allocation spi: ppc4xx: Sort headers spi: ppc4xx: Revert "handle irq_of_parse_and_map() errors" spi: zynqmp-gqspi: Simplify with dev_err_probe() spi: zynqmp-gqspi: Use devm_spi_alloc_host() ...
2 parents 6df9280 + 07f1eb7 commit 303ba85

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+1305
-272
lines changed
Lines changed: 197 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,197 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/iio/adc/adi,ad4000.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Analog Devices AD4000 and similar Analog to Digital Converters
8+
9+
maintainers:
10+
- Marcelo Schmitt <[email protected]>
11+
12+
description: |
13+
Analog Devices AD4000 family of Analog to Digital Converters with SPI support.
14+
Specifications can be found at:
15+
https://www.analog.com/media/en/technical-documentation/data-sheets/ad4000-4004-4008.pdf
16+
https://www.analog.com/media/en/technical-documentation/data-sheets/ad4001-4005.pdf
17+
https://www.analog.com/media/en/technical-documentation/data-sheets/ad4002-4006-4010.pdf
18+
https://www.analog.com/media/en/technical-documentation/data-sheets/ad4003-4007-4011.pdf
19+
https://www.analog.com/media/en/technical-documentation/data-sheets/ad4020-4021-4022.pdf
20+
https://www.analog.com/media/en/technical-documentation/data-sheets/adaq4001.pdf
21+
https://www.analog.com/media/en/technical-documentation/data-sheets/adaq4003.pdf
22+
23+
$ref: /schemas/spi/spi-peripheral-props.yaml#
24+
25+
properties:
26+
compatible:
27+
oneOf:
28+
- const: adi,ad4000
29+
- items:
30+
- enum:
31+
- adi,ad4004
32+
- adi,ad4008
33+
- const: adi,ad4000
34+
35+
- const: adi,ad4001
36+
- items:
37+
- enum:
38+
- adi,ad4005
39+
- const: adi,ad4001
40+
41+
- const: adi,ad4002
42+
- items:
43+
- enum:
44+
- adi,ad4006
45+
- adi,ad4010
46+
- const: adi,ad4002
47+
48+
- const: adi,ad4003
49+
- items:
50+
- enum:
51+
- adi,ad4007
52+
- adi,ad4011
53+
- const: adi,ad4003
54+
55+
- const: adi,ad4020
56+
- items:
57+
- enum:
58+
- adi,ad4021
59+
- adi,ad4022
60+
- const: adi,ad4020
61+
62+
- const: adi,adaq4001
63+
64+
- const: adi,adaq4003
65+
66+
reg:
67+
maxItems: 1
68+
69+
spi-max-frequency:
70+
maximum: 102040816 # for VIO > 2.7 V, 81300813 for VIO > 1.7 V
71+
72+
adi,sdi-pin:
73+
$ref: /schemas/types.yaml#/definitions/string
74+
enum: [ high, low, cs, sdi ]
75+
default: sdi
76+
description:
77+
Describes how the ADC SDI pin is wired. A value of "sdi" indicates that
78+
the ADC SDI is connected to host SDO. "high" indicates that the ADC SDI
79+
pin is hard-wired to logic high (VIO). "low" indicates that it is
80+
hard-wired low (GND). "cs" indicates that the ADC SDI pin is connected to
81+
the host CS line.
82+
83+
'#daisy-chained-devices': true
84+
85+
vdd-supply:
86+
description: A 1.8V supply that powers the chip (VDD).
87+
88+
vio-supply:
89+
description:
90+
A 1.8V to 5.5V supply for the digital inputs and outputs (VIO).
91+
92+
ref-supply:
93+
description:
94+
A 2.5 to 5V supply for the external reference voltage (REF).
95+
96+
cnv-gpios:
97+
description:
98+
When provided, this property indicates the GPIO that is connected to the
99+
CNV pin.
100+
maxItems: 1
101+
102+
adi,high-z-input:
103+
type: boolean
104+
description:
105+
High-Z mode allows the amplifier and RC filter in front of the ADC to be
106+
chosen based on the signal bandwidth of interest, rather than the settling
107+
requirements of the switched capacitor SAR ADC inputs.
108+
109+
adi,gain-milli:
110+
description: |
111+
The hardware gain applied to the ADC input (in milli units).
112+
The gain provided by the ADC input scaler is defined by the hardware
113+
connections between chip pins OUT+, R1K-, R1K1-, R1K+, R1K1+, and OUT-.
114+
If not present, default to 1000 (no actual gain applied).
115+
$ref: /schemas/types.yaml#/definitions/uint16
116+
enum: [454, 909, 1000, 1900]
117+
default: 1000
118+
119+
interrupts:
120+
description:
121+
The SDO pin can also function as a busy indicator. This node should be
122+
connected to an interrupt that is triggered when the SDO line goes low
123+
while the SDI line is high and the CNV line is low ("3-wire" mode) or the
124+
SDI line is low and the CNV line is high ("4-wire" mode); or when the SDO
125+
line goes high while the SDI and CNV lines are high (chain mode),
126+
maxItems: 1
127+
128+
required:
129+
- compatible
130+
- reg
131+
- vdd-supply
132+
- vio-supply
133+
- ref-supply
134+
135+
allOf:
136+
# The configuration register can only be accessed if SDI is connected to MOSI
137+
- if:
138+
required:
139+
- adi,sdi-pin
140+
then:
141+
properties:
142+
adi,high-z-input: false
143+
# chain mode has lower SCLK max rate
144+
- if:
145+
required:
146+
- '#daisy-chained-devices'
147+
then:
148+
properties:
149+
spi-max-frequency:
150+
maximum: 50000000 # for VIO > 2.7 V, 40000000 for VIO > 1.7 V
151+
# Gain property only applies to ADAQ devices
152+
- if:
153+
properties:
154+
compatible:
155+
not:
156+
contains:
157+
enum:
158+
- adi,adaq4001
159+
- adi,adaq4003
160+
then:
161+
properties:
162+
adi,gain-milli: false
163+
164+
unevaluatedProperties: false
165+
166+
examples:
167+
- |
168+
#include <dt-bindings/gpio/gpio.h>
169+
spi {
170+
#address-cells = <1>;
171+
#size-cells = <0>;
172+
adc@0 {
173+
compatible = "adi,ad4020";
174+
reg = <0>;
175+
spi-max-frequency = <71000000>;
176+
vdd-supply = <&supply_1_8V>;
177+
vio-supply = <&supply_1_8V>;
178+
ref-supply = <&supply_5V>;
179+
adi,sdi-pin = "cs";
180+
cnv-gpios = <&gpio0 88 GPIO_ACTIVE_HIGH>;
181+
};
182+
};
183+
- |
184+
spi {
185+
#address-cells = <1>;
186+
#size-cells = <0>;
187+
adc@0 {
188+
compatible = "adi,adaq4003";
189+
reg = <0>;
190+
spi-max-frequency = <80000000>;
191+
vdd-supply = <&supply_1_8V>;
192+
vio-supply = <&supply_1_8V>;
193+
ref-supply = <&supply_5V>;
194+
adi,high-z-input;
195+
adi,gain-milli = /bits/ 16 <454>;
196+
};
197+
};

Documentation/devicetree/bindings/spi/cdns,xspi.yaml

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,24 +15,27 @@ description: |
1515
single, dual, quad or octal wire transmission modes for
1616
read/write access to slaves such as SPI-NOR flash.
1717

18-
allOf:
19-
- $ref: spi-controller.yaml#
20-
2118
properties:
2219
compatible:
23-
const: cdns,xspi-nor
20+
enum:
21+
- cdns,xspi-nor
22+
- marvell,cn10-xspi-nor
2423

2524
reg:
2625
items:
2726
- description: address and length of the controller register set
2827
- description: address and length of the Slave DMA data port
2928
- description: address and length of the auxiliary registers
29+
- description: address and length of the xfer registers
30+
minItems: 3
3031

3132
reg-names:
3233
items:
3334
- const: io
3435
- const: sdma
3536
- const: aux
37+
- const: xfer
38+
minItems: 3
3639

3740
interrupts:
3841
maxItems: 1
@@ -42,6 +45,27 @@ required:
4245
- reg
4346
- interrupts
4447

48+
allOf:
49+
- $ref: spi-controller.yaml#
50+
- if:
51+
properties:
52+
compatible:
53+
contains:
54+
enum:
55+
- marvell,cn10-xspi-nor
56+
then:
57+
properties:
58+
reg:
59+
minItems: 4
60+
reg-names:
61+
minItems: 4
62+
else:
63+
properties:
64+
reg:
65+
maxItems: 3
66+
reg-names:
67+
maxItems: 3
68+
4569
unevaluatedProperties: false
4670

4771
examples:

Documentation/devicetree/bindings/spi/mediatek,spi-mt65xx.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ properties:
3333
- const: mediatek,mt6765-spi
3434
- items:
3535
- enum:
36+
- mediatek,mt7981-spi-ipm
3637
- mediatek,mt7986-spi-ipm
3738
- mediatek,mt8188-spi-ipm
3839
- const: mediatek,spi-ipm

Documentation/devicetree/bindings/spi/microchip,mpfs-spi.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,14 @@ properties:
1717
compatible:
1818
oneOf:
1919
- items:
20-
- const: microchip,mpfs-qspi
20+
- enum:
21+
- microchip,mpfs-qspi
22+
- microchip,pic64gx-qspi
2123
- const: microchip,coreqspi-rtl-v2
2224
- const: microchip,coreqspi-rtl-v2 # FPGA QSPI
25+
- items:
26+
- const: microchip,pic64gx-spi
27+
- const: microchip,mpfs-spi
2328
- const: microchip,mpfs-spi
2429

2530
reg:
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/spi/nxp,sc18is.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: NXP SC18IS602/SC18IS603 I2C to SPI bridge
8+
9+
maintainers:
10+
- Frank Li <[email protected]>
11+
12+
properties:
13+
compatible:
14+
enum:
15+
- nxp,sc18is602
16+
- nxp,sc18is602b
17+
- nxp,sc18is603
18+
19+
reg:
20+
maxItems: 1
21+
22+
clock-frequency:
23+
$ref: /schemas/types.yaml#/definitions/uint32
24+
default: 7372000
25+
description:
26+
external oscillator clock frequency. The clock-frequency property is
27+
relevant and needed only if the chip has an external oscillator
28+
(SC18IS603).
29+
30+
allOf:
31+
- $ref: spi-controller.yaml#
32+
33+
unevaluatedProperties: false
34+
35+
required:
36+
- compatible
37+
- reg
38+
39+
examples:
40+
- |
41+
i2c {
42+
#address-cells = <1>;
43+
#size-cells = <0>;
44+
45+
spi@28 {
46+
compatible = "nxp,sc18is603";
47+
reg = <0x28>;
48+
clock-frequency = <14744000>;
49+
};
50+
};
51+

Documentation/devicetree/bindings/spi/spi-nxp-fspi.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ properties:
2121
- nxp,imx8mm-fspi
2222
- nxp,imx8mp-fspi
2323
- nxp,imx8qxp-fspi
24+
- nxp,imx8ulp-fspi
2425
- nxp,lx2160a-fspi
2526
- items:
2627
- enum:

Documentation/devicetree/bindings/spi/spi-rockchip.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ properties:
3535
- rockchip,rk3368-spi
3636
- rockchip,rk3399-spi
3737
- rockchip,rk3568-spi
38+
- rockchip,rk3576-spi
3839
- rockchip,rk3588-spi
3940
- rockchip,rv1126-spi
4041
- const: rockchip,rk3066-spi

Documentation/devicetree/bindings/spi/spi-sc18is602.txt

Lines changed: 0 additions & 23 deletions
This file was deleted.

Documentation/devicetree/bindings/trivial-devices.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,8 @@ properties:
110110
- domintech,dmard09
111111
# DMARD10: 3-axis Accelerometer
112112
- domintech,dmard10
113+
# Elgin SPI-controlled LCD
114+
- elgin,jg10309-01
113115
# MMA7660FC: 3-Axis Orientation/Motion Detection Sensor
114116
- fsl,mma7660
115117
# MMA8450Q: Xtrinsic Low-power, 3-axis Xtrinsic Accelerometer

0 commit comments

Comments
 (0)