From nobody Sat Jun 13 08:46:27 2026 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id ACB4D32B981; Fri, 8 May 2026 10:56:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778237796; cv=none; b=fXR8yrCooMm9gkrhAy/iJguZ94TtBCmN41E4RMRrOfg71S1a9WmFPGrkF0PpRxr8xoLsOUoHFI5oS3lTQf9OpXk93zuiJobMY9DI2ytpVkFfHN3oJhuf2kol043t0ibOaGl5tKVZT7CFU2wyKL8Wwoww4q/Gpeu+kM159oobTN4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778237796; c=relaxed/simple; bh=VeMBRgXplKwUj6wCdbljWC26AKUluIEy6aUNuaRZij0=; h=Date:From:To:Subject:Cc:MIME-Version:Message-ID:Content-Type; b=cQ5HIqtQVEcRrLd9rZU2CkiG06faVNwbAZbNJP6azn7ix1IgM5VF9PnXvHbhAhB7H3B36Y3l0RCJv+l9DtuZp8C9DNkdCcoxIUWt4oLtPIHmXPunNne1zkpl6o6UM4ptxW9bGoh+9Czau9cZw9m5tdgkCr0QvbPFGryvzgar3UA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=fsF0xCBm; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=eKLZ9b4u; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="fsF0xCBm"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="eKLZ9b4u" Date: Fri, 08 May 2026 10:56:31 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1778237793; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mrUf94fhs8vyjOhRBo+HvbcKPBYOfb++jLw9PYGna4c=; b=fsF0xCBmR3LRaXOE0uO9VMks8Db2bnmfnN1oqsOSzE6dCuMf7LdOMDdRYj9pRZQ3MR7Uno RLAm7398nRVsB0yXF/mFKfVGr/pzHw9WV2ZOF7hlBDV2oFYT7Yv7meWBL/FtClFIcgSVw7 whxVp4Gs7FL4ngpqwwOoJ0hhWubV/amgcAD2p5Ur2eJfEE8hGa2hgK2Id2OoJ4R4C6OQMg cGnP4XRv5MSEzV7Q91AdEB3yXIhzHhrnczTch2lIik7w9HUNwiu/fYTIFIf+imG+s6Hbl1 An/RMtYPyE+tdd5qYW1joBMNpGSeDu29+ripBkQ3CIFiGQylLDnR/WuOwG7zCw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1778237793; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mrUf94fhs8vyjOhRBo+HvbcKPBYOfb++jLw9PYGna4c=; b=eKLZ9b4uW+Jf37ku20LPVmVt+SxONJrZhf+o+HH+SS4QavOSLII3cctdssm/w3jurXpPN/ PrQaqd9mwmIKlhAQ== From: "tip-bot2 for Ben Horgan" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: x86/cache] fs/resctrl: Document tasks file behaviour for task id 0 and idle tasks Cc: Ben Horgan , "Borislav Petkov (AMD)" , Babu Moger , Reinette Chatre , x86@kernel.org, linux-kernel@vger.kernel.org Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <177823779136.864.6531421918327353093.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable The following commit has been merged into the x86/cache branch of tip: Commit-ID: 1cfa74c683ea82d37156ccd7ab4f4659056dc701 Gitweb: https://git.kernel.org/tip/1cfa74c683ea82d37156ccd7ab4f46590= 56dc701 Author: Ben Horgan AuthorDate: Wed, 06 May 2026 09:28:55 +01:00 Committer: Borislav Petkov (AMD) CommitterDate: Fri, 08 May 2026 12:27:00 +02:00 fs/resctrl: Document tasks file behaviour for task id 0 and idle tasks When 0 is written to the tasks file it is interpreted as the current task in rdtgroup_move_task(). Each CPU's idle task has task_struct::pid set to 0 an= d, on x86, task_struct::closid to RESCTRL_RESERVED_CLOSID and task_struct::rmid to RESCTRL_RESERVED_RMID. Equivalently, on MPAM platforms, thread_info::mpam_partid_pmg is encoded wi= th PARTID and PMG set to RESCTRL_RESERVED_CLOSID and RESCTRL_RESERVED_RMID, respectively. As there is no interface to change these from the default, the resctrl configuration for the idle tasks is fixed and they always behave equivalently to a task in the default tasks file and so take their configuration from the cpus/cpus_list files. On read of the tasks file, show_rdt_tasks() filters out any 0 PID. Hence, a task id of 0 is never shown in the tasks file and the idle tasks are not represented either. Document the user visible behaviour. Signed-off-by: Ben Horgan Signed-off-by: Borislav Petkov (AMD) Reviewed-by: Babu Moger Reviewed-by: Reinette Chatre Tested-by: Babu Moger Link: https://lore.kernel.org/20260506082855.3694761-1-ben.horgan@arm.com --- Documentation/filesystems/resctrl.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/filesystems/resctrl.rst b/Documentation/filesyst= ems/resctrl.rst index b388e91..e4b66af 100644 --- a/Documentation/filesystems/resctrl.rst +++ b/Documentation/filesystems/resctrl.rst @@ -575,6 +575,11 @@ All groups contain the following files: then the task must already belong to the CTRL_MON parent of this group. The task is removed from any previous MON group. =20 + When writing to this file, a task id of 0 is interpreted as the + task id of the currently running task. On reading the file, a task + id of 0 will never be shown and there is no representation of the + idle tasks. Instead, a CPU's idle task is always considered as a + member of the group owning the CPU. =20 "cpus": Reading this file shows a bitmask of the logical CPUs owned by