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

2019-10-29 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Wed Oct 30 05:35:36 UTC 2019

Modified Files:
src/sys/arch/x86/include: specialreg.h

Log Message:
- GMET is not bit 11 but 17.
- Add unknown CPUID Fn8000_000a %edx bit 20.


To generate a diff of this commit:
cvs rdiff -u -r1.155 -r1.156 src/sys/arch/x86/include/specialreg.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/x86/include/specialreg.h
diff -u src/sys/arch/x86/include/specialreg.h:1.155 src/sys/arch/x86/include/specialreg.h:1.156
--- src/sys/arch/x86/include/specialreg.h:1.155	Tue Oct  8 03:16:21 2019
+++ src/sys/arch/x86/include/specialreg.h	Wed Oct 30 05:35:36 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: specialreg.h,v 1.155 2019/10/08 03:16:21 msaitoh Exp $	*/
+/*	$NetBSD: specialreg.h,v 1.156 2019/10/30 05:35:36 msaitoh Exp $	*/
 
 /*
  * Copyright (c) 2014-2019 The NetBSD Foundation, Inc.
@@ -755,19 +755,20 @@
 #define CPUID_AMD_SVM_FlushByASID	0x0040
 #define CPUID_AMD_SVM_DecodeAssist	0x0080
 #define CPUID_AMD_SVM_PauseFilter	0x0400
-#define CPUID_AMD_SVM_GMET		0x0800
 #define CPUID_AMD_SVM_PFThreshold	0x1000 /* PAUSE filter threshold */
 #define CPUID_AMD_SVM_AVIC		0x2000 /* AMD Virtual intr. ctrl */
 #define CPUID_AMD_SVM_V_VMSAVE_VMLOAD	0x8000 /* Virtual VM{SAVE/LOAD} */
 #define CPUID_AMD_SVM_vGIF		0x0001 /* Virtualized GIF */
+#define CPUID_AMD_SVM_GMET		0x0002
 #define CPUID_AMD_SVM_FLAGS	 "\20" \
 	"\1" "NP"	"\2" "LbrVirt"	"\3" "SVML"	"\4" "NRIPS"	\
 	"\5" "TSCRate"	"\6" "VMCBCleanBits" \
 			"\7" "FlushByASID" "\10" "DecodeAssist"	\
-	"\11" "B08"	"\12" "B09"	"\13" "PauseFilter" "\14" "GMET" \
+	"\11" "B08"	"\12" "B09"	"\13" "PauseFilter" "\14" "B11"	\
 	"\15" "PFThreshold" "\16" "AVIC" "\17" "B14"			\
 		"\20" "V_VMSAVE_VMLOAD"	\
-	"\21" "VGIF"
+	"\21" "VGIF"	"\22" "GMET"	\
+	"\25" "B20"
 
 /*
  * AMD Fn8000_0001d Cache Topology Information.



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

2019-10-29 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Wed Oct 30 05:35:36 UTC 2019

Modified Files:
src/sys/arch/x86/include: specialreg.h

Log Message:
- GMET is not bit 11 but 17.
- Add unknown CPUID Fn8000_000a %edx bit 20.


To generate a diff of this commit:
cvs rdiff -u -r1.155 -r1.156 src/sys/arch/x86/include/specialreg.h

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



CVS commit: src/sys

2019-10-29 Thread Kengo NAKAHARA
Module Name:src
Committed By:   knakahara
Date:   Wed Oct 30 03:45:59 UTC 2019

Modified Files:
src/sys/net: if_gif.c if_gif.h
src/sys/netinet6: in6.h in6_gif.c in6_gif.h

Log Message:
Add sysctl nodes to control fragmentation with IPv[46] over IPv6 gif(4).

New sysctl node "net.inet6.ip6.gifpmtu" means
- 0 (default)
  Fragment by IPV6_MMTU. All packets reach the destination certainly,
  however the long packet performance is poor.
  This is same behavior as before.
- 1
  Fragment by outer interface's MTU. The long packet performance would
  be good, however the packets may be dropped in some network paths
  whose path MTU less than the interface's MTU.
- others
  undefined yet

New sysctl node "net.interfaces.gif*.pmtu" means
- -1 (default)
  Use system default value (net.inet6.ip6.gifpmtu).
- 0
  Fragment by IPV6_MMTU for this gif(4) tunnel.
- 1
  Fragment by outer interface's MTU for this gif(4) tunnel.
- others
  undefined yet

See RFC4459 for more information and other solutions.


To generate a diff of this commit:
cvs rdiff -u -r1.149 -r1.150 src/sys/net/if_gif.c
cvs rdiff -u -r1.33 -r1.34 src/sys/net/if_gif.h
cvs rdiff -u -r1.96 -r1.97 src/sys/netinet6/in6.h
cvs rdiff -u -r1.94 -r1.95 src/sys/netinet6/in6_gif.c
cvs rdiff -u -r1.17 -r1.18 src/sys/netinet6/in6_gif.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/net/if_gif.c
diff -u src/sys/net/if_gif.c:1.149 src/sys/net/if_gif.c:1.150
--- src/sys/net/if_gif.c:1.149	Thu Sep 19 06:07:24 2019
+++ src/sys/net/if_gif.c	Wed Oct 30 03:45:59 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_gif.c,v 1.149 2019/09/19 06:07:24 knakahara Exp $	*/
+/*	$NetBSD: if_gif.c,v 1.150 2019/10/30 03:45:59 knakahara Exp $	*/
 /*	$KAME: if_gif.c,v 1.76 2001/08/20 02:01:02 kjc Exp $	*/
 
 /*
@@ -31,7 +31,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.149 2019/09/19 06:07:24 knakahara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_gif.c,v 1.150 2019/10/30 03:45:59 knakahara Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -142,6 +142,58 @@ static int max_gif_nesting = MAX_GIF_NES
 
 static struct sysctllog *gif_sysctl;
 
+#ifdef INET6
+static int
+sysctl_gif_pmtu_global(SYSCTLFN_ARGS)
+{
+	int error, pmtu;
+	struct sysctlnode node = *rnode;
+
+	pmtu = ip6_gif_pmtu;
+	node.sysctl_data = 
+	error = sysctl_lookup(SYSCTLFN_CALL());
+	if (error || newp == NULL)
+		return error;
+
+	switch (pmtu) {
+	case GIF_PMTU_MINMTU:
+	case GIF_PMTU_OUTERMTU:
+		ip6_gif_pmtu = pmtu;
+		break;
+	default:
+		return EINVAL;
+	}
+
+	return 0;
+}
+
+static int
+sysctl_gif_pmtu_perif(SYSCTLFN_ARGS)
+{
+	int error, pmtu;
+	struct sysctlnode node = *rnode;
+	struct gif_softc *sc = (struct gif_softc *)node.sysctl_data;
+
+	pmtu = sc->gif_pmtu;
+	node.sysctl_data = 
+	error = sysctl_lookup(SYSCTLFN_CALL());
+	if (error || newp == NULL)
+		return error;
+
+	switch (pmtu) {
+	case GIF_PMTU_SYSDEFAULT:
+	case GIF_PMTU_MINMTU:
+	case GIF_PMTU_OUTERMTU:
+		sc->gif_pmtu = pmtu;
+		break;
+	default:
+		return EINVAL;
+	}
+
+	return 0;
+}
+#endif
+
 static void
 gif_sysctl_setup(void)
 {
@@ -196,6 +248,52 @@ gif_sysctl_setup(void)
 		   NULL, 0, _gif_hlim, 0,
 		   CTL_NET, PF_INET6, IPPROTO_IPV6,
 		   IPV6CTL_GIF_HLIM, CTL_EOL);
+
+	sysctl_createv(_sysctl, 0, NULL, NULL,
+		   CTLFLAG_PERMANENT | CTLFLAG_READWRITE,
+		   CTLTYPE_INT, "gifpmtu",
+		   SYSCTL_DESCR("Default Path MTU setting for gif tunnels"),
+		   sysctl_gif_pmtu_global, 0, NULL, 0,
+		   CTL_NET, PF_INET6, IPPROTO_IPV6,
+		   IPV6CTL_GIF_PMTU, CTL_EOL);
+#endif
+}
+
+static void
+gif_perif_sysctl_setup(struct sysctllog **clog, struct gif_softc *sc)
+{
+#ifdef INET6
+	const struct sysctlnode *cnode, *rnode;
+	struct ifnet *ifp = >gif_if;
+	const char *ifname = ifp->if_xname;
+	int rv;
+
+	/*
+	 * Already created in sysctl_sndq_setup().
+	 */
+	sysctl_createv(clog, 0, NULL, ,
+		   CTLFLAG_PERMANENT,
+		   CTLTYPE_NODE, "interfaces",
+		   SYSCTL_DESCR("Per-interface controls"),
+		   NULL, 0, NULL, 0,
+		   CTL_NET, CTL_CREATE, CTL_EOL);
+	sysctl_createv(clog, 0, , ,
+		   CTLFLAG_PERMANENT,
+		   CTLTYPE_NODE, ifname,
+		   SYSCTL_DESCR("Interface controls"),
+		   NULL, 0, NULL, 0,
+		   CTL_CREATE, CTL_EOL);
+
+	rv = sysctl_createv(clog, 0, , ,
+			CTLFLAG_PERMANENT,
+			CTLTYPE_INT, "pmtu",
+			SYSCTL_DESCR("Path MTU setting for this gif tunnel"),
+			sysctl_gif_pmtu_perif, 0, (void *)sc, 0,
+			CTL_CREATE, CTL_EOL);
+	if (rv != 0)
+		log(LOG_WARNING, "%s: could not attach sysctl node pmtu\n", ifname);
+
+	sc->gif_pmtu = GIF_PMTU_SYSDEFAULT;
 #endif
 }
 
@@ -248,6 +346,7 @@ gif_clone_create(struct if_clone *ifc, i
 {
 	struct gif_softc *sc;
 	struct gif_variant *var;
+	struct ifnet *ifp;
 	int rv;
 
 	sc = kmem_zalloc(sizeof(struct 

CVS commit: src/sys

2019-10-29 Thread Kengo NAKAHARA
Module Name:src
Committed By:   knakahara
Date:   Wed Oct 30 03:45:59 UTC 2019

Modified Files:
src/sys/net: if_gif.c if_gif.h
src/sys/netinet6: in6.h in6_gif.c in6_gif.h

Log Message:
Add sysctl nodes to control fragmentation with IPv[46] over IPv6 gif(4).

New sysctl node "net.inet6.ip6.gifpmtu" means
- 0 (default)
  Fragment by IPV6_MMTU. All packets reach the destination certainly,
  however the long packet performance is poor.
  This is same behavior as before.
- 1
  Fragment by outer interface's MTU. The long packet performance would
  be good, however the packets may be dropped in some network paths
  whose path MTU less than the interface's MTU.
- others
  undefined yet

New sysctl node "net.interfaces.gif*.pmtu" means
- -1 (default)
  Use system default value (net.inet6.ip6.gifpmtu).
- 0
  Fragment by IPV6_MMTU for this gif(4) tunnel.
- 1
  Fragment by outer interface's MTU for this gif(4) tunnel.
- others
  undefined yet

See RFC4459 for more information and other solutions.


To generate a diff of this commit:
cvs rdiff -u -r1.149 -r1.150 src/sys/net/if_gif.c
cvs rdiff -u -r1.33 -r1.34 src/sys/net/if_gif.h
cvs rdiff -u -r1.96 -r1.97 src/sys/netinet6/in6.h
cvs rdiff -u -r1.94 -r1.95 src/sys/netinet6/in6_gif.c
cvs rdiff -u -r1.17 -r1.18 src/sys/netinet6/in6_gif.h

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



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

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 02:44:29 UTC 2019

Modified Files:
src/sys/arch/powerpc/include: fenv.h

Log Message:
do the ignore builtin dance for gcc-8


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

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



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

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 02:44:29 UTC 2019

Modified Files:
src/sys/arch/powerpc/include: fenv.h

Log Message:
do the ignore builtin dance for gcc-8


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/powerpc/include/fenv.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/powerpc/include/fenv.h
diff -u src/sys/arch/powerpc/include/fenv.h:1.5 src/sys/arch/powerpc/include/fenv.h:1.6
--- src/sys/arch/powerpc/include/fenv.h:1.5	Thu Apr 19 17:50:07 2018
+++ src/sys/arch/powerpc/include/fenv.h	Tue Oct 29 22:44:29 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: fenv.h,v 1.5 2018/04/19 21:50:07 christos Exp $	*/
+/*	$NetBSD: fenv.h,v 1.6 2019/10/30 02:44:29 christos Exp $	*/
 
 /*-
  * Copyright (c) 2004-2005 David Schultz 
@@ -143,6 +143,11 @@ union __fpscr {
 	} __bits;
 };
 
+#if __GNUC_PREREQ__(8, 0)
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wshadow"
+#endif
+
 __fenv_static __inline int
 feclearexcept(int __excepts)
 {
@@ -273,6 +278,10 @@ feupdateenv(const fenv_t *__envp)
 	return (0);
 }
 
+#if __GNUC_PREREQ__(8, 0)
+#pragma GCC diagnostic pop
+#endif
+
 #if defined(_NETBSD_SOURCE) || defined(_GNU_SOURCE)
 
 __fenv_static __inline int



CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 00:26:54 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
more hacks


To generate a diff of this commit:
cvs rdiff -u -r1.193 -r1.194 src/doc/HACKS

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

Modified files:

Index: src/doc/HACKS
diff -u src/doc/HACKS:1.193 src/doc/HACKS:1.194
--- src/doc/HACKS:1.193	Tue Oct 29 17:32:35 2019
+++ src/doc/HACKS	Tue Oct 29 20:26:54 2019
@@ -1,4 +1,4 @@
-# $NetBSD: HACKS,v 1.193 2019/10/29 21:32:35 christos Exp $
+# $NetBSD: HACKS,v 1.194 2019/10/30 00:26:54 christos Exp $
 #
 # This file is intended to document workarounds for currently unsolved
 # (mostly) compiler bugs.
@@ -919,6 +919,14 @@ descr	fails to compile, confused by char
 	strcpy(words[n - 1], words[n + 1]);
 kcah
 
+port	sh3
+hack	compile ddns.c in dhcpcd with no-stringop-overflow
+cdate	Tue Oct 29 20:25:59 EDT 2019
+who	christos
+file	/cvsroot/src/external/mpl/dhcp/bin/server/Makefile 1.2
+descr	fails to compile, confused by builtin_object_size in strcat(p, ".in..")
+kcah
+
 port	arm
 hack	avoid using labels in a 12-bit constant.
 who	matt



CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 00:26:54 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
more hacks


To generate a diff of this commit:
cvs rdiff -u -r1.193 -r1.194 src/doc/HACKS

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



CVS commit: src/external/mpl/dhcp/bin/server

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 00:25:00 UTC 2019

Modified Files:
src/external/mpl/dhcp/bin/server: Makefile

Log Message:
Looks like builtin_object_size does not work properly on sh3...


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/mpl/dhcp/bin/server/Makefile

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



CVS commit: src/external/mpl/dhcp/bin/server

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Wed Oct 30 00:25:00 UTC 2019

Modified Files:
src/external/mpl/dhcp/bin/server: Makefile

Log Message:
Looks like builtin_object_size does not work properly on sh3...


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/external/mpl/dhcp/bin/server/Makefile

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

Modified files:

Index: src/external/mpl/dhcp/bin/server/Makefile
diff -u src/external/mpl/dhcp/bin/server/Makefile:1.1 src/external/mpl/dhcp/bin/server/Makefile:1.2
--- src/external/mpl/dhcp/bin/server/Makefile:1.1	Sat Apr  7 18:31:37 2018
+++ src/external/mpl/dhcp/bin/server/Makefile	Tue Oct 29 20:25:00 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2018/04/07 22:31:37 christos Exp $
+# $NetBSD: Makefile,v 1.2 2019/10/30 00:25:00 christos Exp $
 
 .include 
 
@@ -15,6 +15,10 @@ FILESDIR= /usr/share/examples/dhcp
 FILES=	dhcpd.conf
 .endif
 
+.if !empty(MACHINE_ARCH:Msh3*)
+COPTS.ddns.c +=-Wno-stringop-overflow
+.endif
+
 COPTS.omapi.c +=	-Wno-stack-protector
 
 .include 



CVS commit: src/common/lib/libc/misc

2019-10-29 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Wed Oct 30 00:13:46 UTC 2019

Modified Files:
src/common/lib/libc/misc: ubsan.c

Log Message:
uubsan: Handle implicit_conversion


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/common/lib/libc/misc/ubsan.c

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

Modified files:

Index: src/common/lib/libc/misc/ubsan.c
diff -u src/common/lib/libc/misc/ubsan.c:1.7 src/common/lib/libc/misc/ubsan.c:1.8
--- src/common/lib/libc/misc/ubsan.c:1.7	Fri Oct  4 12:12:47 2019
+++ src/common/lib/libc/misc/ubsan.c	Wed Oct 30 00:13:46 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: ubsan.c,v 1.7 2019/10/04 12:12:47 mrg Exp $	*/
+/*	$NetBSD: ubsan.c,v 1.8 2019/10/30 00:13:46 kamil Exp $	*/
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -38,9 +38,9 @@
 
 #include 
 #if defined(_KERNEL)
-__KERNEL_RCSID(0, "$NetBSD: ubsan.c,v 1.7 2019/10/04 12:12:47 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ubsan.c,v 1.8 2019/10/30 00:13:46 kamil Exp $");
 #else
-__RCSID("$NetBSD: ubsan.c,v 1.7 2019/10/04 12:12:47 mrg Exp $");
+__RCSID("$NetBSD: ubsan.c,v 1.8 2019/10/30 00:13:46 kamil Exp $");
 #endif
 
 #if defined(_KERNEL)
@@ -238,6 +238,13 @@ struct CFloatCastOverflowData {
 	struct CTypeDescriptor *mToType;
 };
 
+struct CImplicitConversionData {
+	struct CSourceLocation mLocation;
+	struct CTypeDescriptor *mFromType;
+	struct CTypeDescriptor *mToType;
+	uint8_t mKind;
+};
+
 /* Local utility functions */
 static void Report(bool isFatal, const char *pFormat, ...) __printflike(2, 3);
 static bool isAlreadyReported(struct CSourceLocation *pLocation);
@@ -261,6 +268,7 @@ static void DeserializeNumber(char *szLo
 static const char *DeserializeTypeCheckKind(uint8_t hhuTypeCheckKind);
 static const char *DeserializeBuiltinCheckKind(uint8_t hhuBuiltinCheckKind);
 static const char *DeserializeCFICheckKind(uint8_t hhuCFICheckKind);
+static const char *DeserializeImplicitConversionCheckKind(uint8_t hhuImplicitConversionCheckKind);
 static bool isNegativeNumber(char *szLocation, struct CTypeDescriptor *pType, unsigned long ulNumber);
 static bool isShiftExponentTooLarge(char *szLocation, struct CTypeDescriptor *pType, unsigned long ulNumber, size_t zWidth);
 
@@ -313,6 +321,8 @@ void __ubsan_handle_type_mismatch_v1(str
 void __ubsan_handle_type_mismatch_v1_abort(struct CTypeMismatchData_v1 *pData, unsigned long ulPointer);
 void __ubsan_handle_vla_bound_not_positive(struct CVLABoundData *pData, unsigned long ulBound);
 void __ubsan_handle_vla_bound_not_positive_abort(struct CVLABoundData *pData, unsigned long ulBound);
+void __ubsan_handle_implicit_conversion(struct CImplicitConversionData *pData, unsigned long ulFrom, unsigned long ulTo);
+void __ubsan_handle_implicit_conversion_abort(struct CImplicitConversionData *pData, unsigned long ulFrom, unsigned long ulTo);
 void __ubsan_get_current_report_data(const char **ppOutIssueKind, const char **ppOutMessage, const char **ppOutFilename, uint32_t *pOutLine, uint32_t *pOutCol, char **ppOutMemoryAddr);
 
 static void HandleOverflow(bool isFatal, struct COverflowData *pData, unsigned long ulLHS, unsigned long ulRHS, const char *szOperation);
@@ -684,6 +694,26 @@ HandlePointerOverflow(bool isFatal, stru
 	   szLocation, ulBase, ulResult);
 }
 
+static void
+HandleImplicitConversion(bool isFatal, struct CImplicitConversionData *pData, unsigned long ulFrom, unsigned long ulTo)
+{
+	char szLocation[LOCATION_MAXLEN];
+	char szFrom[NUMBER_MAXLEN];
+	char szTo[NUMBER_MAXLEN];
+
+	ASSERT(pData);
+
+	if (isAlreadyReported(>mLocation))
+		return;
+
+	DeserializeLocation(szLocation, LOCATION_MAXLEN, >mLocation);
+	DeserializeNumber(szLocation, szFrom, NUMBER_MAXLEN, pData->mFromType, ulFrom);
+	DeserializeNumber(szLocation, szTo, NUMBER_MAXLEN, pData->mToType, ulTo);
+
+	Report(isFatal, "UBSan: Undefined Behavior in %s, %s from %s %zu-bit %s (%s) to %s changed the value to %s %zu-bit %s\n",
+	   szLocation, DeserializeImplicitConversionCheckKind(pData->mKind), szFrom, zDeserializeTypeWidth(pData->mFromType), ISSET(pData->mFromType->mTypeInfo, NUMBER_SIGNED_BIT) ? "signed" : "unsigned", pData->mFromType->mTypeName, pData->mToType->mTypeName, szTo, zDeserializeTypeWidth(pData->mToType), ISSET(pData->mToType->mTypeInfo, NUMBER_SIGNED_BIT) ? "signed" : "unsigned");
+}
+
 /* Definions of public symbols emitted by the instrumentation code */
 void
 __ubsan_handle_add_overflow(struct COverflowData *pData, unsigned long ulLHS, unsigned long ulRHS)
@@ -1095,6 +1125,23 @@ __ubsan_handle_vla_bound_not_positive_ab
 }
 
 void
+__ubsan_handle_implicit_conversion(struct CImplicitConversionData *pData, unsigned long ulFrom, unsigned long ulTo)
+{
+
+	ASSERT(pData);
+
+	HandleImplicitConversion(false, pData, ulFrom, ulTo);
+}
+
+void
+__ubsan_handle_implicit_conversion_abort(struct CImplicitConversionData *pData, unsigned long ulFrom, unsigned long ulTo)
+{
+	ASSERT(pData);
+
+	

CVS commit: src/common/lib/libc/misc

2019-10-29 Thread Kamil Rytarowski
Module Name:src
Committed By:   kamil
Date:   Wed Oct 30 00:13:46 UTC 2019

Modified Files:
src/common/lib/libc/misc: ubsan.c

Log Message:
uubsan: Handle implicit_conversion


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/common/lib/libc/misc/ubsan.c

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



CVS commit: src/external/gpl3/gcc

2019-10-29 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Wed Oct 30 00:07:39 UTC 2019

Modified Files:
src/external/gpl3/gcc/lib/libstdc++-v3/arch/aarch64: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/arm: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/armeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earm: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmhf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmhfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv4: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv4eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6hf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6hfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7hf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7hfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/arm: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/armeb: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earm: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmeb: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhf: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv4: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv4eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6hf: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6hfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7hf: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7hfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/aarch64: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/arm: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/armeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earm: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmhf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmhfeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv4: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv4eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6hf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6hfeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7hf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7hfeb: config.h
Added Files:
src/external/gpl3/gcc/usr.bin/gcc/arch/arm: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/armeb: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earm: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmeb: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhf: arm-cpu-cdata.h
arm-cpu-data.h

CVS commit: src/external/gpl3/gcc

2019-10-29 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Wed Oct 30 00:07:39 UTC 2019

Modified Files:
src/external/gpl3/gcc/lib/libstdc++-v3/arch/aarch64: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/arm: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/armeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earm: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmhf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmhfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv4: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv4eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6hf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv6hfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7eb: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7hf: c++config.h
symver-config.h
src/external/gpl3/gcc/lib/libstdc++-v3/arch/earmv7hfeb: c++config.h
symver-config.h
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/arm: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/armeb: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earm: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmeb: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhf: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv4: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv4eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6hf: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv6hfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7: auto-host.h configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7eb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7hf: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmv7hfeb: auto-host.h
configargs.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/aarch64: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/arm: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/armeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earm: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmhf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmhfeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv4: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv4eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6hf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv6hfeb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7eb: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7hf: config.h
src/external/gpl3/gcc/usr.bin/libcpp/arch/earmv7hfeb: config.h
Added Files:
src/external/gpl3/gcc/usr.bin/gcc/arch/arm: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/armeb: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earm: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmeb: arm-cpu-cdata.h
arm-cpu-data.h
src/external/gpl3/gcc/usr.bin/gcc/arch/earmhf: arm-cpu-cdata.h
arm-cpu-data.h

CVS commit: src/tools/host-mkdep

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 23:33:06 UTC 2019

Modified Files:
src/tools/host-mkdep: host-mkdep.in

Log Message:
Don't escape ", GNU awk 5 warns about it.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/tools/host-mkdep/host-mkdep.in

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



CVS commit: src/tools/host-mkdep

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 23:33:06 UTC 2019

Modified Files:
src/tools/host-mkdep: host-mkdep.in

Log Message:
Don't escape ", GNU awk 5 warns about it.


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/tools/host-mkdep/host-mkdep.in

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

Modified files:

Index: src/tools/host-mkdep/host-mkdep.in
diff -u src/tools/host-mkdep/host-mkdep.in:1.31 src/tools/host-mkdep/host-mkdep.in:1.32
--- src/tools/host-mkdep/host-mkdep.in:1.31	Tue May 12 00:04:34 2015
+++ src/tools/host-mkdep/host-mkdep.in	Tue Oct 29 23:33:06 2019
@@ -1,6 +1,6 @@
 #!@BSHELL@ -
 #
-#	$NetBSD: host-mkdep.in,v 1.31 2015/05/12 00:04:34 christos Exp $
+#	$NetBSD: host-mkdep.in,v 1.32 2019/10/29 23:33:06 joerg Exp $
 #
 # Copyright (c) 1991, 1993
 #	The Regents of the University of California.  All rights reserved.
@@ -239,10 +239,10 @@ else
 		( (@CPP@ "$@" $f; echo $? >&3) | @AWK@ '
 			/^#/ {
 # Be as tolerant as possible.
-sub(/^#(line)? [ 0-9]*\"?/, "")
+sub(/^#(line)? [ 0-9]*"?/, "")
 sub(/^#(pragma).*/, "")
 sub(/^<.*/, "")
-sub(/\".*$/, "")
+sub(/".*$/, "")
 sub(/^\.\//, "")
 sub(/ [ 0-9]*$/, "")
 



CVS commit: src/sys/arch/evbarm/conf

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:21:53 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: GENERIC

Log Message:
Add OMAP3 support.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sys/arch/evbarm/conf/GENERIC

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/evbarm/conf/GENERIC
diff -u src/sys/arch/evbarm/conf/GENERIC:1.61 src/sys/arch/evbarm/conf/GENERIC:1.62
--- src/sys/arch/evbarm/conf/GENERIC:1.61	Tue Oct 29 10:54:10 2019
+++ src/sys/arch/evbarm/conf/GENERIC	Tue Oct 29 22:21:53 2019
@@ -1,5 +1,5 @@
 #
-#	$NetBSD: GENERIC,v 1.61 2019/10/29 10:54:10 jmcneill Exp $
+#	$NetBSD: GENERIC,v 1.62 2019/10/29 22:21:53 jmcneill Exp $
 #
 #	GENERIC ARM (aarch32) kernel
 #
@@ -62,6 +62,57 @@ makeoptions	DTS="
 	meson8b-mxq.dts
 	meson8b-odroidc1.dts
 
+	omap3-beagle-xm-ab.dts
+	omap3-beagle-xm.dts
+	omap3-beagle.dts
+	omap3-cm-t3517.dts
+	omap3-cm-t3530.dts
+	omap3-cm-t3730.dts
+	omap3-devkit8000-lcd43.dts
+	omap3-devkit8000-lcd70.dts
+	omap3-devkit8000.dts
+	omap3-evm-37xx.dts
+	omap3-evm.dts
+	omap3-gta04a3.dts
+	omap3-gta04a4.dts
+	omap3-gta04a5.dts
+	omap3-gta04a5one.dts
+	omap3-ha-lcd.dts
+	omap3-ha.dts
+	omap3-igep0020-rev-f.dts
+	omap3-igep0020.dts
+	omap3-igep0030-rev-g.dts
+	omap3-igep0030.dts
+	omap3-ldp.dts
+	omap3-lilly-dbb056.dts
+	omap3-n9.dts
+	omap3-n900.dts
+	omap3-n950.dts
+	omap3-overo-alto35.dts
+	omap3-overo-chestnut43.dts
+	omap3-overo-gallop43.dts
+	omap3-overo-palo35.dts
+	omap3-overo-palo43.dts
+	omap3-overo-storm-alto35.dts
+	omap3-overo-storm-chestnut43.dts
+	omap3-overo-storm-gallop43.dts
+	omap3-overo-storm-palo35.dts
+	omap3-overo-storm-palo43.dts
+	omap3-overo-storm-summit.dts
+	omap3-overo-storm-tobi.dts
+	omap3-overo-storm-tobiduo.dts
+	omap3-overo-summit.dts
+	omap3-overo-tobi.dts
+	omap3-overo-tobiduo.dts
+	omap3-pandora-1ghz.dts
+	omap3-pandora-600mhz.dts
+	omap3-sbc-t3517.dts
+	omap3-sbc-t3530.dts
+	omap3-sbc-t3730.dts
+	omap3-sniper.dts
+	omap3-thunder.dts
+	omap3-zoom3.dts
+
 	socfpga_cyclone5_de0_nano_soc.dts
 
 	sun4i-a10-a1000.dts
@@ -203,17 +254,13 @@ options 	CPU_CORTEXA8
 options 	CPU_CORTEXA9
 options 	CPU_CORTEXA15
 options 	CPU_CORTEXA17
-
 options 	CPU_CORTEXA53
 
-# Can't add SOC_BCM2835 until interrupt and register issues sorted out
-#options 	SOC_BCM2835
+options 	SOC_AM33XX
 options 	SOC_BCM2836
-
 options 	SOC_EXYNOS5422
-
 options 	SOC_MESON8B
-
+options 	SOC_OMAP3
 options 	SOC_SUN4I_A10
 options 	SOC_SUN5I_A13
 options 	SOC_SUN6I_A31
@@ -221,13 +268,8 @@ options 	SOC_SUN7I_A20
 options 	SOC_SUN8I_A83T
 options 	SOC_SUN8I_H3
 options 	SOC_SUN9I_A80
-
 options 	SOC_TEGRA124
-
-options 	SOC_AM33XX
-
 options 	SOC_VIRT
-
 options 	SOC_ZYNQ7000
 
 options 	MULTIPROCESSOR
@@ -246,6 +288,7 @@ options 	MSGBUFSIZE=32768
 # EARLYCONS is required for early init messages from VERBOSE_INIT_ARM.
 
 #options 	EARLYCONS=am33xx, CONSADDR=0x44e09000
+#options 	EARLYCONS=omap3, CONSADDR=0x4902
 
 # ODROID-C1
 #options 	EARLYCONS=meson, CONSADDR=0xc81004c0
@@ -301,6 +344,8 @@ exy5410clk* 	at fdt? pass 3		# Exynos541
 exy5422clk* 	at fdt? pass 3		# Exynos5422 clock controller
 meson8bclkc* 	at fdt? pass 2		# Amlogic Meson8b clock controller
 mesonresets* 	at fdt? pass 2		# Amlogic Meson misc. clock resets
+omap3cm*	at fdt? pass 1		# TI OMAP3 CM
+omap3prm*	at fdt? pass 1		# TI OMAP3 PRM
 sun4ia10ccu* 	at fdt? pass 2		# Allwinner A10/A20 CCU
 sun5ia13ccu* 	at fdt? pass 2		# Allwinner A13 CCU
 sun6ia31ccu* 	at fdt? pass 2		# Allwinner A31 CCU



CVS commit: src/sys/arch/evbarm/conf

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:21:53 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: GENERIC

Log Message:
Add OMAP3 support.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sys/arch/evbarm/conf/GENERIC

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



CVS commit: src/sys/arch/arm/ti

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:19:13 UTC 2019

Modified Files:
src/sys/arch/arm/ti: files.ti ti_com.c ti_dpll_clock.c ti_gpio.c
ti_iic.c ti_omapintc.c ti_omaptimer.c ti_prcm.c ti_prcm.h ti_rng.c
ti_sdhc.c
Added Files:
src/sys/arch/arm/ti: omap3_cm.c omap3_platform.c omap3_prm.c

Log Message:
Add support for TI OMAP3.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/ti/files.ti
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/ti/omap3_cm.c \
src/sys/arch/arm/ti/omap3_platform.c src/sys/arch/arm/ti/omap3_prm.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/ti/ti_com.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/ti/ti_dpll_clock.c \
src/sys/arch/arm/ti/ti_gpio.c src/sys/arch/arm/ti/ti_iic.c \
src/sys/arch/arm/ti/ti_omapintc.c src/sys/arch/arm/ti/ti_rng.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/ti/ti_omaptimer.c \
src/sys/arch/arm/ti/ti_prcm.c src/sys/arch/arm/ti/ti_prcm.h \
src/sys/arch/arm/ti/ti_sdhc.c

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



CVS commit: src/sys/arch/arm/dts

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:18:28 UTC 2019

Added Files:
src/sys/arch/arm/dts: omap3-beagle.dts

Log Message:
Set stdout-path on TI OMAP3 BeagleBoard


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/dts/omap3-beagle.dts

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



CVS commit: src/sys/arch/arm/dts

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:18:28 UTC 2019

Added Files:
src/sys/arch/arm/dts: omap3-beagle.dts

Log Message:
Set stdout-path on TI OMAP3 BeagleBoard


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/dts/omap3-beagle.dts

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

Added files:

Index: src/sys/arch/arm/dts/omap3-beagle.dts
diff -u /dev/null src/sys/arch/arm/dts/omap3-beagle.dts:1.1
--- /dev/null	Tue Oct 29 22:18:29 2019
+++ src/sys/arch/arm/dts/omap3-beagle.dts	Tue Oct 29 22:18:28 2019
@@ -0,0 +1,35 @@
+/* $NetBSD: omap3-beagle.dts,v 1.1 2019/10/29 22:18:28 jmcneill Exp $ */
+
+/*-
+ * Copyright (c) 2019 Jared McNeill 
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 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.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+
+#include_next "omap3-beagle.dts"
+
+/ {
+	chosen {
+		stdout-path = 
+	};
+};



CVS commit: src/sys/arch/arm/ti

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 22:19:13 UTC 2019

Modified Files:
src/sys/arch/arm/ti: files.ti ti_com.c ti_dpll_clock.c ti_gpio.c
ti_iic.c ti_omapintc.c ti_omaptimer.c ti_prcm.c ti_prcm.h ti_rng.c
ti_sdhc.c
Added Files:
src/sys/arch/arm/ti: omap3_cm.c omap3_platform.c omap3_prm.c

Log Message:
Add support for TI OMAP3.


To generate a diff of this commit:
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/ti/files.ti
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/ti/omap3_cm.c \
src/sys/arch/arm/ti/omap3_platform.c src/sys/arch/arm/ti/omap3_prm.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/ti/ti_com.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/ti/ti_dpll_clock.c \
src/sys/arch/arm/ti/ti_gpio.c src/sys/arch/arm/ti/ti_iic.c \
src/sys/arch/arm/ti/ti_omapintc.c src/sys/arch/arm/ti/ti_rng.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/ti/ti_omaptimer.c \
src/sys/arch/arm/ti/ti_prcm.c src/sys/arch/arm/ti/ti_prcm.h \
src/sys/arch/arm/ti/ti_sdhc.c

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/arm/ti/files.ti
diff -u src/sys/arch/arm/ti/files.ti:1.15 src/sys/arch/arm/ti/files.ti:1.16
--- src/sys/arch/arm/ti/files.ti:1.15	Tue Oct 29 10:54:10 2019
+++ src/sys/arch/arm/ti/files.ti	Tue Oct 29 22:19:13 2019
@@ -1,8 +1,9 @@
-#	$NetBSD: files.ti,v 1.15 2019/10/29 10:54:10 jmcneill Exp $
+#	$NetBSD: files.ti,v 1.16 2019/10/29 22:19:13 jmcneill Exp $
 #
 
 file	arch/arm/ti/ti_cpufreq.c	soc_ti
 file	arch/arm/ti/am3_platform.c	soc_am33xx
+file	arch/arm/ti/omap3_platform.c	soc_omap3
 
 # Interrupt controller
 device	omapintc: pic, pic_splfuncs
@@ -23,6 +24,16 @@ device	am3prcm { } : fdt, ti_prcm
 attach	am3prcm at fdt with am3_prcm
 file	arch/arm/ti/am3_prcm.c		am3_prcm
 
+# CM (OMAP3)
+device	omap3cm { } : fdt, ti_prcm
+attach	omap3cm at fdt with omap3_cm
+file	arch/arm/ti/omap3_cm.c		omap3_cm
+
+# PRM (OMAP3)
+device	omap3prm { } : fdt
+attach	omap3prm at fdt with omap3_prm
+file	arch/arm/ti/omap3_prm.c		omap3_prm
+
 # Clocks
 device	timuxclk
 attach	timuxclk at fdt with ti_mux_clock
@@ -88,3 +99,4 @@ file	arch/arm/ti/ti_rng.c		ti_rng
 # SOC parameters
 defflag	opt_soc.h			SOC_TI
 defflag	opt_soc.h			SOC_AM33XX: SOC_TI
+defflag	opt_soc.h			SOC_OMAP3: SOC_TI

Index: src/sys/arch/arm/ti/ti_com.c
diff -u src/sys/arch/arm/ti/ti_com.c:1.7 src/sys/arch/arm/ti/ti_com.c:1.8
--- src/sys/arch/arm/ti/ti_com.c:1.7	Sun Oct 27 12:14:51 2019
+++ src/sys/arch/arm/ti/ti_com.c	Tue Oct 29 22:19:13 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: ti_com.c,v 1.7 2019/10/27 12:14:51 jmcneill Exp $ */
+/* $NetBSD: ti_com.c,v 1.8 2019/10/29 22:19:13 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2017 Jared McNeill 
@@ -28,7 +28,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: ti_com.c,v 1.7 2019/10/27 12:14:51 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: ti_com.c,v 1.8 2019/10/29 22:19:13 jmcneill Exp $");
 
 #include 
 #include 
@@ -105,7 +105,7 @@ ti_com_attach(device_t parent, device_t 
 		return;
 	}
 
-	if (ti_prcm_enable_hwmod(OF_parent(phandle), 0) != 0) {
+	if (ti_prcm_enable_hwmod(phandle, 0) != 0) {
 		aprint_error(": couldn't enable module\n");
 		return;
 	}

Index: src/sys/arch/arm/ti/ti_dpll_clock.c
diff -u src/sys/arch/arm/ti/ti_dpll_clock.c:1.1 src/sys/arch/arm/ti/ti_dpll_clock.c:1.2
--- src/sys/arch/arm/ti/ti_dpll_clock.c:1.1	Mon Oct 28 21:16:47 2019
+++ src/sys/arch/arm/ti/ti_dpll_clock.c	Tue Oct 29 22:19:13 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: ti_dpll_clock.c,v 1.1 2019/10/28 21:16:47 jmcneill Exp $ */
+/* $NetBSD: ti_dpll_clock.c,v 1.2 2019/10/29 22:19:13 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ti_dpll_clock.c,v 1.1 2019/10/28 21:16:47 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ti_dpll_clock.c,v 1.2 2019/10/29 22:19:13 jmcneill Exp $");
 
 #include 
 #include 
@@ -39,24 +39,25 @@ __KERNEL_RCSID(0, "$NetBSD: ti_dpll_cloc
 
 #include 
 
-/* CM_IDLEST_DPLL_MPU */
-#define	ST_MN_BYPASS		__BIT(8)
-#define	ST_DPLL_CLK		__BIT(0)
-
-/* CM_CLKSEL_DPLL_MPU */
-#define	DPLL_BYP_CLKSEL		__BIT(23)
 #define	DPLL_MULT		__BITS(18,8)
 #define	DPLL_DIV		__BITS(6,0)
 
-/* CM_CLKMODE_DPLL_MPU */
-#define	DPLL_EN			__BITS(2,0)
-#define	 DPLL_EN_NM_BYPASS	4
-#define	 DPLL_EN_LOCK		7
-
-static const char * const compatible[] = {
-	"ti,am3-dpll-clock",
-	NULL
-};
+#define	AM3_ST_MN_BYPASS	__BIT(8)
+#define	AM3_ST_DPLL_CLK		__BIT(0)
+
+#define	AM3_DPLL_EN		__BITS(2,0)
+#define	 AM3_DPLL_EN_NM_BYPASS	4
+#define	 AM3_DPLL_EN_LOCK	7
+
+#define	OMAP3_ST_MPU_CLK	__BIT(0)
+
+#define	OMAP3_EN_MPU_DPLL	__BITS(2,0)
+#define	 OMAP3_EN_MPU_DPLL_BYPASS	5
+#define	 OMAP3_EN_MPU_DPLL_LOCK		7
+
+#define	OMAP3_CORE_DPLL_CLKOUT_DIV __BITS(31,27)
+#define	OMAP3_CORE_DPLL_MULT	__BITS(26,16)
+#define	OMAP3_CORE_DPLL_DIV	__BITS(14,8)
 
 static int	ti_dpll_clock_match(device_t, cfdata_t, void *);
 static void	

CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:32:35 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
sh3 now


To generate a diff of this commit:
cvs rdiff -u -r1.192 -r1.193 src/doc/HACKS

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



CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:32:35 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
sh3 now


To generate a diff of this commit:
cvs rdiff -u -r1.192 -r1.193 src/doc/HACKS

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

Modified files:

Index: src/doc/HACKS
diff -u src/doc/HACKS:1.192 src/doc/HACKS:1.193
--- src/doc/HACKS:1.192	Tue Oct 29 17:16:25 2019
+++ src/doc/HACKS	Tue Oct 29 17:32:35 2019
@@ -1,4 +1,4 @@
-# $NetBSD: HACKS,v 1.192 2019/10/29 21:16:25 christos Exp $
+# $NetBSD: HACKS,v 1.193 2019/10/29 21:32:35 christos Exp $
 #
 # This file is intended to document workarounds for currently unsolved
 # (mostly) compiler bugs.
@@ -910,6 +910,15 @@ file	/cvsroot/src/external/bsd/nvi/usr.b
 descr	":%! sort" core-dumps, tm is NULL but was not NULL on entry.
 kcah
 
+port	sh3
+hack	compile parse.c in battlestar with -Wno-restrict
+cdate	Mon Oct 28 14:39:35 EDT 2019
+who	christos
+file	/cvsroot/src/games/battlestar/Makefile 1.11
+descr	fails to compile, confused by char words[][];
+	strcpy(words[n - 1], words[n + 1]);
+kcah
+
 port	arm
 hack	avoid using labels in a 12-bit constant.
 who	matt



CVS commit: src/games/battlestar

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:30:42 UTC 2019

Modified Files:
src/games/battlestar: Makefile

Log Message:
Gcc-8 bug confusion with restrict on sh3


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/games/battlestar/Makefile

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

Modified files:

Index: src/games/battlestar/Makefile
diff -u src/games/battlestar/Makefile:1.10 src/games/battlestar/Makefile:1.11
--- src/games/battlestar/Makefile:1.10	Sat Feb  6 18:45:24 2010
+++ src/games/battlestar/Makefile	Tue Oct 29 17:30:42 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.10 2010/02/06 23:45:24 he Exp $
+#	$NetBSD: Makefile,v 1.11 2019/10/29 21:30:42 christos Exp $
 #	@(#)Makefile	8.1 (Berkeley) 5/31/93
 
 PROG=	battlestar
@@ -12,4 +12,8 @@ LDADD=	-lcurses -lterminfo
 HIDEGAME=hidegame
 SETGIDGAME=yes
 
+.if !empty(MACHINE_ARCH:Msh3*)
+COPTS.parse.c+=-Wno-restrict
+.endif
+
 .include 



CVS commit: src/games/battlestar

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:30:42 UTC 2019

Modified Files:
src/games/battlestar: Makefile

Log Message:
Gcc-8 bug confusion with restrict on sh3


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/games/battlestar/Makefile

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



CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:16:25 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
gcc lossage


To generate a diff of this commit:
cvs rdiff -u -r1.191 -r1.192 src/doc/HACKS

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

Modified files:

Index: src/doc/HACKS
diff -u src/doc/HACKS:1.191 src/doc/HACKS:1.192
--- src/doc/HACKS:1.191	Mon Oct 28 14:41:23 2019
+++ src/doc/HACKS	Tue Oct 29 17:16:25 2019
@@ -1,4 +1,4 @@
-# $NetBSD: HACKS,v 1.191 2019/10/28 18:41:23 christos Exp $
+# $NetBSD: HACKS,v 1.192 2019/10/29 21:16:25 christos Exp $
 #
 # This file is intended to document workarounds for currently unsolved
 # (mostly) compiler bugs.
@@ -902,6 +902,14 @@ file	/cvsroot/src/external/mit/xorg/lib/
 descr	gallium does not compile.
 kcah
 
+port	aarch64
+hack	compile ex_filter.c in vi with -O0
+cdate	Mon Oct 28 14:39:35 EDT 2019
+who	christos
+file	/cvsroot/src/external/bsd/nvi/usr.bin/nvi/Makefile 1.20
+descr	":%! sort" core-dumps, tm is NULL but was not NULL on entry.
+kcah
+
 port	arm
 hack	avoid using labels in a 12-bit constant.
 who	matt



CVS commit: src/doc

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:16:25 UTC 2019

Modified Files:
src/doc: HACKS

Log Message:
gcc lossage


To generate a diff of this commit:
cvs rdiff -u -r1.191 -r1.192 src/doc/HACKS

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



CVS commit: src/external/bsd/nvi/usr.bin/nvi

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:14:37 UTC 2019

Modified Files:
src/external/bsd/nvi/usr.bin/nvi: Makefile

Log Message:
PR/54656: Martin Husemann: gcc-8 miscompiles ex_filter.c even with -O1, make
it -O0. The tm argument gets passed in as non-null and it is non-null after
the command execution, but then becomes null and causes a null dereference.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/external/bsd/nvi/usr.bin/nvi/Makefile

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



CVS commit: src/external/bsd/nvi/usr.bin/nvi

2019-10-29 Thread Christos Zoulas
Module Name:src
Committed By:   christos
Date:   Tue Oct 29 21:14:37 UTC 2019

Modified Files:
src/external/bsd/nvi/usr.bin/nvi: Makefile

Log Message:
PR/54656: Martin Husemann: gcc-8 miscompiles ex_filter.c even with -O1, make
it -O0. The tm argument gets passed in as non-null and it is non-null after
the command execution, but then becomes null and causes a null dereference.


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/external/bsd/nvi/usr.bin/nvi/Makefile

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

Modified files:

Index: src/external/bsd/nvi/usr.bin/nvi/Makefile
diff -u src/external/bsd/nvi/usr.bin/nvi/Makefile:1.19 src/external/bsd/nvi/usr.bin/nvi/Makefile:1.20
--- src/external/bsd/nvi/usr.bin/nvi/Makefile:1.19	Wed Jul 24 04:37:59 2019
+++ src/external/bsd/nvi/usr.bin/nvi/Makefile	Tue Oct 29 17:14:37 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: Makefile,v 1.19 2019/07/24 08:37:59 rin Exp $
+#	$NetBSD: Makefile,v 1.20 2019/10/29 21:14:37 christos Exp $
 
 .include 
 
@@ -114,6 +114,10 @@ version.h:	../../Makefile.inc
 #	${_MKTARGET_CREATE}
 #	${TOOL_PERL} -n ${.ALLSRC} > ${.TARGET}
 
+.if ${MACHINE_ARCH} == "aarch64"
+COPTS.ex_filter.c+=-O0
+.endif
+
 
 .include "${.CURDIR}/../../Makefile.inc"
 



CVS commit: src/sys/arch/aarch64

2019-10-29 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Tue Oct 29 20:01:22 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: pmap.c
src/sys/arch/aarch64/include: pmap.h

Log Message:
Define PMAP_NEED_PROCWR, providing strategically placed i-cache
synchronization where just-changed memory is about to be executed.

Fixes SIGILLs seen when running Mono 6 on QEMU Cortex-A57.

ok ryo


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/sys/arch/aarch64/aarch64/pmap.c
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/aarch64/include/pmap.h

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



CVS commit: src/sys/arch/aarch64

2019-10-29 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Tue Oct 29 20:01:22 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: pmap.c
src/sys/arch/aarch64/include: pmap.h

Log Message:
Define PMAP_NEED_PROCWR, providing strategically placed i-cache
synchronization where just-changed memory is about to be executed.

Fixes SIGILLs seen when running Mono 6 on QEMU Cortex-A57.

ok ryo


To generate a diff of this commit:
cvs rdiff -u -r1.47 -r1.48 src/sys/arch/aarch64/aarch64/pmap.c
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/aarch64/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/aarch64/aarch64/pmap.c
diff -u src/sys/arch/aarch64/aarch64/pmap.c:1.47 src/sys/arch/aarch64/aarch64/pmap.c:1.48
--- src/sys/arch/aarch64/aarch64/pmap.c:1.47	Sun Sep 22 13:57:55 2019
+++ src/sys/arch/aarch64/aarch64/pmap.c	Tue Oct 29 20:01:22 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.47 2019/09/22 13:57:55 jmcneill Exp $	*/
+/*	$NetBSD: pmap.c,v 1.48 2019/10/29 20:01:22 maya Exp $	*/
 
 /*
  * Copyright (c) 2017 Ryo Shimizu 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.47 2019/09/22 13:57:55 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.48 2019/10/29 20:01:22 maya Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_ddb.h"
@@ -877,6 +877,22 @@ pmap_icache_sync_range(pmap_t pm, vaddr_
 	pm_unlock(pm);
 }
 
+/*
+ * Routine:	pmap_procwr
+ *
+ * Function:
+ *	Synchronize caches corresponding to [addr, addr+len) in p.
+ *
+ */
+void
+pmap_procwr(struct proc *p, vaddr_t va, int len)
+{
+
+	/* We only need to do anything if it is the current process. */
+	if (p == curproc)
+		cpu_icache_sync_range(va, len);
+}
+
 static pt_entry_t
 _pmap_pte_adjust_prot(pt_entry_t pte, vm_prot_t prot, vm_prot_t protmask,
 bool user)

Index: src/sys/arch/aarch64/include/pmap.h
diff -u src/sys/arch/aarch64/include/pmap.h:1.25 src/sys/arch/aarch64/include/pmap.h:1.26
--- src/sys/arch/aarch64/include/pmap.h:1.25	Mon Aug 12 10:28:04 2019
+++ src/sys/arch/aarch64/include/pmap.h	Tue Oct 29 20:01:22 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: pmap.h,v 1.25 2019/08/12 10:28:04 skrll Exp $ */
+/* $NetBSD: pmap.h,v 1.26 2019/10/29 20:01:22 maya Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -46,6 +46,7 @@
 
 #include 
 
+#define PMAP_NEED_PROCWR
 #define PMAP_GROWKERNEL
 #define PMAP_STEAL_MEMORY
 
@@ -272,6 +273,7 @@ aarch64_mmap_flags(paddr_t mdpgno)
 #define pmap_wired_count(pmap)		((pmap)->pm_stats.wired_count)
 #define pmap_resident_count(pmap)	((pmap)->pm_stats.resident_count)
 
+void	pmap_procwr(struct proc *, vaddr_t, int);
 bool	pmap_extract_coherency(pmap_t, vaddr_t, paddr_t *, bool *);
 void	pmap_icache_sync_range(pmap_t, vaddr_t, vaddr_t);
 



CVS commit: src/sys/dev/pci

2019-10-29 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Tue Oct 29 16:32:45 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs.h pcidevs_data.h

Log Message:
Regen.


To generate a diff of this commit:
cvs rdiff -u -r1.1376 -r1.1377 src/sys/dev/pci/pcidevs.h
cvs rdiff -u -r1.1375 -r1.1376 src/sys/dev/pci/pcidevs_data.h

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



CVS commit: src/sys/dev/pci

2019-10-29 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Tue Oct 29 16:32:45 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs.h pcidevs_data.h

Log Message:
Regen.


To generate a diff of this commit:
cvs rdiff -u -r1.1376 -r1.1377 src/sys/dev/pci/pcidevs.h
cvs rdiff -u -r1.1375 -r1.1376 src/sys/dev/pci/pcidevs_data.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/dev/pci/pcidevs.h
diff -u src/sys/dev/pci/pcidevs.h:1.1376 src/sys/dev/pci/pcidevs.h:1.1377
--- src/sys/dev/pci/pcidevs.h:1.1376	Sat Oct 12 07:38:28 2019
+++ src/sys/dev/pci/pcidevs.h	Tue Oct 29 16:32:44 2019
@@ -1,10 +1,10 @@
-/*	$NetBSD: pcidevs.h,v 1.1376 2019/10/12 07:38:28 skrll Exp $	*/
+/*	$NetBSD: pcidevs.h,v 1.1377 2019/10/29 16:32:44 msaitoh Exp $	*/
 
 /*
  * THIS FILE IS AUTOMATICALLY GENERATED.  DO NOT EDIT.
  *
  * generated from:
- *	NetBSD: pcidevs,v 1.1388 2019/10/12 06:46:42 skrll Exp
+ *	NetBSD: pcidevs,v 1.1389 2019/10/29 16:31:48 msaitoh Exp
  */
 
 /*
@@ -7038,6 +7038,7 @@
 #define	PCI_PRODUCT_REALTEK_RT8029	0x8029		/* 8029 Ethernet */
 #define	PCI_PRODUCT_REALTEK_RT8139D	0x8039		/* 8139D 10/100 Ethernet */
 #define	PCI_PRODUCT_REALTEK_RT8100	0x8100		/* 8100 10/100 Ethernet */
+#define	PCI_PRODUCT_REALTEK_RT8125	0x8125		/* 8129 10/100/1G/2.5G Ethernet */
 #define	PCI_PRODUCT_REALTEK_RT8129	0x8129		/* 8129 10/100 Ethernet */
 #define	PCI_PRODUCT_REALTEK_RT8101E	0x8136		/* 8100E/8101E/8102E 10/100 Ethernet */
 #define	PCI_PRODUCT_REALTEK_RT8138	0x8138		/* 8138 10/100 Ethernet */

Index: src/sys/dev/pci/pcidevs_data.h
diff -u src/sys/dev/pci/pcidevs_data.h:1.1375 src/sys/dev/pci/pcidevs_data.h:1.1376
--- src/sys/dev/pci/pcidevs_data.h:1.1375	Sat Oct 12 07:38:28 2019
+++ src/sys/dev/pci/pcidevs_data.h	Tue Oct 29 16:32:44 2019
@@ -1,10 +1,10 @@
-/*	$NetBSD: pcidevs_data.h,v 1.1375 2019/10/12 07:38:28 skrll Exp $	*/
+/*	$NetBSD: pcidevs_data.h,v 1.1376 2019/10/29 16:32:44 msaitoh Exp $	*/
 
 /*
  * THIS FILE IS AUTOMATICALLY GENERATED.  DO NOT EDIT.
  *
  * generated from:
- *	NetBSD: pcidevs,v 1.1388 2019/10/12 06:46:42 skrll Exp
+ *	NetBSD: pcidevs,v 1.1389 2019/10/29 16:31:48 msaitoh Exp
  */
 
 /*
@@ -12421,436 +12421,438 @@ static const uint16_t pci_products[] = {
 	32224, 5770, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8100, 
 	32230, 5770, 5668, 0,
+	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8125, 
+	32235, 32240, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8129, 
 	32235, 5770, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8101E, 
-	32240, 5770, 5668, 0,
+	32255, 5770, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8138, 
-	32258, 5770, 5668, 0,
+	32273, 5770, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8139, 
 	7550, 5770, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8169SC, 
-	32263, 5683, 5668, 0,
+	32278, 5683, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8168, 
-	32277, 5683, 5668, 0,
+	32292, 5683, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8169, 
-	32287, 5683, 5668, 0,
+	32302, 5683, 5668, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RTL8188CE, 
-	32297, 4759, 4534, 32307, 18633, 19245, 0,
+	32312, 4759, 4534, 32322, 18633, 19245, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RTL8192CE, 
-	32315, 4759, 4534, 32307, 18633, 19245, 0,
+	32330, 4759, 4534, 32322, 18633, 19245, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RTL8188EE, 
-	32325, 4759, 4534, 32307, 18633, 19245, 0,
+	32340, 4759, 4534, 32322, 18633, 19245, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8180, 
-	32335, 7637, 0,
+	32350, 7637, 0,
 	PCI_VENDOR_REALTEK, PCI_PRODUCT_REALTEK_RT8185, 
-	32340, 32345, 0,
+	32355, 32360, 0,
 	PCI_VENDOR_REDHAT, PCI_PRODUCT_REDHAT_PPB, 
-	32357, 8490, 0,
+	32372, 8490, 0,
 	PCI_VENDOR_REDHAT, PCI_PRODUCT_REDHAT_QXL, 
-	32362, 234, 0,
+	32377, 234, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_SH7780, 
-	32366, 615, 6406, 0,
+	32381, 615, 6406, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_SH7785, 
-	32373, 615, 6406, 0,
+	32388, 615, 6406, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_SH7757_PBI, 
-	32380, 8124, 32387, 32397, 0,
+	32395, 8124, 32402, 32412, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_SH7757_PPB, 
-	32380, 9263, 6514, 32403, 0,
+	32395, 9263, 6514, 32418, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_SH7757_PS, 
-	32380, 8124, 14085, 32409, 0,
+	32395, 8124, 14085, 32424, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_PD720201, 
-	32414, 6896, 8184, 6904, 6406, 0,
+	32429, 6896, 8184, 6904, 6406, 0,
 	PCI_VENDOR_RENESAS, PCI_PRODUCT_RENESAS_PD720202, 
-	32424, 6896, 8184, 6904, 6406, 0,
+	32439, 6896, 8184, 6904, 6406, 0,
 	PCI_VENDOR_RICOH, PCI_PRODUCT_RICOH_Rx5C465, 

CVS commit: src/sys/dev/pci

2019-10-29 Thread SAITOH Masanobu
Module Name:src
Committed By:   msaitoh
Date:   Tue Oct 29 16:31:48 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs

Log Message:
 Add Realtek RTL8125.


To generate a diff of this commit:
cvs rdiff -u -r1.1388 -r1.1389 src/sys/dev/pci/pcidevs

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

Modified files:

Index: src/sys/dev/pci/pcidevs
diff -u src/sys/dev/pci/pcidevs:1.1388 src/sys/dev/pci/pcidevs:1.1389
--- src/sys/dev/pci/pcidevs:1.1388	Sat Oct 12 06:46:42 2019
+++ src/sys/dev/pci/pcidevs	Tue Oct 29 16:31:48 2019
@@ -1,4 +1,4 @@
-$NetBSD: pcidevs,v 1.1388 2019/10/12 06:46:42 skrll Exp $
+$NetBSD: pcidevs,v 1.1389 2019/10/29 16:31:48 msaitoh Exp $
 
 /*
  * Copyright (c) 1995, 1996 Christopher G. Demetriou
@@ -7031,6 +7031,7 @@ product REALTEK RTL8411		0x5289	RTL8411 
 product REALTEK RT8029		0x8029	8029 Ethernet
 product REALTEK RT8139D		0x8039	8139D 10/100 Ethernet
 product REALTEK RT8100		0x8100	8100 10/100 Ethernet
+product REALTEK RT8125		0x8125	8129 10/100/1G/2.5G Ethernet
 product REALTEK RT8129		0x8129	8129 10/100 Ethernet
 product REALTEK RT8101E		0x8136	8100E/8101E/8102E 10/100 Ethernet
 product REALTEK RT8138		0x8138	8138 10/100 Ethernet



CVS commit: src/bin/ksh

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:19:59 UTC 2019

Modified Files:
src/bin/ksh: misc.c

Log Message:
Avoid arithmetics on strings.


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/bin/ksh/misc.c

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



CVS commit: src/bin/ksh

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:19:59 UTC 2019

Modified Files:
src/bin/ksh: misc.c

Log Message:
Avoid arithmetics on strings.


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/bin/ksh/misc.c

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

Modified files:

Index: src/bin/ksh/misc.c
diff -u src/bin/ksh/misc.c:1.24 src/bin/ksh/misc.c:1.25
--- src/bin/ksh/misc.c:1.24	Tue May  8 16:37:59 2018
+++ src/bin/ksh/misc.c	Tue Oct 29 16:19:59 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: misc.c,v 1.24 2018/05/08 16:37:59 kamil Exp $	*/
+/*	$NetBSD: misc.c,v 1.25 2019/10/29 16:19:59 joerg Exp $	*/
 
 /*
  * Miscellaneous functions
@@ -6,7 +6,7 @@
 #include 
 
 #ifndef lint
-__RCSID("$NetBSD: misc.c,v 1.24 2018/05/08 16:37:59 kamil Exp $");
+__RCSID("$NetBSD: misc.c,v 1.25 2019/10/29 16:19:59 joerg Exp $");
 #endif
 
 
@@ -1091,7 +1091,7 @@ print_value_quoted(s)
 	}
 	for (p = s; *p; p++) {
 		if (*p == '\'') {
-			shprintf("%s", "'\\'" + 1 - inquote);
+			shprintf("%s", &"'\\'"[1 - inquote]);
 			inquote = 0;
 		} else {
 			if (!inquote) {



CVS commit: src/sys/arch/arm

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:18:23 UTC 2019

Modified Files:
src/sys/arch/arm/arm32: cpuswitch.S
src/sys/arch/arm/include: armreg.h
src/sys/arch/arm/vfp: vfp_init.c

Log Message:
Explicitly annotate FPU requirements for LLVM MC.

When using GCC, this annotations change the global state, but there is
no push/pop functionality for .fpu to avoid this problem. The state is
local to each inline assembler block with LLVM MC.


To generate a diff of this commit:
cvs rdiff -u -r1.94 -r1.95 src/sys/arch/arm/arm32/cpuswitch.S
cvs rdiff -u -r1.128 -r1.129 src/sys/arch/arm/include/armreg.h
cvs rdiff -u -r1.63 -r1.64 src/sys/arch/arm/vfp/vfp_init.c

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/arm/arm32/cpuswitch.S
diff -u src/sys/arch/arm/arm32/cpuswitch.S:1.94 src/sys/arch/arm/arm32/cpuswitch.S:1.95
--- src/sys/arch/arm/arm32/cpuswitch.S:1.94	Fri Sep 13 06:30:10 2019
+++ src/sys/arch/arm/arm32/cpuswitch.S	Tue Oct 29 16:18:23 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpuswitch.S,v 1.94 2019/09/13 06:30:10 skrll Exp $	*/
+/*	$NetBSD: cpuswitch.S,v 1.95 2019/10/29 16:18:23 joerg Exp $	*/
 
 /*
  * Copyright 2003 Wasabi Systems, Inc.
@@ -87,10 +87,14 @@
 #include 
 #include 
 
-	RCSID("$NetBSD: cpuswitch.S,v 1.94 2019/09/13 06:30:10 skrll Exp $")
+	RCSID("$NetBSD: cpuswitch.S,v 1.95 2019/10/29 16:18:23 joerg Exp $")
 
 /* LINTSTUB: include  */
 
+#ifdef FPU_VFP
+	.fpu vfpv2
+#endif
+
 #undef IRQdisable
 #undef IRQenable
 

Index: src/sys/arch/arm/include/armreg.h
diff -u src/sys/arch/arm/include/armreg.h:1.128 src/sys/arch/arm/include/armreg.h:1.129
--- src/sys/arch/arm/include/armreg.h:1.128	Mon Aug 12 23:31:48 2019
+++ src/sys/arch/arm/include/armreg.h	Tue Oct 29 16:18:23 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: armreg.h,v 1.128 2019/08/12 23:31:48 jmcneill Exp $	*/
+/*	$NetBSD: armreg.h,v 1.129 2019/10/29 16:18:23 joerg Exp $	*/
 
 /*
  * Copyright (c) 1998, 2001 Ben Harris
@@ -745,17 +745,17 @@ static inline void armreg_##name##_write
 }
 
 /* cp10 registers */
-ARMREG_READ_INLINE2(fpsid, "vmrs\t%0, fpsid") /* VFP System ID */
-ARMREG_READ_INLINE2(fpscr, "vmrs\t%0, fpscr") /* VFP Status/Control Register */
-ARMREG_WRITE_INLINE2(fpscr, "vmsr\tfpscr, %0") /* VFP Status/Control Register */
-ARMREG_READ_INLINE2(mvfr1, "vmrs\t%0, mvfr1") /* Media and VFP Feature Register 1 */
-ARMREG_READ_INLINE2(mvfr0, "vmrs\t%0, mvfr0") /* Media and VFP Feature Register 0 */
-ARMREG_READ_INLINE2(fpexc, "vmrs\t%0, fpexc") /* VFP Exception Register */
-ARMREG_WRITE_INLINE2(fpexc, "vmsr\tfpexc, %0") /* VFP Exception Register */
-ARMREG_READ_INLINE2(fpinst, "fmrx\t%0, fpinst") /* VFP Exception Instruction */
-ARMREG_WRITE_INLINE2(fpinst, "fmxr\tfpinst, %0") /* VFP Exception Instruction */
-ARMREG_READ_INLINE2(fpinst2, "fmrx\t%0, fpinst2") /* VFP Exception Instruction 2 */
-ARMREG_WRITE_INLINE2(fpinst2, "fmxr\tfpinst2, %0") /* VFP Exception Instruction 2 */
+ARMREG_READ_INLINE2(fpsid, ".fpu vfp\n vmrs\t%0, fpsid") /* VFP System ID */
+ARMREG_READ_INLINE2(fpscr, ".fpu vfp\n vmrs\t%0, fpscr") /* VFP Status/Control Register */
+ARMREG_WRITE_INLINE2(fpscr, ".fpu vfp\n vmsr\tfpscr, %0") /* VFP Status/Control Register */
+ARMREG_READ_INLINE2(mvfr1, ".fpu vfp\n vmrs\t%0, mvfr1") /* Media and VFP Feature Register 1 */
+ARMREG_READ_INLINE2(mvfr0, ".fpu vfp\n vmrs\t%0, mvfr0") /* Media and VFP Feature Register 0 */
+ARMREG_READ_INLINE2(fpexc, ".fpu vfp\n vmrs\t%0, fpexc") /* VFP Exception Register */
+ARMREG_WRITE_INLINE2(fpexc, ".fpu vfp\n vmsr\tfpexc, %0") /* VFP Exception Register */
+ARMREG_READ_INLINE2(fpinst, ".fpu vfp\n fmrx\t%0, fpinst") /* VFP Exception Instruction */
+ARMREG_WRITE_INLINE2(fpinst, ".fpu vfp\n vmsr\tfpinst, %0") /* VFP Exception Instruction */
+ARMREG_READ_INLINE2(fpinst2, ".fpu vfp\n fmrx\t%0, fpinst2") /* VFP Exception Instruction 2 */
+ARMREG_WRITE_INLINE2(fpinst2, ".fpu vfp\n fmxr\tfpinst2, %0") /* VFP Exception Instruction 2 */
 
 /* cp15 c0 registers */
 ARMREG_READ_INLINE(midr, "p15,0,%0,c0,c0,0") /* Main ID Register */

Index: src/sys/arch/arm/vfp/vfp_init.c
diff -u src/sys/arch/arm/vfp/vfp_init.c:1.63 src/sys/arch/arm/vfp/vfp_init.c:1.64
--- src/sys/arch/arm/vfp/vfp_init.c:1.63	Sat Sep  7 19:42:42 2019
+++ src/sys/arch/arm/vfp/vfp_init.c	Tue Oct 29 16:18:23 2019
@@ -1,4 +1,4 @@
-/*  $NetBSD: vfp_init.c,v 1.63 2019/09/07 19:42:42 tnn Exp $ */
+/*  $NetBSD: vfp_init.c,v 1.64 2019/10/29 16:18:23 joerg Exp $ */
 
 /*
  * Copyright (c) 2008 ARM Ltd
@@ -32,7 +32,7 @@
 #include "opt_cputypes.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: vfp_init.c,v 1.63 2019/09/07 19:42:42 tnn Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vfp_init.c,v 1.64 2019/10/29 16:18:23 joerg Exp $");
 
 #include 
 #include 
@@ -63,7 +63,7 @@ static inline void
 load_vfpregs_lo(const uint64_t *p)
 {
 	SETFPU;
-	__asm __volatile("vldmia\t%0, {d0-d15}" :: "r" (p) : "memory");
+	__asm __volatile(".fpu 

CVS commit: src/sys/arch/arm

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:18:23 UTC 2019

Modified Files:
src/sys/arch/arm/arm32: cpuswitch.S
src/sys/arch/arm/include: armreg.h
src/sys/arch/arm/vfp: vfp_init.c

Log Message:
Explicitly annotate FPU requirements for LLVM MC.

When using GCC, this annotations change the global state, but there is
no push/pop functionality for .fpu to avoid this problem. The state is
local to each inline assembler block with LLVM MC.


To generate a diff of this commit:
cvs rdiff -u -r1.94 -r1.95 src/sys/arch/arm/arm32/cpuswitch.S
cvs rdiff -u -r1.128 -r1.129 src/sys/arch/arm/include/armreg.h
cvs rdiff -u -r1.63 -r1.64 src/sys/arch/arm/vfp/vfp_init.c

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



CVS commit: src/lib/libc/compiler_rt

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:08:50 UTC 2019

Modified Files:
src/lib/libc/compiler_rt: Makefile.inc

Log Message:
Always include soft-float compare and order logic in libc when using
compiler-rt.


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/lib/libc/compiler_rt/Makefile.inc

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



CVS commit: src/lib/libc/compiler_rt

2019-10-29 Thread Joerg Sonnenberger
Module Name:src
Committed By:   joerg
Date:   Tue Oct 29 16:08:50 UTC 2019

Modified Files:
src/lib/libc/compiler_rt: Makefile.inc

Log Message:
Always include soft-float compare and order logic in libc when using
compiler-rt.


To generate a diff of this commit:
cvs rdiff -u -r1.35 -r1.36 src/lib/libc/compiler_rt/Makefile.inc

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

Modified files:

Index: src/lib/libc/compiler_rt/Makefile.inc
diff -u src/lib/libc/compiler_rt/Makefile.inc:1.35 src/lib/libc/compiler_rt/Makefile.inc:1.36
--- src/lib/libc/compiler_rt/Makefile.inc:1.35	Sun Jul 23 09:50:54 2017
+++ src/lib/libc/compiler_rt/Makefile.inc	Tue Oct 29 16:08:50 2019
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.35 2017/07/23 09:50:54 martin Exp $
+# $NetBSD: Makefile.inc,v 1.36 2019/10/29 16:08:50 joerg Exp $
 
 COMPILER_RT_SRCDIR=	${NETBSDSRCDIR}/sys/external/bsd/compiler_rt/dist
 
@@ -144,6 +144,9 @@ GENERIC_SRCS+= \
 	floatuntidf.c \
 	floatuntisf.c \
 	floatuntixf.c
+.else
+GENERIC_SRCS+= \
+	comparetf2.c
 .endif
 
 # These have h/w instructions which are always used.



CVS commit: src/sys/arch/x86/x86

2019-10-29 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Oct 29 12:39:46 UTC 2019

Modified Files:
src/sys/arch/x86/x86: identcpu.c

Log Message:
Enable XSAVEOPT.


To generate a diff of this commit:
cvs rdiff -u -r1.97 -r1.98 src/sys/arch/x86/x86/identcpu.c

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



CVS commit: src/sys/arch/x86/x86

2019-10-29 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Oct 29 12:39:46 UTC 2019

Modified Files:
src/sys/arch/x86/x86: identcpu.c

Log Message:
Enable XSAVEOPT.


To generate a diff of this commit:
cvs rdiff -u -r1.97 -r1.98 src/sys/arch/x86/x86/identcpu.c

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/x86/x86/identcpu.c
diff -u src/sys/arch/x86/x86/identcpu.c:1.97 src/sys/arch/x86/x86/identcpu.c:1.98
--- src/sys/arch/x86/x86/identcpu.c:1.97	Mon Oct 21 10:09:24 2019
+++ src/sys/arch/x86/x86/identcpu.c	Tue Oct 29 12:39:46 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: identcpu.c,v 1.97 2019/10/21 10:09:24 maxv Exp $	*/
+/*	$NetBSD: identcpu.c,v 1.98 2019/10/29 12:39:46 maxv Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: identcpu.c,v 1.97 2019/10/21 10:09:24 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: identcpu.c,v 1.98 2019/10/29 12:39:46 maxv Exp $");
 
 #include "opt_xen.h"
 
@@ -804,11 +804,9 @@ cpu_probe_fpu(struct cpu_info *ci)
 
 	x86_fpu_save = FPU_SAVE_XSAVE;
 
-#if 0 /* XXX PR 52966 */
 	x86_cpuid2(0xd, 1, descs);
 	if (descs[0] & CPUID_PES1_XSAVEOPT)
 		x86_fpu_save = FPU_SAVE_XSAVEOPT;
-#endif
 
 	/* Get features and maximum size of the save area */
 	x86_cpuid(0xd, descs);



CVS commit: src/sys/arch

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 10:54:10 UTC 2019

Modified Files:
src/sys/arch/arm/ti: files.ti ti_cpufreq.c ti_iicreg.h
src/sys/arch/evbarm/conf: GENERIC
Added Files:
src/sys/arch/arm/ti: am3_platform.c
Removed Files:
src/sys/arch/arm/ti: ti_platform.c ti_platform.h

Log Message:
Rename SOC_TI_AM335X to SOC_AM33XX and rename ti_platform.c to
am3_platform.c


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/ti/am3_platform.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/ti/files.ti
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/ti/ti_cpufreq.c \
src/sys/arch/arm/ti/ti_iicreg.h
cvs rdiff -u -r1.9 -r0 src/sys/arch/arm/ti/ti_platform.c
cvs rdiff -u -r1.1 -r0 src/sys/arch/arm/ti/ti_platform.h
cvs rdiff -u -r1.60 -r1.61 src/sys/arch/evbarm/conf/GENERIC

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/arm/ti/files.ti
diff -u src/sys/arch/arm/ti/files.ti:1.14 src/sys/arch/arm/ti/files.ti:1.15
--- src/sys/arch/arm/ti/files.ti:1.14	Mon Oct 28 23:57:59 2019
+++ src/sys/arch/arm/ti/files.ti	Tue Oct 29 10:54:10 2019
@@ -1,8 +1,8 @@
-#	$NetBSD: files.ti,v 1.14 2019/10/28 23:57:59 jmcneill Exp $
+#	$NetBSD: files.ti,v 1.15 2019/10/29 10:54:10 jmcneill Exp $
 #
 
-file	arch/arm/ti/ti_platform.c	soc_ti
 file	arch/arm/ti/ti_cpufreq.c	soc_ti
+file	arch/arm/ti/am3_platform.c	soc_am33xx
 
 # Interrupt controller
 device	omapintc: pic, pic_splfuncs
@@ -87,4 +87,4 @@ file	arch/arm/ti/ti_rng.c		ti_rng
 
 # SOC parameters
 defflag	opt_soc.h			SOC_TI
-defflag	opt_soc.h			SOC_TI_AM335X: SOC_TI
+defflag	opt_soc.h			SOC_AM33XX: SOC_TI

Index: src/sys/arch/arm/ti/ti_cpufreq.c
diff -u src/sys/arch/arm/ti/ti_cpufreq.c:1.1 src/sys/arch/arm/ti/ti_cpufreq.c:1.2
--- src/sys/arch/arm/ti/ti_cpufreq.c:1.1	Mon Oct 28 21:16:47 2019
+++ src/sys/arch/arm/ti/ti_cpufreq.c	Tue Oct 29 10:54:10 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: ti_cpufreq.c,v 1.1 2019/10/28 21:16:47 jmcneill Exp $ */
+/* $NetBSD: ti_cpufreq.c,v 1.2 2019/10/29 10:54:10 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared McNeill 
@@ -29,7 +29,7 @@
 #include "opt_soc.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: ti_cpufreq.c,v 1.1 2019/10/28 21:16:47 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ti_cpufreq.c,v 1.2 2019/10/29 10:54:10 jmcneill Exp $");
 
 #include 
 #include 
@@ -44,7 +44,7 @@ static bool		ti_opp_probed = false;
 static bool		(*ti_opp_supportedfn)(const int, const int);
 static struct syscon	*ti_opp_syscon;
 
-#ifdef SOC_TI_AM335X
+#ifdef SOC_AM33XX
 
 #define	AM33XX_REV_OFFSET	0x0600
 #define	AM33XX_REV_MASK		0xf000
@@ -93,7 +93,7 @@ ti_opp_probe(const int opp_table)
 
 	ti_opp_syscon = fdtbus_syscon_acquire(opp_table, "syscon");
 
-#ifdef SOC_TI_AM335X
+#ifdef SOC_AM33XX
 	if (ti_opp_syscon && of_match_compatible(OF_finddevice("/"), am33xx_compatible))
 		ti_opp_supportedfn = am33xx_opp_supported;
 #endif
Index: src/sys/arch/arm/ti/ti_iicreg.h
diff -u src/sys/arch/arm/ti/ti_iicreg.h:1.1 src/sys/arch/arm/ti/ti_iicreg.h:1.2
--- src/sys/arch/arm/ti/ti_iicreg.h:1.1	Sun Oct 27 19:11:07 2019
+++ src/sys/arch/arm/ti/ti_iicreg.h	Tue Oct 29 10:54:10 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: ti_iicreg.h,v 1.1 2019/10/27 19:11:07 jmcneill Exp $	*/
+/*	$NetBSD: ti_iicreg.h,v 1.2 2019/10/29 10:54:10 jmcneill Exp $	*/
 
 /*
  * Copyright (c) 2013 Manuel Bouyer.  All rights reserved.
@@ -134,10 +134,4 @@
 #define		I2C_ACTOA_OA1_ACT		0x0002
 #define		I2C_ACTOA_OA0_ACT		0x0001
 
-#if defined(TI_AM335X)
-#define	OMAP2_I2C0_BASE	0x44E0B000
-#define	OMAP2_I2C1_BASE	0x4802A000
-#define	OMAP2_I2C2_BASE	0x4819C000
-#endif /* TI_AM335X */
-
 #endif /* _OMAP2IICREG_H */

Index: src/sys/arch/evbarm/conf/GENERIC
diff -u src/sys/arch/evbarm/conf/GENERIC:1.60 src/sys/arch/evbarm/conf/GENERIC:1.61
--- src/sys/arch/evbarm/conf/GENERIC:1.60	Mon Oct 28 23:58:18 2019
+++ src/sys/arch/evbarm/conf/GENERIC	Tue Oct 29 10:54:10 2019
@@ -1,5 +1,5 @@
 #
-#	$NetBSD: GENERIC,v 1.60 2019/10/28 23:58:18 jmcneill Exp $
+#	$NetBSD: GENERIC,v 1.61 2019/10/29 10:54:10 jmcneill Exp $
 #
 #	GENERIC ARM (aarch32) kernel
 #
@@ -224,7 +224,7 @@ options 	SOC_SUN9I_A80
 
 options 	SOC_TEGRA124
 
-options 	SOC_TI_AM335X
+options 	SOC_AM33XX
 
 options 	SOC_VIRT
 

Added files:

Index: src/sys/arch/arm/ti/am3_platform.c
diff -u /dev/null src/sys/arch/arm/ti/am3_platform.c:1.1
--- /dev/null	Tue Oct 29 10:54:10 2019
+++ src/sys/arch/arm/ti/am3_platform.c	Tue Oct 29 10:54:10 2019
@@ -0,0 +1,150 @@
+/* $NetBSD: am3_platform.c,v 1.1 2019/10/29 10:54:10 jmcneill Exp $ */
+
+#include "opt_console.h"
+
+#include 
+__KERNEL_RCSID(0, "$NetBSD: am3_platform.c,v 1.1 2019/10/29 10:54:10 jmcneill Exp $");
+
+#include 
+
+#include 
+#include 
+
+#include 
+
+#include 
+
+#include 
+
+extern struct bus_space armv7_generic_bs_tag;
+extern struct bus_space armv7_generic_a4x_bs_tag;
+extern struct arm32_bus_dma_tag arm_generic_dma_tag;
+
+void 

CVS commit: src/sys/dev/fdt

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 10:52:22 UTC 2019

Modified Files:
src/sys/dev/fdt: cpufreq_dt.c

Log Message:
Add explicit FDT_OPP for operating-points-v2 so the link set won't be empty


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/dev/fdt/cpufreq_dt.c

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



CVS commit: src/sys/arch

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 10:54:10 UTC 2019

Modified Files:
src/sys/arch/arm/ti: files.ti ti_cpufreq.c ti_iicreg.h
src/sys/arch/evbarm/conf: GENERIC
Added Files:
src/sys/arch/arm/ti: am3_platform.c
Removed Files:
src/sys/arch/arm/ti: ti_platform.c ti_platform.h

Log Message:
Rename SOC_TI_AM335X to SOC_AM33XX and rename ti_platform.c to
am3_platform.c


To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 src/sys/arch/arm/ti/am3_platform.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/ti/files.ti
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/ti/ti_cpufreq.c \
src/sys/arch/arm/ti/ti_iicreg.h
cvs rdiff -u -r1.9 -r0 src/sys/arch/arm/ti/ti_platform.c
cvs rdiff -u -r1.1 -r0 src/sys/arch/arm/ti/ti_platform.h
cvs rdiff -u -r1.60 -r1.61 src/sys/arch/evbarm/conf/GENERIC

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



CVS commit: src/sys/dev/fdt

2019-10-29 Thread Jared D. McNeill
Module Name:src
Committed By:   jmcneill
Date:   Tue Oct 29 10:52:22 UTC 2019

Modified Files:
src/sys/dev/fdt: cpufreq_dt.c

Log Message:
Add explicit FDT_OPP for operating-points-v2 so the link set won't be empty


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/dev/fdt/cpufreq_dt.c

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

Modified files:

Index: src/sys/dev/fdt/cpufreq_dt.c
diff -u src/sys/dev/fdt/cpufreq_dt.c:1.12 src/sys/dev/fdt/cpufreq_dt.c:1.13
--- src/sys/dev/fdt/cpufreq_dt.c:1.12	Mon Oct 28 21:14:58 2019
+++ src/sys/dev/fdt/cpufreq_dt.c	Tue Oct 29 10:52:22 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: cpufreq_dt.c,v 1.12 2019/10/28 21:14:58 jmcneill Exp $ */
+/* $NetBSD: cpufreq_dt.c,v 1.13 2019/10/29 10:52:22 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2015-2017 Jared McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: cpufreq_dt.c,v 1.12 2019/10/28 21:14:58 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpufreq_dt.c,v 1.13 2019/10/29 10:52:22 jmcneill Exp $");
 
 #include 
 #include 
@@ -377,6 +377,14 @@ cpufreq_dt_lookup_opp_info(const int opp
 }
 
 static bool
+cpufreq_dt_opp_v2_supported(const int opp_table, const int opp_node)
+{
+	return true;
+}
+
+FDT_OPP(opp_v2, "operating-points-v2", cpufreq_dt_opp_v2_supported);
+
+static bool
 cpufreq_dt_node_supported(const struct fdt_opp_info *opp_info, const int opp_table, const int opp_node)
 {
 	if (!fdtbus_status_okay(opp_node))
@@ -387,7 +395,7 @@ cpufreq_dt_node_supported(const struct f
 	if (opp_info != NULL)
 		return opp_info->opp_supported(opp_table, opp_node);
 
-	return true;
+	return false;
 }
 
 static int



CVS commit: src/usr.sbin/nvmmctl

2019-10-29 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Oct 29 08:13:17 UTC 2019

Modified Files:
src/usr.sbin/nvmmctl: Makefile

Log Message:
Forgot to put nvmmctl in the "nvmm" group.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/usr.sbin/nvmmctl/Makefile

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

Modified files:

Index: src/usr.sbin/nvmmctl/Makefile
diff -u src/usr.sbin/nvmmctl/Makefile:1.1 src/usr.sbin/nvmmctl/Makefile:1.2
--- src/usr.sbin/nvmmctl/Makefile:1.1	Mon Oct 28 13:04:18 2019
+++ src/usr.sbin/nvmmctl/Makefile	Tue Oct 29 08:13:16 2019
@@ -1,12 +1,16 @@
-#	$NetBSD: Makefile,v 1.1 2019/10/28 13:04:18 maxv Exp $
+#	$NetBSD: Makefile,v 1.2 2019/10/29 08:13:16 maxv Exp $
 
 .include 
 
 MAN=	nvmmctl.8
 
 .if (${MACHINE_ARCH} == "x86_64")
-PROG=	nvmmctl
-SRCS=	nvmmctl.c
+USE_FORT?=yes	# setgid
+PROG=nvmmctl
+SRCS=nvmmctl.c
+
+BINGRP=nvmm
+BINMODE=2555
 
 CPPFLAGS+=-D_KERNTYPES
 LDADD+=-lutil -lnvmm



CVS commit: src/usr.sbin/nvmmctl

2019-10-29 Thread Maxime Villard
Module Name:src
Committed By:   maxv
Date:   Tue Oct 29 08:13:17 UTC 2019

Modified Files:
src/usr.sbin/nvmmctl: Makefile

Log Message:
Forgot to put nvmmctl in the "nvmm" group.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/usr.sbin/nvmmctl/Makefile

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



CVS commit: src/external/gpl3

2019-10-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Tue Oct 29 07:57:29 UTC 2019

Modified Files:
src/external/gpl3/binutils.old/dist/ld/emulparams: hppanbsd.sh
src/external/gpl3/binutils/dist/ld/emulparams: hppanbsd.sh

Log Message:
G/C


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh

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



CVS commit: src/external/gpl3

2019-10-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Tue Oct 29 07:57:29 UTC 2019

Modified Files:
src/external/gpl3/binutils.old/dist/ld/emulparams: hppanbsd.sh
src/external/gpl3/binutils/dist/ld/emulparams: hppanbsd.sh

Log Message:
G/C


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh

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

Modified files:

Index: src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
diff -u src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.5 src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.6
--- src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.5	Sat Apr 14 15:49:45 2018
+++ src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh	Tue Oct 29 07:57:29 2019
@@ -1,6 +1,3 @@
-# If you change this file, please also look at files which source this one:
-# hppaobsd.sh
-
 . ${srcdir}/emulparams/hppalinux.sh
 
 OUTPUT_FORMAT="elf32-hppa-netbsd"

Index: src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh
diff -u src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.1.1.1 src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.2
--- src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.1.1.1	Tue Aug 18 10:16:42 2009
+++ src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh	Tue Oct 29 07:57:29 2019
@@ -1,6 +1,3 @@
-# If you change this file, please also look at files which source this one:
-# hppaobsd.sh
-
 . ${srcdir}/emulparams/hppalinux.sh
 
 OUTPUT_FORMAT="elf32-hppa-netbsd"