summaryrefslogtreecommitdiffstats
path: root/dts/Bindings/input/cypress,tm2-touchkey.yaml
blob: 52dca8b64081d60640e99b37cb0ca8c65a3cdec3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/input/cypress,tm2-touchkey.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Samsung TM2 touch key controller

maintainers:
  - Stephan Gerhold <stephan@gerhold.net>

description: |
  Touch key controllers similar to the TM2 can be found in a wide range of
  Samsung devices. They are implemented using many different MCUs, but use
  a similar I2C protocol.

allOf:
  - $ref: input.yaml#

properties:
  compatible:
    enum:
      - cypress,tm2-touchkey
      - cypress,midas-touchkey
      - cypress,aries-touchkey
      - coreriver,tc360-touchkey

  reg:
    maxItems: 1

  interrupts:
    maxItems: 1

  vdd-supply:
    description: Optional regulator for LED voltage, 3.3V.

  vcc-supply:
    description: Optional regulator for MCU, 1.8V-3.3V (depending on MCU).

  vddio-supply:
    description: |
      Optional regulator that provides digital I/O voltage,
      e.g. for pulling up the interrupt line or the I2C pins.

  linux,keycodes:
    minItems: 1
    maxItems: 4

required:
  - compatible
  - reg
  - interrupts

additionalProperties: false

examples:
  - |
    #include <dt-bindings/input/input.h>
    #include <dt-bindings/interrupt-controller/irq.h>
    i2c {
        #address-cells = <1>;
        #size-cells = <0>;

        touchkey@20 {
            compatible = "cypress,tm2-touchkey";
            reg = <0x20>;
            interrupt-parent = <&gpa3>;
            interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
            vcc-supply = <&ldo32_reg>;
            vdd-supply = <&ldo33_reg>;
            linux,keycodes = <KEY_MENU KEY_BACK>;
        };
    };