summaryrefslogtreecommitdiff
path: root/drivers/base/arch_topology.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-02-19 09:13:29 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-02-19 09:13:29 +0100
commita09ebb32afbe2b215075a81aa3f78795d553b91f (patch)
tree047a0abd5a122d919d2558acb1d484f7a46a1efc /drivers/base/arch_topology.c
parentcf92b9df3dcf45eab0fe3fcf9e97ce55c31c48c0 (diff)
parentb401b621758e46812da61fa58a67c3fd8d91de0d (diff)
downloadlinux-a09ebb32afbe2b215075a81aa3f78795d553b91f.tar.gz
linux-a09ebb32afbe2b215075a81aa3f78795d553b91f.tar.bz2
linux-a09ebb32afbe2b215075a81aa3f78795d553b91f.zip
Merge 6.8-rc5 into usb-next
We need the USB fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base/arch_topology.c')
-rw-r--r--drivers/base/arch_topology.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/base/arch_topology.c b/drivers/base/arch_topology.c
index 018ac202de34..024b78a0cfc1 100644
--- a/drivers/base/arch_topology.c
+++ b/drivers/base/arch_topology.c
@@ -431,9 +431,6 @@ init_cpu_capacity_callback(struct notifier_block *nb,
struct cpufreq_policy *policy = data;
int cpu;
- if (!raw_capacity)
- return 0;
-
if (val != CPUFREQ_CREATE_POLICY)
return 0;
@@ -450,9 +447,11 @@ init_cpu_capacity_callback(struct notifier_block *nb,
}
if (cpumask_empty(cpus_to_visit)) {
- topology_normalize_cpu_scale();
- schedule_work(&update_topology_flags_work);
- free_raw_capacity();
+ if (raw_capacity) {
+ topology_normalize_cpu_scale();
+ schedule_work(&update_topology_flags_work);
+ free_raw_capacity();
+ }
pr_debug("cpu_capacity: parsing done\n");
schedule_work(&parsing_done_work);
}
@@ -472,7 +471,7 @@ static int __init register_cpufreq_notifier(void)
* On ACPI-based systems skip registering cpufreq notifier as cpufreq
* information is not needed for cpu capacity initialization.
*/
- if (!acpi_disabled || !raw_capacity)
+ if (!acpi_disabled)
return -EINVAL;
if (!alloc_cpumask_var(&cpus_to_visit, GFP_KERNEL))