From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f199.google.com (mail-pf0-f199.google.com [209.85.192.199]) by kanga.kvack.org (Postfix) with ESMTP id 4EF826B0033 for ; Wed, 1 Feb 2017 01:12:53 -0500 (EST) Received: by mail-pf0-f199.google.com with SMTP id y143so549499775pfb.6 for ; Tue, 31 Jan 2017 22:12:53 -0800 (PST) Received: from lgeamrelo12.lge.com (LGEAMRELO12.lge.com. [156.147.23.52]) by mx.google.com with ESMTP id y19si13481299pgj.37.2017.01.31.22.12.51 for ; Tue, 31 Jan 2017 22:12:52 -0800 (PST) Date: Wed, 1 Feb 2017 15:12:48 +0900 From: Minchan Kim Subject: Re: [PATCH 1/2 v3] mm: vmscan: do not pass reclaimed slab to vmpressure Message-ID: <20170201061248.GA9690@bbox> References: <1485504817-3124-1-git-send-email-vinmenon@codeaurora.org> <1485853328-7672-1-git-send-email-vinmenon@codeaurora.org> MIME-Version: 1.0 In-Reply-To: <1485853328-7672-1-git-send-email-vinmenon@codeaurora.org> Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline Sender: owner-linux-mm@kvack.org List-ID: To: Vinayak Menon Cc: akpm@linux-foundation.org, hannes@cmpxchg.org, mgorman@techsingularity.net, vbabka@suse.cz, mhocko@suse.com, riel@redhat.com, vdavydov.dev@gmail.com, anton.vorontsov@linaro.org, shashim@codeaurora.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org On Tue, Jan 31, 2017 at 02:32:08PM +0530, Vinayak Menon wrote: > During global reclaim, the nr_reclaimed passed to vmpressure > includes the pages reclaimed from slab. But the corresponding > scanned slab pages is not passed. This can cause total reclaimed > pages to be greater than scanned, causing an unsigned underflow > in vmpressure resulting in a critical event being sent to root > cgroup. So do not consider reclaimed slab pages for vmpressure > calculation. The reclaimed pages from slab can be excluded because > the freeing of a page by slab shrinking depends on each slab's > object population, making the cost model (i.e. scan:free) different > from that of LRU. Also, not every shrinker accounts the pages it > reclaims. This is a regression introduced by commit 6b4f7799c6a5 > ("mm: vmscan: invoke slab shrinkers from shrink_zone()"). > > Signed-off-by: Vinayak Menon Acked-by: Minchan Kim -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751375AbdBAGMy (ORCPT ); Wed, 1 Feb 2017 01:12:54 -0500 Received: from LGEAMRELO12.lge.com ([156.147.23.52]:43692 "EHLO lgeamrelo12.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751004AbdBAGMx (ORCPT ); Wed, 1 Feb 2017 01:12:53 -0500 X-Original-SENDERIP: 156.147.1.121 X-Original-MAILFROM: minchan@kernel.org X-Original-SENDERIP: 165.244.249.25 X-Original-MAILFROM: minchan@kernel.org X-Original-SENDERIP: 10.177.223.161 X-Original-MAILFROM: minchan@kernel.org Date: Wed, 1 Feb 2017 15:12:48 +0900 From: Minchan Kim To: Vinayak Menon CC: , , , , , , , , , , Subject: Re: [PATCH 1/2 v3] mm: vmscan: do not pass reclaimed slab to vmpressure Message-ID: <20170201061248.GA9690@bbox> References: <1485504817-3124-1-git-send-email-vinmenon@codeaurora.org> <1485853328-7672-1-git-send-email-vinmenon@codeaurora.org> MIME-Version: 1.0 In-Reply-To: <1485853328-7672-1-git-send-email-vinmenon@codeaurora.org> User-Agent: Mutt/1.5.24 (2015-08-30) X-MIMETrack: Itemize by SMTP Server on LGEKRMHUB05/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2017/02/01 15:12:48, Serialize by Router on LGEKRMHUB05/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2017/02/01 15:12:49, Serialize complete at 2017/02/01 15:12:49 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 31, 2017 at 02:32:08PM +0530, Vinayak Menon wrote: > During global reclaim, the nr_reclaimed passed to vmpressure > includes the pages reclaimed from slab. But the corresponding > scanned slab pages is not passed. This can cause total reclaimed > pages to be greater than scanned, causing an unsigned underflow > in vmpressure resulting in a critical event being sent to root > cgroup. So do not consider reclaimed slab pages for vmpressure > calculation. The reclaimed pages from slab can be excluded because > the freeing of a page by slab shrinking depends on each slab's > object population, making the cost model (i.e. scan:free) different > from that of LRU. Also, not every shrinker accounts the pages it > reclaims. This is a regression introduced by commit 6b4f7799c6a5 > ("mm: vmscan: invoke slab shrinkers from shrink_zone()"). > > Signed-off-by: Vinayak Menon Acked-by: Minchan Kim