diff options
author | simokawa <simokawa@FreeBSD.org> | 1999-04-11 12:48:15 +0000 |
---|---|---|
committer | simokawa <simokawa@FreeBSD.org> | 1999-04-11 12:48:15 +0000 |
commit | bc8426204cefe3bde1c1f899fa9cab422d06de77 (patch) | |
tree | 6452a185d061839cf915fbe0dade350e8f0c15ba /sys/alpha | |
parent | d7e60ed61940ee907f63d93e180f22111ff5f2ab (diff) | |
download | FreeBSD-src-bc8426204cefe3bde1c1f899fa9cab422d06de77.zip FreeBSD-src-bc8426204cefe3bde1c1f899fa9cab422d06de77.tar.gz |
Control unaligned access handling via sysctl.
Diffstat (limited to 'sys/alpha')
-rw-r--r-- | sys/alpha/alpha/machdep.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/sys/alpha/alpha/machdep.c b/sys/alpha/alpha/machdep.c index f513a63..2e9cdb1 100644 --- a/sys/alpha/alpha/machdep.c +++ b/sys/alpha/alpha/machdep.c @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: machdep.c,v 1.34 1999/03/06 04:46:10 wollman Exp $ + * $Id: machdep.c,v 1.35 1999/04/03 22:19:50 jdp Exp $ */ /*- * Copyright (c) 1998 The NetBSD Foundation, Inc. @@ -176,10 +176,18 @@ SYSCTL_STRING(_hw, HW_MODEL, model, CTLFLAG_RD, cpu_model, 0, ""); void *ksym_start, *ksym_end; #endif -/* for cpu_sysctl() */ -int alpha_unaligned_print = 1; /* warn about unaligned accesses */ -int alpha_unaligned_fix = 1; /* fix up unaligned accesses */ -int alpha_unaligned_sigbus = 0; /* don't SIGBUS on fixed-up accesses */ +int alpha_unaligned_print; /* warn about unaligned accesses */ +int alpha_unaligned_fix; /* fix up unaligned accesses */ +int alpha_unaligned_sigbus; /* SIGBUS on fixed-up accesses */ + +SYSCTL_INT(_machdep, CPU_UNALIGNED_PRINT, unaligned_print, + CTLFLAG_RW, &alpha_unaligned_print, 1, ""); + +SYSCTL_INT(_machdep, CPU_UNALIGNED_FIX, unaligned_fix, + CTLFLAG_RW, &alpha_unaligned_fix, 1, ""); + +SYSCTL_INT(_machdep, CPU_UNALIGNED_SIGBUS, unaligned_sigbus, + CTLFLAG_RW, &alpha_unaligned_sigbus, 0, ""); static void cpu_startup __P((void *)); SYSINIT(cpu, SI_SUB_CPU, SI_ORDER_FIRST, cpu_startup, NULL) |