cpufreq Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cpufreq/db8500: support all frequencies
@ 2011-09-02  6:52 Linus Walleij
  2011-10-07 11:13 ` Linus Walleij
  0 siblings, 1 reply; 4+ messages in thread
From: Linus Walleij @ 2011-09-02  6:52 UTC (permalink / raw)
  To: Dave Jones, cpufreq; +Cc: Lee Jones, Linus Walleij, Vincent Guittot

From: Linus Walleij <linus.walleij@linaro.org>

This adds support for the 200 MHz frequency mode of the
DB8500 SoC, and prints the available frequencies at init
time.

Cc: Vincent Guittot <vincent.guittot@linaro.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
 drivers/cpufreq/db8500-cpufreq.c |   24 ++++++++++++++++--------
 1 files changed, 16 insertions(+), 8 deletions(-)

diff --git a/drivers/cpufreq/db8500-cpufreq.c b/drivers/cpufreq/db8500-cpufreq.c
index d90456a..26c1645 100644
--- a/drivers/cpufreq/db8500-cpufreq.c
+++ b/drivers/cpufreq/db8500-cpufreq.c
@@ -18,24 +18,29 @@
 static struct cpufreq_frequency_table freq_table[] = {
 	[0] = {
 		.index = 0,
-		.frequency = 300000,
+		.frequency = 200000,
 	},
 	[1] = {
 		.index = 1,
-		.frequency = 600000,
+		.frequency = 300000,
 	},
 	[2] = {
-		/* Used for MAX_OPP, if available */
 		.index = 2,
-		.frequency = CPUFREQ_TABLE_END,
+		.frequency = 600000,
 	},
 	[3] = {
+		/* Used for MAX_OPP, if available */
 		.index = 3,
 		.frequency = CPUFREQ_TABLE_END,
 	},
+	[4] = {
+		.index = 4,
+		.frequency = CPUFREQ_TABLE_END,
+	},
 };
 
 static enum arm_opp idx2opp[] = {
+	ARM_EXTCLK,
 	ARM_50_OPP,
 	ARM_100_OPP,
 	ARM_MAX_OPP
@@ -108,12 +113,15 @@ static int __cpuinit db8500_cpufreq_init(struct cpufreq_policy *policy)
 
 	BUILD_BUG_ON(ARRAY_SIZE(idx2opp) + 1 != ARRAY_SIZE(freq_table));
 
-	if (cpu_is_u8500v2() && !prcmu_is_u8400()) {
-		freq_table[0].frequency = 400000;
-		freq_table[1].frequency = 800000;
+	if (!prcmu_is_u8400()) {
+		freq_table[1].frequency = 400000;
+		freq_table[2].frequency = 800000;
 		if (prcmu_has_arm_maxopp())
-			freq_table[2].frequency = 1000000;
+			freq_table[3].frequency = 1000000;
 	}
+	pr_info("db8500-cpufreq : Available frequencies:\n");
+	while (freq_table[i].frequency != CPUFREQ_TABLE_END)
+		pr_info("  %d Mhz\n", freq_table[i++].frequency/1000);
 
 	/* get policy fields based on the table */
 	res = cpufreq_frequency_table_cpuinfo(policy, freq_table);
-- 
1.7.3.2


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] cpufreq/db8500: support all frequencies
  2011-09-02  6:52 [PATCH] cpufreq/db8500: support all frequencies Linus Walleij
@ 2011-10-07 11:13 ` Linus Walleij
  2011-10-07 19:52   ` Dave Jones
  0 siblings, 1 reply; 4+ messages in thread
From: Linus Walleij @ 2011-10-07 11:13 UTC (permalink / raw)
  To: Dave Jones; +Cc: cpufreq, Lee Jones, Vincent Guittot

On Fri, Sep 2, 2011 at 8:52 AM, Linus Walleij
<linus.walleij@stericsson.com> wrote:

> From: Linus Walleij <linus.walleij@linaro.org>
>
> This adds support for the 200 MHz frequency mode of the
> DB8500 SoC, and prints the available frequencies at init
> time.
>
> Cc: Vincent Guittot <vincent.guittot@linaro.org>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

Dave have you had a chance to look at this?

I guess I might not be seeing it in next due to kernelorg
outage...

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] cpufreq/db8500: support all frequencies
  2011-10-07 11:13 ` Linus Walleij
@ 2011-10-07 19:52   ` Dave Jones
  2011-10-07 19:54     ` Dave Jones
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Jones @ 2011-10-07 19:52 UTC (permalink / raw)
  To: Linus Walleij; +Cc: cpufreq, Lee Jones, Vincent Guittot

On Fri, Oct 07, 2011 at 01:13:07PM +0200, Linus Walleij wrote:
 > On Fri, Sep 2, 2011 at 8:52 AM, Linus Walleij
 > <linus.walleij@stericsson.com> wrote:
 > 
 > > From: Linus Walleij <linus.walleij@linaro.org>
 > >
 > > This adds support for the 200 MHz frequency mode of the
 > > DB8500 SoC, and prints the available frequencies at init
 > > time.
 > >
 > > Cc: Vincent Guittot <vincent.guittot@linaro.org>
 > > Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
 > 
 > Dave have you had a chance to look at this?

hmm, I don't see that one in my mail archive.
Can you bounce me a copy please ?
 
 > I guess I might not be seeing it in next due to kernelorg
 > outage...

I'm sitting on a bunch of patches pending for 3.1 when the merge window opens.
I've been taking a 'wait and see' approach wrt to kernel.org.
Hope to have an account set up there again soon so that I can get
cpufreq.git available once more.

thanks,

	Dave


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] cpufreq/db8500: support all frequencies
  2011-10-07 19:52   ` Dave Jones
@ 2011-10-07 19:54     ` Dave Jones
  0 siblings, 0 replies; 4+ messages in thread
From: Dave Jones @ 2011-10-07 19:54 UTC (permalink / raw)
  To: Linus Walleij; +Cc: cpufreq, Lee Jones, Vincent Guittot

On Fri, Oct 07, 2011 at 03:52:49PM -0400, Dave Jones wrote:
 > On Fri, Oct 07, 2011 at 01:13:07PM +0200, Linus Walleij wrote:
 >  > On Fri, Sep 2, 2011 at 8:52 AM, Linus Walleij
 >  > <linus.walleij@stericsson.com> wrote:
 >  > 
 >  > > From: Linus Walleij <linus.walleij@linaro.org>
 >  > >
 >  > > This adds support for the 200 MHz frequency mode of the
 >  > > DB8500 SoC, and prints the available frequencies at init
 >  > > time.
 >  > >
 >  > > Cc: Vincent Guittot <vincent.guittot@linaro.org>
 >  > > Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
 >  > 
 >  > Dave have you had a chance to look at this?
 > 
 > hmm, I don't see that one in my mail archive.
 > Can you bounce me a copy please ?

scrap that, found it. It was already in my queue.

	Dave

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-10-07 19:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-02  6:52 [PATCH] cpufreq/db8500: support all frequencies Linus Walleij
2011-10-07 11:13 ` Linus Walleij
2011-10-07 19:52   ` Dave Jones
2011-10-07 19:54     ` Dave Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox