dt-bindings: input: gpio-keys: enforce node names to match all properties
authorKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Tue, 5 Jul 2022 12:03:54 +0000 (14:03 +0200)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 8 Jul 2022 22:21:54 +0000 (15:21 -0700)
commit5eb5652250e489fdcb31b46cc898e5f848b96d05
treed70db3fa566bfa15c51a1e6b8b1bf7ad9d75338b
parent538c64068bb4f212544325f292cd0abecc081cd0
dt-bindings: input: gpio-keys: enforce node names to match all properties

The gpio-keys DT schema matches all properties with a wide pattern and
applies specific schema to children.  This has drawback - all regular
properties are also matched and are silently ignored, even if they are
not described in schema.  Basically this allows any non-object property
to be present.

Enforce specific naming pattern for children (keys) to narrow the
pattern thus do not match other properties.  This will require all
children to be properly prefixed or suffixed (button, event, switch or
key).

Removal of "if:" within patternProperties causes drop of one indentation
level, but there are no other changes in the affected block.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220705120356.94876-2-krzysztof.kozlowski@linaro.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Documentation/devicetree/bindings/input/gpio-keys.yaml