RE: [PATCH 17/33] arm_mpam: Merge supported features during mpam_enable() into mpam_class

Shaopeng Tan (Fujitsu)
2025-11-12T08:25:01Z

> From: James Morse <james.morse@arm.com>
>
> To make a decision about whether to expose an mpam class as a resctrl
> resource we need to know its overall supported features and properties.
>
> Once we've probed all the resources, we can walk the tree and produce overall
> values by merging the bitmaps. This eliminates features that are only
> supported by some MSC that make up a component or class.
>
> If bitmap properties are mismatched within a component we cannot support
> the mismatched feature.
>
> Care has to be taken as vMSC may hold mismatched RIS.
>
> Signed-off-by: James Morse <james.morse@arm.com>
> Reviewed-by: Ben Horgan <ben.horgan@arm.com>
> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>
> Reviewed-by: Fenghua Yu <fenghuay@nvidia.com>
> Tested-by: Fenghua Yu <fenghuay@nvidia.com>
> Tested-by: Shaopeng Tan <tan.shaopeng@jp.fujitsu.com>
> Tested-by: Peter Newman <peternewman@google.com>
> Signed-off-by: Ben Horgan <ben.horgan@arm.com>

Reviewed-by: Shaopeng Tan <tan.shaopeng@jp.fujitsu.com>