Re: [PATCHv5] cpufreq for freescale mx51

2010-10-22 Thread Amit Kucheria
On 10 Oct 21, Yong Shen wrote: > From: Yong Shen > > Currently, only two operating points: 160Mhz and 800Mhz. > the operating points are tested on babbage 3.0 > > Signed-off-by: Yong Shen Signed-off-by: Amit Kucheria > --- > arch/arm/Kconfig |6 + > arch/arm/mach-m

[PATCHv5] cpufreq for freescale mx51

2010-10-21 Thread yong . shen
From: Yong Shen Currently, only two operating points: 160Mhz and 800Mhz. the operating points are tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |1 +

Re: [[PATCHv4]] cpufreq for freescale mx51

2010-10-21 Thread Amit Kucheria
On 10 Oct 20, Yong Shen wrote: > From: Yong Shen > > Currently, only two operating points: 160Mhz and 800Mhz. > the operating points are tested on babbage 3.0 > > Signed-off-by: Yong Shen At this point, I have no more feedback. But could you rebase your patch on top of Sascha's tree git://git.

[[PATCHv4]] cpufreq for freescale mx51

2010-10-20 Thread yong . shen
From: Yong Shen Currently, only two operating points: 160Mhz and 800Mhz. the operating points are tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |1 +

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-19 Thread Sascha Hauer
On Tue, Oct 19, 2010 at 05:28:51PM +0800, Yong Shen wrote: > > > > > > > > > +#include > > > + > > > +static struct cpu_op mx51_cpu_op[] = { > > > + { > > > + .cpu_rate = 16000,}, > > > + { > > > + .cpu_rate = 8,}, > > > +}; > > > > Why did you remove the values between

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-19 Thread Yong Shen
Vishwanath, Thanks for suggestion. Voltage change is not a must for frequency change, and it can be integrate in after regulator driver is ready for mx51. Yong On Tue, Oct 19, 2010 at 5:18 PM, Vishwanath Sripathy < vishwanath.sripa...@linaro.org> wrote: > Yong, > > >On Mon, Oct 18, 2010 at 1:51

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-19 Thread Yong Shen
> > > > > +#include > > + > > +static struct cpu_op mx51_cpu_op[] = { > > + { > > + .cpu_rate = 16000,}, > > + { > > + .cpu_rate = 8,}, > > +}; > > Why did you remove the values between 800MHz and 160MHz? 400MHz and > 200Mhz should work also, no? > > It proved that thos

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-19 Thread Vishwanath Sripathy
Yong, >On Mon, Oct 18, 2010 at 1:51 PM, wrote: >From: Yong Shen >the operating points are tested on babbage 3.0 Commit log needs more description like What are the supported operating points, Is there any link between mpu OPP and other devices? What are the platforms this patch is tested agains

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-19 Thread Yong Shen
> > > > > > > > > > > > > > +struct cpu_wp *(*get_cpu_wp)(int *wp); > > > > > > + > > > > > > > > > > This is not needed. > > > > > > > > > This is needed, otherwise it does not pass compile. > > > > > > This hunk is the only change to arch/arm/mach-mx5/cpu.c and get_cpu_wp > > > is introduced with

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-19 Thread Yong Shen
Hi amit, On Mon, Oct 18, 2010 at 6:02 PM, Amit Kucheria wrote: > Yong, > > I get the following errors if I try to compile this with the Linaro > toolchain. > > In file included from > > /home/amit/work/sources/linux-amit-upstream.git/arch/arm/plat-mxc/include/mach/hardware.h:63:0, >

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-18 Thread Sascha Hauer
On Mon, Oct 18, 2010 at 04:21:45PM +0800, yong.s...@linaro.org wrote: > From: Yong Shen > > the operating points are tested on babbage 3.0 > > Signed-off-by: Yong Shen > --- > arch/arm/Kconfig |6 + > arch/arm/mach-mx5/Kconfig |1 + > arch/arm/mach-mx

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-18 Thread Sascha Hauer
On Mon, Oct 18, 2010 at 05:08:14PM +0800, Yong Shen wrote: > Hi Sascha, > > > On Mon, Oct 18, 2010 at 4:31 PM, Sascha Hauer wrote: > > > Hi Yong, > > > > On Mon, Oct 18, 2010 at 01:43:43PM +0800, Yong Shen wrote: > > > Hi Sascha, > > > > > > Thanks for your thorough review. I have two feedbacks

Re: [PATCHv3] cpufreq for freescale mx51

2010-10-18 Thread Amit Kucheria
Yong, I get the following errors if I try to compile this with the Linaro toolchain. In file included from /home/amit/work/sources/linux-amit-upstream.git/arch/arm/plat-mxc/include/mach/hardware.h:63:0, from /home/amit/work/sources/linux-amit-upstream.git/arch/a

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-18 Thread Sascha Hauer
Hi Yong, On Mon, Oct 18, 2010 at 01:43:43PM +0800, Yong Shen wrote: > Hi Sascha, > > Thanks for your thorough review. I have two feedbacks to your commends. > Sorry for delayed response, cause I had a hard time due to my computer crash > and data loss. > > > diff --git a/arch/arm/mach-mx5/cpu.c

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-18 Thread Yong Shen
Hi Sascha, On Mon, Oct 18, 2010 at 4:31 PM, Sascha Hauer wrote: > Hi Yong, > > On Mon, Oct 18, 2010 at 01:43:43PM +0800, Yong Shen wrote: > > Hi Sascha, > > > > Thanks for your thorough review. I have two feedbacks to your commends. > > Sorry for delayed response, cause I had a hard time due to

[PATCHv3] cpufreq for freescale mx51

2010-10-18 Thread yong . shen
From: Yong Shen the operating points are tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |1 + arch/arm/mach-mx5/board-mx51_babbage.c | 12 ++- arch

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-17 Thread Yong Shen
Hi Amit, I agree about all the comments. New patch is coming. Yong On Wed, Oct 13, 2010 at 6:38 PM, Amit Kucheria wrote: > Yong, > > Some more comments. But the patch is looking good now. > > On Fri, Oct 8, 2010 at 11:08 AM, wrote: > > From: Yong Shen > > > > it is tested on babbage 3.0 > >

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-17 Thread Yong Shen
Hi Sascha, Thanks for your thorough review. I have two feedbacks to your commends. Sorry for delayed response, cause I had a hard time due to my computer crash and data loss. > diff --git a/arch/arm/mach-mx5/cpu.c b/arch/arm/mach-mx5/cpu.c > > index 2d37785..83add9c 100644 > > --- a/arch/arm/mach

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-13 Thread Sascha Hauer
On Fri, Oct 08, 2010 at 04:08:27PM +0800, yong.s...@linaro.org wrote: > From: Yong Shen > > it is tested on babbage 3.0 > > Signed-off-by: Yong Shen > --- > arch/arm/Kconfig |6 + > arch/arm/mach-mx5/Kconfig |1 + > arch/arm/mach-mx5/Makefile

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-13 Thread Amit Kucheria
Yong, Some more comments. But the patch is looking good now. On Fri, Oct 8, 2010 at 11:08 AM, wrote: > From: Yong Shen > > it is tested on babbage 3.0 Change to "Cpufreq driver for imx51. The operating points are currently tested on babbage 3.0." > Signed-off-by: Yong Shen > --- >  arch/ar

Re: [PATCHv2] cpufreq for freescale mx51

2010-10-12 Thread Yong Shen
Does anybody have more comments on [PATCHv2] ? On Thu, Oct 7, 2010 at 8:00 PM, Yong Shen wrote: > > > Using wp_tbl is because that it also contains information like regulator >> > voltage. >> >> The clock code does not handle the regulators, not even in the fsl >> kernel. >> > I did not mean to

cpufreq for freescale mx51

2010-10-08 Thread yong . shen
Hope this time I can cover all the comments. :) ___ linaro-dev mailing list linaro-dev@lists.linaro.org http://lists.linaro.org/mailman/listinfo/linaro-dev

[PATCHv2] cpufreq for freescale mx51

2010-10-08 Thread yong . shen
From: Yong Shen it is tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |1 + arch/arm/mach-mx5/board-mx51_babbage.c | 12 ++- arch/arm/mach-mx5/clock

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Yong Shen
> > Using wp_tbl is because that it also contains information like regulator > > voltage. > > The clock code does not handle the regulators, not even in the fsl > kernel. > I did not mean to say clock code will handle regulators. I mean this table also contains such information which may be needed

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Amit Kucheria
On Thu, Oct 7, 2010 at 2:33 PM, Yong Shen wrote: > >> >  # Object file lists. >> > -obj-y   := cpu.o mm.o clock-mx51.o devices.o >> > +obj-y   := cpu.o mm.o clock-mx51.o devices.o cpu_wp-mx51.o >> >> By hardcoding cpu_wp-mx51 here, you are making the assumption that even if >> cpufreq is turned of

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Yong Shen
> > # Object file lists. > > -obj-y := cpu.o mm.o clock-mx51.o devices.o > > +obj-y := cpu.o mm.o clock-mx51.o devices.o cpu_wp-mx51.o > > By hardcoding cpu_wp-mx51 here, you are making the assumption that even if > cpufreq is turned off, you'll still need the entire WP table to set the > cpu

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Sascha Hauer
On Thu, Oct 07, 2010 at 10:40:44AM +0300, Amit Kucheria wrote: > On 10 Oct 07, Yong Shen wrote: > > > > > > +static struct cpufreq_frequency_table imx_freq_table[4]; > > > > > > Three frequencies should be enough for everyone, right? This should be > > > dynamically allocated like in other cpufreq

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Sascha Hauer
On Thu, Oct 07, 2010 at 11:36:07AM +0800, Yong Shen wrote: > Hi Sascha, > > Thanks for your thorough comments. > I have already received comments from Arnd before yours arrived. So some of > the commends you two provided are common. > I acknowledge most of your opinions, except for two, I have som

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Amit Kucheria
Some comments inline. On 10 Oct 07, Yong Shen wrote: > From: Yong Shen > > it is tested on babbage 3.0 > > Signed-off-by: Yong Shen > --- > arch/arm/Kconfig |6 + > arch/arm/mach-mx5/Kconfig |1 + > arch/arm/mach-mx5/Makefile |2 +- >

Re: [PATCH] cpufreq for freescale mx51

2010-10-07 Thread Amit Kucheria
On 10 Oct 07, Yong Shen wrote: > > > > +static struct cpufreq_frequency_table imx_freq_table[4]; > > > > Three frequencies should be enough for everyone, right? This should be > > dynamically allocated like in other cpufreq drivers. > > > > Yes, we only support 3 work points, which is for sure. A

[PATCH] cpufreq for freescale mx51

2010-10-06 Thread yong . shen
From: Yong Shen it is tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |2 +- arch/arm/mach-mx5/board-mx51_babbage.c | 10 ++- arch/arm/mach-mx5/cloc

Re: [PATCH] cpufreq for freescale mx51

2010-10-06 Thread Yong Shen
> I still disagree, but it's not important. IMHO most of the uses of > __raw_readl should be converted to readl or readl_relaxed if you are > worried about efficiency. > > The main difference between __raw_readl and readl_relaxed is that the > endianess is well-defined on readl_relaxed. > >

Re: [PATCH] cpufreq for freescale mx51

2010-10-06 Thread Yong Shen
Hi Sascha, Thanks for your thorough comments. I have already received comments from Arnd before yours arrived. So some of the commends you two provided are common. I acknowledge most of your opinions, except for two, I have some explanations. > > +*/ > > > + reg = __raw_readl(MXC_CCM_CACRR)

Re: [PATCH] cpufreq for freescale mx51

2010-10-06 Thread Sascha Hauer
On Thu, Sep 30, 2010 at 01:48:17PM +0300, Amit Kucheria wrote: > Add'ed linaro-dev and linux-arm-kernel to CC. > > Thanks Yong, some feeback follows inline. > > On 10 Sep 29, Yong Shen wrote: > > From: Yong Shen > > > > --- > > arch/arm/Kconfig |6 + > > arch/arm/mach

Re: [PATCH] cpufreq for freescale mx51

2010-10-06 Thread Arnd Bergmann
On Wednesday 06 October 2010, Yong Shen wrote: > Hi Arnd, > > Really appreciate your valuable comments. Most of them are accepted. I have > different option about two comments. > 1. > > > It would be better to make this code a proper device driver, > > probably a platform_driver unless you have a

Re: [PATCH] cpufreq for freescale mx51

2010-10-05 Thread Yong Shen
Hi Arnd, Really appreciate your valuable comments. Most of them are accepted. I have different option about two comments. 1. > It would be better to make this code a proper device driver, > probably a platform_driver unless you have a way to probe > the presence of the registers on another bus. >

Re: [PATCH] cpufreq for freescale mx51

2010-10-05 Thread Arnd Bergmann
> From: Yong Shen > > it is tested on babbage 3.0 One big comment and a couple of smaller ones: It would be better to make this code a proper device driver, probably a platform_driver unless you have a way to probe the presence of the registers on another bus. Making it a driver that registers

[PATCH] cpufreq for freescale mx51

2010-10-05 Thread yong . shen
From: Yong Shen it is tested on babbage 3.0 Signed-off-by: Yong Shen --- arch/arm/Kconfig |6 + arch/arm/mach-mx5/Kconfig |1 + arch/arm/mach-mx5/Makefile |2 +- arch/arm/mach-mx5/board-mx51_babbage.c |7 +- arch/arm/mach-mx5/clock

Re: [PATCH] cpufreq for freescale mx51

2010-10-04 Thread Amit Kucheria
More comments. On Fri, Oct 1, 2010 at 7:06 AM, Yong Shen wrote: > Hi Amit, > > Please see my feedback embedded. > > On Thu, Sep 30, 2010 at 6:48 PM, Amit Kucheria > wrote: [snip] >> > +static int mxc_set_target(struct cpufreq_policy *policy, >> > +                       unsigned int target_fre

Re: [PATCH] cpufreq for freescale mx51

2010-09-30 Thread Yong Shen
Hi Amit, Please see my feedback embedded. On Thu, Sep 30, 2010 at 6:48 PM, Amit Kucheria wrote: > Add'ed linaro-dev and linux-arm-kernel to CC. > > Thanks Yong, some feeback follows inline. > > On 10 Sep 29, Yong Shen wrote: > > From: Yong Shen > > > > --- > > arch/arm/Kconfig

Re: [PATCH] cpufreq for freescale mx51

2010-09-30 Thread Amit Kucheria
Add'ed linaro-dev and linux-arm-kernel to CC. Thanks Yong, some feeback follows inline. On 10 Sep 29, Yong Shen wrote: > From: Yong Shen > > --- > arch/arm/Kconfig |6 + > arch/arm/mach-mx5/Kconfig |1 + > arch/arm/mach-mx5/board-mx51_babbage.c | 32