Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/x86/x86 Update from Intel SDM:
details: https://anonhg.NetBSD.org/src/rev/9f2e521a9c72
branches: trunk
changeset: 336906:9f2e521a9c72
user: msaitoh <msaitoh%NetBSD.org@localhost>
date: Fri Mar 27 05:32:38 2015 +0000
description:
Update from Intel SDM:
- Add busclock values for Airmont.
diffstat:
sys/arch/x86/x86/intel_busclock.c | 54 +++++++++++++++++++++++++++++++++++++-
1 files changed, 52 insertions(+), 2 deletions(-)
diffs (75 lines):
diff -r 0de2d5ad48ec -r 9f2e521a9c72 sys/arch/x86/x86/intel_busclock.c
--- a/sys/arch/x86/x86/intel_busclock.c Fri Mar 27 05:31:34 2015 +0000
+++ b/sys/arch/x86/x86/intel_busclock.c Fri Mar 27 05:32:38 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: intel_busclock.c,v 1.20 2014/12/17 03:39:02 msaitoh Exp $ */
+/* $NetBSD: intel_busclock.c,v 1.21 2015/03/27 05:32:38 msaitoh Exp $ */
/*-
* Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: intel_busclock.c,v 1.20 2014/12/17 03:39:02 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: intel_busclock.c,v 1.21 2015/03/27 05:32:38 msaitoh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -272,6 +272,56 @@
goto print_msr;
}
break;
+ case 0x4c: /* Airmont */
+ if (rdmsr_safe(MSR_FSB_FREQ, &msr) == EFAULT) {
+ aprint_debug_dev(ci->ci_dev,
+ "unable to determine bus speed");
+ goto print_msr;
+ }
+ bus = (msr >> 0) & 0xf;
+ switch (bus) {
+ case 0:
+ bus_clock = 8333;
+ break;
+ case 1:
+ bus_clock = 10000;
+ break;
+ case 2:
+ bus_clock = 13333;
+ break;
+ case 3:
+ bus_clock = 11650;
+ break;
+ case 4:
+ bus_clock = 8333;
+ break;
+ case 5:
+ bus_clock = 10000;
+ break;
+ case 6:
+ bus_clock = 13333;
+ break;
+ case 7:
+ bus_clock = 11666;
+ break;
+ case 12:
+ bus_clock = 8000;
+ break;
+ case 13:
+ bus_clock = 9333;
+ break;
+ case 14:
+ bus_clock = 9000;
+ break;
+ case 15:
+ bus_clock = 8888;
+ break;
+ default:
+ aprint_debug("%s: unknown Airmont FSB_FREQ value %d",
+ device_xname(ci->ci_dev), bus);
+ goto print_msr;
+ }
+ break;
default:
aprint_debug("%s: unknown i686 model %02x, can't get bus clock",
device_xname(ci->ci_dev),
Home |
Main Index |
Thread Index |
Old Index