Patch correcting ARM data abort exception frame delivery and providing more abort info.

Pavel Pisa ppisa4lists at pikron.com
Mon Dec 12 02:11:09 UTC 2005


Hello Jay and other RTEMS users,

there seems to be mismatch between void do_data_abort() function expected
context and stack data preparation in the cpu_asm.S.
In the fact, things are fundamentally broken there, because original
code stores registers r0 to r12 into space of the length SIZE_REGS.
The first is 13*4=52 bytes and available space is 48 bytes only.
Some locations in this space are overwritten by storing LR and other registers
over previously stored registers. This leads to non-informative
reporting if data abort occurs.

The patch correcting problem and adding more information to trace data aborts
can be found in our university RTEMS patches repository

http://rtime.felk.cvut.cz/repos/rtems-devel/rtems-patches/rtems-arm-more-abort-info.patch

I can try to separate fix from more info part and put these into PR database.
But I would like to discuss that there first. I think, that data abort
and undefined instruction exceptions should store linear full state of all
registers (something like pt_regs in the Linux word). This would enable
to prepare full registers report and to call GDB stub if such condition
occurs. There is other strange part in the data abort handler. There
is probably not fully functional code trying to solve misalignment
cases. It does mad things, if data abort is due real data access
error. I have disabled this part in my patch. It is more appropriate
to shut down hard real-application in the case of error than to
continue execution with incorrectly alterred processor state.

I would be very happy, if already existing ARM patches could propagate
into mainline, because this could help to lower depth of our patch-stacks
and enable more smooth application of future enhancements.

Best wishes

                Pavel Pisa
        e-mail: pisa at cmp.felk.cvut.cz
        www:    http://cmp.felk.cvut.cz/~pisa
        work:   http://www.pikron.com



More information about the users mailing list