diff --git a/sys/i386/apm/apm.c b/sys/i386/apm/apm.c index 9d039b1b14b6..5a823205505f 100644 --- a/sys/i386/apm/apm.c +++ b/sys/i386/apm/apm.c @@ -13,7 +13,7 @@ * * Sep, 1994 Implemented on FreeBSD 1.1.5.1R (Toshiba AVS001WD) * - * $Id: apm.c,v 1.24 1996/03/11 06:48:48 nate Exp $ + * $Id: apm.c,v 1.25 1996/03/12 06:09:34 nate Exp $ */ #include "apm.h" @@ -62,12 +62,6 @@ struct apm_softc { static struct apm_softc apm_softc[NAPM]; static struct apm_softc *master_softc = NULL; /* XXX */ static struct apmhook *hook[NAPM_HOOK]; /* XXX */ -#ifdef APM_SLOWSTART -int apm_slowstart = 0; -int apm_ss_cnt = 0; -static int apm_slowstart_p = 0; -int apm_slowstart_stat = 0; -#endif /* APM_SLOWSTART */ #define is_enabled(foo) ((foo) ? "enabled" : "disabled") @@ -471,7 +465,6 @@ apm_get_info(struct apm_softc *sc, apm_info_t aip) } -#ifdef APM_SLOWSTART /* inform APM BIOS that CPU is idle */ void apm_cpu_idle(void) @@ -493,19 +486,11 @@ apm_cpu_idle(void) * "hlt" operation from swtch() and managed it under * APM driver. */ - /* - * UKAI Note: on NetBSD, idle() called from cpu_switch() - * doesn't halt CPU, so halt_cpu may not need on NetBSD/i386 - * or only "sti" operation would be needed. - */ - if (!sc->active || sc->halt_cpu) { __asm("sti ; hlt"); /* wait for interrupt */ } } -#endif /* APM_SLOWSTART */ -#if APM_SLOWSTART > 0 /* inform APM BIOS that CPU is busy */ void apm_cpu_busy(void) @@ -516,7 +501,6 @@ apm_cpu_busy(void) __asm("movw $0x5306, %ax; lcall _apm_addr"); } } -#endif /* APM_SLOWSTART > 0 */ /* @@ -567,9 +551,6 @@ apm_halt_cpu(struct apm_softc *sc) if (sc->initialized) { sc->halt_cpu = 1; } -#ifdef APM_SLOWSTART - apm_slowstart = 0; -#endif /* APM_SLOWSTART */ } /* don't halt CPU in scheduling loop */ @@ -579,9 +560,6 @@ apm_not_halt_cpu(struct apm_softc *sc) if (sc->initialized) { sc->halt_cpu = 0; } -#ifdef APM_SLOWSTART - apm_slowstart = apm_slowstart_p; -#endif /* APM_SLOWSTART */ } /* device driver definitions */ @@ -734,12 +712,6 @@ apmattach(struct isa_device *dvp) sc->disabled = ((apm_flags & APM_DISABLED) != 0); sc->disengaged = ((apm_flags & APM_DISENGAGED) != 0); -#ifdef APM_SLOWSTART - if (sc->idle_cpu) { - apm_slowstart = apm_slowstart_p = 1; - } -#endif - /* print bootstrap messages */ #ifdef APM_DEBUG printf(" found APM BIOS version %04x\n", apm_version); diff --git a/sys/i386/bios/apm.c b/sys/i386/bios/apm.c index 9d039b1b14b6..5a823205505f 100644 --- a/sys/i386/bios/apm.c +++ b/sys/i386/bios/apm.c @@ -13,7 +13,7 @@ * * Sep, 1994 Implemented on FreeBSD 1.1.5.1R (Toshiba AVS001WD) * - * $Id: apm.c,v 1.24 1996/03/11 06:48:48 nate Exp $ + * $Id: apm.c,v 1.25 1996/03/12 06:09:34 nate Exp $ */ #include "apm.h" @@ -62,12 +62,6 @@ struct apm_softc { static struct apm_softc apm_softc[NAPM]; static struct apm_softc *master_softc = NULL; /* XXX */ static struct apmhook *hook[NAPM_HOOK]; /* XXX */ -#ifdef APM_SLOWSTART -int apm_slowstart = 0; -int apm_ss_cnt = 0; -static int apm_slowstart_p = 0; -int apm_slowstart_stat = 0; -#endif /* APM_SLOWSTART */ #define is_enabled(foo) ((foo) ? "enabled" : "disabled") @@ -471,7 +465,6 @@ apm_get_info(struct apm_softc *sc, apm_info_t aip) } -#ifdef APM_SLOWSTART /* inform APM BIOS that CPU is idle */ void apm_cpu_idle(void) @@ -493,19 +486,11 @@ apm_cpu_idle(void) * "hlt" operation from swtch() and managed it under * APM driver. */ - /* - * UKAI Note: on NetBSD, idle() called from cpu_switch() - * doesn't halt CPU, so halt_cpu may not need on NetBSD/i386 - * or only "sti" operation would be needed. - */ - if (!sc->active || sc->halt_cpu) { __asm("sti ; hlt"); /* wait for interrupt */ } } -#endif /* APM_SLOWSTART */ -#if APM_SLOWSTART > 0 /* inform APM BIOS that CPU is busy */ void apm_cpu_busy(void) @@ -516,7 +501,6 @@ apm_cpu_busy(void) __asm("movw $0x5306, %ax; lcall _apm_addr"); } } -#endif /* APM_SLOWSTART > 0 */ /* @@ -567,9 +551,6 @@ apm_halt_cpu(struct apm_softc *sc) if (sc->initialized) { sc->halt_cpu = 1; } -#ifdef APM_SLOWSTART - apm_slowstart = 0; -#endif /* APM_SLOWSTART */ } /* don't halt CPU in scheduling loop */ @@ -579,9 +560,6 @@ apm_not_halt_cpu(struct apm_softc *sc) if (sc->initialized) { sc->halt_cpu = 0; } -#ifdef APM_SLOWSTART - apm_slowstart = apm_slowstart_p; -#endif /* APM_SLOWSTART */ } /* device driver definitions */ @@ -734,12 +712,6 @@ apmattach(struct isa_device *dvp) sc->disabled = ((apm_flags & APM_DISABLED) != 0); sc->disengaged = ((apm_flags & APM_DISENGAGED) != 0); -#ifdef APM_SLOWSTART - if (sc->idle_cpu) { - apm_slowstart = apm_slowstart_p = 1; - } -#endif - /* print bootstrap messages */ #ifdef APM_DEBUG printf(" found APM BIOS version %04x\n", apm_version);