Moved splhigh()/spl0() calls from isa_configure() to configure() so that
there is a natural place to initialize `safepri' in a future commit. Spinoffs: - spl0() gets called in the unlikely event that isa is not configured. - configure() has better control over enabling interrupts. - it is now less unclear that interrupts aren't actually enabled early. Rev.1.48 of autoconf.c seems to have done the opposite of what was intended - moving the isa_configure() call delayed the spl0() side effect. Added some comments about the bogons. Removed the splhigh() call since it is a no-op.
This commit is contained in:
parent
60fadeeab4
commit
63e63c0d00
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91
|
||||
* $Id: autoconf.c,v 1.79 1997/11/20 17:07:21 bde Exp $
|
||||
* $Id: autoconf.c,v 1.80 1997/11/21 05:44:07 peter Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -200,6 +200,12 @@ configure(dummy)
|
||||
* XXX behavior to no longer rely on interrupts or to register an
|
||||
* XXX interrupt_driven_config_hook for the task.
|
||||
*/
|
||||
/*
|
||||
* XXX The above is wrong, because we're implicitly at splhigh(),
|
||||
* XXX and should stay there, so enabling interrupts in the CPU
|
||||
* XXX and the ICU at most gives pending interrupts which just get
|
||||
* XXX in the way.
|
||||
*/
|
||||
#ifdef APIC_IO
|
||||
bsp_apic_configure();
|
||||
enable_intr();
|
||||
@ -224,6 +230,12 @@ configure(dummy)
|
||||
isa_configure();
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Now we're ready to handle (pending) interrupts.
|
||||
* XXX this is slightly misplaced.
|
||||
*/
|
||||
spl0();
|
||||
|
||||
#if NCARD > 0
|
||||
/* After everyone else has a chance at grabbing resources */
|
||||
pccard_configure();
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: isa.c,v 1.105 1997/09/21 21:41:18 gibbs Exp $
|
||||
* $Id: isa.c,v 1.106 1997/10/12 08:31:41 jkh Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -351,7 +351,6 @@ void
|
||||
isa_configure() {
|
||||
struct isa_device *dvp;
|
||||
|
||||
splhigh();
|
||||
printf("Probing for devices on the ISA bus:\n");
|
||||
/* First probe all the sensitive probes */
|
||||
for (dvp = isa_devtab_tty; dvp->id_driver; dvp++)
|
||||
@ -431,7 +430,6 @@ isa_configure() {
|
||||
register_imask(dvp, cam_imask);
|
||||
for (dvp = isa_devtab_null; dvp->id_driver; dvp++)
|
||||
register_imask(dvp, SWI_CLOCK_MASK);
|
||||
spl0();
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)autoconf.c 7.1 (Berkeley) 5/9/91
|
||||
* $Id: autoconf.c,v 1.79 1997/11/20 17:07:21 bde Exp $
|
||||
* $Id: autoconf.c,v 1.80 1997/11/21 05:44:07 peter Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -200,6 +200,12 @@ configure(dummy)
|
||||
* XXX behavior to no longer rely on interrupts or to register an
|
||||
* XXX interrupt_driven_config_hook for the task.
|
||||
*/
|
||||
/*
|
||||
* XXX The above is wrong, because we're implicitly at splhigh(),
|
||||
* XXX and should stay there, so enabling interrupts in the CPU
|
||||
* XXX and the ICU at most gives pending interrupts which just get
|
||||
* XXX in the way.
|
||||
*/
|
||||
#ifdef APIC_IO
|
||||
bsp_apic_configure();
|
||||
enable_intr();
|
||||
@ -224,6 +230,12 @@ configure(dummy)
|
||||
isa_configure();
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Now we're ready to handle (pending) interrupts.
|
||||
* XXX this is slightly misplaced.
|
||||
*/
|
||||
spl0();
|
||||
|
||||
#if NCARD > 0
|
||||
/* After everyone else has a chance at grabbing resources */
|
||||
pccard_configure();
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: isa.c,v 1.105 1997/09/21 21:41:18 gibbs Exp $
|
||||
* $Id: isa.c,v 1.106 1997/10/12 08:31:41 jkh Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -351,7 +351,6 @@ void
|
||||
isa_configure() {
|
||||
struct isa_device *dvp;
|
||||
|
||||
splhigh();
|
||||
printf("Probing for devices on the ISA bus:\n");
|
||||
/* First probe all the sensitive probes */
|
||||
for (dvp = isa_devtab_tty; dvp->id_driver; dvp++)
|
||||
@ -431,7 +430,6 @@ isa_configure() {
|
||||
register_imask(dvp, cam_imask);
|
||||
for (dvp = isa_devtab_null; dvp->id_driver; dvp++)
|
||||
register_imask(dvp, SWI_CLOCK_MASK);
|
||||
spl0();
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user