This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cyg_hal_gdb_interrupt


John Newlin <jnewlin@rawbw.com> writes:

> In file:
> packages/hal/common/current/src/hal_stub.c
> 
> There is this wonderful function: cyg_hal_gdb_interrupt
> 
> This function saves the current instruction, and installs a break
> instruction.  Generally this is safe, but on the Xtensa architecture
> instructions can be on any address alignment, which will cause the load of
> the old instruction and store of the new instruction to generate an
> exception.
> 
> Is there a general way to override this function, or if I made a change to
> do a memcpy instead of load/store would you accept that back into the
> tree?

The ususal approach here is for the HAL to supply a substitute
routine. The ARM HAL does this since it has to deal with 32 bit ARM
breakpoints and 16 bit Thumb breakpoints, and has to decide which to
plant at runtime.

-- 
Nick Garnett                    eCos Kernel Architect
http://www.ecoscentric.com      The eCos and RedBoot experts


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]