All of lore.kernel.org
 help / color / mirror / Atom feed
From: Raul E Rangel <rrangel@chromium.org>
To: linux-acpi@vger.kernel.org, linux-input@vger.kernel.org
Cc: hdegoede@redhat.com, mario.limonciello@amd.com, timvp@google.com,
	rafael@kernel.org, Raul E Rangel <rrangel@chromium.org>,
	Alistair Francis <alistair@alistair23.me>,
	Angela Czubak <acz@semihalf.com>,
	Benjamin Tissoires <benjamin.tissoires@redhat.com>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Jiri Kosina <jikos@kernel.org>,
	Matthias Kaehlcke <mka@chromium.org>,
	linux-kernel@vger.kernel.org
Subject: [PATCH 7/8] HID: i2c-hid: Don't set wake_irq when using ACPI
Date: Tue, 30 Aug 2022 17:15:40 -0600	[thread overview]
Message-ID: <20220830171332.7.Id22d056440953134d8e8fe2c2aff79c79bc78424@changeid> (raw)
In-Reply-To: <20220830231541.1135813-1-rrangel@chromium.org>

The i2c-core will now handle setting the wake_irq for ACPI systems.

I didn't delete the whole block since this also covers systems that
don't use ACPI or DT, but I'm honestly not sure if that's a valid
config.

Signed-off-by: Raul E Rangel <rrangel@chromium.org>
---

 drivers/hid/i2c-hid/i2c-hid-core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/hid/i2c-hid/i2c-hid-core.c b/drivers/hid/i2c-hid/i2c-hid-core.c
index 0b7a1a8b3e9a33..630e8dcda1100d 100644
--- a/drivers/hid/i2c-hid/i2c-hid-core.c
+++ b/drivers/hid/i2c-hid/i2c-hid-core.c
@@ -1037,10 +1037,10 @@ int i2c_hid_core_probe(struct i2c_client *client, struct i2chid_ops *ops,
 		goto err_powered;
 
 	/*
-	 * Systems using device tree should set up wakeup via DTS,
+	 * Systems using device tree should set up wakeup via DTS or ACPI,
 	 * the rest will configure device as wakeup source by default.
 	 */
-	if (!client->dev.of_node) {
+	if (!client->dev.of_node && !has_acpi_companion(&client->dev)) {
 		device_init_wakeup(&client->dev, true);
 		dev_pm_set_wake_irq(&client->dev, client->irq);
 	}
-- 
2.37.2.672.g94769d06f0-goog


  parent reply	other threads:[~2022-08-30 23:16 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-30 23:15 [PATCH 0/8] acpi: i2c: Use SharedAndWake and ExclusiveAndWake to enable wake irq Raul E Rangel
2022-08-30 23:15 ` [PATCH 1/8] Input: elan_i2c - Use PM subsystem to manage " Raul E Rangel
2022-08-31 18:01   ` Rafael J. Wysocki
2022-08-31 18:13     ` Raul Rangel
2022-08-31 18:42       ` Rafael J. Wysocki
2022-09-01  6:57         ` Tony Lindgren
2022-08-31 19:12     ` Dmitry Torokhov
2022-08-31 19:16       ` Dmitry Torokhov
2022-09-01  2:17         ` Raul Rangel
2022-09-03  5:06           ` Dmitry Torokhov
2022-09-06 17:18             ` Raul Rangel
2022-09-06 18:40               ` Dmitry Torokhov
2022-08-30 23:15 ` [PATCH 2/8] HID: i2c-hid: " Raul E Rangel
2022-08-30 23:15 ` [PATCH 3/8] gpiolib: acpi: Add wake_capable parameter to acpi_dev_gpio_irq_get_by Raul E Rangel
2022-08-31  4:58   ` kernel test robot
2022-08-30 23:15 ` [PATCH 4/8] i2c: acpi: Use ACPI GPIO wake capability bit to set wake_irq Raul E Rangel
2022-09-07  1:00   ` Dmitry Torokhov
2022-09-07  2:00     ` Raul Rangel
2022-09-07  2:04       ` Dmitry Torokhov
2022-09-07  8:12       ` Hans de Goede
2022-09-08 14:40         ` Raul Rangel
2022-09-08 15:23           ` Rafael J. Wysocki
2022-09-09 18:47             ` Raul Rangel
2022-09-10  1:25               ` Dmitry Torokhov
2022-08-30 23:15 ` [PATCH 5/8] HID: i2c-hid: acpi: Stop setting wakeup_capable Raul E Rangel
2022-08-30 23:15 ` [PATCH 6/8] Input: elan_i2c - Don't set wake_irq when using ACPI Raul E Rangel
2022-08-30 23:15 ` Raul E Rangel [this message]
2022-08-30 23:15 ` [PATCH 8/8] ACPI: PM: Take wake IRQ into consideration when entering suspend-to-idle Raul E Rangel
2022-08-31 11:52 ` [PATCH 0/8] acpi: i2c: Use SharedAndWake and ExclusiveAndWake to enable wake irq Andy Shevchenko
2022-08-31 14:37   ` Raul Rangel
2022-08-31 15:18     ` Hans de Goede

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=20220830171332.7.Id22d056440953134d8e8fe2c2aff79c79bc78424@changeid \
    --to=rrangel@chromium.org \
    --cc=acz@semihalf.com \
    --cc=alistair@alistair23.me \
    --cc=benjamin.tissoires@redhat.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=hdegoede@redhat.com \
    --cc=jikos@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mario.limonciello@amd.com \
    --cc=mka@chromium.org \
    --cc=rafael@kernel.org \
    --cc=timvp@google.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.