Skip to content
Snippets Groups Projects
Commit 04efddc8 authored by Jean-Christophe PLAGNIOL-VILLARD's avatar Jean-Christophe PLAGNIOL-VILLARD Committed by Jon Loeliger
Browse files

mpc86xx: Fix unused variable 'config' and 'immap'


and remove useless CONFIG_DDR_INTERLEAVE

Signed-off-by: default avatarJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
parent 83d1b387
No related branches found
No related tags found
No related merge requests found
...@@ -943,7 +943,7 @@ unsigned int enable_ddr(unsigned int ddr_num) ...@@ -943,7 +943,7 @@ unsigned int enable_ddr(unsigned int ddr_num)
spd_eeprom_t spd1,spd2; spd_eeprom_t spd1,spd2;
volatile ccsr_ddr_t *ddr; volatile ccsr_ddr_t *ddr;
unsigned sdram_cfg_1; unsigned sdram_cfg_1;
unsigned char sdram_type, mem_type, config, mod_attr; unsigned char sdram_type, mem_type, mod_attr;
unsigned char d_init; unsigned char d_init;
unsigned int no_dimm1=0, no_dimm2=0; unsigned int no_dimm1=0, no_dimm2=0;
...@@ -1017,6 +1017,10 @@ unsigned int enable_ddr(unsigned int ddr_num) ...@@ -1017,6 +1017,10 @@ unsigned int enable_ddr(unsigned int ddr_num)
printf("No memory modules found for DDR controller %d!!\n", ddr_num); printf("No memory modules found for DDR controller %d!!\n", ddr_num);
return 0; return 0;
} else { } else {
#if defined(CONFIG_DDR_ECC)
unsigned char config;
#endif
mem_type = no_dimm2 ? spd1.mem_type : spd2.mem_type; mem_type = no_dimm2 ? spd1.mem_type : spd2.mem_type;
/* /*
...@@ -1122,8 +1126,8 @@ spd_sdram(void) ...@@ -1122,8 +1126,8 @@ spd_sdram(void)
int memsize_ddr1_dimm2 = 0; int memsize_ddr1_dimm2 = 0;
int memsize_ddr1 = 0; int memsize_ddr1 = 0;
unsigned int law_size_ddr1; unsigned int law_size_ddr1;
volatile immap_t *immap = (immap_t *)CFG_IMMR;
#ifdef CONFIG_DDR_INTERLEAVE #ifdef CONFIG_DDR_INTERLEAVE
volatile immap_t *immap = (immap_t *)CFG_IMMR;
volatile ccsr_ddr_t *ddr1 = &immap->im_ddr1; volatile ccsr_ddr_t *ddr1 = &immap->im_ddr1;
#endif #endif
...@@ -1183,7 +1187,6 @@ spd_sdram(void) ...@@ -1183,7 +1187,6 @@ spd_sdram(void)
#endif #endif
debug("Interleaved memory size is 0x%08lx\n", memsize_total); debug("Interleaved memory size is 0x%08lx\n", memsize_total);
#ifdef CONFIG_DDR_INTERLEAVE
#if (CFG_PAGE_INTERLEAVING == 1) #if (CFG_PAGE_INTERLEAVING == 1)
printf("Page "); printf("Page ");
#elif (CFG_BANK_INTERLEAVING == 1) #elif (CFG_BANK_INTERLEAVING == 1)
...@@ -1192,7 +1195,6 @@ spd_sdram(void) ...@@ -1192,7 +1195,6 @@ spd_sdram(void)
printf("Super-bank "); printf("Super-bank ");
#else #else
printf("Cache-line "); printf("Cache-line ");
#endif
#endif #endif
printf("Interleaved"); printf("Interleaved");
return memsize_total * 1024 * 1024; return memsize_total * 1024 * 1024;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment