[U-Boot] [u-boot] [PATCH] imx27: make 26MHz clock input value selectable from config files.

Some boards like Freescale imx27-ipcam and Vista Silicon imx27_visstrim_m10 have 25MHz clocks connected to 26MHz input.
This patch allows this value to be specified from the board configuration file in the same way as it is done with 32KHz clock.
It does not break any existing board since its default value is 26MHz. Tested in imx27lite and imx27_visstrim_m10 board.
Signed-off-by: Javier Martin javier.martin@vista-silicon.com -- cpu/arm926ejs/mx27/generic.c | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/cpu/arm926ejs/mx27/generic.c b/cpu/arm926ejs/mx27/generic.c index da05c55..c26fc56 100644 --- a/cpu/arm926ejs/mx27/generic.c +++ b/cpu/arm926ejs/mx27/generic.c @@ -26,7 +26,9 @@ #ifdef CONFIG_MXC_MMC #include <asm/arch/mxcmmc.h> #endif - +#ifndef CONFIG_MX27_CLK26M +#define CONFIG_MX27_CLK26M 26000000 +#endif /* * get the system pll clock in Hz * @@ -58,9 +60,9 @@ static ulong clk_in_26m(void)
if (readl(&pll->cscr) & CSCR_OSC26M_DIV1P5) { /* divide by 1.5 */ - return 26000000 * 2 / 3; + return CONFIG_MX27_CLK26M * 2 / 3; } else { - return 26000000; + return CONFIG_MX27_CLK26M; } }

I think Fred Fan is currently responsible of acking this patch if there are no objections, but he seems missing since some weeks. Couldn't the patch be reviewed by a higher level maintainer?
Thanks.

Dear javier Martin,
In message eedb5540910290053n75762fbue8a277b21b983e16@mail.gmail.com you wrote:
Some boards like Freescale imx27-ipcam and Vista Silicon imx27_visstrim_m10 have 25MHz clocks connected to 26MHz input.
This patch allows this value to be specified from the board configuration file in the same way as it is done with 32KHz clock.
It does not break any existing board since its default value is 26MHz. Tested in imx27lite and imx27_visstrim_m10 board.
Sorry for the long delay.
Signed-off-by: Javier Martin javier.martin@vista-silicon.com
cpu/arm926ejs/mx27/generic.c | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/cpu/arm926ejs/mx27/generic.c b/cpu/arm926ejs/mx27/generic.c index da05c55..c26fc56 100644 --- a/cpu/arm926ejs/mx27/generic.c +++ b/cpu/arm926ejs/mx27/generic.c @@ -26,7 +26,9 @@ #ifdef CONFIG_MXC_MMC #include <asm/arch/mxcmmc.h> #endif
+#ifndef CONFIG_MX27_CLK26M +#define CONFIG_MX27_CLK26M 26000000 +#endif
I agree with the patch in general, but it seems very strange to me to name the variable "CLK26M" when it could be, for example, 25M instead.
Please chose a better name and resubmit.
Best regards,
Wolfgang Denk

I agree with the patch in general, but it seems very strange to me to
name the variable "CLK26M" when it could be, for example, 25M instead.
Please chose a better name and resubmit.
Thank you for your comments I will pick up a better name and resubmit.
participants (2)
-
javier Martin
-
Wolfgang Denk