ulong size = 0;
ulong fbase = 0;
- fbase = (ulong) CONFIG_SYS_FLASH_BASE;
+ fbase = (ulong) CFG_SYS_FLASH_BASE;
flash_get_size((FPWV *) fbase, &flash_info[0]);
flash_get_offsets((ulong) fbase, &flash_info[0]);
fbase += flash_info[0].size;
info->start[0] = base;
info->protect[0] = 0;
- for (i = 1; i < CONFIG_SYS_SST_SECT; i++) {
+ for (i = 1; i < CFG_SYS_SST_SECT; i++) {
info->start[i] = info->start[i - 1]
- + CONFIG_SYS_SST_SECTSZ;
+ + CFG_SYS_SST_SECTSZ;
info->protect[i] = 0;
}
}
info->sector_count = 0;
info->size = 0;
- info->sector_count = CONFIG_SYS_SST_SECT;
- info->size = CONFIG_SYS_SST_SECT * CONFIG_SYS_SST_SECTSZ;
+ info->sector_count = CFG_SYS_SST_SECT;
+ info->size = CFG_SYS_SST_SECT * CFG_SYS_SST_SECTSZ;
/* reset ID mode */
*addr = (FPWV) 0x00F000F0;
start = get_timer(0);
- if ((s_last - s_first) == (CONFIG_SYS_SST_SECT - 1)) {
+ if ((s_last - s_first) == (CFG_SYS_SST_SECT - 1)) {
if (prot == 0) {
addr = (FPWV *) info->start[0];
enable_interrupts();
return 0;
- } else if (prot == CONFIG_SYS_SST_SECT) {
+ } else if (prot == CFG_SYS_SST_SECT) {
return 1;
}
}
flag = disable_interrupts();
- base = (FPWV *) (CONFIG_SYS_FLASH_BASE); /* First sector */
+ base = (FPWV *) (CFG_SYS_FLASH_BASE); /* First sector */
base[FLASH_CYCLE1] = 0x00AA; /* unlock */
base[FLASH_CYCLE2] = 0x0055; /* unlock */
return (2);
}
- base = (FPWV *) (CONFIG_SYS_FLASH_BASE);
+ base = (FPWV *) (CFG_SYS_FLASH_BASE);
/* Disable interrupts which might cause a timeout here */
flag = disable_interrupts();