From patchwork Thu May 3 11:43:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roman Gushchin X-Patchwork-Id: 10377871 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3044A60327 for ; Thu, 3 May 2018 11:45:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 11042290A1 for ; Thu, 3 May 2018 11:45:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 01C47290AE; Thu, 3 May 2018 11:45:14 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0477C290A1 for ; Thu, 3 May 2018 11:45:13 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 74D0C6B000C; Thu, 3 May 2018 07:45:12 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 6D22F6B0012; Thu, 3 May 2018 07:45:12 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 526236B0010; Thu, 3 May 2018 07:45:12 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-qk0-f198.google.com (mail-qk0-f198.google.com [209.85.220.198]) by kanga.kvack.org (Postfix) with ESMTP id 2674A6B000A for ; Thu, 3 May 2018 07:45:12 -0400 (EDT) Received: by mail-qk0-f198.google.com with SMTP id d11so13045775qkg.20 for ; Thu, 03 May 2018 04:45:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:dkim-signature:dkim-signature:from:to:cc:subject :date:message-id:in-reply-to:references:mime-version :spamdiagnosticoutput:spamdiagnosticmetadata; bh=BEJDzgUVFcDVEDduYEr7Eg8yuuLZwWdoKtBiOgweTqY=; b=fGOtZAbwc9iHyD9AXAXTNyyFt27nZj8SkqR1JN+PS2qLCb2GWHjUhAfz0YSlRfD+Q6 U4qwqGc+o/7juSHM4oDy6V0FMPCl3A1FKx3efD1wY8bv2Qi7Fck+GW923+vfekPjWcFA Zl6xX9GEr4JEbvfgHNR1r3R1xF8L4jhf/JeCWzIBRPSGVWZECHcIeZcdBA7GlrPRSWMA WPWqea8QUvL/V4pWHtOgUkOZmV6pIYY1h3T6yKAgb/jh3zlx3oUTyULaVeebTPqq0Hs6 N9/LlTM7GG7HB06BI7INiIgH5Y454D59RKKcjGZPMJISdXl8BeX/wr97KXAGjzOHM1aH 0Udw== X-Gm-Message-State: ALQs6tCa1BLQsiMh+OXp2+w8vh5dwAj5trq7ai5YcR1jsNf3tMx/Mx0U wRxmaxekp3u7VhYwpN/vSuYAjlb+5Nmbl9adPyfemSiYyxWzfuiOBx9GSkW8UwjxBxuLZP+/YgD 7OBFPIZebmiuNjueyAf8uC6tBVrmCqRfhwbMybluAQAClyirsgCmT/z31QkdaM7FT0g== X-Received: by 10.55.31.24 with SMTP id f24mr18604515qkf.442.1525347911732; Thu, 03 May 2018 04:45:11 -0700 (PDT) X-Google-Smtp-Source: AB8JxZq4BpBF0UB2CtD/xGCvlqOjlwKMNUHlq2/PxpAF48BDRw0CZYHwEBYMyyMnEhuCHPOm6/Vy X-Received: by 10.55.31.24 with SMTP id f24mr18604485qkf.442.1525347911081; Thu, 03 May 2018 04:45:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525347911; cv=none; d=google.com; s=arc-20160816; b=hVznIw6EUOutrMG1J0YlQYAxaW5trIH+mlTV4lkY9bVepMUu5Ya9JsL92H/4uGVVNe xUknrbj1YEaO2ir4RQr9DS+MTnl+3gW0hl6aYeMn81wwQF+UvthEXiDZEQxpREb7025z E7MIyINiySv2dD/n/+SmNlwwdd8LBlXDxRaIiqa0za6KHWHmts+DWimfnfnG/mX2trbb LmjL+BYgfBvm0botKG0ojgMpf1xVxqQ9tV44gWFN2yGAUx7GtPtiOcAaeEvyKagMcmES 6BMJORHbQXN6M2SY81O+dAaRiK7Xxs8SiWRAxa+KGf8V14LiKXGyUx2UrCQaUUc+vT4h 0j6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=spamdiagnosticmetadata:spamdiagnosticoutput:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :dkim-signature:arc-authentication-results; bh=BEJDzgUVFcDVEDduYEr7Eg8yuuLZwWdoKtBiOgweTqY=; b=OI+aIDhWyx81nYHAARnVCSkm52WaRuh++6xu5HfimeJUHoGVcLvrOHKmSqzNIk8M2B yQbW1ixAadeUYfd3etwlH7eC+Ep9ftaDZb0+Pzyr4hKoYC3HGUw+ZcKwQJiAHXR51SgM wmg3rorCOMzeisfS6c+w30lH0kq52+OiRkDOIjXozdaw1Pgo5HmvgpgvEqoj6t5hDD7u 8yR85xTBDZ43Uf2GytLQDVNUaoh/hT7Af/9upYxMBCLWaFyPnX7iX6zZnDrZsBUR44ee x+n/CASUVBouWUfFswhkHDgbL2r3Aw2MMY4AwD75fAULVh1spAtGMjT1EEsBekaaZhVy SLkQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=C0kDMCJ5; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=iejiaxh+; spf=pass (google.com: domain of prvs=8661c9bccc=guro@fb.com designates 67.231.145.42 as permitted sender) smtp.mailfrom=prvs=8661c9bccc=guro@fb.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Received: from mx0a-00082601.pphosted.com (mx0a-00082601.pphosted.com. [67.231.145.42]) by mx.google.com with ESMTPS id 11-v6si5261326qvq.149.2018.05.03.04.45.10 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 May 2018 04:45:11 -0700 (PDT) Received-SPF: pass (google.com: domain of prvs=8661c9bccc=guro@fb.com designates 67.231.145.42 as permitted sender) client-ip=67.231.145.42; Authentication-Results: mx.google.com; dkim=pass header.i=@fb.com header.s=facebook header.b=C0kDMCJ5; dkim=pass header.i=@fb.onmicrosoft.com header.s=selector1-fb-com header.b=iejiaxh+; spf=pass (google.com: domain of prvs=8661c9bccc=guro@fb.com designates 67.231.145.42 as permitted sender) smtp.mailfrom=prvs=8661c9bccc=guro@fb.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=fb.com Received: from pps.filterd (m0148461.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w43BXPoa031244; Thu, 3 May 2018 04:45:04 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=facebook; bh=BEJDzgUVFcDVEDduYEr7Eg8yuuLZwWdoKtBiOgweTqY=; b=C0kDMCJ5UGmZXClHSVWYSAG2qPFhqb4MxymZ6V0fyiDgNtHve//68QXuUmeCnZyiCKUn 9DIzfqe15KMCPQ8lgWIERvEdcmwAE/5vHLULoKwR8ssHgvWF6TwMD7jMraTfUATpsqPf IzVdwh6ht9qUFBXafCZixMptcEW4l++MY9g= Received: from maileast.thefacebook.com ([199.201.65.23]) by mx0a-00082601.pphosted.com with ESMTP id 2hqye38ay9-2 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 03 May 2018 04:45:04 -0700 Received: from NAM02-BL2-obe.outbound.protection.outlook.com (192.168.183.28) by o365-in.thefacebook.com (192.168.177.25) with Microsoft SMTP Server (TLS) id 14.3.361.1; Thu, 3 May 2018 07:45:01 -0400 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=BEJDzgUVFcDVEDduYEr7Eg8yuuLZwWdoKtBiOgweTqY=; b=iejiaxh+8blkx6uXv0kXr1tmUi/7BQrKO3HHRi7a8zWgl1kgGqjZvCcOsij9nZ3arDOdCZsyTSs4ep0NYRjh7G70D8b5WWWIujMP9MVzO5YexFQLGgOVXbzyuvMymLRjFU6eBkleG5nF+1nKnO0SzqGupFMlEJdZYgwkmXOCwO8= Received: from castle.thefacebook.com (2620:10d:c092:200::1:d1b9) by CO1PR15MB1079.namprd15.prod.outlook.com (2a01:111:e400:7b66::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.715.18; Thu, 3 May 2018 11:44:41 +0000 From: Roman Gushchin To: CC: , , Roman Gushchin , Johannes Weiner , Michal Hocko , Vladimir Davydov , Tejun Heo Subject: [PATCH v3 2/2] mm: ignore memory.min of abandoned memory cgroups Date: Thu, 3 May 2018 12:43:58 +0100 Message-ID: <20180503114358.7952-2-guro@fb.com> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180503114358.7952-1-guro@fb.com> References: <20180503114358.7952-1-guro@fb.com> MIME-Version: 1.0 X-Originating-IP: [2620:10d:c092:200::1:d1b9] X-ClientProxiedBy: AM5PR0202CA0024.eurprd02.prod.outlook.com (2603:10a6:203:69::34) To CO1PR15MB1079.namprd15.prod.outlook.com (2a01:111:e400:7b66::9) X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:CO1PR15MB1079; X-Microsoft-Exchange-Diagnostics: 1; CO1PR15MB1079; 3:kY8zUXG93gCqxTSY8DrldqzUX5Lca0OAepJ6ITq++AysKSWfdJBtKG2/OrJt/vAKcekYJGw0euKF61DglLaCaURYc0SltpZGs64W+VbMO/CjtxSq+yMFiFpqzCo3LWkNkhWJen8LLryhpB6/27LJyq9khYIv+dlCBdLBYIXBmpw+pjBFrT6RGp3+0gdjIAw5tmigmf0UJe1GKb4ta+LawDVHKprnYSqMZ96jsQ5aDGeIqOzZkvZAumQo3+UPo/7Z; 25:SWS9JzMRXwnYzH89nnuUZBU44cC0Av/9r6WMUKWZ0QQYbYUhZx6XvJM4dkghIow1t1V/OOJ62xprC9B4qtPRFTpemwLtF84f0xqmoq97osjtjHvDRY9QqucB4D/rnSOgtn9kCleSWoQ/khEIDb0kwYgMhxGzEKVApzlEXJ2nylOM0UjAzBBNVEOj9yeIt4QJjd5808ac/oqX2wBJA/zwaqqQxZHL9tw4CXEQ+CFVmxQzB4hq4e9efwD+AwwYylq7rqo9rnlecXP5cFizBVEW+vK19pv5klDee/AYd2Hbfn2fMcH5X+6dtdrWwi7uB9pSVIWuIfDdWqPr83p0asM7IA==; 31:RNt0iGq3HIcM4wOtaaUmZwNdXPMK9lTGX3/koOhYepWlQhbI98guDE1DdwWxaursUJ1eotLc0BonMTX8eWAdVRo+B6VqWTqdBOXf6jprFW/ELFbRl2k+mcZPAgyK7cln1IqAKXvjmZQNT2wx2pUNn7a2GV+cA6e+EgWl9SyyNHoyGC8nDD+AuMzCnocv8c9iWe7DKgnVveOcBOGrVA+18VUyP62yOJc7OCpIQGicyVw= X-MS-TrafficTypeDiagnostic: CO1PR15MB1079: X-Microsoft-Exchange-Diagnostics: 1; CO1PR15MB1079; 20:O2IUfD0b8IDJApQh/JAFS85SUNt/3pWVKz4IKDbLtjjLcg7ui763XJcqbT4pn2cyRDeiYoOJxdizNLVfQhepKkCQ+PuCg7f0ccsRGSQ94npC7aglNtt53cBocTtbWzzYxvLV84Mawb5Hwmz4yFJHI52f+ouVXjtgqUWJCoH/vYPROt6vvBMbeLgC0FLt6ihERocvaBXjdSTIVLRRhG+FTSUDY8rFXH4FdhAE1Gv97HTTmurx3ut04Lj/KEVcgegmzbcQ8PuRgRiPfy1xlnP3Oq4AEKIsYEP5vUDpIzYzUJ+1WhR60R8QFTduGAuisSCs5K739L+B7hmV0+OaMDGkAfmm0QiBzkxgqj4gNilCYJREMb1ZYA/EijpJnF301QV8ZSI0Lu2Tc1QpCvT2dWHs6Ou/MGV68DUA0jnnqr1VnG0msul5dVyPDdfUxuuoMYHKTa17Dutu67d9A3suBtLE7rxr570HETEvGkfZTkoaefzniivUVlh81g2YUav7DsRH; 4:Uo0a68ij+ex3PBC6jgLxYX7h2HqDmHpTtakItVbY1vPcKQNGUeLt/pAggHKXOqsehOA4I+lrALEVf1jqpR3niGP4eYTFlPG46sM53+XALy8h6s20gKm2W0CP/Tr4WvULMGt/L2/LxHu8vrCHoT/gq5p9SmaEOU8rCmz7Ou6SUaQMEYULkpoc9/rTRP9Q4VHLFFEsFfS9YiOuKjohYiryY0BC3NmV817BaFquGH4lZouXDfq0/Tu1GVQXl75zgx+ZCf0jAR6XDeUi5X0KSPZQBa+NZsZY6yzWujbzfQ+BRppHHcg+nWTCGHORvXjSjQrJ1qdt1COA91ZTmpl8bMp/7+tccHdKYT2eVLmEycq8a7U= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(85827821059158)(67672495146484); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(10201501046)(3002001)(93006095)(93001095)(3231254)(11241501184)(944501410)(52105095)(6041310)(20161123562045)(20161123560045)(20161123564045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:CO1PR15MB1079; BCL:0; PCL:0; RULEID:; SRVR:CO1PR15MB1079; X-Forefront-PRVS: 066153096A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(346002)(376002)(39380400002)(396003)(39860400002)(366004)(199004)(189003)(2361001)(59450400001)(97736004)(106356001)(50466002)(16526019)(305945005)(68736007)(4326008)(186003)(2351001)(86362001)(105586002)(2906002)(5660300001)(48376002)(53936002)(53416004)(1076002)(46003)(39060400002)(2616005)(11346002)(446003)(476003)(486006)(52396003)(52116002)(69596002)(47776003)(25786009)(6916009)(81166006)(81156014)(6512007)(6116002)(6506007)(36756003)(76176011)(6666003)(478600001)(8676002)(386003)(50226002)(51416003)(8936002)(54906003)(316002)(7736002)(6486002)(16586007)(42262002); DIR:OUT; SFP:1102; SCL:1; SRVR:CO1PR15MB1079; H:castle.thefacebook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: fb.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CO1PR15MB1079; 23:Ku7zxunQ5rRy52/sH1p6jqLbyyTGdBoRksQ/ofUat?= =?us-ascii?Q?tobE+etebaqAVfle3JsljEIzu4SP93QOu7FuzATVKpbmP27T+e+WYFk+VgN6?= =?us-ascii?Q?la8+bkKwDn48EbkDnZE2EjvSBS3Org7JVqn1XHyTzdMy49SlWTI8mNh+efxW?= =?us-ascii?Q?kDV80/IRjAZXMxF0WOHxHG/jR1D0Oglc/rB5JSDOuQqwCnmxP7+wbA7W5sxX?= =?us-ascii?Q?M++QsGfxnCK8SizP/LAiZ18Xcv2npZEmpirhmSZASUaw+w/EaN63jsA2HYZU?= =?us-ascii?Q?tjGeiPc0fAB5KDoYUNVifZ3OImbC/r7B8LAKIDPrcJ0Ds/UFmxNiN3KZsxZw?= =?us-ascii?Q?hxJzO+Dyz7H8UKjG7f8YHppnAJ+H/GGND8TPddIQukbtt4n89d0srdO/7cop?= =?us-ascii?Q?CIO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eI+Tpo= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CO1PR15MB1079; 7:VR3b1S6MhghVYUXq3+iSfdUHiDKb5T3X5rXsu62nsYoL3t/edTqJaxnLdJat/DNsEgM008Jhi8akbTrPSn1jpr7yFw+ZWOMcLqkNneXCaU3asXGnk0n1Mytzdl0bnjlQteBVh8Th/SZ+0JyxEQYxLYLxnFfCU9SiuOuPt6D1TN7QY8/k3wk6CElMBDFlvb/6ggA4+GXPbra6Zu2q2J/MeNs5MOmsJ6D5cf8c+IAfhPspxuZt4dpWQy184Vrif5um; 20:tJoXGeXyqUHHg2Hd0eK+S/lPVlX8ZUa0V6NzYWekQRgJ5r8DpCTnKwbh3nUoUfYU8XP5Mk1U7uYkYVx4K88chDu8B3gX2xUnT3s0tpGLWgoxkzqIltfeSBP9wdMgWSLfnm7IQeXQz2xnt6LpNpJgGZ6Zbf8o8yzJ47/a5GH6mAE= X-MS-Office365-Filtering-Correlation-Id: 1ef2bc37-62cc-4eee-6810-08d5b0eb4334 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 May 2018 11:44:41.7384 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1ef2bc37-62cc-4eee-6810-08d5b0eb4334 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR15MB1079 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2018-05-03_06:, , signatures=0 X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe 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: X-Virus-Scanned: ClamAV using ClamSMTP If a cgroup has no associated tasks, invoking the OOM killer won't help release any memory, so respecting the memory.min can lead to an infinite OOM loop or system stall. Let's ignore memory.min of unpopulated cgroups. Signed-off-by: Roman Gushchin Cc: Johannes Weiner Cc: Michal Hocko Cc: Vladimir Davydov Cc: Tejun Heo Acked-by: Johannes Weiner --- include/linux/memcontrol.h | 10 ++++++++++ mm/vmscan.c | 6 +++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h index 3b65d092614f..7d8472022aae 100644 --- a/include/linux/memcontrol.h +++ b/include/linux/memcontrol.h @@ -374,6 +374,11 @@ static inline void mem_cgroup_put(struct mem_cgroup *memcg) css_put(&memcg->css); } +static inline bool mem_cgroup_is_populated(struct mem_cgroup *memcg) +{ + return cgroup_is_populated(memcg->css.cgroup); +} + #define mem_cgroup_from_counter(counter, member) \ container_of(counter, struct mem_cgroup, member) @@ -835,6 +840,11 @@ static inline void mem_cgroup_put(struct mem_cgroup *memcg) { } +static inline bool mem_cgroup_is_populated(struct mem_cgroup *memcg) +{ + return false; +} + static inline struct mem_cgroup * mem_cgroup_iter(struct mem_cgroup *root, struct mem_cgroup *prev, diff --git a/mm/vmscan.c b/mm/vmscan.c index 50055d72f294..5e2047e04770 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -2549,8 +2549,12 @@ static bool shrink_node(pg_data_t *pgdat, struct scan_control *sc) /* * Hard protection. * If there is no reclaimable memory, OOM. + * Abandoned cgroups are losing protection, + * because OOM killer won't release any memory. */ - continue; + if (mem_cgroup_is_populated(memcg)) + continue; + break; case MEMCG_PROT_LOW: /* * Soft protection.