Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/amd64/amd64 Add machdep.fpu_present, machdep.sse an...



details:   https://anonhg.NetBSD.org/src/rev/946917928a91
branches:  trunk
changeset: 756764:946917928a91
user:      joerg <joerg%NetBSD.org@localhost>
date:      Sat Jul 31 18:38:32 2010 +0000

description:
Add machdep.fpu_present, machdep.sse and machdep.sse2 sysctls for
compatibility with i386 and compat32.

diffstat:

 sys/arch/amd64/amd64/machdep.c |  19 +++++++++++++++++--
 1 files changed, 17 insertions(+), 2 deletions(-)

diffs (40 lines):

diff -r 4edef61b2325 -r 946917928a91 sys/arch/amd64/amd64/machdep.c
--- a/sys/arch/amd64/amd64/machdep.c    Sat Jul 31 17:12:53 2010 +0000
+++ b/sys/arch/amd64/amd64/machdep.c    Sat Jul 31 18:38:32 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.146 2010/07/07 01:14:52 chs Exp $        */
+/*     $NetBSD: machdep.c,v 1.147 2010/07/31 18:38:32 joerg Exp $      */
 
 /*-
  * Copyright (c) 1996, 1997, 1998, 2000, 2006, 2007, 2008
@@ -107,7 +107,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.146 2010/07/07 01:14:52 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.147 2010/07/31 18:38:32 joerg Exp $");
 
 /* #define XENDEBUG_LOW  */
 
@@ -500,6 +500,21 @@
                       sysctl_machdep_diskinfo, 0, NULL, 0,
                       CTL_MACHDEP, CPU_DISKINFO, CTL_EOL);
        sysctl_createv(clog, 0, NULL, NULL,
+                      CTLFLAG_PERMANENT | CTLFLAG_IMMEDIATE,
+                      CTLTYPE_INT, "fpu_present", NULL,
+                      NULL, 1, NULL, 0,
+                      CTL_MACHDEP, CPU_FPU_PRESENT, CTL_EOL);
+       sysctl_createv(clog, 0, NULL, NULL,
+                      CTLFLAG_PERMANENT | CTLFLAG_IMMEDIATE,
+                      CTLTYPE_INT, "sse", NULL,
+                      NULL, 1, NULL, 0,
+                      CTL_MACHDEP, CPU_SSE, CTL_EOL);
+       sysctl_createv(clog, 0, NULL, NULL,
+                      CTLFLAG_PERMANENT | CTLFLAG_IMMEDIATE,
+                      CTLTYPE_INT, "sse2", NULL,
+                      NULL, 1, NULL, 0,
+                      CTL_MACHDEP, CPU_SSE2, CTL_EOL);
+       sysctl_createv(clog, 0, NULL, NULL,
                       CTLFLAG_PERMANENT,
                       CTLTYPE_QUAD, "tsc_freq", NULL,
                       NULL, 0, &tsc_freq, 0,



Home | Main Index | Thread Index | Old Index