linux-stable/Documentation/devicetree/bindings/mfd/allwinner,sun4i-a10-ts.yaml
Rob Herring 3d21a46093 dt-bindings: Remove cases of 'allOf' containing a '$ref'
json-schema versions draft7 and earlier have a weird behavior in that
any keywords combined with a '$ref' are ignored (silently). The correct
form was to put a '$ref' under an 'allOf'. This behavior is now changed
in the 2019-09 json-schema spec and '$ref' can be mixed with other
keywords. The json-schema library doesn't yet support this, but the
tooling now does a fixup for this and either way works.

This has been a constant source of review comments, so let's change this
treewide so everyone copies the simpler syntax.

Scripted with ruamel.yaml with some manual fixups. Some minor whitespace
changes from the script.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Maxime Ripard <mripard@kernel.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Acked-By: Vinod Koul <vkoul@kernel.org>
Acked-by: Mark Brown <broonie@kernel.org>
Acked-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Acked-by: Wolfram Sang <wsa@the-dreams.de> # for I2C
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> #for-iio
Reviewed-by: Stephen Boyd <sboyd@kernel.org> # clock
Signed-off-by: Rob Herring <robh@kernel.org>
2020-05-03 11:10:41 -05:00

76 lines
1.6 KiB
YAML

# SPDX-License-Identifier: GPL-2.0
%YAML 1.2
---
$id: http://devicetree.org/schemas/mfd/allwinner,sun4i-a10-ts.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#
title: Allwinner A10 Resistive Touchscreen Controller Device Tree Bindings
maintainers:
- Chen-Yu Tsai <wens@csie.org>
- Maxime Ripard <mripard@kernel.org>
properties:
"#thermal-sensor-cells":
const: 0
compatible:
enum:
- allwinner,sun4i-a10-ts
- allwinner,sun5i-a13-ts
- allwinner,sun6i-a31-ts
reg:
maxItems: 1
interrupts:
maxItems: 1
allwinner,ts-attached:
$ref: /schemas/types.yaml#/definitions/flag
description: A touchscreen is attached to the controller
allwinner,tp-sensitive-adjust:
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 15
default: 15
description: Sensitivity of pen down detection
allwinner,filter-type:
$ref: /schemas/types.yaml#/definitions/uint32
minimum: 0
maximum: 3
default: 1
description: |
Select median and averaging filter. Sample used for median /
averaging filter:
0: 4/2
1: 5/3
2: 8/4
3: 16/8
required:
- "#thermal-sensor-cells"
- compatible
- reg
- interrupts
additionalProperties: false
examples:
- |
rtp: rtp@1c25000 {
compatible = "allwinner,sun4i-a10-ts";
reg = <0x01c25000 0x100>;
interrupts = <29>;
allwinner,ts-attached;
#thermal-sensor-cells = <0>;
/* sensitive/noisy touch panel */
allwinner,tp-sensitive-adjust = <0>;
allwinner,filter-type = <3>;
};
...