Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp5516531pxb; Mon, 7 Feb 2022 03:59:24 -0800 (PST) X-Google-Smtp-Source: ABdhPJyhB6UQMfuDUYZFIHGsm1RfxkXJpzxLTZ68MSdbrchIihK1Zq7r7NSlTgJSbJk+YC9XGS7A X-Received: by 2002:a05:6402:2549:: with SMTP id l9mr13526513edb.129.1644235164687; Mon, 07 Feb 2022 03:59:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644235164; cv=none; d=google.com; s=arc-20160816; b=nlB1fqUMq3ulYDuh8OHrVtWNz6sX9W9XAbsyx8eF7j0EI4xIN/cVlAfWjosIoJp/DF qJVygp+rDYbECi0AIFNsnd2K2J06ZiMLQxgLlW3ymteJNvZTHDDG0tPxA4ACI0xELYLj 8G9qhGlBUouX/PjnGwHbMZDFJBl2iJgpSbf+rhewnnkxX3hzVAY3Uw4iqDDeQP1VcmBL mVjGKC8ndPEh3rCb0W9hD8dsb1CJpP36gXu86Ddflydb9oweqev7cp+exYFJ+9b165Sj FhlarL9Gz+/zeoDW48qVux8zV4Jm1MuCe+MLAB6UC9IDKmhr1oDVp3szsk/9B1ae4rNk VoJQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=kom0rnZXZn47YFlPMfS28zjK6FLYKt/ZTTdoLV2yT4Q=; b=FuN6FNt/bBJwqeZKMJOlPKmFdUQSb6MKnbeMVtwzpjFDZHvQTsVXvOj5tTmRLOu8bZ VueG6ik1ECM1uoeuXYzX1EduVgrzSkXvXzbuAElXgwBznTDaBAc655o5xZjviKY7leRS NmwFNfD/jrNoF9D01gBn4DxXc2binkHl6Pa6uHSwvYs++3+m4zeZun+xauoxndGG0vsE TMvzKFw0iUEBNBn7lSUIOYR1vOiE4GUgfHLzE4cIoKDOaH9kjY5u9AqiD3T2HWs+WcVH UdliAg6raMoRZAv1wba+p1/X/1V5vc+htkoOZ1WAtRx+nJbj+LpBBYPZYLtnOV+w/2lu +5eA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Tp67YNDY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gn21si8080341ejc.748.2022.02.07.03.58.55; Mon, 07 Feb 2022 03:59:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Tp67YNDY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1381540AbiBFCL0 (ORCPT + 99 others); Sat, 5 Feb 2022 21:11:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40410 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232151AbiBFCLZ (ORCPT ); Sat, 5 Feb 2022 21:11:25 -0500 Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C0A43C043186 for ; Sat, 5 Feb 2022 18:11:24 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id d10so31456360eje.10 for ; Sat, 05 Feb 2022 18:11:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:reply-to:references:mime-version :content-disposition:in-reply-to:user-agent; bh=kom0rnZXZn47YFlPMfS28zjK6FLYKt/ZTTdoLV2yT4Q=; b=Tp67YNDYO4k7ScZNzTnDsX9iV0SicTghOQd6D5OO4tZ0aI0A1+ky8payE32xq/VnCe HFQd+9wiJ00MEOVBe9k54EHI/diQp9Tjq+V11YW8XI15zYv0xe7viWUfJlGtkNMMoVjj OnCn7XCHrV4t5K1nadLISMRBUXyHirD8loWAjjcoLSe5izAlbtQRbO7pamPqb9BQxF9o C3vLuRAlfAK71yJQXC1F19fFiuIYorig69CyNrATmF2vFXIsQYgo52WY4gkLEY6xowQ8 SKirnPMYoa34eVjaNiZug804bQSyNbJJsARgeQ7BCR6kk9pXjF0luaukaqp51zBwB5uw ziVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:reply-to :references:mime-version:content-disposition:in-reply-to:user-agent; bh=kom0rnZXZn47YFlPMfS28zjK6FLYKt/ZTTdoLV2yT4Q=; b=lbb6lJWHTeZCAYjvIwIFr45etnfF6WDew/rTVPKdUU7z7DcGDWYqicIQZ8xyYz6uV0 JnXgWzTLyCZpF6Dr1FkRd84CJIP1BPNC8+fF/7hKPxQL9OoWEV8cJfvX9mcjZvR/0mK2 llTKMDoA46u0Qqw6uCTIbnbgYUPfAJidyd8IzrmST6YI3IFIkAardOCYrWrmQWxJgFnV IPNswEt3EjRoWDb0EwE6BReoAZZSiEj1cGY8F1U46DHFVKGiWJh7psuwrkd5nXjQCquS /RiffyvHc6CfpHtAODn/w/gnEpvj6+BRO86bSYnljwzKMFw2A9T5BZXfoCAiS3FqcUWO nh3Q== X-Gm-Message-State: AOAM530xZf7oDleNNHDxiWj4NhVrFicZXHieoj91AcuH1dFheRZsrwKH yepjoJG3kvs50bzjkgCxSqY= X-Received: by 2002:a17:907:3f87:: with SMTP id hr7mr5173101ejc.586.1644113483316; Sat, 05 Feb 2022 18:11:23 -0800 (PST) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id p13sm2128231ejx.191.2022.02.05.18.11.22 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 05 Feb 2022 18:11:22 -0800 (PST) Date: Sun, 6 Feb 2022 02:11:22 +0000 From: Wei Yang To: David Hildenbrand Cc: Wei Yang , akpm@linux-foundation.org, mhocko@suse.com, mgorman@techsingularity.net, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/page_alloc: add zone to zonelist if populated Message-ID: <20220206021122.luaihnjz3vhqwxax@master> Reply-To: Wei Yang References: <20220203020022.3044-1-richard.weiyang@gmail.com> <530d1ca4-6e05-b237-e0a9-c43d61767c4d@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <530d1ca4-6e05-b237-e0a9-c43d61767c4d@redhat.com> User-Agent: NeoMutt/20170113 (1.7.2) X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 03, 2022 at 10:25:51AM +0100, David Hildenbrand wrote: >On 03.02.22 03:00, Wei Yang wrote: >> During memory hotplug, when online/offline a zone, we need to rebuild >> the zonelist for all nodes. Current behavior would lose a valid zone in >> zonelist since only pick up managed_zone. >> >> There are two cases for a zone with memory but still !managed. >> >> * all pages were allocated via memblock >> * all pages were taken by ballooning / virtio-mem >> >> This state maybe temporary, since both of them may release some memory. >> Then it end up with a managed zone not in zonelist. >> >> This is introduced in 'commit 6aa303defb74 ("mm, vmscan: only allocate >> and reclaim from zones with pages managed by the buddy allocator")'. >> This patch restore the behavior. >> >> Signed-off-by: Wei Yang >> CC: Mel Gorman >> CC: David Hildenbrand >> Fixes: 6aa303defb74 ("mm, vmscan: only allocate and reclaim from zones with pages managed by the buddy allocator") > >That commit mentions that there used to be some ppc64 cases with fadump >where it might have been a real problem. Unfortunately, that commit >doesn't really tell what the performance implications are. > It mentioned a 100% CPU usage by commit 1d82de618ddd. Currently I don't find which part introduced this and how it is fixed. >We'd have to know how many "permanent memblock" allocations we have, >that can never get freed. > For the case in that commit, the memory are reserved for crash kernel. I am afraid this never get freed. But for all the cases, I am not sure. -- Wei Yang Help you, Help me