Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp878188pxv; Thu, 1 Jul 2021 11:20:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyxYb1s+EHGHY17XOe6S8HiccgwCkCfDqJiP+j7qGEWXVI0CJ/4ytNYO3ZCiBVs9trWzAI4 X-Received: by 2002:a17:907:2d27:: with SMTP id gs39mr1309054ejc.328.1625163601470; Thu, 01 Jul 2021 11:20:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625163601; cv=none; d=google.com; s=arc-20160816; b=xaSNzXb5BwtHl2eP+MCGqIKQCN9Dj2Yxf7AM7fYVUPi+T5jsj2QkWIJcpUqWngquHs vaE58kHPQ3+Ef0TSeEyXMhQcAQJg22UvfuioKEOEjY8jQzLC40tTgcP/hGXOewluRjBy 3UVu81WbRV9UuWZX0I0SQ3notPlj6RPt6MnH53ja+9XTUkYUd/7lDu9QE1WFPlZy44jr wkWbEl7hp2hX1F8RX5bUVE08kmmadXrM6rvzWKTNakntHBqCWJJ+Ib0GlifwuarueXmY aYAYFE2e5xKTiFLC/RixcI9tsMRvCTQzbErR8jF34zgJZYwKHW4v+Et7pbTixLC1a2Da vs9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-disposition:mime-version:message-id :subject:cc:to:from:date; bh=RfAst8jf06jV75PDGjbAHUMMTq2o1HWk2Y22ohLeAWI=; b=vchQvAARhHEit6xbSkS6e+g5P1X+xBps7WcdVUDAOQFW63ZAhDEssxGNSBj5Kk1rqG bUVIMGy1eymtr35xI461zJc3rwKNS34e3JGgiGPuCvoRHyzFICdp0QYWn6pyZ+O5pCoS emBd+VYs1nrrEw7VluvReFYYx4OvOLglvn+M+VSMFjb4hfqQ0NFwrT2x1Yc32lInWlka Wpdwx6+EcitlEE8eZsWrwnn9+tkAfzx8eCw6HryoikgCbcXwHbXEWBp2bPZwCVOjDYXJ Ba8rc9ShH6qPIVq3JJ9xA2hokyBiCpwT1RH1eHoMEaN8JtypgSDybofzGDDsDa/048H7 x/2w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i10si665589ejw.269.2021.07.01.11.19.37; Thu, 01 Jul 2021 11:20:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233223AbhGASUt (ORCPT + 99 others); Thu, 1 Jul 2021 14:20:49 -0400 Received: from mail-il1-f171.google.com ([209.85.166.171]:47001 "EHLO mail-il1-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229844AbhGASUr (ORCPT ); Thu, 1 Jul 2021 14:20:47 -0400 Received: by mail-il1-f171.google.com with SMTP id t12so7246819ile.13 for ; Thu, 01 Jul 2021 11:18:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition; bh=RfAst8jf06jV75PDGjbAHUMMTq2o1HWk2Y22ohLeAWI=; b=uP2EkQkzgjU7jFcsj28w8PThb6Q7Ay3jsg2thuYlujN0RtbeskUknV7deTLKMuZghp 5MMTydha16D9eqI56Qk5RjRZyrutfrojBr+GKXs2klMtW50YpNAmO2MLwbNsW/jGyxm8 LvlpNYw4Oe+DkrXQnrzyuinV/ZKqa3d0IlQl3x6SQ8NdwCBCgx4Mzszewj7XTh8Xs8F6 wbKQfNo8NZ7QEBnGnh9Hi1ajVJdzQ0pE8dkZdry/eyj8XlnJFak+zcCjviSH+tLb9MC5 gOoZclojkOUGV3B9zBZp1gjCLUiMU2GT28c55NESCYo+yVLGRZ2FlX9odTbLcFW1dWiK /N5Q== X-Gm-Message-State: AOAM530jwd9vr/Gnw8euEvQBcoFX4okxM2Zq7696mbPrkcDnERturyIp ImROLBT57ZKD0kDjXGT42ak= X-Received: by 2002:a92:7b0f:: with SMTP id w15mr534304ilc.150.1625163495763; Thu, 01 Jul 2021 11:18:15 -0700 (PDT) Received: from google.com (243.199.238.35.bc.googleusercontent.com. [35.238.199.243]) by smtp.gmail.com with ESMTPSA id 67sm318917iob.15.2021.07.01.11.18.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Jul 2021 11:18:15 -0700 (PDT) Date: Thu, 1 Jul 2021 18:18:14 +0000 From: Dennis Zhou To: Linus Torvalds Cc: Tejun Heo , Christoph Lameter , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [GIT PULL] percpu changes for v5.14-rc1 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Linus, This pull request contains: - percpu chunk depopulation - depopulate backing pages for chunks with empty pages when we exceed a global threshold without those pages. This lets us reclaim a portion of memory that would previously be lost until the full chunk would be freed (possibly never). - memcg accounting cleanup - previously separate chunks were managed for normal allocations and __GFP_ACCOUNT allocations. These are now consolidated which cleans up the code quite a bit. - a few misc clean ups for clang warnings Two notes though. First there is a small conflict in mm/memcontrol.c and I have an example merge in percpu#for-5.14-merge [1]. Second, I have an outstanding patch to do some level of batching for percpu depopulation. Oliver Wang (krobot tests) is reporting a regression only on Knights Landing cpus [2]. I am working on debugging it and hopefully will have it figured out soon. [1] https://git.kernel.org/pub/scm/linux/kernel/git/dennis/percpu.git/log/?h=for-5.14-merge [2] https://lore.kernel.org/lkml/20210630074500.GB10248@xsang-OptiPlex-9020/ Thanks, Dennis The following changes since commit d434405aaab7d0ebc516b68a8fc4100922d7f5ef: Linux 5.12-rc7 (2021-04-11 15:16:13 -0700) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/dennis/percpu.git for-5.14 for you to fetch changes up to e4d777003a43feab2e000749163e531f6c48c385: percpu: optimize locking in pcpu_balance_workfn() (2021-06-17 23:05:24 +0000) ---------------------------------------------------------------- Dennis Zhou (2): percpu: use pcpu_free_slot instead of pcpu_nr_slots - 1 percpu: initialize best_upa variable Roman Gushchin (8): percpu: fix a comment about the chunks ordering percpu: split __pcpu_balance_workfn() percpu: factor out pcpu_check_block_hint() percpu: implement partial chunk depopulation mm, memcg: mark cgroup_memory_nosocket, nokmem and noswap as __ro_after_init mm, memcg: introduce mem_cgroup_kmem_disabled() percpu: rework memcg accounting percpu: optimize locking in pcpu_balance_workfn() Wei Yongjun (1): percpu: make symbol 'pcpu_free_slot' static include/linux/memcontrol.h | 5 + mm/memcontrol.c | 11 +- mm/percpu-internal.h | 56 +------ mm/percpu-km.c | 10 +- mm/percpu-stats.c | 44 ++---- mm/percpu-vm.c | 35 ++++- mm/percpu.c | 368 +++++++++++++++++++++++++++++++++------------ 7 files changed, 343 insertions(+), 186 deletions(-)