summaryrefslogtreecommitdiff
path: root/src/flash/nand
diff options
context:
space:
mode:
authorDaniel Bäder <openocd@eh-oh.de>2010-03-25 11:24:42 +0100
committerØyvind Harboe <oyvind.harboe@zylin.com>2010-03-25 12:45:32 +0100
commit010492a1ede305d2375602afa26f50281fea3e2f (patch)
tree523e40e6201a6ab468ef4d7d2612a4f08f4633b8 /src/flash/nand
parente736468b0e25f255db60cfd6cb2f6a2e470ba50e (diff)
downloadopenocd+libswd-010492a1ede305d2375602afa26f50281fea3e2f.tar.gz
openocd+libswd-010492a1ede305d2375602afa26f50281fea3e2f.tar.bz2
openocd+libswd-010492a1ede305d2375602afa26f50281fea3e2f.tar.xz
openocd+libswd-010492a1ede305d2375602afa26f50281fea3e2f.zip
change %x and %d to PRIx32 and PRId32 where needed for cygwin
Diffstat (limited to 'src/flash/nand')
-rw-r--r--src/flash/nand/lpc3180.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/flash/nand/lpc3180.c b/src/flash/nand/lpc3180.c
index 6562e041..40324f28 100644
--- a/src/flash/nand/lpc3180.c
+++ b/src/flash/nand/lpc3180.c
@@ -817,7 +817,7 @@ static int lpc3180_write_page(struct nand_device *nand, uint32_t page, uint8_t *
target_free_working_area(target,pworking_area);
- LOG_INFO("Page = 0x%x was written.",page);
+ LOG_INFO("Page = 0x%" PRIx32 " was written.",page);
}
else
@@ -1112,7 +1112,7 @@ static int lpc3180_read_page(struct nand_device *nand, uint32_t page, uint8_t *d
target_read_memory(target, target_mem_base+DATA_OFFS, 4, nand->page_size == 2048?512:128, page_buffer);
memcpy(data, page_buffer, data_size);
- LOG_INFO("Page = 0x%x was read.",page);
+ LOG_INFO("Page = 0x%" PRIx32 " was read.",page);
/* check hw generated ECC for each 256 bytes block with the saved ECC in flash spare area*/
int idx = nand->page_size/0x200 ;
@@ -1120,9 +1120,9 @@ static int lpc3180_read_page(struct nand_device *nand, uint32_t page, uint8_t *d
target_read_memory(target, target_mem_base+ECC_OFFS, 4, 8, ecc_hw_buffer);
for(i=0;i<idx;i++){
if( (0x00ffffff&*(uint32_t *)(ecc_hw_buffer+i*8)) != (0x00ffffff&*(uint32_t *)(ecc_flash_buffer+8+i*16)) )
- LOG_WARNING("ECC mismatch at 256 bytes size block= %d at page= 0x%x",i*2+1,page);
+ LOG_WARNING("ECC mismatch at 256 bytes size block= %d at page= 0x%" PRIx32,i*2+1,page);
if( (0x00ffffff&*(uint32_t *)(ecc_hw_buffer+4+i*8)) != (0x00ffffff&*(uint32_t *)(ecc_flash_buffer+12+i*16)) )
- LOG_WARNING("ECC mismatch at 256 bytes size block= %d at page= 0x%x",i*2+2,page);
+ LOG_WARNING("ECC mismatch at 256 bytes size block= %d at page= 0x%" PRIx32,i*2+2,page);
}
}