Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757414Ab2FQCUO (ORCPT ); Sat, 16 Jun 2012 22:20:14 -0400 Received: from mail-pz0-f46.google.com ([209.85.210.46]:60852 "EHLO mail-pz0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756565Ab2FQCUM (ORCPT ); Sat, 16 Jun 2012 22:20:12 -0400 Date: Sat, 16 Jun 2012 19:20:09 -0700 (PDT) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Jiang Liu cc: Mel Gorman , KOSAKI Motohiro , KAMEZAWA Hiroyuki , Andrew Morton , Minchan Kim , Hugh Dickins , Keping Chen , Tony Luck , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Xishi Qiu , Jiang Liu Subject: Re: [PATCH] memory hotplug: fix invalid memory access caused by stale kswapd pointer In-Reply-To: <1339645491-5656-1-git-send-email-jiang.liu@huawei.com> Message-ID: References: <1339645491-5656-1-git-send-email-jiang.liu@huawei.com> User-Agent: Alpine 2.00 (DEB 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 857 Lines: 18 On Thu, 14 Jun 2012, Jiang Liu wrote: > Function kswapd_stop() will be called to destroy the kswapd work thread > when all memory of a NUMA node has been offlined. But kswapd_stop() only > terminates the work thread without resetting NODE_DATA(nid)->kswapd to NULL. > The stale pointer will prevent kswapd_run() from creating a new work thread > when adding memory to the memory-less NUMA node again. Eventually the stale > pointer may cause invalid memory access. > > Signed-off-by: Xishi Qiu > Signed-off-by: Jiang Liu Acked-by: David Rientjes -- 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/