Thread (6 messages) 6 messages, 5 authors, 2007-08-23

Re: [PATCH] hook ACPI _PSx method to IDE power on/off

From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Date: 2007-08-04 20:16:01
Also in: linux-acpi

On Thursday 02 August 2007, Shaohua Li wrote:
ACPI spec defines the sequence of IDE power on/off:
Powering down:
	Call _GTM.
	Power down drive (calls _PS3 method and turns off power planes).
Powering up:
	Power up drive (calls _PS0 method if present and turns on power planes).
	Call _STM passing info from _GTM (possibly modified), with ID data from
	each drive.
	Initialize the channel.
	May modify the results of _GTF.
	For each drive:
		Call _GTF.
		Execute task file (possibly modified).
This patch adds the missed _PS0/_PS3 methods call.

Signed-off-by: Shaohua Li <redacted>
applied, thanks

Len, are you OK with the ACPI part of the patch (below)?
quoted hunk ↗ jump to hunk
Index: linux/drivers/acpi/bus.c
===================================================================
--- linux.orig/drivers/acpi/bus.c	2007-08-02 13:35:06.000000000 +0800
+++ linux/drivers/acpi/bus.c	2007-08-02 13:56:56.000000000 +0800
@@ -262,10 +262,12 @@ int acpi_bus_set_power(acpi_handle handl
 		printk(KERN_WARNING PREFIX
 			      "Transitioning device [%s] to D%d\n",
 			      device->pnp.bus_id, state);
-	else
+	else {
+		device->power.state = state;
 		ACPI_DEBUG_PRINT((ACPI_DB_INFO,
 				  "Device [%s] transitioned to D%d\n",
 				  device->pnp.bus_id, state));
+	}
 
 	return result;
 }
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help