bcm: move fiq saved pc adjust into lexception.s so it can be shared with arm64
This commit is contained in:
parent
3ca395a36c
commit
eb4bd4aa3e
3 changed files with 3 additions and 3 deletions
|
@ -83,6 +83,7 @@ irq(Ureg* ureg)
|
||||||
Vctl *v;
|
Vctl *v;
|
||||||
int clockintr;
|
int clockintr;
|
||||||
|
|
||||||
|
m->intr++;
|
||||||
clockintr = 0;
|
clockintr = 0;
|
||||||
for(v = vctl[m->machno]; v != nil; v = v->next)
|
for(v = vctl[m->machno]; v != nil; v = v->next)
|
||||||
if((*v->reg & v->mask) != 0){
|
if((*v->reg & v->mask) != 0){
|
||||||
|
@ -103,11 +104,10 @@ fiq(Ureg *ureg)
|
||||||
{
|
{
|
||||||
Vctl *v;
|
Vctl *v;
|
||||||
|
|
||||||
|
m->intr++;
|
||||||
v = vfiq;
|
v = vfiq;
|
||||||
if(v == nil)
|
if(v == nil)
|
||||||
panic("cpu%d: unexpected item in bagging area", m->machno);
|
panic("cpu%d: unexpected item in bagging area", m->machno);
|
||||||
m->intr++;
|
|
||||||
ureg->pc -= 4;
|
|
||||||
coherence();
|
coherence();
|
||||||
v->f(ureg, v->a);
|
v->f(ureg, v->a);
|
||||||
coherence();
|
coherence();
|
||||||
|
|
|
@ -187,6 +187,7 @@ TEXT _vfiq(SB), 1, $-4 /* FIQ */
|
||||||
MOVW $PsrMfiq, R8 /* trap type */
|
MOVW $PsrMfiq, R8 /* trap type */
|
||||||
MOVW SPSR, R9 /* interrupted psr */
|
MOVW SPSR, R9 /* interrupted psr */
|
||||||
MOVW R14, R10 /* interrupted pc */
|
MOVW R14, R10 /* interrupted pc */
|
||||||
|
SUB $4, R10 /* ureg->pc -= 4 */
|
||||||
MOVM.DB.W [R8-R10], (R13) /* save in ureg */
|
MOVM.DB.W [R8-R10], (R13) /* save in ureg */
|
||||||
MOVM.DB.S [R0-R14], (R13) /* save interrupted regs */
|
MOVM.DB.S [R0-R14], (R13) /* save interrupted regs */
|
||||||
SUB $(15*4), R13
|
SUB $(15*4), R13
|
||||||
|
|
|
@ -188,7 +188,6 @@ trap(Ureg *ureg)
|
||||||
break;
|
break;
|
||||||
case PsrMirq:
|
case PsrMirq:
|
||||||
clockintr = irq(ureg);
|
clockintr = irq(ureg);
|
||||||
m->intr++;
|
|
||||||
break;
|
break;
|
||||||
case PsrMabt: /* prefetch fault */
|
case PsrMabt: /* prefetch fault */
|
||||||
x = ifsrget();
|
x = ifsrget();
|
||||||
|
|
Loading…
Reference in a new issue