xref: /freebsd/sys/contrib/device-tree/Bindings/tpm/tcg,tpm_tis-spi.yaml (revision 8d13bc63c0e1d50bc9e47ac1f26329c999bfecf0)
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/tpm/tcg,tpm_tis-spi.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: SPI-attached Trusted Platform Module conforming to TCG TIS specification
8
9maintainers:
10  - Lukas Wunner <lukas@wunner.de>
11
12description: |
13  The Trusted Computing Group (TCG) has defined a multi-vendor standard
14  for accessing a TPM chip.  It can be transported over various buses,
15  one of them being SPI.  The standard is named:
16  TCG PC Client Specific TPM Interface Specification (TIS)
17  https://trustedcomputinggroup.org/resource/pc-client-work-group-pc-client-specific-tpm-interface-specification-tis/
18
19properties:
20  compatible:
21    items:
22      - enum:
23          - infineon,slb9670
24          - st,st33htpm-spi
25          - st,st33zp24-spi
26      - const: tcg,tpm_tis-spi
27
28allOf:
29  - $ref: tpm-common.yaml#
30  - $ref: /schemas/spi/spi-peripheral-props.yaml#
31  - if:
32      properties:
33        compatible:
34          contains:
35            const: st,st33zp24-spi
36    then:
37      properties:
38        spi-max-frequency:
39          maximum: 10000000
40
41required:
42  - compatible
43  - reg
44
45unevaluatedProperties: false
46
47examples:
48  - |
49    spi {
50        #address-cells = <1>;
51        #size-cells = <0>;
52
53        tpm@0 {
54            reg = <0>;
55            compatible = "infineon,slb9670", "tcg,tpm_tis-spi";
56            spi-max-frequency = <10000000>;
57        };
58    };
59
60  - |
61    #include <dt-bindings/gpio/gpio.h>
62    #include <dt-bindings/interrupt-controller/irq.h>
63    spi {
64        #address-cells = <1>;
65        #size-cells = <0>;
66
67        tpm@0 {
68            reg = <0>;
69            compatible = "st,st33zp24-spi", "tcg,tpm_tis-spi";
70            spi-max-frequency = <10000000>;
71            interrupt-parent = <&gpio5>;
72            interrupts = <7 IRQ_TYPE_LEVEL_HIGH>;
73            lpcpd-gpios = <&gpio5 15 GPIO_ACTIVE_HIGH>;
74        };
75    };
76