linux-loongson/Documentation/devicetree/bindings/input/hid-over-i2c.yaml
Douglas Anderson 2ca376ef18 dt-bindings: HID: i2c-hid: Add "panel" property to i2c-hid backed touchscreens
As talked about in the patch ("drm/panel: Add a way for other devices
to follow panel state"), touchscreens that are connected to panels are
generally expected to be power sequenced together with the panel
they're attached to. Today, nothing provides information allowing you
to find out that a touchscreen is connected to a panel. Let's add a
phandle for this.

The proerty is added to the generic touchscreen bindings and then
enabled in the bindings for the i2c-hid backed devices. This can and
should be added for other touchscreens in the future, but for now
let's start small.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Maxime Ripard <mripard@kernel.org>
Reviewed-by: Benjamin Tissoires <bentiss@kernel.org>
Acked-by: Benjamin Tissoires <bentiss@kernel.org>
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230727101636.v4.1.Id68e30343bb1e11470582a9078b086176cfec46b@changeid
2023-08-01 07:34:34 -07:00

86 lines
1.9 KiB
YAML

# SPDX-License-Identifier: GPL-2.0-only
%YAML 1.2
---
$id: http://devicetree.org/schemas/input/hid-over-i2c.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: HID over I2C Devices
maintainers:
- Benjamin Tissoires <benjamin.tissoires@redhat.com>
- Jiri Kosina <jkosina@suse.cz>
description: |+
HID over I2C provides support for various Human Interface Devices over the
I2C bus. These devices can be for example touchpads, keyboards, touch screens
or sensors.
The specification has been written by Microsoft and is currently available here:
https://msdn.microsoft.com/en-us/library/windows/hardware/hh852380.aspx
If this binding is used, the kernel module i2c-hid will handle the communication
with the device and the generic hid core layer will handle the protocol.
allOf:
- $ref: /schemas/input/touchscreen/touchscreen.yaml#
properties:
compatible:
oneOf:
- items:
- enum:
- wacom,w9013
- const: hid-over-i2c
- description: Just "hid-over-i2c" alone is allowed, but not recommended.
const: hid-over-i2c
reg:
maxItems: 1
interrupts:
maxItems: 1
hid-descr-addr:
description: HID descriptor address
$ref: /schemas/types.yaml#/definitions/uint32
panel: true
post-power-on-delay-ms:
description: Time required by the device after enabling its regulators
or powering it on, before it is ready for communication.
touchscreen-inverted-x: true
touchscreen-inverted-y: true
vdd-supply:
description: 3.3V supply
vddl-supply:
description: 1.8V supply
wakeup-source: true
required:
- compatible
- reg
- interrupts
additionalProperties: false
examples:
- |
i2c {
#address-cells = <1>;
#size-cells = <0>;
hid@2c {
compatible = "hid-over-i2c";
reg = <0x2c>;
hid-descr-addr = <0x0020>;
interrupts = <3 2>;
};
};
...