On Thu, Jun 12, 2025 at 05:13:35PM +0000, James Morse wrote: > The MPAM table identifies caches by id. The MPAM driver also wants to know > the cache level to determine if the platform is of the shape that can be > managed via resctrl. Cacheinfo has this information, but only for CPUs that > are online. > > Waiting for all CPUs to come online is a problem for platforms where > CPUs are brought online late by user-space. > > Add a helper that walks every possible cache, until it finds the one > identified by cache-id, then return the level. > > acpi_count_levels() expects its levels parameter to be initialised to > zero as it passes it to acpi_find_cache_level() as starting_level. > The existing callers do this. Document it. > Reviewed-by: Sudeep Holla <sudeep.holla@xxxxxxx> -- Regards, Sudeep