Reply by Nico Admin March 1, 20082008-03-01
Hi Jon

Do you have an interrupt handler for a spurious interrupt?
As far as I can remember the ARM core fall through the interrupt handlers
if one is not defined for it and then executes the next handler --> Data
Prefetch Abort - or if you don't have that one then the next one and so
forth.....

Good Luck
Nico
Reply by Wilco Dijkstra March 1, 20082008-03-01
"Jon" <a@b.com> wrote in message news:mjhis3hgg7mh8mslfm3ccashmmcoet59f3@4ax.com...
> Hi, > > I am using: > - NXP LPC2103FBD48 with ARM7 core. > - Rowley Associates CrossStudio for ARM v1.7 Build 4. > - C++. > - Compiling with no optimizations. > > I have a mysterious bug that is causing, once in a while, a prefetch > abort exception or a data abort exception. I suspect it is either the > chip or the CrossStudio's fault, because commenting out one single > line of source code that says "config_ok=true;" seems to "solve" the > problem. However, I need that line, and I hate mysterious problems > like this one. Anyway, those exceptions (according to the datasheet) > are thrown when the ARM7 core either tries to execute an instruction > fetched from "reserved space" or from "AHB/APB space" in the memory > map or tries to access data from "reserved space" in the memory map. > > The LPC2103 does not have trace. Is there a way to know the address of > the instruction that tried the illegal fetch or data access? Doesn't > the VIC hold such information? That small piece of information would > be very valuable.
If you'd read the ARM documentation you'd know that R14_abt contains the address of the instruction that caused the exception (+4 bytes for prefetch abort and +8 for data abort). So save the registers in your abort handlers or set a breakpoint in your debugger. Wilco
Reply by Jon March 1, 20082008-03-01
Hi,

I am using:
- NXP LPC2103FBD48 with ARM7 core.
- Rowley Associates CrossStudio for ARM v1.7 Build 4.
- C++.
- Compiling with no optimizations.

I have a mysterious bug that is causing, once in a while, a prefetch
abort exception or a data abort exception. I suspect it is either the
chip or the CrossStudio's fault, because commenting out one single
line of source code that says "config_ok=true;" seems to "solve" the
problem. However, I need that line, and I hate mysterious problems
like this one. Anyway, those exceptions (according to the datasheet)
are thrown when the ARM7 core either tries to execute an instruction
fetched from "reserved space" or from "AHB/APB space" in the memory
map or tries to access data from "reserved space" in the memory map.

The LPC2103 does not have trace. Is there a way to know the address of
the instruction that tried the illegal fetch or data access? Doesn't
the VIC hold such information? That small piece of information would
be very valuable.

Thank you very much,
Jon