diff options
Diffstat (limited to 'board')
-rw-r--r-- | board/cobra5272/flash.c | 8 | ||||
-rw-r--r-- | board/freescale/m5253demo/flash.c | 10 |
2 files changed, 10 insertions, 8 deletions
diff --git a/board/cobra5272/flash.c b/board/cobra5272/flash.c index 4337f4879d..5d15ed4e69 100644 --- a/board/cobra5272/flash.c +++ b/board/cobra5272/flash.c @@ -200,8 +200,8 @@ int flash_erase(flash_info_t *info, int s_first, int s_last) do { result = *addr; - /* check timeout */ - if (get_timer(start) > CONFIG_SYS_FLASH_ERASE_TOUT) { + /* check timeout, 1000ms */ + if (get_timer(start) > 1000) { MEM_FLASH_ADDR1 = CMD_READ_ARRAY; chip1 = TMO; break; @@ -289,8 +289,8 @@ static int write_word(flash_info_t *info, ulong dest, ulong data) do { result = *addr; - /* check timeout */ - if (get_timer(start) > CONFIG_SYS_FLASH_ERASE_TOUT) { + /* check timeout, 1000ms */ + if (get_timer(start) > 1000) { chip1 = ERR | TMO; break; } diff --git a/board/freescale/m5253demo/flash.c b/board/freescale/m5253demo/flash.c index 3197421781..bff1ac5fb1 100644 --- a/board/freescale/m5253demo/flash.c +++ b/board/freescale/m5253demo/flash.c @@ -242,7 +242,8 @@ int flash_erase(flash_info_t * info, int s_first, int s_last) count = 0; } - if (get_timer(start) > CONFIG_SYS_FLASH_ERASE_TOUT) { + /* check timeout, 1000ms */ + if (get_timer(start) > 1000) { printf("Timeout\n"); *addr = 0x00F0; /* reset to read mode */ @@ -294,8 +295,8 @@ int flash_erase(flash_info_t * info, int s_first, int s_last) enable_interrupts(); while ((*addr & 0x0080) != 0x0080) { - if (get_timer(start) > - CONFIG_SYS_FLASH_ERASE_TOUT) { + /* check timeout, 1000ms */ + if (get_timer(start) > 1000) { printf("Timeout\n"); *addr = 0x00F0; /* reset to read mode */ @@ -430,7 +431,8 @@ int write_word(flash_info_t * info, FPWV * dest, u16 data) /* data polling for D7 */ while (res == 0 && (*dest & (u8) 0x00800080) != (data & (u8) 0x00800080)) { - if (get_timer(start) > CONFIG_SYS_FLASH_WRITE_TOUT) { + /* check timeout, 500ms */ + if (get_timer(start) > 500) { *dest = (u8) 0x00F000F0; /* reset bank */ res = 1; } |