From f6a3fc818bc6a24b6c5bbcc6057f72d2b0b2e2ab Mon Sep 17 00:00:00 2001 From: Øyvind Harboe Date: Fri, 3 Sep 2010 22:49:37 +0200 Subject: warnings: fix alignment warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit These warnings are for architectures that do not support non-aligned word access. Signed-off-by: Øyvind Harboe --- src/target/arm11.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/target/arm11.c') diff --git a/src/target/arm11.c b/src/target/arm11.c index 85d45b00..9955143a 100644 --- a/src/target/arm11.c +++ b/src/target/arm11.c @@ -901,7 +901,7 @@ static int arm11_read_memory_inner(struct target *target, { uint32_t instr = !arm11_config_memrw_no_increment ? 0xecb05e01 : 0xed905e00; /** \todo TODO: buffer cast to uint32_t* causes alignment warnings */ - uint32_t *words = (uint32_t *)buffer; + uint32_t *words = (uint32_t *)(void *)buffer; /* LDC p14,c5,[R0],#4 */ /* LDC p14,c5,[R0] */ @@ -1023,7 +1023,7 @@ static int arm11_write_memory_inner(struct target *target, uint32_t instr = !no_increment ? 0xeca05e01 : 0xed805e00; /** \todo TODO: buffer cast to uint32_t* causes alignment warnings */ - uint32_t *words = (uint32_t*)buffer; + uint32_t *words = (uint32_t*)(void *)buffer; /* "burst" here just means trusting each instruction executes * fully before we run the next one: per-word roundtrips, to -- cgit v1.2.3