summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/i386/i386/est.c6
-rw-r--r--sys/arch/i386/i386/p4tcc.c6
-rw-r--r--sys/arch/i386/pci/pcib.c6
3 files changed, 13 insertions, 5 deletions
diff --git a/sys/arch/i386/i386/est.c b/sys/arch/i386/i386/est.c
index 0ac6b4c7137..b543ea4f7f7 100644
--- a/sys/arch/i386/i386/est.c
+++ b/sys/arch/i386/i386/est.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: est.c,v 1.5 2004/02/14 15:09:22 grange Exp $ */
+/* $OpenBSD: est.c,v 1.6 2004/02/27 21:15:45 grange Exp $ */
/*
* Copyright (c) 2003 Michael Eriksson.
* All rights reserved.
@@ -201,6 +201,9 @@ est_init(const char *cpu_device)
const struct fqlist *fql;
extern char cpu_brandstr[];
+ if (setperf_prio > 3)
+ return;
+
if ((cpu_ecxfeature & CPUIDECX_EST) == 0)
return;
@@ -256,6 +259,7 @@ est_init(const char *cpu_device)
cpu_setperf = est_setperf;
cpu_cpuspeed = est_cpuspeed;
+ setperf_prio = 3;
}
int
diff --git a/sys/arch/i386/i386/p4tcc.c b/sys/arch/i386/i386/p4tcc.c
index de896265b05..3e0c3b41795 100644
--- a/sys/arch/i386/i386/p4tcc.c
+++ b/sys/arch/i386/i386/p4tcc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: p4tcc.c,v 1.2 2004/02/14 15:09:22 grange Exp $ */
+/* $OpenBSD: p4tcc.c,v 1.3 2004/02/27 21:15:45 grange Exp $ */
/*
* Copyright (c) 2003 Ted Unangst
* All rights reserved.
@@ -62,6 +62,8 @@ static struct {
void
p4tcc_init(int model, int step)
{
+ if (setperf_prio > 1)
+ return;
switch (step) {
case 0x22: /* errata O50 P44 and Z21 */
@@ -85,7 +87,7 @@ p4tcc_init(int model, int step)
}
cpu_setperf = p4tcc_setperf;
-
+ setperf_prio = 1;
}
#if 0
diff --git a/sys/arch/i386/pci/pcib.c b/sys/arch/i386/pci/pcib.c
index 39994a6558e..2dc4c12138f 100644
--- a/sys/arch/i386/pci/pcib.c
+++ b/sys/arch/i386/pci/pcib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pcib.c,v 1.12 2004/02/19 21:38:44 grange Exp $ */
+/* $OpenBSD: pcib.c,v 1.13 2004/02/27 21:15:45 grange Exp $ */
/* $NetBSD: pcib.c,v 1.6 1997/06/06 23:29:16 thorpej Exp $ */
/*-
@@ -125,7 +125,8 @@ pcibattach(parent, self, aux)
/*
* Detect and activate SpeedStep on ICHx-M chipsets.
*/
- if (ichss_match(aux) && ichss_attach(self, aux) == 0)
+ if (setperf_prio < 2 && ichss_match(aux) &&
+ ichss_attach(self, aux) == 0)
printf(": SpeedStep");
#endif
@@ -226,6 +227,7 @@ ichss_attach(struct device *self, void *aux)
/* Hook into hw.setperf sysctl */
ichss_cookie = sc;
cpu_setperf = ichss_setperf;
+ setperf_prio = 2;
return (0);
}