From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796387913; b=PBZlIjKQ0qcCQ2zOStJurnt0riKzCyjVNdi6ZgdZASG/zQj6xU3xMSxoTiP3ME8+qa2Z WppEUs4spl4CbO66n/pr5fM/KlEjo90/BLrvE1LaTHqTd3m5/2FHsn3xDI7YJCJAJok/Q 5y3VO2gvqjZkaqFvSQNAI0aotevBymKIxWaswKdEIGpkgxFYEZg920cvkiox2EJn2DocS zpK14gMlJwt8/yzJLxjpo6OlEjngyd4SZLPbpfpNWiH/FSJ0Af0Was9M775nhq4osGSpx vffvas/e9tJupfTy2nUZDZQpA6KTXdWw1K8LPujtN4wFIUbg9mxY7OrFcNKfcWubovA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796387913; h=Received:DKIM-Signature:From:To:Cc:Subject:Date:Message-ID:X-Mailer: In-Reply-To:References:User-Agent:X-stable:X-Patchwork-Hint: MIME-Version:Content-Transfer-Encoding; bh=05FWlk80ZfITDJkhI/a3lcuPU3SVIaZk6UqQrovd2Gc=; b=mXB6KtQWmpmHH11q9PqZ3nz71hBT2h3XfTYixBB1k7FuUB2yoQ1w4GZ/xQ11BOSLQgX8 +qDcdKXtHUqC7w8CYC9I6FmoWxxV5s8gQrve0Uc2IEiAB5ujDPkIttzhMILPY9r8DtmUK FyhT6jyRwzQjmAbV2T1MhWLj+eH704mr1BXoORpfDnANucGPSeMwKPr7fX0AxSzRwDyRB yCKqLuoUArEkt3VueJ12LpSJiGEykkiCueR/CyDBvCMGj17Ye+MX80BC3o1ilkVS84gOP e6lVMj/Rrt0a6qZRC/OrCcSiJVwaVI+D3Yqw+aC85rScgX9+5Zi8EU5Qp65jRNPwfvQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b="ASllxaJ/"; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E20BE606A32C; Fri, 4 Dec 2026 12:38:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.a=rsa-sha256 header.s=korg header.b=ASllxaJ/ Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5F09A1F000CE; Fri, 4 Dec 2026 12:38:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1796387912; bh=05FWlk80ZfITDJkhI/a3lcuPU3SVIaZk6UqQrovd2Gc=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=ASllxaJ/pOJava0LTHuYePQ/I/FZ0Kk/13VRKH0IS8jTyulYEh7v37zU1Q6K2DsPN kvCU5wX230pEeP0r4uTroYUemYZc3dvc9M+s6TkWjdyeiG8tqCpPyOSsCcX+d6iWgU e1L7/lpeq+nN4VBreFstBm0a6VGj4nsWRVtSp9fI= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Sashiko , Tony Luck , "Borislav Petkov (AMD)" , Reinette Chatre , Sasha Levin Subject: [PATCH 6.1 0368/1059] fs/resctrl: Ensure default group reports tasks on monitor-only systems Date: Fri, 4 Dec 2026 18:58:19 +0900 Message-ID: <20261204100653.811332558@linuxfoundation.org> X-Mailer: git-send-email 2.56.1 In-Reply-To: <20261204100643.980430235@linuxfoundation.org> References: <20261204100643.980430235@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore X-Mailing-List: patches@lists.linux.dev List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Tony Luck [ Upstream commit 2c10b3fa5bdf61e344bc522e6c2e00d870ce7ab8 ] resctrl can be mounted on a system that supports monitoring but not allocation. On such a system reading the "tasks" file in the default group reports no tasks, even when there are tasks assigned to the default group. This problem occurs because the check for whether a task belongs to a CTRL_MON group is gated by a check for whether the system supports allocation. The resctrl_arch_alloc_capable() check in is_closid_match() breaks task reporting for the default group on monitor-only systems so remove this check. On systems that support allocation the check is redundant. Fixes: e6b2fac36fcc ("x86/resctrl: Use is_closid_match() in more places") Closes: https://sashiko.dev/#/patchset/20260831174421.13921-1-tony.luck%40intel.com?part=9 Reported-by: Sashiko Signed-off-by: Tony Luck Signed-off-by: Borislav Petkov (AMD) Reviewed-by: Reinette Chatre Link: https://patch.msgid.link/20261009193923.15498-1-tony.luck@intel.com [ sashal: Removed the rdt_alloc_capable term from is_closid_match() in the old arch/x86/kernel/cpu/resctrl/rdtgroup.c location, since this tree has no resctrl_arch_alloc_capable() and compares t->closid directly. ] Signed-off-by: Sasha Levin --- arch/x86/kernel/cpu/resctrl/rdtgroup.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/x86/kernel/cpu/resctrl/rdtgroup.c b/arch/x86/kernel/cpu/resctrl/rdtgroup.c index 6de03440d66ae..7100cda2ea4ab 100644 --- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c +++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c @@ -611,8 +611,7 @@ static int __rdtgroup_move_task(struct task_struct *tsk, static bool is_closid_match(struct task_struct *t, struct rdtgroup *r) { - return (rdt_alloc_capable && - (r->type == RDTCTRL_GROUP) && (t->closid == r->closid)); + return (r->type == RDTCTRL_GROUP && t->closid == r->closid); } static bool is_rmid_match(struct task_struct *t, struct rdtgroup *r) -- 2.53.0