Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3574698imm; Thu, 17 May 2018 10:54:09 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoYnnODD1WfNMSTLK0oWYYNdhmjE+i26xlW0pN/DRhy7dvudo+KpBrMaZUE617YXeKbb4KS X-Received: by 2002:a17:902:7582:: with SMTP id j2-v6mr6091234pll.65.1526579649525; Thu, 17 May 2018 10:54:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526579649; cv=none; d=google.com; s=arc-20160816; b=Ic1XGx65F08oXlNbjfHkJQvH2kjpu+IeLRw6ojdWzqRw5dtNF/HcGkOsISWgku8Wtv eY6WtOqCb2lYlnR20+ZFjRafQCr+HpI/y/iqyLi5OC1XlUIqc09Waulq2Y4iKjb4Z8ij bgnc7aSLt8sK8qheFrXGbTJRTzZCW6vUVT8vdH+WgiR7trBseG4wNCo53H05YbeL+Ck/ ATUU6UV8SdK1D19AYqrU+BVecvz1JTe2M0DqrDyOUnuwAjzkWRnjidV+F6QTyYd1DjCd +yv/K+CdfwkeU3zVB74iF2qsPah/27aBszx/iRr4Ez+AhVHuhVdOH1Hp2vaCzP6GbxQi tWvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=2+q9EgEue7DyHH6BUSQ5ciP8Qr4HWBAuS9nbR+NLLMk=; b=H/mVFjSagiMhZzM3Vtzf9eCUFPKpO8roy5iGfP8LEoIRh424ULYYgYYWR1y5AYYTEE YIrDXSY+lfqc6XSq76QKNOY0kSMnFrzFk/42ZAkyrgjOmcTMfU0hnArNYkaknk4mBhoN ChnrhYVfyWK6cXCZiOQdfDNs965tiV8acjlsQR8ff+0vkA9EvcK9qolBHY9Z/LNSknAK NQ9SFmLhwQeXEXn9odJdq+klBHfMRVEVbC71yu+K0tAp3YeA1UKDIkcdJdRcxM2vxkjQ WQTX1KHqm5r+dPvGj3b9FzvNDJm+POGzYXikyQY/YbtBFXygbY9dHfdYWV3us/NyTnYK BikQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x4-v6si4420681pgr.301.2018.05.17.10.53.54; Thu, 17 May 2018 10:54:09 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752100AbeEQRxj (ORCPT + 99 others); Thu, 17 May 2018 13:53:39 -0400 Received: from mail-oi0-f67.google.com ([209.85.218.67]:46072 "EHLO mail-oi0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751293AbeEQRxi (ORCPT ); Thu, 17 May 2018 13:53:38 -0400 Received: by mail-oi0-f67.google.com with SMTP id b130-v6so4762770oif.12 for ; Thu, 17 May 2018 10:53:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=2+q9EgEue7DyHH6BUSQ5ciP8Qr4HWBAuS9nbR+NLLMk=; b=OCFwjFJoquuFFVm6BHKM+nrFptaQ188WyPrhuad2gjWHy1MIR1ajxz0Gc9vsGrLWNt pQHKbDy+V/OVSGYdZ8hl7O85WqkY2jhilfPEduIKoqf30vl3HjcUC3RdHUev8xxxQLpO acVvknxzfZc/ZO15GpwNFtXEambrcUuPkXQptH/oGcgubPQwPjvR/rBL45EFY57ObyzM x1iHrrVdWudtve8z++dyC3CN8FlkGXaAewHYTO5yRpApeUHp6nyp8/eitOVuypVKwaVj 8mVh7Wf1Gn7zmvpvjRLpumHzqdCuS7UG8ZYYYnTKTazzGeiocu/7q8WLZT78lq4Olq7E XCEA== X-Gm-Message-State: ALKqPwcMZb2NnVkAIamNRBy2fZxePN0RRNM3EuSGAVnrOEe7LER90C/g H95JSiDw5h+oQzB02ysCe2LiUMOhZtY= X-Received: by 2002:a54:4406:: with SMTP id k6-v6mr3555514oiw.162.1526579616772; Thu, 17 May 2018 10:53:36 -0700 (PDT) Received: from ?IPv6:2601:602:9802:a8dc::d2dd? ([2601:602:9802:a8dc::d2dd]) by smtp.gmail.com with ESMTPSA id g98-v6sm2808256otg.64.2018.05.17.10.53.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 17 May 2018 10:53:35 -0700 (PDT) Subject: Re: [PATCH] Revert "mm/cma: manage the memory of the CMA area by using the ZONE_MOVABLE" To: Michal Hocko , Joonsoo Kim , =?UTF-8?B?VmlsbGUgU3lyasOkbMOk?= Cc: "Aneesh Kumar K . V" , Tony Lindgren , Vlastimil Babka , Johannes Weiner , Laura Abbott , Marek Szyprowski , Mel Gorman , Michal Nazarewicz , Minchan Kim , Rik van Riel , Russell King , Will Deacon , Andrew Morton , Linus Torvalds , linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20180517125959.8095-1-ville.syrjala@linux.intel.com> <20180517132109.GU12670@dhcp22.suse.cz> <20180517133629.GH23723@intel.com> <20180517135832.GI23723@intel.com> <20180517164947.GV12670@dhcp22.suse.cz> <20180517170816.GW12670@dhcp22.suse.cz> From: Laura Abbott Message-ID: Date: Thu, 17 May 2018 10:53:32 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180517170816.GW12670@dhcp22.suse.cz> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/17/2018 10:08 AM, Michal Hocko wrote: > On Thu 17-05-18 18:49:47, Michal Hocko wrote: >> On Thu 17-05-18 16:58:32, Ville Syrjälä wrote: >>> On Thu, May 17, 2018 at 04:36:29PM +0300, Ville Syrjälä wrote: >>>> On Thu, May 17, 2018 at 03:21:09PM +0200, Michal Hocko wrote: >>>>> On Thu 17-05-18 15:59:59, Ville Syrjala wrote: >>>>>> From: Ville Syrjälä >>>>>> >>>>>> This reverts commit bad8c6c0b1144694ecb0bc5629ede9b8b578b86e. >>>>>> >>>>>> Make x86 with HIGHMEM=y and CMA=y boot again. >>>>> >>>>> Is there any bug report with some more details? It is much more >>>>> preferable to fix the issue rather than to revert the whole thing >>>>> right away. >>>> >>>> The machine I have in front of me right now didn't give me anything. >>>> Black screen, and netconsole was silent. No serial port on this >>>> machine unfortunately. >>> >>> Booted on another machine with serial: >> >> Could you provide your .config please? >> >> [...] >>> [ 0.000000] cma: Reserved 4 MiB at 0x0000000037000000 >> [...] >>> [ 0.000000] BUG: Bad page state in process swapper pfn:377fe >>> [ 0.000000] page:f53effc0 count:0 mapcount:-127 mapping:00000000 index:0x0 >> >> OK, so this looks the be the source of the problem. -128 would be a >> buddy page but I do not see anything that would set the counter to -127 >> and the real map count updates shouldn't really happen that early. >> >> Maybe CONFIG_DEBUG_VM and CONFIG_DEBUG_HIGHMEM will tell us more. > > Looking closer, I _think_ that the bug is in set_highmem_pages_init->is_highmem > and zone_movable_is_highmem might force CMA pages in the zone movable to > be initialized as highmem. And that sounds supicious to me. Joonsoo? > For a point of reference, arm with this configuration doesn't hit this bug because highmem pages are freed via the memblock interface only instead of iterating through each zone. It looks like the x86 highmem code assumes only a single highmem zone and/or it's disjoint? Thanks, Laura