CVS commit: src/sys/dev/ic
Module Name:src Committed By: msaitoh Date: Mon Feb 10 07:48:02 UTC 2020 Modified Files: src/sys/dev/ic: elinkxl.c Log Message: Restore an register read for RX_FRAMES_OK which was removed in rev. 1.133. All statistics registers should be read to ACK the interrupt. Fixes PR#54920. XXX pullup-[89] To generate a diff of this commit: cvs rdiff -u -r1.136 -r1.137 src/sys/dev/ic/elinkxl.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/ic/elinkxl.c diff -u src/sys/dev/ic/elinkxl.c:1.136 src/sys/dev/ic/elinkxl.c:1.137 --- src/sys/dev/ic/elinkxl.c:1.136 Fri Feb 7 00:56:48 2020 +++ src/sys/dev/ic/elinkxl.c Mon Feb 10 07:48:02 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: elinkxl.c,v 1.136 2020/02/07 00:56:48 thorpej Exp $ */ +/* $NetBSD: elinkxl.c,v 1.137 2020/02/10 07:48:02 msaitoh Exp $ */ /*- * Copyright (c) 1998 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: elinkxl.c,v 1.136 2020/02/07 00:56:48 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: elinkxl.c,v 1.137 2020/02/10 07:48:02 msaitoh Exp $"); #include #include @@ -1522,6 +1522,7 @@ ex_getstats(struct ex_softc *sc) (void)bus_space_read_1(iot, ioh, TX_AFTER_1_COLLISION); (void)bus_space_read_1(iot, ioh, TX_NO_SQE); (void)bus_space_read_1(iot, ioh, TX_CD_LOST); + (void)bus_space_read_1(iot, ioh, RX_FRAMES_OK); GO_WINDOW(4); (void)bus_space_read_1(iot, ioh, ELINK_W4_BADSSD); GO_WINDOW(1);
CVS commit: src/sys/rump/dev/lib/librnd
Module Name:src Committed By: riastradh Date: Mon Feb 10 07:13:06 UTC 2020 Modified Files: src/sys/rump/dev/lib/librnd: rnd_component.c Log Message: Omit duplicate rnd_init in rump. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/rump/dev/lib/librnd/rnd_component.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/rump/dev/lib/librnd/rnd_component.c diff -u src/sys/rump/dev/lib/librnd/rnd_component.c:1.5 src/sys/rump/dev/lib/librnd/rnd_component.c:1.6 --- src/sys/rump/dev/lib/librnd/rnd_component.c:1.5 Mon May 30 14:52:06 2016 +++ src/sys/rump/dev/lib/librnd/rnd_component.c Mon Feb 10 07:13:06 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: rnd_component.c,v 1.5 2016/05/30 14:52:06 pooka Exp $ */ +/* $NetBSD: rnd_component.c,v 1.6 2020/02/10 07:13:06 riastradh Exp $ */ /* * Copyright (c) 2009 Antti Kantee. All Rights Reserved. @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: rnd_component.c,v 1.5 2016/05/30 14:52:06 pooka Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rnd_component.c,v 1.6 2020/02/10 07:13:06 riastradh Exp $"); #include #include @@ -61,7 +61,6 @@ RUMP_COMPONENT(RUMP_COMPONENT_DEV) panic("cannot create /dev/urandom: %d", error); rump_pdev_add(rndattach, 4); - rnd_init(); } #if 0
CVS commit: src
Module Name:src Committed By: ryo Date: Mon Feb 10 05:53:12 UTC 2020 Modified Files: src/share/man/man4: aq.4 src/sys/dev/pci: if_aq.c Log Message: add support VLAN HW filter To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/share/man/man4/aq.4 cvs rdiff -u -r1.9 -r1.10 src/sys/dev/pci/if_aq.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/aq.4 diff -u src/share/man/man4/aq.4:1.2 src/share/man/man4/aq.4:1.3 --- src/share/man/man4/aq.4:1.2 Wed Jan 1 20:13:19 2020 +++ src/share/man/man4/aq.4 Mon Feb 10 05:53:11 2020 @@ -1,4 +1,4 @@ -.\" $NetBSD: aq.4,v 1.2 2020/01/01 20:13:19 wiz Exp $ +.\" $NetBSD: aq.4,v 1.3 2020/02/10 05:53:11 ryo Exp $ .\" .\" Copyright (c) 2020 Ryo Shimizu .\" All rights reserved. @@ -24,7 +24,7 @@ .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd January 1, 2020 +.Dd February 10, 2020 .Dt AQ 4 .Os .Sh NAME @@ -71,6 +71,7 @@ D109 2.5 Gigabit Network Adapter .Xr ifmedia 4 , .Xr netintro 4 , .Xr pci 4 , +.Xr vlan 4 , .Xr ifconfig 8 .Sh HISTORY The @@ -80,7 +81,3 @@ driver first appeared in and is based on the .Fx driver of the same name, but has been drastically rewritten by Ryo Shimizu. -.Sh BUGS -The -.Nm -driver does not support the VLAN hardware filter. Index: src/sys/dev/pci/if_aq.c diff -u src/sys/dev/pci/if_aq.c:1.9 src/sys/dev/pci/if_aq.c:1.10 --- src/sys/dev/pci/if_aq.c:1.9 Mon Feb 10 05:07:28 2020 +++ src/sys/dev/pci/if_aq.c Mon Feb 10 05:53:12 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: if_aq.c,v 1.9 2020/02/10 05:07:28 ryo Exp $ */ +/* $NetBSD: if_aq.c,v 1.10 2020/02/10 05:53:12 ryo Exp $ */ /** * aQuantia Corporation Network Driver @@ -62,7 +62,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1.9 2020/02/10 05:07:28 ryo Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1.10 2020/02/10 05:53:12 ryo Exp $"); #ifdef _KERNEL_OPT #include "opt_if_aq.h" @@ -1051,6 +1051,7 @@ static int aq_establish_msix_intr(struct static int aq_ifmedia_change(struct ifnet * const); static void aq_ifmedia_status(struct ifnet * const, struct ifmediareq *); +static int aq_vlan_cb(struct ethercom *ec, uint16_t vid, bool set); static int aq_ifflags_cb(struct ethercom *); static int aq_init(struct ifnet *); static void aq_send_common_locked(struct ifnet *, struct aq_softc *, @@ -1404,14 +1405,15 @@ aq_attach(device_t parent, device_t self #if notyet /* TODO */ sc->sc_ethercom.ec_capabilities |= ETHERCAP_EEE; - sc->sc_ethercom.ec_capabilities |= ETHERCAP_VLAN_HWFILTER; #endif sc->sc_ethercom.ec_capabilities |= ETHERCAP_JUMBO_MTU | ETHERCAP_VLAN_MTU | - ETHERCAP_VLAN_HWTAGGING; + ETHERCAP_VLAN_HWTAGGING | + ETHERCAP_VLAN_HWFILTER; sc->sc_ethercom.ec_capenable |= - ETHERCAP_VLAN_HWTAGGING; + ETHERCAP_VLAN_HWTAGGING | + ETHERCAP_VLAN_HWFILTER; ifp->if_capabilities = 0; ifp->if_capenable = 0; @@ -1446,6 +1448,7 @@ aq_attach(device_t parent, device_t self if_attach(ifp); if_deferred_start_init(ifp, NULL); ether_ifattach(ifp, sc->sc_enaddr.ether_addr_octet); + ether_set_vlan_cb(>sc_ethercom, aq_vlan_cb); ether_set_ifflags_cb(>sc_ethercom, aq_ifflags_cb); aq_enable_intr(sc, true, false); /* only intr about link */ @@ -2944,7 +2947,7 @@ aq_hw_init_rx_path(struct aq_softc *sc) ETHERTYPE_QINQ); AQ_WRITE_REG_BIT(sc, RPF_VLAN_TPID_REG, RPF_VLAN_TPID_INNER, ETHERTYPE_VLAN); - AQ_WRITE_REG_BIT(sc, RPF_VLAN_MODE_REG, RPF_VLAN_MODE_PROMISC, 1); + AQ_WRITE_REG_BIT(sc, RPF_VLAN_MODE_REG, RPF_VLAN_MODE_PROMISC, 0); if (sc->sc_features & FEATURES_REV_B) { AQ_WRITE_REG_BIT(sc, RPF_VLAN_MODE_REG, @@ -3216,18 +3219,55 @@ aq_hw_l3_filter_set(struct aq_softc *sc) } static void -aq_update_vlan_filters(struct aq_softc *sc) +aq_set_vlan_filters(struct aq_softc *sc) { - /* XXX: notyet. vlan always promisc */ + struct ethercom *ec = >sc_ethercom; + struct ifnet *ifp = >sc_ethercom.ec_if; + struct vlanid_list *vlanidp; int i; - for (i = 0; i < RPF_VLAN_MAX_FILTERS; i++) { + ETHER_LOCK(ec); + + /* disable all vlan filters */ + for (i = 0; i < RPF_VLAN_MAX_FILTERS; i++) + AQ_WRITE_REG(sc, RPF_VLAN_FILTER_REG(i), 0); + + /* count VID */ + i = 0; + SIMPLEQ_FOREACH(vlanidp, >ec_vids, vid_list) + i++; + + if (((sc->sc_ethercom.ec_capenable & ETHERCAP_VLAN_HWFILTER) == 0) || + (ifp->if_flags & IFF_PROMISC) || + (i > RPF_VLAN_MAX_FILTERS)) { + /* + * no vlan hwfilter, in promiscuous mode, or too many VID? + * must receive all VID + */ + AQ_WRITE_REG_BIT(sc, RPF_VLAN_MODE_REG, + RPF_VLAN_MODE_PROMISC, 1); + goto done; + } + + /* receive only selected VID */ + AQ_WRITE_REG_BIT(sc, RPF_VLAN_MODE_REG, RPF_VLAN_MODE_PROMISC, 0); + i = 0; + SIMPLEQ_FOREACH(vlanidp, >ec_vids, vid_list) { AQ_WRITE_REG_BIT(sc, RPF_VLAN_FILTER_REG(i), - RPF_VLAN_FILTER_EN, 0); +
CVS commit: src/sys/dev/pci
Module Name:src Committed By: ryo Date: Mon Feb 10 05:07:28 UTC 2020 Modified Files: src/sys/dev/pci: if_aq.c Log Message: fix descriptions of register map in comment To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/dev/pci/if_aq.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/pci/if_aq.c diff -u src/sys/dev/pci/if_aq.c:1.8 src/sys/dev/pci/if_aq.c:1.9 --- src/sys/dev/pci/if_aq.c:1.8 Sat Feb 8 07:19:09 2020 +++ src/sys/dev/pci/if_aq.c Mon Feb 10 05:07:28 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: if_aq.c,v 1.8 2020/02/08 07:19:09 maxv Exp $ */ +/* $NetBSD: if_aq.c,v 1.9 2020/02/10 05:07:28 ryo Exp $ */ /** * aQuantia Corporation Network Driver @@ -62,7 +62,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1.8 2020/02/08 07:19:09 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1.9 2020/02/10 05:07:28 ryo Exp $"); #ifdef _KERNEL_OPT #include "opt_if_aq.h" @@ -258,7 +258,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1. #define AQ_HW_MAC_OWN 0 /* index of own address */ #define AQ_HW_MAC_NUM 34 -/* RPF_MCAST_FILTER_REG[12] 0x5250-0x5280 */ +/* RPF_MCAST_FILTER_REG[8] 0x5250-0x5270 */ #define RPF_MCAST_FILTER_REG(i) (0x5250 + (i) * 4) #define RPF_MCAST_FILTER_EN __BIT(31) #define RPF_MCAST_FILTER_MASK_REG 0x5270 @@ -273,7 +273,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_aq.c,v 1. #define RPF_VLAN_TPID_OUTER __BITS(31,16) #define RPF_VLAN_TPID_INNER __BITS(15,0) -/* RPF_VLAN_FILTER_REG[16] 0x5290-0x52d0 */ +/* RPF_VLAN_FILTER_REG[RPF_VLAN_MAX_FILTERS] 0x5290-0x52d0 */ #define RPF_VLAN_MAX_FILTERS 16 #define RPF_VLAN_FILTER_REG(i) (0x5290 + (i) * 4) #define RPF_VLAN_FILTER_EN __BIT(31)
CVS commit: src/usr.bin/xlint
Module Name:src Committed By: christos Date: Mon Feb 10 04:54:01 UTC 2020 Modified Files: src/usr.bin/xlint/common: externs.h mem.c src/usr.bin/xlint/xlint: xlint.c Log Message: use asprintf(). To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/usr.bin/xlint/common/externs.h cvs rdiff -u -r1.7 -r1.8 src/usr.bin/xlint/common/mem.c cvs rdiff -u -r1.48 -r1.49 src/usr.bin/xlint/xlint/xlint.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/xlint/common/externs.h diff -u src/usr.bin/xlint/common/externs.h:1.6 src/usr.bin/xlint/common/externs.h:1.7 --- src/usr.bin/xlint/common/externs.h:1.6 Fri Aug 19 06:18:11 2016 +++ src/usr.bin/xlint/common/externs.h Sun Feb 9 23:54:01 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: externs.h,v 1.6 2016/08/19 10:18:11 christos Exp $ */ +/* $NetBSD: externs.h,v 1.7 2020/02/10 04:54:01 christos Exp $ */ /* * Copyright (c) 1994, 1995 Jochen Pohl @@ -57,6 +57,7 @@ extern void *xrealloc(void *, size_t); extern char *xstrdup(const char *); extern void nomem(void); extern void *xmapalloc(size_t); +extern void xasprintf(char **, const char *, ...) __printflike(2, 3); /* * emit.c Index: src/usr.bin/xlint/common/mem.c diff -u src/usr.bin/xlint/common/mem.c:1.7 src/usr.bin/xlint/common/mem.c:1.8 --- src/usr.bin/xlint/common/mem.c:1.7 Sun Jun 20 18:20:16 2004 +++ src/usr.bin/xlint/common/mem.c Sun Feb 9 23:54:01 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: mem.c,v 1.7 2004/06/20 22:20:16 jmc Exp $ */ +/* $NetBSD: mem.c,v 1.8 2020/02/10 04:54:01 christos Exp $ */ /* * Copyright (c) 1994, 1995 Jochen Pohl @@ -37,12 +37,13 @@ #include #if defined(__RCSID) && !defined(lint) -__RCSID("$NetBSD: mem.c,v 1.7 2004/06/20 22:20:16 jmc Exp $"); +__RCSID("$NetBSD: mem.c,v 1.8 2020/02/10 04:54:01 christos Exp $"); #endif #include #include #include +#include #include #include @@ -98,6 +99,19 @@ nomem(void) errx(1, "virtual memory exhausted"); } +void +xasprintf(char **buf, const char *fmt, ...) +{ + int e; + va_list ap; + + va_start(ap, fmt); + e = vasprintf(buf, fmt, ap); + va_end(ap); + if (e < 0) + nomem(); +} + #if defined(MAP_ANONYMOUS) && !defined(MAP_ANON) #define MAP_ANON MAP_ANONYMOUS #endif Index: src/usr.bin/xlint/xlint/xlint.c diff -u src/usr.bin/xlint/xlint/xlint.c:1.48 src/usr.bin/xlint/xlint/xlint.c:1.49 --- src/usr.bin/xlint/xlint/xlint.c:1.48 Sun Feb 9 03:10:25 2020 +++ src/usr.bin/xlint/xlint/xlint.c Sun Feb 9 23:54:01 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: xlint.c,v 1.48 2020/02/09 08:10:25 fox Exp $ */ +/* $NetBSD: xlint.c,v 1.49 2020/02/10 04:54:01 christos Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou. All Rights Reserved. @@ -38,7 +38,7 @@ #include #if defined(__RCSID) && !defined(lint) -__RCSID("$NetBSD: xlint.c,v 1.48 2020/02/09 08:10:25 fox Exp $"); +__RCSID("$NetBSD: xlint.c,v 1.49 2020/02/10 04:54:01 christos Exp $"); #endif #include @@ -613,7 +613,7 @@ fname(const char *name) const char *bn, *suff; char **args, *ofn, *pathname; const char *CC; - size_t buff_size, len; + size_t len; int is_stdin; int fd; @@ -648,13 +648,10 @@ fname(const char *name) warnx("-i not supported without -o for standard input"); return; } - buff_size = strlen(bn) + (bn == suff ? 4 : 2); - ofn = xmalloc(buff_size); len = bn == suff ? strlen(bn) : (size_t)((suff - 1) - bn); - (void)snprintf(ofn, buff_size, "%.*s.ln", (int)len, bn); + xasprintf(, "%.*s.ln", (int)len, bn); } else { - ofn = xmalloc(strlen(tmpdir) + sizeof ("lint1.XX")); - (void)sprintf(ofn, "%slint1.XX", tmpdir); + xasprintf(, "%slint1.XX", tmpdir); fd = mkstemp(ofn); if (fd == -1) { warn("can't make temp");
CVS commit: src/sys/rump/librump/rumpkern
Module Name:src Committed By: riastradh Date: Mon Feb 10 03:23:29 UTC 2020 Modified Files: src/sys/rump/librump/rumpkern: rump.c Log Message: Initialize struct cpu_info::ci_cpuname (= ci_data.cpu_name) in rump. To generate a diff of this commit: cvs rdiff -u -r1.339 -r1.340 src/sys/rump/librump/rumpkern/rump.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/rump/librump/rumpkern/rump.c diff -u src/sys/rump/librump/rumpkern/rump.c:1.339 src/sys/rump/librump/rumpkern/rump.c:1.340 --- src/sys/rump/librump/rumpkern/rump.c:1.339 Thu Jan 2 15:42:27 2020 +++ src/sys/rump/librump/rumpkern/rump.c Mon Feb 10 03:23:29 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: rump.c,v 1.339 2020/01/02 15:42:27 thorpej Exp $ */ +/* $NetBSD: rump.c,v 1.340 2020/02/10 03:23:29 riastradh Exp $ */ /* * Copyright (c) 2007-2011 Antti Kantee. All Rights Reserved. @@ -26,7 +26,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: rump.c,v 1.339 2020/01/02 15:42:27 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rump.c,v 1.340 2020/02/10 03:23:29 riastradh Exp $"); #include #define ELFSIZE ARCH_ELFSIZE @@ -383,6 +383,7 @@ rump_init(void) rump_cpu_attach(ci); ncpu++; } + snprintf(ci->ci_cpuname, sizeof ci->ci_cpuname, "cpu%d", i); callout_init_cpu(ci); softint_init(ci);
CVS commit: src/sys/kern
Module Name:src Committed By: riastradh Date: Sun Feb 9 22:57:39 UTC 2020 Modified Files: src/sys/kern: kern_threadpool.c Log Message: Switch from ad-hoc logging to dtrace probes. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/sys/kern/kern_threadpool.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/kern_threadpool.c diff -u src/sys/kern/kern_threadpool.c:1.16 src/sys/kern/kern_threadpool.c:1.17 --- src/sys/kern/kern_threadpool.c:1.16 Sun Feb 9 22:57:26 2020 +++ src/sys/kern/kern_threadpool.c Sun Feb 9 22:57:39 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_threadpool.c,v 1.16 2020/02/09 22:57:26 riastradh Exp $ */ +/* $NetBSD: kern_threadpool.c,v 1.17 2020/02/09 22:57:39 riastradh Exp $ */ /*- * Copyright (c) 2014, 2018 The NetBSD Foundation, Inc. @@ -81,7 +81,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_threadpool.c,v 1.16 2020/02/09 22:57:26 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_threadpool.c,v 1.17 2020/02/09 22:57:39 riastradh Exp $"); #include #include @@ -97,10 +97,82 @@ __KERNEL_RCSID(0, "$NetBSD: kern_threadp #include #include #include -#include +#include #include +#include #include +/* Probes */ + +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, get, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, get__create, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, get__race, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, put, +"struct threadpool *"/*pool*/, "pri_t"/*pri*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, put__destroy, +"struct threadpool *"/*pool*/, "pri_t"/*pri*/); + +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, percpu__get, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, percpu__get__create, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, percpu__get__race, +"pri_t"/*pri*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, percpu__put, +"struct threadpool *"/*pool*/, "pri_t"/*pri*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, percpu__put__destroy, +"struct threadpool *"/*pool*/, "pri_t"/*pri*/); + +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, create, +"struct cpu_info *"/*ci*/, "pri_t"/*pri*/); +SDT_PROBE_DEFINE3(sdt, kernel, threadpool, create__success, +"struct cpu_info *"/*ci*/, "pri_t"/*pri*/, "struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE3(sdt, kernel, threadpool, create__failure, +"struct cpu_info *"/*ci*/, "pri_t"/*pri*/, "int"/*error*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, destroy, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, destroy__wait, +"struct threadpool *"/*pool*/, "uint64_t"/*refcnt*/); + +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, schedule__job, +"struct threadpool *"/*pool*/, "struct threadpool_job *"/*job*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, schedule__job__running, +"struct threadpool *"/*pool*/, "struct threadpool_job *"/*job*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, schedule__job__overseer, +"struct threadpool *"/*pool*/, "struct threadpool_job *"/*job*/); +SDT_PROBE_DEFINE3(sdt, kernel, threadpool, schedule__job__thread, +"struct threadpool *"/*pool*/, +"struct threadpool_job *"/*job*/, +"struct lwp *"/*thread*/); + +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, overseer__start, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, overseer__dying, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, overseer__spawn, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, overseer__race, +"struct threadpool *"/*pool*/, +"struct threadpool_job *"/*job*/); +SDT_PROBE_DEFINE3(sdt, kernel, threadpool, overseer__assign, +"struct threadpool *"/*pool*/, +"struct threadpool_job *"/*job*/, +"struct lwp *"/*thread*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, overseer__exit, +"struct threadpool *"/*pool*/); + +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, thread__start, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, thread__dying, +"struct threadpool *"/*pool*/); +SDT_PROBE_DEFINE2(sdt, kernel, threadpool, thread__job, +"struct threadpool *"/*pool*/, "struct threadpool_job *"/*job*/); +SDT_PROBE_DEFINE1(sdt, kernel, threadpool, thread__exit, +"struct threadpool *"/*pool*/); + /* Data structures */ TAILQ_HEAD(job_head, threadpool_job); @@ -224,12 +296,6 @@ threadpool_remove_percpu(struct threadpo LIST_REMOVE(tpp, tpp_link); } -#ifdef THREADPOOL_VERBOSE -#define TP_LOG(x) printf x -#else -#define TP_LOG(x) /* nothing */ -#endif /* THREADPOOL_VERBOSE */ - static int sysctl_kern_threadpool_idle_ms(SYSCTLFN_ARGS) { @@ -308,6 +374,8 @@ threadpool_create(struct threadpool *con KASSERT(threadpool_pri_is_valid(pri)); +
CVS commit: src/sys/kern
Module Name:src Committed By: riastradh Date: Sun Feb 9 22:57:27 UTC 2020 Modified Files: src/sys/kern: kern_threadpool.c Log Message: Teach threadpool(9) to use percpu_create, mostly. To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/kern/kern_threadpool.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/kern_threadpool.c diff -u src/sys/kern/kern_threadpool.c:1.15 src/sys/kern/kern_threadpool.c:1.16 --- src/sys/kern/kern_threadpool.c:1.15 Thu Jan 17 10:18:52 2019 +++ src/sys/kern/kern_threadpool.c Sun Feb 9 22:57:26 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_threadpool.c,v 1.15 2019/01/17 10:18:52 hannken Exp $ */ +/* $NetBSD: kern_threadpool.c,v 1.16 2020/02/09 22:57:26 riastradh Exp $ */ /*- * Copyright (c) 2014, 2018 The NetBSD Foundation, Inc. @@ -81,7 +81,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_threadpool.c,v 1.15 2019/01/17 10:18:52 hannken Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_threadpool.c,v 1.16 2020/02/09 22:57:26 riastradh Exp $"); #include #include @@ -132,6 +132,9 @@ static void threadpool_rele(struct threa static int threadpool_percpu_create(struct threadpool_percpu **, pri_t); static void threadpool_percpu_destroy(struct threadpool_percpu *); +static void threadpool_percpu_init(void *, void *, struct cpu_info *); +static void threadpool_percpu_ok(void *, void *, struct cpu_info *); +static void threadpool_percpu_fini(void *, void *, struct cpu_info *); static threadpool_job_fn_t threadpool_job_dead; @@ -576,80 +579,77 @@ static int threadpool_percpu_create(struct threadpool_percpu **pool_percpup, pri_t pri) { struct threadpool_percpu *pool_percpu; - struct cpu_info *ci; - CPU_INFO_ITERATOR cii; - unsigned int i, j; - int error; + bool ok = true; pool_percpu = kmem_zalloc(sizeof(*pool_percpu), KM_SLEEP); - if (pool_percpu == NULL) { - error = ENOMEM; - goto fail0; - } pool_percpu->tpp_pri = pri; + pool_percpu->tpp_percpu = percpu_create(sizeof(struct threadpool *), + threadpool_percpu_init, threadpool_percpu_fini, + (void *)(intptr_t)pri); - pool_percpu->tpp_percpu = percpu_alloc(sizeof(struct threadpool *)); - if (pool_percpu->tpp_percpu == NULL) { - error = ENOMEM; - goto fail1; - } - - for (i = 0, CPU_INFO_FOREACH(cii, ci), i++) { - struct threadpool *pool; - - pool = kmem_zalloc(sizeof(*pool), KM_SLEEP); - error = threadpool_create(pool, ci, pri); - if (error) { - kmem_free(pool, sizeof(*pool)); - goto fail2; - } - percpu_traverse_enter(); - struct threadpool **const poolp = - percpu_getptr_remote(pool_percpu->tpp_percpu, ci); - *poolp = pool; - percpu_traverse_exit(); - } + /* + * Verify that all of the CPUs were initialized. + * + * XXX What to do if we add CPU hotplug? + */ + percpu_foreach(pool_percpu->tpp_percpu, _percpu_ok, ); + if (!ok) + goto fail; /* Success! */ *pool_percpup = (struct threadpool_percpu *)pool_percpu; return 0; -fail2: for (j = 0, CPU_INFO_FOREACH(cii, ci), j++) { - if (i <= j) - break; - percpu_traverse_enter(); - struct threadpool **const poolp = - percpu_getptr_remote(pool_percpu->tpp_percpu, ci); - struct threadpool *const pool = *poolp; - percpu_traverse_exit(); - threadpool_destroy(pool); - kmem_free(pool, sizeof(*pool)); - } - percpu_free(pool_percpu->tpp_percpu, sizeof(struct taskthread_pool *)); -fail1: kmem_free(pool_percpu, sizeof(*pool_percpu)); -fail0: return error; +fail: percpu_free(pool_percpu->tpp_percpu, sizeof(struct threadpool *)); + kmem_free(pool_percpu, sizeof(*pool_percpu)); + return ENOMEM; } static void threadpool_percpu_destroy(struct threadpool_percpu *pool_percpu) { - struct cpu_info *ci; - CPU_INFO_ITERATOR cii; - - for (CPU_INFO_FOREACH(cii, ci)) { - percpu_traverse_enter(); - struct threadpool **const poolp = - percpu_getptr_remote(pool_percpu->tpp_percpu, ci); - struct threadpool *const pool = *poolp; - percpu_traverse_exit(); - threadpool_destroy(pool); - kmem_free(pool, sizeof(*pool)); - } percpu_free(pool_percpu->tpp_percpu, sizeof(struct threadpool *)); kmem_free(pool_percpu, sizeof(*pool_percpu)); } +static void +threadpool_percpu_init(void *vpoolp, void *vpri, struct cpu_info *ci) +{ + struct threadpool **const poolp = vpoolp; + pri_t pri = (intptr_t)(void *)vpri; + int error; + + *poolp = kmem_zalloc(sizeof(**poolp), KM_SLEEP); + error = threadpool_create(*poolp, ci, pri); + if (error) { + KASSERT(error == ENOMEM); + kmem_free(*poolp, sizeof(**poolp)); + *poolp = NULL; + } +} + +static void +threadpool_percpu_ok(void *vpoolp, void *vokp, struct cpu_info *ci) +{ + struct threadpool **const poolp = vpoolp; + bool *okp = vokp; + + if (*poolp == NULL) + atomic_store_relaxed(okp, false); +} + +static void +threadpool_percpu_fini(void *vpoolp, void *vprip, struct cpu_info *ci) +{ + struct threadpool **const poolp = vpoolp; + + if (*poolp ==
CVS commit: src/sys/net
Module Name:src Committed By: roy Date: Sun Feb 9 21:15:04 UTC 2020 Modified Files: src/sys/net: rtsock_shared.c Log Message: route(4): dst addr could be in a different mbuf for RO_MISSFILTER While here, the correct assertation is RTAX_DST == 0. RTA_DST is just a flag. To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/net/rtsock_shared.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/net/rtsock_shared.c diff -u src/sys/net/rtsock_shared.c:1.13 src/sys/net/rtsock_shared.c:1.14 --- src/sys/net/rtsock_shared.c:1.13 Sat Feb 8 14:17:30 2020 +++ src/sys/net/rtsock_shared.c Sun Feb 9 21:15:03 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: rtsock_shared.c,v 1.13 2020/02/08 14:17:30 roy Exp $ */ +/* $NetBSD: rtsock_shared.c,v 1.14 2020/02/09 21:15:03 roy Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -61,7 +61,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: rtsock_shared.c,v 1.13 2020/02/08 14:17:30 roy Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rtsock_shared.c,v 1.14 2020/02/09 21:15:03 roy Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -237,11 +237,24 @@ COMPATNAME(route_filter)(struct mbuf *m, return EEXIST; if (rop->rocb_missfilterlen != 0 && rtm->rtm_type == RTM_MISS) { - __CTASSERT(RTA_DST == 1); - struct sockaddr *sa, *dst = (struct sockaddr *)(rtm + 1); + __CTASSERT(RTAX_DST == 0); + struct sockaddr_storage ss; + struct sockaddr *dst = (struct sockaddr *), *sa; char *cp = rop->rocb_missfilter; char *ep = cp + rop->rocb_missfilterlen; + /* Ensure we can access sa_len */ + if (m->m_pkthdr.len < sizeof(*rtm) + + offsetof(struct sockaddr, sa_len) + sizeof(ss.ss_len)) + return EINVAL; + m_copydata(m, sizeof(*rtm) + offsetof(struct sockaddr, sa_len), + sizeof(ss.ss_len), ); + if (m->m_pkthdr.len < sizeof(*rtm) + ss.ss_len) + return EINVAL; + /* Copy out the destination sockaddr */ + m_copydata(m, sizeof(*rtm), ss.ss_len, ); + + /* Find a matching sockaddr in the filter */ while (cp < ep) { sa = (struct sockaddr *)cp; if (sa->sa_len == dst->sa_len &&
CVS commit: src
6:1.83 Wed Dec 4 11:47:17 2019 +++ src/distrib/sets/lists/modules/md.i386 Sun Feb 9 16:06:17 2020 @@ -1,4 +1,4 @@ -# $NetBSD: md.i386,v 1.83 2019/12/04 11:47:17 jmcneill Exp $ +# $NetBSD: md.i386,v 1.84 2020/02/09 16:06:17 jmcneill Exp $ # # NOTE that there are two sets of files here: @MODULEDIR@ and i386pae-xen # @@ -47,8 +47,8 @@ ./@MODULEDIR@/au8522/au8522.kmod base-kernel-modules kmod ./@MODULEDIR@/auvitekbase-kernel-modules kmod ./@MODULEDIR@/auvitek/auvitek.kmod base-kernel-modules kmod -./@MODULEDIR@/azaliabase-kernel-modules kmod -./@MODULEDIR@/azalia/azalia.kmod base-kernel-modules kmod +./@MODULEDIR@/azaliabase-obsolete obsolete +./@MODULEDIR@/azalia/azalia.kmod base-obsolete obsolete ./@MODULEDIR@/bpfjitbase-kernel-modules kmod,sljit ./@MODULEDIR@/bpfjit/bpfjit.kmod base-kernel-modules kmod,sljit ./@MODULEDIR@/cac_eisabase-obsolete obsolete Index: src/doc/CHANGES diff -u src/doc/CHANGES:1.2648 src/doc/CHANGES:1.2649 --- src/doc/CHANGES:1.2648 Sun Feb 2 21:50:21 2020 +++ src/doc/CHANGES Sun Feb 9 16:06:17 2020 @@ -1,4 +1,4 @@ -# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2648 $> +# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2649 $> # # # [Note: This file does not mention every change made to the NetBSD source tree. @@ -142,3 +142,4 @@ Changes from NetBSD 9.0 to NetBSD 10.0: Collect network interface statistics using per-cpu counters that are collated when they are queried. [thorpej 20200201] realpath(1): Ported from FreeBSD. [kamil 20200202] + kernel: Remove azalia(4). [jmcneill 20200209] Index: src/share/man/man4/Makefile diff -u src/share/man/man4/Makefile:1.701 src/share/man/man4/Makefile:1.702 --- src/share/man/man4/Makefile:1.701 Wed Jan 29 18:39:04 2020 +++ src/share/man/man4/Makefile Sun Feb 9 16:06:17 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.701 2020/01/29 18:39:04 maya Exp $ +# $NetBSD: Makefile,v 1.702 2020/02/09 16:06:17 jmcneill Exp $ # @(#)Makefile 8.1 (Berkeley) 6/18/93 MAN= aac.4 ac97.4 acardide.4 aceride.4 acphy.4 \ @@ -9,7 +9,7 @@ MAN= aac.4 ac97.4 acardide.4 aceride.4 a an.4 aq.4 arcmsr.4 arcofi.4 aria.4 artsata.4 ata.4 atalk.4 ataraid.4 \ ath.4 athn.4 atphy.4 atppc.4 attimer.4 atw.4 \ auacer.4 audio.4 audiocs.4 auich.4 \ - auixp.4 autri.4 auvia.4 awi.4 azalia.4 \ + auixp.4 autri.4 auvia.4 awi.4 \ battery_pmu.4 bba.4 bce.4 bcsp.4 be.4 bge.4 bnx.4 bha.4 \ bio.4 bktr.4 bluetooth.4 bmtphy.4 bpf.4 bpfjit.4 \ brgphy.4 bridge.4 bthidev.4 bthub.4 btkbd.4 \ Index: src/sys/arch/amd64/conf/ALL diff -u src/sys/arch/amd64/conf/ALL:1.145 src/sys/arch/amd64/conf/ALL:1.146 --- src/sys/arch/amd64/conf/ALL:1.145 Sat Feb 8 07:07:06 2020 +++ src/sys/arch/amd64/conf/ALL Sun Feb 9 16:06:18 2020 @@ -1,4 +1,4 @@ -# $NetBSD: ALL,v 1.145 2020/02/08 07:07:06 maxv Exp $ +# $NetBSD: ALL,v 1.146 2020/02/09 16:06:18 jmcneill 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.145 $" +#ident "ALL-$Revision: 1.146 $" maxusers 64 # estimated number of users @@ -1377,7 +1377,6 @@ auich* at pci? dev ? function ? # Intel auixp* at pci? dev ? function ? # ATI IXP AC'97 Audio autri* at pci? dev ? function ? # Trident 4DWAVE based AC'97 Audio auvia* at pci? dev ? function ? # VIA VT82C686A integrated AC'97 Audio -azalia* at pci? dev ? function ? # High Definition Audio clcs* at pci? dev ? function ? # Cirrus Logic CS4280 clct* at pci? dev ? function ? # Cirrus Logic CS4281 cmpci* at pci? dev ? function ? # C-Media CMI8338/8738 Index: src/sys/arch/amd64/conf/GENERIC diff -u src/sys/arch/amd64/conf/GENERIC:1.561 src/sys/arch/amd64/conf/GENERIC:1.562 --- src/sys/arch/amd64/conf/GENERIC:1.561 Sat Feb 8 07:07:06 2020 +++ src/sys/arch/amd64/conf/GENERIC Sun Feb 9 16:06:18 2020 @@ -1,4 +1,4 @@ -# $NetBSD: GENERIC,v 1.561 2020/02/08 07:07:06 maxv Exp $ +# $NetBSD: GENERIC,v 1.562 2020/02/09 16:06:18 jmcneill 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.561 $" +#ident "GENERIC-$Revision: 1.562 $" maxusers 64 # estimated number of users @@ -958,7 +958,6 @@ auich* at pci? dev ? function ? # Intel/ auixp* at pci? dev ? function ? # ATI IXP AC'97 Audio autri* at pci? dev ? function ? # Trident 4DWAVE based AC'97 Audio auvia* at pci? dev ? function ? # VIA AC'97 audio -#azalia* at pci? dev ? function ? # High Definition Audio clcs* at pci? dev ? function ? # Cirrus Logic CS4280 clct* at pci? dev ? function ? # Cirrus Logic CS4281 cmpci* at pci? dev ? function ? # C-Media CMI8338/8738 Index: src/sys/arch/amd64/conf/XEN3_DOM0 diff -u src/sys/arch/amd64/conf/XEN3_DOM0:1.174 src/sys/a
CVS commit: src/usr.sbin/ypserv/makedbm
Module Name:src Committed By: fox Date: Sun Feb 9 15:52:48 UTC 2020 Modified Files: src/usr.sbin/ypserv/makedbm: Makefile Log Message: usr.sbin/ypserv: Suppress -Werror=format-truncation= error. Add GCC_NO_FORMAT_TRUNCATION makedbm.c to prevent build failure. Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/usr.sbin/ypserv/makedbm/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/ypserv/makedbm/Makefile diff -u src/usr.sbin/ypserv/makedbm/Makefile:1.5 src/usr.sbin/ypserv/makedbm/Makefile:1.6 --- src/usr.sbin/ypserv/makedbm/Makefile:1.5 Thu Oct 2 14:16:19 1997 +++ src/usr.sbin/ypserv/makedbm/Makefile Sun Feb 9 15:52:48 2020 @@ -1,6 +1,8 @@ -# $NetBSD: Makefile,v 1.5 1997/10/02 14:16:19 lukem Exp $ +# $NetBSD: Makefile,v 1.6 2020/02/09 15:52:48 fox Exp $ PROG= makedbm MAN= makedbm.8 +CWARNFLAGS+= ${GCC_NO_FORMAT_TRUNCATION} + .include
CVS commit: src/sys/dev/usb
Module Name:src Committed By: maya Date: Sun Feb 9 15:46:15 UTC 2020 Modified Files: src/sys/dev/usb: files.usb Log Message: Remove trace of uyurex. Pointed out by maxv, thanks! To generate a diff of this commit: cvs rdiff -u -r1.171 -r1.172 src/sys/dev/usb/files.usb 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/files.usb diff -u src/sys/dev/usb/files.usb:1.171 src/sys/dev/usb/files.usb:1.172 --- src/sys/dev/usb/files.usb:1.171 Mon Feb 3 19:37:42 2020 +++ src/sys/dev/usb/files.usb Sun Feb 9 15:46:15 2020 @@ -1,4 +1,4 @@ -# $NetBSD: files.usb,v 1.171 2020/02/03 19:37:42 maya Exp $ +# $NetBSD: files.usb,v 1.172 2020/02/09 15:46:15 maya Exp $ # # Config file and device description for machine-independent USB code. # Included by ports that need it. Ports that use it must provide @@ -83,7 +83,6 @@ defflag opt_usb.h UTS_DEBUG: USB_DEBUG defflag opt_usb.h UVIDEO_DEBUG: USB_DEBUG defflag opt_usb.h UVISOR_DEBUG: USB_DEBUG defflag opt_usb.h UVSCOM_DEBUG: USB_DEBUG -defflag opt_usb.h UYUREX_DEBUG: USB_DEBUG defflag opt_usb.h ZYD_DEBUG: USB_DEBUG define usbroothubif { }
CVS commit: src/sys/arch/arm/sunxi
Module Name:src Committed By: jakllsch Date: Sun Feb 9 15:22:25 UTC 2020 Modified Files: src/sys/arch/arm/sunxi: sunxi_mixer.c Log Message: Improve compatibility with newer A64 DE2 DTB endpoint numbers. Should fix video output with new Linux 5.5rc DTBs on A64/H2/H3/H5-based SoCs. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/sunxi/sunxi_mixer.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/sunxi/sunxi_mixer.c diff -u src/sys/arch/arm/sunxi/sunxi_mixer.c:1.10 src/sys/arch/arm/sunxi/sunxi_mixer.c:1.11 --- src/sys/arch/arm/sunxi/sunxi_mixer.c:1.10 Sat Nov 23 23:47:57 2019 +++ src/sys/arch/arm/sunxi/sunxi_mixer.c Sun Feb 9 15:22:25 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: sunxi_mixer.c,v 1.10 2019/11/23 23:47:57 jmcneill Exp $ */ +/* $NetBSD: sunxi_mixer.c,v 1.11 2020/02/09 15:22:25 jakllsch Exp $ */ /*- * Copyright (c) 2019 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sunxi_mixer.c,v 1.10 2019/11/23 23:47:57 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sunxi_mixer.c,v 1.11 2020/02/09 15:22:25 jakllsch Exp $"); #include #include @@ -173,10 +173,25 @@ enum { MIXER_PORT_OUTPUT = 1, }; +struct sunxi_mixer_compat_data { + uint8_t ovl_ui_count; + uint8_t mixer_index; +}; + +struct sunxi_mixer_compat_data mixer0_data = { + .ovl_ui_count = 3, + .mixer_index = 0, +}; + +struct sunxi_mixer_compat_data mixer1_data = { + .ovl_ui_count = 1, + .mixer_index = 1, +}; + static const struct of_compat_data compat_data[] = { - { "allwinner,sun8i-h3-de2-mixer-0", 3 }, - { "allwinner,sun50i-a64-de2-mixer-0", 3 }, - { "allwinner,sun50i-a64-de2-mixer-1", 1 }, + { "allwinner,sun8i-h3-de2-mixer-0", (uintptr_t)_data }, + { "allwinner,sun50i-a64-de2-mixer-0", (uintptr_t)_data }, + { "allwinner,sun50i-a64-de2-mixer-1", (uintptr_t)_data }, { NULL } }; @@ -1230,6 +1245,8 @@ sunxi_mixer_attach(device_t parent, devi struct fdt_attach_args * const faa = aux; struct fdt_endpoint *out_ep; const int phandle = faa->faa_phandle; + const struct sunxi_mixer_compat_data * const cd = + (const void *)of_search_compatible(phandle, compat_data)->data; struct clk *clk_bus, *clk_mod; struct fdtbus_reset *rst; bus_addr_t addr; @@ -1267,7 +1284,7 @@ sunxi_mixer_attach(device_t parent, devi return; } sc->sc_phandle = faa->faa_phandle; - sc->sc_ovl_ui_count = of_search_compatible(phandle, compat_data)->data; + sc->sc_ovl_ui_count = cd->ovl_ui_count; aprint_naive("\n"); aprint_normal(": Display Engine Mixer\n"); @@ -1276,7 +1293,14 @@ sunxi_mixer_attach(device_t parent, devi sc->sc_ports.dp_ep_get_data = sunxi_mixer_ep_get_data; fdt_ports_register(>sc_ports, self, phandle, EP_DRM_CRTC); - out_ep = fdt_endpoint_get_from_index(>sc_ports, MIXER_PORT_OUTPUT, 0); + out_ep = fdt_endpoint_get_from_index(>sc_ports, + MIXER_PORT_OUTPUT, cd->mixer_index); + if (out_ep == NULL) { + /* Couldn't find new-style DE2 endpoint, try old style. */ + out_ep = fdt_endpoint_get_from_index(>sc_ports, + MIXER_PORT_OUTPUT, 0); + } + if (out_ep != NULL) sunxi_drm_register_endpoint(phandle, out_ep); }
CVS commit: src/usr.sbin/timed/timed
Module Name:src Committed By: fox Date: Sun Feb 9 15:13:28 UTC 2020 Modified Files: src/usr.sbin/timed/timed: Makefile Log Message: usr.sbin/timed: Suppress -Werror=stringop-truncation error. Add GCC_NO_STRINGOP_TRUNCATION master.c to prevent build failure. Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/usr.sbin/timed/timed/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/timed/timed/Makefile diff -u src/usr.sbin/timed/timed/Makefile:1.13 src/usr.sbin/timed/timed/Makefile:1.14 --- src/usr.sbin/timed/timed/Makefile:1.13 Mon Nov 11 22:45:32 2019 +++ src/usr.sbin/timed/timed/Makefile Sun Feb 9 15:13:28 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.13 2019/11/11 22:45:32 joerg Exp $ +# $NetBSD: Makefile,v 1.14 2020/02/09 15:13:28 fox Exp $ # @(#)Makefile 8.1 (Berkeley) 6/6/93 # # optional flags are: MEASURE TESTING DEBUG @@ -13,4 +13,6 @@ MAN= timed.8 CWARNFLAGS.clang+= -Wno-error=implicit-int-float-conversion +COPTS.master.c+= ${GCC_NO_STRINGOP_TRUNCATION} + .include
CVS commit: src/usr.sbin/srtconfig
Module Name:src Committed By: fox Date: Sun Feb 9 15:10:31 UTC 2020 Modified Files: src/usr.sbin/srtconfig: Makefile Log Message: usr.sbin/srtconfig: Suppress -Werror=stringop-truncation error. Add GCC_NO_STRINGOP_TRUNCATION to srtconfig.c to prevent build failure. Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/usr.sbin/srtconfig/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/srtconfig/Makefile diff -u src/usr.sbin/srtconfig/Makefile:1.2 src/usr.sbin/srtconfig/Makefile:1.3 --- src/usr.sbin/srtconfig/Makefile:1.2 Fri Dec 29 10:39:59 2006 +++ src/usr.sbin/srtconfig/Makefile Sun Feb 9 15:10:31 2020 @@ -1,7 +1,9 @@ -# $NetBSD: Makefile,v 1.2 2006/12/29 10:39:59 wiz Exp $ +# $NetBSD: Makefile,v 1.3 2020/02/09 15:10:31 fox Exp $ # This file is in the public domain. PROG= srtconfig SRCS= srtconfig.c +COPTS.srtconfig.c+= ${GCC_NO_STRINGOP_TRUNCATION} + .include
CVS commit: xsrc/external/mit/xorg-server/dist/hw/xfree86/common
Module Name:xsrc Committed By: jmcneill Date: Sun Feb 9 13:02:25 UTC 2020 Modified Files: xsrc/external/mit/xorg-server/dist/hw/xfree86/common: xf86AutoConfig.c Log Message: Revert previous two commits, will fix this another way. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 \ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c diff -u xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.17 xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.18 --- xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.17 Sun Feb 9 12:53:19 2020 +++ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Sun Feb 9 13:02:24 2020 @@ -356,16 +356,16 @@ listPossibleVideoDrivers(XF86MatchedDriv xf86AddMatchedDriver(md, "fbdev"); #endif -#if defined(__NetBSD__) -xf86AddMatchedDriver(md, "wsfb"); -#endif - /* Fallback to platform default hardware */ -#if (defined(__i386__) || defined(__amd64__) || defined(__hurd__)) && !defined(__NetBSD__) +#if defined(__i386__) || defined(__amd64__) || defined(__hurd__) xf86AddMatchedDriver(md, "vesa"); #elif defined(__sparc__) && !defined(__sun) xf86AddMatchedDriver(md, "sunffb"); #endif + +#if defined(__NetBSD__) +xf86AddMatchedDriver(md, "wsfb"); +#endif } /* copy a screen section and enter the desired driver
CVS commit: xsrc/external/mit/xorg-server/dist/hw/xfree86/common
Module Name:xsrc Committed By: jmcneill Date: Sun Feb 9 12:53:19 UTC 2020 Modified Files: xsrc/external/mit/xorg-server/dist/hw/xfree86/common: xf86AutoConfig.c Log Message: Don't autoload vesa on x86 at all as it conflicts with wsfb. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 \ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c diff -u xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.16 xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.17 --- xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.16 Sun Feb 9 11:40:14 2020 +++ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Sun Feb 9 12:53:19 2020 @@ -361,7 +361,7 @@ listPossibleVideoDrivers(XF86MatchedDriv #endif /* Fallback to platform default hardware */ -#if defined(__i386__) || defined(__amd64__) || defined(__hurd__) +#if (defined(__i386__) || defined(__amd64__) || defined(__hurd__)) && !defined(__NetBSD__) xf86AddMatchedDriver(md, "vesa"); #elif defined(__sparc__) && !defined(__sun) xf86AddMatchedDriver(md, "sunffb");
CVS commit: src/external/mit/xorg/server/drivers/xf86-video-radeon-kms
Module Name:src Committed By: jmcneill Date: Sun Feb 9 12:28:28 UTC 2020 Modified Files: src/external/mit/xorg/server/drivers/xf86-video-radeon-kms: Makefile Log Message: Do not define HAVE_DRI3_H To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 \ src/external/mit/xorg/server/drivers/xf86-video-radeon-kms/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/mit/xorg/server/drivers/xf86-video-radeon-kms/Makefile diff -u src/external/mit/xorg/server/drivers/xf86-video-radeon-kms/Makefile:1.11 src/external/mit/xorg/server/drivers/xf86-video-radeon-kms/Makefile:1.12 --- src/external/mit/xorg/server/drivers/xf86-video-radeon-kms/Makefile:1.11 Sun Jan 19 10:44:51 2020 +++ src/external/mit/xorg/server/drivers/xf86-video-radeon-kms/Makefile Sun Feb 9 12:28:28 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.11 2020/01/19 10:44:51 martin Exp $ +# $NetBSD: Makefile,v 1.12 2020/02/09 12:28:28 jmcneill Exp $ .include @@ -16,7 +16,6 @@ CPPFLAGS+= \ -DHAS_DIRTYTRACKING2 \ -DHAVE_XORG_LIST \ -DHAVE_XF86_CURSOR_RESET_CURSOR \ - -DHAVE_DRI3_H \ -DHAVE_MISYNCSHM_H \ -DHAVE_PRESENT_H .endif
CVS commit: src
Module Name:src Committed By: maxv Date: Sun Feb 9 12:19:01 UTC 2020 Modified Files: src/lib/libnvmm: libnvmm.3 src/share/man/man4: nvmm.4 Log Message: Reference nvmmctl(8). To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 src/lib/libnvmm/libnvmm.3 cvs rdiff -u -r1.4 -r1.5 src/share/man/man4/nvmm.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libnvmm/libnvmm.3 diff -u src/lib/libnvmm/libnvmm.3:1.25 src/lib/libnvmm/libnvmm.3:1.26 --- src/lib/libnvmm/libnvmm.3:1.25 Mon Oct 28 14:20:28 2019 +++ src/lib/libnvmm/libnvmm.3 Sun Feb 9 12:19:01 2020 @@ -1,6 +1,6 @@ -.\" $NetBSD: libnvmm.3,v 1.25 2019/10/28 14:20:28 maxv Exp $ +.\" $NetBSD: libnvmm.3,v 1.26 2020/02/09 12:19:01 maxv Exp $ .\" -.\" Copyright (c) 2018, 2019 The NetBSD Foundation, Inc. +.\" Copyright (c) 2018-2020 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" This code is derived from software contributed to The NetBSD Foundation @@ -27,7 +27,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd October 28, 2019 +.Dd February 9, 2020 .Dt LIBNVMM 3 .Os .Sh NAME @@ -733,7 +733,8 @@ A query was made on a machine or a VCPU An attempt was made to access a machine that does not belong to the process. .El .Sh SEE ALSO -.Xr nvmm 4 +.Xr nvmm 4 , +.Xr nvmmctl 8 .Sh AUTHORS NVMM was designed and implemented by .An Maxime Villard . Index: src/share/man/man4/nvmm.4 diff -u src/share/man/man4/nvmm.4:1.4 src/share/man/man4/nvmm.4:1.5 --- src/share/man/man4/nvmm.4:1.4 Thu Mar 28 19:00:40 2019 +++ src/share/man/man4/nvmm.4 Sun Feb 9 12:19:01 2020 @@ -1,6 +1,6 @@ -.\" $NetBSD: nvmm.4,v 1.4 2019/03/28 19:00:40 maxv Exp $ +.\" $NetBSD: nvmm.4,v 1.5 2020/02/09 12:19:01 maxv Exp $ .\" -.\" Copyright (c) 2018 The NetBSD Foundation, Inc. +.\" Copyright (c) 2018-2020 The NetBSD Foundation, Inc. .\" All rights reserved. .\" .\" This code is derived from software contributed to The NetBSD Foundation @@ -27,7 +27,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd March 28, 2019 +.Dd February 9, 2020 .Dt NVMM 4 .Os .Sh NAME @@ -54,7 +54,8 @@ x86-SVM, for x86 AMD CPUs x86-VMX, for x86 Intel CPUs .El .Sh SEE ALSO -.Xr libnvmm 3 +.Xr libnvmm 3 , +.Xr nvmmctl 8 .Sh AUTHORS The .Nm
CVS commit: src/sys/arch/i386/stand/efiboot
Module Name:src Committed By: jmcneill Date: Sun Feb 9 12:13:39 UTC 2020 Modified Files: src/sys/arch/i386/stand/efiboot: efiboot.c Log Message: Do not clear the screen before exiting boot services as this may cause an undesired display mode switch. PR# 54615 To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 src/sys/arch/i386/stand/efiboot/efiboot.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/stand/efiboot/efiboot.c diff -u src/sys/arch/i386/stand/efiboot/efiboot.c:1.11 src/sys/arch/i386/stand/efiboot/efiboot.c:1.12 --- src/sys/arch/i386/stand/efiboot/efiboot.c:1.11 Fri Sep 13 02:19:45 2019 +++ src/sys/arch/i386/stand/efiboot/efiboot.c Sun Feb 9 12:13:39 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: efiboot.c,v 1.11 2019/09/13 02:19:45 manu Exp $ */ +/* $NetBSD: efiboot.c,v 1.12 2020/02/09 12:13:39 jmcneill Exp $ */ /*- * Copyright (c) 2016 Kimihiro Nonaka @@ -112,8 +112,6 @@ efi_cleanup(void) UINT32 DescriptorVersion; size_t allocsz; - clearit(); - memset(_efi, 0, sizeof(btinfo_efi)); btinfo_efi.systblpa = (intptr_t)ST; #ifdef __i386__ /* bootia32.efi */
CVS commit: xsrc/external/mit/xorg-server/dist/hw/xfree86/common
Module Name:xsrc Committed By: jmcneill Date: Sun Feb 9 11:40:14 UTC 2020 Modified Files: xsrc/external/mit/xorg-server/dist/hw/xfree86/common: xf86AutoConfig.c Log Message: Try wsfb before vesa on x86. Modern video cards may not support VBE at all. To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 \ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c diff -u xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.15 xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.16 --- xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c:1.15 Fri Aug 30 15:57:00 2019 +++ xsrc/external/mit/xorg-server/dist/hw/xfree86/common/xf86AutoConfig.c Sun Feb 9 11:40:14 2020 @@ -356,16 +356,16 @@ listPossibleVideoDrivers(XF86MatchedDriv xf86AddMatchedDriver(md, "fbdev"); #endif +#if defined(__NetBSD__) +xf86AddMatchedDriver(md, "wsfb"); +#endif + /* Fallback to platform default hardware */ #if defined(__i386__) || defined(__amd64__) || defined(__hurd__) xf86AddMatchedDriver(md, "vesa"); #elif defined(__sparc__) && !defined(__sun) xf86AddMatchedDriver(md, "sunffb"); #endif - -#if defined(__NetBSD__) -xf86AddMatchedDriver(md, "wsfb"); -#endif } /* copy a screen section and enter the desired driver
CVS commit: src/sys/kern
Module Name:src Committed By: skrll Date: Sun Feb 9 09:30:23 UTC 2020 Modified Files: src/sys/kern: subr_cpu.c Log Message: Trailing whitespace To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 src/sys/kern/subr_cpu.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/subr_cpu.c diff -u src/sys/kern/subr_cpu.c:1.11 src/sys/kern/subr_cpu.c:1.12 --- src/sys/kern/subr_cpu.c:1.11 Mon Jan 13 20:30:08 2020 +++ src/sys/kern/subr_cpu.c Sun Feb 9 09:30:22 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: subr_cpu.c,v 1.11 2020/01/13 20:30:08 ad Exp $ */ +/* $NetBSD: subr_cpu.c,v 1.12 2020/02/09 09:30:22 skrll Exp $ */ /*- * Copyright (c) 2007, 2008, 2009, 2010, 2012, 2019, 2020 @@ -61,7 +61,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: subr_cpu.c,v 1.11 2020/01/13 20:30:08 ad Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_cpu.c,v 1.12 2020/02/09 09:30:22 skrll Exp $"); #include #include @@ -261,7 +261,7 @@ cpu_topology_fake(void) /* * Fix up basic CPU topology info. Right now that means attach each CPU to - * circular lists of its siblings in the same core, and in the same package. + * circular lists of its siblings in the same core, and in the same package. */ void cpu_topology_init(void) @@ -287,7 +287,7 @@ cpu_topology_init(void) ci2 != ci) { #ifdef DEBUG printf("cpu%u %p pkg %u core %u smt %u same as " - "cpu%u %p pkg %u core %u smt %u\n", + "cpu%u %p pkg %u core %u smt %u\n", cpu_index(ci), ci, ci->ci_package_id, ci->ci_core_id, ci->ci_smt_id, cpu_index(ci2), ci2, ci2->ci_package_id,
CVS commit: src/sys/arch/macppc/macppc
Module Name:src Committed By: skrll Date: Sun Feb 9 09:30:37 UTC 2020 Modified Files: src/sys/arch/macppc/macppc: cpu.c Log Message: Traiing whitespace To generate a diff of this commit: cvs rdiff -u -r1.70 -r1.71 src/sys/arch/macppc/macppc/cpu.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/macppc/macppc/cpu.c diff -u src/sys/arch/macppc/macppc/cpu.c:1.70 src/sys/arch/macppc/macppc/cpu.c:1.71 --- src/sys/arch/macppc/macppc/cpu.c:1.70 Thu Jan 9 16:35:03 2020 +++ src/sys/arch/macppc/macppc/cpu.c Sun Feb 9 09:30:37 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.c,v 1.70 2020/01/09 16:35:03 ad Exp $ */ +/* $NetBSD: cpu.c,v 1.71 2020/02/09 09:30:37 skrll Exp $ */ /*- * Copyright (c) 2001 Tsubai Masanari. @@ -33,7 +33,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.70 2020/01/09 16:35:03 ad Exp $"); +__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.71 2020/02/09 09:30:37 skrll Exp $"); #include "opt_ppcparam.h" #include "opt_multiprocessor.h" @@ -170,7 +170,7 @@ cpuattach(device_t parent, device_t self core = 0; vers = (mfpvr() >> 16) & 0x; - + if (vers == IBM970MP) { core = package & 1; package >>= 1; @@ -348,7 +348,7 @@ md_setup_interrupts(void) if (openpic_base) { openpic_set_priority(cpu_number(), 0); } else if (have_u3_ht()) { - __u3_ht_set_priority(cpu_number(), 0); + __u3_ht_set_priority(cpu_number(), 0); } else #endif /* OPENPIC */ out32(HH_INTR_SECONDARY, ~0); /* Reset interrupt. */
CVS commit: src/sys/sys
Module Name:src Committed By: skrll Date: Sun Feb 9 09:29:50 UTC 2020 Modified Files: src/sys/sys: cpu.h Log Message: Trailing whitespace To generate a diff of this commit: cvs rdiff -u -r1.48 -r1.49 src/sys/sys/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/sys/cpu.h diff -u src/sys/sys/cpu.h:1.48 src/sys/sys/cpu.h:1.49 --- src/sys/sys/cpu.h:1.48 Thu Jan 9 16:35:03 2020 +++ src/sys/sys/cpu.h Sun Feb 9 09:29:50 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.h,v 1.48 2020/01/09 16:35:03 ad Exp $ */ +/* $NetBSD: cpu.h,v 1.49 2020/02/09 09:29:50 skrll Exp $ */ /*- * Copyright (c) 2007 YAMAMOTO Takashi, @@ -57,7 +57,7 @@ void cpu_need_resched(struct cpu_info *, /* * CPU_INFO_ITERATOR() may be supplied by machine dependent code as it * controls how the cpu_info structures are allocated. - * + * * This macro must always iterate just the boot-CPU when the system has * not attached any cpus via mi_cpu_attach() yet, and the "ncpu" variable * is zero.
CVS commit: src/libexec/ld.elf_so
Module Name:src Committed By: kamil Date: Sun Feb 9 09:11:59 UTC 2020 Modified Files: src/libexec/ld.elf_so: Makefile Log Message: Specify NOLIBCSANITIZER for the ELF loader The sanitizer does not work reliably before finishing initialization of ld.elf_so. There is also a number of false positives that are not real problems here. To generate a diff of this commit: cvs rdiff -u -r1.142 -r1.143 src/libexec/ld.elf_so/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/libexec/ld.elf_so/Makefile diff -u src/libexec/ld.elf_so/Makefile:1.142 src/libexec/ld.elf_so/Makefile:1.143 --- src/libexec/ld.elf_so/Makefile:1.142 Mon Nov 4 12:45:10 2019 +++ src/libexec/ld.elf_so/Makefile Sun Feb 9 09:11:59 2020 @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.142 2019/11/04 12:45:10 joerg Exp $ +# $NetBSD: Makefile,v 1.143 2020/02/09 09:11:59 kamil Exp $ # # NOTE: when changing ld.so, ensure that ldd still compiles. # +NOLIBCSANITIZER=# defined NOSANITIZER= # defined WARNS?=4
CVS commit: src/sys/arch/aarch64/aarch64
Module Name:src Committed By: skrll Date: Sun Feb 9 08:14:56 UTC 2020 Modified Files: src/sys/arch/aarch64/aarch64: cpu.c Log Message: #if 0 / #endif -> a comment To generate a diff of this commit: cvs rdiff -u -r1.39 -r1.40 src/sys/arch/aarch64/aarch64/cpu.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/aarch64/aarch64/cpu.c diff -u src/sys/arch/aarch64/aarch64/cpu.c:1.39 src/sys/arch/aarch64/aarch64/cpu.c:1.40 --- src/sys/arch/aarch64/aarch64/cpu.c:1.39 Tue Jan 28 17:47:50 2020 +++ src/sys/arch/aarch64/aarch64/cpu.c Sun Feb 9 08:14:55 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: cpu.c,v 1.39 2020/01/28 17:47:50 maxv Exp $ */ +/* $NetBSD: cpu.c,v 1.40 2020/02/09 08:14:55 skrll Exp $ */ /* * Copyright (c) 2017 Ryo Shimizu @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(1, "$NetBSD: cpu.c,v 1.39 2020/01/28 17:47:50 maxv Exp $"); +__KERNEL_RCSID(1, "$NetBSD: cpu.c,v 1.40 2020/02/09 08:14:55 skrll Exp $"); #include "locators.h" #include "opt_arm_debug.h" @@ -159,10 +159,8 @@ cpu_attach(device_t dv, cpuid_t id) fpu_attach(ci); cpu_identify1(dv, ci); -#if 0 - /* already done in locore */ - aarch64_getcacheinfo(unit); -#endif + + /* aarch64_getcacheinfo(0) was called by locore.S */ aarch64_printcacheinfo(dv); cpu_identify2(dv, ci);
CVS commit: src/usr.bin/xlint/xlint
Module Name:src Committed By: fox Date: Sun Feb 9 08:10:26 UTC 2020 Modified Files: src/usr.bin/xlint/xlint: xlint.c Log Message: usr.bin/xlint: Fix -Werror=format-overflow= error. Replace sprintf(3) with snprintf(3). Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.47 -r1.48 src/usr.bin/xlint/xlint/xlint.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/xlint/xlint/xlint.c diff -u src/usr.bin/xlint/xlint/xlint.c:1.47 src/usr.bin/xlint/xlint/xlint.c:1.48 --- src/usr.bin/xlint/xlint/xlint.c:1.47 Sat Apr 13 15:08:49 2019 +++ src/usr.bin/xlint/xlint/xlint.c Sun Feb 9 08:10:25 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: xlint.c,v 1.47 2019/04/13 15:08:49 christos Exp $ */ +/* $NetBSD: xlint.c,v 1.48 2020/02/09 08:10:25 fox Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou. All Rights Reserved. @@ -38,7 +38,7 @@ #include #if defined(__RCSID) && !defined(lint) -__RCSID("$NetBSD: xlint.c,v 1.47 2019/04/13 15:08:49 christos Exp $"); +__RCSID("$NetBSD: xlint.c,v 1.48 2020/02/09 08:10:25 fox Exp $"); #endif #include @@ -613,7 +613,7 @@ fname(const char *name) const char *bn, *suff; char **args, *ofn, *pathname; const char *CC; - size_t len; + size_t buff_size, len; int is_stdin; int fd; @@ -648,10 +648,10 @@ fname(const char *name) warnx("-i not supported without -o for standard input"); return; } - ofn = xmalloc(strlen(bn) + (bn == suff ? 4 : 2)); + buff_size = strlen(bn) + (bn == suff ? 4 : 2); + ofn = xmalloc(buff_size); len = bn == suff ? strlen(bn) : (size_t)((suff - 1) - bn); - (void)sprintf(ofn, "%.*s", (int)len, bn); - (void)strcat(ofn, ".ln"); + (void)snprintf(ofn, buff_size, "%.*s.ln", (int)len, bn); } else { ofn = xmalloc(strlen(tmpdir) + sizeof ("lint1.XX")); (void)sprintf(ofn, "%slint1.XX", tmpdir);
CVS commit: src/sys/arch/aarch64/aarch64
Module Name:src Committed By: skrll Date: Sun Feb 9 08:09:59 UTC 2020 Modified Files: src/sys/arch/aarch64/aarch64: locore.S Log Message: Improve comments To generate a diff of this commit: cvs rdiff -u -r1.54 -r1.55 src/sys/arch/aarch64/aarch64/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/aarch64/aarch64/locore.S diff -u src/sys/arch/aarch64/aarch64/locore.S:1.54 src/sys/arch/aarch64/aarch64/locore.S:1.55 --- src/sys/arch/aarch64/aarch64/locore.S:1.54 Tue Jan 28 17:33:07 2020 +++ src/sys/arch/aarch64/aarch64/locore.S Sun Feb 9 08:09:58 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: locore.S,v 1.54 2020/01/28 17:33:07 maxv Exp $ */ +/* $NetBSD: locore.S,v 1.55 2020/02/09 08:09:58 skrll Exp $ */ /* * Copyright (c) 2017 Ryo Shimizu @@ -38,7 +38,7 @@ #include #include "assym.h" -RCSID("$NetBSD: locore.S,v 1.54 2020/01/28 17:33:07 maxv Exp $") +RCSID("$NetBSD: locore.S,v 1.55 2020/02/09 08:09:58 skrll Exp $") #ifdef AARCH64_DEVICE_MEM_STRONGLY_ORDERED #define MAIR_DEVICE_MEM MAIR_DEVICE_nGnRnE @@ -178,11 +178,13 @@ vstart: msr tpidr_el1, x0 /* curcpu is cpu_info[0] */ DPRINTREG("curcpu = ", x0); - /* get cache configuration */ + /* set topology information */ mrs x0, tpidr_el1 /* curcpu */ mrs x1, mpidr_el1 mov x2, #0 bl arm_cpu_topology_set + + /* get cache configuration */ mov x0, xzr bl aarch64_getcacheinfo
CVS commit: src/external/gpl3/gcc/usr.bin
Module Name:src Committed By: fox Date: Sun Feb 9 08:04:40 UTC 2020 Modified Files: src/external/gpl3/gcc/usr.bin/cc1: Makefile src/external/gpl3/gcc/usr.bin/cc1obj: Makefile Log Message: external/gpl3/gcc: Suppress -Werror=format-overflow error. Add -Wno-error=format-overflow for c-cppbuiltin.c and c-typeck.c to prevent build failure. Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/external/gpl3/gcc/usr.bin/cc1/Makefile cvs rdiff -u -r1.12 -r1.13 src/external/gpl3/gcc/usr.bin/cc1obj/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/gpl3/gcc/usr.bin/cc1/Makefile diff -u src/external/gpl3/gcc/usr.bin/cc1/Makefile:1.14 src/external/gpl3/gcc/usr.bin/cc1/Makefile:1.15 --- src/external/gpl3/gcc/usr.bin/cc1/Makefile:1.14 Wed Feb 6 16:57:30 2019 +++ src/external/gpl3/gcc/usr.bin/cc1/Makefile Sun Feb 9 08:04:40 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.14 2019/02/06 16:57:30 christos Exp $ +# $NetBSD: Makefile,v 1.15 2020/02/09 08:04:40 fox Exp $ PROG= cc1 SRCS= ${G_C_OBJS:S,c-family/,,:S,c/,,:Nlibcpp.a:.o=.c} main.c ${PROG}-checksum.c @@ -32,7 +32,7 @@ COPTS.c-ada-spec.c= -Wno-stack-protector COPTS.c-attribs.c= -Wno-stack-protector COPTS.c-aux-info.c= -Wno-stack-protector COPTS.c-common.c= -Wno-stack-protector -COPTS.c-cppbuiltin.c= -Wno-stack-protector +COPTS.c-cppbuiltin.c= -Wno-stack-protector -Wno-error=format-overflow COPTS.c-decl.c= -Wno-stack-protector COPTS.c-format.c= -Wno-stack-protector COPTS.c-format.h= -Wno-stack-protector @@ -40,7 +40,7 @@ COPTS.c-lex.c= -Wno-stack-protector COPTS.c-opts.c= -Wno-stack-protector COPTS.c-ppoutput.c= -Wno-stack-protector COPTS.c-pragma.c= -Wno-stack-protector -COPTS.c-typeck.c= -Wno-stack-protector +COPTS.c-typeck.c= -Wno-stack-protector -Wno-error=format-overflow CPPFLAGS.default-c.c+= -I${BACKENDOBJ} Index: src/external/gpl3/gcc/usr.bin/cc1obj/Makefile diff -u src/external/gpl3/gcc/usr.bin/cc1obj/Makefile:1.12 src/external/gpl3/gcc/usr.bin/cc1obj/Makefile:1.13 --- src/external/gpl3/gcc/usr.bin/cc1obj/Makefile:1.12 Wed Feb 6 16:57:30 2019 +++ src/external/gpl3/gcc/usr.bin/cc1obj/Makefile Sun Feb 9 08:04:40 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.12 2019/02/06 16:57:30 christos Exp $ +# $NetBSD: Makefile,v 1.13 2020/02/09 08:04:40 fox Exp $ MYOBJS= ${G_OBJC_OBJS} ${G_C_AND_OBJC_OBJS} PROG= cc1obj @@ -35,13 +35,13 @@ COPTS.c-ada-spec.c+= -Wno-stack-protec COPTS.c-attribs.c+= -Wno-stack-protector COPTS.c-aux-info.c+= -Wno-stack-protector COPTS.c-common.c+= -Wno-stack-protector -COPTS.c-cppbuiltin.c+= -Wno-stack-protector +COPTS.c-cppbuiltin.c+= -Wno-stack-protector -Wno-error=format-overflow COPTS.c-decl.c+= -Wno-stack-protector COPTS.c-format.c+= -Wno-stack-protector COPTS.c-lex.c+=-Wno-stack-protector COPTS.c-ppoutput.c+= -Wno-stack-protector COPTS.c-pragma.c+= -Wno-stack-protector -COPTS.c-typeck.c+= -Wno-stack-protector +COPTS.c-typeck.c+= -Wno-stack-protector -Wno-error=format-overflow COPTS.objc-act.c+= -Wno-stack-protector COPTS.objc-gnu-runtime-abi-01.c+= -Wno-stack-protector COPTS.objc-next-runtime-abi-01.c+= -Wno-stack-protector
CVS commit: src/external/mpl/dhcp/bin/server
Module Name:src Committed By: fox Date: Sun Feb 9 07:59:44 UTC 2020 Modified Files: src/external/mpl/dhcp/bin/server: Makefile Log Message: external/mpl/dhcp: Suppress -Werror=format-overflow error. Add -Wno-error=format-overflow mdb6.c to prevent build failure. Error was reported when build.sh was run with MKLIBCSANITIZER=yes flag. Reviewed by: kamil@ To generate a diff of this commit: cvs rdiff -u -r1.2 -r1.3 src/external/mpl/dhcp/bin/server/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/mpl/dhcp/bin/server/Makefile diff -u src/external/mpl/dhcp/bin/server/Makefile:1.2 src/external/mpl/dhcp/bin/server/Makefile:1.3 --- src/external/mpl/dhcp/bin/server/Makefile:1.2 Wed Oct 30 00:25:00 2019 +++ src/external/mpl/dhcp/bin/server/Makefile Sun Feb 9 07:59:44 2020 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2019/10/30 00:25:00 christos Exp $ +# $NetBSD: Makefile,v 1.3 2020/02/09 07:59:44 fox Exp $ .include @@ -19,6 +19,7 @@ FILES= dhcpd.conf COPTS.ddns.c +=-Wno-stringop-overflow .endif +COPTS.mdb6.c += -Wno-error=format-overflow COPTS.omapi.c += -Wno-stack-protector .include