diff options
author | Stefan Roese <sr@denx.de> | 2008-06-03 20:19:08 +0200 |
---|---|---|
committer | Stefan Roese <sr@denx.de> | 2008-06-03 20:19:08 +0200 |
commit | 10a3367955bc2033b288915f8f10d0e507fe2fa1 (patch) | |
tree | c3ac82364df83db5d5cb963c64b863b77a20445c /board/gen860t/flash.c | |
parent | 97f7d27c8ecf34879d6b747c10fa9a18c02a4cc0 (diff) | |
parent | 1f1554841a4c8e069d331176f0c3059fb2bb8280 (diff) | |
download | u-boot-imx-10a3367955bc2033b288915f8f10d0e507fe2fa1.zip u-boot-imx-10a3367955bc2033b288915f8f10d0e507fe2fa1.tar.gz u-boot-imx-10a3367955bc2033b288915f8f10d0e507fe2fa1.tar.bz2 |
Merge branch 'master' of /home/stefan/git/u-boot/u-boot
Diffstat (limited to 'board/gen860t/flash.c')
-rw-r--r-- | board/gen860t/flash.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/board/gen860t/flash.c b/board/gen860t/flash.c index ec32d07..13faaf3 100644 --- a/board/gen860t/flash.c +++ b/board/gen860t/flash.c @@ -156,9 +156,9 @@ flash_init (void) * Monitor protection is ON by default */ flash_protect(FLAG_PROTECT_SET, - CFG_MONITOR_BASE, - CFG_MONITOR_BASE + monitor_flash_len - 1, - &flash_info[0]); + CFG_MONITOR_BASE, + CFG_MONITOR_BASE + monitor_flash_len - 1, + &flash_info[0]); #endif #ifdef CFG_ENV_IS_IN_FLASH @@ -166,9 +166,9 @@ flash_init (void) * Environment protection ON by default */ flash_protect(FLAG_PROTECT_SET, - CFG_ENV_ADDR, - CFG_ENV_ADDR + CFG_ENV_SECT_SIZE - 1, - &flash_info[0]); + CFG_ENV_ADDR, + CFG_ENV_ADDR + CFG_ENV_SECT_SIZE - 1, + &flash_info[0]); #endif PRINTF("## Final Flash bank size: 0x%08lx\n",size_b0); @@ -190,14 +190,14 @@ flash_get_offsets (ulong base, flash_info_t *info) switch (info->flash_id & FLASH_VENDMASK) { case FLASH_MAN_INTEL: - for (i = 0; i < info->sector_count; i++) { + for (i = 0; i < info->sector_count; i++) { info->start[i] = base; base += 1024 * 128; - } - return; + } + return; default: - printf ("Don't know sector offsets for FLASH" + printf ("Don't know sector offsets for FLASH" " type 0x%lx\n", info->flash_id); return; } @@ -436,7 +436,7 @@ write_flash_buffer8(flash_info_t *info_p, vu_char *src_p, vu_char *dest_p, * We assume that the block does not cross a boundary (we'll check before * calling this function). */ - for (i = 0; i < info_p->sector_count; ++i) { + for (i = 0; i < info_p->sector_count; ++i) { if ( ((ulong)dest_p >= info_p->start[i]) && ((ulong)dest_p < (info_p->start[i] + blocksize)) ) { PRINTF("%s:%d: Dest addr 0x%p is in block %d @ 0x%.8lx\n", |