pending = bus_space_read_4(sc->sc_iot, sc->sc_ioh,
PLIC_CLAIM(sc, cpu));
- if(pending >= sc->sc_ndev) {
+ if (pending >= sc->sc_ndev) {
printf("plic0: pending %x\n", pending);
return 0;
}
*/
parent_node = OF_parent(intc);
CPU_INFO_FOREACH(cii, ci) {
- if(ci->ci_node == parent_node)
+ if (ci->ci_node == parent_node)
return ci->ci_cpuid;
}
return -1;
* is for IPI. They should NEVER be passed to plic.
* So we calculate plic priority in the following way:
*/
- if(pri <= 4 || pri >= 12)//invalid input
+ if (pri <= 4 || pri >= 12)//invalid input
prival = 0;//effectively disable this intr source
else
prival = pri - 4;
struct plic_softc *sc = plic;
uint32_t val, mask;
- if(irq == 0)
+ if (irq == 0)
return;
KASSERT(cpu < MAXCPUS);
-/* $OpenBSD: ieee.h,v 1.1 2021/04/23 02:42:16 drahn Exp $ */
+/* $OpenBSD: ieee.h,v 1.2 2021/05/11 14:58:25 deraadt Exp $ */
/* $NetBSD: ieee.h,v 1.1 1996/09/30 16:34:25 ws Exp $ */
/*
(a)[1] = (uint32_t)(p)->ext_fraclm; \
(a)[2] = (uint32_t)(p)->ext_frachm; \
(a)[3] = (uint32_t)(p)->ext_frach; \
-} while(0)
+} while (0)
struct ieee_single {
u_int sng_frac:23;
}
exception = (frame->tf_scause & EXCP_MASK);
- switch(exception) {
+ switch (exception) {
case EXCP_FAULT_LOAD:
case EXCP_FAULT_STORE:
case EXCP_FAULT_FETCH:
curcpu()->ci_curproc, frame->tf_sepc, frame->tf_ra, frame);
#endif
- switch(exception) {
+ switch (exception) {
case EXCP_FAULT_LOAD:
case EXCP_FAULT_STORE:
case EXCP_FAULT_FETCH: