Skip to content

Commit a730bf7

Browse files
AntonioBorneoLinus Walleij
authored andcommitted
dt-bindings: pinctrl: stm32: Support I/O synchronization parameters
Document the support of the I/O synchronization parameters: - skew-delay-input-ps; - skew-delay-output-ps; - st,io-sync. Forbid 'skew-delay-input-ps' and 'skew-delay-output-ps' to be both present on the same pin. Allow the new properties only with compatibles that support them. Add an example that uses the new properties. Co-developed-by: Fabien Dessenne <fabien.dessenne@foss.st.com> Signed-off-by: Fabien Dessenne <fabien.dessenne@foss.st.com> Signed-off-by: Antonio Borneo <antonio.borneo@foss.st.com> Reviewed-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
1 parent cf7a3d4 commit a730bf7

1 file changed

Lines changed: 74 additions & 0 deletions

File tree

Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,12 +220,65 @@ patternProperties:
220220
minimum: 0
221221
maximum: 3
222222

223+
skew-delay-input-ps:
224+
description: |
225+
IO synchronization skew rate applied to the input path
226+
enum: [0, 300, 500, 750, 1000, 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000, 3250]
227+
228+
skew-delay-output-ps:
229+
description: |
230+
IO synchronization latch delay applied to the output path
231+
enum: [0, 300, 500, 750, 1000, 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000, 3250]
232+
233+
st,io-sync:
234+
$ref: /schemas/types.yaml#/definitions/string
235+
enum:
236+
- pass-through
237+
- clock inverted
238+
- data on rising edge
239+
- data on falling edge
240+
- data on both edges
241+
description: |
242+
IO synchronization through re-sampling or inversion
243+
"pass-through" - data or clock GPIO pass-through
244+
"clock inverted" - clock GPIO inverted
245+
"data on rising edge" - data GPIO re-sampled on clock rising edge
246+
"data on falling edge" - data GPIO re-sampled on clock falling edge
247+
"data on both edges" - data GPIO re-sampled on both clock edges
248+
default: pass-through
249+
223250
required:
224251
- pinmux
225252

253+
# Not allowed both skew-delay-input-ps and skew-delay-output-ps
254+
if:
255+
required:
256+
- skew-delay-input-ps
257+
then:
258+
properties:
259+
skew-delay-output-ps: false
260+
226261
allOf:
227262
- $ref: pinctrl.yaml#
228263

264+
- if:
265+
not:
266+
properties:
267+
compatible:
268+
contains:
269+
enum:
270+
- st,stm32mp257-pinctrl
271+
- st,stm32mp257-z-pinctrl
272+
then:
273+
patternProperties:
274+
'-[0-9]*$':
275+
patternProperties:
276+
'^pins':
277+
properties:
278+
skew-delay-input-ps: false
279+
skew-delay-output-ps: false
280+
st,io-sync: false
281+
229282
required:
230283
- compatible
231284
- '#address-cells'
@@ -306,4 +359,25 @@ examples:
306359
pinctrl-names = "default";
307360
};
308361
362+
- |
363+
#include <dt-bindings/pinctrl/stm32-pinfunc.h>
364+
//Example 4 skew-delay and st,io-sync
365+
pinctrl: pinctrl@44240000 {
366+
compatible = "st,stm32mp257-pinctrl";
367+
#address-cells = <1>;
368+
#size-cells = <1>;
369+
ranges = <0 0x44240000 0xa0400>;
370+
371+
eth3_rgmii_pins_a: eth3-rgmii-0 {
372+
pins1 {
373+
pinmux = <STM32_PINMUX('A', 6, AF14)>;
374+
st,io-sync = "data on both edges";
375+
};
376+
pins2 {
377+
pinmux = <STM32_PINMUX('H', 2, AF14)>;
378+
skew-delay-output-ps = <500>;
379+
};
380+
};
381+
};
382+
309383
...

0 commit comments

Comments
 (0)