Subject: Latest ISA changes and IPL levels
To: None <current-users@NetBSD.ORG>
From: Rafal Boni <>
List: current-users
Date: 04/18/1995 18:27:00
I just rebuilt a kernel from sources supped either last night or this morning,
(depending on your definition of morning ;-)) and noticed some wierd stuff on

Mainly, the biomask, netmask and ttymask values printed by the kernel were 
quite off.  After a look at the sources, it seems that the #defines for the
old IPL levels are one-off from the new ISA_IPL_xxx values.  Hence the old
IPL_NET was 1, whereas ISA_IPL_NET should be 2 [don't have the source on
hand, so it could be the other way around, but you get the idea...].

So, I hacked up my /sys/arch/i386/include/psl.h to make the IPL_ defines
say the same thing as the ISA_IPL_ enum types.  But I thought about it and
this is definitely a bogus hack [although at the rate my off-by-one kernel
was panic'ing it was a worthwhile hack...], especially in the face of the
fact that there are at least two sets of IPL_ values (the ISA_IPL_ ones, 
the ones in arch/i386/include/psl.h, and possibly ones in other arch/ trees) 
floating around, and changing one can have quite detrimental effect if the 
other set is not updated simultaneously (try it and see... makes for lots 
of crashes!).

Am I just caught in the middle of some major movement, or did Chris really
miss this when he moved ISA stuff out of the x86 arch tree?? 

[Ideally I suppose, the MD code would do something like make imask[IPL_NET]
the sum of all the imask[xxx_IPL_NET]'s where xxx is a bus-type or something,
but I'm not sure if all the underlying machinery is there to do that... ]


+--------------------------------------------------------+ +------------------+
| In search of the stress-strain relationship governing  |/|       Rafal Boni |
| students of mechanics... Experimentally.               |\| |
+--------------------------------------------------------+ +------------------+