All of lore.kernel.org
 help / color / mirror / Atom feed
From: Linus Walleij <linus.walleij@linaro.org>
To: "Nuno Sá" <nuno.sa@analog.com>
Cc: linux-kernel@vger.kernel.org, Bartosz Golaszewski <brgl@bgdev.pl>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	devicetree@vger.kernel.org, linux-gpio@vger.kernel.org,
	linux-input@vger.kernel.org,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Michael Hennerich <michael.hennerich@analog.com>
Subject: Re: [PATCH v4 01/10] input: keyboard: adp5588-keys: support gpi key events as 'gpio keys'
Date: Wed, 31 Aug 2022 14:37:40 +0200	[thread overview]
Message-ID: <CACRpkdaxfgf6T4EcWKG8_y4LmZPggQHGjHcq6f_5YkgGWv5vcA@mail.gmail.com> (raw)
In-Reply-To: <20220829131553.690063-2-nuno.sa@analog.com>

On Mon, Aug 29, 2022 at 3:15 PM Nuno Sá <nuno.sa@analog.com> wrote:

> This change replaces the support for GPIs as key event generators.
> Instead of reporting the events directly, we add a gpio based irqchip
> so that these events can be consumed by keys defined in the gpio-keys
> driver (as it's goal is indeed for keys on GPIOs capable of generating
> interrupts). With this, the gpio-adp5588 driver can also be dropped.
>
> The basic idea is that all the pins that are not being used as part of
> the keymap matrix can be possibly requested as GPIOs by gpio-keys
> (it's also fine to use these pins as plain interrupts though that's not
> really the point).
>
> Since the gpiochip now also has irqchip capabilities, we should only
> remove it after we free the device interrupt (otherwise we could, in
> theory, be handling GPIs interrupts while the gpiochip is concurrently
> removed). Thus the call 'adp5588_gpio_add()' is moved and since the
> setup phase also needs to come before making the gpios visible, we also
> need to move 'adp5588_setup()'.
>
> While at it, always select GPIOLIB so that we don't need to use #ifdef
> guards.
>
> Signed-off-by: Nuno Sá <nuno.sa@analog.com>

Makes the world simpler so:
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

  parent reply	other threads:[~2022-08-31 12:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-29 13:15 [PATCH v4 00/10] adp5588-keys refactor and fw properties support Nuno Sá
2022-08-29 13:15 ` [PATCH v4 01/10] input: keyboard: adp5588-keys: support gpi key events as 'gpio keys' Nuno Sá
2022-08-29 14:18   ` Andy Shevchenko
2022-08-31 12:37   ` Linus Walleij [this message]
2022-08-29 13:15 ` [PATCH v4 02/10] gpio: gpio-adp5588: drop the driver Nuno Sá
2022-08-31 12:21   ` Linus Walleij
2022-08-31 12:22     ` Linus Walleij
2022-08-31 12:24       ` Sa, Nuno
2022-08-29 13:15 ` [PATCH v4 03/10] input: keyboard: adp5588-keys: bail out on returned error Nuno Sá
2022-08-29 13:15 ` [PATCH v4 04/10] input: keyboard: adp5588-keys: add support for fw properties Nuno Sá
2022-08-29 13:15 ` [PATCH v4 05/10] dt-bindings: input: adp5588: add bindings Nuno Sá
2022-08-29 13:15 ` [PATCH v4 06/10] input: keyboard: adp5588-keys: do not check for irq presence Nuno Sá
2022-08-29 13:15 ` [PATCH v4 07/10] input: keyboard: adp5588-keys: fix coding style warnings Nuno Sá
2022-08-29 13:15 ` [PATCH v4 08/10] input: keyboard: adp5588-keys: add optional reset gpio Nuno Sá
2022-08-29 13:15 ` [PATCH v4 09/10] input: keyboard: adp5588-keys: add regulator support Nuno Sá
2022-08-29 13:15 ` [PATCH v4 10/10] input: keyboard: adp5588-keys: Use new PM macros Nuno Sá
2022-08-31  4:19 ` [PATCH v4 00/10] adp5588-keys refactor and fw properties support Dmitry Torokhov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CACRpkdaxfgf6T4EcWKG8_y4LmZPggQHGjHcq6f_5YkgGWv5vcA@mail.gmail.com \
    --to=linus.walleij@linaro.org \
    --cc=andy.shevchenko@gmail.com \
    --cc=brgl@bgdev.pl \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michael.hennerich@analog.com \
    --cc=nuno.sa@analog.com \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.