Received: by 10.223.185.116 with SMTP id b49csp2633495wrg; Mon, 5 Mar 2018 06:20:32 -0800 (PST) X-Google-Smtp-Source: AG47ELtxV3aICPTBJfA3MqF1gUcc0PgYC+JePj++csc2hjAt86HCCjVBYiq54gKzPxbZN2CFvg5U X-Received: by 10.167.130.133 with SMTP id s5mr15349059pfm.238.1520259632791; Mon, 05 Mar 2018 06:20:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520259632; cv=none; d=google.com; s=arc-20160816; b=V9u3oz0nLnaI8Fq3WJHEf7rrIiSFeheWJ48Xa3Gb/XntLgxaxkFEumhRLIJmXUj9Hv Qb7gM9poSSfvWT5zczqRetviE1qLigmlW/zHY3BSOLDCoOO3W33/RzDZG0AYoj7VJ6CT WH4cddbu8JnlfIq5K+v+g+7LQTVcLcK6Be2KnhU/QKsATzpbgBxr8yXPYH2kpanh6QPq 7hRRlp2fFpfcrmXDIsEH0AFCAnFugprbU4+ZCm9MP62rDCZpqP5cg7gJ7WEuFUDAWXPS VSCQHsedRe0kCl+svfmxJLZWCfT/FWo31egdtfPncFZBCiOFMBU5Hz7hZO0Xljb+Vb9h VS7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:spamdiagnosticmetadata :spamdiagnosticoutput:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature:dkim-signature:arc-authentication-results; bh=5Zg8Mc8Z5fIGhhIWOrW9RWQ3kJ+mW3bYD+lhjNJaYuY=; b=cRQGOf+DiaVQNEp1+GOdHsAh9KlnN7cR4IN+AmvmLhuuz3+Nsbmp8EwsSB1oUXUN2I x03qZCZZEHirwLXdqq8Ms01x5X6Z68eIYmZiIqHCQhLrTsXPjig+eCKBrAsJMmXNrxYz 5wjsul02eMt7fhBeFmb/IvJi+KZEqqu8s5yk3vzTjShvEdLfzNodvZ68Vk6xcRIp1P+V rpw3GuwpUZR72nAJQ/zaS23dQ1dg7vy+TR+RUoQIBVEJDJbUgfFdD23yWPiMzcDxWfIa fibd6jfDofRGtln4srl76o5loXjlqOeC2Hrb9QP4Sd8/6puGTlSefPniJUJW05b4iu12 XO3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=f4LPSmi4; dkim=fail header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=ho0suI05; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f1-v6si9300778pld.744.2018.03.05.06.20.18; Mon, 05 Mar 2018 06:20:32 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=f4LPSmi4; dkim=fail header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=ho0suI05; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935232AbeCENsH (ORCPT + 99 others); Mon, 5 Mar 2018 08:48:07 -0500 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:55804 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934571AbeCENsD (ORCPT ); Mon, 5 Mar 2018 08:48:03 -0500 Received: from pps.filterd (m0044010.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w25DjoSV030438; Mon, 5 Mar 2018 05:47:54 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=facebook; bh=5Zg8Mc8Z5fIGhhIWOrW9RWQ3kJ+mW3bYD+lhjNJaYuY=; b=f4LPSmi4cQJufWzoMqHHBJgGHeDMpYrUpo2nl9Uz3iBCn9YMLClrERSTaGmf2tQVt8so i9MtYA9iARUVWICjgW3pslh54DOTexk616AV/2W5fhPx99D1bR0WrwTGp0WCeSjBTx71 ++Lz58BoYfnVrDMm4RwvRtiwxAw25GulrA4= Received: from maileast.thefacebook.com ([199.201.65.23]) by mx0a-00082601.pphosted.com with ESMTP id 2gh6h9831k-2 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 05 Mar 2018 05:47:54 -0800 Received: from NAM01-SN1-obe.outbound.protection.outlook.com (192.168.183.28) by o365-in.thefacebook.com (192.168.177.28) with Microsoft SMTP Server (TLS) id 14.3.361.1; Mon, 5 Mar 2018 08:47:14 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.onmicrosoft.com; s=selector1-fb-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=5Zg8Mc8Z5fIGhhIWOrW9RWQ3kJ+mW3bYD+lhjNJaYuY=; b=ho0suI05fYqGdQFDs8OpV3hkxaMrHjMTM6z2JiheU7F6h+x2bBZQnSDXweMvLBNZwoZDZiIDA2CL+OnNFTmdP0z48T/XWioNtjpmea5nf7c09RJ27fCAXeNGvrhou9rhhHPSoCaKS3K8fwP55P6O2biuuFw4D9ymZ/YLQYUPh9A= Received: from castle.DHCP.thefacebook.com (2620:10d:c092:200::1:ec6d) by SN2PR15MB1087.namprd15.prod.outlook.com (2603:10b6:804:22::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.548.13; Mon, 5 Mar 2018 13:47:11 +0000 Date: Mon, 5 Mar 2018 13:47:00 +0000 From: Roman Gushchin To: CC: Andrew Morton , Alexander Viro , Michal Hocko , Johannes Weiner , , , Subject: Re: [PATCH 2/3] mm: add indirectly reclaimable memory to MemAvailable Message-ID: <20180305134655.GA13118@castle.DHCP.thefacebook.com> References: <20180305133743.12746-1-guro@fb.com> <20180305133743.12746-3-guro@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20180305133743.12746-3-guro@fb.com> User-Agent: Mutt/1.9.2 (2017-12-15) X-Originating-IP: [2620:10d:c092:200::1:ec6d] X-ClientProxiedBy: AM3PR07CA0133.eurprd07.prod.outlook.com (2603:10a6:207:8::19) To SN2PR15MB1087.namprd15.prod.outlook.com (2603:10b6:804:22::9) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 1c6ec546-3e32-433f-f7c3-08d5829f9956 X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(5600026)(4604075)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603307)(7153060)(7193020);SRVR:SN2PR15MB1087; X-Microsoft-Exchange-Diagnostics: 1;SN2PR15MB1087;3:rBj6BkmcOCcJupmkshk8KYyyOSpgmeJL8GJlL2KdwreNnu8sPvg1pTdWEcuKVBC2sLwgkYos2n6YwezVeeWqa72K2mMW6vgOc6wFV67RS1qIuPmah4+WAKnjPKFTWvTOEbi+ixQ8oHnNAc07OLj2oMUJcJowGHV5h5IRfayQ6TQVbseOUW+QPQPkXqENnBnfS5NCWAQRAWctec8c23oZ03wzzJzLJ/EIlpY1+RfnOuKtvi7KqWuLKWVBOpu6hbWN;25:QLHNbomXGRyLJGK2t6FV2OAXjXDMX9t0OHUrxI2tmHR6oQvEjS1WwPDauLhr+H1GiVZyxjuoFR+VuW4RIHTh4//aXMnZtsiNsy+S7FxZfVnBR+bF+oEd7KwDIw9XrP2lO+LCIVpEodkwKXM3bzxmpMeMDsr2az0f6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mdv4Ljceqz/kQ69AUOiYnLBgMz0nZXlNeCYqTkmI1KLFMpZen8AZ/bVrR3cddeWRdLK7i8Zqd7AGtlAWkIvPgRKUqvDx2RHoia0LWK6vaTORZYkApRj0RarxFLaZEZ8yxiUNxwA+2ywzyqqzslRvo5FSuwdFAgelEdHL9d6/EtAQWDZLKlhIAzijzcNuyOY/SxZu8MG4Eq8FJrrEhD35K7e5fYjmftwCx8Pu5znl0JCBMqb6QBggUl3Vw03JzGk1dulddo49+vDlsnSYj4nChQg2P/OuOalFNxzaqX/rHTlU= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(9452136761055)(67672495146484); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040501)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3231220)(11241501184)(944501244)(52105095)(3002001)(6041288)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123564045)(20161123560045)(6072148)(201708071742011);SRVR:SN2PR15MB1087;BCL:0;PCL:0;RULEID:;SRVR:SN2PR15MB1087; X-Forefront-PRVS: 06022AA85F X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(376002)(366004)(396003)(346002)(39380400002)(39860400002)(189003)(199004)(25786009)(105586002)(97736004)(52396003)(86362001)(386003)(6506007)(76176011)(68736007)(52116002)(5660300001)(7696005)(6116002)(50466002)(23726003)(1076002)(47776003)(8936002)(54906003)(16526019)(229853002)(316002)(186003)(55016002)(4326008)(16586007)(58126008)(6666003)(6246003)(33656002)(81156014)(81166006)(2906002)(46003)(53936002)(6916009)(2950100002)(8676002)(7736002)(9686003)(106356001)(2351001)(2361001)(305945005)(478600001)(18370500001)(42262002);DIR:OUT;SFP:1102;SCL:1;SRVR:SN2PR15MB1087;H:castle.DHCP.thefacebook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; Received-SPF: None (protection.outlook.com: fb.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;SN2PR15MB1087;23:Xqp8GYAfFP/qwtsaDmCvspC+Wv4c0f88l+SaJmVzK?= =?us-ascii?Q?MEUeVk92X05iPm9Tc+NpaNCX8gogmSSLgAr03PKGsCU3bekejUZhpFs8zYGw?= =?us-ascii?Q?TlM1JJH/DnqyFA7xePbXUXF6MdCMMpy5OW8Ib4iwKMWXQxOU7YfUN9W8qNNH?= =?us-ascii?Q?Hx1+hy6VX2Te/78eeuTpeA1XBsQI/fQXmtyamX+S635RE52k6gMaWQLYhbVG?= =?us-ascii?Q?uuBtkvHCEh/Is3jMdKc0M7xug+6WPpgKGRLbMrwupfvQ+6SnOBaFjAPVUsrU?= =?us-ascii?Q?UX8lcxHVcOBoRdIllmF514sOi80A6+4ybyWfWtq40wvLL9By+GIJXu3QcNHM?= =?us-ascii?Q?0vACTX5C+hUxX/OpbkO8RXQ44JCrIko03JhuaYCR/l9jrqYfFOhmYUrdUeQb?= =?us-ascii?Q?+v6KNthJKvfP2cttYJvDRCVXWX3zcGzi0lrmBpXCyJ4nZhTuI2l2ibnQpbfB?= =?us-ascii?Q?ORLVBMV7mimgszP1THJyFiZuGPFxLq8ELo2fCoftOlBNzJYEBD9+mKCVO+KB?= =?us-ascii?Q?uTp0q6+WPWYdUejg38VhE0A57CQFvvloiIESoRL6JdwmyzLLX5F5TVcFKf8L?= =?us-ascii?Q?kdCED6b+dNr3dPi8+uSWwxZYMCWJAL59cKOR4xinr87/6G/ArC/1Fsl9fu5N?= =?us-ascii?Q?lwQ4iIXVJywbyRBMja7XsKYUZR36ls6VzM8ISKYyG7IQL/HUrERYUDMYFaFm?= =?us-ascii?Q?lgG/uev8BFG+DygmEfbityOoAb1MlWWMKlf29UQ2o3VLjEoRVBwI+661+WCJ?= =?us-ascii?Q?RULq6yb6D0J0jSYKmGmjvauhaVkH6v47g5+tZd/E8yq0T12Jn0atUyC/wK41?= =?us-ascii?Q?eq0s4VkAarue9ve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N0SwwuBVpfHOEQ9rWX7E+na4IubfplV/0rhEF8FitpNAXSq+gnlXEhf3l0evVxd9tM=;5:cFBLqQ8wkCPu4MDf8C2DI9oLYyUR2MubWRxZuxdQhEHE1l3q5VEG8gDhbEpc6cMgrDY3ZAGN1G5K3UXfqONeZaZITIfxgfnbnSxml1x3gQlzONu6r8azorHhKwiWkiejwkDxcVqCm11TNMSHhIOF4CYcxU6yEBEQkPnqNP0uuJ0=;24:BK4P3Y0ZJcMQXljhfVP/MRAUGgQmmzAJLzutcy4Gn0qiYVF7lkl1UogqngaB21GN+TfT+UHBY2Wk9mi9Qh8qdUwgvfrE4BrVBsgjnfFOyPk=;7:T2sASc8HW64gNnTAhVio9cSOBFx4GGxCGKamQuECFNSlP0Nq+SNZstyPVv+ldHltQNJ9nLIadN3cZypoaGOuOiOc6gLhQrYJI3F+pcHUJ77W7U2PZkhGpFlha1YZ7ESF9AdWyQWaMDiFoWgwYNN2ENGxMxUdNfvOT8ABfnnk7UnQpbd3KxPj5rfrFafZ6k2EOpnH1lGFDUyA+OkjaCPRzEXnqeRnmxXEiR/JWuvoTiAi8bLEWPATEi/pZGA73Nls SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;SN2PR15MB1087;20:5vhx7F/+pvY56eahTm1e+cXlJn7tdIEssLKl1MAUpRgX54lOm52bksYmiJm4FosyQ8m93XITosnCLCGbEoQxNjaG4wEwgPUFc1TJXfIvxvwRWWN9odEf5spgkr5Dlsfk0Qe/5j47bp1BqikTs73c8WzGEi2uwiT4BC5jDsj9kl4= X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Mar 2018 13:47:11.2598 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1c6ec546-3e32-433f-f7c3-08d5829f9956 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN2PR15MB1087 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2018-03-05_06:,, signatures=0 X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Please, ignore this particular patch, it was sent by mistake. On Mon, Mar 05, 2018 at 01:37:41PM +0000, Roman Gushchin wrote: > This patch adjusts /proc/meminfo MemAvailable calculation > by adding the amount of indirectly reclaimable memory > (rounded to the PAGE_SIZE). > > Signed-off-by: Roman Gushchin > Cc: Andrew Morton > Cc: Alexander Viro > Cc: Michal Hocko > Cc: Johannes Weiner > Cc: linux-fsdevel@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > Cc: linux-mm@kvack.org > Cc: kernel-team@fb.com > --- > mm/page_alloc.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > index 2836bc9e0999..2247cda9e94e 100644 > --- a/mm/page_alloc.c > +++ b/mm/page_alloc.c > @@ -4695,6 +4695,13 @@ long si_mem_available(void) > min(global_node_page_state(NR_SLAB_RECLAIMABLE) / 2, > wmark_low); > > + /* > + * Part of the kernel memory, which can be released under memory > + * pressure. > + */ > + available += global_node_page_state(NR_INDIRECTLY_RECLAIMABLE_BYTES) >> > + PAGE_SHIFT; > + > if (available < 0) > available = 0; > return available; > -- > 2.14.3 >