CVS commit: src/sys/compat/netbsd32
Module Name:src Committed By: dholland Date: Tue Jun 23 06:28:29 UTC 2015 Modified Files: src/sys/compat/netbsd32: netbsd32_nfssvc.c Log Message: add missing opt_nfsserver.h To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/sys/compat/netbsd32/netbsd32_nfssvc.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/netbsd32/netbsd32_nfssvc.c diff -u src/sys/compat/netbsd32/netbsd32_nfssvc.c:1.1 src/sys/compat/netbsd32/netbsd32_nfssvc.c:1.2 --- src/sys/compat/netbsd32/netbsd32_nfssvc.c:1.1 Mon Jun 22 10:35:00 2015 +++ src/sys/compat/netbsd32/netbsd32_nfssvc.c Tue Jun 23 06:28:29 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: netbsd32_nfssvc.c,v 1.1 2015/06/22 10:35:00 mrg Exp $ */ +/* $NetBSD: netbsd32_nfssvc.c,v 1.2 2015/06/23 06:28:29 dholland Exp $ */ /* * Copyright (c) 2015 Matthew R. Green @@ -29,10 +29,11 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_nfssvc.c,v 1.1 2015/06/22 10:35:00 mrg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_nfssvc.c,v 1.2 2015/06/23 06:28:29 dholland Exp $"); #if defined(_KERNEL_OPT) #include "opt_nfs.h" +#include "opt_nfsserver.h" #include "opt_compat_netbsd.h" #endif
CVS commit: src/sys/compat/netbsd32
Module Name:src Committed By: dholland Date: Tue Jun 23 04:45:53 UTC 2015 Modified Files: src/sys/compat/netbsd32: netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_sysent.c netbsd32_systrace_args.c Log Message: regen To generate a diff of this commit: cvs rdiff -u -r1.116 -r1.117 src/sys/compat/netbsd32/netbsd32_syscall.h \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.115 -r1.116 src/sys/compat/netbsd32/netbsd32_syscalls.c \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.6 -r1.7 src/sys/compat/netbsd32/netbsd32_systrace_args.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/netbsd32/netbsd32_syscall.h diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.116 src/sys/compat/netbsd32/netbsd32_syscall.h:1.117 --- src/sys/compat/netbsd32/netbsd32_syscall.h:1.116 Mon Jun 22 10:35:00 2015 +++ src/sys/compat/netbsd32/netbsd32_syscall.h Tue Jun 23 04:45:53 2015 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscall.h,v 1.116 2015/06/22 10:35:00 mrg Exp $ */ +/* $NetBSD: netbsd32_syscall.h,v 1.117 2015/06/23 04:45:53 dholland Exp $ */ /* * System call numbers. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.107 2015/06/21 12:51:33 martin Exp + * created from NetBSD: syscalls.master,v 1.109 2015/06/23 04:44:08 dholland Exp */ #ifndef _NETBSD32_SYS_SYSCALL_H_ @@ -441,9 +441,13 @@ /* syscall: "compat_43_netbsd32_ogetsockname" ret: "int" args: "int" "netbsd32_voidp" "netbsd32_intp" */ #define NETBSD32_SYS_compat_43_netbsd32_ogetsockname 150 +#if defined(NFSSERVER) || !defined(_KERNEL_OPT) /* syscall: "netbsd32_nfssvc" ret: "int" args: "int" "netbsd32_voidp" */ #define NETBSD32_SYS_netbsd32_nfssvc 155 +#else +/* 155 is excluded netbsd32_nfssvc */ +#endif /* syscall: "compat_43_netbsd32_ogetdirentries" ret: "int" args: "int" "netbsd32_charp" "u_int" "netbsd32_longp" */ #define NETBSD32_SYS_compat_43_netbsd32_ogetdirentries 156 Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.116 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.117 --- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.116 Mon Jun 22 10:35:00 2015 +++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Tue Jun 23 04:45:53 2015 @@ -1,10 +1,10 @@ -/* $NetBSD: netbsd32_syscallargs.h,v 1.116 2015/06/22 10:35:00 mrg Exp $ */ +/* $NetBSD: netbsd32_syscallargs.h,v 1.117 2015/06/23 04:45:53 dholland Exp $ */ /* * System call argument lists. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.107 2015/06/21 12:51:33 martin Exp + * created from NetBSD: syscalls.master,v 1.109 2015/06/23 04:44:08 dholland Exp */ #ifndef _NETBSD32_SYS_SYSCALLARGS_H_ @@ -815,12 +815,15 @@ struct compat_43_netbsd32_ogetsockname_a syscallarg(netbsd32_intp) alen; }; check_syscall_args(compat_43_netbsd32_ogetsockname) +#if defined(NFSSERVER) || !defined(_KERNEL_OPT) struct netbsd32_nfssvc_args { syscallarg(int) flag; syscallarg(netbsd32_voidp) argp; }; check_syscall_args(netbsd32_nfssvc) +#else +#endif struct compat_43_netbsd32_ogetdirentries_args { syscallarg(int) fd; @@ -2898,8 +2901,11 @@ int compat_43_sys_quota(struct lwp *, co int compat_43_netbsd32_ogetsockname(struct lwp *, const struct compat_43_netbsd32_ogetsockname_args *, register_t *); +#if defined(NFSSERVER) || !defined(_KERNEL_OPT) int netbsd32_nfssvc(struct lwp *, const struct netbsd32_nfssvc_args *, register_t *); +#else +#endif int compat_43_netbsd32_ogetdirentries(struct lwp *, const struct compat_43_netbsd32_ogetdirentries_args *, register_t *); int compat_20_netbsd32_statfs(struct lwp *, const struct compat_20_netbsd32_statfs_args *, register_t *); Index: src/sys/compat/netbsd32/netbsd32_syscalls.c diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.115 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.116 --- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.115 Mon Jun 22 10:35:00 2015 +++ src/sys/compat/netbsd32/netbsd32_syscalls.c Tue Jun 23 04:45:53 2015 @@ -1,18 +1,19 @@ -/* $NetBSD: netbsd32_syscalls.c,v 1.115 2015/06/22 10:35:00 mrg Exp $ */ +/* $NetBSD: netbsd32_syscalls.c,v 1.116 2015/06/23 04:45:53 dholland Exp $ */ /* * System call names. * * DO NOT EDIT-- this file is automatically generated. - * created from NetBSD: syscalls.master,v 1.107 2015/06/21 12:51:33 martin Exp + * created from NetBSD: syscalls.master,v 1.109 2015/06/23 04:44:08 dholland Exp */ #include -__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.115 2015/06/22 10:35:00 mrg Exp $"); +__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.116 2015/06/23 04:45:53 dholland Exp $"); #if defined(_KERNEL_OPT) #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" +#include "opt_nfsserver.h" #include "opt_ntp.h
CVS commit: src/sys/compat/netbsd32
Module Name:src Committed By: dholland Date: Tue Jun 23 04:44:08 UTC 2015 Modified Files: src/sys/compat/netbsd32: syscalls.master Log Message: Don't reference netbsd32_nfssvc unless NFSSERVER is defined. Fixes PR 49994. To generate a diff of this commit: cvs rdiff -u -r1.108 -r1.109 src/sys/compat/netbsd32/syscalls.master 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/syscalls.master diff -u src/sys/compat/netbsd32/syscalls.master:1.108 src/sys/compat/netbsd32/syscalls.master:1.109 --- src/sys/compat/netbsd32/syscalls.master:1.108 Mon Jun 22 10:35:00 2015 +++ src/sys/compat/netbsd32/syscalls.master Tue Jun 23 04:44:08 2015 @@ -1,4 +1,4 @@ - $NetBSD: syscalls.master,v 1.108 2015/06/22 10:35:00 mrg Exp $ + $NetBSD: syscalls.master,v 1.109 2015/06/23 04:44:08 dholland Exp $ ; from: NetBSD: syscalls.master,v 1.81 1998/07/05 08:49:50 jonathan Exp ; @(#)syscalls.master 8.2 (Berkeley) 1/13/94 @@ -38,6 +38,7 @@ #if defined(_KERNEL_OPT) #include "opt_compat_netbsd.h" +#include "opt_nfsserver.h" #include "opt_ntp.h" #include "opt_sysv.h" #include "opt_compat_43.h" @@ -317,7 +318,11 @@ 152 UNIMPL 153 UNIMPL 154 UNIMPL +#if defined(NFSSERVER) || !defined(_KERNEL_OPT) 155 STD { int|netbsd32||nfssvc(int flag, netbsd32_voidp argp); } +#else +155 EXCL netbsd32_nfssvc +#endif 156 COMPAT_43 { int|netbsd32||ogetdirentries(int fd, \ netbsd32_charp buf, u_int count, \ netbsd32_longp basep); }
CVS commit: src/share/mk
Module Name:src Committed By: matt Date: Tue Jun 23 01:38:17 UTC 2015 Modified Files: src/share/mk: bsd.own.mk Log Message: Default MKPICLIB on powerpc64 to yes To generate a diff of this commit: cvs rdiff -u -r1.856 -r1.857 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.856 src/share/mk/bsd.own.mk:1.857 --- src/share/mk/bsd.own.mk:1.856 Mon Jun 22 06:47:26 2015 +++ src/share/mk/bsd.own.mk Tue Jun 23 01:38:17 2015 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.own.mk,v 1.856 2015/06/22 06:47:26 matt Exp $ +# $NetBSD: bsd.own.mk,v 1.857 2015/06/23 01:38:17 matt Exp $ # This needs to be before bsd.init.mk .if defined(BSD_MK_COMPAT_FILE) @@ -758,6 +758,10 @@ MKGDB.ia64= no MKPICLIB:= no .endif +# PowerPC64 and AArch64 ABI's are PIC +MKPICLIB.powerpc64= no +#MKPICLIB.aarch64= no + # # On VAX using ELF, all objects are PIC, not just shared libraries, # so don't build the _pic version.
CVS commit: src/external/gpl3/gcc/dist/gcc/config/rs6000
Module Name:src Committed By: matt Date: Tue Jun 23 01:37:13 UTC 2015 Modified Files: src/external/gpl3/gcc/dist/gcc/config/rs6000: rs6000.c Log Message: By changing rs6000_elf_reloc_rw_mask to return 3 if using a powerpc64 ABI on NetBSD, we basicly eliminate the only difference between have -fPIC or not. This enables us to turn on MKPICLIB for powerpc64. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 \ src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c diff -u src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.10 src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.11 --- src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c:1.10 Tue Jan 20 07:12:41 2015 +++ src/external/gpl3/gcc/dist/gcc/config/rs6000/rs6000.c Tue Jun 23 01:37:13 2015 @@ -29124,7 +29124,11 @@ rs6000_elf_reloc_rw_mask (void) if (flag_pic) return 3; else if (DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_ELFv2) +#if defined (POWERPC_NETBSD) +return 3; +#else return 2; +#endif else return 0; }
CVS commit: src/distrib/sets/lists
Module Name:src Committed By: matt Date: Tue Jun 23 01:03:35 UTC 2015 Modified Files: src/distrib/sets/lists/base: ad.powerpc src/distrib/sets/lists/comp: ad.powerpc src/distrib/sets/lists/debug: ad.powerpc Log Message: remove unneed arch64 keywords To generate a diff of this commit: cvs rdiff -u -r1.39 -r1.40 src/distrib/sets/lists/base/ad.powerpc cvs rdiff -u -r1.78 -r1.79 src/distrib/sets/lists/comp/ad.powerpc cvs rdiff -u -r1.39 -r1.40 src/distrib/sets/lists/debug/ad.powerpc 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/base/ad.powerpc diff -u src/distrib/sets/lists/base/ad.powerpc:1.39 src/distrib/sets/lists/base/ad.powerpc:1.40 --- src/distrib/sets/lists/base/ad.powerpc:1.39 Tue Jun 23 00:30:47 2015 +++ src/distrib/sets/lists/base/ad.powerpc Tue Jun 23 01:03:35 2015 @@ -1,4 +1,4 @@ -# $NetBSD: ad.powerpc,v 1.39 2015/06/23 00:30:47 matt Exp $ -./libexec/ld.elf_so-powerpc base-sysutil-bin compat,arch64,pic +# $NetBSD: ad.powerpc,v 1.40 2015/06/23 01:03:35 matt Exp $ +./libexec/ld.elf_so-powerpc base-sysutil-bin compat,pic ./usr/bin/fdformatbase-util-bin -./usr/libexec/ld.elf_so-powerpc base-sysutil-bin compat,arch64,pic +./usr/libexec/ld.elf_so-powerpc base-sysutil-bin compat,pic Index: src/distrib/sets/lists/comp/ad.powerpc diff -u src/distrib/sets/lists/comp/ad.powerpc:1.78 src/distrib/sets/lists/comp/ad.powerpc:1.79 --- src/distrib/sets/lists/comp/ad.powerpc:1.78 Tue Jun 23 00:30:47 2015 +++ src/distrib/sets/lists/comp/ad.powerpc Tue Jun 23 01:03:35 2015 @@ -1,14 +1,14 @@ -# $NetBSD: ad.powerpc,v 1.78 2015/06/23 00:30:47 matt Exp $ +# $NetBSD: ad.powerpc,v 1.79 2015/06/23 01:03:35 matt Exp $ ./usr/bin/elf2aoutcomp-sysutil-bin ./usr/bin/psim comp-debug-bin gdb ./usr/include/altivec.hcomp-obsolete obsolete ./usr/include/clang-3.4/altivec.h comp-obsolete obsolete ./usr/include/clang-3.5/altivec.h comp-obsolete obsolete ./usr/include/clang-3.6/altivec.h comp-c-include llvm -./usr/include/g++/bits/powerpc comp-c-include compat,arch64 -./usr/include/g++/bits/powerpc/c++config.h comp-c-include compat,arch64,gcc=48 -./usr/include/g++/bits/powerpc64 comp-c-include compat,arch64 -./usr/include/g++/bits/powerpc64/c++config.h comp-c-include compat,arch64,gcc=48 +./usr/include/g++/bits/powerpc comp-c-include compat +./usr/include/g++/bits/powerpc/c++config.h comp-c-include compat,gcc=48 +./usr/include/g++/bits/powerpc64 comp-c-include compat +./usr/include/g++/bits/powerpc64/c++config.h comp-c-include compat,gcc=48 ./usr/include/gcc-4.1/altivec.h comp-c-include gcccmds,gcc=4 ./usr/include/gcc-4.1/altivec.h comp-obsolete gcc=45,obsolete ./usr/include/gcc-4.1/altivec.h comp-obsolete gcc=48,obsolete Index: src/distrib/sets/lists/debug/ad.powerpc diff -u src/distrib/sets/lists/debug/ad.powerpc:1.39 src/distrib/sets/lists/debug/ad.powerpc:1.40 --- src/distrib/sets/lists/debug/ad.powerpc:1.39 Tue Jun 23 00:30:47 2015 +++ src/distrib/sets/lists/debug/ad.powerpc Tue Jun 23 01:03:35 2015 @@ -1,6 +1,6 @@ -# $NetBSD: ad.powerpc,v 1.39 2015/06/23 00:30:47 matt Exp $ -./usr/libdata/debug/libexec/ld.elf_so-powerpc.debug comp-sys-debug compat,arch64,debug +# $NetBSD: ad.powerpc,v 1.40 2015/06/23 01:03:35 matt Exp $ +./usr/libdata/debug/libexec/ld.elf_so-powerpc.debug comp-sys-debug compat,debug ./usr/libdata/debug/usr/bin/elf2aout.debug comp-sysutil-debug debug ./usr/libdata/debug/usr/bin/fdformat.debug comp-util-debug debug ./usr/libdata/debug/usr/bin/psim.debug comp-debug-debug debug,gdb -./usr/libdata/debug/usr/libexec/ld.elf_so-powerpc.debug comp-sys-debug compat,arch64,debug +./usr/libdata/debug/usr/libexec/ld.elf_so-powerpc.debug comp-sys-debug compat,debug
CVS commit: src/distrib/sets
Module Name:src Committed By: matt Date: Tue Jun 23 00:58:16 UTC 2015 Modified Files: src/distrib/sets: sets.subr Log Message: Fix spurious wantedness of compat, compattests, kmod, and compatmodules keywords. Be more consistent in names. To generate a diff of this commit: cvs rdiff -u -r1.166 -r1.167 src/distrib/sets/sets.subr 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/sets.subr diff -u src/distrib/sets/sets.subr:1.166 src/distrib/sets/sets.subr:1.167 --- src/distrib/sets/sets.subr:1.166 Mon Jun 22 07:07:10 2015 +++ src/distrib/sets/sets.subr Tue Jun 23 00:58:16 2015 @@ -1,4 +1,4 @@ -# $NetBSD: sets.subr,v 1.166 2015/06/22 07:07:10 matt Exp $ +# $NetBSD: sets.subr,v 1.167 2015/06/23 00:58:16 matt Exp $ # # @@ -179,7 +179,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g # In each file, a record consists of a path and a System Package name, # separated by whitespace. E.g., # -# # $NetBSD: sets.subr,v 1.166 2015/06/22 07:07:10 matt Exp $ +# # $NetBSD: sets.subr,v 1.167 2015/06/23 00:58:16 matt Exp $ # . base-sys-root [keyword[,...]] # ./altroot base-sys-root # ./bin base-sys-root @@ -292,7 +292,6 @@ list_set_files() print_set_lists "$@" | \ ${AWK} -v obsolete=${obsolete} ' BEGIN { - x="tmp.out" if (obsolete) wanted["obsolete"] = 1 @@ -309,11 +308,12 @@ list_set_files() sub(/^mk/, "", kw) sub(/^have_/, "", kw) sub(/^target_endianness/, "endian", kw) -if (nv != "HAVE_GCC" && nv != "HAVE_GDB" && ENVIRON[nv] != "no" && nv != "COMPATDIRS" && nv != "MODULEARCHDIRS") +if (nv != "HAVE_GCC" && nv != "HAVE_GDB" && ENVIRON[nv] != "no" && nv != "COMPATARCHDIRS" && nv != "KMODARCHDIRS") { wanted[kw] = 1 +} } - if (wanted["compat"]) { + if ("compat" in wanted) { doingcompat = 1; split("'"${COMPATARCHDIRS}"'", compatarchdirs, ","); compatdirkeywords["compatdir"] = 1 @@ -326,7 +326,7 @@ list_set_files() } } - if (wanted["kmod"] && wanted["compatmodules"]) { + if (("kmod" in wanted) && ("compatmodules" in wanted)) { split("'"${KMODARCHDIRS}"'", kmodarchdirs, ","); kmodpat = "./stand/" ENVIRON["MACHINE"] l_kmodpat = length(kmodpat) @@ -371,7 +371,7 @@ list_set_files() split($3, keywords, ",") show = 1 haveobs = 0 - havecompat = 0 + iscompatfile = 0 havekmod = 0 iscompatdir = 0 for (ki in keywords) { @@ -386,14 +386,13 @@ list_set_files() } else if (kw in compatdirkeywords) { iscompatdir = 1 } else if (kw in compatfilekeywords) { - havecompat = 1 + iscompatfile = 1 } else if (kw in ignoredkeywords) { # ignore -} else { - if (! (kw in wanted)) - show = 0 - else if (kw == "kmod") - havekmod = 1 +} else if (! (kw in wanted)) { + show = 0 +} else if (kw == "kmod") { + havekmod = 1 } if (kw == "obsolete") haveobs = 1 @@ -414,10 +413,10 @@ list_set_files() next } - if (!doingcompat || !(havecompat || iscompatdir)) + if (!doingcompat || !(iscompatfile || iscompatdir)) next - if (havecompat) { + if (iscompatfile) { emitcompat[$1] = 1; next; }
CVS commit: src/distrib/sets/lists
Module Name:src Committed By: matt Date: Tue Jun 23 00:30:47 UTC 2015 Modified Files: src/distrib/sets/lists/base: ad.powerpc src/distrib/sets/lists/comp: ad.powerpc src/distrib/sets/lists/debug: ad.powerpc Log Message: Remove autogenerated entries. To generate a diff of this commit: cvs rdiff -u -r1.38 -r1.39 src/distrib/sets/lists/base/ad.powerpc cvs rdiff -u -r1.77 -r1.78 src/distrib/sets/lists/comp/ad.powerpc cvs rdiff -u -r1.38 -r1.39 src/distrib/sets/lists/debug/ad.powerpc 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/base/ad.powerpc diff -u src/distrib/sets/lists/base/ad.powerpc:1.38 src/distrib/sets/lists/base/ad.powerpc:1.39 --- src/distrib/sets/lists/base/ad.powerpc:1.38 Mon Jun 22 19:11:00 2015 +++ src/distrib/sets/lists/base/ad.powerpc Tue Jun 23 00:30:47 2015 @@ -1,342 +1,4 @@ -# $NetBSD: ad.powerpc,v 1.38 2015/06/22 19:11:00 matt Exp $ -./lib/powerpc base-npf-shlib compat,arch64 -./lib/powerpc/npfbase-npf-shlib compat,arch64 -./lib/powerpc/npf/ext_log.so base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_log.so.0 base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_log.so.0.0 base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_normalize.so base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_normalize.so.0 base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_normalize.so.0.0 base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_rndblock.so base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_rndblock.so.0 base-npf-shlib compat,arch64,pic -./lib/powerpc/npf/ext_rndblock.so.0.0 base-npf-shlib compat,arch64,pic +# $NetBSD: ad.powerpc,v 1.39 2015/06/23 00:30:47 matt Exp $ ./libexec/ld.elf_so-powerpc base-sysutil-bin compat,arch64,pic ./usr/bin/fdformatbase-util-bin -./usr/lib/powerpcbase-compat-lib compat,arch64 -./usr/lib/powerpc/i18nbase-compat-lib compat,arch64 -./usr/lib/powerpc/i18n/libBIG5.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libBIG5.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libDECHanyu.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libDECHanyu.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libEUC.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libEUC.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libEUCTW.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libEUCTW.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libGBK2K.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libGBK2K.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libHZ.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libHZ.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libISO2022.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libISO2022.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libJOHAB.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libJOHAB.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libMSKanji.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libMSKanji.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUES.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUES.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF1632.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF1632.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF7.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF7.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF8.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libUTF8.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libVIQR.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libVIQR.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libZW.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libZW.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libiconv_none.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libiconv_none.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libiconv_std.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libiconv_std.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libmapper_646.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libmapper_646.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libmapper_none.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libmapper_none.so.5.0 base-i18n-shlib compat,arch64,pic -./usr/lib/powerpc/i18n/libmapper_parallel.so.5 base-i18n-shlib compat,arch64,pic -./usr/lib/pow
CVS commit: src/tests/lib/libc/db
Module Name:src Committed By: christos Date: Mon Jun 22 22:35:51 UTC 2015 Modified Files: src/tests/lib/libc/db: t_db_hash_seq.c Log Message: - don't create a db file. - add more tests. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libc/db/t_db_hash_seq.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/db/t_db_hash_seq.c diff -u src/tests/lib/libc/db/t_db_hash_seq.c:1.1 src/tests/lib/libc/db/t_db_hash_seq.c:1.2 --- src/tests/lib/libc/db/t_db_hash_seq.c:1.1 Mon Jun 22 15:06:05 2015 +++ src/tests/lib/libc/db/t_db_hash_seq.c Mon Jun 22 18:35:51 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: t_db_hash_seq.c,v 1.1 2015/06/22 19:06:05 christos Exp $ */ +/* $NetBSD: t_db_hash_seq.c,v 1.2 2015/06/22 22:35:51 christos Exp $ */ /*- * Copyright (c) 2015 The NetBSD Foundation, Inc. @@ -29,7 +29,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ #include -__RCSID("$NetBSD: t_db_hash_seq.c,v 1.1 2015/06/22 19:06:05 christos Exp $"); +__RCSID("$NetBSD: t_db_hash_seq.c,v 1.2 2015/06/22 22:35:51 christos Exp $"); #include #include @@ -248,7 +248,7 @@ testdb(int skip) struct conf c; struct dbinfo d; - db = state_open("foo", O_RDWR|O_CREAT|O_TRUNC, 0600); + db = state_open(NULL, O_RDWR|O_CREAT|O_TRUNC, 0600); if (db == NULL) DO_ERR("%s: cannot open `%s'", __func__, "foo"); @@ -267,7 +267,7 @@ testdb(int skip) if (flag[c.c_port]) DO_WARNX("Already visited %d", c.c_port); flag[c.c_port] = 1; - if (c.c_port % skip == 0) + if (skip == 0 || c.c_port % skip != 0) continue; state_del(db, &c); } @@ -287,21 +287,56 @@ main(int argc, char *argv[]) } #else -ATF_TC(test_hash_seq6); -ATF_TC_HEAD(test_hash_seq6, tc) +ATF_TC(test_hash_del_none); +ATF_TC_HEAD(test_hash_del_none, tc) { - atf_tc_set_md_var(tc, "descr", "Check sequential scan of hash tables with a skip factor of 6"); + atf_tc_set_md_var(tc, "descr", "Check sequential scan of hash tables deleting none"); } -ATF_TC_BODY(test_hash_seq6, tc) +ATF_TC_BODY(test_hash_del_none, tc) { - testdb(6); + testdb(0); +} + +ATF_TC(test_hash_del_all); +ATF_TC_HEAD(test_hash_del_all, tc) +{ + atf_tc_set_md_var(tc, "descr", "Check sequential scan of hash tables deleting all"); +} + +ATF_TC_BODY(test_hash_del_all, tc) +{ + testdb(1); +} + +ATF_TC(test_hash_del_alt); +ATF_TC_HEAD(test_hash_del_alt, tc) +{ + atf_tc_set_md_var(tc, "descr", "Check sequential scan of hash tables alternating deletets"); +} + +ATF_TC_BODY(test_hash_del_alt, tc) +{ + testdb(2); +} + +ATF_TC(test_hash_del_every_7); +ATF_TC_HEAD(test_hash_del_every_7, tc) +{ + atf_tc_set_md_var(tc, "descr", "Check sequential scan of hash tables deleting every 7 elements"); +} + +ATF_TC_BODY(test_hash_del_every_7, tc) +{ + testdb(7); } ATF_TP_ADD_TCS(tp) { - debug++; - ATF_TP_ADD_TC(tp, test_hash_seq6); + ATF_TP_ADD_TC(tp, test_hash_del_none); + ATF_TP_ADD_TC(tp, test_hash_del_all); + ATF_TP_ADD_TC(tp, test_hash_del_alt); + ATF_TP_ADD_TC(tp, test_hash_del_every_7); return 0; }
CVS commit: src/lib/libc/db/hash
Module Name:src Committed By: christos Date: Mon Jun 22 21:16:02 UTC 2015 Modified Files: src/lib/libc/db/hash: hash.c Log Message: Fix hash iteration that deletes the current element under the cursor by adjusting the position of the iterator appropriately. XXX: pullup 7 To generate a diff of this commit: cvs rdiff -u -r1.34 -r1.35 src/lib/libc/db/hash/hash.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/hash/hash.c diff -u src/lib/libc/db/hash/hash.c:1.34 src/lib/libc/db/hash/hash.c:1.35 --- src/lib/libc/db/hash/hash.c:1.34 Mon Jun 22 14:50:06 2015 +++ src/lib/libc/db/hash/hash.c Mon Jun 22 17:16:02 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: hash.c,v 1.34 2015/06/22 18:50:06 christos Exp $ */ +/* $NetBSD: hash.c,v 1.35 2015/06/22 21:16:02 christos Exp $ */ /*- * Copyright (c) 1990, 1993, 1994 @@ -37,7 +37,7 @@ #endif #include -__RCSID("$NetBSD: hash.c,v 1.34 2015/06/22 18:50:06 christos Exp $"); +__RCSID("$NetBSD: hash.c,v 1.35 2015/06/22 21:16:02 christos Exp $"); #include "namespace.h" #include @@ -690,6 +690,27 @@ found: case HASH_DELETE: if (__delpair(hashp, rbufp, ndx)) return (ERROR); + /* + * Our index lags 2 behind on the same page when we are + * deleting the element pointed to by the index; otherwise + * deleting randomly from an iterated hash produces undefined + * results. + */ + if (ndx != hashp->cndx - 2 || rbufp != hashp->cpage) + break; + + if (hashp->cndx > 1) { + /* Move back one element */ + hashp->cndx -= 2; + } else { + /* + * Move back one page, and indicate to go to the last + * element of the previous page by setting cndx to -1 + */ + hashp->cbucket--; + hashp->cpage = NULL; + hashp->cndx = -1; + } break; default: abort(); @@ -725,7 +746,7 @@ next_bucket: if (!(bufp = hashp->cpage)) { for (bucket = hashp->cbucket; bucket <= (uint32_t)hashp->MAX_BUCKET; - bucket++, hashp->cndx = 1) { + bucket++) { bufp = __get_buf(hashp, bucket, NULL, 0); if (!bufp) return (ERROR); @@ -739,10 +760,18 @@ next_bucket: hashp->cbucket = -1; return (ABNORMAL); } + if (hashp->cndx == -1) { +/* move to the last element of the page */ +hashp->cndx = 1; +while (bp[hashp->cndx - 1] != 0) + hashp->cndx += 2; + } else { +/* start on the first element */ +hashp->cndx = 1; + } } else { bp = (uint16_t *)(void *)hashp->cpage->page; if (flag == R_NEXT || flag == 0) { -hashp->cndx += 2; if (hashp->cndx > bp[0]) { hashp->cpage = NULL; hashp->cbucket++; @@ -781,6 +810,7 @@ next_bucket: data->data = (uint8_t *)hashp->cpage->page + bp[ndx + 1]; data->size = bp[ndx] - bp[ndx + 1]; } + hashp->cndx += 2; return (SUCCESS); }
CVS commit: src/distrib/sets/lists
Module Name:src Committed By: matt Date: Mon Jun 22 19:11:00 UTC 2015 Modified Files: src/distrib/sets/lists/base: ad.powerpc src/distrib/sets/lists/comp: ad.powerpc Log Message: Add missing arch64 to libasan entries To generate a diff of this commit: cvs rdiff -u -r1.37 -r1.38 src/distrib/sets/lists/base/ad.powerpc cvs rdiff -u -r1.76 -r1.77 src/distrib/sets/lists/comp/ad.powerpc 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/base/ad.powerpc diff -u src/distrib/sets/lists/base/ad.powerpc:1.37 src/distrib/sets/lists/base/ad.powerpc:1.38 --- src/distrib/sets/lists/base/ad.powerpc:1.37 Fri May 29 12:28:08 2015 +++ src/distrib/sets/lists/base/ad.powerpc Mon Jun 22 19:11:00 2015 @@ -1,4 +1,4 @@ -# $NetBSD: ad.powerpc,v 1.37 2015/05/29 12:28:08 christos Exp $ +# $NetBSD: ad.powerpc,v 1.38 2015/06/22 19:11:00 matt Exp $ ./lib/powerpc base-npf-shlib compat,arch64 ./lib/powerpc/npfbase-npf-shlib compat,arch64 ./lib/powerpc/npf/ext_log.so base-npf-shlib compat,arch64,pic @@ -64,8 +64,8 @@ ./usr/lib/powerpc/libamu.so.5.0 base-compat-shlib compat,arch64,pic ./usr/lib/powerpc/libarchive.so.3 base-compat-shlib compat,arch64,pic ./usr/lib/powerpc/libarchive.so.3.1 base-compat-shlib compat,arch64,pic -./usr/lib/powerpc/libasan.so.0 base-compat-shlib compat,pic,gcc=48 -./usr/lib/powerpc/libasan.so.0.0 base-compat-shlib compat,pic,gcc=48 +./usr/lib/powerpc/libasan.so.0 base-compat-shlib compat,arch64,pic,gcc=48 +./usr/lib/powerpc/libasan.so.0.0 base-compat-shlib compat,arch64,pic,gcc=48 ./usr/lib/powerpc/libasn1.so.9 base-compat-shlib compat,arch64,pic,kerberos ./usr/lib/powerpc/libasn1.so.9.0 base-compat-shlib compat,arch64,pic,kerberos ./usr/lib/powerpc/libatf-c++.so.1 base-compat-shlib compat,arch64,pic,atf Index: src/distrib/sets/lists/comp/ad.powerpc diff -u src/distrib/sets/lists/comp/ad.powerpc:1.76 src/distrib/sets/lists/comp/ad.powerpc:1.77 --- src/distrib/sets/lists/comp/ad.powerpc:1.76 Sun Jan 25 15:50:30 2015 +++ src/distrib/sets/lists/comp/ad.powerpc Mon Jun 22 19:11:00 2015 @@ -1,4 +1,4 @@ -# $NetBSD: ad.powerpc,v 1.76 2015/01/25 15:50:30 christos Exp $ +# $NetBSD: ad.powerpc,v 1.77 2015/06/22 19:11:00 matt Exp $ ./usr/bin/elf2aoutcomp-sysutil-bin ./usr/bin/psim comp-debug-bin gdb ./usr/include/altivec.hcomp-obsolete obsolete @@ -170,10 +170,10 @@ ./usr/lib/powerpc/libarchive.so base-sys-shlib compat,arch64,pic ./usr/lib/powerpc/libarchive_p.a comp-c-proflib compat,arch64,profile ./usr/lib/powerpc/libarchive_pic.a comp-c-piclib compat,arch64,pic,picinstall -./usr/lib/powerpc/libasan.a comp-c-lib compat,gcc=48 -./usr/lib/powerpc/libasan.so base-sys-shlib compat,pic,gcc=48 -./usr/lib/powerpc/libasan_p.a comp-c-proflib compat,profile,gcc=48 -./usr/lib/powerpc/libasan_pic.a comp-c-piclib compat,pic,picinstall,gcc=48 +./usr/lib/powerpc/libasan.a comp-c-lib compat,arch64,gcc=48 +./usr/lib/powerpc/libasan.so base-sys-shlib compat,arch64,pic,gcc=48 +./usr/lib/powerpc/libasan_p.a comp-c-proflib compat,arch64,profile,gcc=48 +./usr/lib/powerpc/libasan_pic.a comp-c-piclib compat,arch64,pic,picinstall,gcc=48 ./usr/lib/powerpc/libasn1.a comp-c-lib compat,arch64,kerberos ./usr/lib/powerpc/libasn1.so base-sys-shlib compat,arch64,pic,kerberos ./usr/lib/powerpc/libasn1_p.a comp-c-proflib compat,arch64,profile,kerberos
CVS commit: src/distrib/sets/lists
Module Name:src Committed By: christos Date: Mon Jun 22 19:10:14 UTC 2015 Modified Files: src/distrib/sets/lists/debug: mi src/distrib/sets/lists/tests: mi Log Message: add new db test To generate a diff of this commit: cvs rdiff -u -r1.117 -r1.118 src/distrib/sets/lists/debug/mi cvs rdiff -u -r1.628 -r1.629 src/distrib/sets/lists/tests/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/debug/mi diff -u src/distrib/sets/lists/debug/mi:1.117 src/distrib/sets/lists/debug/mi:1.118 --- src/distrib/sets/lists/debug/mi:1.117 Mon Jun 22 02:02:02 2015 +++ src/distrib/sets/lists/debug/mi Mon Jun 22 15:10:13 2015 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.117 2015/06/22 06:02:02 matt Exp $ +# $NetBSD: mi,v 1.118 2015/06/22 19:10:13 christos Exp $ ./etc/mtree/set.debug comp-sys-root ./usr/lib/i18n/libBIG5_g.a comp-c-debuglib debuglib,compatfile @@ -1820,6 +1820,7 @@ ./usr/libdata/debug/usr/tests/lib/libc/c063/t_unlinkat.debug tests-lib-debug debug,atf,compattestfile ./usr/libdata/debug/usr/tests/lib/libc/c063/t_utimensat.debug tests-lib-debug debug,atf,compattestfile ./usr/libdata/debug/usr/tests/lib/libc/db/h_db.debug tests-lib-debug debug,atf,compattestfile +./usr/libdata/debug/usr/tests/lib/libc/db/t_db_hash_seq.debug tests-lib-debug debug,atf,compattestfile ./usr/libdata/debug/usr/tests/lib/libc/gen/execve/t_execve.debug tests-kernel-tests debug,atf,compattestfile ./usr/libdata/debug/usr/tests/lib/libc/gen/posix_spawn/h_fileactions.debug tests-kernel-tests debug,atf,compattestfile ./usr/libdata/debug/usr/tests/lib/libc/gen/posix_spawn/h_spawn.debug tests-kernel-tests debug,atf,compattestfile Index: src/distrib/sets/lists/tests/mi diff -u src/distrib/sets/lists/tests/mi:1.628 src/distrib/sets/lists/tests/mi:1.629 --- src/distrib/sets/lists/tests/mi:1.628 Mon Jun 22 02:02:02 2015 +++ src/distrib/sets/lists/tests/mi Mon Jun 22 15:10:14 2015 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.628 2015/06/22 06:02:02 matt Exp $ +# $NetBSD: mi,v 1.629 2015/06/22 19:10:14 christos Exp $ # # Note: don't delete entries from here - mark them as "obsolete" instead. # @@ -2359,6 +2359,7 @@ ./usr/tests/lib/libc/db/README tests-lib-tests compattestfile,atf ./usr/tests/lib/libc/db/h_db tests-lib-tests compattestfile,atf ./usr/tests/lib/libc/db/t_db tests-lib-tests compattestfile,atf +./usr/tests/lib/libc/db/t_db_hash_seq tests-lib-tests compattestfile,atf ./usr/tests/lib/libc/gen tests-lib-tests compattestfile,atf ./usr/tests/lib/libc/gen/Atffile tests-lib-tests compattestfile,atf ./usr/tests/lib/libc/gen/Kyuafile tests-lib-tests compattestfile,atf,kyua
CVS commit: src/distrib/sets/lists/modules
Module Name:src Committed By: matt Date: Mon Jun 22 19:08:14 UTC 2015 Removed Files: src/distrib/sets/lists/modules: md.evbppc.powerpc Log Message: No longer needed To generate a diff of this commit: cvs rdiff -u -r1.9 -r0 src/distrib/sets/lists/modules/md.evbppc.powerpc Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/tests/lib/libc/db
Module Name:src Committed By: christos Date: Mon Jun 22 19:06:06 UTC 2015 Modified Files: src/tests/lib/libc/db: Makefile Added Files: src/tests/lib/libc/db: t_db_hash_seq.c Log Message: Add new failing test. To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libc/db/Makefile cvs rdiff -u -r0 -r1.1 src/tests/lib/libc/db/t_db_hash_seq.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/db/Makefile diff -u src/tests/lib/libc/db/Makefile:1.1 src/tests/lib/libc/db/Makefile:1.2 --- src/tests/lib/libc/db/Makefile:1.1 Fri Jan 7 10:05:58 2011 +++ src/tests/lib/libc/db/Makefile Mon Jun 22 15:06:05 2015 @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.1 2011/01/07 15:05:58 pgoyette Exp $ +# $NetBSD: Makefile,v 1.2 2015/06/22 19:06:05 christos Exp $ .include @@ -6,6 +6,8 @@ TESTSDIR= ${TESTSBASE}/lib/libc/db TESTS_SH+= t_db +TESTS_C+= t_db_hash_seq + BINDIR= ${TESTSDIR} MKMAN= no Added files: Index: src/tests/lib/libc/db/t_db_hash_seq.c diff -u /dev/null src/tests/lib/libc/db/t_db_hash_seq.c:1.1 --- /dev/null Mon Jun 22 15:06:06 2015 +++ src/tests/lib/libc/db/t_db_hash_seq.c Mon Jun 22 15:06:05 2015 @@ -0,0 +1,308 @@ +/* $NetBSD: t_db_hash_seq.c,v 1.1 2015/06/22 19:06:05 christos Exp $ */ + +/*- + * Copyright (c) 2015 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Christos Zoulas. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ +#include +__RCSID("$NetBSD: t_db_hash_seq.c,v 1.1 2015/06/22 19:06:05 christos Exp $"); + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define ATF + +struct conf { + struct sockaddr_storage c_ss; + int c_lmask; + int c_port; + int c_proto; + int c_family; + int c_uid; + int c_nfail; + char c_name[128]; + int c_rmask; + int c_duration; +}; + +struct dbinfo { + int count; + time_t last; + char id[64]; +}; + +#ifdef ATF +#include + +#define DO_ERR(msg, ...) ATF_REQUIRE_MSG(0, msg, __VA_ARGS__) +#define DO_WARNX(msg, ...) ATF_REQUIRE_MSG(0, msg, __VA_ARGS__) +#else +#include + +#define DO_ERR(fmt, ...) err(EXIT_FAILURE, fmt, __VA_ARGS__) +#define DO_WARNX(fmt, ...) warnx(fmt, __VA_ARGS__) +#endif + +#define DO_DEBUG(fmt, ...) fprintf(stderr, fmt, __VA_ARGS__) + +static HASHINFO openinfo = { + 4096, /* bsize */ + 32, /* ffactor */ + 256, /* nelem */ + 8 * 1024 * 1024,/* cachesize */ + NULL, /* hash() */ + 0 /* lorder */ +}; + +static int debug = 0; + +static int +state_close(DB *db) +{ + if (db == NULL) + return -1; + if ((*db->close)(db) == -1) + DO_ERR("%s: can't close db", __func__); + return 0; +} + +static DB * +state_open(const char *dbname, int flags, mode_t perm) +{ + DB *db; + + db = dbopen(dbname, flags, perm, DB_HASH, &openinfo); + if (db == NULL) { + if (errno == ENOENT && (flags & O_CREAT) == 0) + return NULL; + DO_ERR("%s: can't open `%s'", __func__, dbname); + } + return db; +} + +static int +state_sizecheck(const DBT *t) +{ + if (sizeof(struct conf) == t->size) + return 0; + DO_WARNX("Key size mismatch %zu != %zu", sizeof(struct conf), t->size); + return 0; +} + +static int +state_del(DB *db, const struct conf *c) +{ + int rv; + DBT k; + + if (db == NULL) + return -1; + + k.data = __UNCONST(c); + k.size = sizeof(*c); + + switch (rv = (*db->del)(db, &k, 1)) { + case 0: + case 1: + if (debug > 1) { + DO_DEBUG("%s: returns %d", __func__, rv); + (*db->sync)(db, 0); + } + return 0; + default: + DO_ERR("%s: failed", __func__); + return -1; + } +} + +#if
CVS commit: src/distrib/sets
Module Name:src Committed By: matt Date: Mon Jun 22 19:04:21 UTC 2015 Modified Files: src/distrib/sets: mkvars.mk Log Message: Don't put COMPATARCHDIRS or KMODARCHDIRS since we handle them explicitly. To generate a diff of this commit: cvs rdiff -u -r1.21 -r1.22 src/distrib/sets/mkvars.mk 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/mkvars.mk diff -u src/distrib/sets/mkvars.mk:1.21 src/distrib/sets/mkvars.mk:1.22 --- src/distrib/sets/mkvars.mk:1.21 Mon Jun 22 14:17:04 2015 +++ src/distrib/sets/mkvars.mk Mon Jun 22 19:04:21 2015 @@ -1,4 +1,4 @@ -# $NetBSD: mkvars.mk,v 1.21 2015/06/22 14:17:04 matt Exp $ +# $NetBSD: mkvars.mk,v 1.22 2015/06/22 19:04:21 matt Exp $ MKEXTRAVARS= \ MACHINE \ @@ -32,9 +32,7 @@ MKEXTRAVARS= \ MAKEVERBOSE \ TARGET_ENDIANNESS \ EABI \ - ARCH64 \ - COMPATARCHDIRS \ - KMODARCHDIRS + ARCH64 # @@ -98,9 +96,13 @@ mkextravars: .PHONY .endfor .if ${MKCOMPAT} != "no" @echo COMPATARCHDIRS=${COMPATARCHDIRS} | ${TOOL_SED} -e's/ /,/' +.else + @echo COMPATARCHDIRS= .endif .if ${MKKMOD} != "no" && ${MKCOMPATMODULES} != "no" @echo KMODARCHDIRS=${KMODARCHDIRS} | ${TOOL_SED} -e's/ /,/' +.else + @echo KMODARCHDIRS= .endif mksolaris: .PHONY
CVS commit: src/lib/libc/db/hash
Module Name:src Committed By: christos Date: Mon Jun 22 18:50:06 UTC 2015 Modified Files: src/lib/libc/db/hash: hash.c Log Message: Delay moving to the next key until the next iteration. This avoids returning invalid data to the user if the user deletes the current key, but it also fails to iterate over some keys as will be shown by a unit test. From FreeBSD. To generate a diff of this commit: cvs rdiff -u -r1.33 -r1.34 src/lib/libc/db/hash/hash.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/hash/hash.c diff -u src/lib/libc/db/hash/hash.c:1.33 src/lib/libc/db/hash/hash.c:1.34 --- src/lib/libc/db/hash/hash.c:1.33 Sat Nov 30 19:22:48 2013 +++ src/lib/libc/db/hash/hash.c Mon Jun 22 14:50:06 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: hash.c,v 1.33 2013/12/01 00:22:48 christos Exp $ */ +/* $NetBSD: hash.c,v 1.34 2015/06/22 18:50:06 christos Exp $ */ /*- * Copyright (c) 1990, 1993, 1994 @@ -37,7 +37,7 @@ #endif #include -__RCSID("$NetBSD: hash.c,v 1.33 2013/12/01 00:22:48 christos Exp $"); +__RCSID("$NetBSD: hash.c,v 1.34 2015/06/22 18:50:06 christos Exp $"); #include "namespace.h" #include @@ -720,6 +720,7 @@ hash_seq(const DB *dbp, DBT *key, DBT *d hashp->cpage = NULL; } +next_bucket: for (bp = NULL; !bp || !bp[0]; ) { if (!(bufp = hashp->cpage)) { for (bucket = hashp->cbucket; @@ -738,8 +739,19 @@ hash_seq(const DB *dbp, DBT *key, DBT *d hashp->cbucket = -1; return (ABNORMAL); } - } else + } else { bp = (uint16_t *)(void *)hashp->cpage->page; + if (flag == R_NEXT || flag == 0) { +hashp->cndx += 2; +if (hashp->cndx > bp[0]) { + hashp->cpage = NULL; + hashp->cbucket++; + hashp->cndx = 1; + goto next_bucket; +} + } + } + _DIAGASSERT(bp != NULL); _DIAGASSERT(bufp != NULL); @@ -768,13 +780,6 @@ hash_seq(const DB *dbp, DBT *key, DBT *d key->size = (ndx > 1 ? bp[ndx - 1] : hashp->BSIZE) - bp[ndx]; data->data = (uint8_t *)hashp->cpage->page + bp[ndx + 1]; data->size = bp[ndx] - bp[ndx + 1]; - ndx += 2; - if (ndx > bp[0]) { - hashp->cpage = NULL; - hashp->cbucket++; - hashp->cndx = 1; - } else - hashp->cndx = ndx; } return (SUCCESS); }
CVS commit: src/lib/libc/time
Module Name:src Committed By: christos Date: Mon Jun 22 17:43:23 UTC 2015 Modified Files: src/lib/libc/time: private.h Log Message: don't define statics we don't need To generate a diff of this commit: cvs rdiff -u -r1.41 -r1.42 src/lib/libc/time/private.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/time/private.h diff -u src/lib/libc/time/private.h:1.41 src/lib/libc/time/private.h:1.42 --- src/lib/libc/time/private.h:1.41 Sun Jun 21 12:06:51 2015 +++ src/lib/libc/time/private.h Mon Jun 22 13:43:23 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: private.h,v 1.41 2015/06/21 16:06:51 christos Exp $ */ +/* $NetBSD: private.h,v 1.42 2015/06/22 17:43:23 christos Exp $ */ #ifndef PRIVATE_H #define PRIVATE_H @@ -501,9 +501,11 @@ time_t time2posix_z(timezone_t __restric #define MINVAL(t, b) \ ((t) (TYPE_SIGNED(t) ? - TWOS_COMPLEMENT(t) - MAXVAL(t, b) : 0)) +#ifdef LOCALTIME_IMPLEMENTATION /* The minimum and maximum finite time values. This assumes no padding. */ static time_t const time_t_min = MINVAL(time_t, TYPE_BIT(time_t)); static time_t const time_t_max = MAXVAL(time_t, TYPE_BIT(time_t)); +#endif #ifndef INT_STRLEN_MAXIMUM /*
CVS commit: src/sys
Module Name:src Committed By: matt Date: Mon Jun 22 16:35:13 UTC 2015 Modified Files: src/sys/kern: kern_module.c src/sys/sys: module.h Log Message: Make module_machine const char * To generate a diff of this commit: cvs rdiff -u -r1.105 -r1.106 src/sys/kern/kern_module.c cvs rdiff -u -r1.37 -r1.38 src/sys/sys/module.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/kern/kern_module.c diff -u src/sys/kern/kern_module.c:1.105 src/sys/kern/kern_module.c:1.106 --- src/sys/kern/kern_module.c:1.105 Sun Mar 8 01:17:42 2015 +++ src/sys/kern/kern_module.c Mon Jun 22 16:35:13 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_module.c,v 1.105 2015/03/08 01:17:42 christos Exp $ */ +/* $NetBSD: kern_module.c,v 1.106 2015/06/22 16:35:13 matt Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -34,7 +34,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.105 2015/03/08 01:17:42 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.106 2015/06/22 16:35:13 matt Exp $"); #define _MODULE_INTERNAL @@ -58,7 +58,7 @@ __KERNEL_RCSID(0, "$NetBSD: kern_module. #include struct vm_map *module_map; -char *module_machine; +const char *module_machine; char module_base[MODULE_BASE_SIZE]; struct modlistmodule_list = TAILQ_HEAD_INITIALIZER(module_list); Index: src/sys/sys/module.h diff -u src/sys/sys/module.h:1.37 src/sys/sys/module.h:1.38 --- src/sys/sys/module.h:1.37 Fri Jun 19 14:23:59 2015 +++ src/sys/sys/module.h Mon Jun 22 16:35:13 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: module.h,v 1.37 2015/06/19 14:23:59 martin Exp $ */ +/* $NetBSD: module.h,v 1.38 2015/06/22 16:35:13 matt Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -185,7 +185,7 @@ void module_print(const char *, ...) __p #define MODULE_BASE_SIZE 64 extern char module_base[MODULE_BASE_SIZE]; -extern char *module_machine; +extern const char *module_machine; #else /* _KERNEL */
CVS commit: src/distrib/sets
Module Name:src Committed By: matt Date: Mon Jun 22 14:17:04 UTC 2015 Modified Files: src/distrib/sets: mkvars.mk Log Message: Need to check MKCOMPATMODULES as well. To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/distrib/sets/mkvars.mk 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/mkvars.mk diff -u src/distrib/sets/mkvars.mk:1.20 src/distrib/sets/mkvars.mk:1.21 --- src/distrib/sets/mkvars.mk:1.20 Mon Jun 22 08:51:42 2015 +++ src/distrib/sets/mkvars.mk Mon Jun 22 14:17:04 2015 @@ -1,4 +1,4 @@ -# $NetBSD: mkvars.mk,v 1.20 2015/06/22 08:51:42 martin Exp $ +# $NetBSD: mkvars.mk,v 1.21 2015/06/22 14:17:04 matt Exp $ MKEXTRAVARS= \ MACHINE \ @@ -53,7 +53,7 @@ ARCHDIR_SUBDIR:= COMPATARCHDIRS:=${ARCHDIR_SUBDIR:T} .endif -.if ${MKKMOD} != "no" +.if ${MKKMOD} != "no" && ${MKCOMPATMODULES} != "no" ARCHDIR_SUBDIR:= .include "${NETBSDSRCDIR}/sys/modules/arch/archdirs.mk" KMODARCHDIRS:=${ARCHDIR_SUBDIR:T} @@ -99,7 +99,7 @@ mkextravars: .PHONY .if ${MKCOMPAT} != "no" @echo COMPATARCHDIRS=${COMPATARCHDIRS} | ${TOOL_SED} -e's/ /,/' .endif -.if ${MKKMOD} != "no" +.if ${MKKMOD} != "no" && ${MKCOMPATMODULES} != "no" @echo KMODARCHDIRS=${KMODARCHDIRS} | ${TOOL_SED} -e's/ /,/' .endif
CVS commit: src/sys
Module Name:src Committed By: mrg Date: Mon Jun 22 10:35:00 UTC 2015 Modified Files: src/sys/compat/netbsd32: files.netbsd32 netbsd32.h netbsd32_conv.h netbsd32_syscall.h netbsd32_syscallargs.h netbsd32_syscalls.c netbsd32_sysent.c netbsd32_systrace_args.c syscalls.master src/sys/nfs: nfs_syscalls.c nfs_var.h Added Files: src/sys/compat/netbsd32: netbsd32_nfssvc.c Log Message: add netbsd32 support for nfssvc(2). we do this by defining 5 copyin/out functions that do all the ugly work, are just plain copyin/out for the native system calls, and do the necessary translations for netbsd32. with this i'm able to run 32 bit nfsd and mountd on 64 bit kernel and mount the file systems remotely. To generate a diff of this commit: cvs rdiff -u -r1.35 -r1.36 src/sys/compat/netbsd32/files.netbsd32 cvs rdiff -u -r1.106 -r1.107 src/sys/compat/netbsd32/netbsd32.h cvs rdiff -u -r1.29 -r1.30 src/sys/compat/netbsd32/netbsd32_conv.h cvs rdiff -u -r0 -r1.1 src/sys/compat/netbsd32/netbsd32_nfssvc.c cvs rdiff -u -r1.115 -r1.116 src/sys/compat/netbsd32/netbsd32_syscall.h \ src/sys/compat/netbsd32/netbsd32_syscallargs.h cvs rdiff -u -r1.114 -r1.115 src/sys/compat/netbsd32/netbsd32_syscalls.c \ src/sys/compat/netbsd32/netbsd32_sysent.c cvs rdiff -u -r1.5 -r1.6 src/sys/compat/netbsd32/netbsd32_systrace_args.c cvs rdiff -u -r1.107 -r1.108 src/sys/compat/netbsd32/syscalls.master cvs rdiff -u -r1.155 -r1.156 src/sys/nfs/nfs_syscalls.c cvs rdiff -u -r1.92 -r1.93 src/sys/nfs/nfs_var.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/files.netbsd32 diff -u src/sys/compat/netbsd32/files.netbsd32:1.35 src/sys/compat/netbsd32/files.netbsd32:1.36 --- src/sys/compat/netbsd32/files.netbsd32:1.35 Sat Jun 20 19:58:40 2015 +++ src/sys/compat/netbsd32/files.netbsd32 Mon Jun 22 10:35:00 2015 @@ -1,4 +1,4 @@ -# $NetBSD: files.netbsd32,v 1.35 2015/06/20 19:58:40 martin Exp $ +# $NetBSD: files.netbsd32,v 1.36 2015/06/22 10:35:00 mrg Exp $ # # config file description for machine-independent netbsd32 compat code. # included by ports that need it. @@ -20,6 +20,7 @@ file compat/netbsd32/netbsd32_lwp.c com file compat/netbsd32/netbsd32_module.c compat_netbsd32 file compat/netbsd32/netbsd32_mod.c compat_netbsd32 file compat/netbsd32/netbsd32_mqueue.c compat_netbsd32 +file compat/netbsd32/netbsd32_nfssvc.c compat_netbsd32 & nfsserver file compat/netbsd32/netbsd32_select.c compat_netbsd32 file compat/netbsd32/netbsd32_sem.c compat_netbsd32 file compat/netbsd32/netbsd32_signal.c compat_netbsd32 Index: src/sys/compat/netbsd32/netbsd32.h diff -u src/sys/compat/netbsd32/netbsd32.h:1.106 src/sys/compat/netbsd32/netbsd32.h:1.107 --- src/sys/compat/netbsd32/netbsd32.h:1.106 Sun Jun 21 14:03:38 2015 +++ src/sys/compat/netbsd32/netbsd32.h Mon Jun 22 10:35:00 2015 @@ -1,7 +1,7 @@ -/* $NetBSD: netbsd32.h,v 1.106 2015/06/21 14:03:38 mrg Exp $ */ +/* $NetBSD: netbsd32.h,v 1.107 2015/06/22 10:35:00 mrg Exp $ */ /* - * Copyright (c) 1998, 2001, 2008 Matthew R. Green + * Copyright (c) 1998, 2001, 2008, 2015 Matthew R. Green * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -50,6 +50,8 @@ #include #include +#include + /* * first, define the basic types we need. */ @@ -945,6 +947,48 @@ struct netbsd32_mfs_args { netbsd32_u_long size; }; +/* from */ +struct netbsd32_nfsd_args { + int sock; + netbsd32_voidp name; + int namelen; +}; + +typedef netbsd32_pointer_t netbsd32_nfsdp; +struct netbsd32_nfsd_srvargs { + netbsd32_nfsdp nsd_nfsd; + uid_t nsd_uid; + u_int32_t nsd_haddr; + struct uucred nsd_cr; + int nsd_authlen; + netbsd32_u_charp nsd_authstr; + int nsd_verflen; + netbsd32_u_charp nsd_verfstr; + struct netbsd32_timeval nsd_timestamp; + u_int32_t nsd_ttl; + NFSKERBKEY_T nsd_key; +}; + +typedef netbsd32_pointer_t netbsd32_export_argsp; +struct netbsd32_export_args { + int ex_flags; + uid_t ex_root; + struct uucred ex_anon; + netbsd32_sockaddrp_t ex_addr; + int ex_addrlen; + netbsd32_sockaddrp_t ex_mask; + int ex_masklen; + netbsd32_charp ex_indexfile; +}; + +struct netbsd32_mountd_exports_list { + const netbsd32_charp mel_path; + netbsd32_size_t mel_nexports; + netbsd32_export_argsp mel_exports; +}; + +/* no struct export_args30 yet */ + /* from */ struct netbsd32_nfs_args { int32_t version; /* args structure version number */ @@ -966,6 +1010,8 @@ struct netbsd32_nfs_args { int32_t deadthresh; /* Retrans threshold */ netbsd32_charp hostname; /* server's name */ }; + +/* from */ struct netbsd32_msdosfs_args { netbsd32_charp fspec; /* blocks special holding the fs to mount */ struct netbsd32_export_args30 _pad1; /* compat with old userland tools */ Index: src/sys/compat/netbsd32/netbsd32_conv.h diff -u src/sys/compat/netbsd32/netbsd32_conv.h:1.29 src/sys/compat/netbsd32/netbsd3
CVS commit: src/distrib/sets
Module Name:src Committed By: martin Date: Mon Jun 22 08:51:42 UTC 2015 Modified Files: src/distrib/sets: mkvars.mk Log Message: Force ARCHDIR_SUBDIR to empty before including some archdirs.mk - the different files may set different values (or none at all). Example: earm has "oabi" as compat, but none as module subdir. To generate a diff of this commit: cvs rdiff -u -r1.19 -r1.20 src/distrib/sets/mkvars.mk 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/mkvars.mk diff -u src/distrib/sets/mkvars.mk:1.19 src/distrib/sets/mkvars.mk:1.20 --- src/distrib/sets/mkvars.mk:1.19 Mon Jun 22 05:59:59 2015 +++ src/distrib/sets/mkvars.mk Mon Jun 22 08:51:42 2015 @@ -1,4 +1,4 @@ -# $NetBSD: mkvars.mk,v 1.19 2015/06/22 05:59:59 matt Exp $ +# $NetBSD: mkvars.mk,v 1.20 2015/06/22 08:51:42 martin Exp $ MKEXTRAVARS= \ MACHINE \ @@ -48,11 +48,13 @@ MKMANPAGES=yes .endif .if ${MKCOMPAT} != "no" +ARCHDIR_SUBDIR:= .include "${NETBSDSRCDIR}/compat/archdirs.mk" COMPATARCHDIRS:=${ARCHDIR_SUBDIR:T} .endif .if ${MKKMOD} != "no" +ARCHDIR_SUBDIR:= .include "${NETBSDSRCDIR}/sys/modules/arch/archdirs.mk" KMODARCHDIRS:=${ARCHDIR_SUBDIR:T} .endif
CVS commit: src/sys/arch/x86/x86
Module Name:src Committed By: msaitoh Date: Mon Jun 22 07:26:52 UTC 2015 Modified Files: src/sys/arch/x86/x86: mpacpi.c Log Message: Fix wrong output in mpacpi_pci_foundbus() with MPVERBOSE. Assign vaues before printing them. To generate a diff of this commit: cvs rdiff -u -r1.97 -r1.98 src/sys/arch/x86/x86/mpacpi.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/x86/x86/mpacpi.c diff -u src/sys/arch/x86/x86/mpacpi.c:1.97 src/sys/arch/x86/x86/mpacpi.c:1.98 --- src/sys/arch/x86/x86/mpacpi.c:1.97 Mon Mar 25 01:30:37 2013 +++ src/sys/arch/x86/x86/mpacpi.c Mon Jun 22 07:26:52 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: mpacpi.c,v 1.97 2013/03/25 01:30:37 chs Exp $ */ +/* $NetBSD: mpacpi.c,v 1.98 2015/06/22 07:26:52 msaitoh Exp $ */ /* * Copyright (c) 2003 Wasabi Systems, Inc. @@ -36,7 +36,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: mpacpi.c,v 1.97 2013/03/25 01:30:37 chs Exp $"); +__KERNEL_RCSID(0, "$NetBSD: mpacpi.c,v 1.98 2015/06/22 07:26:52 msaitoh Exp $"); #include "acpica.h" #include "opt_acpi.h" @@ -495,6 +495,12 @@ mpacpi_pci_foundbus(struct acpi_devnode } mpr = kmem_zalloc(sizeof(struct mpacpi_pcibus), KM_SLEEP); + mpr->mpr_handle = ad->ad_handle; + mpr->mpr_buf = buf; + mpr->mpr_seg = ad->ad_pciinfo->ap_segment; + mpr->mpr_bus = ad->ad_pciinfo->ap_downbus; + TAILQ_INSERT_TAIL(&mpacpi_pcibusses, mpr, mpr_list); + if ((ad->ad_devinfo->Flags & ACPI_PCI_ROOT_BRIDGE) != 0) { if (mp_verbose) printf("mpacpi: found root PCI bus %d\n", @@ -506,12 +512,6 @@ mpacpi_pci_foundbus(struct acpi_devnode mpr->mpr_bus); } - mpr->mpr_handle = ad->ad_handle; - mpr->mpr_buf = buf; - mpr->mpr_seg = ad->ad_pciinfo->ap_segment; - mpr->mpr_bus = ad->ad_pciinfo->ap_downbus; - TAILQ_INSERT_TAIL(&mpacpi_pcibusses, mpr, mpr_list); - /* * XXX this wrongly assumes that bus numbers are unique * even between segments.
CVS commit: src/distrib/sets
Module Name:src Committed By: matt Date: Mon Jun 22 07:07:10 UTC 2015 Modified Files: src/distrib/sets: sets.subr Log Message: Rework a little. test MKCOMPATMODULES for KMOD entry autogeneration. To generate a diff of this commit: cvs rdiff -u -r1.165 -r1.166 src/distrib/sets/sets.subr 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/sets.subr diff -u src/distrib/sets/sets.subr:1.165 src/distrib/sets/sets.subr:1.166 --- src/distrib/sets/sets.subr:1.165 Mon Jun 22 05:59:59 2015 +++ src/distrib/sets/sets.subr Mon Jun 22 07:07:10 2015 @@ -1,4 +1,4 @@ -# $NetBSD: sets.subr,v 1.165 2015/06/22 05:59:59 matt Exp $ +# $NetBSD: sets.subr,v 1.166 2015/06/22 07:07:10 matt Exp $ # # @@ -179,7 +179,7 @@ SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g # In each file, a record consists of a path and a System Package name, # separated by whitespace. E.g., # -# # $NetBSD: sets.subr,v 1.165 2015/06/22 05:59:59 matt Exp $ +# # $NetBSD: sets.subr,v 1.166 2015/06/22 07:07:10 matt Exp $ # . base-sys-root [keyword[,...]] # ./altroot base-sys-root # ./bin base-sys-root @@ -309,23 +309,27 @@ list_set_files() sub(/^mk/, "", kw) sub(/^have_/, "", kw) sub(/^target_endianness/, "endian", kw) -if (kw == "compat" && ENVIRON[nv] != "no") { - doingcompat = 1; - split("'"${COMPATARCHDIRS}"'", compatarchdirs, ","); +if (nv != "HAVE_GCC" && nv != "HAVE_GDB" && ENVIRON[nv] != "no" && nv != "COMPATDIRS" && nv != "MODULEARCHDIRS") wanted[kw] = 1 - compatdirkeywords["compatdir"] = 1 - compatfilekeywords["compatfile"] = 1 -} else if (kw == "compattests" && ENVIRON[nv] != "no") { + } + + if (wanted["compat"]) { +doingcompat = 1; +split("'"${COMPATARCHDIRS}"'", compatarchdirs, ","); +compatdirkeywords["compatdir"] = 1 +compatfilekeywords["compatfile"] = 1 + +if (wanted["compattests"]) { doingcompattests = 1; compatdirkeywords["compattestdir"] = 1 compatfilekeywords["compattestfile"] = 1 -} else if (kw == "kmod" && ENVIRON[nv] != "no") { - split("'"${KMODARCHDIRS}"'", kmodarchdirs, ","); - wanted[kw] = 1 - kmodpat = "./stand/" ENVIRON["MACHINE"] - l_kmodpat = length(kmodpat) -} else if (nv != "HAVE_GCC" && nv != "HAVE_GDB" && ENVIRON[nv] != "no" && nv != "COMPATDIRS" && nv != "MODULEARCHDIRS") - wanted[kw] = 1 +} + } + + if (wanted["kmod"] && wanted["compatmodules"]) { +split("'"${KMODARCHDIRS}"'", kmodarchdirs, ","); +kmodpat = "./stand/" ENVIRON["MACHINE"] +l_kmodpat = length(kmodpat) } if ("'"${TOOLCHAIN_MISSING}"'" != "yes") {