Commit 39c6eed1 authored by Maciej Wieczor-Retman's avatar Maciej Wieczor-Retman Committed by Borislav Petkov (AMD)

x86/resctrl: Rename arch_has_sparse_bitmaps

Rename arch_has_sparse_bitmaps to arch_has_sparse_bitmasks to ensure
consistent terminology throughout resctrl.
Suggested-by: default avatarReinette Chatre <reinette.chatre@intel.com>
Signed-off-by: default avatarMaciej Wieczor-Retman <maciej.wieczor-retman@intel.com>
Signed-off-by: default avatarBorislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: default avatarIlpo Järvinen <ilpo.jarvinen@linux.intel.com>
Reviewed-by: default avatarPeter Newman <peternewman@google.com>
Reviewed-by: default avatarReinette Chatre <reinette.chatre@intel.com>
Reviewed-by: default avatarBabu Moger <babu.moger@amd.com>
Tested-by: default avatarPeter Newman <peternewman@google.com>
Link: https://lore.kernel.org/r/e330fcdae873ef1a831e707025a4b70fa346666e.1696934091.git.maciej.wieczor-retman@intel.com
parent f05fd4ce
...@@ -872,7 +872,7 @@ static __init void rdt_init_res_defs_intel(void) ...@@ -872,7 +872,7 @@ static __init void rdt_init_res_defs_intel(void)
if (r->rid == RDT_RESOURCE_L3 || if (r->rid == RDT_RESOURCE_L3 ||
r->rid == RDT_RESOURCE_L2) { r->rid == RDT_RESOURCE_L2) {
r->cache.arch_has_sparse_bitmaps = false; r->cache.arch_has_sparse_bitmasks = false;
r->cache.arch_has_per_cpu_cfg = false; r->cache.arch_has_per_cpu_cfg = false;
r->cache.min_cbm_bits = 1; r->cache.min_cbm_bits = 1;
} else if (r->rid == RDT_RESOURCE_MBA) { } else if (r->rid == RDT_RESOURCE_MBA) {
...@@ -892,7 +892,7 @@ static __init void rdt_init_res_defs_amd(void) ...@@ -892,7 +892,7 @@ static __init void rdt_init_res_defs_amd(void)
if (r->rid == RDT_RESOURCE_L3 || if (r->rid == RDT_RESOURCE_L3 ||
r->rid == RDT_RESOURCE_L2) { r->rid == RDT_RESOURCE_L2) {
r->cache.arch_has_sparse_bitmaps = true; r->cache.arch_has_sparse_bitmasks = true;
r->cache.arch_has_per_cpu_cfg = true; r->cache.arch_has_per_cpu_cfg = true;
r->cache.min_cbm_bits = 0; r->cache.min_cbm_bits = 0;
} else if (r->rid == RDT_RESOURCE_MBA) { } else if (r->rid == RDT_RESOURCE_MBA) {
......
...@@ -113,8 +113,8 @@ static bool cbm_validate(char *buf, u32 *data, struct rdt_resource *r) ...@@ -113,8 +113,8 @@ static bool cbm_validate(char *buf, u32 *data, struct rdt_resource *r)
first_bit = find_first_bit(&val, cbm_len); first_bit = find_first_bit(&val, cbm_len);
zero_bit = find_next_zero_bit(&val, cbm_len, first_bit); zero_bit = find_next_zero_bit(&val, cbm_len, first_bit);
/* Are non-contiguous bitmaps allowed? */ /* Are non-contiguous bitmasks allowed? */
if (!r->cache.arch_has_sparse_bitmaps && if (!r->cache.arch_has_sparse_bitmasks &&
(find_next_bit(&val, cbm_len, zero_bit) < cbm_len)) { (find_next_bit(&val, cbm_len, zero_bit) < cbm_len)) {
rdt_last_cmd_printf("The mask %lx has non-consecutive 1-bits\n", val); rdt_last_cmd_printf("The mask %lx has non-consecutive 1-bits\n", val);
return false; return false;
......
...@@ -94,7 +94,7 @@ struct rdt_domain { ...@@ -94,7 +94,7 @@ struct rdt_domain {
* zero CBM. * zero CBM.
* @shareable_bits: Bitmask of shareable resource with other * @shareable_bits: Bitmask of shareable resource with other
* executing entities * executing entities
* @arch_has_sparse_bitmaps: True if a bitmap like f00f is valid. * @arch_has_sparse_bitmasks: True if a bitmask like f00f is valid.
* @arch_has_per_cpu_cfg: True if QOS_CFG register for this cache * @arch_has_per_cpu_cfg: True if QOS_CFG register for this cache
* level has CPU scope. * level has CPU scope.
*/ */
...@@ -102,7 +102,7 @@ struct resctrl_cache { ...@@ -102,7 +102,7 @@ struct resctrl_cache {
unsigned int cbm_len; unsigned int cbm_len;
unsigned int min_cbm_bits; unsigned int min_cbm_bits;
unsigned int shareable_bits; unsigned int shareable_bits;
bool arch_has_sparse_bitmaps; bool arch_has_sparse_bitmasks;
bool arch_has_per_cpu_cfg; bool arch_has_per_cpu_cfg;
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment