From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 03:42:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 43BE09F4; Sun, 20 Jan 2013 03:42:50 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1825BE94; Sun, 20 Jan 2013 03:42:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0K3gnXu006915; Sun, 20 Jan 2013 03:42:49 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0K3gnkK006913; Sun, 20 Jan 2013 03:42:49 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301200342.r0K3gnkK006913@svn.freebsd.org> From: Neel Natu Date: Sun, 20 Jan 2013 03:42:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245678 - in head: lib/libvmmapi sys/amd64/include sys/amd64/vmm sys/amd64/vmm/amd sys/amd64/vmm/intel sys/amd64/vmm/io sys/dev/blackhole sys/dev/bvm sys/modules/blackhole sys/modules/v... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 03:42:50 -0000 Author: neel Date: Sun Jan 20 03:42:49 2013 New Revision: 245678 URL: http://svnweb.freebsd.org/changeset/base/245678 Log: Add svn properties to the recently merged bhyve source files. The pre-commit hook will not allow any commits without the svn:keywords property in head. Modified: head/sys/amd64/include/vmm.h (contents, props changed) head/sys/amd64/include/vmm_dev.h (contents, props changed) Directory Properties: head/lib/libvmmapi/Makefile (props changed) head/lib/libvmmapi/vmmapi.c (props changed) head/lib/libvmmapi/vmmapi.h (props changed) head/lib/libvmmapi/vmmapi_freebsd.c (props changed) head/sys/amd64/vmm/amd/amdv.c (props changed) head/sys/amd64/vmm/intel/ept.c (props changed) head/sys/amd64/vmm/intel/ept.h (props changed) head/sys/amd64/vmm/intel/vmcs.c (props changed) head/sys/amd64/vmm/intel/vmcs.h (props changed) head/sys/amd64/vmm/intel/vmx.c (props changed) head/sys/amd64/vmm/intel/vmx.h (props changed) head/sys/amd64/vmm/intel/vmx_controls.h (props changed) head/sys/amd64/vmm/intel/vmx_cpufunc.h (props changed) head/sys/amd64/vmm/intel/vmx_genassym.c (props changed) head/sys/amd64/vmm/intel/vmx_msr.c (props changed) head/sys/amd64/vmm/intel/vmx_msr.h (props changed) head/sys/amd64/vmm/intel/vmx_support.S (props changed) head/sys/amd64/vmm/intel/vtd.c (props changed) head/sys/amd64/vmm/io/iommu.c (props changed) head/sys/amd64/vmm/io/iommu.h (props changed) head/sys/amd64/vmm/io/ppt.c (props changed) head/sys/amd64/vmm/io/ppt.h (props changed) head/sys/amd64/vmm/io/vdev.c (props changed) head/sys/amd64/vmm/io/vdev.h (props changed) head/sys/amd64/vmm/io/vlapic.c (props changed) head/sys/amd64/vmm/io/vlapic.h (props changed) head/sys/amd64/vmm/vmm.c (props changed) head/sys/amd64/vmm/vmm_dev.c (props changed) head/sys/amd64/vmm/vmm_ipi.c (props changed) head/sys/amd64/vmm/vmm_ipi.h (props changed) head/sys/amd64/vmm/vmm_ktr.h (props changed) head/sys/amd64/vmm/vmm_lapic.c (props changed) head/sys/amd64/vmm/vmm_lapic.h (props changed) head/sys/amd64/vmm/vmm_mem.c (props changed) head/sys/amd64/vmm/vmm_mem.h (props changed) head/sys/amd64/vmm/vmm_msr.c (props changed) head/sys/amd64/vmm/vmm_msr.h (props changed) head/sys/amd64/vmm/vmm_stat.c (props changed) head/sys/amd64/vmm/vmm_stat.h (props changed) head/sys/amd64/vmm/vmm_support.S (props changed) head/sys/amd64/vmm/vmm_util.c (props changed) head/sys/amd64/vmm/vmm_util.h (props changed) head/sys/amd64/vmm/x86.c (props changed) head/sys/amd64/vmm/x86.h (props changed) head/sys/dev/blackhole/blackhole.c (props changed) head/sys/dev/bvm/bvm_console.c (props changed) head/sys/dev/bvm/bvm_dbg.c (props changed) head/sys/modules/blackhole/Makefile (props changed) head/sys/modules/vmm/Makefile (props changed) head/usr.sbin/bhyve/Makefile (props changed) head/usr.sbin/bhyve/atpic.c (props changed) head/usr.sbin/bhyve/bhyverun.c (props changed) head/usr.sbin/bhyve/bhyverun.h (props changed) head/usr.sbin/bhyve/consport.c (props changed) head/usr.sbin/bhyve/dbgport.c (props changed) head/usr.sbin/bhyve/dbgport.h (props changed) head/usr.sbin/bhyve/elcr.c (props changed) head/usr.sbin/bhyve/inout.c (props changed) head/usr.sbin/bhyve/inout.h (props changed) head/usr.sbin/bhyve/mevent.c (props changed) head/usr.sbin/bhyve/mevent.h (props changed) head/usr.sbin/bhyve/mevent_test.c (props changed) head/usr.sbin/bhyve/mptbl.c (props changed) head/usr.sbin/bhyve/pci_emul.c (props changed) head/usr.sbin/bhyve/pci_emul.h (props changed) head/usr.sbin/bhyve/pci_hostbridge.c (props changed) head/usr.sbin/bhyve/pci_passthru.c (props changed) head/usr.sbin/bhyve/pci_virtio_block.c (props changed) head/usr.sbin/bhyve/pci_virtio_net.c (props changed) head/usr.sbin/bhyve/pit_8254.c (props changed) head/usr.sbin/bhyve/pit_8254.h (props changed) head/usr.sbin/bhyve/post.c (props changed) head/usr.sbin/bhyve/rtc.c (props changed) head/usr.sbin/bhyve/uart.c (props changed) head/usr.sbin/bhyve/virtio.h (props changed) head/usr.sbin/bhyve/xmsr.c (props changed) head/usr.sbin/bhyve/xmsr.h (props changed) head/usr.sbin/bhyvectl/Makefile (props changed) head/usr.sbin/bhyvectl/bhyvectl.c (props changed) Modified: head/sys/amd64/include/vmm.h ============================================================================== --- head/sys/amd64/include/vmm.h Sat Jan 19 22:12:57 2013 (r245677) +++ head/sys/amd64/include/vmm.h Sun Jan 20 03:42:49 2013 (r245678) @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: vmm.h 482 2011-05-09 21:22:43Z grehan $ + * $FreeBSD$ */ #ifndef _VMM_H_ Modified: head/sys/amd64/include/vmm_dev.h ============================================================================== --- head/sys/amd64/include/vmm_dev.h Sat Jan 19 22:12:57 2013 (r245677) +++ head/sys/amd64/include/vmm_dev.h Sun Jan 20 03:42:49 2013 (r245678) @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: vmm_dev.h 482 2011-05-09 21:22:43Z grehan $ + * $FreeBSD$ */ #ifndef _VMM_DEV_H_ From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 03:47:14 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E27D7B85; Sun, 20 Jan 2013 03:47:14 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id BCF8DEB3; Sun, 20 Jan 2013 03:47:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0K3lEgh007543; Sun, 20 Jan 2013 03:47:14 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0K3lESV007541; Sun, 20 Jan 2013 03:47:14 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301200347.r0K3lESV007541@svn.freebsd.org> From: Neel Natu Date: Sun, 20 Jan 2013 03:47:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245679 - in head/usr.sbin: bhyve bhyvectl X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 03:47:15 -0000 Author: neel Date: Sun Jan 20 03:47:13 2013 New Revision: 245679 URL: http://svnweb.freebsd.org/changeset/base/245679 Log: Use in a consistent manner in usage messages output by 'bhyve', 'bhyveload' and 'bhyvectl'. Pointed out by: joel@ Modified: head/usr.sbin/bhyve/bhyverun.c head/usr.sbin/bhyvectl/bhyvectl.c Modified: head/usr.sbin/bhyve/bhyverun.c ============================================================================== --- head/usr.sbin/bhyve/bhyverun.c Sun Jan 20 03:42:49 2013 (r245678) +++ head/usr.sbin/bhyve/bhyverun.c Sun Jan 20 03:47:13 2013 (r245679) @@ -131,7 +131,8 @@ usage(int code) fprintf(stderr, "Usage: %s [-aehABHIP][-g ][-z ][-s ]" - "[-S ][-p pincpu][-n ][-m lowmem][-M highmem] \n" + "[-S ][-p pincpu][-n ][-m lowmem][-M highmem]" + " \n" " -a: local apic is in XAPIC mode (default is X2APIC)\n" " -A: create an ACPI table\n" " -g: gdb port (default is %d and 0 means don't open)\n" Modified: head/usr.sbin/bhyvectl/bhyvectl.c ============================================================================== --- head/usr.sbin/bhyvectl/bhyvectl.c Sun Jan 20 03:42:49 2013 (r245678) +++ head/usr.sbin/bhyvectl/bhyvectl.c Sun Jan 20 03:47:13 2013 (r245679) @@ -64,7 +64,7 @@ usage(void) { (void)fprintf(stderr, - "Usage: %s --vm=\n" + "Usage: %s --vm=\n" " [--cpu=]\n" " [--create]\n" " [--destroy]\n" From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 03:55:10 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A0D45EFC; Sun, 20 Jan 2013 03:55:08 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9198AEE7; Sun, 20 Jan 2013 03:55:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0K3t8bk010142; Sun, 20 Jan 2013 03:55:08 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0K3t8qv010141; Sun, 20 Jan 2013 03:55:08 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301200355.r0K3t8qv010141@svn.freebsd.org> From: Nathan Whitehorn Date: Sun, 20 Jan 2013 03:55:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245680 - head/usr.sbin/bsdinstall/partedit X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 03:55:10 -0000 Author: nwhitehorn Date: Sun Jan 20 03:55:08 2013 New Revision: 245680 URL: http://svnweb.freebsd.org/changeset/base/245680 Log: Make "Finish" the default choice in the partition editor. This lets you successfully complete an installation with all defaults by pressing Enter repeatedly until your machine reboots. MFC after: 3 weeks Modified: head/usr.sbin/bsdinstall/partedit/diskeditor.c Modified: head/usr.sbin/bsdinstall/partedit/diskeditor.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/diskeditor.c Sun Jan 20 03:47:13 2013 (r245679) +++ head/usr.sbin/bsdinstall/partedit/diskeditor.c Sun Jan 20 03:55:08 2013 (r245680) @@ -77,7 +77,7 @@ diskeditor_show(const char *title, const int partlist_height, partlist_width; int cur_scroll = 0; int key, fkey; - int cur_button = 0, cur_part = 0; + int cur_button = 5, cur_part = 0; int result = DLG_EXIT_UNKNOWN; static DLG_KEYS_BINDING binding[] = { From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 04:04:37 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DE2BC14E; Sun, 20 Jan 2013 04:04:37 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CFC06F1E; Sun, 20 Jan 2013 04:04:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0K44bw7013209; Sun, 20 Jan 2013 04:04:37 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0K44bfJ013208; Sun, 20 Jan 2013 04:04:37 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301200404.r0K44bfJ013208@svn.freebsd.org> From: Neel Natu Date: Sun, 20 Jan 2013 04:04:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245681 - head/share/man/man4 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 04:04:37 -0000 Author: neel Date: Sun Jan 20 04:04:37 2013 New Revision: 245681 URL: http://svnweb.freebsd.org/changeset/base/245681 Log: Link the bhyve(4) man page to the build so the man page is actually installed. Pointed out by: wxs@ Modified: head/share/man/man4/Makefile Modified: head/share/man/man4/Makefile ============================================================================== --- head/share/man/man4/Makefile Sun Jan 20 03:55:08 2013 (r245680) +++ head/share/man/man4/Makefile Sun Jan 20 04:04:37 2013 (r245681) @@ -70,6 +70,7 @@ MAN= aac.4 \ bce.4 \ bfe.4 \ bge.4 \ + ${_bhyve.4} \ bktr.4 \ blackhole.4 \ bpf.4 \ @@ -784,6 +785,7 @@ MLINKS+=lindev.4 full.4 .endif .if ${MACHINE_CPUARCH} == "amd64" +_bhyve.4= bhyve.4 _qlxgb.4= qlxgb.4 _sfxge.4= sfxge.4 From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 08:18:57 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A53B0CBD; Sun, 20 Jan 2013 08:18:57 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 8C9A36D3; Sun, 20 Jan 2013 08:18:57 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0K8Iv5B087610; Sun, 20 Jan 2013 08:18:57 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0K8IvoJ087609; Sun, 20 Jan 2013 08:18:57 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201301200818.r0K8IvoJ087609@svn.freebsd.org> From: Joel Dahl Date: Sun, 20 Jan 2013 08:18:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245685 - head/usr.sbin/bhyvectl X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 08:18:57 -0000 Author: joel (doc committer) Date: Sun Jan 20 08:18:56 2013 New Revision: 245685 URL: http://svnweb.freebsd.org/changeset/base/245685 Log: Fix minor nit in usage output. Reviewed by: neel Modified: head/usr.sbin/bhyvectl/bhyvectl.c Modified: head/usr.sbin/bhyvectl/bhyvectl.c ============================================================================== --- head/usr.sbin/bhyvectl/bhyvectl.c Sun Jan 20 08:11:50 2013 (r245684) +++ head/usr.sbin/bhyvectl/bhyvectl.c Sun Jan 20 08:18:56 2013 (r245685) @@ -68,7 +68,7 @@ usage(void) " [--cpu=]\n" " [--create]\n" " [--destroy]\n" - " [--get-all]\n" + " [--get-all]\n" " [--get-stats]\n" " [--set-desc-ds]\n" " [--get-desc-ds]\n" From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 11:58:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id F3FD9352; Sun, 20 Jan 2013 11:58:49 +0000 (UTC) (envelope-from gabor@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E587AE00; Sun, 20 Jan 2013 11:58:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KBwniH052415; Sun, 20 Jan 2013 11:58:49 GMT (envelope-from gabor@svn.freebsd.org) Received: (from gabor@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KBwndO052414; Sun, 20 Jan 2013 11:58:49 GMT (envelope-from gabor@svn.freebsd.org) Message-Id: <201301201158.r0KBwndO052414@svn.freebsd.org> From: Gabor Kovesdan Date: Sun, 20 Jan 2013 11:58:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245688 - head/usr.bin/grep X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 11:58:50 -0000 Author: gabor Date: Sun Jan 20 11:58:49 2013 New Revision: 245688 URL: http://svnweb.freebsd.org/changeset/base/245688 Log: - Avoid unnecessary strdup() Submitted by: ache MFC after: 5 days Modified: head/usr.bin/grep/grep.c Modified: head/usr.bin/grep/grep.c ============================================================================== --- head/usr.bin/grep/grep.c Sun Jan 20 11:18:29 2013 (r245687) +++ head/usr.bin/grep/grep.c Sun Jan 20 11:58:49 2013 (r245688) @@ -481,7 +481,7 @@ main(int argc, char *argv[]) case 'e': { char *token; - char *string = strdup(optarg); + char *string = optarg; while ((token = strsep(&string, "\n")) != NULL) add_pattern(token, strlen(token)); @@ -675,7 +675,7 @@ main(int argc, char *argv[]) /* Process patterns from command line */ if (aargc != 0 && needpattern) { char *token; - char *string = strdup(*aargv); + char *string = *aargv; while ((token = strsep(&string, "\n")) != NULL) add_pattern(token, strlen(token)); From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 12:44:52 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 65D7EEEF; Sun, 20 Jan 2013 12:44:52 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3EF63197; Sun, 20 Jan 2013 12:44:52 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KCiq4j066961; Sun, 20 Jan 2013 12:44:52 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KCipIN066956; Sun, 20 Jan 2013 12:44:51 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201301201244.r0KCipIN066956@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 20 Jan 2013 12:44:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245689 - head/bin/sh X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 12:44:52 -0000 Author: jilles Date: Sun Jan 20 12:44:50 2013 New Revision: 245689 URL: http://svnweb.freebsd.org/changeset/base/245689 Log: sh: Remove mkinit's initialization routine. Instead, call the only init function left directly from main(). Modified: head/bin/sh/TOUR head/bin/sh/init.h head/bin/sh/main.c head/bin/sh/mkinit.c head/bin/sh/var.c Modified: head/bin/sh/TOUR ============================================================================== --- head/bin/sh/TOUR Sun Jan 20 11:58:49 2013 (r245688) +++ head/bin/sh/TOUR Sun Jan 20 12:44:50 2013 (r245689) @@ -33,10 +33,6 @@ programs is: There are undoubtedly too many of these. Mkinit searches all the C source files for entries looking like: - INIT { - x = 1; /* executed during initialization */ - } - RESET { x = 2; /* executed when the shell does a longjmp back to the main command loop */ Modified: head/bin/sh/init.h ============================================================================== --- head/bin/sh/init.h Sun Jan 20 11:58:49 2013 (r245688) +++ head/bin/sh/init.h Sun Jan 20 12:44:50 2013 (r245689) @@ -33,5 +33,4 @@ * $FreeBSD$ */ -void init(void); void reset(void); Modified: head/bin/sh/main.c ============================================================================== --- head/bin/sh/main.c Sun Jan 20 11:58:49 2013 (r245688) +++ head/bin/sh/main.c Sun Jan 20 12:44:50 2013 (r245689) @@ -139,7 +139,7 @@ main(int argc, char *argv[]) #endif rootpid = getpid(); rootshell = 1; - init(); + initvar(); setstackmark(&smark); setstackmark(&smark2); procargs(argc, argv); Modified: head/bin/sh/mkinit.c ============================================================================== --- head/bin/sh/mkinit.c Sun Jan 20 11:58:49 2013 (r245688) +++ head/bin/sh/mkinit.c Sun Jan 20 12:44:50 2013 (r245689) @@ -101,7 +101,7 @@ struct block { */ struct event { - const char *name; /* name of event (e.g. INIT) */ + const char *name; /* name of event (e.g. RESET) */ const char *routine; /* name of routine called on event */ const char *comment; /* comment describing routine */ struct text code; /* code for handling event */ @@ -114,11 +114,6 @@ char writer[] = "\ */\n\ \n"; -char init[] = "\ -/*\n\ - * Initialization code.\n\ - */\n"; - char reset[] = "\ /*\n\ * This routine is called when an error or an interrupt occurs in an\n\ @@ -127,7 +122,6 @@ char reset[] = "\ struct event event[] = { - { "INIT", "init", init, { NULL, 0, NULL, NULL } }, { "RESET", "reset", reset, { NULL, 0, NULL, NULL } }, { NULL, NULL, NULL, { NULL, 0, NULL, NULL } } }; Modified: head/bin/sh/var.c ============================================================================== --- head/bin/sh/var.c Sun Jan 20 11:58:49 2013 (r245688) +++ head/bin/sh/var.c Sun Jan 20 12:44:50 2013 (r245689) @@ -146,29 +146,11 @@ static int varequal(const char *, const static struct var *find_var(const char *, struct var ***, int *); static int localevar(const char *); -/* - * Initialize the variable symbol tables and import the environment. - */ - -#ifdef mkinit -INCLUDE "var.h" -MKINIT char **environ; -INIT { - char **envp; - - initvar(); - for (envp = environ ; *envp ; envp++) { - if (strchr(*envp, '=')) { - setvareq(*envp, VEXPORT|VTEXTFIXED); - } - } -} -#endif - +extern char **environ; /* - * This routine initializes the builtin variables. It is called when the - * shell is initialized. + * This routine initializes the builtin variables and imports the environment. + * It is called when the shell is initialized. */ void @@ -178,6 +160,7 @@ initvar(void) const struct varinit *ip; struct var *vp; struct var **vpp; + char **envp; for (ip = varinit ; (vp = ip->var) != NULL ; ip++) { if (find_var(ip->text, &vpp, &vp->name_len) != NULL) @@ -201,6 +184,11 @@ initvar(void) fmtstr(ppid, sizeof(ppid), "%d", (int)getppid()); setvarsafe("PPID", ppid, 0); } + for (envp = environ ; *envp ; envp++) { + if (strchr(*envp, '=')) { + setvareq(*envp, VEXPORT|VTEXTFIXED); + } + } } /* @@ -356,7 +344,7 @@ setvareq(char *s, int flags) * a regular variable function callback, but why bother? * * Note: this assumes iflag is not set to 1 initially. - * As part of init(), this is called before arguments + * As part of initvar(), this is called before arguments * are looked at. */ if ((vp == &vmpath || (vp == &vmail && ! mpathset())) && From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 17:48:57 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0FBC1D41; Sun, 20 Jan 2013 17:48:57 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EA6E2DA1; Sun, 20 Jan 2013 17:48:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KHmuF9058617; Sun, 20 Jan 2013 17:48:56 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KHmuuF058616; Sun, 20 Jan 2013 17:48:56 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201301201748.r0KHmuuF058616@svn.freebsd.org> From: Devin Teske Date: Sun, 20 Jan 2013 17:48:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245695 - head/usr.sbin/bsdconfig/share X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 17:48:57 -0000 Author: dteske Date: Sun Jan 20 17:48:56 2013 New Revision: 245695 URL: http://svnweb.freebsd.org/changeset/base/245695 Log: Backward compatibility fix: treat cmds loaded as a script as nonInteractive Modified: head/usr.sbin/bsdconfig/share/script.subr Modified: head/usr.sbin/bsdconfig/share/script.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/script.subr Sun Jan 20 16:23:37 2013 (r245694) +++ head/usr.sbin/bsdconfig/share/script.subr Sun Jan 20 17:48:56 2013 (r245695) @@ -100,7 +100,7 @@ f_dispatch() # f_script_load() { - local script="$1" config_file + local script="$1" config_file retval=$SUCCESS f_dprintf "f_script_load: script=[%s]" "$script" if [ ! "$script" ]; then @@ -113,9 +113,18 @@ f_script_load() ; do [ -e "$script" ] && break done - elif [ "$script" = "-" ]; then + fi + + local old_interactive= + f_getvar $VAR_NONINTERACTIVE old_interactive # save a copy + + # Hint to others that we're running from a script, should they care + setvar $VAR_NONINTERACTIVE yes + + if [ "$script" = "-" ]; then f_dprintf "f_script_load: Loading script from stdin" eval "$( cat )" + retval=$? else f_dprintf "f_script_load: Loading script \`%s'" "$script" if [ ! -e "$script" ]; then @@ -123,7 +132,13 @@ f_script_load() return $FAILURE fi . "$script" + retval=$? fi + + [ "$old_interactive" ] && + setvar $VAR_NONINTERACTIVE "$old_interactive" + + return $retval } ############################################################ MAIN From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 19:44:34 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 731362EA; Sun, 20 Jan 2013 19:44:34 +0000 (UTC) (envelope-from zont@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4E82917C; Sun, 20 Jan 2013 19:44:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KJiYYe094121; Sun, 20 Jan 2013 19:44:34 GMT (envelope-from zont@svn.freebsd.org) Received: (from zont@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KJiY0C094120; Sun, 20 Jan 2013 19:44:34 GMT (envelope-from zont@svn.freebsd.org) Message-Id: <201301201944.r0KJiY0C094120@svn.freebsd.org> From: Andrey Zonov Date: Sun, 20 Jan 2013 19:44:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245696 - head/usr.sbin/inetd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 19:44:34 -0000 Author: zont Date: Sun Jan 20 19:44:33 2013 New Revision: 245696 URL: http://svnweb.freebsd.org/changeset/base/245696 Log: - Force inetd to have listen queue size to be set to the value of kern.ipc.somaxconn instead of hardcoded value 64. Submitted by: Andrey Ignatov MFC after: 2 weeks Modified: head/usr.sbin/inetd/inetd.c Modified: head/usr.sbin/inetd/inetd.c ============================================================================== --- head/usr.sbin/inetd/inetd.c Sun Jan 20 17:48:56 2013 (r245695) +++ head/usr.sbin/inetd/inetd.c Sun Jan 20 19:44:33 2013 (r245696) @@ -1387,7 +1387,7 @@ setsockopt(fd, SOL_SOCKET, opt, (char *) } } if (sep->se_socktype == SOCK_STREAM) - listen(sep->se_fd, 64); + listen(sep->se_fd, -1); enable(sep); if (debug) { warnx("registered %s on %d", From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 19:55:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 62C88556; Sun, 20 Jan 2013 19:55:50 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2590B1CD; Sun, 20 Jan 2013 19:55:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KJtoik097146; Sun, 20 Jan 2013 19:55:50 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KJtoq9097145; Sun, 20 Jan 2013 19:55:50 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201301201955.r0KJtoq9097145@svn.freebsd.org> From: Andriy Gapon Date: Sun, 20 Jan 2013 19:55:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245697 - head/sys/boot/sparc64/loader X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 19:55:50 -0000 Author: avg Date: Sun Jan 20 19:55:49 2013 New Revision: 245697 URL: http://svnweb.freebsd.org/changeset/base/245697 Log: zfs/sparc64 boot: fix booting after r242230 arch_zfs_probe method is supposed to only probe for ZFS vdevs, but it can not expect that ZFS data is in a ready state yet. So, move some code from sparc64_zfs_probe to main to meet the constraints. Reported by: Chris Ross Tested by: Chris Ross MFC after: 4 days Modified: head/sys/boot/sparc64/loader/main.c Modified: head/sys/boot/sparc64/loader/main.c ============================================================================== --- head/sys/boot/sparc64/loader/main.c Sun Jan 20 19:44:33 2013 (r245696) +++ head/sys/boot/sparc64/loader/main.c Sun Jan 20 19:55:49 2013 (r245697) @@ -142,6 +142,10 @@ static vm_offset_t heapva; static char bootpath[64]; static phandle_t root; +#ifdef LOADER_ZFS_SUPPORT +static struct zfs_devdesc zfs_currdev; +#endif + /* * Machine dependent structures that the machine independent * loader part uses. @@ -732,7 +736,6 @@ static void sparc64_zfs_probe(void) { struct vtoc8 vtoc; - struct zfs_devdesc zfs_currdev; char alias[64], devname[sizeof(alias) + sizeof(":x") - 1]; char type[sizeof("device_type")]; char *bdev, *dev, *odev; @@ -805,9 +808,6 @@ sparc64_zfs_probe(void) zfs_currdev.root_guid = 0; zfs_currdev.d_dev = &zfs_dev; zfs_currdev.d_type = zfs_currdev.d_dev->dv_type; - (void)strncpy(bootpath, zfs_fmtdev(&zfs_currdev), - sizeof(bootpath) - 1); - bootpath[sizeof(bootpath) - 1] = '\0'; } } #endif /* LOADER_ZFS_SUPPORT */ @@ -878,10 +878,14 @@ main(int (*openfirm)(void *)) if ((*dp)->dv_init != 0) (*dp)->dv_init(); - /* - * Now that sparc64_zfs_probe() might have altered bootpath, - * export it. - */ +#ifdef LOADER_ZFS_SUPPORT + if (zfs_currdev.pool_guid != 0) { + (void)strncpy(bootpath, zfs_fmtdev(&zfs_currdev), + sizeof(bootpath) - 1); + bootpath[sizeof(bootpath) - 1] = '\0'; + } +#endif + env_setenv("currdev", EV_VOLATILE, bootpath, ofw_setcurrdev, env_nounset); env_setenv("loaddev", EV_VOLATILE, bootpath, From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 21:28:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EE66019C; Sun, 20 Jan 2013 21:28:05 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C8DFF691; Sun, 20 Jan 2013 21:28:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KLS568024324; Sun, 20 Jan 2013 21:28:05 GMT (envelope-from jilles@svn.freebsd.org) Received: (from jilles@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KLS5rI024323; Sun, 20 Jan 2013 21:28:05 GMT (envelope-from jilles@svn.freebsd.org) Message-Id: <201301202128.r0KLS5rI024323@svn.freebsd.org> From: Jilles Tjoelker Date: Sun, 20 Jan 2013 21:28:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245698 - head/bin/sh X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 21:28:06 -0000 Author: jilles Date: Sun Jan 20 21:28:05 2013 New Revision: 245698 URL: http://svnweb.freebsd.org/changeset/base/245698 Log: sh: Move some stackmarks to fix high memory usage in some loops. If a loop contained certain commands (such as redirected compound commands), the temporary memory for the redirection was not freed between iterations of the loop but only after the loop. Put a stackmark in evaltree(), freeing memory whenever a node has been evaluated. Some other stackmarks are then redundant; remove them. Example: while :; do { :; } nfor.args ; argp ; argp = argp->narg.next) { oexitstatus = exitstatus; @@ -375,7 +377,6 @@ evalfor(union node *n, int flags) } } loopnest--; - popstackmark(&smark); exitstatus = status; } @@ -392,16 +393,13 @@ evalcase(union node *n) union node *cp; union node *patp; struct arglist arglist; - struct stackmark smark; - setstackmark(&smark); arglist.lastp = &arglist.list; oexitstatus = exitstatus; expandarg(n->ncase.expr, &arglist, EXP_TILDE); for (cp = n->ncase.cases ; cp ; cp = cp->nclist.next) { for (patp = cp->nclist.pattern ; patp ; patp = patp->narg.next) { if (casematch(patp, arglist.list->text)) { - popstackmark(&smark); while (cp->nclist.next && cp->type == NCLISTFALLTHRU && cp->nclist.body == NULL) @@ -415,7 +413,6 @@ evalcase(union node *n) } } } - popstackmark(&smark); exitstatus = 0; return (NULL); } @@ -610,7 +607,7 @@ evalbackcmd(union node *n, struct backcm { int pip[2]; struct job *jp; - struct stackmark smark; /* unnecessary */ + struct stackmark smark; struct jmploc jmploc; struct jmploc *savehandler; struct localvar *savelocalvars; @@ -751,7 +748,6 @@ safe_builtin(int idx, int argc, char **a static void evalcommand(union node *cmd, int flags, struct backcmd *backcmd) { - struct stackmark smark; union node *argp; struct arglist arglist; struct arglist varlist; @@ -778,7 +774,6 @@ evalcommand(union node *cmd, int flags, /* First expand the arguments. */ TRACE(("evalcommand(%p, %d) called\n", (void *)cmd, flags)); - setstackmark(&smark); arglist.lastp = &arglist.list; varlist.lastp = &varlist.list; varflag = 1; @@ -1149,7 +1144,6 @@ out: setvar("_", lastarg, 0); if (do_clearcmdentry) clearcmdentry(); - popstackmark(&smark); } From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 22:25:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1F6A8906; Sun, 20 Jan 2013 22:25:26 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0D43F87C; Sun, 20 Jan 2013 22:25:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KMPP6x041838; Sun, 20 Jan 2013 22:25:25 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KMPPf5041837; Sun, 20 Jan 2013 22:25:25 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201301202225.r0KMPPf5041837@svn.freebsd.org> From: Joel Dahl Date: Sun, 20 Jan 2013 22:25:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245699 - head/bin/sh X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 22:25:26 -0000 Author: joel (doc committer) Date: Sun Jan 20 22:25:25 2013 New Revision: 245699 URL: http://svnweb.freebsd.org/changeset/base/245699 Log: Change the $ENV example to use .shrc instead of .shinit. This is consistent with what we use in /usr/share/skel/dot.profile. Discussed with: jilles Modified: head/bin/sh/sh.1 Modified: head/bin/sh/sh.1 ============================================================================== --- head/bin/sh/sh.1 Sun Jan 20 21:28:05 2013 (r245698) +++ head/bin/sh/sh.1 Sun Jan 20 22:25:25 2013 (r245699) @@ -32,7 +32,7 @@ .\" from: @(#)sh.1 8.6 (Berkeley) 5/4/95 .\" $FreeBSD$ .\" -.Dd January 14, 2013 +.Dd January 20, 2013 .Dt SH 1 .Os .Sh NAME @@ -138,10 +138,10 @@ variable to some file by placing the fol .Pa .profile in the home directory, substituting for -.Pa .shinit +.Pa .shrc the filename desired: .Pp -.Dl "ENV=$HOME/.shinit; export ENV" +.Dl "ENV=$HOME/.shrc; export ENV" .Pp The first non-option argument specified on the command line will be treated as the From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 22:25:59 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E4DA7A88; Sun, 20 Jan 2013 22:25:59 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C93DB88D; Sun, 20 Jan 2013 22:25:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KMPxVq041943; Sun, 20 Jan 2013 22:25:59 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KMPxYi041939; Sun, 20 Jan 2013 22:25:59 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301202225.r0KMPxYi041939@svn.freebsd.org> From: Nathan Whitehorn Date: Sun, 20 Jan 2013 22:25:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245700 - head/usr.sbin/bsdinstall/partedit X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 22:26:00 -0000 Author: nwhitehorn Date: Sun Jan 20 22:25:58 2013 New Revision: 245700 URL: http://svnweb.freebsd.org/changeset/base/245700 Log: Add a simple scripted partitioner. Documentation and more scripting support will come soon. This lets the install process have a line like: bsdinstall scriptedpart 'ada0 GPT {1.5G freebsd-ufs /, 10G freebsd-swap, auto freebsd-ufs /usr}' to set up a system with a 1.5GB /, some swap space, and a /usr using the rest of ada0. MFC after: 1 month Added: head/usr.sbin/bsdinstall/partedit/scripted.c (contents, props changed) Modified: head/usr.sbin/bsdinstall/partedit/Makefile head/usr.sbin/bsdinstall/partedit/partedit.c head/usr.sbin/bsdinstall/partedit/partedit.h Modified: head/usr.sbin/bsdinstall/partedit/Makefile ============================================================================== --- head/usr.sbin/bsdinstall/partedit/Makefile Sun Jan 20 22:25:25 2013 (r245699) +++ head/usr.sbin/bsdinstall/partedit/Makefile Sun Jan 20 22:25:58 2013 (r245700) @@ -2,7 +2,8 @@ BINDIR= /usr/libexec/bsdinstall PROG= partedit -LINKS= ${BINDIR}/partedit ${BINDIR}/autopart +LINKS= ${BINDIR}/partedit ${BINDIR}/autopart \ + ${BINDIR}/partedit ${BINDIR}/scriptedpart SYMLINKS= ${BINDIR}/partedit /usr/sbin/sade LDADD= -lgeom -lncursesw -lutil -ldialog -lm @@ -15,7 +16,7 @@ PARTEDIT_ARCH= generic .endif SRCS= diskeditor.c partedit.c gpart_ops.c partedit_${PARTEDIT_ARCH}.c \ - part_wizard.c + part_wizard.c scripted.c WARNS?= 3 MAN= sade.8 Modified: head/usr.sbin/bsdinstall/partedit/partedit.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/partedit.c Sun Jan 20 22:25:25 2013 (r245699) +++ head/usr.sbin/bsdinstall/partedit/partedit.c Sun Jan 20 22:25:58 2013 (r245700) @@ -96,13 +96,16 @@ main(int argc, const char **argv) prompt = "Please review the disk setup. When complete, press " "the Finish button."; part_wizard(); + } else if (strcmp(basename(argv[0]), "scriptedpart") == 0) { + scripted_editor(argc, argv); + prompt = NULL; } else { prompt = "Create partitions for FreeBSD. No changes will be " "made until you select Finish."; } /* Show the part editor either immediately, or to confirm wizard */ - while (1) { + while (prompt != NULL) { dlg_clear(); dlg_put_backtitle(); @@ -189,6 +192,15 @@ main(int argc, const char **argv) free(items); } + if (prompt == NULL) { + error = geom_gettree(&mesh); + if (validate_setup()) { + error = apply_changes(&mesh); + } else { + gpart_revert_all(&mesh); + error = -1; + } + } geom_deletetree(&mesh); free(items); Modified: head/usr.sbin/bsdinstall/partedit/partedit.h ============================================================================== --- head/usr.sbin/bsdinstall/partedit/partedit.h Sun Jan 20 22:25:25 2013 (r245699) +++ head/usr.sbin/bsdinstall/partedit/partedit.h Sun Jan 20 22:25:58 2013 (r245700) @@ -55,6 +55,7 @@ struct partition_metadata *get_part_meta void delete_part_metadata(const char *name); int part_wizard(void); +int scripted_editor(int argc, const char **argv); /* gpart operations */ void gpart_delete(struct gprovider *pp); Added: head/usr.sbin/bsdinstall/partedit/scripted.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.sbin/bsdinstall/partedit/scripted.c Sun Jan 20 22:25:58 2013 (r245700) @@ -0,0 +1,205 @@ +/*- + * Copyright (c) 2013 Nathan Whitehorn + * All rights reserved. + * + * 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 AUTHOR 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 AUTHOR 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. + * + * $FreeBSD$ + */ + +#include +#include +#include +#include + +#include +#include +#include + +#include "partedit.h" + +static struct gprovider * +provider_for_name(struct gmesh *mesh, const char *name) +{ + struct gclass *classp; + struct gprovider *pp = NULL; + struct ggeom *gp; + + LIST_FOREACH(classp, &mesh->lg_class, lg_class) { + if (strcmp(classp->lg_name, "DISK") != 0 && + strcmp(classp->lg_name, "PART") != 0 && + strcmp(classp->lg_name, "RAID") != 0 && + strcmp(classp->lg_name, "MD") != 0) + continue; + + LIST_FOREACH(gp, &classp->lg_geom, lg_geom) { + if (LIST_EMPTY(&gp->lg_provider)) + continue; + + LIST_FOREACH(pp, &gp->lg_provider, lg_provider) + if (strcmp(pp->lg_name, name) == 0) + break; + + if (pp != NULL) break; + } + + if (pp != NULL) break; + } + + return (pp); +} + +static int +part_config(char *disk, const char *scheme, char *config) +{ + char *partition, *ap, *size = NULL, *type = NULL, *mount = NULL; + struct gclass *classp; + struct gmesh mesh; + struct ggeom *gpart = NULL; + int error; + + if (scheme == NULL) + scheme = default_scheme(); + + error = geom_gettree(&mesh); + + /* Remove any existing partitioning and create new scheme */ + LIST_FOREACH(classp, &mesh.lg_class, lg_class) + if (strcmp(classp->lg_name, "PART") == 0) + break; + if (classp != NULL) { + LIST_FOREACH(gpart, &classp->lg_geom, lg_geom) + if (strcmp(gpart->lg_name, disk) == 0) + break; + } + if (gpart != NULL) + gpart_destroy(gpart); + gpart_partition(disk, scheme); + + if (strcmp(scheme, "PC98") == 0 || strcmp(scheme, "MBR") == 0) { + struct gmesh submesh; + geom_gettree(&submesh); + gpart_create(provider_for_name(&submesh, disk), + "freebsd", NULL, NULL, &disk, 0); + geom_deletetree(&submesh); + } else { + disk= strdup(disk); + } + + geom_deletetree(&mesh); + error = geom_gettree(&mesh); + + /* Create partitions */ + while ((partition = strsep(&config, ",")) != NULL) { + while ((ap = strsep(&partition, " \t\n")) != NULL) { + if (*ap == '\0') + continue; + if (size == NULL) + size = ap; + else if (type == NULL) + type = ap; + else if (mount == NULL) + mount = ap; + } + if (size == NULL) + continue; + if (strcmp(size, "auto") == 0) + size = NULL; + gpart_create(provider_for_name(&mesh, disk), type, size, mount, + NULL, 0); + geom_deletetree(&mesh); + error = geom_gettree(&mesh); + size = type = mount = NULL; + } + + geom_deletetree(&mesh); + free(disk); + + return (0); +} + +static +int parse_disk_config(char *input) +{ + char *ap; + char *disk = NULL, *scheme = NULL, *partconfig = NULL; + + while (input != NULL && *input != 0) { + if (isspace(*input)) { + input++; + continue; + } + + switch(*input) { + case '{': + input++; + partconfig = strchr(input, '}'); + if (partconfig == NULL) { + fprintf(stderr, "Malformed partition setup " + "string: %s\n", input); + return (1); + } + *partconfig = '\0'; + ap = partconfig+1; + partconfig = input; + input = ap; + break; + default: + if (disk == NULL) + disk = strsep(&input, " \t\n"); + else if (scheme == NULL) + scheme = strsep(&input, " \t\n"); + else { + fprintf(stderr, "Unknown directive: %s\n", + strsep(&input, " \t\n")); + return (1); + } + } + } while (input != NULL && *input != 0); + + if (disk != NULL) + part_config(disk, scheme, partconfig); + + return (0); +} + +int +scripted_editor(int argc, const char **argv) +{ + char *token; + int i, len = 0; + + for (i = 1; i < argc; i++) + len += strlen(argv[i]) + 1; + char inputbuf[len], *input = inputbuf; + strcpy(input, argv[1]); + for (i = 2; i < argc; i++) { + strcat(input, " "); + strcat(input, argv[i]); + } + + while ((token = strsep(&input, ";")) != NULL) + parse_disk_config(token); + + return (0); +} + From owner-svn-src-head@FreeBSD.ORG Sun Jan 20 23:04:22 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D16D26B5; Sun, 20 Jan 2013 23:04:22 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id AC369A2C; Sun, 20 Jan 2013 23:04:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0KN4Mfo053722; Sun, 20 Jan 2013 23:04:22 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0KN4Md8053718; Sun, 20 Jan 2013 23:04:22 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301202304.r0KN4Md8053718@svn.freebsd.org> From: Nathan Whitehorn Date: Sun, 20 Jan 2013 23:04:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245701 - head/usr.sbin/bsdinstall/partedit X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2013 23:04:22 -0000 Author: nwhitehorn Date: Sun Jan 20 23:04:21 2013 New Revision: 245701 URL: http://svnweb.freebsd.org/changeset/base/245701 Log: If no partition configuration is specified in {}, use the automatic setup the interactive installer uses. Example: bsdinstall scriptedpart ada0 Result: Use entire disk for a FreeBSD system with default partition layout Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c head/usr.sbin/bsdinstall/partedit/partedit.h head/usr.sbin/bsdinstall/partedit/scripted.c Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/part_wizard.c Sun Jan 20 22:25:58 2013 (r245700) +++ head/usr.sbin/bsdinstall/partedit/part_wizard.c Sun Jan 20 23:04:21 2013 (r245701) @@ -42,7 +42,6 @@ static char *boot_disk(struct gmesh *mesh); static char *wizard_partition(struct gmesh *mesh, const char *disk); -static int wizard_makeparts(struct gmesh *mesh, const char *disk); int part_wizard(void) { @@ -71,7 +70,7 @@ startwizard: dlg_put_backtitle(); error = geom_gettree(&mesh); - error = wizard_makeparts(&mesh, schemeroot); + error = wizard_makeparts(&mesh, schemeroot, 1); if (error) goto startwizard; free(schemeroot); @@ -288,8 +287,8 @@ query: return (retval); } -static int -wizard_makeparts(struct gmesh *mesh, const char *disk) +int +wizard_makeparts(struct gmesh *mesh, const char *disk, int interactive) { struct gmesh submesh; struct gclass *classp; @@ -310,7 +309,7 @@ wizard_makeparts(struct gmesh *mesh, con pp = provider_for_name(mesh, disk); available = gpart_max_free(gp, NULL)*pp->lg_sectorsize; - if (available < MIN_FREE_SPACE) { + if (interactive && available < MIN_FREE_SPACE) { char availablestr[10], neededstr[10], message[512]; humanize_number(availablestr, 7, available, "B", HN_AUTOSCALE, HN_DECIMAL); Modified: head/usr.sbin/bsdinstall/partedit/partedit.h ============================================================================== --- head/usr.sbin/bsdinstall/partedit/partedit.h Sun Jan 20 22:25:58 2013 (r245700) +++ head/usr.sbin/bsdinstall/partedit/partedit.h Sun Jan 20 23:04:21 2013 (r245701) @@ -56,6 +56,7 @@ void delete_part_metadata(const char *na int part_wizard(void); int scripted_editor(int argc, const char **argv); +int wizard_makeparts(struct gmesh *mesh, const char *disk, int interactive); /* gpart operations */ void gpart_delete(struct gprovider *pp); Modified: head/usr.sbin/bsdinstall/partedit/scripted.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/scripted.c Sun Jan 20 22:25:58 2013 (r245700) +++ head/usr.sbin/bsdinstall/partedit/scripted.c Sun Jan 20 23:04:21 2013 (r245701) @@ -109,6 +109,11 @@ part_config(char *disk, const char *sche error = geom_gettree(&mesh); /* Create partitions */ + if (config == NULL) { + wizard_makeparts(&mesh, disk, 0); + goto finished; + } + while ((partition = strsep(&config, ",")) != NULL) { while ((ap = strsep(&partition, " \t\n")) != NULL) { if (*ap == '\0') @@ -131,6 +136,7 @@ part_config(char *disk, const char *sche size = type = mount = NULL; } +finished: geom_deletetree(&mesh); free(disk); From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 01:01:33 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 91BAE361; Mon, 21 Jan 2013 01:01:33 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 82E6AEA9; Mon, 21 Jan 2013 01:01:33 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L11XNO088866; Mon, 21 Jan 2013 01:01:33 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L11XpT088863; Mon, 21 Jan 2013 01:01:33 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301210101.r0L11XpT088863@svn.freebsd.org> From: Nathan Whitehorn Date: Mon, 21 Jan 2013 01:01:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245702 - head/usr.sbin/bsdinstall/scripts X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 01:01:33 -0000 Author: nwhitehorn Date: Mon Jan 21 01:01:32 2013 New Revision: 245702 URL: http://svnweb.freebsd.org/changeset/base/245702 Log: Add a scripting frontend. Documentation and release(7) support coming later. Scripts take the form: ------------------------------------ PARTITIONS=ada0 DISTRIBUTIONS="kernel.txz base.txz ports.txz" #!/bin/sh echo "sshd_enable=YES" >> /etc/rc.conf pkg add puppet echo "System setup complete" ------------------------------------ The second part of the script (beginning with #!) is run in the newly installed system after the installation onto ada0 (with default partitioning, see scriptedpart for more complicated scenarios) is complete. Added: head/usr.sbin/bsdinstall/scripts/script (contents, props changed) Modified: head/usr.sbin/bsdinstall/scripts/Makefile Modified: head/usr.sbin/bsdinstall/scripts/Makefile ============================================================================== --- head/usr.sbin/bsdinstall/scripts/Makefile Sun Jan 20 23:04:21 2013 (r245701) +++ head/usr.sbin/bsdinstall/scripts/Makefile Mon Jan 21 01:01:32 2013 (r245702) @@ -2,7 +2,7 @@ SCRIPTS= auto adduser checksum config docsinstall hostname jail keymap \ mirrorselect mount netconfig netconfig_ipv4 netconfig_ipv6 rootpass \ - services time umount wlanconfig + script services time umount wlanconfig BINDIR= /usr/libexec/bsdinstall NO_MAN= true Added: head/usr.sbin/bsdinstall/scripts/script ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.sbin/bsdinstall/scripts/script Mon Jan 21 01:01:32 2013 (r245702) @@ -0,0 +1,87 @@ +#!/bin/sh +#- +# Copyright (c) 2013 Nathan Whitehorn +# All rights reserved. +# +# 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 AUTHOR 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 AUTHOR 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. +# +# $FreeBSD$ + +# VARIABLES: +# PARTITIONS +# DISTRIBUTIONS +# BSDINSTALL_DISTDIR + +error() { + test -f $PATH_FSTAB && bsdinstall umount + echo "Installation Error!" + cat $BSDINSTALL_LOG + echo "Installation Error!" + exit 1 +} + +set -e +trap error EXIT + +SCRIPT="$1" +shift + +echo "Begun Installation at $(date)" > $BSDINSTALL_LOG +rm -rf $BSDINSTALL_TMPETC +mkdir $BSDINSTALL_TMPETC + +split -a 2 -p '^#!.*' "$SCRIPT" /tmp/bsdinstall-installscript- +cd /tmp +echo BORK + +. bsdinstall-installscript-aa +: ${DISTRIBUTIONS="kernel.txz base.txz"}; export DISTRIBUTIONS +export BSDINSTALL_DISTDIR + +# Make partitions +rm -f $PATH_FSTAB +touch $PATH_FSTAB +bsdinstall scriptedpart "$PARTITIONS" +bsdinstall mount + +# Unpack distributions +bsdinstall checksum +bsdinstall distextract + +# Finalize install +bsdinstall config + +# Run post-install script +if [ -f /tmp/bsdinstall-installscript-ab ]; then + cp /tmp/bsdinstall-installscript-ab $BSDINSTALL_CHROOT/tmp/installscript + chmod a+x $BSDINSTALL_CHROOT/tmp/installscript + mount -t devfs devfs "$BSDINSTALL_CHROOT/dev" + chroot $BSDINSTALL_CHROOT /tmp/installscript $@ 2>&1 + umount "$BSDINSTALL_CHROOT/dev" + rm $BSDINSTALL_CHROOT/tmp/installscript +fi + +bsdinstall umount + +echo "Installation Completed at $(date)" >> $BSDINSTALL_LOG + +trap true EXIT From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 01:02:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 52E46518; Mon, 21 Jan 2013 01:02:50 +0000 (UTC) (envelope-from kientzle@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 44A5CED0; Mon, 21 Jan 2013 01:02:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L12od0089139; Mon, 21 Jan 2013 01:02:50 GMT (envelope-from kientzle@svn.freebsd.org) Received: (from kientzle@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L12oQC089138; Mon, 21 Jan 2013 01:02:50 GMT (envelope-from kientzle@svn.freebsd.org) Message-Id: <201301210102.r0L12oQC089138@svn.freebsd.org> From: Tim Kientzle Date: Mon, 21 Jan 2013 01:02:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245703 - head/sys/boot/fdt/dts X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 01:02:50 -0000 Author: kientzle Date: Mon Jan 21 01:02:49 2013 New Revision: 245703 URL: http://svnweb.freebsd.org/changeset/base/245703 Log: Use correct size for AM335x CPSW memory window. Modified: head/sys/boot/fdt/dts/beaglebone.dts Modified: head/sys/boot/fdt/dts/beaglebone.dts ============================================================================== --- head/sys/boot/fdt/dts/beaglebone.dts Mon Jan 21 01:01:32 2013 (r245702) +++ head/sys/boot/fdt/dts/beaglebone.dts Mon Jan 21 01:02:49 2013 (r245703) @@ -161,7 +161,7 @@ #address-cells = <1>; #size-cells = <1>; compatible = "ti,cpsw"; - reg = <0x4A100000 0x3000>; + reg = <0x4A100000 0x4000>; interrupts = <40 41 42 43>; interrupt-parent = <&AINTC>; phy-handle = <&phy0>; From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 01:33:10 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C700DAD4; Mon, 21 Jan 2013 01:33:10 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B523FFAB; Mon, 21 Jan 2013 01:33:10 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L1XA0j098365; Mon, 21 Jan 2013 01:33:10 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L1XAOa098364; Mon, 21 Jan 2013 01:33:10 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301210133.r0L1XAOa098364@svn.freebsd.org> From: Neel Natu Date: Mon, 21 Jan 2013 01:33:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245704 - head/sys/amd64/vmm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 01:33:10 -0000 Author: neel Date: Mon Jan 21 01:33:10 2013 New Revision: 245704 URL: http://svnweb.freebsd.org/changeset/base/245704 Log: Postpone vmm module initialization until after SMP is initialized - particularly that 'smp_started != 0'. This is required because the VT-x initialization calls smp_rendezvous() to set the CR4_VMXE bit on all the cpus. With this change we can preload vmm.ko from the loader. Reported by: alfred@, sbruno@ Obtained from: NetApp Modified: head/sys/amd64/vmm/vmm.c Modified: head/sys/amd64/vmm/vmm.c ============================================================================== --- head/sys/amd64/vmm/vmm.c Mon Jan 21 01:02:49 2013 (r245703) +++ head/sys/amd64/vmm/vmm.c Mon Jan 21 01:33:10 2013 (r245704) @@ -249,11 +249,15 @@ static moduledata_t vmm_kmod = { }; /* - * Execute the module load handler after the pci passthru driver has had - * a chance to claim devices. We need this information at the time we do - * iommu initialization. + * vmm initialization has the following dependencies: + * + * - iommu initialization must happen after the pci passthru driver has had + * a chance to attach to any passthru devices (after SI_SUB_CONFIGURE). + * + * - VT-x initialization requires smp_rendezvous() and therefore must happen + * after SMP is fully functional (after SI_SUB_SMP). */ -DECLARE_MODULE(vmm, vmm_kmod, SI_SUB_CONFIGURE + 1, SI_ORDER_ANY); +DECLARE_MODULE(vmm, vmm_kmod, SI_SUB_SMP + 1, SI_ORDER_ANY); MODULE_VERSION(vmm, 1); SYSCTL_NODE(_hw, OID_AUTO, vmm, CTLFLAG_RW, NULL, NULL); From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 01:46:37 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 19EEDCE5; Mon, 21 Jan 2013 01:46:37 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0D18C8A; Mon, 21 Jan 2013 01:46:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L1kaW8002084; Mon, 21 Jan 2013 01:46:36 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L1kaVW002083; Mon, 21 Jan 2013 01:46:36 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201301210146.r0L1kaVW002083@svn.freebsd.org> From: Adrian Chadd Date: Mon, 21 Jan 2013 01:46:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245705 - head/gnu/usr.bin/gdb/kgdb X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 01:46:37 -0000 Author: adrian Date: Mon Jan 21 01:46:36 2013 New Revision: 245705 URL: http://svnweb.freebsd.org/changeset/base/245705 Log: Add command-line support to kgdb to allow the baudrate to be set. This allows a remote session to be specified with '-r' as well as a non-default baudrate setting using '-b'. TODO: add to the kgdb manpage. MFC after: 2 weeks Modified: head/gnu/usr.bin/gdb/kgdb/main.c Modified: head/gnu/usr.bin/gdb/kgdb/main.c ============================================================================== --- head/gnu/usr.bin/gdb/kgdb/main.c Mon Jan 21 01:33:10 2013 (r245704) +++ head/gnu/usr.bin/gdb/kgdb/main.c Mon Jan 21 01:46:36 2013 (r245705) @@ -333,11 +333,24 @@ main(int argc, char *argv[]) args.argv = malloc(sizeof(char *)); args.argv[0] = argv[0]; - while ((ch = getopt(argc, argv, "ac:d:fn:qr:vw")) != -1) { + while ((ch = getopt(argc, argv, "ab:c:d:fn:qr:vw")) != -1) { switch (ch) { case 'a': annotation_level++; break; + case 'b': + { + int i; + char *p; + + i = strtol (optarg, &p, 0); + if (i == 0 && p == optarg) + warnx("warning: could not set baud rate to `%s'.\n", + optarg); + else + baud_rate = i; + } + break; case 'c': /* use given core file. */ if (vmcore != NULL) { warnx("option %c: can only be specified once", From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 01:55:54 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CF8802E8; Mon, 21 Jan 2013 01:55:54 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id BD9B6DD; Mon, 21 Jan 2013 01:55:54 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L1tswM004846; Mon, 21 Jan 2013 01:55:54 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L1tsvp004845; Mon, 21 Jan 2013 01:55:54 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301210155.r0L1tsvp004845@svn.freebsd.org> From: Nathan Whitehorn Date: Mon, 21 Jan 2013 01:55:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245706 - head/release X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 01:55:54 -0000 Author: nwhitehorn Date: Mon Jan 21 01:55:54 2013 New Revision: 245706 URL: http://svnweb.freebsd.org/changeset/base/245706 Log: More automated install support: if a script exists at /etc/installerconfig, point the installer there and then reboot without asking questions. This design subject to future change. Modified: head/release/rc.local Modified: head/release/rc.local ============================================================================== --- head/release/rc.local Mon Jan 21 01:46:36 2013 (r245705) +++ head/release/rc.local Mon Jan 21 01:55:54 2013 (r245706) @@ -45,6 +45,17 @@ else fi export TERM +if [ -f /etc/installerconfig ]; then + bsdinstall script /etc/installerconfig + if [ $? -eq 0]; then + dialog --backtitle "FreeBSD Installer" --title "Complete" --no-cancel --ok-label "Reboot" --pause "Installation of FreeBSD complete! Rebooting in 10 seconds" 10 30 10 + reboot + else + dialog --backtitle "FreeBSD Installer" --title "Error" --textbox /tmp/bsdinstall_log 0 0 + fi + exit +fi + dialog --backtitle "FreeBSD Installer" --title "Welcome" --extra-button --extra-label "Shell" --ok-label "Install" --cancel-label "Live CD" --yesno "Welcome to FreeBSD! Would you like to begin an installation or use the live CD?" 0 0 case $? in From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 02:47:15 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 44BF8957; Mon, 21 Jan 2013 02:47:15 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 372E4282; Mon, 21 Jan 2013 02:47:15 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L2lFug020258; Mon, 21 Jan 2013 02:47:15 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L2lF7d020257; Mon, 21 Jan 2013 02:47:15 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301210247.r0L2lF7d020257@svn.freebsd.org> From: Nathan Whitehorn Date: Mon, 21 Jan 2013 02:47:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245707 - head/usr.sbin/bsdinstall/scripts X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 02:47:15 -0000 Author: nwhitehorn Date: Mon Jan 21 02:47:14 2013 New Revision: 245707 URL: http://svnweb.freebsd.org/changeset/base/245707 Log: Remove some debugging code that snuck in. Modified: head/usr.sbin/bsdinstall/scripts/script Modified: head/usr.sbin/bsdinstall/scripts/script ============================================================================== --- head/usr.sbin/bsdinstall/scripts/script Mon Jan 21 01:55:54 2013 (r245706) +++ head/usr.sbin/bsdinstall/scripts/script Mon Jan 21 02:47:14 2013 (r245707) @@ -50,10 +50,8 @@ rm -rf $BSDINSTALL_TMPETC mkdir $BSDINSTALL_TMPETC split -a 2 -p '^#!.*' "$SCRIPT" /tmp/bsdinstall-installscript- -cd /tmp -echo BORK -. bsdinstall-installscript-aa +. /tmp/bsdinstall-installscript-aa : ${DISTRIBUTIONS="kernel.txz base.txz"}; export DISTRIBUTIONS export BSDINSTALL_DISTDIR From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 03:45:38 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 788E7147; Mon, 21 Jan 2013 03:45:38 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from duck.symmetricom.us (duck.symmetricom.us [206.168.13.214]) by mx1.freebsd.org (Postfix) with ESMTP id 50F5378C; Mon, 21 Jan 2013 03:45:37 +0000 (UTC) Received: from damnhippie.dyndns.org (daffy.symmetricom.us [206.168.13.218]) by duck.symmetricom.us (8.14.5/8.14.5) with ESMTP id r0L3jb92042182; Sun, 20 Jan 2013 20:45:37 -0700 (MST) (envelope-from ian@FreeBSD.org) Received: from [172.22.42.240] (revolution.hippie.lan [172.22.42.240]) by damnhippie.dyndns.org (8.14.3/8.14.3) with ESMTP id r0L3jEsR011007; Sun, 20 Jan 2013 20:45:14 -0700 (MST) (envelope-from ian@FreeBSD.org) Subject: Re: svn commit: r245707 - head/usr.sbin/bsdinstall/scripts From: Ian Lepore To: Nathan Whitehorn In-Reply-To: <201301210247.r0L2lF7d020257@svn.freebsd.org> References: <201301210247.r0L2lF7d020257@svn.freebsd.org> Content-Type: text/plain; charset="us-ascii" Date: Sun, 20 Jan 2013 20:45:13 -0700 Message-ID: <1358739913.32417.391.camel@revolution.hippie.lan> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 03:45:38 -0000 On Mon, 2013-01-21 at 02:47 +0000, Nathan Whitehorn wrote: > Author: nwhitehorn > Date: Mon Jan 21 02:47:14 2013 > New Revision: 245707 > URL: http://svnweb.freebsd.org/changeset/base/245707 > > Log: > Remove some debugging code that snuck in. > > Modified: > head/usr.sbin/bsdinstall/scripts/script > > Modified: head/usr.sbin/bsdinstall/scripts/script > ============================================================================== > --- head/usr.sbin/bsdinstall/scripts/script Mon Jan 21 01:55:54 2013 (r245706) > +++ head/usr.sbin/bsdinstall/scripts/script Mon Jan 21 02:47:14 2013 (r245707) > @@ -50,10 +50,8 @@ rm -rf $BSDINSTALL_TMPETC > mkdir $BSDINSTALL_TMPETC > > split -a 2 -p '^#!.*' "$SCRIPT" /tmp/bsdinstall-installscript- > -cd /tmp > -echo BORK > > -. bsdinstall-installscript-aa > +. /tmp/bsdinstall-installscript-aa > : ${DISTRIBUTIONS="kernel.txz base.txz"}; export DISTRIBUTIONS > export BSDINSTALL_DISTDIR > It's funny how often one sees this checkin message and very similar code. From someone at work last week: - -// fprintf(stderr, "oink\n"); } - Ian From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 04:06:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3826C6F7; Mon, 21 Jan 2013 04:06:05 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 13698844; Mon, 21 Jan 2013 04:06:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L464Zd047245; Mon, 21 Jan 2013 04:06:04 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L464os047243; Mon, 21 Jan 2013 04:06:04 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201301210406.r0L464os047243@svn.freebsd.org> From: Adrian Chadd Date: Mon, 21 Jan 2013 04:06:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245708 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 04:06:05 -0000 Author: adrian Date: Mon Jan 21 04:06:04 2013 New Revision: 245708 URL: http://svnweb.freebsd.org/changeset/base/245708 Log: Migrate CLRDMASK to be a per-node flag, rather than a per-TID flag. This is easily possible now that the TX is protected by a single lock, rather than a per-TXQ (and thus per-TID) lock. Only set CLRDMASK if none of the destinations are filtered. This likely will need some tuning when it comes time to do UASPD/PS-POLL TX, however at that point it should be manually set anyway. Tested: * AR9280, STA mode TODO: * More thorough testing in AP mode * test other chipsets, just to be safe/sure. Modified: head/sys/dev/ath/if_ath_tx.c head/sys/dev/ath/if_athvar.h Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Mon Jan 21 02:47:14 2013 (r245707) +++ head/sys/dev/ath/if_ath_tx.c Mon Jan 21 04:06:04 2013 (r245708) @@ -1397,12 +1397,13 @@ static void ath_tx_update_clrdmask(struct ath_softc *sc, struct ath_tid *tid, struct ath_buf *bf) { + struct ath_node *an = ATH_NODE(bf->bf_node); ATH_TX_LOCK_ASSERT(sc); - if (tid->clrdmask == 1) { + if (an->clrdmask == 1) { bf->bf_state.bfs_txflags |= HAL_TXDESC_CLRDMASK; - tid->clrdmask = 0; + an->clrdmask = 0; } } @@ -2888,6 +2889,29 @@ ath_tx_swq(struct ath_softc *sc, struct } /* + * Only set the clrdmask bit if none of the nodes are currently + * filtered. + * + * XXX TODO: go through all the callers and check to see + * which are being called in the context of looping over all + * TIDs (eg, if all tids are being paused, resumed, etc.) + * That'll avoid O(n^2) complexity here. + */ +static void +ath_tx_set_clrdmask(struct ath_softc *sc, struct ath_node *an) +{ + int i; + + ATH_TX_LOCK_ASSERT(sc); + + for (i = 0; i < IEEE80211_TID_SIZE; i++) { + if (an->an_tid[i].isfiltered == 1) + break; + } + an->clrdmask = 1; +} + +/* * Configure the per-TID node state. * * This likely belongs in if_ath_node.c but I can't think of anywhere @@ -2918,12 +2942,12 @@ ath_tx_tid_init(struct ath_softc *sc, st atid->sched = 0; atid->hwq_depth = 0; atid->cleanup_inprogress = 0; - atid->clrdmask = 1; /* Always start by setting this bit */ if (i == IEEE80211_NONQOS_TID) atid->ac = ATH_NONQOS_TID_AC; else atid->ac = TID_TO_WME_AC(i); } + an->clrdmask = 1; /* Always start by setting this bit */ } /* @@ -2949,7 +2973,6 @@ ath_tx_tid_pause(struct ath_softc *sc, s static void ath_tx_tid_resume(struct ath_softc *sc, struct ath_tid *tid) { - ATH_TX_LOCK_ASSERT(sc); tid->paused--; @@ -2964,7 +2987,7 @@ ath_tx_tid_resume(struct ath_softc *sc, * Override the clrdmask configuration for the next frame * from this TID, just to get the ball rolling. */ - tid->clrdmask = 1; + ath_tx_set_clrdmask(sc, tid->an); if (tid->axq_depth == 0) return; @@ -3047,7 +3070,8 @@ ath_tx_tid_filt_comp_complete(struct ath DPRINTF(sc, ATH_DEBUG_SW_TX_FILT, "%s: hwq=0, transition back\n", __func__); tid->isfiltered = 0; - tid->clrdmask = 1; + /* XXX ath_tx_tid_resume() also calls ath_tx_set_clrdmask()! */ + ath_tx_set_clrdmask(sc, tid->an); /* XXX this is really quite inefficient */ while ((bf = ATH_TID_FILT_LAST(tid, ath_bufhead_s)) != NULL) { @@ -3303,7 +3327,7 @@ ath_tx_tid_bar_tx(struct ath_softc *sc, * Override the clrdmask configuration for the next frame, * just to get the ball rolling. */ - tid->clrdmask = 1; + ath_tx_set_clrdmask(sc, tid->an); /* * Calculate new BAW left edge, now that all frames have either @@ -3484,7 +3508,7 @@ ath_tx_tid_drain(struct ath_softc *sc, s * * This won't hurt things if the TID is about to be freed. */ - tid->clrdmask = 1; + ath_tx_set_clrdmask(sc, tid->an); /* * Now that it's completed, grab the TID lock and update Modified: head/sys/dev/ath/if_athvar.h ============================================================================== --- head/sys/dev/ath/if_athvar.h Mon Jan 21 02:47:14 2013 (r245707) +++ head/sys/dev/ath/if_athvar.h Mon Jan 21 04:06:04 2013 (r245708) @@ -132,7 +132,6 @@ struct ath_tid { int bar_wait; /* waiting for BAR */ int bar_tx; /* BAR TXed */ int isfiltered; /* is this node currently filtered */ - int clrdmask; /* has clrdmask been set */ /* * Is the TID being cleaned up after a transition @@ -182,6 +181,7 @@ struct ath_node { struct mtx an_mtx; /* protecting the ath_node state */ uint32_t an_swq_depth; /* how many SWQ packets for this node */ + int clrdmask; /* has clrdmask been set */ /* variable-length rate control state follows */ }; #define ATH_NODE(ni) ((struct ath_node *)(ni)) From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 06:47:06 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C00A871; Mon, 21 Jan 2013 06:47:06 +0000 (UTC) (envelope-from jmallett@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B2B79DA4; Mon, 21 Jan 2013 06:47:06 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L6l6j2094662; Mon, 21 Jan 2013 06:47:06 GMT (envelope-from jmallett@svn.freebsd.org) Received: (from jmallett@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L6l6bC094661; Mon, 21 Jan 2013 06:47:06 GMT (envelope-from jmallett@svn.freebsd.org) Message-Id: <201301210647.r0L6l6bC094661@svn.freebsd.org> From: Juli Mallett Date: Mon, 21 Jan 2013 06:47:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245712 - head/sys/contrib/octeon-sdk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 06:47:06 -0000 Author: jmallett Date: Mon Jan 21 06:47:06 2013 New Revision: 245712 URL: http://svnweb.freebsd.org/changeset/base/245712 Log: Fix packet reception and other issues arising from incorrect ASX clock configuration on the physical ports of the Ubiquiti EdgeRouter Lite. Modified: head/sys/contrib/octeon-sdk/cvmx-helper-board.c Modified: head/sys/contrib/octeon-sdk/cvmx-helper-board.c ============================================================================== --- head/sys/contrib/octeon-sdk/cvmx-helper-board.c Mon Jan 21 06:46:17 2013 (r245711) +++ head/sys/contrib/octeon-sdk/cvmx-helper-board.c Mon Jan 21 06:47:06 2013 (r245712) @@ -1394,6 +1394,21 @@ int __cvmx_helper_board_hardware_enable( } } } +#if defined(OCTEON_VENDOR_UBIQUITI) + else if (cvmx_sysinfo_get()->board_type == CVMX_BOARD_TYPE_CUST_UBIQUITI_E100) + { + /* Configure ASX cloks for all ports on interface 0. */ + if (interface == 0) + { + int port; + + for (port = 0; port < 3; port++) { + cvmx_write_csr(CVMX_ASXX_TX_CLK_SETX(port, interface), 16); + cvmx_write_csr(CVMX_ASXX_RX_CLK_SETX(port, interface), 0); + } + } + } +#endif return 0; } From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 07:02:42 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7EC7317D; Mon, 21 Jan 2013 07:02:42 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 54850E4E; Mon, 21 Jan 2013 07:02:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L72g7t000602; Mon, 21 Jan 2013 07:02:42 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L72gvI000600; Mon, 21 Jan 2013 07:02:42 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201301210702.r0L72gvI000600@svn.freebsd.org> From: Hans Petter Selasky Date: Mon, 21 Jan 2013 07:02:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245725 - in head/sys/dev/usb: . quirk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 07:02:42 -0000 Author: hselasky Date: Mon Jan 21 07:02:41 2013 New Revision: 245725 URL: http://svnweb.freebsd.org/changeset/base/245725 Log: Add new quirk and correct old one. PR: usb/175454 MFC after: 1 week Modified: head/sys/dev/usb/quirk/usb_quirk.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- head/sys/dev/usb/quirk/usb_quirk.c Mon Jan 21 07:02:21 2013 (r245724) +++ head/sys/dev/usb/quirk/usb_quirk.c Mon Jan 21 07:02:41 2013 (r245725) @@ -302,7 +302,7 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_INQUIRY), USB_QUIRK(ONSPEC, READER, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_SCSI), USB_QUIRK(ONSPEC, UCF100, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, - UQ_MSC_FORCE_PROTO_ATAPI, UQ_MSC_NO_INQUIRY | UQ_MSC_NO_GETMAXLUN), + UQ_MSC_FORCE_PROTO_ATAPI, UQ_MSC_NO_INQUIRY, UQ_MSC_NO_GETMAXLUN), USB_QUIRK(ONSPEC2, IMAGEMATE_SDDR55, 0x0000, 0xffff, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_NO_GETMAXLUN), USB_QUIRK(PANASONIC, KXL840AN, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, @@ -338,6 +338,8 @@ static struct usb_quirk_entry usb_quirks UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_IGNORE_RESIDUE), USB_QUIRK(SANDISK, SDDR31, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_SCSI, UQ_MSC_READ_CAP_OFFBY1), + USB_QUIRK(SANDISK, IMAGEMATE_SDDR289, 0x0000, 0xffff, + UQ_MSC_NO_SYNC_CACHE, UQ_MSC_NO_GETMAXLUN), USB_QUIRK(SCANLOGIC, SL11R, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_BBB, UQ_MSC_FORCE_PROTO_ATAPI, UQ_MSC_NO_INQUIRY), USB_QUIRK(SHUTTLE, EUSB, 0x0000, 0xffff, UQ_MSC_FORCE_WIRE_CBI_I, Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Mon Jan 21 07:02:21 2013 (r245724) +++ head/sys/dev/usb/usbdevs Mon Jan 21 07:02:41 2013 (r245725) @@ -3561,6 +3561,7 @@ product SANDISK SDDR75 0x0810 ImageMate product SANDISK SDCZ2_256 0x7104 Cruzer Mini 256MB product SANDISK SDCZ4_128 0x7112 Cruzer Micro 128MB product SANDISK SDCZ4_256 0x7113 Cruzer Micro 256MB +product SANDISK IMAGEMATE_SDDR289 0xb6ba ImageMate SDDR-289 /* Sanwa Electric Instrument Co., Ltd. products */ product SANWA KB_USB2 0x0701 KB-USB2 multimeter cable From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 07:50:38 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DBAECBE9; Mon, 21 Jan 2013 07:50:38 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B6BF598; Mon, 21 Jan 2013 07:50:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L7ocDA014400; Mon, 21 Jan 2013 07:50:38 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L7ocAn014399; Mon, 21 Jan 2013 07:50:38 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201301210750.r0L7ocAn014399@svn.freebsd.org> From: Adrian Chadd Date: Mon, 21 Jan 2013 07:50:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245739 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 07:50:38 -0000 Author: adrian Date: Mon Jan 21 07:50:38 2013 New Revision: 245739 URL: http://svnweb.freebsd.org/changeset/base/245739 Log: Fix this routine to acutally break out and not set clrdmask if any of the TIDs are currently marked as "filtered." Modified: head/sys/dev/ath/if_ath_tx.c Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Mon Jan 21 07:45:25 2013 (r245738) +++ head/sys/dev/ath/if_ath_tx.c Mon Jan 21 07:50:38 2013 (r245739) @@ -2906,7 +2906,7 @@ ath_tx_set_clrdmask(struct ath_softc *sc for (i = 0; i < IEEE80211_TID_SIZE; i++) { if (an->an_tid[i].isfiltered == 1) - break; + return; } an->clrdmask = 1; } From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 08:12:59 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E770C242; Mon, 21 Jan 2013 08:12:59 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CFE4E1D9; Mon, 21 Jan 2013 08:12:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L8Cxw5022658; Mon, 21 Jan 2013 08:12:59 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L8Cxb4022656; Mon, 21 Jan 2013 08:12:59 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301210812.r0L8Cxb4022656@svn.freebsd.org> From: Neel Natu Date: Mon, 21 Jan 2013 08:12:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245740 - head/usr.sbin/bhyve X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 08:13:00 -0000 Author: neel Date: Mon Jan 21 08:12:59 2013 New Revision: 245740 URL: http://svnweb.freebsd.org/changeset/base/245740 Log: Get rid of redundant 'table_size' field in struct pi_msix. If needed it can always be calculated from the number of entries in the MSI-X table. Obtained from: NetApp Modified: head/usr.sbin/bhyve/pci_emul.h head/usr.sbin/bhyve/pci_passthru.c Modified: head/usr.sbin/bhyve/pci_emul.h ============================================================================== --- head/usr.sbin/bhyve/pci_emul.h Mon Jan 21 07:50:38 2013 (r245739) +++ head/usr.sbin/bhyve/pci_emul.h Mon Jan 21 08:12:59 2013 (r245740) @@ -119,7 +119,6 @@ struct pci_devinst { int table_bar; int pba_bar; size_t table_offset; - size_t table_size; int table_count; size_t pba_offset; struct msix_table_entry table[MAX_MSIX_TABLE_SIZE]; Modified: head/usr.sbin/bhyve/pci_passthru.c ============================================================================== --- head/usr.sbin/bhyve/pci_passthru.c Mon Jan 21 07:50:38 2013 (r245739) +++ head/usr.sbin/bhyve/pci_passthru.c Mon Jan 21 08:12:59 2013 (r245740) @@ -362,11 +362,10 @@ init_msix_table(struct vmctx *ctx, struc * XXX for now, assume that the table is not in the middle */ table_size = pi->pi_msix.table_count * MSIX_TABLE_ENTRY_SIZE; - pi->pi_msix.table_size = table_size; idx = pi->pi_msix.table_bar; /* Round up to page size */ - table_size = (table_size + 0x1000) & ~0xFFF; + table_size = roundup2(table_size, 4096); if (pi->pi_msix.table_offset == 0) { /* Map everything after the MSI-X table */ start = pi->pi_bar[idx].addr + table_size; From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 08:49:37 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id F4209E08; Mon, 21 Jan 2013 08:49:36 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.dawidek.net (garage.dawidek.net [91.121.88.72]) by mx1.freebsd.org (Postfix) with ESMTP id B1C358A5; Mon, 21 Jan 2013 08:49:35 +0000 (UTC) Received: from localhost (unknown [86.188.145.194]) by mail.dawidek.net (Postfix) with ESMTPSA id 433F44AF; Mon, 21 Jan 2013 09:46:56 +0100 (CET) Date: Mon, 21 Jan 2013 09:49:55 +0100 From: Pawel Jakub Dawidek To: Andrey Zonov Subject: Re: svn commit: r245696 - head/usr.sbin/inetd Message-ID: <20130121084936.GC1404@garage.freebsd.pl> References: <201301201944.r0KJiY0C094120@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="+JUInw4efm7IfTNU" Content-Disposition: inline In-Reply-To: <201301201944.r0KJiY0C094120@svn.freebsd.org> X-OS: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 08:49:37 -0000 --+JUInw4efm7IfTNU Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Jan 20, 2013 at 07:44:34PM +0000, Andrey Zonov wrote: > Author: zont > Date: Sun Jan 20 19:44:33 2013 > New Revision: 245696 > URL: http://svnweb.freebsd.org/changeset/base/245696 >=20 > Log: > - Force inetd to have listen queue size to be set to the value of > kern.ipc.somaxconn instead of hardcoded value 64. Hmm, I didn't know -1 can be provided to use default limit. Would you mind documenting it in listen(2)? > Submitted by: Andrey Ignatov > MFC after: 2 weeks >=20 > Modified: > head/usr.sbin/inetd/inetd.c >=20 > Modified: head/usr.sbin/inetd/inetd.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/usr.sbin/inetd/inetd.c Sun Jan 20 17:48:56 2013 (r245695) > +++ head/usr.sbin/inetd/inetd.c Sun Jan 20 19:44:33 2013 (r245696) > @@ -1387,7 +1387,7 @@ setsockopt(fd, SOL_SOCKET, opt, (char *) > } > } > if (sep->se_socktype =3D=3D SOCK_STREAM) > - listen(sep->se_fd, 64); > + listen(sep->se_fd, -1); > enable(sep); > if (debug) { > warnx("registered %s on %d", --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://tupytaj.pl --+JUInw4efm7IfTNU Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlD9ATMACgkQForvXbEpPzSg7wCfde9JAeCY8ZH/4CxX/Sr2nhO4 HpcAn2PmeVaWF0gwLNMLGhVgjyzj2tt8 =nLkh -----END PGP SIGNATURE----- --+JUInw4efm7IfTNU-- From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 08:54:40 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D7BB9166 for ; Mon, 21 Jan 2013 08:54:40 +0000 (UTC) (envelope-from andrey@zonov.org) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com [209.85.215.44]) by mx1.freebsd.org (Postfix) with ESMTP id 6134C8E0 for ; Mon, 21 Jan 2013 08:54:40 +0000 (UTC) Received: by mail-la0-f44.google.com with SMTP id eb20so4724305lab.17 for ; Mon, 21 Jan 2013 00:54:39 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:sender:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:x-enigmail-version:content-type :x-gm-message-state; bh=itH5eM+itwVYtKscBa8/qM1JrhhM4gC8TVU2JoRXQD0=; b=ktHx3G0PCjKBKkcetsFeNaU9L7siD++iUIXUaF76WM+ZIp28ldYRFw2t4cgl7t9D9a UB1dYiPKSqEzNI+3cq/0TXrnjrw3dVxB4eTA5Pf18+EOU0fRUEWHfxZVIIHcFdRtLJrE mQjw82X8v8JylpB5mP/pOkaMjMj1erTsBZjNydGbxAP2LQQPNj1irYvCzX6UWRY0CB83 H3bH2OzoW7XbR0bEo18YQ4oJDR2CWz4xWgRS0j+tYFX6WNycSULwwkZEv+V/dRXw0y+Q FBN3U4pABHwnO5bY5MXEvs4BtgkBZnSfo8KA+OKKjTkuOuplTz3o8De3Jzdj6x2QFHY0 mFeQ== X-Received: by 10.112.86.67 with SMTP id n3mr279694lbz.28.1358758478902; Mon, 21 Jan 2013 00:54:38 -0800 (PST) Received: from dhcp170-82-red.yandex.net ([2a02:6b8:0:401:f4b4:f051:2982:b49f]) by mx.google.com with ESMTPS id n7sm5010536lbg.3.2013.01.21.00.54.37 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 21 Jan 2013 00:54:37 -0800 (PST) Sender: Andrey Zonov Message-ID: <50FD0247.9050702@FreeBSD.org> Date: Mon, 21 Jan 2013 12:54:31 +0400 From: Andrey Zonov User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130107 Thunderbird/17.0.2 MIME-Version: 1.0 To: Pawel Jakub Dawidek Subject: Re: svn commit: r245696 - head/usr.sbin/inetd References: <201301201944.r0KJiY0C094120@svn.freebsd.org> <20130121084936.GC1404@garage.freebsd.pl> In-Reply-To: <20130121084936.GC1404@garage.freebsd.pl> X-Enigmail-Version: 1.5 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="----enig2LEUFWCLTIBGPCPKEPPGS" X-Gm-Message-State: ALoCoQkVbEoQA3KowTROVcknVBdZ8yCHbNxP1YiPvmuQJtDbmV8vP7U9zv0F/6Qz37jQUrTMop7M Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 08:54:41 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2LEUFWCLTIBGPCPKEPPGS Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 1/21/13 12:49 PM, Pawel Jakub Dawidek wrote: > On Sun, Jan 20, 2013 at 07:44:34PM +0000, Andrey Zonov wrote: >> Author: zont >> Date: Sun Jan 20 19:44:33 2013 >> New Revision: 245696 >> URL: http://svnweb.freebsd.org/changeset/base/245696 >> >> Log: >> - Force inetd to have listen queue size to be set to the value of >> kern.ipc.somaxconn instead of hardcoded value 64. >=20 > Hmm, I didn't know -1 can be provided to use default limit. > Would you mind documenting it in listen(2)? >=20 It's already documented there: The sysctl(3) MIB variable kern.ipc.soacceptqueue specifies a hard limit on backlog; if a value greater than kern.ipc.soacceptqueue or less t= han zero is specified, backlog is silently forced to kern.ipc.soacceptqueue. Note that kern.ipc.soacceptqueue is the same as kern.ipc.somaxconn. --=20 Andrey Zonov ------enig2LEUFWCLTIBGPCPKEPPGS Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.18 (Darwin) Comment: GPGTools - http://gpgtools.org iQEcBAEBAgAGBQJQ/QJLAAoJEBWLemxX/CvT/G4H/Aq+kaJDHN+KPxpAmTSHjkOL a5FVFsdCBS6nruinxaFEEFM54ZcPNv1TNWLTkaQyU9Zy1Azw4EbuQkN2Og3EXs38 ojgGAC9COS5vghvZ25XANo9SviWVsVbvcuulhTNt1RQ4voI+jhk6VqVWPfxv4UAm 9wJl+4IngHqlatks0xKAkuH/6C6VcJ2yHH1XAA8IbxlsuSUVUbp2vG5VFYgRwLId gb2XuzFUSnhqw1GxlOG2g8RNalOfvcXgx0mCubLQFKpftOEhw5eqstfxtZlRAzDA uo+4N5qENgH1S8tm46sBQSBslVBFfciF9+6httTGdHdzfKzjfVM1HaVg08Gih1U= =VCoW -----END PGP SIGNATURE----- ------enig2LEUFWCLTIBGPCPKEPPGS-- From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 08:59:32 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2498A403; Mon, 21 Jan 2013 08:59:32 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E40BE918; Mon, 21 Jan 2013 08:59:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0L8xVF8035415; Mon, 21 Jan 2013 08:59:31 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0L8xV08035414; Mon, 21 Jan 2013 08:59:31 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301210859.r0L8xV08035414@svn.freebsd.org> From: Gleb Smirnoff Date: Mon, 21 Jan 2013 08:59:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245741 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 08:59:32 -0000 Author: glebius Date: Mon Jan 21 08:59:31 2013 New Revision: 245741 URL: http://svnweb.freebsd.org/changeset/base/245741 Log: If lagg(4) can't forward a packet due to underlying port problems, return much more meaningful ENETDOWN to the stack, instead of EBUSY. Modified: head/sys/net/if_lagg.c Modified: head/sys/net/if_lagg.c ============================================================================== --- head/sys/net/if_lagg.c Mon Jan 21 08:12:59 2013 (r245740) +++ head/sys/net/if_lagg.c Mon Jan 21 08:59:31 2013 (r245741) @@ -789,7 +789,7 @@ lagg_port_output(struct ifnet *ifp, stru /* drop any other frames */ m_freem(m); - return (EBUSY); + return (ENETDOWN); } static void @@ -1862,7 +1862,7 @@ lagg_lacp_start(struct lagg_softc *sc, s lp = lacp_select_tx_port(sc, m); if (lp == NULL) { m_freem(m); - return (EBUSY); + return (ENETDOWN); } /* Send mbuf */ From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 09:19:43 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CBE10C10; Mon, 21 Jan 2013 09:19:43 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.dawidek.net (garage.dawidek.net [91.121.88.72]) by mx1.freebsd.org (Postfix) with ESMTP id 928CFA03; Mon, 21 Jan 2013 09:19:42 +0000 (UTC) Received: from localhost (unknown [86.188.145.194]) by mail.dawidek.net (Postfix) with ESMTPSA id 8990E4CE; Mon, 21 Jan 2013 10:17:09 +0100 (CET) Date: Mon, 21 Jan 2013 10:20:14 +0100 From: Pawel Jakub Dawidek To: Andrey Zonov Subject: Re: svn commit: r245696 - head/usr.sbin/inetd Message-ID: <20130121092014.GD1404@garage.freebsd.pl> References: <201301201944.r0KJiY0C094120@svn.freebsd.org> <20130121084936.GC1404@garage.freebsd.pl> <50FD0247.9050702@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="iBwuxWUsK/REspAd" Content-Disposition: inline In-Reply-To: <50FD0247.9050702@FreeBSD.org> X-OS: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 09:19:43 -0000 --iBwuxWUsK/REspAd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jan 21, 2013 at 12:54:31PM +0400, Andrey Zonov wrote: > On 1/21/13 12:49 PM, Pawel Jakub Dawidek wrote: > > On Sun, Jan 20, 2013 at 07:44:34PM +0000, Andrey Zonov wrote: > >> Author: zont > >> Date: Sun Jan 20 19:44:33 2013 > >> New Revision: 245696 > >> URL: http://svnweb.freebsd.org/changeset/base/245696 > >> > >> Log: > >> - Force inetd to have listen queue size to be set to the value of > >> kern.ipc.somaxconn instead of hardcoded value 64. > >=20 > > Hmm, I didn't know -1 can be provided to use default limit. > > Would you mind documenting it in listen(2)? > >=20 >=20 > It's already documented there: >=20 > The sysctl(3) MIB variable kern.ipc.soacceptqueue specifies a hard > limit > on backlog; if a value greater than kern.ipc.soacceptqueue or less t= han > zero is specified, backlog is silently forced to > kern.ipc.soacceptqueue. >=20 > Note that kern.ipc.soacceptqueue is the same as kern.ipc.somaxconn. Indeed, thanks. --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://tupytaj.pl --iBwuxWUsK/REspAd Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlD9CE4ACgkQForvXbEpPzSSkgCfUJUN+qFn3SgR586VAwH/w9UL FOwAoM+4LUsmudcuPUKrDiA/U25990nW =d0Um -----END PGP SIGNATURE----- --iBwuxWUsK/REspAd-- From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 14:06:34 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6C891108; Mon, 21 Jan 2013 14:06:34 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5D7FE248; Mon, 21 Jan 2013 14:06:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LE6YfP029330; Mon, 21 Jan 2013 14:06:34 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LE6Yvv029329; Mon, 21 Jan 2013 14:06:34 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301211406.r0LE6Yvv029329@svn.freebsd.org> From: Nathan Whitehorn Date: Mon, 21 Jan 2013 14:06:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245742 - head/release X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 14:06:34 -0000 Author: nwhitehorn Date: Mon Jan 21 14:06:33 2013 New Revision: 245742 URL: http://svnweb.freebsd.org/changeset/base/245742 Log: Fix typo and simplify condition. Submitted by: Christoph Mallon Modified: head/release/rc.local Modified: head/release/rc.local ============================================================================== --- head/release/rc.local Mon Jan 21 08:59:31 2013 (r245741) +++ head/release/rc.local Mon Jan 21 14:06:33 2013 (r245742) @@ -46,8 +46,7 @@ fi export TERM if [ -f /etc/installerconfig ]; then - bsdinstall script /etc/installerconfig - if [ $? -eq 0]; then + if bsdinstall script /etc/installerconfig; then dialog --backtitle "FreeBSD Installer" --title "Complete" --no-cancel --ok-label "Reboot" --pause "Installation of FreeBSD complete! Rebooting in 10 seconds" 10 30 10 reboot else From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 16:26:04 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 29193681; Mon, 21 Jan 2013 16:26:04 +0000 (UTC) (envelope-from julian@freebsd.org) Received: from vps1.elischer.org (vps1.elischer.org [204.109.63.16]) by mx1.freebsd.org (Postfix) with ESMTP id D8204D52; Mon, 21 Jan 2013 16:26:03 +0000 (UTC) Received: from jre-mbp-2.int.fusionio.com ([216.51.42.66]) (authenticated bits=0) by vps1.elischer.org (8.14.5/8.14.5) with ESMTP id r0LGPl4A068340 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Mon, 21 Jan 2013 08:25:56 -0800 (PST) (envelope-from julian@freebsd.org) Message-ID: <50FD6C06.6030103@freebsd.org> Date: Mon, 21 Jan 2013 09:25:42 -0700 From: Julian Elischer User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:17.0) Gecko/20130107 Thunderbird/17.0.2 MIME-Version: 1.0 To: Adrian Chadd Subject: Re: svn commit: r245705 - head/gnu/usr.bin/gdb/kgdb References: <201301210146.r0L1kaVW002083@svn.freebsd.org> In-Reply-To: <201301210146.r0L1kaVW002083@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 16:26:04 -0000 On 1/20/13 6:46 PM, Adrian Chadd wrote: > Author: adrian > Date: Mon Jan 21 01:46:36 2013 > New Revision: 245705 > URL: http://svnweb.freebsd.org/changeset/base/245705 > > Log: > Add command-line support to kgdb to allow the baudrate to be set. > > This allows a remote session to be specified with '-r' as well as a > non-default baudrate setting using '-b'. --baud is the standard I think (from google) and kgdb seems to already accept set remotebaud 9600. > > TODO: add to the kgdb manpage. > > MFC after: 2 weeks > > Modified: > head/gnu/usr.bin/gdb/kgdb/main.c > > Modified: head/gnu/usr.bin/gdb/kgdb/main.c > ============================================================================== > --- head/gnu/usr.bin/gdb/kgdb/main.c Mon Jan 21 01:33:10 2013 (r245704) > +++ head/gnu/usr.bin/gdb/kgdb/main.c Mon Jan 21 01:46:36 2013 (r245705) > @@ -333,11 +333,24 @@ main(int argc, char *argv[]) > args.argv = malloc(sizeof(char *)); > args.argv[0] = argv[0]; > > - while ((ch = getopt(argc, argv, "ac:d:fn:qr:vw")) != -1) { > + while ((ch = getopt(argc, argv, "ab:c:d:fn:qr:vw")) != -1) { > switch (ch) { > case 'a': > annotation_level++; > break; > + case 'b': > + { > + int i; > + char *p; > + > + i = strtol (optarg, &p, 0); > + if (i == 0 && p == optarg) > + warnx("warning: could not set baud rate to `%s'.\n", > + optarg); > + else > + baud_rate = i; > + } > + break; > case 'c': /* use given core file. */ > if (vmcore != NULL) { > warnx("option %c: can only be specified once", > From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 17:37:24 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 51EC915A; Mon, 21 Jan 2013 17:37:24 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2CD9815F; Mon, 21 Jan 2013 17:37:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LHbOiZ096105; Mon, 21 Jan 2013 17:37:24 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LHbOva096104; Mon, 21 Jan 2013 17:37:24 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301211737.r0LHbOva096104@svn.freebsd.org> From: David Chisnall Date: Mon, 21 Jan 2013 17:37:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245745 - head/contrib/libcxxrt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 17:37:24 -0000 Author: theraven Date: Mon Jan 21 17:37:23 2013 New Revision: 245745 URL: http://svnweb.freebsd.org/changeset/base/245745 Log: Import new fix from libcxxrt. This fixes the case where you attempt to rethrow an exception when you haven't caught one. This is largely a cosmetic fix, as (unless you have a very unusual terminate handler installed) it will print a nice error and then abort, rather than just aborting. MFC after: 7 days Modified: head/contrib/libcxxrt/exception.cc Directory Properties: head/contrib/libcxxrt/ (props changed) Modified: head/contrib/libcxxrt/exception.cc ============================================================================== --- head/contrib/libcxxrt/exception.cc Mon Jan 21 17:32:31 2013 (r245744) +++ head/contrib/libcxxrt/exception.cc Mon Jan 21 17:37:23 2013 (r245745) @@ -801,7 +801,7 @@ extern "C" void __cxa_decrement_exceptio */ extern "C" void __cxa_rethrow() { - __cxa_thread_info *ti = thread_info_fast(); + __cxa_thread_info *ti = thread_info(); __cxa_eh_globals *globals = &ti->globals; // Note: We don't remove this from the caught list here, because // __cxa_end_catch will be called when we unwind out of the try block. We From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 18:26:30 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1552DEC3; Mon, 21 Jan 2013 18:26:30 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-oa0-f52.google.com (mail-oa0-f52.google.com [209.85.219.52]) by mx1.freebsd.org (Postfix) with ESMTP id 84C626BE; Mon, 21 Jan 2013 18:26:29 +0000 (UTC) Received: by mail-oa0-f52.google.com with SMTP id o6so6461701oag.11 for ; Mon, 21 Jan 2013 10:26:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=Zzpnz8mnfaddiBIj2kJTgE2cY5PoXmF6jsCn0WwjDCs=; b=FFdIXbcijGKQy9HJeOws+xyiQnVQ9wHojChI1Qvhphi14+7I6DN+xAYZuGCFX0VDTQ xapDogXBypAAbo+/Gr/BFL+vOjtFtUt/rwaSqV97El5NG9aeIOr+qHCLQAZ9g+EJuLmm btmD3QUIZHsgo949Dv6xuxT3K+PtLDYKLxdQa9Kq8fCNOPQTVZUxS6abvC579KZgjB5B z4Z+z8u8hnoWDH6Xhu8bCVqZD+Qv8Mi76gipXcaEbzHj56lvSOdlV7nfb0sru3Mx8iK3 5bBhIK8HEQvfSpN+DzHMZ2m7opA5ZqEz2hmD70cznO6wevVLpqZH42PT/HQ5P/hsSVA6 fmtA== MIME-Version: 1.0 X-Received: by 10.60.171.38 with SMTP id ar6mr14498193oec.1.1358792783241; Mon, 21 Jan 2013 10:26:23 -0800 (PST) Sender: carpeddiem@gmail.com Received: by 10.60.25.163 with HTTP; Mon, 21 Jan 2013 10:26:23 -0800 (PST) In-Reply-To: <50FD6C06.6030103@freebsd.org> References: <201301210146.r0L1kaVW002083@svn.freebsd.org> <50FD6C06.6030103@freebsd.org> Date: Mon, 21 Jan 2013 13:26:23 -0500 X-Google-Sender-Auth: s5DiHUOdDJoRjzckTuItaMbfON0 Message-ID: Subject: Re: svn commit: r245705 - head/gnu/usr.bin/gdb/kgdb From: Ed Maste To: Julian Elischer Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, Adrian Chadd , src-committers@freebsd.org, svn-src-all@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 18:26:30 -0000 On 21 January 2013 11:25, Julian Elischer wrote: > > --baud is the standard I think (from google) and kgdb seems to already > accept > > set remotebaud 9600. >From gdb(1), | -b bps Set the line speed (baud rate or bits per second) of any serial | interface used by GDB for remote debugging. From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 20:15:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0EA313E3; Mon, 21 Jan 2013 20:15:36 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E91A4ABD; Mon, 21 Jan 2013 20:15:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LKFZak045175; Mon, 21 Jan 2013 20:15:35 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LKFZuU045173; Mon, 21 Jan 2013 20:15:35 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201301212015.r0LKFZuU045173@svn.freebsd.org> From: Sergey Kandaurov Date: Mon, 21 Jan 2013 20:15:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245746 - head/share/man/man9 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 20:15:36 -0000 Author: pluknet Date: Mon Jan 21 20:15:35 2013 New Revision: 245746 URL: http://svnweb.freebsd.org/changeset/base/245746 Log: Use C99 sparse initialization for struct vfsops in pseudocode. Where here, use conventional fsname. Modified: head/share/man/man9/VFS_SET.9 Modified: head/share/man/man9/VFS_SET.9 ============================================================================== --- head/share/man/man9/VFS_SET.9 Mon Jan 21 17:37:23 2013 (r245745) +++ head/share/man/man9/VFS_SET.9 Mon Jan 21 20:15:35 2013 (r245746) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 5, 2007 +.Dd January 22, 2012 .Dt VFS_SET 9 .Os .Sh NAME @@ -87,23 +87,13 @@ sysctl is set to * fill in the ones we use, and use the vfs_std for the rest. */ static struct vfsops myfs_vfsops = { - myfs_mount, - vfs_stdstart, - myfs_unmount, - myfs_root, - vfs_stdquotactl, - myfs_statfs, - vfs_stdsync, - vfs_stdvget, - vfs_stdfhtovp, - vfs_stdcheckexp, - vfs_stdvptofh, - vfs_stdinit, - vfs_stduninit, - vfs_stdextattrctl, + .vfs_mount = myfs_mount, + .vfs_root = myfs_root, + .vfs_statfs = myfs_statfs, + .vfs_unmount = myfs_unmount, }; -VFS_SET(myfs_vfsops, skelfs, 0); +VFS_SET(myfs_vfsops, myfs, 0); .Ed .Sh SEE ALSO .Xr jail 2 , From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 21:26:42 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EB7A3623; Mon, 21 Jan 2013 21:26:42 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C5D19E83; Mon, 21 Jan 2013 21:26:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LLQga5066265; Mon, 21 Jan 2013 21:26:42 GMT (envelope-from jkim@svn.freebsd.org) Received: (from jkim@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LLQgJ5066264; Mon, 21 Jan 2013 21:26:42 GMT (envelope-from jkim@svn.freebsd.org) Message-Id: <201301212126.r0LLQgJ5066264@svn.freebsd.org> From: Jung-uk Kim Date: Mon, 21 Jan 2013 21:26:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245748 - head/sys/contrib/dev/acpica/include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 21:26:43 -0000 Author: jkim Date: Mon Jan 21 21:26:42 2013 New Revision: 245748 URL: http://svnweb.freebsd.org/changeset/base/245748 Log: Fix another build breakage for ia64. Modified: head/sys/contrib/dev/acpica/include/acglobal.h Modified: head/sys/contrib/dev/acpica/include/acglobal.h ============================================================================== --- head/sys/contrib/dev/acpica/include/acglobal.h Mon Jan 21 20:15:49 2013 (r245747) +++ head/sys/contrib/dev/acpica/include/acglobal.h Mon Jan 21 21:26:42 2013 (r245748) @@ -420,7 +420,7 @@ ACPI_EXTERN UINT8 #ifdef ACPI_DISASSEMBLER -BOOLEAN ACPI_INIT_GLOBAL (AcpiGbl_IgnoreNoopOperator, FALSE); +ACPI_EXTERN BOOLEAN ACPI_INIT_GLOBAL (AcpiGbl_IgnoreNoopOperator, FALSE); ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_disasm; ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_verbose; From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 22:07:06 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0E408EB4; Mon, 21 Jan 2013 22:07:06 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DB04FFFE; Mon, 21 Jan 2013 22:07:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LM75Hh078061; Mon, 21 Jan 2013 22:07:05 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LM75bZ078059; Mon, 21 Jan 2013 22:07:05 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301212207.r0LM75bZ078059@svn.freebsd.org> From: Neel Natu Date: Mon, 21 Jan 2013 22:07:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245749 - head/usr.sbin/bhyve X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 22:07:06 -0000 Author: neel Date: Mon Jan 21 22:07:05 2013 New Revision: 245749 URL: http://svnweb.freebsd.org/changeset/base/245749 Log: Allocate the memory for the MSI-X table dynamically instead of allocating 32KB statically. In most cases the number of table entries will be far less than the maximum of 2048 allowed by the PCI specification. Reuse macros from pcireg.h to interpret the MSI-X capability instead of rolling our own. Obtained from: NetApp Modified: head/usr.sbin/bhyve/pci_emul.h head/usr.sbin/bhyve/pci_passthru.c Modified: head/usr.sbin/bhyve/pci_emul.h ============================================================================== --- head/usr.sbin/bhyve/pci_emul.h Mon Jan 21 21:26:42 2013 (r245748) +++ head/usr.sbin/bhyve/pci_emul.h Mon Jan 21 22:07:05 2013 (r245749) @@ -95,8 +95,7 @@ struct msix_table_entry { * In case the structure is modified to hold extra information, use a define * for the size that should be emulated. */ -#define MSIX_TABLE_ENTRY_SIZE 16 -#define MAX_MSIX_TABLE_SIZE 2048 +#define MSIX_TABLE_ENTRY_SIZE 16 struct pci_devinst { struct pci_devemu *pi_d; @@ -121,7 +120,7 @@ struct pci_devinst { size_t table_offset; int table_count; size_t pba_offset; - struct msix_table_entry table[MAX_MSIX_TABLE_SIZE]; + struct msix_table_entry *table; /* allocated at runtime */ } pi_msix; void *pi_arg; /* devemu-private data */ @@ -143,8 +142,8 @@ struct msixcap { uint8_t capid; uint8_t nextptr; uint16_t msgctrl; - uint32_t table_offset; - uint32_t pba_offset; + uint32_t table_info; /* bar index and offset within it */ + uint32_t pba_info; /* bar index and offset within it */ } __packed; void init_pci(struct vmctx *ctx); Modified: head/usr.sbin/bhyve/pci_passthru.c ============================================================================== --- head/usr.sbin/bhyve/pci_passthru.c Mon Jan 21 21:26:42 2013 (r245748) +++ head/usr.sbin/bhyve/pci_passthru.c Mon Jan 21 22:07:05 2013 (r245749) @@ -35,6 +35,8 @@ __FBSDID("$FreeBSD$"); #include #include +#include + #include #include @@ -59,9 +61,7 @@ __FBSDID("$FreeBSD$"); #define LEGACY_SUPPORT 1 -#define MSIX_TABLE_BIR_MASK 7 -#define MSIX_TABLE_OFFSET_MASK (~MSIX_TABLE_BIR_MASK); -#define MSIX_TABLE_COUNT(x) (((x) & 0x7FF) + 1) +#define MSIX_TABLE_COUNT(ctrl) (((ctrl) & PCIM_MSIXCTRL_TABLE_SIZE) + 1) #define MSIX_CAPLEN 12 static int pcifd = -1; @@ -161,7 +161,7 @@ passthru_add_msicap(struct pci_devinst * static int cfginitmsi(struct passthru_softc *sc) { - int ptr, capptr, cap, sts, caplen; + int i, ptr, capptr, cap, sts, caplen, table_size; uint32_t u32; struct pcisel sel; struct pci_devinst *pi; @@ -220,14 +220,25 @@ cfginitmsi(struct passthru_softc *sc) if (sc->psc_msix.capoff != 0) { pi->pi_msix.pba_bar = - msixcap.pba_offset & MSIX_TABLE_BIR_MASK; + msixcap.pba_info & PCIM_MSIX_BIR_MASK; pi->pi_msix.pba_offset = - msixcap.pba_offset & MSIX_TABLE_OFFSET_MASK; + msixcap.pba_info & ~PCIM_MSIX_BIR_MASK; pi->pi_msix.table_bar = - msixcap.table_offset & MSIX_TABLE_BIR_MASK; + msixcap.table_info & PCIM_MSIX_BIR_MASK; pi->pi_msix.table_offset = - msixcap.table_offset & MSIX_TABLE_OFFSET_MASK; + msixcap.table_info & ~PCIM_MSIX_BIR_MASK; pi->pi_msix.table_count = MSIX_TABLE_COUNT(msixcap.msgctrl); + + /* Allocate the emulated MSI-X table array */ + table_size = pi->pi_msix.table_count * MSIX_TABLE_ENTRY_SIZE; + pi->pi_msix.table = malloc(table_size); + bzero(pi->pi_msix.table, table_size); + + /* Mask all table entries */ + for (i = 0; i < pi->pi_msix.table_count; i++) { + pi->pi_msix.table[i].vector_control |= + PCIM_MSIX_VCTRL_MASK; + } } #ifdef LEGACY_SUPPORT @@ -268,9 +279,13 @@ msix_table_read(struct passthru_softc *s int index; pi = sc->psc_pi; - entry_offset = offset % MSIX_TABLE_ENTRY_SIZE; + index = offset / MSIX_TABLE_ENTRY_SIZE; + if (index >= pi->pi_msix.table_count) + return (-1); + entry = &pi->pi_msix.table[index]; + entry_offset = offset % MSIX_TABLE_ENTRY_SIZE; switch(size) { case 1: @@ -308,9 +323,12 @@ msix_table_write(struct vmctx *ctx, int int error, index; pi = sc->psc_pi; - entry_offset = offset % MSIX_TABLE_ENTRY_SIZE; index = offset / MSIX_TABLE_ENTRY_SIZE; + if (index >= pi->pi_msix.table_count) + return; + entry = &pi->pi_msix.table[index]; + entry_offset = offset % MSIX_TABLE_ENTRY_SIZE; /* Only 4 byte naturally-aligned writes are supported */ assert(size == 4); From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 22:07:34 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D11229C; Mon, 21 Jan 2013 22:07:34 +0000 (UTC) (envelope-from pjd@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id BE64669; Mon, 21 Jan 2013 22:07:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LM7Y80078172; Mon, 21 Jan 2013 22:07:34 GMT (envelope-from pjd@svn.freebsd.org) Received: (from pjd@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LM7Yf3078171; Mon, 21 Jan 2013 22:07:34 GMT (envelope-from pjd@svn.freebsd.org) Message-Id: <201301212207.r0LM7Yf3078171@svn.freebsd.org> From: Pawel Jakub Dawidek Date: Mon, 21 Jan 2013 22:07:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245750 - head/lib/libc/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 22:07:34 -0000 Author: pjd Date: Mon Jan 21 22:07:34 2013 New Revision: 245750 URL: http://svnweb.freebsd.org/changeset/base/245750 Log: Note that SIGCHLD is special and if ignored, won't be recorded by the filter. Modified: head/lib/libc/sys/kqueue.2 Modified: head/lib/libc/sys/kqueue.2 ============================================================================== --- head/lib/libc/sys/kqueue.2 Mon Jan 21 22:07:05 2013 (r245749) +++ head/lib/libc/sys/kqueue.2 Mon Jan 21 22:07:34 2013 (r245750) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 15, 2012 +.Dd January 21, 2013 .Dt KQUEUE 2 .Os .Sh NAME @@ -417,7 +417,9 @@ and facilities, and has a lower precedence. The filter will record all attempts to deliver a signal to a process, even if the signal has -been marked as SIG_IGN. +been marked as SIG_IGN, except for the +.Dv SIGCHLD +signal, which, if ignored, won't be recorded by the filter. Event notification happens after normal signal delivery processing. .Va data From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 22:32:01 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3874EC13; Mon, 21 Jan 2013 22:32:01 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 261C815E; Mon, 21 Jan 2013 22:32:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LMW1bl086672; Mon, 21 Jan 2013 22:32:01 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LMW1F0086670; Mon, 21 Jan 2013 22:32:01 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301212232.r0LMW1F0086670@svn.freebsd.org> From: Brooks Davis Date: Mon, 21 Jan 2013 22:32:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245751 - head/tools X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 22:32:01 -0000 Author: brooks Date: Mon Jan 21 22:32:00 2013 New Revision: 245751 URL: http://svnweb.freebsd.org/changeset/base/245751 Log: Implement the -l option using ln(1) to facilitate boostrapping. Ignore the new options -D, -h, -T, and -U. Adjust -M support to ignore an argument. Sponsored by: DARPA, AFRL Reviewed by: ian, ray, rpaulo Modified: head/tools/install.sh Modified: head/tools/install.sh ============================================================================== --- head/tools/install.sh Mon Jan 21 22:07:34 2013 (r245750) +++ head/tools/install.sh Mon Jan 21 22:32:00 2013 (r245751) @@ -30,12 +30,22 @@ # parse install's options and ignore them completely. dirmode="" +linkmode="" while [ $# -gt 0 ]; do case $1 in -d) dirmode="YES"; shift;; - -[bCcMpSsv]) shift;; - -[Bfgmo]) shift; shift;; - -[Bfgmo]*) shift;; + -[bCcpSsv]) shift;; + -[BDfghMmNoTU]) shift; shift;; + -[BDfghMmNoTU]*) shift;; + -l) + shift + case $1 in + *[sm]*) linkmode="symbolic";; # XXX: 'm' should prefer hard + *h*) linkmode="hard";; + *) echo "invalid link mode"; exit 1;; + esac + shift + ;; *) break; esac done @@ -51,7 +61,13 @@ if [ -z "$dirmode" ] && [ "$#" -lt 2 ]; fi # the remaining arguments are assumed to be files/dirs only. -if [ -z "$dirmode" ]; then +if [ -n "${linkmode}" ]; then + if [ "${linkmode}" == "symbolic" ]; then + ln -fsh "$@" + else + ln -f "$@" + fi +elif [ -z "$dirmode" ]; then exec install -p "$@" else exec install -d "$@" From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 22:40:41 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 04532E25; Mon, 21 Jan 2013 22:40:41 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DBE931A4; Mon, 21 Jan 2013 22:40:40 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LMee60088339; Mon, 21 Jan 2013 22:40:40 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LMedcF088022; Mon, 21 Jan 2013 22:40:39 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301212240.r0LMedcF088022@svn.freebsd.org> From: Brooks Davis Date: Mon, 21 Jan 2013 22:40:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245752 - in head: etc share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 22:40:41 -0000 Author: brooks Date: Mon Jan 21 22:40:39 2013 New Revision: 245752 URL: http://svnweb.freebsd.org/changeset/base/245752 Log: Replace all known uses of ln in the build process with appropriate install -l invocations via new INSTALL_LINK and INSTALL_SYMLINK variables. Sponsored by: DARPA, AFRL Reviewed by: ian, ray, rpaulo Modified: head/etc/Makefile head/share/mk/bsd.incs.mk head/share/mk/bsd.info.mk head/share/mk/bsd.lib.mk head/share/mk/bsd.links.mk head/share/mk/bsd.man.mk head/share/mk/bsd.own.mk Modified: head/etc/Makefile ============================================================================== --- head/etc/Makefile Mon Jan 21 22:32:00 2013 (r245751) +++ head/etc/Makefile Mon Jan 21 22:40:39 2013 (r245752) @@ -324,26 +324,29 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true - ln -sfh usr/src/sys ${DESTDIR}/sys + ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ - ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ - ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.UTF-8/; \ + ${INSTALL_SYMLINK} ../$$mandir \ + ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ + ${INSTALL_SYMLINK} ../$$mandir \ + ${DESTDIR}/usr/share/man/en.UTF-8/; \ done cd ${DESTDIR}/usr/share/openssl/man; \ for mandir in man*; do \ - ln -sfh ../$$mandir \ + ${INSTALL_SYMLINK} ../$$mandir \ ${DESTDIR}/usr/share/openssl/man/en.ISO8859-1/; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sfh "$$2" "${DESTDIR}/usr/share/man/$$1"; \ - ln -sfh "$$2" "${DESTDIR}/usr/share/openssl/man/$$1"; \ + ${INSTALL_SYMLINK} "$$2" "${DESTDIR}/usr/share/man/$$1"; \ + ${INSTALL_SYMLINK} "$$2" \ + "${DESTDIR}/usr/share/openssl/man/$$1"; \ shift; shift; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/nls.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sfh "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ + ${INSTALL_SYMLINK} "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ shift; shift; \ done Modified: head/share/mk/bsd.incs.mk ============================================================================== --- head/share/mk/bsd.incs.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.incs.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -73,7 +73,7 @@ installincludes: t=${DESTDIR}$$1; \ shift; \ ${ECHO} $$t -\> $$l; \ - ln -fs $$l $$t; \ + ${INSTALL_SYMLINK} $$l $$t; \ done; true .endif .endif # !target(installincludes) Modified: head/share/mk/bsd.info.mk ============================================================================== --- head/share/mk/bsd.info.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.info.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -113,7 +113,7 @@ DVIPS2ASCII?= dvips2ascii .info.html: ${INFO2HTML} ${.IMPSRC} - ln -f ${.TARGET:R}.info.Top.html ${.TARGET} + ${INSTALL_LINK} ${.TARGET:R}.info.Top.html ${.TARGET} .PATH: ${.CURDIR} ${SRCDIR} Modified: head/share/mk/bsd.lib.mk ============================================================================== --- head/share/mk/bsd.lib.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.lib.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -184,7 +184,7 @@ ${SHLIB_NAME_FULL}: ${SOBJS} @${ECHO} building shared library ${SHLIB_NAME} @rm -f ${SHLIB_NAME} ${SHLIB_LINK} .if defined(SHLIB_LINK) - @ln -fs ${SHLIB_NAME} ${SHLIB_LINK} + @${INSTALL_SYMLINK} ${SHLIB_NAME} ${SHLIB_LINK} .endif .if !defined(NM) @${CC} ${LDFLAGS} ${SSP_CFLAGS} ${SOLINKOPTS} \ @@ -309,9 +309,9 @@ _libinstall: ${_INSTALLFLAGS} lib${LIB}.ld ${DESTDIR}${LIBDIR}/${SHLIB_LINK} .else .if ${SHLIBDIR} == ${LIBDIR} - ln -fs ${SHLIB_NAME} ${DESTDIR}${LIBDIR}/${SHLIB_LINK} + ${INSTALL_SYMLINK} ${SHLIB_NAME} ${DESTDIR}${LIBDIR}/${SHLIB_LINK} .else - ln -fs ${_SHLIBDIRPREFIX}${SHLIBDIR}/${SHLIB_NAME} \ + ${INSTALL_SYMLINK} ${_SHLIBDIRPREFIX}${SHLIBDIR}/${SHLIB_NAME} \ ${DESTDIR}${LIBDIR}/${SHLIB_LINK} .if exists(${DESTDIR}${LIBDIR}/${SHLIB_NAME}) -chflags noschg ${DESTDIR}${LIBDIR}/${SHLIB_NAME} Modified: head/share/mk/bsd.links.mk ============================================================================== --- head/share/mk/bsd.links.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.links.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -15,7 +15,7 @@ _installlinks: t=${DESTDIR}$$1; \ shift; \ ${ECHO} $$t -\> $$l; \ - ln -f $$l $$t; \ + ${INSTALL_LINK} $$l $$t; \ done; true .endif .if defined(SYMLINKS) && !empty(SYMLINKS) @@ -26,6 +26,6 @@ _installlinks: t=${DESTDIR}$$1; \ shift; \ ${ECHO} $$t -\> $$l; \ - ln -fs $$l $$t; \ + ${INSTALL_SYMLINK} $$l $$t; \ done; true .endif Modified: head/share/mk/bsd.man.mk ============================================================================== --- head/share/mk/bsd.man.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.man.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -216,7 +216,7 @@ _maninstall: ${MAN} t=${DESTDIR}${MANDIR}$${sect}${MANSUBDIR}/$$name; \ ${ECHO} $${t}${ZEXT} -\> $${l}${ZEXT}; \ rm -f $${t} $${t}${MCOMPRESS_EXT}; \ - ln $${l}${ZEXT} $${t}${ZEXT}; \ + ${INSTALL_LINK} $${l}${ZEXT} $${t}${ZEXT}; \ done .if defined(MANBUILDCAT) && !empty(MANBUILDCAT) @set ${MLINKS:C/\.([^.]*)$/.\1 \1/}; \ @@ -231,7 +231,7 @@ _maninstall: ${MAN} t=${DESTDIR}${CATDIR}$${sect}${MANSUBDIR}/$$name; \ ${ECHO} $${t}${ZEXT} -\> $${l}${ZEXT}; \ rm -f $${t} $${t}${MCOMPRESS_EXT}; \ - ln $${l}${ZEXT} $${t}${ZEXT}; \ + ${INSTALL_LINK} $${l}${ZEXT} $${t}${ZEXT}; \ done .endif .endif Modified: head/share/mk/bsd.own.mk ============================================================================== --- head/share/mk/bsd.own.mk Mon Jan 21 22:32:00 2013 (r245751) +++ head/share/mk/bsd.own.mk Mon Jan 21 22:40:39 2013 (r245752) @@ -181,6 +181,15 @@ NLSMODE?= ${NOBINMODE} INCLUDEDIR?= /usr/include +# +# install(1) parameters. +# +HRDLINK?= -l h +SYMLINK?= -l s + +INSTALL_LINK?= ${INSTALL} ${HRDLINK} +INSTALL_SYMLINK?= ${INSTALL} ${SYMLINK} + # Common variables .if !defined(DEBUG_FLAGS) STRIP?= -s From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 22:54:44 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 03112224; Mon, 21 Jan 2013 22:54:44 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D4FDA23E; Mon, 21 Jan 2013 22:54:43 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LMsh5K092792; Mon, 21 Jan 2013 22:54:43 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LMshHG092791; Mon, 21 Jan 2013 22:54:43 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301212254.r0LMshHG092791@svn.freebsd.org> From: Brooks Davis Date: Mon, 21 Jan 2013 22:54:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245753 - head/share/info X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 22:54:44 -0000 Author: brooks Date: Mon Jan 21 22:54:43 2013 New Revision: 245753 URL: http://svnweb.freebsd.org/changeset/base/245753 Log: Install the template info directory with mode 644 instead of 444 to allow it to be updated by its owner without resorting to privilege. This is required by upcoming changes to allow installworld to work as a non-root user. Sponsored by: DARPA, AFRL Reviewed by: ian, ray, rpaulo Modified: head/share/info/Makefile Modified: head/share/info/Makefile ============================================================================== --- head/share/info/Makefile Mon Jan 21 22:40:39 2013 (r245752) +++ head/share/info/Makefile Mon Jan 21 22:54:43 2013 (r245753) @@ -17,6 +17,6 @@ beforeinstall: @exit 3; .endif .if !exists(${DESTDIR}${INFODIR}/dir) - ${INSTALL} -o ${INFOOWN} -g ${INFOGRP} -m ${INFOMODE} \ + ${INSTALL} -o ${INFOOWN} -g ${INFOGRP} -m 644 \ dir-tmpl ${DESTDIR}${INFODIR}/dir .endif From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 23:12:51 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A81AE4D3; Mon, 21 Jan 2013 23:12:51 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 83C932C0; Mon, 21 Jan 2013 23:12:51 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LNCphk098800; Mon, 21 Jan 2013 23:12:51 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LNCpw6098799; Mon, 21 Jan 2013 23:12:51 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301212312.r0LNCpw6098799@svn.freebsd.org> From: Brooks Davis Date: Mon, 21 Jan 2013 23:12:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245754 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 23:12:51 -0000 Author: brooks Date: Mon Jan 21 23:12:50 2013 New Revision: 245754 URL: http://svnweb.freebsd.org/changeset/base/245754 Log: Always bootstrap nmtree if it is not available on the host. It is fairly small and it is quite annoying to get all the way through buildworld only to discover that you forgot the DB_FROM_SRC (or soon NO_ROOT) option. Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Mon Jan 21 22:54:43 2013 (r245753) +++ head/Makefile.inc1 Mon Jan 21 23:12:50 2013 (r245754) @@ -1072,7 +1072,7 @@ _lex= usr.bin/lex _yacc= usr.bin/yacc .endif -.if defined(DB_FROM_SRC) && ${BOOTSTRAPPING} < 1000026 +.if ${BOOTSTRAPPING} < 1000026 _nmtree= lib/libnetbsd \ usr.sbin/nmtree .endif From owner-svn-src-head@FreeBSD.ORG Mon Jan 21 23:24:17 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CAB7D6B7; Mon, 21 Jan 2013 23:24:17 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B3A98302; Mon, 21 Jan 2013 23:24:17 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0LNOHaR002025; Mon, 21 Jan 2013 23:24:17 GMT (envelope-from gonzo@svn.freebsd.org) Received: (from gonzo@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0LNOHC5002023; Mon, 21 Jan 2013 23:24:17 GMT (envelope-from gonzo@svn.freebsd.org) Message-Id: <201301212324.r0LNOHC5002023@svn.freebsd.org> From: Oleksandr Tymoshenko Date: Mon, 21 Jan 2013 23:24:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245755 - head/sys/dev/mmc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Jan 2013 23:24:17 -0000 Author: gonzo Date: Mon Jan 21 23:24:16 2013 New Revision: 245755 URL: http://svnweb.freebsd.org/changeset/base/245755 Log: Fix highest voltage detection Submitted by: Daisuke Aoyama Approved by: imp@ Modified: head/sys/dev/mmc/mmc.c head/sys/dev/mmc/mmcreg.h Modified: head/sys/dev/mmc/mmc.c ============================================================================== --- head/sys/dev/mmc/mmc.c Mon Jan 21 23:12:50 2013 (r245754) +++ head/sys/dev/mmc/mmc.c Mon Jan 21 23:24:16 2013 (r245755) @@ -353,7 +353,8 @@ mmc_highest_voltage(uint32_t ocr) { int i; - for (i = 30; i >= 0; i--) + for (i = MMC_OCR_MAX_VOLTAGE_SHIFT; + i >= MMC_OCR_MIN_VOLTAGE_SHIFT; i--) if (ocr & (1 << i)) return (i); return (-1); Modified: head/sys/dev/mmc/mmcreg.h ============================================================================== --- head/sys/dev/mmc/mmcreg.h Mon Jan 21 23:12:50 2013 (r245754) +++ head/sys/dev/mmc/mmcreg.h Mon Jan 21 23:24:16 2013 (r245755) @@ -353,6 +353,7 @@ struct mmc_request { #define MMC_OCR_VOLTAGE 0x3fffffffU /* Vdd Voltage mask */ #define MMC_OCR_LOW_VOLTAGE (1u << 7) /* Low Voltage Range -- tbd */ #define MMC_OCR_200_210 (1U << 8) /* Vdd voltage 2.00 ~ 2.10 */ +#define MMC_OCR_MIN_VOLTAGE_SHIFT 8 #define MMC_OCR_210_220 (1U << 9) /* Vdd voltage 2.10 ~ 2.20 */ #define MMC_OCR_220_230 (1U << 10) /* Vdd voltage 2.20 ~ 2.30 */ #define MMC_OCR_230_240 (1U << 11) /* Vdd voltage 2.30 ~ 2.40 */ @@ -368,6 +369,7 @@ struct mmc_request { #define MMC_OCR_330_340 (1U << 21) /* Vdd voltage 3.30 ~ 3.40 */ #define MMC_OCR_340_350 (1U << 22) /* Vdd voltage 3.40 ~ 3.50 */ #define MMC_OCR_350_360 (1U << 23) /* Vdd voltage 3.50 ~ 3.60 */ +#define MMC_OCR_MAX_VOLTAGE_SHIFT 23 #define MMC_OCR_CCS (1u << 30) /* Card Capacity status (SD vs SDHC) */ #define MMC_OCR_CARD_BUSY (1U << 31) /* Card Power up status */ From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 01:10:48 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 88116D4A; Tue, 22 Jan 2013 01:10:48 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6443CAB2; Tue, 22 Jan 2013 01:10:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M1Am9H034808; Tue, 22 Jan 2013 01:10:48 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M1AmgA034807; Tue, 22 Jan 2013 01:10:48 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201301220110.r0M1AmgA034807@svn.freebsd.org> From: Glen Barber Date: Tue, 22 Jan 2013 01:10:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245756 - head/share/man/man5 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 01:10:48 -0000 Author: gjb (doc,ports committer) Date: Tue Jan 22 01:10:47 2013 New Revision: 245756 URL: http://svnweb.freebsd.org/changeset/base/245756 Log: - Mark SUP_UPDATE as deprecated in make.conf(5), providing instructions to use SVN_UPDATE or freebsd-update(8). - While here, remove bogus NO_WWWUPDATE. MFC after: 3 days Modified: head/share/man/man5/make.conf.5 Modified: head/share/man/man5/make.conf.5 ============================================================================== --- head/share/man/man5/make.conf.5 Mon Jan 21 23:24:16 2013 (r245755) +++ head/share/man/man5/make.conf.5 Tue Jan 22 01:10:47 2013 (r245756) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 14, 2012 +.Dd January 21, 2013 .Dt MAKE.CONF 5 .Os .Sh NAME @@ -255,10 +255,6 @@ Set this to not update the doc tree duri .Pq Vt bool Set this to not update the ports tree during .Dq Li "make update" . -.It Va NO_WWWUPDATE -.Pq Vt bool -Set this to not update the www tree during -.Dq Li "make update" . .It Va SUP .Pq Vt str The location of the @@ -309,6 +305,11 @@ and .Pa ports trees with .Dq Li "make update" . +This option is deprecated. +Please use +.Va SVN_UPDATE +or +.Xr freebsd-update 8 . .It Va SVN_UPDATE .Pq Vt bool Set this to use From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 01:18:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 20AA7F84; Tue, 22 Jan 2013 01:18:50 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EFE06AE2; Tue, 22 Jan 2013 01:18:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M1InmF036030; Tue, 22 Jan 2013 01:18:49 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M1Infx036029; Tue, 22 Jan 2013 01:18:49 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201301220118.r0M1Infx036029@svn.freebsd.org> From: Glen Barber Date: Tue, 22 Jan 2013 01:18:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245757 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 01:18:50 -0000 Author: gjb (doc,ports committer) Date: Tue Jan 22 01:18:49 2013 New Revision: 245757 URL: http://svnweb.freebsd.org/changeset/base/245757 Log: Chase r245756 of make.conf(5): - If update method is SUP_UPDATE or CVS, warn that those update methods are deprecated. - While here, remove bogus NO_WWWUPDATE. MFC after: 3 days X-MFC-with: r245756 Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Tue Jan 22 01:10:47 2013 (r245756) +++ head/Makefile.inc1 Tue Jan 22 01:18:49 2013 (r245757) @@ -12,7 +12,6 @@ # -DNO_KERNELOBJ do not run ${MAKE} obj in ${MAKE} buildkernel # -DNO_PORTSUPDATE do not update ports in ${MAKE} update # -DNO_DOCUPDATE do not update doc in ${MAKE} update -# -DNO_WWWUPDATE do not update www in ${MAKE} update # -DDB_FROM_SRC use the user/group databases in src/etc instead of # the system database when installing. # -DNO_CTF do not run the DTrace CTF conversion tools on built objects @@ -968,6 +967,13 @@ update: @echo "--------------------------------------------------------------" @echo ">>> Running ${SUP}" @echo "--------------------------------------------------------------" + @echo "!! WARNING WARNING WARNING WARNING WARNING WARNING WARNING !!" + @echo "!! Update methods with ${SUP} are deprecated." + @echo "!! Please see http://www.freebsd.org/handbook/svn.html" + @echo "!! and convert your update method to SVN_UPDATE or" + @echo "!! freebsd-update(8)." + @echo "!! WARNING WARNING WARNING WARNING WARNING WARNING WARNING !!" + @sleep 5 .if defined(SUPFILE) @${SUP} ${SUPFLAGS} ${SUPFILE} .endif @@ -983,9 +989,6 @@ update: .if defined(DOCSUPFILE) && !defined(NO_DOCUPDATE) @${SUP} ${SUPFLAGS} ${DOCSUPFILE} .endif -.if defined(WWWSUPFILE) && !defined(NO_WWWUPDATE) - @${SUP} ${SUPFLAGS} ${WWWSUPFILE} -.endif .endif .if defined(CVS_UPDATE) @cd ${.CURDIR} ; \ @@ -993,6 +996,13 @@ update: echo "--------------------------------------------------------------" ; \ echo ">>> Updating ${.CURDIR} from CVS repository" ${CVSROOT} ; \ echo "--------------------------------------------------------------" ; \ + echo "!! WARNING WARNING WARNING WARNING WARNING WARNING WARNING !!" ; \ + echo "!! Update methods with ${SUP} are deprecated." ; \ + echo "!! Please see http://www.freebsd.org/handbook/svn.html" ; \ + echo "!! and convert your update method to SVN_UPDATE or" ; \ + echo "!! freebsd-update(8)." ; \ + echo "!! WARNING WARNING WARNING WARNING WARNING WARNING WARNING !!" ; \ + sleep 5 ; \ echo ${CVS} -R -q update ${CVSFLAGS} ; \ ${CVS} -R -q update ${CVSFLAGS} ; \ fi From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 02:40:06 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C51CEE8A; Tue, 22 Jan 2013 02:40:06 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A8B42DD9; Tue, 22 Jan 2013 02:40:06 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M2e6Sr061402; Tue, 22 Jan 2013 02:40:06 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M2e67u061392; Tue, 22 Jan 2013 02:40:06 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301220240.r0M2e67u061392@svn.freebsd.org> From: Nathan Whitehorn Date: Tue, 22 Jan 2013 02:40:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245758 - head/usr.sbin/bsdinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 02:40:06 -0000 Author: nwhitehorn Date: Tue Jan 22 02:40:06 2013 New Revision: 245758 URL: http://svnweb.freebsd.org/changeset/base/245758 Log: Document bsdinstall scripting as it currently operates. It may change in the future depending on feedback from people using it to do unattended system setup. Modified: head/usr.sbin/bsdinstall/bsdinstall.8 Modified: head/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 01:18:49 2013 (r245757) +++ head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 02:40:06 2013 (r245758) @@ -52,9 +52,10 @@ can be invoked separately by an installa .Sh TARGETS Most of the following targets are only useful for scripting the installer. For interactive use, most users will be interested only in the -.Cm auto +.Cm auto , +.Cm jail , and -.Cm jail +.Cm script targets. .Bl -tag -width ".Cm jail Ar destination" .It Cm auto @@ -68,6 +69,12 @@ Behavior is generally similar to .Cm auto , except that disk partitioning and network setup are skipped and a kernel is not installed into the new system. +.It Cm script Ar script +Runs the installation script at +.Pa script . +See +.Sx SCRIPTING +for more information on this target. .It Cm keymap If the current controlling TTY is a .Xr syscons 4 @@ -104,11 +111,60 @@ partition schemes. Partitions disks, run .Xr newfs 8 , and writes the new system's .Pa fstab . +.It Cm scriptedpart Ar parameters +Sets up disks like +.Cm autopart +and +.Cm partedit , +but non-interactively according to the disk setup specified in +.Ar parameters . +Each disk setup is specified by a three-part argument: +.Pp +.Ar disk [scheme] [{partitions}] +.Pp +Multiple disk setups are separated by semicolons. The +.Ar disk +argument specifies the disk on which to operate (which will be erased), +while the +.Ar scheme +argument specifies the +.Xr gpart 8 +partition scheme to apply to the disk. If +.Ar scheme +is unspecified, +.Cm scriptedpart +will apply the default bootable scheme on your platform. +The +.Ar partitions +argument is also optional and specifies how to partition +.Ar disk . +It consists of a comma-separated list of partitions to create enclosed in +curly braces. Each partition declaration takes the form +.Pp +.Ar size type [mount point] +.Pp +.Ar size +specifies the partition size to create in bytes (K, M, and G suffixes +can be appended to specify kilobytes, megabytes, and gigabytes respectively), +while the +.Em auto +keyword causes the partition to take all the remaining space on the disk. The +.Ar type +option chooses the +.Xr gpart 8 +filesystem type (e.g. freebsd-ufs or freebsd-swap). +The optional +.Ar mount point +argument sets where the created partition is to be mounted in the installed +system. As an example, a typical invocation looks like: +.Pp +bsdinstall scriptedpart ada0 { 20G freebsd-ufs /, 4G freebsd-swap, 20G freebsd-ufs /var, auto freebsd-ufs /usr } .It Cm mount Mounts the file systems previously configured by -.Cm autopart +.Cm autopart , +.Cm partedit , or -.Cm partedit +.Cm scriptedpart under .Ev BSDINSTALL_CHROOT . .It Cm distfetch @@ -177,6 +233,64 @@ target is executed. If this directory do created. Default: .Pa /tmp/bsdinstall_etc .El +.Sh SCRIPTING +.Nm +scripts consist of two parts: a +.Em preamble +and a +.Em setup script . +The preamble sets up the options for the installation (how to partition the +disk[s], which distributions to install, etc.) and the second part is +a shell script run in a chroot in the newly installed system before +.Nm +exits. The two parts are separated by the usual script header (#!), which +also sets the interpreter for the setup script. +.Pp +A typical bsdinstall script looks like this: +.Bd -literal -offset indent +PARTITIONS=ada0 +DISTRIBUTIONS="kernel.txz base.txz" + +#!/bin/sh +echo "ifconfig_em0=DHCP" >> /etc/rc.conf +echo "sshd_enable=YES" >> /etc/rc.conf +pkg install puppet +.Ed +.Pp +On +.Fx +release media, such a script placed at +.Pa /etc/installerconfig +will be run at boot time and the system will be rebooted automatically after +the installation has completed. This can be used for unattended network +installation of new systems; see +.Xr diskless 8 +for details. +.Ss PREAMBLE +The preamble consists of installer settings. These control global installation +parameters (see +.Sx ENVIRONMENT VARIABLES ) +as well as disk partitioning. The preamble is interpreted as a +.Xr sh 1 +script run at the very beginning of the install. If more complicated behavior +than setting these variables is desired, arbitrary commands can be run here +to extend the installer. In addition to the variables in +.Sx ENVIRONMENT VARIABLES , +in particular +.Ev DISTRIBUTIONS , +the preamble can contain a variable +.Ev PARTITIONS +which is passed to the +.Cm scriptedpart +target to control disk setup. +.Ss SETUP SCRIPT +Following the preamble is a shell script, beginning with a #! declaration. +This script will be run at the end of the installation process inside a +.Xr chroot 8 +environment in the newly installed system and can be used to set up +configuration files, install packages, etc. Note that newly configured +system services (e.g. networking) have not been started in the installed +system at this time and only installation host services are available. .Sh HISTORY This version of .Nm From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 02:47:09 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 89F4D1C2; Tue, 22 Jan 2013 02:47:09 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 77BAEE10; Tue, 22 Jan 2013 02:47:09 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M2l9Gl063271; Tue, 22 Jan 2013 02:47:09 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M2l9c0063270; Tue, 22 Jan 2013 02:47:09 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301220247.r0M2l9c0063270@svn.freebsd.org> From: Nathan Whitehorn Date: Tue, 22 Jan 2013 02:47:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245759 - head/usr.sbin/bsdinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 02:47:09 -0000 Author: nwhitehorn Date: Tue Jan 22 02:47:08 2013 New Revision: 245759 URL: http://svnweb.freebsd.org/changeset/base/245759 Log: Update change date. Modified: head/usr.sbin/bsdinstall/bsdinstall.8 Modified: head/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 02:40:06 2013 (r245758) +++ head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 02:47:08 2013 (r245759) @@ -1,5 +1,5 @@ .\"- -.\" Copyright (c) 2011 Nathan Whitehorn +.\" Copyright (c) 2011-2013 Nathan Whitehorn .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd June 11, 2011 +.Dd January 21, 2013 .Dt BSDINSTALL 8 .Os .Sh NAME From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 02:57:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CA92D4C7; Tue, 22 Jan 2013 02:57:53 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A57DDE61; Tue, 22 Jan 2013 02:57:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M2vr4w066285; Tue, 22 Jan 2013 02:57:53 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M2vrPi066284; Tue, 22 Jan 2013 02:57:53 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301220257.r0M2vrPi066284@svn.freebsd.org> From: Nathan Whitehorn Date: Tue, 22 Jan 2013 02:57:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245760 - head/usr.sbin/bsdinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 02:57:53 -0000 Author: nwhitehorn Date: Tue Jan 22 02:57:53 2013 New Revision: 245760 URL: http://svnweb.freebsd.org/changeset/base/245760 Log: Clarify that the setup script is optional. Modified: head/usr.sbin/bsdinstall/bsdinstall.8 Modified: head/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 02:47:08 2013 (r245759) +++ head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 02:57:53 2013 (r245760) @@ -240,8 +240,10 @@ scripts consist of two parts: a and a .Em setup script . The preamble sets up the options for the installation (how to partition the -disk[s], which distributions to install, etc.) and the second part is -a shell script run in a chroot in the newly installed system before +disk[s], which distributions to install, etc.) and the optional second part is +a shell script run under +.Xr chroot 8 +in the newly installed system before .Nm exits. The two parts are separated by the usual script header (#!), which also sets the interpreter for the setup script. From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 03:23:15 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0549FB32; Tue, 22 Jan 2013 03:23:15 +0000 (UTC) (envelope-from davidxu@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D76F0FC7; Tue, 22 Jan 2013 03:23:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M3NEjb075691; Tue, 22 Jan 2013 03:23:14 GMT (envelope-from davidxu@svn.freebsd.org) Received: (from davidxu@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M3NEVE075690; Tue, 22 Jan 2013 03:23:14 GMT (envelope-from davidxu@svn.freebsd.org) Message-Id: <201301220323.r0M3NEVE075690@svn.freebsd.org> From: David Xu Date: Tue, 22 Jan 2013 03:23:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245761 - head/gnu/usr.bin/grep X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 03:23:15 -0000 Author: davidxu Date: Tue Jan 22 03:23:14 2013 New Revision: 245761 URL: http://svnweb.freebsd.org/changeset/base/245761 Log: Make "-D skip" option work with FIFO by opening file in non-blocking mode. Reviewed by: jhb Tested by: delphij Modified: head/gnu/usr.bin/grep/grep.c Modified: head/gnu/usr.bin/grep/grep.c ============================================================================== --- head/gnu/usr.bin/grep/grep.c Tue Jan 22 02:57:53 2013 (r245760) +++ head/gnu/usr.bin/grep/grep.c Tue Jan 22 03:23:14 2013 (r245761) @@ -304,7 +304,7 @@ reset (int fd, char const *file, struct if (directories == SKIP_DIRECTORIES && S_ISDIR (stats->stat.st_mode)) return 0; #ifndef DJGPP - if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode) || S_ISSOCK(stats->stat.st_mode))) + if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode) || S_ISSOCK(stats->stat.st_mode) || S_ISFIFO(stats->stat.st_mode))) #else if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode))) #endif @@ -942,6 +942,7 @@ grepfile (char const *file, struct stats int desc; int count; int status; + int flags; if (! file) { @@ -950,7 +951,7 @@ grepfile (char const *file, struct stats } else { - while ((desc = open (file, O_RDONLY)) < 0 && errno == EINTR) + while ((desc = open (file, O_RDONLY | O_NONBLOCK)) < 0 && errno == EINTR) continue; if (desc < 0) @@ -990,6 +991,9 @@ grepfile (char const *file, struct stats return 1; } + flags = fcntl(desc, F_GETFL); + flags &= ~O_NONBLOCK; + fcntl(desc, F_SETFL, flags); filename = file; } From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 04:14:28 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A117D63A; Tue, 22 Jan 2013 04:14:28 +0000 (UTC) (envelope-from benno@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7D426159; Tue, 22 Jan 2013 04:14:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M4ESIt093651; Tue, 22 Jan 2013 04:14:28 GMT (envelope-from benno@svn.freebsd.org) Received: (from benno@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M4ESQR093650; Tue, 22 Jan 2013 04:14:28 GMT (envelope-from benno@svn.freebsd.org) Message-Id: <201301220414.r0M4ESQR093650@svn.freebsd.org> From: Benno Rice Date: Tue, 22 Jan 2013 04:14:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245765 - head/sys/boot/i386/efi X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 04:14:28 -0000 Author: benno Date: Tue Jan 22 04:14:27 2013 New Revision: 245765 URL: http://svnweb.freebsd.org/changeset/base/245765 Log: Fix linking of loader.efi. gcc handles -symbolic by passing -Bsymbolic through to ld. clang ignores -symbolic and thus invokes ld without -Bsymbolic which leads to some symbols not being properly linked in loader.efi. Fix this by using -Wl,-Bsymbolic which passes -Bsymbolic to ld in both the gcc and clang cases. Approved by: rpaulo Modified: head/sys/boot/i386/efi/Makefile Modified: head/sys/boot/i386/efi/Makefile ============================================================================== --- head/sys/boot/i386/efi/Makefile Tue Jan 22 03:43:28 2013 (r245764) +++ head/sys/boot/i386/efi/Makefile Tue Jan 22 04:14:27 2013 (r245765) @@ -36,7 +36,7 @@ FILES= loader.efi FILESMODE_loader.efi= ${BINMODE} LDSCRIPT= ${.CURDIR}/ldscript.i386 -LDFLAGS= -Wl,-T${LDSCRIPT} -shared -symbolic +LDFLAGS= -Wl,-T${LDSCRIPT} -Wl,-Bsymbolic -shared ${PROG}: ${LDSCRIPT} From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 05:39:35 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0F97CEF; Tue, 22 Jan 2013 05:39:35 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id ECB333E2; Tue, 22 Jan 2013 05:39:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M5dY11024076; Tue, 22 Jan 2013 05:39:34 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M5dYbw024075; Tue, 22 Jan 2013 05:39:34 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201301220539.r0M5dYbw024075@svn.freebsd.org> From: Andrew Turner Date: Tue, 22 Jan 2013 05:39:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245767 - head/usr.bin/tr X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 05:39:35 -0000 Author: andrew Date: Tue Jan 22 05:39:34 2013 New Revision: 245767 URL: http://svnweb.freebsd.org/changeset/base/245767 Log: When copying the complement of the string loop to WINT_MAX as we are dealing with a wint_t. WINT_MAX and WCHAR_MAX are the same on most architectures except ARM EABI where wint_t is signed and wchar_t is unsigned. Modified: head/usr.bin/tr/tr.c Modified: head/usr.bin/tr/tr.c ============================================================================== --- head/usr.bin/tr/tr.c Tue Jan 22 04:50:21 2013 (r245766) +++ head/usr.bin/tr/tr.c Tue Jan 22 05:39:34 2013 (r245767) @@ -47,6 +47,7 @@ static const char sccsid[] = "@(#)tr.c 8 #include #include #include +#include #include #include #include @@ -267,7 +268,7 @@ endloop: */ s2.str = argv[1]; s2.state = NORMAL; - for (cnt = 0; cnt < WCHAR_MAX; cnt++) { + for (cnt = 0; cnt < WINT_MAX; cnt++) { if (Cflag && !iswrune(cnt)) continue; if (cmap_lookup(map, cnt) == OOBCH) { From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 05:41:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 918D4323; Tue, 22 Jan 2013 05:41:36 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 75B65622; Tue, 22 Jan 2013 05:41:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M5faE4025954; Tue, 22 Jan 2013 05:41:36 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M5fZmL025945; Tue, 22 Jan 2013 05:41:35 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201301220541.r0M5fZmL025945@svn.freebsd.org> From: Xin LI Date: Tue, 22 Jan 2013 05:41:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245768 - in head/sys: conf dev/hpt27xx modules/hpt27xx X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 05:41:36 -0000 Author: delphij Date: Tue Jan 22 05:41:34 2013 New Revision: 245768 URL: http://svnweb.freebsd.org/changeset/base/245768 Log: - Don't include date and time the driver is built, this is useful for generating binary diffs. - Constify a few strings used in the driver. - Style changes to make the driver compile with default clang settings. Approved by: HighPoint Technologies MFC after: 3 days Modified: head/sys/conf/files.amd64 head/sys/conf/files.i386 head/sys/dev/hpt27xx/hpt27xx_config.c head/sys/dev/hpt27xx/os_bsd.h head/sys/dev/hpt27xx/osm_bsd.c head/sys/modules/hpt27xx/Makefile Modified: head/sys/conf/files.amd64 ============================================================================== --- head/sys/conf/files.amd64 Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/conf/files.amd64 Tue Jan 22 05:41:34 2013 (r245768) @@ -190,8 +190,7 @@ dev/fdc/fdc_acpi.c optional fdc dev/fdc/fdc_isa.c optional fdc isa dev/fdc/fdc_pccard.c optional fdc pccard dev/hpt27xx/os_bsd.c optional hpt27xx -dev/hpt27xx/osm_bsd.c optional hpt27xx \ - compile-with "${NORMAL_C} ${NO_WFORMAT_SECURITY}" +dev/hpt27xx/osm_bsd.c optional hpt27xx dev/hpt27xx/hpt27xx_config.c optional hpt27xx dev/hptmv/entry.c optional hptmv dev/hptmv/mv.c optional hptmv Modified: head/sys/conf/files.i386 ============================================================================== --- head/sys/conf/files.i386 Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/conf/files.i386 Tue Jan 22 05:41:34 2013 (r245768) @@ -181,8 +181,7 @@ dev/glxiic/glxiic.c optional glxiic dev/glxsb/glxsb.c optional glxsb dev/glxsb/glxsb_hash.c optional glxsb dev/hpt27xx/os_bsd.c optional hpt27xx -dev/hpt27xx/osm_bsd.c optional hpt27xx \ - compile-with "${NORMAL_C} ${NO_WFORMAT_SECURITY}" +dev/hpt27xx/osm_bsd.c optional hpt27xx dev/hpt27xx/hpt27xx_config.c optional hpt27xx dev/hptmv/entry.c optional hptmv dev/hptmv/mv.c optional hptmv Modified: head/sys/dev/hpt27xx/hpt27xx_config.c ============================================================================== --- head/sys/dev/hpt27xx/hpt27xx_config.c Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/dev/hpt27xx/hpt27xx_config.c Tue Jan 22 05:41:34 2013 (r245768) @@ -58,9 +58,9 @@ int init_config(void) return 0; } -char driver_name[] = "hpt27xx"; -char driver_name_long[] = "RocketRAID 27xx controller driver"; -char driver_ver[] = "v1.0 (" __DATE__ " " __TIME__ ")"; +const char driver_name[] = "hpt27xx"; +const char driver_name_long[] = "RocketRAID 27xx controller driver"; +const char driver_ver[] = "v1.0"; int osm_max_targets = 0xff; Modified: head/sys/dev/hpt27xx/os_bsd.h ============================================================================== --- head/sys/dev/hpt27xx/os_bsd.h Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/dev/hpt27xx/os_bsd.h Tue Jan 22 05:41:34 2013 (r245768) @@ -135,9 +135,9 @@ INQUIRYDATA, *PINQUIRYDATA; #include /* driver parameters */ -extern char driver_name[]; -extern char driver_name_long[]; -extern char driver_ver[]; +extern const char driver_name[]; +extern const char driver_name_long[]; +extern const char driver_ver[]; extern int osm_max_targets; /* Modified: head/sys/dev/hpt27xx/osm_bsd.c ============================================================================== --- head/sys/dev/hpt27xx/osm_bsd.c Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/dev/hpt27xx/osm_bsd.c Tue Jan 22 05:41:34 2013 (r245768) @@ -167,7 +167,8 @@ static int hpt_alloc_mem(PVBUS_EXT vbus_ HPT_ASSERT((f->size & (f->alignment-1))==0); - for (order=0, size=PAGE_SIZE; sizesize; order++, size<<=1) ; + for (order=0, size=PAGE_SIZE; sizesize; order++, size<<=1) + ; KdPrint(("%s: %d*%d=%d bytes, order %d", f->tag, f->count, f->size, f->count*f->size, order)); @@ -1036,6 +1037,7 @@ static void hpt_final_init(void *dummy) } if (!i) { + if (bootverbose) os_printk("no controller detected."); return; } @@ -1177,7 +1179,7 @@ static void hpt_final_init(void *dummy) } make_dev(&hpt_cdevsw, DRIVER_MINOR, UID_ROOT, GID_OPERATOR, - S_IRUSR | S_IWUSR, driver_name); + S_IRUSR | S_IWUSR, "%s", driver_name); } #if defined(KLD_MODULE) && (__FreeBSD_version >= 503000) @@ -1224,6 +1226,7 @@ static void override_kernel_driver(void) static void hpt_init(void *dummy) { + if (bootverbose) os_printk("%s %s", driver_name_long, driver_ver); override_kernel_driver(); Modified: head/sys/modules/hpt27xx/Makefile ============================================================================== --- head/sys/modules/hpt27xx/Makefile Tue Jan 22 05:39:34 2013 (r245767) +++ head/sys/modules/hpt27xx/Makefile Tue Jan 22 05:41:34 2013 (r245768) @@ -12,6 +12,3 @@ hpt27xx_lib.o: uudecode -p < ${HPT27XX}/$(MACHINE_ARCH)-elf.hpt27xx_lib.o.uu > ${.TARGET} .include - -CWARNFLAGS.osm_bsd.c= ${NO_WFORMAT_SECURITY} -CWARNFLAGS+= ${CWARNFLAGS.${.IMPSRC:T}} From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 09:44:22 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7AE16EF1; Tue, 22 Jan 2013 09:44:22 +0000 (UTC) (envelope-from lstewart@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 55A45340; Tue, 22 Jan 2013 09:44:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0M9iMaA099131; Tue, 22 Jan 2013 09:44:22 GMT (envelope-from lstewart@svn.freebsd.org) Received: (from lstewart@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0M9iMRK099130; Tue, 22 Jan 2013 09:44:22 GMT (envelope-from lstewart@svn.freebsd.org) Message-Id: <201301220944.r0M9iMRK099130@svn.freebsd.org> From: Lawrence Stewart Date: Tue, 22 Jan 2013 09:44:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245783 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 09:44:22 -0000 Author: lstewart Date: Tue Jan 22 09:44:21 2013 New Revision: 245783 URL: http://svnweb.freebsd.org/changeset/base/245783 Log: Simplify and fix a bug in cc_ack_received()'s "are we congestion window limited" logic (refer to [1] for associated discussion). snd_cwnd and snd_wnd are unsigned long and on 64 bit hosts, min() will truncate them to 32 bits and could therefore potentially corrupt the result (although under normal operation, neither variable should legitmately exceed 32 bits). [1] http://lists.freebsd.org/pipermail/freebsd-net/2013-January/034297.html Submitted by: jhb MFC after: 1 week Modified: head/sys/netinet/tcp_input.c Modified: head/sys/netinet/tcp_input.c ============================================================================== --- head/sys/netinet/tcp_input.c Tue Jan 22 08:09:43 2013 (r245782) +++ head/sys/netinet/tcp_input.c Tue Jan 22 09:44:21 2013 (r245783) @@ -285,7 +285,7 @@ cc_ack_received(struct tcpcb *tp, struct INP_WLOCK_ASSERT(tp->t_inpcb); tp->ccv->bytes_this_ack = BYTES_THIS_ACK(tp, th); - if (tp->snd_cwnd == min(tp->snd_cwnd, tp->snd_wnd)) + if (tp->snd_cwnd <= tp->snd_wnd) tp->ccv->flags |= CCF_CWND_LIMITED; else tp->ccv->flags &= ~CCF_CWND_LIMITED; From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 15:26:20 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4FB4576D; Tue, 22 Jan 2013 15:26:20 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2788DD5D; Tue, 22 Jan 2013 15:26:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MFQJLw010242; Tue, 22 Jan 2013 15:26:19 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MFQJ50010241; Tue, 22 Jan 2013 15:26:19 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301221526.r0MFQJ50010241@svn.freebsd.org> From: Nathan Whitehorn Date: Tue, 22 Jan 2013 15:26:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245792 - head/usr.sbin/bsdinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 15:26:20 -0000 Author: nwhitehorn Date: Tue Jan 22 15:26:19 2013 New Revision: 245792 URL: http://svnweb.freebsd.org/changeset/base/245792 Log: Improve documentation of BSDINSTALL_DISTSITE and mdoc. Modified: head/usr.sbin/bsdinstall/bsdinstall.8 Modified: head/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 12:40:00 2013 (r245791) +++ head/usr.sbin/bsdinstall/bsdinstall.8 Tue Jan 22 15:26:19 2013 (r245792) @@ -120,7 +120,9 @@ but non-interactively according to the d .Ar parameters . Each disk setup is specified by a three-part argument: .Pp -.Ar disk [scheme] [{partitions}] +.Ar disk +.Op Ar scheme +.Op Ar {partitions} .Pp Multiple disk setups are separated by semicolons. The .Ar disk @@ -141,7 +143,9 @@ argument is also optional and specifies It consists of a comma-separated list of partitions to create enclosed in curly braces. Each partition declaration takes the form .Pp -.Ar size type [mount point] +.Ar size +.Ar type +.Op Ar mount point .Pp .Ar size specifies the partition size to create in bytes (K, M, and G suffixes @@ -209,13 +213,27 @@ process. Many are used internally during default values for most installation scenarios. Others are set by various interactive user prompts, and can be usefully overridden when making scripted or customized installers. -.Bl -tag -width ".Ev BSDINSTALL_DISTDIR" +.Bl -tag -width ".Ev BSDINSTALL_DISTSITE" .It Ev DISTRIBUTIONS The set of distributions to install (e.g. "base kernel ports"). Default: none .It Ev BSDINSTALL_DISTDIR The directory in which the distribution files can be found (or to which they should be downloaded). Default: .Pa /usr/freebsd-dist +.It Ev BSDINSTALL_DISTSITE +URL from which the distribution files should be downloaded if they are not +already present in the directory defined by +.Ev BSDINSTALL_DISTDIR . +This should be a full path to the files, including architecture and release +names. Most targets (e.g. +.Cm auto +and +.Cm jail ) +that prompt for a +.Fx +mirror will skip that step if this variable is already defined in the +environment. Example: +.Pa ftp://ftp.freebsd.org/pub/FreeBSD/releases/powerpc/powerpc64/9.1-RELEASE .It Ev BSDINSTALL_CHROOT The directory into which the distribution files should be unpacked and the directory at which the root file system of the new system should be mounted. @@ -286,8 +304,9 @@ which is passed to the .Cm scriptedpart target to control disk setup. .Ss SETUP SCRIPT -Following the preamble is a shell script, beginning with a #! declaration. -This script will be run at the end of the installation process inside a +Following the preamble is an optional shell script, beginning with a #! +declaration. This script will be run at the end of the installation process +inside a .Xr chroot 8 environment in the newly installed system and can be used to set up configuration files, install packages, etc. Note that newly configured From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 16:23:09 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 018419E6; Tue, 22 Jan 2013 16:23:09 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E7CB3F4; Tue, 22 Jan 2013 16:23:08 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MGN8JF027655; Tue, 22 Jan 2013 16:23:08 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MGN8jD027654; Tue, 22 Jan 2013 16:23:08 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301221623.r0MGN8jD027654@svn.freebsd.org> From: Brooks Davis Date: Tue, 22 Jan 2013 16:23:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245793 - head/usr.bin/xinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 16:23:09 -0000 Author: brooks Date: Tue Jan 22 16:23:08 2013 New Revision: 245793 URL: http://svnweb.freebsd.org/changeset/base/245793 Log: Make "install -l s[ar]" act like "ln -sfh" as intended. This fixes installation of symbolic links where the target is a link is to an existing directory. Modified: head/usr.bin/xinstall/xinstall.c Modified: head/usr.bin/xinstall/xinstall.c ============================================================================== --- head/usr.bin/xinstall/xinstall.c Tue Jan 22 15:26:19 2013 (r245792) +++ head/usr.bin/xinstall/xinstall.c Tue Jan 22 16:23:08 2013 (r245793) @@ -336,8 +336,21 @@ main(int argc, char *argv[]) /* NOTREACHED */ } - no_target = stat(to_name = argv[argc - 1], &to_sb); + to_name = argv[argc - 1]; + no_target = stat(to_name, &to_sb); if (!no_target && S_ISDIR(to_sb.st_mode)) { + if (dolink & LN_SYMBOLIC) { + if (lstat(to_name, &to_sb) != 0) + err(EX_OSERR, "%s vanished", to_name); + if (S_ISLNK(to_sb.st_mode)) { + if (argc != 2) { + errno = ENOTDIR; + err(EX_USAGE, "%s", to_name); + } + install(*argv, to_name, fset, iflags); + exit(EX_OK); + } + } for (; *argv != to_name; ++argv) install(*argv, to_name, fset, iflags | DIRECTORY); exit(EX_OK); From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 17:06:29 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 81B3E9D7; Tue, 22 Jan 2013 17:06:29 +0000 (UTC) (envelope-from nwhitehorn@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6F3B3383; Tue, 22 Jan 2013 17:06:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MH6TYI040104; Tue, 22 Jan 2013 17:06:29 GMT (envelope-from nwhitehorn@svn.freebsd.org) Received: (from nwhitehorn@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MH6SEf040101; Tue, 22 Jan 2013 17:06:28 GMT (envelope-from nwhitehorn@svn.freebsd.org) Message-Id: <201301221706.r0MH6SEf040101@svn.freebsd.org> From: Nathan Whitehorn Date: Tue, 22 Jan 2013 17:06:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245796 - head/usr.sbin/bsdinstall/partedit X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 17:06:29 -0000 Author: nwhitehorn Date: Tue Jan 22 17:06:28 2013 New Revision: 245796 URL: http://svnweb.freebsd.org/changeset/base/245796 Log: Improve error handling and remove an unnecessary check on geom provider type. GEOM provider names can't duplicate (or shouldn't -- devfs will either break or only use the first one if they do) so using the first provider by that name is a sufficient check. This also lets the scripted partitioner install onto gmirror and geli and such things. Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c head/usr.sbin/bsdinstall/partedit/partedit.c head/usr.sbin/bsdinstall/partedit/scripted.c Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue Jan 22 17:05:26 2013 (r245795) +++ head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue Jan 22 17:06:28 2013 (r245796) @@ -167,12 +167,6 @@ provider_for_name(struct gmesh *mesh, co struct ggeom *gp; LIST_FOREACH(classp, &mesh->lg_class, lg_class) { - if (strcmp(classp->lg_name, "DISK") != 0 && - strcmp(classp->lg_name, "PART") != 0 && - strcmp(classp->lg_name, "RAID") != 0 && - strcmp(classp->lg_name, "MD") != 0) - continue; - LIST_FOREACH(gp, &classp->lg_geom, lg_geom) { if (LIST_EMPTY(&gp->lg_provider)) continue; Modified: head/usr.sbin/bsdinstall/partedit/partedit.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/partedit.c Tue Jan 22 17:05:26 2013 (r245795) +++ head/usr.sbin/bsdinstall/partedit/partedit.c Tue Jan 22 17:06:28 2013 (r245796) @@ -97,8 +97,12 @@ main(int argc, const char **argv) "the Finish button."; part_wizard(); } else if (strcmp(basename(argv[0]), "scriptedpart") == 0) { - scripted_editor(argc, argv); + error = scripted_editor(argc, argv); prompt = NULL; + if (error != 0) { + end_dialog(); + return (error); + } } else { prompt = "Create partitions for FreeBSD. No changes will be " "made until you select Finish."; Modified: head/usr.sbin/bsdinstall/partedit/scripted.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/scripted.c Tue Jan 22 17:05:26 2013 (r245795) +++ head/usr.sbin/bsdinstall/partedit/scripted.c Tue Jan 22 17:06:28 2013 (r245796) @@ -45,12 +45,6 @@ provider_for_name(struct gmesh *mesh, co struct ggeom *gp; LIST_FOREACH(classp, &mesh->lg_class, lg_class) { - if (strcmp(classp->lg_name, "DISK") != 0 && - strcmp(classp->lg_name, "PART") != 0 && - strcmp(classp->lg_name, "RAID") != 0 && - strcmp(classp->lg_name, "MD") != 0) - continue; - LIST_FOREACH(gp, &classp->lg_geom, lg_geom) { if (LIST_EMPTY(&gp->lg_provider)) continue; @@ -81,6 +75,11 @@ part_config(char *disk, const char *sche scheme = default_scheme(); error = geom_gettree(&mesh); + if (provider_for_name(&mesh, disk) == NULL) { + fprintf(stderr, "GEOM provider %s not found\n", disk); + geom_deletetree(&mesh); + return (-1); + } /* Remove any existing partitioning and create new scheme */ LIST_FOREACH(classp, &mesh.lg_class, lg_class) @@ -183,7 +182,7 @@ int parse_disk_config(char *input) } while (input != NULL && *input != 0); if (disk != NULL) - part_config(disk, scheme, partconfig); + return (part_config(disk, scheme, partconfig)); return (0); } @@ -192,7 +191,7 @@ int scripted_editor(int argc, const char **argv) { char *token; - int i, len = 0; + int i, error = 0, len = 0; for (i = 1; i < argc; i++) len += strlen(argv[i]) + 1; @@ -203,8 +202,11 @@ scripted_editor(int argc, const char **a strcat(input, argv[i]); } - while ((token = strsep(&input, ";")) != NULL) - parse_disk_config(token); + while ((token = strsep(&input, ";")) != NULL) { + error = parse_disk_config(token); + if (error != 0) + return (error); + } return (0); } From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 17:14:49 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id ADD2F25B; Tue, 22 Jan 2013 17:14:49 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 89B3F69B; Tue, 22 Jan 2013 17:14:49 +0000 (UTC) Received: from pakbsde14.localnet (unknown [38.105.238.108]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id CCFA3B94A; Tue, 22 Jan 2013 12:14:48 -0500 (EST) From: John Baldwin To: Eitan Adler Subject: Re: svn commit: r245536 - head/tools/tools/notescheck Date: Tue, 22 Jan 2013 10:50:35 -0500 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p22; KDE/4.5.5; amd64; ; ) References: <201301170420.r0H4Ks7N092837@svn.freebsd.org> In-Reply-To: <201301170420.r0H4Ks7N092837@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201301221050.35473.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Tue, 22 Jan 2013 12:14:48 -0500 (EST) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 17:14:49 -0000 On Wednesday, January 16, 2013 11:20:54 pm Eitan Adler wrote: > Author: eadler > Date: Thu Jan 17 04:20:53 2013 > New Revision: 245536 > URL: http://svnweb.freebsd.org/changeset/base/245536 > > Log: > Convert to Python 3 > > Approved by: cperciva Do we really want to do this? The ports tree still installs 2.7 by default IIRC, and I for one always use 2.x (and I wrote this script originally). Your changes make this script no longer work with 2.x. I think we should defer switching various scripts to Python 3 until we start installing it as the default python. -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 17:49:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7F39F6B1; Tue, 22 Jan 2013 17:49:53 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 54E888EC; Tue, 22 Jan 2013 17:49:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MHnrSf053030; Tue, 22 Jan 2013 17:49:53 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MHnpbC053016; Tue, 22 Jan 2013 17:49:51 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301221749.r0MHnpbC053016@svn.freebsd.org> From: David Chisnall Date: Tue, 22 Jan 2013 17:49:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245803 - in head: . gnu/usr.bin share/man/man5 share/mk usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 17:49:53 -0000 Author: theraven Date: Tue Jan 22 17:49:51 2013 New Revision: 245803 URL: http://svnweb.freebsd.org/changeset/base/245803 Log: Import new (BSDL) device tree compiler. Now built by default, so that it can't be used on the host system (and not installed on the device, if required). The GPL'd one is still available if there are any devices that need it (make universe passes with it, including kernels that use fdt, but there may be some out-of-tree ones). WITH_GPL_DTC can be used to select the old one, for now. Probably won't be MFC'd, but we'll remove the GPL'd version in head after the new one has had a lot more testing and ship it in 10.0. Added: head/usr.bin/dtc/ head/usr.bin/dtc/HACKING (contents, props changed) head/usr.bin/dtc/Makefile (contents, props changed) head/usr.bin/dtc/checking.cc (contents, props changed) head/usr.bin/dtc/checking.hh (contents, props changed) head/usr.bin/dtc/dtb.cc (contents, props changed) head/usr.bin/dtc/dtb.hh (contents, props changed) head/usr.bin/dtc/dtc.1 (contents, props changed) head/usr.bin/dtc/dtc.cc (contents, props changed) head/usr.bin/dtc/fdt.cc (contents, props changed) head/usr.bin/dtc/fdt.hh (contents, props changed) head/usr.bin/dtc/input_buffer.cc (contents, props changed) head/usr.bin/dtc/input_buffer.hh (contents, props changed) head/usr.bin/dtc/string.cc (contents, props changed) head/usr.bin/dtc/string.hh (contents, props changed) head/usr.bin/dtc/util.hh (contents, props changed) Modified: head/Makefile.inc1 head/gnu/usr.bin/Makefile head/share/man/man5/src.conf.5 head/share/mk/bsd.own.mk Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Tue Jan 22 17:21:08 2013 (r245802) +++ head/Makefile.inc1 Tue Jan 22 17:49:51 2013 (r245803) @@ -1112,7 +1112,10 @@ _dtrace_tools= cddl/usr.bin/sgsmsg cddl/ lib/libdwarf cddl/usr.bin/ctfconvert cddl/usr.bin/ctfmerge .endif -.if ${MK_FDT} != "no" +# Default to building the BSDL DTC, but build the GPL one if users explicitly +# request it. +_dtc= /usr.bin/dtc +.if ${MK_GPL_DTC} != "no" _dtc= gnu/usr.bin/dtc .endif Modified: head/gnu/usr.bin/Makefile ============================================================================== --- head/gnu/usr.bin/Makefile Tue Jan 22 17:21:08 2013 (r245802) +++ head/gnu/usr.bin/Makefile Tue Jan 22 17:49:51 2013 (r245803) @@ -30,7 +30,7 @@ _groff= groff _cvs= cvs .endif -.if ${MK_FDT} != "no" +.if ${MK_GPL_DTC} != "no" _dtc= dtc .endif Modified: head/share/man/man5/src.conf.5 ============================================================================== --- head/share/man/man5/src.conf.5 Tue Jan 22 17:21:08 2013 (r245802) +++ head/share/man/man5/src.conf.5 Tue Jan 22 17:49:51 2013 (r245803) @@ -476,6 +476,9 @@ Set to not build GPIB bus support. Set to not build .Xr gpioctl 8 as part of the base system. +.It Va WITH_GPL_DTC +Set to build the GPL'd version of the device tree compiler from elinux.org, +instead of the BSD licensed one. .It Va WITHOUT_GROFF .\" from FreeBSD: head/tools/build/options/WITHOUT_GROFF 218941 2011-02-22 08:13:49Z uqs Set to not build Modified: head/share/mk/bsd.own.mk ============================================================================== --- head/share/mk/bsd.own.mk Tue Jan 22 17:21:08 2013 (r245802) +++ head/share/mk/bsd.own.mk Tue Jan 22 17:49:51 2013 (r245803) @@ -364,6 +364,7 @@ __DEFAULT_NO_OPTIONS = \ BSD_GREP \ CLANG_EXTRAS \ CTF \ + GPL_DTC \ HESIOD \ ICONV \ IDEA \ Added: head/usr.bin/dtc/HACKING ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/HACKING Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,65 @@ +$FreeBSD$ + +Notes for people hacking on dtc +=============================== + +This file contains some notes for people wishing to hack on dtc. + +Upstreaming +----------- + +This code is developed in the FreeBSD svn repository: + +https://svn.freebsd.org/base/head/usr.bin/dtc + +If you got the source from anywhere else and wish to make changes, please +ensure that you are working against the latest version, or you may end up +fixing bugs that are already fixed upstream. Although the license makes no +requirement that you share any improvements that you make, patches are very +welcome. + +C++11 +----- + +This project currently aims to compile with g++ 4.2.1 and so doesn't make any +use of C++11 features. It would be a good idea to relax this restriction once +clang is the default compiler for ARM, MIPS and PowerPC. + +This code makes use of a lot of iterator loops, which would be cleaner using +the new syntax in C++11. It also explicitly deletes a lot of objects held in +collections in destructors that have these collections as their members. This +could be simplified by using `shared_ptr`. + +The code does make use of `static_assert()`, but uses a macro in utility.hh to +remove these if they are not supported. The FreeBSD standard headers also +define a compatibility macro the implements static asserts in terms of an array +with 1 element on success and -1 elements on failure. + +Adding New Checks +----------------- + +Currently, the biggest weakness of this version of the tool is that it lacks +most of the semantic checkers that can be implemented by simply reading the +ePAPR spec. The `checker` class provides a simple superclass for implementing +these quite easily. There are also helper methods on `device_tree` for finding +specific nodes, for checks that require some understanding of the structure of +the tree. + +We should probably add a parent pointer to the `node` class for easily walking +up the tree. + +Adding Direct C Output +---------------------- + +The FreeBSD build system currently uses dtc to generate a blob and then +converts this to C source code. A new `output_writer` subclass could easily +generate the C directly. + +Parser Improvements +------------------- + +There are a few FIXME lines in the parser for some corner cases that are not +currently used by FreeBSD. These are mainly related to labels in the middle of +values. These can be fixed by creating a new `property_value` with the +specified label, starting at the location of the label. Don't forget to remove +the associated comments from the BUGS section of the man page if you fix this. Added: head/usr.bin/dtc/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/Makefile Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,11 @@ +# $FreeBSD$ + +PROG_CXX=dtc +SRCS= dtc.cc input_buffer.cc string.cc dtb.cc fdt.cc checking.cc +MAN= dtc.1 + +WARNS?= 3 + +NO_SHARED?=NO + +.include Added: head/usr.bin/dtc/checking.cc ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/checking.cc Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,210 @@ +/*- + * Copyright (c) 2013 David Chisnall + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * 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 AUTHOR 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 AUTHOR 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. + * + * $FreeBSD$ + */ + +#include "checking.hh" + +namespace dtc +{ +namespace fdt +{ +namespace checking +{ + +bool +checker::visit_node(device_tree *tree, node *n) +{ + path.push_back(std::make_pair(n->name, n->unit_address)); + // Check this node + if (!check_node(tree, n)) + { + return false; + } + // Now check its properties + for (node::property_iterator i=n->property_begin(), e=n->property_end() + ; i!=e ; ++i) + { + if (!check_property(tree, n, *i)) + { + return false; + } + } + // And then recursively check the children + for (node::child_iterator i=n->child_begin(), e=n->child_end() ; i!=e ; + ++i) + { + if (!visit_node(tree, *i)) + { + return false; + } + } + path.pop_back(); + return true; +} + +void +checker::report_error(const char *errmsg) +{ + fprintf(stderr, "Error: %s, while checking node: ", errmsg); + for (device_tree::node_path::iterator p=path.begin()+1, pe=path.end() ; + p!=pe ; ++p) + { + putc('/', stderr); + p->first.dump(); + if (!(p->second.empty())) + { + putc('@', stderr); + p->second.dump(); + } + } + fprintf(stderr, " [-W%s]\n", checker_name); +} + +bool +property_checker::check_property(device_tree *tree, node *n, property *p) +{ + if (p->get_key() == key) + { + if (!check(tree, n, p)) + { + report_error("property check failed"); + return false; + } + } + return true; +} + +bool +property_size_checker::check(device_tree *tree, node *n, property *p) +{ + uint32_t psize = 0; + for (property::value_iterator i=p->begin(),e=p->end() ; i!=e ; ++i) + { + if (!i->is_binary()) + { + return false; + } + psize += i->byte_data.size(); + } + return psize == size; +} + +template +void +check_manager::add_property_type_checker(const char *name, string prop) +{ + checkers.insert(std::make_pair(string(name), + new property_type_checker(name, prop))); +} + +void +check_manager::add_property_size_checker(const char *name, + string prop, + uint32_t size) +{ + checkers.insert(std::make_pair(string(name), + new property_size_checker(name, prop, size))); +} + +check_manager::~check_manager() +{ + while (checkers.begin() != checkers.end()) + { + delete checkers.begin()->second; + checkers.erase(checkers.begin()); + } + while (disabled_checkers.begin() != disabled_checkers.end()) + { + delete disabled_checkers.begin()->second; + } +} + +check_manager::check_manager() +{ + // NOTE: All checks listed here MUST have a corresponding line + // in the man page! + add_property_type_checker( + "type-compatible", string("compatible")); + add_property_type_checker( + "type-model", string("model")); + add_property_size_checker("type-phandle", string("phandle"), 4); +} + +bool +check_manager::run_checks(device_tree *tree, bool keep_going) +{ + bool success = true; + for (std::map::iterator i=checkers.begin(), + e=checkers.end() ; i!=e ; ++i) + { + success &= i->second->check_tree(tree); + if (!(success || keep_going)) + { + break; + } + } + return success; +} + +bool +check_manager::disable_checker(string name) +{ + std::map::iterator checker = checkers.find(name); + if (checker != checkers.end()) + { + disabled_checkers.insert(std::make_pair(name, + checker->second)); + checkers.erase(checker); + return true; + } + return false; +} + +bool +check_manager::enable_checker(string name) +{ + std::map::iterator checker = + disabled_checkers.find(name); + if (checker != disabled_checkers.end()) + { + checkers.insert(std::make_pair(name, checker->second)); + disabled_checkers.erase(checker); + return true; + } + return false; +} + +} // namespace checking + +} // namespace fdt + +} // namespace dtc + Added: head/usr.bin/dtc/checking.hh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/checking.hh Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,308 @@ +/*- + * Copyright (c) 2013 David Chisnall + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * 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 AUTHOR 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 AUTHOR 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. + * + * $FreeBSD$ + */ + +#ifndef _CHECKING_HH_ +#define _CHECKING_HH_ +#include "string.hh" +#include "fdt.hh" + +namespace dtc +{ +namespace fdt +{ +namespace checking +{ +/** + * Base class for all checkers. This will visit the entire tree and perform + * semantic checks defined in subclasses. Note that device trees are generally + * small (a few dozen nodes at most) and so we optimise for flexibility and + * extensibility here, not for performance. Each checker will visit the entire + * tree. + */ +class checker +{ + /** + * The path to the current node being checked. This is used for + * printing error messages. + */ + device_tree::node_path path; + /** + * The name of the checker. This is used for printing error messages + * and for enabling / disabling specific checkers from the command + * line. + */ + const char *checker_name; + /** + * Visits each node, calling the checker functions on properties and + * nodes. + */ + bool visit_node(device_tree *tree, node *n); + protected: + /** + * Prints the error message, along with the path to the node that + * caused the error and the name of the checker. + */ + void report_error(const char *errmsg); + public: + /** + * Constructor. Takes the name of this checker, which is which is used + * when reporting errors. + */ + checker(const char *name) : checker_name(name) {} + /** + * Virtual destructor in case any subclasses need to do cleanup. + */ + virtual ~checker() {} + /** + * Method for checking that a node is valid. The root class version + * does nothing, subclasses should override this. + */ + virtual bool check_node(device_tree *tree, node *n) + { + return true; + } + /** + * Method for checking that a property is valid. The root class + * version does nothing, subclasses should override this. + */ + virtual bool check_property(device_tree *tree, node *n, property *p) + { + return true; + } + /** + * Runs the checker on the specified device tree. + */ + bool check_tree(fdt::device_tree *tree) + { + return visit_node(tree, tree->get_root()); + } +}; + +/** + * Abstract base class for simple property checks. This class defines a check + * method for subclasses, which is invoked only when it finds a property with + * the matching name. To define simple property checkers, just subclass this + * and override the check() method. + */ +class property_checker : public checker +{ + /** + * The name of the property that this checker is looking for. + */ + string key; + public: + /** + * Implementation of the generic property-checking method that checks + * for a property with the name specified in the constructor + */ + virtual bool check_property(device_tree *tree, node *n, property *p); + /** + * Constructor. Takes the name of the checker and the name of the + * property to check. + */ + property_checker(const char* name, string property_name) + : checker(name), key(property_name) {} + /** + * The check method, which subclasses should implement. + */ + virtual bool check(device_tree *tree, node *n, property *p) = 0; +}; + +/** + * Property type checker. + */ +template +struct property_type_checker : public property_checker +{ + /** + * Constructor, takes the name of the checker and the name of the + * property to check as arguments. + */ + property_type_checker(const char* name, string property_name) : + property_checker(name, property_name) {} + virtual bool check(device_tree *tree, node *n, property *p) = 0; +}; + +/** + * Empty property checker. This checks that the property has no value. + */ +template<> +struct property_type_checker : public property_checker +{ + property_type_checker(const char* name, string property_name) : + property_checker(name, property_name) {} + virtual bool check(device_tree *tree, node *n, property *p) + { + return p->begin() == p->end(); + } +}; + +/** + * String property checker. This checks that the property has exactly one + * value, which is a string. + */ +template<> +struct property_type_checker : public property_checker +{ + property_type_checker(const char* name, string property_name) : + property_checker(name, property_name) {} + virtual bool check(device_tree *tree, node *n, property *p) + { + return (p->begin() + 1 == p->end()) && p->begin()->is_string(); + } +}; +/** + * String list property checker. This checks that the property has at least + * one value, all of which are strings. + */ +template<> +struct property_type_checker : + public property_checker +{ + property_type_checker(const char* name, string property_name) : + property_checker(name, property_name) {} + virtual bool check(device_tree *tree, node *n, property *p) + { + for (property::value_iterator i=p->begin(),e=p->end() ; i!=e ; + ++i) + { + if (!(i->is_string() || i->is_string_list())) + { + return false; + } + } + return p->begin() != p->end(); + } +}; + +/** + * Phandle property checker. This checks that the property has exactly one + * value, which is a valid phandle. + */ +template<> +struct property_type_checker : public property_checker +{ + property_type_checker(const char* name, string property_name) : + property_checker(name, property_name) {} + virtual bool check(device_tree *tree, node *n, property *p) + { + return (p->begin() + 1 == p->end()) && + (tree->referenced_node(*p->begin()) != 0); + } +}; + +/** + * Check that a property has the correct size. + */ +struct property_size_checker : public property_checker +{ + /** + * The expected size of the property. + */ + uint32_t size; + public: + /** + * Constructor, takes the name of the checker, the name of the property + * to check, and its expected size as arguments. + */ + property_size_checker(const char* name, string property_name, uint32_t bytes) + : property_checker(name, property_name), size(bytes) {} + /** + * Check, validates that the property has the correct size. + */ + virtual bool check(device_tree *tree, node *n, property *p); +}; + + +/** + * The check manager is the interface to running the checks. This allows + * default checks to be enabled, non-default checks to be enabled, and so on. + */ +class check_manager +{ + /** + * The enabled checkers, indexed by their names. The name is used when + * disabling checkers from the command line. When this manager runs, + * it will only run the checkers from this map. + */ + std::map checkers; + /** + * The disabled checkers. Moving checkers to this list disables them, + * but allows them to be easily moved back. + */ + std::map disabled_checkers; + /** + * Helper function for adding a property value checker. + */ + template + void add_property_type_checker(const char *name, string prop); + /** + * Helper function for adding a simple type checker. + */ + void add_property_type_checker(const char *name, string prop); + /** + * Helper function for adding a property value checker. + */ + void add_property_size_checker(const char *name, + string prop, + uint32_t size); + public: + /** + * Delete all of the checkers that are part of this checker manager. + */ + ~check_manager(); + /** + * Default constructor, creates check manager containing all of the + * default checks. + */ + check_manager(); + /** + * Run all of the checks on the specified tree. + */ + bool run_checks(device_tree *tree, bool keep_going); + /** + * Disables the named checker. + */ + bool disable_checker(string name); + /** + * Enables the named checker. + */ + bool enable_checker(string name); +}; + +} // namespace checking + +} // namespace fdt + +} // namespace dtc + +#endif // !_CHECKING_HH_ Added: head/usr.bin/dtc/dtb.cc ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/dtb.cc Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,308 @@ +/*- + * Copyright (c) 2013 David Chisnall + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * 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 AUTHOR 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 AUTHOR 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. + * + * $FreeBSD$ + */ + +#include "dtb.hh" +#include + +namespace dtc +{ +namespace dtb +{ + +void output_writer::write_data(byte_buffer b) +{ + for (byte_buffer::iterator i=b.begin(), e=b.end(); i!=e ; i++) + { + write_data(*i); + } +} + +void +binary_writer::write_string(string name) +{ + name.push_to_buffer(buffer); + // Trailing nul + buffer.push_back(0); +} + +void +binary_writer::write_data(uint8_t v) +{ + buffer.push_back(v); +} + +void +binary_writer::write_data(uint32_t v) +{ + while (buffer.size() % 4 != 0) + { + buffer.push_back(0); + } + push_big_endian(buffer, v); +} + +void +binary_writer::write_data(uint64_t v) +{ + while (buffer.size() % 8 != 0) + { + buffer.push_back(0); + } + push_big_endian(buffer, v); +} + +void +binary_writer::write_to_file(int fd) +{ + // FIXME: Check return + write(fd, buffer.data(), buffer.size()); +} + +uint32_t +binary_writer::size() +{ + return buffer.size(); +} + +void +asm_writer::write_string(const char *c) +{ + while (*c) + { + buffer.push_back((uint8_t)*(c++)); + } +} + +void +asm_writer::write_line(const char *c) +{ + if (byte_count != 0) + { + byte_count = 0; + buffer.push_back('\n'); + } + write_string(c); +} + +void +asm_writer::write_byte(uint8_t b) +{ + char out[3] = {0}; + if (byte_count++ == 0) + { + buffer.push_back('\t'); + } + write_string(".byte 0x"); + snprintf(out, 3, "%.2hhx", b); + buffer.push_back(out[0]); + buffer.push_back(out[1]); + if (byte_count == 4) + { + buffer.push_back('\n'); + byte_count = 0; + } + else + { + buffer.push_back(';'); + buffer.push_back(' '); + } +} + +void +asm_writer::write_label(string name) +{ + write_line("\t.globl "); + name.push_to_buffer(buffer); + buffer.push_back('\n'); + name.push_to_buffer(buffer); + buffer.push_back(':'); + buffer.push_back('\n'); + buffer.push_back('_'); + name.push_to_buffer(buffer); + buffer.push_back(':'); + buffer.push_back('\n'); + +} + +void +asm_writer::write_comment(string name) +{ + write_line("\t/* "); + name.push_to_buffer(buffer); + write_string(" */\n"); +} + +void +asm_writer::write_string(string name) +{ + write_line("\t.string \""); + name.push_to_buffer(buffer); + write_line("\"\n"); + bytes_written += name.size() + 1; +} + +void +asm_writer::write_data(uint8_t v) +{ + write_byte(v); + bytes_written++; +} + +void +asm_writer::write_data(uint32_t v) +{ + if (bytes_written % 4 != 0) + { + write_line("\t.balign 4\n"); + bytes_written += (4 - (bytes_written % 4)); + } + write_byte((v >> 24) & 0xff); + write_byte((v >> 16) & 0xff); + write_byte((v >> 8) & 0xff); + write_byte((v >> 0) & 0xff); + bytes_written += 4; +} + +void +asm_writer::write_data(uint64_t v) +{ + if (bytes_written % 8 != 0) + { + write_line("\t.balign 8\n"); + bytes_written += (8 - (bytes_written % 8)); + } + write_byte((v >> 56) & 0xff); + write_byte((v >> 48) & 0xff); + write_byte((v >> 40) & 0xff); + write_byte((v >> 32) & 0xff); + write_byte((v >> 24) & 0xff); + write_byte((v >> 16) & 0xff); + write_byte((v >> 8) & 0xff); + write_byte((v >> 0) & 0xff); + bytes_written += 8; +} + +void +asm_writer::write_to_file(int fd) +{ + // FIXME: Check return + write(fd, buffer.data(), buffer.size()); +} + +uint32_t +asm_writer::size() +{ + return bytes_written; +} + +void +header::write(output_writer &out) +{ + out.write_label(string("dt_blob_start")); + out.write_label(string("dt_header")); + out.write_comment("magic"); + out.write_data(magic); + out.write_comment("totalsize"); + out.write_data(totalsize); + out.write_comment("off_dt_struct"); + out.write_data(off_dt_struct); + out.write_comment("off_dt_strings"); + out.write_data(off_dt_strings); + out.write_comment("off_mem_rsvmap"); + out.write_data(off_mem_rsvmap); + out.write_comment("version"); + out.write_data(version); + out.write_comment("last_comp_version"); + out.write_data(last_comp_version); + out.write_comment("boot_cpuid_phys"); + out.write_data(boot_cpuid_phys); + out.write_comment("size_dt_strings"); + out.write_data(size_dt_strings); + out.write_comment("size_dt_struct"); + out.write_data(size_dt_struct); +} + +bool +header::read_dtb(input_buffer &input) +{ + if (!(input.consume_binary(magic) && magic == 0xd00dfeed)) + { + fprintf(stderr, "Missing magic token in header. Got %" PRIx32 + " expected 0xd00dfeed\n", magic); + return false; + } + return input.consume_binary(totalsize) && + input.consume_binary(off_dt_struct) && + input.consume_binary(off_dt_strings) && + input.consume_binary(off_mem_rsvmap) && + input.consume_binary(version) && + input.consume_binary(last_comp_version) && + input.consume_binary(boot_cpuid_phys) && + input.consume_binary(size_dt_strings) && + input.consume_binary(size_dt_struct); +} +uint32_t +string_table::add_string(string str) +{ + std::map::iterator old = string_offsets.find(str); + if (old == string_offsets.end()) + { + uint32_t start = size; + // Don't forget the trailing nul + size += str.size() + 1; + string_offsets.insert(std::make_pair(str, start)); + strings.push_back(str); + return start; + } + else + { + return old->second; + } +} + +void +string_table::write(dtb::output_writer &writer) +{ + writer.write_comment(string("Strings table.")); + writer.write_label(string("dt_strings_start")); + for (std::vector::iterator i=strings.begin(), e=strings.end() ; + i!=e ; ++i) + { + writer.write_string(*i); + } + writer.write_label(string("dt_strings_end")); +} + +} // namespace dtb + +} // namespace dtc + Added: head/usr.bin/dtc/dtb.hh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/dtc/dtb.hh Tue Jan 22 17:49:51 2013 (r245803) @@ -0,0 +1,365 @@ +/*- + * Copyright (c) 2013 David Chisnall + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * 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 AUTHOR 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 AUTHOR 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. + * + * $FreeBSD$ + */ + +#ifndef _DTB_HH_ *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 17:56:07 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id BE7629EA; Tue, 22 Jan 2013 17:56:07 +0000 (UTC) (envelope-from utisoft@gmail.com) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by mx1.freebsd.org (Postfix) with ESMTP id 79D46938; Tue, 22 Jan 2013 17:56:07 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id c10so11960630ieb.25 for ; Tue, 22 Jan 2013 09:56:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=kjrn5pCSQsK+8lk2N8iFzwcH+bzuRw65lqu0Mg//NSY=; b=RK6MI7/unSMoyfCLF2VR2oHcAVfuxEhDx1PfQHGU15bEuUTMYpH/JUdLizJzH6SrJM qbBAq7C6b7fDJHDkVleXfkqLAXENiPRrQNJwmV75/Cyh6J6+G8sZYwg77hglvYB/o0T8 PHOiWv5yCMXGSDZQFhRvjFHvcURahhK8q8Pa00Vy7qyoRBhY+08ui+mkyCu+nIvGHRrQ niF9dxaoIsx3A3KXremd50D5ryuLT7gaTH0GAhJZkPQhvxhQvbEdfcZYoMdKzGi6B+si U1vuvwnDlkRuj7ZlT/Bb72iL/0QSm/Jn+n/a8lKWOs2cgZlIueuhUjklYjxod1CQUPTQ FC2A== X-Received: by 10.50.161.169 with SMTP id xt9mr12345721igb.62.1358877361566; Tue, 22 Jan 2013 09:56:01 -0800 (PST) MIME-Version: 1.0 Sender: utisoft@gmail.com Received: by 10.64.16.73 with HTTP; Tue, 22 Jan 2013 09:55:31 -0800 (PST) In-Reply-To: <201301212240.r0LMedcF088022@svn.freebsd.org> References: <201301212240.r0LMedcF088022@svn.freebsd.org> From: Chris Rees Date: Tue, 22 Jan 2013 17:55:31 +0000 X-Google-Sender-Auth: EGU5yYxbGmePB8yID77Ld_BhoLg Message-ID: Subject: Re: svn commit: r245752 - in head: etc share/mk To: Brooks Davis Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 17:56:07 -0000 On 21 January 2013 22:40, Brooks Davis wrote: > Author: brooks > Date: Mon Jan 21 22:40:39 2013 > New Revision: 245752 > URL: http://svnweb.freebsd.org/changeset/base/245752 > > Log: > Replace all known uses of ln in the build process with appropriate > install -l invocations via new INSTALL_LINK and INSTALL_SYMLINK > variables. > > Sponsored by: DARPA, AFRL > Reviewed by: ian, ray, rpaulo > > Modified: > head/etc/Makefile > head/share/mk/bsd.incs.mk > head/share/mk/bsd.info.mk > head/share/mk/bsd.lib.mk > head/share/mk/bsd.links.mk > head/share/mk/bsd.man.mk > head/share/mk/bsd.own.mk > > Modified: head/etc/Makefile > ============================================================================== > --- head/etc/Makefile Mon Jan 21 22:32:00 2013 (r245751) > +++ head/etc/Makefile Mon Jan 21 22:40:39 2013 (r245752) > @@ -324,26 +324,29 @@ distrib-dirs: > -f $$m -p $$d; \ > ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ > done; true > - ln -sfh usr/src/sys ${DESTDIR}/sys > + ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys This broke installworld for me, because of the different behaviour. ln -sf overwrites existing symlinks, whereas install -l a b puts a symlink to a inside itself... which fails on a read-only src (NFS mounted). Perhaps it's install misbehaving? I can't work out if it's bootstrapped properly; we should be using new install(1), are we? Chris From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 17:59:29 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 4B6FDBAD; Tue, 22 Jan 2013 17:59:29 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.dawidek.net (garage.dawidek.net [91.121.88.72]) by mx1.freebsd.org (Postfix) with ESMTP id F31F2972; Tue, 22 Jan 2013 17:59:28 +0000 (UTC) Received: from localhost (global-1-11.nat.csx.cam.ac.uk [131.111.184.11]) by mail.dawidek.net (Postfix) with ESMTPSA id BA666ADD; Tue, 22 Jan 2013 18:56:54 +0100 (CET) Date: Tue, 22 Jan 2013 19:00:05 +0100 From: Pawel Jakub Dawidek To: Brooks Davis Subject: Re: svn commit: r245751 - head/tools Message-ID: <20130122180005.GB1714@garage.freebsd.pl> References: <201301212232.r0LMW1F0086670@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7ZAtKRhVyVSsbBD2" Content-Disposition: inline In-Reply-To: <201301212232.r0LMW1F0086670@svn.freebsd.org> X-OS: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 17:59:29 -0000 --7ZAtKRhVyVSsbBD2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jan 21, 2013 at 10:32:00PM +0000, Brooks Davis wrote: > Author: brooks > Date: Mon Jan 21 22:32:00 2013 > New Revision: 245751 > URL: http://svnweb.freebsd.org/changeset/base/245751 >=20 > Log: > Implement the -l option using ln(1) to facilitate boostrapping. > =20 > Ignore the new options -D, -h, -T, and -U. Adjust -M support to ignore > an argument. I was doing installworld today and it failed on 'install -l ...' saying '/sys/sys' is not empty. When I removed /sys symlink it installed ok. Was this because of your change? --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://tupytaj.pl --7ZAtKRhVyVSsbBD2 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlD+06UACgkQForvXbEpPzTsfwCg755LPxzECgbjYsScE64qmpFi ge8AoOf+TeV5+V50Ytl1KrCLA4DCf/Id =zxiO -----END PGP SIGNATURE----- --7ZAtKRhVyVSsbBD2-- From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:02:48 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E4F02FC3; Tue, 22 Jan 2013 18:02:48 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CC22C9BC; Tue, 22 Jan 2013 18:02:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MI2mDD058150; Tue, 22 Jan 2013 18:02:48 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MI2msb058149; Tue, 22 Jan 2013 18:02:48 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201301221802.r0MI2msb058149@svn.freebsd.org> From: Ed Maste Date: Tue, 22 Jan 2013 18:02:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245804 - head/tools/tools/notescheck X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:02:49 -0000 Author: emaste Date: Tue Jan 22 18:02:48 2013 New Revision: 245804 URL: http://svnweb.freebsd.org/changeset/base/245804 Log: Restore Python 2.6+ compatibility SVN r245536 ported this to Python 3. The major change was the use of the print function. Unfortunately this is incompatible with Python 2, which is still the default version in the ports tree. Use a __future__ import to make this compatible with Python 2.6 and later. Modified: head/tools/tools/notescheck/notescheck.py Modified: head/tools/tools/notescheck/notescheck.py ============================================================================== --- head/tools/tools/notescheck/notescheck.py Tue Jan 22 17:49:51 2013 (r245803) +++ head/tools/tools/notescheck/notescheck.py Tue Jan 22 18:02:48 2013 (r245804) @@ -7,6 +7,8 @@ # # $FreeBSD$ +from __future__ import print_function + import glob import os.path import sys From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:02:59 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 48102174; Tue, 22 Jan 2013 18:02:59 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3B2579C1; Tue, 22 Jan 2013 18:02:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MI2xPZ058217; Tue, 22 Jan 2013 18:02:59 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MI2xcO058216; Tue, 22 Jan 2013 18:02:59 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201301221802.r0MI2xcO058216@svn.freebsd.org> From: Joel Dahl Date: Tue, 22 Jan 2013 18:02:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245805 - head/bin/sh X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:02:59 -0000 Author: joel (doc committer) Date: Tue Jan 22 18:02:58 2013 New Revision: 245805 URL: http://svnweb.freebsd.org/changeset/base/245805 Log: Add FILES section. Discussed with: jilles Modified: head/bin/sh/sh.1 Modified: head/bin/sh/sh.1 ============================================================================== --- head/bin/sh/sh.1 Tue Jan 22 18:02:48 2013 (r245804) +++ head/bin/sh/sh.1 Tue Jan 22 18:02:58 2013 (r245805) @@ -32,7 +32,7 @@ .\" from: @(#)sh.1 8.6 (Berkeley) 5/4/95 .\" $FreeBSD$ .\" -.Dd January 20, 2013 +.Dd January 22, 2013 .Dt SH 1 .Os .Sh NAME @@ -2674,6 +2674,17 @@ Additionally, all environment variables at startup, which may affect the shell as described under .Sx Special Variables . +.Sh FILES +.Bl -tag -width "/etc/suid_profileXX" -compact +.It Pa ~/.profile +User's login profile. +.It Pa /etc/profile +System login profile. +.It Pa /etc/shells +Shell database. +.It Pa /etc/suid_profile +Privileged shell profile. +.El .Sh EXIT STATUS Errors that are detected by the shell, such as a syntax error, will cause the shell to exit with a non-zero exit status. @@ -2699,7 +2710,8 @@ will return the argument. .Xr getrlimit 2 , .Xr umask 2 , .Xr wctype 3 , -.Xr editrc 5 +.Xr editrc 5 , +.Xr shells 5 .Sh HISTORY A .Nm From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:06:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C5FC837C; Tue, 22 Jan 2013 18:06:26 +0000 (UTC) (envelope-from pawel@dawidek.net) Received: from mail.dawidek.net (garage.dawidek.net [91.121.88.72]) by mx1.freebsd.org (Postfix) with ESMTP id 72E9D9EC; Tue, 22 Jan 2013 18:06:26 +0000 (UTC) Received: from localhost (global-1-11.nat.csx.cam.ac.uk [131.111.184.11]) by mail.dawidek.net (Postfix) with ESMTPSA id 07696AE7; Tue, 22 Jan 2013 19:03:52 +0100 (CET) Date: Tue, 22 Jan 2013 19:07:02 +0100 From: Pawel Jakub Dawidek To: Brooks Davis Subject: Re: svn commit: r245751 - head/tools Message-ID: <20130122180702.GC1714@garage.freebsd.pl> References: <201301212232.r0LMW1F0086670@svn.freebsd.org> <20130122180005.GB1714@garage.freebsd.pl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="z4+8/lEcDcG5Ke9S" Content-Disposition: inline In-Reply-To: <20130122180005.GB1714@garage.freebsd.pl> X-OS: FreeBSD 10.0-CURRENT amd64 User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:06:26 -0000 --z4+8/lEcDcG5Ke9S Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 22, 2013 at 07:00:05PM +0100, Pawel Jakub Dawidek wrote: > On Mon, Jan 21, 2013 at 10:32:00PM +0000, Brooks Davis wrote: > > Author: brooks > > Date: Mon Jan 21 22:32:00 2013 > > New Revision: 245751 > > URL: http://svnweb.freebsd.org/changeset/base/245751 > >=20 > > Log: > > Implement the -l option using ln(1) to facilitate boostrapping. > > =20 > > Ignore the new options -D, -h, -T, and -U. Adjust -M support to igno= re > > an argument. >=20 > I was doing installworld today and it failed on 'install -l ...' saying > '/sys/sys' is not empty. When I removed /sys symlink it installed ok. > Was this because of your change? I see it is fixed already, sorry for the noice. --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://tupytaj.pl --z4+8/lEcDcG5Ke9S Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlD+1UYACgkQForvXbEpPzRMgQCfX9vOVeZYJ305JupfRNr1NYVD 3vsAn0oo7M7ILYelqq9RYQGeyrA+v9Js =TvI4 -----END PGP SIGNATURE----- --z4+8/lEcDcG5Ke9S-- From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:07:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C803F501; Tue, 22 Jan 2013 18:07:46 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-ob0-f177.google.com (mail-ob0-f177.google.com [209.85.214.177]) by mx1.freebsd.org (Postfix) with ESMTP id 2C6209FE; Tue, 22 Jan 2013 18:07:46 +0000 (UTC) Received: by mail-ob0-f177.google.com with SMTP id wc20so6683895obb.36 for ; Tue, 22 Jan 2013 10:07:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=mIG0CJD1rxPhvRrQcOlt4G0gdtNp1zvjfxx5Z8Oein0=; b=z++tfGOnyRXWaye1PxY3yxg9vXHUYKv68UQdcOeJUtOit0cwjlKX5MdLCmNQ1ScArK pmOcJxVPI5qLrJuRucC0ble2539QW3eJoXRYNjgCAZFoWzJtEk6ynijFbQOdIxzeLEB5 2WGAuO2dEj3PIytPzOC6db3VrfC/nvRdJIF3k0GAS9Z2AACTQ06+62aNFqu/k9jxwIpV dGx9qJnSP2A4+NlzleRu0/GDNzAquO6kitflrdpL+PS5jkYgQzEz1rl0+8k/2FgNR7T9 25cK/0HZF051FJD5Tu/H94tW4iJ4gjPvvhR65qdmd4sxnMtglarQUA4os4KL49XlYyWg PTLQ== MIME-Version: 1.0 X-Received: by 10.182.8.73 with SMTP id p9mr17473397oba.88.1358878065667; Tue, 22 Jan 2013 10:07:45 -0800 (PST) Sender: carpeddiem@gmail.com Received: by 10.60.25.163 with HTTP; Tue, 22 Jan 2013 10:07:45 -0800 (PST) In-Reply-To: <201301221050.35473.jhb@freebsd.org> References: <201301170420.r0H4Ks7N092837@svn.freebsd.org> <201301221050.35473.jhb@freebsd.org> Date: Tue, 22 Jan 2013 13:07:45 -0500 X-Google-Sender-Auth: Guwt4QOJORuPPH0-G75plBQEvEg Message-ID: Subject: Re: svn commit: r245536 - head/tools/tools/notescheck From: Ed Maste To: John Baldwin Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:07:46 -0000 On 22 January 2013 10:50, John Baldwin wrote: > On Wednesday, January 16, 2013 11:20:54 pm Eitan Adler wrote: >> Author: eadler >> Date: Thu Jan 17 04:20:53 2013 >> New Revision: 245536 >> URL: http://svnweb.freebsd.org/changeset/base/245536 >> >> Log: >> Convert to Python 3 >> >> Approved by: cperciva > > Do we really want to do this? The ports tree still installs 2.7 by default > IIRC, and I for one always use 2.x (and I wrote this script originally). Your > changes make this script no longer work with 2.x. I think we should defer > switching various scripts to Python 3 until we start installing it as the > default python. I agree that this is premature while Python 3 is not the default. Fortunately there's an easy fix for Python 2.6+ (from __future__ import print_function), which I just committed in r245804. -Ed From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:07:59 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D97B566F; Tue, 22 Jan 2013 18:07:59 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CC8A0A04; Tue, 22 Jan 2013 18:07:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MI7xoa059106; Tue, 22 Jan 2013 18:07:59 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MI7xrt059105; Tue, 22 Jan 2013 18:07:59 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301221807.r0MI7xrt059105@svn.freebsd.org> From: Gleb Smirnoff Date: Tue, 22 Jan 2013 18:07:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245806 - head/usr.bin/netstat X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:07:59 -0000 Author: glebius Date: Tue Jan 22 18:07:59 2013 New Revision: 245806 URL: http://svnweb.freebsd.org/changeset/base/245806 Log: Use pluralies() for "entry"/"entries". Modified: head/usr.bin/netstat/inet.c Modified: head/usr.bin/netstat/inet.c ============================================================================== --- head/usr.bin/netstat/inet.c Tue Jan 22 18:02:58 2013 (r245805) +++ head/usr.bin/netstat/inet.c Tue Jan 22 18:07:59 2013 (r245806) @@ -699,7 +699,7 @@ tcp_stats(u_long off, const char *name, p(tcps_sc_sendcookie, "\t%lu cookie%s sent\n"); p(tcps_sc_recvcookie, "\t%lu cookie%s received\n"); - p(tcps_hc_added, "\t%lu hostcache entrie%s added\n"); + p3(tcps_hc_added, "\t%lu hostcache entr%s added\n"); p1a(tcps_hc_bucketoverflow, "\t\t%lu bucket overflow\n"); p(tcps_sack_recovery_episode, "\t%lu SACK recovery episode%s\n"); From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:12:32 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 9F9D497A; Tue, 22 Jan 2013 18:12:32 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 88073A58; Tue, 22 Jan 2013 18:12:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MICWsa061492; Tue, 22 Jan 2013 18:12:32 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MICWLT061491; Tue, 22 Jan 2013 18:12:32 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301221812.r0MICWLT061491@svn.freebsd.org> From: David Chisnall Date: Tue, 22 Jan 2013 18:12:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245807 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:12:32 -0000 Author: theraven Date: Tue Jan 22 18:12:31 2013 New Revision: 245807 URL: http://svnweb.freebsd.org/changeset/base/245807 Log: Fix logic error in explicitly specified dtb versions spotted by gavin. Modified: head/usr.bin/dtc/dtc.cc Modified: head/usr.bin/dtc/dtc.cc ============================================================================== --- head/usr.bin/dtc/dtc.cc Tue Jan 22 18:07:59 2013 (r245806) +++ head/usr.bin/dtc/dtc.cc Tue Jan 22 18:12:31 2013 (r245807) @@ -164,7 +164,7 @@ main(int argc, char **argv) debug_mode = true; break; case 'V': - if (string(optarg) == string("17")) + if (string(optarg) != string("17")) { fprintf(stderr, "Unknown output format version: %s\n", optarg); return EXIT_FAILURE; From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:13:49 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 48DF4B3F; Tue, 22 Jan 2013 18:13:49 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (lor.one-eyed-alien.net [69.66.77.232]) by mx1.freebsd.org (Postfix) with ESMTP id 07666A72; Tue, 22 Jan 2013 18:13:47 +0000 (UTC) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.5/8.14.5) with ESMTP id r0MIDmoo001992; Tue, 22 Jan 2013 12:13:48 -0600 (CST) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.5/8.14.5/Submit) id r0MIDmpH001991; Tue, 22 Jan 2013 12:13:48 -0600 (CST) (envelope-from brooks) Date: Tue, 22 Jan 2013 12:13:48 -0600 From: Brooks Davis To: Chris Rees Subject: Re: svn commit: r245752 - in head: etc share/mk Message-ID: <20130122181348.GA1662@lor.one-eyed-alien.net> References: <201301212240.r0LMedcF088022@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="J2SCkAp4GZ/dPZZf" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:13:49 -0000 --J2SCkAp4GZ/dPZZf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 22, 2013 at 05:55:31PM +0000, Chris Rees wrote: > On 21 January 2013 22:40, Brooks Davis wrote: > > Author: brooks > > Date: Mon Jan 21 22:40:39 2013 > > New Revision: 245752 > > URL: http://svnweb.freebsd.org/changeset/base/245752 > > > > Log: > > Replace all known uses of ln in the build process with appropriate > > install -l invocations via new INSTALL_LINK and INSTALL_SYMLINK > > variables. > > > > Sponsored by: DARPA, AFRL > > Reviewed by: ian, ray, rpaulo > > > > Modified: > > head/etc/Makefile > > head/share/mk/bsd.incs.mk > > head/share/mk/bsd.info.mk > > head/share/mk/bsd.lib.mk > > head/share/mk/bsd.links.mk > > head/share/mk/bsd.man.mk > > head/share/mk/bsd.own.mk > > > > Modified: head/etc/Makefile > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D > > --- head/etc/Makefile Mon Jan 21 22:32:00 2013 (r245751) > > +++ head/etc/Makefile Mon Jan 21 22:40:39 2013 (r245752) > > @@ -324,26 +324,29 @@ distrib-dirs: > > -f $$m -p $$d; \ > > ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $= $d; \ > > done; true > > - ln -sfh usr/src/sys ${DESTDIR}/sys > > + ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys >=20 > This broke installworld for me, because of the different behaviour. >=20 > ln -sf overwrites existing symlinks, whereas install -l a b puts a > symlink to a inside itself... which fails on a read-only src (NFS > mounted). >=20 > Perhaps it's install misbehaving? I can't work out if it's > bootstrapped properly; we should be using new install(1), are we? Sorry about that. It's fixed. -- Brooks --J2SCkAp4GZ/dPZZf Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (FreeBSD) iD8DBQFQ/tbcXY6L6fI4GtQRAiFLAKCxbdqoSTJF8dvxyoc5NrCMlnqtGQCeMxCO nGEQ58sX2BfUUQ0ST9rgBtk= =vDFI -----END PGP SIGNATURE----- --J2SCkAp4GZ/dPZZf-- From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:15:44 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5FE00DDD; Tue, 22 Jan 2013 18:15:44 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3B669A8E; Tue, 22 Jan 2013 18:15:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIFiid062056; Tue, 22 Jan 2013 18:15:44 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIFigc062055; Tue, 22 Jan 2013 18:15:44 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301221815.r0MIFigc062055@svn.freebsd.org> From: David Chisnall Date: Tue, 22 Jan 2013 18:15:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245809 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:15:44 -0000 Author: theraven Date: Tue Jan 22 18:15:43 2013 New Revision: 245809 URL: http://svnweb.freebsd.org/changeset/base/245809 Log: Fix the missing sentence that ended in the middle in the man page for dtc (also spotted by gavin). Modified: head/usr.bin/dtc/dtc.1 Modified: head/usr.bin/dtc/dtc.1 ============================================================================== --- head/usr.bin/dtc/dtc.1 Tue Jan 22 18:14:35 2013 (r245808) +++ head/usr.bin/dtc/dtc.1 Tue Jan 22 18:15:43 2013 (r245809) @@ -250,7 +250,10 @@ specification, but is in fact a label. The /include/ directive is not part of the standard, however it is implemented with the semantics compatible with the elinux.org tool. It must appear in the top level of a file, and imports a new root definition. If a file, plus all of -its inclusions, contains multiple roots then they +its inclusions, contains multiple roots then they are merged. All nodes that +are present in the second but not the first are imported. Any that appear in +both are recursively merged, with properties from the second replacing those +from the first and properties child nodes being recursively merged. .Sh HISTORY A dtc tool first appeared in .Fx 9.0 . From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:27:20 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 57C32723; Tue, 22 Jan 2013 18:27:20 +0000 (UTC) (envelope-from dru@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 342A5B5A; Tue, 22 Jan 2013 18:27:20 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIRKPM065462; Tue, 22 Jan 2013 18:27:20 GMT (envelope-from dru@svn.freebsd.org) Received: (from dru@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIRK04065461; Tue, 22 Jan 2013 18:27:20 GMT (envelope-from dru@svn.freebsd.org) Message-Id: <201301221827.r0MIRK04065461@svn.freebsd.org> From: Dru Lavigne Date: Tue, 22 Jan 2013 18:27:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245813 - head/share/misc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:27:20 -0000 Author: dru (doc committer) Date: Tue Jan 22 18:27:19 2013 New Revision: 245813 URL: http://svnweb.freebsd.org/changeset/base/245813 Log: add myself to committers-doc.dot Approved by: bcr (mentor) Modified: head/share/misc/committers-doc.dot Modified: head/share/misc/committers-doc.dot ============================================================================== --- head/share/misc/committers-doc.dot Tue Jan 22 18:25:55 2013 (r245812) +++ head/share/misc/committers-doc.dot Tue Jan 22 18:27:19 2013 (r245813) @@ -58,6 +58,7 @@ brueffer [label="Christian Brueffer\nbru chinsan [label="Chinsan Huang\nchinsan@FreeBSD.org\n2006/09/20"] danger [label="Daniel Gerzo\ndanger@FreeBSD.org\n2006/08/20"] delphij [label="Xin Li\ndelphij@FreeBSD.org\n2004/09/14"] +dru [label="Dru Lavigne\ndru@FreeBSD.org\n2013/01/22"] eadler [label="Eitan Adler\neadler@FreeBSD.org\n2012/10/15"] ebrandi [label="Edson Brandi\nebrandi@FreeBSD.org\n2012/09/13"] gabor [label="Gabor Kovesdan\ngabor@FreeBSD.org\n2007/02/02"] @@ -93,6 +94,7 @@ zeising [label="Niclas Zeising\nzeising@ bcr -> gavin bcr -> wblock bcr -> eadler +bcr -> dru blackend -> ale @@ -117,8 +119,10 @@ gabor -> ebrandi gjb -> wblock gjb -> rene +gjb -> dru hrs -> ryusuke +hrs -> dru jesusr -> jcamou From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:33:31 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DDC7EC8A; Tue, 22 Jan 2013 18:33:31 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D0295C24; Tue, 22 Jan 2013 18:33:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIXVxh068075; Tue, 22 Jan 2013 18:33:31 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIXVKH068074; Tue, 22 Jan 2013 18:33:31 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201301221833.r0MIXVKH068074@svn.freebsd.org> From: Joel Dahl Date: Tue, 22 Jan 2013 18:33:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245815 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:33:31 -0000 Author: joel (doc committer) Date: Tue Jan 22 18:33:31 2013 New Revision: 245815 URL: http://svnweb.freebsd.org/changeset/base/245815 Log: Minor mdoc fixes. Modified: head/usr.bin/dtc/dtc.1 Modified: head/usr.bin/dtc/dtc.1 ============================================================================== --- head/usr.bin/dtc/dtc.1 Tue Jan 22 18:30:46 2013 (r245814) +++ head/usr.bin/dtc/dtc.1 Tue Jan 22 18:33:31 2013 (r245815) @@ -173,7 +173,6 @@ end of the strings table. .It dt_blob_end end of the device tree blob. .El -.Pp .Sh CHECKERS The utility provides a number of semantic checks on the correctness of the tree. These can be disabled with the @@ -232,6 +231,8 @@ The warnings and errors supported by the This tool supports the warnings described in the .Sx CHECKERS section. +.Sh SEE ALSO +.Xr fdt 4 .Sh STANDARDS The device tree formats understood by this tool conform to the Power.org Standard for Embedded Power Architecture Platform Requirements @@ -278,6 +279,3 @@ hard to add, but will probably not be ad .Pp The current version performs a very limited set of semantic checks on the tree. This will be improved in future versions. -.Sh SEE ALSO -.Xr fdt 4 -.Pp From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:34:18 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 03B77E07; Tue, 22 Jan 2013 18:34:18 +0000 (UTC) (envelope-from utisoft@gmail.com) Received: from mail-ie0-f181.google.com (mail-ie0-f181.google.com [209.85.223.181]) by mx1.freebsd.org (Postfix) with ESMTP id 9CEE9C34; Tue, 22 Jan 2013 18:34:17 +0000 (UTC) Received: by mail-ie0-f181.google.com with SMTP id 16so11958983iea.40 for ; Tue, 22 Jan 2013 10:34:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=KobalvK5J08E+f0s0qCboRqDOzxdBB548hL6P93D6lc=; b=vMIIZ4B3AjIsnT91JMlA5H6NOC2qM2ZcNzhK426/ncgHliRERjB/VTi8ijQTT4Zu0R u8jnPOlPMO/JZIcSthwRj0osLfDlvUYH6oZFwlFBTkNI2iymITY6AXxf9pDgNeXbEmVk W6ala5TI/ABYOYbqzXj0rqKtIKicovV2Ka1oLM+XDUDvD3fczp/U0pk/enl2yDEq3Dyh +VdIDlJsj71O2JF66xCNFd16GjhcZRlU6k4t+Vfu1vu/HqCF1zM5Kn0p8t3d4j6NUBwM fb9sVZHUCrVMZXBZbSDudETFBxHX7iHm2GUGH1St96ntiGN95JdXNRuvzOJYJKSdlJkl eJrA== X-Received: by 10.50.158.170 with SMTP id wv10mr12852389igb.75.1358879651164; Tue, 22 Jan 2013 10:34:11 -0800 (PST) MIME-Version: 1.0 Sender: utisoft@gmail.com Received: by 10.64.16.73 with HTTP; Tue, 22 Jan 2013 10:33:41 -0800 (PST) In-Reply-To: <20130122181348.GA1662@lor.one-eyed-alien.net> References: <201301212240.r0LMedcF088022@svn.freebsd.org> <20130122181348.GA1662@lor.one-eyed-alien.net> From: Chris Rees Date: Tue, 22 Jan 2013 18:33:41 +0000 X-Google-Sender-Auth: OXAioJFwnOrA9Li1vZlzzO4WG1c Message-ID: Subject: Re: svn commit: r245752 - in head: etc share/mk To: Brooks Davis Content-Type: text/plain; charset=ISO-8859-1 Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:34:18 -0000 On 22 January 2013 18:13, Brooks Davis wrote: > On Tue, Jan 22, 2013 at 05:55:31PM +0000, Chris Rees wrote: >> On 21 January 2013 22:40, Brooks Davis wrote: >> > Author: brooks >> > Date: Mon Jan 21 22:40:39 2013 >> > New Revision: 245752 >> > URL: http://svnweb.freebsd.org/changeset/base/245752 >> > >> > Log: >> > Replace all known uses of ln in the build process with appropriate >> > install -l invocations via new INSTALL_LINK and INSTALL_SYMLINK >> > variables. >> > >> > Sponsored by: DARPA, AFRL >> > Reviewed by: ian, ray, rpaulo >> > >> > Modified: >> > head/etc/Makefile >> > head/share/mk/bsd.incs.mk >> > head/share/mk/bsd.info.mk >> > head/share/mk/bsd.lib.mk >> > head/share/mk/bsd.links.mk >> > head/share/mk/bsd.man.mk >> > head/share/mk/bsd.own.mk >> > >> > Modified: head/etc/Makefile >> > ============================================================================== >> > --- head/etc/Makefile Mon Jan 21 22:32:00 2013 (r245751) >> > +++ head/etc/Makefile Mon Jan 21 22:40:39 2013 (r245752) >> > @@ -324,26 +324,29 @@ distrib-dirs: >> > -f $$m -p $$d; \ >> > ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ >> > done; true >> > - ln -sfh usr/src/sys ${DESTDIR}/sys >> > + ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys >> >> This broke installworld for me, because of the different behaviour. >> >> ln -sf overwrites existing symlinks, whereas install -l a b puts a >> symlink to a inside itself... which fails on a read-only src (NFS >> mounted). >> >> Perhaps it's install misbehaving? I can't work out if it's >> bootstrapped properly; we should be using new install(1), are we? > > Sorry about that. It's fixed. > I presume r245793, thank you :) Chris From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:35:43 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 669ADF94; Tue, 22 Jan 2013 18:35:43 +0000 (UTC) (envelope-from joel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4A686CB6; Tue, 22 Jan 2013 18:35:43 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIZhDG068411; Tue, 22 Jan 2013 18:35:43 GMT (envelope-from joel@svn.freebsd.org) Received: (from joel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIZhGF068410; Tue, 22 Jan 2013 18:35:43 GMT (envelope-from joel@svn.freebsd.org) Message-Id: <201301221835.r0MIZhGF068410@svn.freebsd.org> From: Joel Dahl Date: Tue, 22 Jan 2013 18:35:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245816 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:35:43 -0000 Author: joel (doc committer) Date: Tue Jan 22 18:35:42 2013 New Revision: 245816 URL: http://svnweb.freebsd.org/changeset/base/245816 Log: Remove EOL whitespace. Modified: head/usr.bin/dtc/dtc.1 Modified: head/usr.bin/dtc/dtc.1 ============================================================================== --- head/usr.bin/dtc/dtc.1 Tue Jan 22 18:33:31 2013 (r245815) +++ head/usr.bin/dtc/dtc.1 Tue Jan 22 18:35:42 2013 (r245816) @@ -83,7 +83,7 @@ checker. The full list of checkers is g Force the tool to attempt to generate the output, even if the input had errors. .It Fl h Display the help text and exit. -.It Fl H Ar phandle_format +.It Fl H Ar phandle_format Specifies the type of phandle nodes to generate in the output. Valid values are: .Pp @@ -121,7 +121,7 @@ if the output format is not explicitly s Device tree source. The ASCII representation of the FDT. .El .It Fl o Ar output_file -The file to which to write the output. +The file to which to write the output. .It Fl R Ar entries The number of empty reservation table entries to pad the table with. This is useful if you are generating a device tree blob for bootloader or similar that @@ -129,11 +129,11 @@ needs to reserve some memory before pass .It Fl S Ar bytes The minimum size in bytes of the blob. The blob will be padded after the strings table to ensure that it is the correct size. This is useful for -environments where the device tree blob must be modified in place. +environments where the device tree blob must be modified in place. .It Fl p Ar bytes The number of bytes of padding to add to the blob. The blob will be padded after the strings table to ensure that it is the correct size. This is useful -for environments where the device tree blob must be modified in place. +for environments where the device tree blob must be modified in place. .It Fl W Ar [no-]checker_name Enable or disable a specified checker. This is an alias for .Fl E . @@ -183,16 +183,16 @@ will disable the phandle type check. Th .Pp .Bl -tag -width "no-type-phandle" -compact -offset indent .It type-compatible -Checks the type of the +Checks the type of the .Va compatible property. .It type-model -Checks the type of the +Checks the type of the .Va model property. .It type-compatible -Checks the type of the -.Va compatible +Checks the type of the +.Va compatible property. .El .Sh EXAMPLES @@ -200,7 +200,7 @@ The command: .Pp .Dl "dtc -o blob.S -O asm device.dts" .Pp -will generate a +will generate a .Pa blob.S file from the device tree source .Pa device.dts @@ -220,7 +220,7 @@ provided by elinux.org. Currently, it i required to build FreeBSD and others that have been requested by FreeBSD developers. .Pp -The +The .Ar fs input format is not supported. This builds a tree from a Linux .Pa /proc/device-tree , @@ -258,7 +258,7 @@ from the first and properties child node .Sh HISTORY A dtc tool first appeared in .Fx 9.0 . -This version of the tool first appeared in +This version of the tool first appeared in .Fx 10.0 . .Sh AUTHORS .An David T. Chisnall From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:36:32 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7FFD61A3; Tue, 22 Jan 2013 18:36:32 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 70FD9CC8; Tue, 22 Jan 2013 18:36:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIaWCC068566; Tue, 22 Jan 2013 18:36:32 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIaWH4068564; Tue, 22 Jan 2013 18:36:32 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201301221836.r0MIaWH4068564@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Tue, 22 Jan 2013 18:36:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245817 - head/sys/fs/ext2fs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:36:32 -0000 Author: pfg Date: Tue Jan 22 18:36:31 2013 New Revision: 245817 URL: http://svnweb.freebsd.org/changeset/base/245817 Log: ext2fs: temporarily disable the reallocation code. Testing with fsx has revealed problems and in order to hunt the bugs properly we need reduce the complexity. This seems to help but is not a complete solution. MFC after: 3 days Modified: head/sys/fs/ext2fs/ext2_alloc.c Modified: head/sys/fs/ext2fs/ext2_alloc.c ============================================================================== --- head/sys/fs/ext2fs/ext2_alloc.c Tue Jan 22 18:35:42 2013 (r245816) +++ head/sys/fs/ext2fs/ext2_alloc.c Tue Jan 22 18:36:31 2013 (r245817) @@ -151,11 +151,11 @@ nospace: static SYSCTL_NODE(_vfs, OID_AUTO, ext2fs, CTLFLAG_RW, 0, "EXT2FS filesystem"); -static int doasyncfree = 1; +static int doasyncfree = 0; SYSCTL_INT(_vfs_ext2fs, OID_AUTO, doasyncfree, CTLFLAG_RW, &doasyncfree, 0, "Use asychronous writes to update block pointers when freeing blocks"); -static int doreallocblks = 1; +static int doreallocblks = 0; SYSCTL_INT(_vfs_ext2fs, OID_AUTO, doreallocblks, CTLFLAG_RW, &doreallocblks, 0, ""); int From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:43:37 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5F6F4AD4 for ; Tue, 22 Jan 2013 18:43:37 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id DAB04D5E for ; Tue, 22 Jan 2013 18:43:36 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id gw10so7088082lab.13 for ; Tue, 22 Jan 2013 10:43:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=pctBYClyc+uKhdYn22Jrrnuf/jPvkO8syigGC8sZ3PI=; b=WP5HHV/3C+OwLRN9bKiCLHaN1aI++ti4AV4jH6K0nDjNRUQ5xjQ4nwTz/PwB9Iq8xF uxOLNi1PiHPLbXjZ+ZilvKZXydYGYX68Hul1o36cHzhsuhuvf50fhI+fI2usVf7zTBpm 5yrsOiObLgKvCCZx/vZDtWhtK5BqbTlohPsiM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=pctBYClyc+uKhdYn22Jrrnuf/jPvkO8syigGC8sZ3PI=; b=hVUMlGKsDwFTGjpLEivdwz2FDmu2iPH0A/7f01MtW1MOcyGUHcEOAjkLtrNdw0aQ8N K7CnMmWIiyoQFkbzEmk1kPxXz+m2HDa6ciJvxSHezy4gAg5Z9CUmOdLBf3kdnijmGkDw A341tOnVyKxce3wnjl+MG8dXsIXLUYVPlqHmSkiAxeoLv18fceqWuQQjpdPficOk3EOE 5AXICc6idgEn7nZ/72NGm8N/oxJJTtbmjTL4PDR1Ah+vBt8zLbe4QSYtUrNY6nm2510M q0GwYJ3u+NFx0VMpid9hvot874gy3Z4UqlACzTKtj4xYq7D7meJUiwO/WPzj3f5a8x5Z PUYg== X-Received: by 10.112.17.194 with SMTP id q2mr9599748lbd.7.1358880215581; Tue, 22 Jan 2013 10:43:35 -0800 (PST) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.112.100.164 with HTTP; Tue, 22 Jan 2013 10:43:05 -0800 (PST) In-Reply-To: <201301221050.35473.jhb@freebsd.org> References: <201301170420.r0H4Ks7N092837@svn.freebsd.org> <201301221050.35473.jhb@freebsd.org> From: Eitan Adler Date: Tue, 22 Jan 2013 13:43:05 -0500 X-Google-Sender-Auth: ql2EsW3o2Hwj5VqzHrGGnoRzoOc Message-ID: Subject: Re: svn commit: r245536 - head/tools/tools/notescheck To: John Baldwin Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQnBh/rMkEnMBpXBVrtyqB4ASN5x5/9AtsMQ+QlLdUrZVAFl01HKHngc/TU4PErOE1Qay/Vb Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:43:37 -0000 On 22 January 2013 10:50, John Baldwin wrote: > On Wednesday, January 16, 2013 11:20:54 pm Eitan Adler wrote: >> Author: eadler >> Date: Thu Jan 17 04:20:53 2013 >> New Revision: 245536 >> URL: http://svnweb.freebsd.org/changeset/base/245536 >> >> Log: >> Convert to Python 3 >> >> Approved by: cperciva > > Do we really want to do this? The ports tree still installs 2.7 by default > IIRC, and I for one always use 2.x (and I wrote this script originally). Your > changes make this script no longer work with 2.x. I think we should defer > switching various scripts to Python 3 until we start installing it as the > default python. Okay. I will try make sure that such changes work in both python 2 and python 3 in the future. FWIW Python 2 is considered "extended support and the end-of-life release" so we should be thinking about preparing for the future already. -- Eitan Adler Source, Ports, Doc committer Bugmeister, Ports Security teams From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:44:23 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3FE6CC4E; Tue, 22 Jan 2013 18:44:23 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 0FB95D70; Tue, 22 Jan 2013 18:44:23 +0000 (UTC) Received: from pakbsde14.localnet (unknown [38.105.238.108]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 5A2E9B918; Tue, 22 Jan 2013 13:44:22 -0500 (EST) From: John Baldwin To: David Chisnall Subject: Re: svn commit: r245803 - in head: . gnu/usr.bin share/man/man5 share/mk usr.bin/dtc Date: Tue, 22 Jan 2013 13:38:38 -0500 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p22; KDE/4.5.5; amd64; ; ) References: <201301221749.r0MHnpbC053016@svn.freebsd.org> In-Reply-To: <201301221749.r0MHnpbC053016@svn.freebsd.org> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201301221338.38628.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Tue, 22 Jan 2013 13:44:22 -0500 (EST) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:44:23 -0000 On Tuesday, January 22, 2013 12:49:51 pm David Chisnall wrote: > Author: theraven > Date: Tue Jan 22 17:49:51 2013 > New Revision: 245803 > URL: http://svnweb.freebsd.org/changeset/base/245803 > > Log: > Import new (BSDL) device tree compiler. Now built by default, so that it can't > be used on the host system (and not installed on the device, if required). The > GPL'd one is still available if there are any devices that need it (make > universe passes with it, including kernels that use fdt, but there may be some > out-of-tree ones). WITH_GPL_DTC can be used to select the old one, for now. > > Probably won't be MFC'd, but we'll remove the GPL'd version in head after the > new one has had a lot more testing and ship it in 10.0. > > Modified: > head/Makefile.inc1 > > Modified: head/Makefile.inc1 > ============================================================================== > --- head/Makefile.inc1 Tue Jan 22 17:21:08 2013 (r245802) > +++ head/Makefile.inc1 Tue Jan 22 17:49:51 2013 (r245803) > @@ -1112,7 +1112,10 @@ _dtrace_tools= cddl/usr.bin/sgsmsg cddl/ > lib/libdwarf cddl/usr.bin/ctfconvert cddl/usr.bin/ctfmerge > .endif > > -.if ${MK_FDT} != "no" > +# Default to building the BSDL DTC, but build the GPL one if users explicitly > +# request it. > +_dtc= /usr.bin/dtc > +.if ${MK_GPL_DTC} != "no" > _dtc= gnu/usr.bin/dtc > .endif Should this use "usr.bin/dtc" rather than "/usr.bin/dtc"? -- John Baldwin From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:48:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2241AE16; Tue, 22 Jan 2013 18:48:46 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 14D43DA8; Tue, 22 Jan 2013 18:48:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MImjHJ071947; Tue, 22 Jan 2013 18:48:45 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MImjmL071946; Tue, 22 Jan 2013 18:48:45 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301221848.r0MImjmL071946@svn.freebsd.org> From: Brooks Davis Date: Tue, 22 Jan 2013 18:48:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245818 - head/sys/dev/altera/sdcard X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:48:46 -0000 Author: brooks Date: Tue Jan 22 18:48:45 2013 New Revision: 245818 URL: http://svnweb.freebsd.org/changeset/base/245818 Log: MFP4 change 219819 Remove a duplicate computation of C_SIZE_MULT. Once is sufficient. Sponsored by: DARPA, AFRL Modified: head/sys/dev/altera/sdcard/altera_sdcard_io.c Modified: head/sys/dev/altera/sdcard/altera_sdcard_io.c ============================================================================== --- head/sys/dev/altera/sdcard/altera_sdcard_io.c Tue Jan 22 18:36:31 2013 (r245817) +++ head/sys/dev/altera/sdcard/altera_sdcard_io.c Tue Jan 22 18:48:45 2013 (r245818) @@ -93,13 +93,6 @@ altera_sdcard_process_csd0(struct altera read_bl_len = sc->as_csd.csd_data[ALTERA_SDCARD_CSD_READ_BL_LEN_BYTE]; read_bl_len &= ALTERA_SDCARD_CSD_READ_BL_LEN_MASK; - byte0 = sc->as_csd.csd_data[ALTERA_SDCARD_CSD_C_SIZE_MULT_BYTE0]; - byte0 &= ALTERA_SDCARD_CSD_C_SIZE_MULT_MASK0; - byte1 = sc->as_csd.csd_data[ALTERA_SDCARD_CSD_C_SIZE_MULT_BYTE1]; - byte1 &= ALTERA_SDCARD_CSD_C_SIZE_MULT_MASK1; - c_size_mult = (byte0 >> ALTERA_SDCARD_CSD_C_SIZE_MULT_RSHIFT0) | - (byte0 << ALTERA_SDCARD_CSD_C_SIZE_MULT_LSHIFT1); - byte0 = sc->as_csd.csd_data[ALTERA_SDCARD_CSD_C_SIZE_BYTE0]; byte0 &= ALTERA_SDCARD_CSD_C_SIZE_MASK0; byte1 = sc->as_csd.csd_data[ALTERA_SDCARD_CSD_C_SIZE_BYTE1]; From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:51:14 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DC0D02AF; Tue, 22 Jan 2013 18:51:14 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CA09ADD6; Tue, 22 Jan 2013 18:51:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIpEEY073878; Tue, 22 Jan 2013 18:51:14 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIpEfO073877; Tue, 22 Jan 2013 18:51:14 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301221851.r0MIpEfO073877@svn.freebsd.org> From: Brooks Davis Date: Tue, 22 Jan 2013 18:51:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245819 - head/sys/dev/altera/sdcard X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:51:14 -0000 Author: brooks Date: Tue Jan 22 18:51:14 2013 New Revision: 245819 URL: http://svnweb.freebsd.org/changeset/base/245819 Log: MFP4 change 219820 Add a missing 0 to the mask for byte0 of C_SIZE. The previous mask (0xc) worked except that the last 0-1536K of the disk could not be accessed since we were shifting the (wrong) bits we did mask off the right edge. Modified: head/sys/dev/altera/sdcard/altera_sdcard.h Modified: head/sys/dev/altera/sdcard/altera_sdcard.h ============================================================================== --- head/sys/dev/altera/sdcard/altera_sdcard.h Tue Jan 22 18:48:45 2013 (r245818) +++ head/sys/dev/altera/sdcard/altera_sdcard.h Tue Jan 22 18:51:14 2013 (r245819) @@ -138,7 +138,7 @@ void altera_sdcard_io_start(struct alter * data. Software ease of use was not a design consideration. */ #define ALTERA_SDCARD_CSD_C_SIZE_BYTE0 7 -#define ALTERA_SDCARD_CSD_C_SIZE_MASK0 0xc /* top 2 bits */ +#define ALTERA_SDCARD_CSD_C_SIZE_MASK0 0xc0 /* top 2 bits */ #define ALTERA_SDCARD_CSD_C_SIZE_RSHIFT0 6 #define ALTERA_SDCARD_CSD_C_SIZE_BYTE1 8 From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:54:04 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B1CD8627; Tue, 22 Jan 2013 18:54:04 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A3F06E01; Tue, 22 Jan 2013 18:54:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIs4rK074276; Tue, 22 Jan 2013 18:54:04 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIs3ap074270; Tue, 22 Jan 2013 18:54:03 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201301221854.r0MIs3ap074270@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Tue, 22 Jan 2013 18:54:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245820 - head/sys/fs/ext2fs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:54:04 -0000 Author: pfg Date: Tue Jan 22 18:54:03 2013 New Revision: 245820 URL: http://svnweb.freebsd.org/changeset/base/245820 Log: ext2fs: make some inode fields match the ext2 spec. Ext2fs uses unsigned fields in its dinode struct. FreeBSD can have negative values in some of those fields and the inode is meant to interact with the system so we have never respected the unsigned nature of most of those fields. Block numbers and the NFS generation number do not need to be signed so redefine them as unsigned to better match the on-disk information. MFC after: 1 week Modified: head/sys/fs/ext2fs/ext2_alloc.c head/sys/fs/ext2fs/ext2_balloc.c head/sys/fs/ext2fs/ext2_inode.c head/sys/fs/ext2fs/inode.h Modified: head/sys/fs/ext2fs/ext2_alloc.c ============================================================================== --- head/sys/fs/ext2fs/ext2_alloc.c Tue Jan 22 18:51:14 2013 (r245819) +++ head/sys/fs/ext2fs/ext2_alloc.c Tue Jan 22 18:54:03 2013 (r245820) @@ -169,7 +169,7 @@ ext2_reallocblks(ap) struct inode *ip; struct vnode *vp; struct buf *sbp, *ebp; - int32_t *bap, *sbap, *ebap = 0; + uint32_t *bap, *sbap, *ebap = 0; struct ext2mount *ump; struct cluster_save *buflist; struct indir start_ap[NIADDR + 1], end_ap[NIADDR + 1], *idp; Modified: head/sys/fs/ext2fs/ext2_balloc.c ============================================================================== --- head/sys/fs/ext2fs/ext2_balloc.c Tue Jan 22 18:51:14 2013 (r245819) +++ head/sys/fs/ext2fs/ext2_balloc.c Tue Jan 22 18:54:03 2013 (r245820) @@ -69,7 +69,7 @@ ext2_balloc(ip, lbn, size, cred, bpp, fl struct buf *bp, *nbp; struct vnode *vp = ITOV(ip); struct indir indirs[NIADDR + 2]; - int32_t newb, *bap, pref; + uint32_t newb, *bap, pref; int osize, nsize, num, i, error; *bpp = NULL; Modified: head/sys/fs/ext2fs/ext2_inode.c ============================================================================== --- head/sys/fs/ext2fs/ext2_inode.c Tue Jan 22 18:51:14 2013 (r245819) +++ head/sys/fs/ext2fs/ext2_inode.c Tue Jan 22 18:54:03 2013 (r245820) @@ -119,7 +119,7 @@ ext2_truncate(vp, length, flags, cred, t int32_t lastblock; struct inode *oip; int32_t bn, lbn, lastiblock[NIADDR], indir_lbn[NIADDR]; - int32_t oldblks[NDADDR + NIADDR], newblks[NDADDR + NIADDR]; + uint32_t oldblks[NDADDR + NIADDR], newblks[NDADDR + NIADDR]; struct bufobj *bo; struct m_ext2fs *fs; struct buf *bp; @@ -342,7 +342,9 @@ done: */ oip->i_size = length; oip->i_blocks -= blocksreleased; - if (oip->i_blocks < 0) /* sanity */ + if (oip->i_blocks > blocksreleased) + oip->i_blocks -= blocksreleased; + else /* sanity */ oip->i_blocks = 0; oip->i_flag |= IN_CHANGE; vnode_pager_setsize(ovp, length); Modified: head/sys/fs/ext2fs/inode.h ============================================================================== --- head/sys/fs/ext2fs/inode.h Tue Jan 22 18:51:14 2013 (r245819) +++ head/sys/fs/ext2fs/inode.h Tue Jan 22 18:54:03 2013 (r245820) @@ -90,11 +90,11 @@ struct inode { int32_t i_atimensec; /* Last access time. */ int32_t i_ctimensec; /* Last inode change time. */ int32_t i_birthnsec; /* Inode creation time. */ - int32_t i_db[NDADDR]; /* Direct disk blocks. */ - int32_t i_ib[NIADDR]; /* Indirect disk blocks. */ + uint32_t i_db[NDADDR]; /* Direct disk blocks. */ + uint32_t i_ib[NIADDR]; /* Indirect disk blocks. */ uint32_t i_flags; /* Status flags (chflags). */ - int32_t i_blocks; /* Blocks actually held. */ - int32_t i_gen; /* Generation number. */ + uint32_t i_blocks; /* Blocks actually held. */ + uint32_t i_gen; /* Generation number. */ uint32_t i_uid; /* File owner. */ uint32_t i_gid; /* File group. */ }; @@ -162,7 +162,7 @@ struct ufid { uint16_t ufid_len; /* Length of structure. */ uint16_t ufid_pad; /* Force 32-bit alignment. */ ino_t ufid_ino; /* File number (ino). */ - int32_t ufid_gen; /* Generation number. */ + uint32_t ufid_gen; /* Generation number. */ }; #endif /* _KERNEL */ From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 18:57:52 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3E30C7DB; Tue, 22 Jan 2013 18:57:52 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 30913E2A; Tue, 22 Jan 2013 18:57:52 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MIvqpq074807; Tue, 22 Jan 2013 18:57:52 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MIvq2H074806; Tue, 22 Jan 2013 18:57:52 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301221857.r0MIvq2H074806@svn.freebsd.org> From: Brooks Davis Date: Tue, 22 Jan 2013 18:57:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245821 - head/usr.bin/xinstall X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 18:57:52 -0000 Author: brooks Date: Tue Jan 22 18:57:51 2013 New Revision: 245821 URL: http://svnweb.freebsd.org/changeset/base/245821 Log: Remove documentation of the old -M option. Sponsored by: DARPA, AFRL Modified: head/usr.bin/xinstall/install.1 Modified: head/usr.bin/xinstall/install.1 ============================================================================== --- head/usr.bin/xinstall/install.1 Tue Jan 22 18:54:03 2013 (r245820) +++ head/usr.bin/xinstall/install.1 Tue Jan 22 18:57:51 2013 (r245821) @@ -36,7 +36,7 @@ .Nd install binaries .Sh SYNOPSIS .Nm -.Op Fl bCcMpSsUv +.Op Fl bCcpSsUv .Op Fl B Ar suffix .Op Fl D Ar destdir .Op Fl f Ar flags @@ -50,7 +50,7 @@ .Op Fl T Ar tags .Ar file1 file2 .Nm -.Op Fl bCcMpSsUv +.Op Fl bCcpSsUv .Op Fl B Ar suffix .Op Fl D Ar destdir .Op Fl f Ar flags @@ -194,9 +194,6 @@ are: Absolute and relative have effect only for symbolic links. Mixed links are hard links for files on the same filesystem, symbolic otherwise. -.It Fl M -Disable all use of -.Xr mmap 2 . .It Fl M Ar metalog Write the metadata associated with each item installed to .Ar metalog From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 19:40:27 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 406AC426; Tue, 22 Jan 2013 19:40:27 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 33111FA7; Tue, 22 Jan 2013 19:40:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MJeRYi087138; Tue, 22 Jan 2013 19:40:27 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MJeRLB087137; Tue, 22 Jan 2013 19:40:27 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301221940.r0MJeRLB087137@svn.freebsd.org> From: David Chisnall Date: Tue, 22 Jan 2013 19:40:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245822 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 19:40:27 -0000 Author: theraven Date: Tue Jan 22 19:40:26 2013 New Revision: 245822 URL: http://svnweb.freebsd.org/changeset/base/245822 Log: Fix spurious leading / on dtc path in Makefile.inc1. Spotted by jhb. Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Tue Jan 22 18:57:51 2013 (r245821) +++ head/Makefile.inc1 Tue Jan 22 19:40:26 2013 (r245822) @@ -1114,7 +1114,7 @@ _dtrace_tools= cddl/usr.bin/sgsmsg cddl/ # Default to building the BSDL DTC, but build the GPL one if users explicitly # request it. -_dtc= /usr.bin/dtc +_dtc= usr.bin/dtc .if ${MK_GPL_DTC} != "no" _dtc= gnu/usr.bin/dtc .endif From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 19:45:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 985586EA; Tue, 22 Jan 2013 19:45:05 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6E5A3FDE; Tue, 22 Jan 2013 19:45:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MJj5se089367; Tue, 22 Jan 2013 19:45:05 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MJj5Ni089363; Tue, 22 Jan 2013 19:45:05 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301221945.r0MJj5Ni089363@svn.freebsd.org> From: John Baldwin Date: Tue, 22 Jan 2013 19:45:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245823 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 19:45:05 -0000 Author: jhb Date: Tue Jan 22 19:45:04 2013 New Revision: 245823 URL: http://svnweb.freebsd.org/changeset/base/245823 Log: Use decimal values for UDP and TCP socket options rather than hex to avoid implying that these constants should be treated as bit masks. Reviewed by: net MFC after: 1 week Modified: head/sys/netinet/tcp.h head/sys/netinet/udp.h Modified: head/sys/netinet/tcp.h ============================================================================== --- head/sys/netinet/tcp.h Tue Jan 22 19:40:26 2013 (r245822) +++ head/sys/netinet/tcp.h Tue Jan 22 19:45:04 2013 (r245823) @@ -149,20 +149,22 @@ struct tcphdr { #endif /* __BSD_VISIBLE */ /* - * User-settable options (used with setsockopt). + * User-settable options (used with setsockopt). These are discrete + * values and are not masked together. Some values appear to be + * bitmasks for historical reasons. */ -#define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */ +#define TCP_NODELAY 1 /* don't delay send to coalesce packets */ #if __BSD_VISIBLE -#define TCP_MAXSEG 0x02 /* set maximum segment size */ -#define TCP_NOPUSH 0x04 /* don't push last block of write */ -#define TCP_NOOPT 0x08 /* don't use TCP options */ -#define TCP_MD5SIG 0x10 /* use MD5 digests (RFC2385) */ -#define TCP_INFO 0x20 /* retrieve tcp_info structure */ -#define TCP_CONGESTION 0x40 /* get/set congestion control algorithm */ -#define TCP_KEEPINIT 0x80 /* N, time to establish connection */ -#define TCP_KEEPIDLE 0x100 /* L,N,X start keeplives after this period */ -#define TCP_KEEPINTVL 0x200 /* L,N interval between keepalives */ -#define TCP_KEEPCNT 0x400 /* L,N number of keepalives before close */ +#define TCP_MAXSEG 2 /* set maximum segment size */ +#define TCP_NOPUSH 4 /* don't push last block of write */ +#define TCP_NOOPT 8 /* don't use TCP options */ +#define TCP_MD5SIG 16 /* use MD5 digests (RFC2385) */ +#define TCP_INFO 32 /* retrieve tcp_info structure */ +#define TCP_CONGESTION 64 /* get/set congestion control algorithm */ +#define TCP_KEEPINIT 128 /* N, time to establish connection */ +#define TCP_KEEPIDLE 256 /* L,N,X start keeplives after this period */ +#define TCP_KEEPINTVL 512 /* L,N interval between keepalives */ +#define TCP_KEEPCNT 1024 /* L,N number of keepalives before close */ #define TCP_CA_NAME_MAX 16 /* max congestion control name length */ Modified: head/sys/netinet/udp.h ============================================================================== --- head/sys/netinet/udp.h Tue Jan 22 19:40:26 2013 (r245822) +++ head/sys/netinet/udp.h Tue Jan 22 19:45:04 2013 (r245823) @@ -48,7 +48,7 @@ struct udphdr { /* * User-settable options (used with setsockopt). */ -#define UDP_ENCAP 0x01 +#define UDP_ENCAP 1 /* From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 20:37:31 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C3026294; Tue, 22 Jan 2013 20:37:31 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id ABDEA22B; Tue, 22 Jan 2013 20:37:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MKbVgk004721; Tue, 22 Jan 2013 20:37:31 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MKbVZp004719; Tue, 22 Jan 2013 20:37:31 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301222037.r0MKbVZp004719@svn.freebsd.org> From: John Baldwin Date: Tue, 22 Jan 2013 20:37:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245824 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 20:37:31 -0000 Author: jhb Date: Tue Jan 22 20:37:31 2013 New Revision: 245824 URL: http://svnweb.freebsd.org/changeset/base/245824 Log: Similar to r245823, use decimal constants for UNIX domain socket options. MFC after: 1 week Modified: head/sys/sys/un.h Modified: head/sys/sys/un.h ============================================================================== --- head/sys/sys/un.h Tue Jan 22 19:45:04 2013 (r245823) +++ head/sys/sys/un.h Tue Jan 22 20:37:31 2013 (r245824) @@ -53,9 +53,9 @@ struct sockaddr_un { #if __BSD_VISIBLE /* Socket options. */ -#define LOCAL_PEERCRED 0x001 /* retrieve peer credentials */ -#define LOCAL_CREDS 0x002 /* pass credentials to receiver */ -#define LOCAL_CONNWAIT 0x004 /* connects block until accepted */ +#define LOCAL_PEERCRED 1 /* retrieve peer credentials */ +#define LOCAL_CREDS 2 /* pass credentials to receiver */ +#define LOCAL_CONNWAIT 4 /* connects block until accepted */ #ifndef _KERNEL From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 21:10:03 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EA7B3D97; Tue, 22 Jan 2013 21:10:03 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CE77736F; Tue, 22 Jan 2013 21:10:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MLA3WB014405; Tue, 22 Jan 2013 21:10:03 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MLA3ne014403; Tue, 22 Jan 2013 21:10:03 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301222110.r0MLA3ne014403@svn.freebsd.org> From: Brooks Davis Date: Tue, 22 Jan 2013 21:10:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245825 - in head: . etc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 21:10:04 -0000 Author: brooks Date: Tue Jan 22 21:10:03 2013 New Revision: 245825 URL: http://svnweb.freebsd.org/changeset/base/245825 Log: Introduce a new option -DNO_ROOT that allows install and distribution targets to be run without root privilege. Information about ownership, group, flags, and suid bits are stored in the file specified by METALOG which defaults to ${DESTDIR}/METALOG. This file can be used in conjunction with bsdtar or makefs to generate archives or file system images with correct permissions. The packageworld target has been altered to use this metadata allowing non-root releases (subject to further changes in release/Makefile.) Sponsored by: DARPA, AFRL Reviewed by: ian, ray Modified: head/Makefile.inc1 head/etc/Makefile Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Tue Jan 22 20:37:31 2013 (r245824) +++ head/Makefile.inc1 Tue Jan 22 21:10:03 2013 (r245825) @@ -4,6 +4,8 @@ # Make command line options: # -DNO_CLEANDIR run ${MAKE} clean, instead of ${MAKE} cleandir # -DNO_CLEAN do not clean at all +# -DDB_FROM_SRC use the user/group databases in src/etc instead of +# the system database when installing. # -DNO_SHARE do not go into share subdir # -DKERNFAST define NO_KERNEL{CONFIG,CLEAN,DEPEND,OBJ} # -DNO_KERNELCONFIG do not run config in ${MAKE} buildkernel @@ -11,9 +13,8 @@ # -DNO_KERNELDEPEND do not run ${MAKE} depend in ${MAKE} buildkernel # -DNO_KERNELOBJ do not run ${MAKE} obj in ${MAKE} buildkernel # -DNO_PORTSUPDATE do not update ports in ${MAKE} update +# -DNO_ROOT install without using root privilege # -DNO_DOCUPDATE do not update doc in ${MAKE} update -# -DDB_FROM_SRC use the user/group databases in src/etc instead of -# the system database when installing. # -DNO_CTF do not run the DTrace CTF conversion tools on built objects # LOCAL_DIRS="list of dirs" to add additional dirs to the SUBDIR list # LOCAL_LIB_DIRS="list of dirs" to add additional dirs to libraries target @@ -21,6 +22,8 @@ # to be created before files are installed # LOCAL_TOOL_DIRS="list of dirs" to add additional dirs to the build-tools # list +# METALOG="path to metadata log" to write permission and ownership +# when NO_ROOT is set. (default: ${DESTDIR}/METALOG) # TARGET="machine" to crossbuild world for a different machine type # TARGET_ARCH= may be required when a TARGET supports multiple endians # BUILDENV_SHELL= shell to launch for the buildenv target (def:/bin/sh) @@ -358,8 +361,19 @@ IMAKE+= __MAKE_SHELL=${INSTALLTMP}/sh IMAKEENV+= PATH=${TMPPATH}:${INSTALLTMP} .endif .if defined(DB_FROM_SRC) -IMAKE_INSTALL= INSTALL="install -N ${.CURDIR}/etc" -IMAKE_MTREE= MTREE_CMD="nmtree -N ${.CURDIR}/etc" +INSTALLFLAGS+= -N ${.CURDIR}/etc +MTREEFLAGS+= -N ${.CURDIR}/etc +.endif +.if defined(NO_ROOT) +METALOG?= ${DESTDIR}/${DISTDIR}/METALOG +IMAKE+= -DNO_ROOT METALOG=${METALOG} +INSTALL_DDIR= ${DESTDIR}/${DISTDIR} +INSTALLFLAGS+= -U -M ${METALOG} -D ${INSTALL_DDIR:S://:/:g} +MTREEFLAGS+= -W +.endif +.if defined(DB_FROM_SRC) || defined(NO_ROOT) +IMAKE_INSTALL= INSTALL="install ${INSTALLFLAGS}" +IMAKE_MTREE= MTREE_CMD="nmtree ${MTREEFLAGS}" .endif # kernel stage @@ -658,7 +672,7 @@ _zoneinfo= zic tzsetup .endif ITOOLS= [ awk cap_mkdb cat chflags chmod chown \ - date echo egrep find grep ${_install-info} \ + date echo egrep find grep id install ${_install-info} \ ln lockf make mkdir mtree mv pwd_mkdb rm sed sh sysctl \ test true uname wc ${_zoneinfo} @@ -681,6 +695,8 @@ EXTRA_DISTRIBUTIONS+= games EXTRA_DISTRIBUTIONS+= lib32 .endif +MTREE_MAGIC?= mtree 2.0 + distributeworld installworld: installcheck mkdir -p ${INSTALLTMP} progs=$$(for prog in ${ITOOLS}; do \ @@ -703,6 +719,9 @@ distributeworld installworld: installche done); \ cp $$libs $$progs ${INSTALLTMP} cp -R $${PATH_LOCALE:-"/usr/share/locale"} ${INSTALLTMP}/locale +.if defined(NO_ROOT) + echo "#${MTREE_MAGIC}" > ${METALOG} +.endif .if make(distributeworld) .for dist in ${EXTRA_DISTRIBUTIONS} -mkdir ${DESTDIR}/${DISTDIR}/${dist} @@ -712,10 +731,20 @@ distributeworld installworld: installche -p ${DESTDIR}/${DISTDIR}/${dist}/usr >/dev/null mtree -deU -f ${.CURDIR}/etc/mtree/BSD.include.dist \ -p ${DESTDIR}/${DISTDIR}/${dist}/usr/include >/dev/null +.if defined(NO_ROOT) + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.root.dist | \ + sed -e 's#^\./#./${dist}/#' >> ${METALOG} + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.usr.dist | \ + sed -e 's#^\./#./${dist}/usr/#' >> ${METALOG} + ${IMAKEENV} nmtree -C -f ${.CURDIR}/etc/mtree/BSD.include.dist | \ + sed -e 's#^\./#./${dist}/usr/include/#' >> ${METALOG} +.endif .endfor -mkdir ${DESTDIR}/${DISTDIR}/base - ${_+_}cd ${.CURDIR}; ${IMAKE} distrib-dirs \ - LOCAL_MTREE=${LOCAL_MTREE} DESTDIR=${DESTDIR}/${DISTDIR}/base + cd ${.CURDIR}/etc; ${CROSSENV} PATH=${TMPPATH} ${MAKE} \ + METALOG=${METALOG} ${IMAKE_INSTALL} ${IMAKE_MTREE} \ + DISTBASE=/base DESTDIR=${DESTDIR}/${DISTDIR}/base \ + LOCAL_MTREE=${LOCAL_MTREE} distrib-dirs .endif ${_+_}cd ${.CURDIR}; ${IMAKE} re${.TARGET:S/world$//}; \ ${IMAKEENV} rm -rf ${INSTALLTMP} @@ -723,12 +752,30 @@ distributeworld installworld: installche .for dist in ${EXTRA_DISTRIBUTIONS} find ${DESTDIR}/${DISTDIR}/${dist} -empty -delete .endfor +.if defined(NO_ROOT) +.for dist in base ${EXTRA_DISTRIBUTIONS} + @# For each file that exists in this dist, print the corresponding + @# line from the METALOG. This relies on the fact that + @# a line containing only the filename will sort immediatly before + @# the relevant mtree line. + cd ${DESTDIR}/${DISTDIR}; \ + find ./${dist} | sort -u ${METALOG} - | \ + awk 'BEGIN { print "#${MTREE_MAGIC}" } !/ type=/ { file = $$1 } / type=/ { if ($$1 == file) { sub(/^\.\/${dist}\//, "./"); print } }' > \ + ${DESTDIR}/${DISTDIR}/${dist}.meta +.endfor +.endif .endif packageworld: .for dist in base ${EXTRA_DISTRIBUTIONS} +.if defined(NO_ROOT) + ${_+_}cd ${DESTDIR}/${DISTDIR}/${dist}; \ + tar cvJf ${DESTDIR}/${DISTDIR}/${dist}.txz \ + @${DESTDIR}/${DISTDIR}/${dist}.meta +.else ${_+_}cd ${DESTDIR}/${DISTDIR}/${dist}; \ tar cvJf ${DESTDIR}/${DISTDIR}/${dist}.txz . +.endif .endfor # @@ -765,7 +812,7 @@ redistribute: distrib-dirs distribution: cd ${.CURDIR}/etc; ${CROSSENV} PATH=${TMPPATH} ${MAKE} \ - ${IMAKE_INSTALL} ${IMAKE_MTREE} ${.TARGET} + ${IMAKE_INSTALL} ${IMAKE_MTREE} METALOG=${METALOG} ${.TARGET} # # buildkernel and installkernel @@ -1260,7 +1307,12 @@ cross-tools: # hierarchy - ensure that all the needed directories are present # hierarchy hier: +.if defined(NO_ROOT) + cd ${.CURDIR}/etc; ${MAKE} LOCAL_MTREE=${LOCAL_MTREE} \ + -DNO_ROOT METALOG=${METALOG} distrib-dirs +.else cd ${.CURDIR}/etc; ${MAKE} LOCAL_MTREE=${LOCAL_MTREE} distrib-dirs +.endif # # libraries - build all libraries, and install them under ${DESTDIR}. Modified: head/etc/Makefile ============================================================================== --- head/etc/Makefile Tue Jan 22 20:37:31 2013 (r245824) +++ head/etc/Makefile Tue Jan 22 21:10:03 2013 (r245825) @@ -156,6 +156,9 @@ ETCMAIL=Makefile README mailer.conf acce # Special top level files for FreeBSD FREEBSD=COPYRIGHT +# Sanitize DESTDIR +DESTDIR:= ${DESTDIR:C://*:/:g} + afterinstall: .if ${MK_MAN} != "no" ${_+_}cd ${.CURDIR}/../share/man; ${MAKE} makedb @@ -324,6 +327,20 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true +.if defined(NO_ROOT) + @set ${MTREES}; \ + while test $$# -ge 2; do \ + m=${.CURDIR}/$$1; \ + shift; \ + d=$$1; \ + test "$$d" == "/" && d=""; \ + d=${DISTBASE}$$d; \ + shift; \ + ${ECHO} "${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >>" \ + "${METALOG}" ; \ + ${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >> ${METALOG} ; \ + done; true +.endif ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ From owner-svn-src-head@FreeBSD.ORG Tue Jan 22 22:41:13 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2D7A4D60; Tue, 22 Jan 2013 22:41:13 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 20B1EA99; Tue, 22 Jan 2013 22:41:13 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0MMfDCI043442; Tue, 22 Jan 2013 22:41:13 GMT (envelope-from bapt@svn.freebsd.org) Received: (from bapt@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0MMfCEY043440; Tue, 22 Jan 2013 22:41:12 GMT (envelope-from bapt@svn.freebsd.org) Message-Id: <201301222241.r0MMfCEY043440@svn.freebsd.org> From: Baptiste Daroussin Date: Tue, 22 Jan 2013 22:41:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245828 - head/usr.sbin/pkg_install/lib X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2013 22:41:13 -0000 Author: bapt Date: Tue Jan 22 22:41:12 2013 New Revision: 245828 URL: http://svnweb.freebsd.org/changeset/base/245828 Log: Use snprintf instead of strc* functions and add bounds checking when creating pkgngpath Submitted by: sbz, gahr Modified: head/usr.sbin/pkg_install/lib/lib.h head/usr.sbin/pkg_install/lib/pkgng.c Modified: head/usr.sbin/pkg_install/lib/lib.h ============================================================================== --- head/usr.sbin/pkg_install/lib/lib.h Tue Jan 22 22:31:38 2013 (r245827) +++ head/usr.sbin/pkg_install/lib/lib.h Tue Jan 22 22:41:12 2013 (r245828) @@ -99,7 +99,7 @@ * Version of the package tools - increase whenever you make a change * in the code that is not cosmetic only. */ -#define PKG_INSTALL_VERSION 20121109 +#define PKG_INSTALL_VERSION 20130122 #define PKG_WRAPCONF_FNAME "/var/db/pkg_install.conf" #define main(argc, argv) real_main(argc, argv) Modified: head/usr.sbin/pkg_install/lib/pkgng.c ============================================================================== --- head/usr.sbin/pkg_install/lib/pkgng.c Tue Jan 22 22:31:38 2013 (r245827) +++ head/usr.sbin/pkg_install/lib/pkgng.c Tue Jan 22 22:41:12 2013 (r245828) @@ -38,9 +38,10 @@ this system."; void warnpkgng(void) { - char pkgngpath[MAXPATHLEN]; + char pkgngpath[MAXPATHLEN + 1]; char *pkgngdir; char *dontwarn; + int rc; dontwarn = getenv("PKG_OLD_NOWARN"); if (dontwarn != NULL) @@ -48,8 +49,12 @@ void warnpkgng(void) pkgngdir = getenv("PKG_DBDIR"); if (pkgngdir == NULL) pkgngdir = "/var/db/pkg"; - strcpy(pkgngpath, pkgngdir); - strcat(pkgngpath, "/local.sqlite"); + + rc = snprintf(pkgngpath, sizeof(pkgngpath) "%s/local.sqlite", pkgngdir); + if (rc >= sizeof(pkgngpath)) { + warnx("path too long: %s/local.sqlite", pkgngdir); + return; + } if (access(pkgngpath, F_OK) == 0) warnx(message); From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 02:06:21 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 422E3D0A; Wed, 23 Jan 2013 02:06:21 +0000 (UTC) (envelope-from obrien@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 1DA4F1AE; Wed, 23 Jan 2013 02:06:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N26KqN005310; Wed, 23 Jan 2013 02:06:20 GMT (envelope-from obrien@svn.freebsd.org) Received: (from obrien@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N26Kqm005309; Wed, 23 Jan 2013 02:06:20 GMT (envelope-from obrien@svn.freebsd.org) Message-Id: <201301230206.r0N26Kqm005309@svn.freebsd.org> From: "David E. O'Brien" Date: Wed, 23 Jan 2013 02:06:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245832 - head/bin/cp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 02:06:21 -0000 Author: obrien Date: Wed Jan 23 02:06:20 2013 New Revision: 245832 URL: http://svnweb.freebsd.org/changeset/base/245832 Log: Return "failure" as we do for 'cp -i' and a "n" answer. Otherwise with '-v' we print out the file name as if it was copied: /tmp/2gb-card/M0132.CTG not overwritten /mnt/DCIM/CANONMSC/M0132.CTG -> /tmp/2gb-card/M0132.CTG Modified: head/bin/cp/utils.c Modified: head/bin/cp/utils.c ============================================================================== --- head/bin/cp/utils.c Wed Jan 23 00:49:05 2013 (r245831) +++ head/bin/cp/utils.c Wed Jan 23 02:06:20 2013 (r245832) @@ -104,7 +104,7 @@ copy_file(const FTSENT *entp, int dne) if (vflag) printf("%s not overwritten\n", to.p_path); (void)close(from_fd); - return (0); + return (1); } else if (iflag) { (void)fprintf(stderr, "overwrite %s? %s", to.p_path, YESNO); From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 03:49:48 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id EA4B63C7; Wed, 23 Jan 2013 03:49:48 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DD0C37CC; Wed, 23 Jan 2013 03:49:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N3nmEv036601; Wed, 23 Jan 2013 03:49:48 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N3nmaP036600; Wed, 23 Jan 2013 03:49:48 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201301230349.r0N3nmaP036600@svn.freebsd.org> From: Luigi Rizzo Date: Wed, 23 Jan 2013 03:49:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245834 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 03:49:49 -0000 Author: luigi Date: Wed Jan 23 03:49:48 2013 New Revision: 245834 URL: http://svnweb.freebsd.org/changeset/base/245834 Log: leftover from r245579... flags for semi transparent mode and direct forwarding through a VALE switch Modified: head/sys/net/netmap.h Modified: head/sys/net/netmap.h ============================================================================== --- head/sys/net/netmap.h Wed Jan 23 02:29:05 2013 (r245833) +++ head/sys/net/netmap.h Wed Jan 23 03:49:48 2013 (r245834) @@ -32,7 +32,7 @@ /* * $FreeBSD$ - * $Id: netmap.h 10601 2012-02-21 16:40:14Z luigi $ + * $Id: netmap.h 11997 2013-01-17 21:59:12Z luigi $ * * Definitions of constants and the structures used by the netmap * framework, for the part visible to both kernel and userspace. @@ -113,15 +113,28 @@ * In the kernel, buffers do not necessarily need to be contiguous, * and the virtual and physical addresses are derived through * a lookup table. - * To associate a different buffer to a slot, applications must - * write the new index in buf_idx, and set NS_BUF_CHANGED flag to - * make sure that the kernel updates the hardware ring as needed. - * - * Normally the driver is not requested to report the result of - * transmissions (this can dramatically speed up operation). - * However the user may request to report completion by setting - * NS_REPORT. + * + * struct netmap_slot: + * + * buf_idx is the index of the buffer associated to the slot. + * len is the length of the payload + * NS_BUF_CHANGED must be set whenever userspace wants + * to change buf_idx (it might be necessary to + * reprogram the NIC slot) + * NS_REPORT must be set if we want the NIC to generate an interrupt + * when this slot is used. Leaving it to 0 improves + * performance. + * NS_FORWARD if set on a receive ring, and the device is in + * transparent mode, buffers released with the flag set + * will be forwarded to the 'other' side (host stack + * or NIC, respectively) on the next select() or ioctl() + * NS_NO_LEARN on a VALE switch, do not 'learn' the source port for + * this packet. + * NS_PORT_MASK the high 8 bits of the flag, if not zero, indicate the + * destination port for the VALE switch, overriding + * the lookup table. */ + struct netmap_slot { uint32_t buf_idx; /* buffer index */ uint16_t len; /* packet length, to be copied to/from the hw ring */ @@ -130,6 +143,12 @@ struct netmap_slot { #define NS_REPORT 0x0002 /* ask the hardware to report results * e.g. by generating an interrupt */ +#define NS_FORWARD 0x0004 /* pass packet to the other endpoint + * (host stack or device) + */ +#define NS_NO_LEARN 0x0008 +#define NS_PORT_SHIFT 8 +#define NS_PORT_MASK (0xff << NS_PORT_SHIFT) }; /* @@ -186,6 +205,18 @@ struct netmap_slot { * a system call. * * The netmap_kring is only modified by the upper half of the kernel. + * + * FLAGS + * NR_TIMESTAMP updates the 'ts' field on each syscall. This is + * a global timestamp for all packets. + * NR_RX_TSTMP if set, the last 64 byte in each buffer will + * contain a timestamp for the frame supplied by + * the hardware (if supported) + * NR_FORWARD if set, the NS_FORWARD flag in each slot of the + * RX ring is checked, and if set the packet is + * passed to the other side (host stack or device, + * respectively). This permits bpf-like behaviour + * or transparency for selected packets. */ struct netmap_ring { /* @@ -202,6 +233,8 @@ struct netmap_ring { const uint16_t nr_buf_size; uint16_t flags; #define NR_TIMESTAMP 0x0002 /* set timestamp on *sync() */ +#define NR_FORWARD 0x0004 /* enable NS_FORWARD for ring */ +#define NR_RX_TSTMP 0x0008 /* set rx timestamp in slots */ struct timeval ts; /* time of last *sync() */ From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 03:51:48 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 525555CE; Wed, 23 Jan 2013 03:51:48 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4475B7EA; Wed, 23 Jan 2013 03:51:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N3pmSH038464; Wed, 23 Jan 2013 03:51:48 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N3pl7I038461; Wed, 23 Jan 2013 03:51:47 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201301230351.r0N3pl7I038461@svn.freebsd.org> From: Luigi Rizzo Date: Wed, 23 Jan 2013 03:51:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245835 - head/sys/dev/netmap X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 03:51:48 -0000 Author: luigi Date: Wed Jan 23 03:51:47 2013 New Revision: 245835 URL: http://svnweb.freebsd.org/changeset/base/245835 Log: control some debugging messages with dev.netmap.verbose add infrastracture to adapt to changes in number of queues and buffers at runtime Modified: head/sys/dev/netmap/netmap.c head/sys/dev/netmap/netmap_kern.h head/sys/dev/netmap/netmap_mem2.c Modified: head/sys/dev/netmap/netmap.c ============================================================================== --- head/sys/dev/netmap/netmap.c Wed Jan 23 03:49:48 2013 (r245834) +++ head/sys/dev/netmap/netmap.c Wed Jan 23 03:51:47 2013 (r245835) @@ -275,6 +275,51 @@ nm_find_bridge(const char *name) } #endif /* NM_BRIDGE */ + +/* + * Fetch configuration from the device, to cope with dynamic + * reconfigurations after loading the module. + */ +static int +netmap_update_config(struct netmap_adapter *na) +{ + struct ifnet *ifp = na->ifp; + u_int txr, txd, rxr, rxd; + + txr = txd = rxr = rxd = 0; + if (na->nm_config) { + na->nm_config(ifp, &txr, &txd, &rxr, &rxd); + } else { + /* take whatever we had at init time */ + txr = na->num_tx_rings; + txd = na->num_tx_desc; + rxr = na->num_rx_rings; + rxd = na->num_rx_desc; + } + + if (na->num_tx_rings == txr && na->num_tx_desc == txd && + na->num_rx_rings == rxr && na->num_rx_desc == rxd) + return 0; /* nothing changed */ + if (netmap_verbose || na->refcount > 0) { + D("stored config %s: txring %d x %d, rxring %d x %d", + ifp->if_xname, + na->num_tx_rings, na->num_tx_desc, + na->num_rx_rings, na->num_rx_desc); + D("new config %s: txring %d x %d, rxring %d x %d", + ifp->if_xname, txr, txd, rxr, rxd); + } + if (na->refcount == 0) { + D("configuration changed (but fine)"); + na->num_tx_rings = txr; + na->num_tx_desc = txd; + na->num_rx_rings = rxr; + na->num_rx_desc = rxd; + return 0; + } + D("configuration changed while active, this is bad..."); + return 1; +} + /*------------- memory allocator -----------------*/ #ifdef NETMAP_MEM2 #include "netmap_mem2.c" @@ -351,7 +396,8 @@ netmap_dtor_locked(void *data) if (na->refcount <= 0) { /* last instance */ u_int i, j, lim; - D("deleting last netmap instance for %s", ifp->if_xname); + if (netmap_verbose) + D("deleting last instance for %s", ifp->if_xname); /* * there is a race here with *_netmap_task() and * netmap_poll(), which don't run under NETMAP_REG_LOCK. @@ -482,7 +528,8 @@ static int netmap_dev_pager_ctor(void *handle, vm_ooffset_t size, vm_prot_t prot, vm_ooffset_t foff, struct ucred *cred, u_short *color) { - D("first mmap for %p", handle); + if (netmap_verbose) + D("first mmap for %p", handle); return saved_cdev_pager_ops.cdev_pg_ctor(handle, size, prot, foff, cred, color); } @@ -491,7 +538,7 @@ static void netmap_dev_pager_dtor(void *handle) { saved_cdev_pager_ops.cdev_pg_dtor(handle); - D("ready to release memory for %p", handle); + ND("ready to release memory for %p", handle); } @@ -507,7 +554,7 @@ netmap_mmap_single(struct cdev *cdev, vm { vm_object_t obj; - D("cdev %p foff %jd size %jd objp %p prot %d", cdev, + ND("cdev %p foff %jd size %jd objp %p prot %d", cdev, (intmax_t )*foff, (intmax_t )objsize, objp, prot); obj = vm_pager_allocate(OBJT_DEVICE, cdev, objsize, prot, *foff, curthread->td_ucred); @@ -515,7 +562,7 @@ netmap_mmap_single(struct cdev *cdev, vm if (obj == NULL) return EINVAL; if (saved_cdev_pager_ops.cdev_pg_fault == NULL) { - D("initialize cdev_pager_ops"); + ND("initialize cdev_pager_ops"); saved_cdev_pager_ops = *(obj->un_pager.devp.ops); netmap_cdev_pager_ops.cdev_pg_fault = saved_cdev_pager_ops.cdev_pg_fault; @@ -572,7 +619,9 @@ netmap_mmap(__unused struct cdev *dev, static int netmap_close(struct cdev *dev, int fflag, int devtype, struct thread *td) { - D("dev %p fflag 0x%x devtype %d td %p", dev, fflag, devtype, td); + if (netmap_verbose) + D("dev %p fflag 0x%x devtype %d td %p", + dev, fflag, devtype, td); return 0; } @@ -877,6 +926,7 @@ netmap_set_ringid(struct netmap_priv_d * priv->np_txpoll = (ringid & NETMAP_NO_TX_POLL) ? 0 : 1; if (need_lock) na->nm_lock(ifp, NETMAP_CORE_UNLOCK, 0); + if (netmap_verbose) { if (ringid & NETMAP_SW_RING) D("ringid %s set to SW RING", ifp->if_xname); else if (ringid & NETMAP_HW_RING) @@ -884,6 +934,7 @@ netmap_set_ringid(struct netmap_priv_d * priv->np_qfirst); else D("ringid %s set to all %d HW RINGS", ifp->if_xname, lim); + } return 0; } @@ -965,6 +1016,7 @@ netmap_ioctl(struct cdev *dev, u_long cm if (error) break; na = NA(ifp); /* retrieve netmap_adapter */ + netmap_update_config(na); nmr->nr_rx_rings = na->num_rx_rings; nmr->nr_tx_rings = na->num_tx_rings; nmr->nr_rx_slots = na->num_rx_desc; @@ -1014,6 +1066,8 @@ netmap_ioctl(struct cdev *dev, u_long cm break; } + /* ring configuration may have changed, fetch from the card */ + netmap_update_config(na); priv->np_ifp = ifp; /* store the reference */ error = netmap_set_ringid(priv, nmr->nr_ringid); if (error) @@ -1444,46 +1498,28 @@ netmap_lock_wrapper(struct ifnet *dev, i * setups. */ int -netmap_attach(struct netmap_adapter *na, int num_queues) +netmap_attach(struct netmap_adapter *arg, int num_queues) { - int n, size; - void *buf; - struct ifnet *ifp = na->ifp; + struct netmap_adapter *na = NULL; + struct ifnet *ifp = arg ? arg->ifp : NULL; - if (ifp == NULL) { - D("ifp not set, giving up"); - return EINVAL; - } - /* clear other fields ? */ - na->refcount = 0; + if (arg == NULL || ifp == NULL) + goto fail; + na = malloc(sizeof(*na), M_DEVBUF, M_NOWAIT | M_ZERO); + if (na == NULL) + goto fail; + WNA(ifp) = na; + *na = *arg; /* copy everything, trust the driver to not pass junk */ + NETMAP_SET_CAPABLE(ifp); if (na->num_tx_rings == 0) na->num_tx_rings = num_queues; na->num_rx_rings = num_queues; - /* on each direction we have N+1 resources - * 0..n-1 are the hardware rings - * n is the ring attached to the stack. - */ - n = na->num_rx_rings + na->num_tx_rings + 2; - size = sizeof(*na) + n * sizeof(struct netmap_kring); - - buf = malloc(size, M_DEVBUF, M_NOWAIT | M_ZERO); - if (buf) { - WNA(ifp) = buf; - na->tx_rings = (void *)((char *)buf + sizeof(*na)); - na->rx_rings = na->tx_rings + na->num_tx_rings + 1; - bcopy(na, buf, sizeof(*na)); - NETMAP_SET_CAPABLE(ifp); - - na = buf; - /* Core lock initialized here. Others are initialized after - * netmap_if_new. - */ - mtx_init(&na->core_lock, "netmap core lock", MTX_NETWORK_LOCK, - MTX_DEF); - if (na->nm_lock == NULL) { - ND("using default locks for %s", ifp->if_xname); - na->nm_lock = netmap_lock_wrapper; - } + na->refcount = na->na_single = na->na_multi = 0; + /* Core lock initialized here, others after netmap_if_new. */ + mtx_init(&na->core_lock, "netmap core lock", MTX_NETWORK_LOCK, MTX_DEF); + if (na->nm_lock == NULL) { + ND("using default locks for %s", ifp->if_xname); + na->nm_lock = netmap_lock_wrapper; } #ifdef linux if (ifp->netdev_ops) { @@ -1493,9 +1529,12 @@ netmap_attach(struct netmap_adapter *na, } na->nm_ndo.ndo_start_xmit = linux_netmap_start; #endif - D("%s for %s", buf ? "ok" : "failed", ifp->if_xname); + D("success for %s", ifp->if_xname); + return 0; - return (buf ? 0 : ENOMEM); +fail: + D("fail, arg %p ifp %p na %p", arg, ifp, na); + return (na ? EINVAL : ENOMEM); } @@ -1513,6 +1552,10 @@ netmap_detach(struct ifnet *ifp) mtx_destroy(&na->core_lock); + if (na->tx_rings) { /* XXX should not happen */ + D("freeing leftover tx_rings"); + free(na->tx_rings, M_DEVBUF); + } bzero(na, sizeof(*na)); WNA(ifp) = NULL; free(na, M_DEVBUF); Modified: head/sys/dev/netmap/netmap_kern.h ============================================================================== --- head/sys/dev/netmap/netmap_kern.h Wed Jan 23 03:49:48 2013 (r245834) +++ head/sys/dev/netmap/netmap_kern.h Wed Jan 23 03:51:47 2013 (r245835) @@ -203,6 +203,9 @@ struct netmap_adapter { void (*nm_lock)(struct ifnet *, int what, u_int ringid); int (*nm_txsync)(struct ifnet *, u_int ring, int lock); int (*nm_rxsync)(struct ifnet *, u_int ring, int lock); + /* return configuration information */ + int (*nm_config)(struct ifnet *, u_int *txr, u_int *txd, + u_int *rxr, u_int *rxd); int bdg_port; #ifdef linux Modified: head/sys/dev/netmap/netmap_mem2.c ============================================================================== --- head/sys/dev/netmap/netmap_mem2.c Wed Jan 23 03:49:48 2013 (r245834) +++ head/sys/dev/netmap/netmap_mem2.c Wed Jan 23 03:51:47 2013 (r245835) @@ -388,7 +388,7 @@ netmap_obj_free_va(struct netmap_obj_poo netmap_obj_free(p, j); return; } - ND("address %p is not contained inside any cluster (%s)", + D("address %p is not contained inside any cluster (%s)", vaddr, p->name); } @@ -559,8 +559,9 @@ netmap_config_obj_allocator(struct netma i = (clustsize & (PAGE_SIZE - 1)); if (i) clustsize += PAGE_SIZE - i; - D("objsize %d clustsize %d objects %d", - objsize, clustsize, clustentries); + if (netmap_verbose) + D("objsize %d clustsize %d objects %d", + objsize, clustsize, clustentries); /* * The number of clusters is n = ceil(objtotal/clustentries) @@ -649,9 +650,10 @@ netmap_finalize_obj_allocator(struct net } } p->bitmap[0] = ~3; /* objs 0 and 1 is always busy */ - D("Pre-allocated %d clusters (%d/%dKB) for '%s'", - p->_numclusters, p->_clustsize >> 10, - p->_memtotal >> 10, p->name); + if (netmap_verbose) + D("Pre-allocated %d clusters (%d/%dKB) for '%s'", + p->_numclusters, p->_clustsize >> 10, + p->_memtotal >> 10, p->name); return 0; @@ -721,7 +723,7 @@ netmap_memory_finalize(void) nm_mem.refcount++; if (nm_mem.refcount > 1) { - D("busy (refcount %d)", nm_mem.refcount); + ND("busy (refcount %d)", nm_mem.refcount); goto out; } @@ -796,6 +798,8 @@ static void netmap_free_rings(struct netmap_adapter *na) { int i; + if (!na->tx_rings) + return; for (i = 0; i < na->num_tx_rings + 1; i++) { netmap_ring_free(na->tx_rings[i].ring); na->tx_rings[i].ring = NULL; @@ -804,22 +808,32 @@ netmap_free_rings(struct netmap_adapter netmap_ring_free(na->rx_rings[i].ring); na->rx_rings[i].ring = NULL; } + free(na->tx_rings, M_DEVBUF); + na->tx_rings = na->rx_rings = NULL; } /* call with NMA_LOCK held */ +/* + * Allocate the per-fd structure netmap_if. + * If this is the first instance, also allocate the krings, rings etc. + */ static void * netmap_if_new(const char *ifname, struct netmap_adapter *na) { struct netmap_if *nifp; struct netmap_ring *ring; ssize_t base; /* handy for relative offsets between rings and nifp */ - u_int i, len, ndesc; - u_int ntx = na->num_tx_rings + 1; /* shorthand, include stack ring */ - u_int nrx = na->num_rx_rings + 1; /* shorthand, include stack ring */ + u_int i, len, ndesc, ntx, nrx; struct netmap_kring *kring; + if (netmap_update_config(na)) { + /* configuration mismatch, report and fail */ + return NULL; + } + ntx = na->num_tx_rings + 1; /* shorthand, include stack ring */ + nrx = na->num_rx_rings + 1; /* shorthand, include stack ring */ /* * the descriptor is followed inline by an array of offsets * to the tx and rx rings in the shared memory region. @@ -840,6 +854,14 @@ netmap_if_new(const char *ifname, struct goto final; } + len = (ntx + nrx) * sizeof(struct netmap_kring); + na->tx_rings = malloc(len, M_DEVBUF, M_NOWAIT | M_ZERO); + if (na->tx_rings == NULL) { + D("Cannot allocate krings for %s", ifname); + goto cleanup; + } + na->rx_rings = na->tx_rings + ntx; + /* * First instance, allocate netmap rings and buffers for this card * The rings are contiguous, but have variable size. @@ -947,5 +969,6 @@ static void netmap_memory_deref(void) { nm_mem.refcount--; - D("refcount = %d", nm_mem.refcount); + if (netmap_verbose) + D("refcount = %d", nm_mem.refcount); } From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 05:37:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 88C2DC5F; Wed, 23 Jan 2013 05:37:46 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 61366A05; Wed, 23 Jan 2013 05:37:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N5bkfH068769; Wed, 23 Jan 2013 05:37:46 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N5bkmP068768; Wed, 23 Jan 2013 05:37:46 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201301230537.r0N5bkmP068768@svn.freebsd.org> From: Luigi Rizzo Date: Wed, 23 Jan 2013 05:37:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245836 - head/sys/dev/netmap X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 05:37:46 -0000 Author: luigi Date: Wed Jan 23 05:37:45 2013 New Revision: 245836 URL: http://svnweb.freebsd.org/changeset/base/245836 Log: Add support for transparent mode while in netmap. By setting dev.netmap.fwd=1 (or enabling the feature with a per-ring flag), packets are forwarded between the NIC and the host stack unless the netmap client clears the NS_FORWARD flag on the individual descriptors. This feature greatly simplifies applications where some traffic (think of ARP, control traffic, ssh sessions...) must be processed by the host stack, whereas the bulk is handled by the netmap process which simply (un)marks packets that should not be forwarded. The default is chosen so that now a netmap receiver operates in a mode very similar to bpf. Of course there is no free lunch: traffic to/from the host stack still operates at OS speed (or less, as there is one extra copy in one direction). HOWEVER, since traffic goes to the user process before being reinjected, and reinjection occurs in a user context, you get some form of livelock protection for free. Modified: head/sys/dev/netmap/netmap.c Modified: head/sys/dev/netmap/netmap.c ============================================================================== --- head/sys/dev/netmap/netmap.c Wed Jan 23 03:51:47 2013 (r245835) +++ head/sys/dev/netmap/netmap.c Wed Jan 23 05:37:45 2013 (r245836) @@ -120,10 +120,12 @@ SYSCTL_INT(_dev_netmap, OID_AUTO, no_pen int netmap_drop = 0; /* debugging */ int netmap_flags = 0; /* debug flags */ +int netmap_fwd = 0; /* force transparent mode */ int netmap_copy = 0; /* debugging, copy content */ SYSCTL_INT(_dev_netmap, OID_AUTO, drop, CTLFLAG_RW, &netmap_drop, 0 , ""); SYSCTL_INT(_dev_netmap, OID_AUTO, flags, CTLFLAG_RW, &netmap_flags, 0 , ""); +SYSCTL_INT(_dev_netmap, OID_AUTO, fwd, CTLFLAG_RW, &netmap_fwd, 0 , ""); SYSCTL_INT(_dev_netmap, OID_AUTO, copy, CTLFLAG_RW, &netmap_copy, 0 , ""); #ifdef NM_BRIDGE /* support for netmap bridge */ @@ -647,63 +649,170 @@ netmap_open(struct cdev *dev, int oflags /* * Handlers for synchronization of the queues from/to the host. - * - * netmap_sync_to_host() passes packets up. We are called from a - * system call in user process context, and the only contention - * can be among multiple user threads erroneously calling - * this routine concurrently. In principle we should not even - * need to lock. + * Netmap has two operating modes: + * - in the default mode, the rings connected to the host stack are + * just another ring pair managed by userspace; + * - in transparent mode (XXX to be defined) incoming packets + * (from the host or the NIC) are marked as NS_FORWARD upon + * arrival, and the user application has a chance to reset the + * flag for packets that should be dropped. + * On the RXSYNC or poll(), packets in RX rings between + * kring->nr_kcur and ring->cur with NS_FORWARD still set are moved + * to the other side. + * The transfer NIC --> host is relatively easy, just encapsulate + * into mbufs and we are done. The host --> NIC side is slightly + * harder because there might not be room in the tx ring so it + * might take a while before releasing the buffer. + */ + +/* + * pass a chain of buffers to the host stack as coming from 'dst' */ static void -netmap_sync_to_host(struct netmap_adapter *na) +netmap_send_up(struct ifnet *dst, struct mbuf *head) { - struct netmap_kring *kring = &na->tx_rings[na->num_tx_rings]; - struct netmap_ring *ring = kring->ring; - struct mbuf *head = NULL, *tail = NULL, *m; - u_int k, n, lim = kring->nkr_num_slots - 1; + struct mbuf *m; - k = ring->cur; - if (k > lim) { - netmap_ring_reinit(kring); - return; + /* send packets up, outside the lock */ + while ((m = head) != NULL) { + head = head->m_nextpkt; + m->m_nextpkt = NULL; + if (netmap_verbose & NM_VERB_HOST) + D("sending up pkt %p size %d", m, MBUF_LEN(m)); + NM_SEND_UP(dst, m); } - // na->nm_lock(na->ifp, NETMAP_CORE_LOCK, 0); +} - /* Take packets from hwcur to cur and pass them up. +struct mbq { + struct mbuf *head; + struct mbuf *tail; + int count; +}; + +/* + * put a copy of the buffers marked NS_FORWARD into an mbuf chain. + * Run from hwcur to cur - reserved + */ +static void +netmap_grab_packets(struct netmap_kring *kring, struct mbq *q, int force) +{ + /* Take packets from hwcur to cur-reserved and pass them up. * In case of no buffers we give up. At the end of the loop, * the queue is drained in all cases. + * XXX handle reserved */ + int k = kring->ring->cur - kring->ring->reserved; + u_int n, lim = kring->nkr_num_slots - 1; + struct mbuf *m, *tail = q->tail; + + if (k < 0) + k = k + kring->nkr_num_slots; for (n = kring->nr_hwcur; n != k;) { - struct netmap_slot *slot = &ring->slot[n]; + struct netmap_slot *slot = &kring->ring->slot[n]; n = (n == lim) ? 0 : n + 1; + if ((slot->flags & NS_FORWARD) == 0 && !force) + continue; if (slot->len < 14 || slot->len > NETMAP_BUF_SIZE) { D("bad pkt at %d len %d", n, slot->len); continue; } - m = m_devget(NMB(slot), slot->len, 0, na->ifp, NULL); + slot->flags &= ~NS_FORWARD; // XXX needed ? + m = m_devget(NMB(slot), slot->len, 0, kring->na->ifp, NULL); if (m == NULL) break; if (tail) tail->m_nextpkt = m; else - head = m; + q->head = m; tail = m; + q->count++; m->m_nextpkt = NULL; } + q->tail = tail; +} + +/* + * called under main lock to send packets from the host to the NIC + * The host ring has packets from nr_hwcur to (cur - reserved) + * to be sent down. We scan the tx rings, which have just been + * flushed so nr_hwcur == cur. Pushing packets down means + * increment cur and decrement avail. + * XXX to be verified + */ +static void +netmap_sw_to_nic(struct netmap_adapter *na) +{ + struct netmap_kring *kring = &na->rx_rings[na->num_rx_rings]; + struct netmap_kring *k1 = &na->tx_rings[0]; + int i, howmany, src_lim, dst_lim; + + howmany = kring->nr_hwavail; /* XXX otherwise cur - reserved - nr_hwcur */ + + src_lim = kring->nkr_num_slots; + for (i = 0; howmany > 0 && i < na->num_tx_rings; i++, k1++) { + ND("%d packets left to ring %d (space %d)", howmany, i, k1->nr_hwavail); + dst_lim = k1->nkr_num_slots; + while (howmany > 0 && k1->ring->avail > 0) { + struct netmap_slot *src, *dst, tmp; + src = &kring->ring->slot[kring->nr_hwcur]; + dst = &k1->ring->slot[k1->ring->cur]; + tmp = *src; + src->buf_idx = dst->buf_idx; + src->flags = NS_BUF_CHANGED; + + dst->buf_idx = tmp.buf_idx; + dst->len = tmp.len; + dst->flags = NS_BUF_CHANGED; + ND("out len %d buf %d from %d to %d", + dst->len, dst->buf_idx, + kring->nr_hwcur, k1->ring->cur); + + if (++kring->nr_hwcur >= src_lim) + kring->nr_hwcur = 0; + howmany--; + kring->nr_hwavail--; + if (++k1->ring->cur >= dst_lim) + k1->ring->cur = 0; + k1->ring->avail--; + } + kring->ring->cur = kring->nr_hwcur; // XXX + k1++; + } +} + +/* + * netmap_sync_to_host() passes packets up. We are called from a + * system call in user process context, and the only contention + * can be among multiple user threads erroneously calling + * this routine concurrently. + */ +static void +netmap_sync_to_host(struct netmap_adapter *na) +{ + struct netmap_kring *kring = &na->tx_rings[na->num_tx_rings]; + struct netmap_ring *ring = kring->ring; + u_int k, lim = kring->nkr_num_slots - 1; + struct mbq q = { NULL, NULL }; + + k = ring->cur; + if (k > lim) { + netmap_ring_reinit(kring); + return; + } + // na->nm_lock(na->ifp, NETMAP_CORE_LOCK, 0); + + /* Take packets from hwcur to cur and pass them up. + * In case of no buffers we give up. At the end of the loop, + * the queue is drained in all cases. + */ + netmap_grab_packets(kring, &q, 1); kring->nr_hwcur = k; kring->nr_hwavail = ring->avail = lim; // na->nm_lock(na->ifp, NETMAP_CORE_UNLOCK, 0); - /* send packets up, outside the lock */ - while ((m = head) != NULL) { - head = head->m_nextpkt; - m->m_nextpkt = NULL; - if (netmap_verbose & NM_VERB_HOST) - D("sending up pkt %p size %d", m, MBUF_LEN(m)); - NM_SEND_UP(na->ifp, m); - } + netmap_send_up(na->ifp, q.head); } /* @@ -1236,7 +1345,8 @@ netmap_poll(struct cdev *dev, int events struct ifnet *ifp; struct netmap_kring *kring; u_int core_lock, i, check_all, want_tx, want_rx, revents = 0; - u_int lim_tx, lim_rx; + u_int lim_tx, lim_rx, host_forwarded = 0; + struct mbq q = { NULL, NULL, 0 }; enum {NO_CL, NEED_CL, LOCKED_CL }; /* see below */ void *pwait = dev; /* linux compatibility */ @@ -1284,6 +1394,17 @@ netmap_poll(struct cdev *dev, int events return (revents); } + /* if we are in transparent mode, check also the host rx ring */ + kring = &na->rx_rings[lim_rx]; + if ( (priv->np_qlast == NETMAP_HW_RING) // XXX check_all + && want_rx + && (netmap_fwd || kring->ring->flags & NR_FORWARD) ) { + if (kring->ring->avail == 0) + netmap_sync_from_host(na, td, dev); + if (kring->ring->avail > 0) + revents |= want_rx; + } + /* * check_all is set if the card has more than one queue and * the client is polling all of them. If true, we sleep on @@ -1359,6 +1480,7 @@ netmap_poll(struct cdev *dev, int events * to avoid that the tx rings stall). */ if (priv->np_txpoll || want_tx) { +flush_tx: for (i = priv->np_qfirst; i < lim_tx; i++) { kring = &na->tx_rings[i]; /* @@ -1411,6 +1533,11 @@ netmap_poll(struct cdev *dev, int events } if (na->separate_locks) na->nm_lock(ifp, NETMAP_RX_LOCK, i); + if (netmap_fwd ||kring->ring->flags & NR_FORWARD) { + ND(10, "forwarding some buffers up %d to %d", + kring->nr_hwcur, kring->ring->cur); + netmap_grab_packets(kring, &q, netmap_fwd); + } if (na->nm_rxsync(ifp, i, 0 /* no lock */)) revents |= POLLERR; @@ -1433,8 +1560,28 @@ netmap_poll(struct cdev *dev, int events if (want_rx) selrecord(td, &na->rx_si); } + + /* forward host to the netmap ring */ + kring = &na->rx_rings[lim_rx]; + if (kring->nr_hwavail > 0) + ND("host rx %d has %d packets", lim_rx, kring->nr_hwavail); + if ( (priv->np_qlast == NETMAP_HW_RING) // XXX check_all + && (netmap_fwd || kring->ring->flags & NR_FORWARD) + && kring->nr_hwavail > 0 && !host_forwarded) { + if (core_lock == NEED_CL) { + na->nm_lock(ifp, NETMAP_CORE_LOCK, 0); + core_lock = LOCKED_CL; + } + netmap_sw_to_nic(na); + host_forwarded = 1; /* prevent another pass */ + want_rx = 0; + goto flush_tx; + } + if (core_lock == LOCKED_CL) na->nm_lock(ifp, NETMAP_CORE_UNLOCK, 0); + if (q.head) + netmap_send_up(na->ifp, q.head); return (revents); } @@ -1586,7 +1733,8 @@ netmap_start(struct ifnet *ifp, struct m goto done; /* no space */ } if (len > NETMAP_BUF_SIZE) { - D("drop packet size %d > %d", len, NETMAP_BUF_SIZE); + D("%s from_host, drop packet size %d > %d", ifp->if_xname, + len, NETMAP_BUF_SIZE); goto done; /* too long for us */ } @@ -1597,6 +1745,7 @@ netmap_start(struct ifnet *ifp, struct m slot = &kring->ring->slot[i]; m_copydata(m, 0, len, NMB(slot)); slot->len = len; + slot->flags = kring->nkr_slot_flags; kring->nr_hwavail++; if (netmap_verbose & NM_VERB_HOST) D("wake up host ring %s %d", na->ifp->if_xname, na->num_rx_rings); From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 07:22:34 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 165D2D1F; Wed, 23 Jan 2013 07:22:34 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 08F8FE2B; Wed, 23 Jan 2013 07:22:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N7MXZo000710; Wed, 23 Jan 2013 07:22:33 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N7MXbM000709; Wed, 23 Jan 2013 07:22:33 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201301230722.r0N7MXbM000709@svn.freebsd.org> From: Jason Evans Date: Wed, 23 Jan 2013 07:22:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245837 - head/usr.sbin/pkg_install/lib X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 07:22:34 -0000 Author: jasone Date: Wed Jan 23 07:22:33 2013 New Revision: 245837 URL: http://svnweb.freebsd.org/changeset/base/245837 Log: Fix compilation errors. Modified: head/usr.sbin/pkg_install/lib/pkgng.c Modified: head/usr.sbin/pkg_install/lib/pkgng.c ============================================================================== --- head/usr.sbin/pkg_install/lib/pkgng.c Wed Jan 23 05:37:45 2013 (r245836) +++ head/usr.sbin/pkg_install/lib/pkgng.c Wed Jan 23 07:22:33 2013 (r245837) @@ -50,8 +50,8 @@ void warnpkgng(void) if (pkgngdir == NULL) pkgngdir = "/var/db/pkg"; - rc = snprintf(pkgngpath, sizeof(pkgngpath) "%s/local.sqlite", pkgngdir); - if (rc >= sizeof(pkgngpath)) { + rc = snprintf(pkgngpath, sizeof(pkgngpath), "%s/local.sqlite", pkgngdir); + if ((size_t)rc >= sizeof(pkgngpath)) { warnx("path too long: %s/local.sqlite", pkgngdir); return; } From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 07:27:38 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EEF10FA7; Wed, 23 Jan 2013 07:27:38 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CA63EE6D; Wed, 23 Jan 2013 07:27:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N7RclA001367; Wed, 23 Jan 2013 07:27:38 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N7Rcec001366; Wed, 23 Jan 2013 07:27:38 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201301230727.r0N7Rcec001366@svn.freebsd.org> From: Andrew Turner Date: Wed, 23 Jan 2013 07:27:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245838 - head/sys/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 07:27:39 -0000 Author: andrew Date: Wed Jan 23 07:27:38 2013 New Revision: 245838 URL: http://svnweb.freebsd.org/changeset/base/245838 Log: Don't build the kernel with Thumb interworking as we don't support Thumb. Modified: head/sys/conf/Makefile.arm Modified: head/sys/conf/Makefile.arm ============================================================================== --- head/sys/conf/Makefile.arm Wed Jan 23 07:22:33 2013 (r245837) +++ head/sys/conf/Makefile.arm Wed Jan 23 07:27:38 2013 (r245838) @@ -39,6 +39,8 @@ SYSTEM_DEP:= ${SYSTEM_DEP:$S/conf/ldscri STRIP_FLAGS = -S .endif +CFLAGS += -mno-thumb-interwork + .if empty(DDB_ENABLED) CFLAGS += -mno-apcs-frame .elif defined(WITH_ARM_EABI) From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 08:54:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 192ED30D; Wed, 23 Jan 2013 08:54:36 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E7DB6212; Wed, 23 Jan 2013 08:54:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N8sZYV027487; Wed, 23 Jan 2013 08:54:35 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N8sYuf027478; Wed, 23 Jan 2013 08:54:34 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301230854.r0N8sYuf027478@svn.freebsd.org> From: David Chisnall Date: Wed, 23 Jan 2013 08:54:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245839 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 08:54:36 -0000 Author: theraven Date: Wed Jan 23 08:54:34 2013 New Revision: 245839 URL: http://svnweb.freebsd.org/changeset/base/245839 Log: Explicitly include headers that are implicitly included by libstdc++. Fixes building dtc with libc++. Modified: head/usr.bin/dtc/checking.cc head/usr.bin/dtc/dtb.cc head/usr.bin/dtc/dtc.cc head/usr.bin/dtc/fdt.cc head/usr.bin/dtc/input_buffer.cc head/usr.bin/dtc/string.cc Modified: head/usr.bin/dtc/checking.cc ============================================================================== --- head/usr.bin/dtc/checking.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/checking.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -31,6 +31,7 @@ */ #include "checking.hh" +#include namespace dtc { Modified: head/usr.bin/dtc/dtb.cc ============================================================================== --- head/usr.bin/dtc/dtb.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/dtb.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -31,7 +31,11 @@ */ #include "dtb.hh" +#include #include +#include +#include + namespace dtc { Modified: head/usr.bin/dtc/dtc.cc ============================================================================== --- head/usr.bin/dtc/dtc.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/dtc.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -31,10 +31,14 @@ */ #include -#include -#include #include #include +#include +#include +#include +#include +#include + #include "fdt.hh" #include "checking.hh" Modified: head/usr.bin/dtc/fdt.cc ============================================================================== --- head/usr.bin/dtc/fdt.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/fdt.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -33,9 +33,13 @@ #include "fdt.hh" #include -#include +#include #include +#include #include +#include +#include +#include #include "dtb.hh" namespace dtc Modified: head/usr.bin/dtc/input_buffer.cc ============================================================================== --- head/usr.bin/dtc/input_buffer.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/input_buffer.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -31,8 +31,13 @@ */ #include "input_buffer.hh" -#include +#include +#include #include +#include +#include +#include + #include #include Modified: head/usr.bin/dtc/string.cc ============================================================================== --- head/usr.bin/dtc/string.cc Wed Jan 23 07:27:38 2013 (r245838) +++ head/usr.bin/dtc/string.cc Wed Jan 23 08:54:34 2013 (r245839) @@ -31,6 +31,8 @@ */ #include "string.hh" +#include +#include namespace { From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 09:18:19 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A7CBC827; Wed, 23 Jan 2013 09:18:19 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9992C2FF; Wed, 23 Jan 2013 09:18:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0N9IJe1034305; Wed, 23 Jan 2013 09:18:19 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0N9IJex034303; Wed, 23 Jan 2013 09:18:19 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201301230918.r0N9IJex034303@svn.freebsd.org> From: Andrew Turner Date: Wed, 23 Jan 2013 09:18:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245840 - head/sys/libkern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 09:18:19 -0000 Author: andrew Date: Wed Jan 23 09:18:18 2013 New Revision: 245840 URL: http://svnweb.freebsd.org/changeset/base/245840 Log: Add __aeabi_ulcmp to allow building of the LINT kernel. Modified: head/sys/libkern/quad.h head/sys/libkern/ucmpdi2.c Modified: head/sys/libkern/quad.h ============================================================================== --- head/sys/libkern/quad.h Wed Jan 23 08:54:34 2013 (r245839) +++ head/sys/libkern/quad.h Wed Jan 23 09:18:18 2013 (r245840) @@ -110,4 +110,9 @@ u_quad_t __udivdi3(u_quad_t a, u_quad_t u_quad_t __umoddi3(u_quad_t a, u_quad_t b); int __ucmpdi2(u_quad_t a, u_quad_t b); +/* ARM EABI support functions. */ +#ifdef __ARM_EABI__ +int __aeabi_ulcmp(unsigned long long, unsigned long long); +#endif + #endif /* !_LIBKERN_QUAD_H_ */ Modified: head/sys/libkern/ucmpdi2.c ============================================================================== --- head/sys/libkern/ucmpdi2.c Wed Jan 23 08:54:34 2013 (r245839) +++ head/sys/libkern/ucmpdi2.c Wed Jan 23 09:18:18 2013 (r245840) @@ -51,3 +51,15 @@ __ucmpdi2(a, b) return (aa.ul[H] < bb.ul[H] ? 0 : aa.ul[H] > bb.ul[H] ? 2 : aa.ul[L] < bb.ul[L] ? 0 : aa.ul[L] > bb.ul[L] ? 2 : 1); } + +#ifdef __ARM_EABI__ +/* + * Return -1, 0 or 1 as a <, =, > b respectively. + */ +int +__aeabi_ulcmp(unsigned long long a, unsigned long long b) +{ + return __ucmpdi2(a, b) - 1; +} +#endif + From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 10:50:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5E894C5A; Wed, 23 Jan 2013 10:50:53 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 214FA932; Wed, 23 Jan 2013 10:50:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NAoqZj062443; Wed, 23 Jan 2013 10:50:52 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NAoqdH062442; Wed, 23 Jan 2013 10:50:52 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301231050.r0NAoqdH062442@svn.freebsd.org> From: Gleb Smirnoff Date: Wed, 23 Jan 2013 10:50:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245841 - head/lib/libc/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 10:50:53 -0000 Author: glebius Date: Wed Jan 23 10:50:52 2013 New Revision: 245841 URL: http://svnweb.freebsd.org/changeset/base/245841 Log: posix_fadvise(2) first appeared in FreeBSD 9.1 Modified: head/lib/libc/sys/posix_fadvise.2 Modified: head/lib/libc/sys/posix_fadvise.2 ============================================================================== --- head/lib/libc/sys/posix_fadvise.2 Wed Jan 23 09:18:18 2013 (r245840) +++ head/lib/libc/sys/posix_fadvise.2 Wed Jan 23 10:50:52 2013 (r245841) @@ -134,4 +134,4 @@ interface conforms to The .Fn posix_fadvise system call first appeared in -.Fx 10.0 . +.Fx 9.1 . From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 11:31:12 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2DB0980E; Wed, 23 Jan 2013 11:31:12 +0000 (UTC) (envelope-from baptiste.daroussin@gmail.com) Received: from mail-wi0-f175.google.com (mail-wi0-f175.google.com [209.85.212.175]) by mx1.freebsd.org (Postfix) with ESMTP id 3A53EABE; Wed, 23 Jan 2013 11:31:10 +0000 (UTC) Received: by mail-wi0-f175.google.com with SMTP id hm11so598584wib.8 for ; Wed, 23 Jan 2013 03:31:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=aUNv9EXSKPh8fnJaHnXaVGEBHL6Vd33dykcO7pIpZ+k=; b=gSEFNJ+LyoxQ90NScIlegT58SJ3fHnEYFLGEQOcGMfMQbZ2rtH5jCb2+t5ujwbXfFB xSg1KgIGGu1WmL7dJ5ZIE2ErJOFqoW4Ho5JyDqO58KCSpkj5JFMnlREi9cUrK1G5o2xM I6ZEUPjo4H48hkx97WDmrD9osCeMWFcu8Vy3gOBaGItbfEQ46dpBAVZsueK8Ao6uTmq4 HV6XVNAKx+qNtrNpkRuD5p4zaxInkhq10S+M0K7Yq3wdEVZz+gBU7kAYNonnVnfxB1fL 5tfWLuvbKYNGe0kDq8XZLKIH/D2bC3D6YA7JziO/JCQTtctoacAG2YjJFrNBWhUivS+x VzlQ== X-Received: by 10.194.235.100 with SMTP id ul4mr1947365wjc.7.1358940664476; Wed, 23 Jan 2013 03:31:04 -0800 (PST) Received: from ithaqua.etoilebsd.net (ithaqua.etoilebsd.net. [37.59.37.188]) by mx.google.com with ESMTPS id t17sm29060396wiv.6.2013.01.23.03.31.02 (version=TLSv1 cipher=RC4-SHA bits=128/128); Wed, 23 Jan 2013 03:31:02 -0800 (PST) Sender: Baptiste Daroussin Date: Wed, 23 Jan 2013 12:31:00 +0100 From: Baptiste Daroussin To: Jason Evans Subject: Re: svn commit: r245837 - head/usr.sbin/pkg_install/lib Message-ID: <20130123113100.GI27275@ithaqua.etoilebsd.net> References: <201301230722.r0N7MXbM000709@svn.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="BWWlCdgt6QLN7tv3" Content-Disposition: inline In-Reply-To: <201301230722.r0N7MXbM000709@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 11:31:12 -0000 --BWWlCdgt6QLN7tv3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jan 23, 2013 at 07:22:33AM +0000, Jason Evans wrote: > Author: jasone > Date: Wed Jan 23 07:22:33 2013 > New Revision: 245837 > URL: http://svnweb.freebsd.org/changeset/base/245837 >=20 > Log: > Fix compilation errors. >=20 > Modified: > head/usr.sbin/pkg_install/lib/pkgng.c >=20 > Modified: head/usr.sbin/pkg_install/lib/pkgng.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/usr.sbin/pkg_install/lib/pkgng.c Wed Jan 23 05:37:45 2013 (r2458= 36) > +++ head/usr.sbin/pkg_install/lib/pkgng.c Wed Jan 23 07:22:33 2013 (r2458= 37) > @@ -50,8 +50,8 @@ void warnpkgng(void) > if (pkgngdir =3D=3D NULL) > pkgngdir =3D "/var/db/pkg"; > =20 > - rc =3D snprintf(pkgngpath, sizeof(pkgngpath) "%s/local.sqlite", pkgngdi= r); > - if (rc >=3D sizeof(pkgngpath)) { > + rc =3D snprintf(pkgngpath, sizeof(pkgngpath), "%s/local.sqlite", pkgngd= ir); > + if ((size_t)rc >=3D sizeof(pkgngpath)) { > warnx("path too long: %s/local.sqlite", pkgngdir); > return; > } > _______________________________________________ > svn-src-all@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" thanks and sorry about that regards, Bapt --BWWlCdgt6QLN7tv3 Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlD/yfQACgkQ8kTtMUmk6ExePACgpb1MLkbJFXZ58qtyESr3ZdQN fhIAoKrHvqXfEs9peres/H90yhAL7J8I =zI6k -----END PGP SIGNATURE----- --BWWlCdgt6QLN7tv3-- From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 11:53:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7BAD7C53; Wed, 23 Jan 2013 11:53:26 +0000 (UTC) (envelope-from uqs@FreeBSD.org) Received: from acme.spoerlein.net (acme.spoerlein.net [IPv6:2a01:4f8:131:23c2::1]) by mx1.freebsd.org (Postfix) with ESMTP id 12441BF9; Wed, 23 Jan 2013 11:53:25 +0000 (UTC) Received: from localhost (acme.spoerlein.net [IPv6:2a01:4f8:131:23c2::1]) by acme.spoerlein.net (8.14.6/8.14.6) with ESMTP id r0NBrOxr056778 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Wed, 23 Jan 2013 12:53:24 +0100 (CET) (envelope-from uqs@FreeBSD.org) Date: Wed, 23 Jan 2013 12:53:24 +0100 From: Ulrich =?utf-8?B?U3DDtnJsZWlu?= To: Nathan Whitehorn Subject: Re: svn commit: r245700 - head/usr.sbin/bsdinstall/partedit Message-ID: <20130123115324.GA38645@acme.spoerlein.net> Mail-Followup-To: Ulrich =?utf-8?B?U3DDtnJsZWlu?= , Nathan Whitehorn , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201301202225.r0KMPxYi041939@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201301202225.r0KMPxYi041939@svn.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 11:53:26 -0000 On Sun, 2013-01-20 at 22:25:59 +0000, Nathan Whitehorn wrote: > Author: nwhitehorn > Date: Sun Jan 20 22:25:58 2013 > New Revision: 245700 > URL: http://svnweb.freebsd.org/changeset/base/245700 > > Log: > Add a simple scripted partitioner. Documentation and more scripting support > will come soon. This lets the install process have a line like: > > bsdinstall scriptedpart 'ada0 GPT {1.5G freebsd-ufs /, 10G freebsd-swap, > auto freebsd-ufs /usr}' > > to set up a system with a 1.5GB /, some swap space, and a /usr using the > rest of ada0. What will be the alignment/offset for these? (and also for the fully automated case?) We should make sure the first partition starts at 1MB all the time, unless the user points the gun at his feet ... Thanks Uli From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 13:20:03 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1075628D; Wed, 23 Jan 2013 13:20:03 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from adsum.doit.wisc.edu (adsum.doit.wisc.edu [144.92.197.210]) by mx1.freebsd.org (Postfix) with ESMTP id E1ABF10A; Wed, 23 Jan 2013 13:20:02 +0000 (UTC) MIME-version: 1.0 Content-transfer-encoding: 8BIT Content-type: text/plain; charset=ISO-8859-1 Received: from wanderer.tachypleus.net (adsl-76-208-68-53.dsl.mdsnwi.sbcglobal.net [76.208.68.53]) by smtpauth1.wiscmail.wisc.edu (Sun Java(tm) System Messaging Server 7u2-7.05 32bit (built Jul 30 2009)) with ESMTPSA id <0MH20095VYDAJ830@smtpauth1.wiscmail.wisc.edu>; Wed, 23 Jan 2013 07:20:02 -0600 (CST) X-Spam-PmxInfo: Server=avs-1, Version=5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2013.1.23.130924, SenderIP=76.208.68.53 X-Spam-Report: AuthenticatedSender=yes, SenderIP=76.208.68.53 X-Wisc-Sender: whitehorn@wisc.edu Message-id: <50FFE37E.3030503@freebsd.org> Date: Wed, 23 Jan 2013 07:19:58 -0600 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130112 Thunderbird/17.0.2 To: =?ISO-8859-1?Q?Ulrich_Sp=F6rlein?= , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r245700 - head/usr.sbin/bsdinstall/partedit References: <201301202225.r0KMPxYi041939@svn.freebsd.org> <20130123115324.GA38645@acme.spoerlein.net> In-reply-to: <20130123115324.GA38645@acme.spoerlein.net> X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 13:20:03 -0000 On 01/23/13 05:53, Ulrich Spörlein wrote: > On Sun, 2013-01-20 at 22:25:59 +0000, Nathan Whitehorn wrote: >> Author: nwhitehorn >> Date: Sun Jan 20 22:25:58 2013 >> New Revision: 245700 >> URL: http://svnweb.freebsd.org/changeset/base/245700 >> >> Log: >> Add a simple scripted partitioner. Documentation and more scripting support >> will come soon. This lets the install process have a line like: >> >> bsdinstall scriptedpart 'ada0 GPT {1.5G freebsd-ufs /, 10G freebsd-swap, >> auto freebsd-ufs /usr}' >> >> to set up a system with a 1.5GB /, some swap space, and a /usr using the >> rest of ada0. > > What will be the alignment/offset for these? (and also for the fully > automated case?) > > We should make sure the first partition starts at 1MB all the time, > unless the user points the gun at his feet ... > > Thanks > Uli > The partition alignment always follows the stripesize parameter of the backing GEOM. If that gives wrong alignment (which it never or nearly never seems to, in practice), it needs to be fixed there so that file systems can also plan appropriately. -Nathan From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 14:29:30 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id F3484ACE; Wed, 23 Jan 2013 14:29:29 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DBB9B6D3; Wed, 23 Jan 2013 14:29:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NETThv028088; Wed, 23 Jan 2013 14:29:29 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NETTOC028087; Wed, 23 Jan 2013 14:29:29 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201301231429.r0NETTOC028087@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Wed, 23 Jan 2013 14:29:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245844 - head/sys/fs/ext2fs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 14:29:30 -0000 Author: pfg Date: Wed Jan 23 14:29:29 2013 New Revision: 245844 URL: http://svnweb.freebsd.org/changeset/base/245844 Log: ext2fs: fix a check for negative block numbers. The previous change accidentally left the substraction we were trying to avoid in case that i_blocks could become negative. Reported by: bde MFC after: 4 days Modified: head/sys/fs/ext2fs/ext2_inode.c Modified: head/sys/fs/ext2fs/ext2_inode.c ============================================================================== --- head/sys/fs/ext2fs/ext2_inode.c Wed Jan 23 14:14:13 2013 (r245843) +++ head/sys/fs/ext2fs/ext2_inode.c Wed Jan 23 14:29:29 2013 (r245844) @@ -341,10 +341,9 @@ done: * Put back the real size. */ oip->i_size = length; - oip->i_blocks -= blocksreleased; if (oip->i_blocks > blocksreleased) oip->i_blocks -= blocksreleased; - else /* sanity */ + else /* sanity */ oip->i_blocks = 0; oip->i_flag |= IN_CHANGE; vnode_pager_setsize(ovp, length); From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 14:37:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CF97D7C; Wed, 23 Jan 2013 14:37:05 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C1205774; Wed, 23 Jan 2013 14:37:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NEb5nR030895; Wed, 23 Jan 2013 14:37:05 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NEb5IR030894; Wed, 23 Jan 2013 14:37:05 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301231437.r0NEb5IR030894@svn.freebsd.org> From: John Baldwin Date: Wed, 23 Jan 2013 14:37:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245845 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 14:37:05 -0000 Author: jhb Date: Wed Jan 23 14:37:05 2013 New Revision: 245845 URL: http://svnweb.freebsd.org/changeset/base/245845 Log: Fix a typo. Modified: head/sys/kern/subr_bus.c Modified: head/sys/kern/subr_bus.c ============================================================================== --- head/sys/kern/subr_bus.c Wed Jan 23 14:29:29 2013 (r245844) +++ head/sys/kern/subr_bus.c Wed Jan 23 14:37:05 2013 (r245845) @@ -3318,7 +3318,7 @@ resource_list_release(struct resource_li /** * @brief Fully release a reserved resource * - * Fully releases a resouce reserved via resource_list_reserve(). + * Fully releases a resource reserved via resource_list_reserve(). * * @param rl the resource list which was allocated from * @param bus the parent device of @p child From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 18:34:22 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2701A51A; Wed, 23 Jan 2013 18:34:22 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 011AF74D; Wed, 23 Jan 2013 18:34:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NIYLxb006408; Wed, 23 Jan 2013 18:34:21 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NIYLnp006407; Wed, 23 Jan 2013 18:34:21 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301231834.r0NIYLnp006407@svn.freebsd.org> From: John Baldwin Date: Wed, 23 Jan 2013 18:34:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245848 - head/sys/boot/i386/libi386 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 18:34:22 -0000 Author: jhb Date: Wed Jan 23 18:34:21 2013 New Revision: 245848 URL: http://svnweb.freebsd.org/changeset/base/245848 Log: Always update the hw.uart.console hint anytime a change is made to the comconsole setup. Previously the hint would be set when if you set a custom port, but it would not be updated if you later set a custom speed. Also, leave the hw.uart.console hint mutable so it can be overridden or unset by the user if needed. Reviewed by: kib (earlier version) MFC after: 1 week Modified: head/sys/boot/i386/libi386/comconsole.c Modified: head/sys/boot/i386/libi386/comconsole.c ============================================================================== --- head/sys/boot/i386/libi386/comconsole.c Wed Jan 23 18:19:50 2013 (r245847) +++ head/sys/boot/i386/libi386/comconsole.c Wed Jan 23 18:34:21 2013 (r245848) @@ -50,7 +50,6 @@ static int comc_init(int arg); static void comc_putchar(int c); static int comc_getchar(void); static int comc_getspeed(void); -static void set_hw_console_hint(void); static int comc_ischar(void); static int comc_parseint(const char *string); static uint32_t comc_parse_pcidev(const char *string); @@ -202,27 +201,14 @@ comc_port_set(struct env_var *ev, int fl } if ((comconsole.c_flags & (C_ACTIVEIN | C_ACTIVEOUT)) != 0 && - comc_port != port) { + comc_port != port) comc_setup(comc_curspeed, port); - set_hw_console_hint(); - } env_setenv(ev->ev_name, flags | EV_NOHOOK, value, NULL, NULL); return (CMD_OK); } -static void -set_hw_console_hint(void) -{ - char intbuf[64]; - - unsetenv("hw.uart.console"); - sprintf(intbuf, "io:%d,br:%d", comc_port, comc_curspeed); - env_setenv("hw.uart.console", EV_VOLATILE, intbuf, - env_noset, env_nounset); -} - /* * Input: bus:dev:func[:bar]. If bar is not specified, it is 0x10. * Output: bar[24:16] bus[15:8] dev[7:3] func[2:0] @@ -288,7 +274,6 @@ comc_pcidev_handle(uint32_t locator) comc_port_set, env_nounset); comc_setup(comc_curspeed, port); - set_hw_console_hint(); comc_locator = locator; return (CMD_OK); @@ -318,8 +303,10 @@ static void comc_setup(int speed, int port) { static int TRY_COUNT = 1000000; + char intbuf[64]; int tries; + unsetenv("hw.uart.console"); comc_curspeed = speed; comc_port = port; @@ -334,9 +321,11 @@ comc_setup(int speed, int port) inb(comc_port + com_data); while (inb(comc_port + com_lsr) & LSR_RXRDY && ++tries < TRY_COUNT); - if (tries < TRY_COUNT) + if (tries < TRY_COUNT) { comconsole.c_flags |= (C_PRESENTIN | C_PRESENTOUT); - else + sprintf(intbuf, "io:%d,br:%d", comc_port, comc_curspeed); + env_setenv("hw.uart.console", EV_VOLATILE, intbuf, NULL, NULL); + } else comconsole.c_flags &= ~(C_PRESENTIN | C_PRESENTOUT); } From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 21:44:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0A1B1445; Wed, 23 Jan 2013 21:44:50 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D9B0918E; Wed, 23 Jan 2013 21:44:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NLinAZ064545; Wed, 23 Jan 2013 21:44:49 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NLingS064542; Wed, 23 Jan 2013 21:44:49 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301232144.r0NLingS064542@svn.freebsd.org> From: John Baldwin Date: Wed, 23 Jan 2013 21:44:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245849 - in head/sys: amd64/linux32 compat/linux i386/linux X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 21:44:50 -0000 Author: jhb Date: Wed Jan 23 21:44:48 2013 New Revision: 245849 URL: http://svnweb.freebsd.org/changeset/base/245849 Log: Don't assume that all Linux TCP-level socket options are identical to FreeBSD TCP-level socket options (only the first two are). Instead, using a mapping function and fail unsupported options as we do for other socket option levels. MFC after: 2 weeks Modified: head/sys/amd64/linux32/linux.h head/sys/compat/linux/linux_socket.c head/sys/i386/linux/linux.h Modified: head/sys/amd64/linux32/linux.h ============================================================================== --- head/sys/amd64/linux32/linux.h Wed Jan 23 18:34:21 2013 (r245848) +++ head/sys/amd64/linux32/linux.h Wed Jan 23 21:44:48 2013 (r245849) @@ -725,6 +725,13 @@ union l_semun { #define LINUX_IP_ADD_MEMBERSHIP 35 #define LINUX_IP_DROP_MEMBERSHIP 36 +#define LINUX_TCP_NODELAY 1 +#define LINUX_TCP_MAXSEG 2 +#define LINUX_TCP_KEEPIDLE 4 +#define LINUX_TCP_KEEPINTVL 5 +#define LINUX_TCP_KEEPCNT 6 +#define LINUX_TCP_MD5SIG 14 + struct l_sockaddr { l_ushort sa_family; char sa_data[14]; Modified: head/sys/compat/linux/linux_socket.c ============================================================================== --- head/sys/compat/linux/linux_socket.c Wed Jan 23 18:34:21 2013 (r245848) +++ head/sys/compat/linux/linux_socket.c Wed Jan 23 21:44:48 2013 (r245849) @@ -56,6 +56,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #ifdef INET6 #include #include @@ -326,6 +327,27 @@ linux_to_bsd_so_sockopt(int opt) } static int +linux_to_bsd_tcp_sockopt(int opt) +{ + + switch (opt) { + case LINUX_TCP_NODELAY: + return (TCP_NODELAY); + case LINUX_TCP_MAXSEG: + return (TCP_MAXSEG); + case LINUX_TCP_KEEPIDLE: + return (TCP_KEEPIDLE); + case LINUX_TCP_KEEPINTVL: + return (TCP_KEEPINTVL); + case LINUX_TCP_KEEPCNT: + return (TCP_KEEPCNT); + case LINUX_TCP_MD5SIG: + return (TCP_MD5SIG); + } + return (-1); +} + +static int linux_to_bsd_msg_flags(int flags) { int ret_flags = 0; @@ -1496,8 +1518,7 @@ linux_setsockopt(struct thread *td, stru name = linux_to_bsd_ip_sockopt(args->optname); break; case IPPROTO_TCP: - /* Linux TCP option values match BSD's */ - name = args->optname; + name = linux_to_bsd_tcp_sockopt(args->optname); break; default: name = -1; @@ -1591,8 +1612,7 @@ linux_getsockopt(struct thread *td, stru name = linux_to_bsd_ip_sockopt(args->optname); break; case IPPROTO_TCP: - /* Linux TCP option values match BSD's */ - name = args->optname; + name = linux_to_bsd_tcp_sockopt(args->optname); break; default: name = -1; Modified: head/sys/i386/linux/linux.h ============================================================================== --- head/sys/i386/linux/linux.h Wed Jan 23 18:34:21 2013 (r245848) +++ head/sys/i386/linux/linux.h Wed Jan 23 21:44:48 2013 (r245849) @@ -701,6 +701,13 @@ union l_semun { #define LINUX_IP_ADD_MEMBERSHIP 35 #define LINUX_IP_DROP_MEMBERSHIP 36 +#define LINUX_TCP_NODELAY 1 +#define LINUX_TCP_MAXSEG 2 +#define LINUX_TCP_KEEPIDLE 4 +#define LINUX_TCP_KEEPINTVL 5 +#define LINUX_TCP_KEEPCNT 6 +#define LINUX_TCP_MD5SIG 14 + struct l_sockaddr { l_ushort sa_family; char sa_data[14]; From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 22:52:21 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7B43BD82; Wed, 23 Jan 2013 22:52:21 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5430A6E7; Wed, 23 Jan 2013 22:52:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NMqLkp085110; Wed, 23 Jan 2013 22:52:21 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NMqLxh085107; Wed, 23 Jan 2013 22:52:21 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201301232252.r0NMqLxh085107@svn.freebsd.org> From: Marius Strobl Date: Wed, 23 Jan 2013 22:52:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245850 - in head/sys/sparc64: include sparc64 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 22:52:21 -0000 Author: marius Date: Wed Jan 23 22:52:20 2013 New Revision: 245850 URL: http://svnweb.freebsd.org/changeset/base/245850 Log: Revert the part of r239864 which removed obtaining the SMP mutex around reading registers from other CPUs. As it turns out, the hardware doesn't really like concurrent IPI'ing causing adverse effects. Also the thought deadlock when using this spin lock here and the targeted CPU(s) are also holding or in case of nested locks can't actually happen. This is due to the fact that on sparc64, spinlock_enter() only raises the PIL but doesn't disable interrupts completely. Thus direct cross calls as used for the register reading (and all other MD IPI needs) still will be executed by the targeted CPU(s) in that case. MFC after: 3 days Modified: head/sys/sparc64/include/smp.h head/sys/sparc64/sparc64/tick.c Modified: head/sys/sparc64/include/smp.h ============================================================================== --- head/sys/sparc64/include/smp.h Wed Jan 23 21:44:48 2013 (r245849) +++ head/sys/sparc64/include/smp.h Wed Jan 23 22:52:20 2013 (r245850) @@ -42,6 +42,7 @@ #include #include #include +#include #include #include @@ -202,6 +203,7 @@ ipi_rd(u_int cpu, void *func, u_long *va return (NULL); sched_pin(); ira = &ipi_rd_args; + mtx_lock_spin(&smp_ipi_mtx); CPU_SETOF(cpu, &ira->ira_mask); ira->ira_val = val; cpu_ipi_single(cpu, 0, (u_long)func, (u_long)ira); @@ -298,18 +300,6 @@ ipi_wait(void *cookie) } } -static __inline void -ipi_wait_unlocked(void *cookie) -{ - volatile cpuset_t *mask; - - if ((mask = cookie) != NULL) { - while (!CPU_EMPTY(mask)) - ; - sched_unpin(); - } -} - #endif /* _MACHINE_PMAP_H_ && _SYS_MUTEX_H_ */ #endif /* !LOCORE */ @@ -368,12 +358,6 @@ ipi_wait(void *cookie __unused) } static __inline void -ipi_wait_unlocked(void *cookie __unused) -{ - -} - -static __inline void tl_ipi_cheetah_dcache_page_inval(void) { Modified: head/sys/sparc64/sparc64/tick.c ============================================================================== --- head/sys/sparc64/sparc64/tick.c Wed Jan 23 21:44:48 2013 (r245849) +++ head/sys/sparc64/sparc64/tick.c Wed Jan 23 22:52:20 2013 (r245850) @@ -334,7 +334,7 @@ stick_get_timecount_mp(struct timecounte if (curcpu == 0) stick = rdstick(); else - ipi_wait_unlocked(ipi_rd(0, tl_ipi_stick_rd, &stick)); + ipi_wait(ipi_rd(0, tl_ipi_stick_rd, &stick)); sched_unpin(); return (stick); } @@ -348,7 +348,7 @@ tick_get_timecount_mp(struct timecounter if (curcpu == 0) tick = rd(tick); else - ipi_wait_unlocked(ipi_rd(0, tl_ipi_tick_rd, &tick)); + ipi_wait(ipi_rd(0, tl_ipi_tick_rd, &tick)); sched_unpin(); return (tick); } From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 23:49:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A0C3CF16; Wed, 23 Jan 2013 23:49:36 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 7B2BB911; Wed, 23 Jan 2013 23:49:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NNnasG001046; Wed, 23 Jan 2013 23:49:36 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NNnaoa001045; Wed, 23 Jan 2013 23:49:36 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301232349.r0NNnaoa001045@svn.freebsd.org> From: Brooks Davis Date: Wed, 23 Jan 2013 23:49:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245852 - head/kerberos5/lib/libkrb5 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 23:49:36 -0000 Author: brooks Date: Wed Jan 23 23:49:35 2013 New Revision: 245852 URL: http://svnweb.freebsd.org/changeset/base/245852 Log: Only try to install one link at each path. Don't install verify_krb5_conf.8. It is installed in kerberos5/usr.bin/verify_krb5_conf. Modified: head/kerberos5/lib/libkrb5/Makefile Modified: head/kerberos5/lib/libkrb5/Makefile ============================================================================== --- head/kerberos5/lib/libkrb5/Makefile Wed Jan 23 22:56:03 2013 (r245851) +++ head/kerberos5/lib/libkrb5/Makefile Wed Jan 23 23:49:35 2013 (r245852) @@ -82,8 +82,7 @@ MAN= krb5.3 \ krb5_timeofday.3 \ krb5_v4compat.3 \ krb5_verify_init_creds.3 \ - krb5_verify_user.3 \ - verify_krb5_conf.8 + krb5_verify_user.3 MAN+= krb5.conf.5 MAN+= kerberos.8 @@ -107,7 +106,6 @@ MLINKS= krb5.3 krb5_add_et_list.3 \ krb5.3 krb5_data_realloc.3 \ krb5.3 krb5_data_zero.3 \ krb5.3 krb5_free_config_files.3 \ - krb5.3 krb5_free_context.3 \ krb5.3 krb5_free_cred_contents.3 \ krb5.3 krb5_free_creds.3 \ krb5.3 krb5_free_data.3 \ @@ -123,7 +121,6 @@ MLINKS= krb5.3 krb5_add_et_list.3 \ krb5.3 krb5_get_use_admin_kdc.3 \ krb5.3 krb5_init_ets.3 \ krb5.3 krb5_kerberos_enctypes.3 \ - krb5.3 krb5_krbhst_get_addrinfo.3 \ krb5.3 krb5_prepend_config_files_default.3 \ krb5.3 krb5_set_config_files.3 \ krb5.3 krb5_set_default_in_tkt_etypes.3 \ @@ -195,7 +192,6 @@ MLINKS= krb5.3 krb5_add_et_list.3 \ krb5_auth_context.3 krb5_auth_getcksumtype.3 \ krb5_auth_context.3 krb5_auth_getkeytype.3 \ krb5_auth_context.3 krb5_auth_getlocalseqnumber.3 \ - krb5_auth_context.3 krb5_auth_getremoteseqnumber.3 \ krb5_auth_context.3 krb5_auth_setcksumtype.3 \ krb5_auth_context.3 krb5_auth_setkeytype.3 \ krb5_auth_context.3 krb5_auth_setlocalseqnumber.3 \ @@ -383,11 +379,8 @@ MLINKS= krb5.3 krb5_add_et_list.3 \ krb5_principal.3 krb5_free_principal.3 \ krb5_principal.3 krb5_get_default_principal.3 \ krb5_principal.3 krb5_make_principal.3 \ - krb5_principal.3 krb5_parse_name.3 \ krb5_principal.3 krb5_parse_name_flags.3 \ krb5_principal.3 krb5_parse_nametype.3 \ - krb5_principal.3 krb5_princ_realm.3 \ - krb5_principal.3 krb5_princ_set_realm.3 \ krb5_principal.3 krb5_principal_compare.3 \ krb5_principal.3 krb5_principal_compare_any_realm.3 \ krb5_principal.3 krb5_principal_get_comp_string.3 \ @@ -486,7 +479,6 @@ MLINKS= krb5.3 krb5_add_et_list.3 \ krb5_support.3 krb5_config_vget_time_default.3 \ krb5_support.3 krb5_expand_hostname.3 \ krb5_support.3 krb5_expand_hostname_realms.3 \ - krb5_support.3 krb5_free_host_realm.3 \ krb5_support.3 krb5_kuserok.3 \ krb5_support.3 krb5_plugin_register.3 \ krb5_ticket.3 krb5_ticket_get_flags.3 \ From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 23:51:45 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 3F0A313B; Wed, 23 Jan 2013 23:51:45 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 14D3F931; Wed, 23 Jan 2013 23:51:45 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NNpigg002957; Wed, 23 Jan 2013 23:51:44 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NNpibe002956; Wed, 23 Jan 2013 23:51:44 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301232351.r0NNpibe002956@svn.freebsd.org> From: Brooks Davis Date: Wed, 23 Jan 2013 23:51:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245853 - head/usr.sbin X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 23:51:45 -0000 Author: brooks Date: Wed Jan 23 23:51:44 2013 New Revision: 245853 URL: http://svnweb.freebsd.org/changeset/base/245853 Log: manctl is conditionally added to SUBDIRS later on. Don't unconditionally include in the main list. Modified: head/usr.sbin/Makefile Modified: head/usr.sbin/Makefile ============================================================================== --- head/usr.sbin/Makefile Wed Jan 23 23:49:35 2013 (r245852) +++ head/usr.sbin/Makefile Wed Jan 23 23:51:44 2013 (r245853) @@ -39,7 +39,6 @@ SUBDIR= adduser \ kldxref \ mailwrapper \ makefs \ - manctl \ memcontrol \ mergemaster \ mfiutil \ From owner-svn-src-head@FreeBSD.ORG Wed Jan 23 23:53:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C3A3C2B7; Wed, 23 Jan 2013 23:53:26 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B4E45943; Wed, 23 Jan 2013 23:53:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0NNrQG2003207; Wed, 23 Jan 2013 23:53:26 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0NNrQbv003206; Wed, 23 Jan 2013 23:53:26 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301232353.r0NNrQbv003206@svn.freebsd.org> From: Brooks Davis Date: Wed, 23 Jan 2013 23:53:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245854 - head/lib/libarchive X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jan 2013 23:53:26 -0000 Author: brooks Date: Wed Jan 23 23:53:26 2013 New Revision: 245854 URL: http://svnweb.freebsd.org/changeset/base/245854 Log: Remove several MLINKS that were listed twice. Modified: head/lib/libarchive/Makefile Modified: head/lib/libarchive/Makefile ============================================================================== --- head/lib/libarchive/Makefile Wed Jan 23 23:51:44 2013 (r245853) +++ head/lib/libarchive/Makefile Wed Jan 23 23:53:26 2013 (r245854) @@ -231,9 +231,6 @@ MLINKS+= archive_entry_perms.3 archive_e MLINKS+= archive_entry_perms.3 archive_entry_set_gid.3 MLINKS+= archive_entry_perms.3 archive_entry_set_gname.3 MLINKS+= archive_entry_perms.3 archive_entry_perm.3 -MLINKS+= archive_entry_perms.3 archive_entry_set_fflags.3 -MLINKS+= archive_entry_perms.3 archive_entry_set_gid.3 -MLINKS+= archive_entry_perms.3 archive_entry_set_gname.3 MLINKS+= archive_entry_perms.3 archive_entry_set_perm.3 MLINKS+= archive_entry_perms.3 archive_entry_set_uid.3 MLINKS+= archive_entry_perms.3 archive_entry_set_uname.3 @@ -264,10 +261,6 @@ MLINKS+= archive_entry_stat.3 archive_en MLINKS+= archive_entry_stat.3 archive_entry_set_ino.3 MLINKS+= archive_entry_stat.3 archive_entry_set_ino64.3 MLINKS+= archive_entry_stat.3 archive_entry_set_mode.3 -MLINKS+= archive_entry_stat.3 archive_entry_set_rdev.3 -MLINKS+= archive_entry_stat.3 archive_entry_set_rdevmajor.3 -MLINKS+= archive_entry_stat.3 archive_entry_set_rdevminor.3 -MLINKS+= archive_entry_stat.3 archive_entry_set_size.3 MLINKS+= archive_entry_stat.3 archive_entry_set_nlink.3 MLINKS+= archive_entry_stat.3 archive_entry_set_rdev.3 MLINKS+= archive_entry_stat.3 archive_entry_set_rdevmajor.3 From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 02:25:44 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7D06B792; Thu, 24 Jan 2013 02:25:44 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6B479EC8; Thu, 24 Jan 2013 02:25:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O2Piv7049469; Thu, 24 Jan 2013 02:25:44 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O2PiuH049468; Thu, 24 Jan 2013 02:25:44 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201301240225.r0O2PiuH049468@svn.freebsd.org> From: Pyun YongHyeon Date: Thu, 24 Jan 2013 02:25:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245867 - head/sys/dev/bge X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 02:25:44 -0000 Author: yongari Date: Thu Jan 24 02:25:43 2013 New Revision: 245867 URL: http://svnweb.freebsd.org/changeset/base/245867 Log: For 57765 class controllers, set low watermark max receive frames to 1. Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Thu Jan 24 02:20:25 2013 (r245866) +++ head/sys/dev/bge/if_bge.c Thu Jan 24 02:25:43 2013 (r245867) @@ -5427,7 +5427,7 @@ bge_init_locked(struct bge_softc *sc) * this number of frames, it will drop subsequent incoming * frames until the MBUF High Watermark is reached. */ - if (sc->bge_asicrev == BGE_ASICREV_BCM57765) + if (BGE_IS_57765_PLUS(sc)) CSR_WRITE_4(sc, BGE_MAX_RX_FRAME_LOWAT, 1); else CSR_WRITE_4(sc, BGE_MAX_RX_FRAME_LOWAT, 2); From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 03:08:39 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6B93E3FA; Thu, 24 Jan 2013 03:08:39 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5B30417F; Thu, 24 Jan 2013 03:08:39 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O38de8062484; Thu, 24 Jan 2013 03:08:39 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O38b1o062469; Thu, 24 Jan 2013 03:08:37 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201301240308.r0O38b1o062469@svn.freebsd.org> From: Jason Evans Date: Thu, 24 Jan 2013 03:08:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245868 - in head/contrib/jemalloc: . doc include/jemalloc include/jemalloc/internal src X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 03:08:39 -0000 Author: jasone Date: Thu Jan 24 03:08:37 2013 New Revision: 245868 URL: http://svnweb.freebsd.org/changeset/base/245868 Log: Import jemalloc 3.3.0. This reduces zeroed memory validation overhead for non-MALLOC_PRODUCTION builds. Modified: head/contrib/jemalloc/COPYING head/contrib/jemalloc/ChangeLog head/contrib/jemalloc/FREEBSD-diffs head/contrib/jemalloc/VERSION head/contrib/jemalloc/doc/jemalloc.3 head/contrib/jemalloc/include/jemalloc/internal/arena.h head/contrib/jemalloc/include/jemalloc/internal/ckh.h head/contrib/jemalloc/include/jemalloc/internal/hash.h head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h head/contrib/jemalloc/include/jemalloc/internal/tcache.h head/contrib/jemalloc/include/jemalloc/jemalloc.h head/contrib/jemalloc/include/jemalloc/jemalloc_defs.h head/contrib/jemalloc/src/arena.c head/contrib/jemalloc/src/chunk.c head/contrib/jemalloc/src/chunk_dss.c head/contrib/jemalloc/src/ckh.c head/contrib/jemalloc/src/ctl.c head/contrib/jemalloc/src/jemalloc.c head/contrib/jemalloc/src/prof.c head/contrib/jemalloc/src/tcache.c Modified: head/contrib/jemalloc/COPYING ============================================================================== --- head/contrib/jemalloc/COPYING Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/COPYING Thu Jan 24 03:08:37 2013 (r245868) @@ -1,10 +1,10 @@ Unless otherwise specified, files in the jemalloc source distribution are subject to the following license: -------------------------------------------------------------------------------- -Copyright (C) 2002-2012 Jason Evans . +Copyright (C) 2002-2013 Jason Evans . All rights reserved. Copyright (C) 2007-2012 Mozilla Foundation. All rights reserved. -Copyright (C) 2009-2012 Facebook, Inc. All rights reserved. +Copyright (C) 2009-2013 Facebook, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Modified: head/contrib/jemalloc/ChangeLog ============================================================================== --- head/contrib/jemalloc/ChangeLog Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/ChangeLog Thu Jan 24 03:08:37 2013 (r245868) @@ -6,6 +6,23 @@ found in the git revision history: http://www.canonware.com/cgi-bin/gitweb.cgi?p=jemalloc.git git://canonware.com/jemalloc.git +* 3.3.0 (January 23, 2013) + + This version includes a few minor performance improvements in addition to the + listed new features and bug fixes. + + New features: + - Add clipping support to lg_chunk option processing. + - Add the --enable-ivsalloc option. + - Add the --without-export option. + - Add the --disable-zone-allocator option. + + Bug fixes: + - Fix "arenas.extend" mallctl to output the number of arenas. + - Fix chunk_recycyle() to unconditionally inform Valgrind that returned memory + is undefined. + - Fix build break on FreeBSD related to alloca.h. + * 3.2.0 (November 9, 2012) In addition to a couple of bug fixes, this version modifies page run Modified: head/contrib/jemalloc/FREEBSD-diffs ============================================================================== --- head/contrib/jemalloc/FREEBSD-diffs Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/FREEBSD-diffs Thu Jan 24 03:08:37 2013 (r245868) @@ -1,5 +1,5 @@ diff --git a/doc/jemalloc.xml.in b/doc/jemalloc.xml.in -index 54b8747..91c4a4e 100644 +index 0930580..d45fa3d 100644 --- a/doc/jemalloc.xml.in +++ b/doc/jemalloc.xml.in @@ -51,12 +51,23 @@ @@ -27,7 +27,7 @@ index 54b8747..91c4a4e 100644 Standard API -@@ -2170,4 +2181,16 @@ malloc_conf = "lg_chunk:24";]]> +@@ -2173,4 +2184,16 @@ malloc_conf = "lg_chunk:24";]]> The posix_memalign function conforms to IEEE Std 1003.1-2001 (“POSIX.1”). @@ -45,7 +45,7 @@ index 54b8747..91c4a4e 100644 + diff --git a/include/jemalloc/internal/jemalloc_internal.h.in b/include/jemalloc/internal/jemalloc_internal.h.in -index 475821a..73306ac 100644 +index c606c12..0d46d9d 100644 --- a/include/jemalloc/internal/jemalloc_internal.h.in +++ b/include/jemalloc/internal/jemalloc_internal.h.in @@ -1,5 +1,8 @@ @@ -97,10 +97,10 @@ index de44e14..564d604 100644 bool malloc_mutex_init(malloc_mutex_t *mutex); diff --git a/include/jemalloc/internal/private_namespace.h b/include/jemalloc/internal/private_namespace.h -index 06241cd..7b19906 100644 +index 903fb4d..d6638df 100644 --- a/include/jemalloc/internal/private_namespace.h +++ b/include/jemalloc/internal/private_namespace.h -@@ -204,7 +204,6 @@ +@@ -216,7 +216,6 @@ #define iralloc JEMALLOC_N(iralloc) #define irallocx JEMALLOC_N(irallocx) #define isalloc JEMALLOC_N(isalloc) @@ -203,7 +203,7 @@ index 0000000..9c97a13 +#define pthread_mutex_lock _pthread_mutex_lock +#define pthread_mutex_unlock _pthread_mutex_unlock diff --git a/src/jemalloc.c b/src/jemalloc.c -index 8a667b6..aaf5012 100644 +index c117685..665d98f 100644 --- a/src/jemalloc.c +++ b/src/jemalloc.c @@ -8,6 +8,10 @@ malloc_tsd_data(, arenas, arena_t *, NULL) @@ -216,8 +216,8 @@ index 8a667b6..aaf5012 100644 + /* Runtime configuration options. */ const char *je_malloc_conf; - #ifdef JEMALLOC_DEBUG -@@ -448,7 +452,8 @@ malloc_conf_init(void) + bool opt_abort = +@@ -453,7 +457,8 @@ malloc_conf_init(void) #endif ; Modified: head/contrib/jemalloc/VERSION ============================================================================== --- head/contrib/jemalloc/VERSION Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/VERSION Thu Jan 24 03:08:37 2013 (r245868) @@ -1 +1 @@ -3.2.0-0-g87499f6748ebe4817571e817e9f680ccb5bf54a9 +3.3.0-0-g83789f45307379e096c4e8be81d9e9a51e3f5a4a Modified: head/contrib/jemalloc/doc/jemalloc.3 ============================================================================== --- head/contrib/jemalloc/doc/jemalloc.3 Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/doc/jemalloc.3 Thu Jan 24 03:08:37 2013 (r245868) @@ -2,12 +2,12 @@ .\" Title: JEMALLOC .\" Author: Jason Evans .\" Generator: DocBook XSL Stylesheets v1.76.1 -.\" Date: 11/09/2012 +.\" Date: 01/23/2013 .\" Manual: User Manual -.\" Source: jemalloc 3.2.0-0-g87499f6748ebe4817571e817e9f680ccb5bf54a9 +.\" Source: jemalloc 3.3.0-0-g83789f45307379e096c4e8be81d9e9a51e3f5a4a .\" Language: English .\" -.TH "JEMALLOC" "3" "11/09/2012" "jemalloc 3.2.0-0-g87499f6748eb" "User Manual" +.TH "JEMALLOC" "3" "01/23/2013" "jemalloc 3.3.0-0-g83789f453073" "User Manual" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- @@ -31,7 +31,7 @@ jemalloc \- general purpose memory allocation functions .SH "LIBRARY" .PP -This manual describes jemalloc 3\&.2\&.0\-0\-g87499f6748ebe4817571e817e9f680ccb5bf54a9\&. More information can be found at the +This manual describes jemalloc 3\&.3\&.0\-0\-g83789f45307379e096c4e8be81d9e9a51e3f5a4a\&. More information can be found at the \m[blue]\fBjemalloc website\fR\m[]\&\s-2\u[1]\d\s+2\&. .PP The following configuration options are enabled in libc\*(Aqs built\-in jemalloc: @@ -652,7 +652,7 @@ is specified during configuration, in wh .PP "opt\&.lg_chunk" (\fBsize_t\fR) r\- .RS 4 -Virtual memory chunk size (log base 2)\&. The default chunk size is 4 MiB (2^22)\&. +Virtual memory chunk size (log base 2)\&. If a chunk size outside the supported size range is specified, the size is silently clipped to the minimum/maximum supported size\&. The default chunk size is 4 MiB (2^22)\&. .RE .PP "opt\&.dss" (\fBconst char *\fR) r\- Modified: head/contrib/jemalloc/include/jemalloc/internal/arena.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/arena.h Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/include/jemalloc/internal/arena.h Thu Jan 24 03:08:37 2013 (r245868) @@ -400,7 +400,6 @@ extern arena_bin_info_t arena_bin_info[N #define nlclasses (chunk_npages - map_bias) void arena_purge_all(arena_t *arena); -void arena_prof_accum(arena_t *arena, uint64_t accumbytes); void arena_tcache_fill_small(arena_t *arena, tcache_bin_t *tbin, size_t binind, uint64_t prof_accumbytes); void arena_alloc_junk_small(void *ptr, arena_bin_info_t *bin_info, @@ -464,6 +463,9 @@ void arena_mapbits_small_set(arena_chunk size_t runind, size_t binind, size_t flags); void arena_mapbits_unzeroed_set(arena_chunk_t *chunk, size_t pageind, size_t unzeroed); +void arena_prof_accum_impl(arena_t *arena, uint64_t accumbytes); +void arena_prof_accum_locked(arena_t *arena, uint64_t accumbytes); +void arena_prof_accum(arena_t *arena, uint64_t accumbytes); size_t arena_ptr_small_binind_get(const void *ptr, size_t mapbits); size_t arena_bin_index(arena_t *arena, arena_bin_t *bin); unsigned arena_run_regind(arena_run_t *run, arena_bin_info_t *bin_info, @@ -478,7 +480,7 @@ void arena_dalloc(arena_t *arena, arena_ #if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_ARENA_C_)) # ifdef JEMALLOC_ARENA_INLINE_A -JEMALLOC_INLINE arena_chunk_map_t * +JEMALLOC_ALWAYS_INLINE arena_chunk_map_t * arena_mapp_get(arena_chunk_t *chunk, size_t pageind) { @@ -488,21 +490,21 @@ arena_mapp_get(arena_chunk_t *chunk, siz return (&chunk->map[pageind-map_bias]); } -JEMALLOC_INLINE size_t * +JEMALLOC_ALWAYS_INLINE size_t * arena_mapbitsp_get(arena_chunk_t *chunk, size_t pageind) { return (&arena_mapp_get(chunk, pageind)->bits); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_get(arena_chunk_t *chunk, size_t pageind) { return (*arena_mapbitsp_get(chunk, pageind)); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_unallocated_size_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -512,7 +514,7 @@ arena_mapbits_unallocated_size_get(arena return (mapbits & ~PAGE_MASK); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_large_size_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -523,7 +525,7 @@ arena_mapbits_large_size_get(arena_chunk return (mapbits & ~PAGE_MASK); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_small_runind_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -534,7 +536,7 @@ arena_mapbits_small_runind_get(arena_chu return (mapbits >> LG_PAGE); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_binind_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -546,7 +548,7 @@ arena_mapbits_binind_get(arena_chunk_t * return (binind); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_dirty_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -555,7 +557,7 @@ arena_mapbits_dirty_get(arena_chunk_t *c return (mapbits & CHUNK_MAP_DIRTY); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_unzeroed_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -564,7 +566,7 @@ arena_mapbits_unzeroed_get(arena_chunk_t return (mapbits & CHUNK_MAP_UNZEROED); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_large_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -573,7 +575,7 @@ arena_mapbits_large_get(arena_chunk_t *c return (mapbits & CHUNK_MAP_LARGE); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_mapbits_allocated_get(arena_chunk_t *chunk, size_t pageind) { size_t mapbits; @@ -582,7 +584,7 @@ arena_mapbits_allocated_get(arena_chunk_ return (mapbits & CHUNK_MAP_ALLOCATED); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_unallocated_set(arena_chunk_t *chunk, size_t pageind, size_t size, size_t flags) { @@ -595,7 +597,7 @@ arena_mapbits_unallocated_set(arena_chun *mapbitsp = size | CHUNK_MAP_BININD_INVALID | flags; } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_unallocated_size_set(arena_chunk_t *chunk, size_t pageind, size_t size) { @@ -607,7 +609,7 @@ arena_mapbits_unallocated_size_set(arena *mapbitsp = size | (*mapbitsp & PAGE_MASK); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_large_set(arena_chunk_t *chunk, size_t pageind, size_t size, size_t flags) { @@ -622,7 +624,7 @@ arena_mapbits_large_set(arena_chunk_t *c CHUNK_MAP_LARGE | CHUNK_MAP_ALLOCATED; } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_large_binind_set(arena_chunk_t *chunk, size_t pageind, size_t binind) { @@ -635,7 +637,7 @@ arena_mapbits_large_binind_set(arena_chu CHUNK_MAP_BININD_SHIFT); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_small_set(arena_chunk_t *chunk, size_t pageind, size_t runind, size_t binind, size_t flags) { @@ -651,7 +653,7 @@ arena_mapbits_small_set(arena_chunk_t *c flags | unzeroed | CHUNK_MAP_ALLOCATED; } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_mapbits_unzeroed_set(arena_chunk_t *chunk, size_t pageind, size_t unzeroed) { @@ -661,7 +663,45 @@ arena_mapbits_unzeroed_set(arena_chunk_t *mapbitsp = (*mapbitsp & ~CHUNK_MAP_UNZEROED) | unzeroed; } -JEMALLOC_INLINE size_t +JEMALLOC_INLINE void +arena_prof_accum_impl(arena_t *arena, uint64_t accumbytes) +{ + + cassert(config_prof); + assert(prof_interval != 0); + + arena->prof_accumbytes += accumbytes; + if (arena->prof_accumbytes >= prof_interval) { + prof_idump(); + arena->prof_accumbytes -= prof_interval; + } +} + +JEMALLOC_INLINE void +arena_prof_accum_locked(arena_t *arena, uint64_t accumbytes) +{ + + cassert(config_prof); + + if (prof_interval == 0) + return; + arena_prof_accum_impl(arena, accumbytes); +} + +JEMALLOC_INLINE void +arena_prof_accum(arena_t *arena, uint64_t accumbytes) +{ + + cassert(config_prof); + + if (prof_interval == 0) + return; + malloc_mutex_lock(&arena->lock); + arena_prof_accum_impl(arena, accumbytes); + malloc_mutex_unlock(&arena->lock); +} + +JEMALLOC_ALWAYS_INLINE size_t arena_ptr_small_binind_get(const void *ptr, size_t mapbits) { size_t binind; @@ -856,7 +896,7 @@ arena_prof_ctx_set(const void *ptr, prof arena_mapp_get(chunk, pageind)->prof_ctx = ctx; } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * arena_malloc(arena_t *arena, size_t size, bool zero, bool try_tcache) { tcache_t *tcache; @@ -887,7 +927,7 @@ arena_malloc(arena_t *arena, size_t size } /* Return the size of the allocation pointed to by ptr. */ -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t arena_salloc(const void *ptr, bool demote) { size_t ret; @@ -933,7 +973,7 @@ arena_salloc(const void *ptr, bool demot return (ret); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void arena_dalloc(arena_t *arena, arena_chunk_t *chunk, void *ptr, bool try_tcache) { size_t pageind, mapbits; Modified: head/contrib/jemalloc/include/jemalloc/internal/ckh.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/ckh.h Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/include/jemalloc/internal/ckh.h Thu Jan 24 03:08:37 2013 (r245868) @@ -5,7 +5,7 @@ typedef struct ckh_s ckh_t; typedef struct ckhc_s ckhc_t; /* Typedefs to allow easy function pointer passing. */ -typedef void ckh_hash_t (const void *, unsigned, size_t *, size_t *); +typedef void ckh_hash_t (const void *, size_t[2]); typedef bool ckh_keycomp_t (const void *, const void *); /* Maintain counters used to get an idea of performance. */ @@ -75,11 +75,9 @@ bool ckh_insert(ckh_t *ckh, const void * bool ckh_remove(ckh_t *ckh, const void *searchkey, void **key, void **data); bool ckh_search(ckh_t *ckh, const void *seachkey, void **key, void **data); -void ckh_string_hash(const void *key, unsigned minbits, size_t *hash1, - size_t *hash2); +void ckh_string_hash(const void *key, size_t r_hash[2]); bool ckh_string_keycomp(const void *k1, const void *k2); -void ckh_pointer_hash(const void *key, unsigned minbits, size_t *hash1, - size_t *hash2); +void ckh_pointer_hash(const void *key, size_t r_hash[2]); bool ckh_pointer_keycomp(const void *k1, const void *k2); #endif /* JEMALLOC_H_EXTERNS */ Modified: head/contrib/jemalloc/include/jemalloc/internal/hash.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/hash.h Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/include/jemalloc/internal/hash.h Thu Jan 24 03:08:37 2013 (r245868) @@ -1,3 +1,8 @@ +/* + * The following hash function is based on MurmurHash3, placed into the public + * domain by Austin Appleby. See http://code.google.com/p/smhasher/ for + * details. + */ /******************************************************************************/ #ifdef JEMALLOC_H_TYPES @@ -14,55 +19,311 @@ #ifdef JEMALLOC_H_INLINES #ifndef JEMALLOC_ENABLE_INLINE -uint64_t hash(const void *key, size_t len, uint64_t seed); +void hash(const void *key, size_t len, const uint32_t seed, + size_t r_hash[2]); #endif #if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_HASH_C_)) -/* - * The following hash function is based on MurmurHash64A(), placed into the - * public domain by Austin Appleby. See http://murmurhash.googlepages.com/ for - * details. - */ +/******************************************************************************/ +/* Internal implementation. */ +JEMALLOC_INLINE uint32_t +hash_rotl_32(uint32_t x, int8_t r) +{ + + return (x << r) | (x >> (32 - r)); +} + JEMALLOC_INLINE uint64_t -hash(const void *key, size_t len, uint64_t seed) +hash_rotl_64(uint64_t x, int8_t r) +{ + return (x << r) | (x >> (64 - r)); +} + +JEMALLOC_INLINE uint32_t +hash_get_block_32(const uint32_t *p, int i) +{ + + return p[i]; +} + +JEMALLOC_INLINE uint64_t +hash_get_block_64(const uint64_t *p, int i) +{ + + return p[i]; +} + +JEMALLOC_INLINE uint32_t +hash_fmix_32(uint32_t h) +{ + + h ^= h >> 16; + h *= 0x85ebca6b; + h ^= h >> 13; + h *= 0xc2b2ae35; + h ^= h >> 16; + + return h; +} + +JEMALLOC_INLINE uint64_t +hash_fmix_64(uint64_t k) +{ + + k ^= k >> 33; + k *= QU(0xff51afd7ed558ccdLLU); + k ^= k >> 33; + k *= QU(0xc4ceb9fe1a85ec53LLU); + k ^= k >> 33; + + return k; +} + +JEMALLOC_INLINE uint32_t +hash_x86_32(const void *key, int len, uint32_t seed) +{ + const uint8_t *data = (const uint8_t *) key; + const int nblocks = len / 4; + + uint32_t h1 = seed; + + const uint32_t c1 = 0xcc9e2d51; + const uint32_t c2 = 0x1b873593; + + /* body */ + { + const uint32_t *blocks = (const uint32_t *) (data + nblocks*4); + int i; + + for (i = -nblocks; i; i++) { + uint32_t k1 = hash_get_block_32(blocks, i); + + k1 *= c1; + k1 = hash_rotl_32(k1, 15); + k1 *= c2; + + h1 ^= k1; + h1 = hash_rotl_32(h1, 13); + h1 = h1*5 + 0xe6546b64; + } + } + + /* tail */ + { + const uint8_t *tail = (const uint8_t *) (data + nblocks*4); + + uint32_t k1 = 0; + + switch (len & 3) { + case 3: k1 ^= tail[2] << 16; + case 2: k1 ^= tail[1] << 8; + case 1: k1 ^= tail[0]; k1 *= c1; k1 = hash_rotl_32(k1, 15); + k1 *= c2; h1 ^= k1; + } + } + + /* finalization */ + h1 ^= len; + + h1 = hash_fmix_32(h1); + + return h1; +} + +UNUSED JEMALLOC_INLINE void +hash_x86_128(const void *key, const int len, uint32_t seed, + uint64_t r_out[2]) { - const uint64_t m = UINT64_C(0xc6a4a7935bd1e995); - const int r = 47; - uint64_t h = seed ^ (len * m); - const uint64_t *data = (const uint64_t *)key; - const uint64_t *end = data + (len/8); - const unsigned char *data2; + const uint8_t * data = (const uint8_t *) key; + const int nblocks = len / 16; + + uint32_t h1 = seed; + uint32_t h2 = seed; + uint32_t h3 = seed; + uint32_t h4 = seed; + + const uint32_t c1 = 0x239b961b; + const uint32_t c2 = 0xab0e9789; + const uint32_t c3 = 0x38b34ae5; + const uint32_t c4 = 0xa1e38b93; + + /* body */ + { + const uint32_t *blocks = (const uint32_t *) (data + nblocks*16); + int i; + + for (i = -nblocks; i; i++) { + uint32_t k1 = hash_get_block_32(blocks, i*4 + 0); + uint32_t k2 = hash_get_block_32(blocks, i*4 + 1); + uint32_t k3 = hash_get_block_32(blocks, i*4 + 2); + uint32_t k4 = hash_get_block_32(blocks, i*4 + 3); + + k1 *= c1; k1 = hash_rotl_32(k1, 15); k1 *= c2; h1 ^= k1; + + h1 = hash_rotl_32(h1, 19); h1 += h2; + h1 = h1*5 + 0x561ccd1b; - assert(((uintptr_t)key & 0x7) == 0); + k2 *= c2; k2 = hash_rotl_32(k2, 16); k2 *= c3; h2 ^= k2; - while(data != end) { - uint64_t k = *data++; + h2 = hash_rotl_32(h2, 17); h2 += h3; + h2 = h2*5 + 0x0bcaa747; - k *= m; - k ^= k >> r; - k *= m; + k3 *= c3; k3 = hash_rotl_32(k3, 17); k3 *= c4; h3 ^= k3; - h ^= k; - h *= m; + h3 = hash_rotl_32(h3, 15); h3 += h4; + h3 = h3*5 + 0x96cd1c35; + + k4 *= c4; k4 = hash_rotl_32(k4, 18); k4 *= c1; h4 ^= k4; + + h4 = hash_rotl_32(h4, 13); h4 += h1; + h4 = h4*5 + 0x32ac3b17; + } } - data2 = (const unsigned char *)data; - switch(len & 7) { - case 7: h ^= ((uint64_t)(data2[6])) << 48; - case 6: h ^= ((uint64_t)(data2[5])) << 40; - case 5: h ^= ((uint64_t)(data2[4])) << 32; - case 4: h ^= ((uint64_t)(data2[3])) << 24; - case 3: h ^= ((uint64_t)(data2[2])) << 16; - case 2: h ^= ((uint64_t)(data2[1])) << 8; - case 1: h ^= ((uint64_t)(data2[0])); - h *= m; + /* tail */ + { + const uint8_t *tail = (const uint8_t *) (data + nblocks*16); + uint32_t k1 = 0; + uint32_t k2 = 0; + uint32_t k3 = 0; + uint32_t k4 = 0; + + switch (len & 15) { + case 15: k4 ^= tail[14] << 16; + case 14: k4 ^= tail[13] << 8; + case 13: k4 ^= tail[12] << 0; + k4 *= c4; k4 = hash_rotl_32(k4, 18); k4 *= c1; h4 ^= k4; + + case 12: k3 ^= tail[11] << 24; + case 11: k3 ^= tail[10] << 16; + case 10: k3 ^= tail[ 9] << 8; + case 9: k3 ^= tail[ 8] << 0; + k3 *= c3; k3 = hash_rotl_32(k3, 17); k3 *= c4; h3 ^= k3; + + case 8: k2 ^= tail[ 7] << 24; + case 7: k2 ^= tail[ 6] << 16; + case 6: k2 ^= tail[ 5] << 8; + case 5: k2 ^= tail[ 4] << 0; + k2 *= c2; k2 = hash_rotl_32(k2, 16); k2 *= c3; h2 ^= k2; + + case 4: k1 ^= tail[ 3] << 24; + case 3: k1 ^= tail[ 2] << 16; + case 2: k1 ^= tail[ 1] << 8; + case 1: k1 ^= tail[ 0] << 0; + k1 *= c1; k1 = hash_rotl_32(k1, 15); k1 *= c2; h1 ^= k1; + } } - h ^= h >> r; - h *= m; - h ^= h >> r; + /* finalization */ + h1 ^= len; h2 ^= len; h3 ^= len; h4 ^= len; + + h1 += h2; h1 += h3; h1 += h4; + h2 += h1; h3 += h1; h4 += h1; + + h1 = hash_fmix_32(h1); + h2 = hash_fmix_32(h2); + h3 = hash_fmix_32(h3); + h4 = hash_fmix_32(h4); + + h1 += h2; h1 += h3; h1 += h4; + h2 += h1; h3 += h1; h4 += h1; + + r_out[0] = (((uint64_t) h2) << 32) | h1; + r_out[1] = (((uint64_t) h4) << 32) | h3; +} + +UNUSED JEMALLOC_INLINE void +hash_x64_128(const void *key, const int len, const uint32_t seed, + uint64_t r_out[2]) +{ + const uint8_t *data = (const uint8_t *) key; + const int nblocks = len / 16; + + uint64_t h1 = seed; + uint64_t h2 = seed; - return (h); + const uint64_t c1 = QU(0x87c37b91114253d5LLU); + const uint64_t c2 = QU(0x4cf5ad432745937fLLU); + + /* body */ + { + const uint64_t *blocks = (const uint64_t *) (data); + int i; + + for (i = 0; i < nblocks; i++) { + uint64_t k1 = hash_get_block_64(blocks, i*2 + 0); + uint64_t k2 = hash_get_block_64(blocks, i*2 + 1); + + k1 *= c1; k1 = hash_rotl_64(k1, 31); k1 *= c2; h1 ^= k1; + + h1 = hash_rotl_64(h1, 27); h1 += h2; + h1 = h1*5 + 0x52dce729; + + k2 *= c2; k2 = hash_rotl_64(k2, 33); k2 *= c1; h2 ^= k2; + + h2 = hash_rotl_64(h2, 31); h2 += h1; + h2 = h2*5 + 0x38495ab5; + } + } + + /* tail */ + { + const uint8_t *tail = (const uint8_t*)(data + nblocks*16); + uint64_t k1 = 0; + uint64_t k2 = 0; + + switch (len & 15) { + case 15: k2 ^= ((uint64_t)(tail[14])) << 48; + case 14: k2 ^= ((uint64_t)(tail[13])) << 40; + case 13: k2 ^= ((uint64_t)(tail[12])) << 32; + case 12: k2 ^= ((uint64_t)(tail[11])) << 24; + case 11: k2 ^= ((uint64_t)(tail[10])) << 16; + case 10: k2 ^= ((uint64_t)(tail[ 9])) << 8; + case 9: k2 ^= ((uint64_t)(tail[ 8])) << 0; + k2 *= c2; k2 = hash_rotl_64(k2, 33); k2 *= c1; h2 ^= k2; + + case 8: k1 ^= ((uint64_t)(tail[ 7])) << 56; + case 7: k1 ^= ((uint64_t)(tail[ 6])) << 48; + case 6: k1 ^= ((uint64_t)(tail[ 5])) << 40; + case 5: k1 ^= ((uint64_t)(tail[ 4])) << 32; + case 4: k1 ^= ((uint64_t)(tail[ 3])) << 24; + case 3: k1 ^= ((uint64_t)(tail[ 2])) << 16; + case 2: k1 ^= ((uint64_t)(tail[ 1])) << 8; + case 1: k1 ^= ((uint64_t)(tail[ 0])) << 0; + k1 *= c1; k1 = hash_rotl_64(k1, 31); k1 *= c2; h1 ^= k1; + } + } + + /* finalization */ + h1 ^= len; h2 ^= len; + + h1 += h2; + h2 += h1; + + h1 = hash_fmix_64(h1); + h2 = hash_fmix_64(h2); + + h1 += h2; + h2 += h1; + + r_out[0] = h1; + r_out[1] = h2; +} + + +/******************************************************************************/ +/* API. */ +JEMALLOC_INLINE void +hash(const void *key, size_t len, const uint32_t seed, size_t r_hash[2]) +{ +#if (LG_SIZEOF_PTR == 3) + hash_x64_128(key, len, seed, (uint64_t *)r_hash); +#else + uint64_t hashes[2]; + hash_x86_128(key, len, seed, hashes); + r_hash[0] = (size_t)hashes[0]; + r_hash[1] = (size_t)hashes[1]; +#endif } #endif Modified: head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/include/jemalloc/internal/jemalloc_internal.h Thu Jan 24 03:08:37 2013 (r245868) @@ -226,6 +226,7 @@ static const bool config_ivsalloc = #define ALLOCM_LG_ALIGN_MASK ((int)0x3f) #define ZU(z) ((size_t)z) +#define QU(q) ((uint64_t)q) #ifndef __DECONST # define __DECONST(type, var) ((type)(uintptr_t)(const void *)(var)) @@ -233,10 +234,17 @@ static const bool config_ivsalloc = #ifdef JEMALLOC_DEBUG /* Disable inlining to make debugging easier. */ +# define JEMALLOC_ALWAYS_INLINE # define JEMALLOC_INLINE # define inline #else # define JEMALLOC_ENABLE_INLINE +# ifdef JEMALLOC_HAVE_ATTR +# define JEMALLOC_ALWAYS_INLINE \ + static inline JEMALLOC_ATTR(unused) JEMALLOC_ATTR(always_inline) +# else +# define JEMALLOC_ALWAYS_INLINE static inline +# endif # define JEMALLOC_INLINE static inline # ifdef _MSC_VER # define inline _inline @@ -359,7 +367,11 @@ static const bool config_ivsalloc = # include # define alloca _alloca # else -# include +# ifdef JEMALLOC_HAS_ALLOCA_H +# include +# else +# include +# endif # endif # define VARIABLE_ARRAY(type, name, count) \ type *name = alloca(sizeof(type) * count) @@ -591,13 +603,14 @@ arena_t *choose_arena(arena_t *arena); * for allocations. */ malloc_tsd_externs(arenas, arena_t *) -malloc_tsd_funcs(JEMALLOC_INLINE, arenas, arena_t *, NULL, arenas_cleanup) +malloc_tsd_funcs(JEMALLOC_ALWAYS_INLINE, arenas, arena_t *, NULL, + arenas_cleanup) /* * Compute usable size that would result from allocating an object with the * specified size. */ -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t s2u(size_t size) { @@ -612,7 +625,7 @@ s2u(size_t size) * Compute usable size that would result from allocating an object with the * specified size and alignment. */ -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t sa2u(size_t size, size_t alignment) { size_t usize; @@ -757,7 +770,7 @@ malloc_tsd_protos(JEMALLOC_ATTR(unused), #endif #if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_C_)) -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * imallocx(size_t size, bool try_tcache, arena_t *arena) { @@ -769,14 +782,14 @@ imallocx(size_t size, bool try_tcache, a return (huge_malloc(size, false)); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * imalloc(size_t size) { return (imallocx(size, true, NULL)); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * icallocx(size_t size, bool try_tcache, arena_t *arena) { @@ -786,14 +799,14 @@ icallocx(size_t size, bool try_tcache, a return (huge_malloc(size, true)); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * icalloc(size_t size) { return (icallocx(size, true, NULL)); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * ipallocx(size_t usize, size_t alignment, bool zero, bool try_tcache, arena_t *arena) { @@ -818,7 +831,7 @@ ipallocx(size_t usize, size_t alignment, return (ret); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * ipalloc(size_t usize, size_t alignment, bool zero) { @@ -830,7 +843,7 @@ ipalloc(size_t usize, size_t alignment, * void *ptr = [...] * size_t sz = isalloc(ptr, config_prof); */ -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t isalloc(const void *ptr, bool demote) { size_t ret; @@ -849,7 +862,7 @@ isalloc(const void *ptr, bool demote) return (ret); } -JEMALLOC_INLINE size_t +JEMALLOC_ALWAYS_INLINE size_t ivsalloc(const void *ptr, bool demote) { @@ -882,7 +895,7 @@ p2rz(const void *ptr) return (u2rz(usize)); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void idallocx(void *ptr, bool try_tcache) { arena_chunk_t *chunk; @@ -896,14 +909,14 @@ idallocx(void *ptr, bool try_tcache) huge_dalloc(ptr, true); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void idalloc(void *ptr) { idallocx(ptr, true); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void iqallocx(void *ptr, bool try_tcache) { @@ -913,14 +926,14 @@ iqallocx(void *ptr, bool try_tcache) idallocx(ptr, try_tcache); } -JEMALLOC_INLINE void +JEMALLOC_ALWAYS_INLINE void iqalloc(void *ptr) { iqallocx(ptr, true); } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * irallocx(void *ptr, size_t size, size_t extra, size_t alignment, bool zero, bool no_move, bool try_tcache_alloc, bool try_tcache_dalloc, arena_t *arena) { @@ -989,7 +1002,7 @@ irallocx(void *ptr, size_t size, size_t } } -JEMALLOC_INLINE void * +JEMALLOC_ALWAYS_INLINE void * iralloc(void *ptr, size_t size, size_t extra, size_t alignment, bool zero, bool no_move) { @@ -999,7 +1012,7 @@ iralloc(void *ptr, size_t size, size_t e } malloc_tsd_externs(thread_allocated, thread_allocated_t) -malloc_tsd_funcs(JEMALLOC_INLINE, thread_allocated, thread_allocated_t, +malloc_tsd_funcs(JEMALLOC_ALWAYS_INLINE, thread_allocated, thread_allocated_t, THREAD_ALLOCATED_INITIALIZER, malloc_tsd_no_cleanup) #endif Modified: head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h ============================================================================== --- head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h Thu Jan 24 02:25:43 2013 (r245867) +++ head/contrib/jemalloc/include/jemalloc/internal/private_namespace.h Thu Jan 24 03:08:37 2013 (r245868) @@ -41,6 +41,8 @@ #define arena_postfork_parent JEMALLOC_N(arena_postfork_parent) #define arena_prefork JEMALLOC_N(arena_prefork) #define arena_prof_accum JEMALLOC_N(arena_prof_accum) +#define arena_prof_accum_impl JEMALLOC_N(arena_prof_accum_impl) +#define arena_prof_accum_locked JEMALLOC_N(arena_prof_accum_locked) #define arena_prof_ctx_get JEMALLOC_N(arena_prof_ctx_get) #define arena_prof_ctx_set JEMALLOC_N(arena_prof_ctx_set) #define arena_prof_promoted JEMALLOC_N(arena_prof_promoted) @@ -63,6 +65,7 @@ #define arenas_tsd_boot JEMALLOC_N(arenas_tsd_boot) #define arenas_tsd_cleanup_wrapper JEMALLOC_N(arenas_tsd_cleanup_wrapper) #define arenas_tsd_get JEMALLOC_N(arenas_tsd_get) +#define arenas_tsd_get_wrapper JEMALLOC_N(arenas_tsd_get_wrapper) #define arenas_tsd_set JEMALLOC_N(arenas_tsd_set) #define atomic_add_u JEMALLOC_N(atomic_add_u) #define atomic_add_uint32 JEMALLOC_N(atomic_add_uint32) @@ -174,6 +177,15 @@ #define extent_tree_szad_search JEMALLOC_N(extent_tree_szad_search) #define get_errno JEMALLOC_N(get_errno) #define hash JEMALLOC_N(hash) +#define hash_fmix_32 JEMALLOC_N(hash_fmix_32) +#define hash_fmix_64 JEMALLOC_N(hash_fmix_64) +#define hash_get_block_32 JEMALLOC_N(hash_get_block_32) +#define hash_get_block_64 JEMALLOC_N(hash_get_block_64) +#define hash_rotl_32 JEMALLOC_N(hash_rotl_32) +#define hash_rotl_64 JEMALLOC_N(hash_rotl_64) +#define hash_x64_128 JEMALLOC_N(hash_x64_128) +#define hash_x86_128 JEMALLOC_N(hash_x86_128) +#define hash_x86_32 JEMALLOC_N(hash_x86_32) *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 03:33:16 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 59C69B78; Thu, 24 Jan 2013 03:33:16 +0000 (UTC) (envelope-from jasone@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 42B47285; Thu, 24 Jan 2013 03:33:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O3XGOA070536; Thu, 24 Jan 2013 03:33:16 GMT (envelope-from jasone@svn.freebsd.org) Received: (from jasone@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O3XG2W070535; Thu, 24 Jan 2013 03:33:16 GMT (envelope-from jasone@svn.freebsd.org) Message-Id: <201301240333.r0O3XG2W070535@svn.freebsd.org> From: Jason Evans Date: Thu, 24 Jan 2013 03:33:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245869 - head/contrib/jemalloc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 03:33:16 -0000 Author: jasone Date: Thu Jan 24 03:33:15 2013 New Revision: 245869 URL: http://svnweb.freebsd.org/changeset/base/245869 Log: Update list of ports required for importing jemalloc. Modified: head/contrib/jemalloc/FREEBSD-upgrade Modified: head/contrib/jemalloc/FREEBSD-upgrade ============================================================================== --- head/contrib/jemalloc/FREEBSD-upgrade Thu Jan 24 03:08:37 2013 (r245868) +++ head/contrib/jemalloc/FREEBSD-upgrade Thu Jan 24 03:33:15 2013 (r245869) @@ -9,6 +9,7 @@ # - devel/git # - devel/gmake # - textproc/docbook-xsl +# - textproc/libxslt # # The normal workflow for importing a new release is: # From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 04:54:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id E26E7DD4; Thu, 24 Jan 2013 04:54:53 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D416470E; Thu, 24 Jan 2013 04:54:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O4sroI094481; Thu, 24 Jan 2013 04:54:53 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O4srUg094480; Thu, 24 Jan 2013 04:54:53 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201301240454.r0O4srUg094480@svn.freebsd.org> From: Pyun YongHyeon Date: Thu, 24 Jan 2013 04:54:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245870 - head/sys/dev/bge X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 04:54:54 -0000 Author: yongari Date: Thu Jan 24 04:54:53 2013 New Revision: 245870 URL: http://svnweb.freebsd.org/changeset/base/245870 Log: bge_attach() can fail before attaching mii(4). So make sure to check bge_miibus before detaching mii(4). Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Thu Jan 24 03:33:15 2013 (r245869) +++ head/sys/dev/bge/if_bge.c Thu Jan 24 04:54:53 2013 (r245870) @@ -3899,9 +3899,9 @@ bge_detach(device_t dev) if (sc->bge_tq) taskqueue_drain(sc->bge_tq, &sc->bge_intr_task); - if (sc->bge_flags & BGE_FLAG_TBI) { + if (sc->bge_flags & BGE_FLAG_TBI) ifmedia_removeall(&sc->bge_ifmedia); - } else { + else if (sc->bge_miibus != NULL) { bus_generic_detach(dev); device_delete_child(dev, sc->bge_miibus); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 05:36:38 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1A89F1CF; Thu, 24 Jan 2013 05:36:38 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E98BF7F8; Thu, 24 Jan 2013 05:36:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O5abd0006800; Thu, 24 Jan 2013 05:36:37 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O5ab7l006798; Thu, 24 Jan 2013 05:36:37 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201301240536.r0O5ab7l006798@svn.freebsd.org> From: Xin LI Date: Thu, 24 Jan 2013 05:36:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245871 - head/bin/df X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 05:36:38 -0000 Author: delphij Date: Thu Jan 24 05:36:37 2013 New Revision: 245871 URL: http://svnweb.freebsd.org/changeset/base/245871 Log: - Wrap long line; - Add -, to SYNOPSIS section. MFC after: 2 weeks Modified: head/bin/df/df.1 head/bin/df/df.c Modified: head/bin/df/df.1 ============================================================================== --- head/bin/df/df.1 Thu Jan 24 04:54:53 2013 (r245870) +++ head/bin/df/df.1 Thu Jan 24 05:36:37 2013 (r245871) @@ -29,7 +29,7 @@ .\" @(#)df.1 8.3 (Berkeley) 5/8/95 .\" $FreeBSD$ .\" -.Dd November 16, 2012 +.Dd January 24, 2012 .Dt DF 1 .Os .Sh NAME @@ -39,6 +39,7 @@ .Nm .Op Fl b | g | H | h | k | m | P .Op Fl acilnT +.Op Fl \&, .Op Fl t Ar type .Op Ar file | filesystem ... .Sh DESCRIPTION Modified: head/bin/df/df.c ============================================================================== --- head/bin/df/df.c Thu Jan 24 04:54:53 2013 (r245870) +++ head/bin/df/df.c Thu Jan 24 05:36:37 2013 (r245871) @@ -564,7 +564,8 @@ usage(void) { (void)fprintf(stderr, -"usage: df [-b | -g | -H | -h | -k | -m | -P] [-acilnT] [-t type] [-,] [file | filesystem ...]\n"); +"usage: df [-b | -g | -H | -h | -k | -m | -P] [-acilnT] [-t type] [-,]\n" +" [file | filesystem ...]\n"); exit(EX_USAGE); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 06:30:57 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2600BA20; Thu, 24 Jan 2013 06:30:57 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 01BEE95A; Thu, 24 Jan 2013 06:30:57 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O6UuAM023628; Thu, 24 Jan 2013 06:30:56 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O6UuHS023627; Thu, 24 Jan 2013 06:30:56 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201301240630.r0O6UuHS023627@svn.freebsd.org> From: Eitan Adler Date: Thu, 24 Jan 2013 06:30:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245872 - head/share/man/man4 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 06:30:57 -0000 Author: eadler Date: Thu Jan 24 06:30:56 2013 New Revision: 245872 URL: http://svnweb.freebsd.org/changeset/base/245872 Log: Indicate a bunch of new hardware support. PR: docs/173893 Submitted by: Mathieu Simon Approved by: bcr (mentor) Modified: head/share/man/man4/mfi.4 Modified: head/share/man/man4/mfi.4 ============================================================================== --- head/share/man/man4/mfi.4 Thu Jan 24 05:36:37 2013 (r245871) +++ head/share/man/man4/mfi.4 Thu Jan 24 06:30:56 2013 (r245872) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 12, 2010 +.Dd January 24, 2013 .Dt MFI 4 .Os .Sh NAME @@ -85,16 +85,24 @@ LSI MegaRAID SAS 8408E .It LSI MegaRAID SAS 8480E .It +LSI MegaRAID SAS 9240 +.It LSI MegaRAID SAS 9260 .It Dell PERC5 .It Dell PERC6 .It +IBM ServeRAID M1015 SAS/SATA +.It +IBM ServeRAID M1115 SAS/SATA +.It IBM ServeRAID M5015 SAS/SATA .It IBM ServeRAID-MR10i .It +Intel RAID Controller SRCSAS18E +.It Intel RAID Controller SROMBSAS18E .El .Sh FILES From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 09:29:42 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6EDCD4C9; Thu, 24 Jan 2013 09:29:42 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 509531F7; Thu, 24 Jan 2013 09:29:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O9TglG075187; Thu, 24 Jan 2013 09:29:42 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O9TfBr075185; Thu, 24 Jan 2013 09:29:41 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301240929.r0O9TfBr075185@svn.freebsd.org> From: Gleb Smirnoff Date: Thu, 24 Jan 2013 09:29:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245873 - in head/sys: kern sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 09:29:42 -0000 Author: glebius Date: Thu Jan 24 09:29:41 2013 New Revision: 245873 URL: http://svnweb.freebsd.org/changeset/base/245873 Log: - Move large functions m_getjcl() and m_get2() to kern/uipc_mbuf.c - style(9) fixes to mbuf.h Reviewed by: bde Modified: head/sys/kern/uipc_mbuf.c head/sys/sys/mbuf.h Modified: head/sys/kern/uipc_mbuf.c ============================================================================== --- head/sys/kern/uipc_mbuf.c Thu Jan 24 06:30:56 2013 (r245872) +++ head/sys/kern/uipc_mbuf.c Thu Jan 24 09:29:41 2013 (r245873) @@ -85,6 +85,79 @@ SYSCTL_INT(_kern_ipc, OID_AUTO, m_defrag #endif /* + * m_get2() allocates minimum mbuf that would fit "size" argument. + */ +struct mbuf * +m_get2(int how, short type, int flags, int size) +{ + struct mb_args args; + struct mbuf *m, *n; + uma_zone_t zone; + + args.flags = flags; + args.type = type; + + if (size <= MHLEN || (size <= MLEN && (flags & M_PKTHDR) == 0)) + return (uma_zalloc_arg(zone_mbuf, &args, how)); + if (size <= MCLBYTES) + return (uma_zalloc_arg(zone_pack, &args, how)); + if (size > MJUM16BYTES) + return (NULL); + + m = uma_zalloc_arg(zone_mbuf, &args, how); + if (m == NULL) + return (NULL); + +#if MJUMPAGESIZE != MCLBYTES + if (size <= MJUMPAGESIZE) + zone = zone_jumbop; + else +#endif + if (size <= MJUM9BYTES) + zone = zone_jumbo9; + else + zone = zone_jumbo16; + + n = uma_zalloc_arg(zone, m, how); + if (n == NULL) { + uma_zfree(zone_mbuf, m); + return (NULL); + } + + return (m); +} + +/* + * m_getjcl() returns an mbuf with a cluster of the specified size attached. + * For size it takes MCLBYTES, MJUMPAGESIZE, MJUM9BYTES, MJUM16BYTES. + */ +struct mbuf * +m_getjcl(int how, short type, int flags, int size) +{ + struct mb_args args; + struct mbuf *m, *n; + uma_zone_t zone; + + if (size == MCLBYTES) + return m_getcl(how, type, flags); + + args.flags = flags; + args.type = type; + + m = uma_zalloc_arg(zone_mbuf, &args, how); + if (m == NULL) + return (NULL); + + zone = m_getzone(size); + n = uma_zalloc_arg(zone, m, how); + if (n == NULL) { + uma_zfree(zone_mbuf, m); + return (NULL); + } + return (m); +} + +/* * Allocate a given length worth of mbufs and/or clusters (whatever fits * best) and return a pointer to the top of the allocated chain. If an * existing mbuf chain is provided, then we will append the new chain Modified: head/sys/sys/mbuf.h ============================================================================== --- head/sys/sys/mbuf.h Thu Jan 24 06:30:56 2013 (r245872) +++ head/sys/sys/mbuf.h Thu Jan 24 09:29:41 2013 (r245873) @@ -392,23 +392,8 @@ extern uma_zone_t zone_jumbo9; extern uma_zone_t zone_jumbo16; extern uma_zone_t zone_ext_refcnt; -static __inline struct mbuf *m_getcl(int how, short type, int flags); -static __inline struct mbuf *m_get(int how, short type); -static __inline struct mbuf *m_get2(int how, short type, int flags, - u_int size); -static __inline struct mbuf *m_gethdr(int how, short type); -static __inline struct mbuf *m_getjcl(int how, short type, int flags, - int size); -static __inline struct mbuf *m_getclr(int how, short type); /* XXX */ -static __inline int m_init(struct mbuf *m, uma_zone_t zone, - int size, int how, short type, int flags); -static __inline struct mbuf *m_free(struct mbuf *m); -static __inline void m_clget(struct mbuf *m, int how); -static __inline void *m_cljget(struct mbuf *m, int how, int size); -static __inline void m_chtype(struct mbuf *m, short new_type); -void mb_free_ext(struct mbuf *); -static __inline struct mbuf *m_last(struct mbuf *m); -int m_pkthdr_init(struct mbuf *m, int how); +void mb_free_ext(struct mbuf *); +int m_pkthdr_init(struct mbuf *, int); static __inline int m_gettype(int size) @@ -501,7 +486,7 @@ m_get(int how, short type) args.flags = 0; args.type = type; - return ((struct mbuf *)(uma_zalloc_arg(zone_mbuf, &args, how))); + return (uma_zalloc_arg(zone_mbuf, &args, how)); } /* @@ -528,7 +513,7 @@ m_gethdr(int how, short type) args.flags = M_PKTHDR; args.type = type; - return ((struct mbuf *)(uma_zalloc_arg(zone_mbuf, &args, how))); + return (uma_zalloc_arg(zone_mbuf, &args, how)); } static __inline struct mbuf * @@ -538,85 +523,7 @@ m_getcl(int how, short type, int flags) args.flags = flags; args.type = type; - return ((struct mbuf *)(uma_zalloc_arg(zone_pack, &args, how))); -} - -/* - * m_get2() allocates minimum mbuf that would fit "size" argument. - * - * XXX: This is rather large, should be real function maybe. - */ -static __inline struct mbuf * -m_get2(int how, short type, int flags, u_int size) -{ - struct mb_args args; - struct mbuf *m, *n; - uma_zone_t zone; - - args.flags = flags; - args.type = type; - - if (size <= MHLEN || (size <= MLEN && (flags & M_PKTHDR) == 0)) - return ((struct mbuf *)(uma_zalloc_arg(zone_mbuf, &args, how))); - if (size <= MCLBYTES) - return ((struct mbuf *)(uma_zalloc_arg(zone_pack, &args, how))); - - if (size > MJUM16BYTES) - return (NULL); - - m = uma_zalloc_arg(zone_mbuf, &args, how); - if (m == NULL) - return (NULL); - -#if MJUMPAGESIZE != MCLBYTES - if (size <= MJUMPAGESIZE) - zone = zone_jumbop; - else -#endif - if (size <= MJUM9BYTES) - zone = zone_jumbo9; - else - zone = zone_jumbo16; - - n = uma_zalloc_arg(zone, m, how); - if (n == NULL) { - uma_zfree(zone_mbuf, m); - return (NULL); - } - - return (m); -} - -/* - * m_getjcl() returns an mbuf with a cluster of the specified size attached. - * For size it takes MCLBYTES, MJUMPAGESIZE, MJUM9BYTES, MJUM16BYTES. - * - * XXX: This is rather large, should be real function maybe. - */ -static __inline struct mbuf * -m_getjcl(int how, short type, int flags, int size) -{ - struct mb_args args; - struct mbuf *m, *n; - uma_zone_t zone; - - if (size == MCLBYTES) - return m_getcl(how, type, flags); - - args.flags = flags; - args.type = type; - - m = uma_zalloc_arg(zone_mbuf, &args, how); - if (m == NULL) - return (NULL); - - zone = m_getzone(size); - n = uma_zalloc_arg(zone, m, how); - if (n == NULL) { - uma_zfree(zone_mbuf, m); - return (NULL); - } - return (m); + return (uma_zalloc_arg(zone_pack, &args, how)); } static __inline void @@ -880,7 +787,7 @@ struct mbuf *m_copymdata(struct mbuf *, int, int, int, int); struct mbuf *m_copypacket(struct mbuf *, int); void m_copy_pkthdr(struct mbuf *, struct mbuf *); -struct mbuf *m_copyup(struct mbuf *n, int len, int dstoff); +struct mbuf *m_copyup(struct mbuf *, int, int); struct mbuf *m_defrag(struct mbuf *, int); void m_demote(struct mbuf *, int); struct mbuf *m_devget(char *, int, int, struct ifnet *, @@ -890,6 +797,8 @@ int m_dup_pkthdr(struct mbuf *, struct u_int m_fixhdr(struct mbuf *); struct mbuf *m_fragment(struct mbuf *, int, int); void m_freem(struct mbuf *); +struct mbuf *m_get2(int, short, int, int); +struct mbuf *m_getjcl(int, short, int, int); struct mbuf *m_getm2(struct mbuf *, int, int, short, int); struct mbuf *m_getptr(struct mbuf *, int, int *); u_int m_length(struct mbuf *, struct mbuf **); @@ -899,10 +808,10 @@ struct mbuf *m_prepend(struct mbuf *, in void m_print(const struct mbuf *, int); struct mbuf *m_pulldown(struct mbuf *, int, int, int *); struct mbuf *m_pullup(struct mbuf *, int); -int m_sanity(struct mbuf *, int); +int m_sanity(struct mbuf *, int); struct mbuf *m_split(struct mbuf *, int, int); struct mbuf *m_uiotombuf(struct uio *, int, int, int, int); -struct mbuf *m_unshare(struct mbuf *, int how); +struct mbuf *m_unshare(struct mbuf *, int); /*- * Network packets may have annotations attached by affixing a list of From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 09:30:43 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7556764C; Thu, 24 Jan 2013 09:30:43 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5E01D20B; Thu, 24 Jan 2013 09:30:43 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O9Uh2F076951; Thu, 24 Jan 2013 09:30:43 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O9UhN2076950; Thu, 24 Jan 2013 09:30:43 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301240930.r0O9UhN2076950@svn.freebsd.org> From: Gleb Smirnoff Date: Thu, 24 Jan 2013 09:30:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245874 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 09:30:43 -0000 Author: glebius Date: Thu Jan 24 09:30:42 2013 New Revision: 245874 URL: http://svnweb.freebsd.org/changeset/base/245874 Log: style(9) Reviewed by: bde Modified: head/sys/sys/param.h Modified: head/sys/sys/param.h ============================================================================== --- head/sys/sys/param.h Thu Jan 24 09:29:41 2013 (r245873) +++ head/sys/sys/param.h Thu Jan 24 09:30:42 2013 (r245874) @@ -156,8 +156,8 @@ * MCLBYTES must be no larger than PAGE_SIZE. */ #ifndef MSIZE -#define MSIZE 256 /* size of an mbuf */ -#endif /* MSIZE */ +#define MSIZE 256 /* size of an mbuf */ +#endif #ifndef MCLSHIFT #define MCLSHIFT 11 /* convert bytes to mbuf clusters */ From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 09:33:44 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 240AD800; Thu, 24 Jan 2013 09:33:44 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 16977236; Thu, 24 Jan 2013 09:33:44 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O9Xh4d077403; Thu, 24 Jan 2013 09:33:43 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O9Xh1Q077402; Thu, 24 Jan 2013 09:33:43 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201301240933.r0O9Xh1Q077402@svn.freebsd.org> From: Alexander Motin Date: Thu, 24 Jan 2013 09:33:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245875 - head/sys/dev/ahci X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 09:33:44 -0000 Author: mav Date: Thu Jan 24 09:33:43 2013 New Revision: 245875 URL: http://svnweb.freebsd.org/changeset/base/245875 Log: Disable MSI interrupts for SB600 chipset. According to the report they are not functional. PR: kern/174880, kern/174985, kern/175002 MFC after: 1 week Modified: head/sys/dev/ahci/ahci.c Modified: head/sys/dev/ahci/ahci.c ============================================================================== --- head/sys/dev/ahci/ahci.c Thu Jan 24 09:30:42 2013 (r245874) +++ head/sys/dev/ahci/ahci.c Thu Jan 24 09:33:43 2013 (r245875) @@ -114,8 +114,9 @@ static struct { #define AHCI_Q_NOAA 512 #define AHCI_Q_NOCOUNT 1024 #define AHCI_Q_ALTSIG 2048 +#define AHCI_Q_NOMSI 4096 } ahci_ids[] = { - {0x43801002, 0x00, "ATI IXP600", 0}, + {0x43801002, 0x00, "ATI IXP600", AHCI_Q_NOMSI}, {0x43901002, 0x00, "ATI IXP700", 0}, {0x43911002, 0x00, "ATI IXP700", 0}, {0x43921002, 0x00, "ATI IXP700", 0}, @@ -634,6 +635,8 @@ ahci_setup_interrupt(device_t dev) int i, msi = 1; /* Process hints. */ + if (ctlr->quirks & AHCI_Q_NOMSI) + msi = 0; resource_int_value(device_get_name(dev), device_get_unit(dev), "msi", &msi); if (msi < 0) From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 09:36:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id B31BEAA9; Thu, 24 Jan 2013 09:36:50 +0000 (UTC) (envelope-from ganbold@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A056126C; Thu, 24 Jan 2013 09:36:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0O9aoGU077830; Thu, 24 Jan 2013 09:36:50 GMT (envelope-from ganbold@svn.freebsd.org) Received: (from ganbold@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0O9ao0X077829; Thu, 24 Jan 2013 09:36:50 GMT (envelope-from ganbold@svn.freebsd.org) Message-Id: <201301240936.r0O9ao0X077829@svn.freebsd.org> From: Ganbold Tsagaankhuu Date: Thu, 24 Jan 2013 09:36:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245876 - head/sys/arm/allwinner X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 09:36:50 -0000 Author: ganbold (doc committer) Date: Thu Jan 24 09:36:50 2013 New Revision: 245876 URL: http://svnweb.freebsd.org/changeset/base/245876 Log: Fix timer to support oneshot and periodic mode Use 64 bit high and low counter for timecounter and delay Reviewed by: mav@, ian@ Approved by: gonzo@ Modified: head/sys/arm/allwinner/timer.c Modified: head/sys/arm/allwinner/timer.c ============================================================================== --- head/sys/arm/allwinner/timer.c Thu Jan 24 09:33:43 2013 (r245875) +++ head/sys/arm/allwinner/timer.c Thu Jan 24 09:36:50 2013 (r245876) @@ -62,12 +62,18 @@ __FBSDID("$FreeBSD$"); #define SW_TIMER0_INT_VALUE_REG 0x14 #define SW_TIMER0_CUR_VALUE_REG 0x18 -#define SYS_TIMER_SCAL 16 /* timer clock source pre-divsion */ -#define SYS_TIMER_CLKSRC 24000000 /* timer clock source */ -#define TMR_INTER_VAL SYS_TIMER_CLKSRC/(SYS_TIMER_SCAL * 1000) +#define SW_COUNTER64LO_REG 0xa4 +#define SW_COUNTER64HI_REG 0xa8 +#define CNT64_CTRL_REG 0xa0 + +#define CNT64_RL_EN 0x02 /* read latch enable */ + +#define TIMER_ENABLE (1<<0) +#define TIMER_AUTORELOAD (1<<1) +#define TIMER_OSC24M (1<<2) /* oscillator = 24mhz */ +#define TIMER_PRESCALAR (4<<4) /* prescalar = 16 */ -#define CLOCK_TICK_RATE TMR_INTER_VAL -#define INITIAL_TIMECOUNTER (0xffffffff) +#define SYS_TIMER_CLKSRC 24000000 /* clock source */ struct a10_timer_softc { device_t sc_dev; @@ -76,7 +82,7 @@ struct a10_timer_softc { bus_space_handle_t sc_bsh; void *sc_ih; /* interrupt handler */ uint32_t sc_period; - uint32_t clkfreq; + uint32_t timer0_freq; struct eventtimer et; }; @@ -92,8 +98,10 @@ static int a10_timer_timer_start(struct struct bintime *, struct bintime *); static int a10_timer_timer_stop(struct eventtimer *); +static uint64_t timer_read_counter64(void); + static int a10_timer_initialized = 0; -static int a10_timer_intr(void *); +static int a10_timer_hardclock(void *); static int a10_timer_probe(device_t); static int a10_timer_attach(device_t); @@ -113,6 +121,22 @@ static struct resource_spec a10_timer_sp { -1, 0 } }; +static uint64_t +timer_read_counter64(void) +{ + uint32_t lo, hi; + + /* Latch counter, wait for it to be ready to read. */ + timer_write_4(a10_timer_sc, CNT64_CTRL_REG, CNT64_RL_EN); + while (timer_read_4(a10_timer_sc, CNT64_CTRL_REG) & CNT64_RL_EN) + continue; + + hi = timer_read_4(a10_timer_sc, SW_COUNTER64HI_REG); + lo = timer_read_4(a10_timer_sc, SW_COUNTER64LO_REG); + + return (((uint64_t)hi << 32) | lo); +} + static int a10_timer_probe(device_t dev) { @@ -130,7 +154,6 @@ a10_timer_attach(device_t dev) struct a10_timer_softc *sc; int err; uint32_t val; - uint32_t freq; sc = device_get_softc(dev); @@ -143,28 +166,8 @@ a10_timer_attach(device_t dev) sc->sc_bst = rman_get_bustag(sc->res[0]); sc->sc_bsh = rman_get_bushandle(sc->res[0]); - /* set interval */ - timer_write_4(sc, SW_TIMER0_INT_VALUE_REG, TMR_INTER_VAL); - - /* set clock source to HOSC, 16 pre-division */ - val = timer_read_4(sc, SW_TIMER0_CTRL_REG); - val &= ~(0x07<<4); - val &= ~(0x03<<2); - val |= (4<<4) | (1<<2); - timer_write_4(sc, SW_TIMER0_CTRL_REG, val); - - /* set mode to auto reload */ - val = timer_read_4(sc, SW_TIMER0_CTRL_REG); - val |= (1<<1); - timer_write_4(sc, SW_TIMER0_CTRL_REG, val); - - /* Enable timer0 */ - val = timer_read_4(sc, SW_TIMER_IRQ_EN_REG); - val |= (1<<0); - timer_write_4(sc, SW_TIMER_IRQ_EN_REG, val); - /* Setup and enable the timer interrupt */ - err = bus_setup_intr(dev, sc->res[1], INTR_TYPE_CLK, a10_timer_intr, + err = bus_setup_intr(dev, sc->res[1], INTR_TYPE_CLK, a10_timer_hardclock, NULL, sc, &sc->sc_ih); if (err != 0) { bus_release_resources(dev, a10_timer_spec, sc->res); @@ -172,17 +175,27 @@ a10_timer_attach(device_t dev) "err = %d\n", err); return (ENXIO); } - freq = SYS_TIMER_CLKSRC; - /* Set desired frequency in event timer and timecounter */ - sc->et.et_frequency = (uint64_t)freq; - sc->clkfreq = (uint64_t)freq; + /* Set clock source to OSC24M, 16 pre-division */ + val = timer_read_4(sc, SW_TIMER0_CTRL_REG); + val |= TIMER_PRESCALAR | TIMER_OSC24M; + timer_write_4(sc, SW_TIMER0_CTRL_REG, val); + + /* Enable timer0 */ + val = timer_read_4(sc, SW_TIMER_IRQ_EN_REG); + val |= TIMER_ENABLE; + timer_write_4(sc, SW_TIMER_IRQ_EN_REG, val); + + sc->timer0_freq = SYS_TIMER_CLKSRC; + + /* Set desired frequency in event timer and timecounter */ + sc->et.et_frequency = sc->timer0_freq; sc->et.et_name = "a10_timer Eventtimer"; sc->et.et_flags = ET_FLAGS_ONESHOT | ET_FLAGS_PERIODIC; sc->et.et_quality = 1000; sc->et.et_min_period.sec = 0; sc->et.et_min_period.frac = - ((0x00000002LLU << 32) / sc->et.et_frequency) << 32; + ((0x00000005LLU << 32) / sc->et.et_frequency) << 32; sc->et.et_max_period.sec = 0xfffffff0U / sc->et.et_frequency; sc->et.et_max_period.frac = ((0xfffffffeLLU << 32) / sc->et.et_frequency) << 32; @@ -194,15 +207,20 @@ a10_timer_attach(device_t dev) if (device_get_unit(dev) == 0) a10_timer_sc = sc; - a10_timer_timecounter.tc_frequency = (uint64_t)freq; + a10_timer_timecounter.tc_frequency = sc->timer0_freq; tc_init(&a10_timer_timecounter); - printf("clock: hz=%d stathz = %d\n", hz, stathz); + if (bootverbose) { + device_printf(sc->sc_dev, "clock: hz=%d stathz = %d\n", hz, stathz); - device_printf(sc->sc_dev, "timer clock frequency %d\n", sc->clkfreq); + device_printf(sc->sc_dev, "event timer clock frequency %u\n", + sc->timer0_freq); + device_printf(sc->sc_dev, "timecounter clock frequency %lld\n", + a10_timer_timecounter.tc_frequency); + } a10_timer_initialized = 1; - + return (0); } @@ -211,25 +229,42 @@ a10_timer_timer_start(struct eventtimer struct bintime *period) { struct a10_timer_softc *sc; - uint32_t clo, count; + uint32_t count; + uint32_t val; sc = (struct a10_timer_softc *)et->et_priv; - if (first != NULL) { + sc->sc_period = 0; + + if (period != NULL) { + sc->sc_period = (sc->et.et_frequency * (period->frac >> 32)) >> 32; + sc->sc_period += sc->et.et_frequency * period->sec; + } + if (first == NULL) + count = sc->sc_period; + else { count = (sc->et.et_frequency * (first->frac >> 32)) >> 32; if (first->sec != 0) count += sc->et.et_frequency * first->sec; + } - /* clear */ - timer_write_4(sc, SW_TIMER0_CUR_VALUE_REG, 0); - clo = timer_read_4(sc, SW_TIMER0_CUR_VALUE_REG); - clo += count; - timer_write_4(sc, SW_TIMER0_CUR_VALUE_REG, clo); + /* Update timer values */ + timer_write_4(sc, SW_TIMER0_INT_VALUE_REG, sc->sc_period); + timer_write_4(sc, SW_TIMER0_CUR_VALUE_REG, count); - return (0); + val = timer_read_4(sc, SW_TIMER0_CTRL_REG); + if (first == NULL) { + /* periodic */ + val |= TIMER_AUTORELOAD; + } else { + /* oneshot */ + val &= ~TIMER_AUTORELOAD; } + /* Enable timer0 */ + val |= TIMER_ENABLE; + timer_write_4(sc, SW_TIMER0_CTRL_REG, val); - return (EINVAL); + return (0); } static int @@ -240,12 +275,9 @@ a10_timer_timer_stop(struct eventtimer * sc = (struct a10_timer_softc *)et->et_priv; - /* clear */ - timer_write_4(sc, SW_TIMER0_CUR_VALUE_REG, 0); - - /* disable */ + /* Disable timer0 */ val = timer_read_4(sc, SW_TIMER0_CTRL_REG); - val &= ~(1<<0); /* Disable timer0 */ + val &= ~TIMER_ENABLE; timer_write_4(sc, SW_TIMER0_CTRL_REG, val); sc->sc_period = 0; @@ -256,8 +288,7 @@ a10_timer_timer_stop(struct eventtimer * int a10_timer_get_timerfreq(struct a10_timer_softc *sc) { - - return (sc->clkfreq); + return (sc->timer0_freq); } void @@ -267,18 +298,35 @@ cpu_initclocks(void) } static int -a10_timer_intr(void *arg) +a10_timer_hardclock(void *arg) { struct a10_timer_softc *sc; + uint32_t val; sc = (struct a10_timer_softc *)arg; + /* Clear interrupt pending bit. */ + timer_write_4(sc, SW_TIMER_IRQ_STA_REG, 0x1); + + val = timer_read_4(sc, SW_TIMER0_CTRL_REG); + /* + * Disabled autoreload and sc_period > 0 means + * timer_start was called with non NULL first value. + * Now we will set periodic timer with the given period + * value. + */ + if ((val & (1<<1)) == 0 && sc->sc_period > 0) { + /* Update timer */ + timer_write_4(sc, SW_TIMER0_CUR_VALUE_REG, sc->sc_period); + + /* Make periodic and enable */ + val |= TIMER_AUTORELOAD | TIMER_ENABLE; + timer_write_4(sc, SW_TIMER0_CTRL_REG, val); + } + if (sc->et.et_active) sc->et.et_event_cb(&sc->et, sc->et.et_arg); - /* pending */ - timer_write_4(sc, SW_TIMER_IRQ_STA_REG, 0x1); - return (FILTER_HANDLED); } @@ -289,7 +337,7 @@ a10_timer_get_timecount(struct timecount if (a10_timer_sc == NULL) return (0); - return (timer_read_4(a10_timer_sc, SW_TIMER0_CUR_VALUE_REG)); + return ((u_int)timer_read_counter64()); } static device_method_t a10_timer_methods[] = { @@ -313,29 +361,19 @@ void DELAY(int usec) { uint32_t counter; - uint32_t val, val_temp; - int32_t nticks; + uint64_t end, now; - /* Timer is not initialized yet */ if (!a10_timer_initialized) { for (; usec > 0; usec--) - for (counter = 200; counter > 0; counter--) - /* Prevent optimizing out the loop */ + for (counter = 50; counter > 0; counter--) cpufunc_nullop(); return; } - val = timer_read_4(a10_timer_sc, SW_TIMER0_CUR_VALUE_REG); - nticks = ((a10_timer_sc->clkfreq / 1000000 + 1) * usec); - - while (nticks > 0) { - val_temp = timer_read_4(a10_timer_sc, SW_TIMER0_CUR_VALUE_REG); - if (val > val_temp) - nticks -= (val - val_temp); - else - nticks -= (val + (INITIAL_TIMECOUNTER - val_temp)); + now = timer_read_counter64(); + end = now + (a10_timer_sc->timer0_freq / 1000000) * (usec + 1); - val = val_temp; - } + while (now < end) + now = timer_read_counter64(); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 11:42:16 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DC4C93A9; Thu, 24 Jan 2013 11:42:16 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C6EB1F7; Thu, 24 Jan 2013 11:42:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OBgGIP015955; Thu, 24 Jan 2013 11:42:16 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OBgGui015954; Thu, 24 Jan 2013 11:42:16 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241142.r0OBgGui015954@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 11:42:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245877 - head/sys/mips/nlm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 11:42:16 -0000 Author: jchandra Date: Thu Jan 24 11:42:16 2013 New Revision: 245877 URL: http://svnweb.freebsd.org/changeset/base/245877 Log: Little-endian fix for PCI on Broadcom XLP. Update the function xlp_pcib_hardware_swap_enable() to do nothing when BYTE_ORDER is not BIG_ENDIAN. PCIe hardware swap is not requred in little-endian mode as the endianness matches that of CPU. Modified: head/sys/mips/nlm/xlp_pci.c Modified: head/sys/mips/nlm/xlp_pci.c ============================================================================== --- head/sys/mips/nlm/xlp_pci.c Thu Jan 24 09:36:50 2013 (r245876) +++ head/sys/mips/nlm/xlp_pci.c Thu Jan 24 11:42:16 2013 (r245877) @@ -487,12 +487,14 @@ xlp_pcib_write_config(device_t dev, u_in } /* - * Enable byte swap in hardware. Program a link's PCIe SWAP regions - * from the link's IO and MEM address ranges. + * Enable byte swap in hardware when compiled big-endian. + * Programs a link's PCIe SWAP regions from the link's IO and MEM address + * ranges. */ static void xlp_pcib_hardware_swap_enable(int node, int link) { +#if BYTE_ORDER == BIG_ENDIAN uint64_t bbase, linkpcibase; uint32_t bar; int pcieoffset; @@ -514,6 +516,7 @@ xlp_pcib_hardware_swap_enable(int node, bar = nlm_read_bridge_reg(bbase, BRIDGE_PCIEIO_LIMIT0 + link); nlm_write_pci_reg(linkpcibase, PCIE_BYTE_SWAP_IO_LIM, bar | 0xFFF); +#endif } static int From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 14:29:32 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6B2F4CB4; Thu, 24 Jan 2013 14:29:32 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5DE8EABB; Thu, 24 Jan 2013 14:29:32 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OETWUY065848; Thu, 24 Jan 2013 14:29:32 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OETWAc065847; Thu, 24 Jan 2013 14:29:32 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301241429.r0OETWAc065847@svn.freebsd.org> From: Gleb Smirnoff Date: Thu, 24 Jan 2013 14:29:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245878 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 14:29:32 -0000 Author: glebius Date: Thu Jan 24 14:29:31 2013 New Revision: 245878 URL: http://svnweb.freebsd.org/changeset/base/245878 Log: - Utilize m_get2(), accidentially fixing some signedness bugs. - Return EMSGSIZE in both cases if uio_resid is oversized or undersized. - No need to clear rcvif. Modified: head/sys/net/bpf.c Modified: head/sys/net/bpf.c ============================================================================== --- head/sys/net/bpf.c Thu Jan 24 11:42:16 2013 (r245877) +++ head/sys/net/bpf.c Thu Jan 24 14:29:31 2013 (r245878) @@ -522,32 +522,15 @@ bpf_movein(struct uio *uio, int linktype } len = uio->uio_resid; - - if (len - hlen > ifp->if_mtu) + if (len < hlen || len - hlen > ifp->if_mtu) return (EMSGSIZE); - if ((unsigned)len > MJUM16BYTES) + m = m_get2(M_WAITOK, MT_DATA, M_PKTHDR, len); + if (m == NULL) return (EIO); - - if (len <= MHLEN) - MGETHDR(m, M_WAITOK, MT_DATA); - else if (len <= MCLBYTES) - m = m_getcl(M_WAITOK, MT_DATA, M_PKTHDR); - else - m = m_getjcl(M_WAITOK, MT_DATA, M_PKTHDR, -#if (MJUMPAGESIZE > MCLBYTES) - len <= MJUMPAGESIZE ? MJUMPAGESIZE : -#endif - (len <= MJUM9BYTES ? MJUM9BYTES : MJUM16BYTES)); m->m_pkthdr.len = m->m_len = len; - m->m_pkthdr.rcvif = NULL; *mp = m; - if (m->m_len < hlen) { - error = EPERM; - goto bad; - } - error = uiomove(mtod(m, u_char *), len, uio); if (error) goto bad; From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 14:33:28 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1D60CF67; Thu, 24 Jan 2013 14:33:28 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EBFB3AEB; Thu, 24 Jan 2013 14:33:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OEXQUg068033; Thu, 24 Jan 2013 14:33:26 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OEXQtu068031; Thu, 24 Jan 2013 14:33:26 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241433.r0OEXQtu068031@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 14:33:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245879 - in head/sys/mips/nlm: . hal X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 14:33:28 -0000 Author: jchandra Date: Thu Jan 24 14:33:25 2013 New Revision: 245879 URL: http://svnweb.freebsd.org/changeset/base/245879 Log: Broadcom XLP updates for the new firmware Support few more versions of board firmware. In case the security block is disabled, enable it at boot. Also increase the excluded memory region to cover the area used by the firmware to initialize devices. Modified: head/sys/mips/nlm/hal/sys.h head/sys/mips/nlm/xlp_machdep.c Modified: head/sys/mips/nlm/hal/sys.h ============================================================================== --- head/sys/mips/nlm/hal/sys.h Thu Jan 24 14:29:31 2013 (r245878) +++ head/sys/mips/nlm/hal/sys.h Thu Jan 24 14:33:25 2013 (r245879) @@ -140,5 +140,18 @@ enum { INVALID_DFS_DEVICE = 0xFF }; +static __inline +void nlm_sys_enable_block(uint64_t sys_base, int block) +{ + uint32_t dfsdis, mask; + + mask = 1 << block; + dfsdis = nlm_read_sys_reg(sys_base, SYS_DFS_DIS_CTRL); + if ((dfsdis & mask) == 0) + return; /* already enabled, nothing to do */ + dfsdis &= ~mask; + nlm_write_sys_reg(sys_base, SYS_DFS_DIS_CTRL, dfsdis); +} + #endif #endif Modified: head/sys/mips/nlm/xlp_machdep.c ============================================================================== --- head/sys/mips/nlm/xlp_machdep.c Thu Jan 24 14:29:31 2013 (r245878) +++ head/sys/mips/nlm/xlp_machdep.c Thu Jan 24 14:33:25 2013 (r245879) @@ -157,6 +157,20 @@ xlp_setup_mmu(void) } static void +xlp_enable_blocks(void) +{ + uint64_t sysbase; + int i; + + for (i = 0; i < XLP_MAX_NODES; i++) { + if (!nlm_dev_exists(XLP_IO_SYS_OFFSET(i))) + continue; + sysbase = nlm_get_sys_regbase(i); + nlm_sys_enable_block(sysbase, DFS_DEVICE_RSA); + } +} + +static void xlp_parse_mmu_options(void) { uint64_t sysbase; @@ -420,9 +434,8 @@ xlp_pic_init(void) #define XLP_MEM_LIM 0xfffff000UL #endif static vm_paddr_t xlp_mem_excl[] = { - 0, 0, /* entry for kernel image, set by xlp_mem_init*/ - 0x0c000000, 0x0d000000, /* uboot mess */ - 0x10000000, 0x14000000, /* cms queue and other stuff */ + 0, 0, /* for kernel image region, see xlp_mem_init */ + 0x0c000000, 0x14000000, /* uboot area, cms queue and other stuff */ 0x1fc00000, 0x1fd00000, /* reset vec */ 0x1e000000, 0x1e200000, /* poe buffers */ }; @@ -559,6 +572,8 @@ platform_start(__register_t a0 __unused, /* setup for the startup core */ xlp_setup_mmu(); + xlp_enable_blocks(); + /* Read/Guess/setup board information */ nlm_board_info_setup(); From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 14:42:59 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 685CD370; Thu, 24 Jan 2013 14:42:59 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4F195B5E; Thu, 24 Jan 2013 14:42:59 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OEgxL0070932; Thu, 24 Jan 2013 14:42:59 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OEgwvg070929; Thu, 24 Jan 2013 14:42:58 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241442.r0OEgwvg070929@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 14:42:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245880 - head/sys/mips/nlm/dev/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 14:42:59 -0000 Author: jchandra Date: Thu Jan 24 14:42:58 2013 New Revision: 245880 URL: http://svnweb.freebsd.org/changeset/base/245880 Log: Minor updates to the Broadcom XLP NAE driver Remove unnecessary SGMII initialization code from nae.c. While there clean up some prints and whitespace. Modified: head/sys/mips/nlm/dev/net/nae.c head/sys/mips/nlm/dev/net/xlpge.c Modified: head/sys/mips/nlm/dev/net/nae.c ============================================================================== --- head/sys/mips/nlm/dev/net/nae.c Thu Jan 24 14:33:25 2013 (r245879) +++ head/sys/mips/nlm/dev/net/nae.c Thu Jan 24 14:42:58 2013 (r245880) @@ -1427,9 +1427,8 @@ nlm_nae_open_if(uint64_t nae_base, int n int port, uint32_t desc_size) { uint32_t netwk_inf; - uint32_t mac_cfg1, mac_cfg2, netior_ctrl3; - int iface, speed, duplex, ifmode; - int iface_ctrl_reg, iface_ctrl3_reg, conf1_reg, conf2_reg; + uint32_t mac_cfg1, netior_ctrl3; + int iface, iface_ctrl_reg, iface_ctrl3_reg, conf1_reg, conf2_reg; switch (port_type) { case XAUIC: @@ -1487,6 +1486,7 @@ nlm_nae_open_if(uint64_t nae_base, int n /* clear gmac reset */ mac_cfg1 = nlm_read_nae_reg(nae_base, conf1_reg); nlm_write_nae_reg(nae_base, conf1_reg, mac_cfg1 & ~(1 << 31)); + /* clear speed debug bit */ iface_ctrl3_reg = SGMII_NET_IFACE_CTRL3(nblock, iface); netior_ctrl3 = nlm_read_nae_reg(nae_base, iface_ctrl3_reg); @@ -1500,33 +1500,21 @@ nlm_nae_open_if(uint64_t nae_base, int n nlm_write_nae_reg(nae_base, iface_ctrl_reg, netwk_inf & ~(0x1 << 2)); - /* setup defaults */ /* XXXJC: take defaults from sc? */ - speed = 2; - duplex = 1; - ifmode = 0x2; - netwk_inf = nlm_read_nae_reg(nae_base, iface_ctrl_reg); - netwk_inf &= ~(0x3); - nlm_write_nae_reg(nae_base, iface_ctrl_reg, - netwk_inf | (speed & 0x3)); - mac_cfg2 = nlm_read_nae_reg(nae_base, conf2_reg); - mac_cfg2 &= ~(0x3 << 8); - nlm_write_nae_reg(nae_base, conf2_reg, - mac_cfg2 | - ((ifmode & 0x3) << 8) | /* interface mode */ - (duplex & 0x1)); - /* clear stats counters */ netwk_inf = nlm_read_nae_reg(nae_base, iface_ctrl_reg); nlm_write_nae_reg(nae_base, iface_ctrl_reg, netwk_inf | (1 << 15)); + /* enable stats counters */ netwk_inf = nlm_read_nae_reg(nae_base, iface_ctrl_reg); nlm_write_nae_reg(nae_base, iface_ctrl_reg, (netwk_inf & ~(1 << 15)) | (1 << 16)); + + /* flow control? */ mac_cfg1 = nlm_read_nae_reg(nae_base, conf1_reg); nlm_write_nae_reg(nae_base, conf1_reg, mac_cfg1 | (0x3 << 4)); - break; + break; } nlm_nae_init_ingress(nae_base, desc_size); Modified: head/sys/mips/nlm/dev/net/xlpge.c ============================================================================== --- head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 14:33:25 2013 (r245879) +++ head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 14:42:58 2013 (r245880) @@ -1364,13 +1364,13 @@ nlm_xlpge_mii_statchg(device_t dev) if (mii->mii_media_status & IFM_ACTIVE) { if (IFM_SUBTYPE(mii->mii_media_active) == IFM_10_T) { sc->speed = NLM_SGMII_SPEED_10; - speed = "10-Mbps"; + speed = "10Mbps"; } else if (IFM_SUBTYPE(mii->mii_media_active) == IFM_100_TX) { sc->speed = NLM_SGMII_SPEED_100; - speed = "100-Mbps"; + speed = "100Mbps"; } else { /* default to 1G */ sc->speed = NLM_SGMII_SPEED_1000; - speed = "1-Gbps"; + speed = "1Gbps"; } if ((mii->mii_media_active & IFM_GMASK) == IFM_FDX) { @@ -1381,7 +1381,7 @@ nlm_xlpge_mii_statchg(device_t dev) duplexity = "half"; } - printf("Setup [complex=%d, port=%d] with speed=%s duplex=%s\n", + printf("Port [%d, %d] setup with speed=%s duplex=%s\n", sc->block, sc->port, speed, duplexity); nlm_nae_setup_mac(sc->base_addr, sc->block, sc->port, 0, 1, 1, From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 15:14:23 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EC296455; Thu, 24 Jan 2013 15:14:23 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CF036E75; Thu, 24 Jan 2013 15:14:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OFENwG080484; Thu, 24 Jan 2013 15:14:23 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OFEN2p080480; Thu, 24 Jan 2013 15:14:23 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241514.r0OFEN2p080480@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 15:14:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245881 - in head/sys/mips/nlm: dev/net hal X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 15:14:24 -0000 Author: jchandra Date: Thu Jan 24 15:14:22 2013 New Revision: 245881 URL: http://svnweb.freebsd.org/changeset/base/245881 Log: Broadcom XLP network driver update for XLP 8xx B1 rev Update MDIO reset code to support Broadcom XLP B1 revisions. Update nlm_xlpge_ioctl, nlm_xlpge_port_enable need not be called after nlm_xlpge_init. Obtained from: Venkatesh J V Modified: head/sys/mips/nlm/dev/net/mdio.c head/sys/mips/nlm/dev/net/sgmii.c head/sys/mips/nlm/dev/net/xlpge.c head/sys/mips/nlm/hal/mdio.h Modified: head/sys/mips/nlm/dev/net/mdio.c ============================================================================== --- head/sys/mips/nlm/dev/net/mdio.c Thu Jan 24 14:42:58 2013 (r245880) +++ head/sys/mips/nlm/dev/net/mdio.c Thu Jan 24 15:14:22 2013 (r245881) @@ -149,7 +149,8 @@ nlm_int_gmac_mdio_reset(uint64_t nae_bas uint32_t val; val = (7 << INT_MDIO_CTRL_XDIV_POS) | - (1 << INT_MDIO_CTRL_MCDIV_POS); + (1 << INT_MDIO_CTRL_MCDIV_POS) | + (INT_MDIO_CTRL_SMP); nlm_write_nae_reg(nae_base, NAE_REG(block, intf_type, (INT_MDIO_CTRL + bus * 4)), @@ -302,10 +303,13 @@ nlm_gmac_mdio_reset(uint64_t nae_base, i { uint32_t ctrlval; + ctrlval = nlm_read_nae_reg(nae_base, + NAE_REG(block, intf_type, (EXT_G0_MDIO_CTRL+bus*4))); + if (nlm_is_xlp8xx_ax() || nlm_is_xlp8xx_b0() || nlm_is_xlp3xx_ax()) - ctrlval = EXT_G_MDIO_DIV; + ctrlval |= EXT_G_MDIO_DIV; else - ctrlval = EXT_G_MDIO_DIV_WITH_HW_DIV64; + ctrlval |= EXT_G_MDIO_DIV_WITH_HW_DIV64; nlm_write_nae_reg(nae_base, NAE_REG(block, intf_type, (EXT_G0_MDIO_CTRL + bus * 4)), @@ -314,3 +318,16 @@ nlm_gmac_mdio_reset(uint64_t nae_base, i NAE_REG(block, intf_type, (EXT_G0_MDIO_CTRL + bus * 4)), ctrlval); return (0); } + +/* + * nlm_mdio_reset_all : reset all internal and external MDIO + */ +void +nlm_mdio_reset_all(uint64_t nae_base) +{ + /* reset internal MDIO */ + nlm_int_gmac_mdio_reset(nae_base, 0, BLOCK_7, LANE_CFG); + /* reset external MDIO */ + nlm_gmac_mdio_reset(nae_base, 0, BLOCK_7, LANE_CFG); + nlm_gmac_mdio_reset(nae_base, 1, BLOCK_7, LANE_CFG); +} Modified: head/sys/mips/nlm/dev/net/sgmii.c ============================================================================== --- head/sys/mips/nlm/dev/net/sgmii.c Thu Jan 24 14:42:58 2013 (r245880) +++ head/sys/mips/nlm/dev/net/sgmii.c Thu Jan 24 15:14:22 2013 (r245881) @@ -69,13 +69,6 @@ nlm_configure_sgmii_interface(uint64_t n void nlm_sgmii_pcs_init(uint64_t nae_base, uint32_t cplx_mask) { - /* reset internal MDIO */ - nlm_int_gmac_mdio_reset(nae_base, 0, BLOCK_7, LANE_CFG); - - /* reset external MDIO */ - nlm_gmac_mdio_reset(nae_base, 0, BLOCK_7, LANE_CFG); - nlm_gmac_mdio_reset(nae_base, 1, BLOCK_7, LANE_CFG); - xlp_nae_config_lane_gmac(nae_base, cplx_mask); } Modified: head/sys/mips/nlm/dev/net/xlpge.c ============================================================================== --- head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 14:42:58 2013 (r245880) +++ head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 15:14:22 2013 (r245881) @@ -444,6 +444,8 @@ nlm_xlpnae_init(int node, struct nlm_xlp val = nlm_set_device_frequency(node, DFS_DEVICE_NAE, sc->freq); printf("Setup NAE frequency to %dMHz\n", val); + nlm_mdio_reset_all(nae_base); + printf("Initialze SGMII PCS for blocks 0x%x\n", sc->sgmiimask); nlm_sgmii_pcs_init(nae_base, sc->sgmiimask); @@ -797,8 +799,9 @@ nlm_xlpge_ioctl(struct ifnet *ifp, u_lon if (ifp->if_flags & IFF_UP) { if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) nlm_xlpge_init(sc); - nlm_xlpge_mac_set_rx_mode(sc); - nlm_xlpge_port_enable(sc); + else + nlm_xlpge_port_enable(sc); + nlm_xlpge_mac_set_rx_mode(sc); sc->link = NLM_LINK_UP; } else { if (ifp->if_drv_flags & IFF_DRV_RUNNING) @@ -1288,6 +1291,7 @@ nlm_xlpge_attach(device_t dev) nlm_xlpge_ifinit(sc); ifp_ports[port].xlpge_sc = sc; nlm_xlpge_mii_init(dev, sc); + nlm_xlpge_setup_stats_sysctl(dev, sc); return (0); @@ -1385,7 +1389,7 @@ nlm_xlpge_mii_statchg(device_t dev) sc->block, sc->port, speed, duplexity); nlm_nae_setup_mac(sc->base_addr, sc->block, sc->port, 0, 1, 1, - sc->speed, sc->duplexity); + sc->speed, sc->duplexity); } } Modified: head/sys/mips/nlm/hal/mdio.h ============================================================================== --- head/sys/mips/nlm/hal/mdio.h Thu Jan 24 14:42:58 2013 (r245880) +++ head/sys/mips/nlm/hal/mdio.h Thu Jan 24 15:14:22 2013 (r245881) @@ -100,6 +100,7 @@ int nlm_int_gmac_mdio_reset(uint64_t, in int nlm_gmac_mdio_read(uint64_t, int, int, int, int, int); int nlm_gmac_mdio_write(uint64_t, int, int, int, int, int, uint16_t); int nlm_gmac_mdio_reset(uint64_t, int, int, int); +void nlm_mdio_reset_all(uint64_t); #endif /* !(LOCORE) && !(__ASSEMBLY__) */ #endif From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 15:18:42 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 89D316C6; Thu, 24 Jan 2013 15:18:42 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 762DEEB2; Thu, 24 Jan 2013 15:18:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OFIgB7081068; Thu, 24 Jan 2013 15:18:42 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OFIg15081067; Thu, 24 Jan 2013 15:18:42 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241518.r0OFIg15081067@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 15:18:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245882 - head/gnu/usr.bin/cc/c++ X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 15:18:42 -0000 Author: brooks Date: Thu Jan 24 15:18:41 2013 New Revision: 245882 URL: http://svnweb.freebsd.org/changeset/base/245882 Log: Reorder so that NO_MAN is declared before bsd.own.mk is included and thus has an effect (not installed a g++.1 manpage over the g++.1(.gz) link created in ../cc). Modified: head/gnu/usr.bin/cc/c++/Makefile Modified: head/gnu/usr.bin/cc/c++/Makefile ============================================================================== --- head/gnu/usr.bin/cc/c++/Makefile Thu Jan 24 15:14:22 2013 (r245881) +++ head/gnu/usr.bin/cc/c++/Makefile Thu Jan 24 15:18:41 2013 (r245882) @@ -1,7 +1,5 @@ # $FreeBSD$ -.include - .include "../Makefile.inc" .include "../Makefile.fe" @@ -9,13 +7,16 @@ PROG= g++ SRCS+= g++spec.c -.if ${MK_CLANG_IS_CC} == "no" -LINKS= ${BINDIR}/g++ ${BINDIR}/c++ -LINKS+= ${BINDIR}/g++ ${BINDIR}/CC -.endif NO_MAN= DPADD= ${LIBCPP} ${LIBIBERTY} LDADD= ${LIBCPP} ${LIBIBERTY} +.include + +.if ${MK_CLANG_IS_CC} == "no" +LINKS= ${BINDIR}/g++ ${BINDIR}/c++ +LINKS+= ${BINDIR}/g++ ${BINDIR}/CC +.endif + .include From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 15:23:02 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 925F58DA; Thu, 24 Jan 2013 15:23:02 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6CE5EEF4; Thu, 24 Jan 2013 15:23:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OFN2Y5083241; Thu, 24 Jan 2013 15:23:02 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OFN2OZ083239; Thu, 24 Jan 2013 15:23:02 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241523.r0OFN2OZ083239@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 15:23:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245883 - head/sys/mips/nlm/hal X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 15:23:02 -0000 Author: jchandra Date: Thu Jan 24 15:23:01 2013 New Revision: 245883 URL: http://svnweb.freebsd.org/changeset/base/245883 Log: Fix credit configuration on Broadcom XLP CMS The CMS output queue credit configuration register is 64 bit, so use a 64 bit variable while updating it. Obtained from: Venkatesh J V Modified: head/sys/mips/nlm/hal/fmn.c Modified: head/sys/mips/nlm/hal/fmn.c ============================================================================== --- head/sys/mips/nlm/hal/fmn.c Thu Jan 24 15:18:41 2013 (r245882) +++ head/sys/mips/nlm/hal/fmn.c Thu Jan 24 15:23:01 2013 (r245883) @@ -138,9 +138,9 @@ uint32_t nlm_cms_total_stations = 18 * 4 void nlm_cms_setup_credits(uint64_t base, int destid, int srcid, int credit) { - uint32_t val; + uint64_t val; - val = ((credit << 24) | (destid << 12) | (srcid << 0)); + val = (((uint64_t)credit << 24) | (destid << 12) | (srcid << 0)); nlm_write_cms_reg(base, CMS_OUTPUTQ_CREDIT_CFG, val); } From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 15:49:48 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0B258E3; Thu, 24 Jan 2013 15:49:48 +0000 (UTC) (envelope-from jchandra@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F015EDA; Thu, 24 Jan 2013 15:49:47 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OFnlIF089872; Thu, 24 Jan 2013 15:49:47 GMT (envelope-from jchandra@svn.freebsd.org) Received: (from jchandra@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OFnlk8089870; Thu, 24 Jan 2013 15:49:47 GMT (envelope-from jchandra@svn.freebsd.org) Message-Id: <201301241549.r0OFnlk8089870@svn.freebsd.org> From: "Jayachandran C." Date: Thu, 24 Jan 2013 15:49:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245884 - in head/sys/mips/nlm: dev/net hal X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 15:49:48 -0000 Author: jchandra Date: Thu Jan 24 15:49:47 2013 New Revision: 245884 URL: http://svnweb.freebsd.org/changeset/base/245884 Log: Little-endian and other fixes for Broadcom XLP network driver The changes are: - the microcore code loaded into the NAE has to be byteswapped in LE - the descriptors in memory for a P2P NAE descriptor has to be byteswapped in LE - the m_data pointer is already cacheline aligned, so the unnecessary m_adj to cacheline size can be removed - fix mask used to obtain physical address from the Tx freeback descriptor - fix a compile error in code under #ifdef Obtained from: Venkatesh J V Modified: head/sys/mips/nlm/dev/net/xlpge.c head/sys/mips/nlm/hal/ucore_loader.h Modified: head/sys/mips/nlm/dev/net/xlpge.c ============================================================================== --- head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 15:23:01 2013 (r245883) +++ head/sys/mips/nlm/dev/net/xlpge.c Thu Jan 24 15:49:47 2013 (r245884) @@ -869,6 +869,7 @@ xlpge_tx(struct ifnet *ifp, struct mbuf vm_offset_t buf = (vm_offset_t) m->m_data; int len = m->m_len; int frag_sz; + uint64_t desc; /*printf("m_data = %p len %d\n", m->m_data, len); */ while (len) { @@ -883,8 +884,9 @@ xlpge_tx(struct ifnet *ifp, struct mbuf frag_sz = PAGE_SIZE - (buf & PAGE_MASK); if (len < frag_sz) frag_sz = len; - p2p->frag[pos] = nae_tx_desc(P2D_NEOP, 0, 127, + desc = nae_tx_desc(P2D_NEOP, 0, 127, frag_sz, paddr); + p2p->frag[pos] = htobe64(desc); pos++; len -= frag_sz; buf += frag_sz; @@ -894,7 +896,7 @@ xlpge_tx(struct ifnet *ifp, struct mbuf KASSERT(pos != 0, ("Zero-length mbuf chain?\n")); /* Make the last one P2D EOP */ - p2p->frag[pos-1] |= (uint64_t)P2D_EOP << 62; + p2p->frag[pos-1] |= htobe64((uint64_t)P2D_EOP << 62); /* stash useful pointers in the desc */ p2p->frag[XLP_NTXFRAGS-3] = 0xf00bad; @@ -1131,7 +1133,8 @@ get_buf(void) if ((m_new = m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR)) == NULL) return (NULL); m_new->m_len = m_new->m_pkthdr.len = MCLBYTES; - m_adj(m_new, NAE_CACHELINE_SIZE - ((uintptr_t)m_new->m_data & 0x1f)); + KASSERT(((uintptr_t)m_new->m_data & (NAE_CACHELINE_SIZE - 1)) == 0, + ("m_new->m_data is not cacheline aligned")); md = (uint64_t *)m_new->m_data; md[0] = (intptr_t)m_new; /* Back Ptr */ md[1] = 0xf00bad; @@ -1140,10 +1143,9 @@ get_buf(void) #ifdef INVARIANTS temp1 = vtophys((vm_offset_t) m_new->m_data); temp2 = vtophys((vm_offset_t) m_new->m_data + 1536); - KASSERT(temp1 + 1536) != temp2, + KASSERT((temp1 + 1536) != temp2, ("Alloced buffer is not contiguous")); #endif - return ((void *)m_new->m_data); } @@ -1552,7 +1554,7 @@ nlm_xlpge_msgring_handler(int vc, int si ifp->if_opackets++; } else if (size > 1) { /* Recieve packet */ - phys_addr = msg->msg[1] & 0xffffffffe0ULL; + phys_addr = msg->msg[1] & 0xffffffffc0ULL; length = (msg->msg[1] >> 40) & 0x3fff; length -= MAC_CRC_LEN; Modified: head/sys/mips/nlm/hal/ucore_loader.h ============================================================================== --- head/sys/mips/nlm/hal/ucore_loader.h Thu Jan 24 15:23:01 2013 (r245883) +++ head/sys/mips/nlm/hal/ucore_loader.h Thu Jan 24 15:49:47 2013 (r245884) @@ -49,7 +49,7 @@ nlm_ucore_load_image(uint64_t nae_base, size = sizeof(ucore_app_bin)/sizeof(uint32_t); for (i = 0; i < size; i++, addr += 4) - nlm_store_word_daddr(addr, p[i]); + nlm_store_word_daddr(addr, htobe32(p[i])); /* add a 'nop' if number of instructions are odd */ if (size & 0x1) From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 15:55:25 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 090ED401; Thu, 24 Jan 2013 15:55:25 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EE207141; Thu, 24 Jan 2013 15:55:24 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OFtOVU092267; Thu, 24 Jan 2013 15:55:24 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OFtOpv092266; Thu, 24 Jan 2013 15:55:24 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241555.r0OFtOpv092266@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 15:55:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245885 - head/share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 15:55:25 -0000 Author: brooks Date: Thu Jan 24 15:55:24 2013 New Revision: 245885 URL: http://svnweb.freebsd.org/changeset/base/245885 Log: Don't declare an dependency on _maninstall when LIBRARIES_ONLY is set. It doesn't exist. Modified: head/share/mk/bsd.lib.mk Modified: head/share/mk/bsd.lib.mk ============================================================================== --- head/share/mk/bsd.lib.mk Thu Jan 24 15:49:47 2013 (r245884) +++ head/share/mk/bsd.lib.mk Thu Jan 24 15:55:24 2013 (r245885) @@ -339,7 +339,7 @@ _libinstall: .include -.if ${MK_MAN} != "no" +.if ${MK_MAN} != "no" && !defined(LIBRARIES_ONLY) realinstall: _maninstall .ORDER: beforeinstall _maninstall .endif From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 16:28:37 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id E173F25F; Thu, 24 Jan 2013 16:28:37 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CA53F35D; Thu, 24 Jan 2013 16:28:37 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OGSbNi001963; Thu, 24 Jan 2013 16:28:37 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OGSb7v001962; Thu, 24 Jan 2013 16:28:37 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241628.r0OGSb7v001962@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 16:28:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245886 - head/include/arpa X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 16:28:38 -0000 Author: brooks Date: Thu Jan 24 16:28:37 2013 New Revision: 245886 URL: http://svnweb.freebsd.org/changeset/base/245886 Log: Don't install telnet.h if it will be installed by libtelnet. Modified: head/include/arpa/Makefile Modified: head/include/arpa/Makefile ============================================================================== --- head/include/arpa/Makefile Thu Jan 24 15:55:24 2013 (r245885) +++ head/include/arpa/Makefile Thu Jan 24 16:28:37 2013 (r245886) @@ -1,7 +1,12 @@ # $FreeBSD$ +.include + NO_OBJ= -INCS= ftp.h inet.h nameser.h nameser_compat.h telnet.h tftp.h +INCS= ftp.h inet.h nameser.h nameser_compat.h tftp.h +.if ${MK_TELNET} == "NO" +INCS+= telnet.h +.endif INCSDIR=${INCLUDEDIR}/arpa .include From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 16:38:49 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 279EE610; Thu, 24 Jan 2013 16:38:49 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0A3C8403; Thu, 24 Jan 2013 16:38:49 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OGcm7j004893; Thu, 24 Jan 2013 16:38:48 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OGcmN7004886; Thu, 24 Jan 2013 16:38:48 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241638.r0OGcmN7004886@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 16:38:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245887 - in head/lib/ncurses: form menu ncurses panel X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 16:38:49 -0000 Author: brooks Date: Thu Jan 24 16:38:47 2013 New Revision: 245887 URL: http://svnweb.freebsd.org/changeset/base/245887 Log: Only install manpages and html documentation in the ncurses/*w (wchar) builds so that it is only installed once. This is consistent with the existing decision to only install headers in the that case. Modified: head/lib/ncurses/form/Makefile head/lib/ncurses/menu/Makefile head/lib/ncurses/ncurses/Makefile head/lib/ncurses/panel/Makefile Modified: head/lib/ncurses/form/Makefile ============================================================================== --- head/lib/ncurses/form/Makefile Thu Jan 24 16:28:37 2013 (r245886) +++ head/lib/ncurses/form/Makefile Thu Jan 24 16:38:47 2013 (r245887) @@ -59,7 +59,6 @@ LDADD= -lncurses${LIB_SUFFIX} .if defined(ENABLE_WIDEC) INCS= form.h -.endif .PATH: ${NCURSES_DIR}/man MAN= \ @@ -157,6 +156,9 @@ MLINKS= form_cursor.3 pos_form_cursor.3 form_win.3 scale_form.3 \ form_win.3 set_form_sub.3 \ form_win.3 set_form_win.3 +.else +NO_MAN= +.endif .include Modified: head/lib/ncurses/menu/Makefile ============================================================================== --- head/lib/ncurses/menu/Makefile Thu Jan 24 16:28:37 2013 (r245886) +++ head/lib/ncurses/menu/Makefile Thu Jan 24 16:38:47 2013 (r245887) @@ -45,7 +45,6 @@ LDADD= -lncurses${LIB_SUFFIX} .if defined(ENABLE_WIDEC) INCS= menu.h eti.h -.endif .PATH: ${NCURSES_DIR}/man MAN= \ @@ -130,6 +129,9 @@ MLINKS= menu_attributes.3 menu_back.3 \ mitem_value.3 item_value.3 \ mitem_value.3 set_item_value.3 \ mitem_visible.3 item_visible.3 +.else +NO_MAN= +.endif .include Modified: head/lib/ncurses/ncurses/Makefile ============================================================================== --- head/lib/ncurses/ncurses/Makefile Thu Jan 24 16:28:37 2013 (r245886) +++ head/lib/ncurses/ncurses/Makefile Thu Jan 24 16:38:47 2013 (r245887) @@ -2,6 +2,10 @@ SHLIBDIR?= /lib +.if !defined(ENABLE_WIDEC) +NO_MAN= +.endif + .include .include "${.CURDIR}/../config.mk" @@ -304,8 +308,10 @@ SYMLINKS+= libncurses${LIB_SUFFIX}_p.a $ SYMLINKS+= libncurses${LIB_SUFFIX}_p.a ${LIBDIR}/libtinfo${LIB_SUFFIX}_p.a .endif +.if defined(ENABLE_WIDEC) DOCSDIR= ${SHAREDIR}/doc/ncurses DOCS= ncurses-intro.html hackguide.html +.endif .if ${MK_HTML} != "no" .PATH: ${NCURSES_DIR}/doc/html @@ -457,6 +463,7 @@ terminfo.5: MKterminfo.sh terminfo.head CLEANFILES+= terminfo.5 +.if defined(ENABLE_WIDEC) .PATH: ${NCURSES_DIR}/man MAN= \ curs_addch.3 \ @@ -517,7 +524,6 @@ MAN= \ resizeterm.3 \ wresize.3 -.if defined(ENABLE_WIDEC) MAN+= \ curs_add_wch.3 \ curs_add_wchstr.3 \ Modified: head/lib/ncurses/panel/Makefile ============================================================================== --- head/lib/ncurses/panel/Makefile Thu Jan 24 16:28:37 2013 (r245886) +++ head/lib/ncurses/panel/Makefile Thu Jan 24 16:38:47 2013 (r245887) @@ -34,7 +34,6 @@ LDADD= -lncurses${LIB_SUFFIX} .if defined(ENABLE_WIDEC) INCS= panel.h -.endif # generate MAN .PATH: ${NCURSES_DIR}/man @@ -58,6 +57,9 @@ MLINKS= panel.3 bottom_panel.3 \ panel.3 show_panel.3 \ panel.3 top_panel.3 \ panel.3 update_panels.3 +.else +NO_MAN= +.endif .include From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 16:53:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 288D79D6; Thu, 24 Jan 2013 16:53:36 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 118ED6F0; Thu, 24 Jan 2013 16:53:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OGrZ9d009992; Thu, 24 Jan 2013 16:53:35 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OGrZ24009991; Thu, 24 Jan 2013 16:53:35 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241653.r0OGrZ24009991@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 16:53:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245888 - head/usr.bin/ee X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 16:53:36 -0000 Author: brooks Date: Thu Jan 24 16:53:35 2013 New Revision: 245888 URL: http://svnweb.freebsd.org/changeset/base/245888 Log: Install the NLS catalog in the C directory rather than en_US.US-ASCII which is a link to C. This allow the makefs mtree manifest mode to find the file. Modified: head/usr.bin/ee/Makefile Modified: head/usr.bin/ee/Makefile ============================================================================== --- head/usr.bin/ee/Makefile Thu Jan 24 16:38:47 2013 (r245887) +++ head/usr.bin/ee/Makefile Thu Jan 24 16:53:35 2013 (r245888) @@ -13,7 +13,7 @@ LDADD= -lncurses WARNS?= 2 -NLS= en_US.US-ASCII fr_FR.ISO8859-1 de_DE.ISO8859-1 pl_PL.ISO8859-2 \ +NLS= C fr_FR.ISO8859-1 de_DE.ISO8859-1 pl_PL.ISO8859-2 \ uk_UA.KOI8-U pt_BR.ISO8859-1 ru_RU.KOI8-R hu_HU.ISO8859-2 NLSLINKS_en_US.US-ASCII= en_US.ISO8859-1 en_US.ISO8859-15 From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 17:00:12 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 25919CBF; Thu, 24 Jan 2013 17:00:12 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F3FFC768; Thu, 24 Jan 2013 17:00:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OH0BrP010973; Thu, 24 Jan 2013 17:00:11 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OH0Bsc010969; Thu, 24 Jan 2013 17:00:11 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241700.r0OH0Bsc010969@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 17:00:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245889 - in head/share: monetdef msgdef numericdef X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 17:00:12 -0000 Author: brooks Date: Thu Jan 24 17:00:11 2013 New Revision: 245889 URL: http://svnweb.freebsd.org/changeset/base/245889 Log: Don't link two different things to the same paths. As tiebreaker I've picked the link that was installed last so as to not change the behavior. The one exception is sr_YU.ISO8859-2/LC_MONETARY where a file was being replaced by a link. Modified: head/share/monetdef/Makefile head/share/msgdef/Makefile head/share/numericdef/Makefile Modified: head/share/monetdef/Makefile ============================================================================== --- head/share/monetdef/Makefile Thu Jan 24 16:53:35 2013 (r245888) +++ head/share/monetdef/Makefile Thu Jan 24 17:00:11 2013 (r245889) @@ -110,11 +110,11 @@ ISO8859-1_ISO8859-15= af_ZA ca_AD ca_ES fi_FI fr_BE fr_CA fr_CH fr_FR \ is_IS it_IT it_CH nl_BE nl_NL nb_NO nn_NO no_NO sv_SE ISO8859-1_US-ASCII= en_AU en_CA en_GB en_NZ en_US -ISO8859-1_UTF-8= af_ZA ca_AD ca_ES ca_FR ca_IT da_DK de_AT de_CH de_DE \ +ISO8859-1_UTF-8= af_ZA ca_ES da_DK de_AT de_CH de_DE \ en_AU en_CA en_NZ en_US es_ES \ fi_FI fr_BE fr_CA fr_FR is_IS it_IT nl_BE \ nl_NL nb_NO nn_NO no_NO pt_BR sv_SE -ISO8859-2_UTF-8= hr_HR hu_HU ro_RO sk_SK sl_SI sr_YU +ISO8859-2_UTF-8= hr_HR hu_HU ro_RO sk_SK sl_SI ISO8859-7_UTF-8= el_GR ISO8859-9_UTF-8= tr_TR ISO8859-13_ISO8859-4= lt_LT Modified: head/share/msgdef/Makefile ============================================================================== --- head/share/msgdef/Makefile Thu Jan 24 16:53:35 2013 (r245888) +++ head/share/msgdef/Makefile Thu Jan 24 17:00:11 2013 (r245889) @@ -112,7 +112,7 @@ ISO8859-1_ISO8859-15= af_ZA ca_ES da_DK ${NL_LINKS} ${NO_LINKS} ISO8859-1_US-ASCII= ${GB_LINKS} en_CA en_GB en_US ISO8859-1_UTF-8= af_ZA ca_ES da_DK de_DE en_CA en_GB en_US es_ES eu_ES \ - fi_FI fr_BE fr_CH fr_FR is_IS it_IT nb_NO nl_NL nn_NO no_NO \ + fi_FI fr_BE fr_CH fr_FR is_IS it_IT nl_NL no_NO \ pt_PT sv_SE ISO8859-2_ISO8859-2= ${CZ_LINKS} ISO8859-2_UTF-8= cs_CZ hr_HR hu_HU pl_PL ro_RO sl_SI Modified: head/share/numericdef/Makefile ============================================================================== --- head/share/numericdef/Makefile Thu Jan 24 16:53:35 2013 (r245888) +++ head/share/numericdef/Makefile Thu Jan 24 17:00:11 2013 (r245889) @@ -93,7 +93,7 @@ eucJP_UTF-8= ja_JP eucKR_CP949= ko_KR eucKR_UTF-8= ko_KR ISO8859-1_ISO8859-15= af_ZA ca_ES da_DK de_CH de_DE en_US es_ES eu_ES \ - fi_FI fr_BE fr_FR is_IS it_CH it_IT nl_NL no_NO pt_PT sv_SE \ + fi_FI fr_BE fr_FR is_IS it_IT nl_NL no_NO pt_PT sv_SE \ ${BE_LINKS} ${CA_LINKS} ${DE_LINKS} ${FR_LINKS} ${GB_LINKS} \ ${IT_LINKS} ${NO_LINKS} ${US_LINKS} ISO8859-1_ISO8859-1= ${BE_LINKS} ${CA_LINKS} ${DE_LINKS} ${FR_LINKS} \ From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 17:12:03 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1C18D374; Thu, 24 Jan 2013 17:12:03 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0EFFD827; Thu, 24 Jan 2013 17:12:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OHC2TX016078; Thu, 24 Jan 2013 17:12:02 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OHC2Jn016077; Thu, 24 Jan 2013 17:12:02 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301241712.r0OHC2Jn016077@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 17:12:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245890 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 17:12:03 -0000 Author: brooks Date: Thu Jan 24 17:12:02 2013 New Revision: 245890 URL: http://svnweb.freebsd.org/changeset/base/245890 Log: Strip any trailing slash off of the -D argument to install to support the rather fragile destdir stripping in the metalog. Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Thu Jan 24 17:00:11 2013 (r245889) +++ head/Makefile.inc1 Thu Jan 24 17:12:02 2013 (r245890) @@ -368,7 +368,7 @@ MTREEFLAGS+= -N ${.CURDIR}/etc METALOG?= ${DESTDIR}/${DISTDIR}/METALOG IMAKE+= -DNO_ROOT METALOG=${METALOG} INSTALL_DDIR= ${DESTDIR}/${DISTDIR} -INSTALLFLAGS+= -U -M ${METALOG} -D ${INSTALL_DDIR:S://:/:g} +INSTALLFLAGS+= -U -M ${METALOG} -D ${INSTALL_DDIR:S://:/:g:C:/$::} MTREEFLAGS+= -W .endif .if defined(DB_FROM_SRC) || defined(NO_ROOT) From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 17:28:39 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id AF03488B; Thu, 24 Jan 2013 17:28:39 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id A1BDD8F7; Thu, 24 Jan 2013 17:28:39 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OHSd6W019792; Thu, 24 Jan 2013 17:28:39 GMT (envelope-from jh@svn.freebsd.org) Received: (from jh@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OHSdKg019791; Thu, 24 Jan 2013 17:28:39 GMT (envelope-from jh@svn.freebsd.org) Message-Id: <201301241728.r0OHSdKg019791@svn.freebsd.org> From: Jaakko Heinonen Date: Thu, 24 Jan 2013 17:28:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245891 - head/sys/cam/scsi X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 17:28:39 -0000 Author: jh Date: Thu Jan 24 17:28:39 2013 New Revision: 245891 URL: http://svnweb.freebsd.org/changeset/base/245891 Log: Sanitize the element descriptor string before using it as a device name. Reported and tested by: Vitalij Satanivskij Reviewed by: gibbs, mav Modified: head/sys/cam/scsi/scsi_enc_ses.c Modified: head/sys/cam/scsi/scsi_enc_ses.c ============================================================================== --- head/sys/cam/scsi/scsi_enc_ses.c Thu Jan 24 17:12:02 2013 (r245890) +++ head/sys/cam/scsi/scsi_enc_ses.c Thu Jan 24 17:28:39 2013 (r245891) @@ -36,6 +36,7 @@ __FBSDID("$FreeBSD$"); #include +#include #include #include #include @@ -1053,10 +1054,11 @@ ses_set_physpath(enc_softc_t *enc, enc_e { struct ccb_dev_advinfo cdai; ses_setphyspath_callback_args_t args; - int ret; + int i, ret; struct sbuf sb; uint8_t *devid, *elmaddr; ses_element_t *elmpriv; + const char *c; ret = EIO; devid = NULL; @@ -1099,7 +1101,13 @@ ses_set_physpath(enc_softc_t *enc, enc_e elmpriv = elm->elm_private; if (elmpriv->descr != NULL && elmpriv->descr_len > 0) { sbuf_cat(&sb, "/elmdesc@"); - sbuf_bcat(&sb, elmpriv->descr, elmpriv->descr_len); + for (i = 0, c = elmpriv->descr; i < elmpriv->descr_len; + i++, c++) { + if (!isprint(*c) || isspace(*c) || *c == '/') + sbuf_putc(&sb, '_'); + else + sbuf_putc(&sb, *c); + } } sbuf_finish(&sb); From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 20:47:38 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 403407B9; Thu, 24 Jan 2013 20:47:38 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 335F0617; Thu, 24 Jan 2013 20:47:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0OKlcAl079020; Thu, 24 Jan 2013 20:47:38 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0OKlcAO079019; Thu, 24 Jan 2013 20:47:38 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301242047.r0OKlcAO079019@svn.freebsd.org> From: Brooks Davis Date: Thu, 24 Jan 2013 20:47:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245893 - head/tools X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 20:47:38 -0000 Author: brooks Date: Thu Jan 24 20:47:37 2013 New Revision: 245893 URL: http://svnweb.freebsd.org/changeset/base/245893 Log: Use = not == in test arguments. Submitted by: Christoph Mallon Modified: head/tools/install.sh Modified: head/tools/install.sh ============================================================================== --- head/tools/install.sh Thu Jan 24 19:09:38 2013 (r245892) +++ head/tools/install.sh Thu Jan 24 20:47:37 2013 (r245893) @@ -62,7 +62,7 @@ fi # the remaining arguments are assumed to be files/dirs only. if [ -n "${linkmode}" ]; then - if [ "${linkmode}" == "symbolic" ]; then + if [ "${linkmode}" = "symbolic" ]; then ln -fsh "$@" else ln -f "$@" From owner-svn-src-head@FreeBSD.ORG Thu Jan 24 23:11:52 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id D514AE08; Thu, 24 Jan 2013 23:11:52 +0000 (UTC) (envelope-from pluknet@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C3027D7B; Thu, 24 Jan 2013 23:11:52 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0ONBqGH023631; Thu, 24 Jan 2013 23:11:52 GMT (envelope-from pluknet@svn.freebsd.org) Received: (from pluknet@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0ONBqFE023628; Thu, 24 Jan 2013 23:11:52 GMT (envelope-from pluknet@svn.freebsd.org) Message-Id: <201301242311.r0ONBqFE023628@svn.freebsd.org> From: Sergey Kandaurov Date: Thu, 24 Jan 2013 23:11:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245894 - in head: share/man/man9 sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Jan 2013 23:11:52 -0000 Author: pluknet Date: Thu Jan 24 23:11:51 2013 New Revision: 245894 URL: http://svnweb.freebsd.org/changeset/base/245894 Log: Update and clarify comments regarding VFS op table initialization in the man page and its header counterpart. Submitted by: Christoph Mallon (initial version) Reviewed and further improved by: bde (previous version) All bugs are: mine Modified: head/share/man/man9/VFS_SET.9 head/sys/sys/mount.h Modified: head/share/man/man9/VFS_SET.9 ============================================================================== --- head/share/man/man9/VFS_SET.9 Thu Jan 24 20:47:37 2013 (r245893) +++ head/share/man/man9/VFS_SET.9 Thu Jan 24 23:11:51 2013 (r245894) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 22, 2012 +.Dd January 25, 2012 .Dt VFS_SET 9 .Os .Sh NAME @@ -84,7 +84,9 @@ sysctl is set to .Sh PSEUDOCODE .Bd -literal /* - * fill in the ones we use, and use the vfs_std for the rest. + * Fill in the ones we redefine. The unused fields will be + * automatically initialized by pointers to vfs_std* functions + * during file system registration. */ static struct vfsops myfs_vfsops = { .vfs_mount = myfs_mount, Modified: head/sys/sys/mount.h ============================================================================== --- head/sys/sys/mount.h Thu Jan 24 20:47:37 2013 (r245893) +++ head/sys/sys/mount.h Thu Jan 24 23:11:51 2013 (r245894) @@ -762,8 +762,9 @@ extern struct nfs_public nfs_pub; /* * Declarations for these vfs default operations are located in - * kern/vfs_default.c, they should be used instead of making "dummy" - * functions or casting entries in the VFS op table to "enopnotsupp()". + * kern/vfs_default.c. They will be automatically used to replace + * null entries in VFS ops tables when registering a new filesystem + * type in the global table. */ vfs_root_t vfs_stdroot; vfs_quotactl_t vfs_stdquotactl; From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 06:18:50 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 57467E0F; Fri, 25 Jan 2013 06:18:50 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 49C11F9F; Fri, 25 Jan 2013 06:18:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0P6IoVw050547; Fri, 25 Jan 2013 06:18:50 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0P6IoOj050546; Fri, 25 Jan 2013 06:18:50 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201301250618.r0P6IoOj050546@svn.freebsd.org> From: Andrew Turner Date: Fri, 25 Jan 2013 06:18:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245898 - head/gnu/usr.bin/cc/c++ X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 06:18:50 -0000 Author: andrew Date: Fri Jan 25 06:18:49 2013 New Revision: 245898 URL: http://svnweb.freebsd.org/changeset/base/245898 Log: bsd.own.mk needs to be included before Makefil.inc so MK_ARM_EABI is defined Modified: head/gnu/usr.bin/cc/c++/Makefile Modified: head/gnu/usr.bin/cc/c++/Makefile ============================================================================== --- head/gnu/usr.bin/cc/c++/Makefile Fri Jan 25 03:38:02 2013 (r245897) +++ head/gnu/usr.bin/cc/c++/Makefile Fri Jan 25 06:18:49 2013 (r245898) @@ -1,5 +1,8 @@ # $FreeBSD$ +NO_MAN= +.include + .include "../Makefile.inc" .include "../Makefile.fe" @@ -7,13 +10,10 @@ PROG= g++ SRCS+= g++spec.c -NO_MAN= DPADD= ${LIBCPP} ${LIBIBERTY} LDADD= ${LIBCPP} ${LIBIBERTY} -.include - .if ${MK_CLANG_IS_CC} == "no" LINKS= ${BINDIR}/g++ ${BINDIR}/c++ LINKS+= ${BINDIR}/g++ ${BINDIR}/CC From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 06:27:04 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 964F2261; Fri, 25 Jan 2013 06:27:04 +0000 (UTC) (envelope-from neel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 87F2DFF0; Fri, 25 Jan 2013 06:27:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0P6R4vl053216; Fri, 25 Jan 2013 06:27:04 GMT (envelope-from neel@svn.freebsd.org) Received: (from neel@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0P6R4Hx053215; Fri, 25 Jan 2013 06:27:04 GMT (envelope-from neel@svn.freebsd.org) Message-Id: <201301250627.r0P6R4Hx053215@svn.freebsd.org> From: Neel Natu Date: Fri, 25 Jan 2013 06:27:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245899 - head/usr.sbin/bhyve X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 06:27:04 -0000 Author: neel Date: Fri Jan 25 06:27:03 2013 New Revision: 245899 URL: http://svnweb.freebsd.org/changeset/base/245899 Log: Use the correct type (uint64_t) to retrieve sysctl machdep.tsc_freq. Simplify the function a bit by falling through after initialization and return via the normal code path. Reviewed by: grehan Obtained from: NetApp Modified: head/usr.sbin/bhyve/pmtmr.c Modified: head/usr.sbin/bhyve/pmtmr.c ============================================================================== --- head/usr.sbin/bhyve/pmtmr.c Fri Jan 25 06:18:49 2013 (r245898) +++ head/usr.sbin/bhyve/pmtmr.c Fri Jan 25 06:27:03 2013 (r245899) @@ -66,17 +66,14 @@ pmtmr_val(void) if (!inited) { size_t len; - uint32_t tmpf; inited = 1; pthread_mutex_init(&pmtmr_mtx, NULL); - len = sizeof(tmpf); - sysctlbyname("machdep.tsc_freq", &tmpf, &len, + len = sizeof(pmtmr_tscf); + sysctlbyname("machdep.tsc_freq", &pmtmr_tscf, &len, NULL, 0); - pmtmr_tscf = tmpf; pmtmr_tsc_old = rdtsc(); pmtmr_old = pmtmr_tsc_old / pmtmr_tscf * PMTMR_FREQ; - return (pmtmr_old); } pthread_mutex_lock(&pmtmr_mtx); From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 07:21:23 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A1770A77; Fri, 25 Jan 2013 07:21:23 +0000 (UTC) (envelope-from ganbold@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 929CF221; Fri, 25 Jan 2013 07:21:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0P7LNYI070231; Fri, 25 Jan 2013 07:21:23 GMT (envelope-from ganbold@svn.freebsd.org) Received: (from ganbold@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0P7LMSV070227; Fri, 25 Jan 2013 07:21:22 GMT (envelope-from ganbold@svn.freebsd.org) Message-Id: <201301250721.r0P7LMSV070227@svn.freebsd.org> From: Ganbold Tsagaankhuu Date: Fri, 25 Jan 2013 07:21:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245900 - in head/sys: arm/allwinner boot/fdt/dts X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 07:21:23 -0000 Author: ganbold (doc committer) Date: Fri Jan 25 07:21:22 2013 New Revision: 245900 URL: http://svnweb.freebsd.org/changeset/base/245900 Log: Fix method of naming compatible string to follow "," as described in http://www.devicetree.org/Device_Tree_Usage Reviewed by: andrew@ Approved by: gonzo@ Modified: head/sys/arm/allwinner/aintc.c head/sys/arm/allwinner/common.c head/sys/arm/allwinner/timer.c head/sys/boot/fdt/dts/cubieboard.dts Modified: head/sys/arm/allwinner/aintc.c ============================================================================== --- head/sys/arm/allwinner/aintc.c Fri Jan 25 06:27:03 2013 (r245899) +++ head/sys/arm/allwinner/aintc.c Fri Jan 25 07:21:22 2013 (r245900) @@ -97,7 +97,7 @@ static struct a10_aintc_softc *a10_aintc static int a10_aintc_probe(device_t dev) { - if (!ofw_bus_is_compatible(dev, "a10,aintc")) + if (!ofw_bus_is_compatible(dev, "allwinner,sun4i-ic")) return (ENXIO); device_set_desc(dev, "A10 AINTC Interrupt Controller"); return (BUS_PROBE_DEFAULT); Modified: head/sys/arm/allwinner/common.c ============================================================================== --- head/sys/arm/allwinner/common.c Fri Jan 25 06:27:03 2013 (r245899) +++ head/sys/arm/allwinner/common.c Fri Jan 25 07:21:22 2013 (r245900) @@ -47,7 +47,7 @@ static int fdt_aintc_decode_ic(phandle_t node, pcell_t *intr, int *interrupt, int *trig, int *pol) { - if (!fdt_is_compatible(node, "a10,aintc")) + if (!fdt_is_compatible(node, "allwinner,sun4i-ic")) return (ENXIO); *interrupt = fdt32_to_cpu(intr[0]); Modified: head/sys/arm/allwinner/timer.c ============================================================================== --- head/sys/arm/allwinner/timer.c Fri Jan 25 06:27:03 2013 (r245899) +++ head/sys/arm/allwinner/timer.c Fri Jan 25 07:21:22 2013 (r245900) @@ -141,7 +141,7 @@ static int a10_timer_probe(device_t dev) { - if (!ofw_bus_is_compatible(dev, "a10,timers")) + if (!ofw_bus_is_compatible(dev, "allwinner,sun4i-timer")) return (ENXIO); device_set_desc(dev, "Allwinner A10 timer"); Modified: head/sys/boot/fdt/dts/cubieboard.dts ============================================================================== --- head/sys/boot/fdt/dts/cubieboard.dts Fri Jan 25 06:27:03 2013 (r245899) +++ head/sys/boot/fdt/dts/cubieboard.dts Fri Jan 25 07:21:22 2013 (r245900) @@ -29,8 +29,8 @@ /dts-v1/; / { - model = "cubieboard"; - compatible = "cubieboard", "allwinner,a10"; + model = "Cubietech Cubieboard"; + compatible = "cubietech,a10-cubieboard", "allwinner,sun4i-a10"; #address-cells = <1>; #size-cells = <1>; @@ -54,7 +54,7 @@ bus-frequency = <0>; AINTC: interrupt-controller@01c20400 { - compatible = "a10,aintc"; + compatible = "allwinner,sun4i-ic"; interrupt-controller; #address-cells = <0>; #interrupt-cells = <1>; @@ -62,7 +62,7 @@ }; timer@01c20c00 { - compatible = "a10,timers"; + compatible = "allwinner,sun4i-timer"; reg = <0x01c20c00 0x90>; interrupts = < 22 >; interrupt-parent = <&AINTC>; @@ -70,14 +70,14 @@ }; usb1: usb@01c1c000 { - compatible = "a10,usb-ehci", "usb-ehci"; + compatible = "allwinner,usb-ehci", "usb-ehci"; reg = <0x01c1c000 0x1000>; interrupts = < 40 >; interrupt-parent = <&AINTC>; }; sata@01c18000 { - compatible = "a10,ahci"; + compatible = "allwinner,ahci"; reg = <0x01c18000 0x1000>; interrupts = <56>; interrupt-parent = <&AINTC>; From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 08:34:39 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1750EA45; Fri, 25 Jan 2013 08:34:39 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EC865707; Fri, 25 Jan 2013 08:34:38 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0P8YcA5091006; Fri, 25 Jan 2013 08:34:38 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0P8YcN6091005; Fri, 25 Jan 2013 08:34:38 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201301250834.r0P8YcN6091005@svn.freebsd.org> From: David Chisnall Date: Fri, 25 Jan 2013 08:34:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245901 - head/usr.bin/dtc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 08:34:39 -0000 Author: theraven Date: Fri Jan 25 08:34:38 2013 New Revision: 245901 URL: http://svnweb.freebsd.org/changeset/base/245901 Log: Fix style nit in dtc man page: sentences should start on new lines. Reported By: joel Modified: head/usr.bin/dtc/dtc.1 Modified: head/usr.bin/dtc/dtc.1 ============================================================================== --- head/usr.bin/dtc/dtc.1 Fri Jan 25 07:21:22 2013 (r245900) +++ head/usr.bin/dtc/dtc.1 Fri Jan 25 08:34:38 2013 (r245901) @@ -55,96 +55,113 @@ .Sh DESCRIPTION The .Nm -utility converts flattened device tree (FDT) representations. It is most -commonly used to generate device tree blobs (DTB), the binary representation of -an FDT, from device tree sources (DTS), the ASCII text source representation. -.Pp -The binary can be written in two formats, binary and assembly. The binary is -identical to the in-memory representation and can be used directly by firmware, -loaders, and so on. The assembly format, documented in +utility converts flattened device tree (FDT) representations. + It is most commonly used to generate device tree blobs (DTB), the binary +representation of an FDT, from device tree sources (DTS), the ASCII text source +representation. +.Pp +The binary can be written in two formats, binary and assembly. +The binary is identical to the in-memory representation and can be used +directly by firmware, loaders, and so on. +The assembly format, documented in .Sx "ASM FORMAT" , will produce the same binary format when assembled, but also includes some -global variables that refer to parts of the table. This format is most -commonly used to produce a kernel specific to a device, with the device tree -blob compiled in. +global variables that refer to parts of the table. +This format is most commonly used to produce a kernel specific to a device, +with the device tree blob compiled in. .Pp The options are as follows: .Bl -tag -width indent .It Fl d Ar dependency_file -Writes a dependency file understandable by make to the specified file. This -file can be included in a Makefile and will ensure that the output file depends -on the input file and any files that it includes. This argument is only useful -when the input is DTS, as only the source format has a notion of inclusions. +Writes a dependency file understandable by make to the specified file. +This file can be included in a Makefile and will ensure that the output file +depends on the input file and any files that it includes. +This argument is only useful when the input is DTS, as only the source format +has a notion of inclusions. .It Fl E Ar [no-]checker_name -Enable or disable a specified checker. The argument is the name of the -checker. The full list of checkers is given in +Enable or disable a specified checker. +The argument is the name of the checker. +The full list of checkers is given in .Sx CHECKERS . .It Fl f Force the tool to attempt to generate the output, even if the input had errors. .It Fl h Display the help text and exit. .It Fl H Ar phandle_format -Specifies the type of phandle nodes to generate in the output. Valid values -are: +Specifies the type of phandle nodes to generate in the output. +Valid values are: .Pp .Bl -tag -width indent -compact .It Ar linux Generate the legacy linux,phandle nodes expected by older systems. .It Ar epapr -Generate the phandle nodes, as described in the ePAPR specification. This is -the most sensible option for device trees being used with +Generate the phandle nodes, as described in the ePAPR specification. +This is the most sensible option for device trees being used with .Fx . .It Ar both Generate both, for maximum compatibility. .El .It Fl I Ar input_format -Specifies the input format. Valid values are: +Specifies the input format. +Valid values are: .Pp .Bl -tag -width indent -compact .It Ar dtb -Device tree blob. The binary representation of the FDT. +Device tree blob. +The binary representation of the FDT. .It Ar dts -Device tree source. The ASCII representation of the FDT. This is the default -if the input format is not explicitly stated. +Device tree source. +The ASCII representation of the FDT. +This is the default if the input format is not explicitly stated. .El .It Fl O Ar output_format -Specifies the output format. Valid values are: +Specifies the output format. +Valid values are: .Pp .Bl -tag -width indent -compact .It Ar asm Assembler source for generating a device tree blob, as described in .Sx "ASM FORMAT" . .It Ar dtb -Device tree blob. The binary representation of the FDT. This is the default -if the output format is not explicitly stated. +Device tree blob. +The binary representation of the FDT. +This is the default if the output format is not explicitly stated. .It Ar dts -Device tree source. The ASCII representation of the FDT. +Device tree source. +The ASCII representation of the FDT. .El .It Fl o Ar output_file The file to which to write the output. .It Fl R Ar entries -The number of empty reservation table entries to pad the table with. This is +The number of empty reservation table entries to pad the table with. +This is useful if you are generating a device tree blob for bootloader or similar that needs to reserve some memory before passing control to the operating system. .It Fl S Ar bytes -The minimum size in bytes of the blob. The blob will be padded after the -strings table to ensure that it is the correct size. This is useful for -environments where the device tree blob must be modified in place. +The minimum size in bytes of the blob. +The blob will be padded after the strings table to ensure that it is the +correct size. +This is useful for environments where the device tree blob must be modified in +place. .It Fl p Ar bytes -The number of bytes of padding to add to the blob. The blob will be padded -after the strings table to ensure that it is the correct size. This is useful -for environments where the device tree blob must be modified in place. +The number of bytes of padding to add to the blob. +The blob will be padded after the strings table to ensure that it is the +correct size. +This is useful for environments where the device tree blob must be modified in +place. .It Fl W Ar [no-]checker_name -Enable or disable a specified checker. This is an alias for +Enable or disable a specified checker. +This is an alias for .Fl E . .It Fl s -Sorts the properties and nodes in the tree. This is mainly useful when using -tools like +Sorts the properties and nodes in the tree. +This is mainly useful when using tools like .Xr diff 1 to compare two device tree sources. .It Fl V Ar output_version -The version of the format to output. This is only relevant for binary outputs, -and only a value of 17 is currently supported. +The version of the format to output. +This is only relevant for binary outputs, and only a value of 17 is currently +supported. .It Fl v Display the tool version and exit. .It Ar input_file @@ -152,8 +169,8 @@ The source file. .El .Sh "ASM FORMAT" The assembly format defines several globals that can be referred to from other -compilation units, in addition to any labels specified in the source. These -are: +compilation units, in addition to any labels specified in the source. +These are: .Pp .Bl -tag -width "dt_strings_start" -compact -offset indent .It dt_blob_start @@ -175,11 +192,14 @@ end of the device tree blob. .El .Sh CHECKERS The utility provides a number of semantic checks on the correctness of the -tree. These can be disabled with the +tree. +These can be disabled with the .Fl W -flag. For example, +flag. +For example, .Fl W Ar no-type-phandle -will disable the phandle type check. The supported checks are: +will disable the phandle type check. +The supported checks are: .Pp .Bl -tag -width "no-type-phandle" -compact -offset indent .It type-compatible @@ -204,7 +224,8 @@ will generate a .Pa blob.S file from the device tree source .Pa device.dts -and print errors if any occur during parsing or property checking. The +and print errors if any occur during parsing or property checking. +The resulting file can be assembled and linked into a binary. .Pp The command: @@ -213,16 +234,19 @@ The command: .Pp will write the device tree source for the device tree blob .Pa device.dtb -to the standard output. This is useful when debugging device trees. +to the standard output. +This is useful when debugging device trees. .Sh COMPATIBILITY This utility is intended to be compatible with the device tree compiler -provided by elinux.org. Currently, it implements the subset of features +provided by elinux.org. +Currently, it implements the subset of features required to build FreeBSD and others that have been requested by FreeBSD developers. .Pp The .Ar fs -input format is not supported. This builds a tree from a Linux +input format is not supported. +This builds a tree from a Linux .Pa /proc/device-tree , a file system hierarchy not found in FreeBSD, which instead exposes the DTB directly via a sysctl. @@ -249,12 +273,14 @@ specification, but is in fact a label. .El .Pp The /include/ directive is not part of the standard, however it is implemented -with the semantics compatible with the elinux.org tool. It must appear in the -top level of a file, and imports a new root definition. If a file, plus all of -its inclusions, contains multiple roots then they are merged. All nodes that -are present in the second but not the first are imported. Any that appear in -both are recursively merged, with properties from the second replacing those -from the first and properties child nodes being recursively merged. +with the semantics compatible with the elinux.org tool. +It must appear in the top level of a file, and imports a new root definition. +If a file, plus all of its inclusions, contains multiple roots then they are +merged. +All nodes that are present in the second but not the first are imported. +Any that appear in both are recursively merged, with properties from the second +replacing those from the first and properties child nodes being recursively +merged. .Sh HISTORY A dtc tool first appeared in .Fx 9.0 . @@ -270,11 +296,13 @@ The device tree compiler does not yet su .Pp .Bl -bullet -compact .It -Labels in the middle of property values. This is only useful in the assembly -output, and only vaguely useful there, so is unlikely to be added soon. +Labels in the middle of property values. +This is only useful in the assembly output, and only vaguely useful there, so +is unlikely to be added soon. .It -Full paths, rather than labels, as the targets for phandles. This is not very -hard to add, but will probably not be added until something actually needs it. +Full paths, rather than labels, as the targets for phandles. +This is not very hard to add, but will probably not be added until something +actually needs it. .El .Pp The current version performs a very limited set of semantic checks on the tree. From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 11:52:57 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2322F2E4; Fri, 25 Jan 2013 11:52:57 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F234436B; Fri, 25 Jan 2013 11:52:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PBquli056956; Fri, 25 Jan 2013 11:52:56 GMT (envelope-from glebius@svn.freebsd.org) Received: (from glebius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PBquVd056955; Fri, 25 Jan 2013 11:52:56 GMT (envelope-from glebius@svn.freebsd.org) Message-Id: <201301251152.r0PBquVd056955@svn.freebsd.org> From: Gleb Smirnoff Date: Fri, 25 Jan 2013 11:52:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245905 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 11:52:57 -0000 Author: glebius Date: Fri Jan 25 11:52:56 2013 New Revision: 245905 URL: http://svnweb.freebsd.org/changeset/base/245905 Log: In mbuf(9) API length is always integer. Thus, cast mbuf length constants to be integers. Reviewed by: bde Modified: head/sys/sys/mbuf.h Modified: head/sys/sys/mbuf.h ============================================================================== --- head/sys/sys/mbuf.h Fri Jan 25 11:51:28 2013 (r245904) +++ head/sys/sys/mbuf.h Fri Jan 25 11:52:56 2013 (r245905) @@ -52,11 +52,14 @@ * stored. Additionally, it is possible to allocate a separate buffer * externally and attach it to the mbuf in a way similar to that of mbuf * clusters. - */ -#define MLEN (MSIZE - sizeof(struct m_hdr)) /* normal data len */ -#define MHLEN (MLEN - sizeof(struct pkthdr)) /* data len w/pkthdr */ -#define MINCLSIZE (MHLEN + 1) /* smallest amount to put in cluster */ -#define M_MAXCOMPRESS (MHLEN / 2) /* max amount to copy for compression */ + * + * MLEN is data length in a normal mbuf. + * MHLEN is data length in an mbuf with pktheader. + * MINCLSIZE is a smallest amount of data that should be put into cluster. + */ +#define MLEN ((int)(MSIZE - sizeof(struct m_hdr))) +#define MHLEN ((int)(MLEN - sizeof(struct pkthdr))) +#define MINCLSIZE (MHLEN + 1) #ifdef _KERNEL /*- From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 14:40:55 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 2E2ABFEC; Fri, 25 Jan 2013 14:40:55 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 20D2AF23; Fri, 25 Jan 2013 14:40:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PEetfn007609; Fri, 25 Jan 2013 14:40:55 GMT (envelope-from dchagin@svn.freebsd.org) Received: (from dchagin@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PEesMq007608; Fri, 25 Jan 2013 14:40:54 GMT (envelope-from dchagin@svn.freebsd.org) Message-Id: <201301251440.r0PEesMq007608@svn.freebsd.org> From: Dmitry Chagin Date: Fri, 25 Jan 2013 14:40:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245908 - head/sys/compat/linux X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 14:40:55 -0000 Author: dchagin Date: Fri Jan 25 14:40:54 2013 New Revision: 245908 URL: http://svnweb.freebsd.org/changeset/base/245908 Log: Arithmetic on pointers takes into account the size of the type. Properly cast the pointer to avoid incorrect pointer scaling. MFC after: 1 Week Modified: head/sys/compat/linux/linux_futex.c Modified: head/sys/compat/linux/linux_futex.c ============================================================================== --- head/sys/compat/linux/linux_futex.c Fri Jan 25 14:36:17 2013 (r245907) +++ head/sys/compat/linux/linux_futex.c Fri Jan 25 14:40:54 2013 (r245908) @@ -1203,7 +1203,7 @@ release_futexes(struct proc *p) if (entry != pending) if (handle_futex_death(p, - (uint32_t *)entry + futex_offset, pi)) { + (uint32_t *)((caddr_t)entry + futex_offset), pi)) { LIN_SDT_PROBE0(futex, release_futexes, return); return; } @@ -1222,7 +1222,7 @@ release_futexes(struct proc *p) } if (pending) - handle_futex_death(p, (uint32_t *)pending + futex_offset, pip); + handle_futex_death(p, (uint32_t *)((caddr_t)pending + futex_offset), pip); LIN_SDT_PROBE0(futex, release_futexes, return); } From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 15:25:27 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0BF92E7C; Fri, 25 Jan 2013 15:25:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E3D2229C; Fri, 25 Jan 2013 15:25:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PFPQxL020349; Fri, 25 Jan 2013 15:25:26 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PFPPWA020342; Fri, 25 Jan 2013 15:25:25 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201301251525.r0PFPPWA020342@svn.freebsd.org> From: John Baldwin Date: Fri, 25 Jan 2013 15:25:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245909 - in head/sys: fs/nfs fs/nfsclient fs/nfsserver nfsclient X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 15:25:27 -0000 Author: jhb Date: Fri Jan 25 15:25:24 2013 New Revision: 245909 URL: http://svnweb.freebsd.org/changeset/base/245909 Log: Further cleanups to use of timestamps in NFS: - Use NFSD_MONOSEC (which maps to time_uptime) instead of the seconds portion of wall-time stamps to manage timeouts on events. - Remove unused nd_starttime from the per-request structure in the new NFS server. - Use nanotime() for the modification time on a delegation to get as precise a time as possible. - Use time_second instead of extracting the second from a call to getmicrotime(). Submitted by: bde (3) Reviewed by: bde, rmacklem MFC after: 2 weeks Modified: head/sys/fs/nfs/nfs.h head/sys/fs/nfs/nfs_commonkrpc.c head/sys/fs/nfs/nfsport.h head/sys/fs/nfsclient/nfs_clstate.c head/sys/fs/nfsserver/nfs_nfsdkrpc.c head/sys/fs/nfsserver/nfs_nfsdstate.c head/sys/nfsclient/nfs_krpc.c Modified: head/sys/fs/nfs/nfs.h ============================================================================== --- head/sys/fs/nfs/nfs.h Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfs/nfs.h Fri Jan 25 15:25:24 2013 (r245909) @@ -523,7 +523,6 @@ struct nfsrv_descript { int *nd_errp; /* Pointer to ret status */ u_int32_t nd_retxid; /* Reply xid */ struct nfsrvcache *nd_rp; /* Assoc. cache entry */ - struct timeval nd_starttime; /* Time RPC initiated */ fhandle_t nd_fh; /* File handle */ struct ucred *nd_cred; /* Credentials */ uid_t nd_saveduid; /* Saved uid */ Modified: head/sys/fs/nfs/nfs_commonkrpc.c ============================================================================== --- head/sys/fs/nfs/nfs_commonkrpc.c Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfs/nfs_commonkrpc.c Fri Jan 25 15:25:24 2013 (r245909) @@ -459,18 +459,17 @@ nfs_feedback(int type, int proc, void *a { struct nfs_feedback_arg *nf = (struct nfs_feedback_arg *) arg; struct nfsmount *nmp = nf->nf_mount; - struct timeval now; - - getmicrouptime(&now); + time_t now; switch (type) { case FEEDBACK_REXMIT2: case FEEDBACK_RECONNECT: - if (nf->nf_lastmsg + nmp->nm_tprintf_delay < now.tv_sec) { + now = NFSD_MONOSEC; + if (nf->nf_lastmsg + nmp->nm_tprintf_delay < now) { nfs_down(nmp, nf->nf_td, "not responding", 0, NFSSTA_TIMEO); nf->nf_tprintfmsg = TRUE; - nf->nf_lastmsg = now.tv_sec; + nf->nf_lastmsg = now; } break; @@ -501,7 +500,7 @@ newnfs_request(struct nfsrv_descript *nd u_int16_t procnum; u_int trylater_delay = 1; struct nfs_feedback_arg nf; - struct timeval timo, now; + struct timeval timo; AUTH *auth; struct rpc_callextra ext; enum clnt_stat stat; @@ -617,8 +616,7 @@ newnfs_request(struct nfsrv_descript *nd bzero(&nf, sizeof(struct nfs_feedback_arg)); nf.nf_mount = nmp; nf.nf_td = td; - getmicrouptime(&now); - nf.nf_lastmsg = now.tv_sec - + nf.nf_lastmsg = NFSD_MONOSEC - ((nmp->nm_tprintf_delay)-(nmp->nm_tprintf_initial_delay)); } Modified: head/sys/fs/nfs/nfsport.h ============================================================================== --- head/sys/fs/nfs/nfsport.h Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfs/nfsport.h Fri Jan 25 15:25:24 2013 (r245909) @@ -588,12 +588,6 @@ void nfsrvd_rcv(struct socket *, void *, #define NCHNAMLEN 9999999 /* - * Define these to use the time of day clock. - */ -#define NFSGETTIME(t) (getmicrotime(t)) -#define NFSGETNANOTIME(t) (getnanotime(t)) - -/* * These macros are defined to initialize and set the timer routine. */ #define NFS_TIMERINIT \ Modified: head/sys/fs/nfsclient/nfs_clstate.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clstate.c Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfsclient/nfs_clstate.c Fri Jan 25 15:25:24 2013 (r245909) @@ -2447,7 +2447,7 @@ nfscl_renewthread(struct nfsclclient *cl u_int32_t clidrev; int error, cbpathdown, islept, igotlock, ret, clearok; uint32_t recover_done_time = 0; - struct timespec mytime; + time_t mytime; static time_t prevsec = 0; struct nfscllockownerfh *lfhp, *nlfhp; struct nfscllockownerfhhead lfh; @@ -2720,9 +2720,9 @@ tryagain2: * Call nfscl_cleanupkext() once per second to check for * open/lock owners where the process has exited. */ - NFSGETNANOTIME(&mytime); - if (prevsec != mytime.tv_sec) { - prevsec = mytime.tv_sec; + mytime = NFSD_MONOSEC; + if (prevsec != mytime) { + prevsec = mytime; nfscl_cleanupkext(clp, &lfh); } @@ -4611,7 +4611,7 @@ nfscl_delegmodtime(vnode_t vp) } dp = nfscl_finddeleg(clp, np->n_fhp->nfh_fh, np->n_fhp->nfh_len); if (dp != NULL && (dp->nfsdl_flags & NFSCLDL_WRITE)) { - NFSGETNANOTIME(&dp->nfsdl_modtime); + nanotime(&dp->nfsdl_modtime); dp->nfsdl_flags |= NFSCLDL_MODTIMESET; } NFSUNLOCKCLSTATE(); Modified: head/sys/fs/nfsserver/nfs_nfsdkrpc.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdkrpc.c Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfsserver/nfs_nfsdkrpc.c Fri Jan 25 15:25:24 2013 (r245909) @@ -310,7 +310,6 @@ nfs_proc(struct nfsrv_descript *nd, u_in } else { isdgram = 1; } - NFSGETTIME(&nd->nd_starttime); /* * Two cases: Modified: head/sys/fs/nfsserver/nfs_nfsdstate.c ============================================================================== --- head/sys/fs/nfsserver/nfs_nfsdstate.c Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/fs/nfsserver/nfs_nfsdstate.c Fri Jan 25 15:25:24 2013 (r245909) @@ -3967,7 +3967,6 @@ nfsrv_setupstable(NFSPROC_T *p) int error, i, tryagain; off_t off = 0; ssize_t aresid, len; - struct timeval curtime; /* * If NFSNSF_UPDATEDONE is set, this is a restart of the nfsds without @@ -3978,8 +3977,7 @@ nfsrv_setupstable(NFSPROC_T *p) /* * Set Grace over just until the file reads successfully. */ - NFSGETTIME(&curtime); - nfsrvboottime = curtime.tv_sec; + nfsrvboottime = time_second; LIST_INIT(&sf->nsf_head); sf->nsf_flags = (NFSNSF_GRACEOVER | NFSNSF_NEEDLOCK); sf->nsf_eograce = NFSD_MONOSEC + NFSRV_LEASEDELTA; @@ -4650,8 +4648,7 @@ out: APPLESTATIC void nfsd_recalldelegation(vnode_t vp, NFSPROC_T *p) { - struct timespec mytime; - int32_t starttime; + time_t starttime; int error; /* @@ -4675,8 +4672,7 @@ nfsd_recalldelegation(vnode_t vp, NFSPRO * Now, call nfsrv_checkremove() in a loop while it returns * NFSERR_DELAY. Return upon any other error or when timed out. */ - NFSGETNANOTIME(&mytime); - starttime = (u_int32_t)mytime.tv_sec; + starttime = NFSD_MONOSEC; do { if (NFSVOPLOCK(vp, LK_EXCLUSIVE) == 0) { error = nfsrv_checkremove(vp, 0, p); @@ -4684,11 +4680,7 @@ nfsd_recalldelegation(vnode_t vp, NFSPRO } else error = EPERM; if (error == NFSERR_DELAY) { - NFSGETNANOTIME(&mytime); - if (((u_int32_t)mytime.tv_sec - starttime) > - NFS_REMOVETIMEO && - ((u_int32_t)mytime.tv_sec - starttime) < - 100000) + if (NFSD_MONOSEC - starttime > NFS_REMOVETIMEO) break; /* Sleep for a short period of time */ (void) nfs_catnap(PZERO, 0, "nfsremove"); @@ -4949,9 +4941,7 @@ nfsrv_notsamecredname(struct nfsrv_descr static time_t nfsrv_leaseexpiry(void) { - struct timeval curtime; - NFSGETTIME(&curtime); if (nfsrv_stablefirst.nsf_eograce > NFSD_MONOSEC) return (NFSD_MONOSEC + 2 * (nfsrv_lease + NFSRV_LEASEDELTA)); return (NFSD_MONOSEC + nfsrv_lease + NFSRV_LEASEDELTA); Modified: head/sys/nfsclient/nfs_krpc.c ============================================================================== --- head/sys/nfsclient/nfs_krpc.c Fri Jan 25 14:40:54 2013 (r245908) +++ head/sys/nfsclient/nfs_krpc.c Fri Jan 25 15:25:24 2013 (r245909) @@ -394,18 +394,17 @@ nfs_feedback(int type, int proc, void *a { struct nfs_feedback_arg *nf = (struct nfs_feedback_arg *) arg; struct nfsmount *nmp = nf->nf_mount; - struct timeval now; - - getmicrouptime(&now); + time_t now; switch (type) { case FEEDBACK_REXMIT2: case FEEDBACK_RECONNECT: - if (nf->nf_lastmsg + nmp->nm_tprintf_delay < now.tv_sec) { + now = time_uptime; + if (nf->nf_lastmsg + nmp->nm_tprintf_delay < now) { nfs_down(nmp, nf->nf_td, "not responding", 0, NFSSTA_TIMEO); nf->nf_tprintfmsg = TRUE; - nf->nf_lastmsg = now.tv_sec; + nf->nf_lastmsg = now; } break; @@ -438,7 +437,6 @@ nfs_request(struct vnode *vp, struct mbu time_t waituntil; caddr_t dpos; int error = 0, timeo; - struct timeval now; AUTH *auth = NULL; enum nfs_rto_timer_t timer; struct nfs_feedback_arg nf; @@ -455,8 +453,7 @@ nfs_request(struct vnode *vp, struct mbu bzero(&nf, sizeof(struct nfs_feedback_arg)); nf.nf_mount = nmp; nf.nf_td = td; - getmicrouptime(&now); - nf.nf_lastmsg = now.tv_sec - + nf.nf_lastmsg = time_uptime - ((nmp->nm_tprintf_delay) - (nmp->nm_tprintf_initial_delay)); /* From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 16:33:02 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0B80DE65; Fri, 25 Jan 2013 16:33:02 +0000 (UTC) (envelope-from wblock@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D9EB3927; Fri, 25 Jan 2013 16:33:01 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PGX1PA040755; Fri, 25 Jan 2013 16:33:01 GMT (envelope-from wblock@svn.freebsd.org) Received: (from wblock@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PGX15j040754; Fri, 25 Jan 2013 16:33:01 GMT (envelope-from wblock@svn.freebsd.org) Message-Id: <201301251633.r0PGX15j040754@svn.freebsd.org> From: Warren Block Date: Fri, 25 Jan 2013 16:33:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245910 - head/sbin/geom/class/part X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 16:33:02 -0000 Author: wblock (doc committer) Date: Fri Jan 25 16:33:00 2013 New Revision: 245910 URL: http://svnweb.freebsd.org/changeset/base/245910 Log: Expand description of how gptboot and gptzfsboot choose a partition for booting. Reviewed by: ae MFC after: 1 week Modified: head/sbin/geom/class/part/gpart.8 Modified: head/sbin/geom/class/part/gpart.8 ============================================================================== --- head/sbin/geom/class/part/gpart.8 Fri Jan 25 15:25:24 2013 (r245909) +++ head/sbin/geom/class/part/gpart.8 Fri Jan 25 16:33:00 2013 (r245910) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd January 3, 2013 +.Dd January 25, 2013 .Dt GPART 8 .Os .Sh NAME @@ -807,34 +807,51 @@ Both types of bootstrap code are used to First, a protective MBR is embedded into the first disk sector from the .Pa /boot/pmbr image. -It searches the GPT +It searches through the GPT for a .Cm freebsd-boot partition (see the .Sx "PARTITION TYPES" -section) in the GPT and runs the next bootstrap stage from it. +section) and runs the next bootstrap stage from it. The .Cm freebsd-boot partition should be smaller than 545 KB. +It can be located either before or after other +.Fx +partitions on the disk. There are two variants of bootstrap code to write to this partition: .Pa /boot/gptboot and .Pa /boot/gptzfsboot . .Pa /boot/gptboot is used to boot from UFS. -It searches +It searches through +.Cm freebsd-ufs +partitions in the GPT and boots from the first one with the +.Cm bootonce +attribute set. +If that attribute is not found, +.Pa /boot/gptboot +boots from the first .Cm freebsd-ufs -GPT partitions and starts +partition with the +.Cm bootme +attribute set. +If neither attribute is found, +.Pa /boot/gptboot +boots from the first +.Cm freebsd-ufs +partition. .Pa /boot/loader .Pq the third bootstrap stage -if found. -The +is loaded from the first partition that matches these conditions. .Pa /boot/gptzfsboot is used to boot from ZFS. -It searches +It searches through the GPT for .Cm freebsd-zfs -GPT partitions and starts +partitions, trying to detect ZFS pools. +After all pools are detected, .Pa /boot/zfsloader -if found. +is started from the first one found. .Pp The VTOC8 scheme does not support embedding bootstrap code. Instead, the 8 KBytes bootstrap code image @@ -945,7 +962,7 @@ The GEOM PART class can detect the same different GEOM providers, and some of them will be marked as corrupt. Be careful when choosing a provider for recovery. If you choose incorrectly you can destroy the metadata of another GEOM class, -e.g.\& GEOM MIRROR or GEOM LABEL. +e.g.,\& GEOM MIRROR or GEOM LABEL. .Sh SYSCTL VARIABLES The following .Xr sysctl 8 From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 16:49:45 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 1C2F74FF; Fri, 25 Jan 2013 16:49:45 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id C20429D5; Fri, 25 Jan 2013 16:49:43 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id SAA03311; Fri, 25 Jan 2013 18:49:41 +0200 (EET) (envelope-from avg@FreeBSD.org) Message-ID: <5102B7A5.7030105@FreeBSD.org> Date: Fri, 25 Jan 2013 18:49:41 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130113 Thunderbird/17.0.2 MIME-Version: 1.0 To: Warren Block Subject: Re: svn commit: r245910 - head/sbin/geom/class/part References: <201301251633.r0PGX15j040754@svn.freebsd.org> In-Reply-To: <201301251633.r0PGX15j040754@svn.freebsd.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 16:49:45 -0000 on 25/01/2013 18:33 Warren Block said the following: > +After all pools are detected, > .Pa /boot/zfsloader > -if found. > +is started from the first one found. Thank you for improving this documentation! I would further clarify the above snippet to the effect of saying that /boot/zfsloader is taken from a filesystem pointed to by bootfs property of that first pool. Or if bootfs is not set then from a filesystem in a root of the pool ("poolname"). Not sure how to express this logic properly and concisely. P.S. Just in case: http://ru.kyivbsd.org.ua/arhiv/2012/kyivbsd12-gapon-zfs.pdf?attredirects=0&d=1 Page 17 and on (ZFS Boot Process section). -- Andriy Gapon From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 17:40:11 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8FD792A5; Fri, 25 Jan 2013 17:40:11 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 816FBC48; Fri, 25 Jan 2013 17:40:11 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PHeBjK059337; Fri, 25 Jan 2013 17:40:11 GMT (envelope-from brooks@svn.freebsd.org) Received: (from brooks@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PHeBVQ059336; Fri, 25 Jan 2013 17:40:11 GMT (envelope-from brooks@svn.freebsd.org) Message-Id: <201301251740.r0PHeBVQ059336@svn.freebsd.org> From: Brooks Davis Date: Fri, 25 Jan 2013 17:40:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245911 - head/include/arpa X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 17:40:11 -0000 Author: brooks Date: Fri Jan 25 17:40:10 2013 New Revision: 245911 URL: http://svnweb.freebsd.org/changeset/base/245911 Log: MK_* variable should be compared to "no" not "NO". Submitted by: "b.f." Modified: head/include/arpa/Makefile Modified: head/include/arpa/Makefile ============================================================================== --- head/include/arpa/Makefile Fri Jan 25 16:33:00 2013 (r245910) +++ head/include/arpa/Makefile Fri Jan 25 17:40:10 2013 (r245911) @@ -4,7 +4,7 @@ NO_OBJ= INCS= ftp.h inet.h nameser.h nameser_compat.h tftp.h -.if ${MK_TELNET} == "NO" +.if ${MK_TELNET} == "no" INCS+= telnet.h .endif INCSDIR=${INCLUDEDIR}/arpa From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 18:47:17 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7C5CFC1; Fri, 25 Jan 2013 18:47:17 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 503168A; Fri, 25 Jan 2013 18:47:17 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PIlG5C079432; Fri, 25 Jan 2013 18:47:16 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PIlGV2079428; Fri, 25 Jan 2013 18:47:16 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201301251847.r0PIlGV2079428@svn.freebsd.org> From: Xin LI Date: Fri, 25 Jan 2013 18:47:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245912 - head/bin/df X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 18:47:17 -0000 Author: delphij Date: Fri Jan 25 18:47:16 2013 New Revision: 245912 URL: http://svnweb.freebsd.org/changeset/base/245912 Log: Don't time travel back and use a present date. Noticed by: mckusick Modified: head/bin/df/df.1 Modified: head/bin/df/df.1 ============================================================================== --- head/bin/df/df.1 Fri Jan 25 17:40:10 2013 (r245911) +++ head/bin/df/df.1 Fri Jan 25 18:47:16 2013 (r245912) @@ -29,7 +29,7 @@ .\" @(#)df.1 8.3 (Berkeley) 5/8/95 .\" $FreeBSD$ .\" -.Dd January 24, 2012 +.Dd January 24, 2013 .Dt DF 1 .Os .Sh NAME From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 20:14:28 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A0B9EBA4; Fri, 25 Jan 2013 20:14:28 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9338872E; Fri, 25 Jan 2013 20:14:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PKES7m005964; Fri, 25 Jan 2013 20:14:28 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PKESfI005963; Fri, 25 Jan 2013 20:14:28 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252014.r0PKESfI005963@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 20:14:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245914 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 20:14:28 -0000 Author: np Date: Fri Jan 25 20:14:27 2013 New Revision: 245914 URL: http://svnweb.freebsd.org/changeset/base/245914 Log: Remove redundant test, we know inp_lport is 0. MFC after: 1 week Modified: head/sys/netinet/in_pcb.c Modified: head/sys/netinet/in_pcb.c ============================================================================== --- head/sys/netinet/in_pcb.c Fri Jan 25 19:34:54 2013 (r245913) +++ head/sys/netinet/in_pcb.c Fri Jan 25 20:14:27 2013 (r245914) @@ -334,8 +334,7 @@ in_pcbbind(struct inpcb *inp, struct soc if (inp->inp_lport != 0 || inp->inp_laddr.s_addr != INADDR_ANY) return (EINVAL); - anonport = inp->inp_lport == 0 && (nam == NULL || - ((struct sockaddr_in *)nam)->sin_port == 0); + anonport = nam == NULL || ((struct sockaddr_in *)nam)->sin_port == 0; error = in_pcbbind_setup(inp, nam, &inp->inp_laddr.s_addr, &inp->inp_lport, cred); if (error) From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 20:23:34 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7506FEBA; Fri, 25 Jan 2013 20:23:34 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6808D77A; Fri, 25 Jan 2013 20:23:34 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PKNYPx008704; Fri, 25 Jan 2013 20:23:34 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PKNYH4008703; Fri, 25 Jan 2013 20:23:34 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252023.r0PKNYH4008703@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 20:23:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245915 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 20:23:34 -0000 Author: np Date: Fri Jan 25 20:23:33 2013 New Revision: 245915 URL: http://svnweb.freebsd.org/changeset/base/245915 Log: Heed SO_NO_OFFLOAD. MFC after: 1 week Modified: head/sys/netinet/tcp_usrreq.c Modified: head/sys/netinet/tcp_usrreq.c ============================================================================== --- head/sys/netinet/tcp_usrreq.c Fri Jan 25 20:14:27 2013 (r245914) +++ head/sys/netinet/tcp_usrreq.c Fri Jan 25 20:23:33 2013 (r245915) @@ -370,7 +370,8 @@ tcp_usr_listen(struct socket *so, int ba tp->t_state = TCPS_LISTEN; solisten_proto(so, backlog); #ifdef TCP_OFFLOAD - tcp_offload_listen_start(tp); + if ((so->so_options & SO_NO_OFFLOAD) == 0) + tcp_offload_listen_start(tp); #endif } SOCK_UNLOCK(so); @@ -414,7 +415,8 @@ tcp6_usr_listen(struct socket *so, int b tp->t_state = TCPS_LISTEN; solisten_proto(so, backlog); #ifdef TCP_OFFLOAD - tcp_offload_listen_start(tp); + if ((so->so_options & SO_NO_OFFLOAD) == 0) + tcp_offload_listen_start(tp); #endif } SOCK_UNLOCK(so); @@ -468,6 +470,7 @@ tcp_usr_connect(struct socket *so, struc goto out; #ifdef TCP_OFFLOAD if (registered_toedevs > 0 && + (so->so_options & SO_NO_OFFLOAD) == 0 && (error = tcp_offload_connect(so, nam)) == 0) goto out; #endif From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 20:45:25 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 13CDF6D2; Fri, 25 Jan 2013 20:45:25 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 06BB8866; Fri, 25 Jan 2013 20:45:25 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PKjOdB014403; Fri, 25 Jan 2013 20:45:24 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PKjOAP014402; Fri, 25 Jan 2013 20:45:24 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252045.r0PKjOAP014402@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 20:45:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245916 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 20:45:25 -0000 Author: np Date: Fri Jan 25 20:45:24 2013 New Revision: 245916 URL: http://svnweb.freebsd.org/changeset/base/245916 Log: Teach toe_4tuple_check() to deal with IPv6 4-tuples too. Reviewed by: bz@ Modified: head/sys/netinet/toecore.c Modified: head/sys/netinet/toecore.c ============================================================================== --- head/sys/netinet/toecore.c Fri Jan 25 20:23:33 2013 (r245915) +++ head/sys/netinet/toecore.c Fri Jan 25 20:45:24 2013 (r245916) @@ -52,6 +52,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #define TCPSTATES #include @@ -355,11 +356,14 @@ toe_4tuple_check(struct in_conninfo *inc { struct inpcb *inp; - if (inc->inc_flags & INC_ISIPV6) - return (ENOSYS); /* XXX: implement */ - - inp = in_pcblookup(&V_tcbinfo, inc->inc_faddr, inc->inc_fport, - inc->inc_laddr, inc->inc_lport, INPLOOKUP_WLOCKPCB, ifp); + if (inc->inc_flags & INC_ISIPV6) { + inp = in6_pcblookup(&V_tcbinfo, &inc->inc6_faddr, + inc->inc_fport, &inc->inc6_laddr, inc->inc_lport, + INPLOOKUP_WLOCKPCB, ifp); + } else { + inp = in_pcblookup(&V_tcbinfo, inc->inc_faddr, inc->inc_fport, + inc->inc_laddr, inc->inc_lport, INPLOOKUP_WLOCKPCB, ifp); + } if (inp != NULL) { INP_WLOCK_ASSERT(inp); From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 21:38:31 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C5FC6428; Fri, 25 Jan 2013 21:38:31 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B8864B58; Fri, 25 Jan 2013 21:38:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PLcVxY028867; Fri, 25 Jan 2013 21:38:31 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PLcVuN028866; Fri, 25 Jan 2013 21:38:31 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201301252138.r0PLcVuN028866@svn.freebsd.org> From: Peter Grehan Date: Fri, 25 Jan 2013 21:38:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245917 - head/sys/amd64/vmm/intel X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 21:38:31 -0000 Author: grehan Date: Fri Jan 25 21:38:31 2013 New Revision: 245917 URL: http://svnweb.freebsd.org/changeset/base/245917 Log: Always allow access to the sysenter cs/esp/eip MSRs since they are automatically saved and restored in the VMCS. Reviewed by: neel Obtained from: NetApp Modified: head/sys/amd64/vmm/intel/vmx.c Modified: head/sys/amd64/vmm/intel/vmx.c ============================================================================== --- head/sys/amd64/vmm/intel/vmx.c Fri Jan 25 20:45:24 2013 (r245916) +++ head/sys/amd64/vmm/intel/vmx.c Fri Jan 25 21:38:31 2013 (r245917) @@ -696,6 +696,10 @@ vmx_vminit(struct vm *vm) * vm-exit and vm-entry respectively. The host FSBASE and GSBASE are * always restored from the vmcs host state area on vm-exit. * + * The SYSENTER_CS/ESP/EIP MSRs are identical to FS/GSBASE in + * how they are saved/restored so can be directly accessed by the + * guest. + * * Guest KGSBASE is saved and restored in the guest MSR save area. * Host KGSBASE is restored before returning to userland from the pcb. * There will be a window of time when we are executing in the host @@ -708,6 +712,9 @@ vmx_vminit(struct vm *vm) */ if (guest_msr_rw(vmx, MSR_GSBASE) || guest_msr_rw(vmx, MSR_FSBASE) || + guest_msr_rw(vmx, MSR_SYSENTER_CS_MSR) || + guest_msr_rw(vmx, MSR_SYSENTER_ESP_MSR) || + guest_msr_rw(vmx, MSR_SYSENTER_EIP_MSR) || guest_msr_rw(vmx, MSR_KGSBASE) || guest_msr_rw(vmx, MSR_EFER)) panic("vmx_vminit: error setting guest msr access"); From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 21:44:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2DD97763; Fri, 25 Jan 2013 21:44:46 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 176EDBF5; Fri, 25 Jan 2013 21:44:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PLijRp031279; Fri, 25 Jan 2013 21:44:45 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PLijsB031278; Fri, 25 Jan 2013 21:44:45 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201301252144.r0PLijsB031278@svn.freebsd.org> From: Glen Barber Date: Fri, 25 Jan 2013 21:44:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245918 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 21:44:46 -0000 Author: gjb (doc,ports committer) Date: Fri Jan 25 21:44:45 2013 New Revision: 245918 URL: http://svnweb.freebsd.org/changeset/base/245918 Log: Fix update method (s/SUP/CVS) warning. Submitted by: Ryan Stone MFC after: 1 day Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Fri Jan 25 21:38:31 2013 (r245917) +++ head/Makefile.inc1 Fri Jan 25 21:44:45 2013 (r245918) @@ -1044,7 +1044,7 @@ update: echo ">>> Updating ${.CURDIR} from CVS repository" ${CVSROOT} ; \ echo "--------------------------------------------------------------" ; \ echo "!! WARNING WARNING WARNING WARNING WARNING WARNING WARNING !!" ; \ - echo "!! Update methods with ${SUP} are deprecated." ; \ + echo "!! Update methods with CVS are deprecated." ; \ echo "!! Please see http://www.freebsd.org/handbook/svn.html" ; \ echo "!! and convert your update method to SVN_UPDATE or" ; \ echo "!! freebsd-update(8)." ; \ From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 22:16:36 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 7CFF6F1C; Fri, 25 Jan 2013 22:16:36 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 644ADDD1; Fri, 25 Jan 2013 22:16:36 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PMGaTC040712; Fri, 25 Jan 2013 22:16:36 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PMGa2a040711; Fri, 25 Jan 2013 22:16:36 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252216.r0PMGa2a040711@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 22:16:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245919 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 22:16:36 -0000 Author: np Date: Fri Jan 25 22:16:35 2013 New Revision: 245919 URL: http://svnweb.freebsd.org/changeset/base/245919 Log: Add TCP_OFFLOAD hook in syncache_respond for IPv6 too, just like the one that exists for IPv4. Reviewed by: bz@ Modified: head/sys/netinet/tcp_syncache.c Modified: head/sys/netinet/tcp_syncache.c ============================================================================== --- head/sys/netinet/tcp_syncache.c Fri Jan 25 21:44:45 2013 (r245918) +++ head/sys/netinet/tcp_syncache.c Fri Jan 25 22:16:35 2013 (r245919) @@ -1493,6 +1493,15 @@ syncache_respond(struct syncache *sc) th->th_sum = in6_cksum_pseudo(ip6, tlen + optlen - hlen, IPPROTO_TCP, 0); ip6->ip6_hlim = in6_selecthlim(NULL, NULL); +#ifdef TCP_OFFLOAD + if (ADDED_BY_TOE(sc)) { + struct toedev *tod = sc->sc_tod; + + error = tod->tod_syncache_respond(tod, sc->sc_todctx, m); + + return (error); + } +#endif error = ip6_output(m, NULL, NULL, 0, NULL, NULL, NULL); } #endif From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 22:43:21 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6306B873; Fri, 25 Jan 2013 22:43:21 +0000 (UTC) (envelope-from grehan@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 50BA6ED6; Fri, 25 Jan 2013 22:43:21 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PMhLdu048861; Fri, 25 Jan 2013 22:43:21 GMT (envelope-from grehan@svn.freebsd.org) Received: (from grehan@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PMhLWJ048860; Fri, 25 Jan 2013 22:43:21 GMT (envelope-from grehan@svn.freebsd.org) Message-Id: <201301252243.r0PMhLWJ048860@svn.freebsd.org> From: Peter Grehan Date: Fri, 25 Jan 2013 22:43:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245920 - head/usr.sbin/bhyve X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 22:43:21 -0000 Author: grehan Date: Fri Jan 25 22:43:20 2013 New Revision: 245920 URL: http://svnweb.freebsd.org/changeset/base/245920 Log: Improve correctness of rtc register implementation. Submitted by: tycho nightingale at pluribusnetworks com Modified: head/usr.sbin/bhyve/rtc.c Modified: head/usr.sbin/bhyve/rtc.c ============================================================================== --- head/usr.sbin/bhyve/rtc.c Fri Jan 25 22:16:35 2013 (r245919) +++ head/usr.sbin/bhyve/rtc.c Fri Jan 25 22:43:20 2013 (r245920) @@ -118,12 +118,16 @@ static int rtc_addr_handler(struct vmctx *ctx, int vcpu, int in, int port, int bytes, uint32_t *eax, void *arg) { - assert(in == 0); - if (bytes != 1) return (-1); - switch (*eax) { + if (in) { + /* straight read of this register will return 0xFF */ + *eax = 0xff; + return (0); + } + + switch (*eax & 0x7f) { case RTC_SEC: case RTC_MIN: case RTC_HRS: @@ -144,7 +148,7 @@ rtc_addr_handler(struct vmctx *ctx, int return (-1); } - addr = *eax; + addr = *eax & 0x7f; return (0); } @@ -219,6 +223,9 @@ rtc_data_handler(struct vmctx *ctx, int case RTC_STATUSA: *eax = status_a; return (0); + case RTC_STATUSB: + *eax = status_b; + return (0); case RTC_INTR: *eax = 0; return (0); @@ -249,6 +256,9 @@ rtc_data_handler(struct vmctx *ctx, int return (-1); status_b = *eax; break; + case RTC_STATUSD: + /* ignore write */ + break; case RTC_RSTCODE: rstcode = *eax; break; @@ -270,5 +280,5 @@ rtc_data_handler(struct vmctx *ctx, int return (0); } -INOUT_PORT(rtc, IO_RTC, IOPORT_F_OUT, rtc_addr_handler); +INOUT_PORT(rtc, IO_RTC, IOPORT_F_INOUT, rtc_addr_handler); INOUT_PORT(rtc, IO_RTC + 1, IOPORT_F_INOUT, rtc_data_handler); From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 22:50:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 4FB7BB40; Fri, 25 Jan 2013 22:50:53 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 42D59F22; Fri, 25 Jan 2013 22:50:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PMorAv051492; Fri, 25 Jan 2013 22:50:53 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PMor1A051491; Fri, 25 Jan 2013 22:50:53 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252250.r0PMor1A051491@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 22:50:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245921 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 22:50:53 -0000 Author: np Date: Fri Jan 25 22:50:52 2013 New Revision: 245921 URL: http://svnweb.freebsd.org/changeset/base/245921 Log: There is no need to call into the TOE driver twice in pru_rcvd (tod_rcvd and then tod_output right after that). Reviewed by: bz@ Modified: head/sys/netinet/tcp_usrreq.c Modified: head/sys/netinet/tcp_usrreq.c ============================================================================== --- head/sys/netinet/tcp_usrreq.c Fri Jan 25 22:43:20 2013 (r245920) +++ head/sys/netinet/tcp_usrreq.c Fri Jan 25 22:50:52 2013 (r245921) @@ -769,6 +769,7 @@ tcp_usr_rcvd(struct socket *so, int flag #ifdef TCP_OFFLOAD if (tp->t_flags & TF_TOE) tcp_offload_rcvd(tp); + else #endif tcp_output(tp); From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 23:11:14 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5ECC0E5D; Fri, 25 Jan 2013 23:11:14 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4DA04FBF; Fri, 25 Jan 2013 23:11:14 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PNBE7b057734; Fri, 25 Jan 2013 23:11:14 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PNBE9x057733; Fri, 25 Jan 2013 23:11:14 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252311.r0PNBE9x057733@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 23:11:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245922 - head/sys/netinet6 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 23:11:14 -0000 Author: np Date: Fri Jan 25 23:11:13 2013 New Revision: 245922 URL: http://svnweb.freebsd.org/changeset/base/245922 Log: Avoid NULL dereference in nd6_storelladdr when no mbuf is provided. It is called this way from a couple of places in the OFED code. (toecore calls it too but that's going to change shortly). Reviewed by: bz@ Modified: head/sys/netinet6/nd6.c Modified: head/sys/netinet6/nd6.c ============================================================================== --- head/sys/netinet6/nd6.c Fri Jan 25 22:50:52 2013 (r245921) +++ head/sys/netinet6/nd6.c Fri Jan 25 23:11:13 2013 (r245922) @@ -2166,7 +2166,7 @@ nd6_storelladdr(struct ifnet *ifp, struc *lle = NULL; IF_AFDATA_UNLOCK_ASSERT(ifp); - if (m->m_flags & M_MCAST) { + if (m != NULL && m->m_flags & M_MCAST) { int i; switch (ifp->if_type) { From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 23:44:04 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 51743328; Fri, 25 Jan 2013 23:44:04 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 2BD8C114; Fri, 25 Jan 2013 23:44:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PNi3XD066733; Fri, 25 Jan 2013 23:44:03 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PNi3ec066732; Fri, 25 Jan 2013 23:44:03 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201301252344.r0PNi3ec066732@svn.freebsd.org> From: Marius Strobl Date: Fri, 25 Jan 2013 23:44:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245923 - head/sys/dev/cas X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 23:44:04 -0000 Author: marius Date: Fri Jan 25 23:44:02 2013 New Revision: 245923 URL: http://svnweb.freebsd.org/changeset/base/245923 Log: - Check the return value of taskqueue_start_threads(). - At least the Saturn chips of 501-6738 cards need a delay after freezing the external GMII pins before the internal PHY is accessible again. So wait a bit after (un)freezing these. Also don't touch the other bits of that configuration register. [1] - Take advantage of nitems(). Reported and tested by: Paul Keusemann [1] MFC after: 3 days Modified: head/sys/dev/cas/if_cas.c Modified: head/sys/dev/cas/if_cas.c ============================================================================== --- head/sys/dev/cas/if_cas.c Fri Jan 25 23:11:13 2013 (r245922) +++ head/sys/dev/cas/if_cas.c Fri Jan 25 23:44:02 2013 (r245923) @@ -214,8 +214,12 @@ cas_attach(struct cas_softc *sc) error = ENXIO; goto fail_ifnet; } - taskqueue_start_threads(&sc->sc_tq, 1, PI_NET, "%s taskq", + error = taskqueue_start_threads(&sc->sc_tq, 1, PI_NET, "%s taskq", device_get_nameunit(sc->sc_dev)); + if (error != 0) { + device_printf(sc->sc_dev, "could not start threads\n"); + goto fail_taskq; + } /* Make sure the chip is stopped. */ cas_reset(sc); @@ -339,10 +343,13 @@ cas_attach(struct cas_softc *sc) BUS_SPACE_BARRIER_READ | BUS_SPACE_BARRIER_WRITE); /* Enable/unfreeze the GMII pins of Saturn. */ if (sc->sc_variant == CAS_SATURN) { - CAS_WRITE_4(sc, CAS_SATURN_PCFG, 0); + CAS_WRITE_4(sc, CAS_SATURN_PCFG, + CAS_READ_4(sc, CAS_SATURN_PCFG) & + ~CAS_SATURN_PCFG_FSI); CAS_BARRIER(sc, CAS_SATURN_PCFG, 4, BUS_SPACE_BARRIER_READ | BUS_SPACE_BARRIER_WRITE); + DELAY(10000); } error = mii_attach(sc->sc_dev, &sc->sc_miibus, ifp, cas_mediachange, cas_mediastatus, BMSR_DEFCAPMASK, @@ -359,10 +366,12 @@ cas_attach(struct cas_softc *sc) /* Freeze the GMII pins of Saturn for saving power. */ if (sc->sc_variant == CAS_SATURN) { CAS_WRITE_4(sc, CAS_SATURN_PCFG, + CAS_READ_4(sc, CAS_SATURN_PCFG) | CAS_SATURN_PCFG_FSI); CAS_BARRIER(sc, CAS_SATURN_PCFG, 4, BUS_SPACE_BARRIER_READ | BUS_SPACE_BARRIER_WRITE); + DELAY(10000); } error = mii_attach(sc->sc_dev, &sc->sc_miibus, ifp, cas_mediachange, cas_mediastatus, BMSR_DEFCAPMASK, @@ -2865,7 +2874,7 @@ cas_pci_attach(device_t dev) goto fail; } i = 0; - if (lma > 1 && pci_get_slot(dev) < sizeof(enaddr) / sizeof(*enaddr)) + if (lma > 1 && pci_get_slot(dev) < nitems(enaddr)) i = pci_get_slot(dev); memcpy(sc->sc_enaddr, enaddr[i], ETHER_ADDR_LEN); @@ -2874,7 +2883,7 @@ cas_pci_attach(device_t dev) goto fail; } i = 0; - if (phy > 1 && pci_get_slot(dev) < sizeof(pcs) / sizeof(*pcs)) + if (phy > 1 && pci_get_slot(dev) < nitems(pcs)) i = pci_get_slot(dev); if (pcs[i] != 0) sc->sc_flags |= CAS_SERDES; From owner-svn-src-head@FreeBSD.ORG Fri Jan 25 23:58:22 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 6ABFC74C; Fri, 25 Jan 2013 23:58:22 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5D638197; Fri, 25 Jan 2013 23:58:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0PNwM6w070197; Fri, 25 Jan 2013 23:58:22 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0PNwMLB070195; Fri, 25 Jan 2013 23:58:22 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301252358.r0PNwMLB070195@svn.freebsd.org> From: Navdeep Parhar Date: Fri, 25 Jan 2013 23:58:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245924 - in head/sys: net netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jan 2013 23:58:22 -0000 Author: np Date: Fri Jan 25 23:58:21 2013 New Revision: 245924 URL: http://svnweb.freebsd.org/changeset/base/245924 Log: Move lle_event to if_llatbl.h lle_event replaced arp_update_event after the ARP rewrite and ended up in if_ether.h simply because arp_update_event used to be there too. IPv6 neighbor discovery is going to grow lle_event support and this is a good time to move it to if_llatbl.h. The two in-tree consumers of this event - OFED and toecore - are not affected. Reviewed by: bz@ Modified: head/sys/net/if_llatbl.h head/sys/netinet/if_ether.h Modified: head/sys/net/if_llatbl.h ============================================================================== --- head/sys/net/if_llatbl.h Fri Jan 25 23:44:02 2013 (r245923) +++ head/sys/net/if_llatbl.h Fri Jan 25 23:58:21 2013 (r245924) @@ -205,4 +205,14 @@ lla_lookup(struct lltable *llt, u_int fl } int lla_rt_output(struct rt_msghdr *, struct rt_addrinfo *); + +#include +enum { + LLENTRY_RESOLVED, + LLENTRY_TIMEDOUT, + LLENTRY_DELETED, + LLENTRY_EXPIRED, +}; +typedef void (*lle_event_fn)(void *, struct llentry *, int); +EVENTHANDLER_DECLARE(lle_event, lle_event_fn); #endif /* _NET_IF_LLATBL_H_ */ Modified: head/sys/netinet/if_ether.h ============================================================================== --- head/sys/netinet/if_ether.h Fri Jan 25 23:44:02 2013 (r245923) +++ head/sys/netinet/if_ether.h Fri Jan 25 23:58:21 2013 (r245924) @@ -120,17 +120,6 @@ void arprequest(struct ifnet *, struct i void arp_ifinit(struct ifnet *, struct ifaddr *); void arp_ifinit2(struct ifnet *, struct ifaddr *, u_char *); void arp_ifscrub(struct ifnet *, uint32_t); - -#include -enum { - LLENTRY_RESOLVED, - LLENTRY_TIMEDOUT, - LLENTRY_DELETED, - LLENTRY_EXPIRED, -}; -typedef void (*lle_event_fn)(void *, struct llentry *, int); -EVENTHANDLER_DECLARE(lle_event, lle_event_fn); - #endif #endif From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:05:23 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 18C789A0; Sat, 26 Jan 2013 00:05:23 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id D08B91E9; Sat, 26 Jan 2013 00:05:22 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q05M0a072976; Sat, 26 Jan 2013 00:05:22 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q05MXG072972; Sat, 26 Jan 2013 00:05:22 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260005.r0Q05MXG072972@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 00:05:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245925 - head/sys/netinet6 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:05:23 -0000 Author: np Date: Sat Jan 26 00:05:22 2013 New Revision: 245925 URL: http://svnweb.freebsd.org/changeset/base/245925 Log: Generate lle_event in the IPv6 neighbor discovery code too. Reviewed by: bz@ Modified: head/sys/netinet6/nd6.c head/sys/netinet6/nd6_nbr.c Modified: head/sys/netinet6/nd6.c ============================================================================== --- head/sys/netinet6/nd6.c Fri Jan 25 23:58:21 2013 (r245924) +++ head/sys/netinet6/nd6.c Sat Jan 26 00:05:22 2013 (r245925) @@ -509,6 +509,7 @@ nd6_llinfo_timer(void *arg) ln->la_hold = m0; clear_llinfo_pqueue(ln); } + EVENTHANDLER_INVOKE(lle_event, ln, LLENTRY_TIMEDOUT); (void)nd6_free(ln, 0); ln = NULL; if (m != NULL) @@ -526,6 +527,7 @@ nd6_llinfo_timer(void *arg) case ND6_LLINFO_STALE: /* Garbage Collection(RFC 2461 5.3) */ if (!ND6_LLINFO_PERMANENT(ln)) { + EVENTHANDLER_INVOKE(lle_event, ln, LLENTRY_EXPIRED); (void)nd6_free(ln, 1); ln = NULL; } @@ -553,6 +555,7 @@ nd6_llinfo_timer(void *arg) nd6_ns_output(ifp, dst, dst, ln, 0); LLE_WLOCK(ln); } else { + EVENTHANDLER_INVOKE(lle_event, ln, LLENTRY_EXPIRED); (void)nd6_free(ln, 0); ln = NULL; } @@ -1601,6 +1604,7 @@ nd6_cache_lladdr(struct ifnet *ifp, stru */ bcopy(lladdr, &ln->ll_addr, ifp->if_addrlen); ln->la_flags |= LLE_VALID; + EVENTHANDLER_INVOKE(lle_event, ln, LLENTRY_RESOLVED); } if (!is_newentry) { Modified: head/sys/netinet6/nd6_nbr.c ============================================================================== --- head/sys/netinet6/nd6_nbr.c Fri Jan 25 23:58:21 2013 (r245924) +++ head/sys/netinet6/nd6_nbr.c Sat Jan 26 00:05:22 2013 (r245925) @@ -762,6 +762,7 @@ nd6_na_input(struct mbuf *m, int off, in */ bcopy(lladdr, &ln->ll_addr, ifp->if_addrlen); ln->la_flags |= LLE_VALID; + EVENTHANDLER_INVOKE(lle_event, ln, LLENTRY_RESOLVED); if (is_solicited) { ln->ln_state = ND6_LLINFO_REACHABLE; ln->ln_byhint = 0; @@ -837,6 +838,8 @@ nd6_na_input(struct mbuf *m, int off, in if (lladdr != NULL) { bcopy(lladdr, &ln->ll_addr, ifp->if_addrlen); ln->la_flags |= LLE_VALID; + EVENTHANDLER_INVOKE(lle_event, ln, + LLENTRY_RESOLVED); } /* From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:11:39 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id DDBDFB7B; Sat, 26 Jan 2013 00:11:39 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id CEB90224; Sat, 26 Jan 2013 00:11:39 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q0Bdnw075610; Sat, 26 Jan 2013 00:11:39 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q0Bdc5075609; Sat, 26 Jan 2013 00:11:39 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201301260011.r0Q0Bdc5075609@svn.freebsd.org> From: Marius Strobl Date: Sat, 26 Jan 2013 00:11:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245926 - head/sys/dev/bge X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:11:39 -0000 Author: marius Date: Sat Jan 26 00:11:39 2013 New Revision: 245926 URL: http://svnweb.freebsd.org/changeset/base/245926 Log: - Improve some comments. - Make bge_lookup_{rev,vendor}() static. - Factor out chip identification rather than duplicating the code. - Sanitize bge_probe() a bit (don't hardcode buffer sizes, allow bge_lookup_vendor() to return NULL so the excessive panic() three can be removed there, etc.) and return BUS_PROBE_DEFAULT rather than hardcoding 0. - According to the Linux tg3 driver, BCM57791 and BCM57795 aren't capable of Gigabit Ethernet. - Check the return value of taskqueue_start_threads(). Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Sat Jan 26 00:05:22 2013 (r245925) +++ head/sys/dev/bge/if_bge.c Sat Jan 26 00:11:39 2013 (r245926) @@ -35,10 +35,10 @@ __FBSDID("$FreeBSD$"); /* - * Broadcom BCM570x family gigabit ethernet driver for FreeBSD. + * Broadcom BCM57xx(x)/BCM590x NetXtreme and NetLink family Ethernet driver * * The Broadcom BCM5700 is based on technology originally developed by - * Alteon Networks as part of the Tigon I and Tigon II gigabit ethernet + * Alteon Networks as part of the Tigon I and Tigon II Gigabit Ethernet * MAC chips. The BCM5700, sometimes referred to as the Tigon III, has * two on-board MIPS R4000 CPUs and can have as much as 16MB of external * SSRAM. The BCM5700 supports TCP, UDP and IP checksum offload, jumbo @@ -367,8 +367,9 @@ static const struct bge_revision bge_maj #define BGE_IS_5717_PLUS(sc) ((sc)->bge_flags & BGE_FLAG_5717_PLUS) #define BGE_IS_57765_PLUS(sc) ((sc)->bge_flags & BGE_FLAG_57765_PLUS) -const struct bge_revision * bge_lookup_rev(uint32_t); -const struct bge_vendor * bge_lookup_vendor(uint16_t); +static uint32_t bge_chipid(device_t); +static const struct bge_vendor * bge_lookup_vendor(uint16_t); +static const struct bge_revision * bge_lookup_rev(uint32_t); typedef int (*bge_eaddr_fcn_t)(struct bge_softc *, uint8_t[]); @@ -1916,7 +1917,7 @@ bge_chipinit(struct bge_softc *sc) PCI_CLRBIT(sc->bge_dev, BGE_PCI_CMD, PCIM_CMD_INTxDIS | PCIM_CMD_MWIEN, 4); - /* Set the timer prescaler (always 66Mhz) */ + /* Set the timer prescaler (always 66 MHz). */ CSR_WRITE_4(sc, BGE_MISC_CFG, BGE_32BITTIME_66MHZ); /* XXX: The Linux tg3 driver does this at the start of brgphy_reset. */ @@ -2586,7 +2587,7 @@ bge_blockinit(struct bge_softc *sc) return (0); } -const struct bge_revision * +static const struct bge_revision * bge_lookup_rev(uint32_t chipid) { const struct bge_revision *br; @@ -2604,7 +2605,7 @@ bge_lookup_rev(uint32_t chipid) return (NULL); } -const struct bge_vendor * +static const struct bge_vendor * bge_lookup_vendor(uint16_t vid) { const struct bge_vendor *v; @@ -2613,10 +2614,47 @@ bge_lookup_vendor(uint16_t vid) if (v->v_id == vid) return (v); - panic("%s: unknown vendor %d", __func__, vid); return (NULL); } +static uint32_t +bge_chipid(device_t dev) +{ + uint32_t id; + + id = pci_read_config(dev, BGE_PCI_MISC_CTL, 4) >> + BGE_PCIMISCCTL_ASICREV_SHIFT; + if (BGE_ASICREV(id) == BGE_ASICREV_USE_PRODID_REG) { + /* + * Find the ASCI revision. Different chips use different + * registers. + */ + switch (pci_get_device(dev)) { + case BCOM_DEVICEID_BCM5717: + case BCOM_DEVICEID_BCM5718: + case BCOM_DEVICEID_BCM5719: + case BCOM_DEVICEID_BCM5720: + id = pci_read_config(dev, + BGE_PCI_GEN2_PRODID_ASICREV, 4); + break; + case BCOM_DEVICEID_BCM57761: + case BCOM_DEVICEID_BCM57762: + case BCOM_DEVICEID_BCM57765: + case BCOM_DEVICEID_BCM57766: + case BCOM_DEVICEID_BCM57781: + case BCOM_DEVICEID_BCM57785: + case BCOM_DEVICEID_BCM57791: + case BCOM_DEVICEID_BCM57795: + id = pci_read_config(dev, + BGE_PCI_GEN15_PRODID_ASICREV, 4); + break; + default: + id = pci_read_config(dev, BGE_PCI_PRODID_ASICREV, 4); + } + } + return (id); +} + /* * Probe for a Broadcom chip. Check the PCI vendor and device IDs * against our list and return its name if we find a match. @@ -2634,61 +2672,34 @@ bge_probe(device_t dev) char model[64]; const struct bge_revision *br; const char *pname; - struct bge_softc *sc = device_get_softc(dev); + struct bge_softc *sc; const struct bge_type *t = bge_devs; const struct bge_vendor *v; uint32_t id; uint16_t did, vid; + sc = device_get_softc(dev); sc->bge_dev = dev; vid = pci_get_vendor(dev); did = pci_get_device(dev); while(t->bge_vid != 0) { if ((vid == t->bge_vid) && (did == t->bge_did)) { - id = pci_read_config(dev, BGE_PCI_MISC_CTL, 4) >> - BGE_PCIMISCCTL_ASICREV_SHIFT; - if (BGE_ASICREV(id) == BGE_ASICREV_USE_PRODID_REG) { - /* - * Find the ASCI revision. Different chips - * use different registers. - */ - switch (pci_get_device(dev)) { - case BCOM_DEVICEID_BCM5717: - case BCOM_DEVICEID_BCM5718: - case BCOM_DEVICEID_BCM5719: - case BCOM_DEVICEID_BCM5720: - id = pci_read_config(dev, - BGE_PCI_GEN2_PRODID_ASICREV, 4); - break; - case BCOM_DEVICEID_BCM57761: - case BCOM_DEVICEID_BCM57762: - case BCOM_DEVICEID_BCM57765: - case BCOM_DEVICEID_BCM57766: - case BCOM_DEVICEID_BCM57781: - case BCOM_DEVICEID_BCM57785: - case BCOM_DEVICEID_BCM57791: - case BCOM_DEVICEID_BCM57795: - id = pci_read_config(dev, - BGE_PCI_GEN15_PRODID_ASICREV, 4); - break; - default: - id = pci_read_config(dev, - BGE_PCI_PRODID_ASICREV, 4); - } - } + id = bge_chipid(dev); br = bge_lookup_rev(id); - v = bge_lookup_vendor(vid); if (bge_has_eaddr(sc) && pci_get_vpd_ident(dev, &pname) == 0) - snprintf(model, 64, "%s", pname); - else - snprintf(model, 64, "%s %s", v->v_name, + snprintf(model, sizeof(model), "%s", pname); + else { + v = bge_lookup_vendor(vid); + snprintf(model, sizeof(model), "%s %s", + v != NULL ? v->v_name : "Unknown", br != NULL ? br->br_name : "NetXtreme Ethernet Controller"); - snprintf(buf, 96, "%s, %sASIC rev. %#08x", model, - br != NULL ? "" : "unknown ", id); + } + snprintf(buf, sizeof(buf), "%s, %sASIC rev. %#08x", + model, br != NULL ? "" : "unknown ", id); device_set_desc_copy(dev, buf); - return (0); + return (BUS_PROBE_DEFAULT); } t++; } @@ -3247,38 +3258,7 @@ bge_attach(device_t dev) /* Save various chip information. */ sc->bge_func_addr = pci_get_function(dev); - sc->bge_chipid = - pci_read_config(dev, BGE_PCI_MISC_CTL, 4) >> - BGE_PCIMISCCTL_ASICREV_SHIFT; - if (BGE_ASICREV(sc->bge_chipid) == BGE_ASICREV_USE_PRODID_REG) { - /* - * Find the ASCI revision. Different chips use different - * registers. - */ - switch (pci_get_device(dev)) { - case BCOM_DEVICEID_BCM5717: - case BCOM_DEVICEID_BCM5718: - case BCOM_DEVICEID_BCM5719: - case BCOM_DEVICEID_BCM5720: - sc->bge_chipid = pci_read_config(dev, - BGE_PCI_GEN2_PRODID_ASICREV, 4); - break; - case BCOM_DEVICEID_BCM57761: - case BCOM_DEVICEID_BCM57762: - case BCOM_DEVICEID_BCM57765: - case BCOM_DEVICEID_BCM57766: - case BCOM_DEVICEID_BCM57781: - case BCOM_DEVICEID_BCM57785: - case BCOM_DEVICEID_BCM57791: - case BCOM_DEVICEID_BCM57795: - sc->bge_chipid = pci_read_config(dev, - BGE_PCI_GEN15_PRODID_ASICREV, 4); - break; - default: - sc->bge_chipid = pci_read_config(dev, - BGE_PCI_PRODID_ASICREV, 4); - } - } + sc->bge_chipid = bge_chipid(dev); sc->bge_asicrev = BGE_ASICREV(sc->bge_chipid); sc->bge_chiprev = BGE_CHIPREV(sc->bge_chipid); @@ -3468,6 +3448,8 @@ bge_attach(device_t dev) pci_get_device(dev) == BCOM_DEVICEID_BCM5753F || pci_get_device(dev) == BCOM_DEVICEID_BCM5787F)) || pci_get_device(dev) == BCOM_DEVICEID_BCM57790 || + pci_get_device(dev) == BCOM_DEVICEID_BCM57791 || + pci_get_device(dev) == BCOM_DEVICEID_BCM57795 || sc->bge_asicrev == BGE_ASICREV_BCM5906) { /* These chips are 10/100 only. */ capmask &= ~BMSR_EXTSTAT; @@ -3479,8 +3461,8 @@ bge_attach(device_t dev) * TSO. But the firmware is not available to FreeBSD and Linux * claims that the TSO performed by the firmware is slower than * hardware based TSO. Moreover the firmware based TSO has one - * known bug which can't handle TSO if ethernet header + IP/TCP - * header is greater than 80 bytes. The workaround for the TSO + * known bug which can't handle TSO if Ethernet header + IP/TCP + * header is greater than 80 bytes. A workaround for the TSO * bug exist but it seems it's too expensive than not using * TSO at all. Some hardwares also have the TSO bug so limit * the TSO to the controllers that are not affected TSO issues @@ -3853,8 +3835,13 @@ again: error = ENOMEM; goto fail; } - taskqueue_start_threads(&sc->bge_tq, 1, PI_NET, "%s taskq", - device_get_nameunit(sc->bge_dev)); + error = taskqueue_start_threads(&sc->bge_tq, 1, PI_NET, + "%s taskq", device_get_nameunit(sc->bge_dev)); + if (error != 0) { + device_printf(dev, "could not start threads.\n"); + ether_ifdetach(ifp); + goto fail; + } error = bus_setup_intr(dev, sc->bge_irq, INTR_TYPE_NET | INTR_MPSAFE, bge_msi_intr, NULL, sc, &sc->bge_intrhand); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:14:35 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A1EB7D27; Sat, 26 Jan 2013 00:14:35 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 84C5824C; Sat, 26 Jan 2013 00:14:35 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q0EZOA076100; Sat, 26 Jan 2013 00:14:35 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q0EYpU076094; Sat, 26 Jan 2013 00:14:34 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201301260014.r0Q0EYpU076094@svn.freebsd.org> From: Adrian Chadd Date: Sat, 26 Jan 2013 00:14:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245927 - head/sys/dev/ath X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:14:35 -0000 Author: adrian Date: Sat Jan 26 00:14:34 2013 New Revision: 245927 URL: http://svnweb.freebsd.org/changeset/base/245927 Log: Migrate the TX sending code out from under the ath0 taskq and into the separate ath0 TX taskq. Whilst here, make sure that the TX software scheduler is also running out of the TX task, rather than the ath0 taskqueue. Make sure that the tx taskqueue is blocked/unblocked as necessary. This allows for a little more parallelism on multi-core machines, as well as (eventually) supporting a higher task priority for TX tasks, allowing said TX task to preempt an already running RX or TX completion task. Tested: * AR5416, AR9280 hostap and STA modes Modified: head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_ath_misc.h head/sys/dev/ath/if_ath_tx.c head/sys/dev/ath/if_ath_tx_edma.c Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Sat Jan 26 00:11:39 2013 (r245926) +++ head/sys/dev/ath/if_ath.c Sat Jan 26 00:14:34 2013 (r245927) @@ -436,6 +436,16 @@ ath_attach(u_int16_t devid, struct ath_s taskqueue_start_threads(&sc->sc_tq, 1, PI_NET, "%s taskq", ifp->if_xname); + /* + * This taskqueue doesn't get any higher priority + * than the ath(4) taskqueue (PI_NET) so TX won't + * pre-empt RX and other task priorities. + * + * This may not be optimal - the previous behaviour + * was to direct-dispatch frames via the sending + * task context, rather than (always) software + * queuing. + */ sc->sc_tx_tq = taskqueue_create("ath_tx_taskq", M_NOWAIT, taskqueue_thread_enqueue, &sc->sc_tx_tq); taskqueue_start_threads(&sc->sc_tx_tq, 1, PI_NET, @@ -2135,6 +2145,7 @@ ath_txrx_start(struct ath_softc *sc) { taskqueue_unblock(sc->sc_tq); + taskqueue_unblock(sc->sc_tx_tq); } /* @@ -2235,6 +2246,7 @@ ath_reset(struct ifnet *ifp, ATH_RESET_T /* Try to (stop any further TX/RX from occuring */ taskqueue_block(sc->sc_tq); + taskqueue_block(sc->sc_tx_tq); ATH_PCU_LOCK(sc); ath_hal_intrset(ah, 0); /* disable interrupts */ @@ -3033,6 +3045,7 @@ ath_key_update_begin(struct ieee80211vap DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s:\n", __func__); taskqueue_block(sc->sc_tq); + taskqueue_block(sc->sc_tx_tq); IF_LOCK(&ifp->if_snd); /* NB: doesn't block mgmt frames */ } @@ -3045,6 +3058,7 @@ ath_key_update_end(struct ieee80211vap * DPRINTF(sc, ATH_DEBUG_KEYCACHE, "%s:\n", __func__); IF_UNLOCK(&ifp->if_snd); taskqueue_unblock(sc->sc_tq); + taskqueue_unblock(sc->sc_tx_tq); } static void @@ -4218,9 +4232,7 @@ ath_tx_processq(struct ath_softc *sc, st /* Kick the TXQ scheduler */ if (dosched) { - ATH_TX_LOCK(sc); - ath_txq_sched(sc, txq); - ATH_TX_UNLOCK(sc); + taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask); } ATH_KTR(sc, ATH_KTR_TXCOMP, 1, @@ -4718,6 +4730,7 @@ ath_chan_set(struct ath_softc *sc, struc /* (Try to) stop TX/RX from occuring */ taskqueue_block(sc->sc_tq); + taskqueue_block(sc->sc_tx_tq); ATH_PCU_LOCK(sc); ath_hal_intrset(ah, 0); /* Stop new RX/TX completion */ @@ -5107,6 +5120,7 @@ ath_newstate(struct ieee80211vap *vap, e sc->sc_imask &= ~(HAL_INT_SWBA | HAL_INT_BMISS); sc->sc_beacons = 0; taskqueue_unblock(sc->sc_tq); + taskqueue_unblock(sc->sc_tx_tq); } ni = ieee80211_ref_node(vap->iv_bss); @@ -5272,6 +5286,7 @@ ath_newstate(struct ieee80211vap *vap, e "%s: calibration disabled\n", __func__); } taskqueue_unblock(sc->sc_tq); + taskqueue_unblock(sc->sc_tx_tq); } else if (nstate == IEEE80211_S_INIT) { /* * If there are no vaps left in RUN state then @@ -5285,6 +5300,7 @@ ath_newstate(struct ieee80211vap *vap, e /* disable interrupts */ ath_hal_intrset(ah, sc->sc_imask &~ HAL_INT_GLOBAL); taskqueue_block(sc->sc_tq); + taskqueue_block(sc->sc_tx_tq); sc->sc_beacons = 0; } #ifdef IEEE80211_SUPPORT_TDMA Modified: head/sys/dev/ath/if_ath_misc.h ============================================================================== --- head/sys/dev/ath/if_ath_misc.h Sat Jan 26 00:11:39 2013 (r245926) +++ head/sys/dev/ath/if_ath_misc.h Sat Jan 26 00:14:34 2013 (r245927) @@ -125,7 +125,7 @@ ath_tx_kick(struct ath_softc *sc) { /* XXX eventually try sc_tx_tq? */ - taskqueue_enqueue(sc->sc_tq, &sc->sc_txpkttask); + taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txpkttask); } #endif Modified: head/sys/dev/ath/if_ath_tx.c ============================================================================== --- head/sys/dev/ath/if_ath_tx.c Sat Jan 26 00:11:39 2013 (r245926) +++ head/sys/dev/ath/if_ath_tx.c Sat Jan 26 00:14:34 2013 (r245927) @@ -3001,7 +3001,7 @@ ath_tx_tid_resume(struct ath_softc *sc, ath_tx_tid_sched(sc, tid); /* Punt some frames to the hardware if needed */ //ath_txq_sched(sc, sc->sc_ac2q[tid->ac]); - taskqueue_enqueue(sc->sc_tq, &sc->sc_txqtask); + taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask); } /* Modified: head/sys/dev/ath/if_ath_tx_edma.c ============================================================================== --- head/sys/dev/ath/if_ath_tx_edma.c Sat Jan 26 00:11:39 2013 (r245926) +++ head/sys/dev/ath/if_ath_tx_edma.c Sat Jan 26 00:14:34 2013 (r245927) @@ -655,7 +655,7 @@ ath_edma_tx_processq(struct ath_softc *s * the txq task for _one_ TXQ. This should be fixed. */ if (dosched) - taskqueue_enqueue(sc->sc_tq, &sc->sc_txqtask); + taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask); } static void From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:37:55 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2160437E; Sat, 26 Jan 2013 00:37:55 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 03BA131A; Sat, 26 Jan 2013 00:37:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q0bsBc082305; Sat, 26 Jan 2013 00:37:54 GMT (envelope-from adrian@svn.freebsd.org) Received: (from adrian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q0bsc0082300; Sat, 26 Jan 2013 00:37:54 GMT (envelope-from adrian@svn.freebsd.org) Message-Id: <201301260037.r0Q0bsc0082300@svn.freebsd.org> From: Adrian Chadd Date: Sat, 26 Jan 2013 00:37:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245928 - head/sys/net80211 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:37:55 -0000 Author: adrian Date: Sat Jan 26 00:37:54 2013 New Revision: 245928 URL: http://svnweb.freebsd.org/changeset/base/245928 Log: Initial cut at making IBSS support 802.11n aware. * Add HTINFO field decoding to ieee80211_ies_expand() - it's likely not 100% correct as it's not looking at the draft 11n HTINFO location, but I don't think anyone will care. * When doing an IBSS join make sure the 11n channel configuration is used - otherwise the 11a/11bg channel will be used and there won't be any chance for an upgrade to 11n. * When creating an IBSS network, ensure the channel is updated to an 11n channel so other 11n nodes can see it and speak to it with MCS rates. * Add a bit of code that's disabled for now which handles the HT field updating. This won't work out very well with lots of adhoc nodes as we'd end up ping-ponging between the HT configuration for each node. Instead, we should likely only pay attention to the "master" node we initially associated against and then ensure we propagate that information forward in our subsequent beacons. However, due to the nature of IBSS (ie, there's no specific "master" node in the specification) it's unclear which node we should lift the HT parameters from. So for now this assumes the HT parameters are squirreled away in the initial beacon/probe response. So there's some trickiness here. With ap/sta pairing, the probe response just populates a legacy node and the association request/response is what is used for negotiation 11n-ness (and upgrading things as needed.) With ibss networks, the pairing is done with probe request/response, with discovery being done by creating nodes when new beacons in the IBSS / BSSID are heard. There's no assoc request/response frames going on. So the trick here has been to figure out where to upgrade things. I don't like how I just taught ieee80211_sta_join() to "speak" HT - I'd rather there be an upgrade path when an IBSS node joins and there are HT parameters present. Once I've done that, I'll kill this HT special casing that's going on in ieee80211_sta_join(). Tested: * AR9280, AR5416, AR5212 - basic iperf and ping interoperability tests whilst in a non-encrypted adhoc network. TODO: * Fix up the HT upgrade path for IBSS nodes rather than adding code in ieee80211_sta_join(), then remove my code from there. * When associating, there's a concept of a "master" node in the IBSS which is the node you first joined the network through. It's possible the correct thing to do is to listen to HT updates and configure WME parameters from that node. However, once that node goes away, which node(s) should be listened to for configuration changes? For things like HT channel width, it's likely going to be ok to just associate as HT40 and then use the per-neighbor rate control and HTINFO/HTCAP fields to figure out which rates and configuration to speak. Ie, for a 20MHz 11n node, just speak 20MHz rates to it. It shouldn't "change", like what goes on in AP/STA configurations. Modified: head/sys/net80211/ieee80211_adhoc.c head/sys/net80211/ieee80211_node.c head/sys/net80211/ieee80211_scan_sta.c Modified: head/sys/net80211/ieee80211_adhoc.c ============================================================================== --- head/sys/net80211/ieee80211_adhoc.c Sat Jan 26 00:14:34 2013 (r245927) +++ head/sys/net80211/ieee80211_adhoc.c Sat Jan 26 00:37:54 2013 (r245928) @@ -688,6 +688,7 @@ adhoc_recv_mgmt(struct ieee80211_node *n struct ieee80211_frame *wh; uint8_t *frm, *efrm, *sfrm; uint8_t *ssid, *rates, *xrates; + int ht_state_change = 0; wh = mtod(m0, struct ieee80211_frame *); frm = (uint8_t *)&wh[1]; @@ -748,10 +749,27 @@ adhoc_recv_mgmt(struct ieee80211_node *n memcpy(ni->ni_tstamp.data, scan.tstamp, sizeof(ni->ni_tstamp)); } + /* + * This isn't enabled yet - otherwise it would + * update the HT parameters and channel width + * from any node, which could lead to lots of + * strange behaviour if the 11n nodes aren't + * exactly configured to match. + */ +#if 0 + if (scan.htcap != NULL && scan.htinfo != NULL && + (vap->iv_flags_ht & IEEE80211_FHT_HT)) { + if (ieee80211_ht_updateparams(ni, + scan.htcap, scan.htinfo)) + ht_state_change = 1; + } +#endif if (ni != NULL) { IEEE80211_RSSI_LPF(ni->ni_avgrssi, rssi); ni->ni_noise = nf; } + if (ht_state_change) + ieee80211_update_chw(ic); } break; } Modified: head/sys/net80211/ieee80211_node.c ============================================================================== --- head/sys/net80211/ieee80211_node.c Sat Jan 26 00:14:34 2013 (r245927) +++ head/sys/net80211/ieee80211_node.c Sat Jan 26 00:37:54 2013 (r245928) @@ -771,6 +771,7 @@ ieee80211_sta_join(struct ieee80211vap * /* XXX msg */ return 0; } + /* * Expand scan state into node's format. * XXX may not need all this stuff @@ -821,6 +822,29 @@ ieee80211_sta_join(struct ieee80211vap * IEEE80211_F_DOSORT); if (ieee80211_iserp_rateset(&ni->ni_rates)) ni->ni_flags |= IEEE80211_NODE_ERP; + + /* + * Setup HT state for this node if it's available, otherwise + * non-STA modes won't pick this state up. + * + * For IBSS and related modes that don't go through an + * association request/response, the only appropriate place + * to setup the HT state is here. + */ + if (ni->ni_ies.htinfo_ie != NULL && + ni->ni_ies.htcap_ie != NULL && + vap->iv_flags_ht & IEEE80211_FHT_HT) { + ieee80211_ht_node_init(ni); + ieee80211_ht_updateparams(ni, + ni->ni_ies.htcap_ie, + ni->ni_ies.htinfo_ie); + ieee80211_setup_htrates(ni, ni->ni_ies.htcap_ie, + IEEE80211_F_JOIN | IEEE80211_F_DOBRS); + ieee80211_setup_basic_htrates(ni, ni->ni_ies.htinfo_ie); + } + /* XXX else check for ath FF? */ + /* XXX QoS? Difficult given that WME config is specific to a master */ + ieee80211_node_setuptxparms(ni); ieee80211_ratectl_node_init(ni); @@ -938,6 +962,9 @@ ieee80211_ies_expand(struct ieee80211_ie case IEEE80211_ELEMID_HTCAP: ies->htcap_ie = ie; break; + case IEEE80211_ELEMID_HTINFO: + ies->htinfo_ie = ie; + break; #ifdef IEEE80211_SUPPORT_MESH case IEEE80211_ELEMID_MESHID: ies->meshid_ie = ie; @@ -1404,7 +1431,7 @@ ieee80211_fakeup_adhoc_node(struct ieee8 { struct ieee80211_node *ni; - IEEE80211_DPRINTF(vap, IEEE80211_MSG_NODE, + IEEE80211_DPRINTF(vap, IEEE80211_MSG_NODE | IEEE80211_MSG_ASSOC, "%s: mac<%s>\n", __func__, ether_sprintf(macaddr)); ni = ieee80211_dup_bss(vap, macaddr); if (ni != NULL) { @@ -1444,6 +1471,8 @@ ieee80211_init_neighbor(struct ieee80211 const struct ieee80211_frame *wh, const struct ieee80211_scanparams *sp) { + int do_ht_setup = 0; + ni->ni_esslen = sp->ssid[1]; memcpy(ni->ni_essid, sp->ssid + 2, sp->ssid[1]); IEEE80211_ADDR_COPY(ni->ni_bssid, wh->i_addr3); @@ -1469,12 +1498,41 @@ ieee80211_init_neighbor(struct ieee80211 if (ni->ni_ies.ath_ie != NULL) ieee80211_parse_ath(ni, ni->ni_ies.ath_ie); #endif + if (ni->ni_ies.htcap_ie != NULL) + ieee80211_parse_htcap(ni, ni->ni_ies.htcap_ie); + if (ni->ni_ies.htinfo_ie != NULL) + ieee80211_parse_htinfo(ni, ni->ni_ies.htinfo_ie); + + if ((ni->ni_ies.htcap_ie != NULL) && + (ni->ni_ies.htinfo_ie != NULL) && + (ni->ni_vap->iv_flags_ht & IEEE80211_FHT_HT)) { + do_ht_setup = 1; + } } /* NB: must be after ni_chan is setup */ ieee80211_setup_rates(ni, sp->rates, sp->xrates, IEEE80211_F_DOSORT | IEEE80211_F_DOFRATE | IEEE80211_F_DONEGO | IEEE80211_F_DODEL); + + /* + * If the neighbor is HT compatible, flip that on. + */ + if (do_ht_setup) { + IEEE80211_DPRINTF(ni->ni_vap, IEEE80211_MSG_ASSOC, + "%s: doing HT setup\n", __func__); + ieee80211_ht_node_init(ni); + ieee80211_ht_updateparams(ni, + ni->ni_ies.htcap_ie, + ni->ni_ies.htinfo_ie); + ieee80211_setup_htrates(ni, + ni->ni_ies.htcap_ie, + IEEE80211_F_JOIN | IEEE80211_F_DOBRS); + ieee80211_setup_basic_htrates(ni, + ni->ni_ies.htinfo_ie); + ieee80211_node_setuptxparms(ni); + ieee80211_ratectl_node_init(ni); + } } /* @@ -1490,7 +1548,7 @@ ieee80211_add_neighbor(struct ieee80211v { struct ieee80211_node *ni; - IEEE80211_DPRINTF(vap, IEEE80211_MSG_NODE, + IEEE80211_DPRINTF(vap, IEEE80211_MSG_ASSOC, "%s: mac<%s>\n", __func__, ether_sprintf(wh->i_addr2)); ni = ieee80211_dup_bss(vap, wh->i_addr2);/* XXX alloc_node? */ if (ni != NULL) { Modified: head/sys/net80211/ieee80211_scan_sta.c ============================================================================== --- head/sys/net80211/ieee80211_scan_sta.c Sat Jan 26 00:14:34 2013 (r245927) +++ head/sys/net80211/ieee80211_scan_sta.c Sat Jan 26 00:37:54 2013 (r245928) @@ -51,6 +51,7 @@ __FBSDID("$FreeBSD$"); #ifdef IEEE80211_SUPPORT_MESH #include #endif +#include #include @@ -1567,6 +1568,7 @@ adhoc_pick_bss(struct ieee80211_scan_sta struct sta_table *st = ss->ss_priv; struct sta_entry *selbs; struct ieee80211_channel *chan; + struct ieee80211com *ic = vap->iv_ic; KASSERT(vap->iv_opmode == IEEE80211_M_IBSS || vap->iv_opmode == IEEE80211_M_AHDEMO || @@ -1612,15 +1614,19 @@ notfound: */ if (vap->iv_des_chan == IEEE80211_CHAN_ANYC || IEEE80211_IS_CHAN_RADAR(vap->iv_des_chan)) { - struct ieee80211com *ic = vap->iv_ic; - chan = adhoc_pick_channel(ss, 0); - if (chan != NULL) - chan = ieee80211_ht_adjust_channel(ic, - chan, vap->iv_flags_ht); } else chan = vap->iv_des_chan; if (chan != NULL) { + struct ieee80211com *ic = vap->iv_ic; + /* + * Create a HT capable IBSS; the per-node + * probe request/response will result in + * "correct" rate control capabilities being + * negotiated. + */ + chan = ieee80211_ht_adjust_channel(ic, + chan, vap->iv_flags_ht); ieee80211_create_ibss(vap, chan); return 1; } @@ -1644,6 +1650,14 @@ notfound: chan = selbs->base.se_chan; if (selbs->se_flags & STA_DEMOTE11B) chan = demote11b(vap, chan); + /* + * If HT is available, make it a possibility here. + * The intent is to enable HT20/HT40 when joining a non-HT + * IBSS node; we can then advertise HT IEs and speak HT + * to any subsequent nodes that support it. + */ + chan = ieee80211_ht_adjust_channel(ic, + chan, vap->iv_flags_ht); if (!ieee80211_sta_join(vap, chan, &selbs->base)) goto notfound; return 1; /* terminate scan */ From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:41:54 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id B3D367E6; Sat, 26 Jan 2013 00:41:54 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 9CB43347; Sat, 26 Jan 2013 00:41:54 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q0fsuw084537; Sat, 26 Jan 2013 00:41:54 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q0fsTg084536; Sat, 26 Jan 2013 00:41:54 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201301260041.r0Q0fsTg084536@svn.freebsd.org> From: Marius Strobl Date: Sat, 26 Jan 2013 00:41:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245931 - head/sys/dev/bge X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:41:54 -0000 Author: marius Date: Sat Jan 26 00:41:54 2013 New Revision: 245931 URL: http://svnweb.freebsd.org/changeset/base/245931 Log: Mention NetLink controllers in the fallback description, too. Modified: head/sys/dev/bge/if_bge.c Modified: head/sys/dev/bge/if_bge.c ============================================================================== --- head/sys/dev/bge/if_bge.c Sat Jan 26 00:40:02 2013 (r245930) +++ head/sys/dev/bge/if_bge.c Sat Jan 26 00:41:54 2013 (r245931) @@ -2694,7 +2694,7 @@ bge_probe(device_t dev) snprintf(model, sizeof(model), "%s %s", v != NULL ? v->v_name : "Unknown", br != NULL ? br->br_name : - "NetXtreme Ethernet Controller"); + "NetXtreme/NetLink Ethernet Controller"); } snprintf(buf, sizeof(buf), "%s, %sASIC rev. %#08x", model, br != NULL ? "" : "unknown ", id); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 00:57:30 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8F39AA4A; Sat, 26 Jan 2013 00:57:30 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 514BA3DA; Sat, 26 Jan 2013 00:57:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q0vToH088156; Sat, 26 Jan 2013 00:57:29 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q0vTUx088155; Sat, 26 Jan 2013 00:57:29 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260057.r0Q0vTUx088155@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 00:57:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245932 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 00:57:30 -0000 Author: np Date: Sat Jan 26 00:57:29 2013 New Revision: 245932 URL: http://svnweb.freebsd.org/changeset/base/245932 Log: Teach toe_l2_resolve to resolve IPv6 destinations too. Reviewed by: bz@ Modified: head/sys/netinet/toecore.c Modified: head/sys/netinet/toecore.c ============================================================================== --- head/sys/netinet/toecore.c Sat Jan 26 00:41:54 2013 (r245931) +++ head/sys/netinet/toecore.c Sat Jan 26 00:57:29 2013 (r245932) @@ -52,6 +52,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #define TCPSTATES @@ -444,6 +445,68 @@ toe_route_redirect_event(void *arg __unu return; } +#ifdef INET6 +/* + * XXX: no checks to verify that sa is really a neighbor because we assume it is + * the result of a route lookup and is on-link on the given ifp. + */ +static int +toe_nd6_resolve(struct ifnet *ifp, struct sockaddr *sa, uint8_t *lladdr) +{ + struct llentry *lle; + struct sockaddr_in6 *sin6 = (void *)sa; + int rc, flags = 0; + +restart: + IF_AFDATA_RLOCK(ifp); + lle = lla_lookup(LLTABLE6(ifp), flags, sa); + IF_AFDATA_RUNLOCK(ifp); + if (lle == NULL) { + IF_AFDATA_LOCK(ifp); + lle = nd6_lookup(&sin6->sin6_addr, ND6_CREATE | ND6_EXCLUSIVE, + ifp); + IF_AFDATA_UNLOCK(ifp); + if (lle == NULL) + return (ENOMEM); /* Couldn't create entry in cache. */ + lle->ln_state = ND6_LLINFO_INCOMPLETE; + nd6_llinfo_settimer_locked(lle, + (long)ND_IFINFO(ifp)->retrans * hz / 1000); + LLE_WUNLOCK(lle); + + nd6_ns_output(ifp, NULL, &sin6->sin6_addr, NULL, 0); + + return (EWOULDBLOCK); + } + + if (lle->ln_state == ND6_LLINFO_STALE) { + if ((flags & LLE_EXCLUSIVE) == 0) { + LLE_RUNLOCK(lle); + flags |= LLE_EXCLUSIVE; + goto restart; + } + + LLE_WLOCK_ASSERT(lle); + + lle->la_asked = 0; + lle->ln_state = ND6_LLINFO_DELAY; + nd6_llinfo_settimer_locked(lle, (long)V_nd6_delay * hz); + } + + if (lle->la_flags & LLE_VALID) { + memcpy(lladdr, &lle->ll_addr, ifp->if_addrlen); + rc = 0; + } else + rc = EWOULDBLOCK; + + if (flags & LLE_EXCLUSIVE) + LLE_WUNLOCK(lle); + else + LLE_RUNLOCK(lle); + + return (rc); +} +#endif + /* * Returns 0 or EWOULDBLOCK on success (any other value is an error). 0 means * lladdr and vtag are valid on return, EWOULDBLOCK means the TOE driver's @@ -453,7 +516,9 @@ int toe_l2_resolve(struct toedev *tod, struct ifnet *ifp, struct sockaddr *sa, uint8_t *lladdr, uint16_t *vtag) { +#ifdef INET struct llentry *lle; +#endif int rc; switch (sa->sa_family) { @@ -464,7 +529,7 @@ toe_l2_resolve(struct toedev *tod, struc #endif #ifdef INET6 case AF_INET6: - rc = nd6_storelladdr(ifp, NULL, sa, lladdr, &lle); + rc = toe_nd6_resolve(ifp, sa, lladdr); break; #endif default: From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 01:06:28 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 41BC3D87; Sat, 26 Jan 2013 01:06:28 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 34994646; Sat, 26 Jan 2013 01:06:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q16Sw5091518; Sat, 26 Jan 2013 01:06:28 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q16Rc5091517; Sat, 26 Jan 2013 01:06:27 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260106.r0Q16Rc5091517@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 01:06:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245933 - head/sys/dev/cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 01:06:28 -0000 Author: np Date: Sat Jan 26 01:06:27 2013 New Revision: 245933 URL: http://svnweb.freebsd.org/changeset/base/245933 Log: cxgbe/tom: List IFCAP_TOE6 as supported now that all the required pieces are in place. You still have to enable it explicitly, after loading the t4_tom KLD. Modified: head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/t4_main.c ============================================================================== --- head/sys/dev/cxgbe/t4_main.c Sat Jan 26 00:57:29 2013 (r245932) +++ head/sys/dev/cxgbe/t4_main.c Sat Jan 26 01:06:27 2013 (r245933) @@ -875,7 +875,7 @@ cxgbe_attach(device_t dev) ifp->if_capabilities = T4_CAP; #ifdef TCP_OFFLOAD if (is_offload(pi->adapter)) - ifp->if_capabilities |= IFCAP_TOE4; + ifp->if_capabilities |= IFCAP_TOE; #endif ifp->if_capenable = T4_CAP_ENABLE; ifp->if_hwassist = CSUM_TCP | CSUM_UDP | CSUM_IP | CSUM_TSO | From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 01:41:42 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id CEB1665A; Sat, 26 Jan 2013 01:41:42 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id C04167A9; Sat, 26 Jan 2013 01:41:42 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q1fgvM002772; Sat, 26 Jan 2013 01:41:42 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q1fg1U002771; Sat, 26 Jan 2013 01:41:42 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260141.r0Q1fg1U002771@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 01:41:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245934 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 01:41:42 -0000 Author: np Date: Sat Jan 26 01:41:42 2013 New Revision: 245934 URL: http://svnweb.freebsd.org/changeset/base/245934 Log: Add checks for SO_NO_OFFLOAD in a couple of places that I missed earlier in r245915. Modified: head/sys/netinet/tcp_usrreq.c Modified: head/sys/netinet/tcp_usrreq.c ============================================================================== --- head/sys/netinet/tcp_usrreq.c Sat Jan 26 01:06:27 2013 (r245933) +++ head/sys/netinet/tcp_usrreq.c Sat Jan 26 01:41:42 2013 (r245934) @@ -537,6 +537,7 @@ tcp6_usr_connect(struct socket *so, stru goto out; #ifdef TCP_OFFLOAD if (registered_toedevs > 0 && + (so->so_options & SO_NO_OFFLOAD) == 0 && (error = tcp_offload_connect(so, nam)) == 0) goto out; #endif @@ -553,6 +554,7 @@ tcp6_usr_connect(struct socket *so, stru goto out; #ifdef TCP_OFFLOAD if (registered_toedevs > 0 && + (so->so_options & SO_NO_OFFLOAD) == 0 && (error = tcp_offload_connect(so, nam)) == 0) goto out; #endif From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 03:01:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 81CF36B; Sat, 26 Jan 2013 03:01:53 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 74E7DA8B; Sat, 26 Jan 2013 03:01:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q31r8K027470; Sat, 26 Jan 2013 03:01:53 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q31q1p027460; Sat, 26 Jan 2013 03:01:52 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260301.r0Q31q1p027460@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 03:01:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245935 - in head/sys/dev/cxgbe: common tom X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 03:01:53 -0000 Author: np Date: Sat Jan 26 03:01:51 2013 New Revision: 245935 URL: http://svnweb.freebsd.org/changeset/base/245935 Log: Add a couple of missing error codes. Treat CPL_ERR_KEEPALV_NEG_ADVICE as negative advice and not a fatal error. MFC after: 3 days Modified: head/sys/dev/cxgbe/common/t4_msg.h head/sys/dev/cxgbe/tom/t4_connect.c head/sys/dev/cxgbe/tom/t4_cpl_io.c head/sys/dev/cxgbe/tom/t4_listen.c head/sys/dev/cxgbe/tom/t4_tom.c head/sys/dev/cxgbe/tom/t4_tom.h Modified: head/sys/dev/cxgbe/common/t4_msg.h ============================================================================== --- head/sys/dev/cxgbe/common/t4_msg.h Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/common/t4_msg.h Sat Jan 26 03:01:51 2013 (r245935) @@ -159,6 +159,8 @@ enum CPL_error { CPL_ERR_KEEPALIVE_TIMEDOUT = 34, CPL_ERR_RTX_NEG_ADVICE = 35, CPL_ERR_PERSIST_NEG_ADVICE = 36, + CPL_ERR_KEEPALV_NEG_ADVICE = 37, + CPL_ERR_WAIT_ARP_RPL = 41, CPL_ERR_ABORT_FAILED = 42, CPL_ERR_IWARP_FLM = 50, }; Modified: head/sys/dev/cxgbe/tom/t4_connect.c ============================================================================== --- head/sys/dev/cxgbe/tom/t4_connect.c Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/tom/t4_connect.c Sat Jan 26 03:01:51 2013 (r245935) @@ -196,7 +196,7 @@ do_act_open_rpl(struct sge_iq *iq, const CTR3(KTR_CXGBE, "%s: atid %u, status %u ", __func__, atid, status); /* Ignore negative advice */ - if (status == CPL_ERR_RTX_NEG_ADVICE) + if (negative_advice(status)) return (0); free_atid(sc, atid); Modified: head/sys/dev/cxgbe/tom/t4_cpl_io.c ============================================================================== --- head/sys/dev/cxgbe/tom/t4_cpl_io.c Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/tom/t4_cpl_io.c Sat Jan 26 03:01:51 2013 (r245935) @@ -1018,8 +1018,7 @@ do_abort_req(struct sge_iq *iq, const st KASSERT(toep->tid == tid, ("%s: toep tid mismatch", __func__)); - if (cpl->status == CPL_ERR_RTX_NEG_ADVICE || - cpl->status == CPL_ERR_PERSIST_NEG_ADVICE) { + if (negative_advice(cpl->status)) { CTR4(KTR_CXGBE, "%s: negative advice %d for tid %d (0x%x)", __func__, cpl->status, tid, toep->flags); return (0); /* Ignore negative advice */ Modified: head/sys/dev/cxgbe/tom/t4_listen.c ============================================================================== --- head/sys/dev/cxgbe/tom/t4_listen.c Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/tom/t4_listen.c Sat Jan 26 03:01:51 2013 (r245935) @@ -835,8 +835,7 @@ do_abort_req_synqe(struct sge_iq *iq, co CTR6(KTR_CXGBE, "%s: tid %u, synqe %p (0x%x), lctx %p, status %d", __func__, tid, synqe, synqe->flags, synqe->lctx, cpl->status); - if (cpl->status == CPL_ERR_RTX_NEG_ADVICE || - cpl->status == CPL_ERR_PERSIST_NEG_ADVICE) + if (negative_advice(cpl->status)) return (0); /* Ignore negative advice */ INP_WLOCK(inp); Modified: head/sys/dev/cxgbe/tom/t4_tom.c ============================================================================== --- head/sys/dev/cxgbe/tom/t4_tom.c Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/tom/t4_tom.c Sat Jan 26 03:01:51 2013 (r245935) @@ -547,6 +547,15 @@ set_tcpddp_ulp_mode(struct toepcb *toep) toep->ddp_score = DDP_LOW_SCORE; } +int +negative_advice(int status) +{ + + return (status == CPL_ERR_RTX_NEG_ADVICE || + status == CPL_ERR_PERSIST_NEG_ADVICE || + status == CPL_ERR_KEEPALV_NEG_ADVICE); +} + static int alloc_tid_tabs(struct tid_info *t) { Modified: head/sys/dev/cxgbe/tom/t4_tom.h ============================================================================== --- head/sys/dev/cxgbe/tom/t4_tom.h Sat Jan 26 01:41:42 2013 (r245934) +++ head/sys/dev/cxgbe/tom/t4_tom.h Sat Jan 26 03:01:51 2013 (r245935) @@ -236,6 +236,7 @@ uint64_t calc_opt0(struct socket *, stru int, int, int, int); uint32_t select_ntuple(struct port_info *, struct l2t_entry *, uint32_t); void set_tcpddp_ulp_mode(struct toepcb *); +int negative_advice(int); struct clip_entry *hold_lip(struct tom_data *, struct in6_addr *); void release_lip(struct tom_data *, struct clip_entry *); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 03:10:29 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 877C733D; Sat, 26 Jan 2013 03:10:29 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 624D0AFC; Sat, 26 Jan 2013 03:10:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q3ATZa028922; Sat, 26 Jan 2013 03:10:29 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q3AT65028920; Sat, 26 Jan 2013 03:10:29 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260310.r0Q3AT65028920@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 03:10:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245936 - head/sys/dev/cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 03:10:29 -0000 Author: np Date: Sat Jan 26 03:10:28 2013 New Revision: 245936 URL: http://svnweb.freebsd.org/changeset/base/245936 Log: Force the 404-BT card (4 x 1G) to use the "uwire" configuration file. MFC after: 3 days Modified: head/sys/dev/cxgbe/adapter.h head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/adapter.h ============================================================================== --- head/sys/dev/cxgbe/adapter.h Sat Jan 26 03:01:51 2013 (r245935) +++ head/sys/dev/cxgbe/adapter.h Sat Jan 26 03:10:28 2013 (r245936) @@ -577,7 +577,8 @@ struct adapter { int flags; char fw_version[32]; - unsigned int cfcsum; + char cfg_file[32]; + u_int cfcsum; struct adapter_params params; struct t4_virt_res vres; Modified: head/sys/dev/cxgbe/t4_main.c ============================================================================== --- head/sys/dev/cxgbe/t4_main.c Sat Jan 26 03:01:51 2013 (r245935) +++ head/sys/dev/cxgbe/t4_main.c Sat Jan 26 03:10:28 2013 (r245936) @@ -1604,21 +1604,28 @@ prep_firmware(struct adapter *sc) /* Partition adapter resources as specified in the config file. */ if (sc->flags & MASTER_PF) { - if (strncmp(t4_cfg_file, "default", sizeof(t4_cfg_file))) { + snprintf(sc->cfg_file, sizeof(sc->cfg_file), "%s", + pci_get_device(sc->dev) == 0x440a ? "uwire" : t4_cfg_file); + if (strncmp(sc->cfg_file, "default", sizeof(sc->cfg_file))) { char s[32]; - snprintf(s, sizeof(s), "t4fw_cfg_%s", t4_cfg_file); + snprintf(s, sizeof(s), "t4fw_cfg_%s", sc->cfg_file); cfg = firmware_get(s); if (cfg == NULL) { device_printf(sc->dev, "unable to locate %s module, " "will use default config file.\n", s); + snprintf(sc->cfg_file, sizeof(sc->cfg_file), + "%s", "default"); } } rc = partition_resources(sc, cfg ? cfg : default_cfg); if (rc != 0) goto done; /* error message displayed already */ + } else { + snprintf(sc->cfg_file, sizeof(sc->cfg_file), "%s", "notme"); + sc->cfcsum = (u_int)-1; } sc->flags |= FW_OK; @@ -3109,7 +3116,7 @@ t4_sysctls(struct adapter *sc) CTLFLAG_RD, &sc->fw_version, 0, "firmware version"); SYSCTL_ADD_STRING(ctx, children, OID_AUTO, "cf", - CTLFLAG_RD, &t4_cfg_file, 0, "configuration file"); + CTLFLAG_RD, &sc->cfg_file, 0, "configuration file"); SYSCTL_ADD_UINT(ctx, children, OID_AUTO, "cfcsum", CTLFLAG_RD, &sc->cfcsum, 0, "config file checksum"); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 03:23:29 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 630DC543; Sat, 26 Jan 2013 03:23:29 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 3403CB4F; Sat, 26 Jan 2013 03:23:29 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q3NTgg033896; Sat, 26 Jan 2013 03:23:29 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q3NTF3033895; Sat, 26 Jan 2013 03:23:29 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201301260323.r0Q3NTF3033895@svn.freebsd.org> From: Navdeep Parhar Date: Sat, 26 Jan 2013 03:23:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245937 - head/sys/dev/cxgbe/tom X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 03:23:29 -0000 Author: np Date: Sat Jan 26 03:23:28 2013 New Revision: 245937 URL: http://svnweb.freebsd.org/changeset/base/245937 Log: Install an extra hold on the newly allocated synq entry so that it cannot be freed while do_pass_accept_req is running. This closes a race where do_pass_establish on another CPU (the driver chose a different queue for the new tid) expands the synq entry into a full PCB and then releases the only hold on it, all while do_pass_accept_req is still running. MFC after: 3 days Modified: head/sys/dev/cxgbe/tom/t4_listen.c Modified: head/sys/dev/cxgbe/tom/t4_listen.c ============================================================================== --- head/sys/dev/cxgbe/tom/t4_listen.c Sat Jan 26 03:10:28 2013 (r245936) +++ head/sys/dev/cxgbe/tom/t4_listen.c Sat Jan 26 03:23:28 2013 (r245937) @@ -954,7 +954,7 @@ mbuf_to_synqe(struct mbuf *m) return (NULL); synqe->flags = TPF_SYNQE | TPF_SYNQE_NEEDFREE; } else { - synqe = (void *)(m->m_data + m->m_len + tspace - sizeof(*synqe)); + synqe = (void *)(m->m_data + m->m_len + tspace - len); synqe->flags = TPF_SYNQE; } @@ -1335,7 +1335,7 @@ do_pass_accept_req(struct sge_iq *iq, co synqe->lctx = lctx; synqe->syn = m; m = NULL; - refcount_init(&synqe->refcnt, 0); + refcount_init(&synqe->refcnt, 1); /* 1 means extra hold */ synqe->l2e_idx = e->idx; synqe->rcv_bufsize = rx_credits; atomic_store_rel_ptr(&synqe->wr, (uintptr_t)wr); @@ -1381,6 +1381,7 @@ do_pass_accept_req(struct sge_iq *iq, co if (inp) INP_WUNLOCK(inp); + release_synqe(synqe); /* extra hold */ REJECT_PASS_ACCEPT(); } @@ -1395,15 +1396,19 @@ do_pass_accept_req(struct sge_iq *iq, co * this tid because there was no L2T entry for the tid at that * time. Abort it now. The reply to the abort will clean up. */ - CTR5(KTR_CXGBE, "%s: stid %u, tid %u, lctx %p, synqe %p, ABORT", - __func__, stid, tid, lctx, synqe); - send_reset_synqe(tod, synqe); + CTR6(KTR_CXGBE, + "%s: stid %u, tid %u, lctx %p, synqe %p (0x%x), ABORT", + __func__, stid, tid, lctx, synqe, synqe->flags); + if (!(synqe->flags & TPF_SYNQE_EXPANDED)) + send_reset_synqe(tod, synqe); INP_WUNLOCK(inp); + release_synqe(synqe); /* extra hold */ return (__LINE__); } INP_WUNLOCK(inp); + release_synqe(synqe); /* extra hold */ return (0); reject: CTR4(KTR_CXGBE, "%s: stid %u, tid %u, REJECT (%d)", __func__, stid, tid, From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 08:55:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6C3A3BAD; Sat, 26 Jan 2013 08:55:05 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 5EF616D1; Sat, 26 Jan 2013 08:55:05 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0Q8t4qW031334; Sat, 26 Jan 2013 08:55:04 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0Q8t4Ik031333; Sat, 26 Jan 2013 08:55:04 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201301260855.r0Q8t4Ik031333@svn.freebsd.org> From: Andrew Turner Date: Sat, 26 Jan 2013 08:55:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245942 - head/sys/arm/arm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 08:55:05 -0000 Author: andrew Date: Sat Jan 26 08:55:04 2013 New Revision: 245942 URL: http://svnweb.freebsd.org/changeset/base/245942 Log: Align td_frame as it will be placed into the sp register which must be 8 byte aligned on ARM EABI. Modified: head/sys/arm/arm/vm_machdep.c Modified: head/sys/arm/arm/vm_machdep.c ============================================================================== --- head/sys/arm/arm/vm_machdep.c Sat Jan 26 05:27:00 2013 (r245941) +++ head/sys/arm/arm/vm_machdep.c Sat Jan 26 08:55:04 2013 (r245942) @@ -398,6 +398,12 @@ cpu_thread_alloc(struct thread *td) PAGE_SIZE) - 1; td->td_frame = (struct trapframe *) ((u_int)td->td_kstack + USPACE_SVC_STACK_TOP - sizeof(struct pcb)) - 1; + /* + * Ensure td_frame is aligned to an 8 byte boundary as it will be + * placed into the stack pointer which must be 8 byte aligned in + * the ARM EABI. + */ + td->td_frame = (struct trapframe *)((u_int)td->td_frame & ~7); #ifdef __XSCALE__ #ifndef CPU_XSCALE_CORE3 pmap_use_minicache(td->td_kstack, td->td_kstack_pages * PAGE_SIZE); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 10:11:27 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EA4BEC04; Sat, 26 Jan 2013 10:11:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 6B4098E2; Sat, 26 Jan 2013 10:11:26 +0000 (UTC) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id MAA10463; Sat, 26 Jan 2013 12:11:25 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1Tz2jM-000Hic-Li; Sat, 26 Jan 2013 12:11:24 +0200 Message-ID: <5103ABCC.3010706@FreeBSD.org> Date: Sat, 26 Jan 2013 12:11:24 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: John Baldwin Subject: Re: svn commit: r245850 - in head/sys/sparc64: include sparc64 References: <201301232252.r0NMqLxh085107@svn.freebsd.org> In-Reply-To: <201301232252.r0NMqLxh085107@svn.freebsd.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 10:11:28 -0000 on 24/01/2013 00:52 Marius Strobl said the following: > This is due to > the fact that on sparc64, spinlock_enter() only raises the PIL but doesn't > disable interrupts completely. John, I wonder if you are considering pushing your amd64 TPR patch some day... -- Andriy Gapon From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 10:34:18 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 6B1D5384; Sat, 26 Jan 2013 10:34:18 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 52AD8984; Sat, 26 Jan 2013 10:34:18 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QAYIKP061092; Sat, 26 Jan 2013 10:34:18 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QAYI5S061091; Sat, 26 Jan 2013 10:34:18 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201301261034.r0QAYI5S061091@svn.freebsd.org> From: Andriy Gapon Date: Sat, 26 Jan 2013 10:34:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245945 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 10:34:18 -0000 Author: avg Date: Sat Jan 26 10:34:17 2013 New Revision: 245945 URL: http://svnweb.freebsd.org/changeset/base/245945 Log: spa_generate_rootconf: add support for old vdev labels It seems that old ZFS versions (v15) completely omit "vdev_children" property when there is a single child. Reported by: jase Tested by: jase MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c Sat Jan 26 09:56:06 2013 (r245944) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c Sat Jan 26 10:34:17 2013 (r245945) @@ -3792,9 +3792,8 @@ spa_generate_rootconf(const char *name) /* * Multi-vdev root pool configuration discovery is not supported yet. */ - nchildren = 0; - VERIFY(nvlist_lookup_uint64(best_cfg, ZPOOL_CONFIG_VDEV_CHILDREN, - &nchildren) == 0); + nchildren = 1; + nvlist_lookup_uint64(best_cfg, ZPOOL_CONFIG_VDEV_CHILDREN, &nchildren); holes = NULL; nvlist_lookup_uint64_array(best_cfg, ZPOOL_CONFIG_HOLE_ARRAY, &holes, &nholes); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 10:50:04 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C4A08777; Sat, 26 Jan 2013 10:50:04 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B61509ED; Sat, 26 Jan 2013 10:50:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QAo4vt064807; Sat, 26 Jan 2013 10:50:04 GMT (envelope-from avg@svn.freebsd.org) Received: (from avg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QAo4a6064806; Sat, 26 Jan 2013 10:50:04 GMT (envelope-from avg@svn.freebsd.org) Message-Id: <201301261050.r0QAo4a6064806@svn.freebsd.org> From: Andriy Gapon Date: Sat, 26 Jan 2013 10:50:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245946 - head/sys/geom/mirror X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 10:50:04 -0000 Author: avg Date: Sat Jan 26 10:50:04 2013 New Revision: 245946 URL: http://svnweb.freebsd.org/changeset/base/245946 Log: g_mirror: g_getattr() failure should not be fatal This allows to use gmirror e.g. on top of ZVOLs. PR: kern/175323 Submitted by: Alexei.Volkov@softlynx.ru, mav Reported by: Alexei.Volkov@softlynx.ru Tested by: Alexei.Volkov@softlynx.ru Reviewed by: ae, mav, pjd MFC after: 1 week Modified: head/sys/geom/mirror/g_mirror.c Modified: head/sys/geom/mirror/g_mirror.c ============================================================================== --- head/sys/geom/mirror/g_mirror.c Sat Jan 26 10:34:17 2013 (r245945) +++ head/sys/geom/mirror/g_mirror.c Sat Jan 26 10:50:04 2013 (r245946) @@ -457,9 +457,7 @@ g_mirror_init_disk(struct g_mirror_softc disk->d_priority = md->md_priority; disk->d_flags = md->md_dflags; error = g_getattr("GEOM::candelete", disk->d_consumer, &i); - if (error != 0) - goto fail; - if (i) + if (error == 0 && i != 0) disk->d_flags |= G_MIRROR_DISK_FLAG_CANDELETE; if (md->md_provider[0] != '\0') disk->d_flags |= G_MIRROR_DISK_FLAG_HARDCODED; From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 13:44:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1B8644C9; Sat, 26 Jan 2013 13:44:26 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 08849FE4; Sat, 26 Jan 2013 13:44:26 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QDiPww017666; Sat, 26 Jan 2013 13:44:25 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QDiPXW017663; Sat, 26 Jan 2013 13:44:25 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201301261344.r0QDiPXW017663@svn.freebsd.org> From: Hans Petter Selasky Date: Sat, 26 Jan 2013 13:44:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245947 - in head/sys/dev/usb: . quirk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 13:44:26 -0000 Author: hselasky Date: Sat Jan 26 13:44:24 2013 New Revision: 245947 URL: http://svnweb.freebsd.org/changeset/base/245947 Log: Add new USB quirk. PR: usb/175599 Submitted by: Juan J Lopez MFC after: 1 week Modified: head/sys/dev/usb/quirk/usb_quirk.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- head/sys/dev/usb/quirk/usb_quirk.c Sat Jan 26 10:50:04 2013 (r245946) +++ head/sys/dev/usb/quirk/usb_quirk.c Sat Jan 26 13:44:24 2013 (r245947) @@ -111,6 +111,7 @@ static struct usb_quirk_entry usb_quirks USB_QUIRK(ITUNERNET, USBLCD2X20, 0x0000, 0xffff, UQ_HID_IGNORE), USB_QUIRK(ITUNERNET, USBLCD4X20, 0x0000, 0xffff, UQ_HID_IGNORE), USB_QUIRK(LIEBERT, POWERSURE_PXT, 0x0000, 0xffff, UQ_HID_IGNORE), + USB_QUIRK(LIEBERT2, PSI1000, 0x0000, 0xffff, UQ_HID_IGNORE), USB_QUIRK(MGE, UPS1, 0x0000, 0xffff, UQ_HID_IGNORE), USB_QUIRK(MGE, UPS2, 0x0000, 0xffff, UQ_HID_IGNORE), USB_QUIRK(APPLE, IPHONE, 0x0000, 0xffff, UQ_HID_IGNORE), Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Sat Jan 26 10:50:04 2013 (r245946) +++ head/sys/dev/usb/usbdevs Sat Jan 26 13:44:24 2013 (r245947) @@ -581,6 +581,7 @@ vendor CCYU 0x1065 CCYU Technology vendor CURITEL 0x106c Curitel Communications Inc vendor SILABS2 0x10a6 SILABS2 vendor USI 0x10ab USI +vendor LIEBERT2 0x10af Liebert vendor PLX 0x10b5 PLX vendor ASANTE 0x10bd Asante vendor SILABS 0x10c4 Silicon Labs @@ -2426,6 +2427,7 @@ product LEXMARK S2450 0x0009 Optra S 24 /* Liebert products */ product LIEBERT POWERSURE_PXT 0xffff PowerSure Personal XT +product LIEBERT2 PSI1000 0x0004 UPS PSI 1000 FW:08 /* Link Instruments Inc. products */ product LINKINSTRUMENTS MSO19 0xf190 Link Instruments MSO-19 From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 20:16:58 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id DAEB5B4F; Sat, 26 Jan 2013 20:16:58 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id B504EE3B; Sat, 26 Jan 2013 20:16:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QKGwSq038215; Sat, 26 Jan 2013 20:16:58 GMT (envelope-from ian@svn.freebsd.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QKGwu9038214; Sat, 26 Jan 2013 20:16:58 GMT (envelope-from ian@svn.freebsd.org) Message-Id: <201301262016.r0QKGwu9038214@svn.freebsd.org> From: Ian Lepore Date: Sat, 26 Jan 2013 20:16:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245948 - head/sys/arm/arm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 20:16:58 -0000 Author: ian Date: Sat Jan 26 20:16:58 2013 New Revision: 245948 URL: http://svnweb.freebsd.org/changeset/base/245948 Log: Fix a buffer overrun while pre-formatting the names array, perpetrated in the prior commit. Use essentially the same sprintf() statement for both formatting and pre-formatting, and use a format string which eliminates the need for an extra temporary buffer when formatting the name. Noted by: Christoph Mallon Pointy hat to: ian Approved by: cognet (mentor) Modified: head/sys/arm/arm/intr.c Modified: head/sys/arm/arm/intr.c ============================================================================== --- head/sys/arm/arm/intr.c Sat Jan 26 13:44:24 2013 (r245947) +++ head/sys/arm/arm/intr.c Sat Jan 26 20:16:58 2013 (r245948) @@ -68,13 +68,13 @@ void (*arm_post_filter)(void *) = NULL; * consumers of this data. */ void -arm_intrnames_init() +arm_intrnames_init(void) { int i; - memset(intrnames, ' ', NIRQ * INTRNAME_LEN); for (i = 0; i < NIRQ; ++i) - intrnames[i * INTRNAME_LEN - 1] = 0; + snprintf(&intrnames[i * INTRNAME_LEN], INTRNAME_LEN, "%-*s", + INTRNAME_LEN - 1, ""); } void @@ -83,7 +83,6 @@ arm_setup_irqhandler(const char *name, d { struct intr_event *event; int error; - char namebuf[INTRNAME_LEN]; if (irq < 0 || irq >= NIRQ) return; @@ -95,9 +94,8 @@ arm_setup_irqhandler(const char *name, d if (error) return; intr_events[irq] = event; - snprintf(namebuf, sizeof(namebuf), "irq%d: %s", irq, name); - sprintf(intrnames + INTRNAME_LEN * irq, "%-*s", - INTRNAME_LEN - 1, namebuf); + snprintf(&intrnames[irq * INTRNAME_LEN], INTRNAME_LEN, "%-*s", + INTRNAME_LEN - 1, name); } intr_event_add_handler(event, name, filt, hand, arg, intr_priority(flags), flags, cookiep); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 21:29:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5BAC05C0; Sat, 26 Jan 2013 21:29:46 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 4CAD329; Sat, 26 Jan 2013 21:29:46 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QLTkDg059134; Sat, 26 Jan 2013 21:29:46 GMT (envelope-from ian@svn.freebsd.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QLTjdb059133; Sat, 26 Jan 2013 21:29:45 GMT (envelope-from ian@svn.freebsd.org) Message-Id: <201301262129.r0QLTjdb059133@svn.freebsd.org> From: Ian Lepore Date: Sat, 26 Jan 2013 21:29:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245949 - head/usr.sbin/watchdogd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 21:29:46 -0000 Author: ian Date: Sat Jan 26 21:29:45 2013 New Revision: 245949 URL: http://svnweb.freebsd.org/changeset/base/245949 Log: Reduce watchdogd's memory footprint when running daemonized. This uses the recently-added jemalloc(3) feature of setting the lg_chunk tuning option to zero to request that memory be allocated in the smallest chunks possible. Without this option, the default is to initally map 8MB, and then the mlockall() call wires that entire allocation even though the program only uses a few Kbytes of it at runtime. PR: bin/173332 Approved by: cognet (mentor) Modified: head/usr.sbin/watchdogd/watchdogd.c Modified: head/usr.sbin/watchdogd/watchdogd.c ============================================================================== --- head/usr.sbin/watchdogd/watchdogd.c Sat Jan 26 20:16:58 2013 (r245948) +++ head/usr.sbin/watchdogd/watchdogd.c Sat Jan 26 21:29:45 2013 (r245949) @@ -71,6 +71,14 @@ static int nap = 1; static char *test_cmd = NULL; /* + * Ask malloc() to map minimum-sized chunks of virtual address space at a time, + * so that mlockall() won't needlessly wire megabytes of unused memory into the + * process. This must be done using the malloc_conf string so that it gets set + * up before the first allocation, which happens before entry to main(). + */ +const char * malloc_conf = "lg_chunk:0"; + +/* * Periodically pat the watchdog, preventing it from firing. */ int @@ -188,7 +196,7 @@ watchdog_loop(void) if (watchdog_onoff(0) == 0) { end_program = 2; } else { - warnx("Could not stop the watchdog, not exiting"); + warnx("Could not stop the watchdog, not exitting"); end_program = 0; } } From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 21:43:24 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 5D513877; Sat, 26 Jan 2013 21:43:24 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id ECA1AD4; Sat, 26 Jan 2013 21:43:22 +0000 (UTC) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id XAA14862; Sat, 26 Jan 2013 23:43:20 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1TzDWy-000ILx-5p; Sat, 26 Jan 2013 23:43:20 +0200 Message-ID: <51044DF7.10901@FreeBSD.org> Date: Sat, 26 Jan 2013 23:43:19 +0200 From: Andriy Gapon User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130121 Thunderbird/17.0.2 MIME-Version: 1.0 To: Ian Lepore Subject: Re: svn commit: r245949 - head/usr.sbin/watchdogd References: <201301262129.r0QLTjdb059133@svn.freebsd.org> In-Reply-To: <201301262129.r0QLTjdb059133@svn.freebsd.org> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 21:43:24 -0000 on 26/01/2013 23:29 Ian Lepore said the following: > @@ -188,7 +196,7 @@ watchdog_loop(void) > if (watchdog_onoff(0) == 0) { > end_program = 2; > } else { > - warnx("Could not stop the watchdog, not exiting"); > + warnx("Could not stop the watchdog, not exitting"); > end_program = 0; > } > } Stray chunk that introduces a spelling mistake? -- Andriy Gapon From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 21:50:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 7D303AC9; Sat, 26 Jan 2013 21:50:53 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 6DE9710F; Sat, 26 Jan 2013 21:50:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QLor06066524; Sat, 26 Jan 2013 21:50:53 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QLorLa066523; Sat, 26 Jan 2013 21:50:53 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201301262150.r0QLorLa066523@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sat, 26 Jan 2013 21:50:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245950 - head/sys/fs/ext2fs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 21:50:53 -0000 Author: pfg Date: Sat Jan 26 21:50:52 2013 New Revision: 245950 URL: http://svnweb.freebsd.org/changeset/base/245950 Log: Cosmetical off-by-one Technically, the case when all the blocks are released is not a sanity check. Move further the comment while here. Suggested by: bde MFC after: 3 days Modified: head/sys/fs/ext2fs/ext2_inode.c Modified: head/sys/fs/ext2fs/ext2_inode.c ============================================================================== --- head/sys/fs/ext2fs/ext2_inode.c Sat Jan 26 21:29:45 2013 (r245949) +++ head/sys/fs/ext2fs/ext2_inode.c Sat Jan 26 21:50:52 2013 (r245950) @@ -341,9 +341,9 @@ done: * Put back the real size. */ oip->i_size = length; - if (oip->i_blocks > blocksreleased) + if (oip->i_blocks >= blocksreleased) oip->i_blocks -= blocksreleased; - else /* sanity */ + else /* sanity */ oip->i_blocks = 0; oip->i_flag |= IN_CHANGE; vnode_pager_setsize(ovp, length); From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 21:53:17 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 8672DC48 for ; Sat, 26 Jan 2013 21:53:17 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com [209.85.217.181]) by mx1.freebsd.org (Postfix) with ESMTP id 1190211F for ; Sat, 26 Jan 2013 21:53:16 +0000 (UTC) Received: by mail-lb0-f181.google.com with SMTP id gm6so2347892lbb.40 for ; Sat, 26 Jan 2013 13:53:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=IflejwAQUQr218lZxZhqDqAZoio5rR8l3gZU65h5zf0=; b=jvc+VKDjNmeTh/EXHNe/X/4F3QedJXRxpHNn+kuun80/eUKmH9WHfVImbzA7gXFzEd BSVcnbiSqyT/B825qBxgu2GmKJwLgORd5WSm3adqLQfHIJg/CBDcg/tl8Cku69R42cBp lT76Qe3/9BaFGgKknR9Y98TrUcy6SsdjZbXg8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=IflejwAQUQr218lZxZhqDqAZoio5rR8l3gZU65h5zf0=; b=pzjkipbvCa0x4w2h/bbizhmxD0B8GUjgxPqhFQ+leRSRnVuhdyxLV0jWi0aLHFUHfq NWmtaJJTPmgA7ISPLYR0OmoAglpn+yrJ4daQNbO30BPrkYA0vWlnlayApFk7/gcggLqt 7/fBW3f+Ej3JHJP0p6XdVbekEmGGddsjK08MbNI+Owd74gw5aZuvtKAI5G03+gyoWkq/ SYkuFojCo+WlcXvkzccdW/jFnx+CvAKBe76QPGxso59fwv64CTx9iA7EL2cST+1JrHYb C4+tWmEk8RE2e/oKJf73tAVqNKY/fi//OII9R4xhpAOu0iIFjSGalLE8tzN3aUD0ysdu xwrQ== X-Received: by 10.112.87.66 with SMTP id v2mr1839849lbz.130.1359237195551; Sat, 26 Jan 2013 13:53:15 -0800 (PST) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.112.100.164 with HTTP; Sat, 26 Jan 2013 13:52:44 -0800 (PST) In-Reply-To: <201301262129.r0QLTjdb059133@svn.freebsd.org> References: <201301262129.r0QLTjdb059133@svn.freebsd.org> From: Eitan Adler Date: Sat, 26 Jan 2013 16:52:44 -0500 X-Google-Sender-Auth: B6uiO4rxenCx40Tc5OVBsSU1hN4 Message-ID: Subject: Re: svn commit: r245949 - head/usr.sbin/watchdogd To: Ian Lepore Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQnntbu9Nsv/6tMlJKv9AFONMFtH2YFRlQohVRT5coEPzk7nfHXXc+4+AjyoR7UIAeJibgmn Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 21:53:17 -0000 > @@ -188,7 +196,7 @@ watchdog_loop(void) > if (watchdog_onoff(0) == 0) { > end_program = 2; > } else { > - warnx("Could not stop the watchdog, not exiting"); > + warnx("Could not stop the watchdog, not exitting"); Are you sure? -- Eitan Adler Source, Ports, Doc committer Bugmeister, Ports Security teams From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 22:01:01 2013 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D23C0E3B; Sat, 26 Jan 2013 22:01:01 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from duck.symmetricom.us (duck.symmetricom.us [206.168.13.214]) by mx1.freebsd.org (Postfix) with ESMTP id 51E0414F; Sat, 26 Jan 2013 22:01:01 +0000 (UTC) Received: from damnhippie.dyndns.org (daffy.symmetricom.us [206.168.13.218]) by duck.symmetricom.us (8.14.6/8.14.6) with ESMTP id r0QM0rHX017300; Sat, 26 Jan 2013 15:00:53 -0700 (MST) (envelope-from ian@FreeBSD.org) Received: from [172.22.42.240] (revolution.hippie.lan [172.22.42.240]) by damnhippie.dyndns.org (8.14.3/8.14.3) with ESMTP id r0QM0ovM018579; Sat, 26 Jan 2013 15:00:50 -0700 (MST) (envelope-from ian@FreeBSD.org) Subject: Re: svn commit: r245949 - head/usr.sbin/watchdogd From: Ian Lepore To: Eitan Adler In-Reply-To: References: <201301262129.r0QLTjdb059133@svn.freebsd.org> Content-Type: text/plain; charset="us-ascii" Date: Sat, 26 Jan 2013 15:00:50 -0700 Message-ID: <1359237650.93359.2.camel@revolution.hippie.lan> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 22:01:01 -0000 On Sat, 2013-01-26 at 16:52 -0500, Eitan Adler wrote: > > @@ -188,7 +196,7 @@ watchdog_loop(void) > > if (watchdog_onoff(0) == 0) { > > end_program = 2; > > } else { > > - warnx("Could not stop the watchdog, not exiting"); > > + warnx("Could not stop the watchdog, not exitting"); > > Are you sure? > > Doh! I had the same fix in two sandboxes, so naturally with 50:50 odds I inevitably chose to commit from the outdated one. Fix upcoming... -- Ian From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 22:02:40 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id F06FAFC5; Sat, 26 Jan 2013 22:02:40 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id E3076168; Sat, 26 Jan 2013 22:02:40 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QM2e9M069762; Sat, 26 Jan 2013 22:02:40 GMT (envelope-from ian@svn.freebsd.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QM2eTA069760; Sat, 26 Jan 2013 22:02:40 GMT (envelope-from ian@svn.freebsd.org) Message-Id: <201301262202.r0QM2eTA069760@svn.freebsd.org> From: Ian Lepore Date: Sat, 26 Jan 2013 22:02:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245951 - head/usr.sbin/watchdogd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 22:02:41 -0000 Author: ian Date: Sat Jan 26 22:02:40 2013 New Revision: 245951 URL: http://svnweb.freebsd.org/changeset/base/245951 Log: Revert accidental regression to previous misspelling. Approved by: cognet (mentor) Modified: head/usr.sbin/watchdogd/watchdogd.c Modified: head/usr.sbin/watchdogd/watchdogd.c ============================================================================== --- head/usr.sbin/watchdogd/watchdogd.c Sat Jan 26 21:50:52 2013 (r245950) +++ head/usr.sbin/watchdogd/watchdogd.c Sat Jan 26 22:02:40 2013 (r245951) @@ -196,7 +196,7 @@ watchdog_loop(void) if (watchdog_onoff(0) == 0) { end_program = 2; } else { - warnx("Could not stop the watchdog, not exitting"); + warnx("Could not stop the watchdog, not exiting"); end_program = 0; } } From owner-svn-src-head@FreeBSD.ORG Sat Jan 26 22:08:26 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1E2BF215; Sat, 26 Jan 2013 22:08:26 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F2307193; Sat, 26 Jan 2013 22:08:25 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r0QM8Mav070790; Sat, 26 Jan 2013 22:08:22 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r0QM8MMD070788; Sat, 26 Jan 2013 22:08:22 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201301262208.r0QM8MMD070788@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Sat, 26 Jan 2013 22:08:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245952 - in head: contrib/binutils/config contrib/bsnmp/lib contrib/bsnmp/snmp_target contrib/bsnmp/snmp_usm contrib/bsnmp/snmp_vacm contrib/dialog/samples/copifuncs contrib/ee contrib... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Jan 2013 22:08:26 -0000 Author: pfg Date: Sat Jan 26 22:08:21 2013 New Revision: 245952 URL: http://svnweb.freebsd.org/changeset/base/245952 Log: Clean some 'svn:executable' properties in the tree. Submitted by: Christoph Mallon MFC after: 3 days Modified: Directory Properties: head/contrib/binutils/config/acinclude.m4 (props changed) head/contrib/bsnmp/lib/tc.def (props changed) head/contrib/bsnmp/snmp_target/snmp_target.3 (props changed) head/contrib/bsnmp/snmp_target/target_snmp.c (props changed) head/contrib/bsnmp/snmp_target/target_tree.def (props changed) head/contrib/bsnmp/snmp_usm/snmp_usm.3 (props changed) head/contrib/bsnmp/snmp_usm/usm_snmp.c (props changed) head/contrib/bsnmp/snmp_usm/usm_tree.def (props changed) head/contrib/bsnmp/snmp_vacm/snmp_vacm.3 (props changed) head/contrib/bsnmp/snmp_vacm/vacm_snmp.c (props changed) head/contrib/bsnmp/snmp_vacm/vacm_tree.def (props changed) head/contrib/dialog/samples/copifuncs/common.funcs (props changed) head/contrib/dialog/samples/copifuncs/copi.ifman1 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifman2 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifmcfg2 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifmcfg4 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifmcfg5 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifpoll2 (props changed) head/contrib/dialog/samples/copifuncs/copi.ifreq2 (props changed) head/contrib/dialog/samples/copifuncs/copi.sendifm2 (props changed) head/contrib/ee/Makefile (props changed) head/contrib/ee/ee.c (props changed) head/contrib/expat/doc/expat.png (props changed) head/contrib/expat/doc/valid-xhtml10.png (props changed) head/contrib/expat/lib/expat_external.h (props changed) head/contrib/expat/tests/benchmark/README.txt (props changed) head/contrib/expat/tests/benchmark/benchmark.c (props changed) head/contrib/expat/tests/benchmark/benchmark.dsp (props changed) head/contrib/expat/tests/benchmark/benchmark.dsw (props changed) head/contrib/expat/tests/minicheck.c (props changed) head/contrib/expat/tests/minicheck.h (props changed) head/contrib/expat/tests/runtestspp.cpp (props changed) head/contrib/expat/xmlwf/codepage.c (props changed) head/contrib/expat/xmlwf/codepage.h (props changed) head/contrib/expat/xmlwf/ct.c (props changed) head/contrib/expat/xmlwf/filemap.h (props changed) head/contrib/expat/xmlwf/readfilemap.c (props changed) head/contrib/expat/xmlwf/unixfilemap.c (props changed) head/contrib/expat/xmlwf/win32filemap.c (props changed) head/contrib/expat/xmlwf/xmlfile.c (props changed) head/contrib/expat/xmlwf/xmlfile.h (props changed) head/contrib/expat/xmlwf/xmlmime.c (props changed) head/contrib/expat/xmlwf/xmlmime.h (props changed) head/contrib/expat/xmlwf/xmltchar.h (props changed) head/contrib/expat/xmlwf/xmlurl.h (props changed) head/contrib/expat/xmlwf/xmlwf.c (props changed) head/contrib/expat/xmlwf/xmlwin32url.cxx (props changed) head/contrib/gcc/config/i386/host-cygwin.c (props changed) head/contrib/gcc/config/i386/winnt-cxx.c (props changed) head/contrib/gcc/config/i386/winnt-stubs.c (props changed) head/contrib/gdb/gdb/config/i386/nm-nto.h (props changed) head/contrib/gdb/gdb/config/i386/nto.mh (props changed) head/contrib/gdb/gdb/config/i386/nto.mt (props changed) head/contrib/gdb/gdb/config/i386/tm-nto.h (props changed) head/contrib/gdb/gdb/config/tm-nto.h (props changed) head/contrib/gdb/gdb/i386-nto-tdep.c (props changed) head/contrib/gdb/gdb/nto-procfs.c (props changed) head/contrib/gdb/gdb/nto-tdep.c (props changed) head/contrib/gdb/gdb/nto-tdep.h (props changed) head/contrib/gdb/gdb/proc-api.c (props changed) head/contrib/gdb/gdb/proc-events.c (props changed) head/contrib/gdb/gdb/proc-flags.c (props changed) head/contrib/gdb/gdb/proc-why.c (props changed) head/contrib/gdb/gdb/uw-thread.c (props changed) head/contrib/ipfilter/FreeBSD-4.0/ipv6-patch (props changed) head/contrib/ipfilter/FreeBSD-4.0/ipv6-patch-4.0 (props changed) head/contrib/libpcap/configure.in (props changed) head/contrib/llvm/lib/Target/Hexagon/HexagonAsmPrinter.h (props changed) head/contrib/ntp/html/drivers/driver44.html (props changed) head/contrib/ntp/include/icom.h (props changed) head/contrib/ntp/readme.y2kfixes (props changed) head/contrib/ntp/scripts/stats/clock.awk (props changed) head/contrib/ntp/scripts/stats/dupe.awk (props changed) head/contrib/ntp/scripts/stats/ensemble.S (props changed) head/contrib/ntp/scripts/stats/ensemble.awk (props changed) head/contrib/ntp/scripts/stats/etf.S (props changed) head/contrib/ntp/scripts/stats/etf.awk (props changed) head/contrib/ntp/scripts/stats/itf.S (props changed) head/contrib/ntp/scripts/stats/itf.awk (props changed) head/contrib/ntp/scripts/stats/loop.S (props changed) head/contrib/ntp/scripts/stats/loop.awk (props changed) head/contrib/ntp/scripts/stats/loop_summary (props changed) head/contrib/ntp/scripts/stats/peer.awk (props changed) head/contrib/ntp/scripts/stats/psummary.awk (props changed) head/contrib/ntp/scripts/stats/tdata.S (props changed) head/contrib/ntp/scripts/stats/tdata.awk (props changed) head/contrib/tcpdump/bgp.h (props changed) head/contrib/tcpdump/configure.in (props changed) head/contrib/tcpdump/ipproto.c (props changed) head/contrib/tcpdump/l2vpn.c (props changed) head/contrib/tcpdump/l2vpn.h (props changed) head/contrib/tcpdump/nlpid.c (props changed) head/contrib/tcpdump/print-syslog.c (props changed) head/crypto/heimdal/doc/vars.texi (props changed) head/crypto/openssl/crypto/bn/asm/s390x.S (props changed) head/crypto/openssl/crypto/bn/bn_const.c (props changed) head/crypto/openssl/crypto/ocsp/ocsp_cl.c (props changed) head/crypto/openssl/crypto/ocsp/ocsp_ext.c (props changed) head/crypto/openssl/crypto/ocsp/ocsp_lib.c (props changed) head/crypto/openssl/crypto/ocsp/ocsp_srv.c (props changed) head/crypto/openssl/crypto/rand/rand_lcl.h (props changed) head/crypto/openssl/crypto/vms_rms.h (props changed) head/crypto/openssl/util/libeay.num (props changed) head/crypto/openssl/util/ssleay.num (props changed) head/sys/dev/ath/ath_hal/ar5211/boss.ini (props changed) head/sys/dev/bktr/CHANGELOG.TXT (props changed) head/sys/dev/ixgbe/ixgbe_82598.h (props changed) head/sys/dev/ixgbe/ixgbe_82599.h (props changed) head/sys/dev/ixgbe/ixgbe_x540.c (props changed) head/sys/dev/ixgbe/ixgbe_x540.h (props changed) head/sys/fs/ext2fs/ext2_dinode.h (props changed) head/sys/fs/ext2fs/ext2_dir.h (props changed) head/sys/fs/ext2fs/ext2fs.h (props changed) head/sys/mips/rmi/msgring_xls.cfg (props changed) head/sys/modules/digi/Makefile (props changed) head/sys/modules/digi/Makefile.inc (props changed) head/sys/modules/isci/Makefile (props changed) head/sys/modules/sound/driver/ich/Makefile (props changed) head/usr.sbin/bsnmpd/modules/snmp_target/Makefile (props changed) head/usr.sbin/bsnmpd/modules/snmp_usm/Makefile (props changed) head/usr.sbin/bsnmpd/modules/snmp_vacm/Makefile (props changed) head/usr.sbin/bsnmpd/tools/libbsnmptools/bsnmptools.c (props changed)