Print a message if bootverbose that the emulator is present in the kernel.
Move the initialization before isa_configure() and npx, in case npx does something to initialize the state of the emulator somehow. I do not have any machines without a FPU so that I can test this with - except an old 386sx motherboard in a box somewhere that might work...
This commit is contained in:
parent
18251d7146
commit
9131566cff
@ -6,7 +6,7 @@
|
||||
* [expediant "port" of linux 8087 emulator to 386BSD, with apologies -wfj]
|
||||
*
|
||||
* from: 386BSD 0.1
|
||||
* $Id: math_emulate.c,v 1.27 1998/07/15 09:01:18 bde Exp $
|
||||
* $Id: math_emulate.c,v 1.28 1998/10/16 03:54:59 peter Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -1576,10 +1576,13 @@ fpu_modevent(module_t mod, modeventtype_t type, void *unused)
|
||||
{
|
||||
switch (type) {
|
||||
case MOD_LOAD:
|
||||
if (pmath_emulate)
|
||||
if (pmath_emulate) {
|
||||
printf("Another Math emulator already present\n");
|
||||
else
|
||||
pmath_emulate = math_emulate;
|
||||
return EBUSY;
|
||||
}
|
||||
pmath_emulate = math_emulate;
|
||||
if (bootverbose)
|
||||
printf("Math emulator present\n");
|
||||
break;
|
||||
case MOD_UNLOAD:
|
||||
if (pmath_emulate != math_emulate) {
|
||||
@ -1587,6 +1590,9 @@ fpu_modevent(module_t mod, modeventtype_t type, void *unused)
|
||||
return EACCES;
|
||||
}
|
||||
pmath_emulate = 0;
|
||||
if (bootverbose)
|
||||
printf("Math emulator unloaded\n");
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
@ -1597,6 +1603,6 @@ moduledata_t fpumod = {
|
||||
fpu_modevent,
|
||||
0
|
||||
};
|
||||
DECLARE_MODULE(fpu, fpumod, SI_SUB_PSEUDO, SI_ORDER_ANY);
|
||||
DECLARE_MODULE(fpu, fpumod, SI_SUB_DRIVERS, SI_ORDER_ANY);
|
||||
|
||||
#endif /* LKM */
|
||||
|
Loading…
Reference in New Issue
Block a user