projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of ssh://git.gag.com/scm/git/fw/altos
[fw/altos]
/
src
/
lpc
/
ao_flash_lpc.c
diff --git
a/src/lpc/ao_flash_lpc.c
b/src/lpc/ao_flash_lpc.c
index cb1a060668a173ba6e1c4634c26b8ba887924065..37913091ae7f50796eaf04ae105ef07528b87766 100644
(file)
--- a/
src/lpc/ao_flash_lpc.c
+++ b/
src/lpc/ao_flash_lpc.c
@@
-76,7
+76,7
@@
static uint32_t iap_in[5], iap_out[5];
static uint32_t
ao_lpc_addr_to_sector(uint8_t *addr)
{
static uint32_t
ao_lpc_addr_to_sector(uint8_t *addr)
{
- uint32_t off =
addr - LPC_FLASH_BASE
;
+ uint32_t off =
(uint32_t) (addr - LPC_FLASH_BASE)
;
return off >> LPC_FLASH_SECTOR_SHIFT;
}
return off >> LPC_FLASH_SECTOR_SHIFT;
}
@@
-84,7
+84,7
@@
ao_lpc_addr_to_sector(uint8_t *addr)
static uint8_t
ao_lpc_addr_is_sector_aligned(uint8_t *addr)
{
static uint8_t
ao_lpc_addr_is_sector_aligned(uint8_t *addr)
{
- uint32_t off =
addr - LPC_FLASH_BASE
;
+ uint32_t off =
(uint32_t) (addr - LPC_FLASH_BASE)
;
return (off & LPC_FLASH_SECTOR_MASK) == 0;
}
return (off & LPC_FLASH_SECTOR_MASK) == 0;
}