xref: /linux/Documentation/devicetree/bindings/crypto/allwinner,sun8i-ce.yaml (revision 26fbb4c8c7c3ee9a4c3b4de555a8587b5a19154e)
1# SPDX-License-Identifier: GPL-2.0
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/crypto/allwinner,sun8i-ce.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Allwinner Crypto Engine driver
8
9maintainers:
10  - Corentin Labbe <clabbe.montjoie@gmail.com>
11
12properties:
13  compatible:
14    enum:
15      - allwinner,sun8i-h3-crypto
16      - allwinner,sun8i-r40-crypto
17      - allwinner,sun50i-a64-crypto
18      - allwinner,sun50i-h5-crypto
19      - allwinner,sun50i-h6-crypto
20
21  reg:
22    maxItems: 1
23
24  interrupts:
25    maxItems: 1
26
27  clocks:
28    items:
29      - description: Bus clock
30      - description: Module clock
31      - description: MBus clock
32    minItems: 2
33    maxItems: 3
34
35  clock-names:
36    items:
37      - const: bus
38      - const: mod
39      - const: ram
40    minItems: 2
41    maxItems: 3
42
43  resets:
44    maxItems: 1
45
46if:
47  properties:
48    compatible:
49      items:
50        const: allwinner,sun50i-h6-crypto
51then:
52  properties:
53    clocks:
54      minItems: 3
55    clock-names:
56      minItems: 3
57else:
58  properties:
59    clocks:
60      maxItems: 2
61    clock-names:
62      maxItems: 2
63
64required:
65  - compatible
66  - reg
67  - interrupts
68  - clocks
69  - clock-names
70  - resets
71
72additionalProperties: false
73
74examples:
75  - |
76    #include <dt-bindings/interrupt-controller/arm-gic.h>
77    #include <dt-bindings/clock/sun50i-a64-ccu.h>
78    #include <dt-bindings/reset/sun50i-a64-ccu.h>
79
80    crypto: crypto@1c15000 {
81      compatible = "allwinner,sun8i-h3-crypto";
82      reg = <0x01c15000 0x1000>;
83      interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>;
84      clocks = <&ccu CLK_BUS_CE>, <&ccu CLK_CE>;
85      clock-names = "bus", "mod";
86      resets = <&ccu RST_BUS_CE>;
87    };
88
89