From patchwork Thu May 10 09:53:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kirill Tkhai X-Patchwork-Id: 10391537 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 7E06060353 for ; Thu, 10 May 2018 09:53:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6DFD4288AE for ; Thu, 10 May 2018 09:53:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 626A3289BF; Thu, 10 May 2018 09:53:39 +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 A12A5288AE for ; Thu, 10 May 2018 09:53:38 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7DCFA6B05E7; Thu, 10 May 2018 05:53:37 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 789BC6B05E9; Thu, 10 May 2018 05:53:37 -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 6025B6B05EA; Thu, 10 May 2018 05:53:37 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pg0-f71.google.com (mail-pg0-f71.google.com [74.125.83.71]) by kanga.kvack.org (Postfix) with ESMTP id 185896B05E7 for ; Thu, 10 May 2018 05:53:37 -0400 (EDT) Received: by mail-pg0-f71.google.com with SMTP id m8-v6so629234pgq.9 for ; Thu, 10 May 2018 02:53:37 -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:subject:from:to:date:message-id :in-reply-to:references:user-agent:mime-version :content-transfer-encoding:spamdiagnosticoutput :spamdiagnosticmetadata; bh=+hHnX3Y6CMsne/gWPRYTEBzO6gul6SYjBQeAjVJMMJo=; b=GQ823baByswBVfDXV3g2vzwHAopvcYCyHu7R70a+gzYxIVXQwKLKhF1164y7wEiwRn npwDGbUcy9+OjX0SCft4HYl2V1eVu57BXp1S9w92TUHfsleU7aJ1mK/cQPLfHZ2t0X/9 SFMCnYi9xCDEdYGDeQy401jj53Mk1Y4iTG6WtU54YTAGTsZdxt7tsH14vmmZEhL7MHKx 7WbLiQdgfhaWVb+NitEcFcG7M5lImAjbVJZp+lOu3fBkwRrZO8Ug6XsXrO3odnuD24LJ 8CJE+TLwAVG6TxK8kXUhQ4snvjePzJ5D3KATyBJiumhuaHNnSczJghHebBHS17w/AEJO bcWw== X-Gm-Message-State: ALKqPweTm6ItqHgruX5QVHtVxWxjIayTgSU0VXXjWWGPRZGX0WkEzsAy 1tgPhyc+szokqyOyzi8uQ8f5yj+/rMT6Q/41ShFy8A4iHTUvJ7C2O9F/lBV7ZnfJwAFbzbMvC8G yYQ7gTHZENP6qwoz1EpSIzW/WdgbSzRUsF3S0UMiKJFxL4XOxavHJE8oa1evHPiEAkA== X-Received: by 2002:a17:902:30a3:: with SMTP id v32-v6mr725575plb.123.1525946016781; Thu, 10 May 2018 02:53:36 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoeLF6hIBXtUOhnf69Iyb7qtCw1XGCZfFQFiRcUOMrNS4DfFubiMLYAsHFxzuKudpBRadx0 X-Received: by 2002:a17:902:30a3:: with SMTP id v32-v6mr725548plb.123.1525946016097; Thu, 10 May 2018 02:53:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525946016; cv=none; d=google.com; s=arc-20160816; b=re7uCja7wTjlWp6Jyrb0S3VD4PZ9l2ZV7neXaZHBihx9hbosBAGLiqctAxwda+sc1h O7mzcYDKEBsZu59TDNZOE/8jbcpZAngRbADuM3hKJ19XyK/nz/URpE0TjbY+gtPUuu8w Hw77uRjFP98F79riB4KIASkZw5Q+THWgzEP3uOfjKOurjmUiZNnCmGjAtIY22XVxEdlx nKGVv3Pj0yFbn4CXX0OHr53EZ+jlOLKbS44OrQkTk1izqCWkRWIzeXw02Ul8yaNh1V4s WpLYgDKPavrToCCtRFMMZQENZNZK/lQqyhTGptT6PKu4bIwhJz9qXFR1fGdsg/eDKhX+ hasQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=spamdiagnosticmetadata:spamdiagnosticoutput :content-transfer-encoding:mime-version:user-agent:references :in-reply-to:message-id:date:to:from:subject:dkim-signature :arc-authentication-results; bh=+hHnX3Y6CMsne/gWPRYTEBzO6gul6SYjBQeAjVJMMJo=; b=F2L9och84fZzb6/L+1I0uVBNB3eISP2ZyNnD1N+vMTjOMa4ITJDxeY9UWiBB8R+AGD HRAbVkyrPghoIDeKrNkNJoUcCoFceP3d+GMU6G05DYGNj1ddg2qI+BeDX65/3r+F5+Dt QJ3dt+l9AoBg1jHGuacywNaq/w4lWZMvkz9/4ppIxZbo4W5d5aOiIl6ZjBrQei7jK5Mb s4hd8f8GYsSUOHoJc66+yP3ieaYwWfCdErjo8w+QurHXMrYio1hm/4I1t7/vcqgVYCh9 AJNvT0qvvByA7K11Kfx4tQrzVNOTGtEK2NksJ6jlswg5beDS29k6rqz8lcMtvf3vVBdL 6f+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector1 header.b=aGxL2cji; spf=pass (google.com: domain of ktkhai@virtuozzo.com designates 104.47.2.112 as permitted sender) smtp.mailfrom=ktkhai@virtuozzo.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=virtuozzo.com Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0112.outbound.protection.outlook.com. [104.47.2.112]) by mx.google.com with ESMTPS id 1-v6si454831plx.236.2018.05.10.02.53.35 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 10 May 2018 02:53:36 -0700 (PDT) Received-SPF: pass (google.com: domain of ktkhai@virtuozzo.com designates 104.47.2.112 as permitted sender) client-ip=104.47.2.112; Authentication-Results: mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector1 header.b=aGxL2cji; spf=pass (google.com: domain of ktkhai@virtuozzo.com designates 104.47.2.112 as permitted sender) smtp.mailfrom=ktkhai@virtuozzo.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=virtuozzo.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=+hHnX3Y6CMsne/gWPRYTEBzO6gul6SYjBQeAjVJMMJo=; b=aGxL2cjivmjZ1mn8368J76BNHwxmhw6fGOvqBPkwMny9EBADG1tSpt6PqQd7eGs6ssSfjIdlQgEzwwr95cHpNAvvkbDYjr3gV+d3k6MlQ/bJniMAMrcfCfe6MgE2uxvv3ephc6dJPGpMV9iRC5K0SVvGILsqZNyYg3WwmHtGfqs= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=ktkhai@virtuozzo.com; Received: from localhost.localdomain (195.214.232.6) by HE1PR0801MB1338.eurprd08.prod.outlook.com (2603:10a6:3:39::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.755.16; Thu, 10 May 2018 09:53:27 +0000 Subject: [PATCH v5 08/13] list_lru: Pass dst_memcg argument to memcg_drain_list_lru_node() From: Kirill Tkhai To: akpm@linux-foundation.org, vdavydov.dev@gmail.com, shakeelb@google.com, viro@zeniv.linux.org.uk, hannes@cmpxchg.org, mhocko@kernel.org, ktkhai@virtuozzo.com, tglx@linutronix.de, pombredanne@nexb.com, stummala@codeaurora.org, gregkh@linuxfoundation.org, sfr@canb.auug.org.au, guro@fb.com, mka@chromium.org, penguin-kernel@I-love.SAKURA.ne.jp, chris@chris-wilson.co.uk, longman@redhat.com, minchan@kernel.org, ying.huang@intel.com, mgorman@techsingularity.net, jbacik@fb.com, linux@roeck-us.net, linux-kernel@vger.kernel.org, linux-mm@kvack.org, willy@infradead.org, lirongqing@baidu.com, aryabinin@virtuozzo.com Date: Thu, 10 May 2018 12:53:25 +0300 Message-ID: <152594600514.22949.13772959733696297685.stgit@localhost.localdomain> In-Reply-To: <152594582808.22949.8353313986092337675.stgit@localhost.localdomain> References: <152594582808.22949.8353313986092337675.stgit@localhost.localdomain> User-Agent: StGit/0.18 MIME-Version: 1.0 X-Originating-IP: [195.214.232.6] X-ClientProxiedBy: AM6PR0402CA0005.eurprd04.prod.outlook.com (2603:10a6:209::18) To HE1PR0801MB1338.eurprd08.prod.outlook.com (2603:10a6:3:39::28) X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:HE1PR0801MB1338; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0801MB1338; 3:o67QlVsdZu+cpWiZSHx1xSQ94dCkvw6aLFXIh15Zt7KiiYQ+LzKB2w76opJ+akElrEZD+lujXUHwH9t92Q5oy4jA5eo6udO0IKRVbsj5dOWhszli8OrpAJBCF5UDH9x4B+2gastXTRgqWK0sRoOpl2Cy3DtdIXfbZyCjTMz685awj4RdhB6IgffRioUkGHut9zJa+e4n1xdwVgRZckbsu4cmeO9FOzsR5bUo55fyOpLY0NGqLdN845aL+wd8YkSF; 25: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A/4qmVGOXB7Pd2qzO7Kj68fylRh0++LRjnjgWhm+UCYp0yZORPkUwV3Umy+Z136uJxNCZgZ/JC5Ir9nB0F+7iQn8ta7k; 4:WK+57gcPIQwZucnN9fB8IdP+HVh7cZJJNA9kbWVp2+1VATORwwSOHuHHcj86oCf+SXzZUnrut3pqLpVjhJoHHkDpWqGdTu/+ZryyDH3y++yDjd9/kcKQ3I8cyJ8jTuXlM1UvYtIlcRrlfkisQxhjG6KdEx79v29LVT2obcbGsHqV7CPu1nSykjnDxekLyBQXoHdq5ffWD063WJDQr4jo1syK2CndAywhk+PgTTYhkHSJe2USWDlJwe75gKdt7PfibzaJJqjAhUZtv2mfRbUO1A== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040522)(2401047)(5005006)(8121501046)(10201501046)(3231254)(944501410)(52105095)(93006095)(93001095)(3002001)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123564045)(20161123558120)(6072148)(201708071742011); SRVR:HE1PR0801MB1338; BCL:0; PCL:0; RULEID:; SRVR:HE1PR0801MB1338; X-Forefront-PRVS: 066898046A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(6069001)(39380400002)(366004)(376002)(396003)(39850400004)(346002)(189003)(199004)(230700001)(6636002)(97736004)(55016002)(9686003)(8936002)(53936002)(956004)(11346002)(476003)(446003)(3846002)(7416002)(575784001)(486006)(6116002)(86362001)(5660300001)(2906002)(103116003)(106356001)(105586002)(68736007)(478600001)(26005)(316002)(58126008)(25786009)(2486003)(52116002)(7696005)(76176011)(66066001)(33896004)(61506002)(50466002)(23676004)(39060400002)(59450400001)(386003)(55236004)(6506007)(186003)(47776003)(81156014)(305945005)(7736002)(16526019)(81166006)(8676002)(921003)(1121003); DIR:OUT; SFP:1102; SCL:1; SRVR:HE1PR0801MB1338; H:localhost.localdomain; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:3; A:1; Received-SPF: None (protection.outlook.com: virtuozzo.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtIRTFQUjA4MDFNQjEzMzg7MjM6V2xWTU4rVmRMWk1RenhSMld3VWVQb3dT?= =?utf-8?B?SVBScktlaTlQL05uK09KcmI3VUgrZU90UWNLTGl2TjR6eTBaVDVJUnhONDIy?= =?utf-8?B?MWZ6Y1hUN0tQTUpzTGsvakRydVBrMXl3d05BbFpIdkRvc3ZhMHRXVnpaWUNl?= =?utf-8?B?RXNXbXFlVTNUbjZyMnYvRU5kVEl3MUlmYzM2YTMwSDFSVmIxTXNsazRIOVha?= =?utf-8?B?Q1IyZ1VSK0YzZWx1ZU84MzIrK3NiMXdpazFzRENYZnlnVkhPNlJKdy9Vb21E?= =?utf-8?B?Y21UYkVJZkVaODc4dmdHa3BJSXlubVpUazE3ZnVqK2s4OEg3VXpZT2VVTVJC?= =?utf-8?B?NGtnS0VjSEZpY2YwR3Uwc2F1UitWNTVBckdwcjExZHpuK2pjUVp1amZIRnUv?= =?utf-8?B?VENTYld3UGQ5Z0FHdFAzRTNVYUFDR0l4VHhYdnFMUHBuQzJqdGpILzNUSkFa?= =?utf-8?B?SEFVcDAzcTR2ZTBGZ1JOZ3dTODRvVzJ2NEQzUjVYY1VwMjBpVk5tZTRLSU9H?= =?utf-8?B?cGlBR0ZiVldSOUhzR2plYUJCSHd0MzBaUmV5cUdhWGluV0xNRFdKYktGRDZG?= =?utf-8?B?ZjlrNEtUaHE1VXhrU0cwVVRFK1cxNFRkOGliaVl1M0RJTkliNTZHQUNicnRK?= =?utf-8?B?Z09lTlZVY01TUGxNdkU1UjNFU3FjeXhSaFZWVGJMUXZIMUtOR3U2ckp0TS9k?= =?utf-8?B?L0Y5bkppeG5jajJBYytTTHFNY1RURmJJOGd6UFR6QWViYW8zbjJDYW1PWHJW?= =?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cvntg6gJ48Pmd4ibm65GVNiAlRMAsN/U8fo4M=; 24:DFZu6RHVSZqyWIZYqCN+inSKExBprpLeiCHpCrKRGKb2agQcX0kUaWuXM+MgZLrFXoLJIIMXK8kMVqcgwTqv8GjKdxiIwoccBH+Z2VxxGiY= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; HE1PR0801MB1338; 7:MEUkWZ0NzzdH/NgEi53JOAyYBhI5CnceqLgjJ+SrY0l8liq/XAY600eOXV+jusFyPwYKGaiLEuW4ZDXoTv5C749eV1hPmpuANC6BqKbtOZL+fdCFGupFxEJstr3y8oy4hc3h7IhbTq8UhdouFWYFyztpv1G2uFYt6ldingNelwcdN4X5gAIbHvKNPc5tHGpLqxanJlJf5LGO7/55CXyjcqKWECSwNO1ziiDWvgHHN2a5FMZ5L845UD6rUl2J9Pl5; 20:k0umGE7CtKpowjj2j9Fdb4UfZbUaiY7NZK8zyFd0UmnpvHYg+LCgu4/V+WJ8i87lZT2SBXWC4DvgyLThtSH18FPZz0kuAs+TzQVIk0VcYvXAu31gqCmws2JhNWfgZEOFxx74lSHSdRbAwiFVgYNvX+F7KSqx5oYoUq2WTwMx8hk= X-MS-Office365-Filtering-Correlation-Id: abf3e03a-fa3c-4976-aa9c-08d5b65be1f3 X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 May 2018 09:53:27.0664 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: abf3e03a-fa3c-4976-aa9c-08d5b65be1f3 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0801MB1338 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 is just refactoring to allow next patches to have dst_memcg pointer in memcg_drain_list_lru_node(). Signed-off-by: Kirill Tkhai --- include/linux/list_lru.h | 2 +- mm/list_lru.c | 11 ++++++----- mm/memcontrol.c | 2 +- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/include/linux/list_lru.h b/include/linux/list_lru.h index a63b7a4abc6b..a63bad2c981a 100644 --- a/include/linux/list_lru.h +++ b/include/linux/list_lru.h @@ -68,7 +68,7 @@ int __list_lru_init(struct list_lru *lru, bool memcg_aware, #define list_lru_init_memcg(lru) __list_lru_init((lru), true, NULL) int memcg_update_all_list_lrus(int num_memcgs); -void memcg_drain_all_list_lrus(int src_idx, int dst_idx); +void memcg_drain_all_list_lrus(int src_idx, struct mem_cgroup *dst_memcg); /** * list_lru_add: add an element to the lru list's tail diff --git a/mm/list_lru.c b/mm/list_lru.c index 0721381b2e3d..46b805073ed0 100644 --- a/mm/list_lru.c +++ b/mm/list_lru.c @@ -517,8 +517,9 @@ int memcg_update_all_list_lrus(int new_size) } static void memcg_drain_list_lru_node(struct list_lru_node *nlru, - int src_idx, int dst_idx) + int src_idx, struct mem_cgroup *dst_memcg) { + int dst_idx = dst_memcg->kmemcg_id; struct list_lru_one *src, *dst; /* @@ -538,7 +539,7 @@ static void memcg_drain_list_lru_node(struct list_lru_node *nlru, } static void memcg_drain_list_lru(struct list_lru *lru, - int src_idx, int dst_idx) + int src_idx, struct mem_cgroup *dst_memcg) { int i; @@ -546,16 +547,16 @@ static void memcg_drain_list_lru(struct list_lru *lru, return; for_each_node(i) - memcg_drain_list_lru_node(&lru->node[i], src_idx, dst_idx); + memcg_drain_list_lru_node(&lru->node[i], src_idx, dst_memcg); } -void memcg_drain_all_list_lrus(int src_idx, int dst_idx) +void memcg_drain_all_list_lrus(int src_idx, struct mem_cgroup *dst_memcg) { struct list_lru *lru; mutex_lock(&list_lrus_mutex); list_for_each_entry(lru, &list_lrus, list) - memcg_drain_list_lru(lru, src_idx, dst_idx); + memcg_drain_list_lru(lru, src_idx, dst_memcg); mutex_unlock(&list_lrus_mutex); } #else diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 18e0fdf302a9..df9e7f159369 100644 --- a/mm/memcontrol.c +++ b/mm/memcontrol.c @@ -3173,7 +3173,7 @@ static void memcg_offline_kmem(struct mem_cgroup *memcg) } rcu_read_unlock(); - memcg_drain_all_list_lrus(kmemcg_id, parent->kmemcg_id); + memcg_drain_all_list_lrus(kmemcg_id, parent); memcg_free_cache_id(kmemcg_id); }