Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1247940 > unrolled thread

[PATCH V2 1/5] cpufreq: Use cpumask_copy instead of cpumask_or to copy a mask

Started byViresh Kumar <viresh.kumar@linaro.org>
First post2015-10-15 18:10 +0200
Last post2015-10-15 18:10 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH V2 1/5] cpufreq: Use cpumask_copy instead of cpumask_or to copy a mask Viresh Kumar <viresh.kumar@linaro.org> - 2015-10-15 18:10 +0200

#1247940 — [PATCH V2 1/5] cpufreq: Use cpumask_copy instead of cpumask_or to copy a mask

FromViresh Kumar <viresh.kumar@linaro.org>
Date2015-10-15 18:10 +0200
Subject[PATCH V2 1/5] cpufreq: Use cpumask_copy instead of cpumask_or to copy a mask
Message-ID<qjTgm-2Z7-23@gated-at.bofh.it>
->related_cpus is empty at this point of time and copying ->cpus to it
or orring ->related_cpus with ->cpus would result in the same value. But
cpumask_copy makes it rather clear.

Reviewed-by: Saravana Kannan <skannan@codeaurora.org>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
 drivers/cpufreq/cpufreq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index 8701dc559850..16b9e811ff01 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -1214,7 +1214,7 @@ static int cpufreq_online(unsigned int cpu)
 
 	if (new_policy) {
 		/* related_cpus should at least include policy->cpus. */
-		cpumask_or(policy->related_cpus, policy->related_cpus, policy->cpus);
+		cpumask_copy(policy->related_cpus, policy->cpus);
 		/* Remember CPUs present at the policy creation time. */
 		cpumask_and(policy->real_cpus, policy->cpus, cpu_present_mask);
 	}
-- 
2.4.0

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web