summaryrefslogtreecommitdiff
path: root/src/flash/mflash.c
diff options
context:
space:
mode:
authorØyvind Harboe <oyvind.harboe@zylin.com>2010-09-03 22:49:37 +0200
committerØyvind Harboe <oyvind.harboe@zylin.com>2010-09-20 13:12:35 +0200
commitf6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab (patch)
tree2b9430c70669a47b3503e00612b68238a70a3ea9 /src/flash/mflash.c
parent32ab98c9e9672d0f1d8758c7dfb478b0316c13af (diff)
downloadopenocd+libswd-f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab.tar.gz
openocd+libswd-f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab.tar.bz2
openocd+libswd-f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab.tar.xz
openocd+libswd-f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab.zip
warnings: fix alignment warnings
These warnings are for architectures that do not support non-aligned word access. Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Diffstat (limited to 'src/flash/mflash.c')
-rw-r--r--src/flash/mflash.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/flash/mflash.c b/src/flash/mflash.c
index 43721280..26b85b1f 100644
--- a/src/flash/mflash.c
+++ b/src/flash/mflash.c
@@ -1121,7 +1121,7 @@ static int mg_storage_config(void)
!= ERROR_OK)
return ret;
- mg_gen_ataid((mg_io_type_drv_info *)buff);
+ mg_gen_ataid((mg_io_type_drv_info *)(void *)buff);
if ((ret = mg_mflash_do_write_sects(buff, 0, 1, mg_vcmd_update_stgdrvinfo))
!= ERROR_OK)
@@ -1149,7 +1149,7 @@ static int mg_boot_config(void)
buff[0] = mg_op_mode_snd; /* operation mode */
buff[1] = MG_UNLOCK_OTP_AREA;
buff[2] = 4; /* boot size */
- *((uint32_t *)(buff + 4)) = 0; /* XIP size */
+ *((uint32_t *)(void *)(buff + 4)) = 0; /* XIP size */
if ((ret = mg_mflash_do_write_sects(buff, 0, 1, mg_vcmd_update_xipinfo))
!= ERROR_OK)