Nice
terryl at sail.LABS.TEK.COM
terryl at sail.LABS.TEK.COM
Wed Feb 6 06:16:19 AEST 1991
In article <2007 at necisa.ho.necisa.oz.au> boyd at necisa.ho.necisa.oz.au (Boyd Roberts) writes:
+In article <1991Jan31.180957.9167 at turnkey.tcc.com> jackv at turnkey.TCC.COM (System Administrator) writes:
+>... But it is also not correct that a context
+>switch will take as long as you suggest. What will happen is that the
+>interrupt will cause the kernel to run in trap(),
+
+Device interrupts do not go through trap(). The stack is munged, the
+interrupt routine is called, the stack un-munged and the interrupt is
+returned from. No calls to trap(). trap() handles exceptions, not
+device interrupts.
`Tis true (that device interrupts do not go through trap()), but in
almost all modern Unices I've seen, there is a check just right before
returning from the interrupt(and it goes like this, in my best Ray Davies
imitation!!! (-:):
If we were interrupted in USER mode
AND
We need to reschedule the cpu
then call trap() to reschedule the cpu....
__________________________________________________________
Terry Laskodi "There's a permanent crease
of in your right and wrong."
Tektronix Sly and the Family Stone, "Stand!"
__________________________________________________________
More information about the Comp.unix.internals
mailing list