From: Wen Congyang Date: Wed, 14 Nov 2012 23:22:27 +0000 (+0100) Subject: ACPI / memory-hotplug: call acpi_bus_trim() to remove memory device X-Git-Tag: firefly_0821_release~3680^2~1523^2~1^2~25 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=54c4c7db6cb94d7d1217df6d7fca6847c61744ab;p=firefly-linux-kernel-4.4.55.git 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 Signed-off-by: Rafael J. Wysocki --- diff --git a/drivers/acpi/acpi_memhotplug.c b/drivers/acpi/acpi_memhotplug.c index 24c807f96636..1e90e8f01007 100644 --- a/drivers/acpi/acpi_memhotplug.c +++ b/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;