]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
x86/resctrl: Use is_closid_match() in more places
authorJames Morse <james.morse@arm.com>
Wed, 8 Jul 2020 16:39:25 +0000 (16:39 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jul 2023 06:37:04 +0000 (08:37 +0200)
commit7206eca1ac44b10df2332ec8b3ef6dff4fd7aa8e
tree5199afa840ea658632ca5d0c7c5ca59ed102a424
parent6f2bb37da46819f187d0625d957968230dba9531
x86/resctrl: Use is_closid_match() in more places

[ Upstream commit e6b2fac36fcc0b73cbef063d700a9841850e37a0 ]

rdtgroup_tasks_assigned() and show_rdt_tasks() loop over threads testing
for a CTRL/MON group match by closid/rmid with the provided rdtgrp.
Further down the file are helpers to do this, move these further up and
make use of them here.

These helpers additionally check for alloc/mon capable. This is harmless
as rdtgroup_mkdir() tests these capable flags before allowing the config
directories to be created.

Signed-off-by: James Morse <james.morse@arm.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Reinette Chatre <reinette.chatre@intel.com>
Link: https://lkml.kernel.org/r/20200708163929.2783-7-james.morse@arm.com
Stable-dep-of: 2997d94b5dd0 ("x86/resctrl: Only show tasks' pid in current pid namespace")
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/x86/kernel/cpu/resctrl/rdtgroup.c