From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4DEF82580F2 for ; Sat, 1 Aug 2026 06:58:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.160.179 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785567503; cv=none; b=UWTymWLjjDXw6oxvkJQDjpBM7Y0Ox+KTXQssLTAC9ixFKSUOxB1/QpUEZg7OXM+fleql237aN6bPk123iSPoTr89lgbumylZydUzEBBUtWx4AlnY7fwW0jcYyybNuW1LXhyjAonrDbZSxkKj5oi54MmT7SNx6bzSutruHU78Efc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1785567503; c=relaxed/simple; bh=pVW+S45AUw99y9jBlxP4dBrQBDW6s/gciYJoPeMq5zk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=EgmB8X75ZX5L5pKnaRuKrURrTtzuaHEWPSXFgJCUQicZVzoAdHI9O6xGqbwQQZM5VDGfZNehE+94p/CPgGx8VfkFe3Y8dHV9+tVpGgS5JrcFwEH87mIaAbo9OHSMqEXeFrWJodcE9oPdmyGEG6klErPyXfCC6UMTr2HaZLJaQuI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=cmpxchg.org; spf=pass smtp.mailfrom=cmpxchg.org; dkim=pass (2048-bit key) header.d=cmpxchg.org header.i=@cmpxchg.org header.b=YxHumlqc; arc=none smtp.client-ip=209.85.160.179 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=cmpxchg.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=cmpxchg.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=cmpxchg.org header.i=@cmpxchg.org header.b="YxHumlqc" Received: by mail-qt1-f179.google.com with SMTP id d75a77b69052e-5276d598b96so8484901cf.3 for ; Fri, 31 Jul 2026 23:58:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpxchg.org; s=google; t=1785567500; x=1786172300; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=hFZDtRlmAh/lYsw1peIZwBoJQwUYUw/2AfYQGPu/NJo=; b=YxHumlqccpBRSuSv/WCuyMZly5BIwNoPiTKXkxMw89qJiWrb3QLfD/fg4y83x0p/Bn Ih3UOgMm4xwq2ZSaC99WVqFwNOe+DlpUmPAJlW3KlNquHtQialEnJ3vxC0SCMCRIoeY8 lBNNlMUGXsXG84RJrCWOUPtSc48qDbzy66IezCGOAk0mZ3SLi+x69qWCDuYFwsEuw8w3 D4JowN0sokojwlZdaVzrT3rw3Bn8dnm5O2lEGwl2W0oBFydwe48UAK2ovBCvg++ZZ2+E eE+EpXl4qx1vgpPdNCGmTmQ+H705jXUvjH80YgR+29UGtLRFoAM0RpK6Fy/eJLBDwy6b Jaow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1785567500; x=1786172300; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=hFZDtRlmAh/lYsw1peIZwBoJQwUYUw/2AfYQGPu/NJo=; b=UoZ3zXBjL51jZYWl10PMNJ51UH0nKbm8iNVVHV0WphfvywI6tBlqhYBiz9J+K/85Ud YpnrQXmd9OOFazvpFtrq3rmuururBHmZWjVyaW19mp7dRJNbfagjEFmJWdLiTQqy2FZL a0Wt444WRWgTEosrxpKk9PqOCpnNjiohcHufysPyI42uzProxVQD27lVcdLE7q5KMgpb BrDMM6KcIf4vAbzNK+ZawgMNu3V+C3l58uL8E4ZuhIoHzXeaTMjZ1SrqK+Wt4W1gjn0e LGMgHHHTEil6qBQHr73hNTCf/G5k2OEdinAmkyUda73SJvU0f6HCnXHQwKADcfDzQz/n qsEg== X-Forwarded-Encrypted: i=1; AHgh+Rq/tpcUFRM8J9800gTt3/7biikOCb8B4kIIvlsa75/xxeVEHbPGXsy1Sz1Fe3poQtQ8bRmVXgEathkXAdY=@vger.kernel.org X-Gm-Message-State: AOJu0YwrYzxJ8zJuhAl+ND8131w/PglkIXGZeVyZMZodIvlXpqyiPU14 gQhVgUrU9TyACCqtMr3Qgf/Lzn11t2+ya+oRzm7ASzwCuAFJZ0LOaXvhwB+85jk/1l4= X-Gm-Gg: AR+sD12RSCmbun1lpW5YRAHUNHsW1pt4RFcquF1lw+bE7soI7x6vnn7l7xKZLpNFSJf GRb3eyxS/Wosa1nWIX/zJ4WIf0wp8NFigC7JDyRa7iuSVQlGcJ1/g2xRz4zU+EdAfswSYq+qA9y Tg6+VPpA+HzyO5agfXXAUXv3cdmWsB46Va9BvjQv833ghflUKLuP+WeL24xdOATzTNht7/M6adP 6ho3civL1kx5HWjU1ejjBpQJggrXlzpdF+5EzaPfEhL0GKERDfccBuQUE4lnm7PJxbyp9UG+W99 KrOENkwjWJXd17Wx9cozY6z8kDNBaZrCh2Z8uPyuV7uSwnNe2Tths77khyCs0jBpoPsIFigMHYq YW17nF1evg5MEPeOvQlslLYVuyU2KCvqXBeyceLItQCLPM8EjHDpNZA7vn9znRdrqXARLqahmKL 2GSBNoGXYZ4STSfOgEcl0DbKarD5vR5MTGj+qIgWiBEZeRLod6saAzPAwV7/6PyMfLCX/uxA== X-Received: by 2002:a05:622a:4d04:b0:51c:1532:ae93 with SMTP id d75a77b69052e-52b567dc76bmr61225711cf.26.1785567500235; Fri, 31 Jul 2026 23:58:20 -0700 (PDT) Received: from localhost ([2603:7001:f100:500:365a:60ff:fe62:ff29]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-52b4eb6a862sm23462961cf.16.2026.07.31.23.58.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 31 Jul 2026 23:58:19 -0700 (PDT) Date: Sat, 1 Aug 2026 02:58:18 -0400 From: Johannes Weiner To: Zi Yan Cc: Andrew Morton , Matthew Wilcox , William Kucharski , David Hildenbrand , Lorenzo Stoakes , Baolin Wang , "Liam R. Howlett" , Nico Pache , Ryan Roberts , Dev Jain , Barry Song , Lance Yang , Usama Arif , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH v2 2/2] xarray: honor XA_FLAGS_ACCOUNT in xas_split_alloc() Message-ID: References: <20260730-add-gfp_account-to-xas_split_alloc-v2-0-5a56c2361d85@nvidia.com> <20260730-add-gfp_account-to-xas_split_alloc-v2-2-5a56c2361d85@nvidia.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260730-add-gfp_account-to-xas_split_alloc-v2-2-5a56c2361d85@nvidia.com> On Thu, Jul 30, 2026 at 10:18:01PM -0400, Zi Yan wrote: > XArray operations that allocate xa_nodes, such as xas_nomem() and > xas_alloc(), add __GFP_ACCOUNT when the array has XA_FLAGS_ACCOUNT set. > This charges the allocated memory and avoids the workingset convergence > issue described by commit 7b785645e8f13 ("mm: fix page cache convergence > regression"). > > xas_split_alloc() does not have that flag. Add it when necessary. > > Fixes: 6b24ca4a1a8d4 ("mm: Use multi-index entries in the page cache") > Signed-off-by: Zi Yan Acked-by: Johannes Weiner