Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751429Ab2KOWRo (ORCPT ); Thu, 15 Nov 2012 17:17:44 -0500 Received: from g4t0016.houston.hp.com ([15.201.24.19]:24365 "EHLO g4t0016.houston.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750740Ab2KOWRm (ORCPT ); Thu, 15 Nov 2012 17:17:42 -0500 Message-ID: <1353017366.12509.19.camel@misato.fc.hp.com> Subject: Re: [Patch v5 2/7] acpi,memory-hotplug: deal with eject request in hotplug queue From: Toshi Kani To: Wen Congyang Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-acpi@vger.kernel.org, Len Brown , "Rafael J. Wysocki" , Andrew Morton , Yasuaki Ishimatsu , Lai Jiangshan , Jiang Liu , KOSAKI Motohiro , Minchan Kim , Mel Gorman , David Rientjes , Konrad Rzeszutek Wilk , Jiang Liu , Benjamin Herrenschmidt , Paul Mackerras , Christoph Lameter Date: Thu, 15 Nov 2012 15:09:26 -0700 In-Reply-To: <1352962777-24407-3-git-send-email-wency@cn.fujitsu.com> References: <1352962777-24407-1-git-send-email-wency@cn.fujitsu.com> <1352962777-24407-3-git-send-email-wency@cn.fujitsu.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.4.4 (3.4.4-2.fc17) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1572 Lines: 40 On Thu, 2012-11-15 at 14:59 +0800, Wen Congyang wrote: > The memory device can be removed by 2 ways: > 1. send eject request by SCI > 2. echo 1 >/sys/bus/pci/devices/PNP0C80:XX/eject > > We handle the 1st case in the module acpi_memhotplug, and handle > the 2nd case in ACPI eject notification. This 2 events may happen > at the same time, so we may touch acpi_memory_device.res_list at > the same time. This patch reimplements memory-hotremove support > through an ACPI eject notification. Now the memory device is > offlined and hotremoved only in the function acpi_memory_device_remove() > which is protected by device_lock(). > > CC: David Rientjes > CC: Jiang Liu > CC: Len Brown > CC: Benjamin Herrenschmidt > CC: Paul Mackerras > CC: Christoph Lameter > Cc: Minchan Kim > CC: Andrew Morton > CC: KOSAKI Motohiro > CC: Yasuaki Ishimatsu > CC: Rafael J. Wysocki > CC: Konrad Rzeszutek Wilk > Signed-off-by: Wen Congyang Thanks for the update. It looks good. Reviewed-by: Toshi Kani -Toshi -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/