Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753825AbbKYQax (ORCPT ); Wed, 25 Nov 2015 11:30:53 -0500 Received: from shards.monkeyblade.net ([149.20.54.216]:33706 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753733AbbKYQau (ORCPT ); Wed, 25 Nov 2015 11:30:50 -0500 Date: Wed, 25 Nov 2015 11:30:48 -0500 (EST) Message-Id: <20151125.113048.45218641761530031.davem@davemloft.net> To: hannes@cmpxchg.org Cc: akpm@linux-foundation.org, vdavydov@virtuozzo.com, mhocko@suse.cz, tj@kernel.org, eric.dumazet@gmail.com, netdev@vger.kernel.org, linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com Subject: Re: [PATCH 13/13] mm: memcontrol: hook up vmpressure to socket pressure From: David Miller In-Reply-To: <20151124215940.GB1373@cmpxchg.org> References: <1448401925-22501-1-git-send-email-hannes@cmpxchg.org> <20151124215940.GB1373@cmpxchg.org> X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Wed, 25 Nov 2015 08:30:50 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1552 Lines: 32 From: Johannes Weiner Date: Tue, 24 Nov 2015 16:59:40 -0500 > Let the networking stack know when a memcg is under reclaim pressure > so that it can clamp its transmit windows accordingly. > > Whenever the reclaim efficiency of a cgroup's LRU lists drops low > enough for a MEDIUM or HIGH vmpressure event to occur, assert a > pressure state in the socket and tcp memory code that tells it to curb > consumption growth from sockets associated with said control group. > > Traditionally, vmpressure reports for the entire subtree of a memcg > under pressure, which drops useful information on the individual > groups reclaimed. However, it's too late to change the userinterface, > so add a second reporting mode that reports on the level of reclaim > instead of at the level of pressure, and use that report for sockets. > > vmpressure events are naturally edge triggered, so for hysteresis > assert socket pressure for a second to allow for subsequent vmpressure > events to occur before letting the socket code return to normal. > > This will likely need finetuning for a wider variety of workloads, but > for now stick to the vmpressure presets and keep hysteresis simple. > > Signed-off-by: Johannes Weiner Acked-by: David S. Miller -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/