blob: 477066e2b82173aa81fb4175756a3b8ac65ff3e8 [file] [log] [blame]
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +02001# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/net/nfc/samsung,s3fwrn5.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Samsung S3FWRN5 NCI NFC Controller
8
9maintainers:
10 - Krzysztof Kozlowski <krzk@kernel.org>
11 - Krzysztof Opasiak <k.opasiak@samsung.com>
12
13properties:
14 compatible:
Bongsu Jeon36d07622020-12-02 20:47:38 +090015 enum:
16 - samsung,s3fwrn5-i2c
17 - samsung,s3fwrn82
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020018
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020019 en-gpios:
20 maxItems: 1
21 description:
22 Output GPIO pin used for enabling/disabling the chip
23
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020024 interrupts:
25 maxItems: 1
26
27 reg:
28 maxItems: 1
29
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020030 wake-gpios:
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020031 maxItems: 1
32 description:
33 Output GPIO pin used to enter firmware mode and sleep/wakeup control
34
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020035 s3fwrn5,en-gpios:
36 maxItems: 1
37 deprecated: true
38 description:
39 Use en-gpios
40
41 s3fwrn5,fw-gpios:
42 maxItems: 1
43 deprecated: true
44 description:
45 Use wake-gpios
46
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020047additionalProperties: false
48
49required:
50 - compatible
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020051 - en-gpios
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020052 - wake-gpios
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020053
Bongsu Jeon36d07622020-12-02 20:47:38 +090054allOf:
55 - if:
56 properties:
57 compatible:
58 contains:
59 const: samsung,s3fwrn5-i2c
60 then:
61 required:
62 - interrupts
63 - reg
64
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020065examples:
66 - |
67 #include <dt-bindings/gpio/gpio.h>
68 #include <dt-bindings/interrupt-controller/irq.h>
69
70 i2c4 {
71 #address-cells = <1>;
72 #size-cells = <0>;
73
74 s3fwrn5@27 {
75 compatible = "samsung,s3fwrn5-i2c";
76 reg = <0x27>;
77
78 interrupt-parent = <&gpa1>;
Bongsu Jeonb783ff42020-12-08 23:10:11 +090079 interrupts = <3 IRQ_TYPE_EDGE_RISING>;
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020080
Krzysztof Kozlowski3a9f89a2020-09-10 18:12:13 +020081 en-gpios = <&gpf1 4 GPIO_ACTIVE_HIGH>;
82 wake-gpios = <&gpj0 2 GPIO_ACTIVE_HIGH>;
Krzysztof Kozlowski07d20a62020-09-10 18:12:12 +020083 };
84 };
Bongsu Jeon36d07622020-12-02 20:47:38 +090085 # UART example on Raspberry Pi
86 - |
87 uart0 {
88 status = "okay";
89
90 nfc {
91 compatible = "samsung,s3fwrn82";
92
93 en-gpios = <&gpio 20 GPIO_ACTIVE_HIGH>;
94 wake-gpios = <&gpio 16 GPIO_ACTIVE_HIGH>;
95
96 status = "okay";
97 };
98 };