Re: [U-Boot] [PATCH 6/7] powerpc/82xx: use SDRAM detection for mgcoge2ne

2012-07-31 Thread Wolfgang Denk
Dear Gerlando Falauto,

In message <1343402200-32020-7-git-send-email-gerlando.fala...@keymile.com> you 
wrote:
> mgcoge2ne was an intermediate step towards mgcoge3ne. One difference is the
> smaller SDRAM on mgcoge2ne (128MB). To support both boards with the same
> u-boot we use here the SDRAM detection.
> 
> This patch enables SDRAM detection between 256MB and 128MB.
> So in addition to the existing 256MB geometry:
>  4 chips x 8M (13 rows, 10 cols) x 16 bit x 4 banks
> we can now also have 128MB geometry:
>  4 chips x 4M (13 rows,  9 cols) x 16 bit x 4 banks
> 
> Signed-off-by: Gerlando Falauto 
> ---
>  include/configs/km82xx.h |   17 +
>  1 files changed, 13 insertions(+), 4 deletions(-)

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
I've been programming for (35-9=) 24 years myself,  and  I  find  the
best way to learn a new language is to *read* every example snippet I
can find, with a reference book close by. Eventually, the *rhythm* of
the language starts pounding in my head... and my fluency is close at
hand. That's how I learned Perl, and now I'm one of the drummers. :-)
 -- Randal L. Schwartz in <8cvi6p2tir@gadget.cscaper.com>
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH 6/7] powerpc/82xx: use SDRAM detection for mgcoge2ne

2012-07-27 Thread Gerlando Falauto
mgcoge2ne was an intermediate step towards mgcoge3ne. One difference is the
smaller SDRAM on mgcoge2ne (128MB). To support both boards with the same
u-boot we use here the SDRAM detection.

This patch enables SDRAM detection between 256MB and 128MB.
So in addition to the existing 256MB geometry:
 4 chips x 8M (13 rows, 10 cols) x 16 bit x 4 banks
we can now also have 128MB geometry:
 4 chips x 4M (13 rows,  9 cols) x 16 bit x 4 banks

Signed-off-by: Gerlando Falauto 
---
 include/configs/km82xx.h |   17 +
 1 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/include/configs/km82xx.h b/include/configs/km82xx.h
index 9bfb8df..f046337 100644
--- a/include/configs/km82xx.h
+++ b/include/configs/km82xx.h
@@ -119,7 +119,8 @@
 
 /*
  * Bank 1 - 60x bus SDRAM
- * mgcoge3ne has 256M.
+ * mgcoge3ne has 256MB
+ * mgcoge2ne has 128MB
  */
 #define SDRAM_MAX_SIZE 0x1000  /* max. 256 MB  */
 #define CONFIG_SYS_GLOBAL_SDRAM_LIMIT  (512 << 20) /* less than 512 MB */
@@ -127,20 +128,28 @@
 #define CONFIG_SYS_OR1 ((~(CONFIG_SYS_GLOBAL_SDRAM_LIMIT-1) & \
   ORxS_SDAM_MSK)   |\
ORxS_BPD_4  |\
-   ORxS_ROWST_PBI1_A4  |\
ORxS_NUMR_13)
 
 #define CONFIG_SYS_PSDMR ( \
PSDMR_PBI   |\
-   PSDMR_SDAM_A17_IS_A5|\
PSDMR_BSMA_A13_A15  |\
-   PSDMR_SDA10_PBI1_A6 |\
PSDMR_RFRC_5_CLK|\
PSDMR_PRETOACT_2W   |\
PSDMR_ACTTORW_2W|\
PSDMR_LDOTOPRE_1C   |\
PSDMR_WRC_2C|\
PSDMR_CL_2)
+
+#define CONFIG_SYS_SDRAM_LIST  {   \
+   {   .size   = 256 << 20,\
+   .or1= ORxS_ROWST_PBI1_A4,   \
+   .psdmr  = PSDMR_SDAM_A17_IS_A5 | PSDMR_SDA10_PBI1_A6,   \
+   },  \
+   {   .size   = 128 << 20,\
+   .or1= ORxS_ROWST_PBI1_A5,   \
+   .psdmr  = PSDMR_SDAM_A16_IS_A5 | PSDMR_SDA10_PBI1_A7,   \
+   },  \
+}
 #endif /* defined(CONFIG_MGCOGE3NE) */
 
 /* include further common stuff for all keymile 82xx boards */
-- 
1.7.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot