Thread (25 messages) 25 messages, 3 authors, 2014-09-29

RE: [PATCH 1/2] cpufreq: ppc-corenet: remove duplicate update of cpu_data

From: Yuantian Tang <hidden>
Date: 2014-09-10 05:30:06

-----Original Message-----
From: Viresh Kumar [mailto:viresh.kumar@linaro.org]
Sent: Wednesday, September 10, 2014 12:33 PM
To: Rafael Wysocki; Tang Yuantian-B29983
Cc: Lists linaro-kernel; linux-pm@vger.kernel.org; Zhang Hongbo-B45939; Li
Yang-Leo-R58472; Viresh Kumar
Subject: Re: [PATCH 1/2] cpufreq: ppc-corenet: remove duplicate update of
cpu_data

On 2 September 2014 09:11, Viresh Kumar [off-list ref] wrote:
quoted
'cpu_data' is updated for policy->cpu first and then for all CPUs in
policy->cpus. policy->cpus is guaranteed to contain policy->cpu as
policy->well and so
the first write to 'cpu_data' for policy->cpu is redundant. Remove it.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
---
Hi Yuantian,

I was looking into this driver due to issues reported by Hongtao
(cc'd) and found that we can live without some code. These aren't
fixing any bugs and are just cleanups.

I didn't had a compiler for this and so this isn't even compiled. It
would be great if you can please review/test these patches.

 drivers/cpufreq/ppc-corenet-cpufreq.c | 1 -
 1 file changed, 1 deletion(-)
diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c
b/drivers/cpufreq/ppc-corenet-cpufreq.c
index 3607070..bee5df7 100644
--- a/drivers/cpufreq/ppc-corenet-cpufreq.c
+++ b/drivers/cpufreq/ppc-corenet-cpufreq.c
@@ -199,7 +199,6 @@ static int corenet_cpufreq_cpu_init(struct
cpufreq_policy *policy)
quoted
        }

        data->table = table;
-       per_cpu(cpu_data, cpu) = data;

        /* update ->cpus if we have cluster, no harm if not */
        cpumask_copy(policy->cpus, per_cpu(cpu_mask, cpu));
Hi Yuantian,

Can we get your Ack for this patch atleast so that Rafael can apply it ?
Yeah, your patch should be ok, but is it the best solution?
I was thinking about a final solution just like ARM did.

Thanks,
Yuantian
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help