#1691 closed defect (fixed)

sparc64 usiii MMU trap handler crash

Reported by: Gedare Bloom Owned by: Gedare Bloom
Priority: normal Milestone: 4.11
Component: bsps Version: 4.11
Severity: normal Keywords:
Cc: joel.sherrill@…, chrisj@… Blocked By:
Blocking:

Description

The MMU trap handler copied from the firmware attempts a branch-always (PC relative!) to a region of code that exists in the firmware but is not part of the trap table and therefore is not copied to the relative address of the branch target.

One solution I can think of at the moment is to try to copy more of the firmware. I'm not sure exactly how much needs to be copied though, and it would be best to determine this amount off-line so that the linker knows about the region of code being used. An experimentally derived value of doubling the copied space (from 32K to 64K) works on the Simics simulator. The attached patch introduces this doubling multiplier in the trap table size to accomplish the copying.

Another possible solution would be to install a replacement trap handler, perhaps with a jump to the original trap handler (which still exists) in the firmware. This would have to be done for every trap handler that branches outside of the trap table. Since the previous fix works, I did not investigate this approach.

Attachments (4)

rtems-cvs.diff (672 bytes) - added by Gedare Bloom on Aug 26, 2010 at 4:47:02 PM.
Patch to fix bug.
ChangeLog (165 bytes) - added by Gedare Bloom on Aug 26, 2010 at 4:49:47 PM.
c/src/lib/libbsp/sparc64/ChangeLog entry
rtems-cvs_v1.diff (17.1 KB) - added by Gedare Bloom on Nov 15, 2010 at 9:28:31 PM.
Better patch to fix bug.
ChangeLog_v1 (256 bytes) - added by Gedare Bloom on Nov 15, 2010 at 9:29:12 PM.
c/src/lib/libbsp/sparc64/ChangeLog entry

Download all attachments as: .zip

Change History (11)

Changed on Aug 26, 2010 at 4:47:02 PM by Gedare Bloom

Attachment: rtems-cvs.diff added

Patch to fix bug.

Changed on Aug 26, 2010 at 4:49:47 PM by Gedare Bloom

Attachment: ChangeLog added

c/src/lib/libbsp/sparc64/ChangeLog entry

comment:1 Changed on Aug 26, 2010 at 8:09:42 PM by Gedare Bloom

Resolution: fixed
Status: newclosed

comment:2 Changed on Aug 27, 2010 at 1:05:11 AM by Chris Johns

Cc: Chris Johns added

comment:3 Changed on Aug 27, 2010 at 3:04:05 PM by Gedare Bloom

Resolution: fixedworksforme

Changed on Nov 15, 2010 at 9:28:31 PM by Gedare Bloom

Attachment: rtems-cvs_v1.diff added

Better patch to fix bug.

comment:4 Changed on Nov 15, 2010 at 9:28:31 PM by Gedare Bloom

attachments.isobsolete: 01

Changed on Nov 15, 2010 at 9:29:12 PM by Gedare Bloom

Attachment: ChangeLog_v1 added

c/src/lib/libbsp/sparc64/ChangeLog entry

comment:5 Changed on Nov 15, 2010 at 9:29:12 PM by Gedare Bloom

attachments.isobsolete: 01
Owner: changed from Joel Sherrill to giddyup44@…
Resolution: worksforme
Status: closedreopened

comment:6 Changed on Nov 16, 2010 at 10:20:37 PM by Joel Sherrill

Resolution: fixed
Status: reopenedclosed, joel.sherrill@oarcorp.com

Patch committed. I did not compile. If there are issues, please reopen this PR.

Thanks.

comment:7 Changed on Nov 24, 2014 at 6:58:28 PM by Gedare Bloom

Version: HEAD4.11

Replace Version=HEAD with Version=4.11 for the tickets with Milestone >= 4.11

Note: See TracTickets for help on using tickets.