patch-2.4.23 linux-2.4.23/drivers/acpi/ec.c

Next file: linux-2.4.23/drivers/acpi/events/evgpe.c
Previous file: linux-2.4.23/drivers/acpi/dispatcher/dswstate.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.22/drivers/acpi/ec.c linux-2.4.23/drivers/acpi/ec.c
@@ -33,7 +33,7 @@
 #include <asm/io.h>
 #include <acpi/acpi_bus.h>
 #include <acpi/acpi_drivers.h>
-
+#include <acpi/actypes.h>
 
 #define _COMPONENT		ACPI_EC_COMPONENT
 ACPI_MODULE_NAME		("acpi_ec")
@@ -408,7 +408,10 @@
 	 * The EC object is in the handler context and is needed
 	 * when calling the acpi_ec_space_handler.
 	 */
-	*return_context = handler_context;
+	if(function == ACPI_REGION_DEACTIVATE) 
+		*return_context = NULL;
+	else 
+		*return_context = handler_context;
 
 	return AE_OK;
 }

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)