CVS commit: [netbsd-8] src/doc
Module Name:src Committed By: snj Date: Mon Feb 12 05:40:25 UTC 2018 Modified Files: src/doc [netbsd-8]: CHANGES-8.0 Log Message: 545 To generate a diff of this commit: cvs rdiff -u -r1.1.2.121 -r1.1.2.122 src/doc/CHANGES-8.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-8.0 diff -u src/doc/CHANGES-8.0:1.1.2.121 src/doc/CHANGES-8.0:1.1.2.122 --- src/doc/CHANGES-8.0:1.1.2.121 Mon Feb 12 00:57:48 2018 +++ src/doc/CHANGES-8.0 Mon Feb 12 05:40:25 2018 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-8.0,v 1.1.2.121 2018/02/12 00:57:48 snj Exp $ +# $NetBSD: CHANGES-8.0,v 1.1.2.122 2018/02/12 05:40:25 snj Exp $ A complete list of changes from the initial NetBSD 8.0 branch on 2017-06-04 until the 8.0 release: @@ -9620,3 +9620,14 @@ sys/rump/dev/lib/libucom/UCOM.ioconf 1. Fix device name: u3ginit -> umodeswitch [christos, ticket #544] +sbin/gpt/backup.c1.17-1.18 +sbin/gpt/biosboot.c1.29-1.30 +sbin/gpt/gpt.c 1.71-1.73 +sbin/gpt/gpt.h 1.36 +sbin/gpt/restore.c1.17 +sbin/gpt/show.c 1.40-1.41 +sys/dev/dkwedge/dkwedge_gpt.c 1.19-1.20 + + Fix termination of gpt labels. PR kern/52522. + [christos, ticket #545] +
CVS commit: [netbsd-8] src
Module Name:src Committed By: snj Date: Mon Feb 12 04:05:07 UTC 2018 Modified Files: src/sbin/gpt [netbsd-8]: backup.c biosboot.c gpt.c gpt.h restore.c show.c src/sys/dev/dkwedge [netbsd-8]: dkwedge_gpt.c Log Message: Pull up following revision(s) (requested by christos in ticket #545): sbin/gpt/backup.c: 1.17-1.18 sbin/gpt/biosboot.c: 1.29-1.30 sbin/gpt/gpt.c: 1.71-1.73 sbin/gpt/gpt.h: 1.36 sbin/gpt/restore.c: 1.17 sbin/gpt/show.c: 1.40-1.41 sys/dev/dkwedge/dkwedge_gpt.c: 1.19-1.20 PR/52522: Piotr Meyer: Don't NUL terminate the gpt label name. -- - make sure that the utf16 string is padded with 0's where needed. - since the utf16 string is not 0 terminated, pass the size of the string. -- use __arraycount -- PR/52522: ent_name is not necessarily 0 terminated, so check bounds. -- use arraycount. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.16.8.1 src/sbin/gpt/backup.c src/sbin/gpt/restore.c cvs rdiff -u -r1.27.4.1 -r1.27.4.2 src/sbin/gpt/biosboot.c cvs rdiff -u -r1.70 -r1.70.4.1 src/sbin/gpt/gpt.c cvs rdiff -u -r1.35 -r1.35.4.1 src/sbin/gpt/gpt.h cvs rdiff -u -r1.39 -r1.39.6.1 src/sbin/gpt/show.c cvs rdiff -u -r1.18 -r1.18.6.1 src/sys/dev/dkwedge/dkwedge_gpt.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/gpt/backup.c diff -u src/sbin/gpt/backup.c:1.16 src/sbin/gpt/backup.c:1.16.8.1 --- src/sbin/gpt/backup.c:1.16 Thu Dec 3 21:40:32 2015 +++ src/sbin/gpt/backup.c Mon Feb 12 04:05:07 2018 @@ -33,7 +33,7 @@ __FBSDID("$FreeBSD: src/sbin/gpt/show.c,v 1.14 2006/06/22 22:22:32 marcel Exp $"); #endif #ifdef __RCSID -__RCSID("$NetBSD: backup.c,v 1.16 2015/12/03 21:40:32 christos Exp $"); +__RCSID("$NetBSD: backup.c,v 1.16.8.1 2018/02/12 04:05:07 snj Exp $"); #endif #include @@ -231,7 +231,8 @@ store_tbl(gpt_t gpt, const map_t m, prop PROP_ERR(propnum); rc = prop_dictionary_set(gpt_dict, "attributes", propnum); PROP_ERR(rc); - utf16_to_utf8(ent->ent_name, utfbuf, sizeof(utfbuf)); + utf16_to_utf8(ent->ent_name, __arraycount(ent->ent_name), + utfbuf, __arraycount(utfbuf)); if (utfbuf[0] != '\0') { propstr = prop_string_create_cstring((char *)utfbuf); PROP_ERR(propstr); Index: src/sbin/gpt/restore.c diff -u src/sbin/gpt/restore.c:1.16 src/sbin/gpt/restore.c:1.16.8.1 --- src/sbin/gpt/restore.c:1.16 Thu Dec 3 02:02:43 2015 +++ src/sbin/gpt/restore.c Mon Feb 12 04:05:07 2018 @@ -33,7 +33,7 @@ __FBSDID("$FreeBSD: src/sbin/gpt/create.c,v 1.11 2005/08/31 01:47:19 marcel Exp $"); #endif #ifdef __RCSID -__RCSID("$NetBSD: restore.c,v 1.16 2015/12/03 02:02:43 christos Exp $"); +__RCSID("$NetBSD: restore.c,v 1.16.8.1 2018/02/12 04:05:07 snj Exp $"); #endif #include @@ -178,7 +178,7 @@ restore_ent(gpt_t gpt, prop_dictionary_t if (propstr != NULL) { s = prop_string_cstring_nocopy(propstr); utf8_to_utf16((const uint8_t *)s, ent.ent_name, - __arraycount(ent.ent_name)); + __arraycount(ent.ent_name)); } propnum = prop_dictionary_get(gpt_dict, "index"); PROP_ERR(propnum); Index: src/sbin/gpt/biosboot.c diff -u src/sbin/gpt/biosboot.c:1.27.4.1 src/sbin/gpt/biosboot.c:1.27.4.2 --- src/sbin/gpt/biosboot.c:1.27.4.1 Wed Jul 5 20:07:42 2017 +++ src/sbin/gpt/biosboot.c Mon Feb 12 04:05:07 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: biosboot.c,v 1.27.4.1 2017/07/05 20:07:42 snj Exp $ */ +/* $NetBSD: biosboot.c,v 1.27.4.2 2018/02/12 04:05:07 snj Exp $ */ /* * Copyright (c) 2009 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ #include #ifdef __RCSID -__RCSID("$NetBSD: biosboot.c,v 1.27.4.1 2017/07/05 20:07:42 snj Exp $"); +__RCSID("$NetBSD: biosboot.c,v 1.27.4.2 2018/02/12 04:05:07 snj Exp $"); #endif #include @@ -219,7 +219,9 @@ biosboot(gpt_t gpt, daddr_t start, uint6 break; if (label != NULL) { - utf16_to_utf8(ent->ent_name, utfbuf, sizeof(utfbuf)); + utf16_to_utf8(ent->ent_name, + __arraycount(ent->ent_name), utfbuf, + __arraycount(utfbuf)); if (strcmp((char *)label, (char *)utfbuf) == 0) break; } Index: src/sbin/gpt/gpt.c diff -u src/sbin/gpt/gpt.c:1.70 src/sbin/gpt/gpt.c:1.70.4.1 --- src/sbin/gpt/gpt.c:1.70 Thu Feb 16 03:32:17 2017 +++ src/sbin/gpt/gpt.c Mon Feb 12 04:05:07 2018 @@ -35,7 +35,7 @@ __FBSDID("$FreeBSD: src/sbin/gpt/gpt.c,v 1.16 2006/07/07 02:44:23 marcel Exp $"); #endif #ifdef __RCSID -__RCSID("$NetBSD: gpt.c,v 1.70 2017/02/16 03:32:17 christos Exp $"); +__RCSID("$NetBSD: gpt.c,v 1.70.4.1 2018/02/12 04:05:07 snj Exp $"); #endif #include @@ -121,16 +121,22 @@ crc32(const void *buf, size_t size) return crc ^ ~0U; } +/* + * Produce a NUL-terminated utf-8 string from the non-NUL-terminated + * utf16 string. + */ void -utf16_to_utf8(const uint16_t *s16, uint8_t *s8, size_t s8len) +utf16_to_utf8(const uint16_t *s16, size_t s16len, uint8_t *s8, size_t s8len) { - size_t s8idx, s16idx, s16len; +
CVS commit: src/crypto/external/bsd/openssl/dist/crypto/idea
Module Name:src Committed By: christos Date: Mon Feb 12 02:15:32 UTC 2018 Modified Files: src/crypto/external/bsd/openssl/dist/crypto/idea: i_skey.c Log Message: we need variables to be signed here. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 \ src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c diff -u src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c:1.5 src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c:1.6 --- src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c:1.5 Thu Feb 8 16:51:28 2018 +++ src/crypto/external/bsd/openssl/dist/crypto/idea/i_skey.c Sun Feb 11 21:15:31 2018 @@ -8,6 +8,7 @@ */ #include +#include #include "idea_lcl.h" static IDEA_INT inverse(unsigned int xin); @@ -83,7 +84,7 @@ void IDEA_set_decrypt_key(IDEA_KEY_SCHED /* taken directly from the 'paper' I'll have a look at it later */ static IDEA_INT inverse(unsigned int xin) { -IDEA_INT n1, n2, q, r, b1, b2, t; +int32_t n1, n2, q, r, b1, b2, t; if (xin == 0) b2 = 0;
CVS commit: [netbsd-8] src/doc
Module Name:src Committed By: snj Date: Mon Feb 12 00:57:48 UTC 2018 Modified Files: src/doc [netbsd-8]: CHANGES-8.0 Log Message: 543, 544 To generate a diff of this commit: cvs rdiff -u -r1.1.2.120 -r1.1.2.121 src/doc/CHANGES-8.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-8.0 diff -u src/doc/CHANGES-8.0:1.1.2.120 src/doc/CHANGES-8.0:1.1.2.121 --- src/doc/CHANGES-8.0:1.1.2.120 Sun Feb 11 21:56:20 2018 +++ src/doc/CHANGES-8.0 Mon Feb 12 00:57:48 2018 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-8.0,v 1.1.2.120 2018/02/11 21:56:20 snj Exp $ +# $NetBSD: CHANGES-8.0,v 1.1.2.121 2018/02/12 00:57:48 snj Exp $ A complete list of changes from the initial NetBSD 8.0 branch on 2017-06-04 until the 8.0 release: @@ -9610,3 +9610,13 @@ usr.sbin/ypserv/ypserv/ypserv_proc.c 1. returning stale request data to the client. PR/47615 [christos, ticket #542] +external/gpl2/xcvs/dist/src/rsh-client.c 1.3 + + Fix for CVE-2017-12836; (cvs command injection) from MirBSD. + [christos, ticket #543] + +sys/rump/dev/lib/libucom/UCOM.ioconf 1.6 + + Fix device name: u3ginit -> umodeswitch + [christos, ticket #544] +
CVS commit: [netbsd-8] src/sys/rump/dev/lib/libucom
Module Name:src Committed By: snj Date: Mon Feb 12 00:21:07 UTC 2018 Modified Files: src/sys/rump/dev/lib/libucom [netbsd-8]: UCOM.ioconf Log Message: Pull up following revision(s) (requested by christos in ticket #544): sys/rump/dev/lib/libucom/UCOM.ioconf: 1.6 should be umodeswitch! To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.5.52.1 src/sys/rump/dev/lib/libucom/UCOM.ioconf Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/rump/dev/lib/libucom/UCOM.ioconf diff -u src/sys/rump/dev/lib/libucom/UCOM.ioconf:1.5 src/sys/rump/dev/lib/libucom/UCOM.ioconf:1.5.52.1 --- src/sys/rump/dev/lib/libucom/UCOM.ioconf:1.5 Mon Aug 30 11:51:29 2010 +++ src/sys/rump/dev/lib/libucom/UCOM.ioconf Mon Feb 12 00:21:07 2018 @@ -1,4 +1,4 @@ -# $NetBSD: UCOM.ioconf,v 1.5 2010/08/30 11:51:29 pooka Exp $ +# $NetBSD: UCOM.ioconf,v 1.5.52.1 2018/02/12 00:21:07 snj Exp $ # ioconf ucom @@ -14,6 +14,6 @@ ucom* at uplcom? portno ? # USB 3G datacards u3g* at uhub? port ? -u3ginit* at uhub? port ? +umodeswitch* at uhub? port ? ucom* at u3g?
CVS commit: [netbsd-8] src/external/gpl2/xcvs/dist/src
Module Name:src Committed By: snj Date: Mon Feb 12 00:20:01 UTC 2018 Modified Files: src/external/gpl2/xcvs/dist/src [netbsd-8]: rsh-client.c Log Message: Pull up following revision(s) (requested by christos in ticket #543): external/gpl2/xcvs/dist/src/rsh-client.c: 1.3 Fix for CVE-2017-12836; (cvs command injection) from MirBSD. To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.2.8.1 src/external/gpl2/xcvs/dist/src/rsh-client.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/gpl2/xcvs/dist/src/rsh-client.c diff -u src/external/gpl2/xcvs/dist/src/rsh-client.c:1.2 src/external/gpl2/xcvs/dist/src/rsh-client.c:1.2.8.1 --- src/external/gpl2/xcvs/dist/src/rsh-client.c:1.2 Tue May 17 14:00:09 2016 +++ src/external/gpl2/xcvs/dist/src/rsh-client.c Mon Feb 12 00:20:01 2018 @@ -10,7 +10,7 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ #include -__RCSID("$NetBSD: rsh-client.c,v 1.2 2016/05/17 14:00:09 christos Exp $"); +__RCSID("$NetBSD: rsh-client.c,v 1.2.8.1 2018/02/12 00:20:01 snj Exp $"); #include @@ -55,11 +55,11 @@ start_rsh_server (cvsroot_t *root, struc char *cvs_server = (root->cvs_server != NULL ? root->cvs_server : getenv ("CVS_SERVER")); int i = 0; -/* This needs to fit "rsh", "-b", "-l", "USER", "host", +/* This needs to fit "rsh", "-b", "-l", "USER", "--", "host", "cmd (w/ args)", and NULL. We leave some room to grow. */ -char *rsh_argv[10]; +char *rsh_argv[16]; -if (!cvs_rsh) +if (!cvs_rsh || !*cvs_rsh) /* People sometimes suggest or assume that this should default to "remsh" on systems like HPUX in which that is the system-supplied name for the rsh program. However, that @@ -99,6 +99,9 @@ start_rsh_server (cvsroot_t *root, struc rsh_argv[i++] = root->username; } +/* Only non-option arguments from here. (CVE-2017-12836) */ +rsh_argv[i++] = "--"; + rsh_argv[i++] = root->hostname; rsh_argv[i++] = cvs_server; rsh_argv[i++] = "server"; @@ -159,7 +162,7 @@ start_rsh_server (cvsroot_t *root, struc command = Xasprintf ("%s server", cvs_server); { -char *argv[10]; +char *argv[16]; char **p = argv; *p++ = cvs_rsh; @@ -173,6 +176,8 @@ start_rsh_server (cvsroot_t *root, struc *p++ = root->username; } + *p++ = "--"; + *p++ = root->hostname; *p++ = command; *p++ = NULL;
CVS commit: [netbsd-8] src/doc
Module Name:src Committed By: snj Date: Sun Feb 11 21:56:20 UTC 2018 Modified Files: src/doc [netbsd-8]: CHANGES-8.0 Log Message: tickets 536, 537, 539, 541, 542 To generate a diff of this commit: cvs rdiff -u -r1.1.2.119 -r1.1.2.120 src/doc/CHANGES-8.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-8.0 diff -u src/doc/CHANGES-8.0:1.1.2.119 src/doc/CHANGES-8.0:1.1.2.120 --- src/doc/CHANGES-8.0:1.1.2.119 Sat Feb 10 04:13:26 2018 +++ src/doc/CHANGES-8.0 Sun Feb 11 21:56:20 2018 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-8.0,v 1.1.2.119 2018/02/10 04:13:26 snj Exp $ +# $NetBSD: CHANGES-8.0,v 1.1.2.120 2018/02/11 21:56:20 snj Exp $ A complete list of changes from the initial NetBSD 8.0 branch on 2017-06-04 until the 8.0 release: @@ -9539,3 +9539,74 @@ sys/dist/pf/net/pf.c1.77-1.78 - Fix a remotely-triggerable integer overflow. PR/44059. [maxv, ticket #540] +distrib/sets/lists/base/shl.mi 1.825 +distrib/sets/lists/comp/mi 1.2168-1.2169 +distrib/sets/lists/comp/shl.mi 1.310 +distrib/sets/lists/debug/mi 1.234 +distrib/sets/lists/debug/shl.mi 1.188 +distrib/sets/lists/man/mi 1.1570 +distrib/sets/lists/tests/mi 1.772 +etc/mtree/NetBSD.dist.tests 1.150 +share/man/man4/Makefile1.650 +share/man/man4/ipsec.41.42-1.43 +share/man/man4/ipsecif.4 1.1-1.5 +sys/arch/amd64/conf/ALL1.77 +sys/arch/amd64/conf/GENERIC 1.480 +sys/conf/files 1.1191 +sys/net/Makefile1.34 +sys/net/files.net1.14 +sys/net/if.c 1.404 +sys/net/if.h 1.248 +sys/net/if_gif.c1.135 +sys/net/if_ipsec.c1.1-1.3 +sys/net/if_ipsec.h1.1 +sys/net/if_l2tp.c1.16 +sys/net/if_types.h1.28 +sys/netinet/in.c1.214 +sys/netinet/in.h1.103 +sys/netinet/in_gif.c1.92 +sys/netinet/ip_var.h1.122 +sys/netinet6/in6.c1.257 +sys/netinet6/in6.h1.88 +sys/netinet6/in6_gif.c1.90 +sys/netinet6/ip6_var.h1.75 +sys/netipsec/Makefile1.6 +sys/netipsec/files.netipsec 1.13 +sys/netipsec/ipsec.h1.62 +sys/netipsec/ipsecif.c1.1 +sys/netipsec/ipsecif.h1.1 +sys/netipsec/key.c1.246-1.247 +sys/netipsec/key.h1.34 +sys/rump/net/Makefile.rumpnetcomp 1.20 +sys/rump/net/lib/libipsec/IPSEC.ioconf 1.1 +sys/rump/net/lib/libipsec/Makefile 1.1 +sys/rump/net/lib/libipsec/ipsec_component.c 1.1 +tests/net/Makefile1.34 +tests/net/if_ipsec/Makefile 1.1 +tests/net/if_ipsec/t_ipsec.sh 1.1-1.2 + + Add ipsec interface, which is used for route-based VPN. + See ipsecif(4). + [ozaki-r, ticket #536] + +sys/dev/sdmmc/sdmmc_mem.c 1.64 + + Fix uninitialized variable use. + [bouyer, ticket #537] + +sys/netinet/in.c1.217 + + Fix a panic on a kernel without ARP. + [ozaki-r, ticket #539] + +sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c 1.3 + + Add NVIDIA GT730 support. PR/53006. + [maya, ticket #541] + +usr.sbin/ypserv/ypserv/ypserv_proc.c 1.18 + + Always zero out the result structs in the svc procs to avoid + returning stale request data to the client. PR/47615 + [christos, ticket #542] +
CVS commit: [netbsd-8] src/usr.sbin/ypserv/ypserv
Module Name:src Committed By: snj Date: Sun Feb 11 21:52:54 UTC 2018 Modified Files: src/usr.sbin/ypserv/ypserv [netbsd-8]: ypserv_proc.c Log Message: Pull up following revision(s) (requested by christos in ticket #542): usr.sbin/ypserv/ypserv/ypserv_proc.c: 1.18 PR/47615: Dr. W. Stukenbrock: Always zero out the result structs in the svc procs to avoid returning stale request data to the client. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.17.8.1 src/usr.sbin/ypserv/ypserv/ypserv_proc.c 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/ypserv/ypserv/ypserv_proc.c diff -u src/usr.sbin/ypserv/ypserv/ypserv_proc.c:1.17 src/usr.sbin/ypserv/ypserv/ypserv_proc.c:1.17.8.1 --- src/usr.sbin/ypserv/ypserv/ypserv_proc.c:1.17 Fri Jul 17 15:58:01 2015 +++ src/usr.sbin/ypserv/ypserv/ypserv_proc.c Sun Feb 11 21:52:54 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: ypserv_proc.c,v 1.17 2015/07/17 15:58:01 christos Exp $ */ +/* $NetBSD: ypserv_proc.c,v 1.17.8.1 2018/02/11 21:52:54 snj Exp $ */ /* * Copyright (c) 1994 Mats O Jansson@@ -28,7 +28,7 @@ #include #ifndef lint -__RCSID("$NetBSD: ypserv_proc.c,v 1.17 2015/07/17 15:58:01 christos Exp $"); +__RCSID("$NetBSD: ypserv_proc.c,v 1.17.8.1 2018/02/11 21:52:54 snj Exp $"); #endif #include @@ -163,9 +163,10 @@ ypproc_match_2_svc(void *argp, struct sv "key %.*s", clientstr, TORF(secure), k->domain, k->map, k->keydat.dsize, k->keydat.dptr)); - if (secure && securecheck(caller)) + if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.status = YP_YPERR; - else + } else res = ypdb_get_record(k->domain, k->map, k->keydat, secure); return ((void *)); @@ -190,9 +191,10 @@ ypproc_first_2_svc(void *argp, struct sv "first_2: request from %.500s, secure %s, domain %s, map %s", clientstr, TORF(secure), k->domain, k->map)); - if (secure && securecheck(caller)) + if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.status = YP_YPERR; - else + } else res = ypdb_get_first(k->domain, k->map, FALSE); return ((void *)); @@ -218,9 +220,10 @@ ypproc_next_2_svc(void *argp, struct svc "key %.*s", clientstr, TORF(secure), k->domain, k->map, k->keydat.dsize, k->keydat.dptr)); - if (secure && securecheck(caller)) + if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.status = YP_YPERR; - else + } else res = ypdb_get_next(k->domain, k->map, k->keydat, FALSE); return ((void *)); @@ -326,6 +329,7 @@ ypproc_all_2_svc(void *argp, struct svc_ (void)memset(, 0, sizeof(res)); if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.ypresp_all_u.val.status = YP_YPERR; return (); } @@ -368,9 +372,10 @@ ypproc_master_2_svc(void *argp, struct s "master_2: request from %.500s, secure %s, domain %s, map %s", clientstr, TORF(secure), k->domain, k->map)); - if (secure && securecheck(caller)) + if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.status = YP_YPERR; - else + } else res = ypdb_get_master(k->domain, k->map); /* @@ -409,12 +414,15 @@ ypproc_order_2_svc(void *argp, struct sv "order_2: request from %.500s, secure %s, domain %s, map %s", clientstr, TORF(secure), k->domain, k->map)); - if (secure && securecheck(caller)) + if (secure && securecheck(caller)) { + memset(, 0, sizeof(res)); res.status = YP_YPERR; - else if (_yp_invalid_map(k->map)) + } else if (_yp_invalid_map(k->map)) { + memset(, 0, sizeof(res)); res.status = YP_NOMAP; - else + } else { res = ypdb_get_order(k->domain, k->map); + } return ((void *)); } @@ -446,7 +454,7 @@ ypproc_maplist_2_svc(void *argp, struct (void)snprintf(domain_path, sizeof(domain_path), "%s/%s", YP_DB_PATH, domain); - res.list = NULL; + memset(, 0, sizeof(res)); status = YP_TRUE; if ((stat(domain_path, ) != 0) || !S_ISDIR(finfo.st_mode)) {
CVS commit: [netbsd-8] src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device
Module Name:src Committed By: snj Date: Sun Feb 11 21:48:41 UTC 2018 Modified Files: src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device [netbsd-8]: nouveau_engine_device_nve0.c Log Message: Pull up following revision(s) (requested by maya in ticket #541): sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c: 1.3 PR/53006: stackfield: Please support NVIDIA GT730 to kernel To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.2.10.1 \ src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.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/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c diff -u src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.2 src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.2.10.1 --- src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.2 Sun Oct 18 15:42:00 2015 +++ src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c Sun Feb 11 21:48:41 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: nouveau_engine_device_nve0.c,v 1.2 2015/10/18 15:42:00 jmcneill Exp $ */ +/* $NetBSD: nouveau_engine_device_nve0.c,v 1.2.10.1 2018/02/11 21:48:41 snj Exp $ */ /* * Copyright 2012 Red Hat Inc. @@ -25,7 +25,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: nouveau_engine_device_nve0.c,v 1.2 2015/10/18 15:42:00 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: nouveau_engine_device_nve0.c,v 1.2.10.1 2018/02/11 21:48:41 snj Exp $"); #include #include @@ -213,6 +213,40 @@ nve0_identify(struct nouveau_device *dev #endif device->oclass[NVDEV_ENGINE_PERFMON] = _perfmon_oclass; break; + case 0x106: + device->cname = "GK208B"; + device->oclass[NVDEV_SUBDEV_VBIOS ] = _bios_oclass; + device->oclass[NVDEV_SUBDEV_GPIO ] = _gpio_oclass; + device->oclass[NVDEV_SUBDEV_I2C] = _i2c_oclass; + device->oclass[NVDEV_SUBDEV_CLOCK ] = _clock_oclass; + device->oclass[NVDEV_SUBDEV_THERM ] = _therm_oclass; + device->oclass[NVDEV_SUBDEV_MXM] = _mxm_oclass; + device->oclass[NVDEV_SUBDEV_DEVINIT] = nvc0_devinit_oclass; + device->oclass[NVDEV_SUBDEV_MC ] = nvc3_mc_oclass; + device->oclass[NVDEV_SUBDEV_BUS] = nvc0_bus_oclass; + device->oclass[NVDEV_SUBDEV_TIMER ] = _timer_oclass; + device->oclass[NVDEV_SUBDEV_FB ] = nve0_fb_oclass; + device->oclass[NVDEV_SUBDEV_LTCG ] = gf100_ltcg_oclass; + device->oclass[NVDEV_SUBDEV_IBUS ] = _ibus_oclass; + device->oclass[NVDEV_SUBDEV_INSTMEM] = nv50_instmem_oclass; + device->oclass[NVDEV_SUBDEV_VM ] = _vmmgr_oclass; + device->oclass[NVDEV_SUBDEV_BAR] = _bar_oclass; + device->oclass[NVDEV_SUBDEV_PWR] = _pwr_oclass; + device->oclass[NVDEV_SUBDEV_VOLT ] = _volt_oclass; + device->oclass[NVDEV_ENGINE_DMAOBJ ] = _dmaeng_oclass; + device->oclass[NVDEV_ENGINE_FIFO ] = nv108_fifo_oclass; + device->oclass[NVDEV_ENGINE_SW ] = nvc0_software_oclass; + device->oclass[NVDEV_ENGINE_GR ] = nv108_graph_oclass; + device->oclass[NVDEV_ENGINE_DISP ] = nvf0_disp_oclass; + device->oclass[NVDEV_ENGINE_COPY0 ] = _copy0_oclass; + device->oclass[NVDEV_ENGINE_COPY1 ] = _copy1_oclass; + device->oclass[NVDEV_ENGINE_COPY2 ] = _copy2_oclass; +#if 0 + device->oclass[NVDEV_ENGINE_BSP] = _bsp_oclass; + device->oclass[NVDEV_ENGINE_VP ] = _vp_oclass; + device->oclass[NVDEV_ENGINE_PPP] = _ppp_oclass; +#endif + break; case 0x108: device->cname = "GK208"; device->oclass[NVDEV_SUBDEV_VBIOS ] = _bios_oclass;
CVS commit: [netbsd-8] src/sys/netinet
Module Name:src Committed By: snj Date: Sun Feb 11 21:46:25 UTC 2018 Modified Files: src/sys/netinet [netbsd-8]: in.c Log Message: Pull up following revision(s) (requested by ozaki-r in ticket #539): sys/netinet/in.c: 1.217 Don't call lltable_purge_entries from in_if_down if ARP isn't enabled Reported by bouyer@ To generate a diff of this commit: cvs rdiff -u -r1.203.2.8 -r1.203.2.9 src/sys/netinet/in.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/netinet/in.c diff -u src/sys/netinet/in.c:1.203.2.8 src/sys/netinet/in.c:1.203.2.9 --- src/sys/netinet/in.c:1.203.2.8 Sun Feb 11 21:17:34 2018 +++ src/sys/netinet/in.c Sun Feb 11 21:46:25 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: in.c,v 1.203.2.8 2018/02/11 21:17:34 snj Exp $ */ +/* $NetBSD: in.c,v 1.203.2.9 2018/02/11 21:46:25 snj Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -91,7 +91,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: in.c,v 1.203.2.8 2018/02/11 21:17:34 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: in.c,v 1.203.2.9 2018/02/11 21:46:25 snj Exp $"); #include "arp.h" @@ -1539,7 +1539,9 @@ in_if_down(struct ifnet *ifp) { in_if_link_down(ifp); +#if NARP > 0 lltable_purge_entries(LLTABLE(ifp)); +#endif } void
CVS commit: [netbsd-8] src/sys/dev/sdmmc
Module Name:src Committed By: snj Date: Sun Feb 11 21:29:18 UTC 2018 Modified Files: src/sys/dev/sdmmc [netbsd-8]: sdmmc_mem.c Log Message: Pull up following revision(s) (requested by bouyer in ticket #537): sys/dev/sdmmc/sdmmc_mem.c: revision 1.64 Fix uninitialized variable use: if there is an error, or if we are using a SPI controller, sdmmc_mem_send_op_cond() doens't assign a value to *ocrp, but it is used unconditionally in sdmmc_mem_enable() to see if we can switch to low voltage. In sdmmc_mem_send_op_cond(), if the new ocr is not returned by the card for whatever reason, set *ocrp to the orig value. To generate a diff of this commit: cvs rdiff -u -r1.56.4.4 -r1.56.4.5 src/sys/dev/sdmmc/sdmmc_mem.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/sdmmc/sdmmc_mem.c diff -u src/sys/dev/sdmmc/sdmmc_mem.c:1.56.4.4 src/sys/dev/sdmmc/sdmmc_mem.c:1.56.4.5 --- src/sys/dev/sdmmc/sdmmc_mem.c:1.56.4.4 Fri Sep 1 09:59:10 2017 +++ src/sys/dev/sdmmc/sdmmc_mem.c Sun Feb 11 21:29:18 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: sdmmc_mem.c,v 1.56.4.4 2017/09/01 09:59:10 martin Exp $ */ +/* $NetBSD: sdmmc_mem.c,v 1.56.4.5 2018/02/11 21:29:18 snj Exp $ */ /* $OpenBSD: sdmmc_mem.c,v 1.10 2009/01/09 10:55:22 jsg Exp $ */ /* @@ -45,7 +45,7 @@ /* Routines for SD/MMC memory cards. */ #include -__KERNEL_RCSID(0, "$NetBSD: sdmmc_mem.c,v 1.56.4.4 2017/09/01 09:59:10 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sdmmc_mem.c,v 1.56.4.5 2018/02/11 21:29:18 snj Exp $"); #ifdef _KERNEL_OPT #include "opt_sdmmc.h" @@ -644,10 +644,14 @@ sdmmc_mem_send_op_cond(struct sdmmc_soft error = ETIMEDOUT; sdmmc_delay(1); } - if (error == 0 && - ocrp != NULL && - !ISSET(sc->sc_caps, SMC_CAPS_SPI_MODE)) - *ocrp = MMC_R3(cmd.c_resp); + if (ocrp != NULL) { + if (error == 0 && + !ISSET(sc->sc_caps, SMC_CAPS_SPI_MODE)) { + *ocrp = MMC_R3(cmd.c_resp); + } else { + *ocrp = ocr; + } + } DPRINTF(("%s: sdmmc_mem_send_op_cond: error=%d, ocr=%#x\n", SDMMCDEVNAME(sc), error, MMC_R3(cmd.c_resp))); return error;
CVS commit: src/libexec/ld.elf_so
Module Name:src Committed By: jakllsch Date: Sun Feb 11 18:58:45 UTC 2018 Modified Files: src/libexec/ld.elf_so: rtld.c Log Message: Wrap PowerPC #pragma goop in #if __GNUC_PREREQ__(6,0). Our older GCC warns/errors on it. To generate a diff of this commit: cvs rdiff -u -r1.189 -r1.190 src/libexec/ld.elf_so/rtld.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/libexec/ld.elf_so/rtld.c diff -u src/libexec/ld.elf_so/rtld.c:1.189 src/libexec/ld.elf_so/rtld.c:1.190 --- src/libexec/ld.elf_so/rtld.c:1.189 Wed Feb 7 06:17:45 2018 +++ src/libexec/ld.elf_so/rtld.c Sun Feb 11 18:58:44 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: rtld.c,v 1.189 2018/02/07 06:17:45 mrg Exp $ */ +/* $NetBSD: rtld.c,v 1.190 2018/02/11 18:58:44 jakllsch Exp $ */ /* * Copyright 1996 John D. Polstra. @@ -40,7 +40,7 @@ #include #ifndef lint -__RCSID("$NetBSD: rtld.c,v 1.189 2018/02/07 06:17:45 mrg Exp $"); +__RCSID("$NetBSD: rtld.c,v 1.190 2018/02/11 18:58:44 jakllsch Exp $"); #endif /* not lint */ #include @@ -1109,10 +1109,14 @@ _rtld_objmain_sym(const char *name) static __noinline void * hackish_return_address(void) { +#if __GNUC_PREREQ__(6,0) #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wframe-address" +#endif return __builtin_return_address(1); +#if __GNUC_PREREQ__(6,0) #pragma GCC diagnostic pop +#endif } #endif
CVS commit: src/distrib/sets/lists
Module Name:src Committed By: christos Date: Sun Feb 11 16:45:35 UTC 2018 Modified Files: src/distrib/sets/lists/comp: mi src/distrib/sets/lists/tests: mi Log Message: Add obsolete lines for the gcc-5 and openssl-1.0 lines for systems that have installed gcc-6 and openssl-1.1. Requested by wiz@ To generate a diff of this commit: cvs rdiff -u -r1.2179 -r1.2180 src/distrib/sets/lists/comp/mi cvs rdiff -u -r1.773 -r1.774 src/distrib/sets/lists/tests/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/comp/mi diff -u src/distrib/sets/lists/comp/mi:1.2179 src/distrib/sets/lists/comp/mi:1.2180 --- src/distrib/sets/lists/comp/mi:1.2179 Thu Feb 8 23:20:38 2018 +++ src/distrib/sets/lists/comp/mi Sun Feb 11 11:45:35 2018 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.2179 2018/02/09 04:20:38 christos Exp $ +# $NetBSD: mi,v 1.2180 2018/02/11 16:45:35 christos Exp $ # # Note: don't delete entries from here - mark them as "obsolete" instead. ./etc/mtree/set.compcomp-sys-root @@ -2001,13 +2001,73 @@ ./usr/include/gcc-4.5/omp.h comp-obsolete obsolete ./usr/include/gcc-4.8/mf-runtime.h comp-gcc-include obsolete ./usr/include/gcc-4.8/omp.h comp-gcc-include obsolete +./usr/include/gcc-5/adxintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/ammintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx2intrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512bwintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512cdintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512dqintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512erintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512fintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512ifmaintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512ifmavlintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512pfintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512vbmiintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512vbmivlintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512vlbwintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512vldqintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avx512vlintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/avxintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/bmi2intrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/bmiintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/bmmintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/clflushoptintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/clwbintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/cpuid.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/cross-stdarg.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/emmintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/f16cintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/fma4intrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/fmaintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/fxsrintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/ia32intrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/immintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/lwpintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/lzcntintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/mm3dnow.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/mm_malloc.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/mmintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/mwaitxintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/nmmintrin.h comp-obsolete gcc=6,obsolete ./usr/include/gcc-5/omp.h comp-gcc-include gcc=5 +./usr/include/gcc-5/omp.h comp-obsolete gcc=6,obsolete ./usr/include/gcc-5/openacc.h comp-gcc-include gcc=5 +./usr/include/gcc-5/openacc.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/pmmintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/popcntintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/prfchwintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/rdseedintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/rtmintrin.h comp-obsolete gcc=6,obsolete ./usr/include/gcc-5/sanitizer/allocator_interface.h comp-gcc-include gcc=5 ./usr/include/gcc-5/sanitizer/asan_interface.h comp-gcc-include gcc=5 ./usr/include/gcc-5/sanitizer/common_interface_defs.h comp-gcc-include gcc=5 ./usr/include/gcc-5/sanitizer/tsan_interface_atomic.h comp-gcc-include gcc=5 +./usr/include/gcc-5/shaintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/smmintrin.h comp-obsolete gcc=6,obsolete ./usr/include/gcc-5/stdatomic.h comp-gcc-include gcc=5,gcccmds +./usr/include/gcc-5/stdatomic.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/tbmintrin.h comp-obsolete gcc=6,obsolete +./usr/include/gcc-5/tgmath.h
CVS commit: src/external/gpl3/gcc/dist/gcc/cp
Module Name:src Committed By: christos Date: Sun Feb 11 15:56:25 UTC 2018 Modified Files: src/external/gpl3/gcc/dist/gcc/cp: decl.c Log Message: PR/53008: Henning Petersen: Fix missing brace inside comment. To generate a diff of this commit: cvs rdiff -u -r1.1.1.9 -r1.2 src/external/gpl3/gcc/dist/gcc/cp/decl.c 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/gcc/dist/gcc/cp/decl.c diff -u src/external/gpl3/gcc/dist/gcc/cp/decl.c:1.1.1.9 src/external/gpl3/gcc/dist/gcc/cp/decl.c:1.2 --- src/external/gpl3/gcc/dist/gcc/cp/decl.c:1.1.1.9 Thu Feb 1 20:59:43 2018 +++ src/external/gpl3/gcc/dist/gcc/cp/decl.c Sun Feb 11 10:56:25 2018 @@ -7455,6 +7455,7 @@ expand_static_init (tree decl, tree init } catch { if (!flag) __cxa_guard_abort (); } + } } Note that the `flag' variable is only set to 1 *after* the
CVS commit: src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device
Module Name:src Committed By: christos Date: Sun Feb 11 15:52:59 UTC 2018 Modified Files: src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device: nouveau_engine_device_nve0.c Log Message: PR/53006: stackfield: Please support NVIDIA GT730 to kernel To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 \ src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.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/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c diff -u src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.2 src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.3 --- src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c:1.2 Sun Oct 18 11:42:00 2015 +++ src/sys/external/bsd/drm2/dist/drm/nouveau/core/engine/device/nouveau_engine_device_nve0.c Sun Feb 11 10:52:59 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: nouveau_engine_device_nve0.c,v 1.2 2015/10/18 15:42:00 jmcneill Exp $ */ +/* $NetBSD: nouveau_engine_device_nve0.c,v 1.3 2018/02/11 15:52:59 christos Exp $ */ /* * Copyright 2012 Red Hat Inc. @@ -25,7 +25,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: nouveau_engine_device_nve0.c,v 1.2 2015/10/18 15:42:00 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: nouveau_engine_device_nve0.c,v 1.3 2018/02/11 15:52:59 christos Exp $"); #include #include @@ -213,6 +213,40 @@ nve0_identify(struct nouveau_device *dev #endif device->oclass[NVDEV_ENGINE_PERFMON] = _perfmon_oclass; break; + case 0x106: + device->cname = "GK208B"; + device->oclass[NVDEV_SUBDEV_VBIOS ] = _bios_oclass; + device->oclass[NVDEV_SUBDEV_GPIO ] = _gpio_oclass; + device->oclass[NVDEV_SUBDEV_I2C] = _i2c_oclass; + device->oclass[NVDEV_SUBDEV_CLOCK ] = _clock_oclass; + device->oclass[NVDEV_SUBDEV_THERM ] = _therm_oclass; + device->oclass[NVDEV_SUBDEV_MXM] = _mxm_oclass; + device->oclass[NVDEV_SUBDEV_DEVINIT] = nvc0_devinit_oclass; + device->oclass[NVDEV_SUBDEV_MC ] = nvc3_mc_oclass; + device->oclass[NVDEV_SUBDEV_BUS] = nvc0_bus_oclass; + device->oclass[NVDEV_SUBDEV_TIMER ] = _timer_oclass; + device->oclass[NVDEV_SUBDEV_FB ] = nve0_fb_oclass; + device->oclass[NVDEV_SUBDEV_LTCG ] = gf100_ltcg_oclass; + device->oclass[NVDEV_SUBDEV_IBUS ] = _ibus_oclass; + device->oclass[NVDEV_SUBDEV_INSTMEM] = nv50_instmem_oclass; + device->oclass[NVDEV_SUBDEV_VM ] = _vmmgr_oclass; + device->oclass[NVDEV_SUBDEV_BAR] = _bar_oclass; + device->oclass[NVDEV_SUBDEV_PWR] = _pwr_oclass; + device->oclass[NVDEV_SUBDEV_VOLT ] = _volt_oclass; + device->oclass[NVDEV_ENGINE_DMAOBJ ] = _dmaeng_oclass; + device->oclass[NVDEV_ENGINE_FIFO ] = nv108_fifo_oclass; + device->oclass[NVDEV_ENGINE_SW ] = nvc0_software_oclass; + device->oclass[NVDEV_ENGINE_GR ] = nv108_graph_oclass; + device->oclass[NVDEV_ENGINE_DISP ] = nvf0_disp_oclass; + device->oclass[NVDEV_ENGINE_COPY0 ] = _copy0_oclass; + device->oclass[NVDEV_ENGINE_COPY1 ] = _copy1_oclass; + device->oclass[NVDEV_ENGINE_COPY2 ] = _copy2_oclass; +#if 0 + device->oclass[NVDEV_ENGINE_BSP] = _bsp_oclass; + device->oclass[NVDEV_ENGINE_VP ] = _vp_oclass; + device->oclass[NVDEV_ENGINE_PPP] = _ppp_oclass; +#endif + break; case 0x108: device->cname = "GK208"; device->oclass[NVDEV_SUBDEV_VBIOS ] = _bios_oclass;
CVS commit: src/share/man/man9
Module Name:src Committed By: wiz Date: Sun Feb 11 14:17:24 UTC 2018 Modified Files: src/share/man/man9: pcmcia.9 Log Message: Add missing comma. To generate a diff of this commit: cvs rdiff -u -r1.21 -r1.22 src/share/man/man9/pcmcia.9 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man9/pcmcia.9 diff -u src/share/man/man9/pcmcia.9:1.21 src/share/man/man9/pcmcia.9:1.22 --- src/share/man/man9/pcmcia.9:1.21 Thu Feb 8 09:03:23 2018 +++ src/share/man/man9/pcmcia.9 Sun Feb 11 14:17:24 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: pcmcia.9,v 1.21 2018/02/08 09:03:23 dholland Exp $ +.\" $NetBSD: pcmcia.9,v 1.22 2018/02/11 14:17:24 wiz Exp $ .\" .\" Copyright (c) 2001 The NetBSD Foundation, Inc. .\" All rights reserved. @@ -31,7 +31,7 @@ .Dt PCMCIA 9 .Os .Sh NAME -.Nm PCMCIA +.Nm PCMCIA , .Nm pcmcia_function_init , .Nm pcmcia_function_enable , .Nm pcmcia_function_disable ,
CVS commit: src/share/man/man4
Module Name:src Committed By: wiz Date: Sun Feb 11 14:15:14 UTC 2018 Modified Files: src/share/man/man4: ahc.4 bluetooth.4 Log Message: Remove Tn. To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/share/man/man4/ahc.4 cvs rdiff -u -r1.21 -r1.22 src/share/man/man4/bluetooth.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/ahc.4 diff -u src/share/man/man4/ahc.4:1.35 src/share/man/man4/ahc.4:1.36 --- src/share/man/man4/ahc.4:1.35 Thu Feb 8 09:03:23 2018 +++ src/share/man/man4/ahc.4 Sun Feb 11 14:15:14 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: ahc.4,v 1.35 2018/02/08 09:03:23 dholland Exp $ +.\" $NetBSD: ahc.4,v 1.36 2018/02/11 14:15:14 wiz Exp $ .\" .\" Copyright (c) 1995, 1996, 1997, 1998, 2000 .\" Justin T. Gibbs. All rights reserved. @@ -67,78 +67,65 @@ Change the default SCSI id for cards wit .\" .Pp .\" For one or more SCSI buses: .\" .Cd device scbus0 at ahc0 -For -.Tn SCSI -buses: +For SCSI buses: .Cd scsibus* at ahc? .Sh DESCRIPTION -.\" This driver provides access to the -.\" .Tn SCSI -.\" bus(es) connected to Adaptec -.\" .Tn AIC7770 , -.\" .Tn AIC7850 , -.\" .Tn AIC7860 , -.\" .Tn AIC7870 , -.\" .Tn AIC7880 , -.\" .Tn AIC7890 , -.\" .Tn AIC7891 , -.\" .Tn AIC7892 , -.\" .Tn AIC7895 , -.\" .Tn AIC7896 , -.\" .Tn AIC7897 +.\" This driver provides access to the SCSI bus(es) connected to Adaptec +.\" AIC7770, +.\" AIC7850, +.\" AIC7860, +.\" AIC7870, +.\" AIC7880, +.\" AIC7890, +.\" AIC7891, +.\" AIC7892, +.\" AIC7895, +.\" AIC7896, +.\" AIC7897 .\" and -.\" .Tn AIC7899 +.\" AIC7899 .\" host adapter chips. .\" These chips are found on many motherboards as well as the following .\" Adaptec SCSI controller cards: -.\" .Tn 274X(W) , -.\" .Tn 274X(T) , -.\" .Tn 284X , -.\" .Tn 2910 , -.\" .Tn 2915 , -.\" .Tn 2920C , -.\" .Tn 2930C , -.\" .Tn 2930U2 , -.\" .Tn 2940 , -.\" .Tn 2940U , -.\" .Tn 2940AU , -.\" .Tn 2940UW , -.\" .Tn 2940UW Dual , -.\" .Tn 2940UW Pro , -.\" .Tn 2940U2W , -.\" .Tn 2940U2B , -.\" .Tn 2950U2W , -.\" .Tn 2950U2B , -.\" .Tn 19160B , -.\" .Tn 29160 , -.\" .Tn 29160B , -.\" .Tn 29160N , -.\" .Tn 3940 , -.\" .Tn 3940U , -.\" .Tn 3940AU , -.\" .Tn 3940UW , -.\" .Tn 3940AUW , -.\" .Tn 3940U2W , -.\" .Tn 3950U2 , -.\" .Tn 3960 , -.\" .Tn 39160 , -.\" .Tn 3985 , +.\" 274X(W), +.\" 274X(T), +.\" 284X, +.\" 2910, +.\" 2915, +.\" 2920C, +.\" 2930C, +.\" 2930U2, +.\" 2940, +.\" 2940U, +.\" 2940AU, +.\" 2940UW, +.\" 2940UW Dual, +.\" 2940UW Pro, +.\" 2940U2W, +.\" 2940U2B, +.\" 2950U2W, +.\" 2950U2B, +.\" 19160B, +.\" 29160, +.\" 29160B, +.\" 29160N, +.\" 3940, +.\" 3940U, +.\" 3940AU, +.\" 3940UW, +.\" 3940AUW, +.\" 3940U2W, +.\" 3950U2, +.\" 3960, +.\" 39160, +.\" 3985, .\" and -.\" .Tn 4944UW . +.\" 4944UW . The .Nm -device driver supports -.Tn SCSI -controllers based on -.Tn Adaptec -.Tn AIC77xx -and -.Tn AIC78xx -.Tn SCSI -host adapter chips found on many motherboards as well as -.Tn Adaptec -.Tn SCSI -controller cards. +device driver supports SCSI controllers based on Adaptec AIC77xx +and AIC78xx SCSI host adapter chips found on many motherboards as well as +Adaptec SCSI controller cards. .Pp Driver features include support for twin and wide buses, fast, ultra or ultra2 synchronous transfers depending on controller type, @@ -167,17 +154,9 @@ with this option enabled. .\" of all units where target mode is desired. .\" For example, a value of 0x25, would enable target mode on units 0, 2, and 5. .\" .Pp -Per target configuration performed in the -.Tn SCSI-Select -menu, accessible at boot -in -.No non- Ns Tn EISA -models, -or through an -.Tn EISA -configuration utility for -.Tn EISA -models, +Per target configuration performed in the SCSI-Select menu, accessible at boot +in non-EISA models, +or through an EISA configuration utility for EISA models, is honored by this driver. This includes synchronous/asynchronous transfers, maximum synchronous negotiation rate, @@ -185,30 +164,20 @@ wide transfers, disconnection, the host adapter's SCSI ID, and, -in the case of -.Tn EISA -Twin Channel controllers, +in the case of EISA Twin Channel controllers, the primary channel selection. For systems that store non-volatile settings in a system specific manner rather than a serial EEPROM directly connected to the aic7xxx controller, -the -.Tn BIOS -must be enabled for the driver to access this information. -This restriction applies to all -.Tn EISA -and many motherboard configurations. +the BIOS must be enabled for the driver to access this information. +This restriction applies to all EISA and many motherboard configurations. .Pp Note that I/O addresses are determined automatically by the probe routines, but care should be taken when using a 284x -.Pq Tn VESA No local bus controller -in an -.Tn EISA -system. -The jumpers setting the I/O area for the 284x should match the -.Tn EISA +.Pq VESA No local bus controller +in an EISA
CVS commit: src/external/gpl3
Module Name:src Committed By: maya Date: Sun Feb 11 13:50:15 UTC 2018 Modified Files: src/external/gpl3/gcc.old/dist/gcc/config/i386: i386.c src/external/gpl3/gcc/dist/gcc/config/i386: i386.c Log Message: Use bools with bool. NFCI. >From Henning Petersen in PR toolchain/53009. (I completed for the rest of the function. Similar code exists in GCC trunk.) To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 \ src/external/gpl3/gcc.old/dist/gcc/config/i386/i386.c cvs rdiff -u -r1.15 -r1.16 src/external/gpl3/gcc/dist/gcc/config/i386/i386.c 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/gcc.old/dist/gcc/config/i386/i386.c diff -u src/external/gpl3/gcc.old/dist/gcc/config/i386/i386.c:1.8 src/external/gpl3/gcc.old/dist/gcc/config/i386/i386.c:1.9 --- src/external/gpl3/gcc.old/dist/gcc/config/i386/i386.c:1.8 Mon Nov 13 08:05:18 2017 +++ src/external/gpl3/gcc.old/dist/gcc/config/i386/i386.c Sun Feb 11 13:50:15 2018 @@ -7465,7 +7465,7 @@ function_arg_advance_32 (CUMULATIVE_ARGS HOST_WIDE_INT words) { int res = 0; - bool error_p = NULL; + bool error_p = false; switch (mode) { @@ -7499,12 +7499,12 @@ function_arg_advance_32 (CUMULATIVE_ARGS case DFmode: if (cum->float_in_sse == -1) - error_p = 1; + error_p = true; if (cum->float_in_sse < 2) break; case SFmode: if (cum->float_in_sse == -1) - error_p = 1; + error_p = true; if (cum->float_in_sse < 1) break; /* FALLTHRU */ Index: src/external/gpl3/gcc/dist/gcc/config/i386/i386.c diff -u src/external/gpl3/gcc/dist/gcc/config/i386/i386.c:1.15 src/external/gpl3/gcc/dist/gcc/config/i386/i386.c:1.16 --- src/external/gpl3/gcc/dist/gcc/config/i386/i386.c:1.15 Fri Feb 2 03:41:04 2018 +++ src/external/gpl3/gcc/dist/gcc/config/i386/i386.c Sun Feb 11 13:50:15 2018 @@ -8686,7 +8686,7 @@ function_arg_advance_32 (CUMULATIVE_ARGS HOST_WIDE_INT words) { int res = 0; - bool error_p = NULL; + bool error_p = false; if (TARGET_IAMCU) { @@ -8731,12 +8731,12 @@ pass_in_reg: case DFmode: if (cum->float_in_sse == -1) - error_p = 1; + error_p = true; if (cum->float_in_sse < 2) break; case SFmode: if (cum->float_in_sse == -1) - error_p = 1; + error_p = true; if (cum->float_in_sse < 1) break; /* FALLTHRU */
CVS commit: src/share/man/man7
Module Name:src Committed By: wiz Date: Sun Feb 11 13:31:17 UTC 2018 Modified Files: src/share/man/man7: ascii.7 Log Message: Remove Tn. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/share/man/man7/ascii.7 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man7/ascii.7 diff -u src/share/man/man7/ascii.7:1.12 src/share/man/man7/ascii.7:1.13 --- src/share/man/man7/ascii.7:1.12 Thu Feb 8 03:18:37 2018 +++ src/share/man/man7/ascii.7 Sun Feb 11 13:31:17 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: ascii.7,v 1.12 2018/02/08 03:18:37 pgoyette Exp $ +.\" $NetBSD: ascii.7,v 1.13 2018/02/11 13:31:17 wiz Exp $ .\" .\" Copyright (c) 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. @@ -34,9 +34,7 @@ .Os .Sh NAME .Nm ascii -.Nd octal, hexadecimal and decimal -.Tn ASCII -character sets +.Nd octal, hexadecimal and decimal ASCII character sets .Sh DESCRIPTION The .Nm octal
CVS commit: src/lib/libc/yp
Module Name:src Committed By: wiz Date: Sun Feb 11 13:30:55 UTC 2018 Modified Files: src/lib/libc/yp: ypclnt.3 Log Message: Remove useless macros. Sort errors. To generate a diff of this commit: cvs rdiff -u -r1.29 -r1.30 src/lib/libc/yp/ypclnt.3 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/yp/ypclnt.3 diff -u src/lib/libc/yp/ypclnt.3:1.29 src/lib/libc/yp/ypclnt.3:1.30 --- src/lib/libc/yp/ypclnt.3:1.29 Wed Feb 7 11:16:06 2018 +++ src/lib/libc/yp/ypclnt.3 Sun Feb 11 13:30:55 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: ypclnt.3,v 1.29 2018/02/07 11:16:06 pgoyette Exp $ +.\" $NetBSD: ypclnt.3,v 1.30 2018/02/11 13:30:55 wiz Exp $ .\" .\" Copyright (c) 1996 The NetBSD Foundation, Inc. .\" All rights reserved. @@ -78,12 +78,8 @@ .Sh DESCRIPTION The .Nm ypclnt -suite provides an interface to the -.Tn YP -subsystem. -For a general description of the -.Tn YP -subsystem, see +suite provides an interface to the YP subsystem. +For a general description of the YP subsystem, see .Xr yp 8 . .Pp For all functions, input values begin with @@ -99,14 +95,10 @@ itself is the null pointer, in which cas .Er YPERR_BADARGS will be returned). If necessary, -memory will be allocated by the -.Tn YP -client routines using +memory will be allocated by the YP client routines using .Fn malloc , and the result will be stored in the appropriate output value. -If the invocation of a -.Tn YP -client routine doesn't return an error, +If the invocation of a YP client routine doesn't return an error, and an output value is not the null pointer, then this memory should be freed by the user when there is no additional need for the data stored there. @@ -134,45 +126,30 @@ a corresponding length parameter cannot corresponding length value is zero. Such strings need not be NUL-terminated. .Pp -All -.Tn YP -lookup calls (the functions +All YP lookup calls (the functions .Fn yp_all , .Fn yp_first , .Fn yp_master , .Fn yp_match , .Fn yp_next , .Fn yp_order ) -require a -.Tn YP -domain name and a -.Tn YP -map name. +require a YP domain name and a YP map name. The default domain name may be obtained by calling .Fn yp_get_default_domain , -and should thus be used before all other -.Tn YP -calls in a client program. +and should thus be used before all other YP calls in a client program. The value it places .Pa outdomain is suitable for use as the .Pa indomain -parameter to all subsequent -.Tn YP -calls. -.Pp -In order for -.Tn YP -lookup calls to succeed, the client process must be bound -to a -.Tn YP -server process. +parameter to all subsequent YP calls. +.Pp +In order for YP lookup calls to succeed, the client process must be bound +to a YP server process. The client process need not explicitly bind to the server, as it happens automatically whenever a lookup occurs. The function .Fn yp_bind -is provided for a backup strategy, e.g. a local file, when a -.Tn YP +is provided for a backup strategy, e.g. a local file, when a YP server process is not available. Each binding uses one socket descriptor on the client process, which may be explicitly freed using @@ -180,20 +157,14 @@ process, which may be explicitly freed u which frees all per-process and per-node resources to bind the domain and marks the domain unbound. .Pp -If, during a -.Tn YP -lookup, an RPC failure occurs, the domain used in the lookup +If, during a YP lookup, an RPC failure occurs, the domain used in the lookup is automatically marked unbound and the .Nm ypclnt layer retries the lookup as long as .Xr ypbind 8 is running and either the client process cannot bind to a server for the domain -specified in the lookup, or RPC requests to the -.Tn YP -server process fail. -If an error is not RPC-related, one of the -.Tn YP -error codes described below +specified in the lookup, or RPC requests to the YP server process fail. +If an error is not RPC-related, one of the YP error codes described below is returned and control given back to the user code. .Pp The @@ -225,9 +196,7 @@ Of course, the notions of and .Dq next are particular to the -type of -.Tn YP -map being accessed, and thus there is no guarantee of lexical order. +type of YP map being accessed, and thus there is no guarantee of lexical order. The only guarantees provided with .Fn yp_first and @@ -295,13 +264,11 @@ Holds one of the return status values de .In rpcsvc/yp_prot.h : see .Fn ypprot_err -below for a function that will translate -.Tn YP -protocol errors into a +below for a function that will translate YP protocol errors into a .Nm ypclnt layer error code as described in .In rpcsvc/ypclnt.h . -.It Fa inkey, inval +.It Fa inkey , inval The key and value arguments are somewhat different here than described above. In this case, the memory pointed to by @@ -334,9 +301,7 @@ something useful or simply ignore it. .It Fn yp_order Returns the order
CVS commit: src/lib/libc/time
Module Name:src Committed By: wiz Date: Sun Feb 11 13:28:50 UTC 2018 Modified Files: src/lib/libc/time: getdate.3 Log Message: Remove useless macro. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/lib/libc/time/getdate.3 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/time/getdate.3 diff -u src/lib/libc/time/getdate.3:1.9 src/lib/libc/time/getdate.3:1.10 --- src/lib/libc/time/getdate.3:1.9 Wed Feb 7 11:16:05 2018 +++ src/lib/libc/time/getdate.3 Sun Feb 11 13:28:49 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: getdate.3,v 1.9 2018/02/07 11:16:05 pgoyette Exp $ +.\" $NetBSD: getdate.3,v 1.10 2018/02/11 13:28:49 wiz Exp $ .\" .\" Copyright (c) 2009, 2011, 2012, The NetBSD Foundation. .\" All Rights Reserved. @@ -176,7 +176,6 @@ run job at 3 PM, december 2nd .Pp The following examples show how local data and time specification can be defined in the template. -.Pp .Bl -column -offset indent ".Li Friday 12:00:00" ".Sy Line in Template" .It Sy "Input String" Ta Sy "Line in Template" .It Li 11/27/86 Ta Li \&%m/\&%d/\&%y @@ -191,7 +190,6 @@ given that the current date is and the .Ev LC_TIME environment variable is set to the default C locale. -.Pp .Bl -column -offset indent ".Li Jan Wed 1989" ".Sy Line in Template" ".Sy Date" .It Sy Input String Ta Sy Line in Template Ta Sy Date .It Li Mon Ta Li \&%a Ta Li "Mon Sep 22 12:19:47 EDT 1986"
CVS commit: src/lib/libc/time
Module Name:src Committed By: wiz Date: Sun Feb 11 13:28:26 UTC 2018 Modified Files: src/lib/libc/time: ctime.3 Log Message: Remove Tn. Remove trailing whitespace. Remove useless Pp. To generate a diff of this commit: cvs rdiff -u -r1.57 -r1.58 src/lib/libc/time/ctime.3 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/time/ctime.3 diff -u src/lib/libc/time/ctime.3:1.57 src/lib/libc/time/ctime.3:1.58 --- src/lib/libc/time/ctime.3:1.57 Wed Feb 7 11:16:05 2018 +++ src/lib/libc/time/ctime.3 Sun Feb 11 13:28:26 2018 @@ -1,4 +1,4 @@ -.\" $NetBSD: ctime.3,v 1.57 2018/02/07 11:16:05 pgoyette Exp $ +.\" $NetBSD: ctime.3,v 1.58 2018/02/11 13:28:26 wiz Exp $ .\" .\" XXX: License missing? .\" @@ -131,7 +131,7 @@ or a .Dv NULL pointer denoting Coordinated Universal Time -.Pq Tn UTC . +.Pq UTC . .It Fn difftime "time1" "time2" The .Fn difftime @@ -176,7 +176,7 @@ fields. The .Fn gmtime function converts to Coordinated Universal Time -.Pq Tn UTC +.Pq UTC and returns a pointer to the .Va tm structure described in @@ -233,7 +233,7 @@ argument, returned by a previous call to or a .Dv NULL pointer denoting Coordinated Universal Time -.Pq Tn UTC . +.Pq UTC . .It Fn mktime "tm" The .Fn mktime @@ -313,7 +313,7 @@ argument, returned by a previous call to .Fn tzalloc , or a null pointer denoting Coordinated Universal Time -.Pq Tn UTC . +.Pq UTC . .El .Pp Declarations of all the functions and externals, and the @@ -337,7 +337,6 @@ includes the following fields: char *tm_zone; /* abbreviation of timezone name (optional) */ long tm_gmtoff; /* offset from UT in seconds (optional) */ .Ed -.Pp .Bl -bullet .It .Va tm_isdst @@ -432,7 +431,7 @@ argument is .Dv NULL , and this is not an error, but a way of referring to Coordinated Universal Time -.Pq Tn UTC . +.Pq UTC . .It .Fn tzgetzone function returns string containing the name of the timezone given in @@ -509,9 +508,9 @@ point to an array of characters that can be freed or overwritten by later calls to the functions .Fn localtime , .Fn tzfree , -and -.Fn tzset , -if these functions affect the time zone information that specifies the +and +.Fn tzset , +if these functions affect the time zone information that specifies the abbreviation in question. The remaining functions and data are thread-safe. The functions that do take an explicit
CVS commit: src/sys/arch
Module Name:src Committed By: maxv Date: Sun Feb 11 09:39:37 UTC 2018 Modified Files: src/sys/arch/amd64/amd64: machdep.c src/sys/arch/x86/conf: files.x86 Added Files: src/sys/arch/x86/x86: svs.c Log Message: Move SVS into x86/svs.c To generate a diff of this commit: cvs rdiff -u -r1.297 -r1.298 src/sys/arch/amd64/amd64/machdep.c cvs rdiff -u -r1.92 -r1.93 src/sys/arch/x86/conf/files.x86 cvs rdiff -u -r0 -r1.1 src/sys/arch/x86/x86/svs.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/amd64/amd64/machdep.c diff -u src/sys/arch/amd64/amd64/machdep.c:1.297 src/sys/arch/amd64/amd64/machdep.c:1.298 --- src/sys/arch/amd64/amd64/machdep.c:1.297 Sun Feb 4 17:03:21 2018 +++ src/sys/arch/amd64/amd64/machdep.c Sun Feb 11 09:39:36 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.c,v 1.297 2018/02/04 17:03:21 maxv Exp $ */ +/* $NetBSD: machdep.c,v 1.298 2018/02/11 09:39:36 maxv Exp $ */ /* * Copyright (c) 1996, 1997, 1998, 2000, 2006, 2007, 2008, 2011 @@ -110,7 +110,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.297 2018/02/04 17:03:21 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.298 2018/02/11 09:39:36 maxv Exp $"); /* #define XENDEBUG_LOW */ @@ -123,7 +123,6 @@ __KERNEL_RCSID(0, "$NetBSD: machdep.c,v #include "opt_realmem.h" #include "opt_xen.h" #include "opt_kaslr.h" -#include "opt_svs.h" #ifndef XEN #include "opt_physmem.h" #endif @@ -2236,391 +2235,3 @@ mm_md_direct_mapped_phys(paddr_t paddr, return true; } #endif - -/* -- */ - -#ifdef SVS -/* - * Separate Virtual Space - * - * A per-cpu L4 page is maintained in ci_svs_updirpa. During each context - * switch to a user pmap, updirpa is populated with the entries of the new - * pmap, minus what we don't want to have mapped in userland. - * - * Note on locking/synchronization here: - * - * (a) Touching ci_svs_updir without holding ci_svs_mtx first is *not* - * allowed. - * - * (b) pm_kernel_cpus contains the set of CPUs that have the pmap loaded - * in their CR3 register. It must *not* be replaced by pm_cpus. - * - * (c) When a context switch on the current CPU is made from a user LWP - * towards a kernel LWP, CR3 is not updated. Therefore, the pmap's - * pm_kernel_cpus still contains the current CPU. It implies that the - * remote CPUs that execute other threads of the user process we just - * left will keep synchronizing us against their changes. - * - * List of areas that are removed from userland: - * PTE Space [OK] - * Direct Map[OK] - * Remote PCPU Areas [OK] - * Kernel Heap [OK] - * Kernel Image [OK] - * - * TODO: - * - * (a) The NMI stack is not double-entered. Therefore if we ever receive - * an NMI and leave it, the content of the stack will be visible to - * userland (via Meltdown). Normally we never leave NMIs, unless a - * privileged user launched PMCs. That's unlikely to happen, our PMC - * support is pretty minimal. - * - * (b) Enable SVS depending on the CPU model, and add a sysctl to disable - * it dynamically. - * - * (c) Narrow down the entry points: hide the 'jmp handler' instructions. - * This makes sense on GENERIC_KASLR kernels. - * - * (d) Right now there is only one global LDT, and that's not compatible - * with USER_LDT. - */ - -struct svs_utls { - paddr_t kpdirpa; - uint64_t scratch; - vaddr_t rsp0; -}; - -static pd_entry_t * -svs_tree_add(struct cpu_info *ci, vaddr_t va) -{ - extern const vaddr_t ptp_masks[]; - extern const int ptp_shifts[]; - extern const long nbpd[]; - pd_entry_t *dstpde; - size_t i, pidx, mod; - struct vm_page *pg; - paddr_t pa; - - dstpde = ci->ci_svs_updir; - mod = (size_t)-1; - - for (i = PTP_LEVELS; i > 1; i--) { - pidx = pl_i(va % mod, i); - - if (!pmap_valid_entry(dstpde[pidx])) { - pg = uvm_pagealloc(NULL, 0, NULL, UVM_PGA_ZERO); - if (pg == 0) -panic("%s: failed to allocate PA for CPU %d\n", - __func__, cpu_index(ci)); - pa = VM_PAGE_TO_PHYS(pg); - - dstpde[pidx] = PG_V | PG_RW | pa; - } - - pa = (paddr_t)(dstpde[pidx] & PG_FRAME); - dstpde = (pd_entry_t *)PMAP_DIRECT_MAP(pa); - mod = nbpd[i-1]; - } - - return dstpde; -} - -static void -svs_page_add(struct cpu_info *ci, vaddr_t va) -{ - pd_entry_t *srcpde, *dstpde, pde; - size_t idx, pidx; - paddr_t pa; - - /* Create levels L4, L3 and L2. */ - dstpde = svs_tree_add(ci, va); - - pidx = pl1_i(va % NBPD_L2); - - /* - * If 'va' is in a large page, we need to compute its physical - * address manually. - */ - idx = pl2_i(va); - srcpde = L2_BASE; - if (!pmap_valid_entry(srcpde[idx])) { - panic("%s: L2 page not mapped", __func__); - } - if (srcpde[idx] & PG_PS) { - pa = srcpde[idx] & PG_2MFRAME; - pa += (paddr_t)(va % NBPD_L2); - pde = (srcpde[idx] & ~(PG_PS|PG_2MFRAME)) | pa; - -
CVS commit: src/sys/arch
Module Name:src Committed By: maxv Date: Sun Feb 11 08:27:18 UTC 2018 Modified Files: src/sys/arch/amd64/amd64: db_machdep.c src/sys/arch/i386/i386: db_machdep.c src/sys/arch/x86/x86: db_trace.c Log Message: Style, and reduce the diff between i386 and amd64. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/arch/amd64/amd64/db_machdep.c cvs rdiff -u -r1.6 -r1.7 src/sys/arch/i386/i386/db_machdep.c cvs rdiff -u -r1.3 -r1.4 src/sys/arch/x86/x86/db_trace.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/amd64/amd64/db_machdep.c diff -u src/sys/arch/amd64/amd64/db_machdep.c:1.4 src/sys/arch/amd64/amd64/db_machdep.c:1.5 --- src/sys/arch/amd64/amd64/db_machdep.c:1.4 Wed Oct 3 17:43:22 2012 +++ src/sys/arch/amd64/amd64/db_machdep.c Sun Feb 11 08:27:18 2018 @@ -1,32 +1,32 @@ -/* $NetBSD: db_machdep.c,v 1.4 2012/10/03 17:43:22 riastradh Exp $ */ +/* $NetBSD: db_machdep.c,v 1.5 2018/02/11 08:27:18 maxv Exp $ */ -/* +/* * Mach Operating System * Copyright (c) 1991,1990 Carnegie Mellon University * All Rights Reserved. - * + * * Permission to use, copy, modify and distribute this software and its * documentation is hereby granted, provided that both the copyright * notice and this permission notice appear in all copies of the * software, derivative works or modified versions, and any portions * thereof, and that both notices appear in supporting documentation. - * + * * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE. - * + * * Carnegie Mellon requests users of this software to return to - * + * * Software Distribution Coordinator or software.distribut...@cs.cmu.edu * School of Computer Science * Carnegie Mellon University * Pittsburgh PA 15213-3890 - * + * * any improvements or extensions that they make and grant Carnegie the * rights to redistribute these changes. */ #include -__KERNEL_RCSID(0, "$NetBSD: db_machdep.c,v 1.4 2012/10/03 17:43:22 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: db_machdep.c,v 1.5 2018/02/11 08:27:18 maxv Exp $"); #include #include @@ -79,7 +79,7 @@ const struct db_variable db_regs[] = { { "ss", dbreg(ss), db_x86_regop, NULL }, }; const struct db_variable * const db_eregs = - db_regs + sizeof(db_regs)/sizeof(db_regs[0]); +db_regs + sizeof(db_regs)/sizeof(db_regs[0]); /* * Figure out how many arguments were passed into the frame at "fp". @@ -93,19 +93,19 @@ db_numargs(long *retaddrp) return 0; } -/* - * Figure out the next frame up in the call stack. - * For trap(), we print the address of the faulting instruction and +/* + * Figure out the next frame up in the call stack. + * For trap(), we print the address of the faulting instruction and * proceed with the calling frame. We return the ip that faulted. * If the trap was caused by jumping through a bogus pointer, then - * the next line in the backtrace will list some random function as - * being called. It should get the argument list correct, though. + * the next line in the backtrace will list some random function as + * being called. It should get the argument list correct, though. * It might be possible to dig out from the next frame up the name * of the function that faulted, but that could get hairy. */ int db_nextframe(long **nextframe, long **retaddr, long **arg0, db_addr_t *ip, - long *argp, int is_trap, void (*pr)(const char *, ...)) +long *argp, int is_trap, void (*pr)(const char *, ...)) { struct trapframe *tf; struct x86_64_frame *fp; @@ -189,10 +189,10 @@ db_nextframe(long **nextframe, long **re db_sym_t db_frame_info(long *frame, db_addr_t callpc, const char **namep, - db_expr_t *offp, int *is_trap, int *nargp) +db_expr_t *offp, int *is_trap, int *nargp) { - db_expr_t offset; - db_sym_t sym; + db_expr_t offset; + db_sym_t sym; int narg; const char *name; Index: src/sys/arch/i386/i386/db_machdep.c diff -u src/sys/arch/i386/i386/db_machdep.c:1.6 src/sys/arch/i386/i386/db_machdep.c:1.7 --- src/sys/arch/i386/i386/db_machdep.c:1.6 Tue Aug 15 06:39:37 2017 +++ src/sys/arch/i386/i386/db_machdep.c Sun Feb 11 08:27:18 2018 @@ -1,33 +1,33 @@ -/* $NetBSD: db_machdep.c,v 1.6 2017/08/15 06:39:37 maxv Exp $ */ +/* $NetBSD: db_machdep.c,v 1.7 2018/02/11 08:27:18 maxv Exp $ */ -/* +/* * Mach Operating System * Copyright (c) 1991,1990 Carnegie Mellon University * All Rights Reserved. - * + * * Permission to use, copy, modify and distribute this software and its * documentation is hereby granted, provided that both the copyright * notice and this permission notice appear in all copies of the * software, derivative works or modified