From patchwork Fri Oct 26 11:18:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sasha Levin X-Patchwork-Id: 10657241 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9978F14BD for ; Fri, 26 Oct 2018 11:19:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 86CBE2BB72 for ; Fri, 26 Oct 2018 11:19:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7AD202BF53; Fri, 26 Oct 2018 11:19:11 +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 1EAF92BB72 for ; Fri, 26 Oct 2018 11:19:11 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 278336B0306; Fri, 26 Oct 2018 07:19:10 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 2275C6B0308; Fri, 26 Oct 2018 07:19:10 -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 13DFA6B0309; Fri, 26 Oct 2018 07:19:10 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pg1-f199.google.com (mail-pg1-f199.google.com [209.85.215.199]) by kanga.kvack.org (Postfix) with ESMTP id CBC0A6B0306 for ; Fri, 26 Oct 2018 07:19:09 -0400 (EDT) Received: by mail-pg1-f199.google.com with SMTP id d8-v6so406431pgq.3 for ; Fri, 26 Oct 2018 04:19:09 -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:from:to:cc:subject:date :message-id; bh=m6zGwk8xGgXP90QdkYugSzVUdeFa7OFuq/FVKy3ozJU=; b=ttK3w9jIDjb0fM8eRF2xFsWXtg/Mdn5mSZ+/0g8gJaYK/FJvUcoZIG8ddZOKiJ2mtC csXIiAOSzI0upJ41j9u2O1LNtrSS+eMVFr/2Bl9ZV7M2zoPd7j6jAVM4u7ba1tL6cXk5 XNbh0nnSHxIZtKnlaAKs7ozT+0S1rdBQdZ1QbOgvPvEIYJbfPc7HfiB+7wpm501nMzbL LTL6Q6cTGyfNyYzAmwgIpnaD1ZHe3Vp4n0l305BEotnuaOUyWQY4gZiFdilaVptccRiu krHem3XYcSetECPXm1E/uLD8NxpZ/mmkdWNeDQxLh3noJVMcXVkvLjVGIB0uEsxiCrpX vTDA== X-Gm-Message-State: AGRZ1gJh0luYQ8RFyRZxrsEeRL2Rn8/Gnc6AV5Pc839Iyg8Yt7zKizIJ 8Tl+8LDPNLFoiKXJdikWbl+OGh0xPgEn94NrXu9QTWPDCHKaLUlLIQdnIctSl8TtMaHC+5bERc5 YpZc8i6z1QZIrPRPjJxs4+0ClMvPK3RV51VSYpbPosXff4UpW05LmxG56mLJGv4Gn4Q== X-Received: by 2002:a65:6447:: with SMTP id s7mr3064244pgv.226.1540552749452; Fri, 26 Oct 2018 04:19:09 -0700 (PDT) X-Google-Smtp-Source: AJdET5dJ5FV18Aav6uS6EZaaMt4S+tC94Fd9HasqgOPl4k9ZqKg1U8+4c5lOvihJ0HXmSqlK239M X-Received: by 2002:a65:6447:: with SMTP id s7mr3064193pgv.226.1540552748577; Fri, 26 Oct 2018 04:19:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540552748; cv=none; d=google.com; s=arc-20160816; b=YoSSsiRxVtcN1gKi6CtzaKs9dUIQdQAPBpUsH2GR5YvIeV1SL+UMkcpGOAkF3CxIdi OSZDlXzuGji3EgUmb2t1IFjodYXCzkGz2RHh9dLf6en+/boAJwxgdmuD3HVpA/n+UTn8 90hcLgyUV28cFBVelhiMJxPZxVYAa9TX5aSgYAOEx6hEeeEc7CXPyovzgDYioIie0M+F ymrEeGVvDymlVEFke0+IA4GgTMOA+FtZg8+6CapPi+S5YbOI1vOmqcQ2N1iiVxNrppyX SpLdqdtpu/GBQbF3CVywjDj1zwvg3yNATGR67iK21VChwF04su/a0wi7mT67TIbo0Be2 7bQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:dkim-signature; bh=m6zGwk8xGgXP90QdkYugSzVUdeFa7OFuq/FVKy3ozJU=; b=0teh11n2Ets3gAuGOT+O2h3SEzInPzdeXS3NEQ9iV6rtdjgBc5J3VodyRBuzxaiUGP lJaWxd8nDhaAN+E0i0fy4JxjqKoPjuKkBESTmtCt6JyWW8ZzwpRiP8YuTy8sFLGMVcfR S4sEwAZ9JMLRDLW+yMJYJx+D9DpDUj2i8BIYYXZjiI6sTIiz9gp7f5hRhMNbYbkHa8BS QDR2zek9BBeZHgjsOnnA76A4E+/Yn6pjUl5HTju9MM7v4ylk92M3X05mI5q9Yp9Glqle iLf14qANZh4LWtiS/bJAKiSJj4AMUyd1y0rwhxXpNkcAS0e/8IyOaAs8rQsbWyIP7tAj IvVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=s9ONEDmS; spf=pass (google.com: domain of sashal@kernel.org designates 198.145.29.99 as permitted sender) smtp.mailfrom=sashal@kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from mail.kernel.org (mail.kernel.org. [198.145.29.99]) by mx.google.com with ESMTPS id d2-v6si10541046pgo.299.2018.10.26.04.19.08 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 Oct 2018 04:19:08 -0700 (PDT) Received-SPF: pass (google.com: domain of sashal@kernel.org designates 198.145.29.99 as permitted sender) client-ip=198.145.29.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=s9ONEDmS; spf=pass (google.com: domain of sashal@kernel.org designates 198.145.29.99 as permitted sender) smtp.mailfrom=sashal@kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from sasha-vm.mshome.net (unknown [167.98.65.38]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id F19FE207DD; Fri, 26 Oct 2018 11:19:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1540552748; bh=RrmoJXHdCnd753ExHHEf/75yqhVuVoGGnXzBRcGO7Fw=; h=From:To:Cc:Subject:Date:From; b=s9ONEDmSMY7o1KkgOwazMvNw0YQ3KoC+gxcdZyJ+enPlTPYNTuzxaRm5Lapqa72HS BPSflsxe7TZMHxGLLQl754hXkSJglxLWSLh+0aGedlj3m1BmrY02SWxF3fEOc9P+K6 pVrjgrnBjMBOpxj4tKVP62UuUNN/Cj8czq8yqhvg= From: Sasha Levin To: gregkh@linuxfoundation.org Cc: stable@vger.kernel.org, linux-kernel@vger.kernel.org, akpm@linux-foundation.org, linux-mm@kvack.org, Sasha Levin Subject: [PATCH 4.18] Revert "mm: slowly shrink slabs with a relatively small number of objects" Date: Fri, 26 Oct 2018 07:18:59 -0400 Message-Id: <20181026111859.23807-1-sashal@kernel.org> X-Mailer: git-send-email 2.17.1 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 This reverts commit 62aad93f09c1952ede86405894df1b22012fd5ab. Which was upstream commit 172b06c32b94 ("mm: slowly shrink slabs with a relatively small number of objects"). The upstream commit was found to cause regressions. While there is a proposed fix upstream, revent this patch from stable trees for now as testing the fix will take some time. Signed-off-by: Sasha Levin --- mm/vmscan.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/mm/vmscan.c b/mm/vmscan.c index fc0436407471..03822f86f288 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -386,17 +386,6 @@ static unsigned long do_shrink_slab(struct shrink_control *shrinkctl, delta = freeable >> priority; delta *= 4; do_div(delta, shrinker->seeks); - - /* - * Make sure we apply some minimal pressure on default priority - * even on small cgroups. Stale objects are not only consuming memory - * by themselves, but can also hold a reference to a dying cgroup, - * preventing it from being reclaimed. A dying cgroup with all - * corresponding structures like per-cpu stats and kmem caches - * can be really big, so it may lead to a significant waste of memory. - */ - delta = max_t(unsigned long long, delta, min(freeable, batch_size)); - total_scan += delta; if (total_scan < 0) { pr_err("shrink_slab: %pF negative objects to delete nr=%ld\n",