[PATCH 33/33] cpufreq: Stop checking for duplicate available/boost freq attributes

From: Viresh Kumar
Date: Thu Jan 23 2025 - 06:45:36 EST


None of the drivers set these attributes directly now, remove the
unnecessary check.

Signed-off-by: Viresh Kumar <viresh.kumar@xxxxxxxxxx>
---
drivers/cpufreq/cpufreq.c | 7 -------
1 file changed, 7 deletions(-)

diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index 973bd6e4bdd4..2569f9980d2c 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -1076,13 +1076,6 @@ static int cpufreq_add_dev_interface(struct cpufreq_policy *policy)
/* set up files for this cpu device */
drv_attr = cpufreq_driver->attr;
while (drv_attr && *drv_attr) {
- /* These are already added, skip them */
- if (*drv_attr == &cpufreq_freq_attr_scaling_available_freqs ||
- *drv_attr == &cpufreq_freq_attr_scaling_boost_freqs) {
- drv_attr++;
- continue;
- }
-
ret = sysfs_create_file(&policy->kobj, &((*drv_attr)->attr));
if (ret)
return ret;
--
2.31.1.272.g89b43f80a514