Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp4336186rdb; Thu, 14 Sep 2023 21:25:21 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF28rFeyFBzCBT/9i+D9BwBhGOlW3H+28Z3c71sTyRNkYtNBQoFv/VQ3UihRsK9qmcYbwtT X-Received: by 2002:a05:6870:be99:b0:1d6:6abb:aff3 with SMTP id nx25-20020a056870be9900b001d66abbaff3mr78071oab.26.1694751921294; Thu, 14 Sep 2023 21:25:21 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1694751921; cv=pass; d=google.com; s=arc-20160816; b=mlrJn5C7Z5tmluOlJwcVmWIfrw3f5fGaTQvnA6xwSL7eHpLTdeJDMyJA7keXnqy5kd vIiyWD2+WP3Xu5ygbw3GqkZGMtTEaj5BMEWgeSRcAWUyu+ZpS1xPcvDhWymtO68mJam2 vJJrtlfHPsKma4GEsNn5jFz6+KJbzjhdfcC+ZXxK7KusLDUZVZWHJzpFfSq8xxHdNLsI G0H8NJ3Lr/0T3sn4UXRdOjVKJYM6dSWPi1qSDp6AY5JBTQlzyiTRgW+R9GEMB3aOCam9 VsjS1f/fZJAgkZCH05vEy98wqy5cgJ67LQHcsxq4vskDiaO4LXLWGIspUcbD0mJmcBDl QNGg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :message-id:date:subject:cc:to:from:dkim-signature; bh=N+m0VxUwTyDGYqfeRvoQz6OFTcCzoA6YG47/myLxRHI=; fh=4nuFi4kI9c2NXuFlo7T7MMHrsyk1iu2cOhazgad9qWE=; b=Ybfw+fr/lqErbfJ3WvJsX43dMNQU8nBX8xvTl0HsPBLo7q+zB+OHcGmhmNn4pfjgkH wycWhxBaEvEn2vJP6s2JudS3QD0n2YxaTbnyYJBFjMShM8s8ZCvoiIBW96c7erxt9bhX xpb0WVYB3Rp4jPxbYfMdKrfl6BxhBK/5FyLAVMww+t1ZvhejR1pU5gDTDm0WN+89qJsk TMwXOnIwULUv5zRmgI/saSL/lal6ESgS4W5Il8fSe5JX2oNwHrKE+NmKL8xdDqTiShFH HsZvQr95Te3YX8N5BHq3fJIYARVGv3uoAleWXk5fl2ACXfh+P4xhE+sEylhU95ffkrqr j9ZQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=LjNXJZap; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id x64-20020a636343000000b0057416a797dasi2665838pgb.734.2023.09.14.21.25.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Sep 2023 21:25:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@vivo.com header.s=selector2 header.b=LjNXJZap; arc=pass (i=1 spf=pass spfdomain=vivo.com dkim=pass dkdomain=vivo.com dmarc=pass fromdomain=vivo.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=vivo.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 3B76F8436B53; Thu, 14 Sep 2023 03:48:42 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232234AbjINKsj (ORCPT + 99 others); Thu, 14 Sep 2023 06:48:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36828 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230141AbjINKsh (ORCPT ); Thu, 14 Sep 2023 06:48:37 -0400 Received: from APC01-PSA-obe.outbound.protection.outlook.com (mail-psaapc01on2099.outbound.protection.outlook.com [40.107.255.99]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9A30E1BF0; Thu, 14 Sep 2023 03:48:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GfMBXq8rBBX3j4mqaKi7c7c7k3Vk9KZA08Qeoddsgto2IWA06S1XqwRfq/M14KOI0S4iazwvd5+7OieSHYc1osgEkbTZofDXSuts3hIz1uaSvBgBGt3LvY9poB6pxq3aH34Tx0qNjiObqX/t7peyQrEYaRimsgqYNvAXbnzWDn+wR5PruOKMl2yVry2kU9qxdLq52TwVZDK9A8SZdwkZtHxk+NSzq5WnpOMwfvJ/Qbhd2G+USYG8c3izAvC5fllxT8FZUW9qrXRj52q1xaX45ffaYDc0YJzL+JNsBHwsTZWIMBcpKRm+0XQoZEPG3zcPAvO1skjOitUyoi1oS2rDXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=N+m0VxUwTyDGYqfeRvoQz6OFTcCzoA6YG47/myLxRHI=; b=YlMuPWf+4FIR5XASUvFMhbM+7cLOEnCZjM+eyugOcWCoioeAnoNJCKnNuCC6jY4OkFi8cNE0NC6Noul25W53ATOWfAxzR0ais/DPflywvkFw19krhHH0mOqyme7XXnl6wypzBT56NTDPvM3GxyaNE8tzm4zR8rNAkEsu+qJO4Dw+hVWqhG/23t1iAxslPzDTwm21a+/bJ95VsuALpYZk0R5b7+Ud3CjHkvOLgH1nR+9veBsQ2+MFgrE3F9vfPYP+D0UmPmWDsm4flbVhkDutBo0mZMLghf5IPKZJerTJ7PB0oYc3t8EabBLMgM2ng6dvTMgqc5sUnrgYpkhoa+cR+g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=vivo.com; dmarc=pass action=none header.from=vivo.com; dkim=pass header.d=vivo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vivo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=N+m0VxUwTyDGYqfeRvoQz6OFTcCzoA6YG47/myLxRHI=; b=LjNXJZapGwODgKeLHl9A1+6K6HXFAAS6JA1w/YeV1/SAb5oCQ5EgNy2LHg7i/FH6fBqsBQJBWPlDg9H/ejvXEFkj67t65olRRgJiJnpQvcbMGaWH0eV+pevCrUd06CtFGcQUY1AQwE9P14NJcoEe8ss+tBlBZZtwkbJQMJTwn9b1zqwOacWCgAdW0RfbhXMY80rNJXiHhYgXK2v23vOOlQn+rPOGeV0wXRzl4wjOpClbOVUSN9wK/GZUMtrWyikSYuLgkBjfL07b2uBsRmnm/L0wiV5JVcqZIeSuY8wda5IUT9u6NFj8uXjyFGkRejHjWGNXsts5q7CeuxJ1gndFwg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=vivo.com; Received: from PUZPR06MB5676.apcprd06.prod.outlook.com (2603:1096:301:f8::10) by SI2PR06MB4267.apcprd06.prod.outlook.com (2603:1096:4:15e::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6792.20; Thu, 14 Sep 2023 10:48:28 +0000 Received: from PUZPR06MB5676.apcprd06.prod.outlook.com ([fe80::64c1:bd7f:ced7:7d02]) by PUZPR06MB5676.apcprd06.prod.outlook.com ([fe80::64c1:bd7f:ced7:7d02%4]) with mapi id 15.20.6792.020; Thu, 14 Sep 2023 10:48:28 +0000 From: Huan Yang To: Jonathan Corbet , Andrew Morton , Johannes Weiner , Michal Hocko , Roman Gushchin , Shakeel Butt , Muchun Song , Suleiman Souhlal , Mike Rapoport , "Jan Alexander Steffens (heftig)" , Yu Zhao , Huan Yang , Brian Geffon , Gaosheng Cui , Peter Xu , Axel Rasmussen , "T.J. Alumbaugh" , Kefeng Wang , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, cgroups@vger.kernel.org Cc: kernel@vivo.com Subject: [PATCH 0/3] Per memcg lru_gen node stat Date: Thu, 14 Sep 2023 18:47:42 +0800 Message-Id: <20230914104754.55-1-link@vivo.com> X-Mailer: git-send-email 2.34.1 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: SG3P274CA0004.SGPP274.PROD.OUTLOOK.COM (2603:1096:4:be::16) To PUZPR06MB5676.apcprd06.prod.outlook.com (2603:1096:301:f8::10) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PUZPR06MB5676:EE_|SI2PR06MB4267:EE_ X-MS-Office365-Filtering-Correlation-Id: ac6290bf-5466-4dbc-15e3-08dbb51020dd X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xPmxDFsWf2FK4EFdv3Thz+aPEWAEw0AGMXYEFfYfBerfMeZ3pDYHftw2+HfbaAHFY7Qo10ouJiv5gMlvp9IG0FGvuBf3F0XKEeStMoD1abXFdORhp76kM7M6zqUcHY93uUIWIg4tPCXOplYck/F75D8/A1COoIV00ZlyKuXugw/BKAfVjgXrZuELDdgJjeRwmIWLA5EjqtBeqZ2n4I+Me2DtkXcLV3aaXSbkd48LfNwEjCGwRmYvGpf+z0+TGruosNrs8PQ9RU9Z1dO1ztl/kx6ktLtiajXsnVUIOVkEBC5mZZ3khhibn4eVtbB7PEd773sdmq9lVUhMxDBCB33XaLU2sPOe7DUtBSReabRrkpm5pBVbMtiNxhXgedOnuYZbd7P945BDVhopCBK1WAocLtIBAJEC74IRHBJFSNsmkH6tHFmKyQApf9UF3Zpva+BxzdPRkO5RU7utQJrYFOj31rc+FVFe4bonIAleBciMkVWdmaxyrI2F2Cy7a+6iHvqpBaal86AKbUDSD4yiDNTtS0PVztI3q+0gRrHtlVVLOb38p/Aug1F2jNEJqzBriu+QdqGJ3ghOB+wpWoCFbAfUyVzlKpbgcdWNPCBaY0cZNSfZZDvHarr38xUk9t0YTcJB3PF5ZL1AaNpZE+iFv1yO8Q== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PUZPR06MB5676.apcprd06.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376002)(366004)(396003)(39860400002)(136003)(346002)(451199024)(1800799009)(186009)(6506007)(6486002)(52116002)(6666004)(38100700002)(36756003)(86362001)(921005)(38350700002)(1076003)(2616005)(26005)(4744005)(83380400001)(107886003)(6512007)(478600001)(2906002)(110136005)(4326008)(316002)(8676002)(8936002)(41300700001)(5660300002)(7416002)(66946007)(66476007)(66556008);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?HJ2qbKSDULzikH42TEVZJ2Y/uK0C1h3+xqZVTcmPAAPzj4wwBAxwcqqom4De?= =?us-ascii?Q?Rqp2E6Ac127NtO99nvShkVjMSC0tzvoReVZTzp/MhP6VNdKYdGoj2G6jRkLV?= =?us-ascii?Q?4D5Ay+8AxfbHtNxaDKFt+w/X9D1mZLBfRWN0fgLrFbRgQtopHoMyBHiprN2N?= =?us-ascii?Q?KGGxL8qzxSWwpl8noV6Ll4KOSUDB5tiZt1x0Iwom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q4Su3oLwjDVNsRCEDoAcM+oEfKC9L8FFUij/UXBUzOvl1J+c6GEzV/d4H77?= =?us-ascii?Q?XpaJSA3HYs71/2S6BTSm8xFf7XPvMvwJtrFJvQVk9VGFo+NRN+D6y/s2lWEt?= =?us-ascii?Q?dtZC4FCYSYV0WwNzeOYP8q1uBbn6NaMSRGLjBCYc7WwICXd7WOUHHPOVOPj/?= =?us-ascii?Q?ga692qKKBJmEGQ1wbXBxi9/W0drlEVNV/PLAjrCDbF5IXmSjuMR+3xRZYdJV?= =?us-ascii?Q?MudwfmFBZpF/i+74CnjC37g2GEI3pkzkIEq2U8EIzg6XxXEzCE1PLJOFxkPA?= =?us-ascii?Q?UJH1ODCJ/E5xmrOtGBKeLwtV+sGYMzq/TCFkjwNKVs7NyCng3O0y9bzJ/daF?= =?us-ascii?Q?87ZXzhH4phHgMbzEFxukQNbnF0ZecG1PJJj7lPvmi3FVV4d+IpIXkeQzq3nb?= =?us-ascii?Q?/qo15Ize/8myXXDUF46818qlNt/IOYbNYQREL2Ni4z34myufdsQfd4okPUL9?= =?us-ascii?Q?zTVgK8EaWZMSkb3gvmRWkUMaesp+iOH3LKRDiZdK?= X-OriginatorOrg: vivo.com X-MS-Exchange-CrossTenant-Network-Message-Id: ac6290bf-5466-4dbc-15e3-08dbb51020dd X-MS-Exchange-CrossTenant-AuthSource: PUZPR06MB5676.apcprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Sep 2023 10:48:28.3068 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 923e42dc-48d5-4cbe-b582-1a797a6412ed X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: yUGaHKrhyxIJTCFBPcsYMV9W7tgw9Bvbgnj1pajRdgKuAmFhzm09bPJTYybn9W4XfEQ+DZDBp+Y7XQboUYgswA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SI2PR06MB4267 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Thu, 14 Sep 2023 03:48:43 -0700 (PDT) On original global lru_gen node in debugfs, it can all show each memcg's lru gen info in "lru_gen" or "lru_gen_full", and can type cmd into lru_gen. But which show info contains all memcg's info, and cmd need to know memcg's id. This patchset add lru_gen node in per memcg, with this node, we can get lru_gen info in each memcg. Also, we can type cmd to control each memcg's lru_gen seq, but, this node don't support multi cmd, single memcg just process one cmd once time. Huan Yang (3): mm: multi-gen LRU: fold lru_gen run cmd mm: memcg: add per memcg "lru_gen" node mm: multi-gen LRU: add per memcg "lru_gen" document Documentation/admin-guide/mm/multigen_lru.rst | 10 ++ include/linux/mm_inline.h | 9 + include/linux/mmzone.h | 4 +- mm/memcontrol.c | 163 ++++++++++++++++++ mm/vmscan.c | 82 ++++++--- 5 files changed, 246 insertions(+), 22 deletions(-) -- 2.34.1