Message ID | 20200925124729.884757815@linuxfoundation.org |
---|---|
State | Superseded |
Headers | show
Return-Path: <SRS0=ikAt=DC=vger.kernel.org=stable-owner@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1D9F1C4741F for <stable@archiver.kernel.org>; Fri, 25 Sep 2020 12:53:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D93CD2072E for <stable@archiver.kernel.org>; Fri, 25 Sep 2020 12:53:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601038408; bh=mXM5vul0gInxI6sMmnz2iYhRDDBRaozhlxF2gwo5ya8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=dIFgEMBxlW5zGYxteAvwS6Wk38L/4QJkaBGfOtdyNQQO5nVN4on6Qei3R0CPAtbUP RYFN3tz3nTrDM4a23WS5qOkwcL5371OKN6ruAoWxO9hec8DQnkvzRCiWgTTyb6vyo3 4bZRd0nRuk7SsmB7ukcc0Sn8iH8xr3ktfy8vRtCs= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729410AbgIYMx1 (ORCPT <rfc822;stable@archiver.kernel.org>); Fri, 25 Sep 2020 08:53:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:58940 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729065AbgIYMx1 (ORCPT <rfc822;stable@vger.kernel.org>); Fri, 25 Sep 2020 08:53:27 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E7DE1206DB; Fri, 25 Sep 2020 12:53:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601038406; bh=mXM5vul0gInxI6sMmnz2iYhRDDBRaozhlxF2gwo5ya8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=q3sq4t/kM3cB4EaTin/Ouu/VDYhLLphAWFyyqXxYPQzIKn9xmCcOibGal6+HvYqhf 0fVi7jTo+nUOz5vrg1XgtkpuTeeEQuNJDybJWtVSTflA7ovuNx3wOWCo1CTAnGiMOg ok1BHWwnvS+u/EgHaWtN7TUkl+ohwtkZzExNKp6U= From: Greg Kroah-Hartman <gregkh@linuxfoundation.org> To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>, stable@vger.kernel.org, Michal Hocko <mhocko@suse.com>, Xunlei Pang <xlpang@linux.alibaba.com>, Andrew Morton <akpm@linux-foundation.org>, Chris Down <chris@chrisdown.name>, Johannes Weiner <hannes@cmpxchg.org>, Linus Torvalds <torvalds@linux-foundation.org>, Julius Hemanth Pitti <jpitti@cisco.com> Subject: [PATCH 5.4 42/43] mm: memcg: fix memcg reclaim soft lockup Date: Fri, 25 Sep 2020 14:48:54 +0200 Message-Id: <20200925124729.884757815@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200925124723.575329814@linuxfoundation.org> References: <20200925124723.575329814@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: <stable.vger.kernel.org> X-Mailing-List: stable@vger.kernel.org |
Series |
None
|
expand
|
--- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -2775,6 +2775,14 @@ static bool shrink_node(pg_data_t *pgdat unsigned long reclaimed; unsigned long scanned; + /* + * This loop can become CPU-bound when target memcgs + * aren't eligible for reclaim - either because they + * don't have any reclaimable pages, or because their + * memory is explicitly protected. Avoid soft lockups. + */ + cond_resched(); + switch (mem_cgroup_protected(root, memcg)) { case MEMCG_PROT_MIN: /*