xref: /linux/Documentation/devicetree/bindings/pwm/pwm-nexus-node.yaml (revision 4f9786035f9e519db41375818e1d0b5f20da2f10)
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/pwm/pwm-nexus-node.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: PWM Nexus node properties
8
9description: >
10  Platforms can have a standardized connector/expansion slot that exposes PWMs
11  signals to expansion boards.
12
13  A nexus node allows to remap a phandle list in a consumer node through a
14  connector node in a generic way. With this remapping, the consumer node needs
15  to know only about the nexus node. Resources behind the nexus node are
16  decoupled by the nexus node itself.
17
18maintainers:
19  - Herve Codina <herve.codina@bootlin.com>
20
21select: true
22
23properties:
24  '#pwm-cells': true
25
26  pwm-map:
27    $ref: /schemas/types.yaml#/definitions/uint32-matrix
28
29  pwm-map-mask:
30    $ref: /schemas/types.yaml#/definitions/uint32-array
31
32  pwm-map-pass-thru:
33    $ref: /schemas/types.yaml#/definitions/uint32-array
34
35dependentRequired:
36  pwm-map: ['#pwm-cells']
37  pwm-map-mask: [ pwm-map ]
38  pwm-map-pass-thru: [ pwm-map ]
39
40additionalProperties: true
41
42examples:
43  - |
44        pwm1: pwm@100 {
45            reg = <0x100 0x10>;
46            #pwm-cells = <3>;
47        };
48
49        pwm2: pwm@200 {
50            reg = <0x200 0x10>;
51            #pwm-cells = <3>;
52        };
53
54        connector: connector {
55            #pwm-cells = <3>;
56            pwm-map = <0 0 0 &pwm1 1 0 0>,
57                      <1 0 0 &pwm2 4 0 0>,
58                      <2 0 0 &pwm1 3 0 0>;
59            pwm-map-mask = <0xffffffff 0x0 0x0>;
60            pwm-map-pass-thru = <0x0 0xffffffff 0xffffffff>;
61        };
62
63        device {
64            pwms = <&connector 1 57000 0>;
65        };
66