CVS commit: [netbsd-7] src/external/bsd/blacklist/bin
Module Name:src Committed By: snj Date: Sun Dec 18 07:58:52 UTC 2016 Modified Files: src/external/bsd/blacklist/bin [netbsd-7]: blacklistctl.c Log Message: Pull up following revision(s) (requested by jnemeth in ticket #1330): external/bsd/blacklist/bin/blacklistctl.c: revision 1.21 Correct misplaced break; from FreeBSD. Approved By: christos To generate a diff of this commit: cvs rdiff -u -r1.17.2.3 -r1.17.2.4 \ src/external/bsd/blacklist/bin/blacklistctl.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/bsd/blacklist/bin/blacklistctl.c diff -u src/external/bsd/blacklist/bin/blacklistctl.c:1.17.2.3 src/external/bsd/blacklist/bin/blacklistctl.c:1.17.2.4 --- src/external/bsd/blacklist/bin/blacklistctl.c:1.17.2.3 Fri Aug 7 04:10:23 2015 +++ src/external/bsd/blacklist/bin/blacklistctl.c Sun Dec 18 07:58:52 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: blacklistctl.c,v 1.17.2.3 2015/08/07 04:10:23 snj Exp $ */ +/* $NetBSD: blacklistctl.c,v 1.17.2.4 2016/12/18 07:58:52 snj Exp $ */ /*- * Copyright (c) 2015 The NetBSD Foundation, Inc. @@ -33,7 +33,7 @@ #endif #include -__RCSID("$NetBSD: blacklistctl.c,v 1.17.2.3 2015/08/07 04:10:23 snj Exp $"); +__RCSID("$NetBSD: blacklistctl.c,v 1.17.2.4 2016/12/18 07:58:52 snj Exp $"); #include #include @@ -93,10 +93,10 @@ main(int argc, char *argv[]) break; case 'b': blocked = 1; + break; case 'D': dbname = optarg; break; - break; case 'd': debug++; break;
CVS commit: [netbsd-7] src/sys/dev/pci
Module Name:src Committed By: snj Date: Sun Dec 18 07:53:09 UTC 2016 Modified Files: src/sys/dev/pci [netbsd-7]: if_wm.c if_wmreg.h Log Message: Pull up following revision(s) (requested by msaitoh in ticket #1327): sys/dev/pci/if_wm.c: revision 1.457 sys/dev/pci/if_wmreg.h: revision 1.94 - Change to use 2500Base-KX correctly on C2000(I354). It worked, but the output of ifconfig and if_baudrate was not good. Tested by nils@: - The STATUS_TBIMODE bit in the STATUS register is deleted since 82575, so check for 82575 and newer first and then check for old devices. - Check the 2P5_SKU and 2P5_SKU_OVER bit for KX. - Set IFM_2500_SX instead of IFM_1000_SX for 2.5G. - Check SERDES's speed directly from the PCS layer (PCS_LSTS register) for old devices. - Style fix. To generate a diff of this commit: cvs rdiff -u -r1.289.2.11 -r1.289.2.12 src/sys/dev/pci/if_wm.c cvs rdiff -u -r1.60.2.6 -r1.60.2.7 src/sys/dev/pci/if_wmreg.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/if_wm.c diff -u src/sys/dev/pci/if_wm.c:1.289.2.11 src/sys/dev/pci/if_wm.c:1.289.2.12 --- src/sys/dev/pci/if_wm.c:1.289.2.11 Mon Dec 12 07:18:29 2016 +++ src/sys/dev/pci/if_wm.c Sun Dec 18 07:53:08 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: if_wm.c,v 1.289.2.11 2016/12/12 07:18:29 snj Exp $ */ +/* $NetBSD: if_wm.c,v 1.289.2.12 2016/12/18 07:53:08 snj Exp $ */ /* * Copyright (c) 2001, 2002, 2003, 2004 Wasabi Systems, Inc. @@ -84,7 +84,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.289.2.11 2016/12/12 07:18:29 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_wm.c,v 1.289.2.12 2016/12/18 07:53:08 snj Exp $"); #include #include @@ -2312,100 +2312,91 @@ wm_attach(device_t parent, device_t self || sc->sc_type == WM_T_82574 || sc->sc_type == WM_T_82583) { /* STATUS_TBIMODE reserved/reused, can't rely on it */ wm_gmii_mediainit(sc, wmp->wmp_product); - } else if (sc->sc_type < WM_T_82543 || - (CSR_READ(sc, WMREG_STATUS) & STATUS_TBIMODE) != 0) { - if (sc->sc_mediatype == WM_MEDIATYPE_COPPER) { - aprint_error_dev(sc->sc_dev, - "WARNING: TBIMODE set on 1000BASE-T product!\n"); - sc->sc_mediatype = WM_MEDIATYPE_FIBER; - } - wm_tbi_mediainit(sc); - } else { - switch (sc->sc_type) { - case WM_T_82575: - case WM_T_82576: - case WM_T_82580: - case WM_T_I350: - case WM_T_I354: - case WM_T_I210: - case WM_T_I211: - reg = CSR_READ(sc, WMREG_CTRL_EXT); - link_mode = reg & CTRL_EXT_LINK_MODE_MASK; - switch (link_mode) { - case CTRL_EXT_LINK_MODE_1000KX: -aprint_verbose_dev(sc->sc_dev, "1000KX\n"); -sc->sc_mediatype = WM_MEDIATYPE_SERDES; + } else if ((sc->sc_type == WM_T_82575) || (sc->sc_type == WM_T_82576) + || (sc->sc_type ==WM_T_82580) || (sc->sc_type ==WM_T_I350) + || (sc->sc_type ==WM_T_I354) || (sc->sc_type ==WM_T_I210) + || (sc->sc_type ==WM_T_I211)) { + reg = CSR_READ(sc, WMREG_CTRL_EXT); + link_mode = reg & CTRL_EXT_LINK_MODE_MASK; + switch (link_mode) { + case CTRL_EXT_LINK_MODE_1000KX: + aprint_verbose_dev(sc->sc_dev, "1000KX\n"); + sc->sc_mediatype = WM_MEDIATYPE_SERDES; + break; + case CTRL_EXT_LINK_MODE_SGMII: + if (wm_sgmii_uses_mdio(sc)) { +aprint_verbose_dev(sc->sc_dev, +"SGMII(MDIO)\n"); +sc->sc_flags |= WM_F_SGMII; +sc->sc_mediatype = WM_MEDIATYPE_COPPER; break; - case CTRL_EXT_LINK_MODE_SGMII: -if (wm_sgmii_uses_mdio(sc)) { - aprint_verbose_dev(sc->sc_dev, - "SGMII(MDIO)\n"); - sc->sc_flags |= WM_F_SGMII; + } + aprint_verbose_dev(sc->sc_dev, "SGMII(I2C)\n"); + /*FALLTHROUGH*/ + case CTRL_EXT_LINK_MODE_PCIE_SERDES: + sc->sc_mediatype = wm_sfp_get_media_type(sc); + if (sc->sc_mediatype == WM_MEDIATYPE_UNKNOWN) { +if (link_mode +== CTRL_EXT_LINK_MODE_SGMII) { sc->sc_mediatype = WM_MEDIATYPE_COPPER; - break; -} -aprint_verbose_dev(sc->sc_dev, "SGMII(I2C)\n"); -/*FALLTHROUGH*/ - case CTRL_EXT_LINK_MODE_PCIE_SERDES: -sc->sc_mediatype = wm_sfp_get_media_type(sc); -if (sc->sc_mediatype == WM_MEDIATYPE_UNKNOWN) { - if (link_mode - == CTRL_EXT_LINK_MODE_SGMII) { - sc->sc_mediatype - = WM_MEDIATYPE_COPPER; - sc->sc_flags |= WM_F_SGMII; - } else { - sc->sc_mediatype - = WM_MEDIATYPE_SERDES; - aprint_verbose_dev(sc->sc_dev, - "SERDES\n"); - } - break; -} -if (sc->sc_mediatype == WM_MEDIATYPE_SERDES) + sc->sc_flags |= WM_F_SGMII; +} else { + sc->sc_mediatype = WM_MEDIATYPE_SERDES; aprint_verbose_dev(sc->sc_dev, "SERDES\n"); - -/* Change current link mode setting */ -reg &= ~CTRL_EXT_LINK_MODE_MASK; -switch (sc->sc_mediatype) { -case WM_MEDIATYPE_COPPER: - reg |= CTRL_EXT_LINK_MODE_SGMII; - break; -case WM_MEDIATYPE_SERDES: - reg |= CTRL_EXT_LINK_MODE_PCIE_SERDES; - br
CVS commit: [netbsd-7] src/sys/arch/xen/conf
Module Name:src Committed By: snj Date: Sun Dec 18 07:50:37 UTC 2016 Modified Files: src/sys/arch/xen/conf [netbsd-7]: files.xen Log Message: Pull up following revision(s) (requested by jnemeth in ticket #1326): sys/arch/xen/conf/files.xen: revision 1.141 make CPU microcode loading dependent on both DOM0OPS AND CPU_UCODE To generate a diff of this commit: cvs rdiff -u -r1.133.4.1 -r1.133.4.2 src/sys/arch/xen/conf/files.xen 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/xen/conf/files.xen diff -u src/sys/arch/xen/conf/files.xen:1.133.4.1 src/sys/arch/xen/conf/files.xen:1.133.4.2 --- src/sys/arch/xen/conf/files.xen:1.133.4.1 Sun Sep 25 12:11:33 2016 +++ src/sys/arch/xen/conf/files.xen Sun Dec 18 07:50:37 2016 @@ -1,4 +1,4 @@ -# $NetBSD: files.xen,v 1.133.4.1 2016/09/25 12:11:33 bouyer Exp $ +# $NetBSD: files.xen,v 1.133.4.2 2016/12/18 07:50:37 snj Exp $ # NetBSD: files.x86,v 1.10 2003/10/08 17:30:00 bouyer Exp # NetBSD: files.i386,v 1.254 2004/03/25 23:32:10 jmc Exp @@ -92,9 +92,9 @@ file arch/xen/x86/xen_pmap.c file arch/xen/x86/xen_intr.c file arch/xen/x86/xenfunc.c -file arch/xen/xen/xen_ucode.c dom0ops | cpu_ucode needs-flag -file arch/x86/x86/cpu_ucode_amd.c dom0ops | cpu_ucode needs-flag -file arch/x86/x86/cpu_ucode_intel.c dom0ops | cpu_ucode needs-flag +file arch/xen/xen/xen_ucode.c dom0ops & cpu_ucode needs-flag +file arch/x86/x86/cpu_ucode_amd.c dom0ops & cpu_ucode needs-flag +file arch/x86/x86/cpu_ucode_intel.c dom0ops & cpu_ucode needs-flag file arch/xen/xen/xen_machdep.c file arch/xen/xen/xen_debug.c
CVS commit: [netbsd-7] src/usr.bin/calendar/calendars
Module Name:src Committed By: snj Date: Sun Dec 18 07:47:22 UTC 2016 Modified Files: src/usr.bin/calendar/calendars [netbsd-7]: calendar.birthday calendar.christian calendar.history calendar.holiday calendar.judaic calendar.netbsd calendar.usholiday Log Message: Pull up following revision(s) (requested by jnemeth in ticket #1325): usr.bin/calendar/calendars/calendar.birthday: revision 1.26 usr.bin/calendar/calendars/calendar.christian: revision 1.6 usr.bin/calendar/calendars/calendar.history: revisions 1.33, 1.34 usr.bin/calendar/calendars/calendar.holiday: revisions 1.26, 1.27 usr.bin/calendar/calendars/calendar.judaic: revision 1.6 usr.bin/calendar/calendars/calendar.netbsd: revisions 1.36, 1.37 usr.bin/calendar/calendars/calendar.usholiday: revision 1.7 note the release of NetBSD 7.0 -- Fix typo - Bahamas starts with a 'B' not with a 'G' -- typo -- allexander the greeeat, his name struck fear into hearts of men! ...but let's conquer that fear and give ol' alex a consistent and correct date of death. (he died of fever in baabylooo) -- update floating holidays for 2017 in preparation for pullup for 7.1 release To generate a diff of this commit: cvs rdiff -u -r1.24.6.1 -r1.24.6.2 \ src/usr.bin/calendar/calendars/calendar.birthday cvs rdiff -u -r1.4.10.1 -r1.4.10.2 \ src/usr.bin/calendar/calendars/calendar.christian \ src/usr.bin/calendar/calendars/calendar.judaic cvs rdiff -u -r1.30.4.1 -r1.30.4.2 \ src/usr.bin/calendar/calendars/calendar.history cvs rdiff -u -r1.23.2.1 -r1.23.2.2 \ src/usr.bin/calendar/calendars/calendar.holiday cvs rdiff -u -r1.32.2.1 -r1.32.2.2 \ src/usr.bin/calendar/calendars/calendar.netbsd cvs rdiff -u -r1.4.10.2 -r1.4.10.3 \ src/usr.bin/calendar/calendars/calendar.usholiday Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.bin/calendar/calendars/calendar.birthday diff -u src/usr.bin/calendar/calendars/calendar.birthday:1.24.6.1 src/usr.bin/calendar/calendars/calendar.birthday:1.24.6.2 --- src/usr.bin/calendar/calendars/calendar.birthday:1.24.6.1 Fri Nov 6 00:52:36 2015 +++ src/usr.bin/calendar/calendars/calendar.birthday Sun Dec 18 07:47:22 2016 @@ -142,7 +142,7 @@ 06/07 George Bryan "Beau" Brummel born, 1778 06/07 Alan Mathison Turing died, 1954 06/08 Frank Lloyd Wright born in Richland Center, Wisconsin, 1869 -06/13 Alexander the Great dies (323 BC) +06/11 Alexander the Great dies (323 BC) 06/15 Edward (Edvard Hagerup) Grieg born in Bergen, Norway, 1843 06/16 Hammurabi the Great dies, Babylon, 1686 BC 06/18 M.C. Escher born, 1898 Index: src/usr.bin/calendar/calendars/calendar.christian diff -u src/usr.bin/calendar/calendars/calendar.christian:1.4.10.1 src/usr.bin/calendar/calendars/calendar.christian:1.4.10.2 --- src/usr.bin/calendar/calendars/calendar.christian:1.4.10.1 Fri Nov 6 00:52:36 2015 +++ src/usr.bin/calendar/calendars/calendar.christian Sun Dec 18 07:47:22 2016 @@ -1,17 +1,17 @@ 01/06* Epiphany -02/09* Shrove Tuesday / Mardi Gras (day before Ash Wednesday) -02/10* Ash Wednesday (First day of Lent) -03/20* Palm Sunday (7 days before Easter) -03/24* Maundy Thursday (3 days before Easter) -03/25* Good Friday (2 days before Easter) -03/27* Easter Sunday -05/01* Rogation Sunday -05/05* Ascension Day (10 days before Pentecost) -05/15* Pentecost (Whitsunday) -05/16* Whitmonday -05/22* Trinity Sunday (7 days after Pentecost) -05/26* Corpus Christi (11 days after Pentecost) +02/28* Shrove Tuesday / Mardi Gras (day before Ash Wednesday) +03/01* Ash Wednesday (First day of Lent) +04/09* Palm Sunday (7 days before Easter) +04/13* Maundy Thursday (3 days before Easter) +04/14* Good Friday (2 days before Easter) +04/16* Easter Sunday +05/21* Rogation Sunday +05/25* Ascension Day (10 days before Pentecost) +06/04* Pentecost (Whitsunday) +06/05* Whitmonday +06/11* Trinity Sunday (7 days after Pentecost) +06/15* Corpus Christi (11 days after Pentecost) 10/18 Feast Day of St. Luke -11/29* First Sunday of Advent (4th Sunday before Christmas) +12/03* First Sunday of Advent (4th Sunday before Christmas) 12/06 St. Nicholas' Day 12/25 Feast of the Nativity (Christmas) Index: src/usr.bin/calendar/calendars/calendar.judaic diff -u src/usr.bin/calendar/calendars/calendar.judaic:1.4.10.1 src/usr.bin/calendar/calendars/calendar.judaic:1.4.10.2 --- src/usr.bin/calendar/calendars/calendar.judaic:1.4.10.1 Fri Nov 6 00:52:36 2015 +++ src/usr.bin/calendar/calendars/calendar.judaic Sun Dec 18 07:47:22 2016 @@ -1,27 +1,27 @@ -01/25* Tu B'Shvat (Feast of Trees) -03/23* Fast of Esther (Battle of Purim; 1 day before Purim; fast day) -03/24* Purim (Feast of Lots; 30 days before Pesach) -04/23* Pesach (First Day of Passover; sabbatical) -04/24* Pesach (sabbatical) -04/25* Pesach (sabbatical) -04/26* Pesach (Last Day of Passover; 8th day of Pesach;
CVS commit: [netbsd-7] src/sys
Module Name:src Committed By: snj Date: Sun Dec 18 07:40:50 UTC 2016 Modified Files: src/sys/modules/npf [netbsd-7]: Makefile src/sys/net/npf [netbsd-7]: files.npf npf_impl.h npf_tableset.c src/sys/rump/net/lib/libnpf [netbsd-7]: Makefile Added Files: src/sys/net/npf [netbsd-7]: lpm.c lpm.h Removed Files: src/sys/net/npf [netbsd-7]: npf_tableset_ptree.c Log Message: Pull up following revision(s) (requested by rmind in ticket #1319): sys/modules/npf/Makefile: revision 1.19 sys/net/npf/files.npf: revision 1.18 sys/net/npf/lpm.c: revision 1.1 sys/net/npf/lpm.h: revision 1.1 sys/net/npf/npf_impl.h: revision 1.62 sys/net/npf/npf_tableset.c: revision 1.24 sys/net/npf/npf_tableset_ptree.c: file removal sys/rump/net/lib/libnpf/Makefile: revision 1.18 This patches ditches the ptree(3) library, because it is broken (you can get missing entries!). Instead, as a temporary solution, we switch to a simple linear scan of the hash tables for the longest-prefix-match (lpm.c lpm.h) algorithm. In fact, with few unique prefixes in the set, on modern hardware this simple algorithm is pretty fast anyway! -- ditch ptree and use lpm -- remove ptree add lpm To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.17.2.1 src/sys/modules/npf/Makefile cvs rdiff -u -r1.17 -r1.17.2.1 src/sys/net/npf/files.npf cvs rdiff -u -r0 -r1.1.2.2 src/sys/net/npf/lpm.c src/sys/net/npf/lpm.h cvs rdiff -u -r1.58.2.3 -r1.58.2.4 src/sys/net/npf/npf_impl.h cvs rdiff -u -r1.22 -r1.22.2.1 src/sys/net/npf/npf_tableset.c cvs rdiff -u -r1.1 -r0 src/sys/net/npf/npf_tableset_ptree.c cvs rdiff -u -r1.14 -r1.14.2.1 src/sys/rump/net/lib/libnpf/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/modules/npf/Makefile diff -u src/sys/modules/npf/Makefile:1.17 src/sys/modules/npf/Makefile:1.17.2.1 --- src/sys/modules/npf/Makefile:1.17 Sat Jul 19 18:24:17 2014 +++ src/sys/modules/npf/Makefile Sun Dec 18 07:40:50 2016 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.17 2014/07/19 18:24:17 rmind Exp $ +# $NetBSD: Makefile,v 1.17.2.1 2016/12/18 07:40:50 snj Exp $ # # Public Domain. # @@ -13,7 +13,7 @@ SRCS= npf.c npf_alg.c npf_conf.c npf_ct SRCS+= npf_bpf.c npf_if.c npf_inet.c npf_mbuf.c npf_nat.c SRCS+= npf_ruleset.c npf_conn.c npf_conndb.c npf_rproc.c SRCS+= npf_state.c npf_state_tcp.c npf_tableset.c -SRCS+= npf_tableset_ptree.c npf_sendpkt.c npf_worker.c +SRCS+= lpm.c npf_sendpkt.c npf_worker.c CPPFLAGS+= -DINET6 Index: src/sys/net/npf/files.npf diff -u src/sys/net/npf/files.npf:1.17 src/sys/net/npf/files.npf:1.17.2.1 --- src/sys/net/npf/files.npf:1.17 Sat Jul 19 18:24:16 2014 +++ src/sys/net/npf/files.npf Sun Dec 18 07:40:50 2016 @@ -1,4 +1,4 @@ -# $NetBSD: files.npf,v 1.17 2014/07/19 18:24:16 rmind Exp $ +# $NetBSD: files.npf,v 1.17.2.1 2016/12/18 07:40:50 snj Exp $ # # Public Domain. # @@ -19,7 +19,6 @@ file net/npf/npf_bpf.c npf file net/npf/npf_ruleset.c npf file net/npf/npf_rproc.c npf file net/npf/npf_tableset.c npf -file net/npf/npf_tableset_ptree.c npf file net/npf/npf_if.c npf file net/npf/npf_inet.c npf file net/npf/npf_conn.c npf @@ -31,6 +30,9 @@ file net/npf/npf_alg.c npf file net/npf/npf_sendpkt.c npf file net/npf/npf_worker.c npf +# LPM +file net/npf/lpm.cnpf + # Built-in extensions. file net/npf/npf_ext_log.c npf file net/npf/npf_ext_normalize.c npf Index: src/sys/net/npf/npf_impl.h diff -u src/sys/net/npf/npf_impl.h:1.58.2.3 src/sys/net/npf/npf_impl.h:1.58.2.4 --- src/sys/net/npf/npf_impl.h:1.58.2.3 Wed Feb 4 07:13:04 2015 +++ src/sys/net/npf/npf_impl.h Sun Dec 18 07:40:50 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: npf_impl.h,v 1.58.2.3 2015/02/04 07:13:04 snj Exp $ */ +/* $NetBSD: npf_impl.h,v 1.58.2.4 2016/12/18 07:40:50 snj Exp $ */ /*- * Copyright (c) 2009-2014 The NetBSD Foundation, Inc. @@ -49,7 +49,6 @@ #include #include -#include #include #include @@ -228,8 +227,6 @@ bool npf_bpf_validate(const void *, siz void npf_tableset_sysinit(void); void npf_tableset_sysfini(void); -extern const pt_tree_ops_t npf_table_ptree_ops; - npf_tableset_t *npf_tableset_create(u_int); void npf_tableset_destroy(npf_tableset_t *); int npf_tableset_insert(npf_tableset_t *, npf_table_t *); Index: src/sys/net/npf/npf_tableset.c diff -u src/sys/net/npf/npf_tableset.c:1.22 src/sys/net/npf/npf_tableset.c:1.22.2.1 --- src/sys/net/npf/npf_tableset.c:1.22 Mon Aug 11 01:54:12 2014 +++ src/sys/net/npf/npf_tableset.c Sun Dec 18 07:40:50 2016 @@ -1,7 +1,7 @@ -/* $NetBSD: npf_tableset.c,v 1.22 2014/08/11 01:54:12 rmind Exp $ */ +/* $NetBSD: npf_tableset.c,v 1.22.2.1 2016/12/18 07:40:50 snj Exp $ */ /*- - * Copyright (c) 2009-2014 The NetBSD Foundation, Inc. + * Copyright (c) 2009-2016 The NetBSD Foundation, Inc. * All rights reserved. * * This material is based upon w
CVS commit: [netbsd-7] src/share/misc
Module Name:src Committed By: snj Date: Sun Dec 18 07:12:06 UTC 2016 Modified Files: src/share/misc [netbsd-7]: bsd-family-tree Log Message: Pull up following revision(s) (requested by nakayama in ticket #1317): share/misc/bsd-family-tree: revisions 1.57, 1.58 Sync with FreeBSD r305215 -- Add NetBSD rcs tag which was lost with r1.13. Add NetBSD 7.0.1 heads up by wiz@ To generate a diff of this commit: cvs rdiff -u -r1.56 -r1.56.2.1 src/share/misc/bsd-family-tree Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/misc/bsd-family-tree diff -u src/share/misc/bsd-family-tree:1.56 src/share/misc/bsd-family-tree:1.56.2.1 --- src/share/misc/bsd-family-tree:1.56 Fri May 30 07:26:06 2014 +++ src/share/misc/bsd-family-tree Sun Dec 18 07:12:06 2016 @@ -110,9 +110,11 @@ FreeBSD 2.1 | | | | | | | | NetBSD 1.3.2| | | FreeBSD 2.2.7 | | ||| | | | | | ||| BSD/OS 4.0 - | v | | ||| | | FreeBSD 2.2.8 | | ||| | - | | | ||OpenBSD 2.4 | + | | | | ||| | + | v | | ||OpenBSD 2.4 | + | FreeBSD 2.2.9 | | ||| | + | | | ||| | FreeBSD 3.0 <* | |v| | | | | NetBSD 1.3.3| | *---FreeBSD 3.1 | | | | @@ -279,30 +281,76 @@ FreeBSD 5.2 | | | | | | | | | OpenBSD 5.3 DragonFly 3.4.1 | | | | | | NetBSD | | | | | | | |6.0.2 | | + | | | | | | || | + | | | | | | NetBSD | | + | | | | | |6.0.3 | | | | | | | | || | - | | | | | | NetBSD 6.0.3 | | - | | | | | | || | - | | | | | | NetBSD 6.0.4 | | + | | | | | | NetBSD | | + | | | | | |6.0.4 | | | | | | | | || | - | | | | | | NetBSD 6.0.5 | | + | | | | | | NetBSD | | + | | | | | |6.0.5 | | | | | | | | | | - | | | | | `-NetBSD 6.1 | | + | | | | | |`-NetBSD 6.1 | | | |FreeBSD | | | | | | | 8.4 | |NetBSD 6.1.1 | | | | | | | | | | FreeBSD | |NetBSD 6.1.2 | | |9.2 Mac OS X | | | | - | 10.9| |OpenBSD 5.4 | - || | | | DragonFly 3.6.0 - || | | | | - *--FreeBSD | |NetBSD 6.1.3 | | - | 10.0 | | | | | - || |NetBSD 6.1.4 | | + | | 10.9| |OpenBSD 5.4 | + | `-.| | | | DragonFly 3.6.0 + |\ | | | | | + *--FreeBSD| | |NetBSD 6.1.3 | | + | 10.0 | | | | | | + | | | | | | | DragonFly 3.6.1 + | | | | | | | | + | | | | | | | | + | | | | | | | DragonFly 3.6.2 + | | | | |NetBSD 6.1.4 | | + | | | | | | | | + | | | | | |OpenBSD 5.5 | + | |
CVS commit: [netbsd-7-0] src/sys/arch/x86
Module Name:src Committed By: snj Date: Sun Dec 18 07:02:59 UTC 2016 Modified Files: src/sys/arch/x86/include [netbsd-7-0]: pmap.h src/sys/arch/x86/x86 [netbsd-7-0]: pmap.c vm_machdep.c Log Message: Pull up following revision(s) (requested by riastradh in ticket #1316): sys/arch/x86/x86/pmap.c: revision 1.223 sys/arch/x86/x86/vm_machdep.c: revision 1.26 sys/arch/x86/include/pmap.h: revision 1.61 PR/49691: KAMADA Ken'ichi: free deferred ptp mappings if present. XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.55.4.1 -r1.55.4.1.2.1 src/sys/arch/x86/include/pmap.h cvs rdiff -u -r1.183.2.2.2.1 -r1.183.2.2.2.2 src/sys/arch/x86/x86/pmap.c cvs rdiff -u -r1.25 -r1.25.8.1 src/sys/arch/x86/x86/vm_machdep.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/include/pmap.h diff -u src/sys/arch/x86/include/pmap.h:1.55.4.1 src/sys/arch/x86/include/pmap.h:1.55.4.1.2.1 --- src/sys/arch/x86/include/pmap.h:1.55.4.1 Thu Apr 23 07:31:16 2015 +++ src/sys/arch/x86/include/pmap.h Sun Dec 18 07:02:59 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.h,v 1.55.4.1 2015/04/23 07:31:16 snj Exp $ */ +/* $NetBSD: pmap.h,v 1.55.4.1.2.1 2016/12/18 07:02:59 snj Exp $ */ /* * Copyright (c) 1997 Charles D. Cranor and Washington University. @@ -479,6 +479,7 @@ void pmap_kenter_ma(vaddr_t, paddr_t, vm int pmap_enter_ma(struct pmap *, vaddr_t, paddr_t, paddr_t, vm_prot_t, u_int, int); bool pmap_extract_ma(pmap_t, vaddr_t, paddr_t *); +void pmap_free_ptps(struct vm_page *); /* * Hooks for the pool allocator. Index: src/sys/arch/x86/x86/pmap.c diff -u src/sys/arch/x86/x86/pmap.c:1.183.2.2.2.1 src/sys/arch/x86/x86/pmap.c:1.183.2.2.2.2 --- src/sys/arch/x86/x86/pmap.c:1.183.2.2.2.1 Fri Feb 26 21:51:54 2016 +++ src/sys/arch/x86/x86/pmap.c Sun Dec 18 07:02:59 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.183.2.2.2.1 2016/02/26 21:51:54 snj Exp $ */ +/* $NetBSD: pmap.c,v 1.183.2.2.2.2 2016/12/18 07:02:59 snj Exp $ */ /*- * Copyright (c) 2008, 2010 The NetBSD Foundation, Inc. @@ -171,7 +171,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.183.2.2.2.1 2016/02/26 21:51:54 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.183.2.2.2.2 2016/12/18 07:02:59 snj Exp $"); #include "opt_user_ldt.h" #include "opt_lockdebug.h" @@ -2399,7 +2399,7 @@ pmap_create(void) * pmap_free_ptps: put a list of ptps back to the freelist. */ -static void +void pmap_free_ptps(struct vm_page *empty_ptps) { struct vm_page *ptp; Index: src/sys/arch/x86/x86/vm_machdep.c diff -u src/sys/arch/x86/x86/vm_machdep.c:1.25 src/sys/arch/x86/x86/vm_machdep.c:1.25.8.1 --- src/sys/arch/x86/x86/vm_machdep.c:1.25 Tue Mar 11 20:55:19 2014 +++ src/sys/arch/x86/x86/vm_machdep.c Sun Dec 18 07:02:59 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: vm_machdep.c,v 1.25 2014/03/11 20:55:19 para Exp $ */ +/* $NetBSD: vm_machdep.c,v 1.25.8.1 2016/12/18 07:02:59 snj Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. @@ -80,7 +80,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.25 2014/03/11 20:55:19 para Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.25.8.1 2016/12/18 07:02:59 snj Exp $"); #include "opt_mtrr.h" @@ -249,6 +249,12 @@ cpu_lwp_free(struct lwp *l, int proc) if (proc && l->l_proc->p_md.md_flags & MDP_USEDMTRR) mtrr_clean(l->l_proc); #endif + /* + * Free deferred mappings if any. + */ + struct vm_page *empty_ptps = l->l_md.md_gc_ptp; + l->l_md.md_gc_ptp = NULL; + pmap_free_ptps(empty_ptps); } /*
CVS commit: [netbsd-7] src/sys/arch/x86
Module Name:src Committed By: snj Date: Sun Dec 18 07:01:57 UTC 2016 Modified Files: src/sys/arch/x86/include [netbsd-7]: pmap.h src/sys/arch/x86/x86 [netbsd-7]: pmap.c vm_machdep.c Log Message: Pull up following revision(s) (requested by riastradh in ticket #1316): sys/arch/x86/x86/pmap.c: revision 1.223 sys/arch/x86/x86/vm_machdep.c: revision 1.26 sys/arch/x86/include/pmap.h: revision 1.61 PR/49691: KAMADA Ken'ichi: free deferred ptp mappings if present. XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.55.4.1 -r1.55.4.2 src/sys/arch/x86/include/pmap.h cvs rdiff -u -r1.183.2.4 -r1.183.2.5 src/sys/arch/x86/x86/pmap.c cvs rdiff -u -r1.25 -r1.25.4.1 src/sys/arch/x86/x86/vm_machdep.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/include/pmap.h diff -u src/sys/arch/x86/include/pmap.h:1.55.4.1 src/sys/arch/x86/include/pmap.h:1.55.4.2 --- src/sys/arch/x86/include/pmap.h:1.55.4.1 Thu Apr 23 07:31:16 2015 +++ src/sys/arch/x86/include/pmap.h Sun Dec 18 07:01:57 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.h,v 1.55.4.1 2015/04/23 07:31:16 snj Exp $ */ +/* $NetBSD: pmap.h,v 1.55.4.2 2016/12/18 07:01:57 snj Exp $ */ /* * Copyright (c) 1997 Charles D. Cranor and Washington University. @@ -479,6 +479,7 @@ void pmap_kenter_ma(vaddr_t, paddr_t, vm int pmap_enter_ma(struct pmap *, vaddr_t, paddr_t, paddr_t, vm_prot_t, u_int, int); bool pmap_extract_ma(pmap_t, vaddr_t, paddr_t *); +void pmap_free_ptps(struct vm_page *); /* * Hooks for the pool allocator. Index: src/sys/arch/x86/x86/pmap.c diff -u src/sys/arch/x86/x86/pmap.c:1.183.2.4 src/sys/arch/x86/x86/pmap.c:1.183.2.5 --- src/sys/arch/x86/x86/pmap.c:1.183.2.4 Fri Feb 26 21:50:54 2016 +++ src/sys/arch/x86/x86/pmap.c Sun Dec 18 07:01:57 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.183.2.4 2016/02/26 21:50:54 snj Exp $ */ +/* $NetBSD: pmap.c,v 1.183.2.5 2016/12/18 07:01:57 snj Exp $ */ /*- * Copyright (c) 2008, 2010 The NetBSD Foundation, Inc. @@ -171,7 +171,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.183.2.4 2016/02/26 21:50:54 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.183.2.5 2016/12/18 07:01:57 snj Exp $"); #include "opt_user_ldt.h" #include "opt_lockdebug.h" @@ -2405,7 +2405,7 @@ pmap_create(void) * pmap_free_ptps: put a list of ptps back to the freelist. */ -static void +void pmap_free_ptps(struct vm_page *empty_ptps) { struct vm_page *ptp; Index: src/sys/arch/x86/x86/vm_machdep.c diff -u src/sys/arch/x86/x86/vm_machdep.c:1.25 src/sys/arch/x86/x86/vm_machdep.c:1.25.4.1 --- src/sys/arch/x86/x86/vm_machdep.c:1.25 Tue Mar 11 20:55:19 2014 +++ src/sys/arch/x86/x86/vm_machdep.c Sun Dec 18 07:01:57 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: vm_machdep.c,v 1.25 2014/03/11 20:55:19 para Exp $ */ +/* $NetBSD: vm_machdep.c,v 1.25.4.1 2016/12/18 07:01:57 snj Exp $ */ /*- * Copyright (c) 1982, 1986 The Regents of the University of California. @@ -80,7 +80,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.25 2014/03/11 20:55:19 para Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.25.4.1 2016/12/18 07:01:57 snj Exp $"); #include "opt_mtrr.h" @@ -249,6 +249,12 @@ cpu_lwp_free(struct lwp *l, int proc) if (proc && l->l_proc->p_md.md_flags & MDP_USEDMTRR) mtrr_clean(l->l_proc); #endif + /* + * Free deferred mappings if any. + */ + struct vm_page *empty_ptps = l->l_md.md_gc_ptp; + l->l_md.md_gc_ptp = NULL; + pmap_free_ptps(empty_ptps); } /*
CVS commit: src/external/intel-fw-public/iwl3160
Module Name:src Committed By: nonaka Date: Sun Dec 18 06:56:43 UTC 2016 Modified Files: src/external/intel-fw-public/iwl3160: Makefile Added Files: src/external/intel-fw-public/iwl3160/dist: iwlwifi-3160-16.ucode Log Message: iwm(4): Add new 3160 firmware... To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/external/intel-fw-public/iwl3160/Makefile cvs rdiff -u -r0 -r1.1 \ src/external/intel-fw-public/iwl3160/dist/iwlwifi-3160-16.ucode Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/intel-fw-public/iwl3160/Makefile diff -u src/external/intel-fw-public/iwl3160/Makefile:1.1 src/external/intel-fw-public/iwl3160/Makefile:1.2 --- src/external/intel-fw-public/iwl3160/Makefile:1.1 Fri Feb 13 18:57:47 2015 +++ src/external/intel-fw-public/iwl3160/Makefile Sun Dec 18 06:56:43 2016 @@ -1,9 +1,9 @@ -# $NetBSD: Makefile,v 1.1 2015/02/13 18:57:47 nonaka Exp $ +# $NetBSD: Makefile,v 1.2 2016/12/18 06:56:43 nonaka Exp $ NOMAN= # define FILES= dist/LICENSE.iwlwifi-3160-ucode dist/README.iwlwifi-3160-ucode \ - dist/iwlwifi-3160-9.ucode + dist/iwlwifi-3160-9.ucode dist/iwlwifi-3160-16.ucode FILESDIR= /libdata/firmware/if_iwm Added files: Index: src/external/intel-fw-public/iwl3160/dist/iwlwifi-3160-16.ucode Binary files are different
CVS commit: [netbsd-7] src/share/man/man3
Module Name:src Committed By: snj Date: Sun Dec 18 06:52:03 UTC 2016 Modified Files: src/share/man/man3 [netbsd-7]: bits.3 Log Message: Pull up following revision(s) (requested by riastradh in ticket #1315): share/man/man3/bits.3: revision 1.17 These have been able to handle uintmax-width masks since creation. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.16.4.1 src/share/man/man3/bits.3 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/man3/bits.3 diff -u src/share/man/man3/bits.3:1.16 src/share/man/man3/bits.3:1.16.4.1 --- src/share/man/man3/bits.3:1.16 Tue Mar 18 18:20:39 2014 +++ src/share/man/man3/bits.3 Sun Dec 18 06:52:03 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: bits.3,v 1.16 2014/03/18 18:20:39 riastradh Exp $ +.\" $NetBSD: bits.3,v 1.16.4.1 2016/12/18 06:52:03 snj Exp $ .\" .\" Copyright (c) 2006, 2010 David Young. All rights reserved. .\" @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd October 17, 2012 +.Dd November 6, 2016 .Dt BITS 3 .Os .Sh NAME @@ -146,8 +146,3 @@ contributed the macro names .Fn SHIFTIN and .Fn SHIFTOUT . -.Sh BUGS -.Fn __BIT -and -.Fn __BITS -can only express 32-bit bitmasks.
CVS commit: [netbsd-7] src/share/man/man9
Module Name:src Committed By: snj Date: Sun Dec 18 06:43:24 UTC 2016 Modified Files: src/share/man/man9 [netbsd-7]: fileassoc.9 Log Message: Pull up following revision(s) (requested by riastradh in ticket #1314): share/man/man9/fileassoc.9: revision 1.28 Merge changes from David H. Gutteridge in PR misc/51611 Thanks! To generate a diff of this commit: cvs rdiff -u -r1.27 -r1.27.4.1 src/share/man/man9/fileassoc.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/fileassoc.9 diff -u src/share/man/man9/fileassoc.9:1.27 src/share/man/man9/fileassoc.9:1.27.4.1 --- src/share/man/man9/fileassoc.9:1.27 Tue Mar 18 18:20:40 2014 +++ src/share/man/man9/fileassoc.9 Sun Dec 18 06:43:24 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: fileassoc.9,v 1.27 2014/03/18 18:20:40 riastradh Exp $ +.\" $NetBSD: fileassoc.9,v 1.27.4.1 2016/12/18 06:43:24 snj Exp $ .\" .\" Copyright (c) 2006 Elad Efrat .\" All rights reserved. @@ -25,12 +25,12 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd January 26, 2010 +.Dd November 7, 2016 .Dt FILEASSOC 9 .Os .Sh NAME .Nm fileassoc -.Nd in-kernel, file-system independent, file-meta data association +.Nd in-kernel, file system independent, file meta-data association .Sh SYNOPSIS .In sys/fileassoc.h .Ft int @@ -56,12 +56,12 @@ .Sh DESCRIPTION The .Nm -KPI allows association of meta-data with files independent of file-system +KPI allows association of meta-data with files independent of file system support for such elaborate meta-data. .Pp When plugging a new fileassoc to the system, a developer can specify private data to be associated with every file, as well as (potentially different) -private data to be associated with every file-system mount. +private data to be associated with every file system mount. .Pp For example, a developer might choose to associate a custom ACL with every file, and a count of total files with ACLs with the mount. @@ -88,7 +88,7 @@ KPI it is important to keep in mind that management only for .Nm internal memory. -Any additional memory stored in the tables (such as private data-structures +Any additional memory stored in the tables (such as private data structures used by custom fileassocs) should be allocated and freed by the developer. .Pp .Nm @@ -172,7 +172,7 @@ from .Pp If specified, the fileassoc's .Dq cleanup routine -will be called with a pointer to the private data-structure. +will be called with a pointer to the private data structure. .Pp .It Fn fileassoc_table_run "mp" "id" "cb" "cookie" For each entry for @@ -225,7 +225,7 @@ for the fileassoc specified by .Pp If specified, the fileassoc's .Dq cleanup routine -will be called with a pointer to the private data-structure and indication of +will be called with a pointer to the private data structure and indication of .Dv FILEASSOC_CLEANUP_FILE . .El .Sh EXAMPLES @@ -334,6 +334,8 @@ The .Nm is implemented within .Pa src/sys/kern/kern_fileassoc.c . +.Sh SEE ALSO +.Xr veriexec 9 .Sh HISTORY The .Nm
CVS commit: [netbsd-7] src/usr.sbin/paxctl
Module Name:src Committed By: snj Date: Sun Dec 18 06:41:33 UTC 2016 Modified Files: src/usr.sbin/paxctl [netbsd-7]: paxctl.8 Log Message: Pull up following revision(s) (requested by riastradh in ticket #1313): usr.sbin/paxctl/paxctl.8: revision 1.15 Merge changes from David H. Gutteridge in PR misc/51612 Thanks! To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.14.4.1 src/usr.sbin/paxctl/paxctl.8 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/paxctl/paxctl.8 diff -u src/usr.sbin/paxctl/paxctl.8:1.14 src/usr.sbin/paxctl/paxctl.8:1.14.4.1 --- src/usr.sbin/paxctl/paxctl.8:1.14 Tue Mar 18 18:20:47 2014 +++ src/usr.sbin/paxctl/paxctl.8 Sun Dec 18 06:41:33 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: paxctl.8,v 1.14 2014/03/18 18:20:47 riastradh Exp $ +.\" $NetBSD: paxctl.8,v 1.14.4.1 2016/12/18 06:41:33 snj Exp $ .\" .\" Copyright 2006 Elad Efrat .\" Copyright 2008 Christos Zoulas @@ -23,7 +23,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd September 17, 2009 +.Dd November 7, 2016 .Dt PAXCTL 8 .Os .Sh NAME @@ -110,8 +110,9 @@ The utility currently uses .Xr elf 5 .Dq note -sections to mark executables as PaX Segvguard enabled. +sections to mark executables as having PaX flags enabled. This will be done using .Xr fileassoc 9 in the future so that we can control who does the marking and -not altering the binary file signature. +not altering the binary file signature. (Note this also means that +at present any flags set do not survive binary file upgrades.)
CVS commit: [netbsd-7] src/external/bsd/nvi
Module Name:src Committed By: snj Date: Sun Dec 18 06:37:30 UTC 2016 Modified Files: src/external/bsd/nvi [netbsd-7]: Makefile.inc src/external/bsd/nvi/dist/cl [netbsd-7]: cl.h cl_main.c cl_screen.c cl_term.c src/external/bsd/nvi/dist/common [netbsd-7]: key.h vi_db1.c src/external/bsd/nvi/dist/docs/vi.man [netbsd-7]: vi.1 src/external/bsd/nvi/dist/ex [netbsd-7]: ex_map.c ex_script.c src/external/bsd/nvi/usr.bin/nvi [netbsd-7]: Makefile Log Message: Pull up following revision(s) (requested by riastradh in ticket #1312): external/bsd/nvi/Makefile.inc: revisions 1.2-1.4 external/bsd/nvi/dist/cl/cl.h: revision 1.3 external/bsd/nvi/dist/cl/cl_main.c: revision 1.5 external/bsd/nvi/dist/cl/cl_screen.c: revision 1.5 external/bsd/nvi/dist/cl/cl_term.c: revision 1.5 external/bsd/nvi/dist/common/key.h: revision 1.3 external/bsd/nvi/dist/common/vi_db1.c: revision 1.8 external/bsd/nvi/dist/docs/vi.man/vi.1: revisions 1.3, 1.4 external/bsd/nvi/dist/ex/ex_map.c: revision 1.4 external/bsd/nvi/dist/ex/ex_script.c: revisions 1.5, 1.6 external/bsd/nvi/usr.bin/nvi/Makefile: revision 1.7 PR/50092: Rin Okuyama: Fix memory leaks in vi when resizing. -- PR/50484: Rin Okuyama: fix the script command of vi(1) -- Fix > 1024 char lines in script. (Rin Okuyama) -- remove CONST; it is unused from Brad Harder -- add default: to appease gcc. -- Restore the first line of the copyright header, which accidentally got zapped in -r1.2. -- PR 51446 Brad Harder: fix synopsis for :tagprev To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.1.6.1 src/external/bsd/nvi/Makefile.inc cvs rdiff -u -r1.2 -r1.2.6.1 src/external/bsd/nvi/dist/cl/cl.h cvs rdiff -u -r1.4 -r1.4.6.1 src/external/bsd/nvi/dist/cl/cl_main.c \ src/external/bsd/nvi/dist/cl/cl_screen.c \ src/external/bsd/nvi/dist/cl/cl_term.c cvs rdiff -u -r1.2 -r1.2.6.1 src/external/bsd/nvi/dist/common/key.h cvs rdiff -u -r1.7 -r1.7.6.1 src/external/bsd/nvi/dist/common/vi_db1.c cvs rdiff -u -r1.2 -r1.2.6.1 src/external/bsd/nvi/dist/docs/vi.man/vi.1 cvs rdiff -u -r1.3 -r1.3.6.1 src/external/bsd/nvi/dist/ex/ex_map.c cvs rdiff -u -r1.4 -r1.4.6.1 src/external/bsd/nvi/dist/ex/ex_script.c cvs rdiff -u -r1.5 -r1.5.2.1 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/Makefile.inc diff -u src/external/bsd/nvi/Makefile.inc:1.1 src/external/bsd/nvi/Makefile.inc:1.1.6.1 --- src/external/bsd/nvi/Makefile.inc:1.1 Fri Nov 22 16:00:45 2013 +++ src/external/bsd/nvi/Makefile.inc Sun Dec 18 06:37:30 2016 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.1 2013/11/22 16:00:45 christos Exp $ +# $NetBSD: Makefile.inc,v 1.1.6.1 2016/12/18 06:37:30 snj Exp $ .include @@ -7,4 +7,4 @@ DIST= ${NETBSDSRCDIR}/external/bsd/nvi/d BINDIR=/usr/bin CWARNFLAGS.clang+= -Wno-error=unused-const-variable -VERSION=1.81.6-2013-11-20 +VERSION=1.81.6-2013-11-20nb3 Index: src/external/bsd/nvi/dist/cl/cl.h diff -u src/external/bsd/nvi/dist/cl/cl.h:1.2 src/external/bsd/nvi/dist/cl/cl.h:1.2.6.1 --- src/external/bsd/nvi/dist/cl/cl.h:1.2 Fri Nov 22 15:52:05 2013 +++ src/external/bsd/nvi/dist/cl/cl.h Sun Dec 18 06:37:30 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: cl.h,v 1.2 2013/11/22 15:52:05 christos Exp $ */ +/* $NetBSD: cl.h,v 1.2.6.1 2016/12/18 06:37:30 snj Exp $ */ /*- * Copyright (c) 1993, 1994 * The Regents of the University of California. All rights reserved. @@ -42,6 +42,8 @@ typedef struct _cl_private { struct termios ex_enter;/* Terminal values to enter ex. */ struct termios vi_enter;/* Terminal values to enter vi. */ + SCREEN *screen; /* Curses screen. */ + char *el; /* Clear to EOL terminal string. */ char *cup; /* Cursor movement terminal string. */ char *cuu1; /* Cursor up terminal string. */ @@ -77,6 +79,8 @@ typedef struct _cl_private { #define CL_SIGTERM 0x0100 /* SIGTERM arrived. */ #define CL_SIGWINCH 0x0200 /* SIGWINCH arrived. */ #define CL_STDIN_TTY 0x0400 /* Talking to a terminal. */ +#define CL_SETUPTERM 0x0800 /* Terminal initialized. */ +#define CL_CHANGE_TERM 0x1000 /* Terminal changed. */ u_int32_t flags; } CL_PRIVATE; Index: src/external/bsd/nvi/dist/cl/cl_main.c diff -u src/external/bsd/nvi/dist/cl/cl_main.c:1.4 src/external/bsd/nvi/dist/cl/cl_main.c:1.4.6.1 --- src/external/bsd/nvi/dist/cl/cl_main.c:1.4 Sun Jan 26 21:43:45 2014 +++ src/external/bsd/nvi/dist/cl/cl_main.c Sun Dec 18 06:37:30 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: cl_main.c,v 1.4 2014/01/26 21:43:45 christos Exp $ */ +/* $NetBSD: cl_main.c,v 1.4.6.1 2016/12/18 06:37:30 snj Exp $ */ /*- * Copyright (c) 1993, 1994 * The Regents of the University of California. All rights reserved. @@ -16,7 +16,7 @@ static const char sccsid[] = "Id: cl_main.c,v 10.54 2001/07/29 19:07:27 skimo Exp (Berkeley) Date: 2
CVS commit: [netbsd-7] src/lib/libc/stdlib
Module Name:src Committed By: snj Date: Sun Dec 18 06:31:01 UTC 2016 Modified Files: src/lib/libc/stdlib [netbsd-7]: strtod.3 strtol.3 strtoul.3 Log Message: Pull up following revision(s) (requested by riastradh in ticket #1311): lib/libc/stdlib/strtod.3: revisions 1.21-1.29 lib/libc/stdlib/strtol.3: revision 1.36-1.38 lib/libc/stdlib/strtoul.3: revision 1.36 strtod yields ERANGE for below-subnormal magnitudes, not underflow. For a floating-point computation, in the language of IEEE 754, `underflow' means the output was rounded and is too small to be represented *normally*. There are many nonzero floating-point numbers to which the exact output may have been rounded -- namely subnormals. The condition under which strtod returns ERANGE for small magnitudes is when the magnitude of the exact result is so small it is rounded to zero, not even to a subnormal. While here, use parallel language about large magnitudes instead of the (albeit correct) word `overflow', to avoid temptation to treat `underflow' as the opposite notion with zero instead of infinity. -- Bump date for previous. -- Fix description of ERANGE cases again. Do use the technical terms `overflow' and `underflow', because strtod sets ERANGE precisely to indicate either of these two conditions, and they are the right keywords that one might be looking for. Note that strtod may set ERANGE even if it returns noninfinity and nonzero -- specifically, if the result is subnormal. This part was wrong before I `fixed' it and remained wrong after I `fixed' it earlier this year. -- Add example for strtod. This illustrates all the cases you might be interested in and asserts theorems in those cases. -- Fix infinity detection with isinf(d), not d == HUGE_VAL. Negative infinity counts as overflow too. Simplify. -- EXIT_FAILURE police -- Distinguish altogether invalid syntax from trailing garbage. -- Distinguish invalid syntax from trailing garbage cases. Clarify. -- Simplify error condition case. Add assertions to reflect its implications. -- Tidy up the second example too. -- Update strtoul(3) example to reflect clarifications in strtol(3). -- Fix phrasing about `out-of-band' and `sentinel value'. Either an out-of-band channel, or an in-band sentinel value, could indicate an error, but an out-of-band sentinel value is a silly proposition. Noted by uwe@. -- Use the keywords `underflow' and `overflow' in ERANGE summary. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.20.50.1 src/lib/libc/stdlib/strtod.3 cvs rdiff -u -r1.26.24.2 -r1.26.24.3 src/lib/libc/stdlib/strtol.3 cvs rdiff -u -r1.25.24.2 -r1.25.24.3 src/lib/libc/stdlib/strtoul.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/stdlib/strtod.3 diff -u src/lib/libc/stdlib/strtod.3:1.20 src/lib/libc/stdlib/strtod.3:1.20.50.1 --- src/lib/libc/stdlib/strtod.3:1.20 Wed Oct 24 13:42:10 2007 +++ src/lib/libc/stdlib/strtod.3 Sun Dec 18 06:31:01 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: strtod.3,v 1.20 2007/10/24 13:42:10 reed Exp $ +.\" $NetBSD: strtod.3,v 1.20.50.1 2016/12/18 06:31:01 snj Exp $ .\" .\" Copyright (c) 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -33,7 +33,7 @@ .\" .\" from: @(#)strtod.3 8.1 (Berkeley) 6/4/93 .\" -.Dd March 12, 2006 +.Dd November 4, 2016 .Dt STRTOD 3 .Os .Sh NAME @@ -151,7 +151,9 @@ If no conversion is performed, zero is r is stored in the location referenced by .Fa endptr . .Pp -If the correct value would cause overflow, plus or minus +If the correct value is too large in magnitude to be represented +.Pq Sq overflow , +plus or minus .Dv HUGE_VAL , .Dv HUGE_VALF , or @@ -160,15 +162,58 @@ is returned (according to the return typ .Dv ERANGE is stored in .Va errno . -If the correct value would cause underflow, zero is -returned and +.Pp +If the correct value is too small in magnitude to be represented +normally with full precision +.Pq Sq underflow , +the closest subnormal value, or zero, is returned, and .Dv ERANGE is stored in .Va errno . +.Sh EXAMPLES +Since there is no out-of-band channel or sentinel value to indicate an +error, callers who wish to know whether there was overflow or underflow +must set +.Va errno +to zero before calling +.Fn strtod , +.Fn strtof , +or +.Fn strtold ; +in the case of no underflow or overflow, these functions preserve +.Va errno . +.Pp +To check for syntax errors, callers must +.Em also +check whether +.Fa endptr +was updated to reflect the true end of the string in order to determine +whether the full string was consumed or whether there were additional +erroneous characters in it. +.Bd -literal -offset abcd +char *end; +double d; + +\&... + +errno = 0; +d = strtod(s, &end); +if (end == s) + errx(EXIT_FAILURE, "invalid syntax"); +if (end[0] != '\e0') + errx(EXIT_FAILURE, "trailing garbage"); +if (errno) { + assert(errno ==
CVS commit: [netbsd-7] src/common/lib/libc/stdlib
Module Name:src Committed By: snj Date: Sun Dec 18 06:23:23 UTC 2016 Modified Files: src/common/lib/libc/stdlib [netbsd-7]: _strtoul.h Log Message: Pull up following revision(s) (requested by riastradh in ticket #1310): common/lib/libc/stdlib/_strtoul.h: revision 1.10 Set *endptr in all paths out of strtoul and family. XXX pullup-6 XXX pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.7.6.1 src/common/lib/libc/stdlib/_strtoul.h 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/stdlib/_strtoul.h diff -u src/common/lib/libc/stdlib/_strtoul.h:1.7 src/common/lib/libc/stdlib/_strtoul.h:1.7.6.1 --- src/common/lib/libc/stdlib/_strtoul.h:1.7 Fri May 17 12:55:56 2013 +++ src/common/lib/libc/stdlib/_strtoul.h Sun Dec 18 06:23:22 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: _strtoul.h,v 1.7 2013/05/17 12:55:56 joerg Exp $ */ +/* $NetBSD: _strtoul.h,v 1.7.6.1 2016/12/18 06:23:22 snj Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -67,7 +67,10 @@ INT_FUNCNAME(_int_, _FUNCNAME, _l)(const if (base && (base < 2 || base > 36)) { #if !defined(_KERNEL) && !defined(_STANDALONE) errno = EINVAL; - return(0); + if (endptr != NULL) + /* LINTED interface specification */ + *endptr = __UNCONST(nptr); + return 0; #else panic("%s: invalid base %d", __func__, base); #endif
CVS commit: src/sys/kern
Module Name:src Committed By: dholland Date: Sun Dec 18 05:43:20 UTC 2016 Modified Files: src/sys/kern: vfs_bio.c Log Message: typo in comment To generate a diff of this commit: cvs rdiff -u -r1.262 -r1.263 src/sys/kern/vfs_bio.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/kern/vfs_bio.c diff -u src/sys/kern/vfs_bio.c:1.262 src/sys/kern/vfs_bio.c:1.263 --- src/sys/kern/vfs_bio.c:1.262 Fri Oct 28 20:17:27 2016 +++ src/sys/kern/vfs_bio.c Sun Dec 18 05:43:20 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_bio.c,v 1.262 2016/10/28 20:17:27 jdolecek Exp $ */ +/* $NetBSD: vfs_bio.c,v 1.263 2016/12/18 05:43:20 dholland Exp $ */ /*- * Copyright (c) 2007, 2008, 2009 The NetBSD Foundation, Inc. @@ -123,7 +123,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vfs_bio.c,v 1.262 2016/10/28 20:17:27 jdolecek Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_bio.c,v 1.263 2016/12/18 05:43:20 dholland Exp $"); #ifdef _KERNEL_OPT #include "opt_bufcache.h" @@ -1524,7 +1524,7 @@ biowait(buf_t *bp) * process, invokes a procedure specified in the buffer structure" ] * * In real life, the pagedaemon (or other system processes) wants - * to do async stuff to, and doesn't want the buffer brelse()'d. + * to do async stuff too, and doesn't want the buffer brelse()'d. * (for swap pager, that puts swap buffers on the free lists (!!!), * for the vn device, that puts allocated buffers on the free lists!) */
CVS commit: src/sys/arch/amd64/conf
Module Name:src Committed By: dholland Date: Sun Dec 18 04:35:26 UTC 2016 Modified Files: src/sys/arch/amd64/conf: ALL GENERIC GENERIC_USERMODE INSTALL MODULAR XEN3_DOM0 XEN3_DOMU Log Message: Whitespace. To generate a diff of this commit: cvs rdiff -u -r1.45 -r1.46 src/sys/arch/amd64/conf/ALL cvs rdiff -u -r1.447 -r1.448 src/sys/arch/amd64/conf/GENERIC cvs rdiff -u -r1.1 -r1.2 src/sys/arch/amd64/conf/GENERIC_USERMODE cvs rdiff -u -r1.90 -r1.91 src/sys/arch/amd64/conf/INSTALL cvs rdiff -u -r1.5 -r1.6 src/sys/arch/amd64/conf/MODULAR cvs rdiff -u -r1.124 -r1.125 src/sys/arch/amd64/conf/XEN3_DOM0 cvs rdiff -u -r1.66 -r1.67 src/sys/arch/amd64/conf/XEN3_DOMU 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/conf/ALL diff -u src/sys/arch/amd64/conf/ALL:1.45 src/sys/arch/amd64/conf/ALL:1.46 --- src/sys/arch/amd64/conf/ALL:1.45 Thu Dec 15 04:01:09 2016 +++ src/sys/arch/amd64/conf/ALL Sun Dec 18 04:35:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: ALL,v 1.45 2016/12/15 04:01:09 ozaki-r Exp $ +# $NetBSD: ALL,v 1.46 2016/12/18 04:35:26 dholland Exp $ # From NetBSD: GENERIC,v 1.787 2006/10/01 18:37:54 bouyer Exp # # ALL machine description file @@ -17,7 +17,7 @@ include "arch/amd64/conf/std.amd64" options INCLUDE_CONFIG_FILE # embed config file in kernel binary -#ident "ALL-$Revision: 1.45 $" +#ident "ALL-$Revision: 1.46 $" maxusers 64 # estimated number of users @@ -208,7 +208,7 @@ options LFS_EXTATTR # extended attribut options LFS_QUOTA # quotas for LFS - experimental options LFS_QUOTA2 # new-style quotas for LFS - experimental options NFSSERVER # Network File System server -#options FFS_NO_SNAPSHOT # No FFS snapshot support +#options FFS_NO_SNAPSHOT # No FFS snapshot support options EXT2FS_SYSTEM_FLAGS # makes ext2fs file flags (append and # immutable) behave as system flags. options V7FS_EI # V7FS Endian Independent support @@ -233,7 +233,7 @@ options IPFILTER_COMPAT # Compat for IP options IPFILTER_DEFAULT_BLOCK # block all packets by default options TCP_DEBUG # Record last TCP_NDEBUG packets with SO_DEBUG options TCP_SIGNATURE # RFC 2385 support, used with BGP -options SCTP # Stream Control Transmission Protocol +options SCTP # Stream Control Transmission Protocol options ALTQ # Manipulate network interfaces' output queues options ALTQ_BLUE # Stochastic Fair Blue @@ -382,7 +382,7 @@ com* at acpi? # Serial communications fdc* at acpi? # Floppy disk controller fujbp* at acpi? # Fujitsu Brightness & Pointer fujhk* at acpi? # Fujitsu Hotkeys -hpacel* at acpi? # HP 3D DriveGuard accelerometer +hpacel* at acpi? # HP 3D DriveGuard accelerometer hpqlb* at acpi? # HP Quick Launch Buttons hpet* at acpihpetbus? # High Precision Event Timer (table) hpet* at acpinodebus? # High Precision Event Timer (device) @@ -442,7 +442,7 @@ options PCI_INTR_FIXUP # fixup PCI int # Temperatures amdnb_misc* at pci? # AMD NB Misc Configuration -amdtemp* at amdnb_misc? # AMD CPU Temperature sensors +amdtemp* at amdnb_misc? # AMD CPU Temperature sensors # PCI bridges amdpcib* at pci? dev ? function ? # AMD 8111 PCI-ISA w/ HPET @@ -1181,7 +1181,7 @@ cue* at uhub? port ? # CATC USB-EL1201A kue* at uhub? port ? # Kawasaki LSI KL5KUSB101B based adapters udav* at uhub? port ? # Davicom DM9601 based adapters url* at uhub? port ? # Realtek RTL8150L based adapters -urndis* at uhub? port ? # Microsoft RNDIS specification +urndis* at uhub? port ? # Microsoft RNDIS specification # USB 802.11 adapters atu* at uhub? port ? # Atmel AT76C50XX based adapters @@ -1504,7 +1504,7 @@ satlink0 at isa? port 0x300 drq 1 weasel* at pci? # Virtio devices -virtio* at pci? dev ? function ? # Virtio PCI device +virtio* at pci? dev ? function ? # Virtio PCI device viomb* at virtio? # Virtio memory balloon device ld* at virtio? # Virtio disk device vioif* at virtio? # Virtio network device Index: src/sys/arch/amd64/conf/GENERIC diff -u src/sys/arch/amd64/conf/GENERIC:1.447 src/sys/arch/amd64/conf/GENERIC:1.448 --- src/sys/arch/amd64/conf/GENERIC:1.447 Tue Dec 13 20:42:16 2016 +++ src/sys/arch/amd64/conf/GENERIC Sun Dec 18 04:35:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: GENERIC,v 1.447 2016/12/13 20:42:16 christos Exp $ +# $NetBSD: GENERIC,v 1.448 2016/12/18 04:35:26 dholland Exp $ # # GENERIC machine description file # @@ -22,7 +22,7 @@ include "arch/amd64/conf/std.amd64" options INCLUDE_CONFIG_FILE # embed config file in kernel binary -#ident "GENERIC-$Revision: 1.447 $" +#ident "GENERIC-$Revision: 1.448 $" maxusers 64 # estimated number of users @@ -60,7 +60,7 @@ options NTP # NTP phase/frequency lock options KTRACE # system call tracing via ktrace(1) -options CPU_UCODE # cpu ucode loading support +options CPU_UCODE # cpu ucode loading support # Note: SysV IPC parameters could be changed
CVS commit: src/external/gpl3/gcc/dist/gcc/config/rs6000
Module Name:src Committed By: rin Date: Sun Dec 18 03:00:58 UTC 2016 Modified Files: src/external/gpl3/gcc/dist/gcc/config/rs6000: rs6000.c Log Message: PR port-powerpc/51366 kernel for powerpc/ibm4xx miscompiled by gcc >= 4.8.5 backport fix from upstream: URL: https://gcc.gnu.org/viewcvs?rev=238789&root=gcc&view=rev Log: rs6000: Fix logic for when to emit .machine (PR71216) The current logic determining whether to use .machine in the generated asm code puts it there if the compiler is not configured with a default target cpu, _or_ no -mcpu= was given on the command line. It should be "and" instead. PR target/71216 * config/rs6000/rs6000.c (rs6000_file_start): Fix condition for when to emit a ".machine" pseudo-op. Modified: branches/gcc-5-branch/gcc/ChangeLog branches/gcc-5-branch/gcc/config/rs6000/rs6000.c To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 \ src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.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/config/rs6000/rs6000.c diff -u src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.15 src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.16 --- src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.15 Tue Jun 7 06:14:17 2016 +++ src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c Sun Dec 18 03:00:58 2016 @@ -5185,8 +5185,8 @@ rs6000_file_start (void) } #ifdef USING_ELFOS_H - if (rs6000_default_cpu == 0 || rs6000_default_cpu[0] == '\0' - || !global_options_set.x_rs6000_cpu_index) + if (!(rs6000_default_cpu && rs6000_default_cpu[0]) + && !global_options_set.x_rs6000_cpu_index) { fputs ("\t.machine ", asm_out_file); if ((rs6000_isa_flags & OPTION_MASK_DIRECT_MOVE) != 0)
CVS commit: src/sys/arch/ia64
Module Name:src Committed By: christos Date: Sun Dec 18 02:26:12 UTC 2016 Modified Files: src/sys/arch/ia64: Makefile Log Message: Descend into compile To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/sys/arch/ia64/Makefile 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/ia64/Makefile diff -u src/sys/arch/ia64/Makefile:1.2 src/sys/arch/ia64/Makefile:1.3 --- src/sys/arch/ia64/Makefile:1.2 Tue Jun 20 11:26:19 2006 +++ src/sys/arch/ia64/Makefile Sat Dec 17 21:26:12 2016 @@ -1,5 +1,5 @@ -# $NetBSD: Makefile,v 1.2 2006/06/20 15:26:19 skrll Exp $ +# $NetBSD: Makefile,v 1.3 2016/12/18 02:26:12 christos Exp $ -SUBDIR= include stand +SUBDIR= compile include stand .include
CVS commit: src
Module Name:src Committed By: christos Date: Sun Dec 18 02:20:30 UTC 2016 Modified Files: src: build.sh Log Message: Add -P for reproducible builds based on the latest cvs timestamp. To generate a diff of this commit: cvs rdiff -u -r1.311 -r1.312 src/build.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/build.sh diff -u src/build.sh:1.311 src/build.sh:1.312 --- src/build.sh:1.311 Sun Nov 13 09:47:46 2016 +++ src/build.sh Sat Dec 17 21:20:30 2016 @@ -1,5 +1,5 @@ #! /usr/bin/env sh -# $NetBSD: build.sh,v 1.311 2016/11/13 14:47:46 ast Exp $ +# $NetBSD: build.sh,v 1.312 2016/12/18 02:20:30 christos Exp $ # # Copyright (c) 2001-2011 The NetBSD Foundation, Inc. # All rights reserved. @@ -1003,7 +1003,7 @@ usage() fi cat <<_usage_ -Usage: ${progname} [-EhnorUuxy] [-a arch] [-B buildid] [-C cdextras] +Usage: ${progname} [-EhnoPRrUuxy] [-a arch] [-B buildid] [-C cdextras] [-D dest] [-j njob] [-M obj] [-m mach] [-N noisy] [-O obj] [-R release] [-S seed] [-T tools] [-V var=[value]] [-w wrapper] [-X x11src] [-Y extsrcsrc] @@ -1078,6 +1078,8 @@ Usage: ${progname} [-EhnorUuxy] [-a arch -O obj Set obj root directory to obj; sets a MAKEOBJDIR pattern. Unsets MAKEOBJDIRPREFIX. -o Set MKOBJDIRS=no; do not create objdirs at start of build. +-P Set MKREPRO and MKREPRO_TIMESTAMP to the latest source + CVS timestamp for reproducible builds. -R release Set RELEASEDIR to release. [Default: releasedir] -r Remove contents of TOOLDIR and DESTDIR before building. -S seedSet BUILDSEED to seed. [Default: NetBSD-majorversion] @@ -1103,7 +1105,7 @@ _usage_ parseoptions() { - opts='a:B:C:D:Ehj:M:m:N:nO:oR:rS:T:UuV:w:X:xY:yZ:' + opts='a:B:C:D:Ehj:M:m:N:nO:oPR:rS:T:UuV:w:X:xY:yZ:' opt_a=false opt_m=false @@ -1219,6 +1221,10 @@ parseoptions() MKOBJDIRS=no ;; + -P) + MKREPRO=yes + ;; + -R) eval ${optargcmd}; resolvepath OPTARG setmakeenv RELEASEDIR "${OPTARG}" @@ -1435,38 +1441,20 @@ sanitycheck() ;; esac } - # print_tooldir_make -- # Try to find and print a path to an existing -# ${TOOLDIR}/bin/${toolprefix}make, for use by rebuildmake() before a -# new version of ${toolprefix}make has been built. -# -# * If TOOLDIR was set in the environment or on the command line, use -# that value. -# * Otherwise try to guess what TOOLDIR would be if not overridden by -# /etc/mk.conf, and check whether the resulting directory contains -# a copy of ${toolprefix}make (this should work for everybody who -# doesn't override TOOLDIR via /etc/mk.conf); -# * Failing that, search for ${toolprefix}make, nbmake, bmake, or make, -# in the PATH (this might accidentally find a version of make that -# does not understand the syntax used by NetBSD make, and that will -# lead to failure in the next step); -# * If a copy of make was found above, try to use it with -# nobomb_getmakevar to find the correct value for TOOLDIR, and believe the -# result only if it's a directory that already exists; -# * If a value of TOOLDIR was found above, and if -# ${TOOLDIR}/bin/${toolprefix}make exists, print that value. -# -print_tooldir_make() +# ${TOOLDIR}/bin/${toolprefix}program +print_tooldir_program() { local possible_TOP_OBJ local possible_TOOLDIR - local possible_make - local tooldir_make + local possible_program + local tooldir_program + local program=${1} if [ -n "${TOOLDIR}" ]; then - echo "${TOOLDIR}/bin/${toolprefix}make" - return 0 + echo "${TOOLDIR}/bin/${toolprefix}${program}" + return fi # Set host_ostype to something like "NetBSD-4.5.6-i386". This @@ -1479,8 +1467,8 @@ print_tooldir_make() )" # Look in a few potential locations for - # ${possible_TOOLDIR}/bin/${toolprefix}make. - # If we find it, then set possible_make. + # ${possible_TOOLDIR}/bin/${toolprefix}${program}. + # If we find it, then set possible_program. # # In the usual case (without interference from environment # variables or /etc/mk.conf), should set TOOLDIR to @@ -1501,14 +1489,42 @@ print_tooldir_make() do [ -n "${possible_TOP_OBJ}" ] || continue possible_TOOLDIR="${possible_TOP_OBJ}/tooldir.${host_ostype}" - possible_make="${possible_TOOLDIR}/bin/${toolprefix}make" + possible_program="${possible_TOOLDIR}/bin/${toolprefix}${program}" if [ -x "${possible_make}" ]; then - break - else - unset possible_make + echo ${possible_program} + return; fi done + echo "" +} +# print_tooldir_make -- +# Try to find and print a path to an existing +# ${TOOLDIR}/bin/${toolprefix}make, for use by rebuildmake() before a +# new version of ${toolprefix}make has been built. +# +# * If TOOLDIR was set in the environment or on the command line, use +# that value. +# * Otherwise try to guess what
CVS commit: src/sbin/ping6
Module Name:src Committed By: dholland Date: Sun Dec 18 01:30:54 UTC 2016 Modified Files: src/sbin/ping6: ping6.c Log Message: Merge the PR 36997 fixes into ping6. It already didn't accept too small or wildly too large intervals, but it did allow intervals that failed at poll(). Since that's signed integer overflow and thus UB, better not to. To generate a diff of this commit: cvs rdiff -u -r1.92 -r1.93 src/sbin/ping6/ping6.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/ping6/ping6.c diff -u src/sbin/ping6/ping6.c:1.92 src/sbin/ping6/ping6.c:1.93 --- src/sbin/ping6/ping6.c:1.92 Mon Feb 29 16:25:06 2016 +++ src/sbin/ping6/ping6.c Sun Dec 18 01:30:54 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ping6.c,v 1.92 2016/02/29 16:25:06 riastradh Exp $ */ +/* $NetBSD: ping6.c,v 1.93 2016/12/18 01:30:54 dholland Exp $ */ /* $KAME: ping6.c,v 1.164 2002/11/16 14:05:37 itojun Exp $ */ /* @@ -77,7 +77,7 @@ static char sccsid[] = "@(#)ping.c 8.1 ( #else #include #ifndef lint -__RCSID("$NetBSD: ping6.c,v 1.92 2016/02/29 16:25:06 riastradh Exp $"); +__RCSID("$NetBSD: ping6.c,v 1.93 2016/12/18 01:30:54 dholland Exp $"); #endif #endif @@ -297,6 +297,7 @@ main(int argc, char *argv[]) { struct addrinfo hints; u_int i, packlen; + long l; int ch, hold, preload, optval, ret_ga; u_char *datap, *packet; char *e, *target, *ifname = NULL, *gateway = NULL; @@ -400,10 +401,16 @@ main(int argc, char *argv[]) #endif break; case 'c': - npackets = strtol(optarg, &e, 10); - if (npackets <= 0 || *optarg == '\0' || *e != '\0') + l = strtol(optarg, &e, 10); + if (l <= 0 || *optarg == '\0' || *e != '\0') errx(1, "illegal number of packets -- %s", optarg); +#if INT_MAX < LONG_MAX + if (l > INT_MAX) +errx(EXIT_FAILURE, +"Too many packets to count: %ld", l); +#endif + npackets = l; break; case 'd': options |= F_SO_DEBUG; @@ -447,15 +454,18 @@ main(int argc, char *argv[]) errx(1, "%s: only root may use interval < 1s", strerror(EPERM)); } - interval.tv_sec = (long)intval; + if (intval > INT_MAX/1000.0 - 1.0) { +errx(1, "Interval %s too large", optarg); + } + interval.tv_sec = (time_t)intval; interval.tv_nsec = (long)((intval - interval.tv_sec) * 10); - if (interval.tv_sec < 0) + if (interval.tv_sec < 0 || interval.tv_nsec < 0) errx(1, "illegal timing interval %s", optarg); /* less than 1/hz does not make sense */ if (interval.tv_sec == 0 && interval.tv_nsec < 1000) { -warnx("too small interval, raised to 0.01"); +warnx("Interval too small; raised to 0.01"); interval.tv_nsec = 1000; } options |= F_INTERVAL; @@ -465,9 +475,15 @@ main(int argc, char *argv[]) errno = EPERM; errx(1, "Must be superuser to preload"); } - preload = strtol(optarg, &e, 10); - if (preload < 0 || *optarg == '\0' || *e != '\0') + l = strtol(optarg, &e, 10); + if (l < 0 || *optarg == '\0' || *e != '\0') errx(1, "illegal preload value -- %s", optarg); +#if INT_MAX < LONG_MAX + if (l > INT_MAX) +errx(EXIT_FAILURE, +"Too many preload packets: %ld", l); +#endif + preload = l; break; case 'm': #ifdef IPV6_USE_MIN_MTU
CVS commit: src/sbin/ping
Module Name:src Committed By: dholland Date: Sun Dec 18 01:19:34 UTC 2016 Modified Files: src/sbin/ping: ping.c Log Message: PR bin/36997 Zafer Aydogan: ping doesn't validate numeric inputs enough. Reject packet intervals < 1 ns as they lead to infinite loops adding zero timespecs. Fix the behind-schedule behavior so it doesn't spend all its time in that loop adding very small timespecs. Try ping -c 500 -i 0.1 to see this in action with the old ping. To generate a diff of this commit: cvs rdiff -u -r1.113 -r1.114 src/sbin/ping/ping.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/ping/ping.c diff -u src/sbin/ping/ping.c:1.113 src/sbin/ping/ping.c:1.114 --- src/sbin/ping/ping.c:1.113 Sun Dec 18 00:21:33 2016 +++ src/sbin/ping/ping.c Sun Dec 18 01:19:34 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ping.c,v 1.113 2016/12/18 00:21:33 dholland Exp $ */ +/* $NetBSD: ping.c,v 1.114 2016/12/18 01:19:34 dholland Exp $ */ /* * Copyright (c) 1989, 1993 @@ -58,7 +58,7 @@ #include #ifndef lint -__RCSID("$NetBSD: ping.c,v 1.113 2016/12/18 00:21:33 dholland Exp $"); +__RCSID("$NetBSD: ping.c,v 1.114 2016/12/18 01:19:34 dholland Exp $"); #endif #include @@ -461,6 +461,9 @@ main(int argc, char *argv[]) errx(EXIT_FAILURE, "Must be superuser to use -l"); #endif sec_to_timespec(interval, &interval_tv); + if (interval_tv.tv_sec == 0 && interval_tv.tv_nsec == 0) { + errx(EXIT_FAILURE, "Packet interval must be at least 1 ns"); + } if ((pingflags & (F_AUDIBLE|F_FLOOD)) == (F_AUDIBLE|F_FLOOD)) warnx("Sorry, no audible output for flood pings"); @@ -893,6 +896,8 @@ pinger(void) { struct tv32 tv32; int i, cc, sw; + double waittime; + long numskip; opack_icmp.icmp_code = 0; opack_icmp.icmp_seq = htons((u_int16_t)(ntransmitted)); @@ -976,10 +981,32 @@ pinger(void) * If we are at most 100 ms behind, send extras to get caught up. * Otherwise, skip packets we were too slow to send. */ - if (diffsec(&next_tx, &now) <= interval) { - do { - timespecadd(&next_tx, &interval_tv, &next_tx); - } while (diffsec(&next_tx, &now) < -0.1); + waittime = diffsec(&next_tx, &now); + if (waittime < -1.0) { + /* very behind - forget about being precise */ + next_tx.tv_sec += (int)(-waittime); + } else if (waittime < -0.1) { + /* behind - skip a few */ + if (interval_tv.tv_sec == 0) { + numskip = (long)(-waittime / interval_tv.tv_nsec); + next_tx.tv_nsec += numskip * interval_tv.tv_nsec; + /* + * We can add at most one second's worth, but allow + * for tv_nsec reaching 2 billion just in case FP + * issues strike. + */ + while (next_tx.tv_nsec >= 10) { +next_tx.tv_sec++; +next_tx.tv_nsec -= 10; + } + } else { + do { +timespecadd(&next_tx, &interval_tv, &next_tx); + } while (diffsec(&next_tx, &now) < -0.1); + } + + } else if (waittime <= interval) { + timespecadd(&next_tx, &interval_tv, &next_tx); } if (pingflags & F_FLOOD)
CVS commit: src/sbin/ping
Module Name:src Committed By: dholland Date: Sun Dec 18 00:21:33 UTC 2016 Modified Files: src/sbin/ping: ping.c Log Message: PR bin/36997 Zafer Aydogan: ping doesn't validate numeric inputs enough. Check for values between INT_MAX and LONG_MAX (if they're different) when using strtol to get an int. This applies to the -c and -l options; the other uses were already checked. Also limit the inter-packet interval given with -i to values that don't cause integer overflow calling poll() with milliseconds. Really large intervals (the number is read as floating point) can produce positive poll() values but negative integers when converted to struct timespec; this produces behavior akin to using -l at first and could be construed as a local DoS vulnerability. To generate a diff of this commit: cvs rdiff -u -r1.112 -r1.113 src/sbin/ping/ping.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/ping/ping.c diff -u src/sbin/ping/ping.c:1.112 src/sbin/ping/ping.c:1.113 --- src/sbin/ping/ping.c:1.112 Fri Oct 7 22:31:05 2016 +++ src/sbin/ping/ping.c Sun Dec 18 00:21:33 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ping.c,v 1.112 2016/10/07 22:31:05 joerg Exp $ */ +/* $NetBSD: ping.c,v 1.113 2016/12/18 00:21:33 dholland Exp $ */ /* * Copyright (c) 1989, 1993 @@ -58,7 +58,7 @@ #include #ifndef lint -__RCSID("$NetBSD: ping.c,v 1.112 2016/10/07 22:31:05 joerg Exp $"); +__RCSID("$NetBSD: ping.c,v 1.113 2016/12/18 00:21:33 dholland Exp $"); #endif #include @@ -295,11 +295,17 @@ main(int argc, char *argv[]) compat = 1; break; case 'c': - npackets = strtol(optarg, &p, 0); - if (*p != '\0' || npackets <= 0) + l = strtol(optarg, &p, 0); + if (*p != '\0' || l <= 0) errx(EXIT_FAILURE, "Bad/invalid number of packets: %s", optarg); +#if INT_MAX < LONG_MAX + if (l > INT_MAX) +errx(EXIT_FAILURE, +"Too many packets to count: %ld", l); +#endif + npackets = l; break; case 'D': pingflags |= F_DF; @@ -318,12 +324,27 @@ main(int argc, char *argv[]) if (*p != '\0' || interval <= 0) errx(EXIT_FAILURE, "Bad/invalid interval: %s", optarg); + /* + * In order to avoid overflowing the microseconds + * argument of poll() the interval must be less than + * INT_MAX/1000. Limit it to one second less than + * that to be safe. + */ + if (interval >= INT_MAX/1000.0 - 1.0) +errx(EXIT_FAILURE, +"Timing interval %g too large", interval); break; case 'l': - preload = strtol(optarg, &p, 0); - if (*p != '\0' || preload < 0) + l = strtol(optarg, &p, 0); + if (*p != '\0' || l < 0) errx(EXIT_FAILURE, "Bad/invalid preload value: " "%s", optarg); +#if INT_MAX < LONG_MAX + if (l > INT_MAX) +errx(EXIT_FAILURE, +"Too many preload packets: %ld", l); +#endif + preload = l; break; case 'n': pingflags |= F_NUMERIC;
CVS commit: src/sys/arch/ia64/stand/ia64/ski
Module Name:src Committed By: christos Date: Sat Dec 17 18:41:13 UTC 2016 Modified Files: src/sys/arch/ia64/stand/ia64/ski: Makefile Log Message: XXX: Can't do PIE yet because of gp relocation in start.S To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/ia64/stand/ia64/ski/Makefile 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/ia64/stand/ia64/ski/Makefile diff -u src/sys/arch/ia64/stand/ia64/ski/Makefile:1.5 src/sys/arch/ia64/stand/ia64/ski/Makefile:1.6 --- src/sys/arch/ia64/stand/ia64/ski/Makefile:1.5 Fri Aug 5 13:08:10 2016 +++ src/sys/arch/ia64/stand/ia64/ski/Makefile Sat Dec 17 13:41:13 2016 @@ -4,6 +4,7 @@ VERSIONFILE= ${.CURDIR}/version .include "../Makefile.booters" +NOPIE= yes PROG= skiload MAN=# BINDIR?= /usr/mdec
CVS commit: src/usr.sbin/makemandb
Module Name:src Committed By: abhinav Date: Sat Dec 17 17:04:38 UTC 2016 Modified Files: src/usr.sbin/makemandb: makemandb.c Log Message: Don't ignore symlinks. There can be symlinks which are pointing to man pages not installed in one of the _default locations mentioned in man.conf or MANPATH. For example there are man pages in /usr/pkg/man which are symlinked to pages in /usr/pkg/lib/perl5/man. If we ignore symlinks, we would not be able to index such pages installed outside the default set of directories. (Also, the symlink test was incorecct, so we never noticed this issue) Ok christos@, wiz@ To generate a diff of this commit: cvs rdiff -u -r1.44 -r1.45 src/usr.sbin/makemandb/makemandb.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/makemandb/makemandb.c diff -u src/usr.sbin/makemandb/makemandb.c:1.44 src/usr.sbin/makemandb/makemandb.c:1.45 --- src/usr.sbin/makemandb/makemandb.c:1.44 Mon Oct 3 16:11:11 2016 +++ src/usr.sbin/makemandb/makemandb.c Sat Dec 17 17:04:38 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: makemandb.c,v 1.44 2016/10/03 16:11:11 abhinav Exp $ */ +/* $NetBSD: makemandb.c,v 1.45 2016/12/17 17:04:38 abhinav Exp $ */ /* * Copyright (c) 2011 Abhinav Upadhyay * Copyright (c) 2011 Kristaps Dzonsons @@ -17,7 +17,7 @@ */ #include -__RCSID("$NetBSD: makemandb.c,v 1.44 2016/10/03 16:11:11 abhinav Exp $"); +__RCSID("$NetBSD: makemandb.c,v 1.45 2016/12/17 17:04:38 abhinav Exp $"); #include #include @@ -526,9 +526,10 @@ traversedir(const char *parent, const ch } } closedir(dp); + return; } - if (!S_ISREG(sb.st_mode) && !S_ISLNK(sb.st_mode)) + if (!S_ISREG(sb.st_mode)) return; if (sb.st_size == 0) { @@ -820,15 +821,8 @@ update_db(sqlite3 *db, struct mparse *mp if (md5_status == 0) { /* * The MD5 hash is already present in the database, - * so simply update the metadata, ignoring symlinks. + * so simply update the metadata. */ - struct stat sb; - stat(file, &sb); - if (S_ISLNK(sb.st_mode)) { -free(md5sum); -link_count++; -continue; - } update_existing_entry(db, file, md5sum, rec, &new_count, &link_count, &err_count); free(md5sum); @@ -867,12 +861,12 @@ update_db(sqlite3 *db, struct mparse *mp } if (mflags.verbosity == 2) { - printf("Total Number of new or updated pages encountered = %d\n" - "Total number of (hard or symbolic) links found = %d\n" - "Total number of pages that were successfully" - " indexed/updated = %d\n" - "Total number of pages that could not be indexed" - " due to errors = %d\n", + printf("Number of new or updated pages encountered: %d\n" + "Number of hard links found: %d\n" + "Number of pages that were successfully" + " indexed or updated: %d\n" + "Number of pages that could not be indexed" + " due to errors: %d\n", total_count - link_count, link_count, new_count, err_count); }
CVS commit: src/sys/dev
Module Name:src Committed By: maya Date: Sat Dec 17 17:04:04 UTC 2016 Modified Files: src/sys/dev: audio.c Log Message: audio: don't use an uninitialized variable. PR kern/51717: audioattach erroneously fails due to uninitialized variable from flxd. while here, switch to use aprint_error_dev. To generate a diff of this commit: cvs rdiff -u -r1.284 -r1.285 src/sys/dev/audio.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/audio.c diff -u src/sys/dev/audio.c:1.284 src/sys/dev/audio.c:1.285 --- src/sys/dev/audio.c:1.284 Sat Dec 17 16:08:29 2016 +++ src/sys/dev/audio.c Sat Dec 17 17:04:04 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: audio.c,v 1.284 2016/12/17 16:08:29 christos Exp $ */ +/* $NetBSD: audio.c,v 1.285 2016/12/17 17:04:04 maya Exp $ */ /*- * Copyright (c) 2016 Nathanial Sloss @@ -148,7 +148,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.284 2016/12/17 16:08:29 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.285 2016/12/17 17:04:04 maya Exp $"); #include "audio.h" #if NAUDIO > 0 @@ -575,7 +575,8 @@ bad_play: if (sc->sc_pr.s.start != NULL) audio_free_ring(sc, &sc->sc_pr); sc->hw_if = NULL; - aprint_error("audio: could not allocate play buffer\n"); + aprint_error_dev(sc->sc_dev, "could not allocate play " + "buffer\n"); return; } } @@ -596,8 +597,8 @@ bad_rec: if (sc->sc_vchan[0]->sc_mpr.s.start != 0) audio_free_ring(sc, &sc->sc_vchan[0]->sc_mpr); sc->hw_if = NULL; - aprint_error("audio: could not allocate record " - "buffer\n"); + aprint_error_dev(sc->sc_dev, "could not allocate record" + " buffer\n"); return; } } @@ -605,11 +606,12 @@ bad_rec: sc->sc_lastgain = 128; sc->sc_saturate = true; - audio_set_vchan_defaults(sc, AUMODE_PLAY | AUMODE_PLAY_ALL | + error = audio_set_vchan_defaults(sc, AUMODE_PLAY | AUMODE_PLAY_ALL | AUMODE_RECORD, &vaudio_formats[0], 0); mutex_exit(sc->sc_lock); if (error != 0) { - aprint_error("audioattach: audio_set_defaults() failed\n"); + aprint_error_dev(sc->sc_dev, "%s: audio_set_vchan_defaults() " + "failed\n", __func__); sc->hw_if = NULL; return; }
CVS commit: src/sys/dev
Module Name:src Committed By: christos Date: Sat Dec 17 16:08:29 UTC 2016 Modified Files: src/sys/dev: audio.c Log Message: factor out duplicated code. To generate a diff of this commit: cvs rdiff -u -r1.283 -r1.284 src/sys/dev/audio.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/audio.c diff -u src/sys/dev/audio.c:1.283 src/sys/dev/audio.c:1.284 --- src/sys/dev/audio.c:1.283 Sat Dec 17 10:18:28 2016 +++ src/sys/dev/audio.c Sat Dec 17 11:08:29 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: audio.c,v 1.283 2016/12/17 15:18:28 christos Exp $ */ +/* $NetBSD: audio.c,v 1.284 2016/12/17 16:08:29 christos Exp $ */ /*- * Copyright (c) 2016 Nathanial Sloss @@ -148,7 +148,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.283 2016/12/17 15:18:28 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.284 2016/12/17 16:08:29 christos Exp $"); #include "audio.h" #if NAUDIO > 0 @@ -5619,6 +5619,18 @@ recswvol_func(struct audio_softc *sc, st } } +static uint8_t * +find_vchan_vol(struct audio_softc *sc, int d) +{ + size_t j, n = (size_t)d / 2; + + for (size_t i = j = 0; i <= n; i++) + if (sc->sc_audiopid[i].pid != -1) + j++; + + return (d & 1) == 0 ? + &sc->sc_vchan[j]->sc_swvol : &sc->sc_vchan[j]->sc_recswvol; +} static int audio_set_port(struct audio_softc *sc, mixer_ctrl_t *mc) @@ -5630,20 +5642,13 @@ audio_set_port(struct audio_softc *sc, m if (d < 0) return sc->hw_if->set_port(sc->hw_hdl, mc); - size_t j, n = (size_t)d / 2; - - for (size_t i = j = 0; i <= n; i++) - if (sc->sc_audiopid[i].pid != -1) - j++; - uint8_t *level = &mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; - uint8_t *vol = (d & 1) == 0 ? - &sc->sc_vchan[j]->sc_swvol : &sc->sc_vchan[j]->sc_recswvol; - + uint8_t *vol = find_vchan_vol(sc, d); *vol = *level; return 0; } + static int audio_get_port(struct audio_softc *sc, mixer_ctrl_t *mc) { @@ -5655,16 +5660,8 @@ audio_get_port(struct audio_softc *sc, m if (d < 0) return sc->hw_if->get_port(sc->hw_hdl, mc); - size_t j, n = (size_t)d / 2; - - for (size_t i = j = 0; i <= n; i++) - if (sc->sc_audiopid[i].pid != -1) - j++; - u_char *level = &mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; - uint8_t *vol = (d & 1) == 0 ? - &sc->sc_vchan[j]->sc_swvol : &sc->sc_vchan[j]->sc_recswvol; - + uint8_t *vol = find_vchan_vol(sc, d); *level = *vol; return 0;
CVS commit: [nick-nhusb] src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sat Dec 17 15:30:34 UTC 2016 Modified Files: src/sys/dev/usb [nick-nhusb]: if_athn_usb.c Log Message: Call {mutex,cv}_destroy on all mutexes/condvars To generate a diff of this commit: cvs rdiff -u -r1.6.8.14 -r1.6.8.15 src/sys/dev/usb/if_athn_usb.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/usb/if_athn_usb.c diff -u src/sys/dev/usb/if_athn_usb.c:1.6.8.14 src/sys/dev/usb/if_athn_usb.c:1.6.8.15 --- src/sys/dev/usb/if_athn_usb.c:1.6.8.14 Sun Dec 11 15:10:43 2016 +++ src/sys/dev/usb/if_athn_usb.c Sat Dec 17 15:30:34 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: if_athn_usb.c,v 1.6.8.14 2016/12/11 15:10:43 skrll Exp $ */ +/* $NetBSD: if_athn_usb.c,v 1.6.8.15 2016/12/17 15:30:34 skrll Exp $ */ /* $OpenBSD: if_athn_usb.c,v 1.12 2013/01/14 09:50:31 jsing Exp $ */ /*- @@ -22,7 +22,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.6.8.14 2016/12/11 15:10:43 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.6.8.15 2016/12/17 15:30:34 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -499,8 +499,15 @@ athn_usb_detach(device_t self, int flags athn_usb_close_pipes(usc); mutex_destroy(&usc->usc_tx_mtx); - mutex_destroy(&usc->usc_task_mtx); cv_destroy(&usc->usc_task_cv); + mutex_destroy(&usc->usc_task_mtx); + + mutex_destroy(&usc->usc_cmd_mtx); + cv_destroy(&usc->usc_cmd_cv); + mutex_destroy(&usc->usc_msg_mtx); + cv_destroy(&usc->usc_msg_cv); + + mutex_destroy(&usc->usc_lock); usbd_add_drv_event(USB_EVENT_DRIVER_DETACH, usc->usc_udev, sc->sc_dev); return 0;
CVS commit: src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sat Dec 17 15:27:26 UTC 2016 Modified Files: src/sys/dev/usb: if_athn_usb.c Log Message: Call {mutex,cv}_destroy on all mutexes/condvars To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/dev/usb/if_athn_usb.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/usb/if_athn_usb.c diff -u src/sys/dev/usb/if_athn_usb.c:1.18 src/sys/dev/usb/if_athn_usb.c:1.19 --- src/sys/dev/usb/if_athn_usb.c:1.18 Sun Dec 11 15:01:37 2016 +++ src/sys/dev/usb/if_athn_usb.c Sat Dec 17 15:27:26 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: if_athn_usb.c,v 1.18 2016/12/11 15:01:37 skrll Exp $ */ +/* $NetBSD: if_athn_usb.c,v 1.19 2016/12/17 15:27:26 skrll Exp $ */ /* $OpenBSD: if_athn_usb.c,v 1.12 2013/01/14 09:50:31 jsing Exp $ */ /*- @@ -22,7 +22,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.18 2016/12/11 15:01:37 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.19 2016/12/17 15:27:26 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -499,8 +499,15 @@ athn_usb_detach(device_t self, int flags athn_usb_close_pipes(usc); mutex_destroy(&usc->usc_tx_mtx); - mutex_destroy(&usc->usc_task_mtx); cv_destroy(&usc->usc_task_cv); + mutex_destroy(&usc->usc_task_mtx); + + mutex_destroy(&usc->usc_cmd_mtx); + cv_destroy(&usc->usc_cmd_cv); + mutex_destroy(&usc->usc_msg_mtx); + cv_destroy(&usc->usc_msg_cv); + + mutex_destroy(&usc->usc_lock); usbd_add_drv_event(USB_EVENT_DRIVER_DETACH, usc->usc_udev, sc->sc_dev); return 0;
CVS commit: src/sys/arch/arm
Module Name:src Committed By: riastradh Date: Sat Dec 17 15:24:35 UTC 2016 Modified Files: src/sys/arch/arm/broadcom: bcm2835_rng.c src/sys/arch/arm/nvidia: tegra124_car.c src/sys/arch/arm/omap: am335x_trng.c Log Message: Simplify bcm2835, tegra, and am335x hardware RNG drivers. Tested by nick@. To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/broadcom/bcm2835_rng.c cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra124_car.c cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/omap/am335x_trng.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/broadcom/bcm2835_rng.c diff -u src/sys/arch/arm/broadcom/bcm2835_rng.c:1.11 src/sys/arch/arm/broadcom/bcm2835_rng.c:1.12 --- src/sys/arch/arm/broadcom/bcm2835_rng.c:1.11 Mon Apr 13 21:18:40 2015 +++ src/sys/arch/arm/broadcom/bcm2835_rng.c Sat Dec 17 15:24:35 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: bcm2835_rng.c,v 1.11 2015/04/13 21:18:40 riastradh Exp $ */ +/* $NetBSD: bcm2835_rng.c,v 1.12 2016/12/17 15:24:35 riastradh Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: bcm2835_rng.c,v 1.11 2015/04/13 21:18:40 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: bcm2835_rng.c,v 1.12 2016/12/17 15:24:35 riastradh Exp $"); #include #include @@ -39,8 +39,6 @@ __KERNEL_RCSID(0, "$NetBSD: bcm2835_rng. #include #include #include -#include -#include #include #include @@ -60,19 +58,13 @@ struct bcm2835rng_softc { bus_space_tag_t sc_iot; bus_space_handle_t sc_ioh; - kmutex_t sc_intr_lock; - unsigned int sc_bytes_wanted; - void *sc_sih; - - kmutex_t sc_rnd_lock; + kmutex_t sc_lock; krndsource_t sc_rndsource; }; static int bcmrng_match(device_t, cfdata_t, void *); static void bcmrng_attach(device_t, device_t, void *); -static void bcmrng_get(struct bcm2835rng_softc *); -static void bcmrng_get_cb(size_t, void *); -static void bcmrng_get_intr(void *); +static void bcmrng_get(size_t, void *); CFATTACH_DECL_NEW(bcmrng_amba, sizeof(struct bcm2835rng_softc), bcmrng_match, bcmrng_attach, NULL, NULL); @@ -105,7 +97,7 @@ bcmrng_attach(device_t parent, device_t if (bus_space_map(aaa->aaa_iot, aaa->aaa_addr, BCM2835_RNG_SIZE, 0, &sc->sc_ioh)) { aprint_error_dev(sc->sc_dev, "unable to map device\n"); - goto fail0; + return; } /* discard initial numbers, broadcom says they are "less random" */ @@ -116,41 +108,25 @@ bcmrng_attach(device_t parent, device_t ctrl |= RNG_CTRL_EN; bus_space_write_4(sc->sc_iot, sc->sc_ioh, RNG_CTRL, ctrl); - /* set up a softint for adding data */ - mutex_init(&sc->sc_intr_lock, MUTEX_DEFAULT, IPL_SERIAL); - sc->sc_bytes_wanted = 0; - sc->sc_sih = softint_establish(SOFTINT_SERIAL|SOFTINT_MPSAFE, - &bcmrng_get_intr, sc); - if (sc->sc_sih == NULL) { - aprint_error_dev(sc->sc_dev, "unable to establish softint"); - goto fail1; - } - /* set up an rndsource */ - mutex_init(&sc->sc_rnd_lock, MUTEX_DEFAULT, IPL_SERIAL); - rndsource_setcb(&sc->sc_rndsource, &bcmrng_get_cb, sc); + mutex_init(&sc->sc_lock, MUTEX_DEFAULT, IPL_VM); + rndsource_setcb(&sc->sc_rndsource, &bcmrng_get, sc); rnd_attach_source(&sc->sc_rndsource, device_xname(self), RND_TYPE_RNG, RND_FLAG_COLLECT_VALUE|RND_FLAG_HASCB); /* get some initial entropy ASAP */ - bcmrng_get_cb(RND_POOLBITS / NBBY, sc); - - /* Success! */ - return; - -fail1: mutex_destroy(&sc->sc_intr_lock); - bus_space_unmap(aaa->aaa_iot, sc->sc_ioh, BCM2835_RNG_SIZE); -fail0: return; + bcmrng_get(RND_POOLBITS / NBBY, sc); } static void -bcmrng_get(struct bcm2835rng_softc *sc) +bcmrng_get(size_t bytes_wanted, void *arg) { + struct bcm2835rng_softc *sc = arg; uint32_t status, cnt; uint32_t buf[RNG_DATA_MAX]; /* 1k on the stack */ - mutex_spin_enter(&sc->sc_intr_lock); - while (sc->sc_bytes_wanted) { + mutex_spin_enter(&sc->sc_lock); + while (bytes_wanted) { status = bus_space_read_4(sc->sc_iot, sc->sc_ioh, RNG_STATUS); cnt = __SHIFTOUT(status, RNG_STATUS_CNT); KASSERT(cnt < RNG_DATA_MAX); @@ -158,46 +134,10 @@ bcmrng_get(struct bcm2835rng_softc *sc) continue; /* XXX Busy-waiting seems wrong... */ bus_space_read_multi_4(sc->sc_iot, sc->sc_ioh, RNG_DATA, buf, cnt); - - /* - * This lock dance is necessary because rnd_add_data - * may call bcmrng_get_cb which takes the intr lock. - */ - mutex_spin_exit(&sc->sc_intr_lock); - mutex_spin_enter(&sc->sc_rnd_lock); - rnd_add_data(&sc->sc_rndsource, buf, (cnt * 4), + rnd_add_data_sync(&sc->sc_rndsource, buf, (cnt * 4), (cnt * 4 * NBBY)); - mutex_spin_exit(&sc->sc_rnd_lock); - mutex_spin_enter(&sc->sc_intr_lock); - sc->sc_bytes_wanted -= MIN(sc->sc_bytes_wanted, (cnt * 4)); + bytes_wanted -= MIN(bytes_wanted, (cnt * 4)); } explicit_memset(buf, 0, sizeof(buf)); - mutex_spin_exit(&sc->sc_intr_lock); -} - -static v
CVS commit: src/sys/arch/x86/x86
Module Name:src Committed By: maxv Date: Sat Dec 17 15:23:08 UTC 2016 Modified Files: src/sys/arch/x86/x86: identcpu.c Log Message: Remove a wrong comment - the FPU save size should never be percpu -, and be more explicit about Xen. To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 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.50 src/sys/arch/x86/x86/identcpu.c:1.51 --- src/sys/arch/x86/x86/identcpu.c:1.50 Fri Jan 1 19:46:48 2016 +++ src/sys/arch/x86/x86/identcpu.c Sat Dec 17 15:23:08 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: identcpu.c,v 1.50 2016/01/01 19:46:48 tls Exp $ */ +/* $NetBSD: identcpu.c,v 1.51 2016/12/17 15:23:08 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.50 2016/01/01 19:46:48 tls Exp $"); +__KERNEL_RCSID(0, "$NetBSD: identcpu.c,v 1.51 2016/12/17 15:23:08 maxv Exp $"); #include "opt_xen.h" @@ -760,10 +760,12 @@ cpu_probe_fpu(struct cpu_info *ci) /* Get features and maximum size of the save area */ x86_cpuid(0xd, descs); - /* XXX these probably ought to be per-cpu */ if (descs[2] > 512) - x86_fpu_save_size = descs[2]; -#ifndef XEN + x86_fpu_save_size = descs[2]; + +#ifdef XEN + /* Don't use xsave, force fxsave with x86_xsave_features = 0. */ +#else x86_xsave_features = (uint64_t)descs[3] << 32 | descs[0]; #endif }
CVS commit: src/sys/dev
Module Name:src Committed By: christos Date: Sat Dec 17 15:18:28 UTC 2016 Modified Files: src/sys/dev: audio.c Log Message: fix broken, audio_{g,s}et_port logic. To generate a diff of this commit: cvs rdiff -u -r1.282 -r1.283 src/sys/dev/audio.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/audio.c diff -u src/sys/dev/audio.c:1.282 src/sys/dev/audio.c:1.283 --- src/sys/dev/audio.c:1.282 Fri Dec 16 17:14:15 2016 +++ src/sys/dev/audio.c Sat Dec 17 10:18:28 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: audio.c,v 1.282 2016/12/16 22:14:15 christos Exp $ */ +/* $NetBSD: audio.c,v 1.283 2016/12/17 15:18:28 christos Exp $ */ /*- * Copyright (c) 2016 Nathanial Sloss @@ -148,7 +148,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.282 2016/12/16 22:14:15 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: audio.c,v 1.283 2016/12/17 15:18:28 christos Exp $"); #include "audio.h" #if NAUDIO > 0 @@ -5623,63 +5623,51 @@ recswvol_func(struct audio_softc *sc, st static int audio_set_port(struct audio_softc *sc, mixer_ctrl_t *mc) { - int i, j, n; - KASSERT(mutex_owned(sc->sc_lock)); - if (mc->dev >= sc->sc_static_nmixer_states) { - n = (mc->dev - sc->sc_static_nmixer_states) / 2; - i = j = 0; - while (i <= n) { - j++; - if (sc->sc_audiopid[j].pid != -1) -i++; - } - n = j; + int d = mc->dev - sc->sc_static_nmixer_states; - if ((mc->dev - sc->sc_static_nmixer_states) % 2 == 0) { - sc->sc_vchan[n]->sc_swvol = - mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; - } else { - sc->sc_vchan[n]->sc_recswvol = - mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; - } + if (d < 0) + return sc->hw_if->set_port(sc->hw_hdl, mc); - return 0; - } + size_t j, n = (size_t)d / 2; + + for (size_t i = j = 0; i <= n; i++) + if (sc->sc_audiopid[i].pid != -1) + j++; + + uint8_t *level = &mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; + uint8_t *vol = (d & 1) == 0 ? + &sc->sc_vchan[j]->sc_swvol : &sc->sc_vchan[j]->sc_recswvol; - return sc->hw_if->set_port(sc->hw_hdl, mc); + *vol = *level; + return 0; } static int audio_get_port(struct audio_softc *sc, mixer_ctrl_t *mc) { - int i, j, n; KASSERT(mutex_owned(sc->sc_lock)); - if (mc->dev >= sc->sc_static_nmixer_states) { - n = (mc->dev - sc->sc_static_nmixer_states) / 2; - i = j = 0; - while (i <= n) { + int d = mc->dev - sc->sc_static_nmixer_states; + + if (d < 0) + return sc->hw_if->get_port(sc->hw_hdl, mc); + + size_t j, n = (size_t)d / 2; + + for (size_t i = j = 0; i <= n; i++) + if (sc->sc_audiopid[i].pid != -1) j++; - if (sc->sc_audiopid[j].pid != -1) -i++; - } - n = j; - if ((mc->dev - sc->sc_static_nmixer_states) % 2 == 0) { - mc->un.value.level[AUDIO_MIXER_LEVEL_MONO] = - sc->sc_vchan[n]->sc_swvol; - } else { - mc->un.value.level[AUDIO_MIXER_LEVEL_MONO] = - sc->sc_vchan[n]->sc_recswvol; - } + u_char *level = &mc->un.value.level[AUDIO_MIXER_LEVEL_MONO]; + uint8_t *vol = (d & 1) == 0 ? + &sc->sc_vchan[j]->sc_swvol : &sc->sc_vchan[j]->sc_recswvol; - return 0; - } + *level = *vol; + return 0; - return sc->hw_if->get_port(sc->hw_hdl, mc); } static int
CVS commit: src/sys/arch
Module Name:src Committed By: maxv Date: Sat Dec 17 14:49:26 UTC 2016 Modified Files: src/sys/arch/amd64/conf: XEN3_DOM0 XEN3_DOMU src/sys/arch/i386/conf: XEN3_DOM0 XEN3_DOMU Log Message: Add MODULAR in Xen kernels. To generate a diff of this commit: cvs rdiff -u -r1.123 -r1.124 src/sys/arch/amd64/conf/XEN3_DOM0 cvs rdiff -u -r1.65 -r1.66 src/sys/arch/amd64/conf/XEN3_DOMU cvs rdiff -u -r1.102 -r1.103 src/sys/arch/i386/conf/XEN3_DOM0 cvs rdiff -u -r1.69 -r1.70 src/sys/arch/i386/conf/XEN3_DOMU 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/conf/XEN3_DOM0 diff -u src/sys/arch/amd64/conf/XEN3_DOM0:1.123 src/sys/arch/amd64/conf/XEN3_DOM0:1.124 --- src/sys/arch/amd64/conf/XEN3_DOM0:1.123 Tue Dec 13 20:42:16 2016 +++ src/sys/arch/amd64/conf/XEN3_DOM0 Sat Dec 17 14:49:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: XEN3_DOM0,v 1.123 2016/12/13 20:42:16 christos Exp $ +# $NetBSD: XEN3_DOM0,v 1.124 2016/12/17 14:49:26 maxv Exp $ include "arch/amd64/conf/std.xen" @@ -40,6 +40,7 @@ options SYSVMSG # System V-like messag options SYSVSEM # System V-like semaphores options SYSVSHM # System V-like memory sharing +options MODULAR # new style module(7) framework options USERCONF # userconf(4) support options SYSCTL_INCLUDE_DESCR # Include sysctl descriptions in kernel Index: src/sys/arch/amd64/conf/XEN3_DOMU diff -u src/sys/arch/amd64/conf/XEN3_DOMU:1.65 src/sys/arch/amd64/conf/XEN3_DOMU:1.66 --- src/sys/arch/amd64/conf/XEN3_DOMU:1.65 Sat May 14 17:11:30 2016 +++ src/sys/arch/amd64/conf/XEN3_DOMU Sat Dec 17 14:49:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: XEN3_DOMU,v 1.65 2016/05/14 17:11:30 christos Exp $ +# $NetBSD: XEN3_DOMU,v 1.66 2016/12/17 14:49:26 maxv Exp $ include "arch/amd64/conf/std.xen" @@ -34,6 +34,7 @@ options SYSVMSG # System V-like messag options SYSVSEM # System V-like semaphores options SYSVSHM # System V-like memory sharing +options MODULAR # new style module(7) framework options USERCONF # userconf(4) support options SYSCTL_INCLUDE_DESCR # Include sysctl descriptions in kernel Index: src/sys/arch/i386/conf/XEN3_DOM0 diff -u src/sys/arch/i386/conf/XEN3_DOM0:1.102 src/sys/arch/i386/conf/XEN3_DOM0:1.103 --- src/sys/arch/i386/conf/XEN3_DOM0:1.102 Tue Dec 13 20:42:18 2016 +++ src/sys/arch/i386/conf/XEN3_DOM0 Sat Dec 17 14:49:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: XEN3_DOM0,v 1.102 2016/12/13 20:42:18 christos Exp $ +# $NetBSD: XEN3_DOM0,v 1.103 2016/12/17 14:49:26 maxv Exp $ # # XEN3_0: Xen 3.0 domain0 kernel @@ -56,6 +56,7 @@ options SYSVSEM # System V-like semaph options SYSVSHM # System V-like memory sharing #options SHMMAXPGS=2048 # 2048 pages is the default +options MODULAR # new style module(7) framework options USERCONF # userconf(4) support options SYSCTL_INCLUDE_DESCR # Include sysctl descriptions in kernel Index: src/sys/arch/i386/conf/XEN3_DOMU diff -u src/sys/arch/i386/conf/XEN3_DOMU:1.69 src/sys/arch/i386/conf/XEN3_DOMU:1.70 --- src/sys/arch/i386/conf/XEN3_DOMU:1.69 Wed Aug 12 07:53:57 2015 +++ src/sys/arch/i386/conf/XEN3_DOMU Sat Dec 17 14:49:26 2016 @@ -1,4 +1,4 @@ -# $NetBSD: XEN3_DOMU,v 1.69 2015/08/12 07:53:57 maxv Exp $ +# $NetBSD: XEN3_DOMU,v 1.70 2016/12/17 14:49:26 maxv Exp $ include "arch/xen/conf/std.xen" @@ -42,6 +42,7 @@ options SYSVSEM # System V-like semaph options SYSVSHM # System V-like memory sharing #options SHMMAXPGS=2048 # 2048 pages is the default +options MODULAR # new style module(7) framework options USERCONF # userconf(4) support options SYSCTL_INCLUDE_DESCR # Include sysctl descriptions in kernel
CVS commit: src/sys/arch
Module Name:src Committed By: flxd Date: Sat Dec 17 14:36:30 UTC 2016 Modified Files: src/sys/arch/alpha/include: cpu.h src/sys/arch/amiga/include: cpu.h src/sys/arch/arm/arm32: pmap.c src/sys/arch/cesfic/include: cpu.h src/sys/arch/evbcf/include: cpu.h src/sys/arch/hp300/include: cpu.h src/sys/arch/luna68k/include: cpu.h src/sys/arch/mac68k/include: cpu.h src/sys/arch/mvme68k/include: cpu.h src/sys/arch/news68k/include: cpu.h src/sys/arch/next68k/include: cpu.h src/sys/arch/x68k/include: cpu.h Log Message: Fix typo "one the" and architecture where appropriate. To generate a diff of this commit: cvs rdiff -u -r1.82 -r1.83 src/sys/arch/alpha/include/cpu.h cvs rdiff -u -r1.80 -r1.81 src/sys/arch/amiga/include/cpu.h cvs rdiff -u -r1.340 -r1.341 src/sys/arch/arm/arm32/pmap.c cvs rdiff -u -r1.29 -r1.30 src/sys/arch/cesfic/include/cpu.h cvs rdiff -u -r1.2 -r1.3 src/sys/arch/evbcf/include/cpu.h cvs rdiff -u -r1.68 -r1.69 src/sys/arch/hp300/include/cpu.h cvs rdiff -u -r1.32 -r1.33 src/sys/arch/luna68k/include/cpu.h cvs rdiff -u -r1.98 -r1.99 src/sys/arch/mac68k/include/cpu.h cvs rdiff -u -r1.48 -r1.49 src/sys/arch/mvme68k/include/cpu.h cvs rdiff -u -r1.42 -r1.43 src/sys/arch/news68k/include/cpu.h cvs rdiff -u -r1.47 -r1.48 src/sys/arch/next68k/include/cpu.h cvs rdiff -u -r1.58 -r1.59 src/sys/arch/x68k/include/cpu.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/alpha/include/cpu.h diff -u src/sys/arch/alpha/include/cpu.h:1.82 src/sys/arch/alpha/include/cpu.h:1.83 --- src/sys/arch/alpha/include/cpu.h:1.82 Wed Jan 22 22:52:04 2014 +++ src/sys/arch/alpha/include/cpu.h Sat Dec 17 14:36:29 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.h,v 1.82 2014/01/22 22:52:04 christos Exp $ */ +/* $NetBSD: cpu.h,v 1.83 2016/12/17 14:36:29 flxd Exp $ */ /*- * Copyright (c) 1998, 1999, 2000, 2001 The NetBSD Foundation, Inc. @@ -179,7 +179,7 @@ void cpu_pause_resume_all(int); /* * Arguments to hardclock and gatherstats encapsulate the previous - * machine state in an opaque clockframe. One the Alpha, we use + * machine state in an opaque clockframe. On the alpha, we use * what we push on an interrupt (a trapframe). */ struct clockframe { @@ -204,7 +204,7 @@ struct clockframe { /* * Give a profiling tick to the current process when the user profiling - * buffer pages are invalid. On the Alpha, request an AST to send us + * buffer pages are invalid. On the alpha, request an AST to send us * through trap, marking the proc as needing a profiling tick. */ #define cpu_need_proftick(l) \ Index: src/sys/arch/amiga/include/cpu.h diff -u src/sys/arch/amiga/include/cpu.h:1.80 src/sys/arch/amiga/include/cpu.h:1.81 --- src/sys/arch/amiga/include/cpu.h:1.80 Sat Oct 19 19:20:59 2013 +++ src/sys/arch/amiga/include/cpu.h Sat Dec 17 14:36:29 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.h,v 1.80 2013/10/19 19:20:59 christos Exp $ */ +/* $NetBSD: cpu.h,v 1.81 2016/12/17 14:36:29 flxd Exp $ */ /* * Copyright (c) 1988 University of Utah. @@ -59,7 +59,7 @@ extern volatile unsigned int interrupt_depth; /* * Arguments to hardclock and gatherstats encapsulate the previous - * machine state in an opaque clockframe. One the hp300, we use + * machine state in an opaque clockframe. On the amiga, we use * what the hardware pushes on an interrupt (frame format 0). */ struct clockframe { @@ -85,7 +85,7 @@ struct clockframe { /* * Give a profiling tick to the current process from the softclock - * interrupt. On hp300, request an ast to send us through trap(), + * interrupt. On the amiga, request an ast to send us through trap(), * marking the proc as needing a profiling tick. */ #define profile_tick(l, framep) ((l)->l_pflag |= LP_OWEUPC, setsoftast()) Index: src/sys/arch/arm/arm32/pmap.c diff -u src/sys/arch/arm/arm32/pmap.c:1.340 src/sys/arch/arm/arm32/pmap.c:1.341 --- src/sys/arch/arm/arm32/pmap.c:1.340 Thu Aug 4 08:46:06 2016 +++ src/sys/arch/arm/arm32/pmap.c Sat Dec 17 14:36:29 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.340 2016/08/04 08:46:06 skrll Exp $ */ +/* $NetBSD: pmap.c,v 1.341 2016/12/17 14:36:29 flxd Exp $ */ /* * Copyright 2003 Wasabi Systems, Inc. @@ -217,7 +217,7 @@ #include -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.340 2016/08/04 08:46:06 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.341 2016/12/17 14:36:29 flxd Exp $"); //#define PMAP_DEBUG #ifdef PMAP_DEBUG @@ -6522,7 +6522,7 @@ pmap_bootstrap_pv_page_free(struct pool * * This routine is called after the vm and kmem subsystems have been * initialised. This allows the pmap code to perform any initialisation - * that can only be done one the memory allocation is in place. + * that can only be done once the memory allocation is in place. */ void pmap_postinit(void) Index: src/sys/arch/cesfic/include/cp
CVS commit: src/sys/arch/i386/i386
Module Name:src Committed By: maxv Date: Sat Dec 17 14:27:53 UTC 2016 Modified Files: src/sys/arch/i386/i386: gdt.c machdep.c Log Message: Put a limit in the percpu segment, so we can detect overflows on %fs. To generate a diff of this commit: cvs rdiff -u -r1.55 -r1.56 src/sys/arch/i386/i386/gdt.c cvs rdiff -u -r1.768 -r1.769 src/sys/arch/i386/i386/machdep.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/i386/i386/gdt.c diff -u src/sys/arch/i386/i386/gdt.c:1.55 src/sys/arch/i386/i386/gdt.c:1.56 --- src/sys/arch/i386/i386/gdt.c:1.55 Sat Aug 20 19:46:54 2016 +++ src/sys/arch/i386/i386/gdt.c Sat Dec 17 14:27:53 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: gdt.c,v 1.55 2016/08/20 19:46:54 christos Exp $ */ +/* $NetBSD: gdt.c,v 1.56 2016/12/17 14:27:53 maxv Exp $ */ /*- * Copyright (c) 1996, 1997, 2009 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: gdt.c,v 1.55 2016/08/20 19:46:54 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: gdt.c,v 1.56 2016/12/17 14:27:53 maxv Exp $"); #include "opt_multiprocessor.h" #include "opt_xen.h" @@ -144,8 +144,8 @@ gdt_init(void) pmap_update(pmap_kernel()); memcpy(gdt, old_gdt, NGDT * sizeof(gdt[0])); ci->ci_gdt = gdt; - setsegment(&ci->ci_gdt[GCPU_SEL].sd, ci, 0xf, - SDT_MEMRWA, SEL_KPL, 1, 1); + setsegment(&ci->ci_gdt[GCPU_SEL].sd, ci, + sizeof(struct cpu_info) - 1, SDT_MEMRWA, SEL_KPL, 1, 0); gdt_init_cpu(ci); } @@ -175,8 +175,8 @@ gdt_alloc_cpu(struct cpu_info *ci) pmap_update(pmap_kernel()); memset(ci->ci_gdt, 0, min_len); memcpy(ci->ci_gdt, gdt, gdt_count[0] * sizeof(gdt[0])); - setsegment(&ci->ci_gdt[GCPU_SEL].sd, ci, 0xf, - SDT_MEMRWA, SEL_KPL, 1, 1); + setsegment(&ci->ci_gdt[GCPU_SEL].sd, ci, + sizeof(struct cpu_info) - 1, SDT_MEMRWA, SEL_KPL, 1, 0); } Index: src/sys/arch/i386/i386/machdep.c diff -u src/sys/arch/i386/i386/machdep.c:1.768 src/sys/arch/i386/i386/machdep.c:1.769 --- src/sys/arch/i386/i386/machdep.c:1.768 Fri Dec 16 19:52:22 2016 +++ src/sys/arch/i386/i386/machdep.c Sat Dec 17 14:27:53 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: machdep.c,v 1.768 2016/12/16 19:52:22 maxv Exp $ */ +/* $NetBSD: machdep.c,v 1.769 2016/12/17 14:27:53 maxv Exp $ */ /*- * Copyright (c) 1996, 1997, 1998, 2000, 2004, 2006, 2008, 2009 @@ -67,7 +67,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.768 2016/12/16 19:52:22 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.769 2016/12/17 14:27:53 maxv Exp $"); #include "opt_beep.h" #include "opt_compat_ibcs2.h" @@ -988,8 +988,8 @@ initgdt(union descriptor *tgdt) setsegment(&gdt[GBIOSDATA_SEL].sd, 0, 0xf, SDT_MEMRWA, SEL_KPL, 0, 0); #endif - setsegment(&gdt[GCPU_SEL].sd, &cpu_info_primary, 0xf, - SDT_MEMRWA, SEL_KPL, 1, 1); + setsegment(&gdt[GCPU_SEL].sd, &cpu_info_primary, + sizeof(struct cpu_info) - 1, SDT_MEMRWA, SEL_KPL, 1, 0); #ifndef XEN setregion(®ion, gdt, NGDT * sizeof(gdt[0]) - 1);
CVS commit: src/sys/arch/amd64/amd64
Module Name:src Committed By: maxv Date: Sat Dec 17 13:49:05 UTC 2016 Modified Files: src/sys/arch/amd64/amd64: locore.S Log Message: Fix the name of the labels. I think I got confused by jne, so while here replace it by jnz, which is more explicit. To generate a diff of this commit: cvs rdiff -u -r1.117 -r1.118 src/sys/arch/amd64/amd64/locore.S 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/locore.S diff -u src/sys/arch/amd64/amd64/locore.S:1.117 src/sys/arch/amd64/amd64/locore.S:1.118 --- src/sys/arch/amd64/amd64/locore.S:1.117 Fri Dec 16 19:52:22 2016 +++ src/sys/arch/amd64/amd64/locore.S Sat Dec 17 13:49:05 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: locore.S,v 1.117 2016/12/16 19:52:22 maxv Exp $ */ +/* $NetBSD: locore.S,v 1.118 2016/12/17 13:49:05 maxv Exp $ */ /* * Copyright-o-rama! @@ -1141,9 +1141,9 @@ skip_CR0: /* The 32bit LWPs are handled differently. */ testl $PCB_COMPAT32,PCB_FLAGS(%r14) - jne lwp_64bit + jnz lwp_32bit -lwp_32bit: +lwp_64bit: /* Zero out %fs/%gs registers. */ xorq %rax,%rax movw %ax,%fs @@ -1170,7 +1170,7 @@ lwp_32bit: jmp switch_return -lwp_64bit: +lwp_32bit: /* Reload %fs/%gs GDT descriptors. */ movq CPUVAR(GDT),%rcx movq PCB_FS(%r14),%rax
CVS commit: src/sys/arch/x86/x86
Module Name:src Committed By: maxv Date: Sat Dec 17 13:43:33 UTC 2016 Modified Files: src/sys/arch/x86/x86: pmap.c Log Message: Use pmap_bootstrap_valloc and simplify. By the way, I think the cache stuff is wrong, since the pte is not necessarily aligned to 64 bytes, so nothing guarantees there is no false sharing. To generate a diff of this commit: cvs rdiff -u -r1.232 -r1.233 src/sys/arch/x86/x86/pmap.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/pmap.c diff -u src/sys/arch/x86/x86/pmap.c:1.232 src/sys/arch/x86/x86/pmap.c:1.233 --- src/sys/arch/x86/x86/pmap.c:1.232 Fri Dec 16 19:52:22 2016 +++ src/sys/arch/x86/x86/pmap.c Sat Dec 17 13:43:33 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: pmap.c,v 1.232 2016/12/16 19:52:22 maxv Exp $ */ +/* $NetBSD: pmap.c,v 1.233 2016/12/17 13:43:33 maxv Exp $ */ /*- * Copyright (c) 2008, 2010, 2016 The NetBSD Foundation, Inc. @@ -171,7 +171,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.232 2016/12/16 19:52:22 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.233 2016/12/17 13:43:33 maxv Exp $"); #include "opt_user_ldt.h" #include "opt_lockdebug.h" @@ -1351,46 +1351,33 @@ pmap_bootstrap(vaddr_t kva_start) /* * Now we allocate the "special" VAs which are used for tmp mappings - * by the pmap (and other modules). We allocate the VAs by advancing - * virtual_avail (note that there are no pages mapped at these VAs). - * we find the PTE that maps the allocated VA via the linear PTE - * mapping. + * by pmap. We allocate the VAs, and find the PTE that maps them via + * the linear PTE mapping. */ - - pt_entry_t *pte = PTE_BASE + pl1_i(virtual_avail); + vaddr_t cpuva_base; + pt_entry_t *pte; #ifdef MULTIPROCESSOR /* - * Waste some VA space to avoid false sharing of cache lines - * for page table pages: Give each possible CPU a cache line - * of PTE's (8) to play with, though we only need 4. We could - * recycle some of this waste by putting the idle stacks here - * as well; we could waste less space if we knew the largest - * CPU ID beforehand. + * Waste some VA space to avoid false sharing of cache lines for page + * table pages: give each possible CPU a cache line of 8 PTEs to play + * with, though we only need 4. */ - csrcp = (char *) virtual_avail; csrc_pte = pte; - - cdstp = (char *) virtual_avail+PAGE_SIZE; cdst_pte = pte+1; - - zerop = (char *) virtual_avail+PAGE_SIZE*2; zero_pte = pte+2; - - ptpp = (char *) virtual_avail+PAGE_SIZE*3; ptp_pte = pte+3; - - virtual_avail += PAGE_SIZE * maxcpus * NPTECL; - pte += maxcpus * NPTECL; + cpuva_base = pmap_bootstrap_valloc(maxcpus * NPTECL); #else - csrcp = (void *) virtual_avail; csrc_pte = pte; /* allocate */ - virtual_avail += PAGE_SIZE; pte++; /* advance */ - - cdstp = (void *) virtual_avail; cdst_pte = pte; - virtual_avail += PAGE_SIZE; pte++; - - zerop = (void *) virtual_avail; zero_pte = pte; - virtual_avail += PAGE_SIZE; pte++; - - ptpp = (void *) virtual_avail; ptp_pte = pte; - virtual_avail += PAGE_SIZE; pte++; + cpuva_base = pmap_bootstrap_valloc(4); #endif + pte = PTE_BASE + pl1_i(cpuva_base); + + /* Values used to index the array */ + csrcp = (char *)cpuva_base; + csrc_pte = pte; + cdstp = (char *)cpuva_base + PAGE_SIZE; + cdst_pte = pte + 1; + zerop = (char *)cpuva_base + PAGE_SIZE * 2; + zero_pte = pte + 2; + ptpp = (char *)cpuva_base + PAGE_SIZE * 3; + ptp_pte = pte + 3; if (VM_MIN_KERNEL_ADDRESS == KERNBASE) { early_zerop = zerop; @@ -3152,8 +3139,8 @@ pmap_copy_page(paddr_t srcpa, paddr_t ds kpreempt_disable(); id = cpu_number(); - spte = PTESLEW(csrc_pte,id); - dpte = PTESLEW(cdst_pte,id); + spte = PTESLEW(csrc_pte, id); + dpte = PTESLEW(cdst_pte, id); csrcva = VASLEW(csrcp, id); cdstva = VASLEW(cdstp, id);
CVS commit: src/sys/arch/arm/nvidia
Module Name:src Committed By: maya Date: Sat Dec 17 12:11:38 UTC 2016 Modified Files: src/sys/arch/arm/nvidia: tegra_drm.h tegra_drm_fb.c tegra_fb.c Log Message: Fix regression introduced by myself with the addition of da_fb_linebytes tegra_fb was not adjusted so da_fb_linebytes was used uninitialized add tfa_fb_linebytes and match radeonfb/nouveaufb code in how we set it switch to using an initializer to hopefully avoid future errors this change doesn't need to be pulled up, as tegra_fb.c is absent in netbsd-7 To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra_drm.h cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/nvidia/tegra_drm_fb.c cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/nvidia/tegra_fb.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/nvidia/tegra_drm.h diff -u src/sys/arch/arm/nvidia/tegra_drm.h:1.6 src/sys/arch/arm/nvidia/tegra_drm.h:1.7 --- src/sys/arch/arm/nvidia/tegra_drm.h:1.6 Tue Dec 22 22:10:36 2015 +++ src/sys/arch/arm/nvidia/tegra_drm.h Sat Dec 17 12:11:38 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: tegra_drm.h,v 1.6 2015/12/22 22:10:36 jmcneill Exp $ */ +/* $NetBSD: tegra_drm.h,v 1.7 2016/12/17 12:11:38 maya Exp $ */ /*- * Copyright (c) 2015 Jared D. McNeill @@ -79,6 +79,7 @@ struct tegra_drmfb_attach_args { struct drm_fb_helper_surface_size tfa_fb_sizes; bus_space_tag_t tfa_fb_bst; bus_dma_tag_t tfa_fb_dmat; + uint32_t tfa_fb_linebytes; }; struct tegra_crtc { Index: src/sys/arch/arm/nvidia/tegra_drm_fb.c diff -u src/sys/arch/arm/nvidia/tegra_drm_fb.c:1.3 src/sys/arch/arm/nvidia/tegra_drm_fb.c:1.4 --- src/sys/arch/arm/nvidia/tegra_drm_fb.c:1.3 Mon Nov 16 21:14:33 2015 +++ src/sys/arch/arm/nvidia/tegra_drm_fb.c Sat Dec 17 12:11:38 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: tegra_drm_fb.c,v 1.3 2015/11/16 21:14:33 jmcneill Exp $ */ +/* $NetBSD: tegra_drm_fb.c,v 1.4 2016/12/17 12:11:38 maya Exp $ */ /*- * Copyright (c) 2015 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: tegra_drm_fb.c,v 1.3 2015/11/16 21:14:33 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: tegra_drm_fb.c,v 1.4 2016/12/17 12:11:38 maya Exp $"); #include #include @@ -108,6 +108,7 @@ tegra_fb_probe(struct drm_fb_helper *hel tfa.tfa_fb_sizes = *sizes; tfa.tfa_fb_bst = sc->sc_bst; tfa.tfa_fb_dmat = sc->sc_dmat; + tfa.tfa_fb_linebytes = helper->fb->pitches[0]; helper->fbdev = config_found_ia(ddev->dev, "tegrafbbus", &tfa, NULL); if (helper->fbdev == NULL) { Index: src/sys/arch/arm/nvidia/tegra_fb.c diff -u src/sys/arch/arm/nvidia/tegra_fb.c:1.2 src/sys/arch/arm/nvidia/tegra_fb.c:1.3 --- src/sys/arch/arm/nvidia/tegra_fb.c:1.2 Thu Nov 12 00:43:52 2015 +++ src/sys/arch/arm/nvidia/tegra_fb.c Sat Dec 17 12:11:38 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: tegra_fb.c,v 1.2 2015/11/12 00:43:52 jmcneill Exp $ */ +/* $NetBSD: tegra_fb.c,v 1.3 2016/12/17 12:11:38 maya Exp $ */ /*- * Copyright (c) 2015 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: tegra_fb.c,v 1.2 2015/11/12 00:43:52 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: tegra_fb.c,v 1.3 2016/12/17 12:11:38 maya Exp $"); #include #include @@ -78,7 +78,6 @@ tegra_fb_attach(device_t parent, device_ struct tegra_fb_softc * const sc = device_private(self); struct tegra_drm_softc * const drmsc = device_private(parent); struct tegra_drmfb_attach_args * const tfa = aux; - struct drmfb_attach_args da; int error; sc->sc_dev = self; @@ -89,11 +88,14 @@ tegra_fb_attach(device_t parent, device_ aprint_naive("\n"); aprint_normal("\n"); - da.da_dev = self; - da.da_fb_helper = tfa->tfa_fb_helper; - da.da_fb_sizes = &tfa->tfa_fb_sizes; - da.da_fb_vaddr = sc->sc_fb->obj->dmap; - da.da_params = &tegrafb_drmfb_params; + const struct drmfb_attach_args da = { + .da_dev = self, + .da_fb_helper = tfa->tfa_fb_helper, + .da_fb_sizes = &tfa->tfa_fb_sizes, + .da_fb_vaddr = sc->sc_fb->obj->dmap, + .da_fb_linebytes = tfa->tfa_fb_linebytes, + .da_params = &tegrafb_drmfb_params, + }; error = drmfb_attach(&sc->sc_drmfb, &da); if (error) {
CVS commit: src/lib/libc/gen
Module Name:src Committed By: wiz Date: Sat Dec 17 10:25:49 UTC 2016 Modified Files: src/lib/libc/gen: scandir.3 Log Message: Fix typo. To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/lib/libc/gen/scandir.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/gen/scandir.3 diff -u src/lib/libc/gen/scandir.3:1.15 src/lib/libc/gen/scandir.3:1.16 --- src/lib/libc/gen/scandir.3:1.15 Fri Dec 16 04:45:04 2016 +++ src/lib/libc/gen/scandir.3 Sat Dec 17 10:25:49 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: scandir.3,v 1.15 2016/12/16 04:45:04 mrg Exp $ +.\" $NetBSD: scandir.3,v 1.16 2016/12/17 10:25:49 wiz Exp $ .\" .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -118,5 +118,5 @@ to use .Dq struct dirent ** instead of .Dq void * -for the comparision function, including +for the comparison function, including .Fn alphasort .
CVS commit: [nick-nhusb] src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sat Dec 17 10:10:34 UTC 2016 Modified Files: src/sys/dev/usb [nick-nhusb]: ohci.c Log Message: Wrap a long line. To generate a diff of this commit: cvs rdiff -u -r1.254.2.80 -r1.254.2.81 src/sys/dev/usb/ohci.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/usb/ohci.c diff -u src/sys/dev/usb/ohci.c:1.254.2.80 src/sys/dev/usb/ohci.c:1.254.2.81 --- src/sys/dev/usb/ohci.c:1.254.2.80 Sat Dec 17 10:08:30 2016 +++ src/sys/dev/usb/ohci.c Sat Dec 17 10:10:34 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ohci.c,v 1.254.2.80 2016/12/17 10:08:30 skrll Exp $ */ +/* $NetBSD: ohci.c,v 1.254.2.81 2016/12/17 10:10:34 skrll Exp $ */ /* * Copyright (c) 1998, 2004, 2005, 2012 The NetBSD Foundation, Inc. @@ -41,7 +41,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.254.2.80 2016/12/17 10:08:30 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.254.2.81 2016/12/17 10:10:34 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_usb.h" @@ -2369,7 +2369,10 @@ ohci_abort_xfer(struct usbd_xfer *xfer, DPRINTF("--- dump end ---", 0, 0, 0, 0); #endif -#define OHCI_CC_ACCESSED_P(x) (((x) & OHCI_CC_NOT_ACCESSED_MASK) != OHCI_CC_NOT_ACCESSED) +#define OHCI_CC_ACCESSED_P(x) \ +(((x) & OHCI_CC_NOT_ACCESSED_MASK) != OHCI_CC_NOT_ACCESSED) + + headp = O32TOH(sed->ed.ed_headp) & OHCI_HEADMASK; hit = 0; for (; p->xfer == xfer; p = n) {
CVS commit: [nick-nhusb] src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sat Dec 17 10:08:30 UTC 2016 Modified Files: src/sys/dev/usb [nick-nhusb]: ohci.c Log Message: Tweak a couple of comments To generate a diff of this commit: cvs rdiff -u -r1.254.2.79 -r1.254.2.80 src/sys/dev/usb/ohci.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/usb/ohci.c diff -u src/sys/dev/usb/ohci.c:1.254.2.79 src/sys/dev/usb/ohci.c:1.254.2.80 --- src/sys/dev/usb/ohci.c:1.254.2.79 Mon Dec 5 10:55:18 2016 +++ src/sys/dev/usb/ohci.c Sat Dec 17 10:08:30 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: ohci.c,v 1.254.2.79 2016/12/05 10:55:18 skrll Exp $ */ +/* $NetBSD: ohci.c,v 1.254.2.80 2016/12/17 10:08:30 skrll Exp $ */ /* * Copyright (c) 1998, 2004, 2005, 2012 The NetBSD Foundation, Inc. @@ -41,7 +41,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.254.2.79 2016/12/05 10:55:18 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.254.2.80 2016/12/17 10:08:30 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_usb.h" @@ -2229,7 +2229,7 @@ ohci_close_pipe(struct usbd_pipe *pipe, } /* - * Cancel or timeour a device request. We have two cases to deal with + * Cancel or timeout a device request. We have two cases to deal with * * 1) A driver wants to stop scheduled or inflight transfers * 2) A transfer has timed out @@ -2298,8 +2298,6 @@ ohci_abort_xfer(struct usbd_xfer *xfer, * Step 1: When cancelling a transfer make sure the timeout handler * didn't run or ran to the end and saw the USBD_CANCELLED status. * Otherwise we must have got here via a timeout. - * - * If we timed out then */ if (status == USBD_CANCELLED) { xfer->ux_status = status;
CVS commit: src/usr.bin/netstat
Module Name:src Committed By: mlelstv Date: Sat Dec 17 09:12:22 UTC 2016 Modified Files: src/usr.bin/netstat: inet6.c Log Message: Print previously missing fields from a TCP6 PCB. To generate a diff of this commit: cvs rdiff -u -r1.68 -r1.69 src/usr.bin/netstat/inet6.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.bin/netstat/inet6.c diff -u src/usr.bin/netstat/inet6.c:1.68 src/usr.bin/netstat/inet6.c:1.69 --- src/usr.bin/netstat/inet6.c:1.68 Sun Feb 8 15:09:45 2015 +++ src/usr.bin/netstat/inet6.c Sat Dec 17 09:12:22 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: inet6.c,v 1.68 2015/02/08 15:09:45 christos Exp $ */ +/* $NetBSD: inet6.c,v 1.69 2016/12/17 09:12:22 mlelstv Exp $ */ /* BSDI inet.c,v 2.3 1995/10/24 02:19:29 prb Exp */ /* @@ -64,7 +64,7 @@ #if 0 static char sccsid[] = "@(#)inet.c 8.4 (Berkeley) 4/20/94"; #else -__RCSID("$NetBSD: inet6.c,v 1.68 2015/02/08 15:09:45 christos Exp $"); +__RCSID("$NetBSD: inet6.c,v 1.69 2016/12/17 09:12:22 mlelstv Exp $"); #endif #endif /* not lint */ @@ -1494,6 +1494,9 @@ tcp6_dump(u_long off, const char *name, #ifdef TCP6 printf("peermaxseg %u, maxseg %u, force %d\n\n", mypcb.t_peermaxseg, mypcb.t_maxseg, mypcb.t_force); +#else +printf("peermss %u, ourmss %u, segsz %u, segqlen %u\n\n", + tcpcb.t_peermss, tcpcb.t_ourmss, tcpcb.t_segsz, tcpcb.t_segqlen); #endif printf("snd_una %u, snd_nxt %u, snd_up %u\n", @@ -1511,8 +1514,11 @@ tcp6_dump(u_long off, const char *name, (unsigned long long)mypcb.snd_ssthresh); #ifdef TCP6 - printf("idle %d, rtt %d, " mypcb.t_idle, mypcb.t_rtt) + printf("idle %d, rtt %d, " mypcb.t_idle, mypcb.t_rtt); +#else + printf("rcvtime %u, rtttime %u, ", tcpcb.t_rcvtime, tcpcb.t_rtttime); #endif + printf("rtseq %u, srtt %d, rttvar %d, rttmin %d, " "max_sndwnd %llu\n\n", mypcb.t_rtseq, mypcb.t_srtt, mypcb.t_rttvar, mypcb.t_rttmin,