Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754109AbbG0Pc6 (ORCPT ); Mon, 27 Jul 2015 11:32:58 -0400 Received: from smtp.citrix.com ([66.165.176.89]:55810 "EHLO SMTP.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753332AbbG0Pc5 (ORCPT ); Mon, 27 Jul 2015 11:32:57 -0400 X-IronPort-AV: E=Sophos;i="5.15,554,1432598400"; d="scan'208";a="284759370" Message-ID: <55B64F1D.8090807@citrix.com> Date: Mon, 27 Jul 2015 16:32:45 +0100 From: David Vrabel User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.7.0 MIME-Version: 1.0 To: Mel Gorman CC: "linux-mm@kvack.org" , "linux-kernel@vger.kernel.org" Subject: vmemmap_verify() BUGs during memory hotplug (4.2-rc1 regression) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-DLP: MIA1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1260 Lines: 29 Mel, As of commit 8a942fdea560d4ac0e9d9fabcd5201ad20e0c382 (mm: meminit: make __early_pfn_to_nid SMP-safe and introduce meminit_pfn_in_nid) vmemmap_verify() will BUG_ON() during memory hotplug because of its use of early_pfn_to_nid(). Previously, it would have reported bogus (or failed to report valid) warnings. I believe this does not affect memory hotplug on most x86 systems because vmemmap_populate() would normally call vmemmap_populate_hugepages() which avoids calling vmemmap_verify() in the common case (no existing mappings covering the new area). I'm triggering the early_pfn_to_nid() BUG_ON() with the Xen balloon driver in a PV guest which will always call vmemmap_populate_basepages() (since Xen PV guests lack superpage support). Not really sure what the best way to resolve this is. Presumably vmmemmap_verify() needs to switch to using pfn_to_nid() after the initial initialization but there doesn't appear to be anything suitable to distinguish between the early and hotplug cases. David -- 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/