From patchwork Fri Jul 28 17:10:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kemeng Shi X-Patchwork-Id: 13331537 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 D1B15C001E0 for ; Fri, 28 Jul 2023 09:10:34 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 944938D0006; Fri, 28 Jul 2023 05:10:32 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 8CE498D0003; Fri, 28 Jul 2023 05:10:32 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6FC0B8D0006; Fri, 28 Jul 2023 05:10:32 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 589008D0003 for ; Fri, 28 Jul 2023 05:10:32 -0400 (EDT) Received: from smtpin26.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay03.hostedemail.com (Postfix) with ESMTP id 33E4BA0D04 for ; Fri, 28 Jul 2023 09:10:32 +0000 (UTC) X-FDA: 81060449904.26.2F234D1 Received: from dggsgout11.his.huawei.com (unknown [45.249.212.51]) by imf16.hostedemail.com (Postfix) with ESMTP id 42ABA18000C for ; Fri, 28 Jul 2023 09:10:27 +0000 (UTC) Authentication-Results: imf16.hostedemail.com; dkim=none; spf=none (imf16.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.51) smtp.mailfrom=shikemeng@huaweicloud.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1690535430; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qj0nYBSsAC2wvn2l1Gxd9Hb49uXKy1ml83q/tUvBcI4=; b=Lr8sb9Tkec48YQh+ES0ZzUI5O1CQm2uuMn+oWdoK7fvJpUzORGWONRELSLuejsM93ik8ND 8M7fMYRbNcIQ6sAKvZHZJXZX75GqZoo9+zdNL0On+fBdmcrRqBW74E1mqgIIhLnE+bM96/ DPdO3dbuus7DUou/Gss8dcNYA3d0BRo= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1690535430; a=rsa-sha256; cv=none; b=EW3VYbIFkL6adjLJW0+Vv4MSPjDsGGsE7EYGJ8eCayWN3jM233oopLcKL67TWNJ21g+O+X Cp3xfo4OSvQ/6sj+UwxkcRe/T3fRX05137lOuWHG/y6YzAcXmlbMhqChF+RGx0xYfr21wA IM+vq+ure+VMbGLb/WPfJdCxC6yfnVI= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=none; spf=none (imf16.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.51) smtp.mailfrom=shikemeng@huaweicloud.com; dmarc=none Received: from mail02.huawei.com (unknown [172.30.67.143]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4RC20V2t72z4f43L9 for ; Fri, 28 Jul 2023 17:10:18 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.124.27]) by APP4 (Coremail) with SMTP id gCh0CgA3n7L1hcNkCrD+Ow--.32454S10; Fri, 28 Jul 2023 17:10:18 +0800 (CST) From: Kemeng Shi To: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, baolin.wang@linux.alibaba.com, mgorman@techsingularity.net, willy@infradead.org, david@redhat.com Cc: shikemeng@huaweicloud.com Subject: [PATCH 8/8] mm/compaction: only set skip flag if cc->no_set_skip_hint is false Date: Sat, 29 Jul 2023 01:10:37 +0800 Message-Id: <20230728171037.2219226-9-shikemeng@huaweicloud.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20230728171037.2219226-1-shikemeng@huaweicloud.com> References: <20230728171037.2219226-1-shikemeng@huaweicloud.com> MIME-Version: 1.0 X-CM-TRANSID: gCh0CgA3n7L1hcNkCrD+Ow--.32454S10 X-Coremail-Antispam: 1UD129KBjvdXoWrtw4ktF1DJF1UKr4fGr17ZFb_yoW3WFc_Jr n2yF4Fyw1Svr93AFn8uw43Cr1kKrWDCr17Wa4kXr1ayrWvya1kX3Z7Xr9xXrn8XFW7W3sx G3ykZF48GFyS9jkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbDAFF20E14v26rWj6s0DM7CY07I20VC2zVCF04k26cxKx2IYs7xG 6rWj6s0DM7CIcVAFz4kK6r1j6r18M280x2IEY4vEnII2IxkI6r1a6r45M28IrcIa0xkI8V A2jI8067AKxVWUAVCq3wA2048vs2IY020Ec7CjxVAFwI0_Xr0E3s1l8cAvFVAK0II2c7xJ M28CjxkF64kEwVA0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVW7JVWDJwA2z4x0Y4vE2I x0cI8IcVCY1x0267AKxVW8Jr0_Cr1UM28EF7xvwVC2z280aVAFwI0_GcCE3s1l84ACjcxK 6I8E87Iv6xkF7I0E14v26rxl6s0DM2AIxVAIcxkEcVAq07x20xvEncxIr21l5I8CrVACY4 xI64kE6c02F40Ex7xfMcIj6xIIjxv20xvE14v26r106r15McIj6I8E87Iv67AKxVWUJVW8 JwAm72CE4IkC6x0Yz7v_Jr0_Gr1lF7xvr2IYc2Ij64vIr41lF7I21c0EjII2zVCS5cI20V AGYxC7MxAIw28IcxkI7VAKI48JMxC20s026xCaFVCjc4AY6r1j6r4UMI8I3I0E5I8CrVAF wI0_Jr0_Jr4lx2IqxVCjr7xvwVAFwI0_JrI_JrWlx4CE17CEb7AF67AKxVWUtVW8ZwCIc4 0Y0x0EwIxGrwCI42IY6xIIjxv20xvE14v26r1I6r4UMIIF0xvE2Ix0cI8IcVCY1x0267AK xVWxJVW8Jr1lIxAIcVCF04k26cxKx2IYs7xG6r1j6r1xMIIF0xvEx4A2jsIE14v26r1j6r 4UMIIF0xvEx4A2jsIEc7CjxVAFwI0_Gr0_Gr1UYxBIdaVFxhVjvjDU0xZFpf9x0pRKFAPU UUUU= X-CM-SenderInfo: 5vklyvpphqwq5kxd4v5lfo033gof0z/ X-CFilter-Loop: Reflected X-Stat-Signature: f3dbfb7bqsqbr49fzhchsudfa177zwdy X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 42ABA18000C X-Rspam-User: X-HE-Tag: 1690535427-309204 X-HE-Meta: U2FsdGVkX1+ouWWWpgbE7pbhs/Xm8+NPfz1luxSbeSa8QwNGEYgr+o+QvjW7XLk8pOsUvxA8TbDl+JSCmSQuyInwyGb0elKw/2xJgZTbrvqL6LILBu+m4GISk8xNm5mEfeDzb9iTm7qSkME06rs2Oj2SR/FYb2PdbiKqLQShhPGaxMIF0hGf2u7itdc9hqak1AdoG+EBwQFY2Gk0BDu0cs579g6Q/gLpRUMFuP8aS5WPsPURd3/doa3EO54nz0jP5J19R+pN/dQYv6p4RFO5/tJxWofhUXXChxBzxUq7X5NK1sVGc/YwndDUEDMO1M96mo36HnRt6N0StvwfORdvclHvjhPpa49oIfkoB0oPsBrgIDBF8X5yf2EeXw13TPyF0zWl4u01s7Nl72231Uh3HsYuxlPQn8j2u8OrhOtJAnRFVUvfFwt9zkJmmBDzyWgKriTMkNRQttc7uJAOvo6Zgy97pMHl45trL7F6HDflu8Bbc9eYsEshR5xEYhSJzJUSr+NAlINeKFhBZs99OZfS732QKm2+rRBjFqvsiR2Ho4VgfYDpZwJ86TvRXPQXlOyTtOPh9/VCailM+0Gp9Rg6lVk+83m5BSGflAS6YQgItYGyo+B/K+pmVMu7YL9fLAtRSE1IClwOanCWB2qLtlXUUOlcJSeD2+tDQkECdo9kAU1BiJ0Qx4ihjROdlHl51x/v8Mj0ddtyoBG/+TscWsZkN8l8iFStat12dP6Y3w660A/fqAYACZAshmdpK2S8Gur0AG54Vdv5NQVUaFmRlUFKC7lcYF4YAeqPLiBQcN7QOKO1gaplPdfqK8o7YnCaNvgrXXoEuhMPfmkQ1j1C2el0hAlJx733rV4MJ/oGHxpbRIHzSNY9IVG1UqduVGYXy0KV3BUGPs9YdTRB129ILXQMesu251U6yVJYYMaFw6PTgK8TN43txbO8tYohCxht7pf/PWQ5RkTB/s7EC/L6Pnc rlQjvQYk Hs6yRrl3JyUeQBueQT9Fa60PYAX4v51oktJv5GTFAEI4LUoR+h/Sdcid4OFhrMbSkzF/YFsKHKDRIDdPBm7GqKtVuVeOVraW+Cy/cu06kbpFmaU93L4xKuzK4Gdpd2LD689qawz+UpIoaDwzsUpMespeq5/mrJMgxdcFdPNjar8xywZqR2gn+sM9tQI1fv26Dt6oUsxwjLyG11fKSS/OmvpIe9uN6m+fRbvjpTORokFuUltIz4tmNxSgoerV2hn338DMwdumCmXRJ3cuUOFuMQ9zDoJXNMLN7Rk7MVgEsKRYsHQT/0UpZiYlzNDorFf7/S9O8 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Keep the same logic as update_pageblock_skip, only set skip if no_set_skip_hint is false which is more reasonable. Signed-off-by: Kemeng Shi Reviewed-by: David Hildenbrand --- mm/compaction.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/compaction.c b/mm/compaction.c index 188d610eb3b6..6841c0496223 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -1418,7 +1418,7 @@ fast_isolate_around(struct compact_control *cc, unsigned long pfn) isolate_freepages_block(cc, &start_pfn, end_pfn, &cc->freepages, 1, false); /* Skip this pageblock in the future as it's full or nearly full */ - if (start_pfn == end_pfn) + if (start_pfn == end_pfn && !cc->no_set_skip_hint) set_pageblock_skip(page); }