diff options
Diffstat (limited to 'src/flash')
-rw-r--r-- | src/flash/nor/aduc702x.c | 2 | ||||
-rw-r--r-- | src/flash/nor/aducm360.c | 2 | ||||
-rw-r--r-- | src/flash/nor/at91sam3.c | 2 | ||||
-rw-r--r-- | src/flash/nor/at91sam4.c | 2 | ||||
-rw-r--r-- | src/flash/nor/atsamv.c | 2 | ||||
-rw-r--r-- | src/flash/nor/jtagspi.c | 14 | ||||
-rw-r--r-- | src/flash/nor/lpcspifi.c | 4 | ||||
-rw-r--r-- | src/flash/nor/stmsmi.c | 4 |
8 files changed, 16 insertions, 16 deletions
diff --git a/src/flash/nor/aduc702x.c b/src/flash/nor/aduc702x.c index fa1aeb47..34cc362e 100644 --- a/src/flash/nor/aduc702x.c +++ b/src/flash/nor/aduc702x.c @@ -371,7 +371,7 @@ static int aduc702x_check_flash_completion(struct target *target, unsigned int t { uint8_t v = 4; - long long endtime = timeval_ms() + timeout_ms; + int64_t endtime = timeval_ms() + timeout_ms; while (1) { target_read_u8(target, ADUC702x_FLASH + ADUC702x_FLASH_FEESTA, &v); if ((v & 4) == 0) diff --git a/src/flash/nor/aducm360.c b/src/flash/nor/aducm360.c index 0f85254a..8681a25a 100644 --- a/src/flash/nor/aducm360.c +++ b/src/flash/nor/aducm360.c @@ -551,7 +551,7 @@ static int aducm360_check_flash_completion(struct target *target, unsigned int t { uint32_t v = 1; - long long endtime = timeval_ms() + timeout_ms; + int64_t endtime = timeval_ms() + timeout_ms; while (1) { target_read_u32(target, ADUCM360_FLASH_BASE+ADUCM360_FLASH_FEESTA, &v); if ((v & 0x00000001) == 0) diff --git a/src/flash/nor/at91sam3.c b/src/flash/nor/at91sam3.c index 69b8e3de..1536378d 100644 --- a/src/flash/nor/at91sam3.c +++ b/src/flash/nor/at91sam3.c @@ -2175,7 +2175,7 @@ static int EFC_PerformCommand(struct sam3_bank_private *pPrivate, int r; uint32_t v; - long long ms_now, ms_end; + int64_t ms_now, ms_end; /* default */ if (status) diff --git a/src/flash/nor/at91sam4.c b/src/flash/nor/at91sam4.c index 8431729e..50aa98b8 100644 --- a/src/flash/nor/at91sam4.c +++ b/src/flash/nor/at91sam4.c @@ -1053,7 +1053,7 @@ static int EFC_PerformCommand(struct sam4_bank_private *pPrivate, int r; uint32_t v; - long long ms_now, ms_end; + int64_t ms_now, ms_end; /* default */ if (status) diff --git a/src/flash/nor/atsamv.c b/src/flash/nor/atsamv.c index 0658c590..d21419d0 100644 --- a/src/flash/nor/atsamv.c +++ b/src/flash/nor/atsamv.c @@ -147,7 +147,7 @@ static int samv_efc_perform_command(struct target *target, { int r; uint32_t v; - long long ms_now, ms_end; + int64_t ms_now, ms_end; if (status) *status = 0; diff --git a/src/flash/nor/jtagspi.c b/src/flash/nor/jtagspi.c index 0ba4dc21..a995fc75 100644 --- a/src/flash/nor/jtagspi.c +++ b/src/flash/nor/jtagspi.c @@ -210,14 +210,14 @@ static void jtagspi_read_status(struct flash_bank *bank, uint32_t *status) static int jtagspi_wait(struct flash_bank *bank, int timeout_ms) { uint32_t status; - long long t0 = timeval_ms(); - long long dt; + int64_t t0 = timeval_ms(); + int64_t dt; do { dt = timeval_ms() - t0; jtagspi_read_status(bank, &status); if ((status & SPIFLASH_BSY_BIT) == 0) { - LOG_DEBUG("waited %lld ms", dt); + LOG_DEBUG("waited %" PRId64 " ms", dt); return ERROR_OK; } alive_sleep(1); @@ -244,14 +244,14 @@ static int jtagspi_bulk_erase(struct flash_bank *bank) { struct jtagspi_flash_bank *info = bank->driver_priv; int retval; - long long t0 = timeval_ms(); + int64_t t0 = timeval_ms(); retval = jtagspi_write_enable(bank); if (retval != ERROR_OK) return retval; jtagspi_cmd(bank, info->dev->chip_erase_cmd, NULL, NULL, 0); retval = jtagspi_wait(bank, bank->num_sectors*JTAGSPI_MAX_TIMEOUT); - LOG_INFO("took %lld ms", timeval_ms() - t0); + LOG_INFO("took %" PRId64 " ms", timeval_ms() - t0); return retval; } @@ -259,14 +259,14 @@ static int jtagspi_sector_erase(struct flash_bank *bank, int sector) { struct jtagspi_flash_bank *info = bank->driver_priv; int retval; - long long t0 = timeval_ms(); + int64_t t0 = timeval_ms(); retval = jtagspi_write_enable(bank); if (retval != ERROR_OK) return retval; jtagspi_cmd(bank, info->dev->erase_cmd, &bank->sectors[sector].offset, NULL, 0); retval = jtagspi_wait(bank, JTAGSPI_MAX_TIMEOUT); - LOG_INFO("sector %d took %lld ms", sector, timeval_ms() - t0); + LOG_INFO("sector %d took %" PRId64 " ms", sector, timeval_ms() - t0); return retval; } diff --git a/src/flash/nor/lpcspifi.c b/src/flash/nor/lpcspifi.c index 94a8ccf4..4eb6cc38 100644 --- a/src/flash/nor/lpcspifi.c +++ b/src/flash/nor/lpcspifi.c @@ -106,7 +106,7 @@ static int ssp_setcs(struct target *target, uint32_t io_base, unsigned int value * and the controller is idle. */ static int poll_ssp_busy(struct target *target, uint32_t ssp_base, int timeout) { - long long endtime; + int64_t endtime; uint32_t value; int retval; @@ -325,7 +325,7 @@ static int wait_till_ready(struct flash_bank *bank, int timeout) { uint32_t status; int retval; - long long endtime; + int64_t endtime; endtime = timeval_ms() + timeout; do { diff --git a/src/flash/nor/stmsmi.c b/src/flash/nor/stmsmi.c index e4d59fe3..781ea3b5 100644 --- a/src/flash/nor/stmsmi.c +++ b/src/flash/nor/stmsmi.c @@ -160,7 +160,7 @@ FLASH_BANK_COMMAND_HANDLER(stmsmi_flash_bank_command) /* timeout in ms */ static int poll_tff(struct target *target, uint32_t io_base, int timeout) { - long long endtime; + int64_t endtime; if (SMI_READ_REG(SMI_SR) & SMI_TFF) return ERROR_OK; @@ -211,7 +211,7 @@ static int wait_till_ready(struct flash_bank *bank, int timeout) { uint32_t status; int retval; - long long endtime; + int64_t endtime; endtime = timeval_ms() + timeout; do { |