ACPI: Clear GPE before disabling it
PATCH 1/13 ACPI: Clear GPE before disabling it
From: William Morrow <[email protected]>
On some BIOSen, the GPE bit will remain set even if it is disabled, resulting in a interrupt storm. This patch clears the bit before disabling it.
---
drivers/acpi/events/evgpe.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)
drivers/acpi/events/evgpe.c renamed from drivers/acpi/events/evgpe.c~acpi-clear-gpe-before-disabling-it +13 -1
@@ -677,10 +677,22 @@ acpi_ev_gpe_dispatch(struct acpi_gpe_evecase ACPI_GPE_DISPATCH_METHOD :/* -* Disable GPE, so it doesn't keep firing before the method has a +* Clear GPE, so it doesn't keep firing before the method has a * chance to run. */ + status =acpi_hw_clear_gpe (gpe_event_info); +if (ACPI_FAILURE (status)) { +ACPI_EXCEPTION ((AE_INFO , status, +"Unable to clear GPE[%2X]" , + gpe_number)); +return_UINT32 (ACPI_INTERRUPT_NOT_HANDLED ); + } +/* +* Disable GPE, so it doesn't keep happen again. +*/ + status =acpi_ev_disable_gpe (gpe_event_info); +if (ACPI_FAILURE (status)) { ACPI_EXCEPTION((AE_INFO, status, "Unable to disable GPE[%2X]",
_
Len Brown
reviewerWilliam,
Please test if this is still necessary when you are running ACPICA 20061109.
You can get that release in several ways:
A plain patch on top of 2.6.19:
http://ftp.kernel.org/pub/linux/kernel/people/lenb/acpi/patches/test/2.6.19/acpi-test-20061109-2.6.19.diff.gz
or pull it from git:git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6.git acpica
In both cases, you'll result in a 2.6.19 base plus only the ACPICA update.
thanks,
-Len
Quoted 50 lines · On Monday 04 December 2006 17:49, [email protected] wrote:
From: William Morrow <[email protected]>
On some BIOSen, the GPE bit will remain set even if it is disabled, resulting in a interrupt storm. This patch clears the bit before disabling it.
Signed-off-by William Morrow <[email protected]>Signed-off-by Jordan Crouse <[email protected]>Cc "Yu, Luming" <[email protected]>Cc "Brown, Len" <[email protected]>Cc "Moore, Robert" <[email protected]>Signed-off-by Andrew Morton <[email protected]>---
drivers/acpi/events/evgpe.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)diff -puN
drivers/acpi/events/evgpe.c~acpi-clear-gpe-before-disabling-itdrivers/acpi/events/evgpe.c--- a/drivers/acpi/events/evgpe.c~acpi-clear-gpe-before-disabling-it +++a/drivers/acpi/events/evgpe.cdrivers/acpi/events/evgpe.c renamed from drivers/acpi/events/evgpe.c~acpi-clear-gpe-before-disabling-it +13
-1@@ -677,10 +677,22 @@ acpi_ev_gpe_dispatch(struct acpi_gpe_evecase ACPI_GPE_DISPATCH_METHOD :/* -* Disable GPE, so it doesn't keep firing before the method has a +* Clear GPE, so it doesn't keep firing before the method has a * chance to run. */ + status =acpi_hw_clear_gpe (gpe_event_info); +if (ACPI_FAILURE (status)) { +ACPI_EXCEPTION ((AE_INFO , status, +"Unable to clear GPE[%2X]" , + gpe_number)); +return_UINT32 (ACPI_INTERRUPT_NOT_HANDLED ); + } +/* +* Disable GPE, so it doesn't keep happen again. +*/ + status =acpi_ev_disable_gpe (gpe_event_info); +if (ACPI_FAILURE (status)) { ACPI_EXCEPTION((AE_INFO, status, "Unable to disable GPE[%2X]",_
-
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html