/*
- * Copyright 2008 Freescale Semiconductor, Inc.
+ * Copyright 2008-2011 Freescale Semiconductor, Inc.
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
        unsigned int tDQSQ_max_ps = 0;
        unsigned int tQHS_ps = 0;
 
-       unsigned int temp1, temp2, temp3;
+       unsigned int temp1, temp2;
        unsigned int additive_latency = 0;
 #if !defined(CONFIG_FSL_DDR3)
        const unsigned int mclk_ps = get_memory_clk_period_ps();
        }
 
        outpdimm->all_DIMMs_registered = 0;
+       outpdimm->all_DIMMs_unbuffered = 0;
        if (temp1 && !temp2) {
                outpdimm->all_DIMMs_registered = 1;
-       }
-
-       outpdimm->all_DIMMs_unbuffered = 0;
-       if (!temp1 && temp2) {
+               printf("Detected RDIMM(s)\n");
+       } else if (!temp1 && temp2) {
                outpdimm->all_DIMMs_unbuffered = 1;
-       }
-
-       /* CHECKME: */
-       if (!outpdimm->all_DIMMs_registered
-           && !outpdimm->all_DIMMs_unbuffered) {
+               printf("Detected UDIMM(s)\n");
+       } else {
                printf("ERROR:  Mix of registered buffered and unbuffered "
                                "DIMMs detected!\n");
        }
                        outpdimm->rcw[j] = dimm_params[0].rcw[j];
                        for (i = 1; i < number_of_dimms; i++)
                                if (dimm_params[i].rcw[j] != dimm_params[0].rcw[j]) {
-                                       temp3 = 1;
+                                       temp1 = 1;
                                        break;
                                }
                }