All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055
@ 2021-04-01 16:27 Hans de Goede
  2021-04-01 18:01 ` Andy Shevchenko
  2021-04-02 18:16 ` Andy Shevchenko
  0 siblings, 2 replies; 4+ messages in thread
From: Hans de Goede @ 2021-04-01 16:27 UTC (permalink / raw)
  To: Mika Westerberg, Andy Shevchenko, Bartosz Golaszewski, Linus Walleij
  Cc: Hans de Goede, linux-gpio, linux-acpi

Like some other Bay and Cherry Trail SoC based devices the Dell Venue
10 Pro 5055 has an embedded-controller which uses ACPI GPIO events to
report events instead of using the standard ACPI EC interface for this.

The EC interrupt is only used to report battery-level changes and
it keeps doing this while the system is suspended, causing the system
to not stay suspended.

Add an ignore-wake quirk for the GPIO pin used by the EC to fix the
spurious wakeups from suspend.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/gpio/gpiolib-acpi.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/gpio/gpiolib-acpi.c b/drivers/gpio/gpiolib-acpi.c
index 1aacd2a5a1fd..174839f3772f 100644
--- a/drivers/gpio/gpiolib-acpi.c
+++ b/drivers/gpio/gpiolib-acpi.c
@@ -1438,6 +1438,20 @@ static const struct dmi_system_id gpiolib_acpi_quirks[] __initconst = {
 			.no_edge_events_on_boot = true,
 		},
 	},
+	{
+		/*
+		 * The Dell Venue 10 Pro 5055, with Bay Trail SoC + TI PMIC uses an
+		 * external embedded-controller connected via I2C + an ACPI GPIO
+		 * event handler on INT33FFC:02 pin 12, causing spurious wakeups.
+		 */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "Venue 10 Pro 5055"),
+		},
+		.driver_data = &(struct acpi_gpiolib_dmi_quirk) {
+			.ignore_wake = "INT33FC:02@12",
+		},
+	},
 	{
 		/*
 		 * HP X2 10 models with Cherry Trail SoC + TI PMIC use an
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055
  2021-04-01 16:27 [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055 Hans de Goede
@ 2021-04-01 18:01 ` Andy Shevchenko
  2021-04-02 18:14   ` Andy Shevchenko
  2021-04-02 18:16 ` Andy Shevchenko
  1 sibling, 1 reply; 4+ messages in thread
From: Andy Shevchenko @ 2021-04-01 18:01 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Mika Westerberg, Bartosz Golaszewski, Linus Walleij, linux-gpio,
	linux-acpi

On Thu, Apr 01, 2021 at 06:27:40PM +0200, Hans de Goede wrote:
> Like some other Bay and Cherry Trail SoC based devices the Dell Venue
> 10 Pro 5055 has an embedded-controller which uses ACPI GPIO events to
> report events instead of using the standard ACPI EC interface for this.
> 
> The EC interrupt is only used to report battery-level changes and
> it keeps doing this while the system is suspended, causing the system
> to not stay suspended.
> 
> Add an ignore-wake quirk for the GPIO pin used by the EC to fix the
> spurious wakeups from suspend.

Fine by me,
Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

I have sent my PR to Bart few days ago and today he applied it.
So, since I'm not expecting much going on in this cycle, I assume
it's okay to go directly to Bart's tree.

> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  drivers/gpio/gpiolib-acpi.c | 14 ++++++++++++++
>  1 file changed, 14 insertions(+)
> 
> diff --git a/drivers/gpio/gpiolib-acpi.c b/drivers/gpio/gpiolib-acpi.c
> index 1aacd2a5a1fd..174839f3772f 100644
> --- a/drivers/gpio/gpiolib-acpi.c
> +++ b/drivers/gpio/gpiolib-acpi.c
> @@ -1438,6 +1438,20 @@ static const struct dmi_system_id gpiolib_acpi_quirks[] __initconst = {
>  			.no_edge_events_on_boot = true,
>  		},
>  	},
> +	{
> +		/*
> +		 * The Dell Venue 10 Pro 5055, with Bay Trail SoC + TI PMIC uses an
> +		 * external embedded-controller connected via I2C + an ACPI GPIO
> +		 * event handler on INT33FFC:02 pin 12, causing spurious wakeups.
> +		 */
> +		.matches = {
> +			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
> +			DMI_MATCH(DMI_PRODUCT_NAME, "Venue 10 Pro 5055"),
> +		},
> +		.driver_data = &(struct acpi_gpiolib_dmi_quirk) {
> +			.ignore_wake = "INT33FC:02@12",
> +		},
> +	},
>  	{
>  		/*
>  		 * HP X2 10 models with Cherry Trail SoC + TI PMIC use an
> -- 
> 2.30.2
> 

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055
  2021-04-01 18:01 ` Andy Shevchenko
@ 2021-04-02 18:14   ` Andy Shevchenko
  0 siblings, 0 replies; 4+ messages in thread
From: Andy Shevchenko @ 2021-04-02 18:14 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Mika Westerberg, Bartosz Golaszewski, Linus Walleij, linux-gpio,
	linux-acpi

On Thu, Apr 01, 2021 at 09:01:17PM +0300, Andy Shevchenko wrote:
> On Thu, Apr 01, 2021 at 06:27:40PM +0200, Hans de Goede wrote:
> > Like some other Bay and Cherry Trail SoC based devices the Dell Venue
> > 10 Pro 5055 has an embedded-controller which uses ACPI GPIO events to
> > report events instead of using the standard ACPI EC interface for this.
> > 
> > The EC interrupt is only used to report battery-level changes and
> > it keeps doing this while the system is suspended, causing the system
> > to not stay suspended.
> > 
> > Add an ignore-wake quirk for the GPIO pin used by the EC to fix the
> > spurious wakeups from suspend.
> 
> Fine by me,
> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> 
> I have sent my PR to Bart few days ago and today he applied it.
> So, since I'm not expecting much going on in this cycle, I assume
> it's okay to go directly to Bart's tree.

Bart, nevermind, I'll take it thru my tree. It seems we have two and perhaps
even three patches, so it will be easier to handle together.

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055
  2021-04-01 16:27 [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055 Hans de Goede
  2021-04-01 18:01 ` Andy Shevchenko
@ 2021-04-02 18:16 ` Andy Shevchenko
  1 sibling, 0 replies; 4+ messages in thread
From: Andy Shevchenko @ 2021-04-02 18:16 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Mika Westerberg, Bartosz Golaszewski, Linus Walleij, linux-gpio,
	linux-acpi

On Thu, Apr 01, 2021 at 06:27:40PM +0200, Hans de Goede wrote:
> Like some other Bay and Cherry Trail SoC based devices the Dell Venue
> 10 Pro 5055 has an embedded-controller which uses ACPI GPIO events to
> report events instead of using the standard ACPI EC interface for this.
> 
> The EC interrupt is only used to report battery-level changes and
> it keeps doing this while the system is suspended, causing the system
> to not stay suspended.
> 
> Add an ignore-wake quirk for the GPIO pin used by the EC to fix the
> spurious wakeups from suspend.

Pushed to my review and testing queue, thanks!

> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  drivers/gpio/gpiolib-acpi.c | 14 ++++++++++++++
>  1 file changed, 14 insertions(+)
> 
> diff --git a/drivers/gpio/gpiolib-acpi.c b/drivers/gpio/gpiolib-acpi.c
> index 1aacd2a5a1fd..174839f3772f 100644
> --- a/drivers/gpio/gpiolib-acpi.c
> +++ b/drivers/gpio/gpiolib-acpi.c
> @@ -1438,6 +1438,20 @@ static const struct dmi_system_id gpiolib_acpi_quirks[] __initconst = {
>  			.no_edge_events_on_boot = true,
>  		},
>  	},
> +	{
> +		/*
> +		 * The Dell Venue 10 Pro 5055, with Bay Trail SoC + TI PMIC uses an
> +		 * external embedded-controller connected via I2C + an ACPI GPIO
> +		 * event handler on INT33FFC:02 pin 12, causing spurious wakeups.
> +		 */
> +		.matches = {
> +			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
> +			DMI_MATCH(DMI_PRODUCT_NAME, "Venue 10 Pro 5055"),
> +		},
> +		.driver_data = &(struct acpi_gpiolib_dmi_quirk) {
> +			.ignore_wake = "INT33FC:02@12",
> +		},
> +	},
>  	{
>  		/*
>  		 * HP X2 10 models with Cherry Trail SoC + TI PMIC use an
> -- 
> 2.30.2
> 

-- 
With Best Regards,
Andy Shevchenko



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-04-02 18:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-01 16:27 [PATCH] gpiolib: acpi: Add quirk to ignore EC wakeups on Dell Venue 10 Pro 5055 Hans de Goede
2021-04-01 18:01 ` Andy Shevchenko
2021-04-02 18:14   ` Andy Shevchenko
2021-04-02 18:16 ` Andy Shevchenko

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.