From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Shi Subject: Re: [PATCH v17 03/21] mm/compaction: correct the comments of compact_defer_shift Date: Tue, 28 Jul 2020 19:59:33 +0800 Message-ID: <3bd60e1b-a74e-050d-ade4-6e8f54e00b92@linux.alibaba.com> References: <1595681998-19193-1-git-send-email-alex.shi@linux.alibaba.com> <1595681998-19193-4-git-send-email-alex.shi@linux.alibaba.com> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Sender: cgroups-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-ID: Content-Type: text/plain; charset="us-ascii" To: Alexander Duyck Cc: Andrew Morton , Mel Gorman , Tejun Heo , Hugh Dickins , Konstantin Khlebnikov , Daniel Jordan , Yang Shi , Matthew Wilcox , Johannes Weiner , kbuild test robot , linux-mm , LKML , cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Shakeel Butt , Joonsoo Kim , Wei Yang , "Kirill A. Shutemov" , Rong Chen >> * Compaction is deferred when compaction fails to result in a page >> - * allocation success. 1 << compact_defer_limit compactions are skipped up >> + * allocation success. compact_defer_shift++, compactions are skipped up >> * to a limit of 1 << COMPACT_MAX_DEFER_SHIFT >> */ >> void defer_compaction(struct zone *zone, int order) > > So this doesn't read right. I wouldn't keep the "++," in the > explanation, and if we are going to refer to a limit of "1 << > COMPACT_MAX_DEFER_SHIFT" then maybe this should be left as "1 << > compact_defer_shift". > Thanks for comments! So is the changed patch fine? -- >From 80ffde4c8e13ba2ad1ad5175dbaef245c2fe49bc Mon Sep 17 00:00:00 2001 From: Alex Shi Date: Tue, 26 May 2020 09:47:01 +0800 Subject: [PATCH] mm/compaction: correct the comments of compact_defer_shift There is no compact_defer_limit. It should be compact_defer_shift in use. and add compact_order_failed explanation. Signed-off-by: Alex Shi Cc: Andrew Morton Cc: linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org --- include/linux/mmzone.h | 1 + mm/compaction.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index f6f884970511..14c668b7e793 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -512,6 +512,7 @@ struct zone { * On compaction failure, 1<