Browse Source

ACPI / memory-hotplug: call acpi_bus_trim() to remove memory device

The memory device has been ejected and powoffed, so we can call
acpi_bus_trim() to remove the memory device from acpi bus.

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Wen Congyang 12 years ago
parent
commit
54c4c7db6c
1 changed files with 2 additions and 1 deletions
  1. 2 1
      drivers/acpi/acpi_memhotplug.c

+ 2 - 1
drivers/acpi/acpi_memhotplug.c

@@ -401,8 +401,9 @@ static void acpi_memory_device_notify(acpi_handle handle, u32 event, void *data)
 		}
 
 		/*
-		 * TBD: Invoke acpi_bus_remove to cleanup data structures
+		 * Invoke acpi_bus_trim() to remove memory device
 		 */
+		acpi_bus_trim(device, 1);
 
 		/* _EJ0 succeeded; _OST is not necessary */
 		return;