CVS commit: src/external/bsd/flex/bin
Module Name:src Committed By: mrg Date: Tue Feb 5 07:47:15 UTC 2019 Modified Files: src/external/bsd/flex/bin: Makefile Log Message: force -O1 (unless -O0 already present) on m68k with GCC 7. avoids a "too-far" reference in scan.c. was already close with GCC 6. To generate a diff of this commit: cvs rdiff -u -r1.12 -r1.13 src/external/bsd/flex/bin/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/flex/bin/Makefile diff -u src/external/bsd/flex/bin/Makefile:1.12 src/external/bsd/flex/bin/Makefile:1.13 --- src/external/bsd/flex/bin/Makefile:1.12 Sun Dec 23 16:27:17 2018 +++ src/external/bsd/flex/bin/Makefile Tue Feb 5 07:47:15 2019 @@ -1,5 +1,5 @@ # from: @(#)Makefile 5.4 (Berkeley) 6/24/90 -# $NetBSD: Makefile,v 1.12 2018/12/23 16:27:17 christos Exp $ +# $NetBSD: Makefile,v 1.13 2019/02/05 07:47:15 mrg Exp $ # # By default, flex will be configured to generate 8-bit scanners only if the # -8 flag is given. If you want it to always generate 8-bit scanners, add @@ -71,4 +71,11 @@ scan.c: scan.l scan.o yylex.o: parse.h +# Ugh. Generates too large offsets with -O2. +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +. if ${MACHINE_CPU} == "m68k" && empty(CFLAGS:M-O0) +COPTS.scan.c+=-O1 +. endif +.endif + .include
CVS commit: src/external/bsd/libpcap/lib
Module Name:src Committed By: mrg Date: Tue Feb 5 07:45:35 UTC 2019 Modified Files: src/external/bsd/libpcap/lib: Makefile Log Message: ignore a format truncation issue. To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 src/external/bsd/libpcap/lib/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/libpcap/lib/Makefile diff -u src/external/bsd/libpcap/lib/Makefile:1.22 src/external/bsd/libpcap/lib/Makefile:1.23 --- src/external/bsd/libpcap/lib/Makefile:1.22 Mon Feb 4 04:05:16 2019 +++ src/external/bsd/libpcap/lib/Makefile Tue Feb 5 07:45:35 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.22 2019/02/04 04:05:16 mrg Exp $ +# $NetBSD: Makefile,v 1.23 2019/02/05 07:45:35 mrg Exp $ USE_SHLIBDIR=yes .include @@ -175,4 +175,8 @@ tokdefs.h: grammar.h CLEANFILES+= tokdefs.h scanner.h COPTS.bpf_image.c = -Wno-format-nonliteral +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.pcap.c+= -Wno-error=format-truncation +.endif + .include
CVS commit: src/external/gpl3/gcc
Module Name:src Committed By: mrg Date: Tue Feb 5 07:43:08 UTC 2019 Modified Files: src/external/gpl3/gcc: README.gcc7 Log Message: update status: - alpha, i386, powerpc, sparc64 all seem to work too, though sparc64 has a caveat with signed vs. unsigned "fast" integer types, and its ramdisk overflows. - hppa almost works. 1 uncommited change, ramdisk overflows. - m68k begins to work. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/external/gpl3/gcc/README.gcc7 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/README.gcc7 diff -u src/external/gpl3/gcc/README.gcc7:1.3 src/external/gpl3/gcc/README.gcc7:1.4 --- src/external/gpl3/gcc/README.gcc7:1.3 Mon Feb 4 03:19:23 2019 +++ src/external/gpl3/gcc/README.gcc7 Tue Feb 5 07:43:08 2019 @@ -1,4 +1,4 @@ -$NetBSD: README.gcc7,v 1.3 2019/02/04 03:19:23 mrg Exp $ +$NetBSD: README.gcc7,v 1.4 2019/02/05 07:43:08 mrg Exp $ new stuff (from gcc 5): cc1objcplus @@ -27,7 +27,7 @@ atf: does atf run / compare well architecture tools kernels libgcc native-gcc make release runs atf - --- -- -- --- aarch64 y ? y y n[2] ? ? -alpha y ? y y ? ? ? +alpha y ? y y y y ? arm ? ? ? ? ? ? ? armeb ? ? ? ? ? ? ? earm ? ? ? ? ? ? ? @@ -44,21 +44,21 @@ earmv7 ? ? ? ? ? ? ? earmv7eb ? ? ? ? ? ? ? earmv7hf ? ? ? ? ? ? ? earmv7hfeb ? ? ? ? ? ? ? -hppa y ? ? y ? ? ? -i386 y builds ? y y ? ? +hppa y n[6] y y n[7] ? ? +i386 y y y y y y ? ia64 y ? ? y ? ? ? m68000 n[4] ? ? ? ? ? ? -m68k ? ? ? ? ? ? ? +m68k y ? y y ? ? ? mipseb y ? ? y ? ? ? mipsel y ? ? y ? ? ? mips64eb y y y y y y ? mips64el y ? ? y ? ? ? -powerpc ? ? ? ? ? ? ? +powerpc y y y y y y ? powerpc64 ? ? ? ? ? ? ? -sh3eb y ? ? y ? ? ? -sh3el y ? ? y ? ? ? +sh3eb y ? y y ? ? ? +sh3el y ? y y ? ? ? sparc y y y y y y ? -sparc64 y ? ? n[1] ? ? ? +sparc64 y y y y[1] n[8] y ? vax y ? ? y y/n[3] ? ? x86_64 y y y y y y y -- @@ -69,7 +69,8 @@ coldfire ? N/A ? ? ? N/A N/A - --- -- -- --- architecture tools kernels libgcc native-gcc make release runs atf -[1] - sparc64-gcc gets ICE at startup +[1] - sparc64-gcc gets ICE at startup. because sizeof(ufast8/16/32) != sizeof(sfast8/16/32) + -- uncommited hack to workaround it seems to work fine. [2] - __curbrk won't link libc.so [3] - gcc can't be built: /usr/src6/external/gpl3/gcc/dist/gcc/calls.c:1361:1: error: unrecognizable insn: @@ -85,3 +86,7 @@ architecture tools kernels libgcc native - the rest of the world builds fine. [4] - ar: netbsd.o: No such file or directory [5] - libstdc++ eh_personality.cc ends up with refs to arm eabi specific functions that are in libunwind for us +[6] - uncommited changes that need confirming. +[7] - ramdisk fails: 32,nbmakefs: Writing inode 1562 (work/./usr/mdec/boot), bytes 229376 + 4096: No space left on device +[8] - ramdisk fails: 32,nbmakefs: Writing inode 1026 (work/./usr/share/zoneinfo/US/Alaska), bytes 0 + 2380: No space left on device +
CVS commit: src/external/bsd/tcpdump/dist
Module Name:src Committed By: mrg Date: Tue Feb 5 07:27:47 UTC 2019 Modified Files: src/external/bsd/tcpdump/dist: print-hncp.c Log Message: - pass correct size of buffer to snprintf() to avoid potential truncation To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/external/bsd/tcpdump/dist/print-hncp.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/tcpdump/dist/print-hncp.c diff -u src/external/bsd/tcpdump/dist/print-hncp.c:1.4 src/external/bsd/tcpdump/dist/print-hncp.c:1.5 --- src/external/bsd/tcpdump/dist/print-hncp.c:1.4 Fri Sep 8 14:01:13 2017 +++ src/external/bsd/tcpdump/dist/print-hncp.c Tue Feb 5 07:27:46 2019 @@ -28,7 +28,7 @@ #include #ifndef lint -__RCSID("$NetBSD: print-hncp.c,v 1.4 2017/09/08 14:01:13 christos Exp $"); +__RCSID("$NetBSD: print-hncp.c,v 1.5 2019/02/05 07:27:46 mrg Exp $"); #endif /* \summary: Home Networking Control Protocol (HNCP) printer */ @@ -177,7 +177,7 @@ format_256(const u_char *data) static char buf[4][64+5]; static int i = 0; i = (i + 1) % 4; -snprintf(buf[i], 28, "%016" PRIx64 "%016" PRIx64 "%016" PRIx64 "%016" PRIx64, +snprintf(buf[i], sizeof buf[i], "%016" PRIx64 "%016" PRIx64 "%016" PRIx64 "%016" PRIx64, EXTRACT_64BITS(data), EXTRACT_64BITS(data + 8), EXTRACT_64BITS(data + 16),
CVS commit: src/sys/arch/m68k/m68k
Module Name:src Committed By: mrg Date: Tue Feb 5 07:18:52 UTC 2019 Modified Files: src/sys/arch/m68k/m68k: db_disasm.c Log Message: add fallthru comment. To generate a diff of this commit: cvs rdiff -u -r1.41 -r1.42 src/sys/arch/m68k/m68k/db_disasm.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/m68k/m68k/db_disasm.c diff -u src/sys/arch/m68k/m68k/db_disasm.c:1.41 src/sys/arch/m68k/m68k/db_disasm.c:1.42 --- src/sys/arch/m68k/m68k/db_disasm.c:1.41 Sun Sep 21 16:32:51 2014 +++ src/sys/arch/m68k/m68k/db_disasm.c Tue Feb 5 07:18:52 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: db_disasm.c,v 1.41 2014/09/21 16:32:51 christos Exp $ */ +/* $NetBSD: db_disasm.c,v 1.42 2019/02/05 07:18:52 mrg Exp $ */ /* * Copyright (c) 1994 Christian E. Hopps @@ -63,7 +63,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: db_disasm.c,v 1.41 2014/09/21 16:32:51 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: db_disasm.c,v 1.42 2019/02/05 07:18:52 mrg Exp $"); #include #ifdef _KERNEL @@ -1500,6 +1500,7 @@ opcode_fpu(dis_buffer_t *dbuf, u_short o addstr (dbuf, "fnop"); return; } + /* FALLTHROUGH */ case 3: addstr(dbuf, "fb"); print_fcond(dbuf, BITFIELD(opc,5,0));
CVS commit: src/sys/kern
Module Name:src Committed By: thorpej Date: Tue Feb 5 07:14:32 UTC 2019 Modified Files: src/sys/kern: uipc_sem.c Log Message: In ksem_close_fop(), if we get a pshared semaphore that's not already been marked dead, make sure we mark it so if the owner proc is the proc closing it. (This case can happen if a process sem_init()'s a pshared semaphore and then exits without destroying it.) Fixes kern/53942. To generate a diff of this commit: cvs rdiff -u -r1.52 -r1.53 src/sys/kern/uipc_sem.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/uipc_sem.c diff -u src/sys/kern/uipc_sem.c:1.52 src/sys/kern/uipc_sem.c:1.53 --- src/sys/kern/uipc_sem.c:1.52 Sun Feb 3 03:20:23 2019 +++ src/sys/kern/uipc_sem.c Tue Feb 5 07:14:32 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_sem.c,v 1.52 2019/02/03 03:20:23 thorpej Exp $ */ +/* $NetBSD: uipc_sem.c,v 1.53 2019/02/05 07:14:32 thorpej Exp $ */ /*- * Copyright (c) 2011, 2019 The NetBSD Foundation, Inc. @@ -60,7 +60,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_sem.c,v 1.52 2019/02/03 03:20:23 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_sem.c,v 1.53 2019/02/05 07:14:32 thorpej Exp $"); #include #include @@ -840,12 +840,18 @@ ksem_close_fop(file_t *fp) { ksem_t *ks = fp->f_ksem; - if (ks->ks_pshared_id != 0 && ks->ks_pshared_proc != curproc) { - /* Do nothing if this is not the creator. */ - return 0; + mutex_enter(>ks_lock); + + if (ks->ks_pshared_id) { + if (ks->ks_pshared_proc != curproc) { + /* Do nothing if this is not the creator. */ + mutex_exit(>ks_lock); + return 0; + } + /* Mark this semaphore as dead. */ + ks->ks_pshared_proc = NULL; } - mutex_enter(>ks_lock); ksem_release(ks, -1); return 0; }
CVS commit: src/external/gpl3/gcc
Module Name:src Committed By: mrg Date: Tue Feb 5 06:46:48 UTC 2019 Modified Files: src/external/gpl3/gcc/lib/libbacktrace/arch/m68k: backtrace-supported.h src/external/gpl3/gcc/lib/libgcc/arch/m68k: auto-target.h defs.mk src/external/gpl3/gcc/lib/libgcc/libgcov/arch/m68k: defs.mk gcov-iov.h src/external/gpl3/gcc/lib/libgomp/arch/m68k: config.h libgomp_f.h omp.h src/external/gpl3/gcc/lib/libobjc/arch/m68k: defs.mk src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k: c++config.h cxxabi_tweaks.h defs.mk gstdint.h gthr-posix.h gthr-single.h gthr.h src/external/gpl3/gcc/usr.bin/gcc/arch/m68k: auto-host.h bversion.h configargs.h defs.mk gtyp-input.list insn-modes.h plugin-version.h src/external/gpl3/gcc/usr.bin/libcpp/arch/m68k: config.h Added Files: src/external/gpl3/gcc/lib/libgcc/arch/m68k: gthr-defs.mk src/external/gpl3/gcc/lib/libgcc/arch/sparc64: gthr-defs.mk src/external/gpl3/gcc/usr.bin/common-target/arch: m68k.mk sparc64.mk Log Message: mknative-gcc for m68k and GCC 7, also the files missed for sparc64 previously. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libbacktrace/arch/m68k/backtrace-supported.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libgcc/arch/m68k/auto-target.h cvs rdiff -u -r1.6 -r1.7 src/external/gpl3/gcc/lib/libgcc/arch/m68k/defs.mk cvs rdiff -u -r0 -r1.1 \ src/external/gpl3/gcc/lib/libgcc/arch/m68k/gthr-defs.mk cvs rdiff -u -r0 -r1.1 \ src/external/gpl3/gcc/lib/libgcc/arch/sparc64/gthr-defs.mk cvs rdiff -u -r1.3 -r1.4 \ src/external/gpl3/gcc/lib/libgcc/libgcov/arch/m68k/defs.mk cvs rdiff -u -r1.12 -r1.13 \ src/external/gpl3/gcc/lib/libgcc/libgcov/arch/m68k/gcov-iov.h cvs rdiff -u -r1.7 -r1.8 src/external/gpl3/gcc/lib/libgomp/arch/m68k/config.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libgomp/arch/m68k/libgomp_f.h cvs rdiff -u -r1.5 -r1.6 src/external/gpl3/gcc/lib/libgomp/arch/m68k/omp.h cvs rdiff -u -r1.3 -r1.4 src/external/gpl3/gcc/lib/libobjc/arch/m68k/defs.mk cvs rdiff -u -r1.25 -r1.26 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/c++config.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/cxxabi_tweaks.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/gthr-posix.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/gthr-single.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/gthr.h cvs rdiff -u -r1.9 -r1.10 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/defs.mk cvs rdiff -u -r1.15 -r1.16 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/m68k/gstdint.h cvs rdiff -u -r0 -r1.1 \ src/external/gpl3/gcc/usr.bin/common-target/arch/m68k.mk \ src/external/gpl3/gcc/usr.bin/common-target/arch/sparc64.mk cvs rdiff -u -r1.13 -r1.14 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/auto-host.h \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/plugin-version.h cvs rdiff -u -r1.10 -r1.11 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/bversion.h cvs rdiff -u -r1.25 -r1.26 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/configargs.h cvs rdiff -u -r1.15 -r1.16 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/defs.mk cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/gtyp-input.list cvs rdiff -u -r1.2 -r1.3 \ src/external/gpl3/gcc/usr.bin/gcc/arch/m68k/insn-modes.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/usr.bin/libcpp/arch/m68k/config.h 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/lib/libbacktrace/arch/m68k/backtrace-supported.h diff -u src/external/gpl3/gcc/lib/libbacktrace/arch/m68k/backtrace-supported.h:1.4 src/external/gpl3/gcc/lib/libbacktrace/arch/m68k/backtrace-supported.h:1.5 --- src/external/gpl3/gcc/lib/libbacktrace/arch/m68k/backtrace-supported.h:1.4 Tue Feb 6 09:18:16 2018 +++ src/external/gpl3/gcc/lib/libbacktrace/arch/m68k/backtrace-supported.h Tue Feb 5 06:46:47 2019 @@ -1,9 +1,9 @@ /* This file is automatically generated. DO NOT EDIT! */ -/* Generated from: NetBSD: mknative-gcc,v 1.91 2018/02/03 19:06:25 mrg Exp */ -/* Generated from: NetBSD: mknative.common,v 1.15 2017/11/29 03:32:28 christos Exp */ +/* Generated from: NetBSD: mknative-gcc,v 1.99 2019/02/04 01:46:59 mrg Exp */ +/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp */ /* backtrace-supported.h.in -- Whether stack backtrace is supported. - Copyright (C) 2012-2016 Free Software Foundation, Inc. + Copyright (C) 2012-2017 Free Software Foundation, Inc. Written by Ian Lance Taylor, Google. Redistribution and use in source and binary forms, with or without @@ -11,13 +11,13 @@ modification, are permitted provided tha met: (1) Redistributions of source code must retain the above copyright -notice, this list of
CVS commit: src/sys/net
Module Name:src Committed By: msaitoh Date: Tue Feb 5 06:43:20 UTC 2019 Modified Files: src/sys/net: if.h Log Message: Remove NOTRAILERS from IFFBITS. To generate a diff of this commit: cvs rdiff -u -r1.267 -r1.268 src/sys/net/if.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/net/if.h diff -u src/sys/net/if.h:1.267 src/sys/net/if.h:1.268 --- src/sys/net/if.h:1.267 Tue Feb 5 06:17:03 2019 +++ src/sys/net/if.h Tue Feb 5 06:43:20 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: if.h,v 1.267 2019/02/05 06:17:03 msaitoh Exp $ */ +/* $NetBSD: if.h,v 1.268 2019/02/05 06:43:20 msaitoh Exp $ */ /*- * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc. @@ -572,7 +572,7 @@ if_is_link_state_changeable(struct ifnet #endif /* _KERNEL */ #define IFFBITS \ -"\020\1UP\2BROADCAST\3DEBUG\4LOOPBACK\5POINTOPOINT\6NOTRAILERS" \ +"\020\1UP\2BROADCAST\3DEBUG\4LOOPBACK\5POINTOPOINT" \ "\7RUNNING\10NOARP\11PROMISC\12ALLMULTI\13OACTIVE\14SIMPLEX" \ "\15LINK0\16LINK1\17LINK2\20MULTICAST"
CVS commit: src
Module Name:src Committed By: msaitoh Date: Tue Feb 5 06:17:03 UTC 2019 Modified Files: src/share/man/man4/man4.vax: ec.4 en.4 ex.4 ix.4 vv.4 src/sys/arch/acorn32/podulebus: if_ie.c src/sys/arch/amiga/dev: if_es.c if_qn.c src/sys/arch/arm/at91: at91emac.c src/sys/arch/arm/ep93xx: epe.c src/sys/arch/emips/ebus: if_le_ebus.c src/sys/arch/mac68k/dev: if_mc.c src/sys/arch/mac68k/nubus: if_netdock_nubus.c src/sys/arch/macppc/dev: am79c950.c if_bm.c if_gm.c src/sys/arch/mips/sibyte/dev: sbmac.c src/sys/arch/newsmips/apbus: if_sn.c src/sys/arch/next68k/dev: mb8795.c src/sys/arch/playstation2/dev: if_smap.c src/sys/arch/sgimips/hpc: if_sq.c src/sys/arch/sun2/dev: if_ec.c src/sys/arch/sun3/dev: if_ie.c src/sys/arch/xen/xen: if_xennet_xenbus.c xennetback_xenbus.c src/sys/dev/cadence: if_cemac.c src/sys/dev/ic: an.c atw.c awi.c cs89x0.c dm9000.c dp8390.c elink3.c elinkxl.c gem.c hme.c i82586.c lance.c lemac.c mb86950.c mb86960.c pdq_ifsubr.c rrunner.c rtw.c seeq8005.c smc90cx6.c smc91cxx.c tropic.c wi.c src/sys/dev/isa: if_eg.c if_el.c if_iy.c src/sys/dev/ofw: ofnet.c src/sys/dev/pci: if_cas.c if_de.c if_devar.h if_jme.c if_tl.c if_vte.c src/sys/dev/pcmcia: if_cnw.c if_xi.c src/sys/dev/sbus: be.c qe.c src/sys/dev/scsipi: if_se.c src/sys/net: if.h if_fddisubr.c if_tokensubr.c src/usr.sbin/route6d: route6d.c Log Message: Remove very old IFF_NOTRAILERS flag. To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/share/man/man4/man4.vax/ec.4 cvs rdiff -u -r1.14 -r1.15 src/share/man/man4/man4.vax/en.4 \ src/share/man/man4/man4.vax/vv.4 cvs rdiff -u -r1.13 -r1.14 src/share/man/man4/man4.vax/ex.4 cvs rdiff -u -r1.20 -r1.21 src/share/man/man4/man4.vax/ix.4 cvs rdiff -u -r1.42 -r1.43 src/sys/arch/acorn32/podulebus/if_ie.c cvs rdiff -u -r1.60 -r1.61 src/sys/arch/amiga/dev/if_es.c cvs rdiff -u -r1.46 -r1.47 src/sys/arch/amiga/dev/if_qn.c cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/at91/at91emac.c cvs rdiff -u -r1.39 -r1.40 src/sys/arch/arm/ep93xx/epe.c cvs rdiff -u -r1.16 -r1.17 src/sys/arch/emips/ebus/if_le_ebus.c cvs rdiff -u -r1.48 -r1.49 src/sys/arch/mac68k/dev/if_mc.c cvs rdiff -u -r1.28 -r1.29 src/sys/arch/mac68k/nubus/if_netdock_nubus.c cvs rdiff -u -r1.41 -r1.42 src/sys/arch/macppc/dev/am79c950.c cvs rdiff -u -r1.56 -r1.57 src/sys/arch/macppc/dev/if_bm.c cvs rdiff -u -r1.51 -r1.52 src/sys/arch/macppc/dev/if_gm.c cvs rdiff -u -r1.53 -r1.54 src/sys/arch/mips/sibyte/dev/sbmac.c cvs rdiff -u -r1.43 -r1.44 src/sys/arch/newsmips/apbus/if_sn.c cvs rdiff -u -r1.60 -r1.61 src/sys/arch/next68k/dev/mb8795.c cvs rdiff -u -r1.27 -r1.28 src/sys/arch/playstation2/dev/if_smap.c cvs rdiff -u -r1.49 -r1.50 src/sys/arch/sgimips/hpc/if_sq.c cvs rdiff -u -r1.30 -r1.31 src/sys/arch/sun2/dev/if_ec.c cvs rdiff -u -r1.66 -r1.67 src/sys/arch/sun3/dev/if_ie.c cvs rdiff -u -r1.83 -r1.84 src/sys/arch/xen/xen/if_xennet_xenbus.c cvs rdiff -u -r1.73 -r1.74 src/sys/arch/xen/xen/xennetback_xenbus.c cvs rdiff -u -r1.15 -r1.16 src/sys/dev/cadence/if_cemac.c cvs rdiff -u -r1.69 -r1.70 src/sys/dev/ic/an.c cvs rdiff -u -r1.164 -r1.165 src/sys/dev/ic/atw.c cvs rdiff -u -r1.94 -r1.95 src/sys/dev/ic/awi.c cvs rdiff -u -r1.41 -r1.42 src/sys/dev/ic/cs89x0.c cvs rdiff -u -r1.15 -r1.16 src/sys/dev/ic/dm9000.c cvs rdiff -u -r1.91 -r1.92 src/sys/dev/ic/dp8390.c cvs rdiff -u -r1.145 -r1.146 src/sys/dev/ic/elink3.c cvs rdiff -u -r1.126 -r1.127 src/sys/dev/ic/elinkxl.c cvs rdiff -u -r1.113 -r1.114 src/sys/dev/ic/gem.c cvs rdiff -u -r1.101 -r1.102 src/sys/dev/ic/hme.c cvs rdiff -u -r1.79 -r1.80 src/sys/dev/ic/i82586.c cvs rdiff -u -r1.54 -r1.55 src/sys/dev/ic/lance.c cvs rdiff -u -r1.49 -r1.50 src/sys/dev/ic/lemac.c cvs rdiff -u -r1.28 -r1.29 src/sys/dev/ic/mb86950.c cvs rdiff -u -r1.88 -r1.89 src/sys/dev/ic/mb86960.c src/sys/dev/ic/rrunner.c cvs rdiff -u -r1.61 -r1.62 src/sys/dev/ic/pdq_ifsubr.c cvs rdiff -u -r1.129 -r1.130 src/sys/dev/ic/rtw.c cvs rdiff -u -r1.60 -r1.61 src/sys/dev/ic/seeq8005.c cvs rdiff -u -r1.73 -r1.74 src/sys/dev/ic/smc90cx6.c cvs rdiff -u -r1.98 -r1.99 src/sys/dev/ic/smc91cxx.c cvs rdiff -u -r1.51 -r1.52 src/sys/dev/ic/tropic.c cvs rdiff -u -r1.249 -r1.250 src/sys/dev/ic/wi.c cvs rdiff -u -r1.95 -r1.96 src/sys/dev/isa/if_eg.c cvs rdiff -u -r1.97 -r1.98 src/sys/dev/isa/if_el.c cvs rdiff -u -r1.103 -r1.104 src/sys/dev/isa/if_iy.c cvs rdiff -u -r1.61 -r1.62 src/sys/dev/ofw/ofnet.c cvs rdiff -u -r1.30 -r1.31 src/sys/dev/pci/if_cas.c cvs rdiff -u -r1.157 -r1.158 src/sys/dev/pci/if_de.c cvs rdiff -u -r1.61 -r1.62 src/sys/dev/pci/if_devar.h cvs rdiff -u -r1.37 -r1.38 src/sys/dev/pci/if_jme.c cvs rdiff -u -r1.111 -r1.112 src/sys/dev/pci/if_tl.c cvs rdiff -u -r1.22 -r1.23 src/sys/dev/pci/if_vte.c cvs rdiff -u -r1.64 -r1.65 src/sys/dev/pcmcia/if_cnw.c cvs rdiff -u -r1.85
CVS commit: src/distrib/sets/lists/comp
Module Name:src Committed By: mrg Date: Tue Feb 5 06:14:55 UTC 2019 Modified Files: src/distrib/sets/lists/comp: md.sparc64 Log Message: mark ./usr/include/g++/bits/sparc and ./usr/include/g++/bits/sparc64 subdirs as non-compat. To generate a diff of this commit: cvs rdiff -u -r1.205 -r1.206 src/distrib/sets/lists/comp/md.sparc64 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/comp/md.sparc64 diff -u src/distrib/sets/lists/comp/md.sparc64:1.205 src/distrib/sets/lists/comp/md.sparc64:1.206 --- src/distrib/sets/lists/comp/md.sparc64:1.205 Sat Jan 19 13:06:50 2019 +++ src/distrib/sets/lists/comp/md.sparc64 Tue Feb 5 06:14:55 2019 @@ -1,7 +1,7 @@ -# $NetBSD: md.sparc64,v 1.205 2019/01/19 13:06:50 mrg Exp $ -./usr/include/g++/bits/sparc comp-c-include compat +# $NetBSD: md.sparc64,v 1.206 2019/02/05 06:14:55 mrg Exp $ +./usr/include/g++/bits/sparc comp-c-include ./usr/include/g++/bits/sparc/c++config.h comp-c-include gcc,compat -./usr/include/g++/bits/sparc64 comp-c-include compat +./usr/include/g++/bits/sparc64 comp-c-include ./usr/include/g++/bits/sparc64/c++config.h comp-c-include gcc,compat ./usr/include/gcc-4.5/tgmath.h comp-obsolete obsolete ./usr/include/gcc-4.8/tgmath.h comp-obsolete obsolete
CVS commit: src/sys/dev/pci
Module Name:src Committed By: mrg Date: Tue Feb 5 06:12:39 UTC 2019 Modified Files: src/sys/dev/pci: machfb.c Log Message: add or adjust fallthru comments. To generate a diff of this commit: cvs rdiff -u -r1.96 -r1.97 src/sys/dev/pci/machfb.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/machfb.c diff -u src/sys/dev/pci/machfb.c:1.96 src/sys/dev/pci/machfb.c:1.97 --- src/sys/dev/pci/machfb.c:1.96 Sun Feb 3 12:39:38 2019 +++ src/sys/dev/pci/machfb.c Tue Feb 5 06:12:39 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: machfb.c,v 1.96 2019/02/03 12:39:38 tnn Exp $ */ +/* $NetBSD: machfb.c,v 1.97 2019/02/05 06:12:39 mrg Exp $ */ /* * Copyright (c) 2002 Bang Jun-Young @@ -34,7 +34,7 @@ #include __KERNEL_RCSID(0, - "$NetBSD: machfb.c,v 1.96 2019/02/03 12:39:38 tnn Exp $"); + "$NetBSD: machfb.c,v 1.97 2019/02/05 06:12:39 mrg Exp $"); #include #include @@ -519,6 +519,7 @@ mach64_attach(device_t parent, device_t case PCI_PRODUCT_ATI_MACH64_GX: case PCI_PRODUCT_ATI_MACH64_CX: is_gx = 1; + /* FALLTHROUGH */ case PCI_PRODUCT_ATI_MACH64_CT: sc->has_dsp = 0; break; @@ -528,7 +529,7 @@ mach64_attach(device_t parent, device_t sc->has_dsp = 0; break; } - /* Otherwise fall through. */ + /* FALLTHROUGH */ default: sc->has_dsp = 1; }
CVS commit: src/sys/arch/sparc64/dev
Module Name:src Committed By: mrg Date: Tue Feb 5 06:10:53 UTC 2019 Modified Files: src/sys/arch/sparc64/dev: fdc.c psycho.c schizo.c Log Message: add or avoid fallthru comments. To generate a diff of this commit: cvs rdiff -u -r1.45 -r1.46 src/sys/arch/sparc64/dev/fdc.c cvs rdiff -u -r1.126 -r1.127 src/sys/arch/sparc64/dev/psycho.c cvs rdiff -u -r1.39 -r1.40 src/sys/arch/sparc64/dev/schizo.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/sparc64/dev/fdc.c diff -u src/sys/arch/sparc64/dev/fdc.c:1.45 src/sys/arch/sparc64/dev/fdc.c:1.46 --- src/sys/arch/sparc64/dev/fdc.c:1.45 Mon Sep 3 16:29:27 2018 +++ src/sys/arch/sparc64/dev/fdc.c Tue Feb 5 06:10:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: fdc.c,v 1.45 2018/09/03 16:29:27 riastradh Exp $ */ +/* $NetBSD: fdc.c,v 1.46 2019/02/05 06:10:53 mrg Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -101,7 +101,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: fdc.c,v 1.45 2018/09/03 16:29:27 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: fdc.c,v 1.46 2019/02/05 06:10:53 mrg Exp $"); #include "opt_ddb.h" #include "opt_md.h" @@ -2010,12 +2010,13 @@ loop: case RECALWAIT: callout_stop(>sc_timo_ch); fdc->sc_state = RECALCOMPLETE; - if (fdc->sc_flags & FDC_NEEDHEADSETTLE) { + if ((fdc->sc_flags & FDC_NEEDHEADSETTLE) != 0) { /* allow 1/30 second for heads to settle */ callout_reset(>sc_intr_ch, hz / 30, fdcpseudointr, fdc); return 1; /* will return later */ } + /* FALLTHROUGH */ case RECALCOMPLETE: if (fdc->sc_nstat != 2 || (st0 & 0xf8) != 0x20 || cyl != 0) { Index: src/sys/arch/sparc64/dev/psycho.c diff -u src/sys/arch/sparc64/dev/psycho.c:1.126 src/sys/arch/sparc64/dev/psycho.c:1.127 --- src/sys/arch/sparc64/dev/psycho.c:1.126 Sun Mar 26 12:51:42 2017 +++ src/sys/arch/sparc64/dev/psycho.c Tue Feb 5 06:10:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: psycho.c,v 1.126 2017/03/26 12:51:42 martin Exp $ */ +/* $NetBSD: psycho.c,v 1.127 2019/02/05 06:10:53 mrg Exp $ */ /* * Copyright (c) 1999, 2000 Matthew R. Green @@ -55,7 +55,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: psycho.c,v 1.126 2017/03/26 12:51:42 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: psycho.c,v 1.127 2019/02/05 06:10:53 mrg Exp $"); #include "opt_ddb.h" @@ -1068,11 +1068,16 @@ psycho_iommu_init(struct psycho_softc *s iobase = vdma[0]; #define TSBCASE(x) case 1<<((x)+23): tsbsize = (x); break switch (vdma[1]) { - TSBCASE(1); TSBCASE(2); TSBCASE(3); - TSBCASE(4); TSBCASE(5); TSBCASE(6); + TSBCASE(1); + TSBCASE(2); + TSBCASE(3); + TSBCASE(4); + TSBCASE(5); + TSBCASE(6); + TSBCASE(7); default: printf("bogus tsb size %x, using 7\n", vdma[1]); - TSBCASE(7); + tsbsize = 7; } #undef TSBCASE } Index: src/sys/arch/sparc64/dev/schizo.c diff -u src/sys/arch/sparc64/dev/schizo.c:1.39 src/sys/arch/sparc64/dev/schizo.c:1.40 --- src/sys/arch/sparc64/dev/schizo.c:1.39 Sat Jun 3 21:32:43 2017 +++ src/sys/arch/sparc64/dev/schizo.c Tue Feb 5 06:10:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: schizo.c,v 1.39 2017/06/03 21:32:43 mrg Exp $ */ +/* $NetBSD: schizo.c,v 1.40 2019/02/05 06:10:53 mrg Exp $ */ /* $OpenBSD: schizo.c,v 1.55 2008/08/18 20:29:37 brad Exp $ */ /* @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: schizo.c,v 1.39 2017/06/03 21:32:43 mrg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: schizo.c,v 1.40 2019/02/05 06:10:53 mrg Exp $"); #include #include @@ -490,11 +490,16 @@ schizo_init_iommu(struct schizo_softc *s iobase = vdma[0]; #define TSBCASE(x) case 1 << ((x) + 23): tsbsize = (x); break switch (vdma[1]) { - TSBCASE(1); TSBCASE(2); TSBCASE(3); - TSBCASE(4); TSBCASE(5); TSBCASE(6); + TSBCASE(1); + TSBCASE(2); + TSBCASE(3); + TSBCASE(4); + TSBCASE(5); + TSBCASE(6); + TSBCASE(7); default: printf("bogus tsb size %x, using 7\n", vdma[1]); - TSBCASE(7); + tsbsize = 7; } #undef TSBCASE DPRINTF(SDB_BUSMAP, ("schizo_init_iommu: iobase=0x%x\n", iobase));
CVS commit: src/etc/mtree
Module Name:src Committed By: mrg Date: Tue Feb 5 06:11:29 UTC 2019 Modified Files: src/etc/mtree: NetBSD.dist.base Log Message: add missing ./usr/include/dev/hdmicec To generate a diff of this commit: cvs rdiff -u -r1.188 -r1.189 src/etc/mtree/NetBSD.dist.base Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/etc/mtree/NetBSD.dist.base diff -u src/etc/mtree/NetBSD.dist.base:1.188 src/etc/mtree/NetBSD.dist.base:1.189 --- src/etc/mtree/NetBSD.dist.base:1.188 Mon Feb 4 04:45:48 2019 +++ src/etc/mtree/NetBSD.dist.base Tue Feb 5 06:11:29 2019 @@ -1,4 +1,4 @@ -# $NetBSD: NetBSD.dist.base,v 1.188 2019/02/04 04:45:48 mrg Exp $ +# $NetBSD: NetBSD.dist.base,v 1.189 2019/02/05 06:11:29 mrg Exp $ # @(#)4.4BSD.dist 8.1 (Berkeley) 6/13/93 # Do not customize this file as it may be overwritten on upgrades. @@ -119,6 +119,7 @@ ./usr/include/dev/dtv ./usr/include/dev/filemon ./usr/include/dev/hdaudio +./usr/include/dev/hdmicec ./usr/include/dev/hid ./usr/include/dev/hpc ./usr/include/dev/i2c
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Tue Feb 5 04:48:47 UTC 2019 Modified Files: src/sys/netinet: tcp_usrreq.c src/sys/netinet6: in6.c Log Message: adjust fallthru comments to appease gcc7. To generate a diff of this commit: cvs rdiff -u -r1.223 -r1.224 src/sys/netinet/tcp_usrreq.c cvs rdiff -u -r1.272 -r1.273 src/sys/netinet6/in6.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/netinet/tcp_usrreq.c diff -u src/sys/netinet/tcp_usrreq.c:1.223 src/sys/netinet/tcp_usrreq.c:1.224 --- src/sys/netinet/tcp_usrreq.c:1.223 Mon Jan 28 12:53:01 2019 +++ src/sys/netinet/tcp_usrreq.c Tue Feb 5 04:48:47 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: tcp_usrreq.c,v 1.223 2019/01/28 12:53:01 martin Exp $ */ +/* $NetBSD: tcp_usrreq.c,v 1.224 2019/02/05 04:48:47 mrg Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -99,7 +99,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: tcp_usrreq.c,v 1.223 2019/01/28 12:53:01 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: tcp_usrreq.c,v 1.224 2019/02/05 04:48:47 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -1689,8 +1689,8 @@ sysctl_net_inet_tcp_ident(SYSCTLFN_ARGS) in6_sin6_2_sin_in_sock((struct sockaddr *)[0]); in6_sin6_2_sin_in_sock((struct sockaddr *)[1]); - /*FALLTHROUGH*/ #endif /* INET6 */ + /*FALLTHROUGH*/ case PF_INET: si4[0] = (struct sockaddr_in*)[0]; si4[1] = (struct sockaddr_in*)[1]; Index: src/sys/netinet6/in6.c diff -u src/sys/netinet6/in6.c:1.272 src/sys/netinet6/in6.c:1.273 --- src/sys/netinet6/in6.c:1.272 Thu Nov 29 09:54:23 2018 +++ src/sys/netinet6/in6.c Tue Feb 5 04:48:47 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: in6.c,v 1.272 2018/11/29 09:54:23 ozaki-r Exp $ */ +/* $NetBSD: in6.c,v 1.273 2019/02/05 04:48:47 mrg Exp $ */ /* $KAME: in6.c,v 1.198 2001/07/18 09:12:38 itojun Exp $ */ /* @@ -62,7 +62,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: in6.c,v 1.272 2018/11/29 09:54:23 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: in6.c,v 1.273 2019/02/05 04:48:47 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -531,10 +531,11 @@ in6_control1(struct socket *so, u_long c error = EADDRNOTAVAIL; goto out; } - /* FALLTHROUGH */ #ifdef OSIOCAIFADDR_IN6 + /* FALLTHROUGH */ case OSIOCAIFADDR_IN6: #endif + /* FALLTHROUGH */ case SIOCAIFADDR_IN6: /* * We always require users to specify a valid IPv6 address for @@ -674,8 +675,8 @@ in6_control1(struct socket *so, u_long c #ifdef OSIOCAIFADDR_IN6 case OSIOCAIFADDR_IN6: in6_aliasreq50_to_in6_aliasreq(ifra); - /*FALLTHROUGH*/ #endif + /*FALLTHROUGH*/ case SIOCAIFADDR_IN6: { struct in6_addrlifetime *lt;
CVS commit: src/share/mk
Module Name:src Committed By: mrg Date: Tue Feb 5 04:47:59 UTC 2019 Modified Files: src/share/mk: bsd.own.mk Log Message: re-do version 1.1098 properly: - fix OBJECT_FMTS if mips64 and !MKCOMPAT To generate a diff of this commit: cvs rdiff -u -r1.1099 -r1.1100 src/share/mk/bsd.own.mk Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/mk/bsd.own.mk diff -u src/share/mk/bsd.own.mk:1.1099 src/share/mk/bsd.own.mk:1.1100 --- src/share/mk/bsd.own.mk:1.1099 Mon Feb 4 00:34:12 2019 +++ src/share/mk/bsd.own.mk Tue Feb 5 04:47:59 2019 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.own.mk,v 1.1099 2019/02/04 00:34:12 mrg Exp $ +# $NetBSD: bsd.own.mk,v 1.1100 2019/02/05 04:47:59 mrg Exp $ # This needs to be before bsd.init.mk .if defined(BSD_MK_COMPAT_FILE) @@ -320,7 +320,7 @@ TOOL_CXX.pcc= ${TOOLDIR}/bin/${MACHINE_ # DESTDIR?= -# Don't append another copy of sysroot (coming from COMPATCPPFLAGS etc. +# Don't append another copy of sysroot (coming from COMPATCPPFLAGS etc.) # because it confuses Coverity. Still we need to cov-configure specially # for each specific sysroot argument. .if !defined(HOSTPROG) && !defined(HOSTLIB) @@ -627,7 +627,9 @@ OBJECT_FMTS= OBJECT_FMTS+= elf32 .endif .if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH:M*64*} != "" +. if !(${MKCOMPAT:Uno} == "no" && ${MACHINE_CPU} == "mips") OBJECT_FMTS+= elf64 +. endif .endif # OBJCOPY flags to create a.out binaries for old firmware
CVS commit: src/external/gpl3/gcc/dist/gcc
Module Name:src Committed By: mrg Date: Tue Feb 5 04:45:50 UTC 2019 Modified Files: src/external/gpl3/gcc/dist/gcc: config.gcc Log Message: include sparc/default64.hon netbsd/sparc64. To generate a diff of this commit: cvs rdiff -u -r1.45 -r1.46 src/external/gpl3/gcc/dist/gcc/config.gcc 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.gcc diff -u src/external/gpl3/gcc/dist/gcc/config.gcc:1.45 src/external/gpl3/gcc/dist/gcc/config.gcc:1.46 --- src/external/gpl3/gcc/dist/gcc/config.gcc:1.45 Thu Jan 31 06:59:31 2019 +++ src/external/gpl3/gcc/dist/gcc/config.gcc Tue Feb 5 04:45:50 2019 @@ -3067,6 +3067,7 @@ sparc64-*-freebsd*|ultrasparc-*-freebsd* sparc64-*-netbsd*) tm_file="sparc/biarch64.h ${tm_file}" tm_file="${tm_file} dbxelf.h elfos.h sparc/sysv4.h ${nbsd_tm_file} sparc/netbsd-elf.h" + tm_file="${tm_file} sparc/default64.h" extra_options="${extra_options} netbsd.opt netbsd-elf.opt" extra_options="${extra_options} sparc/long-double-switch.opt" tmake_file="${tmake_file} sparc/t-sparc sparc/t-netbsd64"
CVS commit: src/external/gpl3/gcc/usr.bin/common-target
Module Name:src Committed By: mrg Date: Tue Feb 5 04:45:07 UTC 2019 Modified Files: src/external/gpl3/gcc/usr.bin/common-target: Makefile Log Message: remove 'common/' prefix from sources. To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/external/gpl3/gcc/usr.bin/common-target/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/common-target/Makefile diff -u src/external/gpl3/gcc/usr.bin/common-target/Makefile:1.7 src/external/gpl3/gcc/usr.bin/common-target/Makefile:1.8 --- src/external/gpl3/gcc/usr.bin/common-target/Makefile:1.7 Mon Feb 4 03:01:52 2019 +++ src/external/gpl3/gcc/usr.bin/common-target/Makefile Tue Feb 5 04:45:07 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.7 2019/02/04 03:01:52 mrg Exp $ +# $NetBSD: Makefile,v 1.8 2019/02/05 04:45:07 mrg Exp $ LIBISPRIVATE= yes @@ -8,7 +8,7 @@ LIBISPRIVATE= yes LIB= common-target .include "${.CURDIR}/arch/${GCC_MACHINE_ARCH}.mk" -SRCS= ${G_OBJS-libcommon-target:.o=.c} +SRCS= ${G_OBJS-libcommon-target:S/common\///:.o=.c} CPPFLAGS+= -I${GCCARCH} -I${BACKENDOBJ} -I. \ ${G_ALL_CFLAGS:M-D*} ${G_INCLUDES:M-I*:N-I.*} \
CVS commit: src/external/gpl3/gcc
Module Name:src Committed By: mrg Date: Tue Feb 5 04:43:45 UTC 2019 Modified Files: src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64: backtrace-supported.h src/external/gpl3/gcc/lib/libgcc/arch/sparc64: auto-target.h defs.mk src/external/gpl3/gcc/lib/libgcc/libgcov/arch/sparc64: defs.mk gcov-iov.h src/external/gpl3/gcc/lib/libgomp/arch/sparc64: config.h libgomp_f.h omp.h src/external/gpl3/gcc/lib/libobjc/arch/sparc64: defs.mk src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64: c++config.h cxxabi_tweaks.h defs.mk gstdint.h gthr-posix.h gthr-single.h gthr.h src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64: auto-host.h bversion.h configargs.h defs.mk gtyp-input.list insn-modes.h plugin-version.h tm.h src/external/gpl3/gcc/usr.bin/libcpp/arch/sparc64: config.h Log Message: mknative-gcc for gcc7 and sparc64. replies upon an uncommited (yet) change to not assert if the size of unsigned and signed 'fast' integer types are not the same. we don't have them as the same for 8, 16 and 32 bit for some reason. otherwise seems to work. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64/backtrace-supported.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libgcc/arch/sparc64/auto-target.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/gcc/lib/libgcc/arch/sparc64/defs.mk cvs rdiff -u -r1.3 -r1.4 \ src/external/gpl3/gcc/lib/libgcc/libgcov/arch/sparc64/defs.mk cvs rdiff -u -r1.12 -r1.13 \ src/external/gpl3/gcc/lib/libgcc/libgcov/arch/sparc64/gcov-iov.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libgomp/arch/sparc64/config.h \ src/external/gpl3/gcc/lib/libgomp/arch/sparc64/libgomp_f.h cvs rdiff -u -r1.5 -r1.6 src/external/gpl3/gcc/lib/libgomp/arch/sparc64/omp.h cvs rdiff -u -r1.3 -r1.4 \ src/external/gpl3/gcc/lib/libobjc/arch/sparc64/defs.mk cvs rdiff -u -r1.23 -r1.24 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/c++config.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/cxxabi_tweaks.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/gthr-posix.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/gthr-single.h \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/gthr.h cvs rdiff -u -r1.9 -r1.10 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/defs.mk cvs rdiff -u -r1.17 -r1.18 \ src/external/gpl3/gcc/lib/libstdc++-v3/arch/sparc64/gstdint.h cvs rdiff -u -r1.14 -r1.15 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/auto-host.h \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/defs.mk cvs rdiff -u -r1.10 -r1.11 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/bversion.h cvs rdiff -u -r1.30 -r1.31 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/configargs.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/gtyp-input.list \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/tm.h cvs rdiff -u -r1.2 -r1.3 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/insn-modes.h cvs rdiff -u -r1.13 -r1.14 \ src/external/gpl3/gcc/usr.bin/gcc/arch/sparc64/plugin-version.h cvs rdiff -u -r1.4 -r1.5 \ src/external/gpl3/gcc/usr.bin/libcpp/arch/sparc64/config.h 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/lib/libbacktrace/arch/sparc64/backtrace-supported.h diff -u src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64/backtrace-supported.h:1.4 src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64/backtrace-supported.h:1.5 --- src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64/backtrace-supported.h:1.4 Sun Feb 4 01:17:40 2018 +++ src/external/gpl3/gcc/lib/libbacktrace/arch/sparc64/backtrace-supported.h Tue Feb 5 04:43:44 2019 @@ -1,9 +1,9 @@ /* This file is automatically generated. DO NOT EDIT! */ -/* Generated from: NetBSD: mknative-gcc,v 1.91 2018/02/03 19:06:25 mrg Exp */ -/* Generated from: NetBSD: mknative.common,v 1.15 2017/11/29 03:32:28 christos Exp */ +/* Generated from: NetBSD: mknative-gcc,v 1.99 2019/02/04 01:46:59 mrg Exp */ +/* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp */ /* backtrace-supported.h.in -- Whether stack backtrace is supported. - Copyright (C) 2012-2016 Free Software Foundation, Inc. + Copyright (C) 2012-2017 Free Software Foundation, Inc. Written by Ian Lance Taylor, Google. Redistribution and use in source and binary forms, with or without @@ -11,13 +11,13 @@ modification, are permitted provided tha met: (1) Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. +notice, this list of conditions and the following disclaimer. (2) Redistributions in binary form must
CVS commit: src/tests/lib/libc/sys
Module Name:src Committed By: kamil Date: Tue Feb 5 02:57:10 UTC 2019 Modified Files: src/tests/lib/libc/sys: t_ptrace_x86_wait.h Log Message: Add missing break keywords in t_ptrace_wait* x86 tests Add missing break in switch() cases in dbregs_trap_variable(). Reported by Detected by GCC 7 To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/tests/lib/libc/sys/t_ptrace_x86_wait.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/lib/libc/sys/t_ptrace_x86_wait.h diff -u src/tests/lib/libc/sys/t_ptrace_x86_wait.h:1.7 src/tests/lib/libc/sys/t_ptrace_x86_wait.h:1.8 --- src/tests/lib/libc/sys/t_ptrace_x86_wait.h:1.7 Sat May 26 20:27:48 2018 +++ src/tests/lib/libc/sys/t_ptrace_x86_wait.h Tue Feb 5 02:57:10 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: t_ptrace_x86_wait.h,v 1.7 2018/05/26 20:27:48 kamil Exp $ */ +/* $NetBSD: t_ptrace_x86_wait.h,v 1.8 2019/02/05 02:57:10 kamil Exp $ */ /*- * Copyright (c) 2016 The NetBSD Foundation, Inc. @@ -405,14 +405,17 @@ dbregs_trap_variable(int reg, int cond, dr7.bits.global_dr0_breakpoint = 1; dr7.bits.condition_dr0 = cond; dr7.bits.len_dr0 = len; + break; case 1: dr7.bits.global_dr1_breakpoint = 1; dr7.bits.condition_dr1 = cond; dr7.bits.len_dr1 = len; + break; case 2: dr7.bits.global_dr2_breakpoint = 1; dr7.bits.condition_dr2 = cond; dr7.bits.len_dr2 = len; + break; case 3: dr7.bits.global_dr3_breakpoint = 1; dr7.bits.condition_dr3 = cond;
CVS commit: src/sys/compat/freebsd
Module Name:src Committed By: pgoyette Date: Tue Feb 5 00:40:15 UTC 2019 Modified Files: src/sys/compat/freebsd: freebsd_mod.c Log Message: Update compat_freebsd requirements list to use compat_09 vs compat To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/compat/freebsd/freebsd_mod.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/compat/freebsd/freebsd_mod.c diff -u src/sys/compat/freebsd/freebsd_mod.c:1.6 src/sys/compat/freebsd/freebsd_mod.c:1.7 --- src/sys/compat/freebsd/freebsd_mod.c:1.6 Sat Jul 29 10:39:48 2017 +++ src/sys/compat/freebsd/freebsd_mod.c Tue Feb 5 00:40:15 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: freebsd_mod.c,v 1.6 2017/07/29 10:39:48 maxv Exp $ */ +/* $NetBSD: freebsd_mod.c,v 1.7 2019/02/05 00:40:15 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: freebsd_mod.c,v 1.6 2017/07/29 10:39:48 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: freebsd_mod.c,v 1.7 2019/02/05 00:40:15 pgoyette Exp $"); #ifdef _KERNEL_OPT #include "opt_execfmt.h" @@ -54,7 +54,7 @@ __KERNEL_RCSID(0, "$NetBSD: freebsd_mod. #define ELF32_AUXSIZE (howmany(ELF_AUX_ENTRIES * sizeof(Aux32Info), \ sizeof(Elf32_Addr)) + MAXPATHLEN + ALIGN(1)) -MODULE(MODULE_CLASS_EXEC, compat_freebsd, "compat,compat_ossaudio" MD1); +MODULE(MODULE_CLASS_EXEC, compat_freebsd, "compat_09,compat_ossaudio" MD1); static struct execsw freebsd_execsw[] = { #ifdef EXEC_ELF32
CVS commit: src/sys/compat
Module Name:src Committed By: pgoyette Date: Tue Feb 5 00:32:18 UTC 2019 Modified Files: src/sys/compat/sunos: sunos_mod.c src/sys/compat/sunos32: sunos32_mod.c Log Message: The sunos and sunos32 modules require compat_09, not compat (the latter no longer exists). Should fix "missing prerequisite" errors seen during qemu boot of sparc64's MODULAR kernel. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/compat/sunos/sunos_mod.c cvs rdiff -u -r1.4 -r1.5 src/sys/compat/sunos32/sunos32_mod.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/compat/sunos/sunos_mod.c diff -u src/sys/compat/sunos/sunos_mod.c:1.4 src/sys/compat/sunos/sunos_mod.c:1.5 --- src/sys/compat/sunos/sunos_mod.c:1.4 Sun Jan 27 02:08:40 2019 +++ src/sys/compat/sunos/sunos_mod.c Tue Feb 5 00:32:18 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: sunos_mod.c,v 1.4 2019/01/27 02:08:40 pgoyette Exp $ */ +/* $NetBSD: sunos_mod.c,v 1.5 2019/02/05 00:32:18 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sunos_mod.c,v 1.4 2019/01/27 02:08:40 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sunos_mod.c,v 1.5 2019/02/05 00:32:18 pgoyette Exp $"); #include #include @@ -43,7 +43,7 @@ __KERNEL_RCSID(0, "$NetBSD: sunos_mod.c, #include -MODULE(MODULE_CLASS_EXEC, compat_sunos, "compat,compat_util,exec_aout"); +MODULE(MODULE_CLASS_EXEC, compat_sunos, "compat_09,compat_util,exec_aout"); static struct execsw sunos_execsw = { .es_hdrsz = SUNOS_AOUT_HDR_SIZE, Index: src/sys/compat/sunos32/sunos32_mod.c diff -u src/sys/compat/sunos32/sunos32_mod.c:1.4 src/sys/compat/sunos32/sunos32_mod.c:1.5 --- src/sys/compat/sunos32/sunos32_mod.c:1.4 Sun Jan 27 02:08:40 2019 +++ src/sys/compat/sunos32/sunos32_mod.c Tue Feb 5 00:32:18 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: sunos32_mod.c,v 1.4 2019/01/27 02:08:40 pgoyette Exp $ */ +/* $NetBSD: sunos32_mod.c,v 1.5 2019/02/05 00:32:18 pgoyette Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sunos32_mod.c,v 1.4 2019/01/27 02:08:40 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sunos32_mod.c,v 1.5 2019/02/05 00:32:18 pgoyette Exp $"); #include #include @@ -46,7 +46,7 @@ __KERNEL_RCSID(0, "$NetBSD: sunos32_mod. #include MODULE(MODULE_CLASS_EXEC, compat_sunos, -"compat,compat_util,compat_netbsd32,exec_aout"); +"compat_09,compat_util,compat_netbsd32,exec_aout"); static struct execsw sunos_execsw = { .es_hdrsz = SUNOS32_AOUT_HDR_SIZE,
CVS commit: src/sys/fs/puffs
Module Name:src Committed By: pgoyette Date: Tue Feb 5 00:22:36 UTC 2019 Modified Files: src/sys/fs/puffs: files.puffs Log Message: It turns out we do want the puffs compat code in any kernel which has built-in compat_50 regardless of whether the kernel also has puffs. Should finally fix PR kern/53943 To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/fs/puffs/files.puffs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/fs/puffs/files.puffs diff -u src/sys/fs/puffs/files.puffs:1.9 src/sys/fs/puffs/files.puffs:1.10 --- src/sys/fs/puffs/files.puffs:1.9 Mon Feb 4 14:47:41 2019 +++ src/sys/fs/puffs/files.puffs Tue Feb 5 00:22:36 2019 @@ -1,9 +1,9 @@ -# $NetBSD: files.puffs,v 1.9 2019/02/04 14:47:41 wiz Exp $ +# $NetBSD: files.puffs,v 1.10 2019/02/05 00:22:36 pgoyette Exp $ deffs PUFFS define puffs: vfs -file fs/puffs/puffs_compat.c puffs & compat_50 +file fs/puffs/puffs_compat.c compat_50 file fs/puffs/puffs_msgif.c puffs file fs/puffs/puffs_node.c puffs file fs/puffs/puffs_subr.c puffs
CVS commit: src/sys/arch/arm/sunxi
Module Name:src Committed By: jmcneill Date: Tue Feb 5 00:21:35 UTC 2019 Modified Files: src/sys/arch/arm/sunxi: sunxi_mixer.c Log Message: Add support for video layer scaling and colour space conversion. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 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.3 src/sys/arch/arm/sunxi/sunxi_mixer.c:1.4 --- src/sys/arch/arm/sunxi/sunxi_mixer.c:1.3 Mon Feb 4 12:10:13 2019 +++ src/sys/arch/arm/sunxi/sunxi_mixer.c Tue Feb 5 00:21:35 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: sunxi_mixer.c,v 1.3 2019/02/04 12:10:13 jmcneill Exp $ */ +/* $NetBSD: sunxi_mixer.c,v 1.4 2019/02/05 00:21:35 jmcneill Exp $ */ /*- * Copyright (c) 2019 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sunxi_mixer.c,v 1.3 2019/02/04 12:10:13 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sunxi_mixer.c,v 1.4 2019/02/05 00:21:35 jmcneill Exp $"); #include #include @@ -54,6 +54,8 @@ __KERNEL_RCSID(0, "$NetBSD: sunxi_mixer. #define OVL_BASE(n) (0x02000 + (n) * 0x1000) #define OVL_V_BASE OVL_BASE(0) #define OVL_UI_BASE OVL_BASE(1) +#define VSU_BASE 0x2 +#define CSC_BASE(n) ((n) == 0 ? 0xaa050 : 0xa) /* GLB registers */ #define GLB_CTL 0x000 @@ -120,6 +122,38 @@ __KERNEL_RCSID(0, "$NetBSD: sunxi_mixer. #define OVL_UI_TOP_HADD_LAYER0 __BITS(7,0) #define OVL_UI_SIZE 0x088 +/* VSU registers */ +#define VS_CTRL_REG 0x000 +#define VS_CTRL_COEF_SWITCH_EN __BIT(4) +#define VS_CTRL_EN__BIT(0) +#define VS_STATUS_REG 0x008 +#define VS_FIELD_CTRL_REG 0x00c +#define VS_OUT_SIZE_REG 0x040 +#define VS_Y_SIZE_REG 0x080 +#define VS_Y_HSTEP_REG 0x088 +#define VS_Y_VSTEP_REG 0x08c +#define VS_Y_HPHASE_REG 0x090 +#define VS_Y_VPHASE0_REG 0x098 +#define VS_Y_VPHASE1_REG 0x09c +#define VS_C_SIZE_REG 0x0c0 +#define VS_C_HSTEP_REG 0x0c8 +#define VS_C_VSTEP_REG 0x0cc +#define VS_C_HPHASE_REG 0x0d0 +#define VS_C_VPHASE0_REG 0x0d8 +#define VS_C_VPHASE1_REG 0x0dc +#define VS_Y_HCOEF0_REG(n) (0x200 + (n) * 0x4) +#define VS_Y_HCOEF1_REG(n) (0x300 + (n) * 0x4) +#define VS_Y_VCOEF_REG(n) (0x400 + (n) * 0x4) +#define VS_C_HCOEF0_REG(n) (0x600 + (n) * 0x4) +#define VS_C_HCOEF1_REG(n) (0x700 + (n) * 0x4) +#define VS_C_VCOEF_REG(n) (0x800 + (n) * 0x4) + +/* CSC registers */ +#define CSC_BYPASS_REG 0x000 +#define CSC_BYPASS_DISABLE __BIT(0) +#define CSC_COEFF0_REG(n) (0x10 + 0x10 * (n)) +#define GLB_ALPHA_REG 0x040 + enum { MIXER_PORT_OUTPUT = 1, }; @@ -175,6 +209,16 @@ struct sunxi_mixer_softc { #define OVL_UI_WRITE(sc, reg, val) \ bus_space_write_4((sc)->sc_bst, (sc)->sc_bsh, OVL_UI_BASE + (reg), (val)) +#define VSU_READ(sc, reg)\ + bus_space_read_4((sc)->sc_bst, (sc)->sc_bsh, VSU_BASE + (reg)) +#define VSU_WRITE(sc, reg, val) \ + bus_space_write_4((sc)->sc_bst, (sc)->sc_bsh, VSU_BASE + (reg), (val)) + +#define CSC_READ(sc, n, reg)\ + bus_space_read_4((sc)->sc_bst, (sc)->sc_bsh, CSC_BASE(n) + (reg)) +#define CSC_WRITE(sc, n, reg, val) \ + bus_space_write_4((sc)->sc_bst, (sc)->sc_bsh, CSC_BASE(n) + (reg), (val)) + #define to_sunxi_mixer_crtc(x) container_of(x, struct sunxi_mixer_crtc, base) #define to_sunxi_mixer_overlay(x) container_of(x, struct sunxi_mixer_overlay, base) @@ -346,7 +390,7 @@ sunxi_mixer_overlay_destroy(struct drm_p } static bool -sunxi_mixer_overlay_ui(uint32_t drm_format) +sunxi_mixer_overlay_rgb(uint32_t drm_format) { switch (drm_format) { case DRM_FORMAT_XRGB: @@ -372,6 +416,448 @@ sunxi_mixer_overlay_format(uint32_t drm_ } } +static const uint32_t lan3coefftab32_left[512] = { + 0x4000, 0x40fe, 0x3ffd0100, 0x3efc0100, + 0x3efb0100, 0x3dfa0200, 0x3cf90200, 0x3bf80200, + 0x39f70200, 0x37f70200, 0x35f70200, 0x33f70200, + 0x31f70200, 0x2ef70200, 0x2cf70200, 0x2af70200, + 0x27f70200, 0x24f80100, 0x22f80100, 0x1ef90100, + 0x1cf90100, 0x19fa0100, 0x17fa0100, 0x14fb0100, + 0x11fc, 0x0ffc, 0x0cfd, 0x0afd, + 0x08fe, 0x05ff, 0x03ff, 0x0200, + + 0x4000, 0x40fe, 0x3ffd0100, 0x3efc0100, + 0x3efb0100, 0x3dfa0200, 0x3cf90200, 0x3bf80200, + 0x39f70200, 0x37f70200, 0x35f70200, 0x33f70200, + 0x31f70200, 0x2ef70200, 0x2cf70200, 0x2af70200, + 0x27f70200, 0x24f80100, 0x22f80100, 0x1ef90100, + 0x1cf90100, 0x19fa0100, 0x17fa0100, 0x14fb0100, + 0x11fc, 0x0ffc, 0x0cfd, 0x0afd, + 0x08fe, 0x05ff, 0x03ff, 0x0200, + + 0x3806fc02, 0x3805fc02, 0x3803fd01, 0x3801fe01, + 0x3700fe01, 0x3501, 0x35fdff01, 0x34fc0001, + 0x34fb, 0x33fa, 0x31fa0100, 0x2ff90100, + 0x2df80200, 0x2bf80200, 0x2af70200, 0x28f70200, + 0x27f70200, 0x24f70300, 0x22f70300, 0x1ff70300, + 0x1ef70300, 0x1cf70300, 0x1af70300, 0x18f70300, + 0x16f80300, 0x13f80300, 0x11f90300, 0x0ef90300, + 0x0efa0200, 0x0cfa0200,
CVS commit: src/common/lib/libc/misc
Module Name:src Committed By: mrg Date: Mon Feb 4 22:07:41 UTC 2019 Modified Files: src/common/lib/libc/misc: ubsan.c Log Message: - use __unreachable() and move 'break's around to increase consistency and correctness ok kamil@ To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/common/lib/libc/misc/ubsan.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/common/lib/libc/misc/ubsan.c diff -u src/common/lib/libc/misc/ubsan.c:1.3 src/common/lib/libc/misc/ubsan.c:1.4 --- src/common/lib/libc/misc/ubsan.c:1.3 Fri Aug 3 16:31:04 2018 +++ src/common/lib/libc/misc/ubsan.c Mon Feb 4 22:07:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: ubsan.c,v 1.3 2018/08/03 16:31:04 kamil Exp $ */ +/* $NetBSD: ubsan.c,v 1.4 2019/02/04 22:07:41 mrg Exp $ */ /*- * Copyright (c) 2018 The NetBSD Foundation, Inc. @@ -38,9 +38,9 @@ #include #if defined(_KERNEL) -__KERNEL_RCSID(0, "$NetBSD: ubsan.c,v 1.3 2018/08/03 16:31:04 kamil Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ubsan.c,v 1.4 2019/02/04 22:07:41 mrg Exp $"); #else -__RCSID("$NetBSD: ubsan.c,v 1.3 2018/08/03 16:31:04 kamil Exp $"); +__RCSID("$NetBSD: ubsan.c,v 1.4 2019/02/04 22:07:41 mrg Exp $"); #endif #if defined(_KERNEL) @@ -1236,6 +1236,7 @@ zDeserializeTypeWidth(struct CTypeDescri break; default: Report(true, "UBSan: Unknown variable type %#04" PRIx16 "\n", pType->mTypeKind); + __unreachable(); /* NOTREACHED */ } @@ -1418,15 +1419,17 @@ llliGetNumber(char *szLocation, struct C switch (zNumberWidth) { default: Report(true, "UBSan: Unexpected %zu-Bit Type in %s\n", zNumberWidth, szLocation); + __unreachable(); /* NOTREACHED */ case WIDTH_128: #ifdef __SIZEOF_INT128__ memcpy(, REINTERPRET_CAST(longest *, ulNumber), sizeof(longest)); + break; #else Report(true, "UBSan: Unexpected 128-Bit Type in %s\n", szLocation); + __unreachable(); /* NOTREACHED */ #endif - break; case WIDTH_64: if (sizeof(ulNumber) * CHAR_BIT < WIDTH_64) { L = *REINTERPRET_CAST(int64_t *, ulNumber); @@ -1460,6 +1463,7 @@ llluGetNumber(char *szLocation, struct C switch (zNumberWidth) { default: Report(true, "UBSan: Unexpected %zu-Bit Type in %s\n", zNumberWidth, szLocation); + __unreachable(); /* NOTREACHED */ case WIDTH_128: #ifdef __SIZEOF_INT128__ @@ -1467,6 +1471,7 @@ llluGetNumber(char *szLocation, struct C break; #else Report(true, "UBSan: Unexpected 128-Bit Type in %s\n", szLocation); + __unreachable(); /* NOTREACHED */ #endif case WIDTH_64: @@ -1503,6 +1508,7 @@ DeserializeNumberFloat(char *szLocation, switch (zNumberWidth) { default: Report(true, "UBSan: Unexpected %zu-Bit Type in %s\n", zNumberWidth, szLocation); + __unreachable(); /* NOTREACHED */ #ifdef __HAVE_LONG_DOUBLE case WIDTH_128: @@ -1516,6 +1522,7 @@ DeserializeNumberFloat(char *szLocation, DeserializeFloatOverPointer(pBuffer, zBUfferLength, pType, REINTERPRET_CAST(unsigned long *, ulNumber)); break; } + /* FALLTHROUGH */ case WIDTH_32: case WIDTH_16: DeserializeFloatInlined(pBuffer, zBUfferLength, pType, ulNumber); @@ -1546,15 +1553,16 @@ DeserializeNumber(char *szLocation, char case KIND_FLOAT: #ifdef _KERNEL Report(true, "UBSan: Unexpected Float Type in %s\n", szLocation); + __unreachable(); /* NOTREACHED */ #else DeserializeNumberFloat(szLocation, pBuffer, zBUfferLength, pType, ulNumber); -#endif break; +#endif case KIND_UNKNOWN: Report(true, "UBSan: Unknown Type in %s\n", szLocation); + __unreachable(); /* NOTREACHED */ - break; } }
CVS commit: src/doc
Module Name:src Committed By: mrg Date: Mon Feb 4 22:00:51 UTC 2019 Modified Files: src/doc: TODO.compat-module Log Message: update the rf / netbsd32 comment. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/doc/TODO.compat-module Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/TODO.compat-module diff -u src/doc/TODO.compat-module:1.4 src/doc/TODO.compat-module:1.5 --- src/doc/TODO.compat-module:1.4 Mon Feb 4 00:03:24 2019 +++ src/doc/TODO.compat-module Mon Feb 4 22:00:51 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: TODO.compat-module,v 1.4 2019/02/04 00:03:24 pgoyette Exp $ */ +/* $NetBSD: TODO.compat-module,v 1.5 2019/02/04 22:00:51 mrg Exp $ */ DONE @@ -116,7 +116,8 @@ TODO - Not required for branch merge 23. The raidframe-netbsd32 compat code needs to be better separated from the main raidframe module. The current mechanism requires us -to include compat/netbsd32/netbsd32.h in rf_netbsdkintf.c which -requires us to explicitly #define COMPAT_NETBSD32 to get various -structure definitions which conflicts with possible definitions of -COMPAT_NETBSD32 in opt_compat_netbsd32.h +to include compat/netbsd32/netbsd32.h in rf_netbsdkintf.c to get +various structure definitions. This should all be handled in the +compat module, but requires that the code in the ioctl switch be +moved into a function so the compat code can call it directly and +handle the ioctl commands entirely.
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 21:57:48 UTC 2019 Modified Files: src/sys/dev/raidframe: rf_netbsdkintf.c src/sys/modules: Makefile src/sys/modules/raid: Makefile src/sys/rump/dev/lib/libraidframe: Makefile Added Files: src/sys/compat/netbsd32: netbsd32.mk Log Message: don't assume _LP64 == supports COMPAT_NETBSD32. this is not true for alpha, ia64 and arm32 ports, and the first two were not building because of it, and the latter would be missing the oabi support (likely not a big deal, but still wrong.) add a makefile fragment that tells you if it is supported and include it where needed to define COMPAT_NETBSD32 when building the normal kernel (ie, modules & rump.) fixes alpha build, probably fixes ia64 build. XXX: still leaves some netbsd32 code in rf_netbsdkintf.c, that should be moved into some hooks, but first the configuration setup needs to be moved into a common function the netbsd32 code can call into, vs living in the switch case itself. To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/sys/compat/netbsd32/netbsd32.mk cvs rdiff -u -r1.362 -r1.363 src/sys/dev/raidframe/rf_netbsdkintf.c cvs rdiff -u -r1.217 -r1.218 src/sys/modules/Makefile cvs rdiff -u -r1.4 -r1.5 src/sys/modules/raid/Makefile cvs rdiff -u -r1.11 -r1.12 src/sys/rump/dev/lib/libraidframe/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/dev/raidframe/rf_netbsdkintf.c diff -u src/sys/dev/raidframe/rf_netbsdkintf.c:1.362 src/sys/dev/raidframe/rf_netbsdkintf.c:1.363 --- src/sys/dev/raidframe/rf_netbsdkintf.c:1.362 Sun Feb 3 11:03:53 2019 +++ src/sys/dev/raidframe/rf_netbsdkintf.c Mon Feb 4 21:57:47 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: rf_netbsdkintf.c,v 1.362 2019/02/03 11:03:53 martin Exp $ */ +/* $NetBSD: rf_netbsdkintf.c,v 1.363 2019/02/04 21:57:47 mrg Exp $ */ /*- * Copyright (c) 1996, 1997, 1998, 2008-2011 The NetBSD Foundation, Inc. @@ -101,10 +101,11 @@ ***/ #include -__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.362 2019/02/03 11:03:53 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.363 2019/02/04 21:57:47 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_raid_autoconfig.h" +#include "opt_compat_netbsd32.h" #endif #include @@ -150,10 +151,7 @@ __KERNEL_RCSID(0, "$NetBSD: rf_netbsdkin #include "rf_compat80.h" -#ifdef _LP64 -#ifndef COMPAT_NETBSD32 -#define COMPAT_NETBSD32 1 -#endif +#ifdef COMPAT_NETBSD32 #include "rf_compat32.h" #endif @@ -1112,7 +1110,7 @@ raidioctl(dev_t dev, u_long cmd, void *d case RAIDFRAME_PARITYMAP_GET_DISABLE: case RAIDFRAME_PARITYMAP_SET_DISABLE: case RAIDFRAME_PARITYMAP_SET_PARAMS: -#ifdef _LP64 +#ifdef COMPAT_NETBSD32 case RAIDFRAME_GET_INFO32: #endif if ((rs->sc_flags & RAIDF_INITED) == 0) @@ -1162,7 +1160,7 @@ raidioctl(dev_t dev, u_long cmd, void *d /* configure the system */ case RAIDFRAME_CONFIGURE: -#ifdef _LP64 +#ifdef COMPAT_NETBSD32 case RAIDFRAME_CONFIGURE32: #endif @@ -1179,7 +1177,7 @@ raidioctl(dev_t dev, u_long cmd, void *d if (k_cfg == NULL) { return (ENOMEM); } -#ifdef _LP64 +#ifdef COMPAT_NETBSD32 if (cmd == RAIDFRAME_CONFIGURE32 && (l->l_proc->p_flag & PK_32) != 0) MODULE_CALL_HOOK(raidframe_netbsd32_config_hook, @@ -1487,21 +1485,21 @@ raidioctl(dev_t dev, u_long cmd, void *d return(retcode); case RAIDFRAME_GET_INFO: -#ifdef _LP64 +#ifdef COMPAT_NETBSD32 case RAIDFRAME_GET_INFO32: -#endif /* LP64 */ +#endif RF_Malloc(d_cfg, sizeof(RF_DeviceConfig_t), (RF_DeviceConfig_t *)); if (d_cfg == NULL) return (ENOMEM); retcode = rf_get_info(raidPtr, d_cfg); if (retcode == 0) { -#ifdef _LP64 +#ifdef COMPAT_NETBSD32 if (raidframe_netbsd32_config_hook.hooked && cmd == RAIDFRAME_GET_INFO32) ucfgp = NETBSD32PTR64(*(netbsd32_pointer_t *)data); else -#endif /* _LP64 */ +#endif ucfgp = *(RF_DeviceConfig_t **)data; retcode = copyout(d_cfg, ucfgp, sizeof(RF_DeviceConfig_t)); } Index: src/sys/modules/Makefile diff -u src/sys/modules/Makefile:1.217 src/sys/modules/Makefile:1.218 --- src/sys/modules/Makefile:1.217 Sun Feb 3 08:02:25 2019 +++ src/sys/modules/Makefile Mon Feb 4 21:57:48 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.217 2019/02/03 08:02:25 pgoyette Exp $ +# $NetBSD: Makefile,v 1.218 2019/02/04 21:57:48 mrg Exp $ .include @@ -272,10 +272,9 @@ SUBDIR+= wmihp SUBDIR+= wmimsi .endif -.if ${MACHINE_ARCH} == "x86_64" \ -|| ${MACHINE_CPU} == "arm" \ -|| ${MACHINE_ARCH} == "sparc64" \ -|| (!empty(MACHINE_ARCH:Mmips64*) && !defined(BSD_MK_COMPAT_FILE)) +.include "${.CURDIR}/../compat/netbsd32/netbsd32.mk" +.if ${COMPAT_USE_NETBSD32} != "no" + SUBDIR+= compat_netbsd32 SUBDIR+= compat_netbsd32_09 compat_netbsd32_12 SUBDIR+= compat_netbsd32_13
CVS commit: src/sys/arch
Module Name:src Committed By: cherry Date: Mon Feb 4 18:14:54 UTC 2019 Modified Files: src/sys/arch/amd64/conf: std.xen src/sys/arch/xen/conf: std.xen src/sys/arch/xen/include: hypervisor.h xen.h src/sys/arch/xen/x86: x86_xpmap.c Log Message: Bump up XEN source API compatibility to 0x00030208 from 0x00030201, but maintain backwards source API compilation compatibility. ie; sources with config(5) options __XEN_INTERFACE_VERSION__=0x00030201 # Xen 3.1 interface should compile and run without problems. Not that API version 0x00030201 is the lowest version we support now. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/arch/amd64/conf/std.xen cvs rdiff -u -r1.9 -r1.10 src/sys/arch/xen/conf/std.xen cvs rdiff -u -r1.48 -r1.49 src/sys/arch/xen/include/hypervisor.h cvs rdiff -u -r1.42 -r1.43 src/sys/arch/xen/include/xen.h cvs rdiff -u -r1.81 -r1.82 src/sys/arch/xen/x86/x86_xpmap.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/amd64/conf/std.xen diff -u src/sys/arch/amd64/conf/std.xen:1.10 src/sys/arch/amd64/conf/std.xen:1.11 --- src/sys/arch/amd64/conf/std.xen:1.10 Sat Feb 2 12:32:54 2019 +++ src/sys/arch/amd64/conf/std.xen Mon Feb 4 18:14:53 2019 @@ -1,4 +1,4 @@ -# $NetBSD: std.xen,v 1.10 2019/02/02 12:32:54 cherry Exp $ +# $NetBSD: std.xen,v 1.11 2019/02/04 18:14:53 cherry Exp $ # NetBSD: std.i386,v 1.24 2003/02/26 21:33:36 fvdl Exp # # standard, required NetBSD/i386 'options' @@ -7,7 +7,7 @@ machine xen amd64 include "conf/std" # MI standard options options XEN #Xen support -options __XEN_INTERFACE_VERSION__=0x00030201 # Xen 3.1 interface +options __XEN_INTERFACE_VERSION__=0x00030208 # Xen 3.1 interface #options __XEN_INTERFACE_VERSION__=0x00030205 # Xen 3.1 interface options CPU_IN_CKSUM Index: src/sys/arch/xen/conf/std.xen diff -u src/sys/arch/xen/conf/std.xen:1.9 src/sys/arch/xen/conf/std.xen:1.10 --- src/sys/arch/xen/conf/std.xen:1.9 Sat Feb 2 12:32:54 2019 +++ src/sys/arch/xen/conf/std.xen Mon Feb 4 18:14:53 2019 @@ -1,4 +1,4 @@ -# $NetBSD: std.xen,v 1.9 2019/02/02 12:32:54 cherry Exp $ +# $NetBSD: std.xen,v 1.10 2019/02/04 18:14:53 cherry Exp $ # NetBSD: std.i386,v 1.24 2003/02/26 21:33:36 fvdl Exp # # standard, required NetBSD/i386 'options' @@ -6,7 +6,7 @@ machine xen i386 include "conf/std" # MI standard options -options __XEN_INTERFACE_VERSION__=0x00030201 # Xen 3.1 interface +options __XEN_INTERFACE_VERSION__=0x00030208 # Xen 3.1 interface options EXEC_AOUT # exec a.out binaries options EXEC_ELF32 # exec ELF binaries Index: src/sys/arch/xen/include/hypervisor.h diff -u src/sys/arch/xen/include/hypervisor.h:1.48 src/sys/arch/xen/include/hypervisor.h:1.49 --- src/sys/arch/xen/include/hypervisor.h:1.48 Sat Feb 2 14:50:15 2019 +++ src/sys/arch/xen/include/hypervisor.h Mon Feb 4 18:14:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: hypervisor.h,v 1.48 2019/02/02 14:50:15 cherry Exp $ */ +/* $NetBSD: hypervisor.h,v 1.49 2019/02/04 18:14:53 cherry Exp $ */ /* * Copyright (c) 2006 Manuel Bouyer. @@ -94,6 +94,7 @@ struct xen_npx_attach_args { #include #include +#if __XEN_INTERFACE_VERSION < 0x00030208 /* Undo namespace damage from xen/include/public/io/ring.h * The proper fix is to get upstream to stop assuming that all OSs use * mb(), rmb(), wmb(). @@ -105,6 +106,7 @@ struct xen_npx_attach_args { #define xen_mb() membar_sync() #define xen_rmb() membar_producer() #define xen_wmb() membar_consumer() +#endif /* __XEN_INTERFACE_VERSION */ #include Index: src/sys/arch/xen/include/xen.h diff -u src/sys/arch/xen/include/xen.h:1.42 src/sys/arch/xen/include/xen.h:1.43 --- src/sys/arch/xen/include/xen.h:1.42 Sat Feb 2 12:32:55 2019 +++ src/sys/arch/xen/include/xen.h Mon Feb 4 18:14:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: xen.h,v 1.42 2019/02/02 12:32:55 cherry Exp $ */ +/* $NetBSD: xen.h,v 1.43 2019/02/04 18:14:53 cherry Exp $ */ /* * @@ -122,6 +122,12 @@ void printk(const char *, ...); /* Everything below this point is not included by assembler (.S) files. */ #ifndef _LOCORE +/* Version Specific Glue */ +#if __XEN_INTERFACE_VERSION__ >= 0x00030203 +#define console_mfnconsole.domU.mfn +#define console_evtchn console.domU.evtchn +#endif + /* some function prototypes */ void trap_init(void); void xpq_flush_cache(void); Index: src/sys/arch/xen/x86/x86_xpmap.c diff -u src/sys/arch/xen/x86/x86_xpmap.c:1.81 src/sys/arch/xen/x86/x86_xpmap.c:1.82 --- src/sys/arch/xen/x86/x86_xpmap.c:1.81 Sun Jul 29 08:02:24 2018 +++ src/sys/arch/xen/x86/x86_xpmap.c Mon Feb 4 18:14:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: x86_xpmap.c,v 1.81 2018/07/29 08:02:24 maxv Exp $ */ +/* $NetBSD: x86_xpmap.c,v 1.82 2019/02/04 18:14:53 cherry Exp $ */ /* * Copyright (c) 2017 The NetBSD Foundation, Inc. @@ -95,7 +95,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: x86_xpmap.c,v 1.81
CVS commit: src/sys/kern
Module Name:src Committed By: maxv Date: Mon Feb 4 15:13:54 UTC 2019 Modified Files: src/sys/kern: subr_kmem.c Log Message: Clobber the size when freeing a buffer. This way, if the same buffer gets freed twice, the second size check will fire. To generate a diff of this commit: cvs rdiff -u -r1.72 -r1.73 src/sys/kern/subr_kmem.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_kmem.c diff -u src/sys/kern/subr_kmem.c:1.72 src/sys/kern/subr_kmem.c:1.73 --- src/sys/kern/subr_kmem.c:1.72 Sun Dec 23 12:15:01 2018 +++ src/sys/kern/subr_kmem.c Mon Feb 4 15:13:54 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: subr_kmem.c,v 1.72 2018/12/23 12:15:01 maxv Exp $ */ +/* $NetBSD: subr_kmem.c,v 1.73 2019/02/04 15:13:54 maxv Exp $ */ /*- * Copyright (c) 2009-2015 The NetBSD Foundation, Inc. @@ -92,7 +92,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: subr_kmem.c,v 1.72 2018/12/23 12:15:01 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_kmem.c,v 1.73 2019/02/04 15:13:54 maxv Exp $"); #ifdef _KERNEL_OPT #include "opt_kmem.h" @@ -549,6 +549,8 @@ kmem_size_check(void *p, size_t sz) panic("kmem_free(%p, %zu) != allocated size %zu", (const uint8_t *)p + SIZE_SIZE, sz, hsz); } + + hd->size = -1; } #endif /* defined(KMEM_SIZE) */
CVS commit: src/sys/arch/amd64/include
Module Name:src Committed By: maxv Date: Mon Feb 4 15:07:35 UTC 2019 Modified Files: src/sys/arch/amd64/include: asan.h Log Message: Add more symbols to the unwinder, in case we get a KASAN message inside an exception handler. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/amd64/include/asan.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/amd64/include/asan.h diff -u src/sys/arch/amd64/include/asan.h:1.1 src/sys/arch/amd64/include/asan.h:1.2 --- src/sys/arch/amd64/include/asan.h:1.1 Wed Oct 31 06:26:26 2018 +++ src/sys/arch/amd64/include/asan.h Mon Feb 4 15:07:34 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: asan.h,v 1.1 2018/10/31 06:26:26 maxv Exp $ */ +/* $NetBSD: asan.h,v 1.2 2019/02/04 15:07:34 maxv Exp $ */ /* * Copyright (c) 2018 The NetBSD Foundation, Inc. @@ -165,7 +165,9 @@ static inline bool __md_unwind_end(const char *name) { if (!strcmp(name, "syscall") || + !strcmp(name, "alltraps") || !strcmp(name, "handle_syscall") || + !strncmp(name, "Xtrap", 5) || !strncmp(name, "Xintr", 5) || !strncmp(name, "Xhandle", 7) || !strncmp(name, "Xresume", 7) ||
CVS commit: src/sys/fs/puffs
Module Name:src Committed By: wiz Date: Mon Feb 4 14:47:41 UTC 2019 Modified Files: src/sys/fs/puffs: files.puffs Log Message: try '&' instead of '&&' To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/sys/fs/puffs/files.puffs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/fs/puffs/files.puffs diff -u src/sys/fs/puffs/files.puffs:1.8 src/sys/fs/puffs/files.puffs:1.9 --- src/sys/fs/puffs/files.puffs:1.8 Mon Feb 4 12:08:03 2019 +++ src/sys/fs/puffs/files.puffs Mon Feb 4 14:47:41 2019 @@ -1,9 +1,9 @@ -# $NetBSD: files.puffs,v 1.8 2019/02/04 12:08:03 pgoyette Exp $ +# $NetBSD: files.puffs,v 1.9 2019/02/04 14:47:41 wiz Exp $ deffs PUFFS define puffs: vfs -file fs/puffs/puffs_compat.c puffs && compat_50 +file fs/puffs/puffs_compat.c puffs & compat_50 file fs/puffs/puffs_msgif.c puffs file fs/puffs/puffs_node.c puffs file fs/puffs/puffs_subr.c puffs
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: skrll Date: Mon Feb 4 13:12:03 UTC 2019 Modified Files: src/sys/arch/arm/arm32: arm32_machdep.c Log Message: Report hatched value after the atomic_or so the VERBOSE_INIT_ARM output doesn't get mangled. We start a cpu and wait for it before progressing now. To generate a diff of this commit: cvs rdiff -u -r1.126 -r1.127 src/sys/arch/arm/arm32/arm32_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/arm/arm32/arm32_machdep.c diff -u src/sys/arch/arm/arm32/arm32_machdep.c:1.126 src/sys/arch/arm/arm32/arm32_machdep.c:1.127 --- src/sys/arch/arm/arm32/arm32_machdep.c:1.126 Mon Jan 21 07:46:20 2019 +++ src/sys/arch/arm/arm32/arm32_machdep.c Mon Feb 4 13:12:03 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: arm32_machdep.c,v 1.126 2019/01/21 07:46:20 skrll Exp $ */ +/* $NetBSD: arm32_machdep.c,v 1.127 2019/02/04 13:12:03 skrll Exp $ */ /* * Copyright (c) 1994-1998 Mark Brinicombe. @@ -42,7 +42,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: arm32_machdep.c,v 1.126 2019/01/21 07:46:20 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: arm32_machdep.c,v 1.127 2019/02/04 13:12:03 skrll Exp $"); #include "opt_arm_debug.h" #include "opt_arm_start.h" @@ -769,13 +769,13 @@ cpu_init_secondary_processor(int cpuinde VPRINTS(")"); #endif - atomic_or_uint(_cpu_hatched, __BIT(cpuindex)); - VPRINTS(" hatched="); - VPRINTX(arm_cpu_hatched); + VPRINTX(arm_cpu_hatched | __BIT(cpuindex)); VPRINTS("\n\r"); - /* return to assembly to Wait for cpu_boot_secondary_processors */ + atomic_or_uint(_cpu_hatched, __BIT(cpuindex)); + + /* return to assembly to wait for cpu_boot_secondary_processors */ } void
CVS commit: src/sys/arch/arm/arm32
Module Name:src Committed By: skrll Date: Mon Feb 4 13:08:43 UTC 2019 Modified Files: src/sys/arch/arm/arm32: arm32_kvminit.c Log Message: Fix typo in VPRINTF To generate a diff of this commit: cvs rdiff -u -r1.48 -r1.49 src/sys/arch/arm/arm32/arm32_kvminit.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/arm32/arm32_kvminit.c diff -u src/sys/arch/arm/arm32/arm32_kvminit.c:1.48 src/sys/arch/arm/arm32/arm32_kvminit.c:1.49 --- src/sys/arch/arm/arm32/arm32_kvminit.c:1.48 Tue Nov 13 20:48:14 2018 +++ src/sys/arch/arm/arm32/arm32_kvminit.c Mon Feb 4 13:08:43 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: arm32_kvminit.c,v 1.48 2018/11/13 20:48:14 skrll Exp $ */ +/* $NetBSD: arm32_kvminit.c,v 1.49 2019/02/04 13:08:43 skrll Exp $ */ /* * Copyright (c) 2002, 2003, 2005 Genetec Corporation. All rights reserved. @@ -127,7 +127,7 @@ #include "opt_multiprocessor.h" #include -__KERNEL_RCSID(0, "$NetBSD: arm32_kvminit.c,v 1.48 2018/11/13 20:48:14 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: arm32_kvminit.c,v 1.49 2019/02/04 13:08:43 skrll Exp $"); #include #include @@ -672,8 +672,8 @@ arm32_kernel_vm_init(vaddr_t kernel_vm_b kernel_l2pt[idx].pv_pa, kernel_base + idx * L2_S_SEGSIZE); } - VPRINTF("%s: kernel_vm_base %lx KERNEL_L2PT_KERNEL_NUM %zu\n", __func__, - kernel_vm_base, KERNEL_L2PT_KERNEL_NUM); + VPRINTF("%s: kernel_vm_base %lx KERNEL_L2PT_VMDATA_NUM %d\n", __func__, + kernel_vm_base, KERNEL_L2PT_VMDATA_NUM); for (size_t idx = 0; idx < KERNEL_L2PT_VMDATA_NUM; idx++) { pmap_link_l2pt(l1pt_va, kernel_vm_base + idx * L2_S_SEGSIZE,
CVS commit: src/sys/arch/arm/include/arm32
Module Name:src Committed By: skrll Date: Mon Feb 4 13:06:39 UTC 2019 Modified Files: src/sys/arch/arm/include/arm32: param.h Log Message: Trailing whitespace To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 src/sys/arch/arm/include/arm32/param.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/include/arm32/param.h diff -u src/sys/arch/arm/include/arm32/param.h:1.25 src/sys/arch/arm/include/arm32/param.h:1.26 --- src/sys/arch/arm/include/arm32/param.h:1.25 Fri Jun 9 01:16:54 2017 +++ src/sys/arch/arm/include/arm32/param.h Mon Feb 4 13:06:39 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: param.h,v 1.25 2017/06/09 01:16:54 chs Exp $ */ +/* $NetBSD: param.h,v 1.26 2019/02/04 13:06:39 skrll Exp $ */ /* * Copyright (c) 1994,1995 Mark Brinicombe. @@ -98,7 +98,7 @@ #define arm_btop(x) ((unsigned)(x) >> PGSHIFT) #define arm_ptob(x) ((unsigned)(x) << PGSHIFT) #define arm_trunc_page(x) ((unsigned)(x) & ~PGOFSET) - + #ifdef _KERNEL #ifndef _LOCORE #ifndef __HIDE_DELAY
CVS commit: src/bin/sh
Module Name:src Committed By: wiz Date: Mon Feb 4 12:18:36 UTC 2019 Modified Files: src/bin/sh: sh.1 Log Message: Remove leading zero from date. To generate a diff of this commit: cvs rdiff -u -r1.218 -r1.219 src/bin/sh/sh.1 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/bin/sh/sh.1 diff -u src/bin/sh/sh.1:1.218 src/bin/sh/sh.1:1.219 --- src/bin/sh/sh.1:1.218 Mon Feb 4 11:16:41 2019 +++ src/bin/sh/sh.1 Mon Feb 4 12:18:36 2019 @@ -1,4 +1,4 @@ -.\" $NetBSD: sh.1,v 1.218 2019/02/04 11:16:41 kre Exp $ +.\" $NetBSD: sh.1,v 1.219 2019/02/04 12:18:36 wiz Exp $ .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" @@ -31,7 +31,7 @@ .\" .\" @(#)sh.1 8.6 (Berkeley) 5/4/95 .\" -.Dd February 04, 2019 +.Dd February 4, 2019 .Dt SH 1 .\" everything except c o and s (keep them ordered) .ds flags abCEeFfhIiLmnpquVvXx
CVS commit: src/sys/dev/nvmm/x86
Module Name:src Committed By: maxv Date: Mon Feb 4 12:11:18 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c Log Message: Improvements: - Guest reads/writes to PAT land in gPAT, so no need to emulate them. - When emulating EFER, don't advance the RIP if a fault occurs, and don't forget to flush the VMCB cache accordingly. To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/dev/nvmm/x86/nvmm_x86_svm.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/nvmm/x86/nvmm_x86_svm.c diff -u src/sys/dev/nvmm/x86/nvmm_x86_svm.c:1.18 src/sys/dev/nvmm/x86/nvmm_x86_svm.c:1.19 --- src/sys/dev/nvmm/x86/nvmm_x86_svm.c:1.18 Sat Jan 26 15:12:20 2019 +++ src/sys/dev/nvmm/x86/nvmm_x86_svm.c Mon Feb 4 12:11:18 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: nvmm_x86_svm.c,v 1.18 2019/01/26 15:12:20 maxv Exp $ */ +/* $NetBSD: nvmm_x86_svm.c,v 1.19 2019/02/04 12:11:18 maxv Exp $ */ /* * Copyright (c) 2018 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: nvmm_x86_svm.c,v 1.18 2019/01/26 15:12:20 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: nvmm_x86_svm.c,v 1.19 2019/02/04 12:11:18 maxv Exp $"); #include #include @@ -938,20 +938,15 @@ svm_inkernel_handle_msr(struct nvmm_mach struct nvmm_exit *exit) { struct svm_cpudata *cpudata = vcpu->cpudata; + struct vmcb *vmcb = cpudata->vmcb; uint64_t val; size_t i; switch (exit->u.msr.type) { case NVMM_EXIT_MSR_RDMSR: - if (exit->u.msr.msr == MSR_CR_PAT) { - val = cpudata->vmcb->state.g_pat; - cpudata->vmcb->state.rax = (val & 0x); - cpudata->gprs[NVMM_X64_GPR_RDX] = (val >> 32); - goto handled; - } if (exit->u.msr.msr == MSR_NB_CFG) { val = NB_CFG_INITAPICCPUIDLO; - cpudata->vmcb->state.rax = (val & 0x); + vmcb->state.rax = (val & 0x); cpudata->gprs[NVMM_X64_GPR_RDX] = (val >> 32); goto handled; } @@ -959,7 +954,7 @@ svm_inkernel_handle_msr(struct nvmm_mach if (msr_ignore_list[i] != exit->u.msr.msr) continue; val = 0; - cpudata->vmcb->state.rax = (val & 0x); + vmcb->state.rax = (val & 0x); cpudata->gprs[NVMM_X64_GPR_RDX] = (val >> 32); goto handled; } @@ -967,18 +962,14 @@ svm_inkernel_handle_msr(struct nvmm_mach case NVMM_EXIT_MSR_WRMSR: if (exit->u.msr.msr == MSR_EFER) { if (__predict_false(exit->u.msr.val & ~EFER_VALID)) { -svm_inject_gp(mach, vcpu); -goto handled; +goto error; } - if ((cpudata->vmcb->state.efer ^ exit->u.msr.val) & + if ((vmcb->state.efer ^ exit->u.msr.val) & EFER_TLB_FLUSH) { cpudata->tlb_want_flush = true; } - cpudata->vmcb->state.efer = exit->u.msr.val | EFER_SVME; - goto handled; - } - if (exit->u.msr.msr == MSR_CR_PAT) { - cpudata->vmcb->state.g_pat = exit->u.msr.val; + vmcb->state.efer = exit->u.msr.val | EFER_SVME; + vmcb->ctrl.vmcb_clean &= ~VMCB_CTRL_VMCB_CLEAN_CR; goto handled; } for (i = 0; i < __arraycount(msr_ignore_list); i++) { @@ -994,6 +985,10 @@ svm_inkernel_handle_msr(struct nvmm_mach handled: svm_inkernel_advance(cpudata->vmcb); return true; + +error: + svm_inject_gp(mach, vcpu); + return true; } static void @@ -1557,6 +1552,7 @@ svm_vcpu_init(struct nvmm_machine *mach, * - SYSENTER_EIP [read, write] * - FSBASE [read, write] * - GSBASE [read, write] + * - PAT [read, write] * - TSC [read] * * Intercept the rest. @@ -1573,6 +1569,7 @@ svm_vcpu_init(struct nvmm_machine *mach, svm_vcpu_msr_allow(cpudata->msrbm, MSR_SYSENTER_EIP, true, true); svm_vcpu_msr_allow(cpudata->msrbm, MSR_FSBASE, true, true); svm_vcpu_msr_allow(cpudata->msrbm, MSR_GSBASE, true, true); + svm_vcpu_msr_allow(cpudata->msrbm, MSR_CR_PAT, true, true); svm_vcpu_msr_allow(cpudata->msrbm, MSR_TSC, true, false); vmcb->ctrl.msrpm_base_pa = cpudata->msrbm_pa;
CVS commit: src/sys/arch/arm/sunxi
Module Name:src Committed By: jmcneill Date: Mon Feb 4 12:10:13 UTC 2019 Modified Files: src/sys/arch/arm/sunxi: sunxi_drm.c sunxi_drm.h sunxi_lcdc.c sunxi_mixer.c Log Message: Add support for vblank irq and RGB overlay planes. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/sunxi/sunxi_drm.c cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/sunxi/sunxi_drm.h cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/sunxi/sunxi_lcdc.c cvs rdiff -u -r1.2 -r1.3 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_drm.c diff -u src/sys/arch/arm/sunxi/sunxi_drm.c:1.5 src/sys/arch/arm/sunxi/sunxi_drm.c:1.6 --- src/sys/arch/arm/sunxi/sunxi_drm.c:1.5 Sun Feb 3 15:43:57 2019 +++ src/sys/arch/arm/sunxi/sunxi_drm.c Mon Feb 4 12:10:13 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: sunxi_drm.c,v 1.5 2019/02/03 15:43:57 jmcneill Exp $ */ +/* $NetBSD: sunxi_drm.c,v 1.6 2019/02/04 12:10:13 jmcneill Exp $ */ /*- * Copyright (c) 2019 Jared D. McNeill @@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sunxi_drm.c,v 1.5 2019/02/03 15:43:57 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sunxi_drm.c,v 1.6 2019/02/04 12:10:13 jmcneill Exp $"); #include #include @@ -71,6 +71,10 @@ static void sunxi_drm_init(device_t); static int sunxi_drm_set_busid(struct drm_device *, struct drm_master *); +static uint32_t sunxi_drm_get_vblank_counter(struct drm_device *, unsigned int); +static int sunxi_drm_enable_vblank(struct drm_device *, unsigned int); +static void sunxi_drm_disable_vblank(struct drm_device *, unsigned int); + static int sunxi_drm_load(struct drm_device *, unsigned long); static int sunxi_drm_unload(struct drm_device *); @@ -88,11 +92,9 @@ static struct drm_driver sunxi_drm_drive .dumb_map_offset = drm_gem_cma_dumb_map_offset, .dumb_destroy = drm_gem_dumb_destroy, -#if notyet .get_vblank_counter = sunxi_drm_get_vblank_counter, .enable_vblank = sunxi_drm_enable_vblank, .disable_vblank = sunxi_drm_disable_vblank, -#endif .name = DRIVER_NAME, .desc = DRIVER_DESC, @@ -233,12 +235,23 @@ sunxi_drm_fb_create(struct drm_device *d fb = kmem_zalloc(sizeof(*fb), KM_SLEEP); fb->obj = to_drm_gem_cma_obj(gem_obj); fb->base.pitches[0] = cmd->pitches[0]; + fb->base.pitches[1] = cmd->pitches[1]; + fb->base.pitches[2] = cmd->pitches[2]; fb->base.offsets[0] = cmd->offsets[0]; + fb->base.offsets[1] = cmd->offsets[2]; + fb->base.offsets[2] = cmd->offsets[1]; fb->base.width = cmd->width; fb->base.height = cmd->height; fb->base.pixel_format = cmd->pixel_format; - drm_fb_get_bpp_depth(cmd->pixel_format, >base.depth, - >base.bits_per_pixel); + fb->base.bits_per_pixel = drm_format_plane_cpp(fb->base.pixel_format, 0) * 8; + + switch (fb->base.pixel_format) { + case DRM_FORMAT_XRGB: + fb->base.depth = 32; + break; + default: + break; + } error = drm_framebuffer_init(ddev, >base, _drm_framebuffer_funcs); if (error != 0) @@ -372,6 +385,10 @@ sunxi_drm_load(struct drm_device *ddev, drm_fb_helper_initial_config(>helper, 32); + /* XXX */ + ddev->irq_enabled = true; + drm_vblank_init(ddev, num_crtc); + return 0; drmerr: @@ -381,6 +398,50 @@ drmerr: return error; } +static uint32_t +sunxi_drm_get_vblank_counter(struct drm_device *ddev, unsigned int crtc) +{ + struct sunxi_drm_softc * const sc = sunxi_drm_private(ddev); + + if (crtc >= __arraycount(sc->sc_vbl)) + return 0; + + if (sc->sc_vbl[crtc].get_vblank_counter == NULL) + return 0; + + return sc->sc_vbl[crtc].get_vblank_counter(sc->sc_vbl[crtc].priv); +} + +static int +sunxi_drm_enable_vblank(struct drm_device *ddev, unsigned int crtc) +{ + struct sunxi_drm_softc * const sc = sunxi_drm_private(ddev); + + if (crtc >= __arraycount(sc->sc_vbl)) + return 0; + + if (sc->sc_vbl[crtc].enable_vblank == NULL) + return 0; + + sc->sc_vbl[crtc].enable_vblank(sc->sc_vbl[crtc].priv); + + return 0; +} + +static void +sunxi_drm_disable_vblank(struct drm_device *ddev, unsigned int crtc) +{ + struct sunxi_drm_softc * const sc = sunxi_drm_private(ddev); + + if (crtc >= __arraycount(sc->sc_vbl)) + return; + + if (sc->sc_vbl[crtc].disable_vblank == NULL) + return; + + sc->sc_vbl[crtc].disable_vblank(sc->sc_vbl[crtc].priv); +} + static int sunxi_drm_unload(struct drm_device *ddev) { Index: src/sys/arch/arm/sunxi/sunxi_drm.h diff -u src/sys/arch/arm/sunxi/sunxi_drm.h:1.1 src/sys/arch/arm/sunxi/sunxi_drm.h:1.2 --- src/sys/arch/arm/sunxi/sunxi_drm.h:1.1 Wed Jan 30 01:24:00 2019 +++ src/sys/arch/arm/sunxi/sunxi_drm.h Mon Feb 4 12:10:13 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: sunxi_drm.h,v 1.1 2019/01/30 01:24:00 jmcneill Exp $ */ +/* $NetBSD: sunxi_drm.h,v 1.2 2019/02/04 12:10:13 jmcneill Exp $ */ /*- * Copyright (c) 2019 Jared D. McNeill @@ -44,6 +44,15 @@ struct sunxi_framebuffer; +#define SUNXI_DRM_MAX_CRTC 2 + +struct
CVS commit: src/sys
Module Name:src Committed By: pgoyette Date: Mon Feb 4 12:08:03 UTC 2019 Modified Files: src/sys/fs/puffs: files.puffs src/sys/modules/puffs: Makefile Log Message: Don't include puffs_compat in a kernel unless the filesystem is selected along with COMPAT_50. Also, don't include puffs_compat in the main puffs filesystem module; it is part of the compat_50 module. Should address PR kern/53943 To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/fs/puffs/files.puffs cvs rdiff -u -r1.2 -r1.3 src/sys/modules/puffs/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/fs/puffs/files.puffs diff -u src/sys/fs/puffs/files.puffs:1.7 src/sys/fs/puffs/files.puffs:1.8 --- src/sys/fs/puffs/files.puffs:1.7 Sun Jan 27 02:08:43 2019 +++ src/sys/fs/puffs/files.puffs Mon Feb 4 12:08:03 2019 @@ -1,9 +1,9 @@ -# $NetBSD: files.puffs,v 1.7 2019/01/27 02:08:43 pgoyette Exp $ +# $NetBSD: files.puffs,v 1.8 2019/02/04 12:08:03 pgoyette Exp $ deffs PUFFS define puffs: vfs -file fs/puffs/puffs_compat.c compat_50 +file fs/puffs/puffs_compat.c puffs && compat_50 file fs/puffs/puffs_msgif.c puffs file fs/puffs/puffs_node.c puffs file fs/puffs/puffs_subr.c puffs Index: src/sys/modules/puffs/Makefile diff -u src/sys/modules/puffs/Makefile:1.2 src/sys/modules/puffs/Makefile:1.3 --- src/sys/modules/puffs/Makefile:1.2 Tue Jul 6 16:13:57 2010 +++ src/sys/modules/puffs/Makefile Mon Feb 4 12:08:03 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.2 2010/07/06 16:13:57 pooka Exp $ +# $NetBSD: Makefile,v 1.3 2019/02/04 12:08:03 pgoyette Exp $ .include "../Makefile.inc" @@ -6,6 +6,5 @@ KMOD= puffs SRCS= puffs_node.c puffs_msgif.c puffs_subr.c puffs_vfsops.c puffs_vnops.c -SRCS+= puffs_compat.c .include
CVS commit: src/bin/sh
Module Name:src Committed By: kre Date: Mon Feb 4 11:16:41 UTC 2019 Modified Files: src/bin/sh: error.c error.h eval.c eval.h main.c parser.c sh.1 Log Message: PR bin/53919 Suppress shell error messages while expanding $ENV (which also causes errors while expanding $PS1 $PS2 and $PS4 to be suppressed as well). This allows any random garbage that happens to be in ENV to not cause noise when the shell starts (which is effectively all it did). On a parse error (for any of those vars) we also use "" as the result, which will be a null prompt, and avoid attempting to open any file for ENV. This does not in any way change what happens for a correctly parsed command substitution (either when it is executed when permitted for one of the prompts, or when it is not (which is always for ENV)) and commands run from those can still produce error output (but shell errors remain suppressed). To generate a diff of this commit: cvs rdiff -u -r1.42 -r1.43 src/bin/sh/error.c cvs rdiff -u -r1.21 -r1.22 src/bin/sh/error.h cvs rdiff -u -r1.170 -r1.171 src/bin/sh/eval.c cvs rdiff -u -r1.22 -r1.23 src/bin/sh/eval.h cvs rdiff -u -r1.80 -r1.81 src/bin/sh/main.c cvs rdiff -u -r1.164 -r1.165 src/bin/sh/parser.c cvs rdiff -u -r1.217 -r1.218 src/bin/sh/sh.1 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/bin/sh/error.c diff -u src/bin/sh/error.c:1.42 src/bin/sh/error.c:1.43 --- src/bin/sh/error.c:1.42 Mon Jan 21 14:29:12 2019 +++ src/bin/sh/error.c Mon Feb 4 11:16:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: error.c,v 1.42 2019/01/21 14:29:12 kre Exp $ */ +/* $NetBSD: error.c,v 1.43 2019/02/04 11:16:41 kre Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -37,7 +37,7 @@ #if 0 static char sccsid[] = "@(#)error.c 8.2 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: error.c,v 1.42 2019/01/21 14:29:12 kre Exp $"); +__RCSID("$NetBSD: error.c,v 1.43 2019/02/04 11:16:41 kre Exp $"); #endif #endif /* not lint */ @@ -69,6 +69,9 @@ struct jmploc *handler; int exception; volatile int suppressint; volatile int intpending; +volatile int errors_suppressed; +const char * volatile currentcontext; + static void exverror(int, const char *, va_list) __dead; @@ -133,10 +136,16 @@ exvwarning(int sv_errno, const char *msg if (output.buf != NULL && output.nextc != output.buf && output.nextc[-1] == '\n') flushout(); + + if (errors_suppressed) + return; + if (commandname) outfmt(, "%s: ", commandname); else outfmt(, "%s: ", getprogname()); + if (currentcontext != NULL) + outfmt(, "%s: ", currentcontext); if (msg != NULL) { doformat(, msg, ap); if (sv_errno >= 0) Index: src/bin/sh/error.h diff -u src/bin/sh/error.h:1.21 src/bin/sh/error.h:1.22 --- src/bin/sh/error.h:1.21 Sun Aug 19 23:50:27 2018 +++ src/bin/sh/error.h Mon Feb 4 11:16:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: error.h,v 1.21 2018/08/19 23:50:27 kre Exp $ */ +/* $NetBSD: error.h,v 1.22 2019/02/04 11:16:41 kre Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -61,6 +61,9 @@ struct jmploc { jmp_buf loc; }; +extern volatile int errors_suppressed; +extern const char * volatile currentcontext; + extern struct jmploc *handler; extern int exception; extern int exerrno; /* error for EXEXEC */ Index: src/bin/sh/eval.c diff -u src/bin/sh/eval.c:1.170 src/bin/sh/eval.c:1.171 --- src/bin/sh/eval.c:1.170 Mon Jan 21 14:18:59 2019 +++ src/bin/sh/eval.c Mon Feb 4 11:16:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: eval.c,v 1.170 2019/01/21 14:18:59 kre Exp $ */ +/* $NetBSD: eval.c,v 1.171 2019/02/04 11:16:41 kre Exp $ */ /*- * Copyright (c) 1993 @@ -37,7 +37,7 @@ #if 0 static char sccsid[] = "@(#)eval.c 8.9 (Berkeley) 6/8/95"; #else -__RCSID("$NetBSD: eval.c,v 1.170 2019/01/21 14:18:59 kre Exp $"); +__RCSID("$NetBSD: eval.c,v 1.171 2019/02/04 11:16:41 kre Exp $"); #endif #endif /* not lint */ @@ -1502,6 +1502,23 @@ dotcmd(int argc, char **argv) } /* + * allow dotfile function nesting to be manipulated + * (for read_profile). This allows profile files to + * be treated as if they were used as '.' commands, + * (approximately) and in particular, for "return" to work. + */ +int +set_dot_funcnest(int new) +{ + int rv = dot_funcnest; + + if (new >= 0) + dot_funcnest = new; + + return rv; +} + +/* * Take commands from a file. To be compatible we should do a path * search for the file, which is necessary to find sub-commands. */ Index: src/bin/sh/eval.h diff -u src/bin/sh/eval.h:1.22 src/bin/sh/eval.h:1.23 --- src/bin/sh/eval.h:1.22 Mon Dec 3 06:43:19 2018 +++ src/bin/sh/eval.h Mon Feb 4 11:16:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: eval.h,v 1.22 2018/12/03 06:43:19 kre Exp $ */ +/* $NetBSD: eval.h,v 1.23 2019/02/04 11:16:41 kre Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -75,6 +75,7 @@ enum skipstate current_skipstate(void); void save_skipstate(struct skipsave *); void restore_skipstate(const struct skipsave *); void
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 10:48:46 UTC 2019 Modified Files: src/sys/netinet: ip_output.c src/sys/netinet6: ip6_output.c Log Message: rework the #ifdef IPSEC code to not use fallthru. same number of lines with more local context. To generate a diff of this commit: cvs rdiff -u -r1.309 -r1.310 src/sys/netinet/ip_output.c cvs rdiff -u -r1.216 -r1.217 src/sys/netinet6/ip6_output.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/netinet/ip_output.c diff -u src/sys/netinet/ip_output.c:1.309 src/sys/netinet/ip_output.c:1.310 --- src/sys/netinet/ip_output.c:1.309 Sat Dec 22 13:11:38 2018 +++ src/sys/netinet/ip_output.c Mon Feb 4 10:48:46 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: ip_output.c,v 1.309 2018/12/22 13:11:38 maxv Exp $ */ +/* $NetBSD: ip_output.c,v 1.310 2019/02/04 10:48:46 mrg Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -91,7 +91,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.309 2018/12/22 13:11:38 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.310 2019/02/04 10:48:46 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -1238,9 +1238,9 @@ ip_ctloutput(int op, struct socket *so, error = ipsec_set_policy(inp, sopt->sopt_data, sopt->sopt_size, curlwp->l_cred); -break; - } - /*FALLTHROUGH*/ + } else +error = ENOPROTOOPT; + break; #endif /* IPSEC */ default: Index: src/sys/netinet6/ip6_output.c diff -u src/sys/netinet6/ip6_output.c:1.216 src/sys/netinet6/ip6_output.c:1.217 --- src/sys/netinet6/ip6_output.c:1.216 Sat Dec 22 14:28:57 2018 +++ src/sys/netinet6/ip6_output.c Mon Feb 4 10:48:46 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: ip6_output.c,v 1.216 2018/12/22 14:28:57 maxv Exp $ */ +/* $NetBSD: ip6_output.c,v 1.217 2019/02/04 10:48:46 mrg Exp $ */ /* $KAME: ip6_output.c,v 1.172 2001/03/25 09:55:56 itojun Exp $ */ /* @@ -62,7 +62,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ip6_output.c,v 1.216 2018/12/22 14:28:57 maxv Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ip6_output.c,v 1.217 2019/02/04 10:48:46 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -1702,9 +1702,9 @@ else \ error = ipsec_set_policy(in6p, sopt->sopt_data, sopt->sopt_size, kauth_cred_get()); -break; - } - /*FALLTHROUGH*/ + } else +error = ENOPROTOOPT; + break; #endif /* IPSEC */ default: @@ -1910,9 +1910,9 @@ else \ sopt->sopt_size, ); if (!error) error = sockopt_setmbuf(sopt, m); -break; - } - /*FALLTHROUGH*/ + } else +error = ENOPROTOOPT; + break; #endif /* IPSEC */ default:
CVS commit: src/usr.sbin
Module Name:src Committed By: mrg Date: Mon Feb 4 10:22:15 UTC 2019 Modified Files: src/usr.sbin/sysinst: Makefile.inc src/usr.sbin/syslogd: Makefile Log Message: use -Wno-error=format-truncation for code that seems particularly annoying or unlikely to actually fail. some of the syslogd ones are not too hard to fix, but most remain. To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/usr.sbin/sysinst/Makefile.inc cvs rdiff -u -r1.27 -r1.28 src/usr.sbin/syslogd/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/sysinst/Makefile.inc diff -u src/usr.sbin/sysinst/Makefile.inc:1.16 src/usr.sbin/sysinst/Makefile.inc:1.17 --- src/usr.sbin/sysinst/Makefile.inc:1.16 Mon Dec 17 01:16:49 2018 +++ src/usr.sbin/sysinst/Makefile.inc Mon Feb 4 10:22:15 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.16 2018/12/17 01:16:49 uwe Exp $ +# $NetBSD: Makefile.inc,v 1.17 2019/02/04 10:22:15 mrg Exp $ # # Makefile for sysinst @@ -118,6 +118,11 @@ COPTS.bsddisklabel.c += -Wno-format-nonl COPTS.md.c += -Wno-format-nonliteral COPTS.partman.c += -Wno-format-nonliteral -Wno-stack-protector +# Lots of warnings +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.partman.c+= -Wno-error=format-truncation +.endif + # Host to ftp from. Default: # "ftp.NetBSD.org" # Index: src/usr.sbin/syslogd/Makefile diff -u src/usr.sbin/syslogd/Makefile:1.27 src/usr.sbin/syslogd/Makefile:1.28 --- src/usr.sbin/syslogd/Makefile:1.27 Fri Feb 9 02:23:32 2018 +++ src/usr.sbin/syslogd/Makefile Mon Feb 4 10:22:15 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.27 2018/02/09 02:23:32 christos Exp $ +# $NetBSD: Makefile,v 1.28 2019/02/04 10:22:15 mrg Exp $ # from: @(#)Makefile 8.1 (Berkeley) 6/6/93 .include @@ -30,4 +30,9 @@ DPADD+= ${LIBWRAP} LDADD+= -lssl -lcrypto +# Overflow that appears impossible +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.syslogd.c+=-Wno-error=format-truncation +.endif + .include
CVS commit: src/sys/dev/ic
Module Name:src Committed By: mrg Date: Mon Feb 4 10:09:32 UTC 2019 Modified Files: src/sys/dev/ic: aic79xx.c aic7xxx.c Log Message: add or adjust fallthru comments. To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 src/sys/dev/ic/aic79xx.c cvs rdiff -u -r1.134 -r1.135 src/sys/dev/ic/aic7xxx.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/aic79xx.c diff -u src/sys/dev/ic/aic79xx.c:1.50 src/sys/dev/ic/aic79xx.c:1.51 --- src/sys/dev/ic/aic79xx.c:1.50 Sat Oct 18 08:33:27 2014 +++ src/sys/dev/ic/aic79xx.c Mon Feb 4 10:09:31 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: aic79xx.c,v 1.50 2014/10/18 08:33:27 snj Exp $ */ +/* $NetBSD: aic79xx.c,v 1.51 2019/02/04 10:09:31 mrg Exp $ */ /* * Core routines and tables shareable across OS platforms. @@ -49,7 +49,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: aic79xx.c,v 1.50 2014/10/18 08:33:27 snj Exp $"); +__KERNEL_RCSID(0, "$NetBSD: aic79xx.c,v 1.51 2019/02/04 10:09:31 mrg Exp $"); #include #include @@ -1401,6 +1401,7 @@ ahd_handle_seqint(struct ahd_softc *ahd, switch (scb->hscb->task_management) { case SIU_TASKMGMT_ABORT_TASK: tag = SCB_GET_TAG(scb); +/* FALLTHROUGH */ case SIU_TASKMGMT_ABORT_TASK_SET: case SIU_TASKMGMT_CLEAR_TASK_SET: lun = scb->hscb->lun; @@ -1411,6 +1412,7 @@ ahd_handle_seqint(struct ahd_softc *ahd, break; case SIU_TASKMGMT_LUN_RESET: lun = scb->hscb->lun; +/* FALLTHROUGH */ case SIU_TASKMGMT_TARGET_RESET: { struct ahd_devinfo devinfo; @@ -5515,8 +5517,8 @@ ahd_fini_scbdata(struct ahd_softc *ahd) _map->dmasegs, sns_map->nseg); free(sns_map, M_DEVBUF); } - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case 2: { struct map_node *sg_map; @@ -5529,8 +5531,8 @@ ahd_fini_scbdata(struct ahd_softc *ahd) _map->dmasegs, sg_map->nseg); free(sg_map, M_DEVBUF); } - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case 1: { struct map_node *hscb_map; @@ -5543,8 +5545,8 @@ ahd_fini_scbdata(struct ahd_softc *ahd) _map->dmasegs, hscb_map->nseg); free(hscb_map, M_DEVBUF); } - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case 0: break; } @@ -6175,6 +6177,7 @@ ahd_init(struct ahd_softc *ahd) case FLX_CSTAT_OVER: case FLX_CSTAT_UNDER: warn_user++; + /* FALLTHROUGH */ case FLX_CSTAT_INVALID: case FLX_CSTAT_OKAY: if (warn_user == 0 && bootverbose == 0) @@ -7341,8 +7344,8 @@ ahd_search_scb_list(struct ahd_softc *ah if ((scb->flags & SCB_ACTIVE) == 0) printf("Inactive SCB in Waiting List\n"); ahd_done(ahd, scb); - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case SEARCH_REMOVE: ahd_rem_wscb(ahd, scbid, prev, next, tid); if (prev == SCB_LIST_NULL) @@ -7350,6 +7353,7 @@ ahd_search_scb_list(struct ahd_softc *ah break; case SEARCH_PRINT: printf("0x%x ", scbid); + /* FALLTHROUGH */ case SEARCH_COUNT: prev = scbid; break; @@ -8505,8 +8509,8 @@ ahd_download_instr(struct ahd_softc *ahd { fmt3_ins = fmt3_ins->address = ahd_resolve_seqaddr(ahd, fmt3_ins->address); - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case AIC_OP_OR: case AIC_OP_AND: case AIC_OP_XOR: Index: src/sys/dev/ic/aic7xxx.c diff -u src/sys/dev/ic/aic7xxx.c:1.134 src/sys/dev/ic/aic7xxx.c:1.135 --- src/sys/dev/ic/aic7xxx.c:1.134 Mon Apr 2 10:44:06 2018 +++ src/sys/dev/ic/aic7xxx.c Mon Feb 4 10:09:31 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: aic7xxx.c,v 1.134 2018/04/02 10:44:06 rin Exp $ */ +/* $NetBSD: aic7xxx.c,v 1.135 2019/02/04 10:09:31 mrg Exp $ */ /* * Core routines and tables shareable across OS platforms. @@ -39,7 +39,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGES. * - * $Id: aic7xxx.c,v 1.134 2018/04/02 10:44:06 rin Exp $ + * $Id: aic7xxx.c,v 1.135 2019/02/04 10:09:31 mrg Exp $ * * //depot/aic7xxx/aic7xxx/aic7xxx.c#112 $ * @@ -50,7 +50,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: aic7xxx.c,v 1.134 2018/04/02 10:44:06 rin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: aic7xxx.c,v 1.135 2019/02/04 10:09:31 mrg Exp $"); #include #include @@ -5475,8 +5475,8 @@ ahc_search_qinfifo(struct ahc_softc *ahc printf("Inactive SCB in " "Waiting List\n"); ahc_done(ahc, scb); -/* FALLTHROUGH */ } + /* FALLTHROUGH */ case SEARCH_REMOVE: next = ahc_rem_wscb(ahc, next, prev); break; @@ -6470,8 +6470,8 @@ ahc_download_instr(struct ahc_softc *ahc } address -= address_offset; fmt3_ins->address = address; - /* FALLTHROUGH */ } + /* FALLTHROUGH */ case AIC_OP_OR: case AIC_OP_AND: case AIC_OP_XOR:
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 10:11:34 UTC 2019 Modified Files: src/sys/kern: uipc_usrreq.c src/sys/net: if_ethersubr.c Log Message: add or adjust fallthru comments. To generate a diff of this commit: cvs rdiff -u -r1.189 -r1.190 src/sys/kern/uipc_usrreq.c cvs rdiff -u -r1.272 -r1.273 src/sys/net/if_ethersubr.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/uipc_usrreq.c diff -u src/sys/kern/uipc_usrreq.c:1.189 src/sys/kern/uipc_usrreq.c:1.190 --- src/sys/kern/uipc_usrreq.c:1.189 Tue Jan 29 09:28:50 2019 +++ src/sys/kern/uipc_usrreq.c Mon Feb 4 10:11:34 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: uipc_usrreq.c,v 1.189 2019/01/29 09:28:50 pgoyette Exp $ */ +/* $NetBSD: uipc_usrreq.c,v 1.190 2019/02/04 10:11:34 mrg Exp $ */ /*- * Copyright (c) 1998, 2000, 2004, 2008, 2009 The NetBSD Foundation, Inc. @@ -96,7 +96,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uipc_usrreq.c,v 1.189 2019/01/29 09:28:50 pgoyette Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uipc_usrreq.c,v 1.190 2019/02/04 10:11:34 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_compat_netbsd.h" @@ -669,9 +669,8 @@ uipc_ctloutput(int op, struct socket *so error = sockopt_setint(sopt, optval); break; } - /* FALLTHROUGH */ #undef OPTBIT - + /* FALLTHROUGH */ default: error = ENOPROTOOPT; break; Index: src/sys/net/if_ethersubr.c diff -u src/sys/net/if_ethersubr.c:1.272 src/sys/net/if_ethersubr.c:1.273 --- src/sys/net/if_ethersubr.c:1.272 Fri Dec 21 08:58:08 2018 +++ src/sys/net/if_ethersubr.c Mon Feb 4 10:11:34 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: if_ethersubr.c,v 1.272 2018/12/21 08:58:08 msaitoh Exp $ */ +/* $NetBSD: if_ethersubr.c,v 1.273 2019/02/04 10:11:34 mrg Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -61,7 +61,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_ethersubr.c,v 1.272 2018/12/21 08:58:08 msaitoh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_ethersubr.c,v 1.273 2019/02/04 10:11:34 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -790,9 +790,8 @@ ether_input(struct ifnet *ifp, struct mb /* unknown subtype */ break; } - /* FALLTHROUGH */ } - + /* FALLTHROUGH */ default: if (m->m_flags & M_PROMISC) { m_freem(m);
CVS commit: src/usr.bin/stat
Module Name:src Committed By: mrg Date: Mon Feb 4 10:03:16 UTC 2019 Modified Files: src/usr.bin/stat: Makefile Log Message: rework the previous to only apply if !HOSTPROG To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/usr.bin/stat/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.bin/stat/Makefile diff -u src/usr.bin/stat/Makefile:1.9 src/usr.bin/stat/Makefile:1.10 --- src/usr.bin/stat/Makefile:1.9 Mon Feb 4 09:51:47 2019 +++ src/usr.bin/stat/Makefile Mon Feb 4 10:03:16 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.9 2019/02/04 09:51:47 mrg Exp $ +# $NetBSD: Makefile,v 1.10 2019/02/04 10:03:16 mrg Exp $ PROG= stat @@ -10,7 +10,7 @@ MLINKS= stat.1 readlink.1 .include # Has fallthru comment that is missed -.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +.if !defined(HOSTPROG) && defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" COPTS.stat.c+= -Wno-error=implicit-fallthrough .endif
CVS commit: src/sys/modules/viadrmums
Module Name:src Committed By: mrg Date: Mon Feb 4 09:58:23 UTC 2019 Modified Files: src/sys/modules/viadrmums: Makefile Log Message: apply -Wno-error=implicit-fallthrough to via_dmablit.c. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/modules/viadrmums/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/viadrmums/Makefile diff -u src/sys/modules/viadrmums/Makefile:1.1 src/sys/modules/viadrmums/Makefile:1.2 --- src/sys/modules/viadrmums/Makefile:1.1 Wed Apr 29 12:52:05 2015 +++ src/sys/modules/viadrmums/Makefile Mon Feb 4 09:58:23 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.1 2015/04/29 12:52:05 riastradh Exp $ +# $NetBSD: Makefile,v 1.2 2019/02/04 09:58:23 mrg Exp $ .include "../Makefile.inc" .include "../drmkms/Makefile.inc" @@ -27,4 +27,8 @@ SRCS+= via_video.c SRCS+= via_module.c SRCS+= via_pci.c +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.via_dmablit.c+= -Wno-error=implicit-fallthrough +.endif + .include
CVS commit: src/sys/arch/sparc/sparc
Module Name:src Committed By: mrg Date: Mon Feb 4 09:57:39 UTC 2019 Modified Files: src/sys/arch/sparc/sparc: intr.c Log Message: print the cpu number for the mutex not held xcallintr debug message. add a comment about why this case fires. To generate a diff of this commit: cvs rdiff -u -r1.119 -r1.120 src/sys/arch/sparc/sparc/intr.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/sparc/sparc/intr.c diff -u src/sys/arch/sparc/sparc/intr.c:1.119 src/sys/arch/sparc/sparc/intr.c:1.120 --- src/sys/arch/sparc/sparc/intr.c:1.119 Sat Dec 2 00:48:05 2017 +++ src/sys/arch/sparc/sparc/intr.c Mon Feb 4 09:57:39 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: intr.c,v 1.119 2017/12/02 00:48:05 macallan Exp $ */ +/* $NetBSD: intr.c,v 1.120 2019/02/04 09:57:39 mrg Exp $ */ /* * Copyright (c) 1992, 1993 @@ -41,7 +41,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.119 2017/12/02 00:48:05 macallan Exp $"); +__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.120 2019/02/04 09:57:39 mrg Exp $"); #include "opt_multiprocessor.h" #include "opt_sparc_arch.h" @@ -366,10 +366,14 @@ xcallintr(void *v) if (v != xcallintr) cpuinfo.ci_sintrcnt[13].ev_count++; + /* + * This happens when the remote CPU is slow at responding and the + * caller gave up, and has given up the mutex. + */ if (mutex_owned(_mutex) == 0) { cpuinfo.ci_xpmsg_mutex_not_held.ev_count++; #ifdef DEBUG - printf("%s: mutex not held\n", __func__); + printf("%s: cpu%d mutex not held\n", __func__, cpu_number()); #endif cpuinfo.msg.complete = 1; kpreempt_enable();
CVS commit: src/bin/sh
Module Name:src Committed By: kre Date: Mon Feb 4 09:56:48 UTC 2019 Modified Files: src/bin/sh: syntax.c Log Message: Add a couple of comments. NFC. To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/bin/sh/syntax.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/bin/sh/syntax.c diff -u src/bin/sh/syntax.c:1.7 src/bin/sh/syntax.c:1.8 --- src/bin/sh/syntax.c:1.7 Mon Dec 3 06:40:26 2018 +++ src/bin/sh/syntax.c Mon Feb 4 09:56:48 2019 @@ -1,7 +1,7 @@ -/* $NetBSD: syntax.c,v 1.7 2018/12/03 06:40:26 kre Exp $ */ +/* $NetBSD: syntax.c,v 1.8 2019/02/04 09:56:48 kre Exp $ */ #include -__RCSID("$NetBSD: syntax.c,v 1.7 2018/12/03 06:40:26 kre Exp $"); +__RCSID("$NetBSD: syntax.c,v 1.8 2019/02/04 09:56:48 kre Exp $"); #include #include "shell.h" @@ -19,6 +19,7 @@ __RCSID("$NetBSD: syntax.c,v 1.7 2018/12 /* syntax table used when not in quotes */ const char basesyntax[258] = { CFAKE, CEOF, set_range(CTL_FIRST, CTL_LAST, CCTL) +/* Note code assumes that only the above are CCTL in basesyntax */ set('\n', CNL) set('\\', CBACK) set('\'', CSQUOTE) @@ -61,6 +62,7 @@ const char dqsyntax[258] = { CFAKE, CEOF /* syntax table used when in single quotes */ const char sqsyntax[258] = { CFAKE, CEOF, +/* CCTL includes anything that might perhaps need to be escaped if quoted */ set_range(CTL_FIRST, CTL_LAST, CCTL) set('\n', CNL) set('\'', CSQUOTE)
CVS commit: src/bin/sh
Module Name:src Committed By: kre Date: Mon Feb 4 09:56:26 UTC 2019 Modified Files: src/bin/sh: expand.c Log Message: Fix an old bug (very old) that was made worse in 1.128 (the "${1+$@}" fixes) where a variable containing a CTL char (the only possibility used to be CTLESC (0x81)) would lose that character if the variable was expanded when "set -f" (noglob) was in effect. 1.128 made this worse by adding more 0x8z values (a couple more) which would see the same behaviour, and one of those was noticed by Martijn Dekker. The reasoning was that when noglob is on, when a var is expanded, there are no magic chars, so (apparently) no need to escape anything. Hence nothing was escaped .. including any CTL chars that happened to be present. When we later rmescapes() the CTL chars that we expect might occur are summarily removed - even if they weren't really CTL chars, but just data masquerading. We must *always* escape any CTL char clones that are in the var value, no matter what other conditions apply, and what we expect to happen next. While here, fix rmescapes() (and its $(()) clone, rmescapes_nl()) to be more robust, less likely to forget to delete anything (which was not the issue here, just the reverse) and in a DEBUG shell, have the shell abort() if it encounters something in rmescapes() it is not anticipating, so the code can be made to handle it, or if it should not happen, we can find out why it did. XXX pullup -8 (but will need to be via patch, code is quite different). To generate a diff of this commit: cvs rdiff -u -r1.129 -r1.130 src/bin/sh/expand.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/bin/sh/expand.c diff -u src/bin/sh/expand.c:1.129 src/bin/sh/expand.c:1.130 --- src/bin/sh/expand.c:1.129 Mon Dec 3 06:41:30 2018 +++ src/bin/sh/expand.c Mon Feb 4 09:56:26 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: expand.c,v 1.129 2018/12/03 06:41:30 kre Exp $ */ +/* $NetBSD: expand.c,v 1.130 2019/02/04 09:56:26 kre Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -37,7 +37,7 @@ #if 0 static char sccsid[] = "@(#)expand.c 8.5 (Berkeley) 5/15/95"; #else -__RCSID("$NetBSD: expand.c,v 1.129 2018/12/03 06:41:30 kre Exp $"); +__RCSID("$NetBSD: expand.c,v 1.130 2019/02/04 09:56:26 kre Exp $"); #endif #endif /* not lint */ @@ -938,17 +938,39 @@ evalvar(const char *p, int flag) } else { if (subtype == VSLENGTH) { -for (;*val; val++) +for (; *val; val++) varlen++; } else if (quotes && varflags & VSQUOTE) { +/* + * If we are going to look for magic in the + * value (quotes is set) and the expansion + * occurs inside "" (VSQUOTE) then any char + * that has any potential special meaning + * needs to have that meaning suppressed, + * so supply a CTLESC prefix for it. + */ for (; (c = *val) != '\0'; val++) { if (NEEDESC(c)) STPUTC(CTLESC, expdest); STPUTC(c, expdest); } } else { -while (*val) - STPUTC(*val++, expdest); +/* + * We are going to rmescapes() later, + * so make sure that any data char that + * might be mistaken for one of our CTLxxx + * magic chars is protected ... always. + * + * In BASESYNTAX only our internal CTLxxx + * chars are CCTL, in other syntaxes other + * chars are added (we could also use + * ARISYNTAX, but this is safer) + */ +for (; (c = *val) != '\0'; val++) { + if (BASESYNTAX[c] == CCTL) + STPUTC(CTLESC, expdest); + STPUTC(c, expdest); +} } } } @@ -1968,7 +1990,7 @@ rmescapes(char *str) char *p, *q; p = str; - while (*p != CTLESC && !IS_BORING(*p)) { + while (BASESYNTAX[(int)*p] != CCTL) { if (*p++ == '\0') return; } @@ -1985,6 +2007,10 @@ rmescapes(char *str) } if (*p == CTLESC) p++; +#ifdef DEBUG + else if (BASESYNTAX[(int)*p] == CCTL) + abort(); +#endif *q++ = *p++; } *q = '\0'; @@ -2007,7 +2033,7 @@ rmescapes_nl(char *str) int nls = 0, holdnl = 0, holdlast; p = str; - while (*p != CTLESC && !IS_BORING(*p)) { + while (BASESYNTAX[(int)*p] != CCTL) { if (*p++ == '\0') return; } @@ -2031,6 +2057,10 @@ rmescapes_nl(char *str) } if (*p == CTLESC) p++; +#ifdef DEBUG + else if (BASESYNTAX[(int)*p] == CCTL) + abort(); +#endif holdlast = holdnl; holdnl = is_in_name(*p); /* letters, digits, _ */
CVS commit: src/usr.sbin/mmcformat
Module Name:src Committed By: mrg Date: Mon Feb 4 09:53:41 UTC 2019 Modified Files: src/usr.sbin/mmcformat: mmcformat.c Log Message: - don't make -h/-H get around the argument check by setting 'inquiry' in the fallthru case, but instead explicitly check for 'display_usage' as well. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/usr.sbin/mmcformat/mmcformat.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/mmcformat/mmcformat.c diff -u src/usr.sbin/mmcformat/mmcformat.c:1.4 src/usr.sbin/mmcformat/mmcformat.c:1.5 --- src/usr.sbin/mmcformat/mmcformat.c:1.4 Sat Oct 19 17:16:37 2013 +++ src/usr.sbin/mmcformat/mmcformat.c Mon Feb 4 09:53:41 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: mmcformat.c,v 1.4 2013/10/19 17:16:37 christos Exp $ */ +/* $NetBSD: mmcformat.c,v 1.5 2019/02/04 09:53:41 mrg Exp $ */ /* * Copyright (c) 2006, 2008 Reinoud Zandijk @@ -765,6 +765,7 @@ main(int argc, char *argv[]) case 'h' : case 'H' : display_usage = 1; +break; case 'I' : inquiry = 1; break; @@ -792,10 +793,10 @@ main(int argc, char *argv[]) argv += optind; argc -= optind; - if ((!blank && !format && !grow_session && !grow_spare) && - (!expert && !inquiry)) { - fprintf(stderr, "%s : at least one of -B, -F, -G, -S, -X or -I " -"needs to be specified\n\n", progname); + if (!blank && !format && !grow_session && !grow_spare && + !expert && !inquiry && !display_usage) { + fprintf(stderr, "%s : at least one of -B, -F, -G, -h, -H -S, " +"-X or -I needs to be specified\n\n", progname); return usage(progname); }
CVS commit: src
Module Name:src Committed By: mrg Date: Mon Feb 4 09:51:48 UTC 2019 Modified Files: src/games/backgammon/common_source: Makefile src/games/hunt/huntd: Makefile src/usr.bin/stat: Makefile src/usr.bin/telnet: Makefile src/usr.sbin/quotacheck: Makefile Log Message: apply -Wno-error=implicit-fallthrough on files that have fallthru comments but are missed by the current checker. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/games/backgammon/common_source/Makefile cvs rdiff -u -r1.6 -r1.7 src/games/hunt/huntd/Makefile cvs rdiff -u -r1.8 -r1.9 src/usr.bin/stat/Makefile cvs rdiff -u -r1.56 -r1.57 src/usr.bin/telnet/Makefile cvs rdiff -u -r1.19 -r1.20 src/usr.sbin/quotacheck/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/games/backgammon/common_source/Makefile diff -u src/games/backgammon/common_source/Makefile:1.9 src/games/backgammon/common_source/Makefile:1.10 --- src/games/backgammon/common_source/Makefile:1.9 Sat May 3 14:48:30 2008 +++ src/games/backgammon/common_source/Makefile Mon Feb 4 09:51:48 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.9 2008/05/03 14:48:30 lukem Exp $ +# $NetBSD: Makefile,v 1.10 2019/02/04 09:51:48 mrg Exp $ LIBISPRIVATE= yes @@ -6,4 +6,11 @@ LIB= common SRCS= allow.c board.c check.c fancy.c init.c odds.c \ one.c save.c subs.c table.c +.include + +# Has fallthru comment that is missed +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.check.c+= -Wno-error=implicit-fallthrough +.endif + .include Index: src/games/hunt/huntd/Makefile diff -u src/games/hunt/huntd/Makefile:1.6 src/games/hunt/huntd/Makefile:1.7 --- src/games/hunt/huntd/Makefile:1.6 Sat Mar 29 22:29:55 2014 +++ src/games/hunt/huntd/Makefile Mon Feb 4 09:51:48 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.6 2014/03/29 22:29:55 dholland Exp $ +# $NetBSD: Makefile,v 1.7 2019/02/04 09:51:48 mrg Exp $ PROG= huntd SRCS= answer.c draw.c driver.c execute.c expl.c \ @@ -7,4 +7,11 @@ MAN= huntd.6 CPPFLAGS+=-I${.CURDIR}/../include +.include + +# Has fallthru comment that is missed +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.shots.c+=-Wno-error=implicit-fallthrough +.endif + .include Index: src/usr.bin/stat/Makefile diff -u src/usr.bin/stat/Makefile:1.8 src/usr.bin/stat/Makefile:1.9 --- src/usr.bin/stat/Makefile:1.8 Wed Aug 17 13:22:33 2011 +++ src/usr.bin/stat/Makefile Mon Feb 4 09:51:47 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.8 2011/08/17 13:22:33 christos Exp $ +# $NetBSD: Makefile,v 1.9 2019/02/04 09:51:47 mrg Exp $ PROG= stat @@ -7,6 +7,13 @@ LINKS= ${BINDIR}/stat ${BINDIR}/readlink MLINKS= stat.1 readlink.1 .endif +.include + +# Has fallthru comment that is missed +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.stat.c+= -Wno-error=implicit-fallthrough +.endif + COPTS.stat.c += -Wno-format-nonliteral .include Index: src/usr.bin/telnet/Makefile diff -u src/usr.bin/telnet/Makefile:1.56 src/usr.bin/telnet/Makefile:1.57 --- src/usr.bin/telnet/Makefile:1.56 Sat Jan 5 06:59:46 2019 +++ src/usr.bin/telnet/Makefile Mon Feb 4 09:51:47 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.56 2019/01/05 06:59:46 maya Exp $ +# $NetBSD: Makefile,v 1.57 2019/02/04 09:51:47 mrg Exp $ # # Copyright (c) 1990 The Regents of the University of California. # All rights reserved. @@ -77,4 +77,9 @@ DPADD+= ${LIBPAM} ${PAM_STATIC_DPADD} COPTS.${f}.c+= -Wno-pointer-sign .endfor +# Has fallthru comment that is missed +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.telnet.c+= -Wno-error=implicit-fallthrough +.endif + .include Index: src/usr.sbin/quotacheck/Makefile diff -u src/usr.sbin/quotacheck/Makefile:1.19 src/usr.sbin/quotacheck/Makefile:1.20 --- src/usr.sbin/quotacheck/Makefile:1.19 Sun Mar 6 23:07:23 2011 +++ src/usr.sbin/quotacheck/Makefile Mon Feb 4 09:51:48 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.19 2011/03/06 23:07:23 christos Exp $ +# $NetBSD: Makefile,v 1.20 2019/02/04 09:51:48 mrg Exp $ # @(#)Makefile 8.1 (Berkeley) 6/5/93 .include @@ -12,5 +12,11 @@ CPPFLAGS+=-I${NETBSDSRCDIR}/sbin/fsck -I .PATH: ${NETBSDSRCDIR}/sbin/fsck ${NETBSDSRCDIR}/sys/ufs/ffs ${NETBSDSRCDIR}/usr.bin/quota SRCS+= quotautil.c +.include + +# Has fallthru comment that is missed +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.quotacheck.c+= -Wno-error=implicit-fallthrough +.endif .include
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 09:54:47 UTC 2019 Modified Files: src/sys/kern: kern_veriexec.c src/sys/lib/libunwind: libunwind.cxx Log Message: use __builtin_unreachable() after calls that panic or switch context To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/kern/kern_veriexec.c cvs rdiff -u -r1.10 -r1.11 src/sys/lib/libunwind/libunwind.cxx 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_veriexec.c diff -u src/sys/kern/kern_veriexec.c:1.18 src/sys/kern/kern_veriexec.c:1.19 --- src/sys/kern/kern_veriexec.c:1.18 Tue Nov 7 18:35:57 2017 +++ src/sys/kern/kern_veriexec.c Mon Feb 4 09:54:47 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_veriexec.c,v 1.18 2017/11/07 18:35:57 christos Exp $ */ +/* $NetBSD: kern_veriexec.c,v 1.19 2019/02/04 09:54:47 mrg Exp $ */ /*- * Copyright (c) 2005, 2006 Elad Efrat @@ -29,7 +29,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_veriexec.c,v 1.18 2017/11/07 18:35:57 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_veriexec.c,v 1.19 2019/02/04 09:54:47 mrg Exp $"); #include "opt_veriexec.h" @@ -649,6 +649,7 @@ veriexec_file_verify(struct lwp *l, stru veriexec_file_report(vfe, "Not-evaluated status " "post evaluation; inconsistency detected.", name, NULL, REPORT_ALWAYS|REPORT_PANIC); + __builtin_unreachable(); /* NOTREACHED */ case FINGERPRINT_VALID: Index: src/sys/lib/libunwind/libunwind.cxx diff -u src/sys/lib/libunwind/libunwind.cxx:1.10 src/sys/lib/libunwind/libunwind.cxx:1.11 --- src/sys/lib/libunwind/libunwind.cxx:1.10 Tue Jul 17 19:01:16 2018 +++ src/sys/lib/libunwind/libunwind.cxx Mon Feb 4 09:54:47 2019 @@ -119,6 +119,7 @@ static _Unwind_Reason_Code unwind_phase2 case _URC_INSTALL_CONTEXT: // Transfer control to landing pad. cursor.jumpto(); + __builtin_unreachable(); default: // Bad personality routine. return _URC_FATAL_PHASE2_ERROR; @@ -181,6 +182,7 @@ static _Unwind_Reason_Code unwind_phase2 case _URC_INSTALL_CONTEXT: // Transfer control to landing pad. cursor.jumpto(); + __builtin_unreachable(); default: // Bad personality routine. return _URC_FATAL_PHASE2_ERROR;
CVS commit: src/external/bsd/atf/lib/tools
Module Name:src Committed By: mrg Date: Mon Feb 4 09:40:54 UTC 2019 Modified Files: src/external/bsd/atf/lib/tools: Makefile Log Message: with GCC 7, apply -Wno-error=maybe-uninitialized to parser.cpp. i don't really understand how to remove this warning, someone else could though, so feel free to :-) In file included from /usr/src/external/bsd/atf/dist/tools/parser.cpp:33:0: /usr/src/external/bsd/atf/dist/tools/parser.hpp: In member function 'tools::parser::token tools::parser::tokenizer::next() [with IS = std::basic_istream]': /usr/src/external/bsd/atf/dist/tools/parser.hpp:98:8: warning: '.tools::parser::token::m_line' may be used uninitialized in this function [-Wmaybe-uninitialized] struct token { ^ To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/external/bsd/atf/lib/tools/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/atf/lib/tools/Makefile diff -u src/external/bsd/atf/lib/tools/Makefile:1.5 src/external/bsd/atf/lib/tools/Makefile:1.6 --- src/external/bsd/atf/lib/tools/Makefile:1.5 Wed Feb 12 04:08:31 2014 +++ src/external/bsd/atf/lib/tools/Makefile Mon Feb 4 09:40:54 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.5 2014/02/12 04:08:31 jmmv Exp $ +# $NetBSD: Makefile,v 1.6 2019/02/04 09:40:54 mrg Exp $ NOLINT= # defined @@ -36,4 +36,8 @@ SRCS= application.cpp \ ui.cpp \ user.cpp +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.parser.cpp += -Wno-error=maybe-uninitialized +.endif + .include
CVS commit: src/tests/lib/libc/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 09:35:11 UTC 2019 Modified Files: src/tests/lib/libc/sys: t_wait.c Log Message: - add __unreachable() after ATF_REQUIRE(pid > 0) where pid <= 0. - rearrange one switch so that the -1/0/default cases are the same order in all instances. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/tests/lib/libc/sys/t_wait.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/lib/libc/sys/t_wait.c diff -u src/tests/lib/libc/sys/t_wait.c:1.8 src/tests/lib/libc/sys/t_wait.c:1.9 --- src/tests/lib/libc/sys/t_wait.c:1.8 Fri Jan 13 19:28:55 2017 +++ src/tests/lib/libc/sys/t_wait.c Mon Feb 4 09:35:11 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: t_wait.c,v 1.8 2017/01/13 19:28:55 christos Exp $ */ +/* $NetBSD: t_wait.c,v 1.9 2019/02/04 09:35:11 mrg Exp $ */ /*- * Copyright (c) 2016 The NetBSD Foundation, Inc. @@ -29,7 +29,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__RCSID("$NetBSD: t_wait.c,v 1.8 2017/01/13 19:28:55 christos Exp $"); +__RCSID("$NetBSD: t_wait.c,v 1.9 2019/02/04 09:35:11 mrg Exp $"); #include #include @@ -76,11 +76,12 @@ ATF_TC_BODY(wait6_exited, tc) pid_t pid; switch (pid = fork()) { - case -1: - ATF_REQUIRE(pid > 0); case 0: exit(0x5a5a5a5a); /*NOTREACHED*/ + case -1: + ATF_REQUIRE(pid > 0); + __unreachable(); default: ATF_REQUIRE(wait6(P_PID, pid, , WEXITED, , ) == pid); ATF_REQUIRE(WIFEXITED(st) && WEXITSTATUS(st) == 0x5a); @@ -114,6 +115,7 @@ ATF_TC_BODY(wait6_terminated, tc) /*FALLTHROUGH*/ case -1: ATF_REQUIRE(pid > 0); + __unreachable(); default: ATF_REQUIRE(kill(pid, SIGTERM) == 0); ATF_REQUIRE(wait6(P_PID, pid, , WEXITED, , ) == pid); @@ -150,6 +152,7 @@ ATF_TC_BODY(wait6_coredumped, tc) /*FALLTHROUGH*/ case -1: ATF_REQUIRE(pid > 0); + __unreachable(); default: ATF_REQUIRE(wait6(P_PID, pid, , WEXITED, , ) == pid); ATF_REQUIRE(WIFSIGNALED(st) && WTERMSIG(st) == SIGSEGV @@ -186,6 +189,7 @@ ATF_TC_BODY(wait6_stop_and_go, tc) /*FALLTHROUGH*/ case -1: ATF_REQUIRE(pid > 0); + __unreachable(); default: ATF_REQUIRE(kill(pid, SIGSTOP) == 0); ATF_REQUIRE(wait6(P_PID, pid, , WSTOPPED, , ) == pid); @@ -252,6 +256,7 @@ ATF_TC_BODY(wait6_stopgo_loop, tc) /*FALLTHROUGH*/ case -1: ATF_REQUIRE(pid > 0); + __unreachable(); } printf("Before loop of SIGSTOP/SIGCONT sequence %zu times\n", N);
CVS commit: src/sbin/raidctl
Module Name:src Committed By: mrg Date: Mon Feb 4 09:31:22 UTC 2019 Modified Files: src/sbin/raidctl: raidctl.c Log Message: - add the string length as an explicit parameter to get_time_string() - remove casts when the same type is used on both sides - expand hours_buffer[] to fit the range of hours in an 'int' - add a work around for the sprintf() truncation checker that fails to detect that 'minutes' and 'seconds' have a small range To generate a diff of this commit: cvs rdiff -u -r1.67 -r1.68 src/sbin/raidctl/raidctl.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/raidctl/raidctl.c diff -u src/sbin/raidctl/raidctl.c:1.67 src/sbin/raidctl/raidctl.c:1.68 --- src/sbin/raidctl/raidctl.c:1.67 Sat Mar 24 19:41:35 2018 +++ src/sbin/raidctl/raidctl.c Mon Feb 4 09:31:22 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: raidctl.c,v 1.67 2018/03/24 19:41:35 nakayama Exp $ */ +/* $NetBSD: raidctl.c,v 1.68 2019/02/04 09:31:22 mrg Exp $ */ /*- * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. @@ -39,7 +39,7 @@ #include #ifndef lint -__RCSID("$NetBSD: raidctl.c,v 1.67 2018/03/24 19:41:35 nakayama Exp $"); +__RCSID("$NetBSD: raidctl.c,v 1.68 2019/02/04 09:31:22 mrg Exp $"); #endif @@ -83,7 +83,7 @@ static void check_status(int,int); static void check_parity(int,int, char *); static void do_meter(int, u_long); static void get_bar(char *, double, int); -static void get_time_string(char *, int); +static void get_time_string(char *, size_t, int); static void rf_output_pmstat(int, int); static void rf_pm_configure(int, int, char *, int[]); static unsigned int xstrtouint(const char *); @@ -1076,7 +1076,7 @@ do_meter(int fd, u_long option) last_eta = simple_eta; } - get_time_string(eta_buffer, simple_eta); + get_time_string(eta_buffer, sizeof eta_buffer, simple_eta); fprintf(stdout,"\r%3d%% |%s| ETA: %s %c", percent_done,bar_buffer,eta_buffer,tbits[tbit_value]); @@ -1126,32 +1126,42 @@ get_bar(char *string, double percent, in } static void -get_time_string(char *string, int simple_time) +get_time_string(char *string, size_t len, int simple_time) { int minutes, seconds, hours; - char hours_buffer[5]; + char hours_buffer[8]; char minutes_buffer[5]; char seconds_buffer[5]; if (simple_time >= 0) { - minutes = (int) simple_time / 60; - seconds = ((int)simple_time - 60*minutes); + minutes = simple_time / 60; + seconds = simple_time - 60*minutes; hours = minutes / 60; minutes = minutes - 60*hours; +#if defined(__GNUC__) + /* + * snprintf() truncation checker fails to detect that seconds + * and minutes will be 0-59 range. + */ + if (minutes < 0 || minutes > 60) + minutes = 60; + if (seconds < 0 || seconds > 60) + seconds = 60; +#endif if (hours > 0) { - snprintf(hours_buffer,5,"%02d:",hours); + snprintf(hours_buffer,sizeof hours_buffer,"%02d:",hours); } else { - snprintf(hours_buffer,5," "); + snprintf(hours_buffer,sizeof hours_buffer," "); } - snprintf(minutes_buffer,5,"%02d:",minutes); - snprintf(seconds_buffer,5,"%02d",seconds); - snprintf(string,1024,"%s%s%s", + snprintf(minutes_buffer,sizeof minutes_buffer,"%02d:",minutes); + snprintf(seconds_buffer,sizeof seconds_buffer,"%02d",seconds); + snprintf(string,len,"%s%s%s", hours_buffer, minutes_buffer, seconds_buffer); } else { - snprintf(string,1024," --:--"); + snprintf(string,len," --:--"); } }
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 08:36:43 UTC 2019 Modified Files: src/sys/external/isc/atheros_hal/conf: files.ath_hal src/sys/modules/ath_hal: Makefile Log Message: apply -Wno-error=implicit-fallthrough to ar5212_xmit.c and ar5416_xmit.c. To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 src/sys/external/isc/atheros_hal/conf/files.ath_hal cvs rdiff -u -r1.4 -r1.5 src/sys/modules/ath_hal/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/external/isc/atheros_hal/conf/files.ath_hal diff -u src/sys/external/isc/atheros_hal/conf/files.ath_hal:1.6 src/sys/external/isc/atheros_hal/conf/files.ath_hal:1.7 --- src/sys/external/isc/atheros_hal/conf/files.ath_hal:1.6 Tue Oct 14 08:17:27 2014 +++ src/sys/external/isc/atheros_hal/conf/files.ath_hal Mon Feb 4 08:36:43 2019 @@ -1,4 +1,4 @@ -# $NetBSD: files.ath_hal,v 1.6 2014/10/14 08:17:27 uebayasi Exp $ +# $NetBSD: files.ath_hal,v 1.7 2019/02/04 08:36:43 mrg Exp $ defflag opt_athhal.h ATHHAL_ASSERT ATHHAL_DEBUG ATHHAL_DEBUG_ALQ defflag opt_athhal.h ATHHAL_WRITE_EEPROM ATHHAL_WRITE_REGDOMAIN @@ -93,6 +93,8 @@ file external/isc/atheros_hal/dist/ar521 file external/isc/atheros_hal/dist/ar5212/ar5212_rfgain.c ath & athhal_ar5212_subr file external/isc/atheros_hal/dist/ar5212/ar5212_xmit.c ath & athhal_ar5212_subr +makeoptions ath "CWARNFLAGS.ar5212_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" + # Atheros AR5312 family # defflag opt_athhal.h ATHHAL_AR5312: athhal_eeprom_v3, athhal_ar5212_subr @@ -140,6 +142,8 @@ file external/isc/atheros_hal/dist/ar541 file external/isc/atheros_hal/dist/ar5416/ar9285_attach.c ath & athhal_ar5416 file external/isc/atheros_hal/dist/ar5416/ar9285_reset.c ath & athhal_ar5416 +makeoptions ath "CWARNFLAGS.ar5416_xmit.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" + # # makeoptions ath CPPFLAGS+="-I${S}/external/isc/atheros_hal/dist" Index: src/sys/modules/ath_hal/Makefile diff -u src/sys/modules/ath_hal/Makefile:1.4 src/sys/modules/ath_hal/Makefile:1.5 --- src/sys/modules/ath_hal/Makefile:1.4 Sun Aug 28 15:48:19 2011 +++ src/sys/modules/ath_hal/Makefile Mon Feb 4 08:36:43 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.4 2011/08/28 15:48:19 jmcneill Exp $ +# $NetBSD: Makefile,v 1.5 2019/02/04 08:36:43 mrg Exp $ .include "../Makefile.inc" @@ -96,5 +96,10 @@ SRCS+= ar2133.c \ .include "Makefile.inc" +.if defined(HAVE_GCC) && ${HAVE_GCC} == 7 && ${ACTIVE_CC} == "gcc" +COPTS.ar5212_xmit.c+= -Wno-error=implicit-fallthrough +COPTS.ar5416_xmit.c+= -Wno-error=implicit-fallthrough +.endif + .include KMODSCRIPT= ${S}/modules/ath_hal/ath_hal.ldscript
CVS commit: src/sys/crypto
Module Name:src Committed By: mrg Date: Mon Feb 4 08:23:53 UTC 2019 Modified Files: src/sys/crypto/blowfish: bf_locl.h src/sys/crypto/des: des_locl.h Log Message: add fallthru comments. i considered patching makefiles to ignore these problems, but this code is dead upstream and likely will be removed here rather than ever updated. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/crypto/blowfish/bf_locl.h cvs rdiff -u -r1.4 -r1.5 src/sys/crypto/des/des_locl.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/crypto/blowfish/bf_locl.h diff -u src/sys/crypto/blowfish/bf_locl.h:1.5 src/sys/crypto/blowfish/bf_locl.h:1.6 --- src/sys/crypto/blowfish/bf_locl.h:1.5 Tue Jun 30 13:14:40 2009 +++ src/sys/crypto/blowfish/bf_locl.h Mon Feb 4 08:23:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: bf_locl.h,v 1.5 2009/06/30 13:14:40 pooka Exp $ */ +/* $NetBSD: bf_locl.h,v 1.6 2019/02/04 08:23:53 mrg Exp $ */ /* $KAME: bf_locl.h,v 1.5 2000/08/31 06:03:48 itojun Exp $ */ /* crypto/bf/bf_local.h */ @@ -78,14 +78,14 @@ c+=n; \ l1=l2=0; \ switch (n) { \ - case 8: l2 =((BF_LONG)(*(--(c<<24L; \ - case 7: l2|=((BF_LONG)(*(--(c<<16L; \ - case 6: l2|=((BF_LONG)(*(--(c<< 8L; \ - case 5: l2|=((BF_LONG)(*(--(c; \ - case 4: l1 =((BF_LONG)(*(--(c<<24L; \ - case 3: l1|=((BF_LONG)(*(--(c<<16L; \ - case 2: l1|=((BF_LONG)(*(--(c<< 8L; \ - case 1: l1|=((BF_LONG)(*(--(c; \ + case 8: l2 =((BF_LONG)(*(--(c<<24L; /* FALLTHROUGH */ \ + case 7: l2|=((BF_LONG)(*(--(c<<16L; /* FALLTHROUGH */ \ + case 6: l2|=((BF_LONG)(*(--(c<< 8L; /* FALLTHROUGH */ \ + case 5: l2|=((BF_LONG)(*(--(c; /* FALLTHROUGH */ \ + case 4: l1 =((BF_LONG)(*(--(c<<24L; /* FALLTHROUGH */ \ + case 3: l1|=((BF_LONG)(*(--(c<<16L; /* FALLTHROUGH */ \ + case 2: l1|=((BF_LONG)(*(--(c<< 8L; /* FALLTHROUGH */ \ + case 1: l1|=((BF_LONG)(*(--(c; /* FALLTHROUGH */ \ } \ } @@ -100,14 +100,14 @@ #define l2cn(l1,l2,c,n) { \ c+=n; \ switch (n) { \ - case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); \ - case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); \ - case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); \ - case 5: *(--(c))=(unsigned char)(((l2) )&0xff); \ - case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); \ - case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); \ - case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); \ - case 1: *(--(c))=(unsigned char)(((l1) )&0xff); \ + case 8: *(--(c))=(unsigned char)(((l2)>>24L)&0xff); /* FALLTHROUGH */ \ + case 7: *(--(c))=(unsigned char)(((l2)>>16L)&0xff); /* FALLTHROUGH */ \ + case 6: *(--(c))=(unsigned char)(((l2)>> 8L)&0xff); /* FALLTHROUGH */ \ + case 5: *(--(c))=(unsigned char)(((l2) )&0xff); /* FALLTHROUGH */ \ + case 4: *(--(c))=(unsigned char)(((l1)>>24L)&0xff); /* FALLTHROUGH */ \ + case 3: *(--(c))=(unsigned char)(((l1)>>16L)&0xff); /* FALLTHROUGH */ \ + case 2: *(--(c))=(unsigned char)(((l1)>> 8L)&0xff); /* FALLTHROUGH */ \ + case 1: *(--(c))=(unsigned char)(((l1) )&0xff); /* FALLTHROUGH */ \ } \ } @@ -116,14 +116,14 @@ c+=n; \ l1=l2=0; \ switch (n) { \ - case 8: l2 =((BF_LONG)(*(--(c; \ - case 7: l2|=((BF_LONG)(*(--(c<< 8; \ - case 6: l2|=((BF_LONG)(*(--(c<<16; \ - case 5: l2|=((BF_LONG)(*(--(c<<24; \ - case 4: l1 =((BF_LONG)(*(--(c; \ - case 3: l1|=((BF_LONG)(*(--(c<< 8; \ - case 2: l1|=((BF_LONG)(*(--(c<<16; \ - case 1: l1|=((BF_LONG)(*(--(c<<24; \ + case 8: l2 =((BF_LONG)(*(--(c; /* FALLTHROUGH */ \ + case 7: l2|=((BF_LONG)(*(--(c<< 8; /* FALLTHROUGH */ \ + case 6: l2|=((BF_LONG)(*(--(c<<16; /* FALLTHROUGH */ \ + case 5: l2|=((BF_LONG)(*(--(c<<24; /* FALLTHROUGH */ \ + case 4: l1 =((BF_LONG)(*(--(c; /* FALLTHROUGH */ \ + case 3: l1|=((BF_LONG)(*(--(c<< 8; /* FALLTHROUGH */ \ + case 2: l1|=((BF_LONG)(*(--(c<<16; /* FALLTHROUGH */ \ + case 1: l1|=((BF_LONG)(*(--(c<<24; /* FALLTHROUGH */ \ } \ } @@ -131,14 +131,14 @@ #define l2nn(l1,l2,c,n) { \ c+=n; \ switch (n) { \ - case 8: *(--(c))=(unsigned char)(((l2))&0xff); \ - case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); \ - case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); \ - case 5: *(--(c))=(unsigned char)(((l2)>>24)&0xff); \ - case 4: *(--(c))=(unsigned char)(((l1))&0xff); \ - case 3: *(--(c))=(unsigned char)(((l1)>> 8)&0xff); \ - case 2: *(--(c))=(unsigned char)(((l1)>>16)&0xff); \ - case 1: *(--(c))=(unsigned char)(((l1)>>24)&0xff); \ + case 8: *(--(c))=(unsigned char)(((l2))&0xff); /* FALLTHROUGH */ \ + case 7: *(--(c))=(unsigned char)(((l2)>> 8)&0xff); /* FALLTHROUGH */ \ + case 6: *(--(c))=(unsigned char)(((l2)>>16)&0xff); /* FALLTHROUGH */ \ + case 5:
CVS commit: src
Module Name:src Committed By: mrg Date: Mon Feb 4 08:21:12 UTC 2019 Modified Files: src/lib/libintl: gettext.c src/sbin/iscsid: iscsid_main.c src/usr.sbin/npf/npfd: npfd_log.c Log Message: check for snprintf() truncation and fail sanely if so, rather than attempting to use a file that won't exist or isn't secure. To generate a diff of this commit: cvs rdiff -u -r1.29 -r1.30 src/lib/libintl/gettext.c cvs rdiff -u -r1.11 -r1.12 src/sbin/iscsid/iscsid_main.c cvs rdiff -u -r1.12 -r1.13 src/usr.sbin/npf/npfd/npfd_log.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libintl/gettext.c diff -u src/lib/libintl/gettext.c:1.29 src/lib/libintl/gettext.c:1.30 --- src/lib/libintl/gettext.c:1.29 Fri May 29 12:26:28 2015 +++ src/lib/libintl/gettext.c Mon Feb 4 08:21:11 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: gettext.c,v 1.29 2015/05/29 12:26:28 christos Exp $ */ +/* $NetBSD: gettext.c,v 1.30 2019/02/04 08:21:11 mrg Exp $ */ /*- * Copyright (c) 2000, 2001 Citrus Project, @@ -29,7 +29,7 @@ */ #include -__RCSID("$NetBSD: gettext.c,v 1.29 2015/05/29 12:26:28 christos Exp $"); +__RCSID("$NetBSD: gettext.c,v 1.30 2019/02/04 08:21:11 mrg Exp $"); #include #include @@ -329,8 +329,10 @@ lookup_mofile(char *buf, size_t len, con continue; #endif - snprintf(buf, len, "%s/%s/%s/%s.mo", dir, p, + int rv = snprintf(buf, len, "%s/%s/%s/%s.mo", dir, p, category, domainname); + if (rv > (int)len) + return NULL; if (stat(buf, ) < 0) continue; if ((st.st_mode & S_IFMT) != S_IFREG) @@ -942,7 +944,7 @@ dcngettext(const char *domainname, const unsigned long int n, int category) { const char *msgid; - char path[PATH_MAX]; + char path[PATH_MAX+1]; const char *lpath; static char olpath[PATH_MAX]; const char *cname = NULL; Index: src/sbin/iscsid/iscsid_main.c diff -u src/sbin/iscsid/iscsid_main.c:1.11 src/sbin/iscsid/iscsid_main.c:1.12 --- src/sbin/iscsid/iscsid_main.c:1.11 Mon May 30 21:58:32 2016 +++ src/sbin/iscsid/iscsid_main.c Mon Feb 4 08:21:12 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: iscsid_main.c,v 1.11 2016/05/30 21:58:32 mlelstv Exp $ */ +/* $NetBSD: iscsid_main.c,v 1.12 2019/02/04 08:21:12 mrg Exp $ */ /*- * Copyright (c) 2005,2006,2011 The NetBSD Foundation, Inc. @@ -90,6 +90,7 @@ create_node_name(void) uint32_t hid = 0; size_t siz; int mib[2]; + int total; unsigned char *s; (void) memset(, 0x0, sizeof(snp)); @@ -109,8 +110,12 @@ create_node_name(void) for (s = snp.InitiatorAlias; *s; s++) if (!isalnum((unsigned char) *s) && *s != '-' && *s != '.' && *s != ':') *s = '-'; - snprintf((char *)snp.InitiatorName, sizeof(snp.InitiatorName), + total = snprintf((char *)snp.InitiatorName, sizeof(snp.InitiatorName), "iqn.1994-04.org.netbsd:iscsi.%s:%u", snp.InitiatorAlias, hid); + if ((size_t)total > sizeof(snp.InitiatorName)) { + printf("Warning: iSCSI Node InitiatorName too long to set InitiatorAlias!\n"); + return ISCSID_STATUS_NO_INITIATOR_NAME; + } ioctl(driver, ISCSI_SET_NODE_NAME, ); return snp.status; Index: src/usr.sbin/npf/npfd/npfd_log.c diff -u src/usr.sbin/npf/npfd/npfd_log.c:1.12 src/usr.sbin/npf/npfd/npfd_log.c:1.13 --- src/usr.sbin/npf/npfd/npfd_log.c:1.12 Mon Oct 16 11:17:45 2017 +++ src/usr.sbin/npf/npfd/npfd_log.c Mon Feb 4 08:21:12 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: npfd_log.c,v 1.12 2017/10/16 11:17:45 christos Exp $ */ +/* $NetBSD: npfd_log.c,v 1.13 2019/02/04 08:21:12 mrg Exp $ */ /*- * Copyright (c) 2015 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__RCSID("$NetBSD: npfd_log.c,v 1.12 2017/10/16 11:17:45 christos Exp $"); +__RCSID("$NetBSD: npfd_log.c,v 1.13 2019/02/04 08:21:12 mrg Exp $"); #include #include @@ -190,7 +190,9 @@ fix: rename: fclose(fp); char tmp[MAXPATHLEN]; - snprintf(tmp, sizeof(tmp), "%s.XX", ctx->path); + if (snprintf(tmp, sizeof(tmp), "%s.XX", ctx->path) > MAXPATHLEN) + syslog(LOG_ERR, "Temp file truncated: `%s' does not fit", + ctx->path); int fd; if ((fd = mkstemp(tmp)) == -1) { syslog(LOG_ERR, "Can't make temp file `%s': %m", tmp);
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Feb 4 08:18:08 UTC 2019 Modified Files: src/sys/external/bsd/drm2/i915drm: files.i915drmkms src/sys/external/bsd/drm2/nouveau: files.nouveau src/sys/external/bsd/drm2/radeon: files.radeon src/sys/external/bsd/drm2/ttm: files.ttm src/sys/modules/i915drmkms: Makefile src/sys/modules/savagedrm: Makefile Log Message: add -Wno-error=int-in-bool-context or -Wno-error=implicit-fallthrough for various drm files that would be best ignored or upstream fixed. (could fix savagedrm, no one upstream is that any more.) To generate a diff of this commit: cvs rdiff -u -r1.36 -r1.37 src/sys/external/bsd/drm2/i915drm/files.i915drmkms cvs rdiff -u -r1.25 -r1.26 src/sys/external/bsd/drm2/nouveau/files.nouveau cvs rdiff -u -r1.24 -r1.25 src/sys/external/bsd/drm2/radeon/files.radeon cvs rdiff -u -r1.1 -r1.2 src/sys/external/bsd/drm2/ttm/files.ttm cvs rdiff -u -r1.11 -r1.12 src/sys/modules/i915drmkms/Makefile cvs rdiff -u -r1.1 -r1.2 src/sys/modules/savagedrm/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/external/bsd/drm2/i915drm/files.i915drmkms diff -u src/sys/external/bsd/drm2/i915drm/files.i915drmkms:1.36 src/sys/external/bsd/drm2/i915drm/files.i915drmkms:1.37 --- src/sys/external/bsd/drm2/i915drm/files.i915drmkms:1.36 Sun Jan 27 05:00:48 2019 +++ src/sys/external/bsd/drm2/i915drm/files.i915drmkms Mon Feb 4 08:18:07 2019 @@ -1,4 +1,4 @@ -# $NetBSD: files.i915drmkms,v 1.36 2019/01/27 05:00:48 kre Exp $ +# $NetBSD: files.i915drmkms,v 1.37 2019/02/04 08:18:07 mrg Exp $ version 20180827 @@ -24,6 +24,10 @@ makeoptions i915drmkms "CWARNFLAGS.i91 makeoptions i915drmkms "CWARNFLAGS.intel_sprite.c"+="${${ACTIVE_CC} == gcc:? -Wno-maybe-uninitialized :}" +makeoptions i915drmkms "CWARNFLAGS.intel_ddi.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions i915drmkms "CWARNFLAGS.intel_display.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions i915drmkms "CWARNFLAGS.intel_sdvo.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" + file external/bsd/drm2/i915drm/i915_module.c i915drmkms file external/bsd/drm2/i915drm/i915_pci.c i915drmkms file external/bsd/drm2/i915drm/intel_gtt.c i915drmkms Index: src/sys/external/bsd/drm2/nouveau/files.nouveau diff -u src/sys/external/bsd/drm2/nouveau/files.nouveau:1.25 src/sys/external/bsd/drm2/nouveau/files.nouveau:1.26 --- src/sys/external/bsd/drm2/nouveau/files.nouveau:1.25 Sun Jan 27 05:03:57 2019 +++ src/sys/external/bsd/drm2/nouveau/files.nouveau Mon Feb 4 08:18:08 2019 @@ -1,4 +1,4 @@ -# $NetBSD: files.nouveau,v 1.25 2019/01/27 05:03:57 kre Exp $ +# $NetBSD: files.nouveau,v 1.26 2019/02/04 08:18:08 mrg Exp $ version 20180827 @@ -28,6 +28,9 @@ makeoptions nouveau CPPFLAGS+="-DCONFIG_ makeoptions nouveau "CWARNFLAGS.nouveau"+="-Wno-missing-field-initializers" makeoptions nouveau "CWARNFLAGS.nouveau"+="-Wno-shadow" makeoptions nouveau "CWARNFLAGS.nouveau"+="${${ACTIVE_CC} == clang:? -Wno-error=gnu-variable-sized-type-not-at-end :}" +makeoptions nouveau "CWARNFLAGS.nouveau"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions nouveau "CWARNFLAGS.nouveau_nvkm_subdev_bios_timing.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=int-in-bool-context :}" +makeoptions nouveau "CWARNFLAGS.nouveau_nvkm_subdev_clk_gt215.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=int-in-bool-context :}" file external/bsd/drm2/nouveau/nouveau_module.c nouveau Index: src/sys/external/bsd/drm2/radeon/files.radeon diff -u src/sys/external/bsd/drm2/radeon/files.radeon:1.24 src/sys/external/bsd/drm2/radeon/files.radeon:1.25 --- src/sys/external/bsd/drm2/radeon/files.radeon:1.24 Sun Jan 27 05:05:37 2019 +++ src/sys/external/bsd/drm2/radeon/files.radeon Mon Feb 4 08:18:08 2019 @@ -1,4 +1,4 @@ -# $NetBSD: files.radeon,v 1.24 2019/01/27 05:05:37 kre Exp $ +# $NetBSD: files.radeon,v 1.25 2019/02/04 08:18:08 mrg Exp $ version 20180827 @@ -25,6 +25,11 @@ makeoptions radeon "CWARNFLAGS.radeon"+= makeoptions radeon "CWARNFLAGS.radeon"+="${${ACTIVE_CC} == gcc:? -Wno-maybe-uninitialized :}" +#makeoptions i915drmkms "CWARNFLAGS.radeon_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions i915drmkms "CWARNFLAGS.radeon_evergreen_cs.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions i915drmkms "CWARNFLAGS.radeon_r300.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" +makeoptions i915drmkms "CWARNFLAGS.radeon_r420.c"+="${${ACTIVE_CC} == gcc && ${HAVE_GCC:U0} == 7:? -Wno-error=implicit-fallthrough :}" + file
CVS commit: src/external/gpl3/gcc/usr.bin/backend
Module Name:src Committed By: mrg Date: Mon Feb 4 08:15:51 UTC 2019 Modified Files: src/external/gpl3/gcc/usr.bin/backend: Makefile Log Message: ira-color.c needs -Wno-error=int-in-bool-context for now. To generate a diff of this commit: cvs rdiff -u -r1.51 -r1.52 src/external/gpl3/gcc/usr.bin/backend/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/backend/Makefile diff -u src/external/gpl3/gcc/usr.bin/backend/Makefile:1.51 src/external/gpl3/gcc/usr.bin/backend/Makefile:1.52 --- src/external/gpl3/gcc/usr.bin/backend/Makefile:1.51 Tue Nov 6 06:17:29 2018 +++ src/external/gpl3/gcc/usr.bin/backend/Makefile Mon Feb 4 08:15:51 2019 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.51 2018/11/06 06:17:29 mrg Exp $ +# $NetBSD: Makefile,v 1.52 2019/02/04 08:15:51 mrg Exp $ LIBISPRIVATE= yes @@ -507,6 +507,8 @@ ${G_out_file:T:.c=.o}: insn-target-def.h # XXX make all hooks generated for now. final.o: target-hooks-def.h c-family/c-target-hooks-def.h common/common-target-hooks-def.h +COPTS.ira-color.c+= -Wno-error=int-in-bool-context + .if ${MACHINE_CPU} == "arm" # XXX insn-recog.c:10304:7: error: this decimal constant is unsigned only in ISO C90 [-Werror] COPTS.insn-recog.c+=-Wno-error
CVS commit: src/usr.bin/stat
Module Name:src Committed By: mrg Date: Mon Feb 4 08:07:33 UTC 2019 Modified Files: src/usr.bin/stat: stat.c Log Message: avoid a potential buffer truncation. To generate a diff of this commit: cvs rdiff -u -r1.43 -r1.44 src/usr.bin/stat/stat.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/stat/stat.c diff -u src/usr.bin/stat/stat.c:1.43 src/usr.bin/stat/stat.c:1.44 --- src/usr.bin/stat/stat.c:1.43 Thu Sep 21 22:53:19 2017 +++ src/usr.bin/stat/stat.c Mon Feb 4 08:07:33 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: stat.c,v 1.43 2017/09/21 22:53:19 kre Exp $ */ +/* $NetBSD: stat.c,v 1.44 2019/02/04 08:07:33 mrg Exp $ */ /* * Copyright (c) 2002-2011 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ #include #if !defined(lint) -__RCSID("$NetBSD: stat.c,v 1.43 2017/09/21 22:53:19 kre Exp $"); +__RCSID("$NetBSD: stat.c,v 1.44 2019/02/04 08:07:33 mrg Exp $"); #endif #if ! HAVE_NBTOOL_CONFIG_H @@ -646,7 +646,7 @@ format1(const struct stat *st, uint64_t data; char *stmp, lfmt[24], tmp[20]; const char *sdata; - char smode[12], sid[12], path[PATH_MAX + 4], visbuf[PATH_MAX * 4 + 4]; + char smode[12], sid[13], path[PATH_MAX + 4], visbuf[PATH_MAX * 4 + 4]; struct passwd *pw; struct group *gr; time_t secs;
CVS commit: src/sys/kern
Module Name:src Committed By: mrg Date: Mon Feb 4 08:00:27 UTC 2019 Modified Files: src/sys/kern: subr_thmap.c Log Message: pass a pointer to atomic_cas_ptr_p(), not an (equiv) integer. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/sys/kern/subr_thmap.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_thmap.c diff -u src/sys/kern/subr_thmap.c:1.4 src/sys/kern/subr_thmap.c:1.5 --- src/sys/kern/subr_thmap.c:1.4 Sat Jan 19 20:42:54 2019 +++ src/sys/kern/subr_thmap.c Mon Feb 4 08:00:27 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: subr_thmap.c,v 1.4 2019/01/19 20:42:54 rmind Exp $ */ +/* $NetBSD: subr_thmap.c,v 1.5 2019/02/04 08:00:27 mrg Exp $ */ /*- * Copyright (c) 2018 Mindaugas Rasiukevicius @@ -112,7 +112,7 @@ #include "utils.h" #endif -THMAP_RCSID("$NetBSD: subr_thmap.c,v 1.4 2019/01/19 20:42:54 rmind Exp $"); +THMAP_RCSID("$NetBSD: subr_thmap.c,v 1.5 2019/02/04 08:00:27 mrg Exp $"); /* * NetBSD kernel wrappers @@ -499,7 +499,7 @@ again: thmap->ops->free(nptr, THMAP_INODE_LEN); return false; } - if (!atomic_cas_ptr_p(>root[i], THMAP_NULL, nptr)) { + if (!atomic_cas_ptr_p(>root[i], NULL, nptr)) { goto again; } return true;