shithub: riscv

Download patch

ref: 75d44bc306ffcbaadaa18c161bf54071304510b0
parent: de7190ba6bd21c0465e4aba2d7fe9b49f691ca97
author: cinap_lenrek <[email protected]>
date: Sun May 5 10:04:27 EDT 2019

bcm: make sure fiq is on enabled on cpu0

--- a/sys/src/9/bcm/irq.c
+++ b/sys/src/9/bcm/irq.c
@@ -106,7 +106,7 @@
 
 	m->intr++;
 	v = vfiq;
-	if(v == nil)
+	if(v == nil || m->machno)
 		panic("cpu%d: unexpected item in bagging area", m->machno);
 	coherence();
 	v->f(ureg, v->a);
@@ -149,6 +149,7 @@
 	if(irq == IRQfiq){
 		assert((ip->FIQctl & Fiqenable) == 0);
 		assert((*enable & v->mask) == 0);
+		assert(cpu == 0);
 		vfiq = v;
 		ip->FIQctl = Fiqenable | irq;
 	}else{