Skip to contentSkip to conversation

arch_topology: remove the acpi_disabled check

PATCH Superseded Perry Yuan 2 participants 2 messages Jul 9, 2022 – Jul 11, 2022

Subsystems (2)

v2 of 6 Superseded Latest is v6 →

lore
Share & tools
lore

Perry Yuan

author
#0 lore raw

PATCH v2 13/14 arch_topology: remove the acpi_disabled check

"acpi_cpc_valid" function already includes the acpi_disabled check and we can remove the duplicated check here

---
 drivers/base/arch_topology.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/base/arch_topology.c +1 -1
index 579c851a2bd7..73a8cb31529d 100644
@@ -352,7 +352,7 @@ void topology_init_cpu_capacity_cppc(void)
 	struct cppc_perf_caps perf_caps;
 	int cpu;
 
-	if (likely(acpi_disabled || !acpi_cpc_valid()))
+	if (likely(!acpi_cpc_valid()))
 		return;
 
 	raw_capacity = kcalloc(num_possible_cpus(), sizeof(*raw_capacity),
Signature · 1 line
2.25.1
#1 lore raw
Quoted 13 lines · Perry Yuan

"acpi_cpc_valid" function already includes the acpi_disabled check and we can remove the duplicated check here

---
 drivers/base/arch_topology.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/base/arch_topology.c +0 -0
index 579c851a2bd7..73a8cb31529d 100644

drivers/base/arch_topology.c void topology_init_cpu_capacity_cppc(void) · line 355

Quoted 5 lines
drivers/base/arch_topology.c +1 -1
@@ -352,7 +352,7 @@ void topology_init_cpu_capacity_cppc(void)
 	struct cppc_perf_caps perf_caps;
 	int cpu;
 
-	if (likely(acpi_disabled || !acpi_cpc_valid()))
+	if (likely(!acpi_cpc_valid()))

I think this should be included in Patch 11/14 where the acpi_disabled check is added to acpi_cpc_valid().

-Nathan

Quoted 3 lines
drivers/base/arch_topology.c +0 -0
 		return;
 
 	raw_capacity = kcalloc(num_possible_cpus(), sizeof(*raw_capacity),