From patchwork Wed Jun 19 01:06:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yang X-Patchwork-Id: 13703299 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 28786C2BA18 for ; Wed, 19 Jun 2024 01:06:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 053336B0361; Tue, 18 Jun 2024 21:06:28 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 002656B0363; Tue, 18 Jun 2024 21:06:27 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DF2436B0364; Tue, 18 Jun 2024 21:06:27 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id B0C9E6B0361 for ; Tue, 18 Jun 2024 21:06:27 -0400 (EDT) Received: from smtpin09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 15D1DA151C for ; Wed, 19 Jun 2024 01:06:27 +0000 (UTC) X-FDA: 82245847614.09.7596D23 Received: from mail-lf1-f41.google.com (mail-lf1-f41.google.com [209.85.167.41]) by imf21.hostedemail.com (Postfix) with ESMTP id 6B3B61C0010 for ; Wed, 19 Jun 2024 01:06:25 +0000 (UTC) Authentication-Results: imf21.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b="hv/Y8AIT"; spf=pass (imf21.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.167.41 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1718759175; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references:dkim-signature; bh=uNxYYQKq4nBGWdxowSvovRqaTORnXc/r6W1XqFHApm8=; b=5ygOTL5+jh3bd7HRFsBhiN5rPllUuoI24ZnftOjz8m9/77PLI7c3lIJ0Lgh0TgpNL8ZQ8m hNg+3ArjMZvdQ92nkRYV14u/i3zK0JxCp7RY0Bzo1w4lR0+ni8xfrxF3VGGMgEiY3o52O9 O/WGRjR5rLO7xXoJEfxpx+DiZMBwOk0= ARC-Authentication-Results: i=1; imf21.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b="hv/Y8AIT"; spf=pass (imf21.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.167.41 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1718759175; a=rsa-sha256; cv=none; b=Fnqg4xsMvnW4Ehez6a6OQbHYu0I1DMNObxQn1z9CCpm8dbKPbCmUFVmFAyK87tpDBkAsTW 6fxe3YxTlhkviIGFtcbXVUE6qGWDtOlI17XUf3m9EOlskWJkwuUjj4V7YwdQAWG5izUpvD iy5MrJEiU0aHfh6G2D3qa00IV+35M2E= Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-52bc27cfb14so7410602e87.0 for ; Tue, 18 Jun 2024 18:06:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718759183; x=1719363983; darn=kvack.org; h=message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=uNxYYQKq4nBGWdxowSvovRqaTORnXc/r6W1XqFHApm8=; b=hv/Y8AITzrVoVEMaBANXVE/pJ/HOs8kzej9gtYGk2fimW37nfMzAyrKjIDJxdIvoG8 FW4pz/Bjfx10qb5+cm3itXPlyFY+gPZkggeq7bmX7MpmRo7TboJJWBG2KceGaeJ5wBQY XBX4+H5pW4AhAS98HsT2qEmtft0wjK2YP6z5Wo4fI6g6lmHcSnAiR8uJ2cIcphc5UsrM Cj6a6P7Nl6UWa5RYlE+xWgfvBsc5r/7vj4GidqYC8FbREsT7Xfp/ihBzVWLEt/MtKSVi dfVybA37VrWSwhq0pRcoIZzXs3ipB4MxqJqBZ+4JiKV6X2p+flnWaROZgviIjmpG4jRj BrGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718759183; x=1719363983; h=message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uNxYYQKq4nBGWdxowSvovRqaTORnXc/r6W1XqFHApm8=; b=BDj4lGuqlSJjpqa8sVWKDo76Cpu2rOXIvu8waU+FBWFl7giE8zqPk2HYNQoOr2BnTt NhvuFQQCZMI/0heJgMYuKl4S96XHiajGcvsSV1QA0b/DYRru3XRKCAmg2SyNu514lepg J6kSrhqQ2Dsr4vUQAQTTNw0wQ5G8f7TSezRxmE+BGUKPpFAh/xNABxu/gz+cDCDODf5W EFc2bLYawqW4bc/veVDhD7obupe1DdIIeRjFlLEu61KdM6ScLtPbLGSjCzzELBuvYlBr fdA6YXuqV/a77aVioUzkt/Vw5GlePxl32EZVSfP9Qirm6nmo2TR5Xv+KPygY80ueKwMT bXzA== X-Gm-Message-State: AOJu0Yxv1+KEzWWPehUZ+8+BHO7PW53Rh/ndLe9V0YAeoxjpKRTgXTz/ x8YulLYlfY+qyfK7NC00Rf96A9U1E3yrXlnV+ADlWfHA9fDqf4wc X-Google-Smtp-Source: AGHT+IEz7fcI4jWolKFLj3H0NfWKG62R/1Zxchw/kpmOd4M7/TQpL6gXQVmamS2n/HGRvSqpqEo2zA== X-Received: by 2002:a05:6512:3da3:b0:52b:c33a:aa7c with SMTP id 2adb3069b0e04-52ccaa599d0mr804820e87.65.1718759183341; Tue, 18 Jun 2024 18:06:23 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a6f8186b686sm301852666b.7.2024.06.18.18.06.22 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 Jun 2024 18:06:22 -0700 (PDT) From: Wei Yang To: rppt@kernel.org, akpm@linux-foundation.org Cc: linux-mm@kvack.org, Wei Yang Subject: [PATCH 1/4] mm/sparse: nr_pages won't be 0 Date: Wed, 19 Jun 2024 01:06:09 +0000 Message-Id: <20240619010612.20740-1-richard.weiyang@gmail.com> X-Mailer: git-send-email 2.11.0 X-Rspamd-Server: rspam06 X-Rspamd-Queue-Id: 6B3B61C0010 X-Stat-Signature: d119k38cxz394k1tpkgydyus6dykbhk1 X-Rspam-User: X-HE-Tag: 1718759185-798938 X-HE-Meta: U2FsdGVkX1/FzPa5cqbHk1pgvqsL5imuANJhDKZRvRbwmnoG8mpSFfchet3Gzm3RKnmNH9hIeqZwSjM8U78tJHe2kVdBKQ0KcmY/FPOLjK7v6q3KAfjCl1MXY2VEXoHYmkPR8wFw3qwtbP1uzwb8rvn2JMQDt/UAFr3Rhwu7Nt8twRSoiFTzFtHMr3dQkrb8/x/w/ErlCcypzIChRyOxnGt3CxFS7glodL/nWJTUj27XY1JhaeeUNJ8l/DAGUvRNDadba817GsWS/UwryBhP9f+1I2A2ArjjcV0Mti70o5Rj7vzluS1aBhvWV7+VbYXLu/mK7OE73ggFS/8SApRm61c4RC0V1SsoWkkSbTjMEGJl1LI3PQceGu8xszGaV4PV8d6LNKav3wgOmBXHBAnxooZVAg5mWEG+N6de0kYSOlqV/XrDlBcWeGtEuC8iMBfQkUQLZVCIAGWskikIuuRwaqwGhGspgUCcAIh6vWQl+N+yinCfxSijes/2Bf5nXrWNYAbtydqilKqE6BZ+l9uCxiye7KskCEjbFeTDFZjDzsfeT+5cg+4KEGh/Qki2ImY2TDUA3g3wZlJzNNjseKzmwq85T8EWD7KimJSn12tte5DnBOcfpY+pR33NNOwBf2TJTk0m4GhrWT+x3xyskKLlWiU09dMMVfuDNCDFRkOt5qQEehpm68/wD0MOULKOydiEZAXvKhae4yRc9ZB1uoGCl05fXaxUVgDthvxCrCOZ5MhhVWCB0IDFP0HYUUnewvW7rtw7R91YaCd+Hja7+q3bzAGOHzoqEztuv3rG6fX2L8wZ1YYcaIwIPYnFCuXtFawgB0r5+ZKOj3bafqS+f94kxGksnT3PhtcJmr671uM0ykF91g/Fd1hhkyY/ehEhmK1zUWRg9yTSpxh6IGUiGjXsBeb9AM/KeBiCdhDF/NCuaqdt2V8Py4MRSC5YEWnHs9k3olY6RRZJVhiLUbHrZQa RccWXMVO rDUOSESF4rG3xmBy8yDzE6bkFua/DYEg/LjEivKkQIhDIxxJtU2qw0cc+dcsD4b88sYJMpwF65AJavEyajcg1k6bI9zkw7CKhocUi4jfNW5utBim48qgBWaX2/aeitsZbPNqn/4siBvP1rlMDCgJpaHh3Z9w4QmYICcSB0vKTmBSY35+E+KsBz2T5327frrJQOOa4zfsuRJsGfHsKULcDwtoF+iuCDPRcl9Eiqzgj4fgoqEvfZ9x+lSUqq0bw4GegSuLRMBGlCn+/oi9ePMed1lSvYitO2iIGSWWWarkuEMQliEU/Llxw0pKpjMg3Kalp0ceDL7qyAd5Bji8F1DW4do4GEggnZJnmsdr0+PRlFg2E4j8RP4ucTybbRHbpPT3VIJc7BFJXgujC+wi9vms/mJJzVvhXZx/aHMuR9GX3YbMfyeLhY1l44IY83YwAnulp8khBJY7dS9v8pZntx3TwXeFSueRvGXo0ulNAu7Dpj7WR9zqu6srOkoheP4jYr40ipBIc1MiNPJwllVM= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000134, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Function subsection_map_init() is only used in free_area_init() in the loop of for_each_mem_pfn_range(). And we are sure in each iteration of for_each_mem_pfn_range(), start_pfn < end_pfn. So nr_pages is not possible to be 0 and we can remove the check. Signed-off-by: Wei Yang CC: Mike Rapoport (IBM) --- mm/sparse.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/mm/sparse.c b/mm/sparse.c index de40b2c73406..f56701873ce8 100644 --- a/mm/sparse.c +++ b/mm/sparse.c @@ -195,9 +195,6 @@ void __init subsection_map_init(unsigned long pfn, unsigned long nr_pages) int end_sec = pfn_to_section_nr(pfn + nr_pages - 1); unsigned long nr, start_sec = pfn_to_section_nr(pfn); - if (!nr_pages) - return; - for (nr = start_sec; nr <= end_sec; nr++) { struct mem_section *ms; unsigned long pfns; From patchwork Wed Jun 19 01:06:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yang X-Patchwork-Id: 13703300 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 16218C27C4F for ; Wed, 19 Jun 2024 01:06:30 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 731B26B0363; Tue, 18 Jun 2024 21:06:29 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6E1B56B0365; Tue, 18 Jun 2024 21:06:29 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4E53D6B0368; Tue, 18 Jun 2024 21:06:29 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 2B6016B0363 for ; Tue, 18 Jun 2024 21:06:29 -0400 (EDT) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id C4DEE140BFD for ; Wed, 19 Jun 2024 01:06:28 +0000 (UTC) X-FDA: 82245847656.29.1136660 Received: from mail-ed1-f41.google.com (mail-ed1-f41.google.com [209.85.208.41]) by imf08.hostedemail.com (Postfix) with ESMTP id 1660E160016 for ; Wed, 19 Jun 2024 01:06:26 +0000 (UTC) Authentication-Results: imf08.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=WCoPaJBw; spf=pass (imf08.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.41 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1718759183; a=rsa-sha256; cv=none; b=lE6DQNfgqGXAqDey8hFEGhBbGyg3ddxMGpZA9eKzmroc4LaW9EAGuzrowevofTBTKkpWZn bvM+Qhk9jHghkBoSpPaTvI56K5/dZhGQUkd/35PoDKmrjyEpr5imAejw2X0/P13uHke97G ry49uB8v/XESkaARunNAzI5fnfTTO6Y= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=WCoPaJBw; spf=pass (imf08.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.41 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1718759183; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references:dkim-signature; bh=cQyEVf/Mf2xj6jpT7IAumrZEMBvIqP/r93L8mugrHFU=; b=y/x3pH3KEsEUM1YZswGJ/QDOspLDCk7rziL4iql/yU+5AN+HFxMz8stkgaDP+uASknt1H6 glF3J9MvFXhqlf7Jyn9ensQrkZcHjkZo80ijTHiUcuPWLt+gzi3RCebMh9svclFW5RzXdV crbWQYM8GfzWKhJ/cTeS/T1/NUwf5vU= Received: by mail-ed1-f41.google.com with SMTP id 4fb4d7f45d1cf-57cad4475e0so565495a12.1 for ; Tue, 18 Jun 2024 18:06:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718759185; x=1719363985; darn=kvack.org; h=references:in-reply-to:message-id:date:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=cQyEVf/Mf2xj6jpT7IAumrZEMBvIqP/r93L8mugrHFU=; b=WCoPaJBw6EBoE7rJkHhTsKLWcd7fGh8aqFN4Dwc6WK1Uk2B+OTaS3BYYerFbjs28Af pR7RMk7I/MItNcrsHOt4mxKYDWhr1MYj3/d9aAXFa9S9/ht4dF4EfNj4wiksu0mKrdo3 UH4yWxYdOQsgQsrYY1M1ozmC6dbVn+goiqY0mYETRg2HLAV7VoBma1/5wlhr06LbeHli yYJoqdi5WkVMJjiFtW2suqNLkI7J35YxObm3oN4BFjf3GJ1WgmezXoBbxB3A++qdYDiV apBNyXBpE46hURgudcdqdf4V3rDV3rv7/+O/BYFuCLVOLcXCYQ8rmj+YI2szbYEzwtqw 8/PQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718759185; x=1719363985; h=references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=cQyEVf/Mf2xj6jpT7IAumrZEMBvIqP/r93L8mugrHFU=; b=r1/nMGsix0aut9SfQJpztY2bxEbIOZnA5EmSpHrcmIhpzoM5gZPacE1qAxuo5LmxhJ emMfjumA5aYFa2GmHynOnfIMexGYovcYj8FnCTupvkvpgoIkgy9XKq/GWbjkGOnrapfv ivlEermlcxDmw7EXDx2lbRi/yJBVEZZYQjTAjhn/THazmtS9NqnR0Fu9egTGPjSaXTuH vOgflOCfjRUMdwe1jQ/ltIa/ROX+YZ9oZlJTls6rJEb51qZNw9RPjizI4JrLKajiLOYR JkEkIFnsbuaCQvc1/eaMUHTDjDYMuhUbK+WI+0G9BkN/cVJXJPRMY2rwIRALHcOIroGv pAzw== X-Gm-Message-State: AOJu0YyHd1A9qDoW6OU9hACmwzG75Tcs7qlks82JNsVt/zQjfPlXu54l WE0F8KLNcK8y0l/I/Nbp3Nm/uDSdjwkJDg1s8kZBEcnzEiEbyDmN X-Google-Smtp-Source: AGHT+IHdHmKTj/Joqy++vjSK6QVa2Bd3kBbQ0oTSMnf+NliQ3MlWlBBJGu23P5T4mETeky6DQYaP7g== X-Received: by 2002:a50:d4da:0:b0:57c:b82e:884b with SMTP id 4fb4d7f45d1cf-57d06ade10bmr635177a12.19.1718759185145; Tue, 18 Jun 2024 18:06:25 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-57cb743907bsm8086866a12.87.2024.06.18.18.06.23 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 Jun 2024 18:06:24 -0700 (PDT) From: Wei Yang To: rppt@kernel.org, akpm@linux-foundation.org Cc: linux-mm@kvack.org, Wei Yang Subject: [PATCH 2/4] mm/mm_init.c: move build check on MAX_ZONELISTS out of ifdef Date: Wed, 19 Jun 2024 01:06:10 +0000 Message-Id: <20240619010612.20740-2-richard.weiyang@gmail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20240619010612.20740-1-richard.weiyang@gmail.com> References: <20240619010612.20740-1-richard.weiyang@gmail.com> X-Stat-Signature: 4h1kyscbpzso5jeh3ek9htk57pt3c8xk X-Rspamd-Queue-Id: 1660E160016 X-Rspam-User: X-Rspamd-Server: rspam10 X-HE-Tag: 1718759186-448417 X-HE-Meta: U2FsdGVkX1+voeFwup5v7YKEvNvKfVrh2SOBfOAf5xoz7H7pXXOTg69z4kbgw5PGTDgAORbVOzrEnqBIZCNw5307W15o9gLWA6baOlxGBvDUHPXv5bjKQTgbGYWXgtnww9eSXTSe8voXEtSeAjc1YEmjBCI+shlGifZpbjIdGsjBKGWKJEEi5Umws0pd3l3RjWA5/mduxhQlJK9dJlQK6MQ0YmHIcqLTw8ktjxb1l1xiB6svskVj1HIE7CeBLzbj8syS/lH1usa3Fi1PlBg4LbcukYGGYKF+QpnUjEnhYt2q5mphqtOdl8kKRekAg+XMJ3Uhc/sjUmSkDV6q3q5hmSK6cAsyC9zgY9409uF2ylTucbh/rHpyrW4XntCj5SkuMgvWQts1qDRrVvW9orK4J++E6JL39q2MZAli0I4JugMIU2Pndbiz7IwP0DtX3vMjoiEcfhsAXWyuJh7nXPNxGfucJowAljIm1nB7HcYdUL7zlbgiNe2/9WmSclJrlE3JR4ozTIfq/uv4xFJWVA9JeDYJ0xTW0Pyb8RooqIqgi8YMaKa+N91mMRIzIfldhNpbb9qbLg866H2rtf3kjjMlCRQx5FeJZQQwTD9HF1mc4F38A+Jp6m3Fe4ZVk4rj9nNXocx8ugY0sjMOjhuXF8ttIMvtfKy9UaKiJbA2piqkO/hlxDgXz3/xyCHeYfM4xFjIusvaCDDsJW13IC0W2xufmwI7zax1mdKZpUCMid3GJ6KiqOUY40vuNPVxpeazcoaKUZcnwUiYou9Zznzl1RlBloz8m6qZYVoXnwFgC1eCkqp9WvgrVxzC5vZOhxYWSt/d0OaqD8DyTLzuBDw9+p6aA1EdOgoNqQyf/TY9Ef7BwrFtrpE+0LspFyp3GtHtfwhczwXrbENjtjGWXoHK7XTOmfNEjW5ocEC9M136mgj1yCXBD0agXSJgKbdFyZlHWXMy5d9hs/5sZ/y0a4qRvJ/ bDcqHoJ2 aee3mf5lX4Yx7LICmNyYUE7l0K4Iwjr1i4ZYbRj5eirLgBsNVH/CBjLVjTtNRmClZxk7Mfre+GbJ8lQhmzA5AZ9QlW+QAhLfZyKny7VcLMx9v6yB0rQBj5EArTyN1pa/Ms3l9ivcoHpsnPQ1WEHvYHTqIHoQCTLY8s/3fzvvwAdaVMvKSf6YJUc1Eo2C3spy6AfKPIG7gdXf2dUaw1mA94PZx2mmqewQZUvU9UX2GFkmXB+Lzkp8WXzrJ3oRvUXIZ5e81hJ6FlKcDX96mNy8USEL0ZJRseTFliEo1I0XJBv9KwR0PP3KhTssSQPrWuvHgGCGFnEj1+v2C+u0yf+AlVHoHJ7+rXGA3EnibZ6HBG04mmBYxYZKVjFrZMQCVdptTVLlwzIgCNbi4nQZwmMOQQMrogNUBSDM6Pyhr2ibpOGYE5bQFOxXuk7VITUgIAo8lDUy0YFFKA0WbWFeuKQA2le+R08fi+bQLRc38x1e9baGcuXIA6mrOGns4lXiO789O0Q7obQAk0fS7Sy8= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000752, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Current check on MAX_ZONELISTS is wrapped in CONFIG_DEBUG_MEMORY_INIT, which may not be triggered all the time. Let's move it out to a more general place. Signed-off-by: Wei Yang CC: Mike Rapoport (IBM) Reviewed-by: Mike Rapoport (IBM) --- mm/mm_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/mm_init.c b/mm/mm_init.c index 31ebb3cd53ac..4991cb5c5436 100644 --- a/mm/mm_init.c +++ b/mm/mm_init.c @@ -53,7 +53,6 @@ void __init mminit_verify_zonelist(void) struct zonelist *zonelist; int i, listid, zoneid; - BUILD_BUG_ON(MAX_ZONELISTS > 2); for (i = 0; i < MAX_ZONELISTS * MAX_NR_ZONES; i++) { /* Identify the zone and nodelist */ @@ -2668,6 +2667,7 @@ static void __init mem_init_print_info(void) void __init mm_core_init(void) { /* Initializations relying on SMP setup */ + BUILD_BUG_ON(MAX_ZONELISTS > 2); build_all_zonelists(NULL); page_alloc_init_cpuhp(); From patchwork Wed Jun 19 01:06:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yang X-Patchwork-Id: 13703301 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 00F1CC2BB85 for ; Wed, 19 Jun 2024 01:06:31 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 3D5CC6B0365; Tue, 18 Jun 2024 21:06:31 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 385C16B0369; Tue, 18 Jun 2024 21:06:31 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1DA376B036A; Tue, 18 Jun 2024 21:06:31 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id E50586B0365 for ; Tue, 18 Jun 2024 21:06:30 -0400 (EDT) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 74803120C59 for ; Wed, 19 Jun 2024 01:06:30 +0000 (UTC) X-FDA: 82245847740.05.314A068 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) by imf09.hostedemail.com (Postfix) with ESMTP id B62D614000D for ; Wed, 19 Jun 2024 01:06:28 +0000 (UTC) Authentication-Results: imf09.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=gfwjdcV3; spf=pass (imf09.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.52 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1718759183; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references:dkim-signature; bh=W8wnmFHsllBR/QXYnUAO+P/TrBSywXIoXzzVnXvfqxA=; b=s9BWeAFin4tJBlH72N6fF1giQpMUiS//t+wF2cs+icnPCnAPyBhIG2CFsYskgmLAZPsYa8 3Bfzm4KpBc41J+1lMRLEtTIIL6v66W8b7dJijKYjw/rDDkFQBKvt2UlbF+wFQhIFrSBcgz dmLqwoLPJrWG3n8uHhGOiPTVIx6PndI= ARC-Authentication-Results: i=1; imf09.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=gfwjdcV3; spf=pass (imf09.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.52 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1718759183; a=rsa-sha256; cv=none; b=Wh265FmUvS8qjMG1VTd1HUSundo5etAYNdzJn6p8H5a5FRv9cAGKC+1N5pSQl8dUTjdiLf vvHvcLDu+You1pkhozHr3ENBKse31be/w2cOCqkZFwVVEur6lquHoSw9QQAbitf0Q5SgoY 8RS9Xtv8bLfoOyBbWLlh29bOv+7S2ro= Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-57c60b13a56so7219317a12.0 for ; Tue, 18 Jun 2024 18:06:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718759187; x=1719363987; darn=kvack.org; h=references:in-reply-to:message-id:date:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=W8wnmFHsllBR/QXYnUAO+P/TrBSywXIoXzzVnXvfqxA=; b=gfwjdcV3+sqkVyVCXkaWzLSI9F+mSgLQRVpB+XFGeO5x1Nn19t0VI/MRAjzOsDFxgW eBBrVFkxvo1PX/2g/FNlbwqEl4v++ZrS+R/174UwG/SJW/6U5NAYLKfLGGROcznwI6cw UDVa63HWECEd0yv6Fki1rko6F+Y67BKKIsN2eM7qI73mBXIzmV7ugueY93S8LmUh5ec8 1iIlH+jfCsG9bPruyxJvlFJJUD99kJ/f8FTnoBOjVlJk5ZtSwOBu6Scx3wdktB0Bmhyu 7KRx6bUF17V9gNBcQ34b6EAg2IHPJFGhZbW09QCa64vtvwJpgjUQbBP9lE5Bh0cMV2q1 MqLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718759187; x=1719363987; h=references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=W8wnmFHsllBR/QXYnUAO+P/TrBSywXIoXzzVnXvfqxA=; b=BsYT/4Ze0NC7aih8mhIQGJsHgaGoKnp672eBlFCNfOJ2LZBiF3kl27ALNNiKGJkJDI IMlwgsO2rmTVcwPhX/86t9AU2QbK8KZF0bSQ/wX9tzQrY/KRPfXs3ndMn9zJ3OJiWYPI NNDlN/5du7aKTd70NcQogy5JEGQBJe+/+STAq6p2ErJIPagveNQ6+NMhejIf8XMljYgx mZg3aVeb8tXzqWW7c/NPrbpZ5raRha9g+lSgwuAKeZDG1NyNj08qj35QSA6MyMN5c7vp Qt0PLHngWgqEo3lEFuITk6/aBRumwtUIKferPnCz/gpISux+oBUpYmArAp9d+kGxkulR eaRQ== X-Gm-Message-State: AOJu0YwPenlLCcxH3gIVJccA6hCzqIK0H+HWXYh+kQgkGwfi/l8UMvLc yu4xyNwiAApYx26aTnzG+YT0UMvrSO6i93qeT+tvduTW0rp5ez/3 X-Google-Smtp-Source: AGHT+IHaYlByhYc1lQOtcetWs+4pAka1Ec+5sqNBtcQY/61RIrqlioCRpUPnTh8fastdKt95370pGg== X-Received: by 2002:a50:d50a:0:b0:57d:481:fdf3 with SMTP id 4fb4d7f45d1cf-57d07e8737bmr436791a12.25.1718759186987; Tue, 18 Jun 2024 18:06:26 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-57d048f1af1sm550313a12.59.2024.06.18.18.06.25 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 Jun 2024 18:06:25 -0700 (PDT) From: Wei Yang To: rppt@kernel.org, akpm@linux-foundation.org Cc: linux-mm@kvack.org, Wei Yang Subject: [PATCH 3/4] mm/page_alloc: fix a typo in comment about GFP flag Date: Wed, 19 Jun 2024 01:06:11 +0000 Message-Id: <20240619010612.20740-3-richard.weiyang@gmail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20240619010612.20740-1-richard.weiyang@gmail.com> References: <20240619010612.20740-1-richard.weiyang@gmail.com> X-Stat-Signature: ke898f9og3cu8zenzjyzigybg9sxtbuh X-Rspam-User: X-Rspamd-Queue-Id: B62D614000D X-Rspamd-Server: rspam02 X-HE-Tag: 1718759188-426425 X-HE-Meta: U2FsdGVkX19r0XZvjV38/Lwzlka8I+uPTaoaiXbo3cKZ9wSmqwLArlPCqvx1UTQubXtBudOZvdYWzD8DbNnyYTcqghbPDrWURbK0Jq3wwBLNYN0NSSvzrKuR4AXGO6dujXzkrdXYg8hyF+xsisCbWRW+hwbtiEwEO/grYpA/ubFxomr6hWBGw7QUlY81Bmww7llw14nBKU0ZY1n1EIKFw397tymmOYSwTPL2osahbGXxOwOOal6/hmFGddQehJ1rCBf/hznxaku65CMrBzr/V0kroFxu1Vdw6qq006+lbW3/1H4HjRjOzuym8f95lC9eHRVsBq8n9zW1m2LdCXBhXVhYXPPyYtF6hOHZ5TGSYOJWnEdCPpS77yfnPG4D8Z4STeZhK9WgzWUDDOGiS3+3oxXB7xSG3nlxgULVtU1OKcd/Fx9U3AE3QkiIsPhqlHfcHq4Mh64S5LSAswuawIgb/FOVgQmwBQqTLL70AroiiMVd6INPGLw7E4JvQBYiWeYWvj0w5gUSKMwLOTheqnKOnIhrLmWcm4dz5zBJ42b6EsRy4MZ5UQGkkFuOMQktQkhse6FBKXdrLWxRFYEklcdikNJBZoABdg0V4ZB1anP1vOYGwSyB1IlJClSDd316uGmy6L/FlqLh0UsupJgxDumQ6U6k9iWjryJaI5n8X9FwkwKStrlX2WYF/pG306/twS7SPXfXQyjcInQYs40tidlK5xyhx0FDIGe62bfRYZAXnZtwWzeVO+aa+QM0rfOn7WhP4lNqTjhCPzvWv/rh5BUoIkDGCNhZTT7S1W39SAejhMzmlC8iFX2zKlenmpIxM+Hqo+lsyuAiTc02hsiP190THCeSkGnwQPJYIJFCP7RdPsSP2wemDu9/iTKhLOqbts/p3+/tpvzYT/mrW7gNHjQYS7Bf0MXRhluD7MVYst9mw+rssnJoTofV86VV7QRZ8iPIKzlHqLIeVb+wYXj+sQa NmfXEgzC mzYqtXh9NSkLiFDA0terjMhtU9eN2bSLlXEx4IDyYV6TfMyCigVO9SiVapjE/0mDd2p2YMKyjfajSha6CyaQmn9OQeZXBPpx2ZAD0+5cHe0oZ37n//MuYacKvAxbS4Zqaa6gon87OzCVSaNjUsOwXR2RBsmxpWZ0JkvWICQH8vOHHd8gCIWP5Qz1L17rv9Un2c+RWrlTli8V1LoN9amxHcRZ1a0TOID49VGS6EnCcymXSIR0sCH+aAzi5B4MT1tz5g3Pm9IkOJml7flT6qkeUcQCBMSMwYFdcoFr4z0DczEOGxaE6XSJPvuOkN8ewPTpUQokOT3dXXOV1va2ALvJf9XjvFtQ09S8Y00fv9d7NoQKieZZkGKJjrWNHSk8N9LWzuBGmbHV7OadM+kWD+4sdgElHPmeG/yZvB6tKFwKB/XCdPCIS1P6s7Vsgm1Y302YLzlA9RFI7DHok0L4= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000173, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: The GFP flags used to choose the zonelist is __GFP_THISNODE. Let's change it to what exactly it should be. Signed-off-by: Wei Yang Acked-by: Mike Rapoport (IBM) --- mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index f3ba1ede142d..594176449890 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -5209,7 +5209,7 @@ static void build_zonelists_in_node_order(pg_data_t *pgdat, int *node_order, } /* - * Build gfp_thisnode zonelists + * Build __GFP_THISNODE zonelists */ static void build_thisnode_zonelists(pg_data_t *pgdat) { From patchwork Wed Jun 19 01:06:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yang X-Patchwork-Id: 13703302 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id BCEFEC27C4F for ; Wed, 19 Jun 2024 01:06:34 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 49F1B6B0369; Tue, 18 Jun 2024 21:06:32 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 428316B036B; Tue, 18 Jun 2024 21:06:32 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 29FE66B036C; Tue, 18 Jun 2024 21:06:32 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 0576E6B0369 for ; Tue, 18 Jun 2024 21:06:31 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id B9D231403A4 for ; Wed, 19 Jun 2024 01:06:31 +0000 (UTC) X-FDA: 82245847782.01.1403894 Received: from mail-ed1-f50.google.com (mail-ed1-f50.google.com [209.85.208.50]) by imf15.hostedemail.com (Postfix) with ESMTP id 0A8F2A0003 for ; Wed, 19 Jun 2024 01:06:29 +0000 (UTC) Authentication-Results: imf15.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=N+4GjmVR; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf15.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.50 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1718759181; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references:dkim-signature; bh=4+esPStSBvaPch0YhqViQARgq29meV705wr3ONaOGAM=; b=mmll9HOEVUC7j75T7YxRfOFTGjzAfEWaydEn5ygvit0ADxIjw+U5qlQzLDOWzbffDIo3NS t+x0LpbtUkxbcFKOOMvIgGSL1r5FaVAUH55i/n++Z6KQzor338ijp1D9i8n6jkYngp3ktx +cw1DcAaCXNvcmARz/Ig5LguWrAqUPw= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1718759181; a=rsa-sha256; cv=none; b=zeKQIDeFfi6lK1RXrNWYcvlF9yuXy1mvLe5alvNXUtOnJskQPVG5Kd8aOfDgdUs8esOoKs JDIOev2zQx7LSvIE9Of3jAqW6Jho4ZxCgZ29D90H/cTUyy2PCmmT7anBn9OS3W40/qw/Kw xCpfTPVUYXTY8OFX6jsQe4oHN9m8cLc= ARC-Authentication-Results: i=1; imf15.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=N+4GjmVR; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (imf15.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.50 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com Received: by mail-ed1-f50.google.com with SMTP id 4fb4d7f45d1cf-57cb9efd8d1so619116a12.0 for ; Tue, 18 Jun 2024 18:06:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718759188; x=1719363988; darn=kvack.org; h=references:in-reply-to:message-id:date:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=4+esPStSBvaPch0YhqViQARgq29meV705wr3ONaOGAM=; b=N+4GjmVRgN38MKtegqzLHK2J+uEcOdg3Rw9GXA653zagRKC5UKl4S7wJflsTYjRd72 QtJaxmGv7yrL8f6xh6N2f78XvA3LzFbg8vnvrzg/sm8cdFTxU2yAtgFer06YBzGDcO/R pgUqRBTzjYhWk4zdAlUrOf7d5896BMmiE8JnZrKeAU24blZ7gPCTdH+oaPPRX7nT4xD3 wxfmGmE4nYOmJWNWIsuWu85uFS5JApOUpGslGVtec2yydnKSTD1y3VhYjfaR6Sb5kKr6 bmjpBgz1lrjbkuQdZ1tA/o3AHFWXTAIqOkAvOurEcLpvY3tAYLjPU5C8V1qqlmm5HwVI esmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718759188; x=1719363988; h=references:in-reply-to:message-id:date:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=4+esPStSBvaPch0YhqViQARgq29meV705wr3ONaOGAM=; b=KqikXM+SHfCLsGqsX+7xpvJj/DowcJ5vpMdZSc82FOcJwTub8NbFf6GoLA3jQEhRfh jBhDz2bIUYCpYQ60QBaT+ralL1/y7rU0dwyQuf01p+n4ZCNmSYbXZWo47t7rRa0QK1of Gfd8LlbPcsBWNFv+WbyrUEwR5gzntkeLyHchXLOg1/x4C/OYsLniVHKhkuV4qxflpFGh 0iyroHfv1L8tY/D+KPA9FyPTxeoHSX38lQND31U1m/ztsOVp3Z1oDuOkA24q0nhsXB6i fLzeeEgmGef1A2fC7jwqNsprZ77RyqzCCR/SyaTsjB0lWWVVGRAWn0thTlrDYoZtND37 Wu5A== X-Gm-Message-State: AOJu0YydhSkU1yT3a4XDELWT/q4YUaDbG/l1vmeY2ZQKSOqNEd8fx1Ud gPpQgcS54Q4ryisjKOsIWJIEqtMBZYQED5//k9pVPKIjBbumWrUs X-Google-Smtp-Source: AGHT+IGcruuDA/uPlPhmWGJIN7tHy/tJ+fG1TKVJSB0afFx+PhWFYYSI2DFTvc4bl/Jl7U/iT7uHZQ== X-Received: by 2002:a05:6402:1019:b0:57c:93b7:ab36 with SMTP id 4fb4d7f45d1cf-57cf7ae6832mr2261201a12.21.1718759188581; Tue, 18 Jun 2024 18:06:28 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-57cb72da785sm8047392a12.28.2024.06.18.18.06.27 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 18 Jun 2024 18:06:27 -0700 (PDT) From: Wei Yang To: rppt@kernel.org, akpm@linux-foundation.org Cc: linux-mm@kvack.org, Wei Yang Subject: [PATCH 4/4] mm/page_alloc: reword the comment of buddy_merge_likely() Date: Wed, 19 Jun 2024 01:06:12 +0000 Message-Id: <20240619010612.20740-4-richard.weiyang@gmail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20240619010612.20740-1-richard.weiyang@gmail.com> References: <20240619010612.20740-1-richard.weiyang@gmail.com> X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: 0A8F2A0003 X-Stat-Signature: sbpnxt9xon6y4q4mt9tdftt8t848tu6y X-Rspam-User: X-HE-Tag: 1718759189-463698 X-HE-Meta: U2FsdGVkX18E6jc4v7ptqusDNBXnKYtmPgbBT0ILr88skaUH6EiuUqm7u96FeDNsa3ZgSkBPvNKTZKkWIik6JzFAz0dB87PuEI25aiUV9rUrSQNjZXZWMZs+8TcJCtJMzCJMAXCL8rJRu8nzOLghTJJr3m8s0snLJxTGatkvFTkE/WShWxQdvu/w8POjb47T/7zvMla4McNRNNh+ka9esw3YfIZET0TMzile802UObe6gw5aWp3AONM+aqKyKSL5/HDEauGn1GA/7xwgsXcT29fUOUb2iUw/H4ZRrM14riaHDivDfSOMSDWMkiw5F00ZUenVjZqXP/Ca0ga21muNm54HCcnvynyLOHfpJ5fRVbaD5fRIMPD4as6OLgTOM+JGQQ1wqHOupLMbv+9DTo8/kuVjcKrjf0NmKZQxX8a2xbscFIsOUuooigfGaqrAdOTHqQDdNXcjz/EAUEgswFnmyv/ahsKBJXVJz4VGZr0qTDZFtH6hBqJWHJsFbTTrpXW4TeB8fkmew+0hMqzpKKs1/lv3sGBjAszMK79xQpCDrfkLRT/iFzVLu/K6sDoRFVuiHiPbD/7kutPGDfx/kg9HJ+M3juc8J7WPlWpnCG417BO+D7utMShRnUdkrLvFkmC/rlLtUrsyPWcHwsiuCI3SLjmyY2dYnXE1THAq34CP0Ud0Gmtl4YnZZfiB5EdtuQjs6ypxNbDbA1yM+jPsZnYeiO/Q08yyjuCclSnNiK0q+Ueuo3Rw/2jsE9F7wzOmlGI/pLs5qH9KXWWcgYIhNlOMcO374lBqCm2o5EIV/ZOmDiZ844pwAk/z5MBKvjspLfe7dH7dYzIVtVzrXxYMhVeUckMeb8WNY4Cqy5nG2XdEujnedBuQKUP8JAej2IajYGjXd3dstTNwO0TOalEDi6XtX3cPbAUvXxqk+DDACxnPT7wZZTmPitZX7bw5v8LdDz5+XBbhaNj40JLjHVOnJJV mfGHlOow QeWdrmZFwURsvqwqw/qRYMx7PuhZEFZ/FruaF2VJ2zkbah8CN+l2at1KkrVepL1DrNVOpl0hbfvb8PEw/9QRIWiYku/CstLtiTyD4QY/gyt51mYsyhGkbX+D+7DCXRs6MlPQARxOL84Vkmjpjcy3y8QRdNA7ik/d80OtxaW0y+SikkeDVrGG7AmkzTqzkyVxwH9vDB4JGxN1zmAyZwmslEkjK2u6Mqt/aLOSmM5tsapsM7AS5lBjNaJPT1DWW/+H7hNJWbe5YnBotN42yzLG5imuZLMNBQDM3P/kPYqXESbm3VwaUCRiMJ0HaX2cDoFkuhUJ7XYS08ffw+QbpNop6qf4xaHgJ3/Ve6IJzXAO11ruAHCLQMVoP0Fjn67/TWkaQPOf7ZhO5k/Rgr8HGRmia7ZBemBlUyQIBoX40KpfaBQ29q/SCEAfwerwkNMEYaLHr96QxR0I/No0H1js= X-Bogosity: Ham, tests=bogofilter, spamicity=0.003725, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: For page with order O, we are checking its order (O + 1)'s buddy. If it is free, we would like to put it to the tail and expect it would be merged to a page with order (O + 2). Reword the comment to reflect it. Signed-off-by: Wei Yang --- mm/page_alloc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 594176449890..d1df7929f003 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -706,12 +706,12 @@ static inline struct page *get_page_from_free_area(struct free_area *area, } /* - * If this is not the largest possible page, check if the buddy - * of the next-highest order is free. If it is, it's possible + * If this is less than the 2nd largest possible page, check if the buddy + * of the next-higher order is free. If it is, it's possible * that pages are being freed that will coalesce soon. In case, * that is happening, add the free page to the tail of the list * so it's less likely to be used soon and more likely to be merged - * as a higher order page + * as a 2-level higher order page */ static inline bool buddy_merge_likely(unsigned long pfn, unsigned long buddy_pfn,