Re: [PATCH 2/2] ARM: dts: imx: Add devicetree for Kobo Aura 2

From: Andreas Kemnade
Date: Mon May 23 2022 - 15:26:57 EST


On Mon, 23 May 2022 12:03:09 +0200
Krzysztof Kozlowski <krzysztof.kozlowski@xxxxxxxxxx> wrote:

[...]
> > +
> > + gpio_keys: gpio-keys {
> > + compatible = "gpio-keys";
> > + pinctrl-names = "default";
> > + pinctrl-0 = <&pinctrl_gpio_keys>;
> > +
> > + cover {
>
> Generic node names. You could add suffix if needed, so either key or
> key-cover.
>
hmm, the example in
Documentation/devicetree/bindings/input/gpio-keys.yaml

shows names like I did. I usually expect to trust binding documentation
to have something acceptable.

> > + label = "Cover";
> > + gpios = <&gpio5 12 GPIO_ACTIVE_LOW>;
> > + linux,code = <SW_LID>;
> > + linux,input-type = <EV_SW>;
> > + wakeup-source;
> > + };
> > +
> > + power {
> > + label = "Power";
> > + gpios = <&gpio5 8 GPIO_ACTIVE_LOW>;
> > + linux,code = <KEY_POWER>;
> > + wakeup-source;
> > + };
> > + };
> > +
> > + leds: leds {
> > + compatible = "gpio-leds";
> > + pinctrl-names = "default";
> > + pinctrl-0 = <&pinctrl_led>;
> > +
> > + on {
>
> The same. You also need property for color.
>
here the documentation clearly indicates led-.*|led

Regards,
Andreas