linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: Odd suspend regression in 2.6.21-rc[123]
       [not found] ` <45F24DCE.8060902@madrabbit.org>
@ 2007-03-12 15:42   ` Len Brown
  2007-03-12 16:59     ` ACPI: resolve GPE immediate wakeup regression Ray Lee
  0 siblings, 1 reply; 3+ messages in thread
From: Len Brown @ 2007-03-12 15:42 UTC (permalink / raw)
  To: Ray Lee
  Cc: Adrian Bunk, Linus Torvalds, LKML, Rafael J. Wysocki,
	Alexey Starikovskiy, Vladimir Lebedev, linux-acpi

On Saturday 10 March 2007 01:18, Ray Lee wrote:
> Ray Lee wrote:
> > In 2.6.21-rc1,2,3, my laptop will fully suspend to ram, but then
> > *immediately* resumes back from suspension. (It resumes just fine, as well.)
> [...]
> > HP/Compaq NX6125 system, AMD64, dmesg attached.
> 
> hg bisect found the below patch as the culprit, and reverting it does
> fix the regression. It's supposed to address "sometime ac/battery update
> stops after resume from disk." This thread:
> http://lkml.org/lkml/2007/2/24/111 appears to talk about the same issue,
> and therefore it may be solved without the below patch, so perhaps we
> can all be happy.
> 
> Regardless, I think my laptop no longer being able to go into S3 sleep
> is a bit more important than someone else's laptop merely not showing
> the correct AC status :-).
> 
> Please revert. (git patch id ed41dab90eb40ac4911e60406bc653661f0e4ce1)

I'd rather not break the Acer, if possible.

Ray, Please test the incremental patch below.

---
Subject: ACPI: resolve GPE immediate wakeup regression
From: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>

Removing disabling of GPEs from enter_sleep function causes regression on nx6125.
Doing disable_all_gpes both in prepare to sleep and in enter sleep resolves regression,
while still fixes Acer notebooks.

Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
---

 drivers/acpi/hardware/hwsleep.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/drivers/acpi/hardware/hwsleep.c b/drivers/acpi/hardware/hwsleep.c
index 8fa9312..c84b1fa 100644
--- a/drivers/acpi/hardware/hwsleep.c
+++ b/drivers/acpi/hardware/hwsleep.c
@@ -300,6 +300,11 @@ acpi_status asmlinkage acpi_enter_sleep_state(u8 sleep_state)
 	/*
 	 * 2) Enable all wakeup GPEs
 	 */
+	status = acpi_hw_disable_all_gpes();
+	if (ACPI_FAILURE(status)) {
+		return_ACPI_STATUS(status);
+	}
+
 	acpi_gbl_system_awake_and_running = FALSE;
 
 	status = acpi_hw_enable_all_wakeup_gpes();

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

* ACPI: resolve GPE immediate wakeup regression
  2007-03-12 15:42   ` Odd suspend regression in 2.6.21-rc[123] Len Brown
@ 2007-03-12 16:59     ` Ray Lee
  2007-03-12 17:06       ` Len Brown
  0 siblings, 1 reply; 3+ messages in thread
From: Ray Lee @ 2007-03-12 16:59 UTC (permalink / raw)
  To: Len Brown
  Cc: Adrian Bunk, Linus Torvalds, LKML, Rafael J. Wysocki,
	Alexey Starikovskiy, Vladimir Lebedev, linux-acpi

Len Brown wrote:
> On Saturday 10 March 2007 01:18, Ray Lee wrote:
>> Ray Lee wrote:
>>> In 2.6.21-rc1,2,3, my laptop will fully suspend to ram, but then
>>> *immediately* resumes back from suspension. (It resumes just fine, as well.)
>> [...]
>>> HP/Compaq NX6125 system, AMD64, dmesg attached.
> 
> I'd rather not break the Acer, if possible.
> 
> Ray, Please test the incremental patch below.

Tested and Alexey's patch (copied below) fixes the problem. I added a
signed-off-by just in case; feel free to yank it if inappropriate.
Regardless, please apply.

Thanks Len, Alexey.

Ray
---
Subject: ACPI: resolve GPE immediate wakeup regression
From: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>

Removing disabling of GPEs from enter_sleep function causes regression
on nx6125.
Doing disable_all_gpes both in prepare to sleep and in enter sleep
resolves regression,
while still fixes Acer notebooks.

Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Signed-off-by: Ray Lee <ray-lk@madrabbit.org>
---

 drivers/acpi/hardware/hwsleep.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/drivers/acpi/hardware/hwsleep.c
b/drivers/acpi/hardware/hwsleep.c
index 8fa9312..c84b1fa 100644
--- a/drivers/acpi/hardware/hwsleep.c
+++ b/drivers/acpi/hardware/hwsleep.c
@@ -300,6 +300,11 @@ acpi_status asmlinkage acpi_enter_sleep_state(u8
sleep_state)
 	/*
 	 * 2) Enable all wakeup GPEs
 	 */
+	status = acpi_hw_disable_all_gpes();
+	if (ACPI_FAILURE(status)) {
+		return_ACPI_STATUS(status);
+	}
+
 	acpi_gbl_system_awake_and_running = FALSE;

 	status = acpi_hw_enable_all_wakeup_gpes();



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

* Re: ACPI: resolve GPE immediate wakeup regression
  2007-03-12 16:59     ` ACPI: resolve GPE immediate wakeup regression Ray Lee
@ 2007-03-12 17:06       ` Len Brown
  0 siblings, 0 replies; 3+ messages in thread
From: Len Brown @ 2007-03-12 17:06 UTC (permalink / raw)
  To: Ray Lee
  Cc: Adrian Bunk, Linus Torvalds, LKML, Rafael J. Wysocki,
	Alexey Starikovskiy, Vladimir Lebedev, linux-acpi

On Monday 12 March 2007 12:59, Ray Lee wrote:
> Len Brown wrote:
> > On Saturday 10 March 2007 01:18, Ray Lee wrote:
> >> Ray Lee wrote:
> >>> In 2.6.21-rc1,2,3, my laptop will fully suspend to ram, but then
> >>> *immediately* resumes back from suspension. (It resumes just fine, as well.)
> >> [...]
> >>> HP/Compaq NX6125 system, AMD64, dmesg attached.
> > 
> > I'd rather not break the Acer, if possible.
> > 
> > Ray, Please test the incremental patch below.
> 
> Tested and Alexey's patch (copied below) fixes the problem. I added a
> signed-off-by just in case; feel free to yank it if inappropriate.
> Regardless, please apply.
> 
> Thanks Len, Alexey.

Thanks for testing Ray,
I'll apply this one.

-Len

> ---
> Subject: ACPI: resolve GPE immediate wakeup regression
> From: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
> 
> Removing disabling of GPEs from enter_sleep function causes regression
> on nx6125.
> Doing disable_all_gpes both in prepare to sleep and in enter sleep
> resolves regression,
> while still fixes Acer notebooks.
> 
> Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
> Signed-off-by: Len Brown <len.brown@intel.com>
> Signed-off-by: Ray Lee <ray-lk@madrabbit.org>
> ---
> 
>  drivers/acpi/hardware/hwsleep.c |    5 +++++
>  1 files changed, 5 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/acpi/hardware/hwsleep.c
> b/drivers/acpi/hardware/hwsleep.c
> index 8fa9312..c84b1fa 100644
> --- a/drivers/acpi/hardware/hwsleep.c
> +++ b/drivers/acpi/hardware/hwsleep.c
> @@ -300,6 +300,11 @@ acpi_status asmlinkage acpi_enter_sleep_state(u8
> sleep_state)
>  	/*
>  	 * 2) Enable all wakeup GPEs
>  	 */
> +	status = acpi_hw_disable_all_gpes();
> +	if (ACPI_FAILURE(status)) {
> +		return_ACPI_STATUS(status);
> +	}
> +
>  	acpi_gbl_system_awake_and_running = FALSE;
> 
>  	status = acpi_hw_enable_all_wakeup_gpes();
> 
> 
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 

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

end of thread, other threads:[~2007-03-12 17:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <45F0C018.2020409@madrabbit.org>
     [not found] ` <45F24DCE.8060902@madrabbit.org>
2007-03-12 15:42   ` Odd suspend regression in 2.6.21-rc[123] Len Brown
2007-03-12 16:59     ` ACPI: resolve GPE immediate wakeup regression Ray Lee
2007-03-12 17:06       ` Len Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).