Date: Thu, 19 Oct 2006 23:14:40 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 108130 for review Message-ID: <200610192314.k9JNEeWA063322@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=108130 Change 108130 by rwatson@rwatson_zoo on 2006/10/19 23:14:35 Integrate TrustedBSD base branch from FreeBSD CVS: - CLONE_VFORK. - if_bce fixes. - devfs and VFS fixes. Etc. Affected files ... .. //depot/projects/trustedbsd/base/Makefile#47 integrate .. //depot/projects/trustedbsd/base/Makefile.inc1#80 integrate .. //depot/projects/trustedbsd/base/bin/ls/print.c#25 integrate .. //depot/projects/trustedbsd/base/bin/rm/rm.c#18 integrate .. //depot/projects/trustedbsd/base/contrib/ncurses/man/MKterminfo.sh#3 integrate .. //depot/projects/trustedbsd/base/contrib/traceroute/traceroute.8#8 integrate .. //depot/projects/trustedbsd/base/contrib/traceroute/traceroute.c#12 integrate .. //depot/projects/trustedbsd/base/etc/defaults/rc.conf#61 integrate .. //depot/projects/trustedbsd/base/etc/disktab#3 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/Makefile#44 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/amd#13 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/auto_linklocal#2 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/cleartmp#10 integrate .. //depot/projects/trustedbsd/base/etc/rc.d/idmapd#1 branch .. //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/kthr.c#5 integrate .. //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/trgt.c#5 integrate .. //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/trgt_arm.c#3 integrate .. //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/trgt_powerpc.c#2 integrate .. //depot/projects/trustedbsd/base/gnu/usr.bin/send-pr/send-pr.1#9 integrate .. //depot/projects/trustedbsd/base/lib/libc/i386/sys/i386_get_ldt.2#8 integrate .. //depot/projects/trustedbsd/base/lib/libc/locale/wctype.3#7 integrate .. //depot/projects/trustedbsd/base/lib/libc/stdio/freopen.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libc_r/uthread/uthread_init.c#11 integrate .. //depot/projects/trustedbsd/base/lib/libc_r/uthread/uthread_select.c#5 integrate .. //depot/projects/trustedbsd/base/lib/libc_r/uthread/uthread_sig.c#10 integrate .. //depot/projects/trustedbsd/base/lib/libnetgraph/msg.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libnetgraph/sock.c#7 integrate .. //depot/projects/trustedbsd/base/lib/libthr/thread/thr_fork.c#5 integrate .. //depot/projects/trustedbsd/base/lib/libthr/thread/thr_private.h#26 integrate .. //depot/projects/trustedbsd/base/lib/libthr/thread/thr_umtx.c#5 integrate .. //depot/projects/trustedbsd/base/lib/libthr/thread/thr_umtx.h#6 integrate .. //depot/projects/trustedbsd/base/lib/msun/i387/fenv.h#4 integrate .. //depot/projects/trustedbsd/base/release/doc/en_US.ISO8859-1/relnotes/common/new.sgml#113 integrate .. //depot/projects/trustedbsd/base/release/scripts/package-split.py#8 integrate .. //depot/projects/trustedbsd/base/sbin/Makefile#36 integrate .. //depot/projects/trustedbsd/base/sbin/bsdlabel/bsdlabel.8#15 integrate .. //depot/projects/trustedbsd/base/sbin/idmapd/Makefile#4 integrate .. //depot/projects/trustedbsd/base/sbin/idmapd/idmapd.8#5 integrate .. //depot/projects/trustedbsd/base/sbin/kldload/kldload.8#11 integrate .. //depot/projects/trustedbsd/base/share/examples/etc/README.examples#6 integrate .. //depot/projects/trustedbsd/base/share/man/man1/builtin.1#8 integrate .. //depot/projects/trustedbsd/base/share/man/man3/pthread_schedparam.3#3 integrate .. //depot/projects/trustedbsd/base/share/man/man4/gre.4#6 integrate .. //depot/projects/trustedbsd/base/share/man/man4/ipfirewall.4#6 integrate .. //depot/projects/trustedbsd/base/share/man/man4/man4.i386/ndis.4#6 integrate .. //depot/projects/trustedbsd/base/share/man/man4/pcm.4#16 integrate .. //depot/projects/trustedbsd/base/share/man/man4/sis.4#9 integrate .. //depot/projects/trustedbsd/base/share/man/man5/disktab.5#9 integrate .. //depot/projects/trustedbsd/base/share/man/man5/hosts.equiv.5#6 integrate .. //depot/projects/trustedbsd/base/share/man/man5/rc.conf.5#63 integrate .. //depot/projects/trustedbsd/base/share/man/man9/hash.9#3 integrate .. //depot/projects/trustedbsd/base/share/man/man9/ktr.9#11 integrate .. //depot/projects/trustedbsd/base/share/misc/iso3166#9 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/africa#7 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/asia#12 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/australasia#11 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/backward#9 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/europe#12 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/northamerica#12 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/southamerica#13 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/yearistype.sh#4 integrate .. //depot/projects/trustedbsd/base/share/zoneinfo/zone.tab#13 integrate .. //depot/projects/trustedbsd/base/sys/amd64/amd64/busdma_machdep.c#16 integrate .. //depot/projects/trustedbsd/base/sys/amd64/amd64/intr_machdep.c#14 integrate .. //depot/projects/trustedbsd/base/sys/amd64/amd64/support.S#15 integrate .. //depot/projects/trustedbsd/base/sys/amd64/conf/NOTES#18 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/linux.h#5 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/linux32_machdep.c#12 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/linux32_proto.h#14 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/linux32_syscall.h#14 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/linux32_sysent.c#14 integrate .. //depot/projects/trustedbsd/base/sys/amd64/linux32/syscalls.master#14 integrate .. //depot/projects/trustedbsd/base/sys/arm/arm/fusu.S#7 integrate .. //depot/projects/trustedbsd/base/sys/compat/freebsd32/freebsd32_proto.h#27 integrate .. //depot/projects/trustedbsd/base/sys/compat/freebsd32/freebsd32_syscall.h#27 integrate .. //depot/projects/trustedbsd/base/sys/compat/freebsd32/freebsd32_syscalls.c#27 integrate .. //depot/projects/trustedbsd/base/sys/compat/freebsd32/freebsd32_sysent.c#27 integrate .. //depot/projects/trustedbsd/base/sys/compat/freebsd32/syscalls.master#27 integrate .. //depot/projects/trustedbsd/base/sys/compat/linux/linux_aio.c#1 branch .. //depot/projects/trustedbsd/base/sys/compat/linux/linux_aio.h#1 branch .. //depot/projects/trustedbsd/base/sys/compat/linux/linux_signal.c#16 integrate .. //depot/projects/trustedbsd/base/sys/compat/linux/linux_signal.h#3 integrate .. //depot/projects/trustedbsd/base/sys/conf/files#105 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.amd64#34 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.i386#67 integrate .. //depot/projects/trustedbsd/base/sys/conf/files.pc98#56 integrate .. //depot/projects/trustedbsd/base/sys/dev/awi/if_awi_pccard.c#16 integrate .. //depot/projects/trustedbsd/base/sys/dev/bce/if_bce.c#7 integrate .. //depot/projects/trustedbsd/base/sys/dev/bce/if_bcereg.h#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/bge/if_bge.c#62 integrate .. //depot/projects/trustedbsd/base/sys/dev/mfi/mfi.c#7 integrate .. //depot/projects/trustedbsd/base/sys/dev/mfi/mfi_debug.c#2 integrate .. //depot/projects/trustedbsd/base/sys/dev/mfi/mfi_disk.c#4 integrate .. //depot/projects/trustedbsd/base/sys/dev/mfi/mfireg.h#5 integrate .. //depot/projects/trustedbsd/base/sys/dev/mfi/mfivar.h#5 integrate .. //depot/projects/trustedbsd/base/sys/dev/mxge/if_mxge.c#4 integrate .. //depot/projects/trustedbsd/base/sys/dev/nfe/if_nfe.c#4 integrate .. //depot/projects/trustedbsd/base/sys/dev/nfe/if_nfereg.h#3 integrate .. //depot/projects/trustedbsd/base/sys/dev/ray/if_ray.c#21 integrate .. //depot/projects/trustedbsd/base/sys/dev/sound/midi/sequencer.c#14 integrate .. //depot/projects/trustedbsd/base/sys/dev/sound/pci/hda/hdac.c#2 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/ehci.c#21 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/if_axe.c#24 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/if_udav.c#13 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/if_ural.c#15 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/ohci.c#42 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/uhci.c#42 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/usb.c#28 integrate .. //depot/projects/trustedbsd/base/sys/dev/usb/usbdi.h#13 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs.h#17 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs_devs.c#19 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs_int.h#2 integrate .. //depot/projects/trustedbsd/base/sys/fs/devfs/devfs_vnops.c#45 integrate .. //depot/projects/trustedbsd/base/sys/i386/acpica/Makefile#7 integrate .. //depot/projects/trustedbsd/base/sys/i386/conf/NOTES#71 integrate .. //depot/projects/trustedbsd/base/sys/i386/i386/support.s#19 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/linux.h#11 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/linux_machdep.c#26 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/linux_proto.h#27 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/linux_syscall.h#27 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/linux_sysent.c#28 integrate .. //depot/projects/trustedbsd/base/sys/i386/linux/syscalls.master#26 integrate .. //depot/projects/trustedbsd/base/sys/ia64/ia64/busdma_machdep.c#16 integrate .. //depot/projects/trustedbsd/base/sys/ia64/ia64/clock.c#17 integrate .. //depot/projects/trustedbsd/base/sys/ia64/ia64/support.S#7 integrate .. //depot/projects/trustedbsd/base/sys/kern/init_sysent.c#60 integrate .. //depot/projects/trustedbsd/base/sys/kern/kern_intr.c#43 integrate .. //depot/projects/trustedbsd/base/sys/kern/kern_umtx.c#20 integrate .. //depot/projects/trustedbsd/base/sys/kern/subr_trap.c#39 integrate .. //depot/projects/trustedbsd/base/sys/kern/sys_generic.c#39 integrate .. //depot/projects/trustedbsd/base/sys/kern/sys_process.c#33 integrate .. //depot/projects/trustedbsd/base/sys/kern/syscalls.c#60 integrate .. //depot/projects/trustedbsd/base/sys/kern/syscalls.master#61 integrate .. //depot/projects/trustedbsd/base/sys/kern/systrace_args.c#6 integrate .. //depot/projects/trustedbsd/base/sys/kern/vfs_aio.c#56 integrate .. //depot/projects/trustedbsd/base/sys/modules/aio/Makefile#2 integrate .. //depot/projects/trustedbsd/base/sys/modules/linux/Makefile#16 integrate .. //depot/projects/trustedbsd/base/sys/modules/mem/Makefile#3 integrate .. //depot/projects/trustedbsd/base/sys/modules/uart/Makefile#8 integrate .. //depot/projects/trustedbsd/base/sys/netgraph/netgraph.h#19 integrate .. //depot/projects/trustedbsd/base/sys/netgraph/ng_message.h#13 integrate .. //depot/projects/trustedbsd/base/sys/netgraph/ng_socket.c#27 integrate .. //depot/projects/trustedbsd/base/sys/netgraph/ng_socket.h#4 integrate .. //depot/projects/trustedbsd/base/sys/nfsclient/nfs.h#21 integrate .. //depot/projects/trustedbsd/base/sys/nfsclient/nfs_vnops.c#41 integrate .. //depot/projects/trustedbsd/base/sys/pc98/conf/NOTES#37 integrate .. //depot/projects/trustedbsd/base/sys/pci/agp.c#25 integrate .. //depot/projects/trustedbsd/base/sys/pci/nfsmb.c#5 integrate .. //depot/projects/trustedbsd/base/sys/powerpc/powerpc/copyinout.c#10 integrate .. //depot/projects/trustedbsd/base/sys/sparc64/sparc64/support.S#8 integrate .. //depot/projects/trustedbsd/base/sys/sun4v/conf/NOTES#2 integrate .. //depot/projects/trustedbsd/base/sys/sun4v/sun4v/support.S#2 integrate .. //depot/projects/trustedbsd/base/sys/sun4v/sun4v/trap.c#2 integrate .. //depot/projects/trustedbsd/base/sys/sys/elf32.h#5 integrate .. //depot/projects/trustedbsd/base/sys/sys/elf64.h#6 integrate .. //depot/projects/trustedbsd/base/sys/sys/sem.h#7 integrate .. //depot/projects/trustedbsd/base/sys/sys/syscall.h#60 integrate .. //depot/projects/trustedbsd/base/sys/sys/syscall.mk#60 integrate .. //depot/projects/trustedbsd/base/sys/sys/sysproto.h#61 integrate .. //depot/projects/trustedbsd/base/sys/sys/systm.h#41 integrate .. //depot/projects/trustedbsd/base/sys/sys/umtx.h#11 integrate .. //depot/projects/trustedbsd/base/sys/vm/vnode_pager.c#49 integrate .. //depot/projects/trustedbsd/base/usr.bin/expand/expand.1#8 integrate .. //depot/projects/trustedbsd/base/usr.bin/tr/tr.1#9 integrate .. //depot/projects/trustedbsd/base/usr.bin/unexpand/unexpand.c#9 integrate .. //depot/projects/trustedbsd/base/usr.sbin/Makefile#57 integrate .. //depot/projects/trustedbsd/base/usr.sbin/arp/arp.c#22 integrate .. //depot/projects/trustedbsd/base/usr.sbin/mountd/mountd.c#18 integrate .. //depot/projects/trustedbsd/base/usr.sbin/pccard/Makefile#3 integrate .. //depot/projects/trustedbsd/base/usr.sbin/pccard/dumpcis/Makefile#1 branch .. //depot/projects/trustedbsd/base/usr.sbin/pccard/dumpcis/dumpcis.8#1 branch .. //depot/projects/trustedbsd/base/usr.sbin/pccard/dumpcis/main.c#1 branch .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/Makefile#3 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/cardd.c#7 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/cardd.h#6 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/file.c#4 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/pccard.conf.5#5 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/pccardd.8#8 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/pccardd.c#4 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/server.c#3 delete .. //depot/projects/trustedbsd/base/usr.sbin/pccard/pccardd/util.c#2 delete .. //depot/projects/trustedbsd/base/usr.sbin/zic/zdump/Makefile#3 integrate .. //depot/projects/trustedbsd/base/usr.sbin/zic/zic/Makefile#3 integrate Differences ... ==== //depot/projects/trustedbsd/base/Makefile#47 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile,v 1.335 2006/09/08 10:13:15 ru Exp $ +# $FreeBSD: src/Makefile,v 1.336 2006/10/16 22:18:59 jb Exp $ # # The user-driven targets are: # @@ -266,7 +266,7 @@ @echo "--------------------------------------------------------------" @echo ">>> make universe started on ${STARTTIME}" @echo "--------------------------------------------------------------" -.for target in amd64 i386 ia64 pc98 sparc64 +.for target in amd64 i386 ia64 pc98 sparc64 sun4v KERNCONFS!= cd ${.CURDIR}/sys/${target}/conf && \ find [A-Z]*[A-Z] -type f -maxdepth 0 \ ! -name DEFAULTS ! -name LINT ==== //depot/projects/trustedbsd/base/Makefile.inc1#80 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/Makefile.inc1,v 1.562 2006/10/09 04:58:44 kmacy Exp $ +# $FreeBSD: src/Makefile.inc1,v 1.563 2006/10/16 22:18:13 jb Exp $ # # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir @@ -98,7 +98,7 @@ # Guess machine architecture from machine type, and vice versa. .if !defined(TARGET_ARCH) && defined(TARGET) -TARGET_ARCH= ${TARGET:S/pc98/i386/} +TARGET_ARCH= ${TARGET:S/pc98/i386/:S/sun4v/sparc64/} .elif !defined(TARGET) && defined(TARGET_ARCH) && \ ${TARGET_ARCH} != ${MACHINE_ARCH} TARGET= ${TARGET_ARCH} ==== //depot/projects/trustedbsd/base/bin/ls/print.c#25 (text+ko) ==== @@ -36,7 +36,7 @@ #endif /* not lint */ #endif #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/bin/ls/print.c,v 1.75 2006/03/24 16:38:02 jhb Exp $"); +__FBSDID("$FreeBSD: src/bin/ls/print.c,v 1.76 2006/10/18 10:58:27 ru Exp $"); #include <sys/param.h> #include <sys/stat.h> @@ -628,9 +628,10 @@ p->fts_parent->fts_accpath, p->fts_name); /* * We have no way to tell whether a symbolic link has an ACL since - * pathconf() and acl_get_file() both follow them. + * pathconf() and acl_get_file() both follow them. They also don't + * support whiteouts. */ - if (S_ISLNK(p->fts_statp->st_mode)) { + if (S_ISLNK(p->fts_statp->st_mode) || S_ISWHT(p->fts_statp->st_mode)) { *haveacls = 1; return; } ==== //depot/projects/trustedbsd/base/bin/rm/rm.c#18 (text+ko) ==== @@ -39,7 +39,7 @@ #endif /* not lint */ #endif #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/bin/rm/rm.c,v 1.54 2006/04/15 09:26:23 maxim Exp $"); +__FBSDID("$FreeBSD: src/bin/rm/rm.c,v 1.56 2006/10/18 13:16:06 maxim Exp $"); #include <sys/stat.h> #include <sys/param.h> @@ -347,7 +347,7 @@ if (!fflag && !S_ISWHT(sb.st_mode) && !check(f, f, &sb)) continue; rval = 0; - if (!uid && + if (!uid && !S_ISWHT(sb.st_mode) && (sb.st_flags & (UF_APPEND|UF_IMMUTABLE)) && !(sb.st_flags & (SF_APPEND|SF_IMMUTABLE))) rval = chflags(f, sb.st_flags & ~(UF_APPEND|UF_IMMUTABLE)); ==== //depot/projects/trustedbsd/base/contrib/ncurses/man/MKterminfo.sh#3 (text+ko) ==== @@ -1,6 +1,10 @@ #!/bin/sh +# $Id: MKterminfo.sh,v 1.12 2003/01/11 21:42:12 tom Exp $ +# +# MKterminfo.sh -- generate terminfo.5 from Caps tabular data +# #*************************************************************************** -# Copyright (c) 1998,2000,2001 Free Software Foundation, Inc. * +# Copyright (c) 1998,2002,2003 Free Software Foundation, Inc. * # * # Permission is hereby granted, free of charge, to any person obtaining a * # copy of this software and associated documentation files (the * @@ -27,10 +31,6 @@ # authorization. * #*************************************************************************** # -# $Id: MKterminfo.sh,v 1.9 2001/09/01 23:06:18 tom Exp $ -# -# MKterminfo.sh -- generate terminfo.5 from Caps tabular data -# # This script takes terminfo.head and terminfo.tail and splices in between # them a table derived from the Caps data file. Besides avoiding having # the docs fall out of sync with the table, this also lets us set up tbl @@ -41,10 +41,13 @@ # had better be no s in the table source text. # # keep the order independent of locale: -LANGUAGE=C -LC_ALL=C -export LANGUAGE -export LC_ALL +if test "${LANGUAGE+set}" = set; then LANGUAGE=C; export LANGUAGE; fi +if test "${LANG+set}" = set; then LANG=C; export LANG; fi +if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi +if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi +if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi +if test "${LC_COLLATE+set}" = set; then LC_COLLATE=C; export LC_COLLATE; fi + # head=$1 caps=$2 @@ -66,11 +69,11 @@ sed -n <$caps "\ /%%-STOP-HERE-%%/q -/^#%/s///p +/^#%/s/#%//p /^#/d -s/[ ]\+/ /g +s/[ ][ ]*/ /g s/$/T}/ -s/ [A-Z0-9_()\-]\+ [0-9\-]\+ [Y\-][B\-][C\-][G\-][EK\-]\** / T{/ +s/ [A-Z0-9_()\-][A-Z0-9_()\-]* [0-9\-][0-9\-]* [Y\-][B\-][C\-][G\-][EK\-]\** / T{/ s/ bool / /p s/ num / /p s/ str / /p ==== //depot/projects/trustedbsd/base/contrib/traceroute/traceroute.8#8 (text+ko) ==== @@ -14,7 +14,7 @@ .\" WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. .\" .\" $Id: traceroute.8,v 1.19 2000/09/21 08:44:19 leres Exp $ -.\" $FreeBSD: src/contrib/traceroute/traceroute.8,v 1.14 2006/06/13 14:59:07 dwmalone Exp $ +.\" $FreeBSD: src/contrib/traceroute/traceroute.8,v 1.16 2006/10/15 17:44:49 dwmalone Exp $ .\" .TH TRACEROUTE 8 "21 September 2000" .UC 6 @@ -24,7 +24,7 @@ .na .B traceroute [ -.B \-deFISdnrvx +.B \-dDeFISnrvx ] [ .B \-f .I first_ttl @@ -112,6 +112,18 @@ .B \-d Enable socket level debugging. .TP +.B \-D +When an ICMP response to our probe datagram is received, +print the differences between the transmitted packet and +the packet quoted by the ICMP response. +A key showing the location of fields within the transmitted packet is printed, +followed by the original packet in hex, +followed by the quoted packet in hex. +Bytes that are unchanged in the quoted packet are shown as underscores. +Note, +the IP checksum and the TTL of the quoted packet are not expected to match. +By default, only one probe per hop is sent with this option. +.TP .B \-g Specify a loose source route gateway (8 maximum). .TP @@ -163,7 +175,11 @@ to pick an unused port range. .TP .B \-q -Set the number of probes per hop (default is 3). +Set the number of probes per hop (default is 3, +unless +.B -D +is specified, +when it is 1). .TP .B \-r Bypass the normal routing tables and send directly to a host on an attached ==== //depot/projects/trustedbsd/base/contrib/traceroute/traceroute.c#12 (text+ko) ==== @@ -28,7 +28,7 @@ "@(#)$Id: traceroute.c,v 1.68 2000/12/14 08:04:33 leres Exp $ (LBL)"; #endif static const char rcsid[] = - "$FreeBSD: src/contrib/traceroute/traceroute.c,v 1.30 2006/06/13 14:59:07 dwmalone Exp $"; + "$FreeBSD: src/contrib/traceroute/traceroute.c,v 1.32 2006/10/15 17:44:49 dwmalone Exp $"; #endif /* @@ -316,6 +316,9 @@ struct ip *outip; /* last output ip packet */ u_char *outp; /* last output inner protocol packet */ +struct ip *hip = NULL; /* Quoted IP header */ +int hiplen = 0; + /* loose source route gateway list (including room for final destination) */ u_int32_t gwlist[NGATEWAYS + 1]; @@ -337,7 +340,7 @@ char *device; static const char devnull[] = "/dev/null"; -int nprobes = 3; +int nprobes = -1; int max_ttl; int first_ttl = 1; u_short ident; @@ -354,6 +357,7 @@ #endif int optlen; /* length of ip options */ int fixedPort = 0; /* Use fixed destination port for TCP and UDP */ +int printdiff = 0; /* Print the difference between sent and quoted */ extern int optind; extern int opterr; @@ -380,6 +384,7 @@ void tvsub(struct timeval *, struct timeval *); void usage(void); int wait_for_reply(int, struct sockaddr_in *, const struct timeval *); +void pkt_compare(const u_char *, int, const u_char *, int); #ifndef HAVE_USLEEP int usleep(u_int); #endif @@ -398,6 +403,7 @@ /* Descriptor structure for each outgoing protocol we support */ struct outproto { char *name; /* name of protocol */ + const char *key; /* An ascii key for the bytes of the header */ u_char num; /* IP protocol number */ u_short hdrlen; /* max size of protocol header */ u_short port; /* default base protocol-specific "port" */ @@ -412,6 +418,7 @@ struct outproto protos[] = { { "udp", + "spt dpt len sum", IPPROTO_UDP, sizeof(struct udphdr), 32768 + 666, @@ -420,6 +427,7 @@ }, { "tcp", + "spt dpt seq ack xxflwin sum urp", IPPROTO_TCP, sizeof(struct tcphdr), 32768 + 666, @@ -428,6 +436,7 @@ }, { "gre", + "flg pro len clid", IPPROTO_GRE, sizeof(struct grehdr), GRE_PPTP_PROTO, @@ -436,6 +445,7 @@ }, { "icmp", + "typ cod sum ", IPPROTO_ICMP, sizeof(struct icmp), 0, @@ -444,6 +454,7 @@ }, { NULL, + NULL, 0, 2 * sizeof(u_short), 0, @@ -453,6 +464,8 @@ }; struct outproto *proto = &protos[0]; +const char *ip_hdr_key = "vhtslen id off tlprsum srcip dstip opts"; + int main(int argc, char **argv) { @@ -522,13 +535,17 @@ prog = argv[0]; opterr = 0; - while ((op = getopt(argc, argv, "edFInrSvxf:g:i:M:m:P:p:q:s:t:w:z:")) != EOF) + while ((op = getopt(argc, argv, "edDFInrSvxf:g:i:M:m:P:p:q:s:t:w:z:")) != EOF) switch (op) { case 'd': options |= SO_DEBUG; break; + case 'D': + printdiff = 1; + break; + case 'e': fixedPort = 1; break; @@ -628,6 +645,9 @@ /* Set requested port, if any, else default for this protocol */ port = (requestPort != -1) ? requestPort : proto->port; + if (nprobes == -1) + nprobes = printdiff ? 1 : 3; + if (first_ttl > max_ttl) { Fprintf(stderr, "%s: first ttl (%d) may not be greater than max ttl (%d)\n", @@ -968,6 +988,16 @@ #endif precis = 3; Printf(" %.*f ms", precis, T); + if (printdiff) { + Printf("\n"); + Printf("%*.*s%s\n", + -(outip->ip_hl << 3), + outip->ip_hl << 3, + ip_hdr_key, + proto->key); + pkt_compare((void *)outip, packlen, + (void *)hip, hiplen); + } if (i == -2) { #ifndef ARCHAIC ip = (struct ip *)packet; @@ -1275,10 +1305,10 @@ return -2; if ((type == ICMP_TIMXCEED && code == ICMP_TIMXCEED_INTRANS) || type == ICMP_UNREACH) { - struct ip *hip; u_char *inner; hip = &icp->icmp_ip; + hiplen = ((u_char *)icp + cc) - (u_char *)hip; hlen = hip->ip_hl << 2; inner = (u_char *)((u_char *)hip + hlen); if (hlen + 12 <= cc @@ -1708,13 +1738,33 @@ } void +pkt_compare(const u_char *a, int la, const u_char *b, int lb) { + int l; + int i; + + for (i = 0; i < la; i++) + Printf("%02x", (unsigned int)a[i]); + Printf("\n"); + l = (la <= lb) ? la : lb; + for (i = 0; i < l; i++) + if (a[i] == b[i]) + Printf("__"); + else + Printf("%02x", (unsigned int)b[i]); + for (; i < lb; i++) + Printf("%02x", (unsigned int)b[i]); + Printf("\n"); +} + + +void usage(void) { extern char version[]; Fprintf(stderr, "Version %s\n", version); Fprintf(stderr, - "Usage: %s [-dFInrSvx] [-g gateway] [-i iface] [-f first_ttl]\n" + "Usage: %s [-dDeFInrSvx] [-f first_ttl] [-g gateway] [-i iface]\n" "\t[-m max_ttl] [-p port] [-P proto] [-q nqueries] [-s src_addr]\n" "\t[-t tos] [-w waittime] [-z pausemsecs] host [packetlen]\n", prog); exit(1); ==== //depot/projects/trustedbsd/base/etc/defaults/rc.conf#61 (text+ko) ==== @@ -15,7 +15,7 @@ # For a more detailed explanation of all the rc.conf variables, please # refer to the rc.conf(5) manual page. # -# $FreeBSD: src/etc/defaults/rc.conf,v 1.298 2006/10/06 23:22:12 flz Exp $ +# $FreeBSD: src/etc/defaults/rc.conf,v 1.300 2006/10/15 15:55:00 ceri Exp $ ############################################################## ### Important initial Boot-time options #################### @@ -242,6 +242,8 @@ nfs_access_cache="60" # Client cache timeout in seconds nfs_server_enable="NO" # This host is an NFS server (or NO). nfs_server_flags="-u -t -n 4" # Flags to nfsd (if enabled). +idmapd_enable="NO" # Run the NFS4 id mapper (YES/NO). +idmapd_flags="" # Additional flags for idmapd. mountd_enable="NO" # Run mountd (or NO). mountd_flags="-r" # Flags to mountd (if NFS server enabled). weak_mountd_authentication="NO" # Allow non-root mount requests to be served. ==== //depot/projects/trustedbsd/base/etc/disktab#3 (text+ko) ==== @@ -1,33 +1,7 @@ -# $FreeBSD: src/etc/disktab,v 1.25 2004/06/06 11:46:27 schweikh Exp $ +# $FreeBSD: src/etc/disktab,v 1.26 2006/10/14 16:39:03 ru Exp $ # # Disk geometry and partition layout tables. -# Key: -# dt controller type -# ty type of disk (fixed, removeable, simulated) -# d[0-4] drive-type-dependent parameters -# ns #sectors/track -# nt #tracks/cylinder -# nc #cylinders/disk -# sc #sectors/cylinder, ns*nt default -# su #sectors/unit, sc*nc default -# se sector size, DEV_BSIZE default -# rm rpm, 3600 default -# sf supports bad144-style bad sector forwarding -# sk sector skew per track, default 0 -# cs sector skew per cylinder, default 0 -# hs headswitch time, default 0 -# ts one-cylinder seek time, default 0 -# il sector interleave (n:1), 1 default -# bs boot block size, default BBSIZE -# sb superblock size, default SBSIZE -# o[a-h] partition offsets in sectors -# p[a-h] partition sizes in sectors -# b[a-h] partition block sizes in bytes -# f[a-h] partition fragment sizes in bytes -# t[a-h] partition types (filesystem, swap, etc) -# -# All partition sizes reserve space for bad sector tables. -# (5 cylinders needed for maintenance + replacement sectors) +# See disktab(5) for format of this file. # # ==== //depot/projects/trustedbsd/base/etc/rc.d/Makefile#44 (text+ko) ==== @@ -1,5 +1,5 @@ # $NetBSD: Makefile,v 1.16 2001/01/14 15:37:22 minoura Exp $ -# $FreeBSD: src/etc/rc.d/Makefile,v 1.77 2006/10/07 15:45:56 ume Exp $ +# $FreeBSD: src/etc/rc.d/Makefile,v 1.78 2006/10/15 14:19:06 ceri Exp $ .include <bsd.own.mk> @@ -15,7 +15,7 @@ gbde geli geli2 \ hcsecd \ hostapd hostname \ - inetd initrandom \ + idmapd inetd initrandom \ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ ==== //depot/projects/trustedbsd/base/etc/rc.d/amd#13 (text+ko) ==== @@ -1,7 +1,7 @@ #!/bin/sh # # $NetBSD: amd,v 1.10 2002/04/29 12:08:17 lukem Exp $ -# $FreeBSD: src/etc/rc.d/amd,v 1.17 2006/04/11 09:02:06 flz Exp $ +# $FreeBSD: src/etc/rc.d/amd,v 1.18 2006/10/18 15:56:11 flz Exp $ # # PROVIDE: amd @@ -16,6 +16,7 @@ command="/usr/sbin/${name}" start_precmd="amd_precmd" command_args="&" +extra_commands="reload" amd_precmd() { ==== //depot/projects/trustedbsd/base/etc/rc.d/auto_linklocal#2 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/auto_linklocal,v 1.1 2006/10/07 15:45:56 ume Exp $ +# $FreeBSD: src/etc/rc.d/auto_linklocal,v 1.2 2006/10/13 12:41:35 ume Exp $ # # PROVIDE: auto_linklocal @@ -10,9 +10,15 @@ . /etc/rc.subr name="auto_linklocal" -rcvar=`set_rcvar ipv6` -start_cmd="${SYSCTL_W} net.inet6.ip6.auto_linklocal=1" +start_cmd="auto_linklocal_start" stop_cmd=":" +auto_linklocal_start() +{ + if ! checkyesno ipv6_enable; then + ${SYSCTL_W} net.inet6.ip6.auto_linklocal=0 + fi +} + load_rc_config $name run_rc_command "$1" ==== //depot/projects/trustedbsd/base/etc/rc.d/cleartmp#10 (text+ko) ==== @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/cleartmp,v 1.17 2005/12/27 23:22:18 dougb Exp $ +# $FreeBSD: src/etc/rc.d/cleartmp,v 1.18 2006/10/16 13:01:45 yar Exp $ # # PROVIDE: cleartmp @@ -10,47 +10,48 @@ . /etc/rc.subr name="cleartmp" -rcvar=`set_rcvar clear_tmp` - +# Disguise rcvar for the start method to run irrespective of its setting. +rcvar1=`set_rcvar clear_tmp` start_cmd="${name}_start" +stop_cmd=":" -cleartmp_prestart() +cleartmp_start() { - checkyesno clear_tmp_X || return + # Make /tmp location variable for easier debugging. + local tmp="/tmp" - local x11_socket_dirs="/tmp/.X11-unix /tmp/.ICE-unix /tmp/.font-unix \ - /tmp/.XIM-unix" + # X related directories to create in /tmp. + local x11_socket_dirs="${tmp}/.X11-unix ${tmp}/.XIM-unix \ + ${tmp}/.ICE-unix ${tmp}/.font-unix" - # Remove X lock files, since they will prevent you from restarting X. - rm -f /tmp/.X[0-9]-lock + if checkyesno ${rcvar1}; then + echo "Clearing ${tmp}." - # Create socket directories with correct permissions to avoid - # security problem. - # - rm -fr ${x11_socket_dirs} - mkdir -m 1777 ${x11_socket_dirs} + # This is not needed for mfs, but doesn't hurt anything. + # Things to note: + # + The dot in ${tmp}/. is important. + # + Put -prune before -exec so find never descends + # into a directory that was already passed to rm -rf. + # + "--" in rm arguments isn't strictly necessary, but + # it can prevent foot-shooting in future. + # + /tmp/lost+found is preserved, but its contents are removed. + # + lost+found and quota.* in subdirectories are removed. + find -x ${tmp}/. ! -name . \ + ! \( -name lost+found -type d -user root \) \ + ! \( \( -name quota.user -or -name quota.group \) \ + -type f -user root \) \ + -prune -exec rm -rf -- {} + + elif checkyesno clear_tmp_X; then + # Remove X lock files, since they will prevent you from + # restarting X. Remove other X related directories. + echo "Clearing ${tmp} (X related)." + rm -rf ${tmp}/.X[0-9]-lock ${x11_socket_dirs} + fi + if checkyesno clear_tmp_X; then + # Create X related directories with proper permissions. + mkdir -m 1777 ${x11_socket_dirs} + fi } -cleartmp_start() -{ - echo "Clearing /tmp." - # - # Prune quickly with one rm, then use find to clean up - # /tmp/[lq]* (this is not needed with mfs /tmp, but - # doesn't hurt anything). - # - (cd /tmp && rm -rf [a-km-pr-zA-Z]* && - find -x . ! -name . ! -name lost+found ! -name quota.user \ - ! -name quota.group ! -name .X11-unix ! -name .ICE-unix \ - ! -name .font-unix ! -name .XIM-unix \ - -exec rm -rf -- {} \; -type d -prune) -} - load_rc_config $name - -# The clear_tmp_X variable should be tested even if clear_tmp_enable is NO -case "$1" in -*start) cleartmp_prestart ;; -esac - run_rc_command "$1" ==== //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/kthr.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/kthr.c,v 1.4 2006/08/25 16:20:17 jhb Exp $"); +__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/kthr.c,v 1.5 2006/10/16 20:07:23 jhb Exp $"); #include <sys/param.h> #include <sys/proc.h> @@ -102,7 +102,7 @@ stopped_cpus = 0; stoppcbs = lookup("_stoppcbs"); - + while (paddr != 0) { if (kvm_read(kvm, paddr, &p, sizeof(p)) != sizeof(p)) warnx("kvm_read: %s", kvm_geterr(kvm)); @@ -118,7 +118,7 @@ else if (td.td_state == TDS_RUNNING && ((1 << td.td_oncpu) & stopped_cpus) && stoppcbs != 0) kt->pcb = (uintptr_t) stoppcbs + sizeof(struct pcb) * td.td_oncpu; - else + else kt->pcb = (uintptr_t)td.td_pcb; kt->kstack = td.td_kstack; kt->tid = td.td_tid; ==== //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/trgt.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/trgt.c,v 1.4 2005/09/10 18:25:53 marcel Exp $"); +__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/trgt.c,v 1.5 2006/10/16 20:06:32 jhb Exp $"); #include <sys/param.h> #include <sys/proc.h> @@ -45,6 +45,26 @@ static struct target_ops kgdb_trgt_ops; +#define KERNOFF (kgdb_kernbase ()) +#define INKERNEL(x) ((x) >= KERNOFF) + +static CORE_ADDR +kgdb_kernbase (void) +{ + static CORE_ADDR kernbase; + struct minimal_symbol *sym; + + if (kernbase == 0) { + sym = lookup_minimal_symbol ("kernbase", NULL, NULL); + if (sym == NULL) { + kernbase = KERNBASE; + } else { + kernbase = SYMBOL_VALUE_ADDRESS (sym); + } + } + return kernbase; +} + static char * kgdb_trgt_extra_thread_info(struct thread_info *ti) { @@ -114,6 +134,71 @@ return (tb->to_xfer_memory(memaddr, myaddr, len, write, attrib, tb)); } +static void +kgdb_switch_to_thread(struct kthr *thr) +{ + if (thr->tid == ptid_get_tid(inferior_ptid)) + return; + + inferior_ptid = ptid_build(thr->pid, 0, thr->tid); + flush_cached_frames (); + registers_changed (); + stop_pc = read_pc (); + select_frame (get_current_frame ()); +} + +static void +kgdb_set_proc_cmd (char *arg, int from_tty) +{ + CORE_ADDR addr; + struct kthr *thr; + + if (!arg) + error_no_arg ("proc address for the new context"); + + if (kvm == NULL) + error ("no kernel core file"); + + addr = (CORE_ADDR) parse_and_eval_address (arg); + + if (!INKERNEL (addr)) { + thr = kgdb_thr_lookup_pid((int)addr); + if (thr == NULL) + error ("invalid pid"); + } else { + thr = kgdb_thr_lookup_paddr(addr); + if (thr == NULL) + error("invalid proc address"); + } + kgdb_switch_to_thread(thr); +} + +static void +kgdb_set_tid_cmd (char *arg, int from_tty) +{ + CORE_ADDR addr; + struct kthr *thr; + + if (!arg) + error_no_arg ("TID or thread address for the new context"); + + if (kvm == NULL) + error ("no kernel core file"); + + addr = (CORE_ADDR) parse_and_eval_address (arg); + + if (!INKERNEL (addr)) { + thr = kgdb_thr_lookup_tid((int)addr); + if (thr == NULL) + error ("invalid TID"); + } else { + thr = kgdb_thr_lookup_taddr(addr); + if (thr == NULL) + error("invalid thread address"); + } + kgdb_switch_to_thread(thr); +} + void kgdb_target(void) { @@ -147,4 +232,8 @@ } if (curkthr != 0) inferior_ptid = ptid_build(curkthr->pid, 0, curkthr->tid); + add_com ("proc", class_obscure, kgdb_set_proc_cmd, + "Set current process context"); + add_com ("tid", class_obscure, kgdb_set_tid_cmd, + "Set current thread context"); } ==== //depot/projects/trustedbsd/base/gnu/usr.bin/gdb/kgdb/trgt_arm.c#3 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/trgt_arm.c,v 1.2 2006/09/14 07:51:52 imp Exp $"); +__FBSDID("$FreeBSD: src/gnu/usr.bin/gdb/kgdb/trgt_arm.c,v 1.3 2006/10/16 20:07:23 jhb Exp $"); #include <sys/types.h> #ifndef CROSS_DEBUGGER @@ -54,7 +54,7 @@ struct kthr *kt; struct pcb pcb; int i, reg; - + kt = kgdb_thr_lookup_tid(ptid_get_tid(inferior_ptid)); if (kt == NULL) return; @@ -63,7 +63,7 @@ memset(&pcb, 0, sizeof(pcb)); } for (i = ARM_A1_REGNUM + 8; i <= ARM_SP_REGNUM; i++) { - supply_register(i, (char *)&pcb.un_32.pcb32_r8 + + supply_register(i, (char *)&pcb.un_32.pcb32_r8 + (i - (ARM_A1_REGNUM + 8 )) * 4); } if (pcb.un_32.pcb32_sp != 0) { @@ -174,7 +174,7 @@ return; cache = kgdb_trgt_frame_cache(next_frame, this_cache); - + if (is_undef && (regnum == ARM_SP_REGNUM || regnum == ARM_PC_REGNUM)) { *addrp = cache->sp + offsetof(struct trapframe, tf_spsr); >>> TRUNCATED FOR MAIL (1000 lines) <<<
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200610192314.k9JNEeWA063322>