From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 38A5CC2BB40 for ; Tue, 15 Dec 2020 03:12:46 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id D02F022473 for ; Tue, 15 Dec 2020 03:12:45 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D02F022473 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 6515A8D0065; Mon, 14 Dec 2020 22:12:45 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 602D48D001C; Mon, 14 Dec 2020 22:12:45 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4A7048D0065; Mon, 14 Dec 2020 22:12:45 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0042.hostedemail.com [216.40.44.42]) by kanga.kvack.org (Postfix) with ESMTP id 30E618D001C for ; Mon, 14 Dec 2020 22:12:45 -0500 (EST) Received: from smtpin29.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 02ABB8249980 for ; Tue, 15 Dec 2020 03:12:45 +0000 (UTC) X-FDA: 77594044290.29.stamp05_2907e7427420 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin29.hostedemail.com (Postfix) with ESMTP id DC1441802DDF9 for ; Tue, 15 Dec 2020 03:12:44 +0000 (UTC) X-HE-Tag: stamp05_2907e7427420 X-Filterd-Recvd-Size: 2854 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf50.hostedemail.com (Postfix) with ESMTP for ; Tue, 15 Dec 2020 03:12:44 +0000 (UTC) Date: Mon, 14 Dec 2020 19:12:42 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1608001963; bh=Z8zi46IhhG3F6PFez7Iq7xeKZyxd6JAs2P1/ISzigvU=; h=From:To:Subject:In-Reply-To:From; b=0YyP1mnglUWVRJTalwj0+vXiqz6ASCvlS7jquKy9zQswYjBSiLsTjS9U+vK6TtTvM pF3nq5W9981a8IlNGew1GlTzuryAkFOAVOmqme1uhhDdSRxddOXrcZE1Ep2UClfp6B RJFkbNV+VfukO9glZT8e2t14Fpi+dpKB4tdb5+CI= From: Andrew Morton To: akpm@linux-foundation.org, linux-mm@kvack.org, mm-commits@vger.kernel.org, sh_def@163.com, torvalds@linux-foundation.org Subject: [patch 160/200] mm/compaction: move compaction_suitable's comment to right place Message-ID: <20201215031242.1XgiZ_qo1%akpm@linux-foundation.org> In-Reply-To: <20201214190237.a17b70ae14f129e2dca3d204@linux-foundation.org> User-Agent: s-nail v14.8.16 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: From: Hui Su Subject: mm/compaction: move compaction_suitable's comment to right place Since commit 837d026d560c ("mm/compaction: more trace to understand when/why compaction start/finish"), the comment place is not suitable. So move compaction_suitable's comment to right place. Link: https://lkml.kernel.org/r/20201116144121.GA385717@rlk Signed-off-by: Hui Su Reviewed-by: Andrew Morton Signed-off-by: Andrew Morton --- mm/compaction.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) --- a/mm/compaction.c~mm-compaction-move-compaction_suitables-comment-to-right-place +++ a/mm/compaction.c @@ -2070,13 +2070,6 @@ static enum compact_result compact_finis return ret; } -/* - * compaction_suitable: Is this suitable to run compaction on this zone now? - * Returns - * COMPACT_SKIPPED - If there are too few free pages for compaction - * COMPACT_SUCCESS - If the allocation would succeed without compaction - * COMPACT_CONTINUE - If compaction should run now - */ static enum compact_result __compaction_suitable(struct zone *zone, int order, unsigned int alloc_flags, int highest_zoneidx, @@ -2120,6 +2113,13 @@ static enum compact_result __compaction_ return COMPACT_CONTINUE; } +/* + * compaction_suitable: Is this suitable to run compaction on this zone now? + * Returns + * COMPACT_SKIPPED - If there are too few free pages for compaction + * COMPACT_SUCCESS - If the allocation would succeed without compaction + * COMPACT_CONTINUE - If compaction should run now + */ enum compact_result compaction_suitable(struct zone *zone, int order, unsigned int alloc_flags, int highest_zoneidx) _