CVS commit: src/lib/libc/gen
Module Name:src Committed By: matt Date: Tue May 19 06:09:15 UTC 2015 Modified Files: src/lib/libc/gen: nlist_elf32.c Log Message: Support ELF64 on MIPS N32 even though it's ILP32. XXX should we do this for other arches that support compat_netbsd32? To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/lib/libc/gen/nlist_elf32.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/libc/gen/nlist_elf32.c diff -u src/lib/libc/gen/nlist_elf32.c:1.35 src/lib/libc/gen/nlist_elf32.c:1.36 --- src/lib/libc/gen/nlist_elf32.c:1.35 Wed Mar 21 02:18:14 2012 +++ src/lib/libc/gen/nlist_elf32.c Tue May 19 06:09:15 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: nlist_elf32.c,v 1.35 2012/03/21 02:18:14 christos Exp $ */ +/* $NetBSD: nlist_elf32.c,v 1.36 2015/05/19 06:09:15 matt Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou @@ -36,7 +36,7 @@ #include sys/cdefs.h #if defined(LIBC_SCCS) !defined(lint) -__RCSID($NetBSD: nlist_elf32.c,v 1.35 2012/03/21 02:18:14 christos Exp $); +__RCSID($NetBSD: nlist_elf32.c,v 1.36 2015/05/19 06:09:15 matt Exp $); #endif /* LIBC_SCCS and not lint */ /* If not included by nlist_elf64.c, ELFSIZE won't be defined. */ @@ -77,13 +77,14 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli { struct stat st; Elf_Ehdr ehdr; -#if _LP64 || ELFSIZE == 32 +#if defined(_LP64) || ELFSIZE == 32 || defined(__mips_n32) #if (ELFSIZE == 32) Elf32_Half nshdr; #elif (ELFSIZE == 64) Elf64_Word nshdr; #endif - /* Only support 64+32 mode on LP64; no support for 64 mode on ILP32 */ + /* Only support 64+32 mode on LP64 and MIPS N32 */ + /* No support for 64 mode on ILP32 */ Elf_Ehdr *ehdrp; Elf_Shdr *shdrp, *symshdrp, *symstrshdrp; Elf_Sym *symp; @@ -137,10 +138,11 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli default: BAD; } -#if _LP64 || ELFSIZE == 32 +#if defined(_LP64) || ELFSIZE == 32 || defined(__mips_n32) symshdrp = symstrshdrp = NULL; - /* Only support 64+32 mode on LP64; no support for 64 mode on ILP32 */ + /* Only support 64+32 mode on LP64 and MIPS N32 */ + /* No support for 64 mode on ILP32 */ if (S_ISCHR(st.st_mode)) { const char *nlistname; struct ksyms_gsymbol kg; @@ -308,7 +310,7 @@ done: rv = nent; unmap: munmap(mappedfile, mappedsize); -#endif /* _LP64 || ELFSIZE == 32 */ +#endif /* _LP64 || ELFSIZE == 32 || __mips_n32 */ out: return (rv); }
CVS commit: src/sys/arch/mips/conf
Module Name:src Committed By: matt Date: Tue May 19 07:08:21 UTC 2015 Modified Files: src/sys/arch/mips/conf: std.octeon Log Message: Let the compiler/assembler know we compiling for octeon. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/arch/mips/conf/std.octeon 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/mips/conf/std.octeon diff -u src/sys/arch/mips/conf/std.octeon:1.1 src/sys/arch/mips/conf/std.octeon:1.2 --- src/sys/arch/mips/conf/std.octeon:1.1 Wed Apr 29 08:32:00 2015 +++ src/sys/arch/mips/conf/std.octeon Tue May 19 07:08:21 2015 @@ -1,4 +1,4 @@ -# $NetBSD: std.octeon,v 1.1 2015/04/29 08:32:00 hikaru Exp $ +# $NetBSD: std.octeon,v 1.2 2015/05/19 07:08:21 matt Exp $ machine evbmips mips include conf/std # MI standard options @@ -16,8 +16,8 @@ options EXEC_ELF64 # exec ELF64 binarie options COMPAT_NETBSD32 options EXEC_SCRIPT # exec #! scripts -makeoptions CFLAGS+=-mips64r2 -makeoptions AFLAGS+=-mips64r2 +makeoptions CFLAGS+=-mips64r2 -march=octeon +makeoptions AFLAGS+=-mips64r2 -march=octeon # There is uboot's boot info around 0x10. makeoptions DEFTEXTADDR=0x8020 makeoptions BOARDTYPE=octeon
CVS commit: src/sys/ufs/ffs
Module Name:src Committed By: martin Date: Tue May 19 06:44:42 UTC 2015 Modified Files: src/sys/ufs/ffs: ffs_vfsops.c Log Message: Cosmetics: fix netbsd.org spelling To generate a diff of this commit: cvs rdiff -u -r1.332 -r1.333 src/sys/ufs/ffs/ffs_vfsops.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/ufs/ffs/ffs_vfsops.c diff -u src/sys/ufs/ffs/ffs_vfsops.c:1.332 src/sys/ufs/ffs/ffs_vfsops.c:1.333 --- src/sys/ufs/ffs/ffs_vfsops.c:1.332 Mon May 18 08:33:29 2015 +++ src/sys/ufs/ffs/ffs_vfsops.c Tue May 19 06:44:42 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ffs_vfsops.c,v 1.332 2015/05/18 08:33:29 martin Exp $ */ +/* $NetBSD: ffs_vfsops.c,v 1.333 2015/05/19 06:44:42 martin Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -61,7 +61,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ffs_vfsops.c,v 1.332 2015/05/18 08:33:29 martin Exp $); +__KERNEL_RCSID(0, $NetBSD: ffs_vfsops.c,v 1.333 2015/05/19 06:44:42 martin Exp $); #if defined(_KERNEL_OPT) #include opt_ffs.h @@ -987,7 +987,7 @@ ffs_superblock_validate(struct fs *fs) printf(CGSIZE(fs) miscalculated by one - this file system may have been created by\n an old (buggy) userland, see\n - http://www.netbsd.org/; + http://www.NetBSD.org/; docs/ffsv1badsuperblock.html\n); } else { printf(ERROR: cylinder group size mismatch:
CVS commit: src/distrib
Module Name:src Committed By: martin Date: Tue May 19 06:58:52 UTC 2015 Modified Files: src/distrib/amd64/cdroms: Makefile.cdrom src/distrib/common: Makefile.bootcd src/distrib/i386/cdroms: Makefile.cdrom src/distrib/sparc: Makefile src/distrib/sparc64/cdroms/installcd: Makefile src/distrib/vax/cdroms/installcd: Makefile Log Message: Revert previous untill fallout has been fixed. To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/distrib/amd64/cdroms/Makefile.cdrom cvs rdiff -u -r1.26 -r1.27 src/distrib/common/Makefile.bootcd cvs rdiff -u -r1.34 -r1.35 src/distrib/i386/cdroms/Makefile.cdrom cvs rdiff -u -r1.9 -r1.10 src/distrib/sparc/Makefile cvs rdiff -u -r1.22 -r1.23 src/distrib/sparc64/cdroms/installcd/Makefile cvs rdiff -u -r1.12 -r1.13 src/distrib/vax/cdroms/installcd/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/amd64/cdroms/Makefile.cdrom diff -u src/distrib/amd64/cdroms/Makefile.cdrom:1.14 src/distrib/amd64/cdroms/Makefile.cdrom:1.15 --- src/distrib/amd64/cdroms/Makefile.cdrom:1.14 Mon May 18 06:25:04 2015 +++ src/distrib/amd64/cdroms/Makefile.cdrom Tue May 19 06:58:52 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.cdrom,v 1.14 2015/05/18 06:25:04 martin Exp $ +# $NetBSD: Makefile.cdrom,v 1.15 2015/05/19 06:58:52 martin Exp $ .include bsd.own.mk @@ -11,8 +11,62 @@ CDINSTKERNEL= ../../instkernel CDKERNELS= netbsd-GENERIC.gz netbsd CDRELEASE_NOISOS= true +CDRUNTIME+= ./bin +CDRUNTIME+= ./dev/MAKEDEV +CDRUNTIME+= ./etc +CDRUNTIME+= ./lib +CDRUNTIME+= ./libdata +CDRUNTIME+= ./libexec/ld.elf_so +CDRUNTIME+= ./libexec/lfs_cleanerd +CDRUNTIME+= ./libexec/dhcpcd-run-hooks +CDRUNTIME+= ./libexec/resolvconf/ +CDRUNTIME+= ./mnt +CDRUNTIME+= ./sbin +CDRUNTIME+= ./stand +CDRUNTIME+= ./tmp +CDRUNTIME+= ./usr/bin/ftp +CDRUNTIME+= ./usr/bin/grep +CDRUNTIME+= ./usr/bin/gzip +CDRUNTIME+= ./usr/bin/less +CDRUNTIME+= ./usr/bin/more +CDRUNTIME+= ./usr/bin/netstat +CDRUNTIME+= ./usr/bin/progress +CDRUNTIME+= ./usr/bin/sed +CDRUNTIME+= ./usr/bin/sort +CDRUNTIME+= ./usr/bin/tip +CDRUNTIME+= ./usr/bin/tput +CDRUNTIME+= ./usr/bin/vi +CDRUNTIME+= ./usr/bin/vmstat +.if ${MKBSDTAR} != no +CDRUNTIME+= ./usr/lib/libarchive.so* +.endif +CDRUNTIME+= ./usr/lib/libbz2.so* +CDRUNTIME+= ./usr/lib/libc.so* +CDRUNTIME+= ./usr/lib/libcurses.so* +CDRUNTIME+= ./usr/lib/libedit.so* +CDRUNTIME+= ./usr/lib/libgcc_s.so* +CDRUNTIME+= ./usr/lib/libintl.so* +CDRUNTIME+= ./usr/lib/libkvm.so* +CDRUNTIME+= ./usr/lib/liblzma.so* +CDRUNTIME+= ./usr/lib/libpthread.so* +CDRUNTIME+= ./usr/lib/libterminfo.so* +CDRUNTIME+= ./usr/lib/libutil.so* +CDRUNTIME+= ./usr/lib/libz.so* +.if (${MKCRYPTO} != no) +CDRUNTIME+= ./usr/lib/libcrypto.so* +CDRUNTIME+= ./usr/lib/libssl.so* +.endif +CDRUNTIME+= ./usr/libexec/ld.elf_so +CDRUNTIME+= ./usr/libexec/getty +CDRUNTIME+= ./usr/mdec +CDRUNTIME+= ./usr/sbin/chroot +CDRUNTIME+= ./usr/sbin/installboot +CDRUNTIME+= ./usr/sbin/wiconfig +CDRUNTIME+= ./usr/share/misc/terminfo.cdb +CDRUNTIME+= ./usr/share/locale + image_md_pre: - ${RM} -f cdrom/etc/gettytab cdrom/etc/ttys cdrom/etc/rc + ${MKDIR} cdrom/etc ${HOST_LN} -fs /tmp/gettytab cdrom/etc/gettytab ${INSTALL} ${COPY} ${.CURDIR}/../etc.ttys cdrom/etc/ttys ${INSTALL} ${COPY} ${.CURDIR}/../etc.rc cdrom/etc/rc Index: src/distrib/common/Makefile.bootcd diff -u src/distrib/common/Makefile.bootcd:1.26 src/distrib/common/Makefile.bootcd:1.27 --- src/distrib/common/Makefile.bootcd:1.26 Mon May 18 06:25:04 2015 +++ src/distrib/common/Makefile.bootcd Tue May 19 06:58:52 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.bootcd,v 1.26 2015/05/18 06:25:04 martin Exp $ +# $NetBSD: Makefile.bootcd,v 1.27 2015/05/19 06:58:52 martin Exp $ # # Makefile snipped to create a CD/DVD ISO # @@ -31,9 +31,6 @@ # CDKERNELS couples of the form: #source name_on_cd # CDRUNTIME files/directories to copy from $DESTDIR onto the CD -# CD_SETS sets to be extracted onto the CD -# (default: base modules etc) -# SETS_DIR where the CD_SETS are found (default provided) # source kernels are copied from ${CDINSTKERNEL} (or its obj dir) # note that as of yet, bootxx_cd9660 can't load kernel names of more than # 8 chars (though they can be in a sub-directory meaning the pathname is @@ -59,15 +56,11 @@ CDRELEASE_EXCLUDE+= -s ',./installation/ CDRELEASE_EXCLUDE+= -s ',./installation/installimage.*,,gp' .endif -CD_SETS?= base modules etc -SETS_DIR?= ${RELEASEDIR}/${RELEASEMACHINEDIR}/binary/sets - .include bsd.own.mk # For PRINTOBJDIR .include bsd.kernobj.mk # For KERNSRCDIR DISTRIBVER!= ${HOST_SH} ${KERNSRCDIR}/conf/osrelease.sh DISTRIBREV!= ${HOST_SH} ${KERNSRCDIR}/conf/osrelease.sh -s -CUROBJDIR!= cd ${.CURDIR} ${PRINTOBJDIR} ISO_VOLID!= echo NETBSD_${DISTRIBREV} | tr a-z A-Z PUBLISHER?= The_NetBSD_Project .if defined(CDMAKEFSOPTIONS) @@ -76,12 +69,6 @@ _CDMAKEFSOPTIONS=
CVS commit: src/sys/arch/arm
Module Name:src Committed By: hsuenaga Date: Tue May 19 09:20:19 UTC 2015 Modified Files: src/sys/arch/arm/arm: cpufunc_asm_pj4b.S src/sys/arch/arm/marvell: armadaxp.c mvsocreg.h Log Message: fix Marvell Coherency Barrier register address. configure coherency bus maintance broadcast using MPIDR. we need to configure this regardless of 'options MULTIPROCESSOR.' To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/arm/arm/cpufunc_asm_pj4b.S cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/marvell/armadaxp.c cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/marvell/mvsocreg.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/arm/cpufunc_asm_pj4b.S diff -u src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.9 src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.10 --- src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.9 Thu May 14 17:15:56 2015 +++ src/sys/arch/arm/arm/cpufunc_asm_pj4b.S Tue May 19 09:20:19 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: cpufunc_asm_pj4b.S,v 1.9 2015/05/14 17:15:56 matt Exp $ */ +/* $NetBSD: cpufunc_asm_pj4b.S,v 1.10 2015/05/19 09:20:19 hsuenaga Exp $ */ /*** Copyright (C) Marvell International Ltd. and its affiliates @@ -41,6 +41,16 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI #include arm/asm.h #include arm/locore.h +#define MV_FMC0_SMP (1 1) /* SMP/nAMP enable */ +#define MV_FMC0_PARITY (1 2) /* Enable L1 Cache Parity */ +#define MV_FMC0_LFDIS (1 7) /* Disable DC Speculative linefill*/ +#define MV_FMC0_FW (1 8) /* Cache TLB maintenance broadcast */ + +#define MPIDR_CPUID_MASK (0x3 0) /* CPUID */ +#define MPIDR_CLUSTERID_MASK (0xf 8) /* CLUSTERID */ +#define MPIDR_UNI_PROCESSOR (1 30) /* Uni-Processor System */ +#define MPIDR_MPCORE (1 31) /* New Style MPCore like CortexA9 */ + /* LINTSTUB: void pj4b_cpu_sleep(int); */ ENTRY(pj4b_cpu_sleep) dsb @@ -51,21 +61,21 @@ END(pj4b_cpu_sleep) /* LINTSTUB: void pj4b_config(void); */ ENTRY(pj4b_config) - /* Set Auxiliary Debug Modes Control 0 register */ + /* Set Marvell Auxiliary Debug Modes Control 0 register */ mrc p15, 1, r0, c15, c1, 0 bic r0, r0, #(1 12) @ Erratum#ARM-CPU-6136 @ LDSTM 1st issue is single word orr r0, r0, #(1 22) @ DVM_WAKEUP enable mcr p15, 1, r0, c15, c1, 0 - /* Set Auxiliary Debug Modes Control 1 register */ + /* Set Marvell Auxiliary Debug Modes Control 1 register */ mrc p15, 1, r0, c15, c1, 1 bic r0, r0, #(1 2) @ Erratum#ARM-CPU-6409 @ Disable static branch prediction orr r0, r0, #(1 5) @ STREX backoff disable mcr p15, 1, r0, c15, c1, 1 - /* Set Auxiliary Debug Modes Control 2 register */ + /* Set Marvell Auxiliary Debug Modes Control 2 register */ mrc p15, 1, r0, c15, c1, 2 bic r0, r0, #(1 23) @ Enable fast LDR orr r0, r0, #(1 25) @ Intervention Interleave disable @@ -75,13 +85,18 @@ ENTRY(pj4b_config) orr r0, r0, #(1 31) @ Enable write evict mcr p15, 1, r0, c15, c1, 2 - /* Set Auxiliary FUnction Modes Control 0 register */ - mrc p15, 1, r0, c15, c2, 0 -#ifdef MULTIPROCESSOR - orr r0, r0, #(1 1) @ SMP/nAMP enable -#endif - orr r0, r0, #(1 2) @ L2 parity enable - orr r0, r0, #(1 8) @ Cache TLB maintenance broadcast + /* Set Marvell Auxiliary Function Modes Control 0 register */ + mrc p15, 1, r0, c15, c2, 0 @ get FMC0 + mrc p15, 0, ip, c0, c0, 5 @ get MPIDR + tst ip, #MPIDR_MPCORE + beq 1f@ if not set, not a MPCORE + tst ip, #MPIDR_UNI_PROCESSOR + bne 1f@ if set, uni-processor system + orr r0, r0, #(MV_FMC0_SMP) @ enable SMP/nAMP + orr r0, r0, #(MV_FMC0_FW) @ enable maintenance bcast +1: + bic r0, r0, #(MV_FMC0_LFDIS) @ enable speculative linefill + orr r0, r0, #(MV_FMC0_PARITY) @ enable L1 parity mcr p15, 1, r0, c15, c2, 0 RET @@ -97,7 +112,7 @@ ENTRY_NP(pj4b_io_coherency_barrier) 1: ldr r1, [r0] tst r1, #1 - beq 1b + bne 1b @ if set, CIB is busy. dsb RET END(pj4b_io_coherency_barrier) Index: src/sys/arch/arm/marvell/armadaxp.c diff -u src/sys/arch/arm/marvell/armadaxp.c:1.13 src/sys/arch/arm/marvell/armadaxp.c:1.14 --- src/sys/arch/arm/marvell/armadaxp.c:1.13 Thu May 14 05:39:32 2015 +++ src/sys/arch/arm/marvell/armadaxp.c Tue May 19 09:20:19 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: armadaxp.c,v 1.13 2015/05/14 05:39:32 hsuenaga Exp $ */ +/* $NetBSD: armadaxp.c,v 1.14 2015/05/19 09:20:19 hsuenaga Exp $ */ /*** Copyright (C) Marvell International Ltd. and its affiliates @@ -37,7 +37,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBI ***/ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: armadaxp.c,v 1.13 2015/05/14 05:39:32 hsuenaga Exp $); +__KERNEL_RCSID(0, $NetBSD: armadaxp.c,v 1.14 2015/05/19 09:20:19 hsuenaga Exp $); #define _INTR_PRIVATE @@ -49,7 +49,6 @@
CVS commit: src/sbin/ifconfig
Module Name:src Committed By: ozaki-r Date: Tue May 19 08:14:38 UTC 2015 Modified Files: src/sbin/ifconfig: Makefile Log Message: Fix rump.ifconfig shows host's interface names in link local addresses To generate a diff of this commit: cvs rdiff -u -r1.55 -r1.56 src/sbin/ifconfig/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sbin/ifconfig/Makefile diff -u src/sbin/ifconfig/Makefile:1.55 src/sbin/ifconfig/Makefile:1.56 --- src/sbin/ifconfig/Makefile:1.55 Tue Apr 28 15:14:57 2015 +++ src/sbin/ifconfig/Makefile Tue May 19 08:14:38 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.55 2015/04/28 15:14:57 christos Exp $ +# $NetBSD: Makefile,v 1.56 2015/05/19 08:14:38 ozaki-r Exp $ # @(#)Makefile 8.1 (Berkeley) 6/5/93 # when making a change to this file, please check if the change is @@ -20,7 +20,7 @@ SRCS+= af_inet6.c .include Makefile.inc .PATH: ${.CURDIR}/../../lib/libc/net -RUMPSRCS= getifaddrs.c +RUMPSRCS= getifaddrs.c getnameinfo.c if_indextoname.c .if (${MKRUMP} != no) CPPFLAGS+= -DRUMP_ACTION .endif
CVS commit: src
Module Name:src Committed By: matt Date: Wed May 20 04:37:45 UTC 2015 Modified Files: src/lib/libc/gen: nlist_elf32.c src/sys/compat/netbsd32: netbsd32_ioctl.c src/sys/sys: ksyms.h Log Message: Rework ksym defines and includes. To generate a diff of this commit: cvs rdiff -u -r1.37 -r1.38 src/lib/libc/gen/nlist_elf32.c cvs rdiff -u -r1.71 -r1.72 src/sys/compat/netbsd32/netbsd32_ioctl.c cvs rdiff -u -r1.31 -r1.32 src/sys/sys/ksyms.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libc/gen/nlist_elf32.c diff -u src/lib/libc/gen/nlist_elf32.c:1.37 src/lib/libc/gen/nlist_elf32.c:1.38 --- src/lib/libc/gen/nlist_elf32.c:1.37 Wed May 20 02:45:20 2015 +++ src/lib/libc/gen/nlist_elf32.c Wed May 20 04:37:45 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: nlist_elf32.c,v 1.37 2015/05/20 02:45:20 matt Exp $ */ +/* $NetBSD: nlist_elf32.c,v 1.38 2015/05/20 04:37:45 matt Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou @@ -36,7 +36,7 @@ #include sys/cdefs.h #if defined(LIBC_SCCS) !defined(lint) -__RCSID($NetBSD: nlist_elf32.c,v 1.37 2015/05/20 02:45:20 matt Exp $); +__RCSID($NetBSD: nlist_elf32.c,v 1.38 2015/05/20 04:37:45 matt Exp $); #endif /* LIBC_SCCS and not lint */ /* If not included by nlist_elf64.c, ELFSIZE won't be defined. */ @@ -50,7 +50,6 @@ __RCSID($NetBSD: nlist_elf32.c,v 1.37 2 #include sys/stat.h #include sys/file.h #include sys/ioctl.h -#include sys/ksyms.h #include assert.h #include errno.h @@ -64,6 +63,8 @@ __RCSID($NetBSD: nlist_elf32.c,v 1.37 2 #include sys/exec_elf.h #endif +#include sys/ksyms.h /* after sys/exec_elf.h */ + #if (defined(NLIST_ELF32) (ELFSIZE == 32)) || \ (defined(NLIST_ELF64) (ELFSIZE == 64)) Index: src/sys/compat/netbsd32/netbsd32_ioctl.c diff -u src/sys/compat/netbsd32/netbsd32_ioctl.c:1.71 src/sys/compat/netbsd32/netbsd32_ioctl.c:1.72 --- src/sys/compat/netbsd32/netbsd32_ioctl.c:1.71 Wed May 20 02:45:20 2015 +++ src/sys/compat/netbsd32/netbsd32_ioctl.c Wed May 20 04:37:45 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_ioctl.c,v 1.71 2015/05/20 02:45:20 matt Exp $ */ +/* $NetBSD: netbsd32_ioctl.c,v 1.72 2015/05/20 04:37:45 matt Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -31,7 +31,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: netbsd32_ioctl.c,v 1.71 2015/05/20 02:45:20 matt Exp $); +__KERNEL_RCSID(0, $NetBSD: netbsd32_ioctl.c,v 1.72 2015/05/20 04:37:45 matt Exp $); #include sys/param.h #include sys/systm.h @@ -54,6 +54,7 @@ __KERNEL_RCSID(0, $NetBSD: netbsd32_ioc #include sys/envsys.h #include sys/wdog.h #include sys/clockctl.h +#include sys/exec_elf.h #include sys/ksyms.h #ifdef __sparc__ Index: src/sys/sys/ksyms.h diff -u src/sys/sys/ksyms.h:1.31 src/sys/sys/ksyms.h:1.32 --- src/sys/sys/ksyms.h:1.31 Wed May 20 02:45:20 2015 +++ src/sys/sys/ksyms.h Wed May 20 04:37:45 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ksyms.h,v 1.31 2015/05/20 02:45:20 matt Exp $ */ +/* $NetBSD: ksyms.h,v 1.32 2015/05/20 04:37:45 matt Exp $ */ /* * Copyright (c) 2001, 2003 Anders Magnusson (ra...@ludd.luth.se). @@ -30,10 +30,8 @@ #ifndef _SYS_KSYMS_H_ #define _SYS_KSYMS_H_ -#include sys/exec_elf.h - #ifdef _KSYMS_PRIVATE - +#include sys/exec_elf.h #include sys/queue.h struct ksyms_symtab { @@ -92,12 +90,14 @@ struct ksyms_ogsymbol { #define kg_value _un.ku_value }; +#ifdef ELFSIZE struct ksyms_gsymbol { const char *kg_name; union { Elf_Sym ku_sym; } _un; }; +#endif struct ksyms_gvalue { const char *kv_name;
CVS commit: src/distrib/notes/sparc64
Module Name:src Committed By: snj Date: Wed May 20 05:21:24 UTC 2015 Modified Files: src/distrib/notes/sparc64: Makefile Log Message: don't look for now-gone sparc/legal To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/distrib/notes/sparc64/Makefile Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/notes/sparc64/Makefile diff -u src/distrib/notes/sparc64/Makefile:1.3 src/distrib/notes/sparc64/Makefile:1.4 --- src/distrib/notes/sparc64/Makefile:1.3 Sun Jul 21 08:14:52 2002 +++ src/distrib/notes/sparc64/Makefile Wed May 20 05:21:24 2015 @@ -1,5 +1,5 @@ -# $NetBSD: Makefile,v 1.3 2002/07/21 08:14:52 lukem Exp $ +# $NetBSD: Makefile,v 1.4 2015/05/20 05:21:24 snj Exp $ -MERGED_SRCS+= ${.CURDIR}/../sparc/legal ${COMMON}/xfer +MERGED_SRCS+= ${COMMON}/xfer .include bsd.man.mk
CVS commit: src/sys/dev/i2c
Module Name:src Committed By: msaitoh Date: Wed May 20 00:43:28 UTC 2015 Modified Files: src/sys/dev/i2c: sdtemp.c sdtemp_reg.h Log Message: Add Catalyst CAT34TS02C support. To generate a diff of this commit: cvs rdiff -u -r1.25 -r1.26 src/sys/dev/i2c/sdtemp.c cvs rdiff -u -r1.7 -r1.8 src/sys/dev/i2c/sdtemp_reg.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/i2c/sdtemp.c diff -u src/sys/dev/i2c/sdtemp.c:1.25 src/sys/dev/i2c/sdtemp.c:1.26 --- src/sys/dev/i2c/sdtemp.c:1.25 Thu Apr 23 23:23:00 2015 +++ src/sys/dev/i2c/sdtemp.c Wed May 20 00:43:28 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: sdtemp.c,v 1.25 2015/04/23 23:23:00 pgoyette Exp $*/ +/* $NetBSD: sdtemp.c,v 1.26 2015/05/20 00:43:28 msaitoh Exp $*/ /* * Copyright (c) 2009 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: sdtemp.c,v 1.25 2015/04/23 23:23:00 pgoyette Exp $); +__KERNEL_RCSID(0, $NetBSD: sdtemp.c,v 1.26 2015/05/20 00:43:28 msaitoh Exp $); #include sys/param.h #include sys/systm.h @@ -128,6 +128,8 @@ sdtemp_dev_table[] = { STmicroelectronics STTS3000 }, { CAT_MANUFACTURER_ID, CAT_34TS02_DEVICE_ID, CAT_34TS02_MASK, 4, Catalyst CAT34TS02/CAT6095 }, +{ CAT_MANUFACTURER_ID, CAT_34TS02C_DEVICE_ID, CAT_34TS02C_MASK, 4, + Catalyst CAT34TS02C }, { IDT_MANUFACTURER_ID, IDT_TS3000B3_DEVICE_ID, IDT_TS3000B3_MASK, 4, Integrated Device Technology TS3000B3/TSE2002B3 }, { 0, 0, 0, 2, Unknown } Index: src/sys/dev/i2c/sdtemp_reg.h diff -u src/sys/dev/i2c/sdtemp_reg.h:1.7 src/sys/dev/i2c/sdtemp_reg.h:1.8 --- src/sys/dev/i2c/sdtemp_reg.h:1.7 Thu Jan 9 16:51:05 2014 +++ src/sys/dev/i2c/sdtemp_reg.h Wed May 20 00:43:28 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: sdtemp_reg.h,v 1.7 2014/01/09 16:51:05 mlelstv Exp $ */ +/* $NetBSD: sdtemp_reg.h,v 1.8 2015/05/20 00:43:28 msaitoh Exp $ */ /* * Copyright (c) 2009 The NetBSD Foundation, Inc. @@ -136,5 +136,7 @@ #define CAT_MANUFACTURER_ID 0x1B09 #define CAT_34TS02_DEVICE_ID 0x0800 #define CAT_34TS02_MASK 0xFFE0 +#define CAT_34TS02C_DEVICE_ID 0x0a00 +#define CAT_34TS02C_MASK 0x #endif /* _DEV_I2C_SDTEMPREG_H */
CVS commit: src/distrib/notes
Module Name:src Committed By: snj Date: Wed May 20 05:19:22 UTC 2015 Modified Files: src/distrib/notes: Makefile.inc src/distrib/notes/common: legal.common main Removed Files: src/distrib/notes/acorn26: legal src/distrib/notes/acorn32: legal src/distrib/notes/alpha: legal src/distrib/notes/amd64: legal src/distrib/notes/amiga: legal src/distrib/notes/arc: legal src/distrib/notes/atari: legal src/distrib/notes/bebox: legal src/distrib/notes/cats: legal src/distrib/notes/emips: legal src/distrib/notes/evbarm: legal src/distrib/notes/evbppc: legal src/distrib/notes/ews4800mips: legal src/distrib/notes/hp300: legal src/distrib/notes/hpcarm: legal src/distrib/notes/hpcmips: legal src/distrib/notes/hpcsh: legal src/distrib/notes/hppa: legal src/distrib/notes/i386: legal src/distrib/notes/landisk: legal src/distrib/notes/mac68k: legal src/distrib/notes/macppc: legal src/distrib/notes/mmeye: legal src/distrib/notes/mvme68k: legal src/distrib/notes/news68k: legal src/distrib/notes/newsmips: legal src/distrib/notes/next68k: legal src/distrib/notes/ofppc: legal src/distrib/notes/pmax: legal src/distrib/notes/prep: legal src/distrib/notes/rs6000: legal src/distrib/notes/sandpoint: legal src/distrib/notes/sgimips: legal src/distrib/notes/shark: legal src/distrib/notes/sparc: legal src/distrib/notes/sparc64: legal src/distrib/notes/sun2: legal src/distrib/notes/sun3: legal src/distrib/notes/vax: legal src/distrib/notes/x68k: legal src/distrib/notes/xen: legal Log Message: merge port-specific legal sections into the common file. most of these entries were already in the common file, and it's a pain to maintain them separately. To generate a diff of this commit: cvs rdiff -u -r1.42 -r1.43 src/distrib/notes/Makefile.inc cvs rdiff -u -r1.4 -r0 src/distrib/notes/acorn26/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/acorn32/legal cvs rdiff -u -r1.9 -r0 src/distrib/notes/alpha/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/amd64/legal cvs rdiff -u -r1.11 -r0 src/distrib/notes/amiga/legal cvs rdiff -u -r1.7 -r0 src/distrib/notes/arc/legal cvs rdiff -u -r1.6 -r0 src/distrib/notes/atari/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/bebox/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/cats/legal cvs rdiff -u -r1.93 -r1.94 src/distrib/notes/common/legal.common cvs rdiff -u -r1.520 -r1.521 src/distrib/notes/common/main cvs rdiff -u -r1.2 -r0 src/distrib/notes/emips/legal cvs rdiff -u -r1.5 -r0 src/distrib/notes/evbarm/legal cvs rdiff -u -r1.3 -r0 src/distrib/notes/evbppc/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/ews4800mips/legal cvs rdiff -u -r1.6 -r0 src/distrib/notes/hp300/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/hpcarm/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/hpcmips/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/hpcsh/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/hppa/legal cvs rdiff -u -r1.13 -r0 src/distrib/notes/i386/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/landisk/legal cvs rdiff -u -r1.17 -r0 src/distrib/notes/mac68k/legal cvs rdiff -u -r1.6 -r0 src/distrib/notes/macppc/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/mmeye/legal cvs rdiff -u -r1.7 -r0 src/distrib/notes/mvme68k/legal cvs rdiff -u -r1.2 -r0 src/distrib/notes/news68k/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/newsmips/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/next68k/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/ofppc/legal cvs rdiff -u -r1.10 -r0 src/distrib/notes/pmax/legal cvs rdiff -u -r1.2 -r0 src/distrib/notes/prep/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/rs6000/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/sandpoint/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/sgimips/legal cvs rdiff -u -r1.4 -r0 src/distrib/notes/shark/legal cvs rdiff -u -r1.8 -r0 src/distrib/notes/sparc/legal cvs rdiff -u -r1.3 -r0 src/distrib/notes/sparc64/legal cvs rdiff -u -r1.1 -r0 src/distrib/notes/sun2/legal cvs rdiff -u -r1.6 -r0 src/distrib/notes/sun3/legal cvs rdiff -u -r1.7 -r0 src/distrib/notes/vax/legal cvs rdiff -u -r1.8 -r0 src/distrib/notes/x68k/legal cvs rdiff -u -r1.3 -r0 src/distrib/notes/xen/legal Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/notes/Makefile.inc diff -u src/distrib/notes/Makefile.inc:1.42 src/distrib/notes/Makefile.inc:1.43 --- src/distrib/notes/Makefile.inc:1.42 Sun Jan 26 17:00:03 2014 +++ src/distrib/notes/Makefile.inc Wed May 20 05:19:19 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.inc,v 1.42 2014/01/26 17:00:03 apb Exp $ +# $NetBSD: Makefile.inc,v 1.43 2015/05/20 05:19:19 snj Exp $ # # Ross Harvey r...@netbsd.org @@ -20,7 +20,7 @@ TOCS=
CVS commit: src/sys/compat/netbsd32
Module Name:src Committed By: matt Date: Wed May 20 04:09:37 UTC 2015 Modified Files: src/sys/compat/netbsd32: netbsd32_ioctl.h Log Message: Only define the KIOC netbsd32 stuff if the KIOC ioctls have been defined. To generate a diff of this commit: cvs rdiff -u -r1.46 -r1.47 src/sys/compat/netbsd32/netbsd32_ioctl.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/compat/netbsd32/netbsd32_ioctl.h diff -u src/sys/compat/netbsd32/netbsd32_ioctl.h:1.46 src/sys/compat/netbsd32/netbsd32_ioctl.h:1.47 --- src/sys/compat/netbsd32/netbsd32_ioctl.h:1.46 Wed May 20 02:45:20 2015 +++ src/sys/compat/netbsd32/netbsd32_ioctl.h Wed May 20 04:09:37 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_ioctl.h,v 1.46 2015/05/20 02:45:20 matt Exp $ */ +/* $NetBSD: netbsd32_ioctl.h,v 1.47 2015/05/20 04:09:37 matt Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -533,6 +533,7 @@ struct netbsd32_clockctl_ntp_adjtime { #define CLOCKCTL_NTP_ADJTIME32 _IOWR('C', 0x8, \ struct netbsd32_clockctl_ntp_adjtime) +#ifdef KIOCGSYMBOL struct netbsd32_ksyms_gsymbol { netbsd32_charp kg_name; union { @@ -547,3 +548,4 @@ struct netbsd32_ksyms_gvalue { #define KIOCGVALUE32 _IOWR('l', 4, struct netbsd32_ksyms_gvalue) #define KIOCGSYMBOL32 _IOWR('l', 5, struct netbsd32_ksyms_gsymbol) +#endif /* KIOCGSYMBOL */
CVS commit: [netbsd-7] src/crypto/dist/ipsec-tools/src/racoon
Module Name:src Committed By: msaitoh Date: Wed May 20 02:45:17 UTC 2015 Modified Files: src/crypto/dist/ipsec-tools/src/racoon [netbsd-7]: gssapi.c Log Message: Pull up following revision(s) (requested by christos in ticket #792): crypto/dist/ipsec-tools/src/racoon/gssapi.c: revision 1.5 crypto/dist/ipsec-tools/src/racoon/gssapi.c: revision 1.6 Protect against a NULL pointer dereference described in: https://www.altsci.com/ipsec/ XXX: pullup-7 Detect error earlier to avoid memory leak. XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.4.66.1 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/dist/ipsec-tools/src/racoon/gssapi.c diff -u src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.4 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.4.66.1 --- src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.4 Sat Sep 9 16:22:09 2006 +++ src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Wed May 20 02:45:17 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: gssapi.c,v 1.4 2006/09/09 16:22:09 manu Exp $ */ +/* $NetBSD: gssapi.c,v 1.4.66.1 2015/05/20 02:45:17 msaitoh Exp $ */ /* $KAME: gssapi.c,v 1.19 2001/04/03 15:51:55 thorpej Exp $ */ @@ -192,6 +192,11 @@ gssapi_init(struct ph1handle *iph1) gss_name_t princ, canon_princ; OM_uint32 maj_stat, min_stat; + if (iph1-rmconf == NULL) { + plog(LLV_ERROR, LOCATION, NULL, no remote config\n); + return -1; + } + gps = racoon_calloc(1, sizeof (struct gssapi_ph1_state)); if (gps == NULL) { plog(LLV_ERROR, LOCATION, NULL, racoon_calloc failed\n);
CVS commit: src
Module Name:src Committed By: matt Date: Wed May 20 02:45:20 UTC 2015 Modified Files: src/lib/libc/gen: nlist_elf32.c src/sys/compat/netbsd32: netbsd32_ioctl.c netbsd32_ioctl.h src/sys/kern: kern_ksyms.c src/sys/sys: ksyms.h Log Message: Change the ksyms ioctls to more compat_netbsd32 friendly. Use _IOWR ioctls to avoid extra copyouts. With these changes, netstat and vmstat work on mips64eb with the normal N32 userland and a N64 kernel. To generate a diff of this commit: cvs rdiff -u -r1.36 -r1.37 src/lib/libc/gen/nlist_elf32.c cvs rdiff -u -r1.70 -r1.71 src/sys/compat/netbsd32/netbsd32_ioctl.c cvs rdiff -u -r1.45 -r1.46 src/sys/compat/netbsd32/netbsd32_ioctl.h cvs rdiff -u -r1.75 -r1.76 src/sys/kern/kern_ksyms.c cvs rdiff -u -r1.30 -r1.31 src/sys/sys/ksyms.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libc/gen/nlist_elf32.c diff -u src/lib/libc/gen/nlist_elf32.c:1.36 src/lib/libc/gen/nlist_elf32.c:1.37 --- src/lib/libc/gen/nlist_elf32.c:1.36 Tue May 19 06:09:15 2015 +++ src/lib/libc/gen/nlist_elf32.c Wed May 20 02:45:20 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: nlist_elf32.c,v 1.36 2015/05/19 06:09:15 matt Exp $ */ +/* $NetBSD: nlist_elf32.c,v 1.37 2015/05/20 02:45:20 matt Exp $ */ /* * Copyright (c) 1996 Christopher G. Demetriou @@ -36,7 +36,7 @@ #include sys/cdefs.h #if defined(LIBC_SCCS) !defined(lint) -__RCSID($NetBSD: nlist_elf32.c,v 1.36 2015/05/19 06:09:15 matt Exp $); +__RCSID($NetBSD: nlist_elf32.c,v 1.37 2015/05/20 02:45:20 matt Exp $); #endif /* LIBC_SCCS and not lint */ /* If not included by nlist_elf64.c, ELFSIZE won't be defined. */ @@ -77,14 +77,14 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli { struct stat st; Elf_Ehdr ehdr; -#if defined(_LP64) || ELFSIZE == 32 || defined(__mips_n32) +#if defined(_LP64) || ELFSIZE == 32 || defined(ELF64_MACHDEP_ID) #if (ELFSIZE == 32) Elf32_Half nshdr; #elif (ELFSIZE == 64) Elf64_Word nshdr; #endif - /* Only support 64+32 mode on LP64 and MIPS N32 */ - /* No support for 64 mode on ILP32 */ + /* Only support 64+32 mode on LP64 and those that have defined */ + /* ELF64_MACHDEP_ID, otherwise no support for 64 mode on ILP32 */ Elf_Ehdr *ehdrp; Elf_Shdr *shdrp, *symshdrp, *symstrshdrp; Elf_Sym *symp; @@ -138,14 +138,13 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli default: BAD; } -#if defined(_LP64) || ELFSIZE == 32 || defined(__mips_n32) +#if defined(_LP64) || ELFSIZE == 32 || defined(ELF64_MACHDEP_ID) symshdrp = symstrshdrp = NULL; - /* Only support 64+32 mode on LP64 and MIPS N32 */ - /* No support for 64 mode on ILP32 */ + /* Only support 64+32 mode on LP64 and those that have defined */ + /* ELF64_MACHDEP_ID, otherwise no support for 64 mode on ILP32 */ if (S_ISCHR(st.st_mode)) { const char *nlistname; - struct ksyms_gsymbol kg; Elf_Sym sym; /* @@ -153,6 +152,8 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli */ nent = 0; for (p = list; !ISLAST(p); ++p) { + struct ksyms_gsymbol kg; + int error; p-n_other = 0; p-n_desc = 0; @@ -160,9 +161,32 @@ ELFNAMEEND(__fdnlist)(int fd, struct nli if (*nlistname == '_') nlistname++; + memset(kg, 0, sizeof(kg)); kg.kg_name = nlistname; +#ifdef OKIOCGSYMBOL + struct ksyms_ogsymbol okg; + error = ioctl(fd, KIOCGSYMBOL, kg); + if (error == 0) { +sym = kg.kg_sym; + } else if (error errno == ENOTTY) { +memset(okg, 0, sizeof(okg)); +okg.kg_name = nlistname; +okg.kg_sym = sym; +error = ioctl(fd, OKIOCGSYMBOL, okg); + } +#else kg.kg_sym = sym; - if (ioctl(fd, KIOCGSYMBOL, kg) == 0) { + error = ioctl(fd, KIOCGSYMBOL, kg); +#endif + if (error == 0 +#if !defined(_LP64) ELFSIZE == 64 +#if __mips__ + (intptr_t)sym.st_value == (intmax_t)sym.st_value +#else + (uintptr_t)sym.st_value == sym.st_value +#endif +#endif + 1) { p-n_value = (uintptr_t)sym.st_value; switch (ELF_ST_TYPE(sym.st_info)) { case STT_NOTYPE: @@ -310,7 +334,7 @@ done: rv = nent; unmap: munmap(mappedfile, mappedsize); -#endif /* _LP64 || ELFSIZE == 32 || __mips_n32 */ +#endif /* _LP64 || ELFSIZE == 32 || ELF64_MACHDEP_ID */ out: return (rv); } Index: src/sys/compat/netbsd32/netbsd32_ioctl.c diff -u src/sys/compat/netbsd32/netbsd32_ioctl.c:1.70 src/sys/compat/netbsd32/netbsd32_ioctl.c:1.71 --- src/sys/compat/netbsd32/netbsd32_ioctl.c:1.70 Mon May 18 06:38:59 2015 +++ src/sys/compat/netbsd32/netbsd32_ioctl.c Wed May 20 02:45:20 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_ioctl.c,v 1.70 2015/05/18 06:38:59 martin Exp $ */ +/* $NetBSD: netbsd32_ioctl.c,v 1.71 2015/05/20 02:45:20 matt Exp $ */ /* * Copyright (c) 1998, 2001 Matthew R. Green @@ -31,7 +31,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: netbsd32_ioctl.c,v 1.70 2015/05/18 06:38:59 martin Exp $); +__KERNEL_RCSID(0, $NetBSD: netbsd32_ioctl.c,v 1.71 2015/05/20 02:45:20 matt Exp
CVS commit: src/sys/arch/arm
Module Name:src Committed By: hsuenaga Date: Wed May 20 02:59:57 UTC 2015 Modified Files: src/sys/arch/arm/arm: cpufunc_asm_pj4b.S src/sys/arch/arm/include: armreg.h Log Message: move register accessor macros for MPIDR and AUXFMC0 to armreg.h To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/arm/cpufunc_asm_pj4b.S cvs rdiff -u -r1.104 -r1.105 src/sys/arch/arm/include/armreg.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/arm/cpufunc_asm_pj4b.S diff -u src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.10 src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.11 --- src/sys/arch/arm/arm/cpufunc_asm_pj4b.S:1.10 Tue May 19 09:20:19 2015 +++ src/sys/arch/arm/arm/cpufunc_asm_pj4b.S Wed May 20 02:59:57 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: cpufunc_asm_pj4b.S,v 1.10 2015/05/19 09:20:19 hsuenaga Exp $ */ +/* $NetBSD: cpufunc_asm_pj4b.S,v 1.11 2015/05/20 02:59:57 hsuenaga Exp $ */ /*** Copyright (C) Marvell International Ltd. and its affiliates @@ -88,15 +88,15 @@ ENTRY(pj4b_config) /* Set Marvell Auxiliary Function Modes Control 0 register */ mrc p15, 1, r0, c15, c2, 0 @ get FMC0 mrc p15, 0, ip, c0, c0, 5 @ get MPIDR - tst ip, #MPIDR_MPCORE + tst ip, #PJ4B_MPIDR_MP beq 1f@ if not set, not a MPCORE - tst ip, #MPIDR_UNI_PROCESSOR + tst ip, #PJ4B_MPIDR_U bne 1f@ if set, uni-processor system - orr r0, r0, #(MV_FMC0_SMP) @ enable SMP/nAMP - orr r0, r0, #(MV_FMC0_FW) @ enable maintenance bcast + orr r0, r0, #(PJ4B_AUXFMC0_SMPNAMP) @ enable SMP/nAMP + orr r0, r0, #(PJ4B_AUXFMC0_FW) @ enable maintenance bcast 1: - bic r0, r0, #(MV_FMC0_LFDIS) @ enable speculative linefill - orr r0, r0, #(MV_FMC0_PARITY) @ enable L1 parity + bic r0, r0, #(PJ4B_AUXFMC0_DCSLFD) @ enable speculative linefill + orr r0, r0, #(PJ4B_AUXFMC0_L1PARITY) @ enable L1 parity mcr p15, 1, r0, c15, c2, 0 RET Index: src/sys/arch/arm/include/armreg.h diff -u src/sys/arch/arm/include/armreg.h:1.104 src/sys/arch/arm/include/armreg.h:1.105 --- src/sys/arch/arm/include/armreg.h:1.104 Mon Apr 27 06:56:53 2015 +++ src/sys/arch/arm/include/armreg.h Wed May 20 02:59:57 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: armreg.h,v 1.104 2015/04/27 06:56:53 skrll Exp $ */ +/* $NetBSD: armreg.h,v 1.105 2015/05/20 02:59:57 hsuenaga Exp $ */ /* * Copyright (c) 1998, 2001 Ben Harris @@ -434,8 +434,17 @@ #define MPCORE_AUXCTL_EX 0x0010 /* exclusive L1/L2 cache */ #define MPCORE_AUXCTL_SA 0x0020 /* SMP/AMP */ -/* Marvell PJ4B Auxillary Control Register */ -#define PJ4B_AUXCTL_SMPNAMP 0x0040 /* SMP/AMP */ +/* Marvell PJ4B Auxillary Control Register (CP15.0.R1.c0.1) */ +#define PJ4B_AUXCTL_FW __BIT(0) /* Cache and TLB updates broadcast */ +#define PJ4B_AUXCTL_SMPNAMP __BIT(6) /* 0 = AMP, 1 = SMP */ +#define PJ4B_AUXCTL_L1PARITY __BIT(9) /* L1 parity checking */ + +/* Marvell PJ4B Auxialiary Function Modes Control 0 (CP15.1.R15.c2.0) */ +#define PJ4B_AUXFMC0_L2EN __BIT(0) /* Tightly-Coupled L2 cache enable */ +#define PJ4B_AUXFMC0_SMPNAMP __BIT(1) /* 0 = AMP, 1 = SMP */ +#define PJ4B_AUXFMC0_L1PARITY __BIT(2) /* alias of PJ4B_AUXCTL_L1PARITY */ +#define PJ4B_AUXFMC0_DCSLFD __BIT(2) /* Disable DC Speculative linefill */ +#define PJ4B_AUXFMC0_FW __BIT(8) /* alias of PJ4B_AUXCTL_FW*/ /* Cortex-A9 Auxiliary Control Register (CP15 register 1, opcode 1) */ #define CORTEXA9_AUXCTL_FW 0x0001 /* Cache and TLB updates broadcast */ @@ -671,6 +680,27 @@ #define PRRR_TR_DEVICE 1 // Device #define PRRR_TR_NORMAL 2 // Normal Memory +/* ARMv7 MPIDR, Multiprocessor Affinity Register generic format */ +#define MPIDR_MP __BIT(31) /* 1 = Have MP Extention */ +#define MPIDR_U __BIT(30) /* 1 = Uni-Processor System */ +#define MPIDR_MT __BIT(24) /* 1 = SMT(AFF0 is logical) */ +#define MPIDR_AFF2 __BITS(23,16) /* Affinity Level 2 */ +#define MPIDR_AFF1 __BITS(15,8) /* Affinity Level 1 */ +#define MPIDR_AFF0 __BITS(7,0) /* Affinity Level 0 */ + +/* MPIDR implementation of ARM Cortex A9: SMT and AFF2 is not used */ +#define CORTEXA9_MPIDR_MP MPIDR_MP +#define CORTEXA9_MPIDR_U MPIDR_U +#define CORTEXA9_MPIDR_CLID __BITS(11,8) /* AFF1 = cluster id */ +#define CORTEXA9_MPIDR_CPUID __BITS(0,1) /* AFF0 = phisycal core id */ + +/* MPIDR implementation of Marvell PJ4B-MP: AFF2 is not used */ +#define PJ4B_MPIDR_MP MPIDR_MP +#define PJ4B_MPIDR_U MPIDR_U +#define PJ4B_MPIDR_MT MPIDR_MT /* 1 = SMT(AFF0 is logical) */ +#define PJ4B_MPIDR_CLID __BITS(11,8) /* AFF1 = cluster id */ +#define PJ4B_MPIDR_CPUID __BITS(0,3) /* AFF0 = core id */ + /* Defines for ARM Generic Timer */ #define ARM_CNTCTL_ENABLE __BIT(0) // Timer Enabled #define ARM_CNTCTL_IMASK __BIT(1) // Mask Interrupt @@ -1018,12 +1048,4 @@ ARMREG_WRITE_INLINE(sheeva_xctrl, p15,1 #endif /* !__ASSEMBLER__ */ - -#define MPIDR_31 0x8000 -#define
CVS commit: [netbsd-7] src/doc
Module Name:src Committed By: msaitoh Date: Wed May 20 02:47:17 UTC 2015 Modified Files: src/doc [netbsd-7]: CHANGES-7.0 Log Message: Ticket 792. To generate a diff of this commit: cvs rdiff -u -r1.1.2.304 -r1.1.2.305 src/doc/CHANGES-7.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-7.0 diff -u src/doc/CHANGES-7.0:1.1.2.304 src/doc/CHANGES-7.0:1.1.2.305 --- src/doc/CHANGES-7.0:1.1.2.304 Tue May 19 14:16:33 2015 +++ src/doc/CHANGES-7.0 Wed May 20 02:47:17 2015 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-7.0,v 1.1.2.304 2015/05/19 14:16:33 martin Exp $ +# $NetBSD: CHANGES-7.0,v 1.1.2.305 2015/05/20 02:47:17 msaitoh Exp $ A complete list of changes from the initial NetBSD 7.0 branch on 11 Aug 2014 until the 7.0 release: @@ -23347,3 +23347,9 @@ lib/libc/db/db/db.c1.18 Fix the build for ancient (rhel5) systems that don't have O_CLOEXEC [christos, ticket #791] +crypto/dist/ipsec-tools/src/racoon/gssapi.c 1.5-1.6 + + - Protect against a NULL pointer dereference described in + https://www.altsci.com/ipsec/ + - Detect error earlier to avoid memory leak. + [christos, ticket #792]
CVS commit: src/sys/arch/arm/nvidia
Module Name:src Committed By: jmcneill Date: Wed May 20 00:05:53 UTC 2015 Modified Files: src/sys/arch/arm/nvidia: tegra_car.c Log Message: wait for PLLD2 lock To generate a diff of this commit: cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/nvidia/tegra_car.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/arm/nvidia/tegra_car.c diff -u src/sys/arch/arm/nvidia/tegra_car.c:1.18 src/sys/arch/arm/nvidia/tegra_car.c:1.19 --- src/sys/arch/arm/nvidia/tegra_car.c:1.18 Mon May 18 21:32:05 2015 +++ src/sys/arch/arm/nvidia/tegra_car.c Wed May 20 00:05:53 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: tegra_car.c,v 1.18 2015/05/18 21:32:05 jmcneill Exp $ */ +/* $NetBSD: tegra_car.c,v 1.19 2015/05/20 00:05:53 jmcneill Exp $ */ /*- * Copyright (c) 2015 Jared D. McNeill jmcne...@invisible.ca @@ -29,7 +29,7 @@ #include locators.h #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: tegra_car.c,v 1.18 2015/05/18 21:32:05 jmcneill Exp $); +__KERNEL_RCSID(0, $NetBSD: tegra_car.c,v 1.19 2015/05/20 00:05:53 jmcneill Exp $); #include sys/param.h #include sys/bus.h @@ -609,6 +609,8 @@ tegra_car_hdmi_enable(u_int rate) { bus_space_tag_t bst; bus_space_handle_t bsh; + uint32_t base; + int retry = 1; tegra_car_get_bs(bst, bsh); @@ -620,12 +622,25 @@ tegra_car_hdmi_enable(u_int rate) tegra_reg_set_clear(bst, bsh, CAR_PLLD2_BASE_REG, 0, CAR_PLLD2_BASE_IDDQ); delay(2); + /* Enable lock */ + tegra_reg_set_clear(bst, bsh, CAR_PLLD2_MISC_REG, + CAR_PLLD2_MISC_LOCK_ENABLE, 0); /* Enable PLLD2 */ tegra_reg_set_clear(bst, bsh, CAR_PLLD2_BASE_REG, CAR_PLLD2_BASE_ENABLE, 0); + /* Wait for lock */ + do { + delay(2); + base = bus_space_read_4(bst, bsh, CAR_PLLD2_BASE_REG); + } while ((base CAR_PLLD2_BASE_LOCK) == 0 --retry 0); + delay(100); + if (retry == 0) { + printf(WARNING: timeout waiting for PLLD2 lock\n); + } + /* Set clock source to PLLD2 */ - const u_int div = howmany(tegra_car_plld2_rate(), rate);; + const u_int div = howmany(tegra_car_plld2_rate(), rate); bus_space_write_4(bst, bsh, CAR_CLKSRC_HDMI_REG, __SHIFTIN(CAR_CLKSRC_HDMI_SRC_PLLD2_OUT0, CAR_CLKSRC_HDMI_SRC) | __SHIFTIN(div - 1, CAR_CLKSRC_HDMI_DIV));
CVS commit: src/tests/net/route
Module Name:src Committed By: ozaki-r Date: Wed May 20 01:30:42 UTC 2015 Modified Files: src/tests/net/route: t_flags.sh Log Message: Add tests for XRESOLVE flag To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/tests/net/route/t_flags.sh Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/net/route/t_flags.sh diff -u src/tests/net/route/t_flags.sh:1.1 src/tests/net/route/t_flags.sh:1.2 --- src/tests/net/route/t_flags.sh:1.1 Mon May 18 06:27:04 2015 +++ src/tests/net/route/t_flags.sh Wed May 20 01:30:42 2015 @@ -1,4 +1,4 @@ -# $NetBSD: t_flags.sh,v 1.1 2015/05/18 06:27:04 ozaki-r Exp $ +# $NetBSD: t_flags.sh,v 1.2 2015/05/20 01:30:42 ozaki-r Exp $ # # Copyright (c) 2015 The NetBSD Foundation, Inc. # All rights reserved. @@ -332,20 +332,48 @@ test_announce() # TODO test its behavior } +test_xresolve_rtm() +{ + local ip=$1 + local rtm=$2 + local pid= + + rump.route -n monitor ./mon.log + pid=$! + + atf_check -s exit:0 -o ignore rump.ping -n -w 1 -c 1 $ip + $DEBUG rump.netstat -rn -f inet + $DEBUG cat ./mon.log + + atf_check -s exit:0 grep -q $rtm ./mon.log + + kill $pid +} + test_xresolve() { + export RUMP_SERVER=$SOCK_LOCAL + # For a normal route, a RTM_ADD message is emitted on a route cloning + test_xresolve_rtm 10.0.0.1 RTM_ADD + # Up, Host, LLINFO, cloned + check_entry_flags 10.0.0.1 UHLc + # Delete an existing route first atf_check -s exit:0 -o ignore rump.route delete -net 10.0.0.0/24 - - atf_check -s exit:0 -o ignore rump.route add -net 10.0.0.0/24 10.0.0.1 -xresolve + # Create a connected route with XRESOLVE flag for the interface + atf_check -s exit:0 -o ignore rump.route add -net 10.0.0.0/24 10.0.0.2 \ + -interface -xresolve $DEBUG rump.netstat -rn -f inet - # Up, Gateway, Xresolve, Static - check_entry_flags 10.0.0/24 UGXS - - # TODO test its behavior + # Up, Cloning, Xresolve, Static + check_entry_flags 10.0.0/24 UCXS + + # If XRESOLVE flag is set, a RTM_RESOLVE message is emitted + test_xresolve_rtm 10.0.0.1 RTM_RESOLVE + # Up, Host, Xresolve, LLINFO, cloned + check_entry_flags 10.0.0.1 UHXLc } cleanup()
CVS commit: src/sys/sys
Module Name:src Committed By: matt Date: Wed May 20 04:08:54 UTC 2015 Modified Files: src/sys/sys: exec_elf.h Log Message: add struct exec_package; To generate a diff of this commit: cvs rdiff -u -r1.145 -r1.146 src/sys/sys/exec_elf.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/sys/exec_elf.h diff -u src/sys/sys/exec_elf.h:1.145 src/sys/sys/exec_elf.h:1.146 --- src/sys/sys/exec_elf.h:1.145 Thu Oct 23 08:55:32 2014 +++ src/sys/sys/exec_elf.h Wed May 20 04:08:54 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: exec_elf.h,v 1.145 2014/10/23 08:55:32 martin Exp $ */ +/* $NetBSD: exec_elf.h,v 1.146 2015/05/20 04:08:54 matt Exp $ */ /*- * Copyright (c) 1994 The NetBSD Foundation, Inc. @@ -1285,6 +1285,7 @@ struct elf_args { struct ps_strings; struct coredump_iostate; struct note_state; +struct exec_package; #ifdef EXEC_ELF32 int exec_elf32_makecmds(struct lwp *, struct exec_package *);
CVS commit: src/sys/sys
Module Name:src Committed By: riastradh Date: Tue May 19 23:35:11 UTC 2015 Modified Files: src/sys/sys: time.h Log Message: Avoid C99 initializers outside _KERNEL. Various software is built with, e.g., gcc without -std=c99, which defaults to c89, which chokes on these. Noted by Kamil Rytarowski. To generate a diff of this commit: cvs rdiff -u -r1.68 -r1.69 src/sys/sys/time.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/sys/time.h diff -u src/sys/sys/time.h:1.68 src/sys/sys/time.h:1.69 --- src/sys/sys/time.h:1.68 Wed Apr 29 12:55:23 2015 +++ src/sys/sys/time.h Tue May 19 23:35:11 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: time.h,v 1.68 2015/04/29 12:55:23 riastradh Exp $ */ +/* $NetBSD: time.h,v 1.69 2015/05/19 23:35:11 riastradh Exp $ */ /* * Copyright (c) 1982, 1986, 1993 @@ -203,31 +203,34 @@ timeval2bintime(const struct timeval *tv static __inline struct bintime ms2bintime(uint64_t ms) { + struct bintime bt; - return (struct bintime) { - .sec = ms / 1000U, - .frac = (((ms % 1000U) 32)/1000U) 32, - }; + bt.sec = ms / 1000U; + bt.frac = (((ms % 1000U) 32)/1000U) 32; + + return bt; } static __inline struct bintime us2bintime(uint64_t us) { + struct bintime bt; + + bt.sec = us / 100U; + bt.frac = (((us % 100U) 32)/100U) 32; - return (struct bintime) { - .sec = us / 100U, - .frac = (((us % 100U) 32)/100U) 32, - }; + return bt; } static __inline struct bintime ns2bintime(uint64_t ns) { + struct bintime bt; + + bt.sec = ns / 10U; + bt.frac = (((ns % 10U) 32)/10U) 32; - return (struct bintime) { - .sec = ns / 10U, - .frac = (((ns % 10U) 32)/10U) 32, - }; + return bt; } #endif /* !defined(_STANDALONE) */
CVS commit: src/sys/sys
Module Name:src Committed By: joerg Date: Tue May 19 12:17:53 UTC 2015 Modified Files: src/sys/sys: ipc.h Log Message: Use __BEGIN_DECLS / __END_DECLS consistently for _KERNEL part too. Don't pollute namespace by including sys/sysctl.h for !_KERNEL part. To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/sys/sys/ipc.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/sys/ipc.h diff -u src/sys/sys/ipc.h:1.35 src/sys/sys/ipc.h:1.36 --- src/sys/sys/ipc.h:1.35 Wed May 13 01:23:10 2015 +++ src/sys/sys/ipc.h Tue May 19 12:17:53 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ipc.h,v 1.35 2015/05/13 01:23:10 pgoyette Exp $ */ +/* $NetBSD: ipc.h,v 1.36 2015/05/19 12:17:53 joerg Exp $ */ /* * Copyright (c) 1988 University of Utah. @@ -50,7 +50,6 @@ #include sys/featuretest.h #include sys/types.h -#include sys/sysctl.h struct ipc_perm { uid_t uid; /* user id */ @@ -108,14 +107,17 @@ struct ipc_perm_sysctl { #endif #ifdef _KERNEL +#include sys/sysctl.h #define IPCID_TO_IX(id) ((id) 0x) #define IPCID_TO_SEQ(id) (((id) 16) 0x) struct kauth_cred; +__BEGIN_DECLS int ipcperm(struct kauth_cred *, struct ipc_perm *, int); void sysvipcinit(void); void sysvipcfini(void); +__END_DECLS /* * sysctl helper routine for kern.ipc.sysvipc_info subtree. @@ -135,13 +137,11 @@ void sysvipcfini(void); * Set-up the sysctl routine for COMPAT_50 */ +__BEGIN_DECLS void sysvipc50_set_compat_sysctl(int (*)(SYSCTLFN_PROTO)); +__END_DECLS -#endif /* _KERNEL */ - -#ifndef _KERNEL -#include sys/cdefs.h - +#else /* _KERNEL */ __BEGIN_DECLS key_t ftok(const char *, int); __END_DECLS
CVS commit: src/lib/libc/db/db
Module Name:src Committed By: christos Date: Tue May 19 13:20:52 UTC 2015 Modified Files: src/lib/libc/db/db: db.c Log Message: Fix the build for ancient (rhel5) systems that don't have O_CLOEXEC XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/lib/libc/db/db/db.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/libc/db/db/db.c diff -u src/lib/libc/db/db/db.c:1.17 src/lib/libc/db/db/db.c:1.18 --- src/lib/libc/db/db/db.c:1.17 Mon Dec 22 12:01:42 2014 +++ src/lib/libc/db/db/db.c Tue May 19 09:20:52 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: db.c,v 1.17 2014/12/22 17:01:42 christos Exp $ */ +/* $NetBSD: db.c,v 1.18 2015/05/19 13:20:52 christos Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -34,7 +34,7 @@ #endif #include sys/cdefs.h -__RCSID($NetBSD: db.c,v 1.17 2014/12/22 17:01:42 christos Exp $); +__RCSID($NetBSD: db.c,v 1.18 2015/05/19 13:20:52 christos Exp $); #include namespace.h #include sys/types.h @@ -51,6 +51,10 @@ static int __dberr(void); __weak_alias(dbopen,_dbopen) #endif +#ifndef O_CLOEXEC +#define O_CLOEXEC 0 +#endif + DB * dbopen(const char *fname, int flags, mode_t mode, DBTYPE type, const void *openinfo)
CVS commit: [netbsd-7] src/lib/libc/db/db
Module Name:src Committed By: martin Date: Tue May 19 14:14:53 UTC 2015 Modified Files: src/lib/libc/db/db [netbsd-7]: db.c Log Message: Pull up following revision(s) (requested by christos in ticket #791): lib/libc/db/db/db.c: revision 1.18 Fix the build for ancient (rhel5) systems that don't have O_CLOEXEC To generate a diff of this commit: cvs rdiff -u -r1.16.40.1 -r1.16.40.2 src/lib/libc/db/db/db.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/libc/db/db/db.c diff -u src/lib/libc/db/db/db.c:1.16.40.1 src/lib/libc/db/db/db.c:1.16.40.2 --- src/lib/libc/db/db/db.c:1.16.40.1 Tue May 19 05:11:58 2015 +++ src/lib/libc/db/db/db.c Tue May 19 14:14:52 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: db.c,v 1.16.40.1 2015/05/19 05:11:58 snj Exp $ */ +/* $NetBSD: db.c,v 1.16.40.2 2015/05/19 14:14:52 martin Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -34,7 +34,7 @@ #endif #include sys/cdefs.h -__RCSID($NetBSD: db.c,v 1.16.40.1 2015/05/19 05:11:58 snj Exp $); +__RCSID($NetBSD: db.c,v 1.16.40.2 2015/05/19 14:14:52 martin Exp $); #include namespace.h #include sys/types.h @@ -51,6 +51,10 @@ static int __dberr(void); __weak_alias(dbopen,_dbopen) #endif +#ifndef O_CLOEXEC +#define O_CLOEXEC 0 +#endif + DB * dbopen(const char *fname, int flags, mode_t mode, DBTYPE type, const void *openinfo)
CVS commit: [netbsd-7] src/doc
Module Name:src Committed By: martin Date: Tue May 19 14:16:33 UTC 2015 Modified Files: src/doc [netbsd-7]: CHANGES-7.0 Log Message: Ticket #791 To generate a diff of this commit: cvs rdiff -u -r1.1.2.303 -r1.1.2.304 src/doc/CHANGES-7.0 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES-7.0 diff -u src/doc/CHANGES-7.0:1.1.2.303 src/doc/CHANGES-7.0:1.1.2.304 --- src/doc/CHANGES-7.0:1.1.2.303 Tue May 19 05:37:18 2015 +++ src/doc/CHANGES-7.0 Tue May 19 14:16:33 2015 @@ -1,4 +1,4 @@ -# $NetBSD: CHANGES-7.0,v 1.1.2.303 2015/05/19 05:37:18 snj Exp $ +# $NetBSD: CHANGES-7.0,v 1.1.2.304 2015/05/19 14:16:33 martin Exp $ A complete list of changes from the initial NetBSD 7.0 branch on 11 Aug 2014 until the 7.0 release: @@ -23342,3 +23342,8 @@ xsrc/external/mit/xf86-video-intel/dist/ are no longer necessary. [mrg, ticket #788] +lib/libc/db/db/db.c1.18 + + Fix the build for ancient (rhel5) systems that don't have O_CLOEXEC + [christos, ticket #791] +
CVS commit: src/crypto/dist/ipsec-tools/src/racoon
Module Name:src Committed By: christos Date: Tue May 19 15:14:26 UTC 2015 Modified Files: src/crypto/dist/ipsec-tools/src/racoon: gssapi.c Log Message: Protect against a NULL pointer dereference described in: https://www.altsci.com/ipsec/ XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/dist/ipsec-tools/src/racoon/gssapi.c diff -u src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.4 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.5 --- src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.4 Sat Sep 9 12:22:09 2006 +++ src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Tue May 19 11:14:25 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: gssapi.c,v 1.4 2006/09/09 16:22:09 manu Exp $ */ +/* $NetBSD: gssapi.c,v 1.5 2015/05/19 15:14:25 christos Exp $ */ /* $KAME: gssapi.c,v 1.19 2001/04/03 15:51:55 thorpej Exp $ */ @@ -202,6 +202,10 @@ gssapi_init(struct ph1handle *iph1) gssapi_set_state(iph1, gps); + if (iph1-rmconf == NULL) { + plog(LLV_ERROR, LOCATION, NULL, no remote config\n); + return -1; + } if (iph1-rmconf-proposal-gssid != NULL) { id_token.length = iph1-rmconf-proposal-gssid-l; id_token.value = iph1-rmconf-proposal-gssid-v;
CVS commit: src/crypto/dist/ipsec-tools/src/racoon
Module Name:src Committed By: christos Date: Tue May 19 15:16:01 UTC 2015 Modified Files: src/crypto/dist/ipsec-tools/src/racoon: gssapi.c Log Message: Detect error earlier to avoid memory leak. XXX: pullup-7 To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/crypto/dist/ipsec-tools/src/racoon/gssapi.c diff -u src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.5 src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.6 --- src/crypto/dist/ipsec-tools/src/racoon/gssapi.c:1.5 Tue May 19 11:14:25 2015 +++ src/crypto/dist/ipsec-tools/src/racoon/gssapi.c Tue May 19 11:16:00 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: gssapi.c,v 1.5 2015/05/19 15:14:25 christos Exp $ */ +/* $NetBSD: gssapi.c,v 1.6 2015/05/19 15:16:00 christos Exp $ */ /* $KAME: gssapi.c,v 1.19 2001/04/03 15:51:55 thorpej Exp $ */ @@ -192,6 +192,11 @@ gssapi_init(struct ph1handle *iph1) gss_name_t princ, canon_princ; OM_uint32 maj_stat, min_stat; + if (iph1-rmconf == NULL) { + plog(LLV_ERROR, LOCATION, NULL, no remote config\n); + return -1; + } + gps = racoon_calloc(1, sizeof (struct gssapi_ph1_state)); if (gps == NULL) { plog(LLV_ERROR, LOCATION, NULL, racoon_calloc failed\n); @@ -202,10 +207,6 @@ gssapi_init(struct ph1handle *iph1) gssapi_set_state(iph1, gps); - if (iph1-rmconf == NULL) { - plog(LLV_ERROR, LOCATION, NULL, no remote config\n); - return -1; - } if (iph1-rmconf-proposal-gssid != NULL) { id_token.length = iph1-rmconf-proposal-gssid-l; id_token.value = iph1-rmconf-proposal-gssid-v;
CVS commit: src/sys/netinet
Module Name:src Committed By: kefren Date: Tue May 19 17:33:44 UTC 2015 Modified Files: src/sys/netinet: tcp_subr.c Log Message: Use RUN_ONCE to initialize iss secret. Suggested by riastradh@ To generate a diff of this commit: cvs rdiff -u -r1.261 -r1.262 src/sys/netinet/tcp_subr.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_subr.c diff -u src/sys/netinet/tcp_subr.c:1.261 src/sys/netinet/tcp_subr.c:1.262 --- src/sys/netinet/tcp_subr.c:1.261 Sat May 16 10:09:20 2015 +++ src/sys/netinet/tcp_subr.c Tue May 19 17:33:43 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: tcp_subr.c,v 1.261 2015/05/16 10:09:20 kefren Exp $ */ +/* $NetBSD: tcp_subr.c,v 1.262 2015/05/19 17:33:43 kefren Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -91,7 +91,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: tcp_subr.c,v 1.261 2015/05/16 10:09:20 kefren Exp $); +__KERNEL_RCSID(0, $NetBSD: tcp_subr.c,v 1.262 2015/05/19 17:33:43 kefren Exp $); #include opt_inet.h #include opt_ipsec.h @@ -240,6 +240,7 @@ int tcp_syn_bucket_limit = 3*TCP_SYN_BUC struct syn_cache_head tcp_syn_cache[TCP_SYN_HASH_SIZE]; int tcp_freeq(struct tcpcb *); +static int tcp_iss_secret_init(void); #ifdef INET static void tcp_mtudisc_callback(struct in_addr); @@ -2217,6 +2218,20 @@ tcp_new_iss(struct tcpcb *tp, tcp_seq ad panic(tcp_new_iss); } +static u_int8_t tcp_iss_secret[16]; /* 128 bits; should be plenty */ + +/* + * Initialize RFC 1948 ISS Secret + */ +static int +tcp_iss_secret_init(void) +{ + cprng_strong(kern_cprng, + tcp_iss_secret, sizeof(tcp_iss_secret), 0); + + return 0; +} + /* * This routine actually generates a new TCP initial sequence number. */ @@ -2226,23 +2241,16 @@ tcp_new_iss1(void *laddr, void *faddr, u { tcp_seq tcp_iss; - /* RFC1948 specifics */ - static bool tcp_iss_gotten_secret; - static u_int8_t tcp_iss_secret[16]; /* 128 bits; should be plenty */ - if (tcp_do_rfc1948) { MD5_CTX ctx; u_int8_t hash[16]; /* XXX MD5 knowledge */ + static ONCE_DECL(tcp_iss_secret_control); /* * If we haven't been here before, initialize our cryptographic * hash secret. */ - if (tcp_iss_gotten_secret == false) { - cprng_strong(kern_cprng, - tcp_iss_secret, sizeof(tcp_iss_secret), 0); - tcp_iss_gotten_secret = true; - } + RUN_ONCE(tcp_iss_secret_control, tcp_iss_secret_init); /* * Compute the base value of the ISS. It is a hash
CVS commit: src/distrib/notes/common
Module Name:src Committed By: snj Date: Tue May 19 19:45:57 UTC 2015 Modified Files: src/distrib/notes/common: macros Removed Files: src/distrib/notes/common: list-setsizes.sh Log Message: finish removing the set size stuff, which was thrown out four years ago. To generate a diff of this commit: cvs rdiff -u -r1.7 -r0 src/distrib/notes/common/list-setsizes.sh cvs rdiff -u -r1.41 -r1.42 src/distrib/notes/common/macros Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/notes/common/macros diff -u src/distrib/notes/common/macros:1.41 src/distrib/notes/common/macros:1.42 --- src/distrib/notes/common/macros:1.41 Sat May 9 08:13:34 2015 +++ src/distrib/notes/common/macros Tue May 19 19:45:57 2015 @@ -1,4 +1,4 @@ -.\ $NetBSD: macros,v 1.41 2015/05/09 08:13:34 snj Exp $ +.\ $NetBSD: macros,v 1.42 2015/05/19 19:45:57 snj Exp $ .\ .\ Copyright (c) 1999-2004 The NetBSD Foundation, Inc. .\ All rights reserved. @@ -164,31 +164,6 @@ .Ux Ns -like .. . -.\ setsize G U -.\ Remember G and U for the next showsize -.\ showsize [G U] -.\ Display G MB gzipped, U MB uncompressed on a new line, -.\ and then reset the values of G and U to '-unset-'. -.\ Values can be generated with something like this: -.\ gzip -l *.tgz | \ -.\ awk '/\.tar/ { printf .if \\n[%s] .setsize %d %d\n, \ -.\ substr($4,0,index($4, /)-1), \ -.\ ( $1+1048575 ) /1048576, \ -.\ ( $2 + 1048575) / 1048576 } ' -.\ -. -.de setsize -\.ds set_gzip \\$[1] -\.ds set_gunzip \\$[2] -.. -.de showsize -.br -.if \\n(.$==2 .setsize \\$* -.Em \\*[set_gzip] MB gzipped, \\*[set_gunzip] MB uncompressed -.setsize -unset- -unset- -.. -.setsize -unset- -unset- -. .\ .Bc/.Ec; begin/end two-column mode. This may not work in all .\ cases, but was designed for common/donations. There is no .\ support for more than two pages, nor for right-margins.
CVS commit: src/distrib/notes
Module Name:src Committed By: snj Date: Tue May 19 19:30:29 UTC 2015 Modified Files: src/distrib/notes/acorn26: contents src/distrib/notes/acorn32: contents hardware src/distrib/notes/alpha: contents hardware src/distrib/notes/amd64: contents src/distrib/notes/amiga: contents src/distrib/notes/arc: contents src/distrib/notes/atari: contents src/distrib/notes/bebox: contents hardware src/distrib/notes/cats: contents src/distrib/notes/common: main netboot postinstall sysinst src/distrib/notes/emips: contents hardware install src/distrib/notes/evbarm: contents src/distrib/notes/evbppc: contents src/distrib/notes/ews4800mips: contents src/distrib/notes/hp300: contents src/distrib/notes/hpcarm: contents src/distrib/notes/hpcmips: contents src/distrib/notes/hpcsh: contents src/distrib/notes/hppa: contents src/distrib/notes/i386: contents src/distrib/notes/landisk: contents src/distrib/notes/mac68k: contents hardware prep src/distrib/notes/macppc: contents hardware src/distrib/notes/mmeye: contents src/distrib/notes/mvme68k: contents src/distrib/notes/news68k: contents src/distrib/notes/newsmips: contents src/distrib/notes/next68k: contents src/distrib/notes/ofppc: contents src/distrib/notes/pmax: contents hardware src/distrib/notes/prep: contents hardware upgrade src/distrib/notes/rs6000: contents src/distrib/notes/sandpoint: contents src/distrib/notes/sgimips: contents src/distrib/notes/shark: contents src/distrib/notes/sparc: contents hardware prep src/distrib/notes/sparc64: contents hardware src/distrib/notes/sun2: contents src/distrib/notes/sun3: contents src/distrib/notes/vax: contents hardware src/distrib/notes/x68k: contents hardware Log Message: - update upgrade issues: + ARM ABI change + new users + new groups - add modules set where missing - formatting improvements - note that rtsol{,d} will be gone in the future - fix raw partition info - update sparc64 hardware support - remove note about sparc SMP support being broken - update some size requirements (still lots of ancient bogus RAM minimums lingering -- HI PORTMASTERS!) - various other minor content modernization - whitespace fixes To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/acorn26/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/acorn32/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/acorn32/hardware cvs rdiff -u -r1.15 -r1.16 src/distrib/notes/alpha/contents cvs rdiff -u -r1.17 -r1.18 src/distrib/notes/alpha/hardware cvs rdiff -u -r1.4 -r1.5 src/distrib/notes/amd64/contents cvs rdiff -u -r1.19 -r1.20 src/distrib/notes/amiga/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/arc/contents cvs rdiff -u -r1.19 -r1.20 src/distrib/notes/atari/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/bebox/contents \ src/distrib/notes/bebox/hardware cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/cats/contents cvs rdiff -u -r1.519 -r1.520 src/distrib/notes/common/main cvs rdiff -u -r1.35 -r1.36 src/distrib/notes/common/netboot cvs rdiff -u -r1.80 -r1.81 src/distrib/notes/common/postinstall cvs rdiff -u -r1.105 -r1.106 src/distrib/notes/common/sysinst cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/emips/contents \ src/distrib/notes/emips/hardware src/distrib/notes/emips/install cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/evbarm/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/evbppc/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/ews4800mips/contents cvs rdiff -u -r1.16 -r1.17 src/distrib/notes/hp300/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/hpcarm/contents cvs rdiff -u -r1.9 -r1.10 src/distrib/notes/hpcmips/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/hpcsh/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/hppa/contents cvs rdiff -u -r1.28 -r1.29 src/distrib/notes/i386/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/landisk/contents cvs rdiff -u -r1.19 -r1.20 src/distrib/notes/mac68k/contents cvs rdiff -u -r1.24 -r1.25 src/distrib/notes/mac68k/hardware cvs rdiff -u -r1.16 -r1.17 src/distrib/notes/mac68k/prep cvs rdiff -u -r1.10 -r1.11 src/distrib/notes/macppc/contents cvs rdiff -u -r1.47 -r1.48 src/distrib/notes/macppc/hardware cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/mmeye/contents cvs rdiff -u -r1.12 -r1.13 src/distrib/notes/mvme68k/contents cvs rdiff -u -r1.5 -r1.6 src/distrib/notes/news68k/contents cvs rdiff -u -r1.1 -r1.2 src/distrib/notes/newsmips/contents cvs rdiff -u -r1.6 -r1.7 src/distrib/notes/next68k/contents cvs rdiff -u -r1.2 -r1.3 src/distrib/notes/ofppc/contents cvs rdiff -u -r1.16 -r1.17 src/distrib/notes/pmax/contents cvs rdiff -u -r1.17 -r1.18 src/distrib/notes/pmax/hardware cvs rdiff -u -r1.1 -r1.2