From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751170AbdBUELK (ORCPT ); Mon, 20 Feb 2017 23:11:10 -0500 Received: from out0-151.mail.aliyun.com ([140.205.0.151]:51112 "EHLO out0-151.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750928AbdBUELJ (ORCPT ); Mon, 20 Feb 2017 23:11:09 -0500 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R131e4;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e02c03303;MF=hillf.zj@alibaba-inc.com;NM=1;PH=DS;RN=8;SC=85;SR=0;TI=SMTPD_---.7fj8QCN_1487650234; Reply-To: "Hillf Danton" From: "Hillf Danton" To: "'Vlastimil Babka'" , "'Mel Gorman'" Cc: "'Andrew Morton'" , "'Shantanu Goel'" , "'Chris Mason'" , "'Johannes Weiner'" , "'LKML'" , "'Linux-MM'" References: <20170215092247.15989-1-mgorman@techsingularity.net> <20170215092247.15989-4-mgorman@techsingularity.net> <001501d2881d$242aa790$6c7ff6b0$@alibaba-inc.com> <20170216081039.ukbxl2b4khnwwbic@techsingularity.net> <001f01d2882d$9dd14850$d973d8f0$@alibaba-inc.com> In-Reply-To: Subject: Re: [PATCH 3/3] mm, vmscan: Prevent kswapd sleeping prematurely due to mismatched classzone_idx Date: Tue, 21 Feb 2017 12:10:34 +0800 Message-ID: <012701d28bf8$7380d920$5a828b60$@alibaba-inc.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQKB+Y4QbCcdRwF90qCW6BKDtoYfwAHHz9YmApgb8HQB8Bf2XQIpxlUuAm/xouufvKgH4A== Content-Language: zh-cn Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On February 21, 2017 12:34 AM Vlastimil Babka wrote: > On 02/16/2017 09:21 AM, Hillf Danton wrote: > > Right, but the order-3 request can also come up while kswapd is active and > > gives up order-5. > > "Giving up on order-5" means it will set sc.order to 0, go to sleep (assuming > order-0 watermarks are OK) and wakeup kcompactd for order-5. There's no way how > kswapd could help an order-3 allocation at that point - it's up to kcompactd. > cpu0 cpu1 give up order-5 fall back to order-0 wake up kswapd for order-3 wake up kswapd for order-5 fall in sleep wake up kswapd for order-3 what order would we try? It is order-5 in the patch. Given the fresh new world without hike ban after napping, one tenth second or 3 minutes, we feel free IMHO to select any order and go another round of reclaiming pages. thanks Hillf