On Tue, 7 Dec 2010, Dave Martin wrote: > On Tue, Dec 7, 2010 at 2:53 PM, Dave Martin <dave.martin@xxxxxxxxxx> wrote: > [...] > > Note that converting to C doesn't mean that code which attempts to > > copy function bodies will work: you still need to handle the fact that > > if f() is a C function symbol, then the value of the symbol f is > > actually the function's base address + 1. See my changes in sram.c, > > To clarify, this applies *if* f is a Thumb symbol. To make it generic, a new macro could be used: #define SYM_ADDR(x) ((void *)((long)(x) & ~1L)) Nicolas