]> git.sur5r.net Git - u-boot/commitdiff
fsl ddr skip interleaving if not supported.
authorEd Swarthout <Ed.Swarthout@freescale.com>
Wed, 29 Oct 2008 14:21:44 +0000 (09:21 -0500)
committerAndrew Fleming-AFLEMING <afleming@freescale.com>
Thu, 4 Dec 2008 04:47:19 +0000 (22:47 -0600)
Removed while(1) hang if memctl_intlv_ctl is set wrong.
Remove embedded tabs from strings.

Signed-off-by: Ed Swarthout <Ed.Swarthout@freescale.com>
Acked-by: Kumar Gala <galak@kernel.crashing.org>
Acked-by: Andy Fleming <afleming@freescale.com>
cpu/mpc8xxx/ddr/main.c
cpu/mpc8xxx/ddr/options.c

index 21a16d97e12c5e75ab6dcaf1fef891805a78de2b..f1ad1328658726c5256b5946ca8d5565d273e0b7 100644 (file)
@@ -475,9 +475,14 @@ phys_size_t fsl_ddr_sdram(void)
                         */
                        memctl_interleaved = 1;
                } else {
-                       printf("Error: memctl interleaving not "
+                       printf("Warning: memctl interleaving not "
                                "properly configured on all controllers\n");
-                       while (1);
+                       memctl_interleaved = 0;
+                       for (i = 0; i < CONFIG_NUM_DDR_CONTROLLERS; i++)
+                               info.memctl_opts[i].memctl_interleaving = 0;
+                       debug("Recomputing with memctl_interleaving off.\n");
+                       total_memory = fsl_ddr_compute(&info,
+                                                      STEP_ASSIGN_ADDRESSES);
                }
        }
 
index 714e88d7fa5e10ca7d7ed647e9c985764e31ec21..af7f73a835ae4011709192da96444d9d0600b5f7 100644 (file)
@@ -197,10 +197,10 @@ unsigned int populate_memctl_options(int all_DIMMs_registered,
         */
        if ((p = getenv("memctl_intlv_ctl")) != NULL) {
                if (pdimm[0].n_ranks == 0) {
-                       printf("There is no rank on CS0. Because only rank on \
-                               CS0 and ranks chip-select interleaved with CS0\
-                               are controller interleaved, force non memory \
-                               controller interleaving\n");
+                       printf("There is no rank on CS0. Because only rank on "
+                               "CS0 and ranks chip-select interleaved with CS0"
+                               " are controller interleaved, force non memory "
+                               "controller interleaving\n");
                        popts->memctl_interleaving = 0;
                } else {
                        popts->memctl_interleaving = 1;
@@ -239,22 +239,22 @@ unsigned int populate_memctl_options(int all_DIMMs_registered,
                case FSL_DDR_CS0_CS1:
                        if (pdimm[0].n_ranks != 2) {
                                popts->ba_intlv_ctl = 0;
-                               printf("No enough bank(chip-select) for \
-                                       CS0+CS1, force non-interleaving!\n");
+                               printf("Not enough bank(chip-select) for "
+                                       "CS0+CS1, force non-interleaving!\n");
                        }
                        break;
                case FSL_DDR_CS2_CS3:
                        if (pdimm[1].n_ranks !=2){
                                popts->ba_intlv_ctl = 0;
-                               printf("No enough bank(CS) for CS2+CS3, \
-                                       force non-interleaving!\n");
+                               printf("Not enough bank(CS) for CS2+CS3, "
+                                       "force non-interleaving!\n");
                        }
                        break;
                case FSL_DDR_CS0_CS1_AND_CS2_CS3:
                        if ((pdimm[0].n_ranks != 2)||(pdimm[1].n_ranks != 2)) {
                                popts->ba_intlv_ctl = 0;
-                               printf("No enough bank(CS) for CS0+CS1 or \
-                                        CS2+CS3, force non-interleaving!\n");
+                               printf("Not enough bank(CS) for CS0+CS1 or "
+                                       "CS2+CS3, force non-interleaving!\n");
                        }
                        break;
                default: