All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Tony Lindgren <tony@atomide.com>
Cc: Rob Herring <robh@kernel.org>,
	linux-input@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, Dhruva Gole <d-gole@ti.com>
Subject: Re: [PATCH v5 2/2] Input: gpio-keys - Add system suspend support for dedicated wakeirqs
Date: Tue, 12 Dec 2023 23:14:34 -0800	[thread overview]
Message-ID: <ZXlZ2i0wvI9iu3tv@google.com> (raw)
In-Reply-To: <20231129110618.27551-2-tony@atomide.com>

On Wed, Nov 29, 2023 at 01:06:15PM +0200, Tony Lindgren wrote:
> Some SoCs have a separate dedicated wake-up interrupt controller that can
> be used to wake up the system from deeper idle states. We already support
> configuring a separate interrupt for a gpio-keys button to be used with a
> gpio line. However, we are lacking support system suspend for cases where
> a separate interrupt needs to be used in deeper sleep modes.
> 
> Because of it's nature, gpio-keys does not know about the runtime PM state
> of the button gpios, and may have several gpio buttons configured for each
> gpio-keys device instance. Implementing runtime PM support for gpio-keys
> does not help, and we cannot use drivers/base/power/wakeirq.c support. We
> need to implement custom wakeirq support for gpio-keys.
> 
> For handling a dedicated wakeirq for system suspend, we enable and disable
> it with gpio_keys_enable_wakeup() and gpio_keys_disable_wakeup() that we
> already use based on device_may_wakeup().
> 
> Some systems may have a dedicated wakeirq that can also be used as the
> main interrupt, this is already working for gpio-keys. Let's add some
> wakeirq related comments while at it as the usage with a gpio line and
> separate interrupt line may not be obvious.
> 
> Tested-by: Dhruva Gole <d-gole@ti.com>
> Signed-off-by: Tony Lindgren <tony@atomide.com>

Applied, thank you.

-- 
Dmitry

  reply	other threads:[~2023-12-13  7:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-29 11:06 [PATCH v5 1/2] dt-bindings: input: gpio-keys: Allow optional dedicated wakeirq Tony Lindgren
2023-11-29 11:06 ` [PATCH v5 2/2] Input: gpio-keys - Add system suspend support for dedicated wakeirqs Tony Lindgren
2023-12-13  7:14   ` Dmitry Torokhov [this message]
2023-12-13  7:14 ` [PATCH v5 1/2] dt-bindings: input: gpio-keys: Allow optional dedicated wakeirq 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=ZXlZ2i0wvI9iu3tv@google.com \
    --to=dmitry.torokhov@gmail.com \
    --cc=d-gole@ti.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=tony@atomide.com \
    /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.