> - (RvH) I changed host-linux.c so that it takes the amount of
> quanta to run as an argument to ioctl(). Now it doesn't trap
> back to the user application on ever quantum.
Another point I just noticed: it doesn't even react on signals
any more, so you can't stop the user process with Ctrl-C ;-)
This is fixed by placing this check inside the loop:
// Check for pending signals
if (current->signal & ~current->blocked) {
ret = -ERESTARTSYS;
break;
}
Yet another point: the
sti();
soft_int(monitor_info.vector);
creates a race condition, as the 'int' instruction is *not*
the first instruction after the sti()! You'll need to place
an sti assembly instruction inside the soft_int code, as the
instruction immediately preceding the 'int'.
By the way, the soft_int self-modifying code is not particularly
SMP-safe (but then again, the whole module isn't ...) ;-)
Bye,
Ulrich
--
Ulrich Weigand,
IMMD 1, Universitaet Erlangen-Nuernberg,
Martensstr. 3, D-91058 Erlangen, Phone: +49 9131 85-7688