CVS commit: src/sys/arch/vax/include

2018-04-25 Thread Anders Magnusson
Module Name:src
Committed By:   ragge
Date:   Wed Apr 25 09:23:01 UTC 2018

Modified Files:
src/sys/arch/vax/include: asm.h

Log Message:
Add __KERNEL_RCSID() macro.


To generate a diff of this commit:
cvs rdiff -u -r1.26 -r1.27 src/sys/arch/vax/include/asm.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/asm.h
diff -u src/sys/arch/vax/include/asm.h:1.26 src/sys/arch/vax/include/asm.h:1.27
--- src/sys/arch/vax/include/asm.h:1.26	Fri Jun  1 06:26:38 2012
+++ src/sys/arch/vax/include/asm.h	Wed Apr 25 09:23:00 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: asm.h,v 1.26 2012/06/01 06:26:38 matt Exp $ */
+/*	$NetBSD: asm.h,v 1.27 2018/04/25 09:23:00 ragge Exp $ */
 /*
  * Copyright (c) 1982, 1993
  *	The Regents of the University of California.  All rights reserved.
@@ -81,6 +81,11 @@
 #define ALTENTRY(x)		.globl _C_LABEL(x); _C_LABEL(x):
 #define RCSID(name)		.pushsection ".ident"; .asciz name; .popsection
 
+#ifdef NO_KERNEL_RCSIDS
+#define __KERNEL_RCSID(_n, _s)  /* nothing */
+#else
+#define __KERNEL_RCSID(_n, _s)  RCSID(_s)
+#endif
 
 #define	WEAK_ALIAS(alias,sym)		\
 	.weak alias;			\



CVS commit: src/sys/arch/vax/include

2018-03-31 Thread Anders Magnusson
Module Name:src
Committed By:   ragge
Date:   Sat Mar 31 06:34:51 UTC 2018

Modified Files:
src/sys/arch/vax/include: vmparam.h

Log Message:
Shrink MAXDSIZ to 512MB.
XXX this should be depending of amount of physical memory.


To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.51 src/sys/arch/vax/include/vmparam.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/vmparam.h
diff -u src/sys/arch/vax/include/vmparam.h:1.50 src/sys/arch/vax/include/vmparam.h:1.51
--- src/sys/arch/vax/include/vmparam.h:1.50	Sun Jan 26 03:18:39 2014
+++ src/sys/arch/vax/include/vmparam.h	Sat Mar 31 06:34:51 2018
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.50 2014/01/26 03:18:39 christos Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.51 2018/03/31 06:34:51 ragge Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -68,7 +68,7 @@
 #define DFLDSIZ		(128*1024*1024)		/* initial data size limit */
 #endif
 #ifndef MAXDSIZ
-#define MAXDSIZ		(1024*1024*1024)	/* max data size */
+#define MAXDSIZ		(512*1024*1024)		/* max data size */
 #endif
 #ifndef DFLSSIZ
 #define DFLSSIZ		(512*1024)		/* initial stack size limit */



CVS commit: src/sys/arch/vax/include

2017-11-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Nov 29 17:54:55 UTC 2017

Modified Files:
src/sys/arch/vax/include: signal.h

Log Message:
include  for sigset_t


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/vax/include/signal.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/signal.h
diff -u src/sys/arch/vax/include/signal.h:1.15 src/sys/arch/vax/include/signal.h:1.16
--- src/sys/arch/vax/include/signal.h:1.15	Tue Jan 13 18:56:13 2009
+++ src/sys/arch/vax/include/signal.h	Wed Nov 29 12:54:55 2017
@@ -1,4 +1,4 @@
-/*  $NetBSD: signal.h,v 1.15 2009/01/13 23:56:13 mjf Exp $   */
+/*  $NetBSD: signal.h,v 1.16 2017/11/29 17:54:55 christos Exp $   */
 
 /*
  * Copyright (c) 1982, 1986, 1989, 1991 Regents of the University of California.
@@ -43,6 +43,7 @@
 typedef int sig_atomic_t;
 
 #if defined(_NETBSD_SOURCE)
+#include 
 /*
  * Information pushed on stack when a signal is delivered.
  * This is used by the kernel to restore state following



CVS commit: src/sys/arch/vax/include

2017-07-27 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Jul 27 12:15:59 UTC 2017

Modified Files:
src/sys/arch/vax/include: math.h

Log Message:
Some stupid pkgsrc stuff insists on -std=c89, duh!
Use __inline instead of inline.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/include/math.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/math.h
diff -u src/sys/arch/vax/include/math.h:1.7 src/sys/arch/vax/include/math.h:1.8
--- src/sys/arch/vax/include/math.h:1.7	Mon Sep 16 15:56:24 2013
+++ src/sys/arch/vax/include/math.h	Thu Jul 27 12:15:59 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: math.h,v 1.7 2013/09/16 15:56:24 martin Exp $	*/
+/*	$NetBSD: math.h,v 1.8 2017/07/27 12:15:59 martin Exp $	*/
 
 #ifndef _VAX_MATH_H_
 #define _VAX_MATH_H_
@@ -11,8 +11,8 @@
 #define	__INFINITY	1.0E+39F
 #endif
 
-static inline int __isinf(double __x) { return 0; }
-static inline int __isnan(double __x) { return 0; }
+static __inline int __isinf(double __x) { return 0; }
+static __inline int __isnan(double __x) { return 0; }
 #define	__HAVE_INLINE___ISINF
 #define	__HAVE_INLINE___ISNAN
 



CVS commit: src/sys/arch/vax/include

2017-05-22 Thread Anders Magnusson
Module Name:src
Committed By:   ragge
Date:   Mon May 22 17:12:11 UTC 2017

Modified Files:
src/sys/arch/vax/include: cca.h clock.h cpu.h frame.h ka410.h ka420.h
ka43.h ka46.h ka48.h ka670.h ka680.h ka730.h ka750.h ka88.h lock.h
macros.h mtpr.h pcb.h pte.h ptrace.h reg.h rpb.h rsp.h scb.h sid.h
userret.h uvax.h vsbus.h

Log Message:
Update copyright notice for Ludd (remove clause 3 & 4).


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/vax/include/cca.h \
src/sys/arch/vax/include/frame.h src/sys/arch/vax/include/ka680.h \
src/sys/arch/vax/include/rsp.h
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/vax/include/clock.h \
src/sys/arch/vax/include/ptrace.h src/sys/arch/vax/include/rpb.h
cvs rdiff -u -r1.99 -r1.100 src/sys/arch/vax/include/cpu.h
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/include/ka410.h \
src/sys/arch/vax/include/ka88.h
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/vax/include/ka420.h \
src/sys/arch/vax/include/ka46.h src/sys/arch/vax/include/ka48.h \
src/sys/arch/vax/include/ka670.h
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/include/ka43.h \
src/sys/arch/vax/include/uvax.h
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/vax/include/ka730.h
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/vax/include/ka750.h
cvs rdiff -u -r1.29 -r1.30 src/sys/arch/vax/include/lock.h
cvs rdiff -u -r1.45 -r1.46 src/sys/arch/vax/include/macros.h
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/vax/include/mtpr.h
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/vax/include/pcb.h \
src/sys/arch/vax/include/userret.h
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/vax/include/pte.h
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/vax/include/reg.h
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/vax/include/scb.h
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/vax/include/sid.h
cvs rdiff -u -r1.19 -r1.20 src/sys/arch/vax/include/vsbus.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/cca.h
diff -u src/sys/arch/vax/include/cca.h:1.2 src/sys/arch/vax/include/cca.h:1.3
--- src/sys/arch/vax/include/cca.h:1.2	Tue Mar 11 05:34:02 2008
+++ src/sys/arch/vax/include/cca.h	Mon May 22 17:12:11 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: cca.h,v 1.2 2008/03/11 05:34:02 matt Exp $	*/
+/*	$NetBSD: cca.h,v 1.3 2017/05/22 17:12:11 ragge Exp $	*/
 
 /*
  * Copyright (c) 2000 Ludd, University of Lule}, Sweden. All rights reserved.
@@ -11,12 +11,6 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *notice, this list of conditions and the following disclaimer in the
  *documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *must display the following acknowledgement:
- *  This product includes software developed at Ludd, University of
- *  Lule}, Sweden and its contributors.
- * 4. The name of the author may not be used to endorse or promote products
- *derived from this software without specific prior written permission
  *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
Index: src/sys/arch/vax/include/frame.h
diff -u src/sys/arch/vax/include/frame.h:1.2 src/sys/arch/vax/include/frame.h:1.3
--- src/sys/arch/vax/include/frame.h:1.2	Sun Jun  4 19:30:15 2000
+++ src/sys/arch/vax/include/frame.h	Mon May 22 17:12:11 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: frame.h,v 1.2 2000/06/04 19:30:15 matt Exp $ */
+/*	$NetBSD: frame.h,v 1.3 2017/05/22 17:12:11 ragge Exp $ */
 /*
  * Copyright (c) 1995 Ludd, University of Lule}, Sweden.
  * All rights reserved.
@@ -11,12 +11,6 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *notice, this list of conditions and the following disclaimer in the
  *documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *must display the following acknowledgement:
- *  This product includes software developed at Ludd, University of 
- *  Lule}, Sweden and its contributors.
- * 4. The name of the author may not be used to endorse or promote products
- *derived from this software without specific prior written permission
  *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
Index: src/sys/arch/vax/include/ka680.h
diff -u src/sys/arch/vax/include/ka680.h:1.2 src/sys/arch/vax/include/ka680.h:1.3
--- src/sys/arch/vax/include/ka680.h:1.2	Sun Dec  1 21:21:45 2002
+++ src/sys/arch/vax/include/ka680.h	Mon May 22 17:12:11 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: ka680.h,v 1.2 2002/12/01 21:21:45 matt Exp $	*/
+/*	$NetBSD: ka680.h,v 1.3 2017/05/22 17:12:11 ragge Exp $	*/
 /*
  * Copyright (c) 1998 Ludd, University of Lule}, Sweden.
  * 

CVS commit: src/sys/arch/vax/include

2017-04-11 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Tue Apr 11 07:45:37 UTC 2017

Modified Files:
src/sys/arch/vax/include: ptrace.h

Log Message:
Trailing whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/include/ptrace.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/ptrace.h
diff -u src/sys/arch/vax/include/ptrace.h:1.7 src/sys/arch/vax/include/ptrace.h:1.8
--- src/sys/arch/vax/include/ptrace.h:1.7	Sat Apr  8 00:25:49 2017
+++ src/sys/arch/vax/include/ptrace.h	Tue Apr 11 07:45:36 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: ptrace.h,v 1.7 2017/04/08 00:25:49 kamil Exp $	*/
+/*	$NetBSD: ptrace.h,v 1.8 2017/04/11 07:45:36 skrll Exp $	*/
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -31,7 +31,7 @@
  */
 
  /* All bugs are subject to removal without further notice */
-		
+
 
 #define PT_STEP (PT_FIRSTMACH + 0)
 #define PT_GETREGS  (PT_FIRSTMACH + 1)



CVS commit: src/sys/arch/vax/include

2017-01-14 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Jan 14 16:21:28 UTC 2017

Modified Files:
src/sys/arch/vax/include: byte_swap.h

Log Message:
cast return value


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/vax/include/byte_swap.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/byte_swap.h
diff -u src/sys/arch/vax/include/byte_swap.h:1.11 src/sys/arch/vax/include/byte_swap.h:1.12
--- src/sys/arch/vax/include/byte_swap.h:1.11	Fri Feb 17 03:41:31 2006
+++ src/sys/arch/vax/include/byte_swap.h	Sat Jan 14 11:21:28 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: byte_swap.h,v 1.11 2006/02/17 08:41:31 skrll Exp $	*/
+/*	$NetBSD: byte_swap.h,v 1.12 2017/01/14 16:21:28 christos Exp $	*/
 
 /*
  * Copyright (c) 1987, 1991 Regents of the University of California.
@@ -61,7 +61,7 @@ static __inline uint16_t __attribute__((
 __byte_swap_u16_variable(uint16_t x)
 {
 
-	return (x << 8 | x >> 8);
+	return (uint16_t)(x << 8 | x >> 8);
 }
 
 __END_DECLS



CVS commit: src/sys/arch/vax/include

2014-12-20 Thread John Klos
Module Name:src
Committed By:   jklos
Date:   Sat Dec 20 13:13:58 UTC 2014

Added Files:
src/sys/arch/vax/include: autoconf.h

Log Message:
Added as a placeholder so kernels compile until a better fix is found.


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/vax/include/autoconf.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Added files:




CVS commit: src/sys/arch/vax/include

2014-08-21 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Thu Aug 21 06:48:04 UTC 2014

Modified Files:
src/sys/arch/vax/include: int_fmtio.h

Log Message:
Revert back to 1.7.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/vax/include/int_fmtio.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/int_fmtio.h
diff -u src/sys/arch/vax/include/int_fmtio.h:1.8 src/sys/arch/vax/include/int_fmtio.h:1.9
--- src/sys/arch/vax/include/int_fmtio.h:1.8	Thu Aug 14 14:21:03 2014
+++ src/sys/arch/vax/include/int_fmtio.h	Thu Aug 21 06:48:04 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: int_fmtio.h,v 1.8 2014/08/14 14:21:03 matt Exp $	*/
+/*	$NetBSD: int_fmtio.h,v 1.9 2014/08/21 06:48:04 matt Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -143,8 +143,8 @@
 #define	SCNdLEAST16	hd	/* int_least16_t	*/
 #define	SCNdLEAST32	d	/* int_least32_t	*/
 #define	SCNdLEAST64	lld	/* int_least64_t	*/
-#define	SCNdFAST8	d	/* int_fast8_t		*/
-#define	SCNdFAST16	d	/* int_fast16_t		*/
+#define	SCNdFAST8	hhd	/* int_fast8_t		*/
+#define	SCNdFAST16	hd	/* int_fast16_t		*/
 #define	SCNdFAST32	d	/* int_fast32_t		*/
 #define	SCNdFAST64	lld	/* int_fast64_t		*/
 #define	SCNdMAX		lld	/* intmax_t		*/
@@ -158,8 +158,8 @@
 #define	SCNiLEAST16	hi	/* int_least16_t	*/
 #define	SCNiLEAST32	i	/* int_least32_t	*/
 #define	SCNiLEAST64	lli	/* int_least64_t	*/
-#define	SCNiFAST8	i	/* int_fast8_t		*/
-#define	SCNiFAST16	i	/* int_fast16_t		*/
+#define	SCNiFAST8	hhi	/* int_fast8_t		*/
+#define	SCNiFAST16	hi	/* int_fast16_t		*/
 #define	SCNiFAST32	i	/* int_fast32_t		*/
 #define	SCNiFAST64	lli	/* int_fast64_t		*/
 #define	SCNiMAX		lli	/* intmax_t		*/
@@ -175,8 +175,8 @@
 #define	SCNoLEAST16	ho	/* uint_least16_t	*/
 #define	SCNoLEAST32	o	/* uint_least32_t	*/
 #define	SCNoLEAST64	llo	/* uint_least64_t	*/
-#define	SCNoFAST8	o	/* uint_fast8_t		*/
-#define	SCNoFAST16	o	/* uint_fast16_t	*/
+#define	SCNoFAST8	hho	/* uint_fast8_t		*/
+#define	SCNoFAST16	ho	/* uint_fast16_t	*/
 #define	SCNoFAST32	o	/* uint_fast32_t	*/
 #define	SCNoFAST64	llo	/* uint_fast64_t	*/
 #define	SCNoMAX		llo	/* uintmax_t		*/
@@ -190,8 +190,8 @@
 #define	SCNuLEAST16	hu	/* uint_least16_t	*/
 #define	SCNuLEAST32	u	/* uint_least32_t	*/
 #define	SCNuLEAST64	llu	/* uint_least64_t	*/
-#define	SCNuFAST8	u	/* uint_fast8_t		*/
-#define	SCNuFAST16	u	/* uint_fast16_t	*/
+#define	SCNuFAST8	hhu	/* uint_fast8_t		*/
+#define	SCNuFAST16	hu	/* uint_fast16_t	*/
 #define	SCNuFAST32	u	/* uint_fast32_t	*/
 #define	SCNuFAST64	llu	/* uint_fast64_t	*/
 #define	SCNuMAX		llu	/* uintmax_t		*/
@@ -205,8 +205,8 @@
 #define	SCNxLEAST16	hx	/* uint_least16_t	*/
 #define	SCNxLEAST32	x	/* uint_least32_t	*/
 #define	SCNxLEAST64	llx	/* uint_least64_t	*/
-#define	SCNxFAST8	x	/* uint_fast8_t		*/
-#define	SCNxFAST16	x	/* uint_fast16_t	*/
+#define	SCNxFAST8	hhx	/* uint_fast8_t		*/
+#define	SCNxFAST16	hx	/* uint_fast16_t	*/
 #define	SCNxFAST32	x	/* uint_fast32_t	*/
 #define	SCNxFAST64	llx	/* uint_fast64_t	*/
 #define	SCNxMAX		llx	/* uintmax_t		*/



CVS commit: src/sys/arch/vax/include

2014-08-14 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 14 09:02:18 UTC 2014

Modified Files:
src/sys/arch/vax/include: mutex.h

Log Message:
Previously we used unsigned long int as __uintptr_t, but gcc prefers
__UINTPTR_TYPE__ as unsigned int, and now we use that for __uintptr_t
as well, so adapt MUTEX_CAS() accordingly.


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/vax/include/mutex.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/mutex.h
diff -u src/sys/arch/vax/include/mutex.h:1.12 src/sys/arch/vax/include/mutex.h:1.13
--- src/sys/arch/vax/include/mutex.h:1.12	Mon Apr 28 20:23:39 2008
+++ src/sys/arch/vax/include/mutex.h	Thu Aug 14 09:02:18 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: mutex.h,v 1.12 2008/04/28 20:23:39 martin Exp $	*/
+/*	$NetBSD: mutex.h,v 1.13 2014/08/14 09:02:18 martin Exp $	*/
 
 /*-
  * Copyright (c) 2002, 2007 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@ struct kmutex {
  */
 #define	MUTEX_GIVE(mtx)		/* nothing */
 
-#define	MUTEX_CAS(p, o, n)	(atomic_cas_ulong((p), (o), (n)) == (o))
+#define	MUTEX_CAS(p, o, n)	(atomic_cas_uint((p), (o), (n)) == (o))
 
 #endif	/* __MUTEX_PRIVATE */
 



CVS commit: src/sys/arch/vax/include

2014-08-14 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 14 09:17:32 UTC 2014

Modified Files:
src/sys/arch/vax/include: int_fmtio.h

Log Message:
intptr_t and uintptr_t are not long any more.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/include/int_fmtio.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/int_fmtio.h
diff -u src/sys/arch/vax/include/int_fmtio.h:1.5 src/sys/arch/vax/include/int_fmtio.h:1.6
--- src/sys/arch/vax/include/int_fmtio.h:1.5	Wed Aug 13 19:48:17 2014
+++ src/sys/arch/vax/include/int_fmtio.h	Thu Aug 14 09:17:32 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: int_fmtio.h,v 1.5 2014/08/13 19:48:17 matt Exp $	*/
+/*	$NetBSD: int_fmtio.h,v 1.6 2014/08/14 09:17:32 martin Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -69,7 +69,7 @@
 #define	PRIiFAST32	i	/* int_fast32_t		*/
 #define	PRIiFAST64	lli	/* int_fast64_t		*/
 #define	PRIiMAX		lli	/* intmax_t		*/
-#define	PRIiPTR		li	/* intptr_t		*/
+#define	PRIiPTR		i	/* intptr_t		*/
 
 /* fprintf macros for unsigned integers */
 
@@ -101,7 +101,7 @@
 #define	PRIuFAST32	u	/* uint_fast32_t	*/
 #define	PRIuFAST64	llu	/* uint_fast64_t	*/
 #define	PRIuMAX		llu	/* uintmax_t		*/
-#define	PRIuPTR		lu	/* uintptr_t		*/
+#define	PRIuPTR		u	/* uintptr_t		*/
 
 #define	PRIx8		x	/* uint8_t		*/
 #define	PRIx16		x	/* uint16_t		*/



CVS commit: src/sys/arch/vax/include

2014-08-14 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Aug 14 11:28:13 UTC 2014

Modified Files:
src/sys/arch/vax/include: int_fmtio.h mutex.h

Log Message:
Revert previous changes, gcc configuration will be adapted instead.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/vax/include/int_fmtio.h
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/vax/include/mutex.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/int_fmtio.h
diff -u src/sys/arch/vax/include/int_fmtio.h:1.6 src/sys/arch/vax/include/int_fmtio.h:1.7
--- src/sys/arch/vax/include/int_fmtio.h:1.6	Thu Aug 14 09:17:32 2014
+++ src/sys/arch/vax/include/int_fmtio.h	Thu Aug 14 11:28:13 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: int_fmtio.h,v 1.6 2014/08/14 09:17:32 martin Exp $	*/
+/*	$NetBSD: int_fmtio.h,v 1.7 2014/08/14 11:28:13 martin Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -69,7 +69,7 @@
 #define	PRIiFAST32	i	/* int_fast32_t		*/
 #define	PRIiFAST64	lli	/* int_fast64_t		*/
 #define	PRIiMAX		lli	/* intmax_t		*/
-#define	PRIiPTR		i	/* intptr_t		*/
+#define	PRIiPTR		li	/* intptr_t		*/
 
 /* fprintf macros for unsigned integers */
 
@@ -101,7 +101,7 @@
 #define	PRIuFAST32	u	/* uint_fast32_t	*/
 #define	PRIuFAST64	llu	/* uint_fast64_t	*/
 #define	PRIuMAX		llu	/* uintmax_t		*/
-#define	PRIuPTR		u	/* uintptr_t		*/
+#define	PRIuPTR		lu	/* uintptr_t		*/
 
 #define	PRIx8		x	/* uint8_t		*/
 #define	PRIx16		x	/* uint16_t		*/

Index: src/sys/arch/vax/include/mutex.h
diff -u src/sys/arch/vax/include/mutex.h:1.13 src/sys/arch/vax/include/mutex.h:1.14
--- src/sys/arch/vax/include/mutex.h:1.13	Thu Aug 14 09:02:18 2014
+++ src/sys/arch/vax/include/mutex.h	Thu Aug 14 11:28:13 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: mutex.h,v 1.13 2014/08/14 09:02:18 martin Exp $	*/
+/*	$NetBSD: mutex.h,v 1.14 2014/08/14 11:28:13 martin Exp $	*/
 
 /*-
  * Copyright (c) 2002, 2007 The NetBSD Foundation, Inc.
@@ -82,7 +82,7 @@ struct kmutex {
  */
 #define	MUTEX_GIVE(mtx)		/* nothing */
 
-#define	MUTEX_CAS(p, o, n)	(atomic_cas_uint((p), (o), (n)) == (o))
+#define	MUTEX_CAS(p, o, n)	(atomic_cas_ulong((p), (o), (n)) == (o))
 
 #endif	/* __MUTEX_PRIVATE */
 



CVS commit: src/sys/arch/vax/include

2014-08-14 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Thu Aug 14 14:21:03 UTC 2014

Modified Files:
src/sys/arch/vax/include: int_fmtio.h

Log Message:
Fix SCN?FAST{8,16} formats to match reality (int) in gcc4.8.3


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/include/int_fmtio.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/int_fmtio.h
diff -u src/sys/arch/vax/include/int_fmtio.h:1.7 src/sys/arch/vax/include/int_fmtio.h:1.8
--- src/sys/arch/vax/include/int_fmtio.h:1.7	Thu Aug 14 11:28:13 2014
+++ src/sys/arch/vax/include/int_fmtio.h	Thu Aug 14 14:21:03 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: int_fmtio.h,v 1.7 2014/08/14 11:28:13 martin Exp $	*/
+/*	$NetBSD: int_fmtio.h,v 1.8 2014/08/14 14:21:03 matt Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -143,8 +143,8 @@
 #define	SCNdLEAST16	hd	/* int_least16_t	*/
 #define	SCNdLEAST32	d	/* int_least32_t	*/
 #define	SCNdLEAST64	lld	/* int_least64_t	*/
-#define	SCNdFAST8	hhd	/* int_fast8_t		*/
-#define	SCNdFAST16	hd	/* int_fast16_t		*/
+#define	SCNdFAST8	d	/* int_fast8_t		*/
+#define	SCNdFAST16	d	/* int_fast16_t		*/
 #define	SCNdFAST32	d	/* int_fast32_t		*/
 #define	SCNdFAST64	lld	/* int_fast64_t		*/
 #define	SCNdMAX		lld	/* intmax_t		*/
@@ -158,8 +158,8 @@
 #define	SCNiLEAST16	hi	/* int_least16_t	*/
 #define	SCNiLEAST32	i	/* int_least32_t	*/
 #define	SCNiLEAST64	lli	/* int_least64_t	*/
-#define	SCNiFAST8	hhi	/* int_fast8_t		*/
-#define	SCNiFAST16	hi	/* int_fast16_t		*/
+#define	SCNiFAST8	i	/* int_fast8_t		*/
+#define	SCNiFAST16	i	/* int_fast16_t		*/
 #define	SCNiFAST32	i	/* int_fast32_t		*/
 #define	SCNiFAST64	lli	/* int_fast64_t		*/
 #define	SCNiMAX		lli	/* intmax_t		*/
@@ -175,8 +175,8 @@
 #define	SCNoLEAST16	ho	/* uint_least16_t	*/
 #define	SCNoLEAST32	o	/* uint_least32_t	*/
 #define	SCNoLEAST64	llo	/* uint_least64_t	*/
-#define	SCNoFAST8	hho	/* uint_fast8_t		*/
-#define	SCNoFAST16	ho	/* uint_fast16_t	*/
+#define	SCNoFAST8	o	/* uint_fast8_t		*/
+#define	SCNoFAST16	o	/* uint_fast16_t	*/
 #define	SCNoFAST32	o	/* uint_fast32_t	*/
 #define	SCNoFAST64	llo	/* uint_fast64_t	*/
 #define	SCNoMAX		llo	/* uintmax_t		*/
@@ -190,8 +190,8 @@
 #define	SCNuLEAST16	hu	/* uint_least16_t	*/
 #define	SCNuLEAST32	u	/* uint_least32_t	*/
 #define	SCNuLEAST64	llu	/* uint_least64_t	*/
-#define	SCNuFAST8	hhu	/* uint_fast8_t		*/
-#define	SCNuFAST16	hu	/* uint_fast16_t	*/
+#define	SCNuFAST8	u	/* uint_fast8_t		*/
+#define	SCNuFAST16	u	/* uint_fast16_t	*/
 #define	SCNuFAST32	u	/* uint_fast32_t	*/
 #define	SCNuFAST64	llu	/* uint_fast64_t	*/
 #define	SCNuMAX		llu	/* uintmax_t		*/
@@ -205,8 +205,8 @@
 #define	SCNxLEAST16	hx	/* uint_least16_t	*/
 #define	SCNxLEAST32	x	/* uint_least32_t	*/
 #define	SCNxLEAST64	llx	/* uint_least64_t	*/
-#define	SCNxFAST8	hhx	/* uint_fast8_t		*/
-#define	SCNxFAST16	hx	/* uint_fast16_t	*/
+#define	SCNxFAST8	x	/* uint_fast8_t		*/
+#define	SCNxFAST16	x	/* uint_fast16_t	*/
 #define	SCNxFAST32	x	/* uint_fast32_t	*/
 #define	SCNxFAST64	llx	/* uint_fast64_t	*/
 #define	SCNxMAX		llx	/* uintmax_t		*/



CVS commit: src/sys/arch/vax/include

2014-01-25 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sun Jan 26 03:18:39 UTC 2014

Modified Files:
src/sys/arch/vax/include: vmparam.h

Log Message:
don't re-specify the defaults


To generate a diff of this commit:
cvs rdiff -u -r1.49 -r1.50 src/sys/arch/vax/include/vmparam.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/vmparam.h
diff -u src/sys/arch/vax/include/vmparam.h:1.49 src/sys/arch/vax/include/vmparam.h:1.50
--- src/sys/arch/vax/include/vmparam.h:1.49	Sat Jan 25 10:16:50 2014
+++ src/sys/arch/vax/include/vmparam.h	Sat Jan 25 22:18:39 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.49 2014/01/25 15:16:50 christos Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.50 2014/01/26 03:18:39 christos Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -98,14 +98,7 @@
 #define VM_MIN_KERNEL_ADDRESS	((vaddr_t)KERNBASE)
 #define VM_MAX_KERNEL_ADDRESS	((vaddr_t)(0xC000))
 
-/*
- * The address to which unspecified mapping requests default
- */
 #define __USE_TOPDOWN_VM
-#define VM_DEFAULT_ADDRESS_TOPDOWN(da, sz) \
-trunc_page(VM_MAXUSER_ADDRESS - MAXSSIZ - (sz))
-#define VM_DEFAULT_ADDRESS_BOTTOMUP(da, sz) \
-round_page((vaddr_t)(da) + (vsize_t)maxdmap)
 
 #define	USRIOSIZE		(8 * VAX_NPTEPG)	/* 512MB */
 #define	VM_PHYS_SIZE		(USRIOSIZE*VAX_NBPG)



CVS commit: src/sys/arch/vax/include

2014-01-23 Thread John Klos
Module Name:src
Committed By:   jklos
Date:   Thu Jan 23 21:37:09 UTC 2014

Modified Files:
src/sys/arch/vax/include: param.h

Log Message:
Removed MAXBSIZE. Cleared with Anders Magnusson and tested myself.


To generate a diff of this commit:
cvs rdiff -u -r1.60 -r1.61 src/sys/arch/vax/include/param.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/param.h
diff -u src/sys/arch/vax/include/param.h:1.60 src/sys/arch/vax/include/param.h:1.61
--- src/sys/arch/vax/include/param.h:1.60	Tue Jan 24 20:03:38 2012
+++ src/sys/arch/vax/include/param.h	Thu Jan 23 21:37:09 2014
@@ -1,4 +1,4 @@
-/*  $NetBSD: param.h,v 1.60 2012/01/24 20:03:38 christos Exp $*/
+/*  $NetBSD: param.h,v 1.61 2014/01/23 21:37:09 jklos Exp $*/
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
  * All rights reserved.
@@ -62,7 +62,6 @@
 
 #define BLKDEV_IOSIZE	2048
 #define	MAXPHYS		(64 * 1024)	/* max raw I/O transfer size */
-#define	MAXBSIZE	0x4000		/* max FS block size - XXX */
 
 #define	UPAGES		2		/* pages of u-area */
 #define USPACE		(NBPG*UPAGES)



CVS commit: src/sys/arch/vax/include

2013-11-09 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Sat Nov  9 20:32:59 UTC 2013

Modified Files:
src/sys/arch/vax/include: cpu.h

Log Message:
__USE cii


To generate a diff of this commit:
cvs rdiff -u -r1.96 -r1.97 src/sys/arch/vax/include/cpu.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/cpu.h
diff -u src/sys/arch/vax/include/cpu.h:1.96 src/sys/arch/vax/include/cpu.h:1.97
--- src/sys/arch/vax/include/cpu.h:1.96	Sat Oct 19 15:21:00 2013
+++ src/sys/arch/vax/include/cpu.h	Sat Nov  9 15:32:59 2013
@@ -1,4 +1,4 @@
-/*  $NetBSD: cpu.h,v 1.96 2013/10/19 19:21:00 christos Exp $  */
+/*  $NetBSD: cpu.h,v 1.97 2013/11/09 20:32:59 christos Exp $  */
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden
@@ -186,7 +186,8 @@ cpu_intr_p(void)
 #define	CPU_IS_PRIMARY(ci)	((ci)-ci_flags  CI_MASTERCPU)
 
 #define	CPU_INFO_ITERATOR	int
-#define	CPU_INFO_FOREACH(cii, ci)	cii = 0, ci = SIMPLEQ_FIRST(cpus); \
+#define	CPU_INFO_FOREACH(cii, ci)	cii = 0, __USE(cii), \
+	ci = SIMPLEQ_FIRST(cpus); \
 	ci != NULL; \
 	ci = SIMPLEQ_NEXT(ci, ci_next)
 



CVS commit: src/sys/arch/vax/include

2013-09-18 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Wed Sep 18 13:31:39 UTC 2013

Modified Files:
src/sys/arch/vax/include: vmparam.h

Log Message:
Bump MAXTSIZ to 32 MB (it is an arbitrary limit anyway)


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/sys/arch/vax/include/vmparam.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/vmparam.h
diff -u src/sys/arch/vax/include/vmparam.h:1.47 src/sys/arch/vax/include/vmparam.h:1.48
--- src/sys/arch/vax/include/vmparam.h:1.47	Sun Nov 14 13:33:23 2010
+++ src/sys/arch/vax/include/vmparam.h	Wed Sep 18 13:31:39 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmparam.h,v 1.47 2010/11/14 13:33:23 uebayasi Exp $	*/
+/*	$NetBSD: vmparam.h,v 1.48 2013/09/18 13:31:39 martin Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -62,7 +62,7 @@
  */
 
 #ifndef MAXTSIZ
-#define MAXTSIZ		(8*1024*1024)		/* max text size */
+#define MAXTSIZ		(32*1024*1024)		/* max text size */
 #endif
 #ifndef DFLDSIZ
 #define DFLDSIZ		(128*1024*1024)		/* initial data size limit */



CVS commit: src/sys/arch/vax/include

2013-09-16 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Mon Sep 16 15:56:24 UTC 2013

Modified Files:
src/sys/arch/vax/include: math.h

Log Message:
Change __isinf and __isnan from macros to inline functions. The macros do
collide with newer gcc libstdc++.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/vax/include/math.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/math.h
diff -u src/sys/arch/vax/include/math.h:1.6 src/sys/arch/vax/include/math.h:1.7
--- src/sys/arch/vax/include/math.h:1.6	Sun Feb  5 17:45:38 2012
+++ src/sys/arch/vax/include/math.h	Mon Sep 16 15:56:24 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: math.h,v 1.6 2012/02/05 17:45:38 matt Exp $	*/
+/*	$NetBSD: math.h,v 1.7 2013/09/16 15:56:24 martin Exp $	*/
 
 #ifndef _VAX_MATH_H_
 #define _VAX_MATH_H_
@@ -11,8 +11,10 @@
 #define	__INFINITY	1.0E+39F
 #endif
 
-#define	__isinf(__x)	(0)
-#define	__isnan(__x)	(0)
+static inline int __isinf(double __x) { return 0; }
+static inline int __isnan(double __x) { return 0; }
+#define	__HAVE_INLINE___ISINF
+#define	__HAVE_INLINE___ISNAN
 
 #if !defined(_ANSI_SOURCE)  !defined(_POSIX_C_SOURCE)  \
 !defined(_XOPEN_SOURCE) || \



CVS commit: src/sys/arch/vax/include

2013-04-04 Thread Martin Husemann
Module Name:src
Committed By:   martin
Date:   Thu Apr  4 12:50:03 UTC 2013

Modified Files:
src/sys/arch/vax/include: disklabel.h

Log Message:
Drop MAXPARTITIONS down to 12 - we do not have more space to store a
larger disklabel in the bootblocks at least on some supported machines.
Keep the extended major/minor sheme compatible with the 6.0 release and
note that we had a bigger MAXPARTITIONS in between.


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/vax/include/disklabel.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/disklabel.h
diff -u src/sys/arch/vax/include/disklabel.h:1.6 src/sys/arch/vax/include/disklabel.h:1.7
--- src/sys/arch/vax/include/disklabel.h:1.6	Mon Jul  2 22:42:18 2012
+++ src/sys/arch/vax/include/disklabel.h	Thu Apr  4 12:50:03 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: disklabel.h,v 1.6 2012/07/02 22:42:18 abs Exp $	*/
+/*	$NetBSD: disklabel.h,v 1.7 2013/04/04 12:50:03 martin Exp $	*/
 
 /*
  * Copyright (c) 1994 Christopher G. Demetriou
@@ -36,16 +36,24 @@
 #define LABELUSESMBR		0	/* no MBR partitionning */
 #define	LABELSECTOR		0	/* sector containing label */
 #define	LABELOFFSET		64	/* offset of label in sector */
-#define	MAXPARTITIONS		16	/* number of partitions */
+#define	MAXPARTITIONS		12	/* number of partitions */
 #define	OLDMAXPARTITIONS 	8	/* number of partitions before nb-6 */
 #define	RAW_PART		2	/* raw partition: xx?c */
+/*
+ * In NetBSD 6 we eroneously used a too large MAXPARTITIONS value (disklabel
+ * overlapped with important parts of the bootblocks and made some machines
+ * unbootable).
+ */
+#define	__TMPBIGMAXPARTITIONS	16	/* compatibility with 6.0 installs */
 
 /*
  * We use the highest bit of the minor number for the partition number.
  * This maintains backward compatibility with device nodes created before
  * MAXPARTITIONS was increased.
+ * Temporarily MAXPARTITIONS was 16, so we use that to keep compatibility
+ * with existing installations.
  */
-#define __VAX_MAXDISKS	((1  20) / MAXPARTITIONS)
+#define __VAX_MAXDISKS	((1  20) / __TMPBIGMAXPARTITIONS)
 #define DISKUNIT(dev)	((minor(dev) / OLDMAXPARTITIONS) % __VAX_MAXDISKS)
 #define DISKPART(dev)	((minor(dev) % OLDMAXPARTITIONS) + \
 ((minor(dev) / (__VAX_MAXDISKS * OLDMAXPARTITIONS)) * OLDMAXPARTITIONS))



CVS commit: src/sys/arch/vax/include

2012-06-01 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Fri Jun  1 06:26:38 UTC 2012

Modified Files:
src/sys/arch/vax/include: asm.h

Log Message:
Really fix polyf/polyd macros.  Now returns expected results.


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/vax/include/asm.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/asm.h
diff -u src/sys/arch/vax/include/asm.h:1.25 src/sys/arch/vax/include/asm.h:1.26
--- src/sys/arch/vax/include/asm.h:1.25	Tue May 29 17:25:38 2012
+++ src/sys/arch/vax/include/asm.h	Fri Jun  1 06:26:38 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: asm.h,v 1.25 2012/05/29 17:25:38 matt Exp $ */
+/*	$NetBSD: asm.h,v 1.26 2012/06/01 06:26:38 matt Exp $ */
 /*
  * Copyright (c) 1982, 1993
  *	The Regents of the University of California.  All rights reserved.
@@ -110,11 +110,9 @@
 	movzwl	\degree, %r2
 	movab	\tbladdr, %r3
 
-	clrd	%r0
-	jr	2f
+	movf	(%r3)+, %r0
 1:
 	mulf2	%r1, %r0		/* result *= arg */
-2:
 	addf2	(%r3)+, %r0		/* result += c[n] */
 	sobgtr	%r2, 1b
 	clrf	%r1			/* r1 is 0 on finish */
@@ -125,11 +123,9 @@
 	movzwl	\degree, %r2
 	movab	\tbladdr, %r3
 
-	clrd	%r0
-	jr	2f
+	movd	(%r3)+,	%r0
 1:
 	muld2	%r4, %r0		/* result *= arg */
-2:
 	addd2	(%r3)+, %r0		/* result += c[n] */
 	sobgtr	%r2, 1b
 	clrq	%r4			/* r4, r5 are 0 on finish */



CVS commit: src/sys/arch/vax/include

2012-05-29 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue May 29 17:25:38 UTC 2012

Modified Files:
src/sys/arch/vax/include: asm.h

Log Message:
Remove an unneeded indirect access from polyd/polyf macros


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/vax/include/asm.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/asm.h
diff -u src/sys/arch/vax/include/asm.h:1.24 src/sys/arch/vax/include/asm.h:1.25
--- src/sys/arch/vax/include/asm.h:1.24	Thu Jul 28 22:54:02 2011
+++ src/sys/arch/vax/include/asm.h	Tue May 29 17:25:38 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: asm.h,v 1.24 2011/07/28 22:54:02 matt Exp $ */
+/*	$NetBSD: asm.h,v 1.25 2012/05/29 17:25:38 matt Exp $ */
 /*
  * Copyright (c) 1982, 1993
  *	The Regents of the University of California.  All rights reserved.
@@ -115,7 +115,7 @@
 1:
 	mulf2	%r1, %r0		/* result *= arg */
 2:
-	addf2	*(%r3)+, %r0		/* result += c[n] */
+	addf2	(%r3)+, %r0		/* result += c[n] */
 	sobgtr	%r2, 1b
 	clrf	%r1			/* r1 is 0 on finish */
 .endm
@@ -130,7 +130,7 @@
 1:
 	muld2	%r4, %r0		/* result *= arg */
 2:
-	addd2	*(%r3)+, %r0		/* result += c[n] */
+	addd2	(%r3)+, %r0		/* result += c[n] */
 	sobgtr	%r2, 1b
 	clrq	%r4			/* r4, r5 are 0 on finish */
 .endm



CVS commit: src/sys/arch/vax/include

2012-05-25 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Fri May 25 12:32:49 UTC 2012

Modified Files:
src/sys/arch/vax/include: types.h userret.h

Log Message:
Implement __HAVE_RAS.  Unlike most implementation, this is done in userret
instead of cpu_switchto since we already accessing the proc structure so
the additional overhead of check p_raslist is minimal.


To generate a diff of this commit:
cvs rdiff -u -r1.44 -r1.45 src/sys/arch/vax/include/types.h
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/vax/include/userret.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/types.h
diff -u src/sys/arch/vax/include/types.h:1.44 src/sys/arch/vax/include/types.h:1.45
--- src/sys/arch/vax/include/types.h:1.44	Tue Jan 17 20:34:57 2012
+++ src/sys/arch/vax/include/types.h	Fri May 25 12:32:48 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: types.h,v 1.44 2012/01/17 20:34:57 joerg Exp $	*/
+/*	$NetBSD: types.h,v 1.45 2012/05/25 12:32:48 matt Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -78,6 +78,9 @@ typedef volatile char	__cpu_simple_lock_
 #define	__HAVE_CPU_DATA_FIRST
 #define	__HAVE_MM_MD_READWRITE
 #define	__HAVE_MM_MD_DIRECT_MAPPED_PHYS
+#ifdef _KERNEL
+#define	__HAVE_RAS
+#endif
 
 #define	__HAVE___LWP_GETPRIVATE_FAST
 #define	__HAVE_NO___THREAD

Index: src/sys/arch/vax/include/userret.h
diff -u src/sys/arch/vax/include/userret.h:1.13 src/sys/arch/vax/include/userret.h:1.14
--- src/sys/arch/vax/include/userret.h:1.13	Sun Jul  3 02:18:20 2011
+++ src/sys/arch/vax/include/userret.h	Fri May 25 12:32:48 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: userret.h,v 1.13 2011/07/03 02:18:20 matt Exp $	*/
+/*	$NetBSD: userret.h,v 1.14 2012/05/25 12:32:48 matt Exp $	*/
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -31,6 +31,7 @@
  */
 
 #include sys/userret.h
+#include sys/ras.h
 
 /*
  *	Common code used by various exception handlers to
@@ -44,6 +45,15 @@ userret(struct lwp *l, struct trapframe 
 	mi_userret(l);
 
 	/*
+	 * Check to see if a RAS was interrupted and restart it if it was.
+	 */
+	if (__predict_false(p-p_raslist != NULL)) {
+		void * const ras_pc = ras_lookup(p, (void *) tf-tf_pc);
+		if (ras_pc != (void *) -1)
+			tf-tf_pc = (vaddr_t) ras_pc;
+	}
+
+	/*
 	 * If profiling, charge system time to the trapped pc.
 	 */
 	if ((p-p_stflag  PST_PROFIL) != 0) {



CVS commit: src/sys/arch/vax/include

2012-02-27 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Mon Feb 27 15:50:49 UTC 2012

Modified Files:
src/sys/arch/vax/include: cpu.h

Log Message:
Change cpu_idle to be an inline which sets IPL to 1 and then back to 0
so simh can recognize the kernel is idle.


To generate a diff of this commit:
cvs rdiff -u -r1.93 -r1.94 src/sys/arch/vax/include/cpu.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/cpu.h
diff -u src/sys/arch/vax/include/cpu.h:1.93 src/sys/arch/vax/include/cpu.h:1.94
--- src/sys/arch/vax/include/cpu.h:1.93	Sun Jun  5 16:59:21 2011
+++ src/sys/arch/vax/include/cpu.h	Mon Feb 27 15:50:48 2012
@@ -1,4 +1,4 @@
-/*  $NetBSD: cpu.h,v 1.93 2011/06/05 16:59:21 matt Exp $  */
+/*  $NetBSD: cpu.h,v 1.94 2012/02/27 15:50:48 matt Exp $  */
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden
@@ -162,7 +162,18 @@ extern int cpu_printfataltraps;
 		mtpr(AST_OK,PR_ASTLVL);		\
 	} while (/*CONSTCOND*/ 0)
 #define	cpu_proc_fork(x, y)	do { } while (/*CONSCOND*/0)
-#define	cpu_idle()		do { } while (/*CONSCOND*/0)
+
+/*
+ * This allows SIMH to recognize the kernel wants to sleep.
+ */
+static inline void
+cpu_idle(void)
+{
+	int ipl = mfpr(PR_IPL);
+	mtpr(1, PR_IPL);
+	mtpr(ipl, PR_IPL);
+}
+
 static inline bool
 cpu_intr_p(void)
 {



CVS commit: src/sys/arch/vax/include

2012-02-05 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Sun Feb  5 17:45:38 UTC 2012

Modified Files:
src/sys/arch/vax/include: math.h

Log Message:
Define __INFINITY as huge_val since VAX FP doesn't have infinities.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/include/math.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/math.h
diff -u src/sys/arch/vax/include/math.h:1.5 src/sys/arch/vax/include/math.h:1.6
--- src/sys/arch/vax/include/math.h:1.5	Sun Dec 11 12:19:34 2005
+++ src/sys/arch/vax/include/math.h	Sun Feb  5 17:45:38 2012
@@ -1,6 +1,15 @@
-/*	$NetBSD: math.h,v 1.5 2005/12/11 12:19:34 christos Exp $	*/
+/*	$NetBSD: math.h,v 1.6 2012/02/05 17:45:38 matt Exp $	*/
 
+#ifndef _VAX_MATH_H_
+#define _VAX_MATH_H_
+
+#include sys/cdefs.h
+
+#if __GNUC_PREREQ__(3, 3)
+#define	__INFINITY	__builtin_huge_valf()
+#else
 #define	__INFINITY	1.0E+39F
+#endif
 
 #define	__isinf(__x)	(0)
 #define	__isnan(__x)	(0)
@@ -15,3 +24,5 @@
 #define	FP_DIRTYZERO	0x80
 #define	FP_ROP		0x81
 #endif
+
+#endif /* _VAX_MATH_H_ */



CVS commit: src/sys/arch/vax/include

2012-02-02 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Thu Feb  2 18:32:16 UTC 2012

Modified Files:
src/sys/arch/vax/include: mcontext.h

Log Message:
For fast lwp_getprivate, just do the chmk $SYS_lwp_getprivate inline.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/vax/include/mcontext.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/mcontext.h
diff -u src/sys/arch/vax/include/mcontext.h:1.7 src/sys/arch/vax/include/mcontext.h:1.8
--- src/sys/arch/vax/include/mcontext.h:1.7	Sat Jan  7 16:47:42 2012
+++ src/sys/arch/vax/include/mcontext.h	Thu Feb  2 18:32:16 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: mcontext.h,v 1.7 2012/01/07 16:47:42 chs Exp $	*/
+/*	$NetBSD: mcontext.h,v 1.8 2012/02/02 18:32:16 matt Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -73,12 +73,16 @@ typedef struct {
 
 #define	_UC_MACHINE_SET_PC(uc, pc)	_UC_MACHINE_PC(uc) = (pc)
 
+#ifndef _KERNEL
+#include sys/syscall.h
+
 static __inline void *
 __lwp_getprivate_fast(void)
 {
 	register void *tcb __asm(r0);
-	__asm(chmu $1 ::: r0);
+	__asm(chmk %0 :: i(SYS__lwp_getprivate) : r0);
 	return tcb;
 }
+#endif
 
 #endif	/* !_VAX_MCONTEXT_H_ */



CVS commit: src/sys/arch/vax/include

2011-07-28 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Thu Jul 28 22:54:02 UTC 2011

Modified Files:
src/sys/arch/vax/include: asm.h

Log Message:
Add macros for polyd and polyf


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/vax/include/asm.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/asm.h
diff -u src/sys/arch/vax/include/asm.h:1.23 src/sys/arch/vax/include/asm.h:1.24
--- src/sys/arch/vax/include/asm.h:1.23	Tue Jan 25 02:37:35 2011
+++ src/sys/arch/vax/include/asm.h	Thu Jul 28 22:54:02 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: asm.h,v 1.23 2011/01/25 02:37:35 matt Exp $ */
+/*	$NetBSD: asm.h,v 1.24 2011/07/28 22:54:02 matt Exp $ */
 /*
  * Copyright (c) 1982, 1993
  *	The Regents of the University of California.  All rights reserved.
@@ -105,4 +105,34 @@
 	.popsection
 #endif /* __STDC__ */
 
+.macro	polyf arg:req degree:req tbladdr:req
+	movf	\arg, %r1
+	movzwl	\degree, %r2
+	movab	\tbladdr, %r3
+
+	clrd	%r0
+	jr	2f
+1:
+	mulf2	%r1, %r0		/* result *= arg */
+2:
+	addf2	*(%r3)+, %r0		/* result += c[n] */
+	sobgtr	%r2, 1b
+	clrf	%r1			/* r1 is 0 on finish */
+.endm
+
+.macro	polyd arg:req degree:req tbladdr:req
+	movd	\arg, %r4
+	movzwl	\degree, %r2
+	movab	\tbladdr, %r3
+
+	clrd	%r0
+	jr	2f
+1:
+	muld2	%r4, %r0		/* result *= arg */
+2:
+	addd2	*(%r3)+, %r0		/* result += c[n] */
+	sobgtr	%r2, 1b
+	clrq	%r4			/* r4, r5 are 0 on finish */
+.endm
+
 #endif /* !_VAX_ASM_H_ */



CVS commit: src/sys/arch/vax/include

2011-06-21 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Wed Jun 22 04:00:43 UTC 2011

Modified Files:
src/sys/arch/vax/include: stdarg.h

Log Message:
deal with __builtin_va_start()'s introduction.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/vax/include/stdarg.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/stdarg.h
diff -u src/sys/arch/vax/include/stdarg.h:1.17 src/sys/arch/vax/include/stdarg.h:1.18
--- src/sys/arch/vax/include/stdarg.h:1.17	Sun Dec 11 12:19:34 2005
+++ src/sys/arch/vax/include/stdarg.h	Wed Jun 22 04:00:43 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: stdarg.h,v 1.17 2005/12/11 12:19:34 christos Exp $	*/
+/*	$NetBSD: stdarg.h,v 1.18 2011/06/22 04:00:43 mrg Exp $	*/
 
 /*-
  * Copyright (c) 1991 The Regents of the University of California.
@@ -44,7 +44,11 @@
 #endif
 
 #if __GNUC_PREREQ__(2, 96)
+#if __GNUC_PREREQ__(4, 5)
+#define	va_start(ap, last)	__builtin_va_start((ap), (last))
+#else
 #define	va_start(ap, last)	__builtin_stdarg_start((ap), (last))
+#endif
 #define	va_arg			__builtin_va_arg
 #define	va_end			__builtin_va_end
 #define	__va_copy(dest, src)	__builtin_va_copy((dest), (src))



CVS commit: src/sys/arch/vax/include

2011-04-12 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Apr 12 18:24:28 UTC 2011

Modified Files:
src/sys/arch/vax/include: mcontext.h

Log Message:
Add __lwp_getprivate_fast


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/vax/include/mcontext.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/mcontext.h
diff -u src/sys/arch/vax/include/mcontext.h:1.5 src/sys/arch/vax/include/mcontext.h:1.6
--- src/sys/arch/vax/include/mcontext.h:1.5	Mon Apr 28 20:23:39 2008
+++ src/sys/arch/vax/include/mcontext.h	Tue Apr 12 18:24:28 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: mcontext.h,v 1.5 2008/04/28 20:23:39 martin Exp $	*/
+/*	$NetBSD: mcontext.h,v 1.6 2011/04/12 18:24:28 matt Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -70,4 +70,12 @@
 
 #define	_UC_MACHINE_SET_PC(uc, pc)	_UC_MACHINE_PC(uc) = (pc)
 
+static __inline void *
+__lwp_getprivate_fast(void)
+{
+	register void *tcb __asm(r0);
+	__asm(chmu $1 ::: r0);
+	return tcb;
+}
+
 #endif	/* !_VAX_MCONTEXT_H_ */



CVS commit: src/sys/arch/vax/include

2011-01-24 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Jan 25 02:37:35 UTC 2011

Modified Files:
src/sys/arch/vax/include: asm.h

Log Message:
Align functions on 4 byte boundaries, not 16.
Add END(x) for function sizing.


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/vax/include/asm.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/asm.h
diff -u src/sys/arch/vax/include/asm.h:1.22 src/sys/arch/vax/include/asm.h:1.23
--- src/sys/arch/vax/include/asm.h:1.22	Mon Dec 20 21:11:26 2010
+++ src/sys/arch/vax/include/asm.h	Tue Jan 25 02:37:35 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: asm.h,v 1.22 2010/12/20 21:11:26 joerg Exp $ */
+/*	$NetBSD: asm.h,v 1.23 2011/01/25 02:37:35 matt Exp $ */
 /*
  * Copyright (c) 1982, 1993
  *	The Regents of the University of California.  All rights reserved.
@@ -60,7 +60,7 @@
 
 /* let kernels and others override entrypoint alignment */
 #ifndef _ALIGN_TEXT
-# define _ALIGN_TEXT .align 4
+# define _ALIGN_TEXT .p2align 2
 #endif
 
 #define	_ENTRY(x, regs) \
@@ -76,6 +76,7 @@
 #define ENTRY(x, regs)		_ENTRY(_C_LABEL(x), regs); _PROF_PROLOGUE
 #define NENTRY(x, regs)		_ENTRY(_C_LABEL(x), regs)
 #define ASENTRY(x, regs)	_ENTRY(_ASM_LABEL(x), regs); _PROF_PROLOGUE
+#define END(x)			.size _C_LABEL(x),.-_C_LABEL(x)
 
 #define ALTENTRY(x)		.globl _C_LABEL(x); _C_LABEL(x):
 #define RCSID(name)		.pushsection .ident; .asciz name; .popsection



CVS commit: src/sys/arch/vax/include

2010-12-21 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Wed Dec 22 01:03:18 UTC 2010

Modified Files:
src/sys/arch/vax/include: types.h

Log Message:
Add a define __HAVE_CPU_DATA_FIRST which means that cpu_data is the first
member in struct cpu_info.


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/sys/arch/vax/include/types.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/types.h
diff -u src/sys/arch/vax/include/types.h:1.40 src/sys/arch/vax/include/types.h:1.41
--- src/sys/arch/vax/include/types.h:1.40	Fri Dec 11 05:52:04 2009
+++ src/sys/arch/vax/include/types.h	Wed Dec 22 01:03:18 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: types.h,v 1.40 2009/12/11 05:52:04 matt Exp $	*/
+/*	$NetBSD: types.h,v 1.41 2010/12/22 01:03:18 matt Exp $	*/
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -75,5 +75,6 @@
 #define	__HAVE_DEVICE_REGISTER
 #define	__HAVE_SYSCALL_INTERN
 #define	__HAVE_FAST_SOFTINTS
+#define	__HAVE_CPU_DATA_FIRST
 
 #endif	/* _MACHTYPES_H_ */



CVS commit: src/sys/arch/vax/include

2010-12-14 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 14 23:27:37 UTC 2010

Modified Files:
src/sys/arch/vax/include: cpu.h

Log Message:
Switch to use sys/device_if.h


To generate a diff of this commit:
cvs rdiff -u -r1.90 -r1.91 src/sys/arch/vax/include/cpu.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/cpu.h
diff -u src/sys/arch/vax/include/cpu.h:1.90 src/sys/arch/vax/include/cpu.h:1.91
--- src/sys/arch/vax/include/cpu.h:1.90	Sat Nov 13 02:23:27 2010
+++ src/sys/arch/vax/include/cpu.h	Tue Dec 14 23:27:37 2010
@@ -1,4 +1,4 @@
-/*  $NetBSD: cpu.h,v 1.90 2010/11/13 02:23:27 matt Exp $  */
+/*  $NetBSD: cpu.h,v 1.91 2010/12/14 23:27:37 matt Exp $  */
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden
@@ -48,7 +48,7 @@
 
 #include sys/cdefs.h
 #include sys/queue.h
-#include sys/device.h
+#include sys/device_if.h
 #include sys/cpu_data.h
 
 #include machine/mtpr.h



CVS commit: src/sys/arch/vax/include

2010-12-14 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 14 23:29:02 UTC 2010

Modified Files:
src/sys/arch/vax/include: psl.h

Log Message:
Since CLKF_BASEPRI isn't used any more, merge its test into CLKF_INTR which
results in a simplier comparision.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/vax/include/psl.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/psl.h
diff -u src/sys/arch/vax/include/psl.h:1.11 src/sys/arch/vax/include/psl.h:1.12
--- src/sys/arch/vax/include/psl.h:1.11	Tue Aug  5 15:56:04 2008
+++ src/sys/arch/vax/include/psl.h	Tue Dec 14 23:29:02 2010
@@ -1,4 +1,4 @@
-/*  $NetBSD: psl.h,v 1.11 2008/08/05 15:56:04 matt Exp $  */
+/*  $NetBSD: psl.h,v 1.12 2010/12/14 23:29:02 matt Exp $  */
 
 /*
  * Rewritten for the VAX port. Based on Berkeley code. /IC
@@ -102,11 +102,10 @@
 /*
  * Macros to decode processor status word.
  */
-#define	CLKF_USERMODE(framep)	framep)-ps)  (PSL_U)) == PSL_U)
-#define	CLKF_BASEPRI(framep)	framep)-ps)  (PSL_IPL1F))  PSL_IPL02)
+#define	CLKF_USERMODE(framep)	(((framep)-ps  PSL_U) == PSL_U)
 #define	CLKF_PC(framep)		((framep)-pc)
-#define	CLKF_INTR(framep)	(framep)-ps)  (PSL_IS)) == PSL_IS)  \
-!CLKF_BASEPRI(framep))
+#define	CLKF_INTR(framep)	(((framep)-ps  (PSL_IS|PSL_IPL1F)) \
+= (PSL_IPL02|PSL_IS))
 #define PSL2IPL(ps) ((ps)  16)
 
 #endif



CVS commit: src/sys/arch/vax/include

2010-12-14 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Tue Dec 14 23:29:33 UTC 2010

Modified Files:
src/sys/arch/vax/include: scb.h

Log Message:
Include sys/evcnt.h since sys/cpu.h no includes sys/device.h


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/vax/include/scb.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/scb.h
diff -u src/sys/arch/vax/include/scb.h:1.12 src/sys/arch/vax/include/scb.h:1.13
--- src/sys/arch/vax/include/scb.h:1.12	Wed Feb 20 16:37:52 2008
+++ src/sys/arch/vax/include/scb.h	Tue Dec 14 23:29:33 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: scb.h,v 1.12 2008/02/20 16:37:52 matt Exp $	*/
+/*	$NetBSD: scb.h,v 1.13 2010/12/14 23:29:33 matt Exp $	*/
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -29,9 +29,12 @@
  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
+
 #ifndef _VAX_SCB_H
 #define	_VAX_SCB_H
 
+#include sys/evcnt.h
+
 /*
  * Definition of the System Control Block. More about it can be
  * found in the Vax Architecture Reference Manual, section 6.6.



CVS commit: src/sys/arch/vax/include

2010-11-12 Thread Masao Uebayashi
Module Name:src
Committed By:   uebayasi
Date:   Fri Nov 12 13:35:51 UTC 2010

Modified Files:
src/sys/arch/vax/include: pmap.h

Log Message:
Pull in uvm/uvm.h for VM_PAGE_TO_PHYS().


To generate a diff of this commit:
cvs rdiff -u -r1.77 -r1.78 src/sys/arch/vax/include/pmap.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/pmap.h
diff -u src/sys/arch/vax/include/pmap.h:1.77 src/sys/arch/vax/include/pmap.h:1.78
--- src/sys/arch/vax/include/pmap.h:1.77	Wed Oct 21 21:12:04 2009
+++ src/sys/arch/vax/include/pmap.h	Fri Nov 12 13:35:51 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.h,v 1.77 2009/10/21 21:12:04 rmind Exp $	   */
+/*	$NetBSD: pmap.h,v 1.78 2010/11/12 13:35:51 uebayasi Exp $	   */
 
 /* 
  * Copyright (c) 1991 Regents of the University of California.
@@ -83,6 +83,8 @@
 
 #include sys/simplelock.h
 
+#include uvm/uvm_page.h
+
 #include machine/pte.h
 #include machine/mtpr.h
 #include machine/pcb.h



CVS commit: src/sys/arch/vax/include

2010-05-29 Thread Takehiko NOZAKI
Module Name:src
Committed By:   tnozaki
Date:   Sat May 29 17:45:15 UTC 2010

Modified Files:
src/sys/arch/vax/include: int_const.h

Log Message:
fix wrong integer promotion rule(removed U suffix from UINT{8,16}_C).
see ISO/IEC 9899:1999 7.18.4.3.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/vax/include/int_const.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/int_const.h
diff -u src/sys/arch/vax/include/int_const.h:1.2 src/sys/arch/vax/include/int_const.h:1.3
--- src/sys/arch/vax/include/int_const.h:1.2	Mon Apr 28 20:23:39 2008
+++ src/sys/arch/vax/include/int_const.h	Sat May 29 17:45:15 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: int_const.h,v 1.2 2008/04/28 20:23:39 martin Exp $	*/
+/*	$NetBSD: int_const.h,v 1.3 2010/05/29 17:45:15 tnozaki Exp $	*/
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -43,8 +43,8 @@
 #define	INT32_C(c)	c
 #define	INT64_C(c)	c ## LL
 
-#define	UINT8_C(c)	c ## U
-#define	UINT16_C(c)	c ## U
+#define	UINT8_C(c)	c
+#define	UINT16_C(c)	c
 #define	UINT32_C(c)	c ## U
 #define	UINT64_C(c)	c ## ULL
 



CVS commit: src/sys/arch/vax/include

2009-08-10 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Mon Aug 10 08:05:33 UTC 2009

Modified Files:
src/sys/arch/vax/include: pte.h

Log Message:
Change kvtopte and kvtophys from ({ }) to static inline and while there
make them tolerable of rump.


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/vax/include/pte.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/pte.h
diff -u src/sys/arch/vax/include/pte.h:1.22 src/sys/arch/vax/include/pte.h:1.23
--- src/sys/arch/vax/include/pte.h:1.22	Fri Aug 29 18:25:02 2008
+++ src/sys/arch/vax/include/pte.h	Mon Aug 10 08:05:32 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: pte.h,v 1.22 2008/08/29 18:25:02 matt Exp $	  */
+/*	$NetBSD: pte.h,v 1.23 2009/08/10 08:05:32 matt Exp $	  */
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -77,17 +77,49 @@
 #endif
 
 #ifdef __GNUC__
-#define kvtopte(va) ({ \
-	struct pte *r; \
-	__asm(extzv $9,$21,%1,%0;moval *Sysmap[%0],%0 : =r(r) : g(va)); \
-	r; \
-})
-#define kvtophys(va) ({ \
-	paddr_t r; \
-	__asm(extzv $9,$21,%1,%0;ashl $9,*Sysmap[%0],%0;insv %1,$0,$9,%0 \
-	: =r(r) : g(va) : cc); \
-	r; \
-})
+#define	kvtopte(va)	kvtopte0((vaddr_t) (va))
+static inline struct pte *
+kvtopte0(vaddr_t va)
+{
+	struct pte *pt;
+#ifdef _RUMPKERNEL
+	__asm(
+		extzv $9,$21,%1,%0\n\t
+		moval %2[%0],%0\n\t
+	 : =r(pt)
+	 : g(va), o(*Sysmap));
+#else
+	__asm(
+		extzv $9,$21,%1,%0\n\t
+		moval *Sysmap[%0],%0\n\t
+	 : =r(pt)
+	 : g(va));
+#endif
+	return pt;
+}
+
+#define	kvtophys(va)	kvtophys0((vaddr_t) (va))
+static inline paddr_t
+kvtophys0(vaddr_t va)
+{
+	paddr_t pa;
+#ifdef _RUMPKERNEL
+	__asm(
+		extzv $9,$21,%1,%0\n\t
+		ashl $9,%2[%0],%0\n\t
+		insv %1,$0,$9,%0\n\t
+	: =r(pa)
+	: g(va), o(*Sysmap) : cc);
+#else
+	__asm(
+		extzv $9,$21,%1,%0\n\t
+		ashl $9,*Sysmap[%0],%0\n\t
+		insv %1,$0,$9,%0\n\t
+	: =r(pa)
+	: g(va) : cc);
+#endif
+	return pa;
+}
 #else /* __GNUC__ */
 #define kvtophys(va) \
 	(((kvtopte(va))-pg_pfn  VAX_PGSHIFT) | ((paddr_t)(va)  VAX_PGOFSET))



CVS commit: src/sys/arch/vax/include

2009-05-13 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed May 13 09:40:48 UTC 2009

Modified Files:
src/sys/arch/vax/include: mtpr.h

Log Message:
Fix obvious typo in last.


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/vax/include/mtpr.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/mtpr.h
diff -u src/sys/arch/vax/include/mtpr.h:1.21 src/sys/arch/vax/include/mtpr.h:1.22
--- src/sys/arch/vax/include/mtpr.h:1.21	Wed May 13 03:40:13 2009
+++ src/sys/arch/vax/include/mtpr.h	Wed May 13 09:40:48 2009
@@ -1,4 +1,4 @@
-/*  $NetBSD: mtpr.h,v 1.21 2009/05/13 03:40:13 mhitch Exp $ */
+/*  $NetBSD: mtpr.h,v 1.22 2009/05/13 09:40:48 skrll Exp $ */
 
 /*
  * Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -169,7 +169,7 @@
 static inline void
 mtpr(register_t val, int reg)
 {
-	__asmB volatile (
+	__asm volatile (
 		mtpr %0,%1
 	: /* No output */
 	: g (val), g (reg)



CVS commit: src/sys/arch/vax/include

2009-05-12 Thread Michael L. Hitch
Module Name:src
Committed By:   mhitch
Date:   Wed May 13 03:38:08 UTC 2009

Modified Files:
src/sys/arch/vax/include: intr.h

Log Message:
Revert using __insn_barrier();  changed to use memory clobber in the
mtpr() macro.


To generate a diff of this commit:
cvs rdiff -u -r1.28 -r1.29 src/sys/arch/vax/include/intr.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/vax/include/intr.h
diff -u src/sys/arch/vax/include/intr.h:1.28 src/sys/arch/vax/include/intr.h:1.29
--- src/sys/arch/vax/include/intr.h:1.28	Wed May  6 21:41:59 2009
+++ src/sys/arch/vax/include/intr.h	Wed May 13 03:38:08 2009
@@ -1,4 +1,4 @@
-/* 	$NetBSD: intr.h,v 1.28 2009/05/06 21:41:59 mhitch Exp $	*/
+/* 	$NetBSD: intr.h,v 1.29 2009/05/13 03:38:08 mhitch Exp $	*/
 
 /*
  * Copyright (c) 1998 Matt Thomas.
@@ -73,7 +73,6 @@
 _splset(ipl_t ipl)
 {
 	mtpr(ipl, PR_IPL);
-	__insn_barrier();
 }
 
 static inline ipl_t