mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH v2 1/2] m33xx-clock: configure PLLs based on oscillator frequency
@ 2013-04-18  9:47 Jan Luebbe
  2013-04-18  9:47 ` [PATCH v2 2/2] m33xx-clock: remove unused code Jan Luebbe
  0 siblings, 1 reply; 2+ messages in thread
From: Jan Luebbe @ 2013-04-18  9:47 UTC (permalink / raw)
  To: barebox

The *PLL_N values can be calculated from the OSC value. This patch
includes no functional change.

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
---
    changes from v1:
      * add change description (sha)
      * add spaces around operator (sha)
      * split off patch to remove unused code

 arch/arm/mach-omap/include/mach/am33xx-clock.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-omap/include/mach/am33xx-clock.h b/arch/arm/mach-omap/include/mach/am33xx-clock.h
index 39c107f..cf4c921 100644
--- a/arch/arm/mach-omap/include/mach/am33xx-clock.h
+++ b/arch/arm/mach-omap/include/mach/am33xx-clock.h
@@ -31,12 +31,12 @@
 #define MPUPLL_M_600	600	/* 125 * n */
 #define MPUPLL_M_720	720	/* 125 * n */
 
-#define MPUPLL_N	23	/* (n -1 ) */
+#define MPUPLL_N	(OSC - 1)
 #define MPUPLL_M2	1
 
 /* Core PLL Fdll = 1 GHZ, */
 #define COREPLL_M	1000	/* 125 * n */
-#define COREPLL_N	23	/* (n -1 ) */
+#define COREPLL_N	(OSC - 1)
 
 #define COREPLL_M4	10	/* CORE_CLKOUTM4 = 200 MHZ */
 #define COREPLL_M5	8	/* CORE_CLKOUTM5 = 250 MHZ */
@@ -48,7 +48,7 @@
  * For clkout = 192 MHZ, Fdll = 960 MHZ, divider values are given below
  */
 #define PERPLL_M	960
-#define PERPLL_N	23
+#define PERPLL_N	(OSC - 1)
 #define PERPLL_M2	5
 
 /* DDR Freq is 166 MHZ for now*/
@@ -60,7 +60,7 @@
 #define DDRPLL_M	266
 #endif
 
-#define DDRPLL_N	23
+#define DDRPLL_N	(OSC - 1)
 #define DDRPLL_M2	1
 
 /* PRCM */
-- 
1.8.2.rc2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

* [PATCH v2 2/2] m33xx-clock: remove unused code
  2013-04-18  9:47 [PATCH v2 1/2] m33xx-clock: configure PLLs based on oscillator frequency Jan Luebbe
@ 2013-04-18  9:47 ` Jan Luebbe
  0 siblings, 0 replies; 2+ messages in thread
From: Jan Luebbe @ 2013-04-18  9:47 UTC (permalink / raw)
  To: barebox

This patch includes no functional change. If a configurable DDRPLL_M
is required later, it should be set by the board instead of from here.

Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
---
 arch/arm/mach-omap/include/mach/am33xx-clock.h | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/arch/arm/mach-omap/include/mach/am33xx-clock.h b/arch/arm/mach-omap/include/mach/am33xx-clock.h
index cf4c921..028df43 100644
--- a/arch/arm/mach-omap/include/mach/am33xx-clock.h
+++ b/arch/arm/mach-omap/include/mach/am33xx-clock.h
@@ -51,15 +51,9 @@
 #define PERPLL_N	(OSC - 1)
 #define PERPLL_M2	5
 
-/* DDR Freq is 166 MHZ for now*/
+/* DDR Freq is 266 MHZ for now*/
 /* Set Fdll = 400 MHZ , Fdll = M * 2 * CLKINP/ N + 1; clkout = Fdll /(2 * M2) */
-//#if	(CONFIG_AM335X_EVM_IS_13x13 == 1)
-#if 0
-#define DDRPLL_M	166	/* M/N + 1 = 25/3 */
-#else
 #define DDRPLL_M	266
-#endif
-
 #define DDRPLL_N	(OSC - 1)
 #define DDRPLL_M2	1
 
-- 
1.8.2.rc2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

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

end of thread, other threads:[~2013-04-18  9:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-04-18  9:47 [PATCH v2 1/2] m33xx-clock: configure PLLs based on oscillator frequency Jan Luebbe
2013-04-18  9:47 ` [PATCH v2 2/2] m33xx-clock: remove unused code Jan Luebbe

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