From owner-svn-src-head@freebsd.org Sun May 21 00:06:38 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3CA85D6B02A; Sun, 21 May 2017 00:06:38 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0711D907; Sun, 21 May 2017 00:06:37 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4L06bUj092895; Sun, 21 May 2017 00:06:37 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4L06bGq092894; Sun, 21 May 2017 00:06:37 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201705210006.v4L06bGq092894@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Sun, 21 May 2017 00:06:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318590 - head/sys/compat/linuxkpi/common/include/asm 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.23 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, 21 May 2017 00:06:38 -0000 Author: markj Date: Sun May 21 00:06:36 2017 New Revision: 318590 URL: https://svnweb.freebsd.org/changeset/base/318590 Log: Add get_cpu() and put_cpu(). MFC after: 1 week Modified: head/sys/compat/linuxkpi/common/include/asm/smp.h Modified: head/sys/compat/linuxkpi/common/include/asm/smp.h ============================================================================== --- head/sys/compat/linuxkpi/common/include/asm/smp.h Sat May 20 23:25:07 2017 (r318589) +++ head/sys/compat/linuxkpi/common/include/asm/smp.h Sun May 21 00:06:36 2017 (r318590) @@ -37,4 +37,12 @@ int linux_wbinvd_on_all_cpus(void); #endif +#define get_cpu() ({ \ + sched_pin(); \ + PCPU_GET(cpuid); \ +}) + +#define put_cpu() \ + sched_unpin() + #endif /* _ASM_SMP_H_ */ From owner-svn-src-head@freebsd.org Sun May 21 14:05:34 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BA67FD77794; Sun, 21 May 2017 14:05:34 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7D6281CCD; Sun, 21 May 2017 14:05:34 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LE5Xf9039150; Sun, 21 May 2017 14:05:33 GMT (envelope-from jilles@FreeBSD.org) Received: (from jilles@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LE5XtD039146; Sun, 21 May 2017 14:05:33 GMT (envelope-from jilles@FreeBSD.org) Message-Id: <201705211405.v4LE5XtD039146@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jilles set sender to jilles@FreeBSD.org using -f From: Jilles Tjoelker Date: Sun, 21 May 2017 14:05:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318591 - in head: etc/mtree usr.bin/compress usr.bin/compress/tests 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.23 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, 21 May 2017 14:05:34 -0000 Author: jilles Date: Sun May 21 14:05:32 2017 New Revision: 318591 URL: https://svnweb.freebsd.org/changeset/base/318591 Log: compress: Add basic tests. Added: head/usr.bin/compress/tests/ head/usr.bin/compress/tests/Makefile (contents, props changed) head/usr.bin/compress/tests/compress_test.sh (contents, props changed) Modified: head/etc/mtree/BSD.tests.dist head/usr.bin/compress/Makefile Modified: head/etc/mtree/BSD.tests.dist ============================================================================== --- head/etc/mtree/BSD.tests.dist Sun May 21 00:06:36 2017 (r318590) +++ head/etc/mtree/BSD.tests.dist Sun May 21 14:05:32 2017 (r318591) @@ -606,6 +606,8 @@ .. cmp .. + compress + .. cpio .. col Modified: head/usr.bin/compress/Makefile ============================================================================== --- head/usr.bin/compress/Makefile Sun May 21 00:06:36 2017 (r318590) +++ head/usr.bin/compress/Makefile Sun May 21 14:05:32 2017 (r318591) @@ -1,6 +1,8 @@ # @(#)Makefile 8.2 (Berkeley) 4/17/94 # $FreeBSD$ +.include + PROG= compress SRCS= compress.c zopen.c LINKS= ${BINDIR}/compress ${BINDIR}/uncompress @@ -9,4 +11,8 @@ MLINKS= compress.1 uncompress.1 # XXX zopen is not part of libc # MAN=zopen.3 +.if ${MK_TESTS} != "no" +SUBDIR+= tests +.endif + .include Added: head/usr.bin/compress/tests/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/compress/tests/Makefile Sun May 21 14:05:32 2017 (r318591) @@ -0,0 +1,7 @@ +# $FreeBSD$ + +PACKAGE= tests + +ATF_TESTS_SH= compress_test + +.include Added: head/usr.bin/compress/tests/compress_test.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/compress/tests/compress_test.sh Sun May 21 14:05:32 2017 (r318591) @@ -0,0 +1,174 @@ +# Copyright (c) 2017 Jilles Tjoelker +# 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$ + +atf_test_case uncompress_file_1 +uncompress_file_1_head() +{ + atf_set "descr" \ + "Test uncompress without options, filename with .Z" +} +uncompress_file_1_body() +{ + printf '%01000d\n' 7 >expectfile1 + printf "\ +\037\235\220\060\002\012\034\110\260\240\301\203\010\023\052\134\ +\310\260\241\303\207\020\043\112\234\110\261\242\305\213\030\063\ +\152\334\310\261\243\307\217\040\103\212\034\111\262\244\311\223\ +\050\123\252\134\211\360\206\002" >file1.Z + atf_check uncompress file1.Z + atf_check cmp file1 expectfile1 + atf_check test ! -e file1.Z +} + +atf_test_case uncompress_file_2 +uncompress_file_2_head() +{ + atf_set "descr" \ + "Test uncompress without options, filename without .Z" +} +uncompress_file_2_body() +{ + printf '%01000d\n' 7 >expectfile1 + printf "\ +\037\235\220\060\002\012\034\110\260\240\301\203\010\023\052\134\ +\310\260\241\303\207\020\043\112\234\110\261\242\305\213\030\063\ +\152\334\310\261\243\307\217\040\103\212\034\111\262\244\311\223\ +\050\123\252\134\211\360\206\002" >file1.Z + atf_check uncompress file1 + atf_check cmp file1 expectfile1 + atf_check test ! -e file1.Z +} + +atf_test_case uncompress_stdio_1 +uncompress_stdio_1_head() +{ + atf_set "descr" \ + "Test uncompress without parameters" +} +uncompress_stdio_1_body() +{ + printf '%01000d\n' 7 >expectfile1 + printf "\ +\037\235\220\060\002\012\034\110\260\240\301\203\010\023\052\134\ +\310\260\241\303\207\020\043\112\234\110\261\242\305\213\030\063\ +\152\334\310\261\243\307\217\040\103\212\034\111\262\244\311\223\ +\050\123\252\134\211\360\206\002" >file1.Z + atf_check -o file:expectfile1 -x 'uncompress expectfile1 + printf "\ +\037\235\220\060\002\012\034\110\260\240\301\203\010\023\052\134\ +\310\260\241\303\207\020\043\112\234\110\261\242\305\213\030\063\ +\152\334\310\261\243\307\217\040\103\212\034\111\262\244\311\223\ +\050\123\252\134\211\360\206\002" >file1.Z + atf_check -o file:expectfile1 uncompress -c file1.Z + atf_check test -e file1.Z + atf_check test ! -e file1 +} + +atf_test_case compress_uncompress_stdio_1 +compress_uncompress_stdio_1_head() +{ + atf_set "descr" \ + "Test compressing and uncompressing some data, using stdio" +} +compress_uncompress_stdio_1_body() +{ + printf '%01000d\n' 7 8 >expectfile1 + atf_check -x 'compress file1.Z' + atf_check -o file:expectfile1 uncompress -c file1.Z +} + +atf_test_case compress_uncompress_minusc_1 +compress_uncompress_minusc_1_head() +{ + atf_set "descr" \ + "Test compressing and uncompressing some data, using -c" +} +compress_uncompress_minusc_1_body() +{ + printf '%01000d\n' 7 8 >expectfile1 + atf_check -x 'compress -c expectfile1 >file1.Z' + atf_check -o file:expectfile1 uncompress -c file1.Z +} + +atf_test_case compress_uncompress_file_1 +compress_uncompress_file_1_head() +{ + atf_set "descr" \ + "Test compressing and uncompressing some data, passing one filename" +} +compress_uncompress_file_1_body() +{ + printf '%01000d\n' 7 8 >expectfile1 + cp expectfile1 file1 + atf_check compress file1 + atf_check -s exit:1 cmp -s file1.Z expectfile1 + atf_check uncompress file1.Z + atf_check cmp file1 expectfile1 +} + +atf_test_case compress_uncompress_file_2 +compress_uncompress_file_2_head() +{ + atf_set "descr" \ + "Test compressing and uncompressing some data, passing two filenames" +} +compress_uncompress_file_2_body() +{ + printf '%01000d\n' 7 8 >expectfile1 + printf '%01000d\n' 8 7 >expectfile2 + cp expectfile1 file1 + cp expectfile2 file2 + atf_check compress file1 file2 + atf_check -s exit:1 cmp -s file1.Z expectfile1 + atf_check -s exit:1 cmp -s file2.Z expectfile2 + atf_check -s exit:1 cmp -s file1.Z file2.Z + atf_check uncompress file1.Z file2.Z + atf_check cmp file1 expectfile1 + atf_check cmp file2 expectfile2 +} + +atf_init_test_cases() +{ + atf_add_test_case uncompress_file_1 + atf_add_test_case uncompress_file_2 + atf_add_test_case uncompress_stdio_1 + atf_add_test_case uncompress_minusc_1 + atf_add_test_case compress_uncompress_stdio_1 + atf_add_test_case compress_uncompress_minusc_1 + atf_add_test_case compress_uncompress_file_1 + atf_add_test_case compress_uncompress_file_2 +} From owner-svn-src-head@freebsd.org Sun May 21 14:35:17 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E39FD77FA8; Sun, 21 May 2017 14:35:17 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4F6C7F59; Sun, 21 May 2017 14:35:17 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LEZG5E052332; Sun, 21 May 2017 14:35:16 GMT (envelope-from jilles@FreeBSD.org) Received: (from jilles@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LEZG53052330; Sun, 21 May 2017 14:35:16 GMT (envelope-from jilles@FreeBSD.org) Message-Id: <201705211435.v4LEZG53052330@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jilles set sender to jilles@FreeBSD.org using -f From: Jilles Tjoelker Date: Sun, 21 May 2017 14:35:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318592 - in head/usr.bin/compress: . tests 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.23 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, 21 May 2017 14:35:17 -0000 Author: jilles Date: Sun May 21 14:35:16 2017 New Revision: 318592 URL: https://svnweb.freebsd.org/changeset/base/318592 Log: compress: Allow uncompress -c with multiple pathnames, as required by POSIX. Per POSIX, allow passing multiple pathnames to uncompress -c, concatenating the uncompressed data. Passing multiple pathnames to compress -c remains disallowed, since the result cannot be decompressed. PR: 219387 Reported by: Jörg Schilling Modified: head/usr.bin/compress/compress.c head/usr.bin/compress/tests/compress_test.sh Modified: head/usr.bin/compress/compress.c ============================================================================== --- head/usr.bin/compress/compress.c Sun May 21 14:05:32 2017 (r318591) +++ head/usr.bin/compress/compress.c Sun May 21 14:35:16 2017 (r318592) @@ -129,7 +129,7 @@ main(int argc, char *argv[]) exit (eval); } - if (cat == 1 && argc > 1) + if (cat == 1 && style == COMPRESS && argc > 1) errx(1, "the -c option permits only a single file argument"); for (; *argv; ++argv) Modified: head/usr.bin/compress/tests/compress_test.sh ============================================================================== --- head/usr.bin/compress/tests/compress_test.sh Sun May 21 14:05:32 2017 (r318591) +++ head/usr.bin/compress/tests/compress_test.sh Sun May 21 14:35:16 2017 (r318592) @@ -161,6 +161,27 @@ compress_uncompress_file_2_body() atf_check cmp file2 expectfile2 } +atf_test_case compress_uncompress_file_minusc_1 +compress_uncompress_file_minusc_1_head() +{ + atf_set "descr" \ + "Test compressing and uncompressing some data, passing two filenames to uncompress -c" +} +compress_uncompress_file_minusc_1_body() +{ + printf '%01000d\n' 7 8 >expectfile1 + printf '%01000d\n' 8 7 >expectfile2 + cp expectfile1 file1 + cp expectfile2 file2 + atf_check compress file1 file2 + atf_check -s exit:1 cmp -s file1.Z expectfile1 + atf_check -s exit:1 cmp -s file2.Z expectfile2 + atf_check -s exit:1 cmp -s file1.Z file2.Z + atf_check -x 'uncompress -c file1.Z file2.Z >all' + atf_check -x 'cat expectfile1 expectfile2 >expectall' + atf_check cmp all expectall +} + atf_init_test_cases() { atf_add_test_case uncompress_file_1 @@ -171,4 +192,5 @@ atf_init_test_cases() atf_add_test_case compress_uncompress_minusc_1 atf_add_test_case compress_uncompress_file_1 atf_add_test_case compress_uncompress_file_2 + atf_add_test_case compress_uncompress_file_minusc_1 } From owner-svn-src-head@freebsd.org Sun May 21 15:37:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 625B7D771A2; Sun, 21 May 2017 15:37:10 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3D45E154F; Sun, 21 May 2017 15:37:10 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LFb9Xx078497; Sun, 21 May 2017 15:37:09 GMT (envelope-from asomers@FreeBSD.org) Received: (from asomers@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LFb9Z5078495; Sun, 21 May 2017 15:37:09 GMT (envelope-from asomers@FreeBSD.org) Message-Id: <201705211537.v4LFb9Z5078495@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: asomers set sender to asomers@FreeBSD.org using -f From: Alan Somers Date: Sun, 21 May 2017 15:37:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318593 - head/tests/sys/aio 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.23 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, 21 May 2017 15:37:10 -0000 Author: asomers Date: Sun May 21 15:37:08 2017 New Revision: 318593 URL: https://svnweb.freebsd.org/changeset/base/318593 Log: Fix build of AIO tests with -DDEBUG Also, redefine some constants for clarity. No functional change. MFC after: 1 week Modified: head/tests/sys/aio/aio_kqueue_test.c head/tests/sys/aio/lio_kqueue_test.c Modified: head/tests/sys/aio/aio_kqueue_test.c ============================================================================== --- head/tests/sys/aio/aio_kqueue_test.c Sun May 21 14:35:16 2017 (r318592) +++ head/tests/sys/aio/aio_kqueue_test.c Sun May 21 15:37:08 2017 (r318593) @@ -163,7 +163,8 @@ main (int argc, char *argv[]) printf("kevent %d %d errno %d return.ident %p " "return.data %p return.udata %p %p\n", i, result, error, - kq_returned.ident, kq_returned.data, + (void*)kq_returned.ident, + (void*)kq_returned.data, kq_returned.udata, kq_iocb); #endif @@ -171,7 +172,7 @@ main (int argc, char *argv[]) if (kq_iocb) break; #ifdef DEBUG - printf("Try again left %d out of %d %d\n", + printf("Try again left %d out of %lu %d\n", pending, nitems(iocb), cancel); #endif } Modified: head/tests/sys/aio/lio_kqueue_test.c ============================================================================== --- head/tests/sys/aio/lio_kqueue_test.c Sun May 21 14:35:16 2017 (r318592) +++ head/tests/sys/aio/lio_kqueue_test.c Sun May 21 15:37:08 2017 (r318593) @@ -55,7 +55,8 @@ #define PATH_TEMPLATE "aio.XXXXXXXXXX" #define LIO_MAX 5 -#define MAX_IOCBS LIO_MAX * 16 +#define IOCBS_PER_LIO 16 +#define MAX_IOCBS (LIO_MAX * IOCBS_PER_LIO) #define MAX_RUNS 300 int @@ -103,9 +104,9 @@ main(int argc, char *argv[]) #endif for (j = 0; j < LIO_MAX; j++) { lio[j] = - malloc(sizeof(struct aiocb *) * MAX_IOCBS/LIO_MAX); - for (i = 0; i < MAX_IOCBS / LIO_MAX; i++) { - k = (MAX_IOCBS / LIO_MAX * j) + i; + malloc(sizeof(struct aiocb *) * IOCBS_PER_LIO); + for (i = 0; i < IOCBS_PER_LIO; i++) { + k = (IOCBS_PER_LIO * j) + i; lio[j][i] = iocb[k] = calloc(1, sizeof(struct aiocb)); iocb[k]->aio_nbytes = sizeof(buffer); @@ -115,7 +116,7 @@ main(int argc, char *argv[]) = iocb[k]->aio_nbytes * k * (run + 1); #ifdef DEBUG - printf("hello iocb[k] %d\n", + printf("hello iocb[k] %ld\n", iocb[k]->aio_offset); #endif iocb[k]->aio_lio_opcode = LIO_WRITE; @@ -125,11 +126,11 @@ main(int argc, char *argv[]) sig.sigev_notify = SIGEV_KEVENT; time(&time1); result = lio_listio(LIO_NOWAIT, lio[j], - MAX_IOCBS / LIO_MAX, &sig); + IOCBS_PER_LIO, &sig); error = errno; time(&time2); #ifdef DEBUG - printf("Time %d %d %d result -> %d\n", + printf("Time %ld %ld %ld result -> %d\n", time1, time2, time2-time1, result); #endif if (result != 0) { @@ -169,7 +170,8 @@ main(int argc, char *argv[]) printf("kevent %d %d errno %d return.ident %p " "return.data %p return.udata %p %p\n", i, result, error, - kq_returned.ident, kq_returned.data, + (void*)kq_returned.ident, + (void*)kq_returned.data, kq_returned.udata, lio[j]); #endif From owner-svn-src-head@freebsd.org Sun May 21 17:07:14 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 11E2CD77EE2; Sun, 21 May 2017 17:07:14 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BD98B68F; Sun, 21 May 2017 17:07:13 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LH7CAo016262; Sun, 21 May 2017 17:07:12 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LH7CbN016259; Sun, 21 May 2017 17:07:12 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705211707.v4LH7CbN016259@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 21 May 2017 17:07:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318594 - in head: lib lib/libc++experimental tools/build/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.23 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, 21 May 2017 17:07:14 -0000 Author: dim Date: Sun May 21 17:07:12 2017 New Revision: 318594 URL: https://svnweb.freebsd.org/changeset/base/318594 Log: Add libc++experimental.a for std::experimental support This adds a separate library for supporting std::experimental features. It is purposefully static, and must be explicitly linked into programs using -lc++experimental. PLEASE NOTE: there is NO WARRANTY as to any stability or continuing existence of the features in the std::experimental parts of the C++ library! Reviewed by: ed Differential Revision: https://reviews.freebsd.org/D10840 Added: head/lib/libc++experimental/ head/lib/libc++experimental/Makefile (contents, props changed) Modified: head/lib/Makefile head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/lib/Makefile ============================================================================== --- head/lib/Makefile Sun May 21 15:37:08 2017 (r318593) +++ head/lib/Makefile Sun May 21 17:07:12 2017 (r318594) @@ -156,7 +156,7 @@ _libclang_rt= libclang_rt .if ${MK_LIBCPLUSPLUS} != "no" _libcxxrt= libcxxrt -_libcplusplus= libc++ +_libcplusplus= libc++ libc++experimental .endif SUBDIR.${MK_EFI}+= libefivar Added: head/lib/libc++experimental/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libc++experimental/Makefile Sun May 21 17:07:12 2017 (r318594) @@ -0,0 +1,29 @@ +# $FreeBSD$ + +.include + +PACKAGE= clibs +SRCDIR= ${SRCTOP}/contrib/libc++ + +LIB= c++experimental +NO_PIC= +MK_PROFILE= no + +.PATH: ${SRCDIR}/src/experimental + +SRCS+= filesystem/directory_iterator.cpp +SRCS+= filesystem/operations.cpp +SRCS+= filesystem/path.cpp +SRCS+= memory_resource.cpp + +WARNS?= 0 +CXXFLAGS+= -isystem ${SRCDIR}/include +CXXFLAGS+= -nostdinc++ +CXXFLAGS+= -nostdlib +CXXFLAGS+= -D_LIBCPP_BUILDING_LIBRARY +CXXFLAGS+= -DLIBCXXRT +.if empty(CXXFLAGS:M-std=*) +CXXFLAGS+= -std=c++14 +.endif + +.include Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Sun May 21 15:37:08 2017 (r318593) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Sun May 21 17:07:12 2017 (r318594) @@ -4512,6 +4512,7 @@ OLD_LIBS+=${DEBUG_LIB32_LIBS} OLD_LIBS+=lib/libcxxrt.so.1 OLD_FILES+=usr/lib/libc++.a OLD_FILES+=usr/lib/libc++_p.a +OLD_FILES+=usr/lib/libc++experimental.a OLD_FILES+=usr/lib/libc++.so OLD_LIBS+=usr/lib/libc++.so.1 OLD_FILES+=usr/lib/libcxxrt.a From owner-svn-src-head@freebsd.org Sun May 21 18:00:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B2915D76B81; Sun, 21 May 2017 18:00:48 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 317FD1A25; Sun, 21 May 2017 18:00:48 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4LI0g6d091838 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sun, 21 May 2017 21:00:42 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4LI0g6d091838 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4LI0gGL091837; Sun, 21 May 2017 21:00:42 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 21 May 2017 21:00:42 +0300 From: Konstantin Belousov To: Dimitry Andric Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318594 - in head: lib lib/libc++experimental tools/build/mk Message-ID: <20170521180042.GK1622@kib.kiev.ua> References: <201705211707.v4LH7CbN016259@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705211707.v4LH7CbN016259@repo.freebsd.org> User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 21 May 2017 18:00:48 -0000 On Sun, May 21, 2017 at 05:07:12PM +0000, Dimitry Andric wrote: > Author: dim > Date: Sun May 21 17:07:12 2017 > New Revision: 318594 > URL: https://svnweb.freebsd.org/changeset/base/318594 > > Log: > Add libc++experimental.a for std::experimental support > > This adds a separate library for supporting std::experimental features. > It is purposefully static, and must be explicitly linked into programs > using -lc++experimental. > > PLEASE NOTE: there is NO WARRANTY as to any stability or continuing > existence of the features in the std::experimental parts of the C++ > library! > > Reviewed by: ed > Differential Revision: https://reviews.freebsd.org/D10840 > > Added: > head/lib/libc++experimental/ > head/lib/libc++experimental/Makefile (contents, props changed) > Modified: > head/lib/Makefile > head/tools/build/mk/OptionalObsoleteFiles.inc > > Modified: head/lib/Makefile > ============================================================================== > --- head/lib/Makefile Sun May 21 15:37:08 2017 (r318593) > +++ head/lib/Makefile Sun May 21 17:07:12 2017 (r318594) > @@ -156,7 +156,7 @@ _libclang_rt= libclang_rt > > .if ${MK_LIBCPLUSPLUS} != "no" > _libcxxrt= libcxxrt > -_libcplusplus= libc++ > +_libcplusplus= libc++ libc++experimental > .endif > > SUBDIR.${MK_EFI}+= libefivar > > Added: head/lib/libc++experimental/Makefile > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/lib/libc++experimental/Makefile Sun May 21 17:07:12 2017 (r318594) > @@ -0,0 +1,29 @@ > +# $FreeBSD$ > + > +.include > + > +PACKAGE= clibs > +SRCDIR= ${SRCTOP}/contrib/libc++ > + > +LIB= c++experimental > +NO_PIC= I suspect for this case it is almost required to provide libc++experimental_pic.a, otherwise linking the lib to dso would cause textrel. From owner-svn-src-head@freebsd.org Sun May 21 18:34:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77219D779A8; Sun, 21 May 2017 18:34:53 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from tensor.andric.com (tensor.andric.com [IPv6:2001:470:7a58:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "tensor.andric.com", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2D815DB3; Sun, 21 May 2017 18:34:53 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from [IPv6:2001:470:7a58::e0f5:766f:bd10:a778] (unknown [IPv6:2001:470:7a58:0:e0f5:766f:bd10:a778]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 1DC7932832; Sun, 21 May 2017 20:34:42 +0200 (CEST) From: Dimitry Andric Message-Id: <55649C56-DA8E-41C5-91B4-E72FB6A07CBC@FreeBSD.org> Content-Type: multipart/signed; boundary="Apple-Mail=_03C65E7D-FA3B-40D1-A3BA-01E65777B791"; protocol="application/pgp-signature"; micalg=pgp-sha1 Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: svn commit: r318594 - in head: lib lib/libc++experimental tools/build/mk Date: Sun, 21 May 2017 20:34:31 +0200 In-Reply-To: <20170521180042.GK1622@kib.kiev.ua> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org To: Konstantin Belousov References: <201705211707.v4LH7CbN016259@repo.freebsd.org> <20170521180042.GK1622@kib.kiev.ua> X-Mailer: Apple Mail (2.3273) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 21 May 2017 18:34:53 -0000 --Apple-Mail=_03C65E7D-FA3B-40D1-A3BA-01E65777B791 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On 21 May 2017, at 20:00, Konstantin Belousov = wrote: >=20 > On Sun, May 21, 2017 at 05:07:12PM +0000, Dimitry Andric wrote: >> Author: dim >> Date: Sun May 21 17:07:12 2017 >> New Revision: 318594 >> URL: https://svnweb.freebsd.org/changeset/base/318594 >>=20 >> Log: >> Add libc++experimental.a for std::experimental support >>=20 >> This adds a separate library for supporting std::experimental = features. >> It is purposefully static, and must be explicitly linked into = programs >> using -lc++experimental. >>=20 >> PLEASE NOTE: there is NO WARRANTY as to any stability or continuing >> existence of the features in the std::experimental parts of the C++ >> library! >>=20 >> Reviewed by: ed >> Differential Revision: https://reviews.freebsd.org/D10840 >>=20 >> Added: >> head/lib/libc++experimental/ >> head/lib/libc++experimental/Makefile (contents, props changed) >> Modified: >> head/lib/Makefile >> head/tools/build/mk/OptionalObsoleteFiles.inc >>=20 >> Modified: head/lib/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/lib/Makefile Sun May 21 15:37:08 2017 = (r318593) >> +++ head/lib/Makefile Sun May 21 17:07:12 2017 = (r318594) >> @@ -156,7 +156,7 @@ _libclang_rt=3D libclang_rt >>=20 >> .if ${MK_LIBCPLUSPLUS} !=3D "no" >> _libcxxrt=3D libcxxrt >> -_libcplusplus=3D libc++ >> +_libcplusplus=3D libc++ libc++experimental >> .endif >>=20 >> SUBDIR.${MK_EFI}+=3D libefivar >>=20 >> Added: head/lib/libc++experimental/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 >> --- /dev/null 00:00:00 1970 (empty, because file is newly = added) >> +++ head/lib/libc++experimental/Makefile Sun May 21 17:07:12 2017 = (r318594) >> @@ -0,0 +1,29 @@ >> +# $FreeBSD$ >> + >> +.include >> + >> +PACKAGE=3D clibs >> +SRCDIR=3D ${SRCTOP}/contrib/libc++ >> + >> +LIB=3D c++experimental >> +NO_PIC=3D > I suspect for this case it is almost required to provide > libc++experimental_pic.a, otherwise linking the lib to dso would > cause textrel. Hmm, I don't know how to tell the build system otherwise that I don't want any shared library. It looks like NO_PIC is needed in bsd.lib.mk to force no .so to be built, though. Maybe it is easier to just build the .a file with -fPIC always? There is really no need for two .a files. -Dimitry --Apple-Mail=_03C65E7D-FA3B-40D1-A3BA-01E65777B791 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.30 iEYEARECAAYFAlkh3cEACgkQsF6jCi4glqO19gCbBa7FodF+0tf/Kx2IAm2XWEEX hhoAn0li8bAoxt9nWmRLQN55pSGISXd4 =JCBu -----END PGP SIGNATURE----- --Apple-Mail=_03C65E7D-FA3B-40D1-A3BA-01E65777B791-- From owner-svn-src-head@freebsd.org Sun May 21 18:47:29 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9272BD77E2B; Sun, 21 May 2017 18:47:29 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 387351432; Sun, 21 May 2017 18:47:29 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4LIlNtT002130 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sun, 21 May 2017 21:47:23 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4LIlNtT002130 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4LIlNFk002129; Sun, 21 May 2017 21:47:23 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 21 May 2017 21:47:23 +0300 From: Konstantin Belousov To: Dimitry Andric Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318594 - in head: lib lib/libc++experimental tools/build/mk Message-ID: <20170521184723.GL1622@kib.kiev.ua> References: <201705211707.v4LH7CbN016259@repo.freebsd.org> <20170521180042.GK1622@kib.kiev.ua> <55649C56-DA8E-41C5-91B4-E72FB6A07CBC@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <55649C56-DA8E-41C5-91B4-E72FB6A07CBC@FreeBSD.org> User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 21 May 2017 18:47:29 -0000 On Sun, May 21, 2017 at 08:34:31PM +0200, Dimitry Andric wrote: > On 21 May 2017, at 20:00, Konstantin Belousov wrote: > > > > On Sun, May 21, 2017 at 05:07:12PM +0000, Dimitry Andric wrote: > >> Author: dim > >> Date: Sun May 21 17:07:12 2017 > >> New Revision: 318594 > >> URL: https://svnweb.freebsd.org/changeset/base/318594 > >> > >> Log: > >> Add libc++experimental.a for std::experimental support > >> > >> This adds a separate library for supporting std::experimental features. > >> It is purposefully static, and must be explicitly linked into programs > >> using -lc++experimental. > >> > >> PLEASE NOTE: there is NO WARRANTY as to any stability or continuing > >> existence of the features in the std::experimental parts of the C++ > >> library! > >> > >> Reviewed by: ed > >> Differential Revision: https://reviews.freebsd.org/D10840 > >> > >> Added: > >> head/lib/libc++experimental/ > >> head/lib/libc++experimental/Makefile (contents, props changed) > >> Modified: > >> head/lib/Makefile > >> head/tools/build/mk/OptionalObsoleteFiles.inc > >> > >> Modified: head/lib/Makefile > >> ============================================================================== > >> --- head/lib/Makefile Sun May 21 15:37:08 2017 (r318593) > >> +++ head/lib/Makefile Sun May 21 17:07:12 2017 (r318594) > >> @@ -156,7 +156,7 @@ _libclang_rt= libclang_rt > >> > >> .if ${MK_LIBCPLUSPLUS} != "no" > >> _libcxxrt= libcxxrt > >> -_libcplusplus= libc++ > >> +_libcplusplus= libc++ libc++experimental > >> .endif > >> > >> SUBDIR.${MK_EFI}+= libefivar > >> > >> Added: head/lib/libc++experimental/Makefile > >> ============================================================================== > >> --- /dev/null 00:00:00 1970 (empty, because file is newly added) > >> +++ head/lib/libc++experimental/Makefile Sun May 21 17:07:12 2017 (r318594) > >> @@ -0,0 +1,29 @@ > >> +# $FreeBSD$ > >> + > >> +.include > >> + > >> +PACKAGE= clibs > >> +SRCDIR= ${SRCTOP}/contrib/libc++ > >> + > >> +LIB= c++experimental > >> +NO_PIC= > > I suspect for this case it is almost required to provide > > libc++experimental_pic.a, otherwise linking the lib to dso would > > cause textrel. > > Hmm, I don't know how to tell the build system otherwise that I don't > want any shared library. It looks like NO_PIC is needed in bsd.lib.mk > to force no .so to be built, though. > > Maybe it is easier to just build the .a file with -fPIC always? There > is really no need for two .a files. May be, indeed. From owner-svn-src-head@freebsd.org Sun May 21 19:29:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4A4EAD77096; Sun, 21 May 2017 19:29:30 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1A255E6C; Sun, 21 May 2017 19:29:30 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LJTTOd073074; Sun, 21 May 2017 19:29:29 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LJTSP0073067; Sun, 21 May 2017 19:29:28 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705211929.v4LJTSP0073067@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Sun, 21 May 2017 19:29:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318595 - head/sys/fs/msdosfs 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.23 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, 21 May 2017 19:29:30 -0000 Author: emaste Date: Sun May 21 19:29:28 2017 New Revision: 318595 URL: https://svnweb.freebsd.org/changeset/base/318595 Log: msdosfs: capitalize FAT appropriately Diff reduction with NetBSD, including some nearby minor whitespace or style fixes. Obtained from: NetBSD Sponsored by: The FreeBSD Foundation Modified: head/sys/fs/msdosfs/denode.h head/sys/fs/msdosfs/fat.h head/sys/fs/msdosfs/msdosfs_denode.c head/sys/fs/msdosfs/msdosfs_fat.c head/sys/fs/msdosfs/msdosfs_vfsops.c head/sys/fs/msdosfs/msdosfs_vnops.c head/sys/fs/msdosfs/msdosfsmount.h Modified: head/sys/fs/msdosfs/denode.h ============================================================================== --- head/sys/fs/msdosfs/denode.h Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/denode.h Sun May 21 19:29:28 2017 (r318595) @@ -98,7 +98,7 @@ #define MSDOSFSROOT_OFS 0x1fffffff /* - * The fat cache structure. fc_fsrcn is the filesystem relative cluster + * The FAT cache structure. fc_fsrcn is the filesystem relative cluster * number that corresponds to the file relative cluster number in this * structure (fc_frcn). */ @@ -108,11 +108,11 @@ struct fatcache { }; /* - * The fat entry cache as it stands helps make extending files a "quick" - * operation by avoiding having to scan the fat to discover the last + * The FAT entry cache as it stands helps make extending files a "quick" + * operation by avoiding having to scan the FAT to discover the last * cluster of the file. The cache also helps sequential reads by * remembering the last cluster read from the file. This also prevents us - * from having to rescan the fat to find the next cluster to read. This + * from having to rescan the FAT to find the next cluster to read. This * cache is probably pretty worthless if a file is opened by multiple * processes. */ @@ -126,7 +126,7 @@ struct fatcache { #define FCE_EMPTY 0xffffffff /* doesn't represent an actual cluster # */ /* - * Set a slot in the fat cache. + * Set a slot in the FAT cache. */ #define fc_setcache(dep, slot, frcn, fsrcn) \ (dep)->de_fc[(slot)].fc_frcn = (frcn); \ @@ -156,7 +156,7 @@ struct denode { u_short de_MDate; /* modification date */ u_long de_StartCluster; /* starting cluster of file */ u_long de_FileSize; /* size of file in bytes */ - struct fatcache de_fc[FC_SIZE]; /* fat cache */ + struct fatcache de_fc[FC_SIZE]; /* FAT cache */ u_quad_t de_modrev; /* Revision level for lease. */ uint64_t de_inode; /* Inode number (really byte offset of direntry) */ }; Modified: head/sys/fs/msdosfs/fat.h ============================================================================== --- head/sys/fs/msdosfs/fat.h Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/fat.h Sun May 21 19:29:28 2017 (r318595) @@ -66,10 +66,10 @@ /* * MSDOSFS: - * Return true if filesystem uses 12 bit fats. Microsoft Programmer's + * Return true if filesystem uses 12 bit FATs. Microsoft Programmer's * Reference says if the maximum cluster number in a filesystem is greater * than 4078 ((CLUST_RSRVS - CLUST_FIRST) & FAT12_MASK) then we've got a - * 16 bit fat filesystem. While mounting, the result of this test is stored + * 16 bit FAT filesystem. While mounting, the result of this test is stored * in pm_fatentrysize. */ #define FAT12(pmp) (pmp->pm_fatmask == FAT12_MASK) @@ -83,8 +83,8 @@ * These are the values for the function argument to the function * fatentry(). */ -#define FAT_GET 0x0001 /* get a fat entry */ -#define FAT_SET 0x0002 /* set a fat entry */ +#define FAT_GET 0x0001 /* get a FAT entry */ +#define FAT_SET 0x0002 /* set a FAT entry */ #define FAT_GET_AND_SET (FAT_GET | FAT_SET) /* Modified: head/sys/fs/msdosfs/msdosfs_denode.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_denode.c Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/msdosfs_denode.c Sun May 21 19:29:28 2017 (r318595) @@ -160,7 +160,7 @@ deget(struct msdosfsmount *pmp, u_long d ldep->de_diroffset = diroffset; ldep->de_inode = inode; lockmgr(nvp->v_vnlock, LK_EXCLUSIVE, NULL); - fc_purge(ldep, 0); /* init the fat cache for this denode */ + fc_purge(ldep, 0); /* init the FAT cache for this denode */ error = insmntque(nvp, mntp); if (error != 0) { free(ldep, M_MSDOSFSNODE); Modified: head/sys/fs/msdosfs/msdosfs_fat.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_fat.c Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/msdosfs_fat.c Sun May 21 19:29:28 2017 (r318595) @@ -176,8 +176,8 @@ pcbmap(struct denode *dep, u_long findcn *sp = pmp->pm_bpcluster; /* - * Rummage around in the fat cache, maybe we can avoid tromping - * through every fat entry for the file. And, keep track of how far + * Rummage around in the FAT cache, maybe we can avoid tromping + * through every FAT entry for the file. And, keep track of how far * off the cache was from where we wanted to be. */ i = 0; @@ -244,13 +244,13 @@ hiteof:; *cnp = i; if (bp) brelse(bp); - /* update last file cluster entry in the fat cache */ + /* update last file cluster entry in the FAT cache */ fc_setcache(dep, FC_LASTFC, i - 1, prevcn); return (E2BIG); } /* - * Find the closest entry in the fat cache to the cluster we are looking + * Find the closest entry in the FAT cache to the cluster we are looking * for. */ static void @@ -276,7 +276,7 @@ fc_lookup(struct denode *dep, u_long fin } /* - * Purge the fat cache in denode dep of all entries relating to file + * Purge the FAT cache in denode dep of all entries relating to file * relative cluster frcn and beyond. */ void @@ -295,13 +295,13 @@ fc_purge(struct denode *dep, u_int frcn) } /* - * Update the fat. - * If mirroring the fat, update all copies, with the first copy as last. - * Else update only the current fat (ignoring the others). + * Update the FAT. + * If mirroring the FAT, update all copies, with the first copy as last. + * Else update only the current FAT (ignoring the others). * * pmp - msdosfsmount structure for filesystem to update - * bp - addr of modified fat block - * fatbn - block number relative to begin of filesystem of the modified fat block. + * bp - addr of modified FAT block + * fatbn - block number relative to begin of filesystem of the modified FAT block. */ static void updatefats(struct msdosfsmount *pmp, struct buf *bp, u_long fatbn) @@ -315,12 +315,12 @@ updatefats(struct msdosfsmount *pmp, str if (pmp->pm_flags & MSDOSFS_FATMIRROR) { /* - * Now copy the block(s) of the modified fat to the other copies of - * the fat and write them out. This is faster than reading in the - * other fats and then writing them back out. This could tie up - * the fat for quite a while. Preventing others from accessing it. - * To prevent us from going after the fat quite so much we use - * delayed writes, unless they specfied "synchronous" when the + * Now copy the block(s) of the modified FAT to the other copies of + * the FAT and write them out. This is faster than reading in the + * other FATs and then writing them back out. This could tie up + * the FAT for quite a while. Preventing others from accessing it. + * To prevent us from going after the FAT quite so much we use + * delayed writes, unless they specified "synchronous" when the * filesystem was mounted. If synch is asked for then use * bwrite()'s and really slow things down. */ @@ -349,7 +349,7 @@ updatefats(struct msdosfsmount *pmp, str } /* - * Write out the first (or current) fat last. + * Write out the first (or current) FAT last. */ if (pmp->pm_mountp->mnt_flag & MNT_SYNCHRONOUS) bwrite(bp); @@ -358,7 +358,7 @@ updatefats(struct msdosfsmount *pmp, str } /* - * Updating entries in 12 bit fats is a pain in the butt. + * Updating entries in 12 bit FATs is a pain in the butt. * * The following picture shows where nibbles go when moving from a 12 bit * cluster number into the appropriate bytes in the FAT. @@ -436,21 +436,21 @@ clusterfree(struct msdosfsmount *pmp, u_ } /* - * Get or Set or 'Get and Set' the cluster'th entry in the fat. + * Get or Set or 'Get and Set' the cluster'th entry in the FAT. * - * function - whether to get or set a fat entry + * function - whether to get or set a FAT entry * pmp - address of the msdosfsmount structure for the filesystem - * whose fat is to be manipulated. + * whose FAT is to be manipulated. * cn - which cluster is of interest * oldcontents - address of a word that is to receive the contents of the * cluster'th entry if this is a get function * newcontents - the new value to be written into the cluster'th element of - * the fat if this is a set function. + * the FAT if this is a set function. * - * This function can also be used to free a cluster by setting the fat entry + * This function can also be used to free a cluster by setting the FAT entry * for a cluster to 0. * - * All copies of the fat are updated if this is a set function. NOTE: If + * All copies of the FAT are updated if this is a set function. NOTE: If * fatentry() marks a cluster as free it does not update the inusemap in * the msdosfsmount structure. This is left to the caller. */ @@ -513,7 +513,7 @@ fatentry(int function, struct msdosfsmou if (FAT12(pmp) & (cn & 1)) readcn >>= 4; readcn &= pmp->pm_fatmask; - /* map reserved fat entries to same values for all fats */ + /* map reserved FAT entries to same values for all FATs */ if ((readcn | ~pmp->pm_fatmask) >= CLUST_RSRVD) readcn |= ~pmp->pm_fatmask; *oldcontents = readcn; @@ -537,7 +537,7 @@ fatentry(int function, struct msdosfsmou case FAT32_MASK: /* * According to spec we have to retain the - * high order bits of the fat entry. + * high order bits of the FAT entry. */ readcn = getulong(&bp->b_data[bo]); readcn &= ~FAT32_MASK; @@ -560,7 +560,7 @@ fatentry(int function, struct msdosfsmou * pmp - mount point * start - first cluster of chain * count - number of clusters in chain - * fillwith - what to write into fat entry of last cluster + * fillwith - what to write into FAT entry of last cluster */ static int fatchain(struct msdosfsmount *pmp, u_long start, u_long count, u_long fillwith) @@ -685,7 +685,7 @@ chainlength(struct msdosfsmount *pmp, u_ * pmp - mount point. * start - start of cluster chain. * count - number of clusters to allocate. - * fillwith - put this value into the fat entry for the + * fillwith - put this value into the FAT entry for the * last allocated cluster. * retcluster - put the first allocated cluster's number here. * got - how many clusters were actually allocated. @@ -730,7 +730,7 @@ chainalloc(struct msdosfsmount *pmp, u_l * pmp - mount point. * start - preferred start of cluster chain. * count - number of clusters requested. - * fillwith - put this value into the fat entry for the + * fillwith - put this value into the FAT entry for the * last allocated cluster. * retcluster - put the first allocated cluster's number here. * got - how many clusters were actually allocated. @@ -882,7 +882,7 @@ freeclusterchain(struct msdosfsmount *pm } /* - * Read in fat blocks looking for free clusters. For every free cluster + * Read in FAT blocks looking for free clusters. For every free cluster * found turn off its corresponding bit in the pm_inusemap. */ int @@ -896,7 +896,7 @@ fillinusemap(struct msdosfsmount *pmp) MSDOSFS_ASSERT_MP_LOCKED(pmp); /* - * Mark all clusters in use, we mark the free ones in the fat scan + * Mark all clusters in use, we mark the free ones in the FAT scan * loop further down. */ for (cn = 0; cn < (pmp->pm_maxcluster + N_INUSEBITS) / N_INUSEBITS; cn++) @@ -904,7 +904,7 @@ fillinusemap(struct msdosfsmount *pmp) /* * Figure how many free clusters are in the filesystem by ripping - * through the fat counting the number of entries whose content is + * through the FAT counting the number of entries whose content is * zero. These represent free clusters. */ pmp->pm_freeclustercount = 0; @@ -1042,8 +1042,8 @@ extendfile(struct denode *dep, u_long co } /* - * Update the "last cluster of the file" entry in the denode's fat - * cache. + * Update the "last cluster of the file" entry in the + * denode's FAT cache. */ fc_setcache(dep, FC_LASTFC, frcn + got - 1, cn + got - 1); Modified: head/sys/fs/msdosfs/msdosfs_vfsops.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_vfsops.c Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/msdosfs_vfsops.c Sun May 21 19:29:28 2017 (r318595) @@ -604,7 +604,7 @@ mountmsdosfs(struct vnode *devvp, struct <= ((CLUST_RSRVD - CLUST_FIRST) & FAT12_MASK)) { /* * This will usually be a floppy disk. This size makes - * sure that one fat entry will not be split across + * sure that one FAT entry will not be split across * multiple blocks. */ pmp->pm_fatmask = FAT12_MASK; @@ -717,9 +717,9 @@ mountmsdosfs(struct vnode *devvp, struct goto error_exit; /* - * If they want fat updates to be synchronous then let them suffer + * If they want FAT updates to be synchronous then let them suffer * the performance degradation in exchange for the on disk copy of - * the fat being correct just about all the time. I suppose this + * the FAT being correct just about all the time. I suppose this * would be a good thing to turn on if the kernel is still flakey. */ if (mp->mnt_flag & MNT_SYNCHRONOUS) @@ -925,14 +925,14 @@ msdosfs_sync(struct mount *mp, int waitf td = curthread; /* - * If we ever switch to not updating all of the fats all the time, + * If we ever switch to not updating all of the FATs all the time, * this would be the place to update them from the first one. */ if (pmp->pm_fmod != 0) { if (pmp->pm_flags & MSDOSFSMNT_RONLY) panic("msdosfs_sync: rofs mod"); else { - /* update fats here */ + /* update FATs here */ } } /* Modified: head/sys/fs/msdosfs/msdosfs_vnops.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_vnops.c Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/msdosfs_vnops.c Sun May 21 19:29:28 2017 (r318595) @@ -736,7 +736,7 @@ msdosfs_write(struct vop_write_args *ap) vfs_bio_clrbuf(bp); /* * Do the bmap now, since pcbmap needs buffers - * for the fat table. (see msdosfs_strategy) + * for the FAT table. (see msdosfs_strategy) */ if (bp->b_blkno == bp->b_lblkno) { error = pcbmap(dep, bp->b_lblkno, &bn, 0, 0); Modified: head/sys/fs/msdosfs/msdosfsmount.h ============================================================================== --- head/sys/fs/msdosfs/msdosfsmount.h Sun May 21 17:07:12 2017 (r318594) +++ head/sys/fs/msdosfs/msdosfsmount.h Sun May 21 19:29:28 2017 (r318595) @@ -65,7 +65,7 @@ MALLOC_DECLARE(M_MSDOSFSMNT); struct msdosfs_fileno; /* - * Layout of the mount control block for a msdos filesystem. + * Layout of the mount control block for a MSDOSFS filesystem. */ struct msdosfsmount { struct mount *pm_mountp;/* vfs mount struct for this fs */ @@ -73,7 +73,7 @@ struct msdosfsmount { struct bufobj *pm_bo; uid_t pm_uid; /* uid to set as owner of the files */ gid_t pm_gid; /* gid to set as owner of the files */ - mode_t pm_mask; /* mask to and with file protection bits + mode_t pm_mask; /* mask to and with file protection bits for files */ mode_t pm_dirmask; /* mask to and with file protection bits for directories */ @@ -81,7 +81,7 @@ struct msdosfsmount { struct cdev *pm_dev; /* character device mounted */ struct bpb50 pm_bpb; /* BIOS parameter blk for this fs */ u_long pm_BlkPerSec; /* How many DEV_BSIZE blocks fit inside a physical sector */ - u_long pm_FATsecs; /* actual number of fat sectors */ + u_long pm_FATsecs; /* actual number of FAT sectors */ u_long pm_fatblk; /* block # of first FAT */ u_long pm_rootdirblk; /* block # (cluster # for FAT32) of root directory number */ u_long pm_rootdirsize; /* size in blocks (not clusters) */ @@ -93,15 +93,15 @@ struct msdosfsmount { u_long pm_bnshift; /* shift file offset right this amount to get a block number */ u_long pm_bpcluster; /* bytes per cluster */ u_long pm_fmod; /* ~0 if fs is modified, this can rollover to 0 */ - u_long pm_fatblocksize; /* size of fat blocks in bytes */ - u_long pm_fatblocksec; /* size of fat blocks in sectors */ - u_long pm_fatsize; /* size of fat in bytes */ - uint32_t pm_fatmask; /* mask to use for fat numbers */ + u_long pm_fatblocksize; /* size of FAT blocks in bytes */ + u_long pm_fatblocksec; /* size of FAT blocks in sectors */ + u_long pm_fatsize; /* size of FAT in bytes */ + uint32_t pm_fatmask; /* mask to use for FAT numbers */ u_long pm_fsinfo; /* fsinfo block number */ u_long pm_nxtfree; /* next place to search for a free cluster */ - u_int pm_fatmult; /* these 2 values are used in fat */ + u_int pm_fatmult; /* these 2 values are used in FAT */ u_int pm_fatdiv; /* offset computation */ - u_int pm_curfat; /* current fat for FAT32 (0 otherwise) */ + u_int pm_curfat; /* current FAT for FAT32 (0 otherwise) */ u_int *pm_inusemap; /* ptr to bitmap of in-use clusters */ uint64_t pm_flags; /* see below */ void *pm_u2w; /* Local->Unicode iconv handle */ From owner-svn-src-head@freebsd.org Sun May 21 19:48:18 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 155DCD776BF; Sun, 21 May 2017 19:48:18 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DB81F19CE; Sun, 21 May 2017 19:48:17 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LJmGwA081558; Sun, 21 May 2017 19:48:16 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LJmGhq081557; Sun, 21 May 2017 19:48:16 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705211948.v4LJmGhq081557@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Sun, 21 May 2017 19:48:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318596 - head/sys/fs/msdosfs 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.23 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, 21 May 2017 19:48:18 -0000 Author: emaste Date: Sun May 21 19:48:16 2017 New Revision: 318596 URL: https://svnweb.freebsd.org/changeset/base/318596 Log: msdosfs: correct constant and typo in comment Revisions: fat.h 1.5 1.6 Obtained from: NetBSD Sponsored by: The FreeBSD Foundation Modified: head/sys/fs/msdosfs/fat.h Modified: head/sys/fs/msdosfs/fat.h ============================================================================== --- head/sys/fs/msdosfs/fat.h Sun May 21 19:29:28 2017 (r318595) +++ head/sys/fs/msdosfs/fat.h Sun May 21 19:48:16 2017 (r318596) @@ -68,7 +68,7 @@ * MSDOSFS: * Return true if filesystem uses 12 bit FATs. Microsoft Programmer's * Reference says if the maximum cluster number in a filesystem is greater - * than 4078 ((CLUST_RSRVS - CLUST_FIRST) & FAT12_MASK) then we've got a + * than 4084 ((CLUST_RSRVD - CLUST_FIRST) & FAT12_MASK) then we've got a * 16 bit FAT filesystem. While mounting, the result of this test is stored * in pm_fatentrysize. */ From owner-svn-src-head@freebsd.org Sun May 21 20:00:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 97732D77924; Sun, 21 May 2017 20:00:50 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 648201E89; Sun, 21 May 2017 20:00:50 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LK0neo085888; Sun, 21 May 2017 20:00:49 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LK0nkm085887; Sun, 21 May 2017 20:00:49 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705212000.v4LK0nkm085887@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Sun, 21 May 2017 20:00:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318597 - head/sys/fs/msdosfs 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.23 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, 21 May 2017 20:00:50 -0000 Author: emaste Date: Sun May 21 20:00:49 2017 New Revision: 318597 URL: https://svnweb.freebsd.org/changeset/base/318597 Log: msdosfs: constify Obtained from: NetBSD Sponsored by: The FreeBSD Foundation Modified: head/sys/fs/msdosfs/msdosfs_conv.c Modified: head/sys/fs/msdosfs/msdosfs_conv.c ============================================================================== --- head/sys/fs/msdosfs/msdosfs_conv.c Sun May 21 19:48:16 2017 (r318596) +++ head/sys/fs/msdosfs/msdosfs_conv.c Sun May 21 20:00:49 2017 (r318597) @@ -73,7 +73,7 @@ static uint16_t unix2winchr(const u_char * 2 - character ('.' and ' ') should be skipped in DOS file name, * and generation number inserted. */ -static u_char +static const u_char unix2dos[256] = { /* iso8859-1 -> cp850 */ 0, 0, 0, 0, 0, 0, 0, 0, /* 00-07 */ @@ -110,7 +110,7 @@ unix2dos[256] = { 0x9d, 0xeb, 0xe9, 0xea, 0x9a, 0xed, 0xe8, 0x98, /* f8-ff */ }; -static u_char +static const u_char dos2unix[256] = { /* cp850 -> iso8859-1 */ 0x3f, 0x3f, 0x3f, 0x3f, 0x3f, 0x3f, 0x3f, 0x3f, /* 00-07 */ @@ -147,7 +147,7 @@ dos2unix[256] = { 0xb0, 0xa8, 0xb7, 0xb9, 0xb3, 0xb2, 0x3f, 0x3f, /* f8-ff */ }; -static u_char +static const u_char u2l[256] = { /* tolower */ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, /* 00-07 */ @@ -184,7 +184,7 @@ u2l[256] = { 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff, /* f8-ff */ }; -static u_char +static const u_char l2u[256] = { /* toupper */ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, /* 00-07 */ From owner-svn-src-head@freebsd.org Sun May 21 20:48:42 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2F222D77A2D; Sun, 21 May 2017 20:48:42 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F40B318EB; Sun, 21 May 2017 20:48:41 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x244.google.com with SMTP id n23so15383010pfb.3; Sun, 21 May 2017 13:48:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=X3UAsNbpndKI3JcUUilxQqrGmPSmP64FUAt8umygvyU=; b=P5Iw6ByTzr71xJTFjm9KlUMistBKg48paoL4NdEYvhe682GtdekIptiNHIkE1TxFS4 opHgoh0buGEemNqMXaZ4y6wKK7Tagis62zLBgR7FFsy5u7peDbJAgwBDf8K3wKdQJ3t1 etb7I3QGTZgTx5FvN9vFlpQr1Z8r04d2GeQsD5u+cQYfULlxOC8X0qu2/D0FTos1FbnX Kssi83EeDunSm0y70MAVdGYHuhvXu+icqxIf7befp8taVoviJvlRTReNkS1ddxZ37xES 3pcgUS0V0VnJoJDwk4iwBYT4phVq6hJr+h/ieoQwx82DeoPiPpOOhHZDh2irc4KEHL91 3R+A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=X3UAsNbpndKI3JcUUilxQqrGmPSmP64FUAt8umygvyU=; b=TQvmSiBKUBl6sEApM6+5g/3d/3gKOw3Zp66JYMwwIpoXUxwb+gzHP632TmVPdCGbtT pmtPJFeU20q3qxPsrk0BhmAzNbycZMkOHXU8Dgq429ImDIaLV4XoJMohp+oXXF8ygRvS 9CwYxm34m5GEIrPmHpwYe2LrBIdmD7Q8si1d2l0gLDCV+TF/pEsBKA/EI6NEZNh+J0y0 OO9Fix7yUJ1/t2uGtlOKRrp2wzoT73WgTYZOpMRx4Xk0D5dyfXBYPmAx6hwE0YXEUtY9 /CQEdEcOrQ/V/GXY1k9W1QXJyJ6ZqAiOY4DFIbstby+HCI2dLqj4Yrm2F0dmBmhHC0n+ XWIw== X-Gm-Message-State: AODbwcBbXgFb9idIPos7G+vF3ZSHtyfb1rP3C01LXnRlwCGGJG1x0W1Y TUO0auNodQDYEw== X-Received: by 10.98.89.201 with SMTP id k70mr21505415pfj.196.1495399721366; Sun, 21 May 2017 13:48:41 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id r68sm26612251pfd.91.2017.05.21.13.48.40 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 21 May 2017 13:48:40 -0700 (PDT) Subject: Re: svn commit: r318594 - in head: lib lib/libc++experimental tools/build/mk Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_2A8F8C6D-32BF-4A87-9897-D1E286972088"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <55649C56-DA8E-41C5-91B4-E72FB6A07CBC@FreeBSD.org> Date: Sun, 21 May 2017 13:48:39 -0700 Cc: Konstantin Belousov , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <4A7031DC-30A0-415E-AD45-6FDC1925C868@gmail.com> References: <201705211707.v4LH7CbN016259@repo.freebsd.org> <20170521180042.GK1622@kib.kiev.ua> <55649C56-DA8E-41C5-91B4-E72FB6A07CBC@FreeBSD.org> To: Dimitry Andric X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 21 May 2017 20:48:42 -0000 --Apple-Mail=_2A8F8C6D-32BF-4A87-9897-D1E286972088 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On May 21, 2017, at 11:34, Dimitry Andric wrote: =E2=80=A6 > Hmm, I don't know how to tell the build system otherwise that I don't > want any shared library. It looks like NO_PIC is needed in bsd.lib.mk > to force no .so to be built, though. NO_PIC is the way to do this. -Ngie --Apple-Mail=_2A8F8C6D-32BF-4A87-9897-D1E286972088 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJZIf0nAAoJEPWDqSZpMIYVnl4QAIah8GXNvmj2ZYsbotXCKFTe rW+LipjtC1LIRRmSuKThituY8I6MEmPD5H2UmqwzEKHCJ124uMeNJPPwrJhEjhHn xXhnmRffBYOGM+xu4ar7azqHxCXYlt+s/m4MQ2UVzENv5w76dbJuLeAvJLKssR2h 2/+HKLKuksg53e7uILgDjn1jEkJ6Y+tfzCjgnsbj9ev1GReK2Jv8t4WEeaC6318g c/6xj/QiclHJnSu0R5anXBcj0kQZZpOtIl5l3D/hcbIVPc+3yYTEwkYz+Zs0w3DD 9p6lWfeI7yer6+KBA7o0ktsu7ADqa106PeAah8AGlh6WBAsu0PGo0TlSDLaniuhF GGXHLmJj0SpCRrXUvL5Y4azVkRjSFSgo2kBY9O0q/b7sPyDEEZ9xKkUH65CtDr8h BsUeKIDMm3b0I3t1ti0QRSZLRj9pbcDIo5TG3JZxysK7nj539H8O62mPPSKkLNsK 0qZM89U2e+P2akLTLCmIgFGl4NkxZFUceAg0L/ijK8JXlF42fnGtacVwhGTEz7EF oMQ9f60H5qalFa5d6OLHsCQsJUoot22SwEZ73nd6h0vTnKK2Kijz6XYFziwd/jRp ksAyF+XzQBYmf6vLgd8SrxKzfCrPjcX1YW5aBexnq7992zfjKmmHNzJ63GP6HpAv SgJeUxZBa4dXycnGns8w =gH1N -----END PGP SIGNATURE----- --Apple-Mail=_2A8F8C6D-32BF-4A87-9897-D1E286972088-- From owner-svn-src-head@freebsd.org Sun May 21 21:33:17 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3A55FD7811C; Sun, 21 May 2017 21:33:17 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0AC101DF1; Sun, 21 May 2017 21:33:16 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LLXGLF026307; Sun, 21 May 2017 21:33:16 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LLXG1e026306; Sun, 21 May 2017 21:33:16 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705212133.v4LLXG1e026306@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 21 May 2017 21:33:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318598 - head/lib/libc++experimental 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.23 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, 21 May 2017 21:33:17 -0000 Author: dim Date: Sun May 21 21:33:15 2017 New Revision: 318598 URL: https://svnweb.freebsd.org/changeset/base/318598 Log: Add PICFLAG to build libc++experimental.a, so it can be used in all situations. Noticed by: kib Modified: head/lib/libc++experimental/Makefile Modified: head/lib/libc++experimental/Makefile ============================================================================== --- head/lib/libc++experimental/Makefile Sun May 21 20:00:49 2017 (r318597) +++ head/lib/libc++experimental/Makefile Sun May 21 21:33:15 2017 (r318598) @@ -17,6 +17,7 @@ SRCS+= filesystem/path.cpp SRCS+= memory_resource.cpp WARNS?= 0 +CXXFLAGS+= ${PICFLAG} CXXFLAGS+= -isystem ${SRCDIR}/include CXXFLAGS+= -nostdinc++ CXXFLAGS+= -nostdlib From owner-svn-src-head@freebsd.org Sun May 21 22:10:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5A069D78A40; Sun, 21 May 2017 22:10:10 +0000 (UTC) (envelope-from bjk@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A3E7F15; Sun, 21 May 2017 22:10:10 +0000 (UTC) (envelope-from bjk@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LMA9ef039612; Sun, 21 May 2017 22:10:09 GMT (envelope-from bjk@FreeBSD.org) Received: (from bjk@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LMA9i0039611; Sun, 21 May 2017 22:10:09 GMT (envelope-from bjk@FreeBSD.org) Message-Id: <201705212210.v4LMA9i0039611@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bjk set sender to bjk@FreeBSD.org using -f From: Benjamin Kaduk Date: Sun, 21 May 2017 22:10:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318599 - head/usr.sbin/efivar 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.23 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, 21 May 2017 22:10:10 -0000 Author: bjk (doc committer) Date: Sun May 21 22:10:08 2017 New Revision: 318599 URL: https://svnweb.freebsd.org/changeset/base/318599 Log: Updates for efivar.8 Fix spelling [1], appease igor and mandoc -Tlint, and adopt the language style to be more consistent with our corpus. PR: 219434 [1] Submitted by: olgeni [1] Modified: head/usr.sbin/efivar/efivar.8 Modified: head/usr.sbin/efivar/efivar.8 ============================================================================== --- head/usr.sbin/efivar/efivar.8 Sun May 21 21:33:15 2017 (r318598) +++ head/usr.sbin/efivar/efivar.8 Sun May 21 22:10:08 2017 (r318599) @@ -24,12 +24,12 @@ .\" .\" $FreeBSD$ .\" -.Dd March 4, 2017 +.Dd May 21, 2017 .Dt EFIVAR 8 .Os .Sh NAME .Nm efivar -.Nd UEFI environemnt variable interaction +.Nd UEFI environment variable interaction .Sh SYNOPSIS .Nm .Op Fl abdDHlLNpRtw @@ -58,7 +58,7 @@ This program manages .Pq UEFI environment variables. UEFI variables have three part: A namespace, a name and a value. -The namespace is a GUID that's self assigned by the group defining the +The namespace is a GUID that is self assigned by the group defining the variables. The name is a Unicode name for the variable. The value is binary data. @@ -70,7 +70,7 @@ The following options are available: Specify the name of the variable to operate on. The .Ar name -argument is the GUID of variable, followed by a dash, followed by the +argument is the GUID of the variable, followed by a dash, followed by the UEFI variable name. The GUID may be in numeric format, or may be one of the well known symbolic name (see @@ -86,19 +86,19 @@ This flag implies unless the .Fl -append flag is given. -This is not well understood and currently unimplemented. +This behavior is not well understood and is currently unimplemented. .It Fl a Fl -append Append the specified value to the UEFI variable rather than replacing -it.p +it. .It Fl t Ar attr Fl -attributes Ar attr -Specify, in user hostile hexidecimal, the attributes for this +Specify, in hexadecimal, the attributes for this variable. See section 7.2 (GetVariable subsection, Related Definitions) of the UEFI Specification for hex values to use. .It Fl A Fl -ascii Display the variable data as modified ascii: All printable characters are printed, while unprintable characters are rendered as a two-digit -hexadecimal number preceeded by a % character. +hexadecimal number preceded by a % character. .It Fl b Fl -binary Display the variable data as binary data. Usually will be used with the @@ -155,29 +155,27 @@ can be used to specify simple strings. Display the .Ar name environment variable. +.El .Sh COMPATIBILITY The .Nm -program is intended to be compatible (strict superset) with a progam -of the same name included in the Red Hat libefivar package. -.Pp -Except the +program is intended to be compatible (strict superset) with a program +of the same name included in the Red Hat libefivar package, +but the .Fl d and .Fl -print-decimal -flags are not implmenented and never will be. +flags are not implemented and never will be. +.Pp The .Fl d -flag is a short-hand for +flag is short for .Fl -device-path . .Sh SEE ALSO Appendix A of the UEFI specification has the format for GUIDs. All GUIDs .Dq Globally Unique Identifiers have the format described in RFC 4122. -.El -.Pp -.Xr efivar 8 .Sh HISTORY The .Nm From owner-svn-src-head@freebsd.org Sun May 21 22:28:29 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B91BCD78E47; Sun, 21 May 2017 22:28:29 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8B7661795; Sun, 21 May 2017 22:28:29 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LMSS2N047767; Sun, 21 May 2017 22:28:28 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LMSSJV047765; Sun, 21 May 2017 22:28:28 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705212228.v4LMSSJV047765@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 21 May 2017 22:28:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318600 - head/usr.bin/catman 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.23 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, 21 May 2017 22:28:29 -0000 Author: bapt Date: Sun May 21 22:28:28 2017 New Revision: 318600 URL: https://svnweb.freebsd.org/changeset/base/318600 Log: Make catman(1) use mandoc(1) by default catman(1) checks if mandoc(1) do support the manpage before trying to generate the catpage and falls back on nroff, using the same mechanism as man(1). Modified: head/usr.bin/catman/catman.1 head/usr.bin/catman/catman.c Modified: head/usr.bin/catman/catman.1 ============================================================================== --- head/usr.bin/catman/catman.1 Sun May 21 22:10:08 2017 (r318599) +++ head/usr.bin/catman/catman.1 Sun May 21 22:28:28 2017 (r318600) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 3, 2005 +.Dd May 22, 2017 .Dt CATMAN 1 .Os .Sh NAME @@ -40,6 +40,8 @@ The utility preformats all the man pages in .Ar directories using the +.Nm mandoc +command when supported, falling back on the .Nm nroff Fl man command. Directories may be separated by colons instead of spaces. @@ -99,6 +101,7 @@ environment variable is not set. .Sh SEE ALSO .Xr makewhatis 1 , .Xr man 1 , +.Xr mandoc 1 , .Xr nroff 1 .Sh HISTORY A previous version of the Modified: head/usr.bin/catman/catman.c ============================================================================== --- head/usr.bin/catman/catman.c Sun May 21 22:10:08 2017 (r318599) +++ head/usr.bin/catman/catman.c Sun May 21 22:28:28 2017 (r318600) @@ -43,6 +43,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -70,6 +71,8 @@ static char *lang_locale; /* short form static const char *machine, *machine_arch; static int exit_code; /* exit code to use when finished */ +extern char **environ; + /* * -T argument for nroff */ @@ -93,6 +96,7 @@ static const char *locale_device[] = { #define GZCAT_CMD "z" enum Ziptype {NONE, BZIP, GZIP}; +static bool mandoc_locales = false; static uid_t uid; static int starting_dir; static char tmp_file[MAXPATHLEN]; @@ -438,11 +442,24 @@ process_page(char *mandir, char *src, ch } snprintf(tmp_file, sizeof tmp_file, "%s.tmp", cat); snprintf(cmd, sizeof cmd, - "%scat %s | tbl | nroff -c -T%s -man | %s > %s.tmp", + "%scat %s | mandoc -Tlint -Wunsupp 2>/dev/null", zipped == BZIP ? BZ2CAT_CMD : zipped == GZIP ? GZCAT_CMD : "", - src, nroff_device, - zipped == BZIP ? BZ2_CMD : zipped == GZIP ? GZ_CMD : "cat", - cat); + src); + if (system(cmd) == 0) { + snprintf(cmd, sizeof cmd, + "%scat %s | mandoc -T%s | %s > %s.tmp", + zipped == BZIP ? BZ2CAT_CMD : zipped == GZIP ? GZCAT_CMD : "", + src, mandoc_locales ? "locale" : "ascii", + zipped == BZIP ? BZ2_CMD : zipped == GZIP ? GZ_CMD : "cat", + cat); + } else { + snprintf(cmd, sizeof cmd, + "%scat %s | tbl | nroff -c -T%s -man | %s > %s.tmp", + zipped == BZIP ? BZ2CAT_CMD : zipped == GZIP ? GZCAT_CMD : "", + src, nroff_device, + zipped == BZIP ? BZ2_CMD : zipped == GZIP ? GZ_CMD : "cat", + cat); + } if (system(cmd) != 0) err(1, "formatting pipeline"); if (rename(tmp_file, cat) < 0) @@ -771,6 +788,7 @@ main(int argc, char **argv) break; case 'L': determine_locale(); + mandoc_locales = true; break; case 'n': pretend++; From owner-svn-src-head@freebsd.org Sun May 21 23:15:34 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5A01FD78163; Sun, 21 May 2017 23:15:34 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 355E01193; Sun, 21 May 2017 23:15:34 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LNFX9a067722; Sun, 21 May 2017 23:15:33 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LNFWQw067717; Sun, 21 May 2017 23:15:32 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705212315.v4LNFWQw067717@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Sun, 21 May 2017 23:15:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318601 - in head: contrib/compiler-rt/lib/builtins lib/libcompiler_rt 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.23 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, 21 May 2017 23:15:34 -0000 Author: adrian Date: Sun May 21 23:15:32 2017 New Revision: 318601 URL: https://svnweb.freebsd.org/changeset/base/318601 Log: [libcompiler-rt] add bswapdi2/bswapsi2 This is required for mips gcc 6.3 userland to build/run. Reviewed by: emaste, dim Approved by: emaste Differential Revision: https://reviews.freebsd.org/D10838 Added: head/contrib/compiler-rt/lib/builtins/bswapdi2.c (contents, props changed) head/contrib/compiler-rt/lib/builtins/bswapsi2.c (contents, props changed) Modified: head/contrib/compiler-rt/lib/builtins/README.txt head/lib/libcompiler_rt/Makefile.inc Modified: head/contrib/compiler-rt/lib/builtins/README.txt ============================================================================== --- head/contrib/compiler-rt/lib/builtins/README.txt Sun May 21 22:28:28 2017 (r318600) +++ head/contrib/compiler-rt/lib/builtins/README.txt Sun May 21 23:15:32 2017 (r318601) @@ -57,8 +57,8 @@ si_int __popcountsi2(si_int a); // bit si_int __popcountdi2(di_int a); // bit population si_int __popcountti2(ti_int a); // bit population -uint32_t __bswapsi2(uint32_t a); // a byteswapped, arm only -uint64_t __bswapdi2(uint64_t a); // a byteswapped, arm only +uint32_t __bswapsi2(uint32_t a); // a byteswapped, arm/mips only +uint64_t __bswapdi2(uint64_t a); // a byteswapped, arm/mips only // Integral arithmetic Added: head/contrib/compiler-rt/lib/builtins/bswapdi2.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/compiler-rt/lib/builtins/bswapdi2.c Sun May 21 23:15:32 2017 (r318601) @@ -0,0 +1,28 @@ +/* ===-- bswapdi2.c - Implement __bswapdi2 ---------------------------------=== + * + * The LLVM Compiler Infrastructure + * + * This file is dual licensed under the MIT and the University of Illinois Open + * Source Licenses. See LICENSE.TXT for details. + * + * ===----------------------------------------------------------------------=== + * + * This file implements __bswapdi2 for the compiler_rt library. + * + * ===----------------------------------------------------------------------=== + */ + +#include "int_lib.h" + +COMPILER_RT_ABI uint64_t +__bswapdi2 (uint64_t u) +{ + return ((((u) & 0xff00000000000000ULL) >> 56) + | (((u) & 0x00ff000000000000ULL) >> 40) + | (((u) & 0x0000ff0000000000ULL) >> 24) + | (((u) & 0x000000ff00000000ULL) >> 8) + | (((u) & 0x00000000ff000000ULL) << 8) + | (((u) & 0x0000000000ff0000ULL) << 24) + | (((u) & 0x000000000000ff00ULL) << 40) + | (((u) & 0x00000000000000ffULL) << 56)); +} Added: head/contrib/compiler-rt/lib/builtins/bswapsi2.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/compiler-rt/lib/builtins/bswapsi2.c Sun May 21 23:15:32 2017 (r318601) @@ -0,0 +1,25 @@ +/* ===-- bswapsi2.c - Implement __bswapsi2 ---------------------------------=== + * + * The LLVM Compiler Infrastructure + * + * This file is dual licensed under the MIT and the University of Illinois Open + * Source Licenses. See LICENSE.TXT for details. + * + * ===----------------------------------------------------------------------=== + * + * This file implements __bswapsi2 for the compiler_rt library. + * + * ===----------------------------------------------------------------------=== + */ + +#include "int_lib.h" + +COMPILER_RT_ABI uint32_t +__bswapsi2 (uint32_t u) +{ + + return ((((u) & 0xff000000) >> 24) + | (((u) & 0x00ff0000) >> 8) + | (((u) & 0x0000ff00) << 8) + | (((u) & 0x000000ff) << 24)); +} Modified: head/lib/libcompiler_rt/Makefile.inc ============================================================================== --- head/lib/libcompiler_rt/Makefile.inc Sun May 21 22:28:28 2017 (r318600) +++ head/lib/libcompiler_rt/Makefile.inc Sun May 21 23:15:32 2017 (r318601) @@ -224,3 +224,10 @@ SRCS+= switch8.S SRCS+= switchu8.S SRCS+= sync_synchronize.S .endif + +# GCC-6.3 on mips32 requires bswap32 built-in. +.if ${MACHINE_CPUARCH} == "mips" +SRCS+= bswapdi2.c +SRCS+= bswapsi2.c +.endif + From owner-svn-src-head@freebsd.org Sun May 21 23:56:00 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 359AFD7885C; Sun, 21 May 2017 23:56:00 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 07AC9146E; Sun, 21 May 2017 23:55:59 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4LNtxHu084104; Sun, 21 May 2017 23:55:59 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4LNtxtI084103; Sun, 21 May 2017 23:55:59 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705212355.v4LNtxtI084103@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Sun, 21 May 2017 23:55:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318602 - head/sys/mips/atheros 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.23 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, 21 May 2017 23:56:00 -0000 Author: adrian Date: Sun May 21 23:55:58 2017 New Revision: 318602 URL: https://svnweb.freebsd.org/changeset/base/318602 Log: [ar71xx] fix up dump space a la what jhb@ did elsewhere a while ago. Modified: head/sys/mips/atheros/ar71xx_machdep.c Modified: head/sys/mips/atheros/ar71xx_machdep.c ============================================================================== --- head/sys/mips/atheros/ar71xx_machdep.c Sun May 21 23:15:32 2017 (r318601) +++ head/sys/mips/atheros/ar71xx_machdep.c Sun May 21 23:55:58 2017 (r318602) @@ -383,8 +383,8 @@ platform_start(__register_t a0 __unused, phys_avail[0] = MIPS_KSEG0_TO_PHYS(kernel_kseg0_end); phys_avail[1] = ctob(realmem); - dump_avail[0] = phys_avail[0]; - dump_avail[1] = phys_avail[1] - phys_avail[0]; + dump_avail[0] = 0; + dump_avail[1] = phys_avail[1]; physmem = realmem; From owner-svn-src-head@freebsd.org Mon May 22 01:10:13 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EC2D7D7706B; Mon, 22 May 2017 01:10:13 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BE4011170; Mon, 22 May 2017 01:10:13 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4M1ACkq012616; Mon, 22 May 2017 01:10:12 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4M1ACGw012615; Mon, 22 May 2017 01:10:12 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705220110.v4M1ACGw012615@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Mon, 22 May 2017 01:10:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318603 - head/contrib/elftoolchain/nm 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.23 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, 22 May 2017 01:10:14 -0000 Author: emaste Date: Mon May 22 01:10:12 2017 New Revision: 318603 URL: https://svnweb.freebsd.org/changeset/base/318603 Log: nm: document 'r' symbol type PR: 219245 MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/contrib/elftoolchain/nm/nm.1 Modified: head/contrib/elftoolchain/nm/nm.1 ============================================================================== --- head/contrib/elftoolchain/nm/nm.1 Sun May 21 23:55:58 2017 (r318602) +++ head/contrib/elftoolchain/nm/nm.1 Mon May 22 01:10:12 2017 (r318603) @@ -24,7 +24,7 @@ .\" .\" $Id: nm.1 3195 2015-05-12 17:22:19Z emaste $ .\" -.Dd February 15, 2015 +.Dd May 21, 2017 .Os .Dt NM 1 .Sh NAME @@ -304,6 +304,8 @@ A local (uninitialized data) symbol. .It d A local data symbol. +.It r +A local read-only data symbol. .It t A local text symbol. .It v From owner-svn-src-head@freebsd.org Mon May 22 03:01:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BFAFFD77733; Mon, 22 May 2017 03:01:36 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9021F12D2; Mon, 22 May 2017 03:01:36 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4M31ZTk059140; Mon, 22 May 2017 03:01:35 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4M31ZiU059139; Mon, 22 May 2017 03:01:35 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201705220301.v4M31ZiU059139@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Mon, 22 May 2017 03:01:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318606 - head/sys/contrib/ipfilter/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.23 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, 22 May 2017 03:01:36 -0000 Author: cy Date: Mon May 22 03:01:35 2017 New Revision: 318606 URL: https://svnweb.freebsd.org/changeset/base/318606 Log: Refactor & compact struct i6addr_t #ifdef: remove redundant structure definintion when USE_INET6 is false. MFC after: 1 week Modified: head/sys/contrib/ipfilter/netinet/ip_fil.h Modified: head/sys/contrib/ipfilter/netinet/ip_fil.h ============================================================================== --- head/sys/contrib/ipfilter/netinet/ip_fil.h Mon May 22 02:30:15 2017 (r318605) +++ head/sys/contrib/ipfilter/netinet/ip_fil.h Mon May 22 03:01:35 2017 (r318606) @@ -143,11 +143,12 @@ typedef int (* lookupfunc_t) __P((struct * i6addr is used as a container for both IPv4 and IPv6 addresses, as well * as other types of objects, depending on its qualifier. */ -#ifdef USE_INET6 typedef union i6addr { u_32_t i6[4]; struct in_addr in4; +#ifdef USE_INET6 struct in6_addr in6; +#endif void *vptr[2]; lookupfunc_t lptr[2]; struct { @@ -156,19 +157,6 @@ typedef union i6addr { int name; } i6un; } i6addr_t; -#else -typedef union i6addr { - u_32_t i6[4]; - struct in_addr in4; - void *vptr[2]; - lookupfunc_t lptr[2]; - struct { - u_short type; - u_short subtype; - int name; - } i6un; -} i6addr_t; -#endif #define in4_addr in4.s_addr #define iplookupnum i6[1] From owner-svn-src-head@freebsd.org Mon May 22 11:33:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA1F4D78E32; Mon, 22 May 2017 11:33:45 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AC12B1799; Mon, 22 May 2017 11:33:45 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MBXixJ069927; Mon, 22 May 2017 11:33:44 GMT (envelope-from royger@FreeBSD.org) Received: (from royger@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MBXieZ069926; Mon, 22 May 2017 11:33:44 GMT (envelope-from royger@FreeBSD.org) Message-Id: <201705221133.v4MBXieZ069926@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: royger set sender to royger@FreeBSD.org using -f From: =?UTF-8?Q?Roger_Pau_Monn=c3=a9?= Date: Mon, 22 May 2017 11:33:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318631 - head/sys/dev/xen/netfront 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.23 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, 22 May 2017 11:33:46 -0000 Author: royger Date: Mon May 22 11:33:44 2017 New Revision: 318631 URL: https://svnweb.freebsd.org/changeset/base/318631 Log: xen/netfront: don't drop the RX lock in xn_rxeof Since netfront uses different locks for the RX and TX paths there's no need to drop the RX lock before calling if_input. Suggested by: jhb Tested by: cperciva Sponsored by: Citrix Systems R&D MFC with: r318523 Modified: head/sys/dev/xen/netfront/netfront.c Modified: head/sys/dev/xen/netfront/netfront.c ============================================================================== --- head/sys/dev/xen/netfront/netfront.c Mon May 22 10:28:17 2017 (r318630) +++ head/sys/dev/xen/netfront/netfront.c Mon May 22 11:33:44 2017 (r318631) @@ -1224,7 +1224,6 @@ xn_rxeof(struct netfront_rxq *rxq) RING_FINAL_CHECK_FOR_RESPONSES(&rxq->ring, work_to_do); } while (work_to_do); - XN_RX_UNLOCK(rxq); mbufq_drain(&mbufq_errq); /* * Process all the mbufs after the remapping is complete. @@ -1253,7 +1252,6 @@ xn_rxeof(struct netfront_rxq *rxq) */ tcp_lro_flush_all(lro); #endif - XN_RX_LOCK(rxq); } static void From owner-svn-src-head@freebsd.org Mon May 22 11:38:41 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3D8C1D78F36; Mon, 22 May 2017 11:38:41 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E92711A69; Mon, 22 May 2017 11:38:40 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MBcet8070250; Mon, 22 May 2017 11:38:40 GMT (envelope-from royger@FreeBSD.org) Received: (from royger@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MBcdgw070249; Mon, 22 May 2017 11:38:39 GMT (envelope-from royger@FreeBSD.org) Message-Id: <201705221138.v4MBcdgw070249@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: royger set sender to royger@FreeBSD.org using -f From: =?UTF-8?Q?Roger_Pau_Monn=c3=a9?= Date: Mon, 22 May 2017 11:38:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318632 - 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.23 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, 22 May 2017 11:38:41 -0000 Author: royger Date: Mon May 22 11:38:39 2017 New Revision: 318632 URL: https://svnweb.freebsd.org/changeset/base/318632 Log: bsdinstall: mount is not needed for the ZFS install case Because the datasets are already mounted by zfsboot, and the mount script doesn't know anything about ZFS. Also do not execute the "umount" script for ZFS for the same reasons. Reviewed by: dteske, tsoome Sponsored by: Citrix Systems R&D MFC after: 1 week Differential revision: https://reviews.freebsd.org/D10738 Modified: head/usr.sbin/bsdinstall/scripts/script Modified: head/usr.sbin/bsdinstall/scripts/script ============================================================================== --- head/usr.sbin/bsdinstall/scripts/script Mon May 22 11:33:44 2017 (r318631) +++ head/usr.sbin/bsdinstall/scripts/script Mon May 22 11:38:39 2017 (r318632) @@ -42,6 +42,11 @@ f_include $BSDCFG_SHARE/variable.subr # DISTRIBUTIONS # BSDINSTALL_DISTDIR +# +# Default name of the ZFS boot-pool +# +: ${ZFSBOOT_POOL_NAME:=zroot} + ############################################################ GLOBALS # @@ -53,8 +58,6 @@ msg_installation_error="Installation Err error() { - [ -f "$PATH_FSTAB" ] && bsdinstall umount - local file f_getvar "$VAR_DEBUG_FILE#+" file if [ "$file" ]; then @@ -63,6 +66,13 @@ error() # No need to restore title, pining for the fjords fi + [ -f "$PATH_FSTAB" ] || exit + if [ "$ZFSBOOT_DISKS" ]; then + zpool export $ZFSBOOT_POOL_NAME + else + bsdinstall umount + fi + exit 1 } @@ -99,8 +109,8 @@ if [ "$ZFSBOOT_DISKS" ]; then bsdinstall zfsboot else bsdinstall scriptedpart "$PARTITIONS" + bsdinstall mount fi -bsdinstall mount # Unpack distributions bsdinstall checksum @@ -125,7 +135,11 @@ if [ -f /tmp/bsdinstall-installscript-ab fi bsdinstall entropy -bsdinstall umount +if [ "$ZFSBOOT_DISKS" ]; then + zpool export $ZFSBOOT_POOL_NAME +else + bsdinstall umount +fi f_dprintf "Installation Completed at %s" "$( date )" From owner-svn-src-head@freebsd.org Mon May 22 11:41:19 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4C601D78FFE; Mon, 22 May 2017 11:41:19 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 18F731D92; Mon, 22 May 2017 11:41:19 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MBfI4o072509; Mon, 22 May 2017 11:41:18 GMT (envelope-from royger@FreeBSD.org) Received: (from royger@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MBfISm072508; Mon, 22 May 2017 11:41:18 GMT (envelope-from royger@FreeBSD.org) Message-Id: <201705221141.v4MBfISm072508@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: royger set sender to royger@FreeBSD.org using -f From: =?UTF-8?Q?Roger_Pau_Monn=c3=a9?= Date: Mon, 22 May 2017 11:41:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318633 - 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.23 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, 22 May 2017 11:41:19 -0000 Author: royger Date: Mon May 22 11:41:17 2017 New Revision: 318633 URL: https://svnweb.freebsd.org/changeset/base/318633 Log: bsdinstall: do not use distextract in scripted mode It requires a tty, which might not be available in scripted installs. Instead extract the sets manually using tar. Reviewed by: tsoome Sponsored by: Citrix Systems R&D MFC after: 1 week Differential revision: https://reviews.freebsd.org/D10736 Modified: head/usr.sbin/bsdinstall/scripts/script Modified: head/usr.sbin/bsdinstall/scripts/script ============================================================================== --- head/usr.sbin/bsdinstall/scripts/script Mon May 22 11:38:39 2017 (r318632) +++ head/usr.sbin/bsdinstall/scripts/script Mon May 22 11:41:17 2017 (r318633) @@ -114,7 +114,10 @@ fi # Unpack distributions bsdinstall checksum -bsdinstall distextract +for set in $DISTRIBUTIONS; do + f_dprintf "Extracting $BSDINSTALL_DISTDIR/$set" + tar -xf "$BSDINSTALL_DISTDIR/$set" -C $BSDINSTALL_CHROOT +done # Finalize install bsdinstall config From owner-svn-src-head@freebsd.org Mon May 22 11:43:20 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6F2BD7622D; Mon, 22 May 2017 11:43:20 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9718210D1; Mon, 22 May 2017 11:43:20 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MBhJx1074142; Mon, 22 May 2017 11:43:19 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MBhJer074140; Mon, 22 May 2017 11:43:19 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705221143.v4MBhJer074140@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Mon, 22 May 2017 11:43:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318634 - in head/sys: compat/freebsd32 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.23 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, 22 May 2017 11:43:20 -0000 Author: emaste Date: Mon May 22 11:43:19 2017 New Revision: 318634 URL: https://svnweb.freebsd.org/changeset/base/318634 Log: disallow open(2) in capability mode Previously open(2) was allowed in capability mode, with a comment that suggested this was likely the case to facilitate debugging. The system call would still fail later on, but it's better to disallow the syscall altogether. We now have the kern.trap_enotcap sysctl or PROC_TRAPCAP_CTL proccontrol to aid in debugging. In any case libc has translated open() to the openat syscall since r277032. Reviewed by: kib, rwatson Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10850 Modified: head/sys/compat/freebsd32/capabilities.conf head/sys/kern/capabilities.conf Modified: head/sys/compat/freebsd32/capabilities.conf ============================================================================== --- head/sys/compat/freebsd32/capabilities.conf Mon May 22 11:41:17 2017 (r318633) +++ head/sys/compat/freebsd32/capabilities.conf Mon May 22 11:43:19 2017 (r318634) @@ -188,7 +188,6 @@ renameat symlinkat unlinkat freebsd32_utimensat -open pdfork pdgetpid pdkill Modified: head/sys/kern/capabilities.conf ============================================================================== --- head/sys/kern/capabilities.conf Mon May 22 11:41:17 2017 (r318633) +++ head/sys/kern/capabilities.conf Mon May 22 11:43:19 2017 (r318634) @@ -460,14 +460,6 @@ unlinkat utimensat ## -## Allow entry into open(2). This system call will fail, since access to the -## global file namespace has been disallowed, but allowing entry into the -## syscall means that an audit trail will be generated (which is also very -## useful for debugging). -## -open - -## ## Process descriptor-related system calls are allowed. ## pdfork From owner-svn-src-head@freebsd.org Mon May 22 11:45:46 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AF26AD762EF; Mon, 22 May 2017 11:45:46 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 68B5C12BE; Mon, 22 May 2017 11:45:46 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MBjj2s074317; Mon, 22 May 2017 11:45:45 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MBjjjc074315; Mon, 22 May 2017 11:45:45 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705221145.v4MBjjjc074315@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Mon, 22 May 2017 11:45:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318635 - in head/sys: compat/freebsd32 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.23 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, 22 May 2017 11:45:46 -0000 Author: emaste Date: Mon May 22 11:45:45 2017 New Revision: 318635 URL: https://svnweb.freebsd.org/changeset/base/318635 Log: Regen sysent after r318634, no open(2) in capability mode Sponsored by: The FreeBSD Foundation Modified: head/sys/compat/freebsd32/freebsd32_sysent.c head/sys/kern/init_sysent.c Modified: head/sys/compat/freebsd32/freebsd32_sysent.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_sysent.c Mon May 22 11:43:19 2017 (r318634) +++ head/sys/compat/freebsd32/freebsd32_sysent.c Mon May 22 11:45:45 2017 (r318635) @@ -57,7 +57,7 @@ struct sysent freebsd32_sysent[] = { { 0, (sy_call_t *)sys_fork, AUE_FORK, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 2 = fork */ { AS(read_args), (sy_call_t *)sys_read, AUE_READ, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 3 = read */ { AS(write_args), (sy_call_t *)sys_write, AUE_WRITE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 4 = write */ - { AS(open_args), (sy_call_t *)sys_open, AUE_OPEN_RWTC, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 5 = open */ + { AS(open_args), (sy_call_t *)sys_open, AUE_OPEN_RWTC, NULL, 0, 0, 0, SY_THR_STATIC }, /* 5 = open */ { AS(close_args), (sy_call_t *)sys_close, AUE_CLOSE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 6 = close */ { AS(freebsd32_wait4_args), (sy_call_t *)freebsd32_wait4, AUE_WAIT4, NULL, 0, 0, 0, SY_THR_STATIC }, /* 7 = freebsd32_wait4 */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 8 = obsolete old creat */ Modified: head/sys/kern/init_sysent.c ============================================================================== --- head/sys/kern/init_sysent.c Mon May 22 11:43:19 2017 (r318634) +++ head/sys/kern/init_sysent.c Mon May 22 11:45:45 2017 (r318635) @@ -50,7 +50,7 @@ struct sysent sysent[] = { { 0, (sy_call_t *)sys_fork, AUE_FORK, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 2 = fork */ { AS(read_args), (sy_call_t *)sys_read, AUE_READ, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 3 = read */ { AS(write_args), (sy_call_t *)sys_write, AUE_WRITE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 4 = write */ - { AS(open_args), (sy_call_t *)sys_open, AUE_OPEN_RWTC, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 5 = open */ + { AS(open_args), (sy_call_t *)sys_open, AUE_OPEN_RWTC, NULL, 0, 0, 0, SY_THR_STATIC }, /* 5 = open */ { AS(close_args), (sy_call_t *)sys_close, AUE_CLOSE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 6 = close */ { AS(wait4_args), (sy_call_t *)sys_wait4, AUE_WAIT4, NULL, 0, 0, 0, SY_THR_STATIC }, /* 7 = wait4 */ { compat(AS(ocreat_args),creat), AUE_CREAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 8 = old creat */ From owner-svn-src-head@freebsd.org Mon May 22 13:21:29 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7CD0BD785CA; Mon, 22 May 2017 13:21:29 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4F03C1702; Mon, 22 May 2017 13:21:29 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MDLS8h016087; Mon, 22 May 2017 13:21:28 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MDLSmr016086; Mon, 22 May 2017 13:21:28 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705221321.v4MDLSmr016086@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Mon, 22 May 2017 13:21:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318641 - head/lib/libthr 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.23 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, 22 May 2017 13:21:29 -0000 Author: vangyzen Date: Mon May 22 13:21:28 2017 New Revision: 318641 URL: https://svnweb.freebsd.org/changeset/base/318641 Log: Revert r318583 (libthr: use default WARNS level of 6) Revert this while I fix RISC-V, SPARC, and probably all architectures that use GCC. Reported by: kib Pointy hat to: vangyzen Sponsored by: Dell EMC Modified: head/lib/libthr/Makefile Modified: head/lib/libthr/Makefile ============================================================================== --- head/lib/libthr/Makefile Mon May 22 13:15:59 2017 (r318640) +++ head/lib/libthr/Makefile Mon May 22 13:21:28 2017 (r318641) @@ -16,6 +16,7 @@ MK_SSP= no LIB=thr SHLIB_MAJOR= 3 +WARNS?= 3 NO_WTHREAD_SAFETY=1 CFLAGS+=-DPTHREAD_KERNEL CFLAGS+=-I${SRCTOP}/lib/libc/include -I${.CURDIR}/thread \ From owner-svn-src-head@freebsd.org Mon May 22 13:56:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 31FF9D78EDD; Mon, 22 May 2017 13:56:01 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 027AA1DAD; Mon, 22 May 2017 13:56:00 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MDu0LR029260; Mon, 22 May 2017 13:56:00 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MDu0t1029256; Mon, 22 May 2017 13:56:00 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705221356.v4MDu0t1029256@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Mon, 22 May 2017 13:56:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318643 - head/usr.sbin/efivar 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.23 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, 22 May 2017 13:56:01 -0000 Author: gjb Date: Mon May 22 13:55:59 2017 New Revision: 318643 URL: https://svnweb.freebsd.org/changeset/base/318643 Log: Correct the "first appeared in" version for efivar(8). MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/usr.sbin/efivar/efivar.8 Modified: head/usr.sbin/efivar/efivar.8 ============================================================================== --- head/usr.sbin/efivar/efivar.8 Mon May 22 13:27:31 2017 (r318642) +++ head/usr.sbin/efivar/efivar.8 Mon May 22 13:55:59 2017 (r318643) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 21, 2017 +.Dd May 22, 2017 .Dt EFIVAR 8 .Os .Sh NAME @@ -180,4 +180,4 @@ have the format described in RFC 4122. The .Nm utility first appeared in -.Fx 12.0 . +.Fx 11.1 . From owner-svn-src-head@freebsd.org Mon May 22 14:21:08 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 96BB6D78ACE; Mon, 22 May 2017 14:21:08 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6651B13C8; Mon, 22 May 2017 14:21:08 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MEL7s9040037; Mon, 22 May 2017 14:21:07 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MEL7tY040036; Mon, 22 May 2017 14:21:07 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705221421.v4MEL7tY040036@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Mon, 22 May 2017 14:21:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318645 - head/gnu/usr.bin/groff/tmac 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.23 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, 22 May 2017 14:21:08 -0000 Author: gjb Date: Mon May 22 14:21:07 2017 New Revision: 318645 URL: https://svnweb.freebsd.org/changeset/base/318645 Log: Add 11.1 to the mdoc(7) mdoc.local.in. Sponsored by: The FreeBSD Foundation Modified: head/gnu/usr.bin/groff/tmac/mdoc.local.in Modified: head/gnu/usr.bin/groff/tmac/mdoc.local.in ============================================================================== --- head/gnu/usr.bin/groff/tmac/mdoc.local.in Mon May 22 13:56:34 2017 (r318644) +++ head/gnu/usr.bin/groff/tmac/mdoc.local.in Mon May 22 14:21:07 2017 (r318645) @@ -65,6 +65,7 @@ .ds doc-operating-system-FreeBSD-10.2 10.2 .ds doc-operating-system-FreeBSD-10.3 10.3 .ds doc-operating-system-FreeBSD-11.0 11.0 +.ds doc-operating-system-FreeBSD-11.1 11.1 .ds doc-operating-system-FreeBSD-12.0 12.0 . .\" Definitions for other *BSDs not (yet) in doc-common From owner-svn-src-head@freebsd.org Mon May 22 14:21:47 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0EA73D78C56; Mon, 22 May 2017 14:21:47 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BA08D1611; Mon, 22 May 2017 14:21:46 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MELjN7040836; Mon, 22 May 2017 14:21:45 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MELj1f040835; Mon, 22 May 2017 14:21:45 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705221421.v4MELj1f040835@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Mon, 22 May 2017 14:21:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318646 - in head/release: . 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.23 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, 22 May 2017 14:21:47 -0000 Author: gjb Date: Mon May 22 14:21:45 2017 New Revision: 318646 URL: https://svnweb.freebsd.org/changeset/base/318646 Log: Allow PORTSDIR to be overridden in the pkg-stage target. Submitted by: Johannes Jost Meixner (original) PR: 218393 MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/release/Makefile head/release/scripts/pkg-stage.sh Modified: head/release/Makefile ============================================================================== --- head/release/Makefile Mon May 22 14:21:07 2017 (r318645) +++ head/release/Makefile Mon May 22 14:21:45 2017 (r318646) @@ -270,7 +270,7 @@ packagesystem: base.txz kernel.txz ${EXT pkg-stage: .if !defined(NOPKG) - env REPOS_DIR=${.CURDIR}/pkg_repos/ \ + env PORTSDIR=${PORTSDIR} REPOS_DIR=${.CURDIR}/pkg_repos/ \ sh ${.CURDIR}/scripts/pkg-stage.sh mkdir -p ${.OBJDIR}/dvd/packages/repos/ cp ${.CURDIR}/scripts/FreeBSD_install_cdrom.conf \ Modified: head/release/scripts/pkg-stage.sh ============================================================================== --- head/release/scripts/pkg-stage.sh Mon May 22 14:21:07 2017 (r318645) +++ head/release/scripts/pkg-stage.sh Mon May 22 14:21:45 2017 (r318646) @@ -10,6 +10,7 @@ export PKG_DBDIR="/tmp/pkg" export PERMISSIVE="YES" export REPO_AUTOUPDATE="NO" export PKGCMD="/usr/sbin/pkg -d" +export PORTSDIR="${PORTSDIR:-/usr/ports}" _DVD_PACKAGES="archivers/unzip devel/subversion @@ -33,8 +34,8 @@ x11/kde4 x11/xorg" # If NOPORTS is set for the release, do not attempt to build pkg(8). -if [ ! -f /usr/ports/Makefile ]; then - echo "*** /usr/ports is missing! ***" +if [ ! -f ${PORTSDIR}/Makefile ]; then + echo "*** ${PORTSDIR} is missing! ***" echo "*** Skipping pkg-stage.sh ***" echo "*** Unset NOPORTS to fix this ***" exit 0 @@ -42,7 +43,7 @@ fi if [ ! -x /usr/local/sbin/pkg ]; then /etc/rc.d/ldconfig restart - /usr/bin/make -C /usr/ports/ports-mgmt/pkg install clean + /usr/bin/make -C ${PORTSDIR}/ports-mgmt/pkg install clean fi export DVD_DIR="dvd/packages" @@ -58,7 +59,7 @@ fi # Ensure the ports listed in _DVD_PACKAGES exist to sanitize the # final list. for _P in ${_DVD_PACKAGES}; do - if [ -d "/usr/ports/${_P}" ]; then + if [ -d "${PORTSDIR}/${_P}" ]; then DVD_PACKAGES="${DVD_PACKAGES} ${_P}" else echo "*** Skipping nonexistent port: ${_P}" From owner-svn-src-head@freebsd.org Mon May 22 14:28:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2B261D78DEF; Mon, 22 May 2017 14:28:53 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: from mail-oi0-x22e.google.com (mail-oi0-x22e.google.com [IPv6:2607:f8b0:4003:c06::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E38061A7E; Mon, 22 May 2017 14:28:52 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: by mail-oi0-x22e.google.com with SMTP id b204so163391492oii.1; Mon, 22 May 2017 07:28:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=AfGjVFEs5w6pOjWDIMU1pVZ8xpPUO0YYnmQaoH0LaOw=; b=ZGea64jZ0EQWvILn8uxAcUolMGIVNuCgOvrgdndOYlx/F2BVAezz7iPyWdo9KDjy4C ga/6ql0KE0BO1LwFhNuj3REvB5UclwLmN42PgNetNjFGQiy9K9f6TmCYsMc4edkC0nAU 781uMpqk6UwFFHlt6uaIBhAypbhGj7+KDsODhdPKn6mE/J4EIuRVXSyuvtneNEMA2djU nfZX2C6Vw14K5I80+le1BY9vUqTc+nEguaHjJR+bL6fquOQCQ2k0RaatBF3eQ36IVNWd hNKbpI7EXD6x2EFH51OCPN0JwemgpTpaaUuV/S0fAr3cBEtU80UzCiQrnkzMRPKJm+gv NTjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=AfGjVFEs5w6pOjWDIMU1pVZ8xpPUO0YYnmQaoH0LaOw=; b=VtfQU+5KT8RPpDRbuQnY9sxYtJei3jVknYqMVa4Sosb0mDzZVLmYFK64j9Ro9XN0Rk PBSBnqZ7nt5ddtJa3EoB31VIVOO+3G4HFY6xZB52WEBvui5lII/sxO4CQmHyZ+Cbfa/i tL1f+W64K+ba69WI4gWCkqsSs01PxN8nNw8SszMmbbX9LJjnU51x8woa7Xksc3QHX6z7 0IjsQ9yYWmbfdf1/2rGm2SFzFLfYS7cJ6Z8OJjDBt/kRSlrRVMX4Psx7H2uikAOkugkR wqk9c4vv12rd/67hYb0pptgpfyy1yU7W/iVAR0W8LJkAkxWJLhTxvPENsjQR6yQB+BFd Zubg== X-Gm-Message-State: AODbwcCZrs6DgFZQbya0vSupPvoJbiFzyqWdHE8BZ0rdh2aSQnwCJOag HCeA+Da/fp3mxEVHmCVNOTcPz8VTBg== X-Received: by 10.202.230.8 with SMTP id d8mr12029212oih.206.1495463331961; Mon, 22 May 2017 07:28:51 -0700 (PDT) MIME-Version: 1.0 Received: by 10.182.20.163 with HTTP; Mon, 22 May 2017 07:28:51 -0700 (PDT) In-Reply-To: <201705221356.v4MDu0t1029256@repo.freebsd.org> References: <201705221356.v4MDu0t1029256@repo.freebsd.org> From: Benjamin Kaduk Date: Mon, 22 May 2017 09:28:51 -0500 Message-ID: Subject: Re: svn commit: r318643 - head/usr.sbin/efivar To: Glen Barber Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 22 May 2017 14:28:53 -0000 On Mon, May 22, 2017 at 8:56 AM, Glen Barber wrote: > Author: gjb > Date: Mon May 22 13:55:59 2017 > New Revision: 318643 > URL: https://svnweb.freebsd.org/changeset/base/318643 > > Log: > Correct the "first appeared in" version for efivar(8). > Hmm, I guess I should have put an MFC note for r318599, then. -Ben From owner-svn-src-head@freebsd.org Mon May 22 14:46:15 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5107AD782F8; Mon, 22 May 2017 14:46:15 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 195D91533; Mon, 22 May 2017 14:46:15 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MEkEFX050137; Mon, 22 May 2017 14:46:14 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MEkDJF050133; Mon, 22 May 2017 14:46:13 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705221446.v4MEkDJF050133@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Mon, 22 May 2017 14:46:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318647 - in head: share/man/man4 sys/conf sys/dev/ena sys/modules sys/modules/ena 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.23 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, 22 May 2017 14:46:15 -0000 Author: zbb Date: Mon May 22 14:46:13 2017 New Revision: 318647 URL: https://svnweb.freebsd.org/changeset/base/318647 Log: Add support for Amazon Elastic Network Adapter (ENA) NIC ENA is a networking interface designed to make good use of modern CPU features and system architectures. The ENA device exposes a lightweight management interface with a minimal set of memory mapped registers and extendable command set through an Admin Queue. The driver supports a range of ENA devices, is link-speed independent (i.e., the same driver is used for 10GbE, 25GbE, 40GbE, etc.), and has a negotiated and extendable feature set. Some ENA devices support SR-IOV. This driver is used for both the SR-IOV Physical Function (PF) and Virtual Function (VF) devices. ENA devices enable high speed and low overhead network traffic processing by providing multiple Tx/Rx queue pairs (the maximum number is advertised by the device via the Admin Queue), a dedicated MSI-X interrupt vector per Tx/Rx queue pair, and CPU cacheline optimized data placement. The ENA driver supports industry standard TCP/IP offload features such as checksum offload and TCP transmit segmentation offload (TSO). Receive-side scaling (RSS) is supported for multi-core scaling. The ENA driver and its corresponding devices implement health monitoring mechanisms such as watchdog, enabling the device and driver to recover in a manner transparent to the application, as well as debug logs. Some of the ENA devices support a working mode called Low-latency Queue (LLQ), which saves several more microseconds. This feature will be implemented for driver in future releases. Submitted by: Michal Krawczyk Jakub Palider Jan Medala Obtained from: Semihalf Sponsored by: Amazon.com Inc. Differential revision: https://reviews.freebsd.org/D10427 Added: head/share/man/man4/ena.4 (contents, props changed) head/sys/dev/ena/ head/sys/dev/ena/ena.c (contents, props changed) head/sys/dev/ena/ena.h (contents, props changed) head/sys/dev/ena/ena_sysctl.c (contents, props changed) head/sys/dev/ena/ena_sysctl.h (contents, props changed) head/sys/modules/ena/ head/sys/modules/ena/Makefile (contents, props changed) Modified: head/sys/conf/files head/sys/modules/Makefile Added: head/share/man/man4/ena.4 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/man/man4/ena.4 Mon May 22 14:46:13 2017 (r318647) @@ -0,0 +1,255 @@ +.\" Copyright (c) 2015-2017 Amazon.com, Inc. or its affiliates. +.\" 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 COPYRIGHT HOLDERS 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 COPYRIGHT +.\" OWNER 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$ +.\" +.Dd May 04, 2017 +.Dt ENA 4 +.Os +.Sh NAME +.Nm ena +.Nd "FreeBSD kernel driver for Elastic Network Adapter (ENA) family" +.Sh SYNOPSIS +To compile this driver into the kernel, +place the following line in your +kernel configuration file: +.Bd -ragged -offset indent +.Cd "device ena" +.Ed +.Pp +Alternatively, to load the driver as a +module at boot time, place the following line in +.Xr loader.conf 5 : +.Bd -literal -offset indent +if_ena_load="YES" +.Ed +.Sh DESCRIPTION +The ENA is a networking interface designed to make good use of modern CPU +features and system architectures. +.Pp +The ENA device exposes a lightweight management interface with a +minimal set of memory mapped registers and extendable command set +through an Admin Queue. +.Pp +The driver supports a range of ENA devices, is link-speed independent +(i.e., the same driver is used for 10GbE, 25GbE, 40GbE, etc.), and has +a negotiated and extendable feature set. +.Pp +Some ENA devices support SR-IOV. This driver is used for both the +SR-IOV Physical Function (PF) and Virtual Function (VF) devices. +.Pp +The ENA devices enable high speed and low overhead network traffic +processing by providing multiple Tx/Rx queue pairs (the maximum number +is advertised by the device via the Admin Queue), a dedicated MSI-X +interrupt vector per Tx/Rx queue pair, and CPU cacheline optimized +data placement. +.Pp +The +.Nm +driver supports industry standard TCP/IP offload features such +as checksum offload and TCP transmit segmentation offload (TSO). +Receive-side scaling (RSS) is supported for multi-core scaling. +.Pp +The +.Nm +driver and its corresponding devices implement health +monitoring mechanisms such as watchdog, enabling the device and driver +to recover in a manner transparent to the application, as well as +debug logs. +.Pp +Some of the ENA devices support a working mode called Low-latency +Queue (LLQ), which saves several more microseconds. This feature will +be implemented for driver in future releases. +.Sh HARDWARE +Supported PCI vendor ID/device IDs: +.Pp +.Bl -bullet -compact +.It +1d0f:0ec2 - ENA PF +.It +1d0f:1ec2 - ENA PF with LLQ support +.It +1d0f:ec20 - ENA VF +.It +1d0f:ec21 - ENA VF with LLQ support +.El +.Sh DIAGNOSTICS +.Ss Device initialization phase: +.Bl -diag +.It ena%d: failed to init mmio read less +.Pp +Error occured during initialization of the mmio register read request. +.It ena%d: Can not reset device +.Pp +Device could not be reset; device may not be responding or is already +during reset. +.It ena%d: device version is too low +.Pp +Version of the controller is too low and it is not supported by the driver. +.It ena%d: Invalid dma width value %d +.Pp +The controller is able to request dma transcation width. Device stopped +responding or it demanded invalid value. +.It ena%d: Can not initialize ena admin queue with device +.Pp +Initialization of the Admin Queue failed; device may not be responding or there +was a problem with initialization of the resources. +.It ena%d: Cannot get attribute for ena device rc: %d +.Pp +Failed to get attributes of the device from the controller. +.It ena%d: Cannot configure aenq groups rc: %d +.Pp +Errors occured when trying to configure AENQ groups. +.El +.Ss Driver initialisation/shutdown phase: +.Bl -diag +.It ena%d: PCI resource allocation failed! +.It ena%d: allocating ena_dev failed +.It ena%d: failed to pmap registers bar +.It ena%d: Error while setting up bufring +.It ena%d: Error with initialization of IO rings +.It ena%d: can not allocate ifnet structure +.It ena%d: Error with network interface setup +.It ena%d: Failed to enable and set the admin interrupts +.It ena%d: Failed to allocate %d, vectors %d +.It ena%d: Failed to enable MSIX, vectors %d rc %d +.It ena%d: Error with MSI-X enablement +.It ena%d: could not allocate irq vector: %d +.It ena%d: Unable to allocate bus resource: registers +.Pp +Resource allocation failed when initializing the device; driver will not +be attached. +.It ena%d: ENA device init failed (err: %d) +.Pp +Device initialization failed; driver will not be attached. +.It ena%d: could not activate irq vector: %d +.Pp +Error occured when trying to activate interrupt vectors for Admin Queue. +.It ena%d: failed to register interrupt handler for irq %ju: %d +.Pp +Error occured when trying to register Admin Queue interrupt handler. +.It ena%d: Cannot setup mgmnt queue intr +.Pp +Error occured during configuration of the Admin Queue interrupts. +.It ena%d: Enable MSI-X failed +.Pp +Configuration of the MSI-X for Admin Queue failed; there could be lack +of resources or interrupts could not have been configured; driver will +not be attached. +.It ena%d: VLAN is in use, detach first +.Pp +VLANs are being used when trying to detach the driver; VLANs should be detached +first and then detach routine should be called again. +.It ena%d: Unmapped RX DMA tag associations +.It ena%d: Unmapped TX DMA tag associations +.Pp +Error occured when trying to destroy RX/TX DMA tag. +.It ena%d: Cannot init RSS +.It ena%d: Cannot fill indirect table +.It ena%d: Cannot fill indirect table +.It ena%d: Cannot fill hash function +.It ena%d: Cannot fill hash control +.It ena%d: WARNING: RSS was not properly initialized, it will affect bandwidth +.Pp +Error occured during initialization of one of RSS resources; device is still +going to work but it will affect performance because all RX packets will be +passed to queue 0 and there will be no hash information. +.It ena%d: failed to tear down irq: %d +.It ena%d: dev has no parent while releasing res for irq: %d +Release of the interrupts failed. +.El +.Ss Additional diagnostic: +.Bl -diag +.It ena%d: Cannot get attribute for ena device +.Pp +This message appears when trying to change MTU and driver is unable to get +attributes from the device. +.It ena%d: Invalid MTU setting. new_mtu: %d +.Pp +Requested MTU value is not supported and will not be set. +.It ena%d: keep alive watchdog timeout +.Pp +Device stopped responding and will be reset. +.It ena%d: Found a Tx that wasn't completed on time, qid %d, index %d. +.Pp +Packet was pushed to the NIC but not sent within given time limit; it may +be caused by hang of the IO queue. +.It ena%d: The number of lost tx completion is aboce the threshold (%d > %d). Reset the device +.Pp +If too many Tx wasn't completed on time the device is going to be reset; it may +be caused by hanged queue or device. +.It ena%d: trigger reset is on +.Pp +Device will be reset; reset is triggered either by watchdog or if too many TX +packets were not completed on time. +.It ena%d: invalid value recvd +.Pp +Link status received from the device in the AENQ handler is invalid. +.It ena%d: Allocation for Tx Queue %u failed +.It ena%d: Allocation for Rx Queue %u failed +.It ena%d: Unable to create Rx DMA map for buffer %d +.It ena%d: Failed to create io TX queue #%d rc: %d +.It ena%d: Failed to get TX queue handlers. TX queue num %d rc: %d +.It ena%d: Failed to create io RX queue[%d] rc: %d +.It ena%d: Failed to get RX queue handlers. RX queue num %d rc: %d +.It ena%d: failed to request irq +.It ena%d: could not allocate irq vector: %d +.It ena%d: failed to register interrupt handler for irq %ju: %d +.Pp +IO resources initialization failed. Interface will not be brought up. +.It ena%d: LRO[%d] Initialization failed! +.Pp +Initialization of the LRO for the RX ring failed. +.It ena%d: failed to alloc buffer for rx queue +.It ena%d: failed to add buffer for rx queue %d +.It ena%d: refilled rx queue %d with %d pages only +.Pp +Allocation of resources used on RX path failed; if happened during +initialization of the IO queue, the interface will not be brought up. +.It ena%d: ioctl promisc/allmulti +.Pp +IOCTL request for the device to work in promiscuous/allmulti mode; see +.Xr ifconfig 8 +for more details. +.It ena%d: too many fragments. Last fragment: %d! +.Pp +Packet with unsupported number of segments was queued for sending to the +device; packet will be dropped. +.Sh SUPPORT +If an issue is identified with the released source code with a supported adapter +email the specific information related to the issue to +.Aq Mt mk@semihalf.com +and +.Aq Mt mw@semihalf.com . +.Sh SEE ALSO +.Xr vlan 4 , +.Xr ifconfig 8 +.Sh AUTHORS +The +.Nm +driver was written by +.An Semihalf. Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Mon May 22 14:21:45 2017 (r318646) +++ head/sys/conf/files Mon May 22 14:46:13 2017 (r318647) @@ -1584,6 +1584,12 @@ dev/e1000/e1000_mbx.c optional em \ dev/e1000/e1000_osdep.c optional em \ compile-with "${NORMAL_C} -I$S/dev/e1000" dev/et/if_et.c optional et +dev/ena/ena.c optional ena \ + compile-with "${NORMAL_C} -I$S/contrib" +dev/ena/ena_sysctl.c optional ena \ + compile-with "${NORMAL_C} -I$S/contrib" +contrib/ena-com/ena_com.c optional ena +contrib/ena-com/ena_eth_com.c optional ena dev/ep/if_ep.c optional ep dev/ep/if_ep_isa.c optional ep isa dev/ep/if_ep_pccard.c optional ep pccard Added: head/sys/dev/ena/ena.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ena/ena.c Mon May 22 14:46:13 2017 (r318647) @@ -0,0 +1,3769 @@ +/*- + * BSD LICENSE + * + * Copyright (c) 2015-2017 Amazon.com, Inc. or its affiliates. + * 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 COPYRIGHT HOLDERS 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 COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include "ena.h" +#include "ena_sysctl.h" + +/********************************************************* + * Function prototypes + *********************************************************/ +static int ena_probe(device_t); +static void ena_intr_msix_mgmnt(void *); +static int ena_allocate_pci_resources(struct ena_adapter*); +static void ena_free_pci_resources(struct ena_adapter *); +static int ena_change_mtu(if_t, int); +static inline void ena_alloc_counters(counter_u64_t *, int); +static inline void ena_free_counters(counter_u64_t *, int); +static inline void ena_reset_counters(counter_u64_t *, int); +static void ena_init_io_rings_common(struct ena_adapter *, + struct ena_ring *, uint16_t); +static int ena_init_io_rings(struct ena_adapter *); +static void ena_free_io_ring_resources(struct ena_adapter *, unsigned int); +static void ena_free_all_io_rings_resources(struct ena_adapter *); +static int ena_setup_tx_dma_tag(struct ena_adapter *); +static int ena_free_tx_dma_tag(struct ena_adapter *); +static int ena_setup_rx_dma_tag(struct ena_adapter *); +static int ena_free_rx_dma_tag(struct ena_adapter *); +static int ena_setup_tx_resources(struct ena_adapter *, int); +static void ena_free_tx_resources(struct ena_adapter *, int); +static int ena_setup_all_tx_resources(struct ena_adapter *); +static void ena_free_all_tx_resources(struct ena_adapter *); +static int ena_setup_rx_resources(struct ena_adapter *, unsigned int); +static void ena_free_rx_resources(struct ena_adapter *, unsigned int); +static int ena_setup_all_rx_resources(struct ena_adapter *); +static void ena_free_all_rx_resources(struct ena_adapter *); +static inline int ena_alloc_rx_mbuf(struct ena_adapter *, struct ena_ring *, + struct ena_rx_buffer *); +static void ena_free_rx_mbuf(struct ena_adapter *, struct ena_ring *, + struct ena_rx_buffer *); +static int ena_refill_rx_bufs(struct ena_ring *, uint32_t); +static void ena_free_rx_bufs(struct ena_adapter *, unsigned int); +static void ena_refill_all_rx_bufs(struct ena_adapter *); +static void ena_free_all_rx_bufs(struct ena_adapter *); +static void ena_free_tx_bufs(struct ena_adapter *, unsigned int); +static void ena_free_all_tx_bufs(struct ena_adapter *); +static void ena_destroy_all_tx_queues(struct ena_adapter *); +static void ena_destroy_all_rx_queues(struct ena_adapter *); +static void ena_destroy_all_io_queues(struct ena_adapter *); +static int ena_create_io_queues(struct ena_adapter *); +static int ena_tx_cleanup(struct ena_ring *); +static int ena_rx_cleanup(struct ena_ring *); +static int validate_tx_req_id(struct ena_ring *, uint16_t); +static void ena_rx_hash_mbuf(struct ena_ring *, struct ena_com_rx_ctx *, + struct mbuf *); +static struct mbuf* ena_rx_mbuf(struct ena_ring *, struct ena_com_rx_buf_info *, + struct ena_com_rx_ctx *, uint16_t *); +static inline void ena_rx_checksum(struct ena_ring *, struct ena_com_rx_ctx *, + struct mbuf *); +static void ena_handle_msix(void *); +static int ena_enable_msix(struct ena_adapter *); +static void ena_setup_mgmnt_intr(struct ena_adapter *); +static void ena_setup_io_intr(struct ena_adapter *); +static int ena_request_mgmnt_irq(struct ena_adapter *); +static int ena_request_io_irq(struct ena_adapter *); +static void ena_free_mgmnt_irq(struct ena_adapter *); +static void ena_free_io_irq(struct ena_adapter *); +static void ena_free_irqs(struct ena_adapter*); +static void ena_disable_msix(struct ena_adapter *); +static void ena_unmask_all_io_irqs(struct ena_adapter *); +static int ena_rss_configure(struct ena_adapter *); +static int ena_up_complete(struct ena_adapter *); +static int ena_up(struct ena_adapter *); +static void ena_down(struct ena_adapter *); +static uint64_t ena_get_counter(if_t, ift_counter); +static int ena_media_change(if_t); +static void ena_media_status(if_t, struct ifmediareq *); +static void ena_init(void *); +static int ena_ioctl(if_t, u_long, caddr_t); +static int ena_get_dev_offloads(struct ena_com_dev_get_features_ctx *); +static void ena_update_host_info(struct ena_admin_host_info *, if_t); +static void ena_update_hwassist(struct ena_adapter *); +static int ena_setup_ifnet(device_t, struct ena_adapter *, + struct ena_com_dev_get_features_ctx *); +static void ena_tx_csum(struct ena_com_tx_ctx *, struct mbuf *); +static int ena_xmit_mbuf(struct ena_ring *, struct mbuf *); +static void ena_start_xmit(struct ena_ring *); +static int ena_mq_start(if_t, struct mbuf *); +static void ena_deferred_mq_start(void *, int); +static void ena_qflush(if_t); +static int ena_calc_io_queue_num(struct ena_adapter *, + struct ena_com_dev_get_features_ctx *); +static int ena_calc_queue_size(struct ena_adapter *, uint16_t *, + uint16_t *, struct ena_com_dev_get_features_ctx *); +static int ena_rss_init_default(struct ena_adapter *); +static void ena_rss_init_default_deferred(void *); +static void ena_config_host_info(struct ena_com_dev *); +static int ena_attach(device_t); +static int ena_detach(device_t); +static int ena_device_init(struct ena_adapter *, device_t, + struct ena_com_dev_get_features_ctx *, int *); +static int ena_enable_msix_and_set_admin_interrupts(struct ena_adapter *, + int); +static void ena_update_on_link_change(void *, struct ena_admin_aenq_entry *); +static void unimplemented_aenq_handler(void *, + struct ena_admin_aenq_entry *); +static void ena_timer_service(void *); + +static char ena_version[] = DEVICE_NAME DRV_MODULE_NAME " v" DRV_MODULE_VERSION; + +static SYSCTL_NODE(_hw, OID_AUTO, ena, CTLFLAG_RD, 0, "ENA driver parameters"); + +/* + * Tuneable number of buffers in the buf-ring (drbr) + */ +static int ena_buf_ring_size = 4096; +SYSCTL_INT(_hw_ena, OID_AUTO, buf_ring_size, CTLFLAG_RWTUN, + &ena_buf_ring_size, 0, "Size of the bufring"); + + +static ena_vendor_info_t ena_vendor_info_array[] = { + { PCI_VENDOR_ID_AMAZON, PCI_DEV_ID_ENA_PF, 0}, + { PCI_VENDOR_ID_AMAZON, PCI_DEV_ID_ENA_LLQ_PF, 0}, + { PCI_VENDOR_ID_AMAZON, PCI_DEV_ID_ENA_VF, 0}, + { PCI_VENDOR_ID_AMAZON, PCI_DEV_ID_ENA_LLQ_VF, 0}, + /* Last entry */ + { 0, 0, 0 } +}; + +/* + * Contains pointers to event handlers, e.g. link state chage. + */ +static struct ena_aenq_handlers aenq_handlers; + +void +ena_dmamap_callback(void *arg, bus_dma_segment_t *segs, int nseg, int error) +{ + if (error) + return; + *(bus_addr_t *) arg = segs[0].ds_addr; + return; +} + +int +ena_dma_alloc(device_t dmadev, bus_size_t size, + ena_mem_handle_t *dma , int mapflags) +{ + struct ena_adapter* adapter = device_get_softc(dmadev); + uint32_t maxsize = ((size - 1)/PAGE_SIZE + 1) * PAGE_SIZE; + uint64_t dma_space_addr = ENA_DMA_BIT_MASK(adapter->dma_width); + int error; + + if (dma_space_addr == 0) + dma_space_addr = BUS_SPACE_MAXADDR; + error = bus_dma_tag_create(bus_get_dma_tag(dmadev), /* parent */ + 8, 0, /* alignment, bounds */ + dma_space_addr, /* lowaddr */ + dma_space_addr, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + maxsize, /* maxsize */ + 1, /* nsegments */ + maxsize, /* maxsegsize */ + BUS_DMA_ALLOCNOW, /* flags */ + NULL, /* lockfunc */ + NULL, /* lockarg */ + &dma->tag); + if (error) { + device_printf(dmadev, + "%s: bus_dma_tag_create failed: %d\n", + __func__, error); + goto fail_tag; + } + + error = bus_dmamem_alloc(dma->tag, (void**) &dma->vaddr, + BUS_DMA_COHERENT | BUS_DMA_ZERO, &dma->map); + if (error) { + device_printf(dmadev, + "%s: bus_dmamem_alloc(%ju) failed: %d\n", + __func__, (uintmax_t)size, error); + goto fail_map_create; + } + + dma->paddr = 0; + error = bus_dmamap_load(dma->tag, dma->map, dma->vaddr, + size, ena_dmamap_callback, &dma->paddr, mapflags); + if (error || dma->paddr == 0) { + device_printf(dmadev, + "%s: bus_dmamap_load failed: %d\n", + __func__, error); + goto fail_map_load; + } + + return (0); + +fail_map_load: + bus_dmamap_unload(dma->tag, dma->map); +fail_map_create: + bus_dmamem_free(dma->tag, dma->vaddr, dma->map); + bus_dma_tag_destroy(dma->tag); +fail_tag: + dma->tag = NULL; + + return (error); +} + +static int +ena_allocate_pci_resources(struct ena_adapter* adapter) +{ + device_t pdev = adapter->pdev; + int rid; + + rid = PCIR_BAR(ENA_REG_BAR); + adapter->memory = NULL; + adapter->registers = bus_alloc_resource_any(pdev, SYS_RES_MEMORY, + &rid, RF_ACTIVE); + if (adapter->registers == NULL) { + device_printf(pdev, "Unable to allocate bus resource: " + "registers\n"); + return (ENXIO); + } + + return (0); +} + +static void +ena_free_pci_resources(struct ena_adapter *adapter) +{ + device_t pdev = adapter->pdev; + + if (adapter->memory != NULL) { + bus_release_resource(pdev, SYS_RES_MEMORY, + PCIR_BAR(ENA_MEM_BAR), adapter->memory); + } + + if (adapter->registers != NULL) { + bus_release_resource(pdev, SYS_RES_MEMORY, + PCIR_BAR(ENA_REG_BAR), adapter->registers); + } + + return; +} + +static int +ena_probe(device_t dev) +{ + ena_vendor_info_t *ent; + char adapter_name[60]; + uint16_t pci_vendor_id = 0; + uint16_t pci_device_id = 0; + + pci_vendor_id = pci_get_vendor(dev); + pci_device_id = pci_get_device(dev); + + ent = ena_vendor_info_array; + while (ent->vendor_id != 0) { + if ((pci_vendor_id == ent->vendor_id) && + (pci_device_id == ent->device_id)) { + ena_trace(ENA_DBG, "vendor=%x device=%x ", + pci_vendor_id, pci_device_id); + + sprintf(adapter_name, DEVICE_DESC); + device_set_desc_copy(dev, adapter_name); + return (BUS_PROBE_DEFAULT); + } + + ent++; + + } + + return (ENXIO); +} + +static int +ena_change_mtu(if_t ifp, int new_mtu) +{ + struct ena_adapter *adapter = if_getsoftc(ifp); + struct ena_com_dev_get_features_ctx get_feat_ctx; + int rc, old_mtu, max_frame; + + rc = ena_com_get_dev_attr_feat(adapter->ena_dev, &get_feat_ctx); + if (rc) { + device_printf(adapter->pdev, + "Cannot get attribute for ena device\n"); + return (ENXIO); + } + + /* Save old MTU in case of fail */ + old_mtu = if_getmtu(ifp); + + /* Change MTU and calculate max frame */ + if_setmtu(ifp, new_mtu); + max_frame = ETHER_MAX_FRAME(ifp, ETHERTYPE_VLAN, 1); + + if ((new_mtu < ENA_MIN_FRAME_LEN) || + (new_mtu > get_feat_ctx.dev_attr.max_mtu) || + (max_frame > ENA_MAX_FRAME_LEN)) { + device_printf(adapter->pdev, "Invalid MTU setting. " + "new_mtu: %d\n", new_mtu); + goto error; + } + + rc = ena_com_set_dev_mtu(adapter->ena_dev, new_mtu); + if (rc != 0) + goto error; + + return (0); +error: + if_setmtu(ifp, old_mtu); + return (EINVAL); +} + +static inline void +ena_alloc_counters(counter_u64_t *begin, int size) +{ + counter_u64_t *end = (counter_u64_t *)((char *)begin + size); + + for (; begin < end; ++begin) + *begin = counter_u64_alloc(M_WAITOK); +} + +static inline void +ena_free_counters(counter_u64_t *begin, int size) +{ + counter_u64_t *end = (counter_u64_t *)((char *)begin + size); + + for (; begin < end; ++begin) + counter_u64_free(*begin); +} + +static inline void +ena_reset_counters(counter_u64_t *begin, int size) +{ + counter_u64_t *end = (counter_u64_t *)((char *)begin + size); + + for (; begin < end; ++begin) + counter_u64_zero(*begin); +} + +static void +ena_init_io_rings_common(struct ena_adapter *adapter, struct ena_ring *ring, + uint16_t qid) +{ + + ring->qid = qid; + ring->adapter = adapter; + ring->ena_dev = adapter->ena_dev; +} + +static int +ena_init_io_rings(struct ena_adapter *adapter) +{ + struct ena_com_dev *ena_dev; + struct ena_ring *txr, *rxr; + struct ena_que *que; + int i; + int rc; + + ena_dev = adapter->ena_dev; + + for (i = 0; i < adapter->num_queues; i++) { + txr = &adapter->tx_ring[i]; + rxr = &adapter->rx_ring[i]; + + /* TX/RX common ring state */ + ena_init_io_rings_common(adapter, txr, i); + ena_init_io_rings_common(adapter, rxr, i); + + /* TX specific ring state */ + txr->ring_size = adapter->tx_ring_size; + txr->tx_max_header_size = ena_dev->tx_max_header_size; + txr->tx_mem_queue_type = ena_dev->tx_mem_queue_type; + txr->smoothed_interval = + ena_com_get_nonadaptive_moderation_interval_tx(ena_dev); + + /* Allocate a buf ring */ + txr->br = buf_ring_alloc(ena_buf_ring_size, M_DEVBUF, + M_WAITOK, &txr->ring_mtx); + if (txr->br == NULL) { + device_printf(adapter->pdev, + "Error while setting up bufring\n"); + rc = ENOMEM; + goto err_bufr_free; + } + + /* Alloc TX statistics. */ + ena_alloc_counters((counter_u64_t *)&txr->tx_stats, + sizeof(txr->tx_stats)); + + /* RX specific ring state */ + rxr->ring_size = adapter->rx_ring_size; + rxr->rx_small_copy_len = adapter->small_copy_len; + rxr->smoothed_interval = + ena_com_get_nonadaptive_moderation_interval_rx(ena_dev); + + /* Alloc RX statistics. */ + ena_alloc_counters((counter_u64_t *)&rxr->rx_stats, + sizeof(rxr->rx_stats)); + + /* Initialize locks */ + snprintf(txr->mtx_name, nitems(txr->mtx_name), "%s:tx(%d)", + device_get_nameunit(adapter->pdev), i); + snprintf(rxr->mtx_name, nitems(rxr->mtx_name), "%s:rx(%d)", + device_get_nameunit(adapter->pdev), i); + + mtx_init(&txr->ring_mtx, txr->mtx_name, NULL, MTX_DEF); + mtx_init(&rxr->ring_mtx, rxr->mtx_name, NULL, MTX_DEF); + + que = &adapter->que[i]; + que->adapter = adapter; + que->id = i; + que->tx_ring = txr; + que->rx_ring = rxr; + + txr->que = que; + rxr->que = que; + } + + return 0; + +err_bufr_free: + while (i--) + ena_free_io_ring_resources(adapter, i); + + return (rc); +} + +static void +ena_free_io_ring_resources(struct ena_adapter *adapter, unsigned int qid) +{ + struct ena_ring *txr = &adapter->tx_ring[qid]; + struct ena_ring *rxr = &adapter->rx_ring[qid]; + + ena_free_counters((counter_u64_t *)&txr->tx_stats, + sizeof(txr->tx_stats)); + ena_free_counters((counter_u64_t *)&rxr->rx_stats, + sizeof(rxr->rx_stats)); + + mtx_destroy(&txr->ring_mtx); + mtx_destroy(&rxr->ring_mtx); + + drbr_free(txr->br, M_DEVBUF); + +} + +static void +ena_free_all_io_rings_resources(struct ena_adapter *adapter) +{ + int i; + + for (i = 0; i < adapter->num_queues; i++) + ena_free_io_ring_resources(adapter, i); + +} + +static int +ena_setup_tx_dma_tag(struct ena_adapter *adapter) +{ + int ret; + + /* Create DMA tag for Tx buffers */ + ret = bus_dma_tag_create(bus_get_dma_tag(adapter->pdev), + 1, 0, /* alignment, bounds */ + ENA_DMA_BIT_MASK(adapter->dma_width), /* lowaddr */ + ENA_DMA_BIT_MASK(adapter->dma_width), /* highaddr */ + NULL, NULL, /* filter, filterarg */ + ENA_TSO_MAXSIZE, /* maxsize */ + adapter->max_tx_sgl_size, /* nsegments */ + ENA_TSO_MAXSIZE, /* maxsegsize */ + 0, /* flags */ + NULL, /* lockfunc */ + NULL, /* lockfuncarg */ + &adapter->tx_buf_tag); + + if (ret != 0) + device_printf(adapter->pdev, "Unable to create Tx DMA tag\n"); + + return (ret); +} + +static int +ena_free_tx_dma_tag(struct ena_adapter *adapter) +{ + int ret; + + ret = bus_dma_tag_destroy(adapter->tx_buf_tag); + + if (ret == 0) + adapter->tx_buf_tag = NULL; + + return (ret); +} + +static int +ena_setup_rx_dma_tag(struct ena_adapter *adapter) +{ + int ret; + + /* Create DMA tag for Rx buffers*/ + ret = bus_dma_tag_create(bus_get_dma_tag(adapter->pdev), /* parent */ + 1, 0, /* alignment, bounds */ + ENA_DMA_BIT_MASK(adapter->dma_width), /* lowaddr */ + ENA_DMA_BIT_MASK(adapter->dma_width), /* highaddr */ + NULL, NULL, /* filter, filterarg */ + MJUM16BYTES, /* maxsize */ + 1, /* nsegments */ + MJUM16BYTES, /* maxsegsize */ + 0, /* flags */ + NULL, /* lockfunc */ + NULL, /* lockarg */ + &adapter->rx_buf_tag); + + if (ret != 0) + device_printf(adapter->pdev, "Unable to create Rx DMA tag\n"); + + return (ret); +} + +static int +ena_free_rx_dma_tag(struct ena_adapter *adapter) +{ + int ret; + + ret = bus_dma_tag_destroy(adapter->rx_buf_tag); + + if (ret == 0) + adapter->rx_buf_tag = NULL; + + return (ret); +} + + +/** + * ena_setup_tx_resources - allocate Tx resources (Descriptors) + * @adapter: network interface device structure + * @qid: queue index + * + * Returns 0 on success, otherwise on failure. + **/ +static int +ena_setup_tx_resources(struct ena_adapter *adapter, int qid) +{ + struct ena_que *que = &adapter->que[qid]; + struct ena_ring *tx_ring = que->tx_ring; + int size, i, err; +#ifdef RSS + cpuset_t cpu_mask; +#endif + + size = sizeof(struct ena_tx_buffer) * tx_ring->ring_size; + + tx_ring->tx_buffer_info = malloc(size, M_DEVBUF, M_NOWAIT | M_ZERO); + if (!tx_ring->tx_buffer_info) + goto err_tx_buffer_info; + + size = sizeof(uint16_t) * tx_ring->ring_size; + tx_ring->free_tx_ids = malloc(size, M_DEVBUF, M_NOWAIT | M_ZERO); + if (!tx_ring->free_tx_ids) + goto err_tx_reqs; + + /* Req id stack for TX OOO completions */ + for (i = 0; i < tx_ring->ring_size; i++) + tx_ring->free_tx_ids[i] = i; + + /* Reset TX statistics. */ + ena_reset_counters((counter_u64_t *)&tx_ring->tx_stats, + sizeof(tx_ring->tx_stats)); + + tx_ring->next_to_use = 0; + tx_ring->next_to_clean = 0; + + /* Make sure that drbr is empty */ + drbr_flush(adapter->ifp, tx_ring->br); + + /* ... and create the buffer DMA maps */ + for (i = 0; i < tx_ring->ring_size; i++) { + err = bus_dmamap_create(adapter->tx_buf_tag, 0, + &tx_ring->tx_buffer_info[i].map); + if (err != 0) { + device_printf(adapter->pdev, + "Unable to create Tx DMA map for buffer %d\n", i); + goto err_tx_map; + } + } + + /* Allocate taskqueues */ + TASK_INIT(&tx_ring->enqueue_task, 0, ena_deferred_mq_start, tx_ring); + tx_ring->enqueue_tq = taskqueue_create_fast("ena_tx_enque", M_NOWAIT, + taskqueue_thread_enqueue, &tx_ring->enqueue_tq); + if (tx_ring->enqueue_tq == NULL) { + device_printf(adapter->pdev, + "Unable to create taskqueue for enqueue task\n"); + i = tx_ring->ring_size; + goto err_tx_map; + } + + /* RSS set cpu for thread */ +#ifdef RSS + CPU_SETOF(que->cpu, &cpu_mask); + taskqueue_start_threads_cpuset(&tx_ring->enqueue_tq, 1, PI_NET, + &cpu_mask, "%s tx_ring enq (bucket %d)", + device_get_nameunit(adapter->pdev), que->cpu); +#else /* RSS */ + taskqueue_start_threads(&tx_ring->enqueue_tq, 1, PI_NET, + "%s txeq %d", device_get_nameunit(adapter->pdev), que->cpu); +#endif /* RSS */ + + return (0); + +err_tx_map: + while (i--) { + bus_dmamap_destroy(adapter->tx_buf_tag, + tx_ring->tx_buffer_info[i].map); + } + ENA_MEM_FREE(adapter->ena_dev->dmadev, tx_ring->free_tx_ids); +err_tx_reqs: + ENA_MEM_FREE(adapter->ena_dev->dmadev, tx_ring->tx_buffer_info); +err_tx_buffer_info: + return (ENOMEM); +} + +/** + * ena_free_tx_resources - Free Tx Resources per Queue + * @adapter: network interface device structure + * @qid: queue index + * + * Free all transmit software resources + **/ +static void +ena_free_tx_resources(struct ena_adapter *adapter, int qid) +{ + struct ena_ring *tx_ring = &adapter->tx_ring[qid]; + + while (taskqueue_cancel(tx_ring->enqueue_tq, &tx_ring->enqueue_task, + NULL)) + taskqueue_drain(tx_ring->enqueue_tq, &tx_ring->enqueue_task); + + taskqueue_free(tx_ring->enqueue_tq); + + /* Flush buffer ring, */ + drbr_flush(adapter->ifp, tx_ring->br); + + /* Free buffer DMA maps, */ + for (int i = 0; i < tx_ring->ring_size; i++) { + m_freem(tx_ring->tx_buffer_info[i].mbuf); + tx_ring->tx_buffer_info[i].mbuf = NULL; + bus_dmamap_unload(adapter->tx_buf_tag, + tx_ring->tx_buffer_info[i].map); + bus_dmamap_destroy(adapter->tx_buf_tag, + tx_ring->tx_buffer_info[i].map); + } + + /* And free allocated memory. */ *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Mon May 22 14:57:25 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 82C08D78800; Mon, 22 May 2017 14:57:25 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 002701E51; Mon, 22 May 2017 14:57:24 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4MEvJ9q067730 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 22 May 2017 17:57:19 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4MEvJ9q067730 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4MEvJOR067729; Mon, 22 May 2017 17:57:19 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Mon, 22 May 2017 17:57:19 +0300 From: Konstantin Belousov To: Stephen McConnell Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318427 - in head: share/man/man4 sys/dev/mpr sys/dev/mpr/mpi Message-ID: <20170522145719.GS1622@kib.kiev.ua> References: <201705172133.v4HLXbi6044710@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705172133.v4HLXbi6044710@repo.freebsd.org> User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 22 May 2017 14:57:25 -0000 On Wed, May 17, 2017 at 09:33:37PM +0000, Stephen McConnell wrote: > Author: slm > Date: Wed May 17 21:33:37 2017 > New Revision: 318427 > URL: https://svnweb.freebsd.org/changeset/base/318427 > > Log: > Add tri-mode support (SAS/SATA/PCIe). > > This includes NVMe device support and adds support for the following adapters: > SAS 3408 > SAS 3416 > SAS 3508 > SAS 3516 > SAS 3616 > SAS 3708 > SAS 3716 > > Reviewed by: ken, scottl, asomers, mav > Approved by: ken, scottl, mav > MFC after: 2 weeks > Relnotes: yes > Differential Revision: https://reviews.freebsd.org/D10095 It seems that this commit causes the following compilation issue: cc1: warnings being treated as errors /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c: In function 'mprsas_build_nvme_unm ap': /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c:1839: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] --- mpr_sas.o --- *** [mpr_sas.o] Error code 1 at least on powerpc. From owner-svn-src-head@freebsd.org Mon May 22 15:29:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D57AD78215; Mon, 22 May 2017 15:29:12 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 150081F8E; Mon, 22 May 2017 15:29:12 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MFTBbv066797; Mon, 22 May 2017 15:29:11 GMT (envelope-from tuexen@FreeBSD.org) Received: (from tuexen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MFTAm2066795; Mon, 22 May 2017 15:29:10 GMT (envelope-from tuexen@FreeBSD.org) Message-Id: <201705221529.v4MFTAm2066795@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tuexen set sender to tuexen@FreeBSD.org using -f From: Michael Tuexen Date: Mon, 22 May 2017 15:29:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318649 - in head/sys: netinet 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.23 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, 22 May 2017 15:29:12 -0000 Author: tuexen Date: Mon May 22 15:29:10 2017 New Revision: 318649 URL: https://svnweb.freebsd.org/changeset/base/318649 Log: The connect() system call should return -1 and set errno to EAFNOSUPPORT if it is called on a TCP socket * with an IPv6 address and the socket is bound to an IPv4-mapped IPv6 address. * with an IPv4-mapped IPv6 address and the socket is bound to an IPv6 address. Thanks to Jonathan T. Leighton for reporting this issue. Reviewed by: bz gnn MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D9163 Modified: head/sys/netinet/tcp_usrreq.c head/sys/netinet6/udp6_usrreq.c Modified: head/sys/netinet/tcp_usrreq.c ============================================================================== --- head/sys/netinet/tcp_usrreq.c Mon May 22 15:12:49 2017 (r318648) +++ head/sys/netinet/tcp_usrreq.c Mon May 22 15:29:10 2017 (r318649) @@ -597,6 +597,10 @@ tcp6_usr_connect(struct socket *so, stru error = EINVAL; goto out; } + if ((inp->inp_vflag & INP_IPV4) == 0) { + error = EAFNOSUPPORT; + goto out; + } in6_sin6_2_sin(&sin, sin6p); inp->inp_vflag |= INP_IPV4; @@ -614,6 +618,11 @@ tcp6_usr_connect(struct socket *so, stru #endif error = tp->t_fb->tfb_tcp_output(tp); goto out; + } else { + if ((inp->inp_vflag & INP_IPV6) == 0) { + error = EAFNOSUPPORT; + goto out; + } } #endif inp->inp_vflag &= ~INP_IPV4; Modified: head/sys/netinet6/udp6_usrreq.c ============================================================================== --- head/sys/netinet6/udp6_usrreq.c Mon May 22 15:12:49 2017 (r318648) +++ head/sys/netinet6/udp6_usrreq.c Mon May 22 15:29:10 2017 (r318649) @@ -1119,6 +1119,10 @@ udp6_connect(struct socket *so, struct s error = EINVAL; goto out; } + if ((inp->inp_vflag & INP_IPV4) == 0) { + error = EAFNOSUPPORT; + goto out; + } if (inp->inp_faddr.s_addr != INADDR_ANY) { error = EISCONN; goto out; @@ -1136,6 +1140,11 @@ udp6_connect(struct socket *so, struct s if (error == 0) soisconnected(so); goto out; + } else { + if ((inp->inp_vflag & INP_IPV6) == 0) { + error = EAFNOSUPPORT; + goto out; + } } #endif if (!IN6_IS_ADDR_UNSPECIFIED(&inp->in6p_faddr)) { From owner-svn-src-head@freebsd.org Mon May 22 15:53:31 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 639EFD78C50; Mon, 22 May 2017 15:53:31 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 337B21375; Mon, 22 May 2017 15:53:31 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MFrUmr079169; Mon, 22 May 2017 15:53:30 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MFrU8s079168; Mon, 22 May 2017 15:53:30 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705221553.v4MFrU8s079168@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 22 May 2017 15:53:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318651 - head/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.23 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, 22 May 2017 15:53:31 -0000 Author: ngie Date: Mon May 22 15:53:30 2017 New Revision: 318651 URL: https://svnweb.freebsd.org/changeset/base/318651 Log: Remove glimpse make target added in r181432 The textproc/glimpse port expired over 3 years ago because there weren't any more publicly available distfiles, and because it lacked a maintainer. Remove the target as it's no longer executable on FreeBSD. Differential Revision: D10764 MFC after: 1 month Reviewed by: imp Sponsored by: Dell EMC Isilon Modified: head/sys/Makefile Modified: head/sys/Makefile ============================================================================== --- head/sys/Makefile Mon May 22 15:51:17 2017 (r318650) +++ head/sys/Makefile Mon May 22 15:53:30 2017 (r318651) @@ -59,19 +59,7 @@ TAGS ${.CURDIR}/TAGS: ${.CURDIR}/cscope. rm -f ${.CURDIR}/TAGS cd ${.CURDIR}; xargs etags -a < ${.CURDIR}/cscope.files -# You need the textproc/glimpse ports for this. -glimpse: -.if !exists(${.CURDIR}/.glimpse_exclude) - echo .svn > ${.CURDIR}/.glimpse_exclude - echo /compile/ >> ${.CURDIR}/.glimpse_exclude -.endif - cd ${.CURDIR}; glimpseindex -H . -B -f -o . - -glimpse-clean: - cd ${.CURDIR}; rm -f .glimpse_* - -.if !(make(cscope) || make(cscope-clean) || make(cscope-hook) || make(TAGS) || \ - make(glimpse) || make(glimpse-clean)) +.if !(make(cscope) || make(cscope-clean) || make(cscope-hook) || make(TAGS)) .include # The boot loader From owner-svn-src-head@freebsd.org Mon May 22 15:53:38 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 08F58D78C8D for ; Mon, 22 May 2017 15:53:38 +0000 (UTC) (envelope-from stephen.mcconnell@broadcom.com) Received: from mail-io0-x236.google.com (mail-io0-x236.google.com [IPv6:2607:f8b0:4001:c06::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B1CAB13C5 for ; Mon, 22 May 2017 15:53:37 +0000 (UTC) (envelope-from stephen.mcconnell@broadcom.com) Received: by mail-io0-x236.google.com with SMTP id f102so83589289ioi.2 for ; Mon, 22 May 2017 08:53:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:references:in-reply-to:mime-version:thread-index:date :message-id:subject:to:cc; bh=XmVrJ/uykKBFhuLNtRLWv6zlyX+dgAC+clAxGBBlH/A=; b=BKUEOStPvmto0mnklLAQV+qq4wcxiyVrybLITz17m2KoFfygXaFDHBuNJlrXRs7ARo LvRBeUhOG3MkGQcaolMeQS/W8gIv96zKps2WOnOKSlAco8zR3Y3sYEOAdbufc1SN9j93 HY6Y8n2iKuRkYd0dRCSHTmIYXsnFdfv14CwXk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:references:in-reply-to:mime-version :thread-index:date:message-id:subject:to:cc; bh=XmVrJ/uykKBFhuLNtRLWv6zlyX+dgAC+clAxGBBlH/A=; b=of777jORVdzS8l4e4dboRljPi1WGd/SWoTQ0LXHSk1rHlg80uE3sE9cizDI+er/TwN s0LqfWoJzyKGDAuy+tk5O3NGfuJ1wc8k+L5HmVyRTf2dZyLPASaKVEIDo98GuWzLmQhf P9tG3eMTy6jPHzj+yJx1YdwOGVs31bvKnqfYYhwEdkePkUxCj/vPSeDd+Gt330GYXgp3 o8aYpNY6FBuUW07jq7yIinNY4/vUxJGd8DrfIZbCJ5JEMIQsoyTO84BFW5xK+TAgQv87 aFrqnR//V/HYhO66FGHj/doY4Gm4vLeI5OwZzD7gtOpteYsPUvsp/MfBIB4IpGEd2deF 2YVQ== X-Gm-Message-State: AODbwcDTFt7nWDo5I4EE38b67WhUJNJxRwFjwiab1VvSjJncZqNGNCXH gRYZcoh9aVgOLzpdfbTZh/GAZYdodyHv X-Received: by 10.107.135.20 with SMTP id j20mr23232128iod.56.1495468416918; Mon, 22 May 2017 08:53:36 -0700 (PDT) From: Stephen Mcconnell References: <201705172133.v4HLXbi6044710@repo.freebsd.org> <20170522145719.GS1622@kib.kiev.ua> In-Reply-To: <20170522145719.GS1622@kib.kiev.ua> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQIMtlBOfE3fpeKohkny3vGsD68sXQDlJpdooYWRLyA= Date: Mon, 22 May 2017 09:53:35 -0600 Message-ID: Subject: RE: svn commit: r318427 - in head: share/man/man4 sys/dev/mpr sys/dev/mpr/mpi To: Konstantin Belousov , Stephen McConnell Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 22 May 2017 15:53:38 -0000 > -----Original Message----- > From: Konstantin Belousov [mailto:kostikbel@gmail.com] > Sent: Monday, May 22, 2017 8:57 AM > To: Stephen McConnell > Cc: src-committers@freebsd.org; svn-src-all@freebsd.org; svn-src- > head@freebsd.org > Subject: Re: svn commit: r318427 - in head: share/man/man4 sys/dev/mpr > sys/dev/mpr/mpi > > On Wed, May 17, 2017 at 09:33:37PM +0000, Stephen McConnell wrote: > > Author: slm > > Date: Wed May 17 21:33:37 2017 > > New Revision: 318427 > > URL: https://svnweb.freebsd.org/changeset/base/318427 > > > > Log: > > Add tri-mode support (SAS/SATA/PCIe). > > > > This includes NVMe device support and adds support for the following > adapters: > > SAS 3408 > > SAS 3416 > > SAS 3508 > > SAS 3516 > > SAS 3616 > > SAS 3708 > > SAS 3716 > > > > Reviewed by: ken, scottl, asomers, mav > > Approved by: ken, scottl, mav > > MFC after: 2 weeks > > Relnotes: yes > > Differential Revision: https://reviews.freebsd.org/D10095 > > It seems that this commit causes the following compilation issue: > > cc1: warnings being treated as errors > /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c: In function > 'mprsas_build_nvme_unm > ap': > /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c:1839: warning: cast to pointer > from integer of different size [-Wint-to-pointer-cast] > --- mpr_sas.o --- > *** [mpr_sas.o] Error code 1 > > at least on powerpc. Thanks. I'll take a look. From owner-svn-src-head@freebsd.org Mon May 22 16:13:31 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9CA31D78556; Mon, 22 May 2017 16:13:31 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 651451883; Mon, 22 May 2017 16:13:31 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MGDUl0088311; Mon, 22 May 2017 16:13:30 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MGDUlN088310; Mon, 22 May 2017 16:13:30 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705221613.v4MGDUlN088310@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Mon, 22 May 2017 16:13:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318654 - head/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.23 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, 22 May 2017 16:13:31 -0000 Author: dim Date: Mon May 22 16:13:30 2017 New Revision: 318654 URL: https://svnweb.freebsd.org/changeset/base/318654 Log: For now, disable building libc++experimental for arm, since there are a number of static assertion failures in the time_t related parts. Reported by: mmel, kib Modified: head/lib/Makefile Modified: head/lib/Makefile ============================================================================== --- head/lib/Makefile Mon May 22 16:11:46 2017 (r318653) +++ head/lib/Makefile Mon May 22 16:13:30 2017 (r318654) @@ -156,7 +156,10 @@ _libclang_rt= libclang_rt .if ${MK_LIBCPLUSPLUS} != "no" _libcxxrt= libcxxrt -_libcplusplus= libc++ libc++experimental +_libcplusplus= libc++ +.if ${MACHINE_CPUARCH} != "arm" +_libcplusplus+= libc++experimental +.endif .endif SUBDIR.${MK_EFI}+= libefivar From owner-svn-src-head@freebsd.org Mon May 22 16:16:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 71980D78718; Mon, 22 May 2017 16:16:50 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C3BE1C6C; Mon, 22 May 2017 16:16:50 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MGGnMN088486; Mon, 22 May 2017 16:16:49 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MGGnGw088483; Mon, 22 May 2017 16:16:49 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705221616.v4MGGnGw088483@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Mon, 22 May 2017 16:16:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318655 - in head/contrib/llvm: include/llvm/MC lib/MC lib/Target/ARM/MCTargetDesc 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.23 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, 22 May 2017 16:16:50 -0000 Author: dim Date: Mon May 22 16:16:48 2017 New Revision: 318655 URL: https://svnweb.freebsd.org/changeset/base/318655 Log: Pull in r302416 from upstream llvm trunk (by Martin Storsjö): [ARM] Clear the constant pool cache on explicit .ltorg directives Multiple ldr pseudoinstructions with the same constant value will reuse the same constant pool entry. However, if the constant pool is explicitly flushed with a .ltorg directive, we should not try to reference constants in the previous pool any longer, since they may be out of range. This fixes assembling hand-written assembler source which repeatedly loads the same constant value, across a binary size larger than the pc-relative fixup range for ldr instructions (4096 bytes). Such assembler source already uses explicit .ltorg instructions to emit constant pools with regular intervals. However if we try to reuse constants emitted in earlier pools, they end up out of range. This makes the output of the testcase match what binutils gas does (prior to this patch, it would fail to assemble). Differential Revision: https://reviews.llvm.org/D32847 This should fix "out of range pc-relative fixup value" errors, when compiling certain ARM inline assembly for www/webkit-gtk[23]. Reported by: mmel MFC after: 3 days Modified: head/contrib/llvm/include/llvm/MC/ConstantPools.h head/contrib/llvm/lib/MC/ConstantPools.cpp head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMTargetStreamer.cpp Modified: head/contrib/llvm/include/llvm/MC/ConstantPools.h ============================================================================== --- head/contrib/llvm/include/llvm/MC/ConstantPools.h Mon May 22 16:13:30 2017 (r318654) +++ head/contrib/llvm/include/llvm/MC/ConstantPools.h Mon May 22 16:16:48 2017 (r318655) @@ -60,6 +60,8 @@ public: // Return true if the constant pool is empty bool empty(); + + void clearCache(); }; class AssemblerConstantPools { @@ -83,6 +85,7 @@ class AssemblerConstantPools { public: void emitAll(MCStreamer &Streamer); void emitForCurrentSection(MCStreamer &Streamer); + void clearCacheForCurrentSection(MCStreamer &Streamer); const MCExpr *addEntry(MCStreamer &Streamer, const MCExpr *Expr, unsigned Size, SMLoc Loc); Modified: head/contrib/llvm/lib/MC/ConstantPools.cpp ============================================================================== --- head/contrib/llvm/lib/MC/ConstantPools.cpp Mon May 22 16:13:30 2017 (r318654) +++ head/contrib/llvm/lib/MC/ConstantPools.cpp Mon May 22 16:16:48 2017 (r318655) @@ -54,6 +54,10 @@ const MCExpr *ConstantPool::addEntry(con bool ConstantPool::empty() { return Entries.empty(); } +void ConstantPool::clearCache() { + CachedEntries.clear(); +} + // // AssemblerConstantPools implementation // @@ -95,6 +99,13 @@ void AssemblerConstantPools::emitForCurr } } +void AssemblerConstantPools::clearCacheForCurrentSection(MCStreamer &Streamer) { + MCSection *Section = Streamer.getCurrentSectionOnly(); + if (ConstantPool *CP = getConstantPool(Section)) { + CP->clearCache(); + } +} + const MCExpr *AssemblerConstantPools::addEntry(MCStreamer &Streamer, const MCExpr *Expr, unsigned Size, SMLoc Loc) { Modified: head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMTargetStreamer.cpp ============================================================================== --- head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMTargetStreamer.cpp Mon May 22 16:13:30 2017 (r318654) +++ head/contrib/llvm/lib/Target/ARM/MCTargetDesc/ARMTargetStreamer.cpp Mon May 22 16:16:48 2017 (r318655) @@ -33,6 +33,7 @@ const MCExpr *ARMTargetStreamer::addCons void ARMTargetStreamer::emitCurrentConstantPool() { ConstantPools->emitForCurrentSection(Streamer); + ConstantPools->clearCacheForCurrentSection(Streamer); } // finish() - write out any non-empty assembler constant pools. From owner-svn-src-head@freebsd.org Mon May 22 19:57:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53690D79155; Mon, 22 May 2017 19:57:30 +0000 (UTC) (envelope-from davidcs@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 22D0D1E43; Mon, 22 May 2017 19:57:30 +0000 (UTC) (envelope-from davidcs@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MJvTYP081700; Mon, 22 May 2017 19:57:29 GMT (envelope-from davidcs@FreeBSD.org) Received: (from davidcs@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MJvTJC081699; Mon, 22 May 2017 19:57:29 GMT (envelope-from davidcs@FreeBSD.org) Message-Id: <201705221957.v4MJvTJC081699@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: davidcs set sender to davidcs@FreeBSD.org using -f From: David C Somayajulu Date: Mon, 22 May 2017 19:57:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318676 - head/sys/dev/qlnx/qlnxe 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.23 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, 22 May 2017 19:57:30 -0000 Author: davidcs Date: Mon May 22 19:57:28 2017 New Revision: 318676 URL: https://svnweb.freebsd.org/changeset/base/318676 Log: Check for IPV6 TCP/UDP CSUM offload in pkt header during transmits. Submitted by:Shminderjit.Singh@cavium.com Modified: head/sys/dev/qlnx/qlnxe/qlnx_os.c Modified: head/sys/dev/qlnx/qlnxe/qlnx_os.c ============================================================================== --- head/sys/dev/qlnx/qlnxe/qlnx_os.c Mon May 22 19:57:20 2017 (r318675) +++ head/sys/dev/qlnx/qlnxe/qlnx_os.c Mon May 22 19:57:28 2017 (r318676) @@ -2946,7 +2946,8 @@ qlnx_send(qlnx_host_t *ha, struct qlnx_f (1 << ETH_TX_1ST_BD_FLAGS_IP_CSUM_SHIFT); } - if (m_head->m_pkthdr.csum_flags & (CSUM_UDP | CSUM_TCP)) { + if (m_head->m_pkthdr.csum_flags & + (CSUM_UDP | CSUM_TCP | CSUM_TCP_IPV6 | CSUM_UDP_IPV6)) { first_bd->data.bd_flags.bitfields |= (1 << ETH_TX_1ST_BD_FLAGS_L4_CSUM_SHIFT); } From owner-svn-src-head@freebsd.org Mon May 22 20:00:03 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B224AD79203; Mon, 22 May 2017 20:00:03 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 72F2710B6; Mon, 22 May 2017 20:00:03 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MK02UH081907; Mon, 22 May 2017 20:00:02 GMT (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MK02BJ081903; Mon, 22 May 2017 20:00:02 GMT (envelope-from glebius@FreeBSD.org) Message-Id: <201705222000.v4MK02BJ081903@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: glebius set sender to glebius@FreeBSD.org using -f From: Gleb Smirnoff Date: Mon, 22 May 2017 20:00:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318677 - in head/sys: compat/ndis dev/if_ndis 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.23 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, 22 May 2017 20:00:03 -0000 Author: glebius Date: Mon May 22 20:00:01 2017 New Revision: 318677 URL: https://svnweb.freebsd.org/changeset/base/318677 Log: Fix regression in ndis(4) after r286410. This adds a bunch of checks for whether this is a Ethernet or 802.11 device and does proper dereferencing. PR: 213237 Submitted by: MFC after: 2 weeks Modified: head/sys/compat/ndis/kern_ndis.c head/sys/compat/ndis/subr_ndis.c head/sys/dev/if_ndis/if_ndis.c head/sys/dev/if_ndis/if_ndisvar.h Modified: head/sys/compat/ndis/kern_ndis.c ============================================================================== --- head/sys/compat/ndis/kern_ndis.c Mon May 22 19:57:28 2017 (r318676) +++ head/sys/compat/ndis/kern_ndis.c Mon May 22 20:00:01 2017 (r318677) @@ -210,8 +210,8 @@ ndis_status_func(adapter, status, sbuf, block = adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); - ifp = sc->ifp; - if (ifp->if_flags & IFF_DEBUG) + ifp = NDISUSB_GET_IFNET(sc); + if ( ifp && ifp->if_flags & IFF_DEBUG) device_printf(sc->ndis_dev, "status: %x\n", status); } @@ -225,8 +225,8 @@ ndis_statusdone_func(adapter) block = adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); - ifp = sc->ifp; - if (ifp->if_flags & IFF_DEBUG) + ifp = NDISUSB_GET_IFNET(sc); + if (ifp && ifp->if_flags & IFF_DEBUG) device_printf(sc->ndis_dev, "status complete\n"); } @@ -264,9 +264,9 @@ ndis_resetdone_func(ndis_handle adapter, block = adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); - ifp = sc->ifp; + ifp = NDISUSB_GET_IFNET(sc); - if (ifp->if_flags & IFF_DEBUG) + if (ifp && ifp->if_flags & IFF_DEBUG) device_printf(sc->ndis_dev, "reset done...\n"); KeSetEvent(&block->nmb_resetevent, IO_NO_INCREMENT, FALSE); } @@ -285,6 +285,9 @@ ndis_create_sysctls(arg) return (EINVAL); sc = arg; + /* + device_printf(sc->ndis_dev, "ndis_create_sysctls() sc=%p\n", sc); + */ vals = sc->ndis_regvals; TAILQ_INIT(&sc->ndis_cfglist_head); @@ -698,8 +701,8 @@ ndis_ptom(m0, p) */ eh = mtod((*m0), struct ether_header *); - ifp = ((struct ndis_softc *)p->np_softc)->ifp; - if (totlen > ETHER_MAX_FRAME(ifp, eh->ether_type, FALSE)) { + ifp = NDISUSB_GET_IFNET((struct ndis_softc *)p->np_softc); + if (ifp && totlen > ETHER_MAX_FRAME(ifp, eh->ether_type, FALSE)) { diff = totlen - ETHER_MAX_FRAME(ifp, eh->ether_type, FALSE); totlen -= diff; m->m_len -= diff; Modified: head/sys/compat/ndis/subr_ndis.c ============================================================================== --- head/sys/compat/ndis/subr_ndis.c Mon May 22 19:57:28 2017 (r318676) +++ head/sys/compat/ndis/subr_ndis.c Mon May 22 20:00:01 2017 (r318677) @@ -626,6 +626,9 @@ NdisReadConfiguration(status, parm, cfg, block = (ndis_miniport_block *)cfg; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); + /* + device_printf(sc->ndis_dev, "NdisReadConfiguration sc=%p\n", sc); + */ if (key->us_len == 0 || key->us_buf == NULL) { *status = NDIS_STATUS_FAILURE; @@ -984,7 +987,7 @@ NdisWriteErrorLogEntry(ndis_handle adapt dev = block->nmb_physdeviceobj->do_devext; drv = block->nmb_deviceobj->do_drvobj; sc = device_get_softc(dev); - ifp = sc->ifp; + ifp = NDISUSB_GET_IFNET(sc); if (ifp != NULL && ifp->if_flags & IFF_DEBUG) { error = pe_get_message((vm_offset_t)drv->dro_driverstart, @@ -1304,17 +1307,19 @@ NdisReadNetworkAddress(status, addr, add ndis_handle adapter; { struct ndis_softc *sc; + struct ifnet *ifp; ndis_miniport_block *block; uint8_t empty[] = { 0, 0, 0, 0, 0, 0 }; block = (ndis_miniport_block *)adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); - if (sc->ifp == NULL) { + ifp = NDISUSB_GET_IFNET(sc); + if (ifp == NULL) { *status = NDIS_STATUS_FAILURE; return; } - if (sc->ifp->if_addr == NULL || + if (ifp->if_addr == NULL || bcmp(IF_LLADDR(sc->ifp), empty, ETHER_ADDR_LEN) == 0) *status = NDIS_STATUS_FAILURE; else { Modified: head/sys/dev/if_ndis/if_ndis.c ============================================================================== --- head/sys/dev/if_ndis/if_ndis.c Mon May 22 19:57:28 2017 (r318676) +++ head/sys/dev/if_ndis/if_ndis.c Mon May 22 20:00:01 2017 (r318677) @@ -147,7 +147,7 @@ static funcptr ndis_rxeof_xfr_done_wrap; static funcptr ndis_linksts_wrap; static funcptr ndis_linksts_done_wrap; static funcptr ndis_ticktask_wrap; -static funcptr ndis_starttask_wrap; +static funcptr ndis_ifstarttask_wrap; static funcptr ndis_resettask_wrap; static funcptr ndis_inputtask_wrap; @@ -162,11 +162,11 @@ static int ndis_raw_xmit (struct ieee802 const struct ieee80211_bpf_params *); static void ndis_update_mcast (struct ieee80211com *); static void ndis_update_promisc (struct ieee80211com *); -static void ndis_start (struct ifnet *); -static void ndis_starttask (device_object *, void *); +static void ndis_ifstart (struct ifnet *); +static void ndis_ifstarttask (device_object *, void *); static void ndis_resettask (device_object *, void *); static void ndis_inputtask (device_object *, void *); -static int ndis_ioctl (struct ifnet *, u_long, caddr_t); +static int ndis_ifioctl (struct ifnet *, u_long, caddr_t); static int ndis_newstate (struct ieee80211vap *, enum ieee80211_state, int); static int ndis_nettype_chan (uint32_t); @@ -246,7 +246,7 @@ ndisdrv_modevent(mod, cmd, arg) &ndis_linksts_done_wrap, 1, WINDRV_WRAP_STDCALL); windrv_wrap((funcptr)ndis_ticktask, &ndis_ticktask_wrap, 2, WINDRV_WRAP_STDCALL); - windrv_wrap((funcptr)ndis_starttask, &ndis_starttask_wrap, + windrv_wrap((funcptr)ndis_ifstarttask, &ndis_ifstarttask_wrap, 2, WINDRV_WRAP_STDCALL); windrv_wrap((funcptr)ndis_resettask, &ndis_resettask_wrap, 2, WINDRV_WRAP_STDCALL); @@ -268,7 +268,7 @@ ndisdrv_modevent(mod, cmd, arg) windrv_unwrap(ndis_linksts_wrap); windrv_unwrap(ndis_linksts_done_wrap); windrv_unwrap(ndis_ticktask_wrap); - windrv_unwrap(ndis_starttask_wrap); + windrv_unwrap(ndis_ifstarttask_wrap); windrv_unwrap(ndis_resettask_wrap); windrv_unwrap(ndis_inputtask_wrap); break; @@ -292,11 +292,14 @@ ndis_setmulti(sc) int len, mclistsz, error; uint8_t *mclist; - ifp = sc->ifp; if (!NDIS_INITIALIZED(sc)) return; + if (sc->ndis_80211) + return; + + ifp = sc->ifp; if (ifp->if_flags & IFF_ALLMULTI || ifp->if_flags & IFF_PROMISC) { sc->ndis_filter |= NDIS_PACKET_TYPE_ALL_MULTICAST; len = sizeof(sc->ndis_filter); @@ -368,13 +371,14 @@ ndis_set_offload(sc) struct ifnet *ifp; int len, error; - ifp = sc->ifp; - if (!NDIS_INITIALIZED(sc)) return (EINVAL); + if (sc->ndis_80211) + return (EINVAL); /* See if there's anything to set. */ + ifp = sc->ifp; error = ndis_probe_offload(sc); if (error) return (error); @@ -965,8 +969,8 @@ ndis_ifattach(struct ndis_softc *sc) if_initname(ifp, device_get_name(sc->ndis_dev), device_get_unit(sc->ndis_dev)); ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; - ifp->if_ioctl = ndis_ioctl; - ifp->if_start = ndis_start; + ifp->if_ioctl = ndis_ifioctl; + ifp->if_start = ndis_ifstart; ifp->if_init = ndis_init; ifp->if_baudrate = 10000000; IFQ_SET_MAXLEN(&ifp->if_snd, 50); @@ -1560,19 +1564,23 @@ ndis_txeof(adapter, packet, status) sc->ndis_txarray[idx] = NULL; sc->ndis_txpending++; - if (status == NDIS_STATUS_SUCCESS) - if_inc_counter(ifp, IFCOUNTER_OPACKETS, 1); - else - if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); - + if (!sc->ndis_80211) { + struct ifnet *ifp = sc->ifp; + if (status == NDIS_STATUS_SUCCESS) + if_inc_counter(ifp, IFCOUNTER_OPACKETS, 1); + else + if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); + ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; + } sc->ndis_tx_timer = 0; - ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; NDIS_UNLOCK(sc); - IoQueueWorkItem(sc->ndis_startitem, - (io_workitem_func)ndis_starttask_wrap, - WORKQUEUE_CRITICAL, ifp); + if (!sc->ndis_80211) + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_ifstarttask_wrap, + WORKQUEUE_CRITICAL, sc); + DPRINTF(("%s: ndis_ifstarttask_wrap sc=%p\n", __func__, sc)); } static void @@ -1635,9 +1643,10 @@ ndis_linksts_done(adapter) IoQueueWorkItem(sc->ndis_tickitem, (io_workitem_func)ndis_ticktask_wrap, WORKQUEUE_CRITICAL, sc); - IoQueueWorkItem(sc->ndis_startitem, - (io_workitem_func)ndis_starttask_wrap, - WORKQUEUE_CRITICAL, ifp); + if (!sc->ndis_80211) + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_ifstarttask_wrap, + WORKQUEUE_CRITICAL, sc); break; case NDIS_STATUS_MEDIA_DISCONNECT: if (sc->ndis_link) @@ -1672,9 +1681,10 @@ ndis_tick(xsc) IoQueueWorkItem(sc->ndis_resetitem, (io_workitem_func)ndis_resettask_wrap, WORKQUEUE_CRITICAL, sc); - IoQueueWorkItem(sc->ndis_startitem, - (io_workitem_func)ndis_starttask_wrap, - WORKQUEUE_CRITICAL, sc->ifp); + if (!sc->ndis_80211) + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_ifstarttask_wrap, + WORKQUEUE_CRITICAL, sc); } callout_reset(&sc->ndis_stat_callout, hz, ndis_tick, sc); @@ -1796,16 +1806,16 @@ ndis_update_promisc(struct ieee80211com } static void -ndis_starttask(d, arg) - device_object *d; - void *arg; +ndis_ifstarttask(device_object *d, void *arg) { - struct ifnet *ifp; - - ifp = arg; + struct ndis_softc *sc = arg; + DPRINTF(("%s: sc=%p, ifp=%p\n", __func__, sc, sc->ifp)); + if (sc->ndis_80211) + return; + struct ifnet *ifp = sc->ifp; if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) - ndis_start(ifp); + ndis_ifstart(ifp); } /* @@ -1821,8 +1831,7 @@ ndis_starttask(d, arg) * will do the mapping themselves on a buffer by buffer basis. */ static void -ndis_start(ifp) - struct ifnet *ifp; +ndis_ifstart(struct ifnet *ifp) { struct ndis_softc *sc; struct mbuf *m = NULL; @@ -2880,7 +2889,7 @@ ndis_getstate_80211(struct ndis_softc *s } static int -ndis_ioctl(ifp, command, data) +ndis_ifioctl(ifp, command, data) struct ifnet *ifp; u_long command; caddr_t data; Modified: head/sys/dev/if_ndis/if_ndisvar.h ============================================================================== --- head/sys/dev/if_ndis/if_ndisvar.h Mon May 22 19:57:28 2017 (r318676) +++ head/sys/dev/if_ndis/if_ndisvar.h Mon May 22 20:00:01 2017 (r318677) @@ -152,6 +152,7 @@ struct ndisusb_task { }; struct ndis_softc { +#define NDISUSB_GET_IFNET(ndis_softc) ( (ndis_softc)->ndis_80211 ? NULL : (ndis_softc)->ifp ) u_int ndis_80211:1, ndis_link:1, ndis_running:1; From owner-svn-src-head@freebsd.org Mon May 22 20:11:42 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 27237D79776; Mon, 22 May 2017 20:11:42 +0000 (UTC) (envelope-from oshogbo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ED4B91A62; Mon, 22 May 2017 20:11:41 +0000 (UTC) (envelope-from oshogbo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MKBf3g087345; Mon, 22 May 2017 20:11:41 GMT (envelope-from oshogbo@FreeBSD.org) Received: (from oshogbo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MKBf4v087344; Mon, 22 May 2017 20:11:41 GMT (envelope-from oshogbo@FreeBSD.org) Message-Id: <201705222011.v4MKBf4v087344@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: oshogbo set sender to oshogbo@FreeBSD.org using -f From: Mariusz Zaborski Date: Mon, 22 May 2017 20:11:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318678 - head/sys/boot/common 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.23 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, 22 May 2017 20:11:42 -0000 Author: oshogbo Date: Mon May 22 20:11:40 2017 New Revision: 318678 URL: https://svnweb.freebsd.org/changeset/base/318678 Log: Replacing iterating over rootpath by strsep(3). Submitted by: kczekirda Reviewed by: tsoome, bapt, jhb, oshogbo MFC after: 3 weeks Sponsored by: Oktawave Differential Revision: https://reviews.freebsd.org/D10726 Modified: head/sys/boot/common/dev_net.c Modified: head/sys/boot/common/dev_net.c ============================================================================== --- head/sys/boot/common/dev_net.c Mon May 22 20:00:01 2017 (r318677) +++ head/sys/boot/common/dev_net.c Mon May 22 20:11:40 2017 (r318678) @@ -387,16 +387,14 @@ net_print(int verbose) uint32_t net_parse_rootpath() { - int i; n_long addr = INADDR_NONE; + char *ptr; - for (i = 0; rootpath[i] != '\0' && i < FNAME_SIZE; i++) - if (rootpath[i] == ':') - break; - if (i && i != FNAME_SIZE && rootpath[i] == ':') { - rootpath[i++] = '\0'; - addr = inet_addr(&rootpath[0]); - bcopy(&rootpath[i], rootpath, strlen(&rootpath[i])+1); + ptr = rootpath; + (void)strsep(&ptr, ":"); + if (ptr != NULL) { + addr = inet_addr(rootpath); + bcopy(ptr, rootpath, strlen(ptr) + 1); } return (addr); From owner-svn-src-head@freebsd.org Mon May 22 20:27:31 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 15ED5D79BE6; Mon, 22 May 2017 20:27:31 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DA9721359; Mon, 22 May 2017 20:27:30 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MKRT9X093901; Mon, 22 May 2017 20:27:29 GMT (envelope-from slm@FreeBSD.org) Received: (from slm@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MKRTxn093900; Mon, 22 May 2017 20:27:29 GMT (envelope-from slm@FreeBSD.org) Message-Id: <201705222027.v4MKRTxn093900@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: slm set sender to slm@FreeBSD.org using -f From: Stephen McConnell Date: Mon, 22 May 2017 20:27:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318679 - head/sys/dev/mpr 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.23 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, 22 May 2017 20:27:31 -0000 Author: slm Date: Mon May 22 20:27:29 2017 New Revision: 318679 URL: https://svnweb.freebsd.org/changeset/base/318679 Log: Fix powerpc compiler error. Approved by: ken Modified: head/sys/dev/mpr/mpr_sas.c Modified: head/sys/dev/mpr/mpr_sas.c ============================================================================== --- head/sys/dev/mpr/mpr_sas.c Mon May 22 20:11:40 2017 (r318678) +++ head/sys/dev/mpr/mpr_sas.c Mon May 22 20:27:29 2017 (r318679) @@ -1836,8 +1836,8 @@ mprsas_build_nvme_unmap(struct mpr_softc mprsas_log_command(cm, MPR_XINFO, "%s cm %p ccb %p outstanding %u\n", __func__, cm, ccb, targ->outstanding); - mpr_build_nvme_prp(sc, cm, req, (void *)nvme_dsm_ranges_dma_handle, 0, - data_length); + mpr_build_nvme_prp(sc, cm, req, + (void *)(uintptr_t)nvme_dsm_ranges_dma_handle, 0, data_length); mpr_map_command(sc, cm); out: From owner-svn-src-head@freebsd.org Mon May 22 20:29:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6C4FCD79C58 for ; Mon, 22 May 2017 20:29:27 +0000 (UTC) (envelope-from stephen.mcconnell@broadcom.com) Received: from mail-io0-x229.google.com (mail-io0-x229.google.com [IPv6:2607:f8b0:4001:c06::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 37982152A for ; Mon, 22 May 2017 20:29:27 +0000 (UTC) (envelope-from stephen.mcconnell@broadcom.com) Received: by mail-io0-x229.google.com with SMTP id f102so88380316ioi.2 for ; Mon, 22 May 2017 13:29:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:references:in-reply-to:mime-version:thread-index:date :message-id:subject:to:cc; bh=riO8lwV1mz4TISaekgdQh115eQuqZJErkBAdoxyMg8g=; b=ffQ17FPlgxDpHB72Cz5ugvbTfpSjR9XXRNC3bocbNRsedSTKeIzjNNm0ajNG5oLF3W wU9Cc0tM3TQgUvMApk1D/+aaisVr0OiUyLJlzSumA2miYdhYwXFkTzHNvJyN5MqHQxWr YCw7L32JHt37IlFV1N8iMAR++KSo06FTM0Lzs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:references:in-reply-to:mime-version :thread-index:date:message-id:subject:to:cc; bh=riO8lwV1mz4TISaekgdQh115eQuqZJErkBAdoxyMg8g=; b=hZ/OoVC5gumaIbthRjU2l1a8+QgInXGR/2jxZKH9UeyMR87Q3PPiciEn7IfhrKc4O+ rGM8Fc0Ct7/WO0XQw9mTvuryP0xsm1I3isN5axNjh0sPW5tADFPPXDroCZ2weBwHD8Nl t0VtlbYGkP18LDr7WnMzRmSG8Lto5CaKO788rxsiiXD/9s87XAMWODMHN71A/zJOL+Gv 3Kh3F7af8LRD02D86DpZ5mPs6NUsD/xFAiuFl02zjZV5i1oAtZktbHm7Ysmt8GRNeYLg EyEe7PLTvYZC9JUnrwJDX41IKWo9u/LJ8PeccSv5ChViytY7RMxgDs9NgpCEU30gZ3Un Q/hA== X-Gm-Message-State: AODbwcDVxLnZboMHKJRTYyxspSRwzsh3QlqQvAQYF980I9O9yVjU+YcC TyjupICjGPEeRcWKTmdWZtQgqhvROm87 X-Received: by 10.107.181.68 with SMTP id e65mr28425004iof.156.1495484966497; Mon, 22 May 2017 13:29:26 -0700 (PDT) From: Stephen Mcconnell References: <201705172133.v4HLXbi6044710@repo.freebsd.org> <20170522145719.GS1622@kib.kiev.ua> In-Reply-To: <20170522145719.GS1622@kib.kiev.ua> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQIMtlBOfE3fpeKohkny3vGsD68sXQDlJpdooYXeRkA= Date: Mon, 22 May 2017 14:29:43 -0600 Message-ID: <3aaaee191edfb5b860fa24d247ef21fb@mail.gmail.com> Subject: RE: svn commit: r318427 - in head: share/man/man4 sys/dev/mpr sys/dev/mpr/mpi To: Konstantin Belousov , Stephen McConnell Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 22 May 2017 20:29:27 -0000 > -----Original Message----- > From: Konstantin Belousov [mailto:kostikbel@gmail.com] > Sent: Monday, May 22, 2017 8:57 AM > To: Stephen McConnell > Cc: src-committers@freebsd.org; svn-src-all@freebsd.org; svn-src- > head@freebsd.org > Subject: Re: svn commit: r318427 - in head: share/man/man4 sys/dev/mpr > sys/dev/mpr/mpi > > On Wed, May 17, 2017 at 09:33:37PM +0000, Stephen McConnell wrote: > > Author: slm > > Date: Wed May 17 21:33:37 2017 > > New Revision: 318427 > > URL: https://svnweb.freebsd.org/changeset/base/318427 > > > > Log: > > Add tri-mode support (SAS/SATA/PCIe). > > > > This includes NVMe device support and adds support for the following > adapters: > > SAS 3408 > > SAS 3416 > > SAS 3508 > > SAS 3516 > > SAS 3616 > > SAS 3708 > > SAS 3716 > > > > Reviewed by: ken, scottl, asomers, mav > > Approved by: ken, scottl, mav > > MFC after: 2 weeks > > Relnotes: yes > > Differential Revision: https://reviews.freebsd.org/D10095 > > It seems that this commit causes the following compilation issue: > > cc1: warnings being treated as errors > /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c: In function > 'mprsas_build_nvme_unm > ap': > /scratch/tmp/kib/ino64/sys/dev/mpr/mpr_sas.c:1839: warning: cast to pointer > from integer of different size [-Wint-to-pointer-cast] > --- mpr_sas.o --- > *** [mpr_sas.o] Error code 1 > > at least on powerpc. Fixed in r318679 From owner-svn-src-head@freebsd.org Mon May 22 20:34:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EB4CED79E8F; Mon, 22 May 2017 20:34:52 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C85CA19C0; Mon, 22 May 2017 20:34:52 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MKYpmn097921; Mon, 22 May 2017 20:34:51 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MKYpGO097918; Mon, 22 May 2017 20:34:51 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201705222034.v4MKYpGO097918@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Mon, 22 May 2017 20:34:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318680 - in head/cddl: contrib/opensolaris/cmd/dtrace/test/tst/common/proc usr.sbin/dtrace/tests/common/proc 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.23 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, 22 May 2017 20:34:53 -0000 Author: markj Date: Mon May 22 20:34:51 2017 New Revision: 318680 URL: https://svnweb.freebsd.org/changeset/base/318680 Log: Add a little helper program for tst.exitcore.ksh. sleep(1) is capsicumized, which means that we cannot rely on it to dump core as required by the test. MFC after: 1 week Sponsored by: Dell EMC Isilon Added: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.c (contents, props changed) Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh head/cddl/usr.sbin/dtrace/tests/common/proc/Makefile Added: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.c Mon May 22 20:34:51 2017 (r318680) @@ -0,0 +1,36 @@ +/* + * CDDL HEADER START + * + * The contents of this file are subject to the terms of the + * Common Development and Distribution License (the "License"). + * You may not use this file except in compliance with the License. + * + * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE + * or http://www.opensolaris.org/os/licensing. + * See the License for the specific language governing permissions + * and limitations under the License. + * + * When distributing Covered Code, include this CDDL HEADER in each + * file and include the License file at usr/src/OPENSOLARIS.LICENSE. + * If applicable, add the following below this CDDL HEADER, with the + * fields enclosed by brackets "[]" replaced with your own identifying + * information: Portions Copyright [yyyy] [name of copyright owner] + * + * CDDL HEADER END + */ + +/* + * Copyright 2017 Mark Johnston + */ + +#include + +int +main(int argc, char **argv) +{ + + for (;;) + sleep(1); + + return (0); +} Modified: head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh ============================================================================== --- head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh Mon May 22 20:27:29 2017 (r318679) +++ head/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/proc/tst.exitcore.ksh Mon May 22 20:34:51 2017 (r318680) @@ -52,7 +52,7 @@ script() /curpsinfo->pr_ppid == $child && execargs == "$longsleep" && args[0] != CLD_DUMPED/ { - printf("Child process could did dump core."); + printf("Child process could not dump core."); exit(1); } EOF @@ -62,10 +62,9 @@ sleeper() { while true; do $longsleep & - /bin/sleep 1 + /bin/sleep 1 kill -SEGV $! done - /bin/rm -f $corefile } if [ $# != 1 ]; then @@ -74,8 +73,7 @@ if [ $# != 1 ]; then fi dtrace=$1 -longsleep="/bin/sleep 10000" -corefile=/tmp/sleep.core +longsleep="./tst.exitcore.exe" sleeper & child=$! @@ -83,10 +81,6 @@ child=$! script status=$? -#pstop $child -#pkill -P $child kill $child -#prun $child -/bin/rm -f $corefile exit $status Modified: head/cddl/usr.sbin/dtrace/tests/common/proc/Makefile ============================================================================== --- head/cddl/usr.sbin/dtrace/tests/common/proc/Makefile Mon May 22 20:27:29 2017 (r318679) +++ head/cddl/usr.sbin/dtrace/tests/common/proc/Makefile Mon May 22 20:34:51 2017 (r318680) @@ -23,6 +23,7 @@ TESTEXES= \ CFILES= \ + tst.exitcore.c \ tst.sigwait.c \ From owner-svn-src-head@freebsd.org Mon May 22 23:17:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EDA40D79C0B; Mon, 22 May 2017 23:17:56 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B2B9E1D0B; Mon, 22 May 2017 23:17:56 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MNHtr1063638; Mon, 22 May 2017 23:17:55 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MNHtwY063637; Mon, 22 May 2017 23:17:55 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201705222317.v4MNHtwY063637@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 22 May 2017 23:17:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318686 - head/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.23 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, 22 May 2017 23:17:57 -0000 Author: pfg Date: Mon May 22 23:17:55 2017 New Revision: 318686 URL: https://svnweb.freebsd.org/changeset/base/318686 Log: ndbm.h: Add a comment pointing out our non-compliance with POSIX. Changing it to full conformance breaks the ABI. Reference: http://pubs.opengroup.org/onlinepubs/009695399/basedefs/ndbm.h.html Discussion at: https://reviews.freebsd.org/D10544 Modified: head/include/ndbm.h Modified: head/include/ndbm.h ============================================================================== --- head/include/ndbm.h Mon May 22 22:10:02 2017 (r318685) +++ head/include/ndbm.h Mon May 22 23:17:55 2017 (r318686) @@ -53,7 +53,7 @@ typedef struct { void *dptr; - int dsize; + int dsize; /* XXX Should be size_t according to 1003.1-2008. */ } datum; typedef DB DBM; From owner-svn-src-head@freebsd.org Mon May 22 23:21:25 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AAACCD79C95; Mon, 22 May 2017 23:21:25 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7A13B1F23; Mon, 22 May 2017 23:21:25 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MNLOQF063811; Mon, 22 May 2017 23:21:24 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MNLOvm063810; Mon, 22 May 2017 23:21:24 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201705222321.v4MNLOvm063810@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Mon, 22 May 2017 23:21:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318687 - head/lib/libproc 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.23 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, 22 May 2017 23:21:25 -0000 Author: markj Date: Mon May 22 23:21:24 2017 New Revision: 318687 URL: https://svnweb.freebsd.org/changeset/base/318687 Log: Ensure that the mappings table is populated in proc_objname(). MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/lib/libproc/proc_sym.c Modified: head/lib/libproc/proc_sym.c ============================================================================== --- head/lib/libproc/proc_sym.c Mon May 22 23:17:55 2017 (r318686) +++ head/lib/libproc/proc_sym.c Mon May 22 23:21:24 2017 (r318687) @@ -339,6 +339,9 @@ proc_objname(struct proc_handle *p, uint prmap_t *map; size_t i; + if (p->nmappings == 0) + if (proc_rdagent(p) == NULL) + return (NULL); for (i = 0; i < p->nmappings; i++) { map = &p->mappings[i].map; if (addr >= map->pr_vaddr && From owner-svn-src-head@freebsd.org Mon May 22 23:31:29 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9FF2CD79FCC; Mon, 22 May 2017 23:31:29 +0000 (UTC) (envelope-from rpokala@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 700991519; Mon, 22 May 2017 23:31:29 +0000 (UTC) (envelope-from rpokala@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4MNVSQd069973; Mon, 22 May 2017 23:31:28 GMT (envelope-from rpokala@FreeBSD.org) Received: (from rpokala@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4MNVSsR069972; Mon, 22 May 2017 23:31:28 GMT (envelope-from rpokala@FreeBSD.org) Message-Id: <201705222331.v4MNVSsR069972@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rpokala set sender to rpokala@FreeBSD.org using -f From: Ravi Pokala Date: Mon, 22 May 2017 23:31:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318688 - 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.23 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, 22 May 2017 23:31:29 -0000 Author: rpokala Date: Mon May 22 23:31:28 2017 New Revision: 318688 URL: https://svnweb.freebsd.org/changeset/base/318688 Log: "struct ata_params" field "reserved206[2]" actually starts at offset 20*7*. MFC after: 1 week Sponsored by: Panasas Modified: head/sys/sys/ata.h Modified: head/sys/sys/ata.h ============================================================================== --- head/sys/sys/ata.h Mon May 22 23:21:24 2017 (r318687) +++ head/sys/sys/ata.h Mon May 22 23:31:28 2017 (r318688) @@ -263,7 +263,7 @@ struct ata_params { u_int16_t reserved170[6]; /*176*/ u_int8_t media_serial[60]; /*206*/ u_int16_t sct; - u_int16_t reserved206[2]; + u_int16_t reserved207[2]; /*209*/ u_int16_t lsalign; /*210*/ u_int16_t wrv_sectors_m3_1; u_int16_t wrv_sectors_m3_2; From owner-svn-src-head@freebsd.org Tue May 23 00:13:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 75C76D78CC3; Tue, 23 May 2017 00:13:28 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 52D1E160F; Tue, 23 May 2017 00:13:28 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N0DRqJ087543; Tue, 23 May 2017 00:13:27 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N0DRuo087542; Tue, 23 May 2017 00:13:27 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201705230013.v4N0DRuo087542@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 23 May 2017 00:13:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318689 - 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.23 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, 23 May 2017 00:13:28 -0000 Author: mav Date: Tue May 23 00:13:27 2017 New Revision: 318689 URL: https://svnweb.freebsd.org/changeset/base/318689 Log: Add parent interface reference counting to if_vlan. Using plain ifunit() looks like a request for troubles. MFC after: 1 week Modified: head/sys/net/if_vlan.c Modified: head/sys/net/if_vlan.c ============================================================================== --- head/sys/net/if_vlan.c Mon May 22 23:31:28 2017 (r318688) +++ head/sys/net/if_vlan.c Tue May 23 00:13:27 2017 (r318689) @@ -474,6 +474,7 @@ trunk_destroy(struct ifvlantrunk *trunk) trunk->parent->if_vlantrunk = NULL; TRUNK_UNLOCK(trunk); TRUNK_LOCK_DESTROY(trunk); + if_rele(trunk->parent); free(trunk, M_VLAN); } @@ -848,16 +849,20 @@ vlan_clone_match_ethervid(const char *na if ((cp = strchr(ifname, '.')) == NULL) return (NULL); *cp = '\0'; - if ((ifp = ifunit(ifname)) == NULL) + if ((ifp = ifunit_ref(ifname)) == NULL) return (NULL); /* Parse VID. */ - if (*++cp == '\0') + if (*++cp == '\0') { + if_rele(ifp); return (NULL); + } vid = 0; for(; *cp >= '0' && *cp <= '9'; cp++) vid = (vid * 10) + (*cp - '0'); - if (*cp != '\0') + if (*cp != '\0') { + if_rele(ifp); return (NULL); + } if (vidp != NULL) *vidp = vid; @@ -890,7 +895,6 @@ vlan_clone_create(struct if_clone *ifc, int unit; int error; int vid; - int ethertag; struct ifvlan *ifv; struct ifnet *ifp; struct ifnet *p; @@ -915,23 +919,21 @@ vlan_clone_create(struct if_clone *ifc, error = copyin(params, &vlr, sizeof(vlr)); if (error) return error; - p = ifunit(vlr.vlr_parent); + p = ifunit_ref(vlr.vlr_parent); if (p == NULL) return (ENXIO); error = ifc_name2unit(name, &unit); - if (error != 0) + if (error != 0) { + if_rele(p); return (error); - - ethertag = 1; + } vid = vlr.vlr_tag; wildcard = (unit < 0); } else if ((p = vlan_clone_match_ethervid(name, &vid)) != NULL) { - ethertag = 1; unit = -1; wildcard = 0; } else { - ethertag = 0; - + p = NULL; error = ifc_name2unit(name, &unit); if (error != 0) return (error); @@ -940,8 +942,11 @@ vlan_clone_create(struct if_clone *ifc, } error = ifc_alloc_unit(ifc, &unit); - if (error != 0) + if (error != 0) { + if (p != NULL) + if_rele(p); return (error); + } /* In the wildcard case, we need to update the name. */ if (wildcard) { @@ -957,6 +962,8 @@ vlan_clone_create(struct if_clone *ifc, if (ifp == NULL) { ifc_free_unit(ifc, unit); free(ifv, M_VLAN); + if (p != NULL) + if_rele(p); return (ENOSPC); } SLIST_INIT(&ifv->vlan_mc_listhead); @@ -990,8 +997,9 @@ vlan_clone_create(struct if_clone *ifc, sdl = (struct sockaddr_dl *)ifa->ifa_addr; sdl->sdl_type = IFT_L2VLAN; - if (ethertag) { + if (p != NULL) { error = vlan_config(ifv, p, vid); + if_rele(p); if (error != 0) { /* * Since we've partially failed, we need to back @@ -1278,6 +1286,7 @@ vlan_config(struct ifvlan *ifv, struct i TRUNK_LOCK(trunk); p->if_vlantrunk = trunk; trunk->parent = p; + if_ref(trunk->parent); } else { VLAN_LOCK(); exists: @@ -1693,8 +1702,10 @@ vlan_ioctl(struct ifnet *ifp, u_long cmd VLAN_LOCK(); if (TRUNK(ifv) != NULL) { p = PARENT(ifv); + if_ref(p); VLAN_UNLOCK(); error = (*p->if_ioctl)(p, SIOCGIFMEDIA, data); + if_rele(p); /* Limit the result to the parent's current config. */ if (error == 0) { struct ifmediareq *ifmr; @@ -1756,12 +1767,13 @@ vlan_ioctl(struct ifnet *ifp, u_long cmd vlan_unconfig(ifp); break; } - p = ifunit(vlr.vlr_parent); + p = ifunit_ref(vlr.vlr_parent); if (p == NULL) { error = ENOENT; break; } error = vlan_config(ifv, p, vlr.vlr_tag); + if_rele(p); if (error) break; From owner-svn-src-head@freebsd.org Tue May 23 03:48:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4721DD79AF9; Tue, 23 May 2017 03:48:44 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 16BCF14EE; Tue, 23 May 2017 03:48:44 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N3mhCB073159; Tue, 23 May 2017 03:48:43 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N3mhN1073158; Tue, 23 May 2017 03:48:43 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705230348.v4N3mhN1073158@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Tue, 23 May 2017 03:48:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318690 - head/sys/dev/etherswitch/arswitch 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.23 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, 23 May 2017 03:48:44 -0000 Author: adrian Date: Tue May 23 03:48:42 2017 New Revision: 318690 URL: https://svnweb.freebsd.org/changeset/base/318690 Log: [arswitch] add phy debugging to the internal PHY read/write functions. Modified: head/sys/dev/etherswitch/arswitch/arswitch_phy.c Modified: head/sys/dev/etherswitch/arswitch/arswitch_phy.c ============================================================================== --- head/sys/dev/etherswitch/arswitch/arswitch_phy.c Tue May 23 00:13:27 2017 (r318689) +++ head/sys/dev/etherswitch/arswitch/arswitch_phy.c Tue May 23 03:48:42 2017 (r318690) @@ -151,10 +151,20 @@ arswitch_readphy_internal(device_t dev, data = arswitch_readreg_lsb(dev, a) & AR8X16_MDIO_CTRL_DATA_MASK; ARSWITCH_UNLOCK(sc); + + DPRINTF(sc, ARSWITCH_DBG_PHYIO, + "%s: phy=0x%08x, reg=0x%08x, ret=0x%08x\n", + __func__, phy, reg, data); + return (data); fail: ARSWITCH_UNLOCK(sc); + + DPRINTF(sc, ARSWITCH_DBG_PHYIO, + "%s: phy=0x%08x, reg=0x%08x, fail; err=%d\n", + __func__, phy, reg, err); + return (-1); } @@ -194,6 +204,11 @@ arswitch_writephy_internal(device_t dev, } if (timeout < 0) err = EIO; + + DPRINTF(sc, ARSWITCH_DBG_PHYIO, + "%s: phy=0x%08x, reg=0x%08x, data=0x%08x, err=%d\n", + __func__, phy, reg, data, err); + out: DEVERR(dev, err, "arswitch_writephy()=%d: phy=%d.%02x\n", phy, reg); ARSWITCH_UNLOCK(sc); From owner-svn-src-head@freebsd.org Tue May 23 06:04:39 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D7418D7964A; Tue, 23 May 2017 06:04:39 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8A7E11878; Tue, 23 May 2017 06:04:39 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N64cNk045624; Tue, 23 May 2017 06:04:38 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N64cpT045623; Tue, 23 May 2017 06:04:38 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230604.v4N64cpT045623@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:04:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318693 - 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.23 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, 23 May 2017 06:04:39 -0000 Author: ngie Date: Tue May 23 06:04:38 2017 New Revision: 318693 URL: https://svnweb.freebsd.org/changeset/base/318693 Log: Some minor style(9) fixes - Wrap at <80 columns. - Sort by type MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue May 23 04:14:34 2017 (r318692) +++ head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue May 23 06:04:38 2017 (r318693) @@ -47,11 +47,12 @@ static char *boot_disk(struct gmesh *mes static char *wizard_partition(struct gmesh *mesh, const char *disk); int -part_wizard(const char *fsreq) { - int error; - struct gmesh mesh; +part_wizard(const char *fsreq) +{ char *disk, *schemeroot; const char *fstype; + struct gmesh mesh; + int error; if (fsreq != NULL) fstype = fsreq; @@ -199,9 +200,9 @@ wizard_partition(struct gmesh *mesh, con struct gclass *classp; struct ggeom *gpart = NULL; struct gconfig *gc; - char message[512]; - const char *scheme = NULL; char *retval = NULL; + const char *scheme = NULL; + char message[512]; int choice; LIST_FOREACH(classp, &mesh->lg_class, lg_class) @@ -295,15 +296,17 @@ query: } int -wizard_makeparts(struct gmesh *mesh, const char *disk, const char *fstype, int interactive) +wizard_makeparts(struct gmesh *mesh, const char *disk, const char *fstype, + int interactive) { - struct gmesh submesh; struct gclass *classp; struct ggeom *gp; struct gprovider *pp; - intmax_t swapsize, available; - char swapsizestr[10], rootsizestr[10], *fsname; char *fsnames[] = {"freebsd-ufs", "freebsd-zfs"}; + char *fsname; + struct gmesh submesh; + char swapsizestr[10], rootsizestr[10]; + intmax_t swapsize, available; int retval; if (strcmp(fstype, "zfs") == 0) { @@ -362,4 +365,3 @@ wizard_makeparts(struct gmesh *mesh, con return (0); } - From owner-svn-src-head@freebsd.org Tue May 23 06:05:55 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 775E3D796DA; Tue, 23 May 2017 06:05:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 496BA19F8; Tue, 23 May 2017 06:05:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N65sni045715; Tue, 23 May 2017 06:05:54 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N65sLh045714; Tue, 23 May 2017 06:05:54 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230605.v4N65sLh045714@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:05:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318694 - 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.23 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, 23 May 2017 06:05:55 -0000 Author: ngie Date: Tue May 23 06:05:54 2017 New Revision: 318694 URL: https://svnweb.freebsd.org/changeset/base/318694 Log: style(9): sort headers MFC after: 2 weeks MFC with: r318693 Sponsored by: Dell EMC Isilon Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c Modified: head/usr.sbin/bsdinstall/partedit/part_wizard.c ============================================================================== --- head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue May 23 06:04:38 2017 (r318693) +++ head/usr.sbin/bsdinstall/partedit/part_wizard.c Tue May 23 06:05:54 2017 (r318694) @@ -27,11 +27,10 @@ */ #include +#include #include -#include #include - -#include +#include #include #include From owner-svn-src-head@freebsd.org Tue May 23 06:14:04 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 004E2D7991D; Tue, 23 May 2017 06:14:04 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C6D231E40; Tue, 23 May 2017 06:14:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6E2Lo049548; Tue, 23 May 2017 06:14:02 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6E2Yt049547; Tue, 23 May 2017 06:14:02 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230614.v4N6E2Yt049547@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:14:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318695 - head/lib/libc/gen 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.23 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, 23 May 2017 06:14:04 -0000 Author: ngie Date: Tue May 23 06:14:02 2017 New Revision: 318695 URL: https://svnweb.freebsd.org/changeset/base/318695 Log: err(3): use `NULL`, aka `(void*)0` per POSIX instead of `(FILE *)0` This is being done to aid humans and static analysis checkers. MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/err.c Modified: head/lib/libc/gen/err.c ============================================================================== --- head/lib/libc/gen/err.c Tue May 23 06:05:54 2017 (r318694) +++ head/lib/libc/gen/err.c Tue May 23 06:14:02 2017 (r318695) @@ -97,7 +97,7 @@ void verrc(int eval, int code, const char *fmt, va_list ap) { if (err_file == NULL) - err_set_file((FILE *)0); + err_set_file(NULL); fprintf(err_file, "%s: ", _getprogname()); if (fmt != NULL) { vfprintf(err_file, fmt, ap); @@ -122,7 +122,7 @@ void verrx(int eval, const char *fmt, va_list ap) { if (err_file == NULL) - err_set_file((FILE *)0); + err_set_file(NULL); fprintf(err_file, "%s: ", _getprogname()); if (fmt != NULL) vfprintf(err_file, fmt, ap); @@ -162,7 +162,7 @@ void vwarnc(int code, const char *fmt, va_list ap) { if (err_file == NULL) - err_set_file((FILE *)0); + err_set_file(NULL); fprintf(err_file, "%s: ", _getprogname()); if (fmt != NULL) { vfprintf(err_file, fmt, ap); @@ -184,7 +184,7 @@ void vwarnx(const char *fmt, va_list ap) { if (err_file == NULL) - err_set_file((FILE *)0); + err_set_file(NULL); fprintf(err_file, "%s: ", _getprogname()); if (fmt != NULL) vfprintf(err_file, fmt, ap); From owner-svn-src-head@freebsd.org Tue May 23 06:20:08 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 024ACD79B97; Tue, 23 May 2017 06:20:08 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BA897122F; Tue, 23 May 2017 06:20:07 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6K6sX049847; Tue, 23 May 2017 06:20:06 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6K6hT049845; Tue, 23 May 2017 06:20:06 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705230620.v4N6K6hT049845@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Tue, 23 May 2017 06:20:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318696 - head/sys/mips/atheros 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.23 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, 23 May 2017 06:20:08 -0000 Author: adrian Date: Tue May 23 06:20:06 2017 New Revision: 318696 URL: https://svnweb.freebsd.org/changeset/base/318696 Log: [ar71xx] add a very simple early boot driver called "caldata" to commit cross-layer atrocities. The (eventually) upcoming ath(4) changes will include being able to load ath(4) devices on the AHB bus (ie the on-die wifi part of the SoC) as modules. In order for this to happen, a copy of the calibration data needs to be copied away before the SPI driver runs or the memory map access hack won't work. Now, ideally (!) there'd be some driver that can come up after the MTD pieces (eg, SPI, NAND, etc) and load into a firmware chunk the calibration data. (Or, really really nicely, would be an actual async firmware API that would lead itself to having a driver schedule a file read - or a raw device read - to get to the calibration data.) Now, until all of the above is done - I'm going to perpetuate the layer breaking atrocity here by simply doing the PCI bus fixup EEPROM/calibration data hack here. This will work for any AR71xx (and later on, AR231x/AR531x) device, as well as the handful of QCA MIPS + QCA9880v2 802.11ac boards with NOR flash. To use, this goes into the kernel config: # Enable EEPROM hacks options AR71XX_ATH_EEPROM device ar71xx_caldata device firmware # This enables the ath_ahb driver (when I commit the change!) to # pull data out of the firmware hack. options ATH_EEPROM_FIRMWARE In the hints file: # ART calibration data mapping device hint.ar71xx_caldata.0.at="nexus0" hint.ar71xx_caldata.0.order=0 # Where the ART is - last 64k in the first 8MB of flash hint.ar71xx_caldata.0.map.0.ath_fixup_addr=0x1fff0000 hint.ar71xx_caldata.0.map.0.ath_fixup_size=16384 # And now tell the ath(4) driver where to look! hint.ath.0.eeprom_firmware="ar71xx_caldata.0.map.0.eeprom_firmware" Tested: * carambola2, AR933x SoC, using a set of ath and ath_hal modules to load TODO: * unify this bit of firmware loading code, as I will definitely need to include both the PCI bus firmware version (for PCI ID fixups too!) as well as AHB/on-chip calibration data. * Commit the ath_ahb bus code * Convert .. everything over. That'll take the majority of the time. Added: head/sys/mips/atheros/ar71xx_caldata.c (contents, props changed) Modified: head/sys/mips/atheros/files.ar71xx Added: head/sys/mips/atheros/ar71xx_caldata.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/atheros/ar71xx_caldata.c Tue May 23 06:20:06 2017 (r318696) @@ -0,0 +1,176 @@ +/*- + * Copyright (c) 2017, Adrian Chadd . + * 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 unmodified, 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. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include "opt_ar71xx.h" + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include + +#include +#include + +struct ar71xx_caldata_softc { + device_t sc_dev; +}; + +static int +ar71xx_caldata_probe(device_t dev) +{ + + return (BUS_PROBE_NOWILDCARD); +} + +/* XXX TODO: unify with what's in ar71xx_fixup.c */ + +/* + * Create a calibration block from memory mapped SPI data for use by + * various drivers. Right now it's just ath(4) but later board support + * will include 802.11ac NICs with calibration data in NOR flash. + * + * (Yes, there are a handful of QCA MIPS boards with QCA9880v2 802.11ac chips + * with calibration data in flash..) + */ +static void +ar71xx_platform_create_cal_data(device_t dev, int id, long int flash_addr, + int size) +{ + char buf[64]; + uint16_t *cal_data = (uint16_t *) MIPS_PHYS_TO_KSEG1(flash_addr); + void *eeprom = NULL; + const struct firmware *fw = NULL; + + device_printf(dev, "EEPROM firmware: 0x%lx @ %d bytes\n", + flash_addr, size); + + eeprom = malloc(size, M_DEVBUF, M_WAITOK | M_ZERO); + if (! eeprom) { + device_printf(dev, "%s: malloc failed for '%s', aborting EEPROM\n", + __func__, buf); + return; + } + + memcpy(eeprom, cal_data, size); + + /* + * Generate a flash EEPROM 'firmware' from the given memory + * region. Since the SPI controller will eventually + * go into port-IO mode instead of memory-mapped IO + * mode, a copy of the EEPROM contents is required. + */ + + snprintf(buf, sizeof(buf), "%s.%d.map.%d.eeprom_firmware", + device_get_name(dev), + device_get_unit(dev), + id); + + fw = firmware_register(buf, eeprom, size, 1, NULL); + if (fw == NULL) { + device_printf(dev, "%s: firmware_register (%s) failed\n", + __func__, buf); + free(eeprom, M_DEVBUF); + return; + } + device_printf(dev, "device EEPROM '%s' registered\n", buf); +} + +/* + * Iterate through a list of early-boot hints creating calibration + * data firmware chunks for AHB (ie, non-PCI) devices with calibration + * data. + */ +static int +ar71xx_platform_check_eeprom_hints(device_t dev) +{ + char buf[64]; + long int addr; + int size; + int i; + + for (i = 0; i < 8; i++) { + snprintf(buf, sizeof(buf), "map.%d.ath_fixup_addr", i); + if (resource_long_value(device_get_name(dev), + device_get_unit(dev), buf, &addr) != 0) + break; + snprintf(buf, sizeof(buf), "map.%d.ath_fixup_size", i); + if (resource_int_value(device_get_name(dev), + device_get_unit(dev), buf, &size) != 0) + break; + device_printf(dev, "map.%d.ath_fixup_addr=0x%08x; size=%d\n", + i, (int) addr, size); + (void) ar71xx_platform_create_cal_data(dev, i, addr, size); + } + + return (0); +} + +static int +ar71xx_caldata_attach(device_t dev) +{ + + device_add_child(dev, "nexus", -1); + ar71xx_platform_check_eeprom_hints(dev); + return (bus_generic_attach(dev)); +} + +static device_method_t ar71xx_caldata_methods[] = { + /* Device interface */ + DEVMETHOD(device_probe, ar71xx_caldata_probe), + DEVMETHOD(device_attach, ar71xx_caldata_attach), + DEVMETHOD(device_shutdown, bus_generic_shutdown), + DEVMETHOD(device_suspend, bus_generic_suspend), + DEVMETHOD(device_resume, bus_generic_resume), + DEVMETHOD_END +}; + +static driver_t ar71xx_caldata_driver = { + "ar71xx_caldata", + ar71xx_caldata_methods, + sizeof(struct ar71xx_caldata_softc), +}; + +static devclass_t ar71xx_caldata_devclass; + +DRIVER_MODULE(ar71xx_caldata, nexus, ar71xx_caldata_driver, ar71xx_caldata_devclass, 0, 0); Modified: head/sys/mips/atheros/files.ar71xx ============================================================================== --- head/sys/mips/atheros/files.ar71xx Tue May 23 06:14:02 2017 (r318695) +++ head/sys/mips/atheros/files.ar71xx Tue May 23 06:20:06 2017 (r318696) @@ -1,6 +1,7 @@ # $FreeBSD$ mips/atheros/apb.c optional ar71xx_apb +mips/atheros/ar71xx_caldata.c optional ar71xx_caldata mips/atheros/ar71xx_gpio.c optional gpio mips/atheros/ar71xx_machdep.c standard mips/atheros/ar71xx_ehci.c optional ehci From owner-svn-src-head@freebsd.org Tue May 23 06:20:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 223D4D79BFB; Tue, 23 May 2017 06:20:26 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E62F8134A; Tue, 23 May 2017 06:20:25 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6KOG5049904; Tue, 23 May 2017 06:20:24 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6KOoD049903; Tue, 23 May 2017 06:20:24 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705230620.v4N6KOoD049903@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Tue, 23 May 2017 06:20:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318697 - head/sys/mips/atheros 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.23 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, 23 May 2017 06:20:26 -0000 Author: adrian Date: Tue May 23 06:20:24 2017 New Revision: 318697 URL: https://svnweb.freebsd.org/changeset/base/318697 Log: [ar71xx] remove dead code! Modified: head/sys/mips/atheros/ar71xx_fixup.c Modified: head/sys/mips/atheros/ar71xx_fixup.c ============================================================================== --- head/sys/mips/atheros/ar71xx_fixup.c Tue May 23 06:20:06 2017 (r318696) +++ head/sys/mips/atheros/ar71xx_fixup.c Tue May 23 06:20:24 2017 (r318697) @@ -110,43 +110,3 @@ ar71xx_pci_slot_create_eeprom_firmware(d } device_printf(dev, "device EEPROM '%s' registered\n", buf); } - -#if 0 -static void -ar71xx_pci_slot_fixup(device_t dev, u_int bus, u_int slot, u_int func) -{ - long int flash_addr; - char buf[64]; - int size; - - /* - * Check whether the given slot has a hint to poke. - */ - if (bootverbose) - device_printf(dev, "%s: checking dev %s, %d/%d/%d\n", - __func__, device_get_nameunit(dev), bus, slot, func); - - snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_addr", - bus, slot, func); - - if (resource_long_value(device_get_name(dev), device_get_unit(dev), - buf, &flash_addr) == 0) { - snprintf(buf, sizeof(buf), "bus.%d.%d.%d.ath_fixup_size", - bus, slot, func); - if (resource_int_value(device_get_name(dev), - device_get_unit(dev), buf, &size) != 0) { - device_printf(dev, - "%s: missing hint '%s', aborting EEPROM\n", - __func__, buf); - return; - } - - - device_printf(dev, "found EEPROM at 0x%lx on %d.%d.%d\n", - flash_addr, bus, slot, func); - ar71xx_pci_fixup(dev, bus, slot, func, flash_addr, size); - ar71xx_pci_slot_create_eeprom_firmware(dev, bus, slot, func, - flash_addr, size); - } -} -#endif /* 0 */ From owner-svn-src-head@freebsd.org Tue May 23 06:53:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 88F53D7A91B; Tue, 23 May 2017 06:53:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5B01515C7; Tue, 23 May 2017 06:53:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6rVXw065629; Tue, 23 May 2017 06:53:31 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6rVjC065628; Tue, 23 May 2017 06:53:31 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230653.v4N6rVjC065628@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:53:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318698 - head/lib/libc/gen 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.23 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, 23 May 2017 06:53:32 -0000 Author: ngie Date: Tue May 23 06:53:31 2017 New Revision: 318698 URL: https://svnweb.freebsd.org/changeset/base/318698 Log: basename(3): fix section ordering IMPLEMENTATION NOTES come before RETURN VALUES MFC after: 2 weeks Reported by: make manlint Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/basename.3 Modified: head/lib/libc/gen/basename.3 ============================================================================== --- head/lib/libc/gen/basename.3 Tue May 23 06:20:24 2017 (r318697) +++ head/lib/libc/gen/basename.3 Tue May 23 06:53:31 2017 (r318698) @@ -16,7 +16,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 29, 2016 +.Dd May 22, 2017 .Dt BASENAME 3 .Os .Sh NAME @@ -34,6 +34,16 @@ function returns the last component from deleting any trailing .Sq \&/ characters. +.Sh IMPLEMENTATION NOTES +This implementation of +.Fn basename +uses the buffer provided by the caller to store the resulting pathname +component. +Other vendor implementations may return a pointer to internal storage +space instead. +The advantage of the former approach is that it ensures thread-safety, +while also placing no upper limit on the supported length of the +pathname. .Sh RETURN VALUES If .Fa path @@ -50,16 +60,6 @@ is returned. Otherwise, it returns a pointer to the last component of .Fa path . -.Sh IMPLEMENTATION NOTES -This implementation of -.Fn basename -uses the buffer provided by the caller to store the resulting pathname -component. -Other vendor implementations may return a pointer to internal storage -space instead. -The advantage of the former approach is that it ensures thread-safety, -while also placing no upper limit on the supported length of the -pathname. .Sh SEE ALSO .Xr basename 1 , .Xr dirname 1 , From owner-svn-src-head@freebsd.org Tue May 23 06:55:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7A334D7AA40; Tue, 23 May 2017 06:55:52 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4BCDD18A2; Tue, 23 May 2017 06:55:52 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6tpDF065769; Tue, 23 May 2017 06:55:51 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6tpx0065768; Tue, 23 May 2017 06:55:51 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230655.v4N6tpx0065768@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:55:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318699 - head/lib/libc/gen 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.23 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, 23 May 2017 06:55:52 -0000 Author: ngie Date: Tue May 23 06:55:51 2017 New Revision: 318699 URL: https://svnweb.freebsd.org/changeset/base/318699 Log: directory(3): delete trailing whitespace and rewrite `E.g.` as `e.g.` Reported by: make manlint Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/directory.3 Modified: head/lib/libc/gen/directory.3 ============================================================================== --- head/lib/libc/gen/directory.3 Tue May 23 06:53:31 2017 (r318698) +++ head/lib/libc/gen/directory.3 Tue May 23 06:55:51 2017 (r318699) @@ -28,7 +28,7 @@ .\" @(#)directory.3 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd August 31, 2016 +.Dd May 22, 2017 .Dt DIRECTORY 3 .Os .Sh NAME @@ -292,14 +292,15 @@ is likely to be wrong if there are paral and the directory is larger than one page. There is code to ensure that a .Fn seekdir -to the location given by a +to the location given by a .Fn telldir -immediately before the last +immediately before the last .Fn readdir will always set the correct location to return the same value as that last .Fn readdir performed. -This is enough for some applications which want to "push back the last entry read" E.g. Samba. +This is enough for some applications which want to +"push back the last entry read", e.g. Samba. Seeks back to any other location, other than the beginning of the directory, may result in unexpected behaviour if deletes are present. From owner-svn-src-head@freebsd.org Tue May 23 06:56:59 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 41100D7AAE0; Tue, 23 May 2017 06:56:59 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1176A1A2F; Tue, 23 May 2017 06:56:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6uw3j065849; Tue, 23 May 2017 06:56:58 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6uwY8065848; Tue, 23 May 2017 06:56:58 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230656.v4N6uwY8065848@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:56:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318700 - head/lib/libc/gen 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.23 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, 23 May 2017 06:56:59 -0000 Author: ngie Date: Tue May 23 06:56:57 2017 New Revision: 318700 URL: https://svnweb.freebsd.org/changeset/base/318700 Log: dirname(3): fix section ordering IMPLEMENTATION NOTES come before RETURN VALUES MFC after: 2 weeks Reported by: make manlint Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/dirname.3 Modified: head/lib/libc/gen/dirname.3 ============================================================================== --- head/lib/libc/gen/dirname.3 Tue May 23 06:55:51 2017 (r318699) +++ head/lib/libc/gen/dirname.3 Tue May 23 06:56:57 2017 (r318700) @@ -37,6 +37,16 @@ Any trailing .Sq \&/ characters are not counted as part of the directory name. +.Sh IMPLEMENTATION NOTES +This implementation of +.Fn dirname +uses the buffer provided by the caller to store the resulting parent +directory. +Other vendor implementations may return a pointer to internal storage +space instead. +The advantage of the former approach is that it ensures thread-safety, +while also placing no upper limit on the supported length of the +pathname. .Sh RETURN VALUES If .Fa path @@ -50,16 +60,6 @@ signifying the current directory. Otherwise, it returns a pointer to the parent directory of .Fa path . -.Sh IMPLEMENTATION NOTES -This implementation of -.Fn dirname -uses the buffer provided by the caller to store the resulting parent -directory. -Other vendor implementations may return a pointer to internal storage -space instead. -The advantage of the former approach is that it ensures thread-safety, -while also placing no upper limit on the supported length of the -pathname. .Sh SEE ALSO .Xr basename 1 , .Xr dirname 1 , From owner-svn-src-head@freebsd.org Tue May 23 06:58:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4BF61D7AB91; Tue, 23 May 2017 06:58:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1C46B1BCF; Tue, 23 May 2017 06:58:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N6w9gp065939; Tue, 23 May 2017 06:58:09 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N6w9As065938; Tue, 23 May 2017 06:58:09 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230658.v4N6w9As065938@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 06:58:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318701 - head/lib/libc/gen 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.23 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, 23 May 2017 06:58:10 -0000 Author: ngie Date: Tue May 23 06:58:08 2017 New Revision: 318701 URL: https://svnweb.freebsd.org/changeset/base/318701 Log: tcsendbreak(3): delete spurious blank line at the end of the man page MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/tcsendbreak.3 Modified: head/lib/libc/gen/tcsendbreak.3 ============================================================================== --- head/lib/libc/gen/tcsendbreak.3 Tue May 23 06:56:57 2017 (r318700) +++ head/lib/libc/gen/tcsendbreak.3 Tue May 23 06:58:08 2017 (r318701) @@ -177,4 +177,3 @@ without writing all output. The default value for .Va kern.tty_drainwait is 300 seconds. - From owner-svn-src-head@freebsd.org Tue May 23 07:00:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3576DD7AC17; Tue, 23 May 2017 07:00:48 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 07E381D61; Tue, 23 May 2017 07:00:47 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N70l7H066839; Tue, 23 May 2017 07:00:47 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N70l7E066838; Tue, 23 May 2017 07:00:47 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230700.v4N70l7E066838@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:00:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318702 - head/contrib/libc-vis 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.23 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, 23 May 2017 07:00:48 -0000 Author: ngie Date: Tue May 23 07:00:46 2017 New Revision: 318702 URL: https://svnweb.freebsd.org/changeset/base/318702 Log: vis(3): delete spurious .Pp macro MFC after: 2 weeks Reported by: make manlint Sponsored by: Dell EMC Isilon Modified: head/contrib/libc-vis/vis.3 Modified: head/contrib/libc-vis/vis.3 ============================================================================== --- head/contrib/libc-vis/vis.3 Tue May 23 06:58:08 2017 (r318701) +++ head/contrib/libc-vis/vis.3 Tue May 23 07:00:46 2017 (r318702) @@ -373,7 +373,6 @@ space. .It Dv \e240 Represents Meta-space. .El -.Pp .It Dv VIS_CSTYLE Use C-style backslash sequences to represent standard non-printable characters. From owner-svn-src-head@freebsd.org Tue May 23 07:02:02 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A8DF0D7AC84; Tue, 23 May 2017 07:02:02 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7615110CA; Tue, 23 May 2017 07:02:02 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N721aY067589; Tue, 23 May 2017 07:02:01 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N721hG067588; Tue, 23 May 2017 07:02:01 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230702.v4N721hG067588@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:02:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318703 - head/lib/libc/iconv 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.23 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, 23 May 2017 07:02:02 -0000 Author: ngie Date: Tue May 23 07:02:01 2017 New Revision: 318703 URL: https://svnweb.freebsd.org/changeset/base/318703 Log: __iconv_get_list: separate .Nm entries with commas MFC after: 2 weeks Reported by: make manlint Sponsored by: Dell EMC Isilon Modified: head/lib/libc/iconv/__iconv_get_list.3 Modified: head/lib/libc/iconv/__iconv_get_list.3 ============================================================================== --- head/lib/libc/iconv/__iconv_get_list.3 Tue May 23 07:00:46 2017 (r318702) +++ head/lib/libc/iconv/__iconv_get_list.3 Tue May 23 07:02:01 2017 (r318703) @@ -38,7 +38,7 @@ .Dt __ICONV_GET_LIST 3 .Os .Sh NAME -.Nm __iconv_get_list +.Nm __iconv_get_list , .Nm __iconv_free_list .Nd retrieving a list of character encodings supported by .Xr iconv 3 From owner-svn-src-head@freebsd.org Tue May 23 07:05:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 301C2D7AE0F; Tue, 23 May 2017 07:05:36 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 007231311; Tue, 23 May 2017 07:05:35 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N75ZVh070064; Tue, 23 May 2017 07:05:35 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N75ZiY070063; Tue, 23 May 2017 07:05:35 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230705.v4N75ZiY070063@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:05:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318704 - head/lib/libc/posix1e 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.23 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, 23 May 2017 07:05:36 -0000 Author: ngie Date: Tue May 23 07:05:34 2017 New Revision: 318704 URL: https://svnweb.freebsd.org/changeset/base/318704 Log: posix1e(3): reference using the section (3) when referencing libbsm with .Xr MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/posix1e/posix1e.3 Modified: head/lib/libc/posix1e/posix1e.3 ============================================================================== --- head/lib/libc/posix1e/posix1e.3 Tue May 23 07:02:01 2017 (r318703) +++ head/lib/libc/posix1e/posix1e.3 Tue May 23 07:05:34 2017 (r318704) @@ -63,7 +63,7 @@ flow label APIs. However, .Fx does implement the -.Xr libbsm +.Xr libbsm 3 audit API. It also provides .Xr capsicum 4 , From owner-svn-src-head@freebsd.org Tue May 23 07:08:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 483CAD7AE9A; Tue, 23 May 2017 07:08:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0FF3C14F2; Tue, 23 May 2017 07:08:31 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N78VrJ070282; Tue, 23 May 2017 07:08:31 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N78Ve3070281; Tue, 23 May 2017 07:08:31 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230708.v4N78Ve3070281@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:08:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318705 - head/lib/libc/stdio 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.23 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, 23 May 2017 07:08:32 -0000 Author: ngie Date: Tue May 23 07:08:30 2017 New Revision: 318705 URL: https://svnweb.freebsd.org/changeset/base/318705 Log: fopen(3): make manlint fixes - Break on new lines. - Use .Dv with NULL. - Rewrap lines as necessary/when possible. MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/stdio/fopen.3 Modified: head/lib/libc/stdio/fopen.3 ============================================================================== --- head/lib/libc/stdio/fopen.3 Tue May 23 07:05:34 2017 (r318704) +++ head/lib/libc/stdio/fopen.3 Tue May 23 07:08:30 2017 (r318705) @@ -230,15 +230,20 @@ argument, .Fn fmemopen allocates .Fa size -bytes of memory. This buffer is automatically freed when the -stream is closed. Buffers can be opened in text-mode (default) or binary-mode +bytes of memory. +This buffer is automatically freed when the stream is closed. +Buffers can be opened in text-mode (default) or binary-mode (if .Dq Li b is present in the second or third position of the .Fa mode -argument). Buffers opened in text-mode make sure that writes are terminated with -a NULL byte, if the last write hasn't filled up the whole buffer. Buffers -opened in binary-mode never append a NULL byte. +argument). +Buffers opened in text-mode make sure that writes are terminated with a +.Dv NULL +byte, if the last write hasn't filled up the whole buffer. +Buffers opened in binary-mode never append a +.Dv NULL +byte. .Sh RETURN VALUES Upon successful completion .Fn fopen , From owner-svn-src-head@freebsd.org Tue May 23 07:09:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 799FAD7AEF5; Tue, 23 May 2017 07:09:27 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4BCD41685; Tue, 23 May 2017 07:09:27 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N79QK2070358; Tue, 23 May 2017 07:09:26 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N79Qjd070357; Tue, 23 May 2017 07:09:26 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230709.v4N79Qjd070357@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:09:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318706 - head/lib/libc/locale 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.23 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, 23 May 2017 07:09:27 -0000 Author: ngie Date: Tue May 23 07:09:26 2017 New Revision: 318706 URL: https://svnweb.freebsd.org/changeset/base/318706 Log: localeconv(3): start sentences on new lines Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/locale/localeconv.3 Modified: head/lib/libc/locale/localeconv.3 ============================================================================== --- head/lib/libc/locale/localeconv.3 Tue May 23 07:08:30 2017 (r318705) +++ head/lib/libc/locale/localeconv.3 Tue May 23 07:09:26 2017 (r318706) @@ -202,7 +202,8 @@ result similarly denotes an unavailable .Pp The .Fn localeconv_l -function takes an explicit locale parameter. For more information, see +function takes an explicit locale parameter. +For more information, see .Xr xlocale 3 . .Sh RETURN VALUES The From owner-svn-src-head@freebsd.org Tue May 23 07:10:21 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8C946D7AF60; Tue, 23 May 2017 07:10:21 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5EC921811; Tue, 23 May 2017 07:10:21 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7AKMZ070470; Tue, 23 May 2017 07:10:20 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7AKFw070469; Tue, 23 May 2017 07:10:20 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230710.v4N7AKFw070469@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:10:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318707 - head/lib/libc/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.23 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, 23 May 2017 07:10:21 -0000 Author: ngie Date: Tue May 23 07:10:20 2017 New Revision: 318707 URL: https://svnweb.freebsd.org/changeset/base/318707 Log: sctp_send(3): start sentences on new lines Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/net/sctp_send.3 Modified: head/lib/libc/net/sctp_send.3 ============================================================================== --- head/lib/libc/net/sctp_send.3 Tue May 23 07:09:26 2017 (r318706) +++ head/lib/libc/net/sctp_send.3 Tue May 23 07:10:20 2017 (r318707) @@ -105,8 +105,8 @@ struct sctp_sndrcvinfo { The .Fa sinfo->sinfo_ppid argument is an opaque 32 bit value that is passed transparently -through the stack to the peer endpoint. It will be available on -reception of a message (see +through the stack to the peer endpoint. +It will be available on reception of a message (see .Xr sctp_recvmsg 3 ) . Note that the stack passes this value without regard to byte order. From owner-svn-src-head@freebsd.org Tue May 23 07:11:17 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 323ABD7AFD6; Tue, 23 May 2017 07:11:17 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 048791B06; Tue, 23 May 2017 07:11:16 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7BGYm071445; Tue, 23 May 2017 07:11:16 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7BGNv071444; Tue, 23 May 2017 07:11:16 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230711.v4N7BGNv071444@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:11:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318708 - head/lib/libc/posix1e 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.23 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, 23 May 2017 07:11:17 -0000 Author: ngie Date: Tue May 23 07:11:15 2017 New Revision: 318708 URL: https://svnweb.freebsd.org/changeset/base/318708 Log: acl_create_entry(3): separate .Nm entries with commas in SYNOPSIS Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/posix1e/acl_create_entry.3 Modified: head/lib/libc/posix1e/acl_create_entry.3 ============================================================================== --- head/lib/libc/posix1e/acl_create_entry.3 Tue May 23 07:10:20 2017 (r318707) +++ head/lib/libc/posix1e/acl_create_entry.3 Tue May 23 07:11:15 2017 (r318708) @@ -29,7 +29,7 @@ .Dt ACL_CREATE_ENTRY 3 .Os .Sh NAME -.Nm acl_create_entry +.Nm acl_create_entry , .Nm acl_create_entry_np .Nd create a new ACL entry .Sh LIBRARY From owner-svn-src-head@freebsd.org Tue May 23 07:12:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F0850D7A171; Tue, 23 May 2017 07:12:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C11341DA7; Tue, 23 May 2017 07:12:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7CVOr074468; Tue, 23 May 2017 07:12:31 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7CVfo074467; Tue, 23 May 2017 07:12:31 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230712.v4N7CVfo074467@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:12:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318709 - head/lib/libc/posix1e 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.23 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, 23 May 2017 07:12:33 -0000 Author: ngie Date: Tue May 23 07:12:31 2017 New Revision: 318709 URL: https://svnweb.freebsd.org/changeset/base/318709 Log: acl_to_text(3): start sentences on new lines Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/posix1e/acl_to_text.3 Modified: head/lib/libc/posix1e/acl_to_text.3 ============================================================================== --- head/lib/libc/posix1e/acl_to_text.3 Tue May 23 07:11:15 2017 (r318708) +++ head/lib/libc/posix1e/acl_to_text.3 Tue May 23 07:12:31 2017 (r318709) @@ -58,8 +58,9 @@ including the NULL terminator) in the lo .Va len_p . If the ACL is POSIX.1e, the format of the text string returned by .Fn acl_to_text -shall be the POSIX.1e long ACL form. If the ACL is NFSv4, the format -of the text string shall be the compact form, unless the +shall be the POSIX.1e long ACL form. +If the ACL is NFSv4, the format of the text string shall be the compact form, unless +the .Va ACL_TEXT_VERBOSE flag is given. .Pp From owner-svn-src-head@freebsd.org Tue May 23 07:14:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 22B06D7A218; Tue, 23 May 2017 07:14:48 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E8F831F3C; Tue, 23 May 2017 07:14:47 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7EluD074579; Tue, 23 May 2017 07:14:47 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7EkRo074578; Tue, 23 May 2017 07:14:46 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230714.v4N7EkRo074578@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:14:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318710 - head/lib/libc/stdlib 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.23 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, 23 May 2017 07:14:48 -0000 Author: ngie Date: Tue May 23 07:14:46 2017 New Revision: 318710 URL: https://svnweb.freebsd.org/changeset/base/318710 Log: quick_exit(3): delete trailing whitespace in licensing tort Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/stdlib/quick_exit.3 Modified: head/lib/libc/stdlib/quick_exit.3 ============================================================================== --- head/lib/libc/stdlib/quick_exit.3 Tue May 23 07:12:31 2017 (r318709) +++ head/lib/libc/stdlib/quick_exit.3 Tue May 23 07:14:46 2017 (r318710) @@ -1,6 +1,6 @@ .\" Copyright (c) 2011 David Chisnall .\" All rights reserved. -.\" +.\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: @@ -9,7 +9,7 @@ .\" 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 @@ -21,7 +21,7 @@ .\" 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$ .\" .Dd December 13, 2014 From owner-svn-src-head@freebsd.org Tue May 23 07:15:59 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2A0E4D7A2A5; Tue, 23 May 2017 07:15:59 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EB75110CC; Tue, 23 May 2017 07:15:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7FvAK074667; Tue, 23 May 2017 07:15:57 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7FvwW074666; Tue, 23 May 2017 07:15:57 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230715.v4N7FvwW074666@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:15:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318711 - head/lib/libc/stdio 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.23 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, 23 May 2017 07:15:59 -0000 Author: ngie Date: Tue May 23 07:15:57 2017 New Revision: 318711 URL: https://svnweb.freebsd.org/changeset/base/318711 Log: fopencookie(3): declare function pointers in SYNOPSIS correctly Add obligatory `*` in declarations. Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/stdio/fopencookie.3 Modified: head/lib/libc/stdio/fopencookie.3 ============================================================================== --- head/lib/libc/stdio/fopencookie.3 Tue May 23 07:14:46 2017 (r318710) +++ head/lib/libc/stdio/fopencookie.3 Tue May 23 07:15:57 2017 (r318711) @@ -35,13 +35,13 @@ .Sh SYNOPSIS .In stdio.h .Ft typedef ssize_t -.Fn (cookie_read_function_t) "void *cookie" "char *buf" "size_t size" +.Fn (*cookie_read_function_t) "void *cookie" "char *buf" "size_t size" .Ft typedef ssize_t -.Fn (cookie_write_function_t) "void *cookie" "const char *buf" "size_t size" +.Fn (*cookie_write_function_t) "void *cookie" "const char *buf" "size_t size" .Ft typedef int -.Fn (cookie_seek_function_t) "void *cookie" "off64_t *offset" "int whence" +.Fn (*cookie_seek_function_t) "void *cookie" "off64_t *offset" "int whence" .Ft typedef int -.Fn (cookie_close_function_t) "void *cookie" +.Fn (*cookie_close_function_t) "void *cookie" .Bd -literal typedef struct { cookie_read_function_t *read; From owner-svn-src-head@freebsd.org Tue May 23 07:17:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3C1DD7A344; Tue, 23 May 2017 07:17:53 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 911F512B9; Tue, 23 May 2017 07:17:53 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7Hqoh074771; Tue, 23 May 2017 07:17:52 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7Hqmf074770; Tue, 23 May 2017 07:17:52 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230717.v4N7Hqmf074770@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:17:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318712 - head/lib/libc/xdr 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.23 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, 23 May 2017 07:17:53 -0000 Author: ngie Date: Tue May 23 07:17:52 2017 New Revision: 318712 URL: https://svnweb.freebsd.org/changeset/base/318712 Log: xdr(3): add missing comma after xdr_sizeof(3) in SYNOPSIS This unbreaks the .Nm declaration Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/xdr/xdr.3 Modified: head/lib/libc/xdr/xdr.3 ============================================================================== --- head/lib/libc/xdr/xdr.3 Tue May 23 07:15:57 2017 (r318711) +++ head/lib/libc/xdr/xdr.3 Tue May 23 07:17:52 2017 (r318712) @@ -31,7 +31,7 @@ .Nm xdr_reference , .Nm xdr_setpos , .Nm xdr_short , -.Nm xdr_sizeof, +.Nm xdr_sizeof , .Nm xdrstdio_create , .Nm xdr_string , .Nm xdr_u_char , From owner-svn-src-head@freebsd.org Tue May 23 07:20:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 84705D7A3E9; Tue, 23 May 2017 07:20:30 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 51ACD14A8; Tue, 23 May 2017 07:20:30 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7KTl9074915; Tue, 23 May 2017 07:20:29 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7KTdk074914; Tue, 23 May 2017 07:20:29 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201705230720.v4N7KTdk074914@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Tue, 23 May 2017 07:20:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318713 - head/usr.bin/vmstat 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.23 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, 23 May 2017 07:20:30 -0000 Author: markj Date: Tue May 23 07:20:29 2017 New Revision: 318713 URL: https://svnweb.freebsd.org/changeset/base/318713 Log: Let vmstat -o recognize OBJT_MGTDEVICE objects. MFC after: 1 week Modified: head/usr.bin/vmstat/vmstat.c Modified: head/usr.bin/vmstat/vmstat.c ============================================================================== --- head/usr.bin/vmstat/vmstat.c Tue May 23 07:17:52 2017 (r318712) +++ head/usr.bin/vmstat/vmstat.c Tue May 23 07:20:29 2017 (r318713) @@ -1643,6 +1643,9 @@ display_object(struct kinfo_vmobject *kv case KVME_TYPE_SG: str = "sg"; break; + case KVME_TYPE_MGTDEVICE: + str = "md"; + break; case KVME_TYPE_UNKNOWN: default: str = "??"; From owner-svn-src-head@freebsd.org Tue May 23 07:26:46 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6E1CD7A711; Tue, 23 May 2017 07:26:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 885451B13; Tue, 23 May 2017 07:26:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7QjbI078717; Tue, 23 May 2017 07:26:45 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7QjRf078716; Tue, 23 May 2017 07:26:45 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230726.v4N7QjRf078716@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:26:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318715 - 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.23 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, 23 May 2017 07:26:46 -0000 Author: ngie Date: Tue May 23 07:26:45 2017 New Revision: 318715 URL: https://svnweb.freebsd.org/changeset/base/318715 Log: _umtx_op(2): fix minor manlint issues - Sort .Xr entries in SEE ALSO section. - Sort SEE ALSO and STANDARDS sections properly, in terms of the entire document. Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/sys/_umtx_op.2 Modified: head/lib/libc/sys/_umtx_op.2 ============================================================================== --- head/lib/libc/sys/_umtx_op.2 Tue May 23 07:21:26 2017 (r318714) +++ head/lib/libc/sys/_umtx_op.2 Tue May 23 07:26:45 2017 (r318715) @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 29, 2016 +.Dd May 23, 2017 .Dt _UMTX_OP 2 .Os .Sh NAME @@ -1382,32 +1382,11 @@ Mutex lock requests without timeout spec The error is not returned to userspace code since restart is handled by usual adjustment of the instruction counter. .El -.Sh BUGS -A window between a unlocking robust mutex and resetting the pointer in the -.Dv robust_inact_offset -member of the registered -.Vt struct umtx_robust_lists_params -allows another thread to destroy the mutex, thus making the kernel inspect -freed or reused memory. -The -.Li libthr -implementation is only vulnerable to this race when operating on -a shared mutex. -A possible fix for the current implementation is to strengthen the checks -for shared mutexes before terminating them, in particular, verifying -that the mutex memory is mapped from a shared memory object allocated -by the -.Dv UMTX_OP_SHM -request. -This is not done because it is believed that the race is adequately -covered by other consistency checks, while adding the check would -prevent alternative implementations of -.Li libpthread . .Sh SEE ALSO .Xr clock_gettime 2 , .Xr mmap 2 , -.Xr shm_open 2 , .Xr setrlimit 2 , +.Xr shm_open 2 , .Xr sigaction 2 , .Xr thr_exit 2 , .Xr thr_kill 2 , @@ -1425,3 +1404,24 @@ to implement .St -p1003.1-2001 .Xr pthread 3 functionality. +.Sh BUGS +A window between a unlocking robust mutex and resetting the pointer in the +.Dv robust_inact_offset +member of the registered +.Vt struct umtx_robust_lists_params +allows another thread to destroy the mutex, thus making the kernel inspect +freed or reused memory. +The +.Li libthr +implementation is only vulnerable to this race when operating on +a shared mutex. +A possible fix for the current implementation is to strengthen the checks +for shared mutexes before terminating them, in particular, verifying +that the mutex memory is mapped from a shared memory object allocated +by the +.Dv UMTX_OP_SHM +request. +This is not done because it is believed that the race is adequately +covered by other consistency checks, while adding the check would +prevent alternative implementations of +.Li libpthread . From owner-svn-src-head@freebsd.org Tue May 23 07:31:04 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D1B38D7A8AE; Tue, 23 May 2017 07:31:04 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A3ADF100C; Tue, 23 May 2017 07:31:04 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7V3E5078993; Tue, 23 May 2017 07:31:03 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7V3A9078992; Tue, 23 May 2017 07:31:03 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230731.v4N7V3A9078992@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:31:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318717 - 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.23 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, 23 May 2017 07:31:04 -0000 Author: ngie Date: Tue May 23 07:31:03 2017 New Revision: 318717 URL: https://svnweb.freebsd.org/changeset/base/318717 Log: cap_enter(2): fix manlint issues - Sort SEE ALSO section appropriately. - Correct section for sysctl(9). Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/sys/cap_enter.2 Modified: head/lib/libc/sys/cap_enter.2 ============================================================================== --- head/lib/libc/sys/cap_enter.2 Tue May 23 07:27:30 2017 (r318716) +++ head/lib/libc/sys/cap_enter.2 Tue May 23 07:31:03 2017 (r318717) @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 27, 2016 +.Dd May 23, 2017 .Dt CAP_ENTER 2 .Os .Sh NAME @@ -144,11 +144,11 @@ points outside the process's allocated a .Xr cap_fcntls_limit 2 , .Xr cap_ioctls_limit 2 , .Xr cap_rights_limit 2 , -.Xr procctl 2 , -.Xr sysctl 2 , .Xr fexecve 2 , +.Xr procctl 2 , .Xr cap_sandboxed 3 , -.Xr capsicum 4 +.Xr capsicum 4 , +.Xr sysctl 9 .Sh HISTORY Support for capabilities and capabilities mode was developed as part of the .Tn TrustedBSD From owner-svn-src-head@freebsd.org Tue May 23 07:32:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C0D86D7AA4F; Tue, 23 May 2017 07:32:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 92F6412DD; Tue, 23 May 2017 07:32:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7WvVZ082580; Tue, 23 May 2017 07:32:57 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7WvV3082579; Tue, 23 May 2017 07:32:57 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230732.v4N7WvV3082579@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:32:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318718 - 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.23 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, 23 May 2017 07:32:58 -0000 Author: ngie Date: Tue May 23 07:32:57 2017 New Revision: 318718 URL: https://svnweb.freebsd.org/changeset/base/318718 Log: rctl_add_rule(2): fix manlint warnings - Fix commas (either missing or misused) after .Nm entries in SYNOPSIS Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/sys/rctl_add_rule.2 Modified: head/lib/libc/sys/rctl_add_rule.2 ============================================================================== --- head/lib/libc/sys/rctl_add_rule.2 Tue May 23 07:31:03 2017 (r318717) +++ head/lib/libc/sys/rctl_add_rule.2 Tue May 23 07:32:57 2017 (r318718) @@ -28,10 +28,10 @@ .Dt RCTL_ADD_RULE 2 .Os .Sh NAME -.Nm rctl_add_rule, -.Nm rctl_get_limits -.Nm rctl_get_racct, -.Nm rctl_get_rules, +.Nm rctl_add_rule , +.Nm rctl_get_limits , +.Nm rctl_get_racct , +.Nm rctl_get_rules , .Nm rctl_remove_rule .Nd manipulate and query the resource limits database .Sh LIBRARY From owner-svn-src-head@freebsd.org Tue May 23 07:44:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5A710D7AF71; Tue, 23 May 2017 07:44:45 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2AB3E1A54; Tue, 23 May 2017 07:44:45 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7iiLc086933; Tue, 23 May 2017 07:44:44 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7ii1S086932; Tue, 23 May 2017 07:44:44 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230744.v4N7ii1S086932@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:44:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318719 - 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.23 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, 23 May 2017 07:44:45 -0000 Author: ngie Date: Tue May 23 07:44:43 2017 New Revision: 318719 URL: https://svnweb.freebsd.org/changeset/base/318719 Log: open(2): fix manlint warnings - Sort SEE ALSO .Xr entries. - Sort sections (HISTORY comes after STANDARDS). Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/sys/open.2 Modified: head/lib/libc/sys/open.2 ============================================================================== --- head/lib/libc/sys/open.2 Tue May 23 07:32:57 2017 (r318718) +++ head/lib/libc/sys/open.2 Tue May 23 07:44:43 2017 (r318719) @@ -490,7 +490,6 @@ was called and the process is in capabil is an absolute path or contained "..". .El .Sh SEE ALSO -.Xr capsicum 4 , .Xr chmod 2 , .Xr close 2 , .Xr dup 2 , @@ -503,16 +502,8 @@ is an absolute path or contained "..". .Xr read 2 , .Xr umask 2 , .Xr write 2 , -.Xr fopen 3 -.Sh HISTORY -The -.Fn open -function appeared in -.At v6 . -The -.Fn openat -function was introduced in -.Fx 8.0 . +.Xr fopen 3 , +.Xr capsicum 4 .Sh STANDARDS These functions are specified by .St -p1003.1-2008 . @@ -529,6 +520,15 @@ when is set in flags and the final component of pathname is a symbolic link to distinguish it from the case of too many symbolic link traversals in one of its non-final components. +.Sh HISTORY +The +.Fn open +function appeared in +.At v6 . +The +.Fn openat +function was introduced in +.Fx 8.0 . .Sh BUGS The Open Group Extended API Set 2 specification requires that the test for whether From owner-svn-src-head@freebsd.org Tue May 23 07:45:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 91ABDD7AFE0; Tue, 23 May 2017 07:45:30 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 621361BD2; Tue, 23 May 2017 07:45:30 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7jT8Q087009; Tue, 23 May 2017 07:45:29 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7jT33087008; Tue, 23 May 2017 07:45:29 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230745.v4N7jT33087008@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:45:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318720 - 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.23 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, 23 May 2017 07:45:30 -0000 Author: ngie Date: Tue May 23 07:45:29 2017 New Revision: 318720 URL: https://svnweb.freebsd.org/changeset/base/318720 Log: ptrace(2): clean up trailing whitespace Reviewed by: make manlint MFC after: 2 weeks Modified: head/lib/libc/sys/ptrace.2 Modified: head/lib/libc/sys/ptrace.2 ============================================================================== --- head/lib/libc/sys/ptrace.2 Tue May 23 07:44:43 2017 (r318719) +++ head/lib/libc/sys/ptrace.2 Tue May 23 07:45:29 2017 (r318720) @@ -166,7 +166,7 @@ new child processes will execute without This event flag controls tracing of LWP .Pq kernel thread creation and destruction. -When this event is enabled, +When this event is enabled, new LWPs will stop and report an event with .Dv PL_FLAG_BORN set before executing their first instruction, @@ -215,7 +215,7 @@ or includes only .Dv PTRACE_EXEC events. -All other event flags are disabled. +All other event flags are disabled. .Pp The .Fa request From owner-svn-src-head@freebsd.org Tue May 23 07:46:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 47744D7A034; Tue, 23 May 2017 07:46:12 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1938F1D1E; Tue, 23 May 2017 07:46:12 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7kBt5087076; Tue, 23 May 2017 07:46:11 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7kBKH087075; Tue, 23 May 2017 07:46:11 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230746.v4N7kBKH087075@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:46:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318721 - 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.23 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, 23 May 2017 07:46:12 -0000 Author: ngie Date: Tue May 23 07:46:10 2017 New Revision: 318721 URL: https://svnweb.freebsd.org/changeset/base/318721 Log: kill(2): add missing section for sysctl(9) Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/lib/libc/sys/kill.2 Modified: head/lib/libc/sys/kill.2 ============================================================================== --- head/lib/libc/sys/kill.2 Tue May 23 07:45:29 2017 (r318720) +++ head/lib/libc/sys/kill.2 Tue May 23 07:46:10 2017 (r318721) @@ -71,7 +71,7 @@ A single exception is the signal SIGCONT to any process with the same session ID as the sender. In addition, if the .Va security.bsd.conservative_signals -.Xr sysctl +.Xr sysctl 9 is set to 1, the user is not a super-user, and the receiver is set-uid, then only job control and terminal control signals may From owner-svn-src-head@freebsd.org Tue May 23 07:50:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D97FD7A12D; Tue, 23 May 2017 07:50:44 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A8DA1EF8; Tue, 23 May 2017 07:50:44 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N7oh1b087352; Tue, 23 May 2017 07:50:43 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N7ohBT087335; Tue, 23 May 2017 07:50:43 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230750.v4N7ohBT087335@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 07:50:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318722 - 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.23 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, 23 May 2017 07:50:44 -0000 Author: ngie Date: Tue May 23 07:50:42 2017 New Revision: 318722 URL: https://svnweb.freebsd.org/changeset/base/318722 Log: sade(8): start new sentence on new line Reported by: make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/usr.sbin/bsdinstall/partedit/sade.8 Modified: head/usr.sbin/bsdinstall/partedit/sade.8 ============================================================================== --- head/usr.sbin/bsdinstall/partedit/sade.8 Tue May 23 07:46:10 2017 (r318721) +++ head/usr.sbin/bsdinstall/partedit/sade.8 Tue May 23 07:50:42 2017 (r318722) @@ -59,7 +59,8 @@ first appeared in .Fx 6.3 as a utility encapsulating features from the .Xr sysinstall 8 -installer. It was replaced in +installer. +It was replaced in .Fx 10.0 with the equivalent part of .Xr bsdinstall 8 . From owner-svn-src-head@freebsd.org Tue May 23 08:01:13 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5A0AD7A587; Tue, 23 May 2017 08:01:13 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 085C014AB; Tue, 23 May 2017 08:01:12 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N81CEt092106; Tue, 23 May 2017 08:01:12 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N81CWA092090; Tue, 23 May 2017 08:01:12 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705230801.v4N81CWA092090@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 08:01:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318723 - 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.23 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, 23 May 2017 08:01:14 -0000 Author: ngie Date: Tue May 23 08:01:11 2017 New Revision: 318723 URL: https://svnweb.freebsd.org/changeset/base/318723 Log: bsdinstall(8): fix manpage issues - Start new sentences on new lines. - Separate e.g. (more of an igor thing) with commas, and rewrite some examples not to be enclosed in parentheses. Reported by: igor, make manlint MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/usr.sbin/bsdinstall/bsdinstall.8 Modified: head/usr.sbin/bsdinstall/bsdinstall.8 ============================================================================== --- head/usr.sbin/bsdinstall/bsdinstall.8 Tue May 23 07:50:42 2017 (r318722) +++ head/usr.sbin/bsdinstall/bsdinstall.8 Tue May 23 08:01:11 2017 (r318723) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 31, 2014 +.Dd May 23, 2017 .Dt BSDINSTALL 8 .Os .Sh NAME @@ -39,17 +39,18 @@ .Sh DESCRIPTION .Nm is used for installation of new systems, both for system setup from -installation media (e.g. CD-ROMs) and for use on live systems to prepare +installation media, e.g., CD-ROMs, and for use on live systems to prepare VM images and jails. .Pp Much like .Xr make 1 , Nm -takes a target and possible parameters of the target as arguments. If -invoked with no arguments, it will invoke the +takes a target and possible parameters of the target as arguments. +If invoked with no arguments, it will invoke the .Cm auto target, which provides a standard interactive installation, invoking the -others in sequence. To perform a scripted installation, these subtargets -can be invoked separately by an installation script. +others in sequence. +To perform a scripted installation, +these subtargets can be invoked separately by an installation script. .Sh OPTIONS .Nm supports the following options, global to all targets: @@ -115,7 +116,8 @@ If is set, also configures the network interfaces of the current system to match. .It Cm autopart Provides the installer's interactive guided disk partitioner for single-disk -installations. Defaults to UFS. +installations. +Defaults to UFS. .It Cm zfsboot Provides an alternative ZFS-only automatic interactive disk partitioner. Creates a single @@ -135,8 +137,8 @@ to encrypt the disk. Provides the installer's interactive manual disk partitioner with an interface identical to .Xr sade 8 . -Supports multiple disks as well as UFS, ZFS, and FAT file systems. ZFS -is set up with one pool and dataset per partition. +Supports multiple disks as well as UFS, ZFS, and FAT file systems. +ZFS is set up with one pool and dataset per partition. .It Cm scriptedpart Ar parameters Sets up disks like .Cm autopart @@ -150,14 +152,16 @@ Each disk setup is specified by a three- .Op Ar scheme .Op Ar {partitions} .Pp -Multiple disk setups are separated by semicolons. The +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 +partition scheme to apply to the disk. +If .Ar scheme is unspecified, .Cm scriptedpart @@ -167,7 +171,8 @@ The 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 +curly braces. +Each partition declaration takes the form .Pp .Ar size .Ar type @@ -178,15 +183,17 @@ specifies the partition size to create i 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 +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, freebsd-zfs, or freebsd-swap). +filesystem type, e.g., freebsd-ufs, freebsd-zfs, 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: +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 } .Pp @@ -238,37 +245,43 @@ Reads a small amount of data from .Pa /dev/random and stores it in a file in the new system's root directory. .It Cm config -Installs the configuration files destined for the new system (e.g. rc.conf +Installs the configuration files destined for the new system, e.g., +.Xr rc.conf 5 fragments generated by .Cm netconfig , etc.) onto the new system. .El .Sh ENVIRONMENT VARIABLES The following environment variables control various aspects of the installation -process. Many are used internally during installation and have reasonable -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. +process. +Many are used internally during installation and have reasonable 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_DISTSITE" .It Ev DISTRIBUTIONS -The set of distributions to install (e.g. "base kernel ports"). Default: none +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: +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. +names. +Most targets, e.g., .Cm auto and -.Cm jail ) +.Cm jail , that prompt for a .Fx mirror will skip that step if this variable is already defined in the -environment. Example: +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 @@ -276,23 +289,26 @@ directory at which the root file system Default: .Pa /mnt .It Ev BSDINSTALL_LOG -Path to a log file for the installation. Default: +Path to a log file for the installation. +Default: .Pa /tmp/bsdinstall_log .It Ev BSDINSTALL_TMPETC Directory where files destined for the new system's .Pa /etc will be stored until the .Cm config -target is executed. If this directory does not already exist, it will be -created. Default: +target is executed. +If this directory does not already exist, it will be created. +Default: .Pa /tmp/bsdinstall_etc .It Ev BSDINSTALL_TMPBOOT Directory where files destined for the new system's .Pa /boot will be stored until the .Cm config -target is executed. If this directory does not already exist, it will be -created. Default: +target is executed. +If this directory does not already exist, it will be created. +Default: .Pa /tmp/bsdinstall_boot .El .Sh SCRIPTING @@ -307,8 +323,9 @@ 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. +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 @@ -326,19 +343,21 @@ On 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 +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 +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 +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 +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 , @@ -358,13 +377,14 @@ instead of .Ev PARTITIONS . .Ss SETUP SCRIPT 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 +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. +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 May 23 09:01:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2FDDED78EFD; Tue, 23 May 2017 09:01:50 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E8EDD1046; Tue, 23 May 2017 09:01:49 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N91ns2016186; Tue, 23 May 2017 09:01:49 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N91mE0016182; Tue, 23 May 2017 09:01:48 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201705230901.v4N91mE0016182@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Tue, 23 May 2017 09:01:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318734 - head/sys/netipsec 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.23 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, 23 May 2017 09:01:50 -0000 Author: ae Date: Tue May 23 09:01:48 2017 New Revision: 318734 URL: https://svnweb.freebsd.org/changeset/base/318734 Log: Fix possible double releasing for SA reference. There are two possible ways how crypto callback are called: directly from caller and deffered from crypto thread. For inbound packets the direct call chain is the following: IPSEC_INPUT() method -> ipsec_common_input() -> xform_input() -> -> crypto_dispatch() -> crypto_invoke() -> crypto_done() -> -> xform_input_cb() -> ipsec[46]_common_input_cb() -> netisr_queue(). The SA reference is held while crypto processing is not finished. The error handling code wrongly expected that crypto callback always called from the crypto thread context, and it did SA reference releasing in xform_input_cb(). But when the crypto callback called directly, in case of error (e.g. data authentification failed) the error handling in ipsec_common_input() also did SA reference releasing. To fix this, remove error handling from ipsec_common_input() and do it in xform_input() before crypto_dispatch(). PR: 219356 MFC after: 10 days Modified: head/sys/netipsec/ipsec_input.c head/sys/netipsec/xform_ah.c head/sys/netipsec/xform_esp.c head/sys/netipsec/xform_ipcomp.c Modified: head/sys/netipsec/ipsec_input.c ============================================================================== --- head/sys/netipsec/ipsec_input.c Tue May 23 08:11:55 2017 (r318733) +++ head/sys/netipsec/ipsec_input.c Tue May 23 09:01:48 2017 (r318734) @@ -223,8 +223,6 @@ ipsec_common_input(struct mbuf *m, int s * everything else. */ error = (*sav->tdb_xform->xf_input)(m, sav, skip, protoff); - if (error != 0) - key_freesav(&sav); return (error); } Modified: head/sys/netipsec/xform_ah.c ============================================================================== --- head/sys/netipsec/xform_ah.c Tue May 23 08:11:55 2017 (r318733) +++ head/sys/netipsec/xform_ah.c Tue May 23 09:01:48 2017 (r318734) @@ -566,8 +566,8 @@ ah_input(struct mbuf *m, struct secasvar if (ah == NULL) { DPRINTF(("ah_input: cannot pullup header\n")); AHSTAT_INC(ahs_hdrops); /*XXX*/ - m_freem(m); - return ENOBUFS; + error = ENOBUFS; + goto bad; } /* Check replay window, if applicable. */ @@ -578,8 +578,8 @@ ah_input(struct mbuf *m, struct secasvar AHSTAT_INC(ahs_replay); DPRINTF(("%s: packet replay failure: %s\n", __func__, ipsec_sa2str(sav, buf, sizeof(buf)))); - m_freem(m); - return (EACCES); + error = EACCES; + goto bad; } cryptoid = sav->tdb_cryptoid; SECASVAR_UNLOCK(sav); @@ -595,8 +595,8 @@ ah_input(struct mbuf *m, struct secasvar ipsec_address(&sav->sah->saidx.dst, buf, sizeof(buf)), (u_long) ntohl(sav->spi))); AHSTAT_INC(ahs_badauthl); - m_freem(m); - return EACCES; + error = EACCES; + goto bad; } AHSTAT_ADD(ahs_ibytes, m->m_pkthdr.len - skip - hl); @@ -606,8 +606,8 @@ ah_input(struct mbuf *m, struct secasvar DPRINTF(("%s: failed to acquire crypto descriptor\n", __func__)); AHSTAT_INC(ahs_crypto); - m_freem(m); - return ENOBUFS; + error = ENOBUFS; + goto bad; } crda = crp->crp_desc; @@ -629,8 +629,8 @@ ah_input(struct mbuf *m, struct secasvar DPRINTF(("%s: failed to allocate xform_data\n", __func__)); AHSTAT_INC(ahs_crypto); crypto_freereq(crp); - m_freem(m); - return ENOBUFS; + error = ENOBUFS; + goto bad; } /* @@ -650,6 +650,7 @@ ah_input(struct mbuf *m, struct secasvar AHSTAT_INC(ahs_hdrops); free(xd, M_XDATA); crypto_freereq(crp); + key_freesav(&sav); return (error); } @@ -668,6 +669,10 @@ ah_input(struct mbuf *m, struct secasvar xd->skip = skip; xd->cryptoid = cryptoid; return (crypto_dispatch(crp)); +bad: + m_freem(m); + key_freesav(&sav); + return (error); } /* Modified: head/sys/netipsec/xform_esp.c ============================================================================== --- head/sys/netipsec/xform_esp.c Tue May 23 08:11:55 2017 (r318733) +++ head/sys/netipsec/xform_esp.c Tue May 23 09:01:48 2017 (r318734) @@ -272,18 +272,18 @@ esp_input(struct mbuf *m, struct secasva struct newesp *esp; uint8_t *ivp; uint64_t cryptoid; - int plen, alen, hlen; + int alen, error, hlen, plen; IPSEC_ASSERT(sav != NULL, ("null SA")); IPSEC_ASSERT(sav->tdb_encalgxform != NULL, ("null encoding xform")); + error = EINVAL; /* Valid IP Packet length ? */ if ( (skip&3) || (m->m_pkthdr.len&3) ){ DPRINTF(("%s: misaligned packet, skip %u pkt len %u", __func__, skip, m->m_pkthdr.len)); ESPSTAT_INC(esps_badilen); - m_freem(m); - return EINVAL; + goto bad; } /* XXX don't pullup, just copy header */ IP6_EXTHDR_GET(esp, struct newesp *, m, skip, sizeof (struct newesp)); @@ -314,8 +314,7 @@ esp_input(struct mbuf *m, struct secasva ipsec_address(&sav->sah->saidx.dst, buf, sizeof(buf)), (u_long)ntohl(sav->spi))); ESPSTAT_INC(esps_badilen); - m_freem(m); - return EINVAL; + goto bad; } /* @@ -328,8 +327,8 @@ esp_input(struct mbuf *m, struct secasva DPRINTF(("%s: packet replay check for %s\n", __func__, ipsec_sa2str(sav, buf, sizeof(buf)))); ESPSTAT_INC(esps_replay); - m_freem(m); - return (EACCES); + error = EACCES; + goto bad; } } cryptoid = sav->tdb_cryptoid; @@ -344,8 +343,8 @@ esp_input(struct mbuf *m, struct secasva DPRINTF(("%s: failed to acquire crypto descriptors\n", __func__)); ESPSTAT_INC(esps_crypto); - m_freem(m); - return ENOBUFS; + error = ENOBUFS; + goto bad; } /* Get IPsec-specific opaque pointer */ @@ -354,8 +353,8 @@ esp_input(struct mbuf *m, struct secasva DPRINTF(("%s: failed to allocate xform_data\n", __func__)); ESPSTAT_INC(esps_crypto); crypto_freereq(crp); - m_freem(m); - return ENOBUFS; + error = ENOBUFS; + goto bad; } if (esph != NULL) { @@ -425,6 +424,10 @@ esp_input(struct mbuf *m, struct secasva crde->crd_alg = espx->type; return (crypto_dispatch(crp)); +bad: + m_freem(m); + key_freesav(&sav); + return (error); } /* Modified: head/sys/netipsec/xform_ipcomp.c ============================================================================== --- head/sys/netipsec/xform_ipcomp.c Tue May 23 08:11:55 2017 (r318733) +++ head/sys/netipsec/xform_ipcomp.c Tue May 23 09:01:48 2017 (r318734) @@ -194,34 +194,35 @@ ipcomp_input(struct mbuf *m, struct seca struct cryptop *crp; struct ipcomp *ipcomp; caddr_t addr; - int hlen = IPCOMP_HLENGTH; + int error, hlen = IPCOMP_HLENGTH; /* * Check that the next header of the IPComp is not IPComp again, before * doing any real work. Given it is not possible to do double * compression it means someone is playing tricks on us. */ + error = ENOBUFS; if (m->m_len < skip + hlen && (m = m_pullup(m, skip + hlen)) == NULL) { IPCOMPSTAT_INC(ipcomps_hdrops); /*XXX*/ DPRINTF(("%s: m_pullup failed\n", __func__)); - return (ENOBUFS); + key_freesav(&sav); + return (error); } addr = (caddr_t) mtod(m, struct ip *) + skip; ipcomp = (struct ipcomp *)addr; if (ipcomp->comp_nxt == IPPROTO_IPCOMP) { - m_freem(m); IPCOMPSTAT_INC(ipcomps_pdrops); /* XXX have our own stats? */ DPRINTF(("%s: recursive compression detected\n", __func__)); - return (EINVAL); + error = EINVAL; + goto bad; } /* Get crypto descriptors */ crp = crypto_getreq(1); if (crp == NULL) { - m_freem(m); DPRINTF(("%s: no crypto descriptors\n", __func__)); IPCOMPSTAT_INC(ipcomps_crypto); - return ENOBUFS; + goto bad; } /* Get IPsec-specific opaque pointer */ xd = malloc(sizeof(*xd), M_XDATA, M_NOWAIT | M_ZERO); @@ -229,8 +230,7 @@ ipcomp_input(struct mbuf *m, struct seca DPRINTF(("%s: cannot allocate xform_data\n", __func__)); IPCOMPSTAT_INC(ipcomps_crypto); crypto_freereq(crp); - m_freem(m); - return ENOBUFS; + goto bad; } crdc = crp->crp_desc; @@ -259,6 +259,10 @@ ipcomp_input(struct mbuf *m, struct seca SECASVAR_UNLOCK(sav); return crypto_dispatch(crp); +bad: + m_freem(m); + key_freesav(&sav); + return (error); } /* From owner-svn-src-head@freebsd.org Tue May 23 09:05:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D5470D7901E; Tue, 23 May 2017 09:05:48 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4EE51139B; Tue, 23 May 2017 09:05:48 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4N95dqF010707 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 23 May 2017 12:05:39 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4N95dqF010707 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4N95daD010705; Tue, 23 May 2017 12:05:39 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Tue, 23 May 2017 12:05:39 +0300 From: Konstantin Belousov To: Ngie Cooper Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318721 - head/lib/libc/sys Message-ID: <20170523090539.GZ1622@kib.kiev.ua> References: <201705230746.v4N7kBKH087075@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705230746.v4N7kBKH087075@repo.freebsd.org> User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 09:05:48 -0000 On Tue, May 23, 2017 at 07:46:11AM +0000, Ngie Cooper wrote: > Author: ngie > Date: Tue May 23 07:46:10 2017 > New Revision: 318721 > URL: https://svnweb.freebsd.org/changeset/base/318721 > > Log: > kill(2): add missing section for sysctl(9) > > Reported by: make manlint > MFC after: 2 weeks > Sponsored by: Dell EMC Isilon > > Modified: > head/lib/libc/sys/kill.2 > > Modified: head/lib/libc/sys/kill.2 > ============================================================================== > --- head/lib/libc/sys/kill.2 Tue May 23 07:45:29 2017 (r318720) > +++ head/lib/libc/sys/kill.2 Tue May 23 07:46:10 2017 (r318721) > @@ -71,7 +71,7 @@ A single exception is the signal SIGCONT > to any process with the same session ID as the sender. > In addition, if the > .Va security.bsd.conservative_signals > -.Xr sysctl > +.Xr sysctl 9 Section 9 implies that user must somehow access in-kernel interface to tweak the setting. > is set to 1, the user is not a super-user, and > the receiver is set-uid, then > only job control and terminal control signals may From owner-svn-src-head@freebsd.org Tue May 23 09:29:08 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4E72DD796BC; Tue, 23 May 2017 09:29:08 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1A8721F77; Tue, 23 May 2017 09:29:08 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N9T7Vn028139; Tue, 23 May 2017 09:29:07 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N9T5g1028124; Tue, 23 May 2017 09:29:05 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705230929.v4N9T5g1028124@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 23 May 2017 09:29:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... 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.23 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, 23 May 2017 09:29:08 -0000 Author: kib Date: Tue May 23 09:29:05 2017 New Revision: 318736 URL: https://svnweb.freebsd.org/changeset/base/318736 Log: Commit the 64-bit inode project. Extend the ino_t, dev_t, nlink_t types to 64-bit ints. Modify struct dirent layout to add d_off, increase the size of d_fileno to 64-bits, increase the size of d_namlen to 16-bits, and change the required alignment. Increase struct statfs f_mntfromname[] and f_mntonname[] array length MNAMELEN to 1024. ABI breakage is mitigated by providing compatibility using versioned symbols, ingenious use of the existing padding in structures, and by employing other tricks. Unfortunately, not everything can be fixed, especially outside the base system. For instance, third-party APIs which pass struct stat around are broken in backward and forward incompatible ways. Kinfo sysctl MIBs ABI is changed in backward-compatible way, but there is no general mechanism to handle other sysctl MIBS which return structures where the layout has changed. It was considered that the breakage is either in the management interfaces, where we usually allow ABI slip, or is not important. Struct xvnode changed layout, no compat shims are provided. For struct xtty, dev_t tty device member was reduced to uint32_t. It was decided that keeping ABI compat in this case is more useful than reporting 64-bit dev_t, for the sake of pstat. Update note: strictly follow the instructions in UPDATING. Build and install the new kernel with COMPAT_FREEBSD11 option enabled, then reboot, and only then install new world. Credits: The 64-bit inode project, also known as ino64, started life many years ago as a project by Gleb Kurtsou (gleb). Kirk McKusick (mckusick) then picked up and updated the patch, and acted as a flag-waver. Feedback, suggestions, and discussions were carried by Ed Maste (emaste), John Baldwin (jhb), Jilles Tjoelker (jilles), and Rick Macklem (rmacklem). Kris Moore (kris) performed an initial ports investigation followed by an exp-run by Antoine Brodin (antoine). Essential and all-embracing testing was done by Peter Holm (pho). The heavy lifting of coordinating all these efforts and bringing the project to completion were done by Konstantin Belousov (kib). Sponsored by: The FreeBSD Foundation (emaste, kib) Differential revision: https://reviews.freebsd.org/D10439 Added: head/lib/libc/gen/devname-compat11.c (contents, props changed) head/lib/libc/gen/fts-compat11.c - copied, changed from r318735, head/lib/libc/gen/fts.c head/lib/libc/gen/fts-compat11.h - copied, changed from r318735, head/include/fts.h head/lib/libc/gen/ftw-compat11.c - copied, changed from r318735, head/lib/libc/gen/ftw.c head/lib/libc/gen/gen-compat.h (contents, props changed) head/lib/libc/gen/getmntinfo-compat11.c - copied, changed from r318735, head/lib/libc/gen/getmntinfo.c head/lib/libc/gen/glob-compat11.c - copied, changed from r318735, head/lib/libc/gen/glob.c head/lib/libc/gen/glob-compat11.h - copied, changed from r318735, head/include/glob.h head/lib/libc/gen/nftw-compat11.c - copied, changed from r318735, head/lib/libc/gen/nftw.c head/lib/libc/gen/readdir-compat11.c - copied, changed from r318735, head/lib/libc/gen/readdir.c head/lib/libc/gen/scandir-compat11.c - copied, changed from r318735, head/lib/libc/gen/scandir.c head/lib/libc/sys/getdents.c (contents, props changed) head/lib/libc/sys/lstat.c (contents, props changed) head/lib/libc/sys/mknod.c (contents, props changed) head/lib/libc/sys/stat.c (contents, props changed) head/lib/libprocstat/libprocstat_compat.c (contents, props changed) Modified: head/cddl/lib/libzfs/Makefile head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h head/contrib/openbsm/libbsm/bsm_wrappers.c head/include/dirent.h head/lib/libarchive/Makefile head/lib/libc/gen/Makefile.inc head/lib/libc/gen/Symbol.map head/lib/libc/gen/closedir.c head/lib/libc/gen/fts-compat.c head/lib/libc/gen/fts-compat.h head/lib/libc/gen/gen-private.h head/lib/libc/gen/opendir.c head/lib/libc/gen/readdir.c head/lib/libc/gen/scandir.c head/lib/libc/gen/telldir.h head/lib/libc/include/compat.h head/lib/libc/include/libc_private.h head/lib/libc/sys/Makefile.inc head/lib/libc/sys/Symbol.map head/lib/libc/sys/getdirentries.2 head/lib/libc/sys/statfs.2 head/lib/libkvm/kvm_proc.c head/lib/libmilter/Makefile head/lib/libprocstat/Makefile head/lib/libprocstat/Symbol.map head/lib/libprocstat/libprocstat.c head/lib/libprocstat/libprocstat.h head/lib/libufs/libufs.h head/sbin/badsect/badsect.c head/sbin/fsck_ffs/suj.c head/share/man/man5/acct.5 head/share/man/man5/dir.5 head/sys/bsm/audit.h head/sys/cddl/compat/opensolaris/sys/dirent.h head/sys/compat/freebsd32/capabilities.conf head/sys/compat/freebsd32/freebsd32.h head/sys/compat/freebsd32/freebsd32_misc.c head/sys/compat/freebsd32/syscalls.master head/sys/compat/linux/linux_file.c head/sys/dev/snp/snp.c head/sys/fs/devfs/devfs_devs.c head/sys/fs/devfs/devfs_vnops.c head/sys/fs/fdescfs/fdesc_vnops.c head/sys/fs/nandfs/nandfs_fs.h head/sys/fs/nfs/nfsport.h head/sys/fs/nfsclient/nfs_clrpcops.c head/sys/fs/nfsclient/nfs_clvnops.c head/sys/fs/nfsserver/nfs_nfsdport.c head/sys/kern/capabilities.conf head/sys/kern/kern_acct.c head/sys/kern/kern_descrip.c head/sys/kern/kern_proc.c head/sys/kern/makesyscalls.sh head/sys/kern/sys_socket.c head/sys/kern/syscalls.master head/sys/kern/tty.c head/sys/kern/tty_pts.c head/sys/kern/vfs_syscalls.c head/sys/kern/vfs_vnops.c head/sys/nlm/nlm_advlock.c head/sys/security/audit/audit_private.h head/sys/sys/_types.h head/sys/sys/acct.h head/sys/sys/dirent.h head/sys/sys/mount.h head/sys/sys/param.h head/sys/sys/stat.h head/sys/sys/syscallsubr.h head/sys/sys/tty.h head/sys/sys/user.h head/sys/sys/vnode.h head/sys/vm/swap_pager.c head/sys/vm/vm_object.c head/sys/vm/vm_param.h head/usr.bin/kdump/kdump.c head/usr.bin/lastcomm/lastcomm.c head/usr.bin/lastcomm/readrec.c head/usr.sbin/pstat/pstat.c head/usr.sbin/sa/extern.h head/usr.sbin/sa/main.c Modified: head/cddl/lib/libzfs/Makefile ============================================================================== --- head/cddl/lib/libzfs/Makefile Tue May 23 09:20:31 2017 (r318735) +++ head/cddl/lib/libzfs/Makefile Tue May 23 09:29:05 2017 (r318736) @@ -37,6 +37,7 @@ SRCS+= libzfs_changelist.c \ zprop_common.c \ WARNS?= 0 +SHLIB_MAJOR= 3 CSTD= c99 CFLAGS+= -DZFS_NO_ACL CFLAGS+= -I${SRCTOP}/sbin/mount Modified: head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc ============================================================================== --- head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc Tue May 23 09:20:31 2017 (r318735) +++ head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_linux.cc Tue May 23 09:29:05 2017 (r318736) @@ -223,7 +223,8 @@ static void kernel_stat_to_stat(struct k uptr internal_stat(const char *path, void *buf) { #if SANITIZER_FREEBSD - return internal_syscall(SYSCALL(stat), path, buf); + return internal_syscall(SYSCALL(fstatat), AT_FDCWD, (uptr)path, + (uptr)buf, 0); #elif SANITIZER_USES_CANONICAL_LINUX_SYSCALLS return internal_syscall(SYSCALL(newfstatat), AT_FDCWD, (uptr)path, (uptr)buf, 0); @@ -247,7 +248,8 @@ uptr internal_stat(const char *path, voi uptr internal_lstat(const char *path, void *buf) { #if SANITIZER_FREEBSD - return internal_syscall(SYSCALL(lstat), path, buf); + return internal_syscall(SYSCALL(fstatat), AT_FDCWD, (uptr)path, + (uptr)buf, AT_SYMLINK_NOFOLLOW); #elif SANITIZER_USES_CANONICAL_LINUX_SYSCALLS return internal_syscall(SYSCALL(newfstatat), AT_FDCWD, (uptr)path, (uptr)buf, AT_SYMLINK_NOFOLLOW); @@ -590,7 +592,9 @@ uptr internal_getppid() { } uptr internal_getdents(fd_t fd, struct linux_dirent *dirp, unsigned int count) { -#if SANITIZER_USES_CANONICAL_LINUX_SYSCALLS +#if SANITIZER_FREEBSD + return internal_syscall(SYSCALL(getdirentries), fd, (uptr)dirp, count, NULL); +#elif SANITIZER_USES_CANONICAL_LINUX_SYSCALLS return internal_syscall(SYSCALL(getdents64), fd, (uptr)dirp, count); #else return internal_syscall(SYSCALL(getdents), fd, (uptr)dirp, count); Modified: head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h ============================================================================== --- head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h Tue May 23 09:20:31 2017 (r318735) +++ head/contrib/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h Tue May 23 09:29:05 2017 (r318736) @@ -489,7 +489,8 @@ namespace __sanitizer { }; #elif SANITIZER_FREEBSD struct __sanitizer_dirent { - unsigned int d_fileno; + unsigned long long d_fileno; + unsigned long long d_off; unsigned short d_reclen; // more fields that we don't care about }; Modified: head/contrib/openbsm/libbsm/bsm_wrappers.c ============================================================================== --- head/contrib/openbsm/libbsm/bsm_wrappers.c Tue May 23 09:20:31 2017 (r318735) +++ head/contrib/openbsm/libbsm/bsm_wrappers.c Tue May 23 09:29:05 2017 (r318736) @@ -264,12 +264,14 @@ audit_set_terminal_host(uint32_t *m) int audit_set_terminal_id(au_tid_t *tid) { + dev_t port; int ret; if (tid == NULL) return (kAUBadParamErr); - if ((ret = audit_set_terminal_port(&tid->port)) != kAUNoErr) + if ((ret = audit_set_terminal_port(&port)) != kAUNoErr) return (ret); + tid->port = port; return (audit_set_terminal_host(&tid->machine)); } Modified: head/include/dirent.h ============================================================================== --- head/include/dirent.h Tue May 23 09:20:31 2017 (r318735) +++ head/include/dirent.h Tue May 23 09:29:05 2017 (r318736) @@ -41,6 +41,25 @@ #include #include +#if __BSD_VISIBLE + +#ifndef _SIZE_T_DECLARED +typedef __size_t size_t; +#define _SIZE_T_DECLARED +#endif + +#ifndef _SSIZE_T_DECLARED +typedef __ssize_t ssize_t; +#define _SSIZE_T_DECLARED +#endif + +#ifndef _OFF_T_DECLARED +typedef __off_t off_t; +#define _OFF_T_DECLARED +#endif + +#endif /* __BSD_VISIBLE */ + #if __XSI_VISIBLE #ifndef _INO_T_DECLARED @@ -89,8 +108,8 @@ int dirfd(DIR *); #if __BSD_VISIBLE DIR *__opendir2(const char *, int); int fdclosedir(DIR *); -int getdents(int, char *, int); -int getdirentries(int, char *, int, long *); +ssize_t getdents(int, char *, size_t); +ssize_t getdirentries(int, char *, size_t, off_t *); #endif DIR *opendir(const char *); DIR *fdopendir(int); Modified: head/lib/libarchive/Makefile ============================================================================== --- head/lib/libarchive/Makefile Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libarchive/Makefile Tue May 23 09:29:05 2017 (r318736) @@ -11,7 +11,7 @@ CFLAGS+= -DHAVE_BZLIB_H=1 -DHAVE_LIBLZMA # FreeBSD SHLIB_MAJOR value is managed as part of the FreeBSD system. # It has no real relation to the libarchive version number. -SHLIB_MAJOR= 6 +SHLIB_MAJOR= 7 CFLAGS+= -DPLATFORM_CONFIG_H=\"${.CURDIR}/config_freebsd.h\" CFLAGS+= -I${.OBJDIR} Modified: head/lib/libc/gen/Makefile.inc ============================================================================== --- head/lib/libc/gen/Makefile.inc Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libc/gen/Makefile.inc Tue May 23 09:29:05 2017 (r318736) @@ -148,7 +148,15 @@ SRCS+= __getosreldate.c \ waitid.c \ wordexp.c .if ${MK_SYMVER} == yes -SRCS+= fts-compat.c \ +SRCS+= devname-compat11.c \ + fts-compat.c \ + fts-compat11.c \ + ftw-compat11.c \ + getmntinfo-compat11.c \ + glob-compat11.c \ + nftw-compat11.c \ + readdir-compat11.c \ + scandir-compat11.c \ unvis-compat.c .endif Modified: head/lib/libc/gen/Symbol.map ============================================================================== --- head/lib/libc/gen/Symbol.map Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libc/gen/Symbol.map Tue May 23 09:29:05 2017 (r318736) @@ -75,8 +75,6 @@ FBSD_1.0 { ctermid; ctermid_r; daemon; - devname; - devname_r; getdiskbyname; dladdr; dlclose; @@ -128,9 +126,6 @@ FBSD_1.0 { setfsent; endfsent; ftok; - ftw; - glob; - globfree; getbootfile; getbsize; cgetset; @@ -163,7 +158,6 @@ FBSD_1.0 { getloadavg; getlogin; getlogin_r; - getmntinfo; setnetgrent; getnetgrent; endnetgrent; @@ -209,7 +203,6 @@ FBSD_1.0 { lrand48; modf; mrand48; - nftw; nice; nlist; nrand48; @@ -220,13 +213,9 @@ FBSD_1.0 { pclose; psignal; raise; - readdir; - readdir_r; readpassphrase; getpass; rewinddir; - scandir; - alphasort; seed48; seekdir; user_from_uid; @@ -314,14 +303,6 @@ FBSD_1.1 { fdevname_r; fdopendir; feature_present; - fts_children; - fts_close; - fts_get_clientptr; - fts_get_stream; - fts_open; - fts_read; - fts_set; - fts_set_clientptr; posix_spawn; posix_spawn_file_actions_addclose; posix_spawn_file_actions_adddup2; @@ -408,13 +389,32 @@ FBSD_1.4 { pthread_mutex_consistent; pthread_mutexattr_getrobust; pthread_mutexattr_setrobust; - scandir_b; stravis; }; FBSD_1.5 { + alphasort; basename; + devname; + devname_r; dirname; + fts_children; + fts_close; + fts_get_clientptr; + fts_get_stream; + fts_open; + fts_read; + fts_set; + fts_set_clientptr; + ftw; + getmntinfo; + glob; + globfree; + nftw; + readdir; + readdir_r; + scandir; + scandir_b; sem_clockwait_np; }; Modified: head/lib/libc/gen/closedir.c ============================================================================== --- head/lib/libc/gen/closedir.c Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libc/gen/closedir.c Tue May 23 09:29:05 2017 (r318736) @@ -59,6 +59,7 @@ fdclosedir(DIR *dirp) dirp->dd_fd = -1; dirp->dd_loc = 0; free((void *)dirp->dd_buf); + free(dirp->dd_compat_de); _reclaim_telldir(dirp); if (__isthreaded) { _pthread_mutex_unlock(&dirp->dd_lock); Added: head/lib/libc/gen/devname-compat11.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libc/gen/devname-compat11.c Tue May 23 09:29:05 2017 (r318736) @@ -0,0 +1,50 @@ +/*- + * Copyright (c) 2011 Gleb Kurtsou + * 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. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include "gen-compat.h" + +char * +freebsd11_devname(uint32_t dev, mode_t type) +{ + + return (devname(dev, type)); +} + +char * +freebsd11_devname_r(uint32_t dev, mode_t type, char *buf, int len) +{ + + return (devname_r(dev, type, buf, len)); +} + +__sym_compat(devname, freebsd11_devname, FBSD_1.0); +__sym_compat(devname_r, freebsd11_devname_r, FBSD_1.0); Modified: head/lib/libc/gen/fts-compat.c ============================================================================== --- head/lib/libc/gen/fts-compat.c Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libc/gen/fts-compat.c Tue May 23 09:29:05 2017 (r318736) @@ -40,15 +40,19 @@ __FBSDID("$FreeBSD$"); #include "namespace.h" #include +#define _WANT_FREEBSD11_STATFS #include +#define _WANT_FREEBSD11_STAT #include +#define _WANT_FREEBSD11_DIRENT #include #include #include #include #include #include +#include "gen-compat.h" #include "fts-compat.h" #include "un-namespace.h" @@ -96,8 +100,8 @@ static int fts_ufslinks(FTS *, const FT */ struct _fts_private { FTS ftsp_fts; - struct statfs ftsp_statfs; - dev_t ftsp_dev; + struct freebsd11_statfs ftsp_statfs; + uint32_t ftsp_dev; int ftsp_linksreliable; }; @@ -626,7 +630,7 @@ __fts_set_clientptr_44bsd(FTS *sp, void static FTSENT * fts_build(FTS *sp, int type) { - struct dirent *dp; + struct freebsd11_dirent *dp; FTSENT *p, *head; int nitems; FTSENT *cur, *tail; @@ -738,7 +742,8 @@ fts_build(FTS *sp, int type) /* Read the directory, attaching each entry to the `link' pointer. */ doadjust = 0; - for (head = tail = NULL, nitems = 0; dirp && (dp = readdir(dirp));) { + for (head = tail = NULL, nitems = 0; + dirp && (dp = freebsd11_readdir(dirp));) { dnamlen = dp->d_namlen; if (!ISSET(FTS_SEEDOT) && ISDOT(dp->d_name)) continue; @@ -891,9 +896,9 @@ static u_short fts_stat(FTS *sp, FTSENT *p, int follow) { FTSENT *t; - dev_t dev; - ino_t ino; - struct stat *sbp, sb; + uint32_t dev; + uint32_t ino; + struct freebsd11_stat *sbp, sb; int saved_errno; /* If user needs stat info, stat buffer already allocated. */ @@ -916,16 +921,16 @@ fts_stat(FTS *sp, FTSENT *p, int follow) * fail, set the errno from the stat call. */ if (ISSET(FTS_LOGICAL) || follow) { - if (stat(p->fts_accpath, sbp)) { + if (freebsd11_stat(p->fts_accpath, sbp)) { saved_errno = errno; - if (!lstat(p->fts_accpath, sbp)) { + if (!freebsd11_lstat(p->fts_accpath, sbp)) { errno = 0; return (FTS_SLNONE); } p->fts_errno = saved_errno; goto err; } - } else if (lstat(p->fts_accpath, sbp)) { + } else if (freebsd11_lstat(p->fts_accpath, sbp)) { p->fts_errno = errno; err: memset(sbp, 0, sizeof(struct stat)); return (FTS_NS); @@ -1019,7 +1024,7 @@ fts_alloc(FTS *sp, char *name, int namel struct ftsent_withstat { FTSENT ent; - struct stat statbuf; + struct freebsd11_stat statbuf; }; /* @@ -1145,14 +1150,14 @@ static int fts_safe_changedir(FTS *sp, FTSENT *p, int fd, char *path) { int ret, oerrno, newfd; - struct stat sb; + struct freebsd11_stat sb; newfd = fd; if (ISSET(FTS_NOCHDIR)) return (0); if (fd < 0 && (newfd = _open(path, O_RDONLY | O_CLOEXEC, 0)) < 0) return (-1); - if (_fstat(newfd, &sb)) { + if (freebsd11_fstat(newfd, &sb)) { ret = -1; goto bail; } @@ -1187,7 +1192,7 @@ fts_ufslinks(FTS *sp, const FTSENT *ent) * avoidance. */ if (priv->ftsp_dev != ent->fts_dev) { - if (statfs(ent->fts_path, &priv->ftsp_statfs) != -1) { + if (freebsd11_statfs(ent->fts_path, &priv->ftsp_statfs) != -1) { priv->ftsp_dev = ent->fts_dev; priv->ftsp_linksreliable = 0; for (cpp = ufslike_filesystems; *cpp; cpp++) { Modified: head/lib/libc/gen/fts-compat.h ============================================================================== --- head/lib/libc/gen/fts-compat.h Tue May 23 09:20:31 2017 (r318735) +++ head/lib/libc/gen/fts-compat.h Tue May 23 09:29:05 2017 (r318736) @@ -37,7 +37,7 @@ typedef struct { struct _ftsent *fts_cur; /* current node */ struct _ftsent *fts_child; /* linked list of children */ struct _ftsent **fts_array; /* sort array */ - dev_t fts_dev; /* starting device # */ + uint32_t fts_dev; /* starting device # */ char *fts_path; /* path for this descent */ int fts_rfd; /* fd for root */ int fts_pathlen; /* sizeof(path) */ @@ -82,9 +82,9 @@ typedef struct _ftsent { u_short fts_pathlen; /* strlen(fts_path) */ u_short fts_namelen; /* strlen(fts_name) */ - ino_t fts_ino; /* inode */ - dev_t fts_dev; /* device */ - nlink_t fts_nlink; /* link count */ + uint32_t fts_ino; /* inode */ + uint32_t fts_dev; /* device */ + uint16_t fts_nlink; /* link count */ #define FTS_ROOTPARENTLEVEL -1 #define FTS_ROOTLEVEL 0 @@ -117,7 +117,7 @@ typedef struct _ftsent { #define FTS_SKIP 4 /* discard node */ u_short fts_instr; /* fts_set() instructions */ - struct stat *fts_statp; /* stat(2) information */ + struct freebsd11_stat *fts_statp; /* stat(2) information */ char *fts_name; /* file name */ FTS *fts_fts; /* back pointer to main FTS */ } FTSENT; Copied and modified: head/lib/libc/gen/fts-compat11.c (from r318735, head/lib/libc/gen/fts.c) ============================================================================== --- head/lib/libc/gen/fts.c Tue May 23 09:20:31 2017 (r318735, copy source) +++ head/lib/libc/gen/fts-compat11.c Tue May 23 09:29:05 2017 (r318736) @@ -26,7 +26,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $OpenBSD: fts.c,v 1.22 1999/10/03 19:22:22 millert Exp $ + * from: $OpenBSD: fts.c,v 1.22 1999/10/03 19:22:22 millert Exp $ */ #if 0 @@ -40,9 +40,12 @@ __FBSDID("$FreeBSD$"); #include "namespace.h" #include +#define _WANT_FREEBSD11_STATFS #include +#define _WANT_FREEBSD11_STAT #include +#define _WANT_FREEBSD11_DIRENT #include #include #include @@ -50,21 +53,23 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include "gen-compat.h" +#include "fts-compat11.h" #include "un-namespace.h" #include "gen-private.h" -static FTSENT *fts_alloc(FTS *, char *, size_t); -static FTSENT *fts_build(FTS *, int); -static void fts_lfree(FTSENT *); -static void fts_load(FTS *, FTSENT *); +static FTSENT11 *fts_alloc(FTS11 *, char *, size_t); +static FTSENT11 *fts_build(FTS11 *, int); +static void fts_lfree(FTSENT11 *); +static void fts_load(FTS11 *, FTSENT11 *); static size_t fts_maxarglen(char * const *); -static void fts_padjust(FTS *, FTSENT *); -static int fts_palloc(FTS *, size_t); -static FTSENT *fts_sort(FTS *, FTSENT *, size_t); -static int fts_stat(FTS *, FTSENT *, int, int); -static int fts_safe_changedir(FTS *, FTSENT *, int, char *); -static int fts_ufslinks(FTS *, const FTSENT *); +static void fts_padjust(FTS11 *, FTSENT11 *); +static int fts_palloc(FTS11 *, size_t); +static FTSENT11 *fts_sort(FTS11 *, FTSENT11 *, size_t); +static int fts_stat(FTS11 *, FTSENT11 *, int, int); +static int fts_safe_changedir(FTS11 *, FTSENT11 *, int, char *); +static int fts_ufslinks(FTS11 *, const FTSENT11 *); #define ISDOT(a) (a[0] == '.' && (!a[1] || (a[1] == '.' && !a[2]))) @@ -84,10 +89,10 @@ static int fts_ufslinks(FTS *, const FT * details. The FTS returned from fts_open points to this structure's * ftsp_fts member (and can be cast to an _fts_private as required) */ -struct _fts_private { - FTS ftsp_fts; - struct statfs ftsp_statfs; - dev_t ftsp_dev; +struct _fts_private11 { + FTS11 ftsp_fts; + struct freebsd11_statfs ftsp_statfs; + uint32_t ftsp_dev; int ftsp_linksreliable; }; @@ -108,14 +113,14 @@ static const char *ufslike_filesystems[] 0 }; -FTS * -fts_open(char * const *argv, int options, - int (*compar)(const FTSENT * const *, const FTSENT * const *)) +FTS11 * +freebsd11_fts_open(char * const *argv, int options, + int (*compar)(const FTSENT11 * const *, const FTSENT11 * const *)) { - struct _fts_private *priv; - FTS *sp; - FTSENT *p, *root; - FTSENT *parent, *tmp; + struct _fts_private11 *priv; + FTS11 *sp; + FTSENT11 *p, *root; + FTSENT11 *parent, *tmp; size_t len, nitems; /* Options check. */ @@ -221,7 +226,7 @@ mem1: free(sp); } static void -fts_load(FTS *sp, FTSENT *p) +fts_load(FTS11 *sp, FTSENT11 *p) { size_t len; char *cp; @@ -245,9 +250,9 @@ fts_load(FTS *sp, FTSENT *p) } int -fts_close(FTS *sp) +freebsd11_fts_close(FTS11 *sp) { - FTSENT *freep, *p; + FTSENT11 *freep, *p; int saved_errno; /* @@ -298,10 +303,10 @@ fts_close(FTS *sp) (p->fts_path[p->fts_pathlen - 1] == '/' \ ? p->fts_pathlen - 1 : p->fts_pathlen) -FTSENT * -fts_read(FTS *sp) +FTSENT11 * +freebsd11_fts_read(FTS11 *sp) { - FTSENT *p, *tmp; + FTSENT11 *p, *tmp; int instr; char *t; int saved_errno; @@ -497,7 +502,7 @@ name: t = sp->fts_path + NAPPEND(p->fts */ /* ARGSUSED */ int -fts_set(FTS *sp, FTSENT *p, int instr) +freebsd11_fts_set(FTS11 *sp, FTSENT11 *p, int instr) { if (instr != 0 && instr != FTS_AGAIN && instr != FTS_FOLLOW && instr != FTS_NOINSTR && instr != FTS_SKIP) { @@ -508,10 +513,10 @@ fts_set(FTS *sp, FTSENT *p, int instr) return (0); } -FTSENT * -fts_children(FTS *sp, int instr) +FTSENT11 * +freebsd11_fts_children(FTS11 *sp, int instr) { - FTSENT *p; + FTSENT11 *p; int fd, rc, serrno; if (instr != 0 && instr != FTS_NAMEONLY) { @@ -579,29 +584,29 @@ fts_children(FTS *sp, int instr) return (sp->fts_child); } -#ifndef fts_get_clientptr -#error "fts_get_clientptr not defined" +#ifndef freebsd11_fts_get_clientptr +#error "freebsd11_fts_get_clientptr not defined" #endif void * -(fts_get_clientptr)(FTS *sp) +(freebsd11_fts_get_clientptr)(FTS11 *sp) { - return (fts_get_clientptr(sp)); + return (freebsd11_fts_get_clientptr(sp)); } -#ifndef fts_get_stream -#error "fts_get_stream not defined" +#ifndef freebsd11_fts_get_stream +#error "freebsd11_fts_get_stream not defined" #endif -FTS * -(fts_get_stream)(FTSENT *p) +FTS11 * +(freebsd11_fts_get_stream)(FTSENT11 *p) { - return (fts_get_stream(p)); + return (freebsd11_fts_get_stream(p)); } void -fts_set_clientptr(FTS *sp, void *clientptr) +freebsd11_fts_set_clientptr(FTS11 *sp, void *clientptr) { sp->fts_clientptr = clientptr; @@ -621,12 +626,12 @@ fts_set_clientptr(FTS *sp, void *clientp * directories and for any files after the subdirectories in the directory have * been found, cutting the stat calls by about 2/3. */ -static FTSENT * -fts_build(FTS *sp, int type) +static FTSENT11 * +fts_build(FTS11 *sp, int type) { - struct dirent *dp; - FTSENT *p, *head; - FTSENT *cur, *tail; + struct freebsd11_dirent *dp; + FTSENT11 *p, *head; + FTSENT11 *cur, *tail; DIR *dirp; void *oldaddr; char *cp; @@ -736,7 +741,8 @@ fts_build(FTS *sp, int type) /* Read the directory, attaching each entry to the `link' pointer. */ doadjust = 0; - for (head = tail = NULL, nitems = 0; dirp && (dp = readdir(dirp));) { + for (head = tail = NULL, nitems = 0; + dirp && (dp = freebsd11_readdir(dirp));) { dnamlen = dp->d_namlen; if (!ISSET(FTS_SEEDOT) && ISDOT(dp->d_name)) continue; @@ -870,12 +876,12 @@ mem1: saved_errno = errno; } static int -fts_stat(FTS *sp, FTSENT *p, int follow, int dfd) +fts_stat(FTS11 *sp, FTSENT11 *p, int follow, int dfd) { - FTSENT *t; - dev_t dev; - ino_t ino; - struct stat *sbp, sb; + FTSENT11 *t; + uint32_t dev; + uint32_t ino; + struct freebsd11_stat *sbp, sb; int saved_errno; const char *path; @@ -904,9 +910,10 @@ fts_stat(FTS *sp, FTSENT *p, int follow, * fail, set the errno from the stat call. */ if (ISSET(FTS_LOGICAL) || follow) { - if (fstatat(dfd, path, sbp, 0)) { + if (freebsd11_fstatat(dfd, path, sbp, 0)) { saved_errno = errno; - if (fstatat(dfd, path, sbp, AT_SYMLINK_NOFOLLOW)) { + if (freebsd11_fstatat(dfd, path, sbp, + AT_SYMLINK_NOFOLLOW)) { p->fts_errno = saved_errno; goto err; } @@ -914,9 +921,9 @@ fts_stat(FTS *sp, FTSENT *p, int follow, if (S_ISLNK(sbp->st_mode)) return (FTS_SLNONE); } - } else if (fstatat(dfd, path, sbp, AT_SYMLINK_NOFOLLOW)) { + } else if (freebsd11_fstatat(dfd, path, sbp, AT_SYMLINK_NOFOLLOW)) { p->fts_errno = errno; -err: memset(sbp, 0, sizeof(struct stat)); +err: memset(sbp, 0, sizeof(*sbp)); return (FTS_NS); } @@ -965,16 +972,16 @@ err: memset(sbp, 0, sizeof(struct stat) static int fts_compar(const void *a, const void *b) { - FTS *parent; + FTS11 *parent; - parent = (*(const FTSENT * const *)a)->fts_fts; + parent = (*(const FTSENT11 * const *)a)->fts_fts; return (*parent->fts_compar)(a, b); } -static FTSENT * -fts_sort(FTS *sp, FTSENT *head, size_t nitems) +static FTSENT11 * +fts_sort(FTS11 *sp, FTSENT11 *head, size_t nitems) { - FTSENT **ap, *p; + FTSENT11 **ap, *p; /* * Construct an array of pointers to the structures and call qsort(3). @@ -986,29 +993,29 @@ fts_sort(FTS *sp, FTSENT *head, size_t n if (nitems > sp->fts_nitems) { sp->fts_nitems = nitems + 40; if ((sp->fts_array = reallocf(sp->fts_array, - sp->fts_nitems * sizeof(FTSENT *))) == NULL) { + sp->fts_nitems * sizeof(FTSENT11 *))) == NULL) { sp->fts_nitems = 0; return (head); } } for (ap = sp->fts_array, p = head; p; p = p->fts_link) *ap++ = p; - qsort(sp->fts_array, nitems, sizeof(FTSENT *), fts_compar); + qsort(sp->fts_array, nitems, sizeof(FTSENT11 *), fts_compar); for (head = *(ap = sp->fts_array); --nitems; ++ap) ap[0]->fts_link = ap[1]; ap[0]->fts_link = NULL; return (head); } -static FTSENT * -fts_alloc(FTS *sp, char *name, size_t namelen) +static FTSENT11 * +fts_alloc(FTS11 *sp, char *name, size_t namelen) { - FTSENT *p; + FTSENT11 *p; size_t len; - struct ftsent_withstat { - FTSENT ent; - struct stat statbuf; + struct ftsent11_withstat { + FTSENT11 ent; + struct freebsd11_stat statbuf; }; /* @@ -1018,9 +1025,9 @@ fts_alloc(FTS *sp, char *name, size_t na * be careful that the stat structure is reasonably aligned. */ if (ISSET(FTS_NOSTAT)) - len = sizeof(FTSENT) + namelen + 1; + len = sizeof(FTSENT11) + namelen + 1; else - len = sizeof(struct ftsent_withstat) + namelen + 1; + len = sizeof(struct ftsent11_withstat) + namelen + 1; if ((p = malloc(len)) == NULL) return (NULL); @@ -1029,8 +1036,8 @@ fts_alloc(FTS *sp, char *name, size_t na p->fts_name = (char *)(p + 1); p->fts_statp = NULL; } else { - p->fts_name = (char *)((struct ftsent_withstat *)p + 1); - p->fts_statp = &((struct ftsent_withstat *)p)->statbuf; + p->fts_name = (char *)((struct ftsent11_withstat *)p + 1); + p->fts_statp = &((struct ftsent11_withstat *)p)->statbuf; } /* Copy the name and guarantee NUL termination. */ @@ -1048,9 +1055,9 @@ fts_alloc(FTS *sp, char *name, size_t na } static void -fts_lfree(FTSENT *head) +fts_lfree(FTSENT11 *head) { - FTSENT *p; + FTSENT11 *p; /* Free a linked list of structures. */ while ((p = head)) { @@ -1066,7 +1073,7 @@ fts_lfree(FTSENT *head) * plus 256 bytes so don't realloc the path 2 bytes at a time. */ static int -fts_palloc(FTS *sp, size_t more) +fts_palloc(FTS11 *sp, size_t more) { sp->fts_pathlen += more + 256; @@ -1079,9 +1086,9 @@ fts_palloc(FTS *sp, size_t more) * already returned. */ static void -fts_padjust(FTS *sp, FTSENT *head) +fts_padjust(FTS11 *sp, FTSENT11 *head) { - FTSENT *p; + FTSENT11 *p; char *addr = sp->fts_path; #define ADJUST(p) do { \ @@ -1119,10 +1126,10 @@ fts_maxarglen(char * const *argv) * Assumes p->fts_dev and p->fts_ino are filled in. */ static int -fts_safe_changedir(FTS *sp, FTSENT *p, int fd, char *path) +fts_safe_changedir(FTS11 *sp, FTSENT11 *p, int fd, char *path) { int ret, oerrno, newfd; - struct stat sb; + struct freebsd11_stat sb; newfd = fd; if (ISSET(FTS_NOCHDIR)) @@ -1130,7 +1137,7 @@ fts_safe_changedir(FTS *sp, FTSENT *p, i if (fd < 0 && (newfd = _open(path, O_RDONLY | O_DIRECTORY | O_CLOEXEC, 0)) < 0) return (-1); - if (_fstat(newfd, &sb)) { + if (freebsd11_fstat(newfd, &sb)) { ret = -1; goto bail; } @@ -1152,12 +1159,12 @@ bail: * Check if the filesystem for "ent" has UFS-style links. */ static int -fts_ufslinks(FTS *sp, const FTSENT *ent) +fts_ufslinks(FTS11 *sp, const FTSENT11 *ent) { - struct _fts_private *priv; + struct _fts_private11 *priv; const char **cpp; - priv = (struct _fts_private *)sp; + priv = (struct _fts_private11 *)sp; /* * If this node's device is different from the previous, grab * the filesystem information, and decide on the reliability @@ -1165,7 +1172,7 @@ fts_ufslinks(FTS *sp, const FTSENT *ent) * avoidance. */ if (priv->ftsp_dev != ent->fts_dev) { - if (statfs(ent->fts_path, &priv->ftsp_statfs) != -1) { + if (freebsd11_statfs(ent->fts_path, &priv->ftsp_statfs) != -1) { priv->ftsp_dev = ent->fts_dev; priv->ftsp_linksreliable = 0; for (cpp = ufslike_filesystems; *cpp; cpp++) { @@ -1181,3 +1188,12 @@ fts_ufslinks(FTS *sp, const FTSENT *ent) } return (priv->ftsp_linksreliable); } + +__sym_compat(fts_open, freebsd11_fts_open, FBSD_1.1); +__sym_compat(fts_close, freebsd11_fts_close, FBSD_1.1); +__sym_compat(fts_read, freebsd11_fts_read, FBSD_1.1); +__sym_compat(fts_set, freebsd11_fts_set, FBSD_1.1); +__sym_compat(fts_children, freebsd11_fts_children, FBSD_1.1); +__sym_compat(fts_get_clientptr, freebsd11_fts_get_clientptr, FBSD_1.1); +__sym_compat(fts_get_stream, freebsd11_fts_get_stream, FBSD_1.1); +__sym_compat(fts_set_clientptr, freebsd11_fts_set_clientptr, FBSD_1.1); Copied and modified: head/lib/libc/gen/fts-compat11.h (from r318735, head/include/fts.h) ============================================================================== --- head/include/fts.h Tue May 23 09:20:31 2017 (r318735, copy source) +++ head/lib/libc/gen/fts-compat11.h Tue May 23 09:29:05 2017 (r318736) @@ -30,45 +30,30 @@ * $FreeBSD$ */ -#ifndef _FTS_H_ -#define _FTS_H_ - -#include +#ifndef _FTS_COPMAT11_H_ +#define _FTS_COPMAT11_H_ typedef struct { - struct _ftsent *fts_cur; /* current node */ - struct _ftsent *fts_child; /* linked list of children */ - struct _ftsent **fts_array; /* sort array */ - __dev_t fts_dev; /* starting device # */ + struct _ftsent11 *fts_cur; /* current node */ + struct _ftsent11 *fts_child; /* linked list of children */ + struct _ftsent11 **fts_array; /* sort array */ + uint32_t fts_dev; /* starting device # */ char *fts_path; /* path for this descent */ int fts_rfd; /* fd for root */ __size_t fts_pathlen; /* sizeof(path) */ __size_t fts_nitems; /* elements in the sort array */ int (*fts_compar) /* compare function */ - (const struct _ftsent * const *, const struct _ftsent * const *); - -#define FTS_COMFOLLOW 0x001 /* follow command line symlinks */ -#define FTS_LOGICAL 0x002 /* logical walk */ -#define FTS_NOCHDIR 0x004 /* don't change directories */ -#define FTS_NOSTAT 0x008 /* don't get stat info */ -#define FTS_PHYSICAL 0x010 /* physical walk */ -#define FTS_SEEDOT 0x020 /* return dot and dot-dot */ -#define FTS_XDEV 0x040 /* don't cross devices */ -#define FTS_WHITEOUT 0x080 /* return whiteout information */ -#define FTS_OPTIONMASK 0x0ff /* valid user option mask */ - -#define FTS_NAMEONLY 0x100 /* (private) child names only */ -#define FTS_STOP 0x200 /* (private) unrecoverable error */ + (const struct _ftsent11 * const *, + const struct _ftsent11 * const *); int fts_options; /* fts_open options, global flags */ void *fts_clientptr; /* thunk for sort function */ -} FTS; +} FTS11; -typedef struct _ftsent { - struct _ftsent *fts_cycle; /* cycle node */ - struct _ftsent *fts_parent; /* parent directory */ - struct _ftsent *fts_link; /* next file in directory */ +typedef struct _ftsent11 { + struct _ftsent11 *fts_cycle; /* cycle node */ + struct _ftsent11 *fts_parent; /* parent directory */ + struct _ftsent11 *fts_link; /* next file in directory */ long long fts_number; /* local numeric value */ -#define fts_bignum fts_number /* XXX non-std, should go away */ void *fts_pointer; /* local address value */ char *fts_accpath; /* access path */ char *fts_path; /* root path */ @@ -77,60 +62,34 @@ typedef struct _ftsent { __size_t fts_pathlen; /* strlen(fts_path) */ __size_t fts_namelen; /* strlen(fts_name) */ - __ino_t fts_ino; /* inode */ - __dev_t fts_dev; /* device */ - __nlink_t fts_nlink; /* link count */ + uint32_t fts_ino; /* inode */ + uint32_t fts_dev; /* device */ + uint16_t fts_nlink; /* link count */ -#define FTS_ROOTPARENTLEVEL -1 -#define FTS_ROOTLEVEL 0 long fts_level; /* depth (-1 to N) */ -#define FTS_D 1 /* preorder directory */ -#define FTS_DC 2 /* directory that causes cycles */ -#define FTS_DEFAULT 3 /* none of the above */ -#define FTS_DNR 4 /* unreadable directory */ -#define FTS_DOT 5 /* dot or dot-dot */ -#define FTS_DP 6 /* postorder directory */ -#define FTS_ERR 7 /* error; errno is set */ -#define FTS_F 8 /* regular file */ -#define FTS_INIT 9 /* initialized only */ -#define FTS_NS 10 /* stat(2) failed */ -#define FTS_NSOK 11 /* no stat(2) requested */ -#define FTS_SL 12 /* symbolic link */ -#define FTS_SLNONE 13 /* symbolic link without target */ -#define FTS_W 14 /* whiteout object */ int fts_info; /* user status for FTSENT structure */ -#define FTS_DONTCHDIR 0x01 /* don't chdir .. to the parent */ -#define FTS_SYMFOLLOW 0x02 /* followed a symlink to get here */ -#define FTS_ISW 0x04 /* this is a whiteout object */ unsigned fts_flags; /* private flags for FTSENT structure */ -#define FTS_AGAIN 1 /* read node again */ -#define FTS_FOLLOW 2 /* follow symbolic link */ -#define FTS_NOINSTR 3 /* no instructions */ -#define FTS_SKIP 4 /* discard node */ int fts_instr; /* fts_set() instructions */ *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Tue May 23 09:30:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A13AD7974E; Tue, 23 May 2017 09:30:44 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BF657110C; Tue, 23 May 2017 09:30:43 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N9UgsY028984; Tue, 23 May 2017 09:30:42 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N9Ug8w028978; Tue, 23 May 2017 09:30:42 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705230930.v4N9Ug8w028978@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 23 May 2017 09:30:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318737 - in head/sys: compat/freebsd32 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.23 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, 23 May 2017 09:30:44 -0000 Author: kib Date: Tue May 23 09:30:42 2017 New Revision: 318737 URL: https://svnweb.freebsd.org/changeset/base/318737 Log: Regen. Modified: head/sys/compat/freebsd32/freebsd32_proto.h head/sys/compat/freebsd32/freebsd32_syscall.h head/sys/compat/freebsd32/freebsd32_syscalls.c head/sys/compat/freebsd32/freebsd32_sysent.c head/sys/compat/freebsd32/freebsd32_systrace_args.c head/sys/kern/init_sysent.c head/sys/kern/syscalls.c head/sys/kern/systrace_args.c head/sys/sys/syscall.h head/sys/sys/syscall.mk head/sys/sys/sysproto.h Modified: head/sys/compat/freebsd32/freebsd32_proto.h ============================================================================== --- head/sys/compat/freebsd32/freebsd32_proto.h Tue May 23 09:29:05 2017 (r318736) +++ head/sys/compat/freebsd32/freebsd32_proto.h Tue May 23 09:30:42 2017 (r318737) @@ -161,24 +161,6 @@ struct freebsd32_shmsys_args { char a3_l_[PADL_(uint32_t)]; uint32_t a3; char a3_r_[PADR_(uint32_t)]; char a4_l_[PADL_(uint32_t)]; uint32_t a4; char a4_r_[PADR_(uint32_t)]; }; -struct freebsd32_stat_args { - char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; - char ub_l_[PADL_(struct stat32 *)]; struct stat32 * ub; char ub_r_[PADR_(struct stat32 *)]; -}; -struct freebsd32_fstat_args { - char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; - char ub_l_[PADL_(struct stat32 *)]; struct stat32 * ub; char ub_r_[PADR_(struct stat32 *)]; -}; -struct freebsd32_lstat_args { - char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; - char ub_l_[PADL_(struct stat32 *)]; struct stat32 * ub; char ub_r_[PADR_(struct stat32 *)]; -}; -struct freebsd32_getdirentries_args { - char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; - char buf_l_[PADL_(char *)]; char * buf; char buf_r_[PADR_(char *)]; - char count_l_[PADL_(u_int)]; u_int count; char count_r_[PADR_(u_int)]; - char basep_l_[PADL_(int32_t *)]; int32_t * basep; char basep_r_[PADR_(int32_t *)]; -}; struct freebsd32_sysctl_args { char name_l_[PADL_(int *)]; int * name; char name_r_[PADR_(int *)]; char namelen_l_[PADL_(u_int)]; u_int namelen; char namelen_r_[PADR_(u_int)]; @@ -551,12 +533,6 @@ struct freebsd32_fexecve_args { char argv_l_[PADL_(uint32_t *)]; uint32_t * argv; char argv_r_[PADR_(uint32_t *)]; char envv_l_[PADL_(uint32_t *)]; uint32_t * envv; char envv_r_[PADR_(uint32_t *)]; }; -struct freebsd32_fstatat_args { - char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; - char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; - char buf_l_[PADL_(struct stat *)]; struct stat * buf; char buf_r_[PADR_(struct stat *)]; - char flag_l_[PADL_(int)]; int flag; char flag_r_[PADR_(int)]; -}; struct freebsd32_futimesat_args { char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; @@ -697,6 +673,26 @@ struct freebsd32_utimensat_args { char times_l_[PADL_(struct timespec *)]; struct timespec * times; char times_r_[PADR_(struct timespec *)]; char flag_l_[PADL_(int)]; int flag; char flag_r_[PADR_(int)]; }; +struct freebsd32_fstat_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char ub_l_[PADL_(struct stat32 *)]; struct stat32 * ub; char ub_r_[PADR_(struct stat32 *)]; +}; +struct freebsd32_fstatat_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char buf_l_[PADL_(struct stat32 *)]; struct stat32 * buf; char buf_r_[PADR_(struct stat32 *)]; + char flag_l_[PADL_(int)]; int flag; char flag_r_[PADR_(int)]; +}; +struct freebsd32_fhstat_args { + char u_fhp_l_[PADL_(const struct fhandle *)]; const struct fhandle * u_fhp; char u_fhp_r_[PADR_(const struct fhandle *)]; + char sb_l_[PADL_(struct stat32 *)]; struct stat32 * sb; char sb_r_[PADR_(struct stat32 *)]; +}; +struct freebsd32_getdirentries_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char buf_l_[PADL_(char *)]; char * buf; char buf_r_[PADR_(char *)]; + char count_l_[PADL_(size_t)]; size_t count; char count_r_[PADR_(size_t)]; + char basep_l_[PADL_(int32_t *)]; int32_t * basep; char basep_r_[PADR_(int32_t *)]; +}; #if !defined(PAD64_REQUIRED) && (defined(__powerpc__) || defined(__mips__)) #define PAD64_REQUIRED #endif @@ -723,10 +719,6 @@ int freebsd32_sysarch(struct thread *, s int freebsd32_semsys(struct thread *, struct freebsd32_semsys_args *); int freebsd32_msgsys(struct thread *, struct freebsd32_msgsys_args *); int freebsd32_shmsys(struct thread *, struct freebsd32_shmsys_args *); -int freebsd32_stat(struct thread *, struct freebsd32_stat_args *); -int freebsd32_fstat(struct thread *, struct freebsd32_fstat_args *); -int freebsd32_lstat(struct thread *, struct freebsd32_lstat_args *); -int freebsd32_getdirentries(struct thread *, struct freebsd32_getdirentries_args *); int freebsd32_sysctl(struct thread *, struct freebsd32_sysctl_args *); int freebsd32_futimes(struct thread *, struct freebsd32_futimes_args *); int freebsd32_msgsnd(struct thread *, struct freebsd32_msgsnd_args *); @@ -800,7 +792,6 @@ int freebsd32_cpuset_getid(struct thread int freebsd32_cpuset_getaffinity(struct thread *, struct freebsd32_cpuset_getaffinity_args *); int freebsd32_cpuset_setaffinity(struct thread *, struct freebsd32_cpuset_setaffinity_args *); int freebsd32_fexecve(struct thread *, struct freebsd32_fexecve_args *); -int freebsd32_fstatat(struct thread *, struct freebsd32_fstatat_args *); int freebsd32_futimesat(struct thread *, struct freebsd32_futimesat_args *); int freebsd32_jail_get(struct thread *, struct freebsd32_jail_get_args *); int freebsd32_jail_set(struct thread *, struct freebsd32_jail_set_args *); @@ -828,6 +819,10 @@ int freebsd32_procctl(struct thread *, s int freebsd32_ppoll(struct thread *, struct freebsd32_ppoll_args *); int freebsd32_futimens(struct thread *, struct freebsd32_futimens_args *); int freebsd32_utimensat(struct thread *, struct freebsd32_utimensat_args *); +int freebsd32_fstat(struct thread *, struct freebsd32_fstat_args *); +int freebsd32_fstatat(struct thread *, struct freebsd32_fstatat_args *); +int freebsd32_fhstat(struct thread *, struct freebsd32_fhstat_args *); +int freebsd32_getdirentries(struct thread *, struct freebsd32_getdirentries_args *); #ifdef COMPAT_43 @@ -1132,7 +1127,82 @@ int freebsd10_freebsd32_pipe(struct thre #endif /* COMPAT_FREEBSD10 */ + +#ifdef COMPAT_FREEBSD11 + +#if !defined(PAD64_REQUIRED) && (defined(__powerpc__) || defined(__mips__)) +#define PAD64_REQUIRED +#endif +struct freebsd11_freebsd32_mknod_args { + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char mode_l_[PADL_(int)]; int mode; char mode_r_[PADR_(int)]; + char dev_l_[PADL_(int)]; int dev; char dev_r_[PADR_(int)]; +}; +struct freebsd11_freebsd32_stat_args { + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char ub_l_[PADL_(struct freebsd11_stat32 *)]; struct freebsd11_stat32 * ub; char ub_r_[PADR_(struct freebsd11_stat32 *)]; +}; +struct freebsd11_freebsd32_fstat_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char ub_l_[PADL_(struct freebsd11_stat32 *)]; struct freebsd11_stat32 * ub; char ub_r_[PADR_(struct freebsd11_stat32 *)]; +}; +struct freebsd11_freebsd32_lstat_args { + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char ub_l_[PADL_(struct freebsd11_stat32 *)]; struct freebsd11_stat32 * ub; char ub_r_[PADR_(struct freebsd11_stat32 *)]; +}; +struct freebsd11_freebsd32_getdirentries_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char buf_l_[PADL_(char *)]; char * buf; char buf_r_[PADR_(char *)]; + char count_l_[PADL_(u_int)]; u_int count; char count_r_[PADR_(u_int)]; + char basep_l_[PADL_(int32_t *)]; int32_t * basep; char basep_r_[PADR_(int32_t *)]; +}; +struct freebsd11_freebsd32_getdents_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char buf_l_[PADL_(char *)]; char * buf; char buf_r_[PADR_(char *)]; + char count_l_[PADL_(int)]; int count; char count_r_[PADR_(int)]; +}; +struct freebsd11_freebsd32_fhstat_args { + char u_fhp_l_[PADL_(const struct fhandle *)]; const struct fhandle * u_fhp; char u_fhp_r_[PADR_(const struct fhandle *)]; + char sb_l_[PADL_(struct freebsd11_stat32 *)]; struct freebsd11_stat32 * sb; char sb_r_[PADR_(struct freebsd11_stat32 *)]; +}; +#ifdef PAD64_REQUIRED +#else +#endif +#ifdef PAD64_REQUIRED +#else +#endif +struct freebsd11_freebsd32_fstatat_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char buf_l_[PADL_(struct freebsd11_stat32 *)]; struct freebsd11_stat32 * buf; char buf_r_[PADR_(struct freebsd11_stat32 *)]; + char flag_l_[PADL_(int)]; int flag; char flag_r_[PADR_(int)]; +}; +struct freebsd11_freebsd32_mknodat_args { + char fd_l_[PADL_(int)]; int fd; char fd_r_[PADR_(int)]; + char path_l_[PADL_(char *)]; char * path; char path_r_[PADR_(char *)]; + char mode_l_[PADL_(mode_t)]; mode_t mode; char mode_r_[PADR_(mode_t)]; + char dev_l_[PADL_(uint32_t)]; uint32_t dev; char dev_r_[PADR_(uint32_t)]; +}; +#ifdef PAD64_REQUIRED +#else +#endif +#ifdef PAD64_REQUIRED +#else +#endif +int freebsd11_freebsd32_mknod(struct thread *, struct freebsd11_freebsd32_mknod_args *); +int freebsd11_freebsd32_stat(struct thread *, struct freebsd11_freebsd32_stat_args *); +int freebsd11_freebsd32_fstat(struct thread *, struct freebsd11_freebsd32_fstat_args *); +int freebsd11_freebsd32_lstat(struct thread *, struct freebsd11_freebsd32_lstat_args *); +int freebsd11_freebsd32_getdirentries(struct thread *, struct freebsd11_freebsd32_getdirentries_args *); +int freebsd11_freebsd32_getdents(struct thread *, struct freebsd11_freebsd32_getdents_args *); +int freebsd11_freebsd32_fhstat(struct thread *, struct freebsd11_freebsd32_fhstat_args *); +int freebsd11_freebsd32_fstatat(struct thread *, struct freebsd11_freebsd32_fstatat_args *); +int freebsd11_freebsd32_mknodat(struct thread *, struct freebsd11_freebsd32_mknodat_args *); + +#endif /* COMPAT_FREEBSD11 */ + #define FREEBSD32_SYS_AUE_freebsd32_wait4 AUE_WAIT4 +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_mknod AUE_MKNOD #define FREEBSD32_SYS_AUE_freebsd4_freebsd32_getfsstat AUE_GETFSSTAT #define FREEBSD32_SYS_AUE_ofreebsd32_lseek AUE_LSEEK #define FREEBSD32_SYS_AUE_freebsd32_recvmsg AUE_RECVMSG @@ -1176,10 +1246,10 @@ int freebsd10_freebsd32_pipe(struct thre #define FREEBSD32_SYS_AUE_freebsd32_shmsys AUE_SHMSYS #define FREEBSD32_SYS_AUE_freebsd6_freebsd32_pread AUE_PREAD #define FREEBSD32_SYS_AUE_freebsd6_freebsd32_pwrite AUE_PWRITE -#define FREEBSD32_SYS_AUE_freebsd32_stat AUE_STAT -#define FREEBSD32_SYS_AUE_freebsd32_fstat AUE_FSTAT -#define FREEBSD32_SYS_AUE_freebsd32_lstat AUE_LSTAT -#define FREEBSD32_SYS_AUE_freebsd32_getdirentries AUE_GETDIRENTRIES +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_stat AUE_STAT +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_fstat AUE_FSTAT +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_lstat AUE_LSTAT +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_getdirentries AUE_GETDIRENTRIES #define FREEBSD32_SYS_AUE_freebsd6_freebsd32_mmap AUE_MMAP #define FREEBSD32_SYS_AUE_freebsd6_freebsd32_lseek AUE_LSEEK #define FREEBSD32_SYS_AUE_freebsd6_freebsd32_truncate AUE_TRUNCATE @@ -1203,10 +1273,12 @@ int freebsd10_freebsd32_pipe(struct thre #define FREEBSD32_SYS_AUE_freebsd32_aio_read AUE_AIO_READ #define FREEBSD32_SYS_AUE_freebsd32_aio_write AUE_AIO_WRITE #define FREEBSD32_SYS_AUE_freebsd32_lio_listio AUE_LIO_LISTIO +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_getdents AUE_O_GETDENTS #define FREEBSD32_SYS_AUE_freebsd32_lutimes AUE_LUTIMES #define FREEBSD32_SYS_AUE_freebsd32_preadv AUE_PREADV #define FREEBSD32_SYS_AUE_freebsd32_pwritev AUE_PWRITEV #define FREEBSD32_SYS_AUE_freebsd4_freebsd32_fhstatfs AUE_FHSTATFS +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_fhstat AUE_FHSTAT #define FREEBSD32_SYS_AUE_freebsd32_modstat AUE_NULL #define FREEBSD32_SYS_AUE_freebsd32_kldstat AUE_NULL #define FREEBSD32_SYS_AUE_freebsd32_aio_return AUE_AIO_RETURN @@ -1261,8 +1333,9 @@ int freebsd10_freebsd32_pipe(struct thre #define FREEBSD32_SYS_AUE_freebsd32_cpuset_getaffinity AUE_NULL #define FREEBSD32_SYS_AUE_freebsd32_cpuset_setaffinity AUE_NULL #define FREEBSD32_SYS_AUE_freebsd32_fexecve AUE_FEXECVE -#define FREEBSD32_SYS_AUE_freebsd32_fstatat AUE_FSTATAT +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_fstatat AUE_FSTATAT #define FREEBSD32_SYS_AUE_freebsd32_futimesat AUE_FUTIMESAT +#define FREEBSD32_SYS_AUE_freebsd11_freebsd32_mknodat AUE_MKNODAT #define FREEBSD32_SYS_AUE_freebsd32_jail_get AUE_JAIL_GET #define FREEBSD32_SYS_AUE_freebsd32_jail_set AUE_JAIL_SET #define FREEBSD32_SYS_AUE_freebsd32_semctl AUE_SEMCTL @@ -1283,6 +1356,10 @@ int freebsd10_freebsd32_pipe(struct thre #define FREEBSD32_SYS_AUE_freebsd32_ppoll AUE_POLL #define FREEBSD32_SYS_AUE_freebsd32_futimens AUE_FUTIMES #define FREEBSD32_SYS_AUE_freebsd32_utimensat AUE_FUTIMESAT +#define FREEBSD32_SYS_AUE_freebsd32_fstat AUE_FSTAT +#define FREEBSD32_SYS_AUE_freebsd32_fstatat AUE_FSTATAT +#define FREEBSD32_SYS_AUE_freebsd32_fhstat AUE_FHSTAT +#define FREEBSD32_SYS_AUE_freebsd32_getdirentries AUE_GETDIRENTRIES #undef PAD_ #undef PADL_ Modified: head/sys/compat/freebsd32/freebsd32_syscall.h ============================================================================== --- head/sys/compat/freebsd32/freebsd32_syscall.h Tue May 23 09:29:05 2017 (r318736) +++ head/sys/compat/freebsd32/freebsd32_syscall.h Tue May 23 09:30:42 2017 (r318737) @@ -19,7 +19,7 @@ /* 11 is obsolete execv */ #define FREEBSD32_SYS_chdir 12 #define FREEBSD32_SYS_fchdir 13 -#define FREEBSD32_SYS_mknod 14 +#define FREEBSD32_SYS_freebsd11_freebsd32_mknod 14 #define FREEBSD32_SYS_chmod 15 #define FREEBSD32_SYS_chown 16 #define FREEBSD32_SYS_break 17 @@ -171,14 +171,14 @@ #define FREEBSD32_SYS_setgid 181 #define FREEBSD32_SYS_setegid 182 #define FREEBSD32_SYS_seteuid 183 -#define FREEBSD32_SYS_freebsd32_stat 188 -#define FREEBSD32_SYS_freebsd32_fstat 189 -#define FREEBSD32_SYS_freebsd32_lstat 190 +#define FREEBSD32_SYS_freebsd11_freebsd32_stat 188 +#define FREEBSD32_SYS_freebsd11_freebsd32_fstat 189 +#define FREEBSD32_SYS_freebsd11_freebsd32_lstat 190 #define FREEBSD32_SYS_pathconf 191 #define FREEBSD32_SYS_fpathconf 192 #define FREEBSD32_SYS_getrlimit 194 #define FREEBSD32_SYS_setrlimit 195 -#define FREEBSD32_SYS_freebsd32_getdirentries 196 +#define FREEBSD32_SYS_freebsd11_freebsd32_getdirentries 196 /* 197 is freebsd6 freebsd32_mmap */ #define FREEBSD32_SYS___syscall 198 /* 199 is freebsd6 freebsd32_lseek */ @@ -224,19 +224,19 @@ #define FREEBSD32_SYS_freebsd32_aio_read 255 #define FREEBSD32_SYS_freebsd32_aio_write 256 #define FREEBSD32_SYS_freebsd32_lio_listio 257 -#define FREEBSD32_SYS_getdents 272 +#define FREEBSD32_SYS_freebsd11_freebsd32_getdents 272 #define FREEBSD32_SYS_lchmod 274 #define FREEBSD32_SYS_netbsd_lchown 275 #define FREEBSD32_SYS_freebsd32_lutimes 276 #define FREEBSD32_SYS_netbsd_msync 277 -#define FREEBSD32_SYS_nstat 278 -#define FREEBSD32_SYS_nfstat 279 -#define FREEBSD32_SYS_nlstat 280 +#define FREEBSD32_SYS_freebsd11_nstat 278 +#define FREEBSD32_SYS_freebsd11_nfstat 279 +#define FREEBSD32_SYS_freebsd11_nlstat 280 #define FREEBSD32_SYS_freebsd32_preadv 289 #define FREEBSD32_SYS_freebsd32_pwritev 290 /* 297 is freebsd4 freebsd32_fhstatfs */ #define FREEBSD32_SYS_fhopen 298 -#define FREEBSD32_SYS_fhstat 299 +#define FREEBSD32_SYS_freebsd11_freebsd32_fhstat 299 #define FREEBSD32_SYS_modnext 300 #define FREEBSD32_SYS_freebsd32_modstat 301 #define FREEBSD32_SYS_modfnext 302 @@ -310,10 +310,10 @@ #define FREEBSD32_SYS_lchflags 391 #define FREEBSD32_SYS_uuidgen 392 #define FREEBSD32_SYS_freebsd32_sendfile 393 -#define FREEBSD32_SYS_getfsstat 395 -#define FREEBSD32_SYS_statfs 396 -#define FREEBSD32_SYS_fstatfs 397 -#define FREEBSD32_SYS_fhstatfs 398 +#define FREEBSD32_SYS_freebsd11_getfsstat 395 +#define FREEBSD32_SYS_freebsd11_statfs 396 +#define FREEBSD32_SYS_freebsd11_fstatfs 397 +#define FREEBSD32_SYS_freebsd11_fhstatfs 398 #define FREEBSD32_SYS_ksem_close 400 #define FREEBSD32_SYS_ksem_post 401 #define FREEBSD32_SYS_ksem_wait 402 @@ -398,12 +398,12 @@ #define FREEBSD32_SYS_fchmodat 490 #define FREEBSD32_SYS_fchownat 491 #define FREEBSD32_SYS_freebsd32_fexecve 492 -#define FREEBSD32_SYS_freebsd32_fstatat 493 +#define FREEBSD32_SYS_freebsd11_freebsd32_fstatat 493 #define FREEBSD32_SYS_freebsd32_futimesat 494 #define FREEBSD32_SYS_linkat 495 #define FREEBSD32_SYS_mkdirat 496 #define FREEBSD32_SYS_mkfifoat 497 -#define FREEBSD32_SYS_mknodat 498 +#define FREEBSD32_SYS_freebsd11_freebsd32_mknodat 498 #define FREEBSD32_SYS_openat 499 #define FREEBSD32_SYS_readlinkat 500 #define FREEBSD32_SYS_renameat 501 @@ -458,4 +458,13 @@ #define FREEBSD32_SYS_numa_getaffinity 548 #define FREEBSD32_SYS_numa_setaffinity 549 #define FREEBSD32_SYS_fdatasync 550 -#define FREEBSD32_SYS_MAXSYSCALL 551 +#define FREEBSD32_SYS_freebsd32_fstat 551 +#define FREEBSD32_SYS_freebsd32_fstatat 552 +#define FREEBSD32_SYS_freebsd32_fhstat 553 +#define FREEBSD32_SYS_freebsd32_getdirentries 554 +#define FREEBSD32_SYS_statfs 555 +#define FREEBSD32_SYS_fstatfs 556 +#define FREEBSD32_SYS_getfsstat 557 +#define FREEBSD32_SYS_fhstatfs 558 +#define FREEBSD32_SYS_mknodat 559 +#define FREEBSD32_SYS_MAXSYSCALL 560 Modified: head/sys/compat/freebsd32/freebsd32_syscalls.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_syscalls.c Tue May 23 09:29:05 2017 (r318736) +++ head/sys/compat/freebsd32/freebsd32_syscalls.c Tue May 23 09:30:42 2017 (r318737) @@ -23,7 +23,7 @@ const char *freebsd32_syscallnames[] = { "obs_execv", /* 11 = obsolete execv */ "chdir", /* 12 = chdir */ "fchdir", /* 13 = fchdir */ - "mknod", /* 14 = mknod */ + "compat11.freebsd32_mknod", /* 14 = freebsd11 freebsd32_mknod */ "chmod", /* 15 = chmod */ "chown", /* 16 = chown */ "break", /* 17 = break */ @@ -197,15 +197,15 @@ const char *freebsd32_syscallnames[] = { "#185", /* 185 = lfs_markv */ "#186", /* 186 = lfs_segclean */ "#187", /* 187 = lfs_segwait */ - "freebsd32_stat", /* 188 = freebsd32_stat */ - "freebsd32_fstat", /* 189 = freebsd32_fstat */ - "freebsd32_lstat", /* 190 = freebsd32_lstat */ + "compat11.freebsd32_stat", /* 188 = freebsd11 freebsd32_stat */ + "compat11.freebsd32_fstat", /* 189 = freebsd11 freebsd32_fstat */ + "compat11.freebsd32_lstat", /* 190 = freebsd11 freebsd32_lstat */ "pathconf", /* 191 = pathconf */ "fpathconf", /* 192 = fpathconf */ "#193", /* 193 = nosys */ "getrlimit", /* 194 = getrlimit */ "setrlimit", /* 195 = setrlimit */ - "freebsd32_getdirentries", /* 196 = freebsd32_getdirentries */ + "compat11.freebsd32_getdirentries", /* 196 = freebsd11 freebsd32_getdirentries */ "compat6.freebsd32_mmap", /* 197 = freebsd6 freebsd32_mmap */ "__syscall", /* 198 = __syscall */ "compat6.freebsd32_lseek", /* 199 = freebsd6 freebsd32_lseek */ @@ -281,15 +281,15 @@ const char *freebsd32_syscallnames[] = { "#269", /* 269 = nosys */ "#270", /* 270 = nosys */ "#271", /* 271 = nosys */ - "getdents", /* 272 = getdents */ + "compat11.freebsd32_getdents", /* 272 = freebsd11 freebsd32_getdents */ "#273", /* 273 = nosys */ "lchmod", /* 274 = lchmod */ "netbsd_lchown", /* 275 = netbsd_lchown */ "freebsd32_lutimes", /* 276 = freebsd32_lutimes */ "netbsd_msync", /* 277 = netbsd_msync */ - "nstat", /* 278 = nstat */ - "nfstat", /* 279 = nfstat */ - "nlstat", /* 280 = nlstat */ + "compat11.nstat", /* 278 = freebsd11 nstat */ + "compat11.nfstat", /* 279 = freebsd11 nfstat */ + "compat11.nlstat", /* 280 = freebsd11 nlstat */ "#281", /* 281 = nosys */ "#282", /* 282 = nosys */ "#283", /* 283 = nosys */ @@ -308,7 +308,7 @@ const char *freebsd32_syscallnames[] = { "#296", /* 296 = nosys */ "compat4.freebsd32_fhstatfs", /* 297 = freebsd4 freebsd32_fhstatfs */ "fhopen", /* 298 = fhopen */ - "fhstat", /* 299 = fhstat */ + "compat11.freebsd32_fhstat", /* 299 = freebsd11 freebsd32_fhstat */ "modnext", /* 300 = modnext */ "freebsd32_modstat", /* 301 = freebsd32_modstat */ "modfnext", /* 302 = modfnext */ @@ -404,10 +404,10 @@ const char *freebsd32_syscallnames[] = { "uuidgen", /* 392 = uuidgen */ "freebsd32_sendfile", /* 393 = freebsd32_sendfile */ "#394", /* 394 = mac_syscall */ - "getfsstat", /* 395 = getfsstat */ - "statfs", /* 396 = statfs */ - "fstatfs", /* 397 = fstatfs */ - "fhstatfs", /* 398 = fhstatfs */ + "compat11.getfsstat", /* 395 = freebsd11 getfsstat */ + "compat11.statfs", /* 396 = freebsd11 statfs */ + "compat11.fstatfs", /* 397 = freebsd11 fstatfs */ + "compat11.fhstatfs", /* 398 = freebsd11 fhstatfs */ "#399", /* 399 = nosys */ "ksem_close", /* 400 = ksem_close */ "ksem_post", /* 401 = ksem_post */ @@ -515,12 +515,12 @@ const char *freebsd32_syscallnames[] = { "fchmodat", /* 490 = fchmodat */ "fchownat", /* 491 = fchownat */ "freebsd32_fexecve", /* 492 = freebsd32_fexecve */ - "freebsd32_fstatat", /* 493 = freebsd32_fstatat */ + "compat11.freebsd32_fstatat", /* 493 = freebsd11 freebsd32_fstatat */ "freebsd32_futimesat", /* 494 = freebsd32_futimesat */ "linkat", /* 495 = linkat */ "mkdirat", /* 496 = mkdirat */ "mkfifoat", /* 497 = mkfifoat */ - "mknodat", /* 498 = mknodat */ + "compat11.freebsd32_mknodat", /* 498 = freebsd11 freebsd32_mknodat */ "openat", /* 499 = openat */ "readlinkat", /* 500 = readlinkat */ "renameat", /* 501 = renameat */ @@ -583,4 +583,13 @@ const char *freebsd32_syscallnames[] = { "numa_getaffinity", /* 548 = numa_getaffinity */ "numa_setaffinity", /* 549 = numa_setaffinity */ "fdatasync", /* 550 = fdatasync */ + "freebsd32_fstat", /* 551 = freebsd32_fstat */ + "freebsd32_fstatat", /* 552 = freebsd32_fstatat */ + "freebsd32_fhstat", /* 553 = freebsd32_fhstat */ + "freebsd32_getdirentries", /* 554 = freebsd32_getdirentries */ + "statfs", /* 555 = statfs */ + "fstatfs", /* 556 = fstatfs */ + "getfsstat", /* 557 = getfsstat */ + "fhstatfs", /* 558 = fhstatfs */ + "mknodat", /* 559 = mknodat */ }; Modified: head/sys/compat/freebsd32/freebsd32_sysent.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_sysent.c Tue May 23 09:29:05 2017 (r318736) +++ head/sys/compat/freebsd32/freebsd32_sysent.c Tue May 23 09:30:42 2017 (r318737) @@ -47,6 +47,12 @@ #define compat10(n, name) 0, (sy_call_t *)nosys #endif +#ifdef COMPAT_FREEBSD11 +#define compat11(n, name) n, (sy_call_t *)__CONCAT(freebsd11_,name) +#else +#define compat11(n, name) 0, (sy_call_t *)nosys +#endif + /* The casts are bogus but will do for now. */ struct sysent freebsd32_sysent[] = { #if !defined(PAD64_REQUIRED) && (defined(__powerpc__) || defined(__mips__)) @@ -66,7 +72,7 @@ struct sysent freebsd32_sysent[] = { { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 11 = obsolete execv */ { AS(chdir_args), (sy_call_t *)sys_chdir, AUE_CHDIR, NULL, 0, 0, 0, SY_THR_STATIC }, /* 12 = chdir */ { AS(fchdir_args), (sy_call_t *)sys_fchdir, AUE_FCHDIR, NULL, 0, 0, 0, SY_THR_STATIC }, /* 13 = fchdir */ - { AS(mknod_args), (sy_call_t *)sys_mknod, AUE_MKNOD, NULL, 0, 0, 0, SY_THR_STATIC }, /* 14 = mknod */ + { compat11(AS(freebsd11_freebsd32_mknod_args),freebsd32_mknod), AUE_MKNOD, NULL, 0, 0, 0, SY_THR_STATIC }, /* 14 = freebsd11 freebsd32_mknod */ { AS(chmod_args), (sy_call_t *)sys_chmod, AUE_CHMOD, NULL, 0, 0, 0, SY_THR_STATIC }, /* 15 = chmod */ { AS(chown_args), (sy_call_t *)sys_chown, AUE_CHOWN, NULL, 0, 0, 0, SY_THR_STATIC }, /* 16 = chown */ { AS(obreak_args), (sy_call_t *)sys_obreak, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 17 = break */ @@ -240,15 +246,15 @@ struct sysent freebsd32_sysent[] = { { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 185 = lfs_markv */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 186 = lfs_segclean */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 187 = lfs_segwait */ - { AS(freebsd32_stat_args), (sy_call_t *)freebsd32_stat, AUE_STAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 188 = freebsd32_stat */ - { AS(freebsd32_fstat_args), (sy_call_t *)freebsd32_fstat, AUE_FSTAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 189 = freebsd32_fstat */ - { AS(freebsd32_lstat_args), (sy_call_t *)freebsd32_lstat, AUE_LSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 190 = freebsd32_lstat */ + { compat11(AS(freebsd11_freebsd32_stat_args),freebsd32_stat), AUE_STAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 188 = freebsd11 freebsd32_stat */ + { compat11(AS(freebsd11_freebsd32_fstat_args),freebsd32_fstat), AUE_FSTAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 189 = freebsd11 freebsd32_fstat */ + { compat11(AS(freebsd11_freebsd32_lstat_args),freebsd32_lstat), AUE_LSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 190 = freebsd11 freebsd32_lstat */ { AS(pathconf_args), (sy_call_t *)sys_pathconf, AUE_PATHCONF, NULL, 0, 0, 0, SY_THR_STATIC }, /* 191 = pathconf */ { AS(fpathconf_args), (sy_call_t *)sys_fpathconf, AUE_FPATHCONF, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 192 = fpathconf */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 193 = nosys */ { AS(__getrlimit_args), (sy_call_t *)sys_getrlimit, AUE_GETRLIMIT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 194 = getrlimit */ { AS(__setrlimit_args), (sy_call_t *)sys_setrlimit, AUE_SETRLIMIT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 195 = setrlimit */ - { AS(freebsd32_getdirentries_args), (sy_call_t *)freebsd32_getdirentries, AUE_GETDIRENTRIES, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 196 = freebsd32_getdirentries */ + { compat11(AS(freebsd11_freebsd32_getdirentries_args),freebsd32_getdirentries), AUE_GETDIRENTRIES, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 196 = freebsd11 freebsd32_getdirentries */ { compat6(AS(freebsd6_freebsd32_mmap_args),freebsd32_mmap), AUE_MMAP, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 197 = freebsd6 freebsd32_mmap */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 198 = __syscall */ { compat6(AS(freebsd6_freebsd32_lseek_args),freebsd32_lseek), AUE_LSEEK, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 199 = freebsd6 freebsd32_lseek */ @@ -324,15 +330,15 @@ struct sysent freebsd32_sysent[] = { { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 269 = nosys */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 270 = nosys */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 271 = nosys */ - { AS(getdents_args), (sy_call_t *)sys_getdents, AUE_O_GETDENTS, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 272 = getdents */ + { compat11(AS(freebsd11_freebsd32_getdents_args),freebsd32_getdents), AUE_O_GETDENTS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 272 = freebsd11 freebsd32_getdents */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 273 = nosys */ { AS(lchmod_args), (sy_call_t *)sys_lchmod, AUE_LCHMOD, NULL, 0, 0, 0, SY_THR_STATIC }, /* 274 = lchmod */ { AS(lchown_args), (sy_call_t *)sys_lchown, AUE_LCHOWN, NULL, 0, 0, 0, SY_THR_STATIC }, /* 275 = netbsd_lchown */ { AS(freebsd32_lutimes_args), (sy_call_t *)freebsd32_lutimes, AUE_LUTIMES, NULL, 0, 0, 0, SY_THR_STATIC }, /* 276 = freebsd32_lutimes */ { AS(msync_args), (sy_call_t *)sys_msync, AUE_MSYNC, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 277 = netbsd_msync */ - { AS(nstat_args), (sy_call_t *)sys_nstat, AUE_STAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 278 = nstat */ - { AS(nfstat_args), (sy_call_t *)sys_nfstat, AUE_FSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 279 = nfstat */ - { AS(nlstat_args), (sy_call_t *)sys_nlstat, AUE_LSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 280 = nlstat */ + { compat11(AS(freebsd11_nstat_args),nstat), AUE_STAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 278 = freebsd11 nstat */ + { compat11(AS(freebsd11_nfstat_args),nfstat), AUE_FSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 279 = freebsd11 nfstat */ + { compat11(AS(freebsd11_nlstat_args),nlstat), AUE_LSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 280 = freebsd11 nlstat */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 281 = nosys */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 282 = nosys */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 283 = nosys */ @@ -351,7 +357,7 @@ struct sysent freebsd32_sysent[] = { { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 296 = nosys */ { compat4(AS(freebsd4_freebsd32_fhstatfs_args),freebsd32_fhstatfs), AUE_FHSTATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 297 = freebsd4 freebsd32_fhstatfs */ { AS(fhopen_args), (sy_call_t *)sys_fhopen, AUE_FHOPEN, NULL, 0, 0, 0, SY_THR_STATIC }, /* 298 = fhopen */ - { AS(fhstat_args), (sy_call_t *)sys_fhstat, AUE_FHSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 299 = fhstat */ + { compat11(AS(freebsd11_freebsd32_fhstat_args),freebsd32_fhstat), AUE_FHSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 299 = freebsd11 freebsd32_fhstat */ { AS(modnext_args), (sy_call_t *)sys_modnext, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 300 = modnext */ { AS(freebsd32_modstat_args), (sy_call_t *)freebsd32_modstat, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 301 = freebsd32_modstat */ { AS(modfnext_args), (sy_call_t *)sys_modfnext, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 302 = modfnext */ @@ -447,10 +453,10 @@ struct sysent freebsd32_sysent[] = { { AS(uuidgen_args), (sy_call_t *)sys_uuidgen, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 392 = uuidgen */ { AS(freebsd32_sendfile_args), (sy_call_t *)freebsd32_sendfile, AUE_SENDFILE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 393 = freebsd32_sendfile */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 394 = mac_syscall */ - { AS(getfsstat_args), (sy_call_t *)sys_getfsstat, AUE_GETFSSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 395 = getfsstat */ - { AS(statfs_args), (sy_call_t *)sys_statfs, AUE_STATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 396 = statfs */ - { AS(fstatfs_args), (sy_call_t *)sys_fstatfs, AUE_FSTATFS, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 397 = fstatfs */ - { AS(fhstatfs_args), (sy_call_t *)sys_fhstatfs, AUE_FHSTATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 398 = fhstatfs */ + { compat11(AS(freebsd11_getfsstat_args),getfsstat), AUE_GETFSSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 395 = freebsd11 getfsstat */ + { compat11(AS(freebsd11_statfs_args),statfs), AUE_STATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 396 = freebsd11 statfs */ + { compat11(AS(freebsd11_fstatfs_args),fstatfs), AUE_FSTATFS, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 397 = freebsd11 fstatfs */ + { compat11(AS(freebsd11_fhstatfs_args),fhstatfs), AUE_FHSTATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 398 = freebsd11 fhstatfs */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 399 = nosys */ { AS(ksem_close_args), (sy_call_t *)lkmressys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 400 = ksem_close */ { AS(ksem_post_args), (sy_call_t *)lkmressys, AUE_NULL, NULL, 0, 0, 0, SY_THR_ABSENT }, /* 401 = ksem_post */ @@ -558,12 +564,12 @@ struct sysent freebsd32_sysent[] = { { AS(fchmodat_args), (sy_call_t *)sys_fchmodat, AUE_FCHMODAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 490 = fchmodat */ { AS(fchownat_args), (sy_call_t *)sys_fchownat, AUE_FCHOWNAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 491 = fchownat */ { AS(freebsd32_fexecve_args), (sy_call_t *)freebsd32_fexecve, AUE_FEXECVE, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 492 = freebsd32_fexecve */ - { AS(freebsd32_fstatat_args), (sy_call_t *)freebsd32_fstatat, AUE_FSTATAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 493 = freebsd32_fstatat */ + { compat11(AS(freebsd11_freebsd32_fstatat_args),freebsd32_fstatat), AUE_FSTATAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 493 = freebsd11 freebsd32_fstatat */ { AS(freebsd32_futimesat_args), (sy_call_t *)freebsd32_futimesat, AUE_FUTIMESAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 494 = freebsd32_futimesat */ { AS(linkat_args), (sy_call_t *)sys_linkat, AUE_LINKAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 495 = linkat */ { AS(mkdirat_args), (sy_call_t *)sys_mkdirat, AUE_MKDIRAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 496 = mkdirat */ { AS(mkfifoat_args), (sy_call_t *)sys_mkfifoat, AUE_MKFIFOAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 497 = mkfifoat */ - { AS(mknodat_args), (sy_call_t *)sys_mknodat, AUE_MKNODAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 498 = mknodat */ + { compat11(AS(freebsd11_freebsd32_mknodat_args),freebsd32_mknodat), AUE_MKNODAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 498 = freebsd11 freebsd32_mknodat */ { AS(openat_args), (sy_call_t *)sys_openat, AUE_OPENAT_RWTC, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 499 = openat */ { AS(readlinkat_args), (sy_call_t *)sys_readlinkat, AUE_READLINKAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 500 = readlinkat */ { AS(renameat_args), (sy_call_t *)sys_renameat, AUE_RENAMEAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 501 = renameat */ @@ -626,4 +632,13 @@ struct sysent freebsd32_sysent[] = { { AS(numa_getaffinity_args), (sy_call_t *)sys_numa_getaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 548 = numa_getaffinity */ { AS(numa_setaffinity_args), (sy_call_t *)sys_numa_setaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 549 = numa_setaffinity */ { AS(fdatasync_args), (sy_call_t *)sys_fdatasync, AUE_FSYNC, NULL, 0, 0, 0, SY_THR_STATIC }, /* 550 = fdatasync */ + { AS(freebsd32_fstat_args), (sy_call_t *)freebsd32_fstat, AUE_FSTAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 551 = freebsd32_fstat */ + { AS(freebsd32_fstatat_args), (sy_call_t *)freebsd32_fstatat, AUE_FSTATAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 552 = freebsd32_fstatat */ + { AS(freebsd32_fhstat_args), (sy_call_t *)freebsd32_fhstat, AUE_FHSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 553 = freebsd32_fhstat */ + { AS(freebsd32_getdirentries_args), (sy_call_t *)freebsd32_getdirentries, AUE_GETDIRENTRIES, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 554 = freebsd32_getdirentries */ + { AS(statfs_args), (sy_call_t *)sys_statfs, AUE_STATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 555 = statfs */ + { AS(fstatfs_args), (sy_call_t *)sys_fstatfs, AUE_FSTATFS, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 556 = fstatfs */ + { AS(getfsstat_args), (sy_call_t *)sys_getfsstat, AUE_GETFSSTAT, NULL, 0, 0, 0, SY_THR_STATIC }, /* 557 = getfsstat */ + { AS(fhstatfs_args), (sy_call_t *)sys_fhstatfs, AUE_FHSTATFS, NULL, 0, 0, 0, SY_THR_STATIC }, /* 558 = fhstatfs */ + { AS(mknodat_args), (sy_call_t *)sys_mknodat, AUE_MKNODAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 559 = mknodat */ }; Modified: head/sys/compat/freebsd32/freebsd32_systrace_args.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_systrace_args.c Tue May 23 09:29:05 2017 (r318736) +++ head/sys/compat/freebsd32/freebsd32_systrace_args.c Tue May 23 09:30:42 2017 (r318737) @@ -104,15 +104,6 @@ systrace_args(int sysnum, void *params, *n_args = 1; break; } - /* mknod */ - case 14: { - struct mknod_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - iarg[1] = p->mode; /* int */ - iarg[2] = p->dev; /* int */ - *n_args = 3; - break; - } /* chmod */ case 15: { struct chmod_args *p = params; @@ -914,30 +905,6 @@ systrace_args(int sysnum, void *params, *n_args = 1; break; } - /* freebsd32_stat */ - case 188: { - struct freebsd32_stat_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - uarg[1] = (intptr_t) p->ub; /* struct stat32 * */ - *n_args = 2; - break; - } - /* freebsd32_fstat */ - case 189: { - struct freebsd32_fstat_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->ub; /* struct stat32 * */ - *n_args = 2; - break; - } - /* freebsd32_lstat */ - case 190: { - struct freebsd32_lstat_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - uarg[1] = (intptr_t) p->ub; /* struct stat32 * */ - *n_args = 2; - break; - } /* pathconf */ case 191: { struct pathconf_args *p = params; @@ -970,16 +937,6 @@ systrace_args(int sysnum, void *params, *n_args = 2; break; } - /* freebsd32_getdirentries */ - case 196: { - struct freebsd32_getdirentries_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->buf; /* char * */ - uarg[2] = p->count; /* u_int */ - uarg[3] = (intptr_t) p->basep; /* int32_t * */ - *n_args = 4; - break; - } /* nosys */ case 198: { *n_args = 0; @@ -1334,15 +1291,6 @@ systrace_args(int sysnum, void *params, *n_args = 4; break; } - /* getdents */ - case 272: { - struct getdents_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->buf; /* char * */ - uarg[2] = p->count; /* size_t */ - *n_args = 3; - break; - } /* lchmod */ case 274: { struct lchmod_args *p = params; @@ -1377,30 +1325,6 @@ systrace_args(int sysnum, void *params, *n_args = 3; break; } - /* nstat */ - case 278: { - struct nstat_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - uarg[1] = (intptr_t) p->ub; /* struct nstat * */ - *n_args = 2; - break; - } - /* nfstat */ - case 279: { - struct nfstat_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->sb; /* struct nstat * */ - *n_args = 2; - break; - } - /* nlstat */ - case 280: { - struct nlstat_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - uarg[1] = (intptr_t) p->ub; /* struct nstat * */ - *n_args = 2; - break; - } /* freebsd32_preadv */ case 289: { struct freebsd32_preadv_args *p = params; @@ -1431,14 +1355,6 @@ systrace_args(int sysnum, void *params, *n_args = 2; break; } - /* fhstat */ - case 299: { - struct fhstat_args *p = params; - uarg[0] = (intptr_t) p->u_fhp; /* const struct fhandle * */ - uarg[1] = (intptr_t) p->sb; /* struct stat * */ - *n_args = 2; - break; - } /* modnext */ case 300: { struct modnext_args *p = params; @@ -1965,39 +1881,6 @@ systrace_args(int sysnum, void *params, *n_args = 8; break; } - /* getfsstat */ - case 395: { - struct getfsstat_args *p = params; - uarg[0] = (intptr_t) p->buf; /* struct statfs * */ - iarg[1] = p->bufsize; /* long */ - iarg[2] = p->mode; /* int */ - *n_args = 3; - break; - } - /* statfs */ - case 396: { - struct statfs_args *p = params; - uarg[0] = (intptr_t) p->path; /* char * */ - uarg[1] = (intptr_t) p->buf; /* struct statfs * */ - *n_args = 2; - break; - } - /* fstatfs */ - case 397: { - struct fstatfs_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->buf; /* struct statfs * */ - *n_args = 2; - break; - } - /* fhstatfs */ - case 398: { - struct fhstatfs_args *p = params; - uarg[0] = (intptr_t) p->u_fhp; /* const struct fhandle * */ - uarg[1] = (intptr_t) p->buf; /* struct statfs * */ - *n_args = 2; - break; - } /* ksem_close */ case 400: { struct ksem_close_args *p = params; @@ -2767,16 +2650,6 @@ systrace_args(int sysnum, void *params, *n_args = 3; break; } - /* freebsd32_fstatat */ - case 493: { - struct freebsd32_fstatat_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->path; /* char * */ - uarg[2] = (intptr_t) p->buf; /* struct stat * */ - iarg[3] = p->flag; /* int */ - *n_args = 4; - break; - } /* freebsd32_futimesat */ case 494: { struct freebsd32_futimesat_args *p = params; @@ -2815,16 +2688,6 @@ systrace_args(int sysnum, void *params, *n_args = 3; break; } - /* mknodat */ - case 498: { - struct mknodat_args *p = params; - iarg[0] = p->fd; /* int */ - uarg[1] = (intptr_t) p->path; /* char * */ - iarg[2] = p->mode; /* mode_t */ - iarg[3] = p->dev; /* dev_t */ - *n_args = 4; - break; - } /* openat */ case 499: { struct openat_args *p = params; @@ -3324,6 +3187,85 @@ systrace_args(int sysnum, void *params, *n_args = 1; break; } + /* freebsd32_fstat */ + case 551: { + struct freebsd32_fstat_args *p = params; + iarg[0] = p->fd; /* int */ + uarg[1] = (intptr_t) p->ub; /* struct stat32 * */ + *n_args = 2; + break; + } + /* freebsd32_fstatat */ + case 552: { + struct freebsd32_fstatat_args *p = params; + iarg[0] = p->fd; /* int */ + uarg[1] = (intptr_t) p->path; /* char * */ + uarg[2] = (intptr_t) p->buf; /* struct stat32 * */ + iarg[3] = p->flag; /* int */ + *n_args = 4; + break; + } + /* freebsd32_fhstat */ + case 553: { + struct freebsd32_fhstat_args *p = params; + uarg[0] = (intptr_t) p->u_fhp; /* const struct fhandle * */ + uarg[1] = (intptr_t) p->sb; /* struct stat32 * */ + *n_args = 2; + break; + } + /* freebsd32_getdirentries */ + case 554: { + struct freebsd32_getdirentries_args *p = params; + iarg[0] = p->fd; /* int */ + uarg[1] = (intptr_t) p->buf; /* char * */ + uarg[2] = p->count; /* size_t */ + uarg[3] = (intptr_t) p->basep; /* int32_t * */ + *n_args = 4; + break; + } + /* statfs */ + case 555: { + struct statfs_args *p = params; + uarg[0] = (intptr_t) p->path; /* char * */ + uarg[1] = (intptr_t) p->buf; /* struct statfs32 * */ + *n_args = 2; + break; + } + /* fstatfs */ + case 556: { + struct fstatfs_args *p = params; + iarg[0] = p->fd; /* int */ + uarg[1] = (intptr_t) p->buf; /* struct statfs32 * */ + *n_args = 2; + break; + } + /* getfsstat */ + case 557: { + struct getfsstat_args *p = params; + uarg[0] = (intptr_t) p->buf; /* struct statfs32 * */ + iarg[1] = p->bufsize; /* long */ + iarg[2] = p->mode; /* int */ + *n_args = 3; + break; + } + /* fhstatfs */ + case 558: { + struct fhstatfs_args *p = params; + uarg[0] = (intptr_t) p->u_fhp; /* const struct fhandle * */ + uarg[1] = (intptr_t) p->buf; /* struct statfs32 * */ + *n_args = 2; + break; + } + /* mknodat */ + case 559: { + struct mknodat_args *p = params; + iarg[0] = p->fd; /* int */ + uarg[1] = (intptr_t) p->path; /* char * */ + iarg[2] = p->mode; /* mode_t */ + iarg[3] = p->dev; /* dev_t */ + *n_args = 4; + break; + } default: *n_args = 0; break; @@ -3473,22 +3415,6 @@ systrace_entry_setargdesc(int sysnum, in break; }; break; - /* mknod */ - case 14: - switch(ndx) { - case 0: - p = "userland char *"; - break; - case 1: - p = "int"; - break; - case 2: - p = "int"; - break; - default: - break; - }; - break; /* chmod */ case 15: switch(ndx) { @@ -4792,45 +4718,6 @@ systrace_entry_setargdesc(int sysnum, in break; }; break; - /* freebsd32_stat */ - case 188: - switch(ndx) { - case 0: - p = "userland char *"; - break; - case 1: - p = "userland struct stat32 *"; - break; - default: - break; - }; - break; - /* freebsd32_fstat */ - case 189: - switch(ndx) { - case 0: - p = "int"; - break; - case 1: - p = "userland struct stat32 *"; - break; - default: - break; - }; - break; - /* freebsd32_lstat */ - case 190: - switch(ndx) { - case 0: - p = "userland char *"; - break; - case 1: - p = "userland struct stat32 *"; - break; - default: - break; - }; - break; /* pathconf */ case 191: switch(ndx) { @@ -4883,25 +4770,6 @@ systrace_entry_setargdesc(int sysnum, in break; }; break; - /* freebsd32_getdirentries */ - case 196: - switch(ndx) { - case 0: - p = "int"; - break; - case 1: - p = "userland char *"; - break; - case 2: - p = "u_int"; - break; - case 3: - p = "userland int32_t *"; - break; - default: - break; - }; - break; /* nosys */ case 198: break; @@ -5435,22 +5303,6 @@ systrace_entry_setargdesc(int sysnum, in break; }; break; - /* getdents */ - case 272: - switch(ndx) { - case 0: - p = "int"; - break; - case 1: - p = "userland char *"; - break; - case 2: - p = "size_t"; - break; - default: - break; - }; - break; /* lchmod */ case 274: switch(ndx) { @@ -5509,78 +5361,39 @@ systrace_entry_setargdesc(int sysnum, in break; }; break; - /* nstat */ - case 278: + /* freebsd32_preadv */ + case 289: switch(ndx) { case 0: - p = "userland char *"; + p = "int"; break; case 1: - p = "userland struct nstat *"; + p = "userland struct iovec32 *"; + break; + case 2: + p = "u_int"; + break; + case 3: + p = "uint32_t"; + break; + case 4: + p = "uint32_t"; break; default: break; }; break; - /* nfstat */ - case 279: + /* freebsd32_pwritev */ + case 290: switch(ndx) { case 0: p = "int"; break; case 1: - p = "userland struct nstat *"; + p = "userland struct iovec32 *"; break; - default: *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Tue May 23 09:32:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3604AD79803; Tue, 23 May 2017 09:32:28 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 11767155E; Tue, 23 May 2017 09:32:27 +0000 (UTC) (envelope-from ae@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4N9WRki032054; Tue, 23 May 2017 09:32:27 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4N9WQtT032050; Tue, 23 May 2017 09:32:26 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201705230932.v4N9WQtT032050@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Tue, 23 May 2017 09:32:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318738 - head/sys/netipsec 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.23 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, 23 May 2017 09:32:28 -0000 Author: ae Date: Tue May 23 09:32:26 2017 New Revision: 318738 URL: https://svnweb.freebsd.org/changeset/base/318738 Log: Fix possible double releasing for SA and SP references. There are two possible ways how crypto callback are called: directly from caller and deffered from crypto thread. For outbound packets the direct call chain is the following: IPSEC_OUTPUT() method -> ipsec[46]_common_output() -> -> ipsec[46]_perform_request() -> xform_output() -> -> crypto_dispatch() -> crypto_invoke() -> crypto_done() -> -> xform_output_cb() -> ipsec_process_done() -> ip[6]_output(). The SA and SP references are held while crypto processing is not finished. The error handling code wrongly expected that crypto callback always called from the crypto thread context, and it did references releasing in xform_output_cb(). But when the crypto callback called directly, in case of error the error handling code in ipsec[46]_perform_request() also did references releasing. To fix this, remove error handling from ipsec[46]_perform_request() and do it in xform_output() before crypto_dispatch(). MFC after: 10 days Modified: head/sys/netipsec/ipsec_output.c head/sys/netipsec/xform_ah.c head/sys/netipsec/xform_esp.c head/sys/netipsec/xform_ipcomp.c Modified: head/sys/netipsec/ipsec_output.c ============================================================================== --- head/sys/netipsec/ipsec_output.c Tue May 23 09:30:42 2017 (r318737) +++ head/sys/netipsec/ipsec_output.c Tue May 23 09:32:26 2017 (r318738) @@ -273,10 +273,6 @@ ipsec4_perform_request(struct mbuf *m, s goto bad; } error = (*sav->tdb_xform->xf_output)(m, sp, sav, idx, i, off); - if (error != 0) { - key_freesav(&sav); - key_freesp(&sp); - } return (error); bad: IPSECSTAT_INC(ips_out_inval); @@ -581,10 +577,6 @@ ipsec6_perform_request(struct mbuf *m, s goto bad; } error = (*sav->tdb_xform->xf_output)(m, sp, sav, idx, i, off); - if (error != 0) { - key_freesav(&sav); - key_freesp(&sp); - } return (error); bad: IPSEC6STAT_INC(ips_out_inval); Modified: head/sys/netipsec/xform_ah.c ============================================================================== --- head/sys/netipsec/xform_ah.c Tue May 23 09:30:42 2017 (r318737) +++ head/sys/netipsec/xform_ah.c Tue May 23 09:32:26 2017 (r318738) @@ -1049,6 +1049,8 @@ ah_output(struct mbuf *m, struct secpoli bad: if (m) m_freem(m); + key_freesav(&sav); + key_freesp(&sp); return (error); } Modified: head/sys/netipsec/xform_esp.c ============================================================================== --- head/sys/netipsec/xform_esp.c Tue May 23 09:30:42 2017 (r318737) +++ head/sys/netipsec/xform_esp.c Tue May 23 09:32:26 2017 (r318738) @@ -861,6 +861,8 @@ esp_output(struct mbuf *m, struct secpol bad: if (m) m_freem(m); + key_freesav(&sav); + key_freesp(&sp); return (error); } /* Modified: head/sys/netipsec/xform_ipcomp.c ============================================================================== --- head/sys/netipsec/xform_ipcomp.c Tue May 23 09:30:42 2017 (r318737) +++ head/sys/netipsec/xform_ipcomp.c Tue May 23 09:32:26 2017 (r318738) @@ -510,6 +510,8 @@ ipcomp_output(struct mbuf *m, struct sec bad: if (m) m_freem(m); + key_freesav(&sav); + key_freesp(&sp); return (error); } From owner-svn-src-head@freebsd.org Tue May 23 10:00:54 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 471C1D7A14B; Tue, 23 May 2017 10:00:54 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 22484123B; Tue, 23 May 2017 10:00:54 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NA0rUM040474; Tue, 23 May 2017 10:00:53 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NA0rQu040473; Tue, 23 May 2017 10:00:53 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705231000.v4NA0rQu040473@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 23 May 2017 10:00:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318739 - head/libexec/rtld-elf 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.23 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, 23 May 2017 10:00:54 -0000 Author: kib Date: Tue May 23 10:00:52 2017 New Revision: 318739 URL: https://svnweb.freebsd.org/changeset/base/318739 Log: For ld.so direct execution mode, implement -p option: search for the binary in $PATH. Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D10790 Modified: head/libexec/rtld-elf/rtld.c Modified: head/libexec/rtld-elf/rtld.c ============================================================================== --- head/libexec/rtld-elf/rtld.c Tue May 23 09:32:26 2017 (r318738) +++ head/libexec/rtld-elf/rtld.c Tue May 23 10:00:52 2017 (r318739) @@ -120,6 +120,7 @@ static void objlist_push_head(Objlist *, static void objlist_push_tail(Objlist *, Obj_Entry *); static void objlist_put_after(Objlist *, Obj_Entry *, Obj_Entry *); static void objlist_remove(Objlist *, Obj_Entry *); +static int open_binary_fd(const char *argv0, bool search_in_path); static int parse_args(char* argv[], int argc, bool *use_pathp, int *fdp); static int parse_integer(const char *); static void *path_enumerate(const char *, path_enum_proc, void *); @@ -439,12 +440,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ argv0 = argv[rtld_argc]; explicit_fd = (fd != -1); if (!explicit_fd) - fd = open(argv0, O_RDONLY | O_CLOEXEC | O_VERIFY); - if (fd == -1) { - rtld_printf("Opening %s: %s\n", argv0, - rtld_strerror(errno)); - rtld_die(); - } + fd = open_binary_fd(argv0, search_in_path); if (fstat(fd, &st) == -1) { _rtld_error("failed to fstat FD %d (%s): %s", fd, explicit_fd ? "user-provided descriptor" : argv0, @@ -5280,6 +5276,52 @@ symlook_init_from_req(SymLook *dst, cons dst->lockstate = src->lockstate; } +static int +open_binary_fd(const char *argv0, bool search_in_path) +{ + char *pathenv, *pe, binpath[PATH_MAX]; + int fd; + + if (search_in_path && strchr(argv0, '/') == NULL) { + pathenv = getenv("PATH"); + if (pathenv == NULL) { + rtld_printf("-p and no PATH environment variable\n"); + rtld_die(); + } + pathenv = strdup(pathenv); + if (pathenv == NULL) { + rtld_printf("Cannot allocate memory\n"); + rtld_die(); + } + fd = -1; + errno = ENOENT; + while ((pe = strsep(&pathenv, ":")) != NULL) { + if (strlcpy(binpath, pe, sizeof(binpath)) > + sizeof(binpath)) + continue; + if (binpath[0] != '\0' && + strlcat(binpath, "/", sizeof(binpath)) > + sizeof(binpath)) + continue; + if (strlcat(binpath, argv0, sizeof(binpath)) > + sizeof(binpath)) + continue; + fd = open(binpath, O_RDONLY | O_CLOEXEC | O_VERIFY); + if (fd != -1 || errno != ENOENT) + break; + } + free(pathenv); + } else { + fd = open(argv0, O_RDONLY | O_CLOEXEC | O_VERIFY); + } + + if (fd == -1) { + rtld_printf("Opening %s: %s\n", argv0, + rtld_strerror(errno)); + rtld_die(); + } + return (fd); +} /* * Parse a set of command-line arguments. @@ -5341,10 +5383,8 @@ parse_args(char* argv[], int argc, bool } *fdp = fd; break; - /* TODO: } else if (opt == 'p') { *use_pathp = true; - */ } else { rtld_printf("invalid argument: '%s'\n", arg); print_usage(argv[0]); @@ -5391,7 +5431,7 @@ print_usage(const char *argv0) "\n" "Options:\n" " -h Display this help message\n" - /* TODO: " -p Search in PATH for named binary\n" */ + " -p Search in PATH for named binary\n" " -f Execute instead of searching for \n" " -- End of RTLD options\n" " Name of process to execute\n" From owner-svn-src-head@freebsd.org Tue May 23 11:08:37 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3A98D79A45; Tue, 23 May 2017 11:08:37 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 912D71398; Tue, 23 May 2017 11:08:37 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NB8aNP068648; Tue, 23 May 2017 11:08:36 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NB8aSv068647; Tue, 23 May 2017 11:08:36 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201705231108.v4NB8aSv068647@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Tue, 23 May 2017 11:08:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318740 - head/share/examples 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.23 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, 23 May 2017 11:08:37 -0000 Author: trasz Date: Tue May 23 11:08:36 2017 New Revision: 318740 URL: https://svnweb.freebsd.org/changeset/base/318740 Log: Remove unneccessary call to mtree, which, when building as an unprivileged user (with -DNO_ROOT), resulted in warnings looking like these: share/man/cat8: user (9, 3819, not modified: Operation not permitted) permissions (0755, 0700, modified) The BSD.usr.mk is already taken care of in etc/Makefile. Submitted by: Alex Richardson Reviewed by: bdrewery MFC after: 1 month Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D9212 Modified: head/share/examples/Makefile Modified: head/share/examples/Makefile ============================================================================== --- head/share/examples/Makefile Tue May 23 10:00:52 2017 (r318739) +++ head/share/examples/Makefile Tue May 23 11:08:36 2017 (r318740) @@ -240,8 +240,6 @@ copies: rm -f ${DESTDIR}${BINDIR}/$i; \ fi .endfor - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} \ - -f ${SRCTOP}/etc/mtree/BSD.usr.dist -p ${DESTDIR}/usr .for file in ${XFILES} ${INSTALL} -T package=${PACKAGE_${file}:Uexamples} -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \ ${.CURDIR}/${file} ${DESTDIR}${BINDIR}/${file} From owner-svn-src-head@freebsd.org Tue May 23 12:00:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 13BB1D7ADE1; Tue, 23 May 2017 12:00:10 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D31E01BB2; Tue, 23 May 2017 12:00:09 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NC08Gn088695; Tue, 23 May 2017 12:00:08 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NC0833088694; Tue, 23 May 2017 12:00:08 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201705231200.v4NC0833088694@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Tue, 23 May 2017 12:00:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318741 - head/sys/mips/mips 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.23 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, 23 May 2017 12:00:10 -0000 Author: trasz Date: Tue May 23 12:00:08 2017 New Revision: 318741 URL: https://svnweb.freebsd.org/changeset/base/318741 Log: Remove superfluous parentheses. MFC after: 2 weeks Sponsored by: DARPA, AFRL Modified: head/sys/mips/mips/busdma_machdep.c Modified: head/sys/mips/mips/busdma_machdep.c ============================================================================== --- head/sys/mips/mips/busdma_machdep.c Tue May 23 11:08:36 2017 (r318740) +++ head/sys/mips/mips/busdma_machdep.c Tue May 23 12:00:08 2017 (r318741) @@ -759,7 +759,7 @@ _bus_dmamap_count_phys(bus_dma_tag_t dma bus_addr_t curaddr; bus_size_t sgsize; - if ((map->pagesneeded == 0)) { + if (map->pagesneeded == 0) { CTR3(KTR_BUSDMA, "lowaddr= %d, boundary= %d, alignment= %d", dmat->lowaddr, dmat->boundary, dmat->alignment); CTR2(KTR_BUSDMA, "map= %p, pagesneeded= %d", @@ -790,7 +790,7 @@ _bus_dmamap_count_pages(bus_dma_tag_t dm vm_offset_t vendaddr; bus_addr_t paddr; - if ((map->pagesneeded == 0)) { + if (map->pagesneeded == 0) { CTR3(KTR_BUSDMA, "lowaddr= %d, boundary= %d, alignment= %d", dmat->lowaddr, dmat->boundary, dmat->alignment); CTR2(KTR_BUSDMA, "map= %p, pagesneeded= %d", From owner-svn-src-head@freebsd.org Tue May 23 12:57:42 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 224E5D7A196; Tue, 23 May 2017 12:57:42 +0000 (UTC) (envelope-from andrew@fubar.geek.nz) Received: from fry.fubar.geek.nz (fry.fubar.geek.nz [139.59.165.16]) by mx1.freebsd.org (Postfix) with ESMTP id E441B1794; Tue, 23 May 2017 12:57:41 +0000 (UTC) (envelope-from andrew@fubar.geek.nz) Received: from dhcp-10-248-96-26.eduroam.wireless.private.cam.ac.uk (global-5-141.nat-2.net.cam.ac.uk [131.111.5.141]) by fry.fubar.geek.nz (Postfix) with ESMTPSA id 7992D4E6DB; Tue, 23 May 2017 12:57:39 +0000 (UTC) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: svn commit: r309749 - in head/sys: amd64/conf arm/conf conf i386/conf mips/conf pc98/conf powerpc/conf sparc64/conf From: Andrew Turner In-Reply-To: <201612091854.uB9IsCpN011656@repo.freebsd.org> Date: Tue, 23 May 2017 13:57:38 +0100 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: <0C6D4B91-128A-4918-9FB0-7F1556A97B12@fubar.geek.nz> References: <201612091854.uB9IsCpN011656@repo.freebsd.org> To: Mark Johnston X-Mailer: Apple Mail (2.3273) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 12:57:42 -0000 > On 9 Dec 2016, at 18:54, Mark Johnston wrote: >=20 > Author: markj > Date: Fri Dec 9 18:54:12 2016 > New Revision: 309749 > URL: https://svnweb.freebsd.org/changeset/base/309749 >=20 > Log: > Add a COMPAT_FREEBSD11 kernel option. >=20 > Use it wherever COMPAT_FREEBSD10 is currently specified. Why was this only added where COMPAT_FREEBSD10 was already used? We = added arm64 and riscv between 10 and 11 so neither have this option. Andrew From owner-svn-src-head@freebsd.org Tue May 23 13:57:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EA963D7A6A6; Tue, 23 May 2017 13:57:56 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B79F417E0; Tue, 23 May 2017 13:57:56 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NDvtsv038523; Tue, 23 May 2017 13:57:55 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NDvtGx038522; Tue, 23 May 2017 13:57:55 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705231357.v4NDvtGx038522@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 23 May 2017 13:57:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318744 - head/sys/arm64/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.23 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, 23 May 2017 13:57:57 -0000 Author: kib Date: Tue May 23 13:57:55 2017 New Revision: 318744 URL: https://svnweb.freebsd.org/changeset/base/318744 Log: Add COMPAT_FREEBSD11 on arm64, the arch is almost tier-1. Discussed with: andrew, emaste Sponsored by: The FreeBSD Foundation Modified: head/sys/arm64/conf/GENERIC Modified: head/sys/arm64/conf/GENERIC ============================================================================== --- head/sys/arm64/conf/GENERIC Tue May 23 12:40:50 2017 (r318743) +++ head/sys/arm64/conf/GENERIC Tue May 23 13:57:55 2017 (r318744) @@ -50,6 +50,7 @@ options PSEUDOFS # Pseudo-filesystem f options GEOM_PART_GPT # GUID Partition Tables. options GEOM_RAID # Soft RAID functionality. options GEOM_LABEL # Provides labelization +options COMPAT_FREEBSD11 # Compatible with FreeBSD11 options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI options KTRACE # ktrace(1) support options STACK # stack(9) support From owner-svn-src-head@freebsd.org Tue May 23 14:01:09 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3AC9FD7A889; Tue, 23 May 2017 14:01:09 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io0-x22f.google.com (mail-io0-x22f.google.com [IPv6:2607:f8b0:4001:c06::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0317C1BA8; Tue, 23 May 2017 14:01:09 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io0-x22f.google.com with SMTP id k91so97713780ioi.1; Tue, 23 May 2017 07:01:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=3o48eu4Ebo0X/7fXPz1xetsEphao7eNk+JC7RQq6vEQ=; b=r7XkZmUtL8rCeLeFs95Cy3mbfEqmqkf8BSDnYuXvH0D5UktBiSJ1MB3lHjC99mSTYC dLyHefY94S6Q3c/C4LNdz7LvqRza8HmLa2l336PwGoMz0hzj8f376RbZe6qV7JmY/p51 6UY9JuJZSAXhFyZOOKNQzeajzjLRtphnbXz8XWmX/7JDIUKdMwx0U2Ja4Gn9DmG10H/t YI3OBx0kX4iW1RYwOLZqNK67RapOFGcZ//lYxWo/sOKlngNM8HDGuKRPYW3RUpc7rJQQ 4jSCs0ImnvCQmRmhZzPodznvor+DvxSYgibmSOrTQITEl579PMJ2rjbGZuG75dali81B /Dng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=3o48eu4Ebo0X/7fXPz1xetsEphao7eNk+JC7RQq6vEQ=; b=CbavkC24jZrO6hk0tBJMJ/YqyWeV1ONVy5Uy/5lr4lO9gn5k/eWAz82zTCH2yAYU3K U1YhHc4U9tNqE9bn+zCSQbjzgVoe4yhUmWCwOhlMmM9X2/g9Umf1M4FISp8c0oBokXjD f9plY7dtc8f9KwRgt1rHSVI+fzdVWne8EEpsVavQiNtUryx2yCru5CiGToOyq5ix6APs 09cQ4vvw7Nd8dqTnR3B/bR9JPZBkwSgOkJ68W0c4rTcjeyUnNLZfAGqRZebvdxMr/3OA lLZAmCev8LqP+2COa287azfQjPslaV4PMhNXo0H/yknIAORDzUEaFyEYicoolOSv4vmX 38Rg== X-Gm-Message-State: AODbwcASFini/p+wg1FE5+D+B8ipo84ZpN8uBtskwu3ggB9m3TLwlCYi F6NCKiYALaalakxFgf7ypBIm+uY8q40vitU= X-Received: by 10.107.170.16 with SMTP id t16mr26264629ioe.113.1495548067077; Tue, 23 May 2017 07:01:07 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.169.201 with HTTP; Tue, 23 May 2017 07:00:46 -0700 (PDT) In-Reply-To: <201705230929.v4N9T5g1028124@repo.freebsd.org> References: <201705230929.v4N9T5g1028124@repo.freebsd.org> From: Ed Maste Date: Tue, 23 May 2017 10:00:46 -0400 X-Google-Sender-Auth: v6HPSJd9sFY8XP6jCvhP_w00SVo Message-ID: Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... To: Konstantin Belousov Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 14:01:09 -0000 On 23 May 2017 at 05:29, Konstantin Belousov wrote: > Author: kib > Date: Tue May 23 09:29:05 2017 > New Revision: 318736 > URL: https://svnweb.freebsd.org/changeset/base/318736 > > Update note: strictly follow the instructions in UPDATING. Build > and install the new kernel with COMPAT_FREEBSD11 option enabled, > then reboot, and only then install new world. There's been some confusion over this point, so let me clarify: this note refers to the regular upgrade procedure documented in UPDATING under the heading "To rebuild everything and install it on the current system". Following the regular, documented procedure is both necessary and sufficient for the ino64 change. It's mentioned explicitly here because folks often take shortcuts with updating (e.g. not rebooting), and such a shortcut will fail with the ino64 change. From owner-svn-src-head@freebsd.org Tue May 23 14:10:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 46829D7AD0C; Tue, 23 May 2017 14:10:44 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp004.me.com (mr11p00im-asmtp004.me.com [17.110.69.135]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 280721359; Tue, 23 May 2017 14:10:44 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp004.me.com by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OQE00F00S2JD200@mr11p00im-asmtp004.me.com>; Tue, 23 May 2017 14:10:31 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1495548631; bh=9Er4YjISgiYC5Jc7lYtF4Qp/grD1lxlcA7hzE52yDwg=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=u+Slni5a/fg4o2pinSN1BLdEHKJsZRjd/KabGae/Pf91ryVmzagXFkPAiXaNEUCnj IFZSm+04PJGVj4vByep0wTpR0e97XD37q0tPfM7q+sL97UVBlOPQ9f6AzMDDw2Z7hK Gs/ugcGYoOkiu3tyVks7msKM1y6wnV2vjyg4CVvZW9UKHQyI4ReMQc8xIxdVsNkkt7 HaGrjBpsGpsH/UD/XkHxUqcN72KahJll7C4oDiiO+rHnWrjLLa7ToPf7yg76yLjklJ 0VDQull+Fz0KrXFSq3DwDU+zVdXfslylpuIQ8O6S1wbyDYy2s0B8F8W1qNBpG8Aph9 nQOvC8dABDeBw== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OQE00OB6SPHK020@mr11p00im-asmtp004.me.com>; Tue, 23 May 2017 14:10:30 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-05-23_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1705230074 User-Agent: Microsoft-MacOutlook/f.21.0.170409 Date: Tue, 23 May 2017 07:10:29 -0700 Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... From: Ravi Pokala To: Ed Maste , Konstantin Belousov Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-id: <76949219-D46A-4D27-A331-1317A1410CD3@panasas.com> Thread-topic: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... References: <201705230929.v4N9T5g1028124@repo.freebsd.org> In-reply-to: MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 14:10:44 -0000 -----Original Message----- > From: on behalf of Ed Maste > Date: 2017-05-23, Tuesday at 07:00 > To: Konstantin Belousov > Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" > Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... > > On 23 May 2017 at 05:29, Konstantin Belousov wrote: >> Author: kib >> Date: Tue May 23 09:29:05 2017 >> New Revision: 318736 >> URL: https://svnweb.freebsd.org/changeset/base/318736 >> >> Update note: strictly follow the instructions in UPDATING. Build >> and install the new kernel with COMPAT_FREEBSD11 option enabled, >> then reboot, and only then install new world. > > There's been some confusion over this point, so let me clarify: this > note refers to the regular upgrade procedure documented in UPDATING > under the heading "To rebuild everything and install it on the current > system". Following the regular, documented procedure is both necessary > and sufficient for the ino64 change. > > It's mentioned explicitly here because folks often take shortcuts with > updating (e.g. not rebooting), and such a shortcut will fail with the >ino64 change. So then `tools/build/beinstall.sh' won't DTRT for this upgrade? -Ravi (rpokala@) From owner-svn-src-head@freebsd.org Tue May 23 14:17:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B97ACD7AFC3; Tue, 23 May 2017 14:17:12 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-it0-x22e.google.com (mail-it0-x22e.google.com [IPv6:2607:f8b0:4001:c0b::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 802C417A7; Tue, 23 May 2017 14:17:12 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-it0-x22e.google.com with SMTP id g126so20473583ith.0; Tue, 23 May 2017 07:17:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=uGRCPAi6WJZ0MRInwV412e5syz01u9ziwChujyiuPyo=; b=dvz2S1HYpwJevgaE7Uf0m4vq7/P5OBLGPNkFlN/Ehq30HD9HoMoxHhefWZFAXP8seF 5STUBCLN3dkcoex4ft9i4dpnVfEPO5q0irfAITdBPNY58uQ+ET4xDU1C0i1ViqLhDF5t LeLELKm6TJXhS8+OdCCG95K4yoI7aURLRh3LiSsq83G/BbS8v49vC2jmGDch2fPU5NF8 vzlE/uLSg2ZELXAHEZQgjk9TAMjbCFI+i5uZ29D7QS/rjonjlAkDKeJF/qWtdeSJDP6C 8NfDYBmouPy6heWnOFMY6KJQx/Y0km6bffaMtvhVaXIBF1lJUH0qZwmLyCpm9NM2Ca1P 2UHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=uGRCPAi6WJZ0MRInwV412e5syz01u9ziwChujyiuPyo=; b=NYDp9CkSXWUc26MMbpwqR2nZriuKBqUOQqZ9sFVRQ4UtlZhQNGF3GajkUv8Z4UtK0Q u9+v66G2sWCzbqmpIbn/Yp9ibdpjlzmZzQRoN4FbnLLY1Xl6KKXCx2fjHH12vpjwS9EF yD0mv3Ab39BiTMPkwiqjmPZ3/tamPpcoWiqJhVhEJ5LPnnpDT726tkgVSFH+OsEmqRBj uj2Q7m3gky8YcHglBwsYy0Qqhe0i3O9dtcsYLWlfhoIzCMlUUVPPFYE7Kw4/h6fQ8ZUk o6y+NvN4bNNuGNjvtlojS7urs9A/Dhss3RV0ENIaybIW8Pof0YfS68WQBYH4sDewMzRA YKuA== X-Gm-Message-State: AODbwcC2n5Topr3ntxZUN38DtyNuLI08qnnb/7hTEBu0MTTLP5EIBJdj 4HRdVa6k3OeFs0SJ5hxemQ/RNtoK8w== X-Received: by 10.36.192.195 with SMTP id u186mr3158540itf.88.1495549031874; Tue, 23 May 2017 07:17:11 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.169.201 with HTTP; Tue, 23 May 2017 07:16:51 -0700 (PDT) In-Reply-To: <76949219-D46A-4D27-A331-1317A1410CD3@panasas.com> References: <201705230929.v4N9T5g1028124@repo.freebsd.org> <76949219-D46A-4D27-A331-1317A1410CD3@panasas.com> From: Ed Maste Date: Tue, 23 May 2017 10:16:51 -0400 X-Google-Sender-Auth: 1xBEOWt4NvpZaNloPax1xymOOwE Message-ID: Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... To: Ravi Pokala Cc: Konstantin Belousov , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 14:17:12 -0000 On 23 May 2017 at 10:10, Ravi Pokala wrote: > > So then `tools/build/beinstall.sh' won't DTRT for this upgrade? This should be fine, because the new kernel and world get installed into a new boot environment, not over top of the existing system. The problem only occurs when installing a new userland while the older kernel is still running. From owner-svn-src-head@freebsd.org Tue May 23 14:30:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1B55DD7A3EE; Tue, 23 May 2017 14:30:27 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Received: from mail.madpilot.net (grunt.madpilot.net [78.47.145.38]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D1B131FFA; Tue, 23 May 2017 14:30:26 +0000 (UTC) (envelope-from madpilot@FreeBSD.org) Received: from mail (mail [192.168.254.3]) by mail.madpilot.net (Postfix) with ESMTP id 3wXHxQ2d4dzZt0; Tue, 23 May 2017 16:30:18 +0200 (CEST) Received: from mail.madpilot.net ([192.168.254.3]) by mail (mail.madpilot.net [192.168.254.3]) (amavisd-new, port 10024) with ESMTP id wOtxNNU-ml8V; Tue, 23 May 2017 16:30:16 +0200 (CEST) Received: from marvin.madpilot.net (micro.madpilot.net [88.149.173.206]) by mail.madpilot.net (Postfix) with ESMTPSA; Tue, 23 May 2017 16:30:16 +0200 (CEST) Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... To: Ed Maste , Ravi Pokala Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" , Konstantin Belousov References: <201705230929.v4N9T5g1028124@repo.freebsd.org> <76949219-D46A-4D27-A331-1317A1410CD3@panasas.com> From: Guido Falsi Message-ID: <66e9311a-edca-c9eb-b3bd-e983c9be619a@FreeBSD.org> Date: Tue, 23 May 2017 16:30:15 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 14:30:27 -0000 On 05/23/17 16:16, Ed Maste wrote: > On 23 May 2017 at 10:10, Ravi Pokala wrote: >> >> So then `tools/build/beinstall.sh' won't DTRT for this upgrade? > > This should be fine, because the new kernel and world get installed > into a new boot environment, not over top of the existing system. The > problem only occurs when installing a new userland while the older > kernel is still running. So people using packaged base should avoid doing a simple "pkg upgrade"(which IS a shortcut, I'm aware of that) but should upgrade the kernel package, reboot and then upgrade the rest? -- Guido Falsi From owner-svn-src-head@freebsd.org Tue May 23 14:34:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 30F96D7A69B; Tue, 23 May 2017 14:34:52 +0000 (UTC) (envelope-from ronald-lists@klop.ws) Received: from smarthost1.greenhost.nl (smarthost1.greenhost.nl [195.190.28.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EB5101577; Tue, 23 May 2017 14:34:51 +0000 (UTC) (envelope-from ronald-lists@klop.ws) Received: from smtp.greenhost.nl ([213.108.104.138]) by smarthost1.greenhost.nl with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1dDAek-0003eX-SU; Tue, 23 May 2017 16:19:27 +0200 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes To: "Konstantin Belousov" , "Ed Maste" Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... References: <201705230929.v4N9T5g1028124@repo.freebsd.org> Date: Tue, 23 May 2017 16:19:26 +0200 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Ronald Klop" Message-ID: In-Reply-To: User-Agent: Opera Mail/12.16 (FreeBSD) X-Authenticated-As-Hash: 398f5522cb258ce43cb679602f8cfe8b62a256d1 X-Virus-Scanned: by clamav at smarthost1.samage.net X-Spam-Level: / X-Spam-Score: -0.2 X-Spam-Status: No, score=-0.2 required=5.0 tests=ALL_TRUSTED, BAYES_50 autolearn=disabled version=3.4.0 X-Scan-Signature: 5a1627636b35b65657045ef62631cd80 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 14:34:52 -0000 On Tue, 23 May 2017 16:00:46 +0200, Ed Maste wrote: > On 23 May 2017 at 05:29, Konstantin Belousov wrote: >> Author: kib >> Date: Tue May 23 09:29:05 2017 >> New Revision: 318736 >> URL: https://svnweb.freebsd.org/changeset/base/318736 >> >> Update note: strictly follow the instructions in UPDATING. Build >> and install the new kernel with COMPAT_FREEBSD11 option enabled, >> then reboot, and only then install new world. > > There's been some confusion over this point, so let me clarify: this > note refers to the regular upgrade procedure documented in UPDATING > under the heading "To rebuild everything and install it on the current > system". Following the regular, documented procedure is both necessary > and sufficient for the ino64 change. > > It's mentioned explicitly here because folks often take shortcuts with > updating (e.g. not rebooting), and such a shortcut will fail with the > ino64 change. I read this in the commit log and my first thought was that it would help a lot of people if there was an extra entry in UPDATING mentioning the explicit need of the 'installkernel, reboot, installworld' order of the official procedure. A lot of people do not read the commits, but do follow UPDATING. BTW: The content of the commit is great work and I'm sure it will benefit future of FreeBSD! Cheers, Ronald. From owner-svn-src-head@freebsd.org Tue May 23 14:39:00 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BBB3AD7A8FF; Tue, 23 May 2017 14:39:00 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8C37118DB; Tue, 23 May 2017 14:39:00 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NEcxCi054872; Tue, 23 May 2017 14:38:59 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NEcxpK054871; Tue, 23 May 2017 14:38:59 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201705231438.v4NEcxpK054871@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 23 May 2017 14:38:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318745 - head/sys/contrib/ipfilter/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.23 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, 23 May 2017 14:39:00 -0000 Author: cy Date: Tue May 23 14:38:59 2017 New Revision: 318745 URL: https://svnweb.freebsd.org/changeset/base/318745 Log: Remove redundant variable declaration. MFC after: 3 days Modified: head/sys/contrib/ipfilter/netinet/ip_nat.c Modified: head/sys/contrib/ipfilter/netinet/ip_nat.c ============================================================================== --- head/sys/contrib/ipfilter/netinet/ip_nat.c Tue May 23 13:57:55 2017 (r318744) +++ head/sys/contrib/ipfilter/netinet/ip_nat.c Tue May 23 14:38:59 2017 (r318745) @@ -1677,10 +1677,6 @@ ipf_nat_siocdelnat(softc, softn, n, getl ipnat_t *n; int getlock; { -#ifdef IPF_NAT6 - int i; -#endif - if (getlock) { WRITE_ENTER(&softc->ipf_nat); } From owner-svn-src-head@freebsd.org Tue May 23 15:11:15 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 47D7FD7AE40; Tue, 23 May 2017 15:11:15 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp004.me.com (mr11p00im-asmtp004.me.com [17.110.69.135]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 282461EFA; Tue, 23 May 2017 15:11:15 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp004.me.com by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OQE00400VGD1B00@mr11p00im-asmtp004.me.com>; Tue, 23 May 2017 15:11:14 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1495552274; bh=ZAi7xRvXDvny8mYQgZ+I6TbNWoxmH3wh7YKS7muAmIo=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=L3bWGuYxT56hvlJXnqrKdk4+0Mw0DBGrzqYTO7QnVbJWV5YRfmL1hkdTALqeHTHwx XYBMg2J3+VpjhnXgDtyRaya/c8+mg2DF+mbIuM0eUe5b6Nw/4VbTw81QhBV+lYQjBf K4RQy6uHyviN4wiMrHKas556c4pGfOGniNBS/Zli6zBiFup0CKggWU1X/lY0mdxEHj 9UQkKp+U8i95ZxuU48AcknEEZEooNNfwhWkqH8oZE13gGYgcu0RZnG8JqzLiDn8RiR CBPu2IoSJMVf28FP8R1j2leTy+vCEIu4cLZwVFCyoQm47j7OxSNXCHGXaCMk5tZsKw PcSLMw/ODO7vg== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OQE0084TVIM9G00@mr11p00im-asmtp004.me.com>; Tue, 23 May 2017 15:11:12 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-05-23_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1705230079 User-Agent: Microsoft-MacOutlook/f.21.0.170409 Date: Tue, 23 May 2017 08:11:10 -0700 Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... From: Ravi Pokala To: Ed Maste Cc: Konstantin Belousov , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-id: Thread-topic: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... References: <201705230929.v4N9T5g1028124@repo.freebsd.org> <76949219-D46A-4D27-A331-1317A1410CD3@panasas.com> In-reply-to: MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 15:11:15 -0000 -----Original Message----- > From: on behalf of Ed Maste > Date: 2017-05-23, Tuesday at 07:16 > To: Ravi Pokala > Cc: Konstantin Belousov , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" > Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... > > On 23 May 2017 at 10:10, Ravi Pokala wrote: >> >> So then `tools/build/beinstall.sh' won't DTRT for this upgrade? > > This should be fine, because the new kernel and world get installed > into a new boot environment, not over top of the existing system. The > problem only occurs when installing a new userland while the older > kernel is still running. That's right, I'd forgotten how `beinstall.sh' did it's magic. Thanks for clarifying. -Ravi (rpokala@) From owner-svn-src-head@freebsd.org Tue May 23 15:13:24 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B368AD7A05C; Tue, 23 May 2017 15:13:24 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: from mail-oi0-x234.google.com (mail-oi0-x234.google.com [IPv6:2607:f8b0:4003:c06::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7718513B2; Tue, 23 May 2017 15:13:24 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: by mail-oi0-x234.google.com with SMTP id b204so205308507oii.1; Tue, 23 May 2017 08:13:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=UUSTbFHEvkNeJH19bP7az6Xe8uuIAbqE7elyn7cHNDY=; b=WtsSxrX6TlqcJKRMWQfR2uEOdWGLwuAQRkaRWrITjks3TI753Po/Y993+XNwW5g5DM xF/FKtQk59dB3PswN5bA9mHMlNzSpynD50TOmjJw+W4YmfjgU9tUFgJYhxNBK5Mpqs0t h4R9fMAE7JzUNbxrxGJwxK0oppsqUpN+ovJUwpP/IAVTRmwzwajg0tGkkjaub6j8RoeR cNk0FufdV4tHgF9H7GsaDvSsxzWjE3Te1OzxPFf06qdH78Pn9OyeGHwkYlFRVul/9/Z4 cQ2kKbGKMnOuCRJ9Q4fRAmp0yp/OwyoP9JjS6TPt953HA6gHT8e9cEUNBwPKQGTpia8S HrOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=UUSTbFHEvkNeJH19bP7az6Xe8uuIAbqE7elyn7cHNDY=; b=bK0ct4BhKGddaBjsrvtesVnR4+wN7GjIyAVyM0Uy/7boZSpTAqIbG6/gRoBFSaUOWZ +molvJq++jzGGhAt91o4LnPfAY9w4UsV69xgFZQCmL9vYNdK3glB/XOFm9QZbq/j+XEa 5K1WclTNPp4MQ/6l35CHdgkoBJJXW5nr/BjIGuZtOXeaaJNn4XX1oJbpy7jOfC6UZhQy vgNcR2l/EzqxdmsheihzHTEWNs1RICwUGn6JT673C9pgBLxu7zXXfKYh9dhqEqKV07qG uLZrNomKbYJZXCZIyOZZK37dVUIPVJi6Nn0mbqQkdV7IPic7ZbsDHDshbGnHVVr06iyi cpdA== X-Gm-Message-State: AODbwcBE7RupM5CTmFEyzAAo0AGPEpWci9tK3yiKct6ecXTy0bYEkZHI yYoy2YSzyvprHHeDX+Q3v+e0bnR3Zg== X-Received: by 10.157.60.58 with SMTP id q55mr2149225otc.31.1495552403632; Tue, 23 May 2017 08:13:23 -0700 (PDT) MIME-Version: 1.0 Received: by 10.182.20.163 with HTTP; Tue, 23 May 2017 08:13:23 -0700 (PDT) In-Reply-To: <201705230655.v4N6tpx0065768@repo.freebsd.org> References: <201705230655.v4N6tpx0065768@repo.freebsd.org> From: Benjamin Kaduk Date: Tue, 23 May 2017 10:13:23 -0500 Message-ID: Subject: Re: svn commit: r318699 - head/lib/libc/gen To: Ngie Cooper Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 15:13:24 -0000 On Tue, May 23, 2017 at 1:55 AM, Ngie Cooper wrote: > Author: ngie > Date: Tue May 23 06:55:51 2017 > New Revision: 318699 > URL: https://svnweb.freebsd.org/changeset/base/318699 > > Log: > directory(3): delete trailing whitespace and rewrite `E.g.` as `e.g.` > FWIW, it is better-still written as "e.g.,", i.e., with trailing comma as well as leading comma. -Ben From owner-svn-src-head@freebsd.org Tue May 23 15:46:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 333AED7ABA1; Tue, 23 May 2017 15:46:23 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 056EB14AA; Tue, 23 May 2017 15:46:22 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NFkMrF084972; Tue, 23 May 2017 15:46:22 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NFkMl2084971; Tue, 23 May 2017 15:46:22 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705231546.v4NFkMl2084971@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Tue, 23 May 2017 15:46:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318748 - head/tools/build/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.23 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, 23 May 2017 15:46:23 -0000 Author: gjb Date: Tue May 23 15:46:21 2017 New Revision: 318748 URL: https://svnweb.freebsd.org/changeset/base/318748 Log: Honor WITHOUT_TFTP for check-old* and delete-old* targets. Submitted by: philippe dot michel7 at sfr dot fr PR: 217949 MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Tue May 23 15:04:29 2017 (r318747) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Tue May 23 15:46:21 2017 (r318748) @@ -8653,6 +8653,13 @@ OLD_FILES+=usr/share/man/man1/colcrt.1.g OLD_FILES+=usr/share/man/man1/ul.1.gz .endif +.if ${MK_TFTP} == no +OLD_FILES+=usr/bin/tftp +OLD_FILES+=usr/libexec/tftpd +OLD_FILES+=usr/share/man/man1/tftp.1.gz +OLD_FILES+=usr/share/man/man8/tftpd.8.gz +.endif + .if ${MK_TIMED} == no OLD_FILES+=usr/sbin/timed OLD_FILES+=usr/sbin/timedc From owner-svn-src-head@freebsd.org Tue May 23 16:12:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48011D7AA00; Tue, 23 May 2017 16:12:52 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 08C5C1825; Tue, 23 May 2017 16:12:51 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NGCpAw097348; Tue, 23 May 2017 16:12:51 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NGCoR3097341; Tue, 23 May 2017 16:12:50 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705231612.v4NGCoR3097341@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 23 May 2017 16:12:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318749 - in head: include lib/libc/include lib/libthr/thread 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.23 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, 23 May 2017 16:12:52 -0000 Author: vangyzen Date: Tue May 23 16:12:50 2017 New Revision: 318749 URL: https://svnweb.freebsd.org/changeset/base/318749 Log: libthr: fix warnings from GCC when WARNS=6 Fix warnings about: - redundant declarations - a local variable shadowing a global function (dlinfo) - an old-style function definition (with an empty parameter list) - a variable that is possibly used uninitialized "make tinderbox" passes this time, except for a few unrelated kernel failures. Reviewed by: kib MFC after: 3 days Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10870 Modified: head/include/stdio.h head/lib/libc/include/libc_private.h head/lib/libthr/thread/thr_exit.c head/lib/libthr/thread/thr_kern.c head/lib/libthr/thread/thr_list.c head/lib/libthr/thread/thr_mutex.c head/lib/libthr/thread/thr_private.h Directory Properties: head/ (props changed) Modified: head/include/stdio.h ============================================================================== --- head/include/stdio.h Tue May 23 15:46:21 2017 (r318748) +++ head/include/stdio.h Tue May 23 16:12:50 2017 (r318749) @@ -464,7 +464,10 @@ static __inline int __sputc(int _c, FILE (*(p)->_p = (c), (int)*(p)->_p++)) #endif +#ifndef __LIBC_ISTHREADED_DECLARED +#define __LIBC_ISTHREADED_DECLARED extern int __isthreaded; +#endif #ifndef __cplusplus Modified: head/lib/libc/include/libc_private.h ============================================================================== --- head/lib/libc/include/libc_private.h Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libc/include/libc_private.h Tue May 23 16:12:50 2017 (r318749) @@ -42,7 +42,10 @@ * or more threads. It is used to avoid calling locking functions * when they are not required. */ +#ifndef __LIBC_ISTHREADED_DECLARED +#define __LIBC_ISTHREADED_DECLARED extern int __isthreaded; +#endif /* * Elf_Auxinfo *__elf_aux_vector, the pointer to the ELF aux vector Modified: head/lib/libthr/thread/thr_exit.c ============================================================================== --- head/lib/libthr/thread/thr_exit.c Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libthr/thread/thr_exit.c Tue May 23 16:12:50 2017 (r318749) @@ -46,8 +46,6 @@ __FBSDID("$FreeBSD$"); #include "libc_private.h" #include "thr_private.h" -void _pthread_exit(void *status); - static void exit_thread(void) __dead2; __weak_reference(_pthread_exit, pthread_exit); @@ -72,7 +70,7 @@ static void thread_uw_init(void) { static int inited = 0; - Dl_info dlinfo; + Dl_info dli; void *handle; void *forcedunwind, *getcfa; @@ -80,12 +78,12 @@ thread_uw_init(void) return; handle = RTLD_DEFAULT; if ((forcedunwind = dlsym(handle, "_Unwind_ForcedUnwind")) != NULL) { - if (dladdr(forcedunwind, &dlinfo)) { + if (dladdr(forcedunwind, &dli)) { /* * Make sure the address is always valid by holding the library, * also assume functions are in same library. */ - if ((handle = dlopen(dlinfo.dli_fname, RTLD_LAZY)) != NULL) { + if ((handle = dlopen(dli.dli_fname, RTLD_LAZY)) != NULL) { forcedunwind = dlsym(handle, "_Unwind_ForcedUnwind"); getcfa = dlsym(handle, "_Unwind_GetCFA"); if (forcedunwind != NULL && getcfa != NULL) { Modified: head/lib/libthr/thread/thr_kern.c ============================================================================== --- head/lib/libthr/thread/thr_kern.c Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libthr/thread/thr_kern.c Tue May 23 16:12:50 2017 (r318749) @@ -62,7 +62,7 @@ _thr_setthreaded(int threaded) } void -_thr_assert_lock_level() +_thr_assert_lock_level(void) { PANIC("locklevel <= 0"); } Modified: head/lib/libthr/thread/thr_list.c ============================================================================== --- head/lib/libthr/thread/thr_list.c Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libthr/thread/thr_list.c Tue May 23 16:12:50 2017 (r318749) @@ -35,8 +35,8 @@ __FBSDID("$FreeBSD$"); #include #include -#include "thr_private.h" #include "libc_private.h" +#include "thr_private.h" /*#define DEBUG_THREAD_LIST */ #ifdef DEBUG_THREAD_LIST Modified: head/lib/libthr/thread/thr_mutex.c ============================================================================== --- head/lib/libthr/thread/thr_mutex.c Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libthr/thread/thr_mutex.c Tue May 23 16:12:50 2017 (r318749) @@ -70,8 +70,6 @@ int __pthread_mutex_trylock(pthread_mute int __pthread_mutex_lock(pthread_mutex_t *mutex); int __pthread_mutex_timedlock(pthread_mutex_t *mutex, const struct timespec *abstime); -int _pthread_mutex_init_calloc_cb(pthread_mutex_t *mutex, - void *(calloc_cb)(size_t, size_t)); int _pthread_mutex_getspinloops_np(pthread_mutex_t *mutex, int *count); int _pthread_mutex_setspinloops_np(pthread_mutex_t *mutex, int count); int __pthread_mutex_setspinloops_np(pthread_mutex_t *mutex, int count); @@ -712,6 +710,7 @@ mutex_lock_common(struct pthread_mutex * struct pthread *curthread; int ret, robust; + robust = 0; /* pacify gcc */ curthread = _get_curthread(); if (!cvattach && m->m_flags & PMUTEX_FLAG_PRIVATE) THR_CRITICAL_ENTER(curthread); Modified: head/lib/libthr/thread/thr_private.h ============================================================================== --- head/lib/libthr/thread/thr_private.h Tue May 23 15:46:21 2017 (r318748) +++ head/lib/libthr/thread/thr_private.h Tue May 23 16:12:50 2017 (r318749) @@ -701,7 +701,10 @@ do { \ (curthr->report_events && \ (((curthr)->event_mask | _thread_event_mask ) & e) != 0) +#ifndef __LIBC_ISTHREADED_DECLARED +#define __LIBC_ISTHREADED_DECLARED extern int __isthreaded; +#endif /* * Global variables for the pthread kernel. @@ -835,8 +838,10 @@ int _sched_yield(void); void _pthread_cleanup_push(void (*)(void *), void *); void _pthread_cleanup_pop(int); void _pthread_exit_mask(void *status, sigset_t *mask) __dead2 __hidden; +#ifndef _LIBC_PRIVATE_H_ void _pthread_cancel_enter(int maycancel); void _pthread_cancel_leave(int maycancel); +#endif int _pthread_mutex_consistent(pthread_mutex_t * _Nonnull); int _pthread_mutexattr_getrobust(pthread_mutexattr_t * _Nonnull __restrict, int * _Nonnull __restrict); @@ -844,46 +849,56 @@ int _pthread_mutexattr_setrobust(pthread /* #include */ #ifdef _SYS_FCNTL_H_ +#ifndef _LIBC_PRIVATE_H_ int __sys_fcntl(int, int, ...); int __sys_openat(int, const char *, int, ...); -#endif +#endif /* _LIBC_PRIVATE_H_ */ +#endif /* _SYS_FCNTL_H_ */ /* #include */ #ifdef _SIGNAL_H_ int __sys_kill(pid_t, int); -int __sys_sigaction(int, const struct sigaction *, struct sigaction *); +int __sys_sigaltstack(const struct sigaltstack *, struct sigaltstack *); int __sys_sigpending(sigset_t *); +int __sys_sigreturn(const ucontext_t *); +#ifndef _LIBC_PRIVATE_H_ +int __sys_sigaction(int, const struct sigaction *, struct sigaction *); int __sys_sigprocmask(int, const sigset_t *, sigset_t *); int __sys_sigsuspend(const sigset_t *); -int __sys_sigreturn(const ucontext_t *); -int __sys_sigaltstack(const struct sigaltstack *, struct sigaltstack *); -int __sys_sigwait(const sigset_t *, int *); int __sys_sigtimedwait(const sigset_t *, siginfo_t *, const struct timespec *); +int __sys_sigwait(const sigset_t *, int *); int __sys_sigwaitinfo(const sigset_t *set, siginfo_t *info); -#endif +#endif /* _LIBC_PRIVATE_H_ */ +#endif /* _SYS_FCNTL_H_ */ /* #include */ #ifdef _TIME_H_ +#ifndef _LIBC_PRIVATE_H_ int __sys_clock_nanosleep(clockid_t, int, const struct timespec *, struct timespec *); int __sys_nanosleep(const struct timespec *, struct timespec *); -#endif +#endif /* _LIBC_PRIVATE_H_ */ +#endif /* _SYS_FCNTL_H_ */ /* #include */ #ifdef _SYS_UCONTEXT_H_ +#ifndef _LIBC_PRIVATE_H_ int __sys_setcontext(const ucontext_t *ucp); int __sys_swapcontext(ucontext_t *oucp, const ucontext_t *ucp); -#endif +#endif /* _LIBC_PRIVATE_H_ */ +#endif /* _SYS_FCNTL_H_ */ /* #include */ #ifdef _UNISTD_H_ +void __sys_exit(int); +pid_t __sys_getpid(void); +#ifndef _LIBC_PRIVATE_H_ int __sys_close(int); int __sys_fork(void); -pid_t __sys_getpid(void); ssize_t __sys_read(int, void *, size_t); -void __sys_exit(int); -#endif +#endif /* _LIBC_PRIVATE_H_ */ +#endif /* _SYS_FCNTL_H_ */ static inline int _thr_isthreaded(void) From owner-svn-src-head@freebsd.org Tue May 23 16:35:31 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C1428D7B312; Tue, 23 May 2017 16:35:31 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: from mail-qt0-x236.google.com (mail-qt0-x236.google.com [IPv6:2607:f8b0:400d:c0d::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 79D541645; Tue, 23 May 2017 16:35:31 +0000 (UTC) (envelope-from markjdb@gmail.com) Received: by mail-qt0-x236.google.com with SMTP id c13so132976054qtc.1; Tue, 23 May 2017 09:35:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=QBJ0FdVc5OanE2EV/hr623swwhR2RyRm0de0KiOqfPE=; b=OxF0Ghq/hnnYz8gJ3eouGne7Vaw6niUQ8FSivG2mLYVxLC67fLU9DmWZCXWMgrgfT6 cMeuCv8GoOuCcKPcdJe2jZXls3CWea1YU26vcmDgqpyNAc1vdoRBS8yFE9ezFCrCgp0V WWGfk1TwD2AOQr5r7ZF8zBqI2Iu326SeDxN+u6X3OFuPfy6uhVVECHQEHChl1A/G25Kc NnK9csmwmDdevhx/XvXQaGmMd28Ti2hUmIjCIgyxMw7ENG9xCTEKitTzAzPN4uOsmRpj PiZlmLBBWVJVzRGOWrBIroyKRKMijeGxgJnnCLuzVk3oDPdNdfkvcGsTDkLpcSVfidhr HTig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=QBJ0FdVc5OanE2EV/hr623swwhR2RyRm0de0KiOqfPE=; b=t6ly0Wb7HFy9M26AuueJHwDRlcaEp8hlej/p/oxqicDR9qtPO/vw9U8nFAQRC9/hGx EmNhVLjRO+n6j04S9cRC5Ur9zphFJBIHRTf75IgjLc7XpBbC+7yKA3X2dZn2afbfE3dD JSVWu+oLDiotXz4iRhEf8nLmBDXMcfRa5vRX6qGgWuC1hEvRlEQ+dtYEWADOu5toXvQ/ ZboJRYKNoc0ycxTD/EegDqxJd/8t1pZUZwKazN63NmlVXTQ2/tWa2Kw3eZNkBOFseStf RyKc9OQby/bmhr6QWmUqaQkoDDt7YrBxk8xQ7tx1bcBuOjPjb6PV06/S4wIqFNPtgWiu FISg== X-Gm-Message-State: AODbwcDutgUO+uTDxp2B+XXHBZXqHkGzSB/OdYQdcMDBFydD8ii/rsgr mingj20oLbuN1UeU X-Received: by 10.237.59.119 with SMTP id q52mr30779048qte.143.1495557330566; Tue, 23 May 2017 09:35:30 -0700 (PDT) Received: from wkstn-mjohnston.west.isilon.com (c-76-104-201-218.hsd1.wa.comcast.net. [76.104.201.218]) by smtp.gmail.com with ESMTPSA id q5sm755095qtb.52.2017.05.23.09.35.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 23 May 2017 09:35:29 -0700 (PDT) Sender: Mark Johnston Date: Tue, 23 May 2017 09:35:44 -0700 From: Mark Johnston To: Andrew Turner Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r309749 - in head/sys: amd64/conf arm/conf conf i386/conf mips/conf pc98/conf powerpc/conf sparc64/conf Message-ID: <20170523163544.GA12120@wkstn-mjohnston.west.isilon.com> References: <201612091854.uB9IsCpN011656@repo.freebsd.org> <0C6D4B91-128A-4918-9FB0-7F1556A97B12@fubar.geek.nz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <0C6D4B91-128A-4918-9FB0-7F1556A97B12@fubar.geek.nz> User-Agent: Mutt/1.8.2 (2017-04-18) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 16:35:31 -0000 On Tue, May 23, 2017 at 01:57:38PM +0100, Andrew Turner wrote: > > > On 9 Dec 2016, at 18:54, Mark Johnston wrote: > > > > Author: markj > > Date: Fri Dec 9 18:54:12 2016 > > New Revision: 309749 > > URL: https://svnweb.freebsd.org/changeset/base/309749 > > > > Log: > > Add a COMPAT_FREEBSD11 kernel option. > > > > Use it wherever COMPAT_FREEBSD10 is currently specified. > > Why was this only added where COMPAT_FREEBSD10 was already used? We added arm64 and riscv between 10 and 11 so neither have this option. No real reason, it was an oversight on my part. From owner-svn-src-head@freebsd.org Tue May 23 16:38:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6F4C9D7B3B7; Tue, 23 May 2017 16:38:12 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C62017CE; Tue, 23 May 2017 16:38:12 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NGcBP7005942; Tue, 23 May 2017 16:38:11 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NGcAq1005935; Tue, 23 May 2017 16:38:10 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201705231638.v4NGcAq1005935@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Tue, 23 May 2017 16:38:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318750 - in head/contrib: binutils/bfd binutils/ld binutils/ld/emulparams gcc gcc/config/s390 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.23 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, 23 May 2017 16:38:12 -0000 Author: pfg Date: Tue May 23 16:38:10 2017 New Revision: 318750 URL: https://svnweb.freebsd.org/changeset/base/318750 Log: Bring some rough support for FreeBSD S/390 to the GNU toolchain. This is no-op and only for reference: the S/390 port seems to be elusive in the BSDs so it is convenient to keep some trace from past efforts. It is likely newer attempts will focus on a newer toolchain using clang instead. Obtained from: Perforce depot/projects/s390 Added: head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh (contents, props changed) head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh (contents, props changed) head/contrib/gcc/config/s390/freebsd.h - copied, changed from r318546, head/contrib/gcc/config/s390/linux.h Modified: head/contrib/binutils/bfd/config.bfd head/contrib/binutils/ld/configure.tgt head/contrib/gcc/config.gcc Modified: head/contrib/binutils/bfd/config.bfd ============================================================================== --- head/contrib/binutils/bfd/config.bfd Tue May 23 16:12:50 2017 (r318749) +++ head/contrib/binutils/bfd/config.bfd Tue May 23 16:38:10 2017 (r318750) @@ -1156,13 +1156,13 @@ case "${targ}" in targ_selvecs="bfd_powerpcle_pei_vec bfd_powerpc_pei_vec bfd_powerpcle_pe_vec bfd_powerpc_pe_vec" ;; - s390-*-linux*) + s390-*-freebsd* | s390-*-linux*) targ_defvec=bfd_elf32_s390_vec targ64_selvecs=bfd_elf64_s390_vec want64=true ;; #ifdef BFD64 - s390x-*-linux*) + s390x-*-freebsd* | s390x-*-linux*) targ_defvec=bfd_elf64_s390_vec targ_selvecs=bfd_elf32_s390_vec want64=true Modified: head/contrib/binutils/ld/configure.tgt ============================================================================== --- head/contrib/binutils/ld/configure.tgt Tue May 23 16:12:50 2017 (r318749) +++ head/contrib/binutils/ld/configure.tgt Tue May 23 16:38:10 2017 (r318750) @@ -480,12 +480,21 @@ powerpc-*-lynxos*) targ_emul=ppclynx ;; rs6000-*-aix5*) targ_emul=aix5rs6 ;; rs6000-*-aix*) targ_emul=aixrs6 ;; +s390x-*-freebsd*) targ_emul=elf64_s390 + targ_extra_emuls=elf_s390 + targ_extra_libpath=$targ_extra_emuls + tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; s390x-*-linux*) targ_emul=elf64_s390 targ_extra_emuls=elf_s390 targ_extra_libpath=$targ_extra_emuls tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; s390x-*-tpf*) targ_emul=elf64_s390 tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; +s390-*-freebsd*) targ_emul=elf_s390 + targ64_extra_emuls=elf64_s390 + targ64_extra_libpath=elf64_s390 + tdir_elf64_s390=`echo ${targ_alias} | sed -e 's/s390/s390x/'` + ;; s390-*-linux*) targ_emul=elf_s390 targ64_extra_emuls=elf64_s390 targ64_extra_libpath=elf64_s390 Added: head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh Tue May 23 16:38:10 2017 (r318750) @@ -0,0 +1,2 @@ +. ${srcdir}/emulparams/elf64_s390.sh +. ${srcdir}/emulparams/elf_fbsd.sh Added: head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh Tue May 23 16:38:10 2017 (r318750) @@ -0,0 +1,2 @@ +. ${srcdir}/emulparams/elf_s390.sh +. ${srcdir}/emulparams/elf_fbsd.sh Modified: head/contrib/gcc/config.gcc ============================================================================== --- head/contrib/gcc/config.gcc Tue May 23 16:12:50 2017 (r318749) +++ head/contrib/gcc/config.gcc Tue May 23 16:38:10 2017 (r318750) @@ -1942,10 +1942,19 @@ rs6000-ibm-aix[56789].* | powerpc-ibm-ai thread_file='aix' extra_headers= ;; +s390-*-freebsd*) + tm_file="${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} s390/freebsd.h" + ;; s390-*-linux*) tm_file="s390/s390.h dbxelf.h elfos.h svr4.h linux.h s390/linux.h" tmake_file="${tmake_file} t-dfprules s390/t-crtstuff s390/t-linux" ;; +s390x-*-freebsd*) + tm_file="s390/s390.h s390/s390x.h dbxelf.h elfos.h ${fbsd_tm_file} s390/freebsd.h" + tm_p_file=s390/s390-protos.h + md_file=s390/s390.md + out_file=s390/s390.c + ;; s390x-*-linux*) tm_file="s390/s390x.h s390/s390.h dbxelf.h elfos.h svr4.h linux.h s390/linux.h" tm_p_file=s390/s390-protos.h Copied and modified: head/contrib/gcc/config/s390/freebsd.h (from r318546, head/contrib/gcc/config/s390/linux.h) ============================================================================== --- head/contrib/gcc/config/s390/linux.h Fri May 19 17:14:29 2017 (r318546, copy source) +++ head/contrib/gcc/config/s390/freebsd.h Tue May 23 16:38:10 2017 (r318750) @@ -1,4 +1,4 @@ -/* Definitions for Linux for S/390. +/* Definitions for FreeBSD for S/390. Copyright (C) 1999, 2000, 2001, 2002, 2004, 2005, 2006 Free Software Foundation, Inc. Contributed by Hartmut Penner (hpenner@de.ibm.com) and @@ -21,25 +21,26 @@ along with GCC; see the file COPYING. I Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#ifndef _LINUX_H -#define _LINUX_H +#ifndef _CONFIG_S390_FREEBSD_H +#define _CONFIG_S390_FREEBSD_H /* Target specific version string. */ #ifdef DEFAULT_TARGET_64BIT #undef TARGET_VERSION -#define TARGET_VERSION fprintf (stderr, " (Linux for zSeries)"); +#define TARGET_VERSION fprintf (stderr, " (FreeBSD for zSeries)"); #else #undef TARGET_VERSION -#define TARGET_VERSION fprintf (stderr, " (Linux for S/390)"); +#define TARGET_VERSION fprintf (stderr, " (FreeBSD for S/390)"); #endif /* Target specific type definitions. */ /* ??? Do we really want long as size_t on 31-bit? */ +/* Answer is yes for FreeBSD. */ #undef SIZE_TYPE -#define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "long unsigned int") +#define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "unsigned int") #undef PTRDIFF_TYPE #define PTRDIFF_TYPE (TARGET_64BIT ? "long int" : "int") @@ -48,16 +49,8 @@ Software Foundation, 51 Franklin Street, #undef WCHAR_TYPE_SIZE #define WCHAR_TYPE_SIZE 32 - -/* Target specific preprocessor settings. */ - -#define TARGET_OS_CPP_BUILTINS() \ - do \ - { \ - LINUX_TARGET_OS_CPP_BUILTINS(); \ - } \ - while (0) - +#undef DEFAULT_SIGNED_CHAR +#define DEFAULT_SIGNED_CHAR 1 /* Target specific assembler settings. */ @@ -92,7 +85,7 @@ Software Foundation, 51 Franklin Street, #define TARGET_ASM_FILE_END file_end_indicate_exec_stack -#define MD_UNWIND_SUPPORT "config/s390/linux-unwind.h" +#define MD_UNWIND_SUPPORT "config/s390/freebsd-unwind.h" #ifdef TARGET_LIBC_PROVIDES_SSP /* s390 glibc provides __stack_chk_guard in 0x14(tp), @@ -103,4 +96,10 @@ Software Foundation, 51 Franklin Street, /* Define if long doubles should be mangled as 'g'. */ #define TARGET_ALTERNATE_LONG_DOUBLE_MANGLING +/* Override the default comment-starter of "/APP" from unix.h. */ +#undef ASM_APP_ON +#define ASM_APP_ON "#APP\n" +#undef ASM_APP_OFF +#define ASM_APP_OFF "#NO_APP\n" + #endif From owner-svn-src-head@freebsd.org Tue May 23 16:59:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 49ECCD7B98D; Tue, 23 May 2017 16:59:26 +0000 (UTC) (envelope-from swills@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E9B6712A6; Tue, 23 May 2017 16:59:25 +0000 (UTC) (envelope-from swills@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NGxOW9013884; Tue, 23 May 2017 16:59:24 GMT (envelope-from swills@FreeBSD.org) Received: (from swills@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NGxOB8013882; Tue, 23 May 2017 16:59:24 GMT (envelope-from swills@FreeBSD.org) Message-Id: <201705231659.v4NGxOB8013882@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: swills set sender to swills@FreeBSD.org using -f From: Steve Wills Date: Tue, 23 May 2017 16:59:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318751 - 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.23 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, 23 May 2017 16:59:26 -0000 Author: swills (ports committer) Date: Tue May 23 16:59:24 2017 New Revision: 318751 URL: https://svnweb.freebsd.org/changeset/base/318751 Log: Add security.bsd.see_jail_proc Add security.bsd.see_jail_proc sysctl to hide jail processes from non-root users Reviewed by: jamie Approved by: allanjude Relnotes: yes Differential Revision: https://reviews.freebsd.org/D10770 Modified: head/sys/kern/kern_prot.c head/sys/sys/proc.h Modified: head/sys/kern/kern_prot.c ============================================================================== --- head/sys/kern/kern_prot.c Tue May 23 16:38:10 2017 (r318750) +++ head/sys/kern/kern_prot.c Tue May 23 16:59:24 2017 (r318751) @@ -1386,6 +1386,35 @@ cr_canseeothergids(struct ucred *u1, str return (0); } +/* + * 'see_jail_proc' determines whether or not visibility of processes and + * sockets with credentials holding different jail ids is possible using a + * variety of system MIBs. + * + * XXX: data declarations should be together near the beginning of the file. + */ + +static int see_jail_proc = 1; +SYSCTL_INT(_security_bsd, OID_AUTO, see_jail_proc, CTLFLAG_RW, + &see_jail_proc, 0, + "Unprivileged processes may see subjects/objects with different jail ids"); + +/*- + * Determine if u1 "can see" the subject specified by u2, according to the + * 'see_jail_proc' policy. + * Returns: 0 for permitted, ESRCH otherwise + * Locks: none + * References: *u1 and *u2 must not change during the call + * u1 may equal u2, in which case only one reference is required + */ +int +cr_canseejailproc(struct ucred *u1, struct ucred *u2) +{ + if (u1->cr_uid == 0) + return (0); + return (!see_jail_proc && u1->cr_prison != u2->cr_prison ? ESRCH : 0); +} + /*- * Determine if u1 "can see" the subject specified by u2. * Returns: 0 for permitted, an errno value otherwise @@ -1408,6 +1437,8 @@ cr_cansee(struct ucred *u1, struct ucred return (error); if ((error = cr_canseeothergids(u1, u2))) return (error); + if ((error = cr_canseejailproc(u1, u2))) + return (error); return (0); } Modified: head/sys/sys/proc.h ============================================================================== --- head/sys/sys/proc.h Tue May 23 16:38:10 2017 (r318750) +++ head/sys/sys/proc.h Tue May 23 16:59:24 2017 (r318751) @@ -988,6 +988,7 @@ int cr_cansee(struct ucred *u1, struct u int cr_canseesocket(struct ucred *cred, struct socket *so); int cr_canseeothergids(struct ucred *u1, struct ucred *u2); int cr_canseeotheruids(struct ucred *u1, struct ucred *u2); +int cr_canseejailproc(struct ucred *u1, struct ucred *u2); int cr_cansignal(struct ucred *cred, struct proc *proc, int signum); int enterpgrp(struct proc *p, pid_t pgid, struct pgrp *pgrp, struct session *sess); From owner-svn-src-head@freebsd.org Tue May 23 17:12:40 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DBDDDD7A21F; Tue, 23 May 2017 17:12:40 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 57A341E82; Tue, 23 May 2017 17:12:39 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([78.52.3.248]) by mail.gmx.com (mrgmx003 [212.227.17.190]) with ESMTPSA (Nemesis) id 0MYP57-1dQbKY2LXl-00V9nO; Tue, 23 May 2017 19:12:31 +0200 Date: Tue, 23 May 2017 19:12:24 +0200 From: "O. Hartmann" To: "Pedro F. Giffuni" Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318750 - in head/contrib: binutils/bfd binutils/ld binutils/ld/emulparams gcc gcc/config/s390 Message-ID: <20170523191129.57183b1c@thor.intern.walstatt.dynvpn.de> In-Reply-To: <201705231638.v4NGcAq1005935@repo.freebsd.org> References: <201705231638.v4NGcAq1005935@repo.freebsd.org> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/al1vyjXYFJz=ZTpFGvfuiI1"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:HuRH17bcvOkD4itWerAs6FUpSljGhjgUJwgo7Oki+yWHIcf8lk7 9R2f2PyWR8uY2drk2kDVM/c88POLN2MX4riSF9ylB+xTNELhIlyKWS04FBPDkFZaJg41QwN nlNuXptiqBrf7ks/Xu5PDY8ofrApVjQSXsybKFZ8vBfa9oXEJ5HFsAr7gY476IibO/jYDD5 Bga4+IsashLPXtZ4q2IEg== X-UI-Out-Filterresults: notjunk:1;V01:K0:RTzphnd5OFY=:hxQjUQ56OdMWaftaYDmK0h p7Af3v8qdVb5CYZxoHM3hk8tk7KSbfckITUOax5MRzMtbisAHz9YM1rp2REsq4ugO4RyQ+VSw m91l4/aG5J3m2DL4jldeDI75EM6usjLUGZrionfRRssmC8G81YTRsf0P1lug8xWa164xPvsNf Gc8b5oGNCYtDljYpAVRCdOKw43oJ1nyJfFQfeYDqc+bSpLC+wEueEFgJOIo7LOgX8iIoGMSeM DCtgFV29RmlcB5Qf/x41GB1NP/BgNOJHv7rMcikpaAslr2TqENxT58hitBG2jG9JIiWU8aNX9 dIcZbpixYf/z+wyW4yODda1BTleC6E5cqlqJbVZ9kBNIRL6mRc55CHatua0LRIY/mdLcINIJs Vzz1JaYm0+EQWfIYNhzf0cW3Zgr7Wm+EIU8INnc757Da/0SgiSVr234Ax4oRIOPfeMtJ/liRh ZoQvpXYm2WyOXwSDXjrqfxT/PvuvTbQTbCtkQ3CYbp9ANB+hS6+pYEghVViEsPEl3sLnBQJYc D0cLmreIoTfH6wn13S2hfI25lrCVpE48U9LUHaP/gDApx/qSTV7GmOAgaMKR3IE8EUi8kKAp/ WPTQ41J0WIS1E/cwLjjucv/HifVLZbzAU3TGcYCrXhRUGVDK7CGiIH78WeiNhpv0nKgMM18ZN GScSI5/olq8sKNMDN6wfLNEQekMJ3q5ZpHIKsmdvuq1OJ7VQ5AUCJYGCHNopiLltqJy165UXe n3h569pzHnR//sH0vJn/CivCQjlbH5e6S3+W/2YUK3IFzKRmVyC4b70OF8Jiqm736ccb8PZLW oTMTdzD X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 17:12:41 -0000 --Sig_/al1vyjXYFJz=ZTpFGvfuiI1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Am Tue, 23 May 2017 16:38:10 +0000 (UTC) "Pedro F. Giffuni" schrieb: > Author: pfg > Date: Tue May 23 16:38:10 2017 > New Revision: 318750 > URL: https://svnweb.freebsd.org/changeset/base/318750 >=20 > Log: > Bring some rough support for FreeBSD S/390 to the GNU toolchain. > =20 > This is no-op and only for reference: the S/390 port seems to be elusive > in the BSDs so it is convenient to keep some trace from past efforts. > It is likely newer attempts will focus on a newer toolchain using clang > instead. > =20 > Obtained from: Perforce depot/projects/s390 >=20 > Added: > head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh (contents, pro= ps changed) > head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh (contents, props= changed) > head/contrib/gcc/config/s390/freebsd.h > - copied, changed from r318546, head/contrib/gcc/config/s390/linux.h > Modified: > head/contrib/binutils/bfd/config.bfd > head/contrib/binutils/ld/configure.tgt > head/contrib/gcc/config.gcc >=20 > Modified: head/contrib/binutils/bfd/config.bfd > =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/contrib/binutils/bfd/config.bfd Tue May 23 16:12:50 2017 > (r318749) +++ head/contrib/binutils/bfd/config.bfd Tue May 23 16:38:10 > 2017 (r318750) @@ -1156,13 +1156,13 @@ case "${targ}" in > targ_selvecs=3D"bfd_powerpcle_pei_vec bfd_powerpc_pei_vec bfd_powerp= cle_pe_vec > bfd_powerpc_pe_vec" ;; > =20 > - s390-*-linux*) > + s390-*-freebsd* | s390-*-linux*) > targ_defvec=3Dbfd_elf32_s390_vec > targ64_selvecs=3Dbfd_elf64_s390_vec > want64=3Dtrue > ;; > #ifdef BFD64 > - s390x-*-linux*) > + s390x-*-freebsd* | s390x-*-linux*) > targ_defvec=3Dbfd_elf64_s390_vec > targ_selvecs=3Dbfd_elf32_s390_vec > want64=3Dtrue >=20 > Modified: head/contrib/binutils/ld/configure.tgt > =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/contrib/binutils/ld/configure.tgt Tue May 23 16:12:50 2017 > (r318749) +++ head/contrib/binutils/ld/configure.tgt Tue May 23 16:38:10 > 2017 (r318750) @@ -480,12 +480,21 @@ powerpc-*-lynxos*) > targ_emul=3Dppclynx ;; rs6000-*-aix5*) targ_emul=3Daix5rs6 ;; > rs6000-*-aix*) targ_emul=3Daixrs6 > ;; > +s390x-*-freebsd*) targ_emul=3Delf64_s390 > + targ_extra_emuls=3Delf_s390 > + targ_extra_libpath=3D$targ_extra_emuls > + tdir_elf_s390=3D`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; > s390x-*-linux*) targ_emul=3Delf64_s390 > targ_extra_emuls=3Delf_s390 > targ_extra_libpath=3D$targ_extra_emuls > tdir_elf_s390=3D`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; > s390x-*-tpf*) targ_emul=3Delf64_s390 > tdir_elf_s390=3D`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; > +s390-*-freebsd*) targ_emul=3Delf_s390 > + targ64_extra_emuls=3Delf64_s390 > + targ64_extra_libpath=3Delf64_s390 > + tdir_elf64_s390=3D`echo ${targ_alias} | sed -e 's/s390/s390x/'` > + ;; > s390-*-linux*) targ_emul=3Delf_s390 > targ64_extra_emuls=3Delf64_s390 > targ64_extra_libpath=3Delf64_s390 >=20 > Added: head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh > =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 > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh Tue May 23 16:= 38:10 > 2017 (r318750) @@ -0,0 +1,2 @@ > +. ${srcdir}/emulparams/elf64_s390.sh > +. ${srcdir}/emulparams/elf_fbsd.sh >=20 > Added: head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh > =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 > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh Tue May 23 16:38= :10 > 2017 (r318750) @@ -0,0 +1,2 @@ > +. ${srcdir}/emulparams/elf_s390.sh > +. ${srcdir}/emulparams/elf_fbsd.sh >=20 > Modified: head/contrib/gcc/config.gcc > =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/contrib/gcc/config.gcc Tue May 23 16:12:50 2017 (r318749) > +++ head/contrib/gcc/config.gcc Tue May 23 16:38:10 2017 (r318750) > @@ -1942,10 +1942,19 @@ rs6000-ibm-aix[56789].* | powerpc-ibm-ai > thread_file=3D'aix' > extra_headers=3D > ;; > +s390-*-freebsd*) > + tm_file=3D"${tm_file} dbxelf.h elfos.h ${fbsd_tm_file} s390/freebsd.h" > + ;; > s390-*-linux*) > tm_file=3D"s390/s390.h dbxelf.h elfos.h svr4.h linux.h s390/linux.h" > tmake_file=3D"${tmake_file} t-dfprules s390/t-crtstuff s390/t-linux" > ;; > +s390x-*-freebsd*) > + tm_file=3D"s390/s390.h s390/s390x.h dbxelf.h elfos.h ${fbsd_tm_file} > s390/freebsd.h" > + tm_p_file=3Ds390/s390-protos.h > + md_file=3Ds390/s390.md > + out_file=3Ds390/s390.c > + ;; > s390x-*-linux*) > tm_file=3D"s390/s390x.h s390/s390.h dbxelf.h elfos.h svr4.h linux.h s39= 0/linux.h" > tm_p_file=3Ds390/s390-protos.h >=20 > Copied and modified: head/contrib/gcc/config/s390/freebsd.h (from r318546, > head/contrib/gcc/config/s390/linux.h) > =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/contrib/gcc/config/s390/linux.h Fri May 19 17:14:29 2017 (r318546, > copy source) +++ head/contrib/gcc/config/s390/freebsd.h Tue May 23 16:38:= 10 > 2017 (r318750) @@ -1,4 +1,4 @@ -/* Definitions for Linux for S/390. > +/* Definitions for FreeBSD for S/390. > Copyright (C) 1999, 2000, 2001, 2002, 2004, 2005, 2006 > Free Software Foundation, Inc. > Contributed by Hartmut Penner (hpenner@de.ibm.com) and > @@ -21,25 +21,26 @@ along with GCC; see the file COPYING. I > Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA > 02110-1301, USA. */ > =20 > -#ifndef _LINUX_H > -#define _LINUX_H > +#ifndef _CONFIG_S390_FREEBSD_H > +#define _CONFIG_S390_FREEBSD_H > =20 > /* Target specific version string. */ > =20 > #ifdef DEFAULT_TARGET_64BIT > #undef TARGET_VERSION > -#define TARGET_VERSION fprintf (stderr, " (Linux for zSeries)"); > +#define TARGET_VERSION fprintf (stderr, " (FreeBSD for zSeries)"); > #else > #undef TARGET_VERSION > -#define TARGET_VERSION fprintf (stderr, " (Linux for S/390)"); > +#define TARGET_VERSION fprintf (stderr, " (FreeBSD for S/390)"); > #endif > =20 > =20 > /* Target specific type definitions. */ > =20 > /* ??? Do we really want long as size_t on 31-bit? */ > +/* Answer is yes for FreeBSD. */ > #undef SIZE_TYPE > -#define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "long unsigned i= nt") > +#define SIZE_TYPE (TARGET_64BIT ? "long unsigned int" : "unsigned int") > #undef PTRDIFF_TYPE > #define PTRDIFF_TYPE (TARGET_64BIT ? "long int" : "int") > =20 > @@ -48,16 +49,8 @@ Software Foundation, 51 Franklin Street, > #undef WCHAR_TYPE_SIZE > #define WCHAR_TYPE_SIZE 32 > =20 > - > -/* Target specific preprocessor settings. */ > - > -#define TARGET_OS_CPP_BUILTINS() \ > - do \ > - { \ > - LINUX_TARGET_OS_CPP_BUILTINS(); \ > - } \ > - while (0) > - > +#undef DEFAULT_SIGNED_CHAR > +#define DEFAULT_SIGNED_CHAR 1 > =20 > /* Target specific assembler settings. */ > =20 > @@ -92,7 +85,7 @@ Software Foundation, 51 Franklin Street, > =20 > #define TARGET_ASM_FILE_END file_end_indicate_exec_stack > =20 > -#define MD_UNWIND_SUPPORT "config/s390/linux-unwind.h" > +#define MD_UNWIND_SUPPORT "config/s390/freebsd-unwind.h" > =20 > #ifdef TARGET_LIBC_PROVIDES_SSP > /* s390 glibc provides __stack_chk_guard in 0x14(tp), > @@ -103,4 +96,10 @@ Software Foundation, 51 Franklin Street, > /* Define if long doubles should be mangled as 'g'. */ > #define TARGET_ALTERNATE_LONG_DOUBLE_MANGLING > =20 > +/* Override the default comment-starter of "/APP" from unix.h. */ > +#undef ASM_APP_ON > +#define ASM_APP_ON "#APP\n" > +#undef ASM_APP_OFF > +#define ASM_APP_OFF "#NO_APP\n" > + > #endif > _______________________________________________ > svn-src-head@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" Buildworld fails on r318751 with a "Segmentation fault" error as shown belo= w: Building /usr/obj/usr/src/lib/libkiconv/_libinstall --- lib/libmd__L --- --- skein_block_asm.o --- Segmentation fault *** [skein_block_asm.o] Error code 139 make[4]: stopped in /usr/src/lib/libmd .ERROR_TARGET=3D'skein_block_asm.o' .ERROR_META_FILE=3D'/usr/obj/usr/src/lib/libmd/skein_block_asm.o.meta' .MAKE.LEVEL=3D'4' MAKEFILE=3D'' Host is running recent CURRENT: FreeBSD 12.0-CURRENT #124 r318748: Tue May = 23 18:52:59 CEST 2017 amd64 --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/al1vyjXYFJz=ZTpFGvfuiI1 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSRteAAKCRDS528fyFhY lNJzAf9E+JYxM4l1P7Nh49Rrg1l7hDKe8ta/GFes1MQCpLG9A6I5bi5Bx4awtjMi 9fwdsMRU/M6rqb3k8eLBlkx78DILAf9nMvaOE+Ardj0y0rkLy3kXsXTVrxBoiboR VTxLE2TZ4qNuRdBdTsZtUCjqBWS+EVKhZSd9qj6yzCY6tfeKOhA9 =0zre -----END PGP SIGNATURE----- --Sig_/al1vyjXYFJz=ZTpFGvfuiI1-- From owner-svn-src-head@freebsd.org Tue May 23 17:34:11 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6A873D7A94B; Tue, 23 May 2017 17:34:11 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3AA6B1A64; Tue, 23 May 2017 17:34:11 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NHYANQ030369; Tue, 23 May 2017 17:34:10 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NHYAsT030368; Tue, 23 May 2017 17:34:10 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705231734.v4NHYAsT030368@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 23 May 2017 17:34:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318753 - head/lib/libc/gen 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.23 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, 23 May 2017 17:34:11 -0000 Author: ngie Date: Tue May 23 17:34:10 2017 New Revision: 318753 URL: https://svnweb.freebsd.org/changeset/base/318753 Log: directory(3): add trailing comma after e.g., missed in r318699 Submitted by: bjk MFC after: 2 weeks MFC with: r318699 Sponsored by: Dell EMC Isilon Modified: head/lib/libc/gen/directory.3 Modified: head/lib/libc/gen/directory.3 ============================================================================== --- head/lib/libc/gen/directory.3 Tue May 23 17:00:56 2017 (r318752) +++ head/lib/libc/gen/directory.3 Tue May 23 17:34:10 2017 (r318753) @@ -300,7 +300,7 @@ will always set the correct location to .Fn readdir performed. This is enough for some applications which want to -"push back the last entry read", e.g. Samba. +"push back the last entry read", e.g., Samba. Seeks back to any other location, other than the beginning of the directory, may result in unexpected behaviour if deletes are present. From owner-svn-src-head@freebsd.org Tue May 23 17:34:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E4B1ED7A99D; Tue, 23 May 2017 17:34:32 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x229.google.com (mail-pf0-x229.google.com [IPv6:2607:f8b0:400e:c00::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B03B21BD6; Tue, 23 May 2017 17:34:32 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x229.google.com with SMTP id m17so121161139pfg.3; Tue, 23 May 2017 10:34:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=gHX4TZH9H1Oy8yIXDeX/KcX2GZMU/ZV31tzSJNnUYjk=; b=SpcZ5ghs9fm34qwuIAUoVq0IjL+6RQc/HRMdexQvlQCY5Qi5JQNod193Gsl3YmvUmo LIDY4ITW71Y9hBid92AdzIfGTWn5cnte0rfM85UzW5jipZrO1cyG5aVNfq4/gR9CTCpL OjEY15kn0t82iDP0CmqLioHk278Pa9/F47cg1Qt/MwRu3toqtWki9QoWDQLTGGgKncyD lRppNDIDynwcIvXgjvJkJCWkIKcFgezznBm1JcPlIFAkAGEswHJF7oT8+wByz3IPgjEO TmmJHOfxzL0tWZMedckaWKp/OxSDQQbK1yn1RBQQs14rewdOQ2nQKHB+ipkuLtjxcfLz CJAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=gHX4TZH9H1Oy8yIXDeX/KcX2GZMU/ZV31tzSJNnUYjk=; b=EZqSOCcUjEB3SNheVhV2uzrGs0m/rxzJfQIANonjF0/tnsFGHc1JMBFdjW3lfo3wDG 7s/a9dKdkEBOuI1J6PIr5D+RsvK4rg6yWH2S5QAMjBomf4JSab8QkCXHlOK0DZNWtDcG SpcfS1NR75h1lWw6vIv5NDSw8hcgMcMeVNlEfOiqdgBQWd1w+ZwJkvuFsxtByyt4pkmJ zo3VsxeoEgOfj41rv9zteMtuKo+s6lYrw4421bGekTpS55USo0V/F5AQ3Gtb8HlU0tkc ycqZMzXTgkL9olVO4VC8Z+9eEGPZ2of2txFdRZ5zjrpHR37skPVKcSgwjWOM+bUjjf62 418g== X-Gm-Message-State: AODbwcAWfGa8AdAKKL8+s7wx2ghVr9/fSC/virxSZZ5cVK52Z8pe5yvS nsiTWHGyLfT25A== X-Received: by 10.98.200.23 with SMTP id z23mr33605160pff.18.1495560872301; Tue, 23 May 2017 10:34:32 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id c12sm2572197pgn.21.2017.05.23.10.34.31 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 23 May 2017 10:34:31 -0700 (PDT) Subject: Re: svn commit: r318699 - head/lib/libc/gen Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_FCC89D2C-C32B-4E97-9973-870294F5DC79"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Tue, 23 May 2017 10:34:30 -0700 Cc: Ngie Cooper , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: <35E7F169-33E3-4F48-B19C-58C5AAC82E27@gmail.com> References: <201705230655.v4N6tpx0065768@repo.freebsd.org> To: Benjamin Kaduk X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 17:34:33 -0000 --Apple-Mail=_FCC89D2C-C32B-4E97-9973-870294F5DC79 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On May 23, 2017, at 08:13, Benjamin Kaduk wrote: >=20 > On Tue, May 23, 2017 at 1:55 AM, Ngie Cooper wrote: > Author: ngie > Date: Tue May 23 06:55:51 2017 > New Revision: 318699 > URL: https://svnweb.freebsd.org/changeset/base/318699 >=20 > Log: > directory(3): delete trailing whitespace and rewrite `E.g.` as = `e.g.` >=20 > FWIW, it is better-still written as "e.g.,", i.e., with trailing = comma as well as leading comma. Fixed in r318753 =E2=80=94 thanks :). -Ngie --Apple-Mail=_FCC89D2C-C32B-4E97-9973-870294F5DC79 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJZJHKmAAoJEPWDqSZpMIYVVDYP+gIlJ29PxGaN0lN2OMkY+AUm ZbMabGxICU5T9Vqgy8HCuqs+3jy1NZErGP1FggmSx5w4V9hW+/mQZr/mlfxOe1zx VE1wx0boN5rCKkYj8tJjHdtx1ckj8D/aGEw3a//bLvtnr7qixyi9D0txDH9XeQqK htAFobzHfTr+Xk6x3qmlYmY7Wqq2NIybWqBXHPVAsH1PLJ6INA3sAOKsr7ahm6TC S5FaQkQygYzZ1EDEVWaNH5qRC5fHYe0NXk2yxsihK8tBaqabMG2FhsyvxnAgc1oa XkR6Ibp5sd5KH+51ESRVmCPxD9K7hvn8Jv3U8m9BdnQNhc7JluAS/iECC8tcu01s chXmSS3N5Br0wro0K4b3pe5zMl0Fih4WOCWihxRQPYGL8uCjS5AYug2NH/yq9lpz uZtPBF5mhziyxOUtZjcJIhZasG1aSFH7KfyoWGUEGaK70VmWQcPWX6ySa4EC9E2o i8ghIHr2LwaLaGy/P5ztEwm9rHlQrTDKyxqdvvt4djdBEA6i/Q8VrFKWhHC+6ue1 mOjSz5El/cstGsJjBKNS1Tm0Jf3FUoh2r3GAJoiYT5tHbY2QpBKXAGFe5hGCj3fP irzes8kOGySjAXzqrDr5uAPTxX3R/fSpQqwTiaFaVqgMLw7oWaMPJzvwoac4B6y7 Xn5ru/psctW9X+o2BCV5 =pbim -----END PGP SIGNATURE----- --Apple-Mail=_FCC89D2C-C32B-4E97-9973-870294F5DC79-- From owner-svn-src-head@freebsd.org Tue May 23 17:41:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 792D5D7AA57; Tue, 23 May 2017 17:41:10 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 480D11E93; Tue, 23 May 2017 17:41:10 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NHf9Cm031343; Tue, 23 May 2017 17:41:09 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NHf9jH031342; Tue, 23 May 2017 17:41:09 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201705231741.v4NHf9jH031342@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 23 May 2017 17:41:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318754 - head/sys/boot/mips/beri/boot2 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.23 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, 23 May 2017 17:41:10 -0000 Author: jhb Date: Tue May 23 17:41:09 2017 New Revision: 318754 URL: https://svnweb.freebsd.org/changeset/base/318754 Log: Pass -N directly to ld via -Wl rather than passing it to the compiler driver. In particular, clang doesn't accept -N. Obtained from: CheriBSD Sponsored by: DARPA / AFRL Modified: head/sys/boot/mips/beri/boot2/Makefile Modified: head/sys/boot/mips/beri/boot2/Makefile ============================================================================== --- head/sys/boot/mips/beri/boot2/Makefile Tue May 23 17:34:10 2017 (r318753) +++ head/sys/boot/mips/beri/boot2/Makefile Tue May 23 17:41:09 2017 (r318754) @@ -63,7 +63,7 @@ LIBSTAND= ${.OBJDIR}/../../../../../lib/ LDFLAGS= -nostdlib \ -static \ - -N \ + -Wl,-N \ -G0 \ -L${.CURDIR} From owner-svn-src-head@freebsd.org Tue May 23 17:56:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E8199D7B19B; Tue, 23 May 2017 17:56:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from mail.baldwin.cx (bigwig.baldwin.cx [96.47.65.170]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C65CF1A42; Tue, 23 May 2017 17:56:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by mail.baldwin.cx (Postfix) with ESMTPSA id 03EF310AFA3; Tue, 23 May 2017 13:56:21 -0400 (EDT) From: John Baldwin To: Konstantin Belousov Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... Date: Tue, 23 May 2017 10:31:01 -0700 Message-ID: <13857290.5K0PvDnonX@ralph.baldwin.cx> User-Agent: KMail/4.14.10 (FreeBSD/11.0-STABLE; KDE/4.14.10; amd64; ; ) In-Reply-To: <201705230929.v4N9T5g1028124@repo.freebsd.org> References: <201705230929.v4N9T5g1028124@repo.freebsd.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.4.3 (mail.baldwin.cx); Tue, 23 May 2017 13:56:21 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.99.2 at mail.baldwin.cx X-Virus-Status: Clean X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 17:56:29 -0000 On Tuesday, May 23, 2017 09:29:05 AM Konstantin Belousov wrote: > Author: kib > Date: Tue May 23 09:29:05 2017 > New Revision: 318736 > URL: https://svnweb.freebsd.org/changeset/base/318736 > > Log: > Commit the 64-bit inode project. A _big_ thanks to kib@ for driving this to completion and to gleb@ for doing a large share of the work. -- John Baldwin From owner-svn-src-head@freebsd.org Tue May 23 19:00:49 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4144ED7B351; Tue, 23 May 2017 19:00:49 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B36CC1546; Tue, 23 May 2017 19:00:48 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([78.52.3.248]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0LsChr-1dx8Es1jcF-013uBc; Tue, 23 May 2017 21:00:45 +0200 Date: Tue, 23 May 2017 21:00:39 +0200 From: "O. Hartmann" To: Pedro Giffuni Cc: "O. Hartmann" , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318750 - in head/contrib: binutils/bfd binutils/ld binutils/ld/emulparams gcc gcc/config/s390 Message-ID: <20170523210039.555a2f41@thor.intern.walstatt.dynvpn.de> In-Reply-To: <5d1d0149-7994-a870-0f6d-1499a9efba75@FreeBSD.org> References: <201705231638.v4NGcAq1005935@repo.freebsd.org> <20170523191129.57183b1c@thor.intern.walstatt.dynvpn.de> <5d1d0149-7994-a870-0f6d-1499a9efba75@FreeBSD.org> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/MYZaQ/c8XecG4rMc5Pxs4x_"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:66NVIBnOfqWnxMHg26vSq7J/c/TICtOJSm++d5aabF1Dc0ZaLiY aZIlDuCbitSdhq3nUiwVRuHXbQBerv+5u8O+Xspty695GnTyE38LjGSKSU3jtFAQ4n6RRbd uxRZ2W/LKjPVYP+GSSaL41MDtWJNDAewVcfSNpRiHF9WNkjSBd0H24yXapKXP5X6azrzxyg cm8LZAXadTozxcN7HIySg== X-UI-Out-Filterresults: notjunk:1;V01:K0:1Fg6uvCmUdE=:UWIK/kQF9OEMnxMuTzgEJr 6X+FqMTbikmQKgWieC8UXdu88y42tQHcSov8WhvbGqc5nbxSTlsdeWpH/WLrfbkMPM6vfMa1E Lw9a2naLF3Lp1g1PRV2RVCw9MSZhyVNnCN/LjzFwEIk+B2kXS1YOUj+J4pMS/XQQV1llld/ok 4ouGj0DjpSMVj8Oqsk6nenFdOzqfa1/WCJCPkExmauExr5TMHqG+FjyhIx6UkfUW2DQIKdadS trPTRxRU2FCRHzI+U5ks8VgjAmRKwJEsnBEYT6aWBRbpnDNrCqlilCs//tCWDFxV4qqETQNQi ilbxdEaWONaGNxw9WV04CJxDx+X0pwasd54kdxaEwo12Uqb56vlzhCyCpazzacM1UDzA57uhp Z10WoV5jx0hG+ELCecJ5Qf56T/05wsVudInB+HF/IpSi0PLLvlv9H1z4hiV5pyy6qwrUeQWFR 47hEueBAQZiavImcsKqf2G0YaBzNwdOQU6gPhRLpO8jYBc3PMkVRlvVcrX0jDvPgkN+JhC60E fmesRJHbVMAar7JY/8fKlForRjZgSOPXahP/+1Jj+lLaA5gls+3o4p404qpWbuM4RyIa79mr+ iEO18JPN8YyacO+zFOTfgSnQ99gzQRJq38f0id2U929hFWBYNS6pGK2fJscwqcofUREseep7W mXv5KwTciV9zZ2weGG15YdUefhicnAXsRPxlPzYntCGxcjf+s8UNtBu6illeNChGQ4wCyGzFJ tUxwBX0iU09bmvSpkWdOW1L6d+SI4weia0Py+0hnxyMWJjpstrUCo7fUL2eYxs22ZIklIv2B6 jVALHX5 X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 19:00:49 -0000 --Sig_/MYZaQ/c8XecG4rMc5Pxs4x_ Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Am Tue, 23 May 2017 12:52:35 -0500 Pedro Giffuni schrieb: > On 23/05/2017 12:12, O. Hartmann wrote: > > Am Tue, 23 May 2017 16:38:10 +0000 (UTC) > > "Pedro F. Giffuni" schrieb: > > =20 > >> Author: pfg > >> Date: Tue May 23 16:38:10 2017 > >> New Revision: 318750 > >> URL: https://svnweb.freebsd.org/changeset/base/318750 > >> > >> Log: > >> Bring some rough support for FreeBSD S/390 to the GNU toolchain. > >> =20 > >> This is no-op and only for reference: the S/390 port seems to be el= usive > >> in the BSDs so it is convenient to keep some trace from past effort= s. > >> It is likely newer attempts will focus on a newer toolchain using c= lang > >> instead. > >> =20 > >> Obtained from: Perforce depot/projects/s390 > >> > >> Added: > >> head/contrib/binutils/ld/emulparams/elf64_s390_fbsd.sh (contents,= props changed) > >> head/contrib/binutils/ld/emulparams/elf_s390_fbsd.sh (contents, p= rops changed) > >> head/contrib/gcc/config/s390/freebsd.h > >> - copied, changed from r318546, head/contrib/gcc/config/s390/lin= ux.h > >> Modified: > >> head/contrib/binutils/bfd/config.bfd > >> head/contrib/binutils/ld/configure.tgt > >> head/contrib/gcc/config.gcc =20 > ... > >> Buildworld fails on r318751 with a "Segmentation fault" error as shown= below: > >> > >> Building /usr/obj/usr/src/lib/libkiconv/_libinstall > >> --- lib/libmd__L --- > >> --- skein_block_asm.o --- > >> Segmentation fault > >> *** [skein_block_asm.o] Error code 139 > >> > >> make[4]: stopped in /usr/src/lib/libmd > >> .ERROR_TARGET=3D'skein_block_asm.o' > >> .ERROR_META_FILE=3D'/usr/obj/usr/src/lib/libmd/skein_block_asm.o.meta' > >> .MAKE.LEVEL=3D'4' > >> MAKEFILE=3D'' > >> > >> > >> Host is running recent CURRENT: FreeBSD 12.0-CURRENT #124 r318748: Tue= May 23 > >> 18:52:59 CEST 2017 amd64 =20 >=20 > It shouldn't be related to this change: >=20 > 1) This only affects s390 configuration which is never activated > 2) I did run a tinderbox build to make sure nothing was affected (the=20 > only thing failing was an unrelated powerpc warning that was fixed). >=20 > Pedro. Hello, the problem could be resolved by deleting the /usr/obj folder and start a c= lean build again. Regards, Oliver --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/MYZaQ/c8XecG4rMc5Pxs4x_ Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSSG1wAKCRDS528fyFhY lHLCAf4947rxL/M19A3aoocLM3R5MaMCyVTiwguRowwWYEupAZDf9EPfjNaveee2 Kpqv90pGvdna71TZib/fJwppBKArAgCZUpDGwOPLjD9G6nupskaLEzT/Q6rcCdn0 PZImG1pQsK+xHNEYiP2R7lSH8nwE/qzjXa9Eu/qOwSMH7QotuSq9 =1vjE -----END PGP SIGNATURE----- --Sig_/MYZaQ/c8XecG4rMc5Pxs4x_-- From owner-svn-src-head@freebsd.org Tue May 23 19:03:09 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D80ED7B4E3; Tue, 23 May 2017 19:03:09 +0000 (UTC) (envelope-from lidl@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 38BAA1833; Tue, 23 May 2017 19:03:09 +0000 (UTC) (envelope-from lidl@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NJ38gd068266; Tue, 23 May 2017 19:03:08 GMT (envelope-from lidl@FreeBSD.org) Received: (from lidl@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NJ37Nh068261; Tue, 23 May 2017 19:03:07 GMT (envelope-from lidl@FreeBSD.org) Message-Id: <201705231903.v4NJ37Nh068261@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: lidl set sender to lidl@FreeBSD.org using -f From: Kurt Lidl Date: Tue, 23 May 2017 19:03:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318755 - in head/contrib/blacklist: bin include 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.23 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, 23 May 2017 19:03:09 -0000 Author: lidl Date: Tue May 23 19:03:07 2017 New Revision: 318755 URL: https://svnweb.freebsd.org/changeset/base/318755 Log: Extend libblacklist support with new action types The original blacklist library supported two notification types: - failed auth attempt, which incremented the failed login count by one for the remote address - successful auth attempt, which reset the failed login count to zero for that remote address When the failed login count reached the limit in the configuration file, the remote address would be blocked by a packet filter. This patch implements a new notification type, "abusive behavior", and accepts, but does not act on an additional type, "bad username". It is envisioned that a system administrator will configure a small list of "known bad usernames" that should be blocked immediately. Reviewed by: emaste MFC after: 3 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10604 Modified: head/contrib/blacklist/bin/blacklistd.c head/contrib/blacklist/include/bl.h head/contrib/blacklist/include/blacklist.h head/contrib/blacklist/lib/blacklist.c head/contrib/blacklist/lib/libblacklist.3 Modified: head/contrib/blacklist/bin/blacklistd.c ============================================================================== --- head/contrib/blacklist/bin/blacklistd.c Tue May 23 17:41:09 2017 (r318754) +++ head/contrib/blacklist/bin/blacklistd.c Tue May 23 19:03:07 2017 (r318755) @@ -214,6 +214,17 @@ process(bl_t bl) } switch (bi->bi_type) { + case BL_ABUSE: + /* + * If the application has signaled abusive behavior, + * set the number of fails to be one less than the + * configured limit. Fallthrough to the normal BL_ADD + * processing, which will increment the failure count + * to the threshhold, and block the abusive address. + */ + if (c.c_nfail != -1) + dbi.count = c.c_nfail - 1; + /*FALLTHROUGH*/ case BL_ADD: dbi.count++; dbi.last = ts.tv_sec; @@ -249,6 +260,9 @@ process(bl_t bl) dbi.count = 0; dbi.last = 0; break; + case BL_BADUSER: + /* ignore for now */ + break; default: (*lfun)(LOG_ERR, "unknown message %d", bi->bi_type); } Modified: head/contrib/blacklist/include/bl.h ============================================================================== --- head/contrib/blacklist/include/bl.h Tue May 23 17:41:09 2017 (r318754) +++ head/contrib/blacklist/include/bl.h Tue May 23 19:03:07 2017 (r318755) @@ -40,7 +40,9 @@ typedef enum { BL_INVALID, BL_ADD, - BL_DELETE + BL_DELETE, + BL_ABUSE, + BL_BADUSER } bl_type_t; typedef struct { Modified: head/contrib/blacklist/include/blacklist.h ============================================================================== --- head/contrib/blacklist/include/blacklist.h Tue May 23 17:41:09 2017 (r318754) +++ head/contrib/blacklist/include/blacklist.h Tue May 23 19:03:07 2017 (r318755) @@ -43,4 +43,13 @@ int blacklist_sa_r(struct blacklist *, i const struct sockaddr *, socklen_t, const char *); __END_DECLS +/* action values for user applications */ +#define BLACKLIST_API_ENUM 1 +enum { + BLACKLIST_AUTH_OK = 0, + BLACKLIST_AUTH_FAIL, + BLACKLIST_ABUSIVE_BEHAVIOR, + BLACKLIST_BAD_USER +}; + #endif /* _BLACKLIST_H */ Modified: head/contrib/blacklist/lib/blacklist.c ============================================================================== --- head/contrib/blacklist/lib/blacklist.c Tue May 23 17:41:09 2017 (r318754) +++ head/contrib/blacklist/lib/blacklist.c Tue May 23 19:03:07 2017 (r318755) @@ -61,7 +61,27 @@ int blacklist_sa_r(struct blacklist *bl, int action, int rfd, const struct sockaddr *sa, socklen_t slen, const char *msg) { - return bl_send(bl, action ? BL_ADD : BL_DELETE, rfd, sa, slen, msg); + int internal_action; + + /* internal values are not the same as user application values */ + switch (action) { + case BLACKLIST_AUTH_FAIL: + internal_action = BL_ADD; + break; + case BLACKLIST_AUTH_OK: + internal_action = BL_DELETE; + break; + case BLACKLIST_ABUSIVE_BEHAVIOR: + internal_action = BL_ABUSE; + break; + case BLACKLIST_BAD_USER: + internal_action = BL_BADUSER; + break; + default: + internal_action = BL_INVALID; + break; + } + return bl_send(bl, internal_action, rfd, sa, slen, msg); } int Modified: head/contrib/blacklist/lib/libblacklist.3 ============================================================================== --- head/contrib/blacklist/lib/libblacklist.3 Tue May 23 17:41:09 2017 (r318754) +++ head/contrib/blacklist/lib/libblacklist.3 Tue May 23 19:03:07 2017 (r318755) @@ -27,7 +27,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd January 22, 2015 +.Dd May 5, 2017 .Dt LIBBLACKLIST 3 .Os .Sh NAME @@ -76,13 +76,9 @@ The .Fn blacklist function sends a message to .Xr blacklistd 8 , -with an +with an integer .Ar action -argument specifying -.Dv 1 -for a failed connection or -.Dv 0 -for a successful connection, +argument specifying the type of notification, a file descriptor .Ar fd specifying the accepted file descriptor connected to the client, @@ -91,6 +87,30 @@ and an optional message in the argument. .Pp The +.Ar action +parameter can take these values: +.Bl -tag -width ".Va BLACKLIST_ABUSIVE_BEHAVIOR" +.It Va BLACKLIST_AUTH_FAIL +There was an unsuccessful authentication attempt. +.It Va BLACKLIST_AUTH_OK +A user successfully authenticated. +.It Va BLACKLIST_ABUSIVE_BEHAVIOR +The sending daemon has detected abusive behavior +from the remote system. The remote address should +be blocked as soon as possible. +.It Va BLACKLIST_BAD_USER +The sending daemon has determined the username +presented for authentication is invalid. The +.Xr blacklistd 8 +daemon compares the username to a configured list of forbidden +usernames and +blocks the address immediately if a forbidden username matches. +(The +.Ar BLACKLIST_BAD_USER +support is not currently available.) +.El +.Pp +The .Fn blacklist_r function is more efficient because it keeps the blacklist state around. .Pp @@ -102,8 +122,13 @@ functions can be used with unconnected s .Xr getpeername 2 will not work, the server will pass the peer name in the message. .Pp -All functions log errors to -.Xr syslogd 8 . +By default, +.Xr syslogd 8 +is used for message logging. +The internal +.Fn bl_create +function can be used to create the required internal +state and specify a custom logging function. .Sh RETURN VALUES The function .Fn blacklist_open From owner-svn-src-head@freebsd.org Tue May 23 20:25:51 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0FDCCD7B0A7; Tue, 23 May 2017 20:25:51 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D0E4A1710; Tue, 23 May 2017 20:25:50 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NKPnYU001396; Tue, 23 May 2017 20:25:49 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NKPnrH001395; Tue, 23 May 2017 20:25:49 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705232025.v4NKPnrH001395@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Tue, 23 May 2017 20:25:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318757 - 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.23 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, 23 May 2017 20:25:51 -0000 Author: emaste Date: Tue May 23 20:25:49 2017 New Revision: 318757 URL: https://svnweb.freebsd.org/changeset/base/318757 Log: Add note to UPDATING for ino64 to follow the standard upgrade process The existing upgrade process documented in UPDATING is both necessary and sufficient for upgrading across the ino64 change. However, the shortcut of installing both kernel + world before a single reboot has been possible for quite some time, and several developers and users were surprised by fallout from ino64. Add an explicit entry pointing out that the full process must be followed. Reviewed by: allanjude, gjb, vangyzen Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10877 Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Tue May 23 19:45:31 2017 (r318756) +++ head/UPDATING Tue May 23 20:25:49 2017 (r318757) @@ -51,6 +51,14 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 ****************************** SPECIAL WARNING: ****************************** +20170523: + The "ino64" 64-bit inode project has been committed, which extends + a number of types to 64 bits. In order to upgrade, carefully follow + the full procedure documented below under the heading "To rebuild + everything and install it on the current system." Specifically, a + reboot is required after installing the new kernel before installing + world. + 20170424: The NATM framework including the en(4), fatm(4), hatm(4), and patm(4) devices has been removed. Consumers should plan a From owner-svn-src-head@freebsd.org Tue May 23 20:51:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0A428D7B880; Tue, 23 May 2017 20:51:50 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CE3531519; Tue, 23 May 2017 20:51:49 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NKpmeJ010358; Tue, 23 May 2017 20:51:48 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NKpm9g010357; Tue, 23 May 2017 20:51:48 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705232051.v4NKpm9g010357@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Tue, 23 May 2017 20:51:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318758 - 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.23 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, 23 May 2017 20:51:50 -0000 Author: emaste Date: Tue May 23 20:51:48 2017 New Revision: 318758 URL: https://svnweb.freebsd.org/changeset/base/318758 Log: UPDATING: ino64 upgrade should include COMPAT_FREEBSD11 The upgrade process requires COMPAT_FREEBSD11 to support the combination of "old" userland and "new" kernel that exists after "make kernel" and reboot. Mention this explicitly for those using custom kernel configs. Once the "new" world is installed the COMPAT_FREEBSD11 could be removed again, but that does not seem necessary to mention in UPDATING. Reported by: kib Sponsored by: The FreeBSD Foundation Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Tue May 23 20:25:49 2017 (r318757) +++ head/UPDATING Tue May 23 20:51:48 2017 (r318758) @@ -57,7 +57,8 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 the full procedure documented below under the heading "To rebuild everything and install it on the current system." Specifically, a reboot is required after installing the new kernel before installing - world. + world. In addition, if using a custom kernel configuration ensure + that the COMPAT_FREEBSD11 option is included. 20170424: The NATM framework including the en(4), fatm(4), hatm(4), and From owner-svn-src-head@freebsd.org Tue May 23 21:33:07 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2E274D7BFDB; Tue, 23 May 2017 21:33:07 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0506F189B; Tue, 23 May 2017 21:33:07 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id 3695A11EE; Tue, 23 May 2017 21:33:06 +0000 (UTC) Date: Tue, 23 May 2017 21:33:06 +0000 From: Alexey Dokuchaev To: Ed Maste Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318757 - head Message-ID: <20170523213306.GA74154@FreeBSD.org> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705232025.v4NKPnrH001395@repo.freebsd.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 21:33:07 -0000 On Tue, May 23, 2017 at 08:25:49PM +0000, Ed Maste wrote: > New Revision: 318757 > URL: https://svnweb.freebsd.org/changeset/base/318757 > > Log: > Add note to UPDATING for ino64 to follow the standard upgrade process > ... > +20170523: > + The "ino64" 64-bit inode project has been committed, which extends > + a number of types to 64 bits. For the dumb people among us, what is it all about? E.g., what's so cool about it? ./danfe From owner-svn-src-head@freebsd.org Tue May 23 21:39:37 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5B0FBD7B067; Tue, 23 May 2017 21:39:37 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 1D4351A93; Tue, 23 May 2017 21:39:37 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x244.google.com with SMTP id w69so30091456pfk.1; Tue, 23 May 2017 14:39:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=6Fy68fvVETDEqBTngAirEzB0rwggcgDiL5v6hOMs/ns=; b=ObgPGYamadAgmqGxKRySmm3syRraR7br3dvpWcM4mm2oRaMPQNpYwReC3cAgKqzK71 cV131tXCqrQH3RCsDghO0FH86j0wWbKse0KFg07z+B/1+8sMW+z6oviadyTs1jg8bOne VEA618hRUAzL8yrk0sq1VSpB5q4ko7J5ELf2/88sqF6KDRCnsqc9JDq1SVKGxEtnQ8Ok B+Re5MVQcIXegJS/yXm+KqCZs3OFFn93MjLpl9Xl7nP0VMYzn2cKWYdVAMmn3VFEDDGZ q4HK2KpVPN0W5cSG6HNVcExnz9t4gj1X2mqAlNRL0BTK3VGNBa0p8TX4a0qMP/YYy7dG 4j6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=6Fy68fvVETDEqBTngAirEzB0rwggcgDiL5v6hOMs/ns=; b=R6h/tSaRW3YgDFwkMb8AyrGJe0AdXzORTvegUQcgae7LF+VOfRsLdcusSmnye2SC1C uew5P8R1jDn9LjdgYL2QYb+gUs3d3QciMPzXnVa7LeNyc9ol0I3VjazGW2eYvp2liVmf Wy5UklzfJm2GAuYLpVzwHzgVNLeNxniawQ94qXu+UcdmDayAw+TqeMXS0iIA9a7P9AKb Ig4cIsqdVXOU8Vk8YPCXkiWsJsKlxUvBRLpKie/1BuipMfHdqrWNeWRdUirET+Mkjbs6 +m9sbfRJeN4+n8oylOCHqvBOsQXiiBajfBWn/txiIctNcX7FlojdQigNcaEm8/au4CJX CUdQ== X-Gm-Message-State: AODbwcCFrPFsuXRu3NTajsVQ5PQ/tUveUFoNe+c4d6C+V4AoLMn29dls t+KYIjJn630X0DUQAr0= X-Received: by 10.99.1.85 with SMTP id 82mr35101245pgb.164.1495575576456; Tue, 23 May 2017 14:39:36 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id y2sm3749947pfa.65.2017.05.23.14.39.34 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 23 May 2017 14:39:35 -0700 (PDT) Subject: Re: svn commit: r318757 - head Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_3158879A-AB5C-45EE-900B-38C69308CB43"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <20170523213306.GA74154@FreeBSD.org> Date: Tue, 23 May 2017 14:39:33 -0700 Cc: Ed Maste , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <0BB13EA0-7DE0-48CF-B51F-8BC68338CCDF@gmail.com> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> To: Alexey Dokuchaev X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 21:39:37 -0000 --Apple-Mail=_3158879A-AB5C-45EE-900B-38C69308CB43 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On May 23, 2017, at 14:33, Alexey Dokuchaev wrote: >=20 > On Tue, May 23, 2017 at 08:25:49PM +0000, Ed Maste wrote: >> New Revision: 318757 >> URL: https://svnweb.freebsd.org/changeset/base/318757 >>=20 >> Log: >> Add note to UPDATING for ino64 to follow the standard upgrade = process >> ... >> +20170523: >> + The "ino64" 64-bit inode project has been committed, which = extends >> + a number of types to 64 bits. >=20 > For the dumb people among us, what is it all about? E.g., what's so = cool > about it? 64-bit inodes: more addressable inodes for bigger = filesystems/disks. =46rom = https://lists.freebsd.org/pipermail/freebsd-fs/2017-April/024684.html : =E2=80=9C=E2=80=9D" Inodes are data structures corresponding to objects in a file system, such as files and directories. FreeBSD has historically used 32-bit values to identify inodes, which limits file systems to somewhat under 2^32 objects. Many modern file systems internally use 64-bit identifiers and FreeBSD needs to follow suit to properly and fully support these file systems. =E2=80=9C=E2=80=9D=E2=80=9D With Isilon OneFS we currently support multiples of petabytes of = storage ( = https://www.emc.com/collateral/hardware/white-papers/h10719-isilon-onefs-t= echnical-overview-wp.pdf ), so this matters very much to us. It=E2=80=99s = also useful for other file systems though (assuming they can scale that = high). Cheers, -Ngie --Apple-Mail=_3158879A-AB5C-45EE-900B-38C69308CB43 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJZJKwWAAoJEPWDqSZpMIYVLP0QANDJVWawXT4f1RFkrsjZV2bV 2SJC6taXcpoGjRnt6iAwmpd++1uAvty0TryHeHtOEfhfJZSkCLQlGwxqxaJkzpgZ DETwXcTuN3RCXaciqBGRVJRPQqRDjof2Av7hngOumfVyu9gW85rDnujdr1/EApKo Erq8BkOwftYBMjHkxY/NPGhwn25nvnG89Qwr05j5b8iQWK4dlAI3laP/7PW9cQtG FD2YOOG8pKADwUkPO+jaUoeta6L6c71wnuUQ0ZxaN0Y96HHJpmEE+u5DVWGf3rHq TTTvmxXzFfPIOxYy+qUokZAchx9Sw20cIfe5BPWTjGuqi4b8Sbw+oeRNToH8lcf1 Gk3aWFbWckwF0Gt5yq3M14/UzktH6C1Z3/S0022joqpWNx7PfZMzpjrv4xuQavyS nLudaJZeQcr6lK0Oe/pg21VJv/51x+7Qb9VYXFR/wozf004o40LBMbuyFk0ro6Ak xmnhXd7iErtqwiLsVjUrTLyvvJ+V/19auLCk+8hBStX5dH0Q5APyaYIdbuwQ1MCn kXCOpIqI4HsNN0EiHo6LRqgyDWg0RZubPiR4PEd1p+MrXR7iaZgaRz8dhZ6mlgRH CptpnqRvNGYGIdUGsjrB4KV0d6tfq4ldxoD3E0Lm/0/Q73fN05swlEbrmzaXre6u Xppgl5qVPeSbE6ZMyTvi =q8DN -----END PGP SIGNATURE----- --Apple-Mail=_3158879A-AB5C-45EE-900B-38C69308CB43-- From owner-svn-src-head@freebsd.org Tue May 23 21:40:08 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3BD65D7B0FE; Tue, 23 May 2017 21:40:08 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from mx1.scaleengine.net (mx1.scaleengine.net [209.51.186.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 168A31C16; Tue, 23 May 2017 21:40:07 +0000 (UTC) (envelope-from allanjude@freebsd.org) Received: from [192.168.1.10] (unknown [192.168.1.10]) (Authenticated sender: allanjude.freebsd@scaleengine.com) by mx1.scaleengine.net (Postfix) with ESMTPSA id 4D19413719; Tue, 23 May 2017 21:40:00 +0000 (UTC) Subject: Re: svn commit: r318757 - head To: Alexey Dokuchaev , Ed Maste References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: Allan Jude Message-ID: Date: Tue, 23 May 2017 17:39:50 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <20170523213306.GA74154@FreeBSD.org> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="8EOgERNrMS4TpFKonWhVKT148xaD8918m" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 21:40:08 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --8EOgERNrMS4TpFKonWhVKT148xaD8918m Content-Type: multipart/mixed; boundary="FaPg3vpMjwdeVcvUEJFO4wiTLFOBFoQTr"; protected-headers="v1" From: Allan Jude To: Alexey Dokuchaev , Ed Maste Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-ID: Subject: Re: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> In-Reply-To: <20170523213306.GA74154@FreeBSD.org> --FaPg3vpMjwdeVcvUEJFO4wiTLFOBFoQTr Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 2017-05-23 17:33, Alexey Dokuchaev wrote: > On Tue, May 23, 2017 at 08:25:49PM +0000, Ed Maste wrote: >> New Revision: 318757 >> URL: https://svnweb.freebsd.org/changeset/base/318757 >> >> Log: >> Add note to UPDATING for ino64 to follow the standard upgrade proces= s >> ... >> +20170523: >> + The "ino64" 64-bit inode project has been committed, which extends >> + a number of types to 64 bits. >=20 > For the dumb people among us, what is it all about? E.g., what's so co= ol > about it? >=20 > ./danfe >=20 64bit inodes allow you to have more than 4 billion files in one file system, or NFS mount. The project also includes fixing a number of other long-standing-because-of-ABI changes, like the max length of a mountpoint is now 1024 instead of some small value (60 or 80 or something it was before) --=20 Allan Jude --FaPg3vpMjwdeVcvUEJFO4wiTLFOBFoQTr-- --8EOgERNrMS4TpFKonWhVKT148xaD8918m Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (MingW32) iQIcBAEBAgAGBQJZJKwsAAoJEBmVNT4SmAt+YX4P/ibdx3JimySwjrma5bGUGjsS Hb1q7CaH8jyI5AxZuxsCd4uSNQHD8k11ivJ1290MJ4pdLqE5yyUOqp2ZSFV4UPn4 YE6smNxqwx6TSlv95Q+dgolPirfF/n+cmsfG5FGFslkr3hwLM+11gCff1BDUmwWV Qf2Ipv8or6XoANO7QMbiF9TQObBNMLRG6n6OIAQyKigNlfpQfsEOOnl0CpTce2Ew iMXo3IQiBrkUFPX0TxhxQo0P0EfguVbsWM08OXTHCk1wQBe83LN+RM7Ok/svZZKH XXCB+ZQjT22uP0YDIzIHTOrCuohSak6yJBumYNB6WsE9Bmyyv4aSwv5X8F5IVJ7l 3OSt3Quj+uL5p6GF5FOuCdnMElOORUCVMpU1ZqDBOsrbQ5kbA7L6qwKdp26yqG7A qr2mJSbiNeMhP0s+/xsQsi4iaQM1R9a3ZyqwqJTKKducG8xlEMoplj9wnzd8DKCw OpS7IC+HzNTjTdGAQEsQUmrzOZh+evsnzFbAe2prbj+1DyyHDQaQ5FrsZ8g6QinZ ZuvW0EPksXb/gJHcNgQ0O7Rb1GmurOkJOZLBv4LJrB6PMCFhtmNnoN1YDq/+OY5L pjfQJk7zrdu5T//ATg0wxj2nTpDb5+9S2w20SzdKvIbdPS6ehx2XtPGz0EB+ynCJ yolfsbcWWV5C7pz4Mdow =e9in -----END PGP SIGNATURE----- --8EOgERNrMS4TpFKonWhVKT148xaD8918m-- From owner-svn-src-head@freebsd.org Tue May 23 21:46:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CA524D7B508; Tue, 23 May 2017 21:46:45 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A35C3119E; Tue, 23 May 2017 21:46:45 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:To:From:Subject:Date:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=IPQmzfuPLbRYFKxussXGmH4b4N+QyyWhHDqtFJHI++E=; b=pxnNU7G7rxjNufc6K3OhBH580P Y5vPqeu/cWuRyTFB48rDUpcKLrSxyX3FhtBmq4gl/u/8HhhDzbFskHxslQn+ydWiCu6AA7/x24ZGz ekrBgtUabd8HC/y5ret76ZBoVmR6jZakQgMFEfZeqYVKNedDp3GOMb9VPDxuArKw6twA=; Received: from [74.203.163.58] (port=38685 helo=[10.106.10.44]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDHdc-0008Zx-Kb; Tue, 23 May 2017 16:46:44 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Tue, 23 May 2017 16:46:14 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: Ed Maste , , , , "freebsd-current@freebsd.org" Message-ID: Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> In-Reply-To: <201705232025.v4NKPnrH001395@repo.freebsd.org> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: quoted-printable X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 21:46:45 -0000 My PostgreSQL buildfarm animal BROKE with this change until I force rebuilt lang/perl5.24 and all my p5-* ports.=20 emulators/qemu-user-static also won=E2=80=99t compile (sbruno@ is on this one). Poudriere did *NOT* force a fuill rebuild even though freebsd-version *WAS*= bumped.=20 Is there a hazard for others here? Or more info needed in /usr/{src,ports}/UPDATING? --=20 Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 =20 From owner-svn-src-head@freebsd.org Tue May 23 21:56:16 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 719D7D7BA54; Tue, 23 May 2017 21:56:16 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (turbocat.net [88.99.82.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 394ED1B7E; Tue, 23 May 2017 21:56:15 +0000 (UTC) (envelope-from hps@selasky.org) Received: from hps2016.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 86FC0260874; Tue, 23 May 2017 23:56:13 +0200 (CEST) Subject: Re: svn commit: r318757 - head To: Alexey Dokuchaev , Ed Maste Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "kwm@freebsd.org" References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> From: Hans Petter Selasky Message-ID: <9f3bfde8-370c-0d22-d076-1e57cbba4aa0@selasky.org> Date: Tue, 23 May 2017 23:54:14 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.0.1 MIME-Version: 1.0 In-Reply-To: <20170523213306.GA74154@FreeBSD.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 21:56:16 -0000 On 05/23/17 23:33, Alexey Dokuchaev wrote: > On Tue, May 23, 2017 at 08:25:49PM +0000, Ed Maste wrote: >> New Revision: 318757 >> URL: https://svnweb.freebsd.org/changeset/base/318757 >> >> Log: >> Add note to UPDATING for ino64 to follow the standard upgrade process >> ... >> +20170523: >> + The "ino64" 64-bit inode project has been committed, which extends >> + a number of types to 64 bits. > > For the dumb people among us, what is it all about? E.g., what's so cool > about it? Hi, /usr/ports/multimedia/webcamd should be updated after this change to the latest version. See e-mail to freebsd-multimedia@freebsd.org . Else there will be some breakage in /usr/ports for X.org . I would prefer that webcamd was updated before putting this change into -head, but anyway the road is a bit bumpy sometimes. --HPS From owner-svn-src-head@freebsd.org Tue May 23 22:07:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C82FDD7BDFC for ; Tue, 23 May 2017 22:07:30 +0000 (UTC) (envelope-from 0100015c3759ac15-cf2b6f26-1221-4340-9a79-885f246055ea-000000@amazonses.com) Received: from a8-56.smtp-out.amazonses.com (a8-56.smtp-out.amazonses.com [54.240.8.56]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 887871487 for ; Tue, 23 May 2017 22:07:29 +0000 (UTC) (envelope-from 0100015c3759ac15-cf2b6f26-1221-4340-9a79-885f246055ea-000000@amazonses.com) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=ae7m2yrxjw65l2cqdpjxuucyrvy564tn; d=tarsnap.com; t=1495577243; h=Subject:To:References:Cc:From:Message-ID:Date:MIME-Version:In-Reply-To:Content-Type:Content-Transfer-Encoding; bh=tq32Mp1xfGFIvk9Um/L58cD/+KIod1VkKBaANEOShmI=; b=ia3jSNGKBcPJQfeTi8yRCFPNVg98vdTOu8TcwiRsyguEHugVbc7432pA7WHCAS1d 5rpAR8Rw+YLexDpw2nmbWBBQDE6p9gtlnjKwRDuAGtaMSV7aTm9SSYzHFrdLOiLEo4A pPglt+nzKnCvI00+7HCccAD6pEiFhnUcABje6HMI= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/simple; s=224i4yxa5dv7c2xz3womw6peuasteono; d=amazonses.com; t=1495577242; h=Subject:To:References:Cc:From:Message-ID:Date:MIME-Version:In-Reply-To:Content-Type:Content-Transfer-Encoding:Feedback-ID; bh=tq32Mp1xfGFIvk9Um/L58cD/+KIod1VkKBaANEOShmI=; b=VpWOtyswy6vQdJxN3tWc5YH5A+LpH/aEikRlKOEFXOMxwFvKcJoxnbi9ePgGS/S9 dtlhWIla459eyG8ud0Z0k83uk1Y4pFripMfSMplUuRfkOUJldBtTtD4LSAKQHKmn77A eqx5bjhrGts4OHNqlzDw4Zp+ow8x2wJzE9iR1ugU= Subject: Re: svn commit: r318757 - head To: Allan Jude , Alexey Dokuchaev , Ed Maste References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: Colin Percival Message-ID: <0100015c3759ac15-cf2b6f26-1221-4340-9a79-885f246055ea-000000@email.amazonses.com> Date: Tue, 23 May 2017 22:07:22 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SES-Outgoing: 2017.05.23-54.240.8.56 Feedback-ID: 1.us-east-1.Lv9FVjaNvvR5llaqfLoOVbo2VxOELl7cjN0AOyXnPlk=:AmazonSES X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 22:07:30 -0000 On 05/23/17 14:39, Allan Jude wrote: > On 2017-05-23 17:33, Alexey Dokuchaev wrote: >> On Tue, May 23, 2017 at 08:25:49PM +0000, Ed Maste wrote: >>> New Revision: 318757 >>> URL: https://svnweb.freebsd.org/changeset/base/318757 >>> >>> Log: >>> Add note to UPDATING for ino64 to follow the standard upgrade process >>> ... >>> +20170523: >>> + The "ino64" 64-bit inode project has been committed, which extends >>> + a number of types to 64 bits. >> >> For the dumb people among us, what is it all about? E.g., what's so cool >> about it? > > 64bit inodes allow you to have more than 4 billion files in one file > system, or NFS mount. It can avoid problems on NFS even if you have less than 2^32 files, since NFS uses 64-bit fileids and is not required to use the values 0, 1, 2, 3... for files. In Amazon EFS for example every fileid is > 2^32 and there's no guarantee that two files won't map to the same 32-bit inode # (pre-ino64, we simply reduced the fileid mod 2^32 to generate an inode #). -- Colin Percival Security Officer Emeritus, FreeBSD | The power to serve Founder, Tarsnap | www.tarsnap.com | Online backups for the truly paranoid From owner-svn-src-head@freebsd.org Tue May 23 22:30:16 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3EA1D78231; Tue, 23 May 2017 22:30:16 +0000 (UTC) (envelope-from landonf@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 70ED91E96; Tue, 23 May 2017 22:30:16 +0000 (UTC) (envelope-from landonf@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NMUFc3051323; Tue, 23 May 2017 22:30:15 GMT (envelope-from landonf@FreeBSD.org) Received: (from landonf@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NMUFj9051321; Tue, 23 May 2017 22:30:15 GMT (envelope-from landonf@FreeBSD.org) Message-Id: <201705232230.v4NMUFj9051321@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: landonf set sender to landonf@FreeBSD.org using -f From: "Landon J. Fuller" Date: Tue, 23 May 2017 22:30:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318760 - head/sys/dev/bhnd/nvram 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.23 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, 23 May 2017 22:30:16 -0000 Author: landonf Date: Tue May 23 22:30:15 2017 New Revision: 318760 URL: https://svnweb.freebsd.org/changeset/base/318760 Log: bhnd(4): Fix a SPROM identification regression introduced in r315866 In r315866, we introduced a direct read of the 8-bit sromrev field from the memory mapped SPROM/OTP device. On OTP devices that require 16-bit access alignment, this read fails, preventing identification of the SPROM layout. So, let's perform an aligned read of the combined 16-bit sromrev/crc field instead. Approved by: adrian (mentor, implicit) Modified: head/sys/dev/bhnd/nvram/bhnd_nvram_data_sprom.c head/sys/dev/bhnd/nvram/bhnd_sprom.c Modified: head/sys/dev/bhnd/nvram/bhnd_nvram_data_sprom.c ============================================================================== --- head/sys/dev/bhnd/nvram/bhnd_nvram_data_sprom.c Tue May 23 22:11:45 2017 (r318759) +++ head/sys/dev/bhnd/nvram/bhnd_nvram_data_sprom.c Tue May 23 22:30:15 2017 (r318760) @@ -184,6 +184,7 @@ bhnd_nvram_sprom_ident(struct bhnd_nvram u_char buf[512]; size_t nread; uint16_t magic; + uint8_t srevcrc[2]; uint8_t srev; bool crc_valid; bool have_magic; @@ -224,12 +225,15 @@ bhnd_nvram_sprom_ident(struct bhnd_nvram nbytes += nr; } - /* Read SPROM revision */ - error = bhnd_nvram_io_read(io, layout->srev_offset, &srev, - sizeof(srev)); + /* Read 8-bit SPROM revision, maintaining 16-bit size alignment + * required by some OTP/SPROM chipsets. */ + error = bhnd_nvram_io_read(io, layout->srev_offset, &srevcrc, + sizeof(srevcrc)); if (error) return (error); + srev = srevcrc[0]; + /* Early sromrev 1 devices (specifically some BCM440x enet * cards) are reported to have been incorrectly programmed * with a revision of 0x10. */ Modified: head/sys/dev/bhnd/nvram/bhnd_sprom.c ============================================================================== --- head/sys/dev/bhnd/nvram/bhnd_sprom.c Tue May 23 22:11:45 2017 (r318759) +++ head/sys/dev/bhnd/nvram/bhnd_sprom.c Tue May 23 22:30:15 2017 (r318760) @@ -120,9 +120,9 @@ bhnd_sprom_attach(device_t dev, bus_size sprom_size = r_size - offset; - /* Allocate an I/O context for the SPROM parser. SPROM reads do not - * appear to require any specific alignment. */ - io = bhnd_nvram_iores_new(r, offset, sprom_size, 1); + /* Allocate an I/O context for the SPROM parser. All SPROM reads + * must be 16-bit aligned */ + io = bhnd_nvram_iores_new(r, offset, sprom_size, sizeof(uint16_t)); if (io == NULL) { error = ENXIO; goto failed; From owner-svn-src-head@freebsd.org Tue May 23 22:34:19 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9C620D784DF; Tue, 23 May 2017 22:34:19 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6E8EB1471; Tue, 23 May 2017 22:34:19 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NMYIng055166; Tue, 23 May 2017 22:34:18 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NMYIOE055164; Tue, 23 May 2017 22:34:18 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201705232234.v4NMYIOE055164@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 23 May 2017 22:34:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318761 - in head/sys: i386/i386 x86/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.23 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, 23 May 2017 22:34:19 -0000 Author: jhb Date: Tue May 23 22:34:18 2017 New Revision: 318761 URL: https://svnweb.freebsd.org/changeset/base/318761 Log: Remove the BSD/OS 2.1 system call gate LDT entry. An extra copy of the system call gate was added to the default LDT back in 1996 (r18513 / r18514). However, the ability to run BSD/OS 2.1 i386 binaries under FreeBSD's native ABI is most likely no longer needed. Discussed with: kib Modified: head/sys/i386/i386/machdep.c head/sys/x86/include/segments.h Modified: head/sys/i386/i386/machdep.c ============================================================================== --- head/sys/i386/i386/machdep.c Tue May 23 22:30:15 2017 (r318760) +++ head/sys/i386/i386/machdep.c Tue May 23 22:34:18 2017 (r318761) @@ -2446,10 +2446,6 @@ init386(int first) gdp->gd_p = 1; gdp->gd_hioffset = x >> 16; - /* XXX does this work? */ - /* XXX yes! */ - ldt[LBSDICALLS_SEL] = ldt[LSYS5CALLS_SEL]; - /* transfer to user mode */ _ucodesel = GSEL(GUCODE_SEL, SEL_UPL); Modified: head/sys/x86/include/segments.h ============================================================================== --- head/sys/x86/include/segments.h Tue May 23 22:30:15 2017 (r318760) +++ head/sys/x86/include/segments.h Tue May 23 22:34:18 2017 (r318761) @@ -252,8 +252,7 @@ union descriptor { #define LUDATA_SEL 5 /* separate stack, es,fs,gs sels ? */ /* #define LPOSIXCALLS_SEL 5*/ /* notyet */ -#define LBSDICALLS_SEL 16 /* BSDI system call gate */ -#define NLDT (LBSDICALLS_SEL + 1) +#define NLDT (LUDATA_SEL + 1) #else /* !__i386__ */ /* From owner-svn-src-head@freebsd.org Tue May 23 23:09:02 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B7FC1D78D68; Tue, 23 May 2017 23:09:02 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 794AB12EF; Tue, 23 May 2017 23:09:02 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (unknown [127.0.1.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by freefall.freebsd.org (Postfix) with ESMTPS id 8675D2A00; Tue, 23 May 2017 23:09:01 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (localhost [172.31.3.2]) by mail.xzibition.com (Postfix) with ESMTP id 40A6D623D; Tue, 23 May 2017 23:09:00 +0000 (UTC) X-Virus-Scanned: amavisd-new at mail.xzibition.com Received: from mail.xzibition.com ([172.31.3.2]) by mail.xzibition.com (mail.xzibition.com [172.31.3.2]) (amavisd-new, port 10026) with LMTP id 8s_2dUNIxS1D; Tue, 23 May 2017 23:08:57 +0000 (UTC) Subject: Re: svn commit: r318757 - head DKIM-Filter: OpenDKIM Filter v2.9.2 mail.xzibition.com 22F5F6238 To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" References: <201705232025.v4NKPnrH001395@repo.freebsd.org> From: Bryan Drewery Openpgp: id=F9173CB2C3AAEA7A5C8A1F0935D771BB6E4697CF; url=http://www.shatow.net/bryan/bryan2.asc Organization: FreeBSD Message-ID: Date: Tue, 23 May 2017 16:08:30 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7ngPRtaOIQbnxJqNeuRdJSqjKauXNvC3g" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 23:09:02 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --7ngPRtaOIQbnxJqNeuRdJSqjKauXNvC3g Content-Type: multipart/mixed; boundary="O416vTc3HT3obfmXbKHFLdbWDPBt5iOtr"; protected-headers="v1" From: Bryan Drewery To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Message-ID: Subject: Re: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> In-Reply-To: --O416vTc3HT3obfmXbKHFLdbWDPBt5iOtr Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 5/23/2017 2:46 PM, Larry Rosenman wrote: > My PostgreSQL buildfarm animal BROKE with this change until I force reb= uilt > lang/perl5.24 > and all my p5-* ports.=20 >=20 > emulators/qemu-user-static also won=E2=80=99t compile (sbruno@ is on th= is one). >=20 > Poudriere did *NOT* force a fuill rebuild even though freebsd-version *= WAS* bumped.=20 >=20 It should have. What version are you using? Can you show output of 'poudriere jail -l' please? And show /usr/local/etc/poudriere.d/jails/JAILNAME/version And show the .jailversion output from your PACKAGES directory. > Is there a hazard for others here? >=20 > Or more info needed in /usr/{src,ports}/UPDATING? >=20 >=20 --=20 Regards, Bryan Drewery --O416vTc3HT3obfmXbKHFLdbWDPBt5iOtr-- --7ngPRtaOIQbnxJqNeuRdJSqjKauXNvC3g Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBAgAGBQJZJMD3AAoJEDXXcbtuRpfPv+UIANL/FGjoyrgsYparr9NuMLV0 sOU79WRCvMeJd8+HhfzU7bDLGuIHxleKQrIw4NcLnwTSDAai2oGvAjIRlW47TUk/ Bpha4qpyVvy/+craFBMDWBYPxGIgB762kQ5mc6I0GHY+eYRXl5FZ6oRK4bBd/Y0o sep9MsiBoOEo3SIGdS0Lw48jfrlWFE1ijI/oUKVg57BI7hQfhV9HydJh5ygVp20u 7NY0VQ+RvCO7uohogyAZ2IwJNM9csK+a92HYjzZ/K09WMBKn573B2Z3cn2mXBlKl EHe/+MxC7TbLWIk9BOxJQAr9ItHVTAvXdBxYTmlpFBUlVKfEx4V1wlZRq/iRFn8= =NC5t -----END PGP SIGNATURE----- --7ngPRtaOIQbnxJqNeuRdJSqjKauXNvC3g-- From owner-svn-src-head@freebsd.org Tue May 23 23:24:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 83B4FD793BD; Tue, 23 May 2017 23:24:32 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 614891C6A; Tue, 23 May 2017 23:24:32 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:To:From:Subject:Date:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=BkXt1vaTsoO61oeUQp+TW7ZvYwJ59C3ZZK5X8bZ8uyw=; b=DAW8APJZ8S0Or6q1la3/kDKwlk CWKNWMg70klgOrdTq/gK90Oj8h7GlqysyzRTZay4VVWbxqXh/GO4egTR1QvSzFqfXOpphkzYmZh76 fM8wFjgD0GFefz4RRrCFcnE+BKwo5UXAYGns+cIxGkoSzbVvFp9boLCIki1AF3kq9e+Y=; Received: from adsl-108-90-214-189.dsl.aus2tx.sbcglobal.net ([108.90.214.189]:57713 helo=[172.18.245.140]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDJAF-000BZ6-2K; Tue, 23 May 2017 18:24:31 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Tue, 23 May 2017 18:24:28 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: Bryan Drewery , Ed Maste , , , , "freebsd-current@freebsd.org" Message-ID: <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> In-Reply-To: Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: quoted-printable X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 23:24:32 -0000 borg.lerctr.org /home/ler $ sudo poudriere jail -l JAILNAME VERSION ARCH METHOD TIMESTAMP = PATH p103amd64 10.3-RELEASE-p18 amd64 http 2017-04-23 08:39:24 = /usr/local/poudriere/jails/p103amd64 p103i386 10.3-RELEASE-p18 i386 http 2017-04-23 08:40:44 = /usr/local/poudriere/jails/p103i386 p110amd64 11.0-RELEASE-p10 amd64 http 2017-05-15 14:54:58 = /usr/local/poudriere/jails/p110amd64 p110i386 11.0-RELEASE-p9 i386 http 2017-04-23 08:41:48 = /usr/local/poudriere/jails/p110i386 live 12.0-CURRENT amd64 src=3D/usr/src 2017-05-23 13:39:40 = /usr/local/poudriere/jails/live pHEADamd64 12.0-CURRENT amd64 src=3D/usr/src 2017-04-24 17:15:13 = /usr/local/poudriere/jails/pHEADamd64 p120armv6 12.0-CURRENT r317340 arm.armv6 svn+https 2017-04-23 10:07:40 = /usr/local/poudriere/jails/p110borg.lerctr.org /usr/local/etc/poudriere.d/ja= ils/live $ cat version 12.0-CURRENT borg.lerctr.org /usr/local/etc/poudriere.d/jails/live $armv6 borg.lerctr.org /home/ler $ borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ cat .j= ailversion 12.0-CURRENT borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ --=20 Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 =20 =20 On 5/23/17, 6:08 PM, "Bryan Drewery" wrote: On 5/23/2017 2:46 PM, Larry Rosenman wrote: > My PostgreSQL buildfarm animal BROKE with this change until I force r= ebuilt > lang/perl5.24 > and all my p5-* ports.=20 >=20 > emulators/qemu-user-static also won=E2=80=99t compile (sbruno@ is on this o= ne). >=20 > Poudriere did *NOT* force a fuill rebuild even though freebsd-version= *WAS* bumped.=20 >=20 =20 It should have. What version are you using? Can you show output of 'poudriere jail -l' please? And show /usr/local/etc/poudriere.d/jails/JAILNAME/version And show the .jailversion output from your PACKAGES directory. =20 > Is there a hazard for others here? >=20 > Or more info needed in /usr/{src,ports}/UPDATING? >=20 >=20 =20 =20 --=20 Regards, Bryan Drewery =20 =20 From owner-svn-src-head@freebsd.org Tue May 23 23:29:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BFFC2D79599; Tue, 23 May 2017 23:29:36 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7453A1F4F; Tue, 23 May 2017 23:29:36 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (unknown [127.0.1.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by freefall.freebsd.org (Postfix) with ESMTPS id 5C3292E92; Tue, 23 May 2017 23:29:35 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (localhost [172.31.3.2]) by mail.xzibition.com (Postfix) with ESMTP id 85EB26278; Tue, 23 May 2017 23:29:34 +0000 (UTC) X-Virus-Scanned: amavisd-new at mail.xzibition.com Received: from mail.xzibition.com ([172.31.3.2]) by mail.xzibition.com (mail.xzibition.com [172.31.3.2]) (amavisd-new, port 10026) with LMTP id wlQCwxoyB8JK; Tue, 23 May 2017 23:29:27 +0000 (UTC) Subject: Re: svn commit: r318757 - head DKIM-Filter: OpenDKIM Filter v2.9.2 mail.xzibition.com D0D126273 To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> From: Bryan Drewery Openpgp: id=F9173CB2C3AAEA7A5C8A1F0935D771BB6E4697CF; url=http://www.shatow.net/bryan/bryan2.asc Organization: FreeBSD Message-ID: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> Date: Tue, 23 May 2017 16:29:26 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7eDIcNVIx9U8VmIiW83X24XGONA0TUhKX" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 23:29:36 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --7eDIcNVIx9U8VmIiW83X24XGONA0TUhKX Content-Type: multipart/mixed; boundary="9GFaLkKRl5JbSf39It2Jhcnhfwof5N4lD"; protected-headers="v1" From: Bryan Drewery To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Message-ID: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> Subject: Re: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> In-Reply-To: <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> --9GFaLkKRl5JbSf39It2Jhcnhfwof5N4lD Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 5/23/2017 4:24 PM, Larry Rosenman wrote: > borg.lerctr.org /home/ler $ sudo poudriere jail -l > JAILNAME VERSION ARCH METHOD TIMESTAMP = PATH > p103amd64 10.3-RELEASE-p18 amd64 http 2017-04-23 08:39= :24 /usr/local/poudriere/jails/p103amd64 > p103i386 10.3-RELEASE-p18 i386 http 2017-04-23 08:40= :44 /usr/local/poudriere/jails/p103i386 > p110amd64 11.0-RELEASE-p10 amd64 http 2017-05-15 14:54= :58 /usr/local/poudriere/jails/p110amd64 > p110i386 11.0-RELEASE-p9 i386 http 2017-04-23 08:41= :48 /usr/local/poudriere/jails/p110i386 > live 12.0-CURRENT amd64 src=3D/usr/src 2017-05-23 13:= 39:40 /usr/local/poudriere/jails/live > pHEADamd64 12.0-CURRENT amd64 src=3D/usr/src 2017-04-24 17:= 15:13 /usr/local/poudriere/jails/pHEADamd64 > p120armv6 12.0-CURRENT r317340 arm.armv6 svn+https 2017-04-23 10:07= :40 /usr/local/poudriere/jails/p110borg.lerctr.org /usr/local/etc/poudrie= re.d/jails/live $ cat version > 12.0-CURRENT > borg.lerctr.org /usr/local/etc/poudriere.d/jails/live $armv6 > borg.lerctr.org /home/ler $ >=20 >=20 > borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ ca= t .jailversion > 12.0-CURRENT > borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ >=20 >=20 >=20 That looks like a bug in Poudriere with -m src. It is using 12.0-CURRENT rather than __FreeBSD_version of 1200031. I'm working on a fix. --=20 Regards, Bryan Drewery --9GFaLkKRl5JbSf39It2Jhcnhfwof5N4lD-- --7eDIcNVIx9U8VmIiW83X24XGONA0TUhKX Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBAgAGBQJZJMXWAAoJEDXXcbtuRpfP/FkIANUr5zRaopwkNsKDg44grl0M PtWHRYAOLX1vmgrMgNRhPv8e+nbb9T2tgb9U4T1N3uJ9ifuD6j6IVWrX6+nCBI0m OzUnoPfG0ieXwOauYthNBx0EHAYL2y2AyM3aJJt0v/FUgdfs2XOFDja8hc+7C20H 5ztPJluCKvfPU88zEzwrMkWQMdDhFIn7CZyJjddr/6zU4JBEFzDwH6A8k/+hE9Kw nNkx2htz2HkW46U8f6nuG47ot3G5v90ntztVqwlPWS9OmCsq9TH2oaFQ9Fu9VqRw 81546gDaEW6FW4EBm/d0UXF3/zG0ddnp19FCoflVLpjfpJhhDcePPXpip0SlhG8= =P2A5 -----END PGP SIGNATURE----- --7eDIcNVIx9U8VmIiW83X24XGONA0TUhKX-- From owner-svn-src-head@freebsd.org Tue May 23 23:33:14 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 11C17D798C6; Tue, 23 May 2017 23:33:14 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D187A1562; Tue, 23 May 2017 23:33:13 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (unknown [127.0.1.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by freefall.freebsd.org (Postfix) with ESMTPS id D3BC13067; Tue, 23 May 2017 23:33:12 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (localhost [172.31.3.2]) by mail.xzibition.com (Postfix) with ESMTP id 187AF628F; Tue, 23 May 2017 23:33:12 +0000 (UTC) X-Virus-Scanned: amavisd-new at mail.xzibition.com Received: from mail.xzibition.com ([172.31.3.2]) by mail.xzibition.com (mail.xzibition.com [172.31.3.2]) (amavisd-new, port 10026) with LMTP id 5XmE4Ocyl3D8; Tue, 23 May 2017 23:33:06 +0000 (UTC) Subject: Re: svn commit: r318757 - head DKIM-Filter: OpenDKIM Filter v2.9.2 mail.xzibition.com 88219628A From: Bryan Drewery To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> Openpgp: id=F9173CB2C3AAEA7A5C8A1F0935D771BB6E4697CF; url=http://www.shatow.net/bryan/bryan2.asc Organization: FreeBSD Message-ID: <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org> Date: Tue, 23 May 2017 16:33:06 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="sIw1a8MPU8obGIEqPMSjxuV84b026de6m" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 23:33:14 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --sIw1a8MPU8obGIEqPMSjxuV84b026de6m Content-Type: multipart/mixed; boundary="8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr"; protected-headers="v1" From: Bryan Drewery To: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Message-ID: <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org> Subject: Re: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> In-Reply-To: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> --8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 5/23/2017 4:29 PM, Bryan Drewery wrote: > On 5/23/2017 4:24 PM, Larry Rosenman wrote: >> borg.lerctr.org /home/ler $ sudo poudriere jail -l >> JAILNAME VERSION ARCH METHOD TIMESTAMP = PATH >> p103amd64 10.3-RELEASE-p18 amd64 http 2017-04-23 08:3= 9:24 /usr/local/poudriere/jails/p103amd64 >> p103i386 10.3-RELEASE-p18 i386 http 2017-04-23 08:4= 0:44 /usr/local/poudriere/jails/p103i386 >> p110amd64 11.0-RELEASE-p10 amd64 http 2017-05-15 14:5= 4:58 /usr/local/poudriere/jails/p110amd64 >> p110i386 11.0-RELEASE-p9 i386 http 2017-04-23 08:4= 1:48 /usr/local/poudriere/jails/p110i386 >> live 12.0-CURRENT amd64 src=3D/usr/src 2017-05-23 13= :39:40 /usr/local/poudriere/jails/live >> pHEADamd64 12.0-CURRENT amd64 src=3D/usr/src 2017-04-24 17= :15:13 /usr/local/poudriere/jails/pHEADamd64 >> p120armv6 12.0-CURRENT r317340 arm.armv6 svn+https 2017-04-23 10:0= 7:40 /usr/local/poudriere/jails/p110borg.lerctr.org /usr/local/etc/poudri= ere.d/jails/live $ cat version >> 12.0-CURRENT >> borg.lerctr.org /usr/local/etc/poudriere.d/jails/live $armv6 >> borg.lerctr.org /home/ler $ >> >> >> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ c= at .jailversion >> 12.0-CURRENT >> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ >> >> >> >=20 > That looks like a bug in Poudriere with -m src. It is using 12.0-CURREN= T > rather than __FreeBSD_version of 1200031. I'm working on a fix. >=20 Usually Poudriere, for head, will rebuild if the SVN revision changes. It is very liberal with rebuilds on head and does not usually consider __FreeBSD_version since it can be forgotten, and historically was not always bumped on SA/EN either so we used the uname -r output. So this bug is limited to -m src|null|tar. --=20 Regards, Bryan Drewery --8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr-- --sIw1a8MPU8obGIEqPMSjxuV84b026de6m Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBAgAGBQJZJMayAAoJEDXXcbtuRpfPcd0IAKm8P8McX5I9yUZbOWf8I4Ms cz9Uhts2sDuaiAD1pGRR3/POZmljGebUQks2eX6BVdUz0Uwol6APEs+TK1M8BXBW 3RtL5pXGbjK4fx88DOpRuuWyi8/jZtGmscf4P+miMWPEqE9N7PM1oW41yT13zxmg n67e8BDAbMQTelEd2DZGpHx9QiqZp66ilhUXbQamp709WIBgzDnvzw/JLlogo/ya DigzeoUSsnbznKilvdhQHfTZqYzOOcoYJX7sPcyoS+OG/xLcN9ZxKYoy6ZSeoQ5s ZFQgcFOKhBGUSZwC4Zi4e4e5m6Ruu614wdlbdygD29gmm0WCvfVz+/wSASdRgX0= =3K0J -----END PGP SIGNATURE----- --sIw1a8MPU8obGIEqPMSjxuV84b026de6m-- From owner-svn-src-head@freebsd.org Tue May 23 23:40:19 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0775ED79AD6; Tue, 23 May 2017 23:40:19 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 777AA19FA; Tue, 23 May 2017 23:40:18 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4NNeH5a081290; Tue, 23 May 2017 23:40:17 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4NNeHS0081287; Tue, 23 May 2017 23:40:17 GMT (envelope-from np@FreeBSD.org) Message-Id: <201705232340.v4NNeHS0081287@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Tue, 23 May 2017 23:40:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318762 - in head/sys: conf dev/cxgbe/firmware modules/cxgbe/t4_firmware modules/cxgbe/t5_firmware modules/cxgbe/t6_firmware 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.23 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, 23 May 2017 23:40:19 -0000 Author: np Date: Tue May 23 23:40:17 2017 New Revision: 318762 URL: https://svnweb.freebsd.org/changeset/base/318762 Log: cxgbe(4): Update the T4, T5, and T6 firmwares to 1.16.45.0. The latest firmware has a number of link related fixes, support for a new custom card, and the fix for a bug that affected rate limiting on FreeBSD. Obtained from: Chelsio Communications MFC after: 1 week Sponsored by: Chelsio Communications Added: head/sys/dev/cxgbe/firmware/t4fw-1.16.45.0.bin.uu (contents, props changed) head/sys/dev/cxgbe/firmware/t5fw-1.16.45.0.bin.uu (contents, props changed) head/sys/dev/cxgbe/firmware/t6fw-1.16.45.0.bin.uu (contents, props changed) Deleted: head/sys/dev/cxgbe/firmware/t4fw-1.16.26.0.bin.uu head/sys/dev/cxgbe/firmware/t5fw-1.16.26.0.bin.uu head/sys/dev/cxgbe/firmware/t6fw-1.16.26.0.bin.uu Modified: head/sys/conf/files head/sys/dev/cxgbe/firmware/t4fw_cfg_uwire.txt head/sys/dev/cxgbe/firmware/t4fw_interface.h head/sys/dev/cxgbe/firmware/t5fw_cfg_uwire.txt head/sys/dev/cxgbe/firmware/t6fw_cfg_uwire.txt head/sys/modules/cxgbe/t4_firmware/Makefile head/sys/modules/cxgbe/t5_firmware/Makefile head/sys/modules/cxgbe/t6_firmware/Makefile Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Tue May 23 22:34:18 2017 (r318761) +++ head/sys/conf/files Tue May 23 23:40:17 2017 (r318762) @@ -1376,7 +1376,7 @@ t4fw.fwo optional cxgbe \ no-implicit-rule \ clean "t4fw.fwo" t4fw.fw optional cxgbe \ - dependency "$S/dev/cxgbe/firmware/t4fw-1.16.26.0.bin.uu" \ + dependency "$S/dev/cxgbe/firmware/t4fw-1.16.45.0.bin.uu" \ compile-with "${NORMAL_FW}" \ no-obj no-implicit-rule \ clean "t4fw.fw" @@ -1400,7 +1400,7 @@ t5fw.fwo optional cxgbe \ no-implicit-rule \ clean "t5fw.fwo" t5fw.fw optional cxgbe \ - dependency "$S/dev/cxgbe/firmware/t5fw-1.16.26.0.bin.uu" \ + dependency "$S/dev/cxgbe/firmware/t5fw-1.16.45.0.bin.uu" \ compile-with "${NORMAL_FW}" \ no-obj no-implicit-rule \ clean "t5fw.fw" @@ -1424,7 +1424,7 @@ t6fw.fwo optional cxgbe \ no-implicit-rule \ clean "t6fw.fwo" t6fw.fw optional cxgbe \ - dependency "$S/dev/cxgbe/firmware/t6fw-1.16.26.0.bin.uu" \ + dependency "$S/dev/cxgbe/firmware/t6fw-1.16.45.0.bin.uu" \ compile-with "${NORMAL_FW}" \ no-obj no-implicit-rule \ clean "t6fw.fw" Added: head/sys/dev/cxgbe/firmware/t4fw-1.16.45.0.bin.uu ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/cxgbe/firmware/t4fw-1.16.45.0.bin.uu Tue May 23 23:40:17 2017 (r318762) @@ -0,0 +1,9729 @@ +/*- + * Copyright (c) 2017 Chelsio Communications, 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: + * 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. + */ +begin-base64 644 t4fw +AAAEOAEQLQAAAQkEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAABBsEKgQyAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAENoZWxzaW8gRlcgUlVOTUVNIERFQlVHPTAgKEJ1aWx0IFRodSBNYXkgIDQgMDk6 +Mjg6NDAgUERUIDIwMTcgb24gdm5jNC5hc2ljZGVzaWduZXJzLmNvbTovaG9tZS9maXJtd2FyZS9j +dnMvZnctcmVsZWFzZSksIFZlcnNpb24gVDR4eCAwMS4xMC4yZC4wMAAAAAAAAAAAAAAAAI/sRllg +AMgA4QB78AAQAADhADC4eP///x/84UCAAAAB4QB7cAAAEAAf//2M4QGUcCAAAADhAZwE4QB5AAAC +AEDhAHmAAAYAQAACAAoABgAK4QB5BAAMAACAAAEC4QB7POEAe0ThAHvk4gAAAAABAADhAHuQIAAA +AAAAgADhAHsAAABAAeEAe5wAAEAAREREQuAAAADjAARzREREQOMACAAgAAJcAAAAAB//ktAAAAAA +H/+S1AAAAAAf/5LYAAAAAB//ktwf/8AAAAAAAAAAAADAABL/zRP/zZMgEv/NE//NhCAEMwGTIBH/ +zBL/zJIQEf/MEv/MkhAR/8wB9DER/8siCv+SEADkMQAFMQECABL/yALnMQIWABH/x4EQAQFfwCEC +EQHJERH/xBL/xJIQEf/EEv/EkhBgAA8R/78S/8OSEBH/vxL/wpIQgRAR/8HAIJIREv/AkhLAIJIT +Ev+/khCCEALyUGUv9xH/vccvkhAR/7ySEBL/vBP/vJMgwDKTIRP/u5MigiIS/7oT/7qTICMiIRT/ +uQQzAck4E/+4gzADgxQIMxEU/7akM5MhE/+qkyJgAAjCMJMhE/+nkyIS/7GQIJAhkCKQI5AkkCWQ +JpAnkCiQKZAqkCuQLJAtkC6QLyAmECAmEYIiEv+kwDAtNzAtNzQtNzgtNzwjPQFyM+0AAgAS/6HA +MC83AC83EC83IC83MCM9AXIz7QACABL/l8AwKDcwKDc0KDc4KDc8Iz0BcjPtEv+VwDAnNwAnNxAn +NyAnNzAjPQFyM+0S/5AV/5AW/5HAMNcgBWYBYAAZAAAAAAAAAAQ2BQACANMP0w8FMwxuOxQHRxQH +BEN2MeYENgUFMwxvO+0AAgAS/4MV/4EjCgACJwIHBEMEPgUFMwwHRxRvO/ADAgAS/33JLoMghCGF +IrwidDsOhlC0VZYwtDN0M/Rj/+YAZT/iZV/fEv9xwDIDLgUDAgAS/2jAMCg3QCg3RCg3SCg3TCM9 +AXIz7QACABL/ay0nAMARAUkxAEgxAQIAwAAU/2gE0jEV/2eUUBT/ZwTTMRX/ZpRQFP9mBNQxFf9m +lFAU/2UE1TEV/2WUUBD/ZQMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAf/AAA +H/wAAOMACfgf/AAAH/wAAOMACfgf/AAAH/wAAOMACfgf/4AAH/+KQOMACfgf/4pAH/+KQOMAFDgf +/4pAH/+KQOMAFDgf/4pAH/+L4OMAFDgf/4vgH/+SzOMAFdgf/5LQH/+z8OMAHMgf/7PwH/+z8OMA +Pegf/8AAH//+eeMAPeggAAAAIAABauMAfGQgAAF4IAABfOMAfdAgAAF8IAABheMAfdQgAAGYIAAB +nOMAfeAgAAGcIAABpeMAfeQgAAG4IAABvOMAffAgAAG8IAABxeMAffQgAAHYIAAB2OMAfgAgAAHc +IAAB4uMAfgAgAAH4IAAB+OMAfgggAAH8IAAB/OMAfgggAAIYIAACGOMAfgggAAIcIAACHOMAfggg +AAI4IAACOOMAfgggAAI8IAACPOMAfgggAAJYIAACWOMAfgggAAJcIAACYuMAfgggAAJ4IAACeOMA +fhAgAAJ8IAACguMAfhAgAAKYIAH4+eMAfhggAwAAIAMVtOMCdHwgAxW0IAMVtOMCijAgAxW4IAbx +XOMCijQgBvFgIAb00OMGZdwgCAAAIAgOYOMGaUwgCA5gIAkpjuMGd6wgCSmQIAkqXOMHktwgCwAA +IAsAAOMHk6ggCwAAIAsAAOMHk6ggCwAAIAuiCOMHk6gAAAAAAAAAAAAAAAAgABOOIAATgCAAF2og +ABOAIAAW5SAAE4AgABQyIAAWfSAAFgIgABOAIAAVsSAAFWogABT9IAATbSAAFKcgABOAIAATgCAA +E4AgABRSAAAAAP///////w/8///w////APwgALC+IACyMiAAsmIgALIoIACx6SAAsd8gALGuIACx +pCAAsZggALFHIACyYCAAsT0gALENIACyYiAAsQMgALDxARAYAQAEAAAAAAAAAAAAAAAAAAoAAAAK +AAAAFAAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQABAAEA +AQACAAMABAAFAAYABwAIAAkACgAOABEAFQAZAB4AIwAtADwAUABkAMgBLAGQAfQAAAAAAAAAAAAA +AAAAAAAAAAAAAQABAAIAAgADAAMAAwADAAQABAAEAAQABAAFAAUABQAFAAUABQAGAAYABwAHAAAA +AgAAAAYAAAAKAAAADgAAABQAAAAcAAAAKAAAADgAAABQAAAAcAAAAKAAAADgAAABQAAAAcAAAAKA +AAADgAAABQEAAAcAAAAKAAAADgAAABQAAAAcAAAAKAAAADgAAABQAAAAcAAAAKAAAADgAAABQAAA +AcAAAAKAAAADgAD/AAECAgAAABAgQAAAAAAABAACAAEAAIAAQAAgABAACCBAgAAAAAAAAAAAAAAA +AAAgCKlYIAipWCAIqQsgCKjYIAiooCAIqFsgCKhbIAiqiCAIqoggCKhbIAiqiCAIqoggCKhbIAio +WyAIqAYgCKqIIAiqiCAIqoggCKqIIAiqiCAIqoggCKqIIAiqiCAIqoggCKqIIAiqiCAIqoggCKqI +IAiqiCAIqoggCKqIIAioNyADCtAAAAABIAMK2AAAAAIgAw8YAAAA/yADCDAAAAD/IAMKvAAAAAIg +AwrAAAAAAyADCsgAAAAHAAAAAAAAAAAgAwqgAAAAASADCqQAAAACIAMKrAAAAAQgAw8YAAAA/yAD +CDAAAAD/AAAAAAAAAAAgAwgwAAAAACADDxgAAAAAIAMJbAAAAAEgAwl0AAAABCADCXwAAAAIIAMJ +iAAAACAgAwmYAAAAQCADCaAAAACAIAMJqAAAAQAgAwmwAAACACADCcQAAAQAIAMJ2AAACAAgAwnw +AAAQACADCgQAACAAIAMKFAAAQAAgAwogAACAACADCjQAAQAAIAMKRAACAAAgAwpUABAAACADCmwA +IAAAIAMKhABAAAAgAwqMAIAAACADCVgAAAAQIAMJYAAAABEgAwlAAAAAACADCUQAAAABIAMJSAAA +AAIgAwlQAAAAAwAAAAAAAP//AAAAAAAA//8gAwjAAAABACADCMwAAACAIAMI3AAAAEAgAwjsAAAA +ICADCPwAAAAQIAMJDAAAAAggAwkYAAAABCADCSQAAAACIAMJMAAAAAEAAAAAAAAAAAAAAAEAAAAB +AAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEA +AAAHAAAABwAAAAYAAAAGAAw1AAAQRqoAFFhVABhqAAAAK2gAACODAAAYagAADQYAAAsqAAAAAAAA +AAAAAAAAAABoKwAAaCsAAGyCAABvnAAASmgAAEpoAABNKQAASmgAAE7qAABMmAAAUj0AAE+4AAGG +oAABhqAAAgjWAAII1gACCNUAAgjVAAKLCwACiwsAAgjVAAK2cgACtnIAAw1AAAQGBwAAAAAAAAAA +AAAAAAACAgUFCAgLCw4OEREUFBcXGhodHSAgIyMmJikpLCwvLzIyNTU4ODs7AAAAAAAAAAEDEREI +CBAJAwEAAAAAAAAgBMzkIAGy9CAAN0ggAYJQIAGvQCABqbQgAWM4IAQ5LB//6jwgAJyoIACzGB// +3RAgAGjgIABaQAAAAAAAAAAAIAGECCAAiLAAAAAAAAAAAB//1fQf/8V8H//ClB//wDAgAFVAIABI +nCAARcggAKgwH//j8CAGxCgAAAAAAAAAACAATFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +IAG6XCABmnggAL1gIAC8lB//8RAf/9CgH//MOCAAhiggBUzoIAEzqCABE6wgAPrYIADvSCAA4rQg +ANUsIADAQCAE0NggAybgIAEosCADVVggAea8IABooAAAAAAgAL3EIAXFxCAAsDAgAY0MIAACmCAA +ofAAAAAAAAAAAB//9FggAL18IAMpkAAAAAAAAAAAIAOnvCAAJ4wgAAlwIAAmiAAAAAAgADKAIAAw +GCAALUgAAAAAIAA3CCABLHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgADSk +IATMhAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAA2SCADsJggADVYAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACAAN0ggAJogAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAEAAAABAAAAAgLAAAAIAMTCAgAAAAgAxMUCAAAACADEyAKAAAAIAMT +LAwAAAAgAxM4EgAAACADE0gNAAAAIAMTXA4AAAAgAxNsEwAAACADE3wKAAAAIAMTkA4AAAAgAxOc +GAAAACADE6wNAAAAIAMTyA4AAAAgAxPYEAAAACADE+gSAAAAIAMT/A4AAAAgAxQQEAAAACADFCAR +AAAAIAMUNAoAAAAgAxRICwAAACADFFQNAAAAIAMUYBQAAAAgAxRwCgAAACADFIgPAAAAIAMUlAYA +AAAgAxSkBgAAACADFKwGAAAAIAMUtAYAAAAgAxS8BgAAACADFMQJAAAAIAMUzAYAAAAgAxTYBAAA +ACADFOAGAAAAIAMU6AsAAAAgAxTwCwAAACADFPwEAAAAIAMU4AQAAAAgAxUICQAAACADFRAJAAAA +IAMVHAAAAAAAAAAADQAAACADFSgKAAAAIAMVOAYAAAAgAxVEAgAAACADFUwDAAAAIAMO7AEAAAAg +AxVQAAAAAAAAAADXaqR46Me3ViQgcNvBvc7u9XwPr0eHxiqoMEYT/UaVAWmAmNiLRPev//9bsYlc +175rkBEi/Zhxk6Z5Q45JtAgh9h4lYsBAs0AmXlpR6bbHqtYvEF0CRBRT2KHmgefT+8gh4c3mwzcH +1vTVDYdFWhTtqePpBfzvo/hnbwLZjSpMiv/6OUKHcfaBbZ1hIv3lOAykvupES97Pqfa7S2C+v7xw +KJt+xuqhJ/rU7zCFBIgdBdnU0Dnm25nlH6J8+MSsVmX0KSJEQyr/l6uUI6f8k6A5ZVtZw48MzJL/ +7/R9hYRd0W+ofk/+LObgowFDFE4IEaH3U36CvTryNSrX0rvrhtORBwwRFgcMERYHDBEWBwwRFgUJ +DhQFCQ4UBQkOFAUJDhQECxAXBAsQFwQLEBcECxAXBgoPFQYKDxUGCg8VBgoPFR//wAAABAAgIAb0 +0CAG+YAf/N4AIAb1IB//rBQf/60kH/+wkAOAAACBAAAAH/+wgAD/+AABAAAAABAAAIEEAQCBBAAA +AQQAAAEEAQCAAAAAAAX//x//hTAGAAAAKgAAAB//z/ggBExcAgAAAIAQAABBQAAAQUABAIMAAAH/ +/7//v////x//mMwEAAAIIAMNCIGAAAAMAAAAH/+TIP//AAD//wD/AAEAAAAA//8f/7GAH/+oxA// +/////9Bk///TYB//Zowf/ODoIAbyrP//vvQf/2aAH/9nBP//wWAf/63cH/+e1B/84gAAAAi44P/+ +AOEBkgAf/5lAAP///x//nXQf/638BEEACAQBAAilAAAAwAAAAMAEAAAwAAAAH/+ugAAAHUAAAP+A +IAbxYCALYiDhAC4AH/+udB//qjwf/68wH/+qoAAAF4DgAACg4QAwuAAAgADhAGAQAABAAOECEADh +AjAA4QJQAOECcADhABAIH/zhQOEAe3Af/7OwH/+zqB/84Agf/7OsH/+zyB//s8Af/7PEH/+z4B// +s9gf/7PcIAb1IB//sYAf/6wUH/zeAB//rSQf/60gH/+twB//nYQf/7DMH/+qJCALAGAf/69MAAD/ +gAAAHiAf/5MgH/+vWB//r1Qf/6+4IAsGcAQAAAgFAAAAg/8AAIEAAAAAEAAAKgAAACAACbQgAwwo +H/+JgB//hTAf/4c0H/+wkGdFIwHvzauJmLrc/hAyVHYf/4AAAAA/KCADDuzP////IAsHYBAAAAA/ +////AgAAAEAAAAD//3//IAsIgB//sIAgACPAIAsIsCALCSAIAAAAAP///yALCZD3////IAsLgCAA +IGj//v//IAsWoIAAAAAgAw0ADAAAAAAAQAAAAP//AACAAP/7//8P9oAAIAsaECALGkAAAQAAAAQA +ACALeNAf/63QIAAygCAANGAgADAYIAsa0CAALUggCxtgIAsbsCALHEAEAQAI4AAAACALHMAgCxyA +UwAAACALHOBSAAAAIAsdIFEAAAAgAe/sH/+qkCALH7AgCyAQIAsf4CALIpAf/638IAsi4B//nXwf +/62gIAsk0BQAAACAAAACfFAAAIAAABCAAAAGgACwAAAACgAA/zSS///wD4AAsQDhAZoAAAIAACAL +JJAf/5r0AAB+QB//rdQA/8AAH/+t4B//k6QBAAAAKAAAACYAAAAgCyUAH/+T4AYAAAAFgAAAH/+p +6CsAAAAgAE+4IAt7gB//q4QDgAAAB////zUAAAADAAAAAD///4BAAAAID///H////yAAAAAAAMAA +H/+tuD0AAAAf/5lsBwAAAIEEAQCBBAAAH/+sAAAAOpjDAAAAAAAP/wBDAAAAAAgABAAAAB//q7wg +C3vgH/+zJB//saAf/5jMAAYAAOEAegAf/5k8H/+txCCgAAAf/6wYH/+djB//nXggC3wQAAMHgCAL +fIAf/5tYACAAAABAAAAAAAkAAAAwAv/8+H/AAAAAo/+7AKP/ugANAAAA4AMAAIP/tgAP////D//4 +AP8AAAAgC3zAIAsmYCALJpAgC31QAA8AAAAKAAD//wAPA//AAIP/wAAgC33QIAt+QB//rqAf/7IQ +/2DwAB//sfAf/5LgBIAACB//gFAARAAA/x///wDAAAABgMIAAACBAPAAAACBgAAA/3///x/84HQf +/6jE/7//////AAAAgAAAAACG3R//nswf/OIAH/+T0O4AAAAAAAm8H/ziDA8AAAAgCybQH/+uQAAA +CLwf/69EH/+fSB//mWgf/4BgIAbzAAAAMAAAACcQH//cgCALhKAgC4RwH/+upB//mWAAAP/+H/+d +bN6tvu8gAwfgNAAAAD8AAAAf/69gAACJBgCZAAAf/7DoEAAHAgHAgACZAAAAH/+v0ACIAAiCgAAB +H/+xOP//8AADFQAAAxEAAAAPA/8gCyzgH/+tpCALhPAgCy1AIAstkCALLiAgCy0QIADp7CALLfAg +Cy/AIAsv8CALMEAgCzCgIADvkCkAAAAAAIkUIAD19CALhWAgC4XAIAD/6B//rvDw8PDw/wD/AKqq +qqrMzMzMH/+yMAAAHxAf/7A4AAP//wAAJ/8gAQhoIAuGMAAPQkAgA1x4H/+ueAAJAAAAAEgAggAA +ACABLHggC4agH/+uJDsAAAgOAAAA0AAAAB//gKAAAB/KAAAIUAAAH0AgCznwIAs6ECALOjAACQAI +H/+xNDAAAAD///f/IAs8gCADYsQAAIP/IAb4SBWgAAAgBvlAH/+w+B//rcwAAAgGAACIzH8AAAAA +AA/+IAuLYCALi/AAAOAAIAuJQCALi8Af/5sMAAQD/woAAAAgBvWYH/+tkCAG9eAf/54gg/+3AIP/ +tiAgCzyw4QAAADMAAAAf/7EAH/+x9AP/4AB///8AAD/2kAAAH9gD//AAIAtnoCALZ2AgC2fAH/+z +ACALPTAaAAAAIAs9gCABepgf/7D8AA///x//ryAf/63cIAuMgB//nawf/6o8H/+sMCAAbQggBvKI +IAAFiB//qSAf/5qIH/+ZCB//qpggC0CQwAQAAB//rCQf/6w8H/+x4B//sVQgC42QIAtA0CADDbAg +AG3o4AEAAB//ntAgC47gIAtBECAArQgf/57IIACqCCALjmAgC46wH/+bLCALQyDg//4AIAtqQB// +ntQgC07AH/+t2B//lVwgC1jgIAtZcB//saQgC1mAIAtZsEgAAAAgAcIwH/+rlCABxDQf/5m8H/+p +NB//qVwAABgwAAAWPB//rGQgBvUUH/+p5B//mUDhAC4AH/+scOEAXgDhAg4A//+//+EADgDhAY4A +//++/x//nXQf/6psIAHJYCAB1YjgBQAAA/8AAB//qaQgAw0IH/y//zwAAAAABf//gwAAAB//qTwg +AeuAIAtl4B//rrQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAgYAAAAAAAAD/////////////////////H//8 +gB///IAf//xIH//8SB///Egf//xIH//10B//+Pgf//dUH//3VB//91QgBsYYAAAAAAAAAAAAAAAA +AAAAACAGyWAgBslgAAAAAAAAAAAAAAAAAAAAACAGxhggBsYYH//57B//+ewf//nsH//57B//+ewf +//nsAAAAACAByngAAAAAAAAAAAAAAAAAAAAAAgEAAAAAAAAAAAAAAAAAAAQAAAAAAAAAgYAAAAAA +ABAFAAAAAAAABAAAAAAAAAAAAAAAAAAAAACBAAAAAAAAGAUAAACAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAgCgAR8o8T8o/TDwPmMQECABbyjRfyjndrBpBgtGZ3Y/hUDzFVzCAPFABj//kAAABsEAgoIAUn +IAcpMQX4IIYV4BlFAPkADoVhdwEAiiIW8oD95QAF4AyVAPFXvA3gD6UA6vJ9G8cCgACmiCuCngp5 +CimSv/1gDYOiAJ0AKIKdCYgB6BYFJA1RgAAo0gj3AA2okgCdACtiruzycRWKuYAAKmKtLMJ/7KsB +BHP9AAD9QAoeIgCdAC7WCP1ACh4iAJ0ALyAUpP8PD0cvJBT14Axd0gCdABnyYy4iFiwhKYgVH/Jh +rsyfgOoiHi5nwoAA/QBmFaANJQD9AEYV4AtlAO3yWh1WAoAAC6oCixSagekAFQRAQQAAiRUIAIoo +PBD9IMYV4EwFAP0g5hWgDEUA7Ls2BMiBAABtuQUIAIYJAmHu8ksVoIeAAIgV7gAFDc8CgACpiOiM +ICWkNQAAC8kMbZkCCAJhLSEp0w/qISgm6AUAAA0NTy0lKf1AB3RiAJ0A/+R4BeAMFQD6IKgV4B7l +AOoiHi7NQoAA+CAmFeAIBQD4IAYVoA0FAOgWAiXZgQAAWIZM/uAAFzfFAQD3wABHMA2VAO3mnSgE +CoAA+YAFWVIAnQDAINEPAAAA6iQACdgEgADsRAAK6ASAAFiINdKg0Q8AAAAAwLAPiTTp1ggt9i4A +APpAaB2gG8UA/AACHaANFQBYjPlj/8EAAOokAArYBIAAWInO0qDRDwD/+VgNoAgFAOokAAPYYQAA +/AACHaANlQBYjO1j/5HAoFnFlh3yAojY+R/yCJAPpQBj/6TaIFgLjGP+cAAAAAAA/AACHeAKBQD6 +RSQdr/wqAIon60QACmgEgAD7RAAVoAwFAFiBxdKg0Q8AAABsEAYuIhCUEeUhGirQBIAAJiAH9kEo +FeAfxQDqFgAqx8KAAP8CUg3hZgEABwlC8SBwDeKFAQBkgfLU8CkgBfxASBWgG4UA/p4ADbAaRQD7 +IA+VIgCdAOXx2R4L1gAA5/HZG08CgAD0wAwSEgCdAKWZLZKe96AR61IAnQApkp0Hagoqor8KmQHu +lAAEjkmAAIwpiyoMBz4Muwz3YAkD4gCdACogTi0gTLGo+6AN7CALFQAoJE4qMAEpIhjzQA32kgCd +ACsgBy0hJPhgJBWgDFUA/UAEBTC7EQDgqhEN2oKAAAuqAhvxvwqIAiohBywhCQvdAvsGAAx6qgEA +6/G6HVMCgAAKzAIqISKY4IggnOOd5AuqApri/QAAFDAKZQAKiAKY4S0iEJ3lLCA4G/Gv+AAiHaBN +FQD5wSYVoMwZAAzYOR3xq5ToDL05+aYADrALBQCb5xjxnp3m7fGfFOAFAAAsJhib65nq6AAVB0jB +AAAJAIrt5g4hyEEAAO/mDyd5AQAACSCGDwJjCQCGDwJhDG4Rpe7q5p0jgLGAAIgpLyA4p4goJgnz +4AgXkgCdAIkQCQlH+SAHAVIAnQDAINEPnhLqJAAL2ASAAFiKpI4S/00QDeAfxQDsEgEpUASAAO0S +ACnYBIAAWIeR0qDRDwAe8XWK6PdABjiSAJ0ADGkRpZkrkp73YAaLUgCdACmSnQdrCiuyvwuZAWSQ +v7CsnOjulAAM834AAGAALAAAAAAA89/wSFIAnQAJVAz0nQAVr/gCAAAAAAAA6xIAKVAEgABYiR7S +oNEPAOokAANYYQAA/AAiHaANZQBYjD9j/2mNIsDkDt0C/EBGFe/9fgAAAAD4Q6gVpNkBAADRBAC8 +GgyIAvhDphWv+MYAiieNEcDA6qwgLtgEgABYgRrSoNEP2iBYhydj/vkAAP/3PA2gCQUAwKBZxNQe +8T+K6Plf+XiQH8UA//0oDaAJBQDAkMC6C6s0+8EGFe/87gAAAABsEA6VHCgiEC4iCSchNSkgByMW +DioyAv5giBXgDRUA/GBoHae1AQDjIRol2/kAAAvbOfohphXhmQEA5/82CbfCgAD+wlIN46oBAA4O +QvHAcA3i0wEAZNRjJiAFwej5/gAPMBdFAPbAJB1iAJ0AhyKLHvTl/A3gDoUAK7ABnxHzYCEnEgCd +AJkQmRqaFBjxEu3xExIoDQAA5RYLLK8CgADoVQgM34KAAK276xYJInAFAACJGp4YjRv1IAaqEgCd +ACtSnoYZ/WAKI+IAnQAvUp0mYr8G/wFk9DkZ8QCJmPcgCZiSAJ0AKoKuZKFSGvD9I4KtKqJ/HfD5 +CjsB6xYFJNv9AAD6YAnmIgCdAJvY+mAfZiIAnQCHKYYqDAM+B2YM8sAJq+IAnQApGgDzIjIN4Pr1 +ACsgFpwT+2AJ/SIAnQCLEYbDKiA49+DmFaAGBQD34SYVoEcFAPvhBhXgqhkACnY5F/DrlhYtIhcW +8Oid+i0iG537icQKdjmWF/lgEUriAJ0Ahh2eH+wWAyMN2YAAYAEIGfDSiZhqkS6LGypSno8Ze6NL +LVKdL/K/D90BnRWGFevwyhTT/QAA72QAAwHpgACauGX/E2ADSp4f/CBmFaAKBQBZxFUZ8MGJmBjw +vowT7hIPJI7bAAD//1wNoA8FAMCg+iCmFa/+5gAd8LjAugubNPuhBhXv/vYAAAAAAP/7FA2gDwUA +nh8vFhD8IGYVoAoFAFnEQRnwrYwTLxIQiZiOHxjwqfk/9XCSAJ0AYAK9wKCaFYsVFvClwNoNnTTt +Zggt9iYAAGACpJ4fLxYQnBPqJAAJ2ASAAFiJwowTLxIQ7hIPJXWhgABgAlqeHy8WEPpA8BWgDAUA +WImbjBMvEhDuEg8tdWYAAGADx44XixOIFIwR9iDIFa+KBQAqJDsMmQwIZgKZtKzYBu4CLSIQ6CYb +KVAEgABYiEiOH4wTGPCC+rOmFaEJBQBzmw0rIBYqCv/7YARNIgCdAIopKyA4DwIAo6rqJgkoBAqA +APNgBD+SAJ0AJiE1L8IEKyEaKSIQ5v82De/CgAB/2wsKCkJkoAULDUJk0HP+ICYV4B2FAPn+AA7w +ChUA+iGmFaAGNQD2IYYVr/XGAIonLxYQix7qrCAqYASAAFiE2C8SEJoTLSIb+UCIFe/83gAAAAAA +AADqIAcp4ASAAFiJNRjwV4wT/iHoFa/9ngDaIFiGNxjwUowTjh/6QSgVr/22AHGeiAq/DP/9ABXv +/goAixSKFi0iEBnwWAuqAhvwWApoAoYdGvBPCYgC6fBOGws+AAAjFhElFhImIAeFwCMhB/ZBJBXg +ZhEA61UBCzKCgAD2pgAKujMBAOYhIimbAoAAA3cCClUCIyEkCWYClfCFIJfzlvL94KYV45gBAOj2 +BizKAoAACTkC4xIRIlP5AADp9gQqrgKAAOXlAgZAgQAA5fYBJ8jBAADlEhIiFDUAAG2pBQgAhgkC +YSYgFKRmBgZHJiQU9MAINdIAnQCIGPizphWhBwUA8uHyDeD59QArIBb5YAjNYgCdACoiF7Gq6iYX +IYCpgACMKSsgOKPMnCnzYAefkgCdAI0dZdDPwCDRDy8gTmT72Q54AvhARhWgAIYAAAAAAADzH9zA +UgCdAA4/DP/9ABXv7jYAAAAAAADrEg4pUASAAO0SDCpgBIAAWIYX0qDRDwDrEgwpUASAAFiHutKg +0Q8A+kBoHaAbxQD8ACIdoA0VAFiK22P/wYsQ+kBoHaAMFQDtEgsl2GEAAFiK1WP/qQAAJiA7ZGBx +6iQADlgEgAD8ICgVr4kFAOkkOyxwBIAAWIen+iEGFaALBQArJhv6R2Yd7/vOAAAAAADrEgUpUASA +AFgJaWP+74on60QACmgEgAD7RAAVoAwFAFh/p9Kg0Q8A2iBYhbVj/wjqIAcp4ASAAFiIq2P+3AAA +JyEJJRYSIxYRJBYTJiAHhMAjIST0QOQV4GYRAOtEAQsygoAABkQCCkQC9kREFaq1AQDrIgct0wKA +AAp3AglmAiqxFZoSlPCFIJfzlvL94KYV40gBAOj2BioiAoAABDMC4/YEJdiBAAD0ImgVr8MFAAO7 +ASMSEeupCAquAoAABeUC5fYBJmCBAADlEhIkyQEAAOnLQ35ABIAALUz+DNYRpobmkzt34MEAAPSf +7/ESAJ0AbdkFCACGDAJhY/3tixD6QGgdoAwVAPtiQBXgDQUAWIqCY/5aAAAA+48ADD/+9gAInQwN +SRRtmQUIIIYMAmPv2ggFwQEAAOlMDAVIwQAA9Z/tQRIAnQArzP5tuQUIQIYJAmVj/ZQAAGwQBigg +BRzvhfffBgXgGkUA+wAKnSIAnQArIE6JyLC7KyRO9yAIyJIAnQAucq7t730XEXGAACtyrS3Sfw27 +Aea0AAWRKYAAsJ7uxggliDmAAC8gFLP/Dw9HLyQU9eAQxdIAnQAuIHP4Q6gV7/r1APvABADQCxUA +4LgaB2gFAAD7FwANNN0BAC0kcwmIAQi4OQqZAekmHSwHDgAAiiJ8pwQoIE7Jj32nCCsgTCkgTnuT +FMxsLCAU7SICLlgcAABk0cnAINEPAI4nx/MPrwHvJgInUMEAAFh2pOPvYRUBOYAAKKAA0w/TDwOI +CiiCEOygBy1YBIAA+kBoHaANRQALgABlr9yJJ9MPZJ+mKpkUyqeKmWSvnCigAAOICiiCEOygBy1Y +BIAA+kBoHaANNQALgABlr+Bj/3oAAP//VA2gCgUAwKBZwsoc7zWJyPk/9uiSAJ0AwGApIBSzmfhC +hh3v/B4AAAAAAAAAAOokAArYBIAAWIbs0qDRDwAqIAUrIAfB1P1ADmVhuwEABQVH+KAOeVIAnQCT +EI02nRLt7yEdmASAAPVgCYoSAJ0ADLoRp6ouop73wA2c0gCdACqinQ28CizCvwyqAWShPfpACBXg +DBUAWCJ/He8VKSEJGO8VKyEiLyAHHu8fLCEk+WYADbD/EQDoEgIv+oKAAA/MAg7MAiymAI4gm6L5 +QKYVoA8lAOmmAy92AoAAD+4C/0AmFaAJBQDtABUFUGEAALGZ6oMeDI/oAAAMORH3IABE8AilACiW +nfS/8rkSAJ0AiifrRAAKaASAAPtEABWgDAUAWH7DY/46//dsDaALBQDAugubNOvGCCtvBgAAY/7b +6iQAC1gEgABYCHX93cwFr/d2AIonwLD7RAAVoAwVAFiHcBnu8pmg/kAIFaAbxQD53eAFoAwVAPlA +RhWgDRUA/cAAFzAIFQDo7gINeASAAO72ASlQBIAAWIm8wCDRD4nI9yAEoJIAnQAMOhGnqi6invfA +BVTSAJ0AKqKdDT4KLuK/DqoBZKCYsJ+fyGWuwYgi6xYBJAThgAD4v+w5UgCdAIonKwoA+0QAFaAM +FQBYgzSLEB7uzp6gjCAd7s6dov2AABYwDRUADcwCnKGLtvtAZhXv9UoAAAAA61QACVAEgABYhnJj +/TyPM/4gRhXv+NYA//lkDaAKBQD6ICYV4AoFAFnCPBzuqInIixEd7qf5P/q4kgCdAP/9yA2gCgUA +AMCgwIoImDT5gQYVr/2KAAAAAOokAAXYYQAA/AAiHaANpQBYiYFj/1EAAGwQBCggFO+LHmoYBIAA +iif6YGgd4AwFAOqsICnoBIAAWH5h0qDRDwCLInO+SxTui4pIaqFHG+6ILLKuyscd7okssq0t0n8N +ywF9wBuwrp5IfcAhLyAU7yQUL9rQAADaIFgIDWP/p8CwwIoIqDToRggt/xYAAIkiyZXAINEPwKBZ +wguKSGuhrWP/6gAAAAAAAPpAaB2gG8UA/AAiHaANFQBYiVfAINEPAGwQCCwiDy8gByghNCcyB/5D +RBWn1QEA+b/AFeALFQDpuTkJsASAAOsiCSpQBIAA+CCGFeAEFQDodzYPT8KAAPciUg3h/wEACwlC +8SBwDeKOAQBkgnLBtOx7Hw6UdAAALCBP6SBNJmAFAAAMDEcsJE/9IBSjogCdACwgBfuAEv1iAJ0A +jSL6IAYVr/s1AP1gDljiAJ0AKCIZjjL5wBTVIgCdAIk4GO5HHO5E5JJib9+CgACaEJgRrLvo7j4V +SA0AAJkT6xYCL6cCgACoRPXgDSISAJ0AixMqQp77QBsb4gCdAIoSKUKd0w8qor8KmQHulAAEknGA +AIwpiyoMBT7TDwy7DPVgCdviAJ0ALRoA9aHyDeD49QArIBb5YBl1IgCdACwhIhnuOSghByohJCsh +CfxA8BXqiAEA6aoCDEMCgAAIuwIZ7jIY7iMNLUDpzAIO6oKAAAjdAp3giSCc4prk+8BmFeAKVQDr +7ioczgKAAAqZApnhiC+Y5SwgOPfBBhXgDQUA/cDmFeAKJQD93EQF4EklAPjAiBWgzBkADJo5mOkM +2zmNZZ3qHe4c/MDIFaAJBQDs5gsjh+GAAAqcEA3MApzsjBGJaJfvme6IaSjmEI1qLeYR7AAVB0kh +AAAJAIqIZ/jgC6OiAJ0AH+4BCr0CD90CnebAxfyTphWhCQUA9SHyDeD49QArIBb5YBOlIgCdACwi +GYopKyBPKSA45aoIBmAFAADsJhkl2/0AACskT5op8yAPj5IAnQCLFGWx78Ag0Q+fFZ8WnhfqJAAK +2ASAAFiG/44X7xIFJXWRgACMFGXP24on2zDsEgAlUMEAAFiCDsAg0Q8a7dCKqPdAEIiSAJ0AjBMr +Qp79YBFDogCdAIsSKUKdK7K/He3HC5kB5JIUZWP9AACc2O6UAAzyZgAAYACOKCA58R/4DhIAnQD/ +++QNoAkVAAAAAADzn+xIUgCdAAnnDPb9gBXv9foAAAAAwbN7yRQpIDqaEP4gxhXgDPUA/SAQ/SIA +nQDqJAAK2ASAAFiFbtKg0Q8A8AAYDaAa1QDAoYw3KyEJjTiOMuuvEQ3dAoAAD7sC5LsCCVAEgABY +hVLAINEPAAAA//9YDaAahQDqJAAH2GEAAPwgaBXgDBUAWIiBY/8FAAAKuAKY5sDV/JOmFeEMBQB1 +yw0rIBYpCv/5YA41YgCdAIoUZKFdi2qMZ4ppq3sHzAycZ/dg0g3gDgUAsaqMZZtqi2aaaazqq3t3 +uwGxqo4pm2aaZS0gOKXuninzoAo3kgCdAIknKJkUyoKLmcm+Ge2LKLAAnxWfFgmICiiCECywB/pA +aB2gDTUAC4AAjxWLIsej+1/ygOIAnQAoITSHZy4hGooviynodzYPZ8KAAHfLCgsJQsiUDgtCZLC0 +wdT6/gAOsAwVAPwghhWv8q4A2iBYg0Zj/gqKJ+qsMCtYBIAAWG2D0qDRDwAA//KoDaAJBQAAAJ8V +nxaeF/pA8BWgDAUAWIZdjhfvEgUtZf4AAOokAAfYSQAA/AAiHaANBQBYiDhj/eAAAAAAAOogByrg +BIAAWIYnY/2BnxX+IMYV4AoFAFnA2hrtRoqojxX5X+7YkgCdAP/34A2gCQUAwJAc7UDAugurNPuB +BhXv95oAAAAAAPNf+jhSAJ0ACecM9v2AFe/88gCKJ58V7xYGKdgEgADsEgAlUMEAAFiBbtag/iCo +Fe/6FgCfFe8WBilQBIAAWIMO/iCoFe/6tgAAAMFT+kBoHaALBQD8AAIdoA01AFh7mysgBY8WihD1 +f9qFYgCdAGP9IZ8VnxbqIAcq4ASAAFiF+P4gqBXv+K4AAAAAbBAOkxyVGogviikuIRonITQvMgT4 +QPAV57UBAPt/wBXgDRUAC9s56xYLKeAEgAD34QAP8ZkBAOcgBS83woAA/sHyDeKqAQDxQHAN4m4B +AGRkQcGkCPqN+uAjTSIAnQCOIosc9cRcDeAKhQArsAGfEvNgIFcSAJ0AmRHo7PgSWA0AAJsZG+z4 +6RYILK8CgADoVQgM14KAAKuq6hYHInAFAACGGJ4Wixn0wAXqEgCdACpSnoYX+0AJY+IAnQAvUp0m +Yr8G/wFk9CEZ7OaJmPcgCOCSAJ0AKoKuZKE5GuzjI4KtKqJ/HezfCjsB6xYDJNv9AAD6YAkeIgCd +AJvY+mAepiIAnQCHKYYqDAM+B2YM8sAI4+IAnQApGgDzIjIN4Pr1ACsgFpwQ+2AJJSIAnQAb7OQp +IDj72cQFoAYFAPfg5hWgRwUA/YCIFeCZGQAJdjkJujmLEpoUlhX9YBHS4gCdAIYbZGHTYAEDGey+ +iZhqkS6LGSpSno8Xe6NLLVKdL/K/D90BnROGE+vsthTT/QAA72QAAwHpgACauGX/K2ADSp4d/CAG +FaAKBQBZwEEZ7K2JmIwQGOyq7hINJI7bAAD//1wNoA8FAMCg+iBmFa/+5gAd7KTAugubNPuhBhXv +/vYAAAAAAP/7dA2gDwUAAJ4dnx78IAYVoAoFAFnALRnsmYwQjx6JmI4dGOyV+T/2OJIAnQBgAr7A +oJoTixMW7JHA2g2dNO1mCC327gAAYAKlnh2fHpwQ6iQACdgEgABYha6MEI8e7hINJXZ5gABgAl2e +HZ8e+kDwFaAMBQBYhYiMEI8e7hINLXZOAABgA8ScEP4hphWviQUA6SQ7JjhBAAAHAIbnEgInsIEA +AAYCYY3Hl/iKxInGrX0HqgyaxHfbCZ4d7BYAJMgFAACMEosQhhWOFJm2nbcG7gLtIg8pUASAAFiE +LI4dGOxmjBD6s6YVoQcFAHN7CCsgFikK/3m5foopKyA4o6rqJgkoBAqAAPNgBCeSAJ0AJiE0j8Qr +IRqJL+b/Ng3vwoAAf9sKCgpCyKQLDUJk0HP+IEYV4B1FAPn+AA7wChUA+iFmFaAGNQD2IUYVr/XG +AAAAAAAAnh2KJ58eixzqrCAqYASAAFiAvO8SDi1gBIAA/iGoFa/8UgDqIAcp4ASAAFiFG4wQGOw8 +/iGoFa/9tgDaIFiCHYwQGOw4jh36QSgVr/3CAHGeiAq/DP/9gBXv/goAF+w6G+w6Hew/BqkChhsa +7D7tmQIGQEEAAOVhVGfogQAAJRYQkx8lIAeDwAUlQOozAQqqgoAABTMCBzMCJyEHKiEiJiEJ9EHo +Fep3AQDrqgILuwKAAAdmAichJJPwgyCW85n2mvL14KYV46kBAOUSEC1SAoAACncC5/YEKZ4CgAAD +4wLj9gEiU/0AAOMSDyIMNQAAbakFCACGDQJhJiAUpGYGBkcmJBT0wAgd0gCdAIgW+LOmFaEHBQDy +4fIN4Pn1ACsgFvlgCLViAJ0AyD+LKSogOKO7mynzQAffkgCdAIwbZcDXwCDRDy0gTmTb8wroAvhA +RhWgAIYAAAAAAADzH93QUgCdAArvDP/9gBXv7r4AAAAAAADrEgwpUASAAO0SCipgBIAAWIID0qDR +DwDrEgopUASAAFiDptKg0Q8A+kBoHaAbxQD8ACIdoA0VAFiGx2P/wYsR+kBoHaAMFQDtEgkl2GEA +AFiGwWP/qQAAAAAAJiA7ZGB3K/qAKyQ77BICLlgEgAAIIIYNAmPs9ggs8ASAAO0iDylQBIAAWIOP ++iDGFaAMBQD8R2Ydr/vKAOsSAylQBIAAWAVTY/7yiifrRAAKaASAAPtEABWgDAUAWHuR0qDRDwDa +IFiBn2P/AOogByngBIAAWISVY/7fAAAAJyEHJBYRJiAHhMCTH/JERBXgZhEA6kQBCzKCgAAGRAIW +67YsISSKJwZEAiYhCfpmAAn6dwEA66EVK7sCgAAHZgKHL5TwhCCX9ZPy9+BmFaM5AQDp9gYpmgKA +AAPMAuMSDyomAoAABOQC7PYEJVCBAAD14CYVr8wFAAyqAaq85BIRJmEBAADsiz18SASAALBIDIYR +ppZ2wzb0n/CIkgCdAG2JBQlAhg0CZWP+AIsR+kBoHaAMFQD7YkAV4A0FAFiGcGP+YgAAAPsPAAz/ +/w4ACcwMDEgUbYkFCWCGDQJn780IBUkBAADoTAwGwIEAAPWf7diSAJ0AsM5t6QUJgIYIAmlj/agA +AABsEAYoIAUjIAckCgP9D0BEUTMBACggImSAbwIqAlh5VP1MwIDQDRUALCAhGOtpDwIA7DMRBn1W +gACoMykyng8CAG6TRSsynWSwP/pACBWg/uUADs4B/cYADvAPBQD8RCYd4AkFAPggBhXgDAUA+CAm +FeAOlQD4IEYV4A0FAFh/ePRzphWgAgUA0Q/AINEPAABsEAoqIAX4QPAV4AwVAPhgaB2ntQEA6BYA +Jdv5AADryzkKGASAAOsWBSwgBIAA/UHABFGZAQDBw/1AICUiAJ0AjSLv60EenBYAAOvrPRGwEQAA +5hYELPeCgACv7u4WAyzXAoAAq6rqFgcswASAAIcX9QAEIhIAnQCKFCdynoYTjxf64AdbogCdACZi +vy/ynQb/Ae8WBieaEYAAJSEbikKHKYYqBaU29U8ADnELBQB8swHVoJgaB2YM9MAF4+IAnQAqGgD1 +QjIN4Pz1ACsgFpga/WAF/SIAnQCKQvqgDnqiAJ0AjBUb6zKHQ5ga63cBBgj5gABgALYAABrrE4qo +6BYKJQzfgACLF4wUhhMrsp6PFyZiv3yzQy/ynRzrCgb/AeTwOWVb/QAAm8jvFgYv+24AAGACowAA +AAD4IWYV4AoFAFm+lBrrAIqoiRvoEgolDt8AAP//TA2gDwUAwPAc6vrAugurNPuBBhXv/wYAAAAA +AP/8eA2gDwUAmRvqJAAK2ASAAFiEFokb6BIKJXmpgABgAjUAmRv6QPAVoAwFAFiD8Ikb6BIKLXmW +AABgAxrw4ASIUgCdAC0hGowplxj4IUYVou0BAOkWCy8EFgAAlxj4IUYVouwBAOkWCycDgYAAmBrp +Fgsu/8KAAHX7Xg7VDPnV4AWgt+kA5kIDLdyCgAALeQKZGAhmAfaAZhWgAQIAiieZGysSAOqsICng +BIAAWH9AiRv4IUgVoAslAOukAi0gBIAA6qICKAQKgADy//u4UgCdAIwplxiYGpkbjhiPFuWtDApY +BIAA5cwICVAEgADtRgIq6ASAAOwmCSngBIAAWH9biBqJG48X+/OmFaEOBQB16wgrIBYmCv92uQzA +ofogphWv93YAAAAA6iAHKuAEgABYg4WJG/ghSBWv/4oAjykY6sGJFqX/nymMQ4tAjRXnxAAEyIEA +APwOAAU36wEA7hYBLojmAAAnIAcHB0EIdwoncp/urRANU8KAAO2qAgJAQQAA6ncBAdP9AADnxwIB +jD0AAG2pBQgAhgkCYYtAwICYEhnqrBrqqy8hGoYWHuqoJCEHGOql/CAoFaHXMQD/oABGukQBAO3Q +gConAoAA7MwPJnBBAAD4hgAKNMwdAORmACZgBQAADDwMFOqADV0M6CIAL/oCgACfZpdnnmOdZQyk +OQmJAulmBCxGAoAA5GYCIdAFAAAIqAKYYSYgFONmCA0gBIAA5iQUKAQKgADzYAQakgCdAIgX9ROm +FaEHBQD04fIN4Pn1ACsgFvlgBR1iAJ0AiBLSgNEPAIoVZKCjwCDRDwAAAAAAAADqJAAE2GEAAPwg +iBXgDBUAWIU/Y//Ziif8ISYVp9tBAOqsICgECoAA9aAEYdIAnQCMFisKAezMICnoBIAAWHoemhL6 +gAgV7/vOAACLFuxNEQlQBIAA/WAARfAMFQBYd/z0gGAVr/2iAGW7/Plf38jSAJ0ALyAg8f/fd5IA +nQBj/3MAAAAAAAAA6iAHKuAEgABYgxOIEtKA0Q+KJ9ww6xIAJVCBAABYfqjAsvtARh3gAgUA0Q8A +AAAA6zQADjgEgAD8YGgd4AwFAFh5+9tA7DQACugEgADqFgIr8ASAAO8SBilQBIAAWH7H+oAIFe/7 +FgDqJAAE2EkAAPwAIh2gDQUAWIUDY/7pAABsEAiSFJMVGeoniED4IEYVr8sFAOsqAQJwIQAA+iBm +FaeIQQDkgcBiUBEAAI8TLSEFqYwswACv3wTMC+/8QC5YBIAA/4ANiuIAnQD6ICYVoGgBAP4AIh3g +DQUABv04C98L690KB9ghAACCFZ4Q+QAARXAMJQDyQQAV4A8FAPJAgBWgAg4AjRQOVQz/4CAVoAMF +AO/kAARABQAA8Q5gDeB+AQCGEyKgAC3RBQQiC+bWCAlYBIAA4hYGIzEBAAD2QAZ6ogCdAAgGQPIA +Ih2gDQUABi04C9IL690KAVghAAD3IBAVoAIVAAcjOIcVB2YLF+n+pzcncKAGMgoGMwvsfAgBmCEA +AI7QCwCJBe42LiYAAwCLItIA6qwBJMgFAAD0X/sj4gCdAAUpDA4qDPugBhWgBxUA9WAoFeAGBQAJ +djgIaAgisgAF5QgltgF+WwIiLAHitgAmfRKAABbp5YsSHunk5rYBB5AFAAAGIgKGFe67AQxuAoAA +DbsCkmD6gAYV4SwdANEPixD8ICgV7/1SAAAA/E8ADf/8xgCFFRnptQXFC/gAChXgAgUAsSLlgx4J +D+gAAB3pzoYSGunO7W0BB9gFAAANuwKNFepmAQxOAoAACWYC69YAJhAFAAD2gAYVoSIdANEPAAAA +AOoWAS1oBIAA+8BoHe/51gD9jwAN//k+AGwQDPhASBWgCgUA6yAHKcgEgADygGgd58UBAP2fwBWg +BBUA7Ew5DLgEgAD8ISYVobsBAPMbXA3gDAUAmhacFZkTmxSbGxjphx3prB/phxXphObpqB33goAA +r+4uFgouIBbmFggtpwKAAPSAAEJw//UAf+ETAioCWC1OGOl6Heme6hYIJSoRgABgABcAAGZjy/jA +HyiQ+vUAKSAW+yAZTSIAnQCJiPcgBhCSAJ0AK1KuHOlvZLDRLMJ/K1KtDLsBZLDHsJmZiBzpjWSz +SyzAgCzMN/4haBWkzB0ArDzrFgImYB0AAPXABYISAJ0ALkKe/cAIK6IAnQCMGitCnSzCvwy7AesW +ACWZUYAAKnEMiXeZEf1ADqxiAJ0ALHAQ63IDJglBgAD5n/so0gCdAC5yA2Tg0I8WZfGwhhGPGI0U +7hIAKVAEgADm/zYL2ASAAO8WASngBIAAWCsEGOlDHeln568ubTAEgABgAvIAAMCgWbzRGOk9iYgd +6WD5P/mIkgCdAP/9CA2gCwUAwLDAqgqZNPkBBhXv/M4AAGqRJCtCnnyzQYwaK0KdLMK/DLsB5LA1 +ZPP9AAD/AQYVr/0qAAAAAAD8IaYVoAoFAFm8uhjpJomIHelK7BINJI8TAAD//IwNoAsFAMCwwPoP +nzT/AQYV7/xSAAAAAAAAAP/8GA2gCwUAAAAAihjAsZsW+V/5KuIAnQDA4J4W+V/4yuIAnQDrdAAJ +UASAAO0SCSngBIAAWCtA/gAiHeAHFQDnFgktOASAAP9AZhXv+7oAZLBJjxX+ACIdoAwFAA/sOGTA +jIgRhhjqJAAL2ASAAO0SBCngBIAA6GY2CPAEgADmFgEg+BEAAFgrzOjo+B0wBIAA/dI2Be/3/gAA +AACLGA8CAA8CAPlhNg3gDAUAeaMBwMH4ACId4A4FAAyeOOwWBSd8kYAA63QACVAEgADtEgkp4ASA +AFgsavdAaB3gCxUA+iEmFeAKFQD64GYVr/2eAIsQFej9KiEHiXAc6Pn/0cAF6qoBAP9AABU4mQEA +7KoCBMA9AAD8ISgVpIgdAOq2ACRACQAACDgMjiCZs+hfOQGz/QAA77YCL3YCgADubgIFqEEAAO62 +AS4O5gAAiBPojCAhlFUAAOo8/irIBIAAbakFCACGCQJhKzz+DLsRq1ubECggFCwgBKOI9YAImRIA +nQAICUcpJBT1IAouUgCdAIhyKCYciXHoFgctqASAAPMgCjBSAJ0A8TX4DeAHBQCnZiZGnSogFisK +/3uhCusSASlQBIAAWC/UjBllwOPAINEP6xIBKVAEgABYL88uIBYY6KP90Y4F4P/1AP/f5RxiAJ0A +Y/yHiBllj9IqcBDbcPxgaB2gCRUA+1/gFaANBQDqnTgJUASAAFgp9sAg0Q8AAAD6QGgdoBvFAPwA +Ih2gDRUAWIN3Y/+9AAAd6LMt0IDrEgQm6N0AAPpAaB2k3R0A/GAARvAMFQDt3Acl2GEAAFiDbGP/ +jy4gFi8K///f+vRiAJ0A6xIBKVAEgABYL6fAINEPixAMbBGsu/ogBhXv+5YAKCQUjXDxv/i6kgCd +APpAaB2gDAUAWHYq9sBgFa/8EgCKJ+s0AAnoBIAA+0QAFaAMBQBYeD3SoNEPAAAAAAAAAOsSAilQ +BIAAWAHz+iAIFe/6wgAAAAAAAOokAAxgBIAAWAN2iBeJcZoc56QADV8CgADrVQgE9U2AAOtUAAlQ +BIAA/QBoHeAMBQBYAzv3QABD//o6AIon/KBoHaALJQDqrCAp6ASAAFgp6CtwEPl/8TjSAJ0AKXAV +CQhFZI4ZK3EJHOhsKnEML3ARjicMqgyr/w+ICf3CpBWvzQUA7uwgJHiJAADt7gEEQEkAAAr4Oah9 +rs7u7EAm6IEAAO7bWn7QBIAADuowG+hcLaEB/UAEFaH5MQAL/worIhfv8p8uZAKAAAzdAgvuDA/u +LK7dqF79wCQd792BAP3ABB3v9nYAixT6QGgdoAwVAPtiQBXgDQUAWIMLY/4NAAD9rwANP/6aAGwQ +BCMgACQK7XQxBiIhA7wi0Q+EIYYg8kBoFaAIJQD3ZAACsJRxAPkPAAxzNgEA9GAAQfNmgQDl6Dkc +AQqAAABmGvZgAQG9RAEA5SIBAag5AADlIgwBmGkAAAQkLAQzKKMi0Q9sEAiKIicgB4kwlRX4QtAV +oXcBAPFdTA3omQEA+CAmFeD89QB8gR0FC0f7f8AV4AkVAOubOQlQBIAAWC9N81MwDeD89QAa5/SI +qBbn8vcADZiSAJ0ALmKuGefyZOHbKZJ/JWKtCVUBZFHRKIz/KKYI6VQAAo2BgAAb6A4lsIDt5+cS +qN0AAPggBhXkVR0A5UUIC88CgADmmQgCqA0AAPTgCJISAJ0AKJKe9QATO+IAnQAlkp0NeAoogr8I +VQFkUYgpIBb9IyYNoOvVACowEPtAElRiAJ0AKzELvLvaIFgu+SggFCwgBKSI9YAMQReYAQApJBT1 +IA4uUgCdAIoVHufljREoIQcc58kZ5+H/oeAV6ogBAP8AABQ0/x0A6YgCB/gFAAAPTwyYUIsgD+w5 +/KBmFeeqAQDsVgIt3gKAAOtLAgLIQQAA61YBIcBBAAD5QAlxUgCdAOhBDWJT/QAAbakFCACGCQJh +wICYFOkgBCJb/QAADLsRq1v1IAkJEgCdAIgyKCYc6TIBJdhBAACbEygWAvMgCbhQBQUAZpFQpUyI +FAx9Eabd7NadLBAEgADRDwAAAAAA9wAOkJIAnQAMeRGmmS6SnvXADvviAJ0AJZKdDXsKK7K/C1UB +ZFHNsI2dqGVe3WAAYwAAAAAAAADqJAAJ2ASAAO0SBSpgBIAAWH2h0qDRDwDAoFm7GBrng4io+R/y +GJD89QD/+VgNoAUFAAAAAAAAAPpAaB2gG8UA/AAiHaANFQBYgmFj/7HAUMDqDog0+UEGFa/4rgAd +55kt0IAt3Df64wAV5N0dAO1NCAlQBIAA/aBgFeAMFQBYglRj/3sAAAAA+EKGHa/6DgAAAACKJ/0g +aB2gCxUA6qwgKmgEgABYdzT6IIYVr/tKAIsw82AIopIAnQDiEgQr5wKAAKbMJMad0Q8AAAAAAAAA +6xIAKVAEgABYAONj/jAAAOokAAxgBIAAWAJoiTGLE4gS7KwRDSgEgADsuwgE9Z2AANog/QBoHeAM +BQBYAi+IFKWlpUwMfRGm3ezWnSwQBIAA0Q8AAAAAAP/2lA2gBQUAjTWMNB7nZvpg6BXgCSUA/HAA +B7CtcQD7LwAMu4whAPsgBADTzAEA6MwID/gKgAD/gAEGfd0BAO67AQZwOQAA7rsMBmBpAAANvSwN +zCj9YABFv/W6AAAAAOokAAPYSQAA/AAiHaANBQBYgg1j/mHAoFm6thrnIoioHeci+R/xCJD89QD/ ++PANoAUFAMBQwLoLizT7QQYV7/i2ALBLDLsR61sICVAEgAD7YgAV4AwFAFh0zLNM4hIEK+8CgACm +3SzWndEPAGwQBIk3F+c1KzAW+c5YBaMqBQAKKigLtgnoqAgLNwKAAKhmGOcvp2fkcr8pAQqAAP74 +CBWgDBUA6GYIDmgKgADmQRh0wCEAAIsymOCek5aSDbsCKHbAmzLRDwAAH+cir68p8r0AsQTt8sEu +cAqAAA6ZAvn3phXv/vUADt0DDZkBHuca5XLAKW8CgACu3ZnQjzKYUOaGACkBCoAA5YYBLiAKgAAE +/wIodsCfMtEPAAAAbBAKGecOCSkKKJJ/4hYIKWgEgAD7AAQA0AYVAOYWCisoCoAA+CCGFeBVTQAS +5wUb5wUc5vYY5tP1zggFoyoFAOraKA6/AoAA6ZJ/Juu5AACdFaSkqHesrJwWKHK5JEKf66oIBMv9 +AAD6IOYVo5kBAPghJhXgYwUA+IAEAjAAagCKGsCw/f/iHaBjBQDsVQMFAuGAAJsaLXK4BF4BDt0B +nRABAIcDNmBoPtWKGIsXjRUc5ueIFuM5CQHygQAA7hYJLM8CgACpiP0AAEY///UA4ogIDwEKgADo +gp8rSAqAAA+ZAwlEAQuAAGP/qgCKGYsUsaoKCkMqtn/RDwAAbBAEG+bUiiArsn8e5tP7TwANcy8F +AA+vKA7+CCnivyjivv3NnAXv+/UAC5kD6YsBDWcCgAD9gABGf/T1AP2ACBWgAxUA+Q7gHeANBQAZ +5sQY5rD5AABGfywBAOz8CAX9RIAAyykI6jApwr8v4sAJiAzo+xN+gQqAAC/ivgA4GgSIAwj/AS/m +vv2gIBXhux0A5LAsZmDBAAB/txRj/8QAAAnqMPmX5hXv/4YAAAAAAAD9oCAV4bsdAOW/3GZgwQAA +WC+owCDRDwBsEAQmIQn4QpAV7/gFACcgFeiYAQs2AoAA6JkMC7kCgAAHZgL4QoYd4AcFACc0APhg +Zh2gBBUABGYCljEV5mEkVq3RDwAAAABsEAQW5pQV5mvTD6YiBTUCJSaAJCKAZ0ALbQgFKCKAZ4AC +Y//z0Q8AbBAEE+aLIjaKY//8AAAAAGwQBCggBSUgB/pgqBWv9NUA+kBIFeADJQD9ASAR0VUBAMAg +0Q8AiCmaKw8CAPsACDwiAJ0AGuZ7CloJ6aH8JVALAAAqoQD7IASzogCdAPNgBHASAJ0AAioCWHQS +KyICDwIAA7oBZK+4iicEuwHrJgIlUMEAAFhthuPmQxUBOYAAKKAA0w/TDwOICiiCEOygBy1YBIAA ++kBoHaANRQALgABlr9yJJ9MPZJ92KpkUyqeKmWSvbCigAAOICiiCEOygBy1YBIAA+kBoHaANNQAL +gABlr+Bj/0oAAP//VA2gCgUA2iBYc/8rICLquwwJUASAAFh1SdpQ+gAiHeAMBQBYdvyLIgO6AfN/ ++uZiAJ0ALyAH2iD8ACIdoA0FAPVgBAcxvwEA7iYCJdh9AABYgO/AINEPAAAAAAAAAOsgIilQBIAA +WHU1KiAFwYN4oQxoqCmLIvNgBAV//EYAKSA6wL97mer6QGgdoAsFAPwAAh2gDSUAWHRsY//XAAD6 +QGgdoAsFAPwAAh2gDSUAWHPlY/+/AABsEAqIKx3mEy4gIYs3/GDIFaD/5QAP7gEuJCENzAEMuwzr +iQh4yASAAMAg0Q8DAIYJAmGbFSggBSUgB/ghBhXv9NUA/EBIFeADJQD9G0BB0VUBAIopHOYPmyv7 +QAgUYgCdAAxcCevB/CZgCwAALMEA/WAEo6IAnQDzoARgEgCdANogWHOkiyIDugFkr5uKJwS7Aesm +AiVQwQAAWG0ZCqsC4+XVFQEpgAAosADTDwOICiiCECywB/pAaB2gDUUAC4AA66QADX8eAACJJ2Sf +WiqZFCuSCcqoZL9PKLAAA4gKKIIQLLAH+kBoHaANNQALgADrpAANfy4AAGP/LQAAAAAA//9IDaAL +BQDaIFhzkSsgIuq7DAlQBIAAWHTb2lD6ACId4AwFAFh2josiA7oB83/6zmIAnQAvIAfaIPwAIh2g +DQUA9WAEBzG/AQDuJgIl2H0AAFiAgcAg0Q8AAAAAAAAA6yAiKVAEgABYdMcqIAXBg3ihDGioKYsi +82AEBX/8OgApIDrAv3uZ6vpAaB2gCwUA/AACHaANJQBYc/5j/9cAAPpAaB2gCwUA/AACHaANJQBY +c3dj/78AAGwQBBzltysyBCkwFv1gBAW1mR0A9SAIAJIAnQDq5bIUiIGAAP/LYgWv/eUA5OWEFKS1 +AAAsoX5plR18swoqzAT7YAijogCdACsgBrC7CwtH6yQGJYLRgADAINEPACyhftMP7LMMdngRAAD/ +YAfT4gCdACggBrCICAhH6CQGLH7WAACJJ4siKpkUDbsBmyKLmWSgtCiwAASICiiCENog/WDwFaAN +NQALgADAINEPAIsiiicPAgANuwHrJgIlUMEAAFhsocmtKKAABIgKKIIQ7KAHLVgEgAD6QGgdoA1F +AAuAAGWv4IknZJ9uKpkUZKBgiplkr2MooAAEiAooghDsoActWASAAPpAaB2gDTUAC4AAZa/gY/9B +AADqJAAJ2ASAAOxEAAroBIAAWHR/wCDRDwDqJAAJ2ASAAOxEAAroBIAAW/9BwCDRDwD//RwNoAsF +AP/+dA2gCgUAiDci4n8JiBH4QABBP/uSAIg3IuJ/CYgR+EAAQT/7+gBsEAQa5UEoottkgAsJ6jAr +otwLmQxnkAHRD1h2pNEPAGwQBB3lVCcgBxzlU/5BBBXg5xEADtw5nDCIIPvKLgXgCiUA+mBGFeAZ +BQDpNgMsRgKAAAqJAvhgJhXhdwEA5iB5K7wCgAD35gAPcA0FAPwEAh2gCzUA6eVBEwI5gACdNZwz +C4oCFuU+mjEa5T4G7gImIQmeNJo2BGYCIiAHnTmVO/jGAAtxIgEA5jYKKRQCgAAC/wIJ/wLvNggt +kASAANEPLCEIKyEJnTWVNwfMAgS7Agm7AgnMApw06zYGLRAEgADRDwBsEAQY5Q0e5SIsIAcd5SIZ +5SX6QQQV4PwRAP/NAA7xzAEA7TYALmQCgAAMuwIJuwLjgIApsASAAB3k3/xACBWgDgUAnmXtZgIh +uN0AAPrAhhXkdx0A6nz/LmYCgADsfAINVwKAAOxmASVT4QAAmmMCBImZZiNmBwYgiyUhCfTBZhWk +Mx0A5WYKK5AEgADogAUDKMEAAG05AgUCYdEPAAAAbBAGHeUBCysRrbMqMn8Z5P8X5NyIoMBA+OAA +RPAGFQDpuQgEAamAACwyeC8ye/mABXxiAJ0AZfEULDZ8KzJ5KzZ73UAN5BYBAgCUoA3kFsDJ/EAF +3CIAnQAvMnvBwO3k7BeDkYAAIjJ8KiEEjiDz4f4NproBACQ2fPRvZhWgAB4ALjZ87a8BBcP9AAAI +/wLvJQQljFkAACIyfLDM7zJ7IQDxgADJxmP/v9ogWHa/ZaDCKiEE/0EADBaaAQDIl9EP2iBYdrLR +D9ogWHZ00Q8AAAAAAAD6QGgdoAsFAFh3QtEPLiz46tKILwEKgAD8wAEF3/z1AAy7AwuqASrWiFm+ +QCQ2fCQ2e/pv6BWv/OIAAAAV5HwvUFhk8GpZs4VYdisoctvTD8iBWHYAKVBYZJ8pWHX6yK4V5Lgs +UmuwzOxWayYCyYAAWHWBY/8OAAAAABzksv5viBWgClUA/G9IFeALRQDtFgAha+UAAFm8cPpv6BWv ++zIALjJ74jZ8L3oeAAAiNnvRDx/kpi/yrnH2i/arBh2v/iIAAAAAAFmzTPqtZhWv/pIAbBAEFOSe +GeSY6OR1GV7CgACktCNCf6mI6LgIAYIhgAAqMgB4qQIqQnsc5JArMQQqRn8MugHqNQQp0ASAAFh2 +cc6pKTEE/yEADBbZAQDI19EP2jBYdmXRD9owWHYn0Q8A+kBoHaALBQBYdvbRDyNGf9EPAABsEATw +YOAN7/n1AIgiCTkDCYgBmCKKJyqsMFhrhuPkQhUBGYAAKKAAA4gKKIIQ7KAHLVgEgAD6QGgdoA1F +AAuAAGWv4Ikny5IqmRTKpYqZya0ooAADiAooghDsoActWASAAPpAaB2gDTUAC4AAZa/g0Q8AAP// +XA2gCgUA0Q8AAGwQCB3kOhvkYhbkYPXILAWgGMUA4yzoJdOBAAD4QA3MJzMBAAw1EaRV6FKeKWbC +gACmxClAf/kAEJPiAJ0AKFKdZIIHmxHqCx4NSASAAJkQCiCGCwJlCwJjDQCHCQJhCQJhFuRNH+RL +7cMICQEKgADyIKYV4A4VAOPkDB9wCoAAnhOvz/4ghhXv//UA/9cAD3AHRQD+IEYVoAC6AACKmcmt +KKAAA4gKKIIQ7KAHLVgEgAD6QGgdoA01AAuAAGWv4ClCIGSQ6y1AfB7kKYwVDdsJrt4MuwosQH2m +u4qyLuCAZKE4/ce+DaAIFQDA8A2POIgVD/8JCP8KL/0XL/wcL/Ib8eFwDeAMBQDAsQvbAwsLRytE +fAu7CQi7Cqa7/I+mHaAMBQCNsO9Snibz/wAALuD//+AEe6IAnQAvUp32/+AV4Pj1APHnwA3ndwEA +eHF06hIEJkAFAADoRH0m4+EAAFh19okT0qDrEgIkgGGAAIqiC6oBKiYCiicqrDBYaw7JrSigAAOI +CiiCEOygBy1YBIAA+kBoHaANRQALgABlr+CJJ2SfGyqZFGWu8v/7xA2gCgUAjBGLEAyAhgxghgsC +aQsCZ9EPjxGNEC5Efw/Ahg+ghg0CbQ0Ca9EPmxHqBx4NQASAAJgQCgCGCwJjCwJhDeCHCAJv6OwA +CdAEgABZsq9kr6/t47oZrwKAAORVCAlmwoAA94AAQj/5MgAAAP4gqBWgCxUA+7cADfAMBQD8j6Yd +p7sBACtEfAu7Cf9gAQWwDAUA92AARb/7egAAAAtghgtAhgoCZwoCZdEPAABsEAQY44ECA0cMMxGo +MysyhBnjjiiwAIqxCYgKCiGMAgo+KIIQAwI+/EBoHaANJQALgAAiNoTRD2wQBBTjcwIDRwwzEQQz +CCQyhCpCASZAAChACPqYaB2gqSUAAgU+AwI+eYEjGON6CGgKKIIQ6lQAClgEgAD8QGgdoA0lAAuA +ACI2hNEPAAAA6yQAClAEgABYdbvzQGgdr/82AAAAAAAAbBAEWbYTEuNYE+N5DAIAKSKCCRqOA6gK +iIQLgABj/+sS46AD6DAE7jAFsTCTIJQhlSIS45wT41uEIAQzApMgEuOawDAoN0AoN0QoN0goN0wj +PQFyM+0S45XAMJMgxy8T45QDIwMS45OEIAQ0AZQgEuOShCAENAGUIBLjkIQgBDQBlCAS44+EIAQ0 +AZQgxy/AMQMjAxLjjIQgBDQBlCBj//wAAAAS44mDIAMTFA8zEZMgEuOGwDAjJgBX/9kQ44WRAJIB +kwKUAxHjg4IQAeowohEB8DHAQATkFgACABHjf4IQIxoAAyICkhAR43zAIZIQBOQxhAODAoIBgQAA +0jABIwAAAAAQ43eRAJIBkwKUAxHjdYIQAeowohEB8THAQATkFgACABHjbYIQIyoAAyICkhAR423A +IZIQBOQxhAODAoIBgQAA0zABMwAAAAAQ42iRAJIBkwKUAxHjZoIQAeowohEB8jHAQATkFgACABHj +W4IQI0oAAyICkhAR417AIZIQBOQxhAODAoIBgQAA1DABQwAAAAAAXJQBXZQCXpQDX5QAQwAAAAAA +AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFyQAV2QAl6QA1+Q +AFMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACclAAd +kAGdlAKelAOflAQIlAUJlAYKlAcLlABDAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAnJABnZACnpAHHZADn5AEeJAFeZAGepAHe5AAUwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA +AAAAAAAAAAAAANyUAB2QAd2UAt6UA9+UBASUBQWUBgaUBweUCAiUCQmUCgqUCwuUAEMAAAAAAAAA +AAAAAAAAAAAAAAAAAAAAAADckAHdkALekAsdkAPfkAS0kAW1kAa2kAe3kAi4kAm5kAq6kAu7kABT +AAAAH//9pADSMRD//goAAAAAAB///ewA0zEQ//4KAAAAAAAf//40ANQxEP/+CgAAAAAAAPQwCgAA +AAAA9DAKAAAAAAD0MAoAAAAAbBAIJyAHiCIW4lP9xJ4F4XcBAOWA8WvXAoAAGOJMLoCA5qoIB3Dd +AAD9U8gVpO4dAK5O6+JHF3AJAAD/gAhLoAmlACqinQt8CizCvwyqAeoWAiUH+YAAiNj3AAjwkgCd +AC9iruziPReFwYAAKmKtLMJ/7KsBBHP9AAD9QAUmIgCdAJ7Y/UAFLiIAnQAvIBSk/w8PRy8kFPXg +B65SAJ0A+CBIFeeFAQD5AAdxUgCdAOg8ECIMPQAAsEptqQUIAIYJAmHAUIgSjTLtJhwiS/0AAOsy +ASzPAoAAqYiYE/NgCkBQCgUA6hYALYtKAACLEOtLCAvnAoAA5swIBdv9AADrxp0qkASAANEP6iQA +CdgEgADsRAAK6ASAAFh3w9Kg0Q8AwLAJjDTs1ggt+x4AAI0iZd/V+kBoHaAbxQD8ACIdoA0VAFh8 +h2P/v//8DA2gCgUAAACOImXvsC2AgC3cN/rjABXk3R0A7U0ICVAEgAD9oEAV4AwVAFh8emP/jMCg +WbUjHeHyiNj5H/bAkAmlAGP/nNogW/sZY/8GAI4nnhGI6fvCpBXvyQUA5ekUJ2CBAAAJyQHpvQgK +VwKAAOpVDARAQQAAmOkIVTLl5RQm6QEAAP0ACDriAJ0AaKs9qKsrvPD7oATT4gCdAO8SAiIMdQAA +sE5t6QUIAIYPAmErwgELqwjlyQQl28EAAP1gBsxiAJ0A68YBLcAEgABkUKn1AGgd7/qWAAAAAAAA +6iQADuAEgADsFgQsWASAAFv8eIsxiBONFOoWAC1nAoAA7IgIBfT9gADaIPsAaB3gDAUAW/w/jRDt +rQgKkASAAO1NCAv3AoAA5u4IBuv9AAAt5p3RDwjdDPogSBXk/R0A0w9t+QUIIIYLAmMrEgLvTwwE +wQEAAO27CAeMQQAALvz/bekFCECGCwJlL8kEDagMqJgojDDoxgEv+tYAACqcQJrB+4AGFaAIBQD5 +gIQdr/0WAAuIDPnBJhWv+9oAKJxA+YAmFa/8sgBsEAQd4Zoa4Zsc4Zkt0pgqoX4swo6j3eo6DA7u +QoAA/YAARnALBQArxAQrxAVZEwj6QGgdoAsFAFv86tEPAAAAbBAEGOGNKYJ/KjAHLZECLpEE/SCk +FaAPBQDrkgAmiRGAAO7s/yaT/QAA4pUCL3cCgADuuwgOZwKAAP1vAA2wAMYAK5EFLZEEsbv/v+AV +r7sBAOuVBS93AoAA/WAGvGIAnQCMkO7MCA3fAoAAC8sMCwCHD99g6wAHBvMngAAe4W8pkQUr4n8J +mRGp2e3ifSWGEYAAjNGL0JvAi9CcsZ/Qn9Er4n+wuyvmf/WgBhwfuQEAjNn5owAVr8kFAPkABAR/ +EgUAotIrJjr/ogQd5UkFAOnVESQhAQAA5NYHLS8CgADk1gYqWASAAPWABOQiAJ0AJdUQ6FgIBHgb +AADsjEAn+gEAAP3gBGOiAJ0AyTLpRAAFAIGAAG2pBQMAhgkCYSsiQqtY/wAFjGIAnQDoJkImk+EA +ANEPL5UF//yYDaALBQDApf3CfgWgOyUAWbjbwCDRDy3igIzRi9CbwIvQnLGf0J/RK+KCsLv70EYV +7/z6AADAwPsP6BWgDRUAWHAcwCDRDwAAAAAAAADv1gkmk+EAANEPAMsw+mBoHeBcxQDsrDYKcASA +AG3JBQsghg4CY/hgAEXwXkUAfqENL6ys0w9t+QULQIYEAmUpjfvpJkImk+EAANEPAAAAAOQmQiaT +4QAA0Q8AAGwQBIIjAgJB0Q8AAGwQBIUjgyAU4RP4QIQVoVUBAOrhERquwoAA5FQIAYC5gAD7AAQE +Npg5AAmIAiglBCJCf9EPHeEIE+EJH+EJJkJ+KyEELkJ/kmCWIaP//WAEBfbLOQAMuwKvX+8mACco +BQAAJUZ/IkZ+6yUEKpAEgADRDwAAbBAEiiBloFAd4PrqIgMp9sKAAK7d/a/oFeAMFQD8gEAGMaoB +AAaqAg3ILAjdKCclBe3MDARYBQAA/W0ADD/7xQDrqgEMTkKAAAlZAgOqApojCYgCKCUE0Q+PIxvg +5g8PQQv+EavrLbJ/LLJ+ctka2cDzI/4NoAwFAMDALLZ/LLZ++kAIFaAASgAA2MDzDIYNoAwFAHLR +HY0hmtCOICmyfZ3hnCDsJgEky/0AAPlvphXv/WIAABngzBjgzamIqOh4oSHqtn8vgTYAAM2uKrJ9 +aqIZLbJ7/W/mFeAATgAAAAAAAAAA7LZ/J/8hgAD6QAgVr/6eABzgvRngvYghrJmp6fkPAAzwDAUA +Ccg4+W/GFa/+FgAAbBAE9cFwBeAGFQD0QGgdoAI1APaAQAMwABoAsCIoUn/oY/dyq4EAANEPAAAA +AAAAbBAEKCIc6zQACmAEgADtVAAJUASAAAuAANKg0Q8AAABsEAT0QkgVpCNBAPJaAAk/U4EABCIK +hCaCIQVEKApEEaQi0Q9sEAQqIhIjIAf6PgAEMAY1APUACRCRMwEACshR9QAJKJIAnQD6KAAGsDsF +AP3BJAWgClUAWbglF+CA5OB+Gc8CgAD0YAYSEgCdAKeZKpKe90AIidIAnQAqkp0EOworsr8LqgHx +TuAN50UBACghBxnggv/BBAWqiAEA6+CBHEcCgAAJiAKYoBjgf/xACBXgPAUAnKf7QKYV4BmFAJmj ++UBGFaAIBQCYpu7dAg7+AoAAnaQG/wKfoS8iEg+PQeimCC//AoAAn6nt4HAZ9wKAAKfuJuadLCIS +KiIQDcwC7CYSKVgEgABY5GdoQhmKJ/oAIh3gDAUA+0QAFaANFQBYb7vSoNEPAMAg0Q8c4EmLyGqx +Www5EaeZLZKebtNmKpKdBD0KLdK/DaoB5KBZZfP9AAD/gQYVr/zCAC8aAA+qAvpCRhWv+2IAKCoA +CKoC+kJGFa/7VgAAAIkiy5loQk3AINEPAAAAAP/77A2gCgUAwKBZs2Ac4C6LyGuxlv/7mA2gCgUA +AMCgwNoNvTT9gQYV7/taAAAAAOokAAHYYQAA/AACHaANNQBYeqdpQrGMJy/JFIrJ/4QAFa/IBQDo +7gEH+EEAAO/FFCVTwQAA6sYJJ3EBAAB+qyopwRUd4C2qmprJnaCMIPvAVgXgDRUA66YCLmYCgAAN +zAL9QCYVoAIFANEPHeAjnaCMIPvARAXgDRUA66YCLmYCgAANzAL9QCYVoAIFANEPAGwQGBTgHJIQ +jiAZ4BmLIy0iASwiAiwWIi0WJCsWI/ggxhXgCBUA+CDmFaAPNQD+ISYV4AoFAPogphWgD7UA/iIm +FeAKdQD6IaYVoAiVAPgh5hWgCYUA+CHGFeALZQD6IYYV4A1FAPwhRhXgDFUA/CFmFaANxQD8IkYV +4AzVAPwiZhWgC+UA+iKGFeAJ9QD4IqYV4AhFAJgUGt/5+iSmFaACJQDyIQYVoAKlACIWEBLf8oUW +KxIkKRIFJlF+LBIiJ1F/BpkoL0CAqXn4XogVo5kBAAOZCu6SAC9QBIAAJVI+LRIjCO4IC1AAjhcs +EiQtEiIG7igvQIGufvheqBWj7gEAA+4KjuAqFhbqEiMtWASAAKjuC1AAjhgsEhYtEiQG7igvQIKu +fvheyBWj7gEAA+4KjuAqFhfqEiItWASAAAjuCAtQAI4ZLBIXLRIWBu4oL0CDrn74XugVo+4BAAPu +Co7gKhYY6hIkLVgEgACo7gtQAI4aLBIYLRIXBu4oL0CErn74XwgVo+4BAAPuCo7gKhYZ6hIWLVgE +gACo7gtQAI4bLBIZLRIYBu4oL0CFrn74XygVo+4BAAPuCo7gKhYa6hIXLVgEgAAI7ggLUACOHCwS +Gi0SGQbuKC9Ahq5++F9IFaPuAQAD7gqO4CoWG+oSGC1YBIAAqO4LUACOHSwSGy0SGgbuKC9Ah65+ ++F9oFaPuAQAD7gqO4CoWHOoSGS1YBIAAqO4LUACOHiwSHC0SGwbuKC9AiA5+CPhfiBWj7gEAA+4K +LuIAKhYd6hIaLVgEgACo7gtQAI4fLBIdLRIcBu4oL0CJDn4I+F+oFaPuAQAD7gou4gAqFh7qEhst +WASAAAjuCAtQAC4SECwSHi0SHQbuKC9Aiq5++F/IFaPuAQAD7gqO4CoWH+oSHC1YBIAAqO4LUAAu +EhEsEh8tEh4G7igvQIuufvhf6BWj7gEAA+4KjuAqFiDqEh0tWASAAKjuC1AALBIgLhISLRIfKBIl +Bu4oL0CMrn75D+gVo+4BAAPuCi7iACoWIeoSHi1YBIAACO4IC1AALBIhLRIgLhITL0CNKBIlBu4o +mhOufvkQCBWj7gEAA+4KjuDqEh8tWASAAJsRqO4LUACMES0SIS4SFC9AjigSJQbuKJoSrn75ECgV +o+4BAAPuCo7g6hIgLVgEgAArFiOo7gtQACwSIy4SFY0TKBIlBu4oL0CPrn75EEgVo+4BAAPuCo7g +6hIhLTAEgAAmFiLo7ggLWASAAAtQAI4RKhYkKRISKxITKBIlLRIVjxXsEhQkQQEAAOgWJSboQQAA +7RYVJ/hBAADvFgUmYEEAAOwWFCXYQQAA6xYTJMhBAAApFhKLHYkcjB4vEhCNH+gSESZgQQAA7BYO +J/hBAADvFhAm6EEAAO0WDyRAQQAA6BYRJMhBAADpFgwl2EEAAJsdiRaLF4gbjRnvEgohEQEAAOwS +CCRAQQAA6BYLJuhBAADtFgkn+EEAAO8WCiIgQQAA7xIEJmBBAADsFggl2EEAAOsWByTIIQAA6RYG +J/v9AADvFgQv4WYAAIsQiBOMEo+wibONso6xrJmm3aruqP+fsJ6xnbKZs9EPAAAAbBAEKSIV+KAA +BPA4dQDpjAwBIEEAAPMgAEU/iwUA66QQJVBFAAD5AAXTYgCdACsKAFmvFywiFSsiFO3NEQlABIAA +/EJGFe6APQD9awANsAk1APpCZhXgCiUAbaoMjoQODo7uhgQkQBEAAA8CANMP0w9tmiHpggQkQEEA +AIqBi4KMgwkJjgoKjgsLjgwMjpmAmoGbgpyD60QACVAEgABb/q2KIIgiiSGPIwgIjgkJjg8PjgoK +jpognyMpJgHoJgIpQASAABnexAIAhgMCYfgAChXgCbUAbZoCCACK0Q8AAAAAAAAA/YEAFaALBQBZ +ruj4QGgdoAlFANMPbZoh6YIEJEBBAACKgYuCjIMJCY4KCo4LC44MDI6ZgJqBm4Kcg+okAApYBIAA +W/6L2kD/+/wNoDyFAABsEAYpIhX4QogVoEYFANMP+IAARXWZAQAJZgx0qwGxiComFQYqDOgmFCVR +QQAA9oAHs6IAnQDrNAALYASAAFmuvPhAaB2gCUUA0w/TD22aIemCBCRAQQAAioGLgoyDCQmOCgqO +CwuODAyOmYCagZuCnIMlLBDqJAAK2ASAAFv+aAZHDPbgBY7SAJ0A5jQICtAEgAD24GgdoAMFAOQW +ACpABIAA+MhoHaAJRQAKAmcIQIYKAmUIIIYKAmMIAIbqDAAJQASAAG2aIemCBCRAQQAAioGLgoyD +CQmOCgqOCwuODAyOmYCagZuCnIPqJAAK2ASAAFv+S+pUAAGYBQAA5mzAIiEBAADvbZpqQASAAIsQ +CjwRC8sI7HwMCtAEgABZroTRDwAAAAAAAOs0AApgBIAAWa5/0Q8AAAD2YABGMAMFAPwgBhWv/yYA +bBAEGN5YGd5WGt5UE95XkyOYIpkh+kAGFaALBQArJhUrJhTRDwAAAGwQBt4g5OIQKmAEgADnQgcr +0ASAAPu8iAXgGDUA40IVKZAEgADncg4i++kAAHj7JxjeRQj4CoiAmhOcEu4WASwAIoAAAJMQKrKl +7FQACVgEgABZsD1kpcfygqYV4AIFANEPAAAAACviEgubUu4WASX/QYAAGt4t4xYAKVgEgADqoscq +4ASAAFmwMGSlehreJtsg6qLJKuAEgABZsCsjfQXkps9hmgEAABreINsg6qLLKuAEgABZsCT3R+AN +44YFABreGtsg6qLNKuAEgABZsB5kpsQa3hXbIOqizyrgBIAAWbAZ+0BCiBIAnQArMOXBWPVgK+Bi +AJ0AabchJTTlixD6gqYV4AIFANEPkxAqsp3sVAAJWASAAFmwDGSnAosQ+oKmFeACBQDRDwCTECqy +q+xUAAlYBIAAWbAEZa8a+iBoHaALtQBY4Gv6ACId4AMFAOqzOAUA4YAA6hICK1gEgABZrojIqRzd ++I0RDKw2LNYXZTMljRD8gqYV4AIFANEPLkBuZO7SkxAqssHsVAAJWASAAFmv7WWuv/ogaB2gG2UA +WOBU+gAiHeACBQDqsjgFAKmAAOoSAitYBIAAWa5yLH0DKsUoZSLRjRD8gqYV4AIFANEPAACTECqy +s+xUAAlYBIAAWa/ZZKK3Gt3Q2yDTD+qinyrgBIAAWa/UZa5a+iBoHaALVQBY4Dv6ACId4AIFAOqy +OAUn6YAA6hICK1gEgABZrlgsQG/xgCc+0gCdAGSk34oT+gCiHeAM1QBY4BjSoNEPkxAqsrnsVAAJ +WASAAFmvvmWux/ogaB2gGyUAWOAlZKI1K0BuZLdv6hICK1gEgABZrkQsQhYKzDYsRhaLEPqCphXg +AgUA0Q+TECqyt+xUAAlYBIAAWa+sZKIzGt2j2yDqorEq4ASAAFmvp2WubfogaB2gC+UAWOAPZKHb +6hICK1gEgABZri8rfQIqtRSLEPqCphXgAgUA0Q+TECqyqexUAAlYBIAAWa+YZKIqGt2O2yDqorUq +4ASAAFmvk2Sjhxrditsg0w/qoqMq4ASAAFmvjmWuB/ogaB2gC3UAWN/1ZKF1K0BuZLbjGt1/ixLq +ou8rYASAAFmvhGWmRitAb8DIDLsCK0RvixD6gqYV4AIFANEPAACTECqyv+xUAAlYBIAAWa95ZKHv +Gt1w2yDTD+qioSrgBIAAWa90Za2f+iBoHaALZQBY39tkoQ0rQG5ktmoa3WWLEuqi7ytgBIAAWa9q +ZKZ5K0BvLAr9DLsBK0RvixD6gqYV4AIFANEPAJMQKrKn7FQACVgEgABZr19kobca3VbbINMP6qKb +KuAEgABZr1pkotoa3VDbIOqiuyrgBIAAWa9VZKxfGt1M2yDqosMq4ASAAFmvUGWsTBrdR4sS6qLd +K2AEgABZr0tlpFKLESuyEguZUsiZaJIH+SAPYdIAnQCMESvGEvKCphXgAgUA0Q+TECqyl+xUAAlY +BIAAWa8+ZKF6Gt002yDqopkq4ASAAFmvOWWstPogaB2gCyUAWN+gyqIa3SyLEuqi7ytgBIAAWa8x +ZayUihP6AEId4AzVAFjfgtKg0Q/AINEPAAAA+iBoHaAL9QBY35Jkr+rqEgIrWASAAFmts+sSACPg +CwAAKsUV+oKmFeACBQDRDwAA+iBoHaAbFQBY34Zkr7otQG5k1QYpQG/xP+GXkgCdAPE/4VfSAJ0A +6hICK1gEgABZraEuQhcK7jYuRheLEPqCphXgAgUA0Q8A+iBoHaALpQBY33Rkr3IvQG7TD2T0duoS +AitYBIAAWa2TKEE0+wAPAqIAnQCKE/oBQh3gDNUAWN9T0qDRDwAAAPogaB2gG1UAWN9kZK8y6hIB +KlgEgADsEgIraASAAFje7IsQ+oKmFeACBQDRDwAAAPogaB2gC5UAWN9YZK8CKUBuZJQZGtzjixLq +ou8rYASAAFmu52WiXCtAb40Q/IKmFeAMFQAMuwL6jeYd4AIFANEPAAAAAAAAAPogaB2gCxUAWN9G +ZK66GtzSixLTD+qi7ytgBIAAWa7WZaspihP6ACId4AzVAFjfJ9Kg0Q8AAAAA6hICK1gEgABZrVz1 +QBXykgCdAMcv0Q8A+iBoHaALhQBY3zL6ACId4AIFAOqyOAUBSYAALEBuDwIAZMODGtzC6xICK2AE +gABZrr5lom4tQG/A6A7dAi1Eb2UuNY8Q/oKmFeACBQDRDwDqEgEqWASAAFjfJ2WvnCsw5WP6cwAA +AAD6IGgdoBsFAFjfGGSuAihAbtMPZIL16hICK1gEgABZrTcpQhiLECtGFQqZNviDBhXgAgUA0Q8A +APogaB2gCzUAWN8KZK3KGtyWixLTD+qi1StgBIAAWa6a49ycHQcuAACLESuyEgvJUciZaJIH+T/5 +EdIAnQCOEYwQA70BLeYS/IKmFaACBQDRD2UthI8Q/oKmFeACBQDRD+oSAitYBIAAWa0WKkU0ghDy +gqYVoAIFANEPJX0E9LAAFeALBQD6oGgdoIwFAFmsp+oSAirYBIAAWN8/KzDlwMQMuwL6fCYdp7sB +APp8ph3v5f4ALTDl+iBIFaAOJQAO3QLtNOUrWASAAFms/isw5fp8hh2v5W4AAIoSWaDjLzDif6kU +ihJZoODcoOoSAiPYEwAAWa5lZKG3wKL9uMwFoDsFAFmz5ccv0Q8a3FeLEuqi1ytgBIAAWa5cZa4+ +ixErshILyVFokQpokgf5P/Fp0gCdAB7cWQO9AQ7dAo4RjBAt5hL8gqYVoAIFANEPihP6ASId4AzV +AFjeodKg0Q8AAAD6IGgdoAtFAFjesmSsahrcPosS0w/qotUrYASAAFmuQuPcRx0FZgAAixErshIL +6VHImWiSB/k/7hHSAJ0AjhGMEAO9AS3mEvyCphWgAgUA0Q8a3C2LEuqi3ytgBIAAWa4yZa2WixEr +shILmVJokQpokgf5P+wp0gCdAB/cMYIR778CA+gXAADvJhIm6gEAACzQ5cDhDswCLNTl8oKmFeAC +BQDRD4oT+gECHeAM1QBY3nPSoNEPI30FIzyAKzDlwMEMuwILC0f6fKYd7+ASAAAAGtwOixLqotcr +YASAAFmuEmWtF4sRK7ISC+lRaJEKaJIH+T/oMdIAnQAd3BIDvAENzAKNESzWEosQ+oKmFeACBQDR +DwAAAAAA9uAAQzALBQD6wGgdoIwFAFmsKMFQ6hICK1gEgABY3sArMOUFuwL6fCYdp7sBAPp8ph3v +3hIAAAArMOXAyAy7AgsLR/p8ph3v3b4AihP6AOId4AzVAFjeQ9Kg0Q+KE/oCAh3gDMUAWN4/0qDR +D4oT+gFCHeAMxQBY3jvSoNEPihP6ASId4AzFAFjeNtKg0Q8AihP6AQId4AzFAFjeMtKg0Q+KE/oC +Qh3gDMUAWN4u0qDRDwCKE/oCIh3gDMUAWN4p0qDRD4oT+gDCHeAMxQBY3iXSoNEPihP6AOId4AzF +AFjeIdKg0Q+KE/oAwh3gDNUAWN4c0qDRDwBsEAQkIhBkQGwpMBAqMBEsMBrrMBIszgKAAAqZAuow +EyzOAoAAC5kC6zAZLM4CgAAKmQLqMBgkhREAAAiqEQuqAuswGy1WAoAADKoCCKoRC6oCsarqJhYk +hI0AACkiEuvbthTAKIAAC5sBKyYSLEAFLQqVfcFJwCDRDwAuMBQvMBXoMBYvdgKAAA/uAu8wFy92 +AoAACO4CCO4RD+4C/ddgAFCNBQAvIhJ49yTApf23RgWgOwUAWbMcwCDRDwAAAAD6gGgdoAtlAFj6 +xsAg0Q8AjCcpyRSLyfmEABWvygUA6ogBBMkBAADpxRQl2wEAAOvGCSRBAQAAeLsGLsEVq+ubyRjb +j9mw+AAIHaAPRQBt+gIJAmEc23WcsIog/UAAFTAMRQAMqgKasSkwFCowFR7bhe8wFizOAoAACpkC +6jAXLM4CgAAPmQLutgIszgKAAAqZAum2BCHAIQAA6AYABfhhAAAPAIoqIhKJIg2qAuomEiz35gAA ++kBoHaANNQAL4ABj/ukAbBAGKCAEKQoYeYEDwCDRDyoiEiQiENMP80AKR9IAnQAvQG7TDw8CAP3n +AIDQnFUAK0AFfLHVHNtj/EAIFeAKJQD+gAgVoDsFAFmy1vqAaB2gDSUA/EymHeALFQBY+oDAINEP +ABzbWY0gjjYvMQv4Y/AVoApVAPggBhWgOwUAWbLJGttSJCIYLDELiCyJSoVH/QAARDALBQD4QYYV +oA0FAOVSDiSQSoAALUYeCp4C/oFGFaAAHgArQh7rWggB2IEAAFmrUi9CHi4xC41Ar+4uRh4qUAQs +UAUY2z7rUAYtVgKAAAyqAulQBy1WAoAAC6oC7Ns5HS4CgAAJVQIIVQH0oGAV7/jFAPigBAKwOwUA +/qBoHeAKVQBZsqMqIhMpMQsrQh4PAgAKmQjpJhMiwMEAAPl/9sUiAJ0AHdsoLEIKDcwB7EYKKVAE +gABY94f6QGgdoAsFAPwAAh2gDSUAWDfrwCDRDwAvIhMuMQv6QGgdoAsFAP/AAEdwDAUA/kJmFaAN +JQBYN+LAINEPAAAAbBAGHNsTLSIALjIF9EDoFadVAQD+v8AV4AgVAA+POfSCghWgClUA9CAGFaA7 +RQBZsnqJImWQmCYgBxfa0gYGQeoyBStHAoAAp4grgp4krB/5tZgF5EQdAHSzfCiCnQlrCiuyvwuI +Ae2EAAQDqYAAHNrwDACHbUkCCAJhiDQe2tGe0IkgHNrT6tYDJthBAADs1gIszgKAAOlJAgHggQAA +6dYBKVAEgAALgAAMbxGn/+T2nSKUdQAAiif6AUId4AwFAPtEABWgDaUAWGob0qDRD8Ag0Q8AAAAA +//4sDaAIBQDqJAAKaASAAPrDABXgDAUAWHUnwCDRDwBsEASHJyp5FB/azPjipBXvzQUA6HIIJVAH +AADscgslUoEAAOqTd3PYgQAADbsBq5nowXR0yQEAAC6NAep1FCdSgQAA6pNxfDAEgAB5oX2aeO8A +BQs4BIAABwJhBwJhBwJhBwJhBwJhBwJhBwJhBwJhBwJhBwJhF9qal2CFIJNllGTztWwFoAelAOJm +AiquAoAAB1UC5WYBKxAEgADRD8Ag0Q8AAAAAAAD3gGgdoAgFAPjhZhWv/nIACJoMCroMKq0BKqzg ++uEGFa/+IgAsvED84QYVr/32AABsEATHjwhYAwg4AghIA6ho6CIIC4EKgAACIhiiMtEPAGwQBAQ4 +AwhYA6ho6CIIC4EKgAACIhiiMtEPAABsEAQEOAMIWAEISAOoaOgiCAuBCoAAAiIYojLRDwAAAGwQ +BAVIAwg4AQhYA6ho6CIIC4EKgAACIhiiMtEPAAAAbBAEIyIQKDAF+EJIFeCUJQB0iUj/KKADEI0F +AHifPXCfGeraehS9WIAACpoB+kJGFaACBQDRDwAAAAAA/bTqBaAKVQD8YAgV4DsFAFmx3yswbtMP +abEFLDAFdMEGwCDRDwAAAPpgaB2gDSUA/EymHeALFQBY+YTAINEPAIwnL8kUi8n/hAAVr8gFAOju +AQf5AQAA78UUJdsBAADrxgkncQEAAH67BinBFaubm8kc2k3ZsPwACB2gCkUAbaoCCQJhHNoznLCJ +IB7aSPv/4h2gDEUA6rYELM4CgAAMmQKZsSgiEo8inrINiALoJhIv+4YAAPpAaB2gDTUAC+AAwCDR +D2wQBBPaRAMiAtEPAGwQBiYgB4giHNoJ9EIIFeFmAQDlgntrTwKAAKyZKJKeGtoC9wATitIAnQAk +kp0KaAoogr8IRAHo2hYSEumAACciEoop+EFIFeB3QQCXEAh3CidykOqZDAPYwQAA+yAPs+IAnQAr +IBYoCv94sRL6QPAVoAwFAFhyjuzZ7RURoYAAKyEHHdn6+bRCBeq7AQDv2fod3wKAAA27AptAiCD7 +tDoF4EoFAPqAZhWgBlUA70YCLHYCgAAG7gKeQS0iEo4QLyEa+7QmBaLdUQDq7hEO7YKAAA3uAgvu +AvsGAAwx3jEAqd0t0IDoRgQv+gKAAJ9GDX0M7kYHJujBAACdRSoiFYsp90AARX/pBQDnuwgFUMEA +AOomFSXYwQAA6yYJIlCBAAD4gAtsYgCdABvZ68SQ+gAIHeANBQAKAmEKAmEKAmEpRCAtRCQtRCct +RCb8hKYd74oFACpEIS9SEf6HZh3o/x0A/odGHej/HQD+hyYd6P8dAC9EOC4iFv6H5h2o7h0A/ofG +HajuHQD+h6YdqO4dAC5EPIo0GNnh79nVEfBhAAD1QAYYEPn1AO4GAAJQoQAACgCKKUQwKEQx/oZG +He/+9QAuRDOKNC1EI/qG5h2o/R0A/oRGHejqHQD+hsYdqO4dAP6Gph2o7h0ALkQ06wAFAkkBAAAJ +AmEoIAcICEEMiBGsiCaGnSsgFi8K/3+xCvpA8BWgPAUAWHH8iDRogCeKJ/oAgh3gDAUA+0QAFaAN +RQBYaOwrIhIs+n8MuwH6QkYV4AIFANEPHtm1LSISDt0C/EJGFe//LgDaIFhyNOzZdBVwKYAAYAAr +iF4Z2aixiJheCYgC+IZmHaj4HQD+hkYd6P8dAP6GJh3o/x0A/oYGHe/83gDAINEPAADrbBgpUASA +APwAIh2gDVUAWHPjwCDRDwDrbBIpUASAAPwAIh2gDQUAWHPdwCDRDwBsEAYkIhIqCo7pIhMifGyA +ACgxC6mI+EJmFaAJBQDpJhEskASAANEPLyIYL/B0evFUKCAFGtmJ6dmJFAJZgAArMQsKRAEkJhKN +OSwiE32YPy4iEavM7CYTImWegABk4JKN7H3XIIjr+8BoHaALBQD8AAIdoA0lAAuAAMCQ6SYRLJAE +gADRD8Ag0Q8AAAAAAAD9sugFoAolAP5ACBWgOwUAWbDVKiIQKaAFKwqVe5HWwML8TKYdoAsVAFj4 +fsAg0Q8c2WmN4P/AsBWgClUA9CAGFaA7BQBZsMgtIhLAkPhCJhXvvvUADt0B7SYSLJAEgADRDwDa +IFj1scCQ6SYRLJAEgADRD2wQCCoiEg8CAPNADyfQiOUALSIYK9B0+WAOtCIAnQApIAUc2VDv2VAU +jkGAAAyqAiomEvNAJztSAJ0AjiwoMgYkMCD8YUQVr/XFAP8AJ60lRAEADAxO/ZtgFaAmVQD1gAQG +cIW1APVgEtRgJxUAD6gCrOn4QYYV4DsVAPhCRhWgLCUA9oJGDeAKBQB2QQp7QQf8gCg9IgCdAC0w +MCoiEC4wMS8wMuqgcC7uAoAADt0C7jAzLu4CgAAP3QLo3REFeBkAAO7dAg+CCoAADQ4Z9cAj11X9 +AQAK5REF9QKVEfogBhWgOwUA/bJCBaAKVQBZsIEc2N0b2R8swqAvIhgrsoqlzO/wdC5mQoAArLv6 +QiYV4Ii1AOqwBS3oBIAA+eAYNSCepQD/QBf0IJi1APlAF7QiAJ0A9UAXcJCZlQD5QCClYA9FAPaA +BXxiAJ0A9oAFPCIAnQApMEEsMEAuMDwqMD3oMD4uZgKAAOnMAg92AoAACu4CKTA/6jBCL3YCgAAI +7gLoMEMuZgKAAOrMAg92AoAA6e4CDmYCgAAIzAIOyAzqIhAkBIuAACWiEn5RCAXoDGaAAi6mEi6i +E3zhCA7JDGaQAiymE4q8D6oCmrx2QT3DwfyACXwiAJ0A9oAPjGIAnQDC4v6AF3QiAJ0ALxAQZfMS +wCDRDwAAKDAjwJEImDkotEEoFBD2n/pdIgCdACowIX+nuykwQSwwQC4wPCowPegwPi5mAoAA6cwC +D3YCgAAK7gIpMD/qMEIvdgKAAAjuAugwQy5mAoAA6swCD3YCgADp7gIOZgKAAAjMAg7IDOoiECQE +i4AAJKISfkEIBOgMZoACLqYSLqITfOEIDskMZpACLKYTLjA4KDA5jLzpMDovdgKAAAjuAugwOy92 +AoAACe4C6ti0H3YCgAAI7gLvzAIHcAUAAC4mFpy8+2FmFa/8tgAAAPgAYh2jmuEA+R/s9mIAnQAo +MCQpMCXrMCYsRgKAAAmIAukwJyxGAoAAC4gCCIgR6YgCBlgRAAD5bQAOP/W+AAApMCHxIAfOEgCd +ACowJCwwJe4wJi1WAoAADKoC7DAnLVYCgAAOqgIIqhEMqgJloM8sMEwuME3vME4uZgKAAA7MAu4w +Ty5mAoAAD8wCCMwRDswC6iIQJgVpgAAuohj9wAUTogCdACy2EiowSC4wSe8wSi1WAoAADqoC7jBL +LVYCgAAPqgIIqhEOqgIqthQpMDQuMDXqMDYszgKAAA6ZAujYdRzOAoAACpkC+mbwFaAOBQAuthUu +thPotgsszgKAAAqZAvlhphXv+IYALjA4LzA56DA6L3YCgAAP7gLvMDsvdgKAAAjuAgjuEQ/uAuzY +YxdwBQAALiYW/WFmFa/3sgAAKiIQL6AFKAqV+f/vBCIAnQDAkvhMph3gCxUAWPdkwCDRDxzYVu2y +AC1wBIAA+kJIFaA7BQD6IAYVoApVAFmvrC0iEvpCCBWgTgUADt0CLSYSLjBBKzBALDA8LzA97TA+ +Ld4CgADuuwIOZgKAAA/MAi4wP+8wQi5mAoAADcwC7TBDLd4CgADvuwIOZgKAAO7MAg3eAoAADbsC +DL0M97/qaBIAnQAtohJ80QgNzwxm8AIsphIsohP7n+mcYgCdAAy4DGaNKPtCZhXgAgUA0Q8AAAAq +MDgsMDnuMDotVgKAAAyqAuwwOy1WAoAADqoCCKoRDKoC6dgjFVAFAAAqJhaZu4rXKTwg+0HIFaAL +NQBtugUJAIYKAmHAINEPKSIRZJB/iZeJnvkmABXgC2UAKjwg0w9tuQUKIIYJAmPAINEPAAAqIhBj +/rwAAP/uMA2v9fUAHNgNLzAwKTAxjrDoMDIv/gKAAAn/AukwMy/+AoAA6P8CDWgEgADoMCAv/gKA +APnmAA/wCiUA+CAGFaA7BQBZr1jAINEPAAAA+kImFa/9kgCJ1ysxC4mev7sLS0vlv3xkyMEAAGP8 +NQBsEAYrIgcmIAcPAgAouRQFDUf1YcgVoWYBAOOyCSQOUYAA+aAQUVIAnQAc1+koIgD/YEgVoApV +AP2/wBXgCRUA7Z05CXgEgAD4IAYVoDsFAFmvORzX4PxgEBXgClUA/koQFaA7BQBZrzQX147l140b +TwKAAPTAC8ISAJ0Ap5kqkp73QA9aUgCdACqSnQVrCiuyvwuqAWShpSshBykgQC8gB/WvJgXquwEA +7dfLHd8CgAD1IAuYke8BAPUgCRkSAJ0A9YAI2pIAnQDAwPmviAWg/xEA6SEIL/qCgAAPuwLtuwIP +dAKAAA6ZAgiZApugjiCYpvVARhXgPwUA+UCGFeANRQD/QGYV4AkFAOmmBSVYgQAA6aYHL3YCgAD9 +xgAPcA8lAO6mAS52AoAA7+4CBUkBAAADIIYLAmMDAIYLAmH/QSYVr5V1AASAhgkCaQRghgkCZwRA +hgkCZegiEitPAoAAp5ntlp0hISEAAPUMRg2vZ4UAFtebIyISDwIABzkIKpInJZR9LJImLKYAK5Im ++2AmFaAIBQDoliYhm4EAAOiWJynQBIAAWazh+gCiHaA7BQDsZAAJ6ASAAFmu3y8iEsDh0w/17wAP +sA0FAA/tOGTfpOUkBSlQBIAAWazUwCDRDwD8gFAVr/ueAP/42A2gAwUAHNcqi8hqsX8MaRGnmSiS +nvcABHJSAJ0AKpKdBW0KLdK/DaoBZKB8sL6eyGWueWAAHAAAAAAAAAD8EEIdr/p+AC8gQAj/EP5g +BhXv98IAjyJk8F8c12juIgApaASAAPngaB2gCRUA/y0ADHAKVQD4IAYVoDsFAFmutMAg0Q8AAAD/ ++IQNoAoFAMCgWao4HNcGi8j5f/uQkgCdAP/+NA2gCgUAwKDA2g29NP2BBhXv/foAAACPMOokAANY +YQAA/66cBaf/wQD+SAYd4AwVAP5gBhWgDUUAWHF6/kBIFe/93gBsEAiJJysgByiZFPTgAAZxuwEA +5pIJJAgJgAD5gAnhUgCdAC0gQRTW6+zW6R2YBIAA8bNMDeAFRQD2AAId4A0FAPVgBtoSAJ0ADLoR +pKouop71wA0b4gCdACminQy+Ci7ivw6ZAeqUAASJ6YAALyBBZfFmHNbrGdckKCEHLSAHHtcj/kEE +FeqIAQD8IAAF8N0RAOrdEAxHAoAA7YgCDdwCgAAL/wIO/wIJiAKYoIggn6T/QMYVoA0FAJ2l/UDm +FeA7BQD9QEYVoAlFAOumAyxGAoAACYgC6KYBJUiBAAAGIIYJAmMGAIYJAmH84AAVsAwlAAy7Apup +DDoRBKoI9VOmFe+ZdQDpJAUpUASAAFmsU8Ag0Q8AAAAA//v8DaAGBQAf1qqO+PfABriSAJ0ADDoR +pKooop71AAeD4gCdACqinQw4CiiCvwiqAeSg3mdL/QAAmfj5QGgd7/w6ACogQAiqEPrABhWv+voA +j54t8AQn8AUe1sjl8AYu7gKAAAfdAu/wBy7uAoAABd0CCN0RD90CDt0BJdxn9I4ACvCHlQD0oIAV +7/p+AI8i6xYEJ4R5gAAc1tvuIgApaASAAPngaB2gCRUA/y0ADHAKVQD4IAYVoDsFAFmuJcAg0Q8s +3Ejr3GcpcASAAP7AaB3kux0AWa0KY/5/AAAAAAD/+aQNoAkFAJsU/CCmFeAKBQBZqaAf1m6NFY74 +ixQc1m753/iAkgCdAP/8uA2gCgUAwKDAygzsNP3hBhWv/H4AAAAAjWDqJAAF2GEAAP2tbAWn3cEA +7SRAKugEgAD8wAYVoAwVAFhw4P5ASBXv/TIAbBAGiScjIAcomRQDA0HmkgkkBzGAABTWVfWspgXn +hQEA+QAIoVIAnQD0YAaaEgCdAAw5EaSZKpKeBTsKK7K/90AJ6lIAnQAqkp0LqgFkoPcpIAcrIQcc +1pL7QAAF8NkRAOrdEA3fAoAADbsCDLsCm6COIPmsogWgPwUA/0BmFeANRQDopgIvdgKAAA3uAp6h +LCBB+gACHeAPBQD5RAAV4ekBAOXA0W90AoAALCEIn6UOzAIe1nyfp56mDswCnKQGIIYJAmMGAIYJ +AmH9YAAVsAwlAAy7ApupDDkRpJn9M6YV75h1AOgkBSlQBIAAWavBwCDRDwAAAAD//GgNoAYFABfW +GIt4arF/DDkRpJktkp4FPArswr8oBAqAAPegBApSAJ0AKpKdDKoB5KB1Zev9AACdeGWvGWAADi4g +QAjuEP7ABhWv+5oAAI8iZPBlHNZb7iIAKWgEgAD54GgdoAkVAP8tAAxwClUA+CAGFaA7BQBZraPA +INEPAPoRIh3v/L4A//skDaAKBQDAoFmpJot4+X/7qJIAnQD//mANoAoFAADAoMDKDLw0/OEGFa/+ +IgAAAAAAj2DqJAAB2GEAAP+sgAWn/8EA/kgGHeAMFQD+wAYVoA1FAFhwaP5ASBXv/cYAbBAEiiqO +rxjWN+gmCyFIgQAA6eYAJXjhAADvJggpWASAAP5BJhWgDAUA+UHmFe+YhQD4QKYdoA0lAFhu1MAg +0Q8AAABsEAQb1igqMQzTDyuyfxzWCfhiEBXgFGUA+0P2DeAFBQB8oRfqJAAK2ASAAOw0AApoBIAA +WPRywCDRDwBokUFokiFolAnAQP//ZA2gBQUAfKHRe6vO2jBY9KDVoP//EA2gBAUA/UDmDaAUZQB7 +owJgAAHAQNowWPS3//6cDaAFBQDaMFj0y+WkAAUBEYAA/awMBaAKVQD8YCgV4DsFAFmtT//9/A2g +BAUAAAAA//3QDaAExQBsEAQpMBPxJgAN4PWFAGiRA8Ag0Q+EJ4ROHNX37TARIkAXAAAthGL+YlAV +oApVAP8MZh2gOwUAWa08Kk0E7DARIdhhAABY9NzlOwgCUBcAAOwwEiVTgQAAWPTX6iQAClgEgABY +9i3AINEPhCcPAgAPAgCEThzV4i0wES1EAv5iUBWgClUA/oBmHaA7BQBZrSbrPBgiUAsAAOwwESVT +IQAAWPTF5TsIAlAPAADsMBIlUqEAAFj0wcAg0Q8AAGwQBPRAYCXosx0AI1RX+qrGHeBENQD0qqYd +oAh1APiqhh2gCQUA+KpmHeBKBQAqVFLRDwBsEASPOP2rhAWgClUA/GIQFeA7BQD/4Ggdof/xAFmt +BikwEOrVvBSMkQAAaJJZaZQSiDYion8JiBGoIiggBSkKlXmBXsAg0Q8AAADaMFj3BP9fAA3gCXUA +i6eLviyyjgydVv0jQB3o7LkAwNN+0BD7YEAl4AwFAFj2zsAg0Q8AAFj16cAg0Q8AizYqon8JuxH7 +QABFcAsFAFj1dsAg0Q8AAAAAwKX9qzgFoDsFAFms4vpAaB2gCyUAWPSOwCDRDwBsEASILiMsOHOJ +BcAg0Q8AAIsuiLPsRAAK6ASAAOu84ClQBIAAC4AAjCLtIAUufu4AAGTf1Y4uc+nWY//NAAAAbBAY +JRYZlB4rIAcjFh6HNegyBCn4BIAA/+HkFeADFQDyIgYV4bsBAPojBhXgyFEALBYa/CPIFaDYWQD8 +I6YV4L95ACsWFSrAAP+DsBWj9vUA/YekFeB3+QD8ImYV7DgdAP4gBh2ge3UA7MIfJFRCgAAPCEn4 +IeYVoAAeAACWHxnVZygSGfwiJhWgDwUA+S/EFeAEBQD7QBG8Z4gBAC8WFAk5DPgi5hWvmQEAKRYW +9QBIcRIAnQCKIvtAVKCSAJ0A8OcQDeAOBQDuFhIjgFGAAAM6AlkAAMBQ8oXADeAGBQAtEh4t0IMN +XUIvEh0rEhr+AGIdoAwlAO/sOQvQBIAAWP/fpqbwgQAN4Ar1ACkSHimSKihsMAmGOXagbPQhphWk +th0A4xYMJdgFAAD6I2YV4AGaAAAALBIT0w8PAgD7gEZYEgCdAC0SHg8CAI3V8b/7u1IAnQDrEhMp +0ASAAPwiKBWgDhUA7hYSKOgEgABZAAv7QE4gUgCdAP4AYh3gBQUACvU6ZFGpw2CUHfIhhhXkhh0A +KBYbKRIYHNTAE9TC7tTAHKAEgAD1IAniEgCdAOsSGyy3AoAAo2YqYp77QFKL4gCdACZinQ6YCiiC +vwhmAQZrAu/CCC2wBIAA+2BOoBIAnQArFgX34E8QkgCdACkyrhrVDPsgTIgSAJ0ALjKtLaJg7esB +B9P9AAD9wEvuYgCdAJrI/cBMFmIAnQCNHiwgFK3MDAxHLCQU9YBNplIAnQAuEh3I6ykSFsCD+QBO +0OIAnQBkUPoqEhoPAgDIoWRQY+tkAAlQBIAA/ABiHaAdhQBY//3uEg8teASAAOYSDCK6GYAAHNTs +LRIV+ak2BeAKBQCa8przmvSa9elpAg9EAoAA6fYALuiCgADo3QIK9sKAAP+mAA6wG8UA/eAmFeAK +VQBZrCErEhf5YElpUgCdAMAg7BIbKm8CgACj3SzWndEPLhIeLuCD/kUABzAEFQD+IoYVr/b6AI/I +9+BJoJIAnQDpEhsqNwKAAKNmKGKe+QBJ++IAnQArYp0OTQot0r8NuwHmtAAIBAqAAPtgSVgSAJ0A +sP6eyPrAaB3v+qYAAAAA/JrMDeA2BQD/9rQNoA0FAC8SEmTwdusSBSlQBIAA/ABiHaAdhQBY/8AZ +1LMW1LGOHCgQACZinwnuAhnUhQgfFOaGCw/7AoAA6f8CBHycgAAsEhHtEhMjW/8AACiyPyuxfZ6g +n6Gdopyjm6T5QKYVoABuACwSES0SEythBYhjnqCfoZuimKOdpJylJqwYLRIVjB8C3RDtFgguZAKA +AOwWCSuwPgAALhIdGNRE/iGIFeAKBQDqFgYvcYKAAJ4XCP8C/iFGFeAPJQCfG+tkAAlQBIAA/ABi +HaAdhQBY/5OLHS8SHokW5hIeJZFBgAAmYIPv8gUkkXmAAIgdBk5A5IIYb3MCgAAoEh4ogIIIBkAK +ZhCMFwbtAv2GAA5w36EA86gAFrCPkQD9hgAOcN+JAOOIEA7ogoAA+aYADrCPmQAEiBAIzAIoEh6L +Gg3MAoiE+0AGFeP99QCdopylHNRp/UBmFamIAQCYpBjUZZihLhIL6ZwBJTBhAADpFgYnc/0AAO4W +Cy96RgAALxIU9eAs+JIAnQD14C2xEgCdAPXgLnGSAJ0A9eAvMhIAnQD14C/ykgCdAPXgMLMSAJ0A +9eAxc5IAnQCOHdMPZOBPLxIeL/IqZPBG62QACVAEgAD8AGIdoB2FAFj/USgSHhvUR4wa+QVIFaP9 +9QCdov1ABhWsCQUAmaP7QCYV6ZixAOmmBCxFgoAA6KYFJTBhAADrZAAJUASAAPwAYh2gHYUAWP8/ +HdQ3jxiMGfYhSBWgCQUAmRGZEpkTmRSZpPlAphXv+/UAm6Kbo5ag78wCCvbCgAAOzALuEh4lMGEA +AO3MAgDYIQAA7KYBIOhBAADqHAQg4DEAAFj9WPlAaB3gCBUA6ok5DSgEgADpFiElIzmAACQWIvoA +Ih3gCgUACbo45RYjJWNZgAAT1BeNGYQcGNPmH9QW5RIdKieCgAD4hgAKNgwFAPghCBWgChUA5aU5 +CvDCgAAF/Dn5xgAPMAk1AP3GAA7wCCUABZg5KBYgDs4CLhYc/YYADnAFBQD8I+YVoAR+AAAAAAAA +AP/3bA2gBgUAwOD/98gNoAYFAIgd/CPIFeQMBQD2YAAHMrYpAPELAA3gBgUALdIq7cY5DduCgAAs +EAD/YAAEcN/JAOvdEA5iAoAA7O4CDEUCgAD5xgAPMM/BAPWQABYwj3kA/YYADnDfqQD/QKYVoO+x +AODuEQ7rwoAA/6YADrDvgQDsiBEPdkKAAP8GAAwx72kABO4R/wYADDDvuQDtiAIPckKAAA6+AgyI +Ao0anaAc06ScoQjuAv7GAA8wCCUACO4CnqQY09CYoh7Tz/9AZhWv9i4AAAAAAPoAAh3gBgUA//1M +DaAOBQAAAAAAAACZoZSgnqKeo56knqWdpp2nnaidqS8SIOVcASUwoQAA/qARnGIAnQDrZAAJUASA +APwAgh2gLYUAWP685FBRas7CgAD0oApgkgCdACsSH8fv+yYADPANBQDjmQIL/S4AAI0TLBIejhKP +EYvMLMIQmaGbqfVABhWgCAUAmKKYpp+jnqSdp5yljBT9QQYVr/4mAC0SHSwSHBvTogyZAuuZAgaE +GYAA8OJADe/+9QCZoZSgnqKeo56k/0CmFaANBQCdpp2nnaj9QSYV7/02AC8SHiIWJSvyFibxOCLx +OizyFejxOSs0AoAABiICJvE7LfIb7vIaLEQCgAAIZgIo8hcv8hmfop6jnaScppunmKiWpZmhlKCS +qfIkqBWv+/YAAAAAAAAAAPDiQA3v+/UAmaGUoJuim6ObpPtAphXgCAUAmKaYp5io+UEmFa/7OgAs +Eh6NEi/BOybBOSjBOC7BOuvCGCs0AoAA5v8CDEQCgAAI7gImwhSIzCzCEJukmKeWqJmhnaKUoJyj +n6WeqYwU/UDGFa/6GgArEh3sEhwlg1GAABvTYMfv/SYADLANBQDrmQIDgPGAAJmhlKCeop6jnqSe +pZ2mnaedqP1BJhXv+TIALhIeIhYlLeISLOITK+IYiO2G7i/iFILvLuIRnqKdo5ykm6WYppann6mZ +oZSgkqjyJKgVr/hWACsSH8ff+yYADPAMBQDjmQIDgPGAAJmhlKCdop2jnaSdpZymnKecqP1BJhWv +95oAmaGUoI4T/iAoFeAIBQCYopijmKSYppinmKifpf9BJhWv9woAKhIeGdMyiqUT0sYlEiPkEiIl +TDCAAOPSwhOD4YAAHNMsixwMuwL7P0YV7+JeACUSEMDS960ACv/i4gAAwKX9pkoFoBvFAO4+EQno +BIAAWapZY/bd+iLIFaAOBQCeEZ4SnhOeFFj8RCQWIuUWIyVfYYAA+iLIFaALBQBY/DckFiL0JGYV +7+9aAC8SEfv/uZCSAJ0AY/atGtLjiBwKiAL5P0YVr+B+AADAoFlg/sinG9MKK7CAZLEsKhIWWPwv +6RIhLVweAAD6IsgVoAsVAFj8IvgkKBXv7cIA3GDqEgwpWASAAPwjyBXgDhUAWPzU90BoHa/p8gAA +ANxg6hIMKVgEgAD8I8gV4A41AFj8zPdAaB2v6XYAAAAA3GDqEgwpWASAAPwjyBXgDnUAWPzE90Bo +Ha/o9gAAAADcYOoSDClYBIAA/CPIFeAOtQBY/Lz3QGgdr+h2AAAAANxg6hIMKVgEgAD8I8gV4A7F +AFj8tPdAaB2v5/YAAAAA3GDqEgwpWASAAPwjyBXgDtUAWPys90BoHa/ndgAAAADcYOoSDClYBIAA +/CPIFeAO9QBY/KT3QGgdr+b2AOsSEynQBIAA7BIRKOgEgABY/XJj9ikAACsSHowe7RIZKVAEgABY +aAbSoNEPAAAAAPulfAWhSxUAWZNlLBoADKwC+6VyBaFLFQBZk2Vj/rMAwLDA2g39NJ3I+3+0MJIA +nQD6QGgdoBvFAPwAAh2gDRUAWGzBY/+gAAAAKxIY+kBoHaAMBQDtEhsl2GEAAFhsumP/hMCgWaVj +HNIyj8j5/7CgkgCdAGP/uNogW+tZY/ZHiieNHsDA6qwgLtgEgABYYZjSoOsSGypnAoAAo8wrxp3R +DwAAAAAAAP/W7A2gBgUA/9ikDaAFRQDAoFmlThzSHI/IHtId+f+1+JIAnQD/27ANoAYFAAAAAP/b +NA2gCwUAwNoN/TT9gQYV79tSAAAAAGwQBBTSgoIgJEJ/E9KBBCIMAyIC0Q8AAGwQDBjSfxrSDRnS +fCiAfSqiqSmShgmqEeqZCAR8RIAAJJ0B9JAAFaAAMgAAACSdAyRMgBnSOyhBKfkACAxiAJ0AGtIn +6gAFCMgEgAAJAmEJAmEJAmEJAmEZ0mwY0kQf0mmOIJ8S+CDGFaAKRQDpFgAvdgKAAArqApoRKUAH +L0Ep/aTGBaGZAQDj7gIMzAKAAAn/Agj/Ap8UKyA5/iFmFaANJQCdGQy7AusWCCgECoAA9GAEsZIA +nQCJRyqZFOSgf2TggQAAjZmLwP/4Ah2gJYUA7s4BBoIZgABtCC59sTgv0AAp0Ad18S8vwQXu+AgM +zwKAAOndCARBAQAA6NsRftAEgADtpAAFAImAAGP/ygAA/68ADX//vgD9bwANcAkFAAqdOObUAA6B +pgAA6kQACNgEgAD8AIIdoA0lAFhdWtEP//4MDaANBQAAACocOvpHQBXgDGUAWaH2Y/9cwnaOaPoA +oh2gO0UA7NIqG2gEgAD+RzAV4+4BAFmpVIpoCo9Xd/FtikcuoRX7RAAVr8sFAAurAavr62pwc2kB +AADvogAmgYGAAH3xKCzQANMPDwIAdcEdKdAHDJkR6d0IBcEBAADo2yR+0ASAAO2kAA1+xgAA/e8A +DfAKBQALrTjm1AAG+mGAAGP/dgAA/68ADT//cgAsIDkKDUN9yYiOIAjuEQ4+Ap5r0Q8AAAD/rwAO +v/5CAGwQBiggBSwgB8GUDwIA+QAQdWHMAQApIgJlkcMtMAEW0YHr0X8eOASAAP+hQAbQD6UALiBO +ZeJX7tF4Hk8CgAD1gArSEgCdAKaZKJKenBALywr3ABGU0gCdACuyvyqSnQurAesWASWOSYAAiuj3 +QA64kgCdAChiru3RbBQL+YAALGKtLdJ/7csBBUP9AAD9gAteYgCdAJjo/YALZmIAnQApIBSkmQkJ +RykkFPUgDXXSAJ0AHtFtG9FmjCD4ICgV4AoFACq2Mu7MAg5uAoAA/WcGFaAORQAO3QIttjEb0crc +kOsPHg3QBIAADAJnC0CGDAJlCyCGDAJjCwCG7AwABNkBAAAK4IYLAm8KwIYLAm0KoIYLAmsKgIYL +AmkuMQEoIQktIAcsMAEb0bgqIST8IAAGMN0RAOrdEA5kAoAADcwCDKoCHdGyLCEiC6oCKpYgDcwC +iyAd0U8oliMuliQsliL9YAAVsAwlAAy7AiuWIYoz6pYlJMgHAADtABUEymEAAAkAigx4EaaI/xOm +FeflAQD5wAa5UgCdAMAg0Q8AAIro90AH4JIAnQAMeRGmmS2Sngt7Ciuyv/egCGTSAJ0ALZKdC9sB +ZLEAsK2d6OsWAS305gAA/CAGFaABZgAAAAAAAOokAAnYBIAA7EQACugEgABYZsHSoNEPAAAAAMCw +D6k06eYILfTmAAD6QGgdoBvFAPwAIh2gDRUAWGuFY//BAADqJAAK2ASAAFhoWtKg0Q8AixD6QGgd +oAwVAPtjABXgDaUAWGt7Y/+XwKBZpCQe0PKK6Plf8PiQD6UAY/+q2iBb6hr/+TQNoA+lAACKJ+tE +AApoBIAA+0QAFaAMBQBYYFbSoNEPAAAAAP/3XA2gCwUAwLgLmwL6QEYV7/0eAAAAAPwgBhWgCgUA +WaQMHtDbiuiMEBvQ2/lf93iQD6UA//woDaALBQAAwLAPrTT9wQYV7/vyAABsEAYoIAUmIAfnNAAK +2ASAAPgCgh3gBTUA+QAPnWFmAQALCEdoghSKIhfQyRjQyORkAAUDyYAAwCDRDwArIh1lseGIJ4OI ++wKkFe/MBQDpggskcIEAAAzsAey7CAp/AoAA7BYAJdkBAADzIA38YgCdAC2JFKP6r90thRT7YA3r +ogCdAMl1yUPZMG1JBQcAhgkCYYrgDwIADwIAr6r7QBCsYgCdAPvABhWv/f4A7GoRAyTxAAAHqggr +op4PAgD3YArZ0gCdACqinQhrCiuyvwuqAWWgT+tsGClQBIAA/AAiHaANNQBYax3AINEPABvQlom4 +9yAMoJIAnQAMShEHqggsop73gA0B0gCdACqinQhMCizCvwyqAeShjmTr/QAALbYIZK+vGdCymaCI +IP+iCAXgCxUA66YCLEYCgAAFiAKYoYgzL/J//6E6BaiIHQCo/5+j7gAVBUhBAAD/oSAF4AgFALGI +6YMeDA/oAACfphnQ9PlBBhXgGAUAmKeOIAjuEQXuAp6pDE0Rp90l1p2OIiwgBoknC+4C69DrFmAF +AADsJAYkyIEAAIiR/SCCFe/MBQAMnAHuJgIkQ0EAAOiWASbowQAA7ZUEJmEBAAB8iyIqkQUd0HSo +qJiRnYCMIOuGAi5mAoAABcwC/QAmFaACBQDRDx3QbJ2AjCAb0NPrhgIuZgKAAAXMAv0AJhWgAgUA +0Q/aIFhnq9Kg0Q8AAAD/+sQNoAoFAFgAJ2P+FwAA8yBoHeAOBQD/AWYVr/e+AOO6DAOBuYAACksU +7LwIK8AEgADsTDYJyASAANMPbckFCACGCQJhiRCqeOtNDATJAQAAbdkFCCCGCQJjixAK/Aysuyu8 +QPvABhXv9ooAwKBZo18b0C2JuBjQLvk/8viSAJ0A//n8DaAKBQDAoMDaDZ00/WEGFe/5wgCPEC/8 +QP/ABhXv9aYAAABsEAYS0CIX0J/1oFYFoBOVAPhQyBWgpiUAKiKCf6cgKyKCf7cYKiKELKAIJaAH +dsE3iETAoAuAAAUzDGU/2tEPLSKEKSKHKiKH+WAABPuqgQB6mTAK6jArQkHDwgy7KKuq+puGFa/+ +6gAuoQsu7PgODkPu7Pwi6/0AAP+iAAq//s4AAAAADAIALyKCf//FJdAHblu/3HD6AKIdoAsFAP6g +ABcw/wUAWaeeJVzxylsoCnGYEcChWZt++iAoFeAJ9QAJWTaZEAm7DPogJhXgCgUAWYBkihAKVQxl +X9fAoVmbdPoOIh3gCgUAWYBeY/9lAABsEAYoIAUvIAfBlPkAFM1h/wEA9CAmFaeFAQCYEvUAD7kS +AJ0AiSIdz9rmz9wfoASAAOvP2RyRlgAA9eAPQhAHtQDvFgAv1wKAAKaqLKKeC/sKK7K/94AVu+IA +nQAsop0LywHntAAFkomAAI7Y98AS+JIAnQAsYq7q0EgWECmAAC9irSui5+v8AQdD/QAA++APjmIA +nQCY2PvgD6ZiAJ0AKyAUKTAHq5kJCUcpJBT1IBG10gCdAB/QOZ9wiSD8AIId4AUVAOV2AizOAoAA +DZkCmXGINhnQMyyiGv+flgWiiB0ACYgBqMz84GYVoCsFAO4AFQPIQQAACQCKm3cZz7vpdgYh4MEA +AOwHHgPAgQAACAJj7uMFA+DBAAAMAmEvdhCIIOV2EixGAoAADYgCKHYRjDMqohgMjBSsqup2EyP5 +gQAA7gAVA9FBAAAKAIopdhbrdhch0EEAAApghg8CZwpAhg8CZS0wAY8zGM/Z8aAFB9AchQAtIAcV +0Av6RIQVoN0RAOMxAS7qgoAACN0CLXYgiyApdiIsdiP9YAAVsAw1AAy7Aut2ISPIBwAA7uMFBMpB +AAAJAmEJAmEuIAcoIQny5SYV4BmlAP7lBhXgCwUA63YlLEUCgAD5BgAMce4BAOh2Ji90AoAADq4C +Be4C/uSGFaAJtQDsEgIqbwKAAKbdKdad+YAHqVIAnQDAINEPAAD//4QNoAmFAC4iHWTuBv4gBhXg +A+4Ajtj3wAfgkgCdAAxKEaaqKKKe9wAIo+IAnQAsop0LSAoogr8IzAHrxAAGCEGAALDpmdjntAAN +8H4AAP4gBhXgAVIA6iQACdgEgADsEgEq6ASAAFhk/dKg0Q8AAMDAwLoL6zTr1ggucKYAAPpAaB2g +G8UA/AAiHaANFQBYacFj/8EAAOokAArYBIAAWGaW0qDRDwCLEPpAaB2gDBUA+2MAFeANtQBYabdj +/5fAoFmiYB3PLo7Y+d/suJIAnQBj/6oAAADrxAAJUASAAFvoU/ufUgWv9v4AiieNEcDA6qwgLtgE +gABYXpHSoNEP//U8DaALBQAAAAAAAFv+/P4gCBXv9AYA/iAGFeAKBQBZokgdzxeO2I8QG88X+d/3 +eJIAnQD//DwNoAsFAAAAAP/74A2gDAUAwMoM7DT9oQYVr/veAAAAAGwQCuQiBypQBIAAiCL+QPAV +r88FAOVBFS1nAoAA7DwIAiCBAAAPRAGkVORMQC5YBIAA9YAl0qHuAQAtsAfs3P4tsASAAOSACGbo +DQAAwCDRDx/O9e0WACXAgQAAmBMdzvT1ACSaogCdAOXO8h8gBIAA9cAfYhIAnQAM6xGluymynu4W +ASZAIQAA+SAlm6IAnQArsp0N6Aoogr8IuwHntAAFoBmAAI34mhTTD/egIsiSAJ0AKVKu689eFKBB +gAAuUq0vsucbztkP6AHoFgImy/0AAP/AH4ZiAJ0Ambj/wB/GYgCdAC4gFC1gB67d+iCGFafdAQAt +JBT1oCFt0gCdABnPGh/PTo4giDTtzt0aXwKAAOW7CA92AoAA8QAE+lAFNQCDYyohJAXsAiggBy5h +AfzgRhXgFIUAlHP84CYVoIgRAOzO5xxCgoAA+QYADHAEBQD44AYVoAglAOwABQPgQQAAbYoCDAJh +LSEJLCAHlHX+4SYVoDilAON2CC7tAoAA+aYADrHMAQDtdgYuZAKAAAyqAg+qApp0KSEJAioC/sAk +FaAMBQDltp0s3QKAAPlmAA2wDQUAWGXqwCDRD4gTiID1gCAVoIkVAPXGAAo3iMEAeYkZlHHvzxcW +S/0AAP7gBhXhmR0A+OBGFeAAUgCUcYgTGc8TmXCIgQhYFJhyjzYZzwwoIgcUzwwpkhr1AqQV4v8d +AAT/ASUWBg+ZCO+CCSRAgQAA+OBmFe/JBQDpiAEFIAkAAOgWBSonAoAABP8ICFUI7KkIAqkBAADl +8wp0yAkAACgSBgj/DOoWBCzPAoAABJkM5JBFbicCgADvSAgDyEEAAJkX+KAOyqIAnQAPVQwFThTT +D23pBQ8AhgkCYYkVDs8Mp1jsjBAkyQEAAG35BQkghgwCYy4iAAjuERjO4vTgAESwDxUA/yDGFeAM +RQAM7AKYlBjO25yVjGMoghgVzt7/nOYF6MwdAKyImJcYztnvABUE8IEAAP+dsgXgDAUAsczugx4O +D+gAAP0hRhXgLAUAnJuHY4Q0jDUIRAHvzAELwkKAAAhEAgVEApScKGAJLmALJGAKJWAI787JH3EC +gADmRBAMQwKAAP0GAAwwxTEA7kQCDmHCgAAMRAIIRAKMNhjOaJSd9GFIFaXlHQDvzAEPcEKAAA7M +Av0hxhWkVQEA6EQBCqoCgAAFRAKIZZifhWYllhCPZySWEi+WEY5kLpYTLGAB8YAEp9IAnQAsIAce +znLywCQV4MwRAO8hJC5igoAADswCLJYUiCD+AwIdoAw1AO6WFyxGAoAADIgCHM5E/SLGFeAOBQD5 +IqYVoAglAOwABQThgQAAbYoCDAJhKCEJmhQtIAf7AAAUMBylAAyIAiiWGvmdGgWh3QEA7pYZLuwC +gAAN/QII3QKIECOWHSeWHO2WGCRADQAAmBCOFI8QL7adLWAHiif/oABGsAwFAOvUAAVQgQAAWF1n +0qDRDwAAZM5WbckFD0CGCQJlY/5EjfiaFPegBviSAJ0ADEsRpbsosp64yfkAB6viAJ0AGM3sKbKd +CEgKKIK/CJkB65QABIcxgACw2Zn417DuFgEt4C4AAI0QixH6QGgdoAwVAO3cAyXYYQAAWGhhwCDR +DwAAAMDgnhKIEhvN2MCaCdk06bYILGCGAAD6QGgdoBvFAPwAIh2gDRUAWGhVwCDRDwD1jwAN/+0a +AAWLDPogZhXv7aoAAAAAAAD8IQYVoAoFAFmg9h/NxY34ihSMGPm/3JiSAJ0AY/+wAJwY6xICKVAE +gABb5umKFPwhCBWv7xIAAP/tZA2gCwUAnhH8IQYVoAoFAFmg5h/NtIoUjfiMGI4R+b/4SJIAnQD/ +/LgNoAsFAP/8aA2gCQUAwIoI2DT54QYVr/xmAAAAAGwQBikgBSYgB9gw9gBiHeAaRQD7IA/NIWYB +AAUJR/0jAAFfxQUAiyITzaEZzZ/kZAAFg7GAAMAg0Q+IJ4uILoEV6YILJHiBAAAF+gHq7ggKbwKA +AOoWACdxAQAA+yAORGIAnQAsiRSdEavarcwshRT7wA4jogCdAMk0yULZsG1JBQMAhgkCYSwSASry +AAyqCP9AESQiAJ0AmvDTsPhgaB2v/hoAAAAAAOxqEQMk/QAAA6oILaKeCWsKK7K/96ALAdIAnQAq +op0PAgALqgFloE/rbBgpUASAAPwAIh2gDTUAWGf1wCDRDwAAAAAdzW2L2JgS92AMkJIAnQAMShGj *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Tue May 23 23:46:18 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 736DBD79DC1; Tue, 23 May 2017 23:46:18 +0000 (UTC) (envelope-from linimon@lonesome.com) Received: from mail.soaustin.net (mail.soaustin.net [192.108.105.60]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.soaustin.net", Issuer "StartCom Class 2 IV Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4DD5C1EA5; Tue, 23 May 2017 23:46:18 +0000 (UTC) (envelope-from linimon@lonesome.com) Received: from lonesome.com (bones.soaustin.net [192.108.105.22]) by mail.soaustin.net (Postfix) with ESMTPSA id AE130BB4; Tue, 23 May 2017 18:46:15 -0500 (CDT) Date: Tue, 23 May 2017 18:46:14 -0500 From: Mark Linimon To: Allan Jude Cc: Alexey Dokuchaev , Ed Maste , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r318757 - head Message-ID: <20170523234614.GA7981@lonesome.com> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170523213306.GA74154@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 23 May 2017 23:46:18 -0000 On Tue, May 23, 2017 at 05:39:50PM -0400, Allan Jude wrote: > The project also includes fixing a number of other long-standing- > because-of-ABI changes, like the max length of a mountpoint is now > 1024 instead of some small value (60 or 80 or something it was before) It was around 80. I hit that while trying to run poudriere under jails using ZFS (on what was then PC-BSD). Of course I could have re-done my entire ZFS hierarchy, but I was several years into using it the exact way I had laid it out by that point. I simply installed onto another machine; it was easier. mcl From owner-svn-src-head@freebsd.org Wed May 24 00:58:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A7456D6B85D; Wed, 24 May 2017 00:58:32 +0000 (UTC) (envelope-from allanjude@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6646C1262; Wed, 24 May 2017 00:58:32 +0000 (UTC) (envelope-from allanjude@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O0wVoC014507; Wed, 24 May 2017 00:58:31 GMT (envelope-from allanjude@FreeBSD.org) Received: (from allanjude@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O0wUMW014502; Wed, 24 May 2017 00:58:30 GMT (envelope-from allanjude@FreeBSD.org) Message-Id: <201705240058.v4O0wUMW014502@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: allanjude set sender to allanjude@FreeBSD.org using -f From: Allan Jude Date: Wed, 24 May 2017 00:58:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318765 - in head: lib/libc/sys share/man/man4 sys/compat/freebsd32 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.23 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, 24 May 2017 00:58:32 -0000 Author: allanjude Date: Wed May 24 00:58:30 2017 New Revision: 318765 URL: https://svnweb.freebsd.org/changeset/base/318765 Log: Allow cpuset_{get,set}affinity in capabilities mode bhyve was recently sandboxed with capsicum, and needs to be able to control the CPU sets of its vcpu threads Reviewed by: emaste, oshogbo, rwatson MFC after: 2 weeks Sponsored by: ScaleEngine Inc. Differential Revision: https://reviews.freebsd.org/D10170 Modified: head/lib/libc/sys/cpuset_getaffinity.2 head/share/man/man4/capsicum.4 head/sys/compat/freebsd32/capabilities.conf head/sys/kern/capabilities.conf head/sys/kern/kern_cpuset.c Modified: head/lib/libc/sys/cpuset_getaffinity.2 ============================================================================== --- head/lib/libc/sys/cpuset_getaffinity.2 Wed May 24 00:36:27 2017 (r318764) +++ head/lib/libc/sys/cpuset_getaffinity.2 Wed May 24 00:58:30 2017 (r318765) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd June 2, 2016 +.Dd May 23, 2017 .Dt CPUSET_GETAFFINITY 2 .Os .Sh NAME @@ -148,8 +148,14 @@ was either preposterously large or small .It Bq Er EPERM The calling process did not have the credentials required to complete the operation. +.It Bq Er ECAPMODE +The calling process attempted to act on a process other than itself, while +in capability mode. +See +.Xr capsicum 4 . .El .Sh SEE ALSO +.Xr capsicum 4 , .Xr cpuset 1 , .Xr cpuset 2 , .Xr cpuset_getid 2 , Modified: head/share/man/man4/capsicum.4 ============================================================================== --- head/share/man/man4/capsicum.4 Wed May 24 00:36:27 2017 (r318764) +++ head/share/man/man4/capsicum.4 Wed May 24 00:58:30 2017 (r318765) @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 5, 2016 +.Dd May 18, 2017 .Dt CAPSICUM 4 .Os .Sh NAME @@ -88,6 +88,16 @@ An extension to the POSIX shared memory associated with file descriptors; described in greater detail in .Xr shm_open 2 . .El +.Pp +In some cases, +.Nm +limits the valid values of some parameters to traditional APIs in order to +restrict access to global namespaces: +.Bl -tag -width indent +.It process IDs +Processes can only act upon their own process ID with syscalls such as +.Xr cpuset_setaffinity 2 . +.El .Sh SEE ALSO .Xr cap_enter 2 , .Xr cap_fcntls_limit 2 , Modified: head/sys/compat/freebsd32/capabilities.conf ============================================================================== --- head/sys/compat/freebsd32/capabilities.conf Wed May 24 00:36:27 2017 (r318764) +++ head/sys/compat/freebsd32/capabilities.conf Wed May 24 00:58:30 2017 (r318765) @@ -76,9 +76,9 @@ close closefrom connectat #cpuset -#freebsd32_cpuset_getaffinity +freebsd32_cpuset_getaffinity #freebsd32_cpuset_getid -#freebsd32_cpuset_setaffinity +freebsd32_cpuset_setaffinity #freebsd32_cpuset_setid dup dup2 Modified: head/sys/kern/capabilities.conf ============================================================================== --- head/sys/kern/capabilities.conf Wed May 24 00:36:27 2017 (r318764) +++ head/sys/kern/capabilities.conf Wed May 24 00:58:30 2017 (r318765) @@ -133,13 +133,12 @@ closefrom connectat ## -## cpuset(2) and related calls require scoping by process, but should -## eventually be allowed, at least in the current process case. +## cpuset(2) and related calls are limited to caller's own process/thread. ## #cpuset -#cpuset_getaffinity +cpuset_getaffinity #cpuset_getid -#cpuset_setaffinity +cpuset_setaffinity #cpuset_setid ## Modified: head/sys/kern/kern_cpuset.c ============================================================================== --- head/sys/kern/kern_cpuset.c Wed May 24 00:36:27 2017 (r318764) +++ head/sys/kern/kern_cpuset.c Wed May 24 00:58:30 2017 (r318765) @@ -47,6 +47,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include @@ -522,6 +523,7 @@ cpuset_setproc(pid_t pid, struct cpuset int threads; int nfree; int error; + /* * The algorithm requires two passes due to locking considerations. * @@ -1096,6 +1098,15 @@ kern_cpuset_getaffinity(struct thread *t if (cpusetsize < sizeof(cpuset_t) || cpusetsize > CPU_MAXSIZE / NBBY) return (ERANGE); + /* In Capability mode, you can only get your own CPU set. */ + if (IN_CAPABILITY_MODE(td)) { + if (level != CPU_LEVEL_WHICH) + return (ECAPMODE); + if (which != CPU_WHICH_TID && which != CPU_WHICH_PID) + return (ECAPMODE); + if (id != -1) + return (ECAPMODE); + } size = cpusetsize; mask = malloc(size, M_TEMP, M_WAITOK | M_ZERO); error = cpuset_which(which, id, &p, &ttd, &set); @@ -1204,6 +1215,15 @@ kern_cpuset_setaffinity(struct thread *t if (cpusetsize < sizeof(cpuset_t) || cpusetsize > CPU_MAXSIZE / NBBY) return (ERANGE); + /* In Capability mode, you can only set your own CPU set. */ + if (IN_CAPABILITY_MODE(td)) { + if (level != CPU_LEVEL_WHICH) + return (ECAPMODE); + if (which != CPU_WHICH_TID && which != CPU_WHICH_PID) + return (ECAPMODE); + if (id != -1) + return (ECAPMODE); + } mask = malloc(cpusetsize, M_TEMP, M_WAITOK | M_ZERO); error = copyin(maskp, mask, cpusetsize); if (error) From owner-svn-src-head@freebsd.org Wed May 24 01:01:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E2A20D6B9D9; Wed, 24 May 2017 01:01:44 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AF5A41682; Wed, 24 May 2017 01:01:44 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O11hYK014720; Wed, 24 May 2017 01:01:43 GMT (envelope-from kevlo@FreeBSD.org) Received: (from kevlo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O11hSq014719; Wed, 24 May 2017 01:01:43 GMT (envelope-from kevlo@FreeBSD.org) Message-Id: <201705240101.v4O11hSq014719@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kevlo set sender to kevlo@FreeBSD.org using -f From: Kevin Lo Date: Wed, 24 May 2017 01:01:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318766 - 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.23 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, 24 May 2017 01:01:45 -0000 Author: kevlo Date: Wed May 24 01:01:43 2017 New Revision: 318766 URL: https://svnweb.freebsd.org/changeset/base/318766 Log: Remove duplicate definition of iflib_led_create(). Modified: head/share/man/man9/iflibdi.9 Modified: head/share/man/man9/iflibdi.9 ============================================================================== --- head/share/man/man9/iflibdi.9 Wed May 24 00:58:30 2017 (r318765) +++ head/share/man/man9/iflibdi.9 Wed May 24 01:01:43 2017 (r318766) @@ -1,5 +1,5 @@ .\" $FreeBSD$ -.Dd March 23, 2017 +.Dd May 24, 2017 .Dt IFLIBDI 9 .Os .Sh NAME @@ -81,10 +81,6 @@ .Fa "int linkstate" .Fc .Ft void -.Fo iflib_led_create -.Fa "if_ctx_t ctx" -.Fc -.Ft void .Fo iflib_add_int_delay_sysctl .Fa "if_ctx_t ctx" .Fa "const char *" From owner-svn-src-head@freebsd.org Wed May 24 01:01:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B950CD6BA32; Wed, 24 May 2017 01:01:58 +0000 (UTC) (envelope-from allanjude@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 951AF17A0; Wed, 24 May 2017 01:01:58 +0000 (UTC) (envelope-from allanjude@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O11vYK017706; Wed, 24 May 2017 01:01:57 GMT (envelope-from allanjude@FreeBSD.org) Received: (from allanjude@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O11vgG017704; Wed, 24 May 2017 01:01:57 GMT (envelope-from allanjude@FreeBSD.org) Message-Id: <201705240101.v4O11vgG017704@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: allanjude set sender to allanjude@FreeBSD.org using -f From: Allan Jude Date: Wed, 24 May 2017 01:01:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318767 - in head/sys: compat/freebsd32 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.23 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, 24 May 2017 01:01:58 -0000 Author: allanjude Date: Wed May 24 01:01:57 2017 New Revision: 318767 URL: https://svnweb.freebsd.org/changeset/base/318767 Log: Followup to r318765 (capsicumize cpuset_*affinity) Update *sysent files Modified: head/sys/compat/freebsd32/freebsd32_sysent.c head/sys/kern/init_sysent.c Modified: head/sys/compat/freebsd32/freebsd32_sysent.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_sysent.c Wed May 24 01:01:43 2017 (r318766) +++ head/sys/compat/freebsd32/freebsd32_sysent.c Wed May 24 01:01:57 2017 (r318767) @@ -558,8 +558,8 @@ struct sysent freebsd32_sysent[] = { { AS(freebsd32_cpuset_setid_args), (sy_call_t *)freebsd32_cpuset_setid, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 485 = freebsd32_cpuset_setid */ #endif { AS(freebsd32_cpuset_getid_args), (sy_call_t *)freebsd32_cpuset_getid, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 486 = freebsd32_cpuset_getid */ - { AS(freebsd32_cpuset_getaffinity_args), (sy_call_t *)freebsd32_cpuset_getaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 487 = freebsd32_cpuset_getaffinity */ - { AS(freebsd32_cpuset_setaffinity_args), (sy_call_t *)freebsd32_cpuset_setaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 488 = freebsd32_cpuset_setaffinity */ + { AS(freebsd32_cpuset_getaffinity_args), (sy_call_t *)freebsd32_cpuset_getaffinity, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 487 = freebsd32_cpuset_getaffinity */ + { AS(freebsd32_cpuset_setaffinity_args), (sy_call_t *)freebsd32_cpuset_setaffinity, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 488 = freebsd32_cpuset_setaffinity */ { AS(faccessat_args), (sy_call_t *)sys_faccessat, AUE_FACCESSAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 489 = faccessat */ { AS(fchmodat_args), (sy_call_t *)sys_fchmodat, AUE_FCHMODAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 490 = fchmodat */ { AS(fchownat_args), (sy_call_t *)sys_fchownat, AUE_FCHOWNAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 491 = fchownat */ Modified: head/sys/kern/init_sysent.c ============================================================================== --- head/sys/kern/init_sysent.c Wed May 24 01:01:43 2017 (r318766) +++ head/sys/kern/init_sysent.c Wed May 24 01:01:57 2017 (r318767) @@ -538,8 +538,8 @@ struct sysent sysent[] = { { AS(cpuset_args), (sy_call_t *)sys_cpuset, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 484 = cpuset */ { AS(cpuset_setid_args), (sy_call_t *)sys_cpuset_setid, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 485 = cpuset_setid */ { AS(cpuset_getid_args), (sy_call_t *)sys_cpuset_getid, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 486 = cpuset_getid */ - { AS(cpuset_getaffinity_args), (sy_call_t *)sys_cpuset_getaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 487 = cpuset_getaffinity */ - { AS(cpuset_setaffinity_args), (sy_call_t *)sys_cpuset_setaffinity, AUE_NULL, NULL, 0, 0, 0, SY_THR_STATIC }, /* 488 = cpuset_setaffinity */ + { AS(cpuset_getaffinity_args), (sy_call_t *)sys_cpuset_getaffinity, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 487 = cpuset_getaffinity */ + { AS(cpuset_setaffinity_args), (sy_call_t *)sys_cpuset_setaffinity, AUE_NULL, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 488 = cpuset_setaffinity */ { AS(faccessat_args), (sy_call_t *)sys_faccessat, AUE_FACCESSAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 489 = faccessat */ { AS(fchmodat_args), (sy_call_t *)sys_fchmodat, AUE_FCHMODAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 490 = fchmodat */ { AS(fchownat_args), (sy_call_t *)sys_fchownat, AUE_FCHOWNAT, NULL, 0, 0, SYF_CAPENABLED, SY_THR_STATIC }, /* 491 = fchownat */ From owner-svn-src-head@freebsd.org Wed May 24 01:02:37 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 019A6D6BBF4; Wed, 24 May 2017 01:02:37 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B918F19F8; Wed, 24 May 2017 01:02:36 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O12ZgX018442; Wed, 24 May 2017 01:02:35 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O12ZA9018441; Wed, 24 May 2017 01:02:35 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705240102.v4O12ZA9018441@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Wed, 24 May 2017 01:02:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318768 - 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.23 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, 24 May 2017 01:02:37 -0000 Author: adrian Date: Wed May 24 01:02:35 2017 New Revision: 318768 URL: https://svnweb.freebsd.org/changeset/base/318768 Log: [ath] begin migration of AHB support to use the PCI style board data API for calibration data. This brings the AHB support in line with the PCI support - now other "things" can wrap up the calibration / board data into a firmware blob and have them probe/attach after the system has finished booting. Note that this change requires /all/ of the AHB using kernel configurations to change - so until I drop those changes in, this breaks AHB. Fear not, I'll do that soon. TODO: * the above stuff. Tested: * AR9331, carambola 2, loading if_ath / wlan as modules at run time Modified: head/sys/dev/ath/if_ath_ahb.c Modified: head/sys/dev/ath/if_ath_ahb.c ============================================================================== --- head/sys/dev/ath/if_ath_ahb.c Wed May 24 01:01:57 2017 (r318767) +++ head/sys/dev/ath/if_ath_ahb.c Wed May 24 01:02:35 2017 (r318768) @@ -66,6 +66,12 @@ __FBSDID("$FreeBSD$"); #include #include +/* For EEPROM firmware */ +#ifdef ATH_EEPROM_FIRMWARE +#include +#include +#endif /* ATH_EEPROM_FIRMWARE */ + /* * bus glue. */ @@ -77,7 +83,6 @@ struct ath_ahb_softc { struct ath_softc sc_sc; struct resource *sc_sr; /* memory resource */ struct resource *sc_irq; /* irq resource */ - struct resource *sc_eeprom; /* eeprom location */ void *sc_ih; /* interrupt handler */ }; @@ -132,10 +137,11 @@ ath_ahb_attach(device_t dev) struct ath_softc *sc = &psc->sc_sc; int error = ENXIO; int rid; - long eepromaddr; - int eepromsize; - uint8_t *p; int device_id, vendor_id; +#ifdef ATH_EEPROM_FIRMWARE + const struct firmware *fw = NULL; + const char *buf; +#endif sc->sc_dev = dev; @@ -146,44 +152,6 @@ ath_ahb_attach(device_t dev) goto bad; } - if (resource_long_value(device_get_name(dev), device_get_unit(dev), - "eepromaddr", &eepromaddr) != 0) { - device_printf(dev, "cannot fetch 'eepromaddr' from hints\n"); - goto bad0; - } - - /* - * The default EEPROM size is 2048 * 16 bit words. - * Later EEPROM/OTP/flash regions may be quite a bit bigger. - */ - if (resource_int_value(device_get_name(dev), device_get_unit(dev), - "eepromsize", &eepromsize) != 0) { - eepromsize = ATH_EEPROM_DATA_SIZE * 2; - } - - rid = 0; - device_printf(sc->sc_dev, "eeprom @ %p (%d bytes)\n", - (void *) eepromaddr, eepromsize); - /* - * XXX this assumes that the parent device is the nexus - * and will just pass through requests for all of memory. - * - * Later on, when this has to attach off of the actual - * AHB, this won't work. - * - * Ideally this would be done in machdep code in mips/atheros/ - * and it'd expose the EEPROM via the firmware interface, - * so the ath/ath_ahb drivers can be loaded as modules - * after boot-time. - */ - psc->sc_eeprom = bus_alloc_resource(dev, SYS_RES_MEMORY, - &rid, (uintptr_t) eepromaddr, - (uintptr_t) eepromaddr + (uintptr_t) (eepromsize - 1), 0, RF_ACTIVE); - if (psc->sc_eeprom == NULL) { - device_printf(dev, "cannot map eeprom space\n"); - goto bad0; - } - sc->sc_st = (HAL_BUS_TAG) rman_get_bustag(psc->sc_sr); sc->sc_sh = (HAL_BUS_HANDLE) rman_get_bushandle(psc->sc_sr); /* @@ -192,22 +160,35 @@ ath_ahb_attach(device_t dev) */ sc->sc_invalid = 1; - /* Copy the EEPROM data out */ - sc->sc_eepromdata = malloc(eepromsize, M_TEMP, M_NOWAIT | M_ZERO); - if (sc->sc_eepromdata == NULL) { - device_printf(dev, "cannot allocate memory for eeprom data\n"); - goto bad1; +#ifdef ATH_EEPROM_FIRMWARE + /* + * If there's an EEPROM firmware image, load that in. + */ + if (resource_string_value(device_get_name(dev), device_get_unit(dev), + "eeprom_firmware", &buf) == 0) { + device_printf(dev, "%s: looking up firmware @ '%s'\n", + __func__, buf); + + fw = firmware_get(buf); + if (fw == NULL) { + device_printf(dev, "%s: couldn't find firmware\n", + __func__); + goto bad1; + } + + device_printf(dev, "%s: EEPROM firmware @ %p\n", + __func__, fw->data); + sc->sc_eepromdata = + malloc(fw->datasize, M_TEMP, M_WAITOK | M_ZERO); + if (! sc->sc_eepromdata) { + device_printf(dev, "%s: can't malloc eepromdata\n", + __func__); + goto bad1; + } + memcpy(sc->sc_eepromdata, fw->data, fw->datasize); + firmware_put(fw, 0); } - device_printf(sc->sc_dev, "eeprom data @ %p\n", (void *) rman_get_bushandle(psc->sc_eeprom)); - /* XXX why doesn't this work? -adrian */ -#if 0 - bus_space_read_multi_1( - rman_get_bustag(psc->sc_eeprom), - rman_get_bushandle(psc->sc_eeprom), - 0, (u_int8_t *) sc->sc_eepromdata, eepromsize); -#endif - p = (void *) rman_get_bushandle(psc->sc_eeprom); - memcpy(sc->sc_eepromdata, p, eepromsize); +#endif /* ATH_EEPROM_FIRMWARE */ /* * Arrange interrupt line. @@ -278,8 +259,6 @@ bad3: bad2: bus_release_resource(dev, SYS_RES_IRQ, 0, psc->sc_irq); bad1: - bus_release_resource(dev, SYS_RES_MEMORY, 0, psc->sc_eeprom); -bad0: bus_release_resource(dev, SYS_RES_MEMORY, 0, psc->sc_sr); bad: /* XXX?! */ @@ -305,7 +284,6 @@ ath_ahb_detach(device_t dev) bus_dma_tag_destroy(sc->sc_dmat); bus_release_resource(dev, SYS_RES_MEMORY, 0, psc->sc_sr); - bus_release_resource(dev, SYS_RES_MEMORY, 0, psc->sc_eeprom); /* XXX?! */ if (sc->sc_eepromdata) free(sc->sc_eepromdata, M_TEMP); From owner-svn-src-head@freebsd.org Wed May 24 01:03:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33C49D6BC70; Wed, 24 May 2017 01:03:32 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DE5211B4C; Wed, 24 May 2017 01:03:31 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O13UP3018518; Wed, 24 May 2017 01:03:30 GMT (envelope-from kevlo@FreeBSD.org) Received: (from kevlo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O13UGx018517; Wed, 24 May 2017 01:03:30 GMT (envelope-from kevlo@FreeBSD.org) Message-Id: <201705240103.v4O13UGx018517@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kevlo set sender to kevlo@FreeBSD.org using -f From: Kevin Lo Date: Wed, 24 May 2017 01:03:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318769 - 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.23 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, 24 May 2017 01:03:32 -0000 Author: kevlo Date: Wed May 24 01:03:30 2017 New Revision: 318769 URL: https://svnweb.freebsd.org/changeset/base/318769 Log: Add missing MLINKS for functions decribed in iflibdd(9), iflibdi(9), and iflibtxrx(9). Modified: head/share/man/man9/Makefile Modified: head/share/man/man9/Makefile ============================================================================== --- head/share/man/man9/Makefile Wed May 24 01:02:35 2017 (r318768) +++ head/share/man/man9/Makefile Wed May 24 01:03:30 2017 (r318769) @@ -963,6 +963,61 @@ MLINKS+=ieee80211_scan.9 ieee80211_add_s MLINKS+=ieee80211_vap.9 ieee80211_vap_attach.9 \ ieee80211_vap.9 ieee80211_vap_detach.9 \ ieee80211_vap.9 ieee80211_vap_setup.9 +MLINKS+=iflibdd.9 ifdi_attach_pre.9 \ + iflibdd.9 ifdi_attach_post.9 \ + iflibdd.9 ifdi_detach.9 \ + iflibdd.9 ifdi_get_counter.9 \ + iflibdd.9 ifdi_i2c_req.9 \ + iflibdd.9 ifdi_init.9 \ + iflibdd.9 ifdi_intr_enable.9 \ + iflibdd.9 ifdi_intr_disable.9 \ + iflibdd.9 ifdi_led_func.9 \ + iflibdd.9 ifdi_link_intr_enable.9 \ + iflibdd.9 ifdi_media_set.9 \ + iflibdd.9 ifdi_media_status.9 \ + iflibdd.9 ifdi_media_change.9 \ + iflibdd.9 ifdi_mtu_set.9 \ + iflibdd.9 ifdi_multi_set.9 \ + iflibdd.9 ifdi_promisc_set.9 \ + iflibdd.9 ifdi_queues_alloc.9 \ + iflibdd.9 ifdi_queues_free.9 \ + iflibdd.9 ifdi_queue_intr_enable.9 \ + iflibdd.9 ifdi_resume.9 \ + iflibdd.9 ifdi_rxq_setup.9 \ + iflibdd.9 ifdi_stop.9 \ + iflibdd.9 ifdi_suspend.9 \ + iflibdd.9 ifdi_sysctl_int_delay.9 \ + iflibdd.9 ifdi_timer.9 \ + iflibdd.9 ifdi_txq_setup.9 \ + iflibdd.9 ifdi_update_admin_status.9 \ + iflibdd.9 ifdi_vf_add.9 \ + iflibdd.9 ifdi_vflr_handle.9 \ + iflibdd.9 ifdi_vlan_register.9 \ + iflibdd.9 ifdi_vlan_unregister.9 \ + iflibdd.9 ifdi_watchdog_reset.9 \ + iflibdd.9 iov_init.9 \ + iflibdd.9 iov_uinit.9 +MLINKS+=iflibdi.9 iflib_add_int_delay_sysctl.9 \ + iflibdi.9 iflib_device_attach.9 \ + iflibdi.9 iflib_device_deregister.9 \ + iflibdi.9 iflib_device_detach.9 \ + iflibdi.9 iflib_device_suspend.9 \ + iflibdi.9 iflib_device_register.9 \ + iflibdi.9 iflib_device_resume.9 \ + iflibdi.9 iflib_led_create.9 \ + iflibdi.9 iflib_irq_alloc.9 \ + iflibdi.9 iflib_irq_alloc_generic.9 \ + iflibdi.9 iflib_link_intr_deferred.9 \ + iflibdi.9 iflib_link_state_change.9 \ + iflibdi.9 iflib_rx_intr_deferred.9 \ + iflibdi.9 iflib_tx_intr_deferred.9 +MLINKS+=iflibtxrx.9 isc_rxd_available.9 \ + iflibtxrx.9 isc_rxd_refill.9 \ + iflibtxrx.9 isc_rxd_flush.9 \ + iflibtxrx.9 isc_rxd_pkt_get.9 \ + iflibtxrx.9 isc_txd_credits_update.9 \ + iflibtxrx.9 isc_txd_encap.9 \ + iflibtxrx.9 isc_txd_flush.9 MLINKS+=ifnet.9 if_addmulti.9 \ ifnet.9 if_alloc.9 \ ifnet.9 if_allmulti.9 \ From owner-svn-src-head@freebsd.org Wed May 24 04:48:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 91253D78A7C; Wed, 24 May 2017 04:48:10 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6340718F3; Wed, 24 May 2017 04:48:10 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O4m9wh011001; Wed, 24 May 2017 04:48:09 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O4m9Mr011000; Wed, 24 May 2017 04:48:09 GMT (envelope-from np@FreeBSD.org) Message-Id: <201705240448.v4O4m9Mr011000@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Wed, 24 May 2017 04:48:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318774 - head/sys/dev/cxgbe/iw_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.23 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, 24 May 2017 04:48:10 -0000 Author: np Date: Wed May 24 04:48:09 2017 New Revision: 318774 URL: https://svnweb.freebsd.org/changeset/base/318774 Log: cxgbe/iw_cxgbe: sodisconnect failures are harmless and should not be treated as fatal errors. MFC after: 3 days Sponsored by: Chelsio Communications Modified: head/sys/dev/cxgbe/iw_cxgbe/cm.c Modified: head/sys/dev/cxgbe/iw_cxgbe/cm.c ============================================================================== --- head/sys/dev/cxgbe/iw_cxgbe/cm.c Wed May 24 04:42:31 2017 (r318773) +++ head/sys/dev/cxgbe/iw_cxgbe/cm.c Wed May 24 04:48:09 2017 (r318774) @@ -2376,6 +2376,8 @@ int c4iw_ep_disconnect(struct c4iw_ep *e set_bit(EP_DISC_ABORT, &ep->com.history); close_complete_upcall(ep, -ECONNRESET); ret = send_abort(ep); + if (ret) + fatal = 1; } else { CTR2(KTR_IW_CXGBE, "%s:ced5 %p", __func__, ep); @@ -2383,13 +2385,9 @@ int c4iw_ep_disconnect(struct c4iw_ep *e if (!ep->parent_ep) __state_set(&ep->com, MORIBUND); - ret = sodisconnect(ep->com.so); + sodisconnect(ep->com.so); } - if (ret) { - - fatal = 1; - } } if (fatal) { From owner-svn-src-head@freebsd.org Wed May 24 09:05:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DD535D7B875; Wed, 24 May 2017 09:05:58 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5A27F13B2; Wed, 24 May 2017 09:05:58 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4O95qbG030400 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 24 May 2017 12:05:53 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4O95qbG030400 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4O95qht030392; Wed, 24 May 2017 12:05:52 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 24 May 2017 12:05:52 +0300 From: Konstantin Belousov To: Larry Rosenman Cc: Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Subject: Re: svn commit: r318757 - head Message-ID: <20170524090552.GF1622@kib.kiev.ua> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 09:05:59 -0000 On Tue, May 23, 2017 at 04:46:14PM -0500, Larry Rosenman wrote: > My PostgreSQL buildfarm animal BROKE with this change until I force rebuilt > lang/perl5.24 > and all my p5-* ports. So what was the symptoms and the error, exactly ? A lot of efforts were spent to ensure that _consistent_ set of old binaries and libraries would run without issues on the new system. I mean that if you have binaries and libraries built on pre-ino64 system, which do not reference any libraries built on post ino64, except system libraries (like libc/libthr etc), everything should work. This feature was the main cause of long delay finishing ino64. > > emulators/qemu-user-static also won???t compile (sbruno@ is on this one). This is a separate issue. > > Poudriere did *NOT* force a fuill rebuild even though freebsd-version *WAS* bumped. > > Is there a hazard for others here? > > Or more info needed in /usr/{src,ports}/UPDATING? > > > -- > Larry Rosenman http://www.lerctr.org/~ler > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > From owner-svn-src-head@freebsd.org Wed May 24 09:25:14 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A7B36D7BEC0; Wed, 24 May 2017 09:25:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8203F1FD1; Wed, 24 May 2017 09:25:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4O9PD6r026684; Wed, 24 May 2017 09:25:13 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4O9PDsZ026682; Wed, 24 May 2017 09:25:13 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705240925.v4O9PDsZ026682@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 24 May 2017 09:25:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318780 - in head: include 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.23 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, 24 May 2017 09:25:14 -0000 Author: kib Date: Wed May 24 09:25:13 2017 New Revision: 318780 URL: https://svnweb.freebsd.org/changeset/base/318780 Log: Use __BSD_VISIBLE test instead checking for absense of _POSIX_SOURCE. The Termios headers and used sometimes _POSIX_SOURCE directly to determine if a thing should be exposed to the user. This circumvented the feature mechanisms of . Submitted by: Sebastian Huber MFC after: 2 weeks Modified: head/include/termios.h head/sys/sys/_termios.h Modified: head/include/termios.h ============================================================================== --- head/include/termios.h Wed May 24 09:09:10 2017 (r318779) +++ head/include/termios.h Wed May 24 09:25:13 2017 (r318780) @@ -42,12 +42,12 @@ typedef __pid_t pid_t; #define _PID_T_DECLARED #endif -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define OXTABS TAB3 #define MDMBUF CCAR_OFLOW #endif -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define CCEQ(val, c) ((c) == (val) && (val) != _POSIX_VDISABLE) #endif @@ -57,7 +57,7 @@ typedef __pid_t pid_t; #define TCSANOW 0 /* make change immediate */ #define TCSADRAIN 1 /* drain output, then change */ #define TCSAFLUSH 2 /* drain output, flush input */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define TCSASOFT 0x10 /* flag - don't alter h.w. state */ #endif @@ -95,7 +95,7 @@ __END_DECLS #endif /* !_TERMIOS_H_ */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #include #include #endif Modified: head/sys/sys/_termios.h ============================================================================== --- head/sys/sys/_termios.h Wed May 24 09:09:10 2017 (r318779) +++ head/sys/sys/_termios.h Wed May 24 09:25:13 2017 (r318780) @@ -42,15 +42,15 @@ */ #define VEOF 0 /* ICANON */ #define VEOL 1 /* ICANON */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VEOL2 2 /* ICANON together with IEXTEN */ #endif #define VERASE 3 /* ICANON */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VWERASE 4 /* ICANON together with IEXTEN */ #endif #define VKILL 5 /* ICANON */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VREPRINT 6 /* ICANON together with IEXTEN */ #define VERASE2 7 /* ICANON */ #endif @@ -58,18 +58,18 @@ #define VINTR 8 /* ISIG */ #define VQUIT 9 /* ISIG */ #define VSUSP 10 /* ISIG */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VDSUSP 11 /* ISIG together with IEXTEN */ #endif #define VSTART 12 /* IXON, IXOFF */ #define VSTOP 13 /* IXON, IXOFF */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VLNEXT 14 /* IEXTEN */ #define VDISCARD 15 /* IEXTEN */ #endif #define VMIN 16 /* !ICANON */ #define VTIME 17 /* !ICANON */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define VSTATUS 18 /* ICANON together with IEXTEN */ /* 19 spare 2 */ #endif @@ -91,16 +91,16 @@ #define ICRNL 0x00000100 /* map CR to NL (ala CRMOD) */ #define IXON 0x00000200 /* enable output flow control */ #define IXOFF 0x00000400 /* enable input flow control */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define IXANY 0x00000800 /* any char will restart after stop */ #define IMAXBEL 0x00002000 /* ring bell on input queue full */ -#endif /*_POSIX_SOURCE */ +#endif /* * Output flags - software output processing */ #define OPOST 0x00000001 /* enable following output processing */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define ONLCR 0x00000002 /* map NL to CR-NL (ala CRMOD) */ #define TABDLY 0x00000004 /* tab delay mask */ #define TAB0 0x00000000 /* no tab delay and expansion */ @@ -109,12 +109,12 @@ #define OCRNL 0x00000010 /* map CR to NL on output */ #define ONOCR 0x00000020 /* no CR output at column 0 */ #define ONLRET 0x00000040 /* NL performs CR function */ -#endif /*_POSIX_SOURCE */ +#endif /* * Control flags - hardware control of terminal */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define CIGNORE 0x00000001 /* ignore control flags */ #endif #define CSIZE 0x00000300 /* character size mask */ @@ -128,7 +128,7 @@ #define PARODD 0x00002000 /* odd parity, else even */ #define HUPCL 0x00004000 /* hang up on last close */ #define CLOCAL 0x00008000 /* ignore modem status lines */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define CCTS_OFLOW 0x00010000 /* CTS flow control of output */ #define CRTSCTS (CCTS_OFLOW | CRTS_IFLOW) #define CRTS_IFLOW 0x00020000 /* RTS flow control of input */ @@ -146,30 +146,30 @@ * input flag. */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define ECHOKE 0x00000001 /* visual erase for line kill */ -#endif /*_POSIX_SOURCE */ +#endif #define ECHOE 0x00000002 /* visually erase chars */ #define ECHOK 0x00000004 /* echo NL after line kill */ #define ECHO 0x00000008 /* enable echoing */ #define ECHONL 0x00000010 /* echo NL even if ECHO is off */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define ECHOPRT 0x00000020 /* visual erase mode for hardcopy */ #define ECHOCTL 0x00000040 /* echo control chars as ^(Char) */ -#endif /*_POSIX_SOURCE */ +#endif #define ISIG 0x00000080 /* enable signals INTR, QUIT, [D]SUSP */ #define ICANON 0x00000100 /* canonicalize input lines */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define ALTWERASE 0x00000200 /* use alternate WERASE algorithm */ -#endif /*_POSIX_SOURCE */ +#endif #define IEXTEN 0x00000400 /* enable DISCARD and LNEXT */ #define EXTPROC 0x00000800 /* external processing */ #define TOSTOP 0x00400000 /* stop background jobs from output */ -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define FLUSHO 0x00800000 /* output being flushed (state) */ #define NOKERNINFO 0x02000000 /* no kernel output from VSTATUS */ #define PENDIN 0x20000000 /* XXX retype pending input (state) */ -#endif /*_POSIX_SOURCE */ +#endif #define NOFLSH 0x80000000 /* don't flush after interrupt */ /* @@ -191,7 +191,7 @@ #define B9600 9600 #define B19200 19200 #define B38400 38400 -#ifndef _POSIX_SOURCE +#if __BSD_VISIBLE #define B7200 7200 #define B14400 14400 #define B28800 28800 @@ -203,7 +203,7 @@ #define B921600 921600 #define EXTA 19200 #define EXTB 38400 -#endif /* !_POSIX_SOURCE */ +#endif typedef unsigned int tcflag_t; typedef unsigned char cc_t; From owner-svn-src-head@freebsd.org Wed May 24 10:09:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 07255D7AF1E; Wed, 24 May 2017 10:09:56 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BC20D16AF; Wed, 24 May 2017 10:09:55 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OA9sUj043746; Wed, 24 May 2017 10:09:54 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OA9sMY043744; Wed, 24 May 2017 10:09:54 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705241009.v4OA9sMY043744@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 24 May 2017 10:09:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318781 - 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.23 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, 24 May 2017 10:09:56 -0000 Author: kib Date: Wed May 24 10:09:54 2017 New Revision: 318781 URL: https://svnweb.freebsd.org/changeset/base/318781 Log: Add BIT_OR2(), BIT_AND2(), BIT_NAND2(), BIT_XOR() and BIT_XOR2(). Submitted by: Sebastian Huber MFC after: 2 weeks Modified: head/share/man/man9/bitset.9 head/sys/sys/bitset.h Modified: head/share/man/man9/bitset.9 ============================================================================== --- head/share/man/man9/bitset.9 Wed May 24 09:25:13 2017 (r318780) +++ head/share/man/man9/bitset.9 Wed May 24 10:09:54 2017 (r318781) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 29, 2016 +.Dd May 24, 2017 .Dt BITSET 9 .Os .Sh NAME @@ -48,8 +48,13 @@ .Nm BIT_OVERLAP , .Nm BIT_CMP , .Nm BIT_OR , +.Nm BIT_OR2 , .Nm BIT_AND , +.Nm BIT_AND2 , .Nm BIT_NAND , +.Nm BIT_NAND2 , +.Nm BIT_XOR , +.Nm BIT_XOR2 , .Nm BIT_CLR_ATOMIC , .Nm BIT_SET_ATOMIC , .Nm BIT_SET_ATOMIC_ACQ , @@ -95,8 +100,33 @@ .Fa "const SETSIZE" "struct STRUCTNAME *bitset1" "struct STRUCTNAME *bitset2" .Fc .Fn BIT_OR "const SETSIZE" "struct STRUCTNAME *dst" "struct STRUCTNAME *src" +.Fo BIT_OR2 +.Fa "const SETSIZE" +.Fa "struct STRUCTNAME *dst" +.Fa "struct STRUCTNAME *src1" +.Fa "struct STRUCTNAME *src2" +.Fc .Fn BIT_AND "const SETSIZE" "struct STRUCTNAME *dst" "struct STRUCTNAME *src" +.Fo BIT_AND2 +.Fa "const SETSIZE" +.Fa "struct STRUCTNAME *dst" +.Fa "struct STRUCTNAME *src1" +.Fa "struct STRUCTNAME *src2" +.Fc .Fn BIT_NAND "const SETSIZE" "struct STRUCTNAME *dst" "struct STRUCTNAME *src" +.Fo BIT_NAND2 +.Fa "const SETSIZE" +.Fa "struct STRUCTNAME *dst" +.Fa "struct STRUCTNAME *src1" +.Fa "struct STRUCTNAME *src2" +.Fc +.Fn BIT_XOR "const SETSIZE" "struct STRUCTNAME *dst" "struct STRUCTNAME *src" +.Fo BIT_XOR2 +.Fa "const SETSIZE" +.Fa "struct STRUCTNAME *dst" +.Fa "struct STRUCTNAME *src1" +.Fa "struct STRUCTNAME *src2" +.Fc .\" .Fn BIT_CLR_ATOMIC "const SETSIZE" "size_t bit" "struct STRUCTNAME *bitset" .Fn BIT_SET_ATOMIC "const SETSIZE" "size_t bit" "struct STRUCTNAME *bitset" @@ -312,6 +342,23 @@ is composed of multiple machine words, performs multiple individually atomic operations.) .Pp The +.Fn BIT_OR2 +macro computes +.Fa src1 +bitwise or +.Fa src2 +and assigns the result to +.Fa dst . +(It is the +.Nm +equivalent of the scalar: +.Fa dst += +.Fa src1 +| +.Fa src2 . ) +.Pp +The .Fn BIT_AND macro clears bits absent from .Fa src @@ -328,6 +375,23 @@ is similar, with the same atomic semanti .Fn BIT_OR_ATOMIC . .Pp The +.Fn BIT_AND2 +macro computes +.Fa src1 +bitwise and +.Fa src2 +and assigns the result to +.Fa dst . +(It is the +.Nm +equivalent of the scalar: +.Fa dst += +.Fa src1 +& +.Fa src2 . ) +.Pp +The .Fn BIT_NAND macro clears bits set in .Fa src @@ -339,6 +403,53 @@ equivalent of the scalar: .Fa dst &= .Fa ~ src . ) +.Pp +The +.Fn BIT_NAND2 +macro computes +.Fa src1 +bitwise and not +.Fa src2 +and assigns the result to +.Fa dst . +(It is the +.Nm +equivalent of the scalar: +.Fa dst += +.Fa src1 +& ~ +.Fa src2 . ) +.Pp +The +.Fn BIT_XOR +macro toggles bits set in +.Fa src +in +.Fa dst . +(It is the +.Nm +equivalent of the scalar: +.Fa dst +^= +.Fa src . ) +.Pp +The +.Fn BIT_XOR2 +macro computes +.Fa src1 +bitwise exclusive or +.Fa src2 +and assigns the result to +.Fa dst . +(It is the +.Nm +equivalent of the scalar: +.Fa dst += +.Fa src1 +^ +.Fa src2 . ) .Sh BITSET_T_INITIALIZER EXAMPLE .Bd -literal BITSET_DEFINE(_myset, MYSETSIZE); Modified: head/sys/sys/bitset.h ============================================================================== --- head/sys/sys/bitset.h Wed May 24 09:25:13 2017 (r318780) +++ head/sys/sys/bitset.h Wed May 24 10:09:54 2017 (r318781) @@ -122,18 +122,48 @@ (d)->__bits[__i] |= (s)->__bits[__i]; \ } while (0) +#define BIT_OR2(_s, d, s1, s2) do { \ + __size_t __i; \ + for (__i = 0; __i < __bitset_words((_s)); __i++) \ + (d)->__bits[__i] = (s1)->__bits[__i] | (s2)->__bits[__i];\ +} while (0) + #define BIT_AND(_s, d, s) do { \ __size_t __i; \ for (__i = 0; __i < __bitset_words((_s)); __i++) \ (d)->__bits[__i] &= (s)->__bits[__i]; \ } while (0) +#define BIT_AND2(_s, d, s1, s2) do { \ + __size_t __i; \ + for (__i = 0; __i < __bitset_words((_s)); __i++) \ + (d)->__bits[__i] = (s1)->__bits[__i] & (s2)->__bits[__i];\ +} while (0) + #define BIT_NAND(_s, d, s) do { \ __size_t __i; \ for (__i = 0; __i < __bitset_words((_s)); __i++) \ (d)->__bits[__i] &= ~(s)->__bits[__i]; \ } while (0) +#define BIT_NAND2(_s, d, s1, s2) do { \ + __size_t __i; \ + for (__i = 0; __i < __bitset_words((_s)); __i++) \ + (d)->__bits[__i] = (s1)->__bits[__i] & ~(s2)->__bits[__i];\ +} while (0) + +#define BIT_XOR(_s, d, s) do { \ + __size_t __i; \ + for (__i = 0; __i < __bitset_words((_s)); __i++) \ + (d)->__bits[__i] ^= (s)->__bits[__i]; \ +} while (0) + +#define BIT_XOR2(_s, d, s1, s2) do { \ + __size_t __i; \ + for (__i = 0; __i < __bitset_words((_s)); __i++) \ + (d)->__bits[__i] = (s1)->__bits[__i] ^ (s2)->__bits[__i];\ +} while (0) + #define BIT_CLR_ATOMIC(_s, n, p) \ atomic_clear_long(&(p)->__bits[__bitset_word(_s, n)], \ __bitset_mask((_s), n)) From owner-svn-src-head@freebsd.org Wed May 24 13:06:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4E018D7B2EB; Wed, 24 May 2017 13:06:36 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2C00816BF; Wed, 24 May 2017 13:06:36 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:CC:To:From:Subject:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=Zn21Gb2CZEPJpRgF45rO/+tXieOqv+9MKeq/3Z1Rz8g=; b=nmI8f4c7F3MOk9rI0/4Fxz2Nv2 PFGMsUbJKNeQcvIJVdTgZT5Xe8l0wUkMd2EpRlbOsQRwSDrzRY4LMJn8UWcEaDwdC0UWrIIUptQ1z Mt5qP0A8BRL8leEc1nU+ZsE25fDC6K0MWnX9dCWVCdz5YESYZEaQTswWb5oHIHDws6Wk=; Received: from [47.220.164.50] (port=35847 helo=[192.168.200.198]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDVzn-000BkK-A5; Wed, 24 May 2017 08:06:35 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Wed, 24 May 2017 08:06:34 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: Konstantin Belousov CC: Ed Maste , , , , "freebsd-current@freebsd.org" Message-ID: <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> In-Reply-To: <20170524090552.GF1622@kib.kiev.ua> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 13:06:36 -0000 The initial failure: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=peripatus&dt=2017-05-23%2019%3A17%3A42 I then recompiled perl, and got: borg.lerctr.org /home/pgbuildfarm $ cd /home/pgbuildfarm/bin/latest && ./run_branches.pl --run-all --config=/home/pgbuildfarm/conf/build-farm.conf Socket.c: loadable library and perl binaries are mismatched (got handshake key 0xd200080, needed 0xdf00080) borg.lerctr.org /home/pgbuildfarm/bin/latest $ force rebuilding and installing perl and all p5-* ports fixed that. -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 On 5/24/17, 4:05 AM, "Konstantin Belousov" wrote: On Tue, May 23, 2017 at 04:46:14PM -0500, Larry Rosenman wrote: > My PostgreSQL buildfarm animal BROKE with this change until I force rebuilt > lang/perl5.24 > and all my p5-* ports. So what was the symptoms and the error, exactly ? A lot of efforts were spent to ensure that _consistent_ set of old binaries and libraries would run without issues on the new system. I mean that if you have binaries and libraries built on pre-ino64 system, which do not reference any libraries built on post ino64, except system libraries (like libc/libthr etc), everything should work. This feature was the main cause of long delay finishing ino64. > > emulators/qemu-user-static also won???t compile (sbruno@ is on this one). This is a separate issue. > > Poudriere did *NOT* force a fuill rebuild even though freebsd-version *WAS* bumped. > > Is there a hazard for others here? > > Or more info needed in /usr/{src,ports}/UPDATING? > > > -- > Larry Rosenman http://www.lerctr.org/~ler > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > From owner-svn-src-head@freebsd.org Wed May 24 13:33:24 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BB15FD7BF5B; Wed, 24 May 2017 13:33:24 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 613BF1ACE; Wed, 24 May 2017 13:33:23 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v4ODXI8N090403 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 24 May 2017 16:33:18 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v4ODXI8N090403 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v4ODXIYW090402; Wed, 24 May 2017 16:33:18 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 24 May 2017 16:33:18 +0300 From: Konstantin Belousov To: Larry Rosenman Cc: Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Subject: Re: svn commit: r318757 - head Message-ID: <20170524133318.GN1622@kib.kiev.ua> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> User-Agent: Mutt/1.8.2 (2017-04-18) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 13:33:24 -0000 On Wed, May 24, 2017 at 08:06:34AM -0500, Larry Rosenman wrote: > The initial failure: > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=peripatus&dt=2017-05-23%2019%3A17%3A42 > > I then recompiled perl, and got: > borg.lerctr.org /home/pgbuildfarm $ cd /home/pgbuildfarm/bin/latest && ./run_branches.pl --run-all --config=/home/pgbuildfarm/conf/build-farm.conf > Socket.c: loadable library and perl binaries are mismatched (got handshake key 0xd200080, needed 0xdf00080) > borg.lerctr.org /home/pgbuildfarm/bin/latest $ > > force rebuilding and installing perl and all p5-* ports fixed that. >From what I understand in reading some perl bugs and perl source, perl performs some validation of the structures shared between the perl interpreter and XS libraries loaded into it. So I am almost sure that you have perl itself and some module built against different src/ bases. Is it true ? If yes, then this is user error. You are trying to mix two binaries built against incompatible ABI. > > > > -- > Larry Rosenman http://www.lerctr.org/~ler > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > On 5/24/17, 4:05 AM, "Konstantin Belousov" wrote: > > On Tue, May 23, 2017 at 04:46:14PM -0500, Larry Rosenman wrote: > > My PostgreSQL buildfarm animal BROKE with this change until I force rebuilt > > lang/perl5.24 > > and all my p5-* ports. > So what was the symptoms and the error, exactly ? > > A lot of efforts were spent to ensure that _consistent_ set of old binaries > and libraries would run without issues on the new system. I mean that > if you have binaries and libraries built on pre-ino64 system, which do > not reference any libraries built on post ino64, except system libraries > (like libc/libthr etc), everything should work. This feature was the > main cause of long delay finishing ino64. > > > > > emulators/qemu-user-static also won???t compile (sbruno@ is on this one). > This is a separate issue. > > > > > Poudriere did *NOT* force a fuill rebuild even though freebsd-version *WAS* bumped. > > > > Is there a hazard for others here? > > > > Or more info needed in /usr/{src,ports}/UPDATING? > > > > > > -- > > Larry Rosenman http://www.lerctr.org/~ler > > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > > > > > > > From owner-svn-src-head@freebsd.org Wed May 24 13:53:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D5C87D7A7FA; Wed, 24 May 2017 13:53:26 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B35521A18; Wed, 24 May 2017 13:53:26 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:CC:To:From:Subject:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=5D4J63eVro7sM0qJYmf0PJG6ACD7iZtn76b58drdU6o=; b=XUtdEP++BaoXkQH92eWBbE12az kFmxLcyycirFT6JxW/KVwDQm1Pi+58m+dC4x2hlwny9bb8mh4Ur1tFNo5w4EI8ssbqU24FGZdcPHf Km2XbpyBlijqk9Y0JLz8tR8vgIG9+qJ4IKQmKKhuIBg5lNzIYOOSJRSc+hIsVc+bInpk=; Received: from [74.203.163.58] (port=13119 helo=[10.106.10.44]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDWj7-000DHr-VU; Wed, 24 May 2017 08:53:26 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Wed, 24 May 2017 08:52:55 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: Konstantin Belousov CC: Ed Maste , , , , "freebsd-current@freebsd.org" Message-ID: <341C4D4C-13EE-4640-96DC-F019E1A6E778@lerctr.org> Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524133318.GN1622@kib.kiev.ua> In-Reply-To: <20170524133318.GN1622@kib.kiev.ua> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 13:53:26 -0000 The initial failure was NOT, except that the PostgreSQL build builds a PL/Perl interpreter that MIGHT Be considered that. It was unexpected. -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 On 5/24/17, 8:33 AM, "Konstantin Belousov" wrote: On Wed, May 24, 2017 at 08:06:34AM -0500, Larry Rosenman wrote: > The initial failure: > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=peripatus&dt=2017-05-23%2019%3A17%3A42 > > I then recompiled perl, and got: > borg.lerctr.org /home/pgbuildfarm $ cd /home/pgbuildfarm/bin/latest && ./run_branches.pl --run-all --config=/home/pgbuildfarm/conf/build-farm.conf > Socket.c: loadable library and perl binaries are mismatched (got handshake key 0xd200080, needed 0xdf00080) > borg.lerctr.org /home/pgbuildfarm/bin/latest $ > > force rebuilding and installing perl and all p5-* ports fixed that. From what I understand in reading some perl bugs and perl source, perl performs some validation of the structures shared between the perl interpreter and XS libraries loaded into it. So I am almost sure that you have perl itself and some module built against different src/ bases. Is it true ? If yes, then this is user error. You are trying to mix two binaries built against incompatible ABI. > > > > -- > Larry Rosenman http://www.lerctr.org/~ler > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > On 5/24/17, 4:05 AM, "Konstantin Belousov" wrote: > > On Tue, May 23, 2017 at 04:46:14PM -0500, Larry Rosenman wrote: > > My PostgreSQL buildfarm animal BROKE with this change until I force rebuilt > > lang/perl5.24 > > and all my p5-* ports. > So what was the symptoms and the error, exactly ? > > A lot of efforts were spent to ensure that _consistent_ set of old binaries > and libraries would run without issues on the new system. I mean that > if you have binaries and libraries built on pre-ino64 system, which do > not reference any libraries built on post ino64, except system libraries > (like libc/libthr etc), everything should work. This feature was the > main cause of long delay finishing ino64. > > > > > emulators/qemu-user-static also won???t compile (sbruno@ is on this one). > This is a separate issue. > > > > > Poudriere did *NOT* force a fuill rebuild even though freebsd-version *WAS* bumped. > > > > Is there a hazard for others here? > > > > Or more info needed in /usr/{src,ports}/UPDATING? > > > > > > -- > > Larry Rosenman http://www.lerctr.org/~ler > > Phone: +1 214-642-9640 E-Mail: ler@lerctr.org > > US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 > > > > > > > > > > From owner-svn-src-head@freebsd.org Wed May 24 14:24:49 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5AFBED7B3DC; Wed, 24 May 2017 14:24:49 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2B1571F11; Wed, 24 May 2017 14:24:49 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OEOmMC053465; Wed, 24 May 2017 14:24:48 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OEOmIf053464; Wed, 24 May 2017 14:24:48 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201705241424.v4OEOmIf053464@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Wed, 24 May 2017 14:24:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318788 - 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.23 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, 24 May 2017 14:24:49 -0000 Author: pfg Date: Wed May 24 14:24:47 2017 New Revision: 318788 URL: https://svnweb.freebsd.org/changeset/base/318788 Log: bhyvegc_resize: make use of reallocarray(3) for bounds-checking. Also add __FBSDID. Reviewed by: grehan This file lacks a license(!) so for this change the following declaration applies: To the greatest extent permitted by, but not in contravention of, applicable law, Affirmer hereby overtly, fully, permanently, irrevocably and unconditionally waives, abandons, and surrenders all of Affirmer's Copyright and Related Rights and associated claims and causes of action, whether now known or unknown (including existing as well as future claims and causes of action). Modified: head/usr.sbin/bhyve/bhyvegc.c Modified: head/usr.sbin/bhyve/bhyvegc.c ============================================================================== --- head/usr.sbin/bhyve/bhyvegc.c Wed May 24 14:22:22 2017 (r318787) +++ head/usr.sbin/bhyve/bhyvegc.c Wed May 24 14:24:47 2017 (r318788) @@ -1,4 +1,5 @@ #include +__FBSDID("$FreeBSD$"); #include @@ -56,9 +57,11 @@ bhyvegc_resize(struct bhyvegc *gc, int w gc_image->width = width; gc_image->height = height; if (!gc->raw) { - gc_image->data = realloc(gc_image->data, - sizeof (uint32_t) * width * height); - memset(gc_image->data, 0, width * height * sizeof (uint32_t)); + gc_image->data = reallocarray(gc_image->data, width * height, + sizeof (uint32_t)); + if (gc_image->data != NULL) + memset(gc_image->data, 0, width * height * + sizeof (uint32_t)); } } From owner-svn-src-head@freebsd.org Wed May 24 14:36:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7227DD7B83B; Wed, 24 May 2017 14:36:53 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3F455167D; Wed, 24 May 2017 14:36:53 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OEaq2Q057611; Wed, 24 May 2017 14:36:52 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OEaq6k057610; Wed, 24 May 2017 14:36:52 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201705241436.v4OEaq6k057610@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Wed, 24 May 2017 14:36:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318789 - head/sys/contrib/ipfilter/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.23 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, 24 May 2017 14:36:53 -0000 Author: cy Date: Wed May 24 14:36:51 2017 New Revision: 318789 URL: https://svnweb.freebsd.org/changeset/base/318789 Log: Ifdef out a redundant if statement when LARGE_NAT is disabled. MFC after: 1 week Modified: head/sys/contrib/ipfilter/netinet/ip_nat.c Modified: head/sys/contrib/ipfilter/netinet/ip_nat.c ============================================================================== --- head/sys/contrib/ipfilter/netinet/ip_nat.c Wed May 24 14:24:47 2017 (r318788) +++ head/sys/contrib/ipfilter/netinet/ip_nat.c Wed May 24 14:36:51 2017 (r318789) @@ -497,7 +497,9 @@ ipf_nat_soft_init(softc, arg) softn->ipf_nat_pending.ifq_next = NULL; for (i = 0, tq = softn->ipf_nat_tcptq; i < IPF_TCP_NSTATES; i++, tq++) { +#ifdef LARGE_NAT if (tq->ifq_ttl < softn->ipf_nat_deficmpage) +#endif tq->ifq_ttl = softn->ipf_nat_deficmpage; #ifdef LARGE_NAT else if (tq->ifq_ttl > softn->ipf_nat_defage) From owner-svn-src-head@freebsd.org Wed May 24 14:53:25 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 76F8FD7A057 for ; Wed, 24 May 2017 14:53:25 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from nm20-vm4.bullet.mail.ne1.yahoo.com (nm20-vm4.bullet.mail.ne1.yahoo.com [98.138.91.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 46F6B1281 for ; Wed, 24 May 2017 14:53:25 +0000 (UTC) (envelope-from pfg@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1495637598; bh=WQlOQbTL5h2Oo8BRBokTJenmSFxhGyO6yNYH2lodR8w=; h=Subject:To:References:From:Date:In-Reply-To:From:Subject; b=d88jeUAkYvjMi0XZUu0yCNYXOu9m6g0i4w8b+ctTll8rjKkdtcqs5sGoh4o5v0pNrz6qHNoz3wzUnTHP7ESlQZCkSH6aqFEtFaulReHDHcBBk36TYu80kg52esHXheV0XtTb8rIDg6MOiXBStLPTdpSQOP/6fwDAUyp4qlKkSz3RH99rGbn/z5sxkOcp20jkJjU9eCa/aTsJ4OsvRH/M9AaGi1OiTxoGst+RnlscR2/YR4lbKUpaoBA9OWBLU+iJrg6f5blCAFDsRscELvUdjp6PmHAFw7QNkPgNwviowyVHZrMbwloN2UC7FxyVtsp9GrdVL2sgGLQdUWXaaLNkEg== Received: from [98.138.101.132] by nm20.bullet.mail.ne1.yahoo.com with NNFMP; 24 May 2017 14:53:18 -0000 Received: from [98.138.104.112] by tm20.bullet.mail.ne1.yahoo.com with NNFMP; 24 May 2017 14:53:18 -0000 Received: from [127.0.0.1] by smtp221.mail.ne1.yahoo.com with NNFMP; 24 May 2017 14:53:18 -0000 X-Yahoo-Newman-Id: 508169.93409.bm@smtp221.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: CfyyFkAVM1mh2qSmmQkT0Xb610dbv6dqT.yuQsGSeyo63kG g3UEN0g9ommSGiAciM59uDQ3MYy_BR4i8ptCA6lLSgNHQuQgg.zvThYRo4Xw 8FJDqPvRSqu1NgBr5xbCG1wwhqw_M4NoiJ2i0xSpyvH5DhAdwUpjt_2da7Gb fh5yDbJeUnIAAgH17JqDh_MB4IACdbX0Pm0.RobkA4Ux6lDS9GuFuQMOhnWE Islh.d1if57KmHfZiaDDV6KqsxC_Av2HmLu0IwJ_YTw8GhIREfhIK0eShNZH uHQJExSSPdAP8WcuRmsnzkESoSKUUignKyw6qwWuIGwKQLKUfvL4Zyf3mW6L 4_TJQNKgKea_PxCBYNj8yvh1HLezGaV5Ll1R2eRmwc_tWlvZOo4bSWbnl0Bg qyB.BD28efpLp7c.9RxyUuBxdXmFcf6m4i4JAye3yMv00b6g_2ElXt86iuo6 Cr7qNs0oZB5BaOq7dxXP_90t81.GG8kSLXzMHRtmZiexF0nz2JLapZ4NhQ37 IyoOtlzsb5WboYRYzlPck.NsBI2n.EqZ8hgAY._uz30qQ X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... To: Konstantin Belousov , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201705230929.v4N9T5g1028124@repo.freebsd.org> From: Pedro Giffuni Organization: FreeBSD Message-ID: Date: Wed, 24 May 2017 09:53:17 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: <201705230929.v4N9T5g1028124@repo.freebsd.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 14:53:25 -0000 First of all, HUGE thanks to everyone involved in this project! On 05/23/17 04:29, Konstantin Belousov wrote: > Author: kib > Date: Tue May 23 09:29:05 2017 > New Revision: 318736 > URL: https://svnweb.freebsd.org/changeset/base/318736 > > Log: > Commit the 64-bit inode project. > > Extend the ino_t, dev_t, nlink_t types to 64-bit ints. Modify > struct dirent layout to add d_off, increase the size of d_fileno > to 64-bits, increase the size of d_namlen to 16-bits, and change > the required alignment. Increase struct statfs f_mntfromname[] and > f_mntonname[] array length MNAMELEN to 1024. > > ABI breakage is mitigated by providing compatibility using versioned > symbols, ingenious use of the existing padding in structures, and > by employing other tricks. Unfortunately, not everything can be > fixed, especially outside the base system. For instance, third-party > APIs which pass struct stat around are broken in backward and > forward incompatible ways. > > Kinfo sysctl MIBs ABI is changed in backward-compatible way, but > there is no general mechanism to handle other sysctl MIBS which > return structures where the layout has changed. It was considered > that the breakage is either in the management interfaces, where we > usually allow ABI slip, or is not important. > > Struct xvnode changed layout, no compat shims are provided. > > For struct xtty, dev_t tty device member was reduced to uint32_t. > It was decided that keeping ABI compat in this case is more useful > than reporting 64-bit dev_t, for the sake of pstat. > > Update note: strictly follow the instructions in UPDATING. Build > and install the new kernel with COMPAT_FREEBSD11 option enabled, > then reboot, and only then install new world. > > Credits: The 64-bit inode project, also known as ino64, started life > many years ago as a project by Gleb Kurtsou (gleb). Kirk McKusick > (mckusick) then picked up and updated the patch, and acted as a > flag-waver. Feedback, suggestions, and discussions were carried > by Ed Maste (emaste), John Baldwin (jhb), Jilles Tjoelker (jilles), > and Rick Macklem (rmacklem). Kris Moore (kris) performed an initial > ports investigation followed by an exp-run by Antoine Brodin (antoine). > Essential and all-embracing testing was done by Peter Holm (pho). > The heavy lifting of coordinating all these efforts and bringing the > project to completion were done by Konstantin Belousov (kib). > > Sponsored by: The FreeBSD Foundation (emaste, kib) > Differential revision: https://reviews.freebsd.org/D10439 > There is now a bunch of coverity issues (OVERFLOW_BEFORE_WIDEN mostly) tied to ino64_t. At least the following CIDs are related: 977071, 977072, 977073, 977094, 977095, 977096, 1375572, 1375573, 1375574, 1375575 1375576, 1375577, 1375578, 1375579, 1375580, 1375581, 1375582, 1375584. It may take some time to shake up the issues but the change was very necessary. Thanks again! Pedro. From owner-svn-src-head@freebsd.org Wed May 24 16:26:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48DA6D7C906; Wed, 24 May 2017 16:26:22 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-oi0-x22e.google.com (mail-oi0-x22e.google.com [IPv6:2607:f8b0:4003:c06::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0AB061437; Wed, 24 May 2017 16:26:22 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-oi0-x22e.google.com with SMTP id b204so248413756oii.1; Wed, 24 May 2017 09:26:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=1mKs5uCw24aKza8ugHIhUmZZwN7AIdvnQJLEDXXXnvo=; b=IiqPjM7ezLyp6K0yCA1w0fIz5im/Mj5scxukPBnf+QQhcb+zinCmCL2KbrzTgxef6M 4C79V6FVRgOyqrZErBcySbwUWTja/LvyqaubwtAHFe8kFjYidfSuX/1eEm+qYNR4P9UO 6dfMh3HPJ03+E8rBqI/h6dcqXjgQGxrX61MGGxjitcnaKjUZa0KQdX/yM3UwPgs+MAul 3UhpUg6eiooDz5lXjNvxOrJfBwa3lA5PTV5WPinptjLyVb9NQlqsED5sHW/KYed40V1O dZmjev68PSyJKDihe6sRO9qYhc4EA/wucFqCKyOmSfPpMn9+TUJ/IRXlEt7fOorzwJ9L qFng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=1mKs5uCw24aKza8ugHIhUmZZwN7AIdvnQJLEDXXXnvo=; b=MdXJiKZLhhHwAq5z/lhro2iptK/BajdvhBe29ikvTL5G1qgPiZ6U/0r2MH7CEGN5cA QfaXZ2gKIVkxnrOEkYVS/UqjD38ZLtqA3Q+PQvpq8bVFJ1vscH96/WcCrGWbqCqa/7Tn jBvBpBwyEkHq0d359+OkizlLxNyC7jwzExGUFJybpSTL7W7IqOLVjUVR7qWAc8ymIrpV 3XQ3DLALDLcOe/Ur3eutnT361LxmvcZ9FBPpr5aW9ANgmVGuH366E0+koRd4oO2S3Dd4 1LdE0kXEAaUH1WWy/bpHHu3NydXDViEZreq6lCZgMvIbBqoroo9A2aARS7B/D8h/SwQR o03w== X-Gm-Message-State: AODbwcAjO74HnN9zsooHNi6fWI+BLrbQUWiE7zxoPE3qn4tjZBP1de2j 3li6hqMk09um9MknOUEpUvUi63s7SHjc X-Received: by 10.202.4.144 with SMTP id 138mr15320887oie.105.1495643181154; Wed, 24 May 2017 09:26:21 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.202.219.197 with HTTP; Wed, 24 May 2017 09:26:00 -0700 (PDT) In-Reply-To: References: <201705230929.v4N9T5g1028124@repo.freebsd.org> From: Ed Maste Date: Wed, 24 May 2017 12:26:00 -0400 X-Google-Sender-Auth: wfOZ8K6n1f_5E8UVVZbotk7xUlE Message-ID: Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... To: Pedro Giffuni Cc: Konstantin Belousov , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 16:26:22 -0000 On 24 May 2017 at 10:53, Pedro Giffuni wrote: > > There is now a bunch of coverity issues (OVERFLOW_BEFORE_WIDEN mostly) > tied to ino64_t. At least the following CIDs are related: On a quick look the OVERFLOW_BEFORE_WIDEN issues are false positives in practice: for correct operation the product must fit within 32 bits, because inodes were previously 32 bits. However, it does seem unusual to perform a multiplication with types that could overflow 32 bits, and then store the result in a 64-bit variable. So it seems that a code change to eliminate the warning is likely reasonable. From owner-svn-src-head@freebsd.org Wed May 24 16:30:39 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C06A1D7C9A8; Wed, 24 May 2017 16:30:39 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8CF48166D; Wed, 24 May 2017 16:30:39 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OGUcLs003067; Wed, 24 May 2017 16:30:38 GMT (envelope-from asomers@FreeBSD.org) Received: (from asomers@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OGUcrS003066; Wed, 24 May 2017 16:30:38 GMT (envelope-from asomers@FreeBSD.org) Message-Id: <201705241630.v4OGUcrS003066@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: asomers set sender to asomers@FreeBSD.org using -f From: Alan Somers Date: Wed, 24 May 2017 16:30:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318790 - head/usr.sbin/bootparamd/bootparamd 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.23 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, 24 May 2017 16:30:39 -0000 Author: asomers Date: Wed May 24 16:30:38 2017 New Revision: 318790 URL: https://svnweb.freebsd.org/changeset/base/318790 Log: Fix a buffer overflow in bootparamd(8) If /etc/bootparams contains a line with an excessively long pathname, and a client asks for that path, then bootparamd will overflow a buffer and crash while parsing that line. This is not remotely exploitable since it requires a malformed /etc/bootparams file. Reported by: Coverity CID: 1305954 MFC after: 1 week Sponsored by: Spectra Logic Corp Modified: head/usr.sbin/bootparamd/bootparamd/bootparamd.c Modified: head/usr.sbin/bootparamd/bootparamd/bootparamd.c ============================================================================== --- head/usr.sbin/bootparamd/bootparamd/bootparamd.c Wed May 24 14:36:51 2017 (r318789) +++ head/usr.sbin/bootparamd/bootparamd/bootparamd.c Wed May 24 16:30:38 2017 (r318790) @@ -199,7 +199,10 @@ int blen; int ch, pch, fid_len, res = 0; int match = 0; - char info[MAX_FILEID + MAX_PATH_LEN+MAX_MACHINE_NAME + 3]; +#define INFOLEN 1343 + _Static_assert(INFOLEN >= MAX_FILEID + MAX_PATH_LEN+MAX_MACHINE_NAME + 3, + "INFOLEN isn't large enough"); + char info[INFOLEN + 1]; bpf = fopen(bootpfile, "r"); if ( ! bpf ) @@ -251,8 +254,9 @@ int blen; info of the file */ if (match) { - fid_len = strlen(fileid); - while ( ! res && (fscanf(bpf,"%s", info)) > 0) { /* read a string */ +#define AS_FORMAT(d) "%" #d "s" +#define REXPAND(d) AS_FORMAT(d) /* Force another preprocessor expansion */ + while ( ! res && (fscanf(bpf, REXPAND(INFOLEN), info)) > 0) { ch = getc(bpf); /* and a character */ if ( *info != '#' ) { /* Comment ? */ if (! strncmp(info, fileid, fid_len) && *(info + fid_len) == '=') { From owner-svn-src-head@freebsd.org Wed May 24 17:11:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 20ECBD7CB56; Wed, 24 May 2017 17:11:12 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E0FBA1445; Wed, 24 May 2017 17:11:11 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OHBArD019795; Wed, 24 May 2017 17:11:10 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OHBAJI019794; Wed, 24 May 2017 17:11:10 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705241711.v4OHBAJI019794@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 24 May 2017 17:11:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318792 - 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.23 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, 24 May 2017 17:11:12 -0000 Author: emaste Date: Wed May 24 17:11:10 2017 New Revision: 318792 URL: https://svnweb.freebsd.org/changeset/base/318792 Log: UPDATING: clarify ino64 upgrade instructions even further - mention COMPAT_FREEBSD11 earlier so that the steps are in chronological order - suggest removing /usr/obj before build to ensure there are no stale objects Reviewed by: allanjude, kib Sponsored by: The FreeBSD Foundation Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Wed May 24 16:39:19 2017 (r318791) +++ head/UPDATING Wed May 24 17:11:10 2017 (r318792) @@ -53,12 +53,19 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 20170523: The "ino64" 64-bit inode project has been committed, which extends - a number of types to 64 bits. In order to upgrade, carefully follow - the full procedure documented below under the heading "To rebuild - everything and install it on the current system." Specifically, a - reboot is required after installing the new kernel before installing - world. In addition, if using a custom kernel configuration ensure - that the COMPAT_FREEBSD11 option is included. + a number of types to 64 bits. Upgrading in place requires care and + adherence to the documented upgrade procedure. + + If using a custom kernel configuration ensure that the + COMPAT_FREEBSD11 option is included (as during the upgrade the + system will be running the ino64 kernel with the existing world). + + For the safest in-place upgrade begin by removing previous build + artifacts via "rm -rf /usr/obj/*". Then, carefully follow the + full procedure documented below under the heading "To rebuild + everything and install it on the current system." Specifically, + a reboot is required after installing the new kernel before + installing world. 20170424: The NATM framework including the en(4), fatm(4), hatm(4), and From owner-svn-src-head@freebsd.org Wed May 24 17:25:25 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EED3BD7B071; Wed, 24 May 2017 17:25:25 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 566EC1EC1; Wed, 24 May 2017 17:25:24 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([85.179.134.189]) by mail.gmx.com (mrgmx001 [212.227.17.190]) with ESMTPSA (Nemesis) id 0LcSAg-1ddKaz3mX0-00jtEu; Wed, 24 May 2017 19:25:16 +0200 Date: Wed, 24 May 2017 19:25:08 +0200 From: "O. Hartmann" To: Larry Rosenman Cc: Konstantin Belousov , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Ed Maste , "freebsd-current@freebsd.org" Subject: Re: svn commit: r318757 - head Message-ID: <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> In-Reply-To: <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/HXwAKwZWR0EO3RAdCuQhNXc"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:vaO/dICadey8gwzTKquirs3W/4+tH8T7VGEkpbttTKRUGkiM7GQ /ENTjlU+MO0bjLGFNS/6uS4UCPh3snZ0Ok5ECsCYt0f/vlsIHDZbNVNATz4D6h6beVxbpS4 2OIohIGi9LhStb2J08KSfTqpHm3m/+CojaG2YrqLUaap2mi69Yye8EzU6d89n/9GOEqYXwJ DS3Z+Nyd4QUdmKsc0I2NA== X-UI-Out-Filterresults: notjunk:1;V01:K0:r6Ny5eS5iR4=:JbJbRuJdwn1lE2WE9/KPqq yqrxfNUk5Vjzuzh+WAHW+SijErOpPFiNJdBhXfbuHG9FttttazFgFBT81cGia3U/77E6GtpQt WSbWe+5+H9L+PPELmj9M1I2qDtMBgJvrgMnfwxnoHjaE1FdtYjomCpX9n/wQl4ejyZ5zf0RKV DAIElNPqb3NalsZ0XsbicZaPEw4tj/Qfmw3doKOPiKogVTIEddSPA4XKrxjiALzcfTZjzRP8n kLBOpQnihS3N5nnu5fqUBKAHUGyMaH8vdQ5MNM9uzzejGO1ZMsDw1oJpJUt+3HsU/DeofZtJR +kdD5NIjW03pMMa6UpzzqVWztdLZGCK4N163pEdz7VuogZXfKj7DvnmQbQDJ5MoYDSajbLKyP 7omGgI10KLsI9BOfdcZtWu8x+uIk9srazl0SpEKDLchA4AUayit3Qto3JjHRRGx+QBlytL37n qRg56ZRQx02cnqfTpPQL7+coOb9Ip44HlgkglEiDLwGsN+mS2ir9ZE2H0wNKjWYS3ROhlD4pK C6MjTL4YJ7dZTK+gLhBYmU0mMTtFiIpoF24vs0ItRv4nXt6ylLf8KgwD2VoEWgWJkG/m7Ey+X 4Kqa8VnVslxHrZC6OcXhIK3LxZnm6e0JoqCtkF3QFEcvvGLYeH9LwgPQUWOJwY02rFn+OBUzC 9fcafp4tnb+/oFEyMm1Zd/3a22w6Di6ULKYl2ggysf6Yiwh3ZpUf6RYeAIaRZ/GI1dGZ3MAz7 JgCB4DbP0+vIeQNoHxGm6LllMbqPMN+s+hd2aFfMPmte1BTi3VkPVjjxWuU= X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 17:25:26 -0000 --Sig_/HXwAKwZWR0EO3RAdCuQhNXc Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Am Wed, 24 May 2017 08:06:34 -0500 Larry Rosenman schrieb: > The initial failure: > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=3Dperipatus&dt=3D= 2017-05-23%2019%3A17%3A42 >=20 > I then recompiled perl, and got: > borg.lerctr.org /home/pgbuildfarm $ cd /home/pgbuildfarm/bin/latest > && ./run_branches.pl --run-all --config=3D/home/pgbuildfarm/conf/build-fa= rm.conf > Socket.c: loadable library and perl binaries are mismatched (got handshak= e key > 0xd200080, needed 0xdf00080) borg.lerctr.org /home/pgbuildfarm/bin/latest= $ >=20 > force rebuilding and installing perl and all p5-* ports fixed that.=20 >=20 >=20 >=20 I ran into a similar problem, several ports do not build due to a mysteriou= s error from perl: ListUtil.c: loadable library and perl binaries are mismatched (got handshak= e key 0xd200080, needed 0xdf00080) lang/perl5.24 can be rebuild, but almost every p5* port bails out with that= error shown above. Rebuilding p5-* ports is impossible. Running FreeBSD 12.0-CURRENT #3 r318789: Wed May 24 18:03:48 CEST 2017 am= d64 with WITH_LLD_IS_LD=3Dyes. --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/HXwAKwZWR0EO3RAdCuQhNXc Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSXB9AAKCRDS528fyFhY lMx2Af9VMWu9nqGEnQl3VYZZKUN9LeOATJmhHclqxFZLzYyiEFV2pu/hWuQdhQV/ 8miyNDVZnn4oAfZcFUj/N+uhcUr1Af973dwdunpkN7WF8yP3UzdEbuD7ChwYKFbL BPR/LHqcPBTbWkCiJRvIqRv2+tnEeS1IdU/gnRqFAKtQ5/ZWiMML =Sqdw -----END PGP SIGNATURE----- --Sig_/HXwAKwZWR0EO3RAdCuQhNXc-- From owner-svn-src-head@freebsd.org Wed May 24 17:29:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 21849D7B2B3; Wed, 24 May 2017 17:29:23 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F2EF312F3; Wed, 24 May 2017 17:29:22 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:CC:To:From:Subject:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=WmIzXrPZlmr1PxWZLAuHaC5xZHKY/Erz5vbMJZjpqNQ=; b=IKQ65r7IGbGe/Ue00aLW4Iri4V GU6Z2OKLJEDyWlpXTFkDu9bzIWhosH4NSJId1C6sr/AXTzWeZQvUfWXaFEHsqOYjsDdIUX71GaWl8 o3TWPHZkAUrn3PGaOq3AP3XRe+Eab4djpxNjyGUdDn5qgVsA3FwK+j3/a1JPZxxUguxU=; Received: from [74.203.163.58] (port=43042 helo=[10.106.10.44]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDa65-000KQM-Q8; Wed, 24 May 2017 12:29:21 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Wed, 24 May 2017 12:28:51 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: "O. Hartmann" CC: Konstantin Belousov , , , , Ed Maste , "freebsd-current@freebsd.org" Message-ID: <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 17:29:23 -0000 I fixed my issues by force-rebuilding perl and all installed p5-* ports. -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 From owner-svn-src-head@freebsd.org Wed May 24 17:40:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A5B0DD7B76D; Wed, 24 May 2017 17:40:58 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 06F1C1BB1; Wed, 24 May 2017 17:40:57 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([85.179.134.189]) by mail.gmx.com (mrgmx002 [212.227.17.190]) with ESMTPSA (Nemesis) id 0LwqwS-1e22CU13Oa-016Q1F; Wed, 24 May 2017 19:40:54 +0200 Date: Wed, 24 May 2017 19:40:46 +0200 From: "O. Hartmann" To: Larry Rosenman Cc: "O. Hartmann" , src-committers@freebsd.org, Ed Maste , svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" , Konstantin Belousov Subject: Re: svn commit: r318757 - head Message-ID: <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> In-Reply-To: <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/Qxe0A1Q9LNeFnxwAIt0cOiU"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:LpeonhpISUQspAfXIHlfexPohc5YklM+MqWwSWfi9UgAlDVlqu9 0k8SaxsfpzICbERemxetQ7kfQRQIDuqtHOspYDj/WpbfUA8+kMJZvGxIQzSlkiZdjS5nSCy QJGUxxFjA11ZnqOBGxDjxP2/NvK+p5FdM54yv/TwSdA4wz4eqagM7ao0qYDm/4jMTg6jrXH cb92ce8ixujrOHycY/nDA== X-UI-Out-Filterresults: notjunk:1;V01:K0:Cjzrh2VDmkE=:ZZw8U4TyRjTEKKJS/hj3ir 5VV+3p+/dNJU7bpm5xZnTIPRCGIWcUL5ge/bNcA08KTbw0Cdkfjy708Omj1Y9oDL9Znogi6yi PwIjb1SWbPvaPg1fCaFEBeMiToD5kNwc+DjgndurxQt0BlXtBvpf9vzT9nm5tSctO9SpfZoBL CqcIfW6sOJSKf2VdiYmXqPEe9pdO8Ire5FZSKXC6LhnEfsV3j6bKfwdj+X+j/oZ9jQAew933C dalXgzrD2QRmg31hxY/6cbgmKzGDjScyh8BtQsOt2EwIhFJiTpJGhkDuuVX6itcXDmgLo9aH0 BCi9I/QxxJog+7j1wXY2e6IU9Nm9CNSG0j3I6wM9MKd/sKrarbUD3tj9JGDGu4E2CtGQGcCLw SO93b/9IeuzgDmtVgmLoaqrwprrSMAv+n5kmcvy7bqSaWhmr/+dFi7ZsbpxtSYiLy2no8QIzB /N246rxYwoB8yu4utACaIoxaQiKdLtwbfLxKvY/b7fi4J/frygPRVODZ5HtNtZ0S0Q0I+fA3f 6Jzf8tS7K0A+VJ1HXzHIMiDI/Eq8Ekh0CmoA8a6FOCSAskwiz+TZvasq7NdPcf0ASjR02VRGR ewaJJ3AGhGWU0Efg2MW3/W4BOkGo1tOwAxxZMkYVmYEhbkeXxVRv4frkWb7i8iJzuLEIdVJko ISe2G9RyNjLmnJnBuKlStI+fH4aZYDIoQWYxMDj5Lt0kxNgh2w4AmJecMjwtmU+GPCCwwTLta HITjvp3qCbI+FFqVKzgfHK974B+Gk2zyHJgi6c8xZUrDVqIEz7BuZnnYGJ8= X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 17:40:58 -0000 --Sig_/Qxe0A1Q9LNeFnxwAIt0cOiU Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Am Wed, 24 May 2017 12:28:51 -0500 Larry Rosenman schrieb: > I fixed my issues by force-rebuilding perl and all installed p5-* ports.= =20 >=20 >=20 This isn't possible in my case :-( lang/perl rebuilds all right, but every p5-* ports fails with [...] Checking if your kit is complete... ListUtil.c: loadable library and perl binaries are mismatched (got handshak= e key 0xd200080, needed 0xdf00080)=20 *** Error code 1 I tried to rebuild also via portmaster -f, no success. Now, I growing bunch= of ports showing up with this mysterious error. To which port "ListUtil.c" might belong to? Rebuilding autotools (which I suspected first) also fails ... --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/Qxe0A1Q9LNeFnxwAIt0cOiU Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSXFngAKCRDS528fyFhY lJmqAgCHPd10F/shbWNTVqrmb2CyQAnICW3L5yKCpvCgsl7kLKMIPAR6Vfx6Z9Lr IpMmxMvNfJMA6vP9MZRrnYcfmoCCAf0fv4q9TaqCwqzRNdtusW98T0nlkimG7aeW uYdz8WWEeXaj8ongo9Qou19Va3Ldep69uJR4TZhqyfRm1Eym69kp =4DGd -----END PGP SIGNATURE----- --Sig_/Qxe0A1Q9LNeFnxwAIt0cOiU-- From owner-svn-src-head@freebsd.org Wed May 24 17:42:38 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9A321D7BA60; Wed, 24 May 2017 17:42:38 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7675910AB; Wed, 24 May 2017 17:42:38 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:CC:To:From:Subject:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=6rJJmRfysSYWxe2An696FD5pXmvVQShE5XvOJrljbqE=; b=IJZUMh8B+pNIg0FlbuAP7Xph5+ KvK3LgwYamhWZeHmlcGuejsj5B7OdMyr/I/xZV3KrO2wtiev+bhwo21xmbhvwd5Mis9JhrnbClg/V MENQ1D0lrv2cp64iqpzelNwme/n7IAsMNyEkFmRVXfhaUM2vHTn709Mpds1Tez79mgn4=; Received: from [74.203.163.58] (port=32002 helo=[10.106.10.44]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDaIv-000Kqv-SI; Wed, 24 May 2017 12:42:37 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Wed, 24 May 2017 12:42:07 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: "O. Hartmann" CC: , Ed Maste , , , "freebsd-current@freebsd.org" , Konstantin Belousov Message-ID: Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 17:42:38 -0000 -- Larry Rosenman http://www.lerctr.org/~ler Phone: +1 214-642-9640 E-Mail: ler@lerctr.org US Mail: 17716 Limpia Crk, Round Rock, TX 78664-7281 On 5/24/17, 12:40 PM, "O. Hartmann" wrote: Am Wed, 24 May 2017 12:28:51 -0500 Larry Rosenman schrieb: > I fixed my issues by force-rebuilding perl and all installed p5-* ports. > > This isn't possible in my case :-( lang/perl rebuilds all right, but every p5-* ports fails with [...] Checking if your kit is complete... ListUtil.c: loadable library and perl binaries are mismatched (got handshake key 0xd200080, needed 0xdf00080) *** Error code 1 I tried to rebuild also via portmaster -f, no success. Now, I growing bunch of ports showing up with this mysterious error. To which port "ListUtil.c" might belong to? Rebuilding autotools (which I suspected first) also fails ... I rebuilt all in Poudriere and it was fine. From owner-svn-src-head@freebsd.org Wed May 24 17:47:17 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7B073D7BC84; Wed, 24 May 2017 17:47:17 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 562CF1451; Wed, 24 May 2017 17:47:17 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OHlGv3035801; Wed, 24 May 2017 17:47:16 GMT (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OHlG5C035799; Wed, 24 May 2017 17:47:16 GMT (envelope-from glebius@FreeBSD.org) Message-Id: <201705241747.v4OHlG5C035799@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: glebius set sender to glebius@FreeBSD.org using -f From: Gleb Smirnoff Date: Wed, 24 May 2017 17:47:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318793 - 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.23 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, 24 May 2017 17:47:17 -0000 Author: glebius Date: Wed May 24 17:47:16 2017 New Revision: 318793 URL: https://svnweb.freebsd.org/changeset/base/318793 Log: o Rearrange struct inpcb fields to optimize the TCP output code path considering cache line hits and misses. Put the lock and hash list glue into the first cache line, put inp_refcount inp_flags inp_socket into the second cache line. o On allocation zero out entire structure except the lock and list entries, including inp_route inp_lle inp_gencnt. When inp_route and inp_lle were introduced, they were added below inp_zero_size, resulting on not being cleared after free/alloc. This definitely was a source of bugs with route caching. Could be that r315956 has just fixed one of them. The inp_gencnt is reinitialized on every alloc, so it is safe to clear it. This has been proved to improve TCP performance at Netflix. Obtained from: rrs Differential Revision: D10686 Modified: head/sys/netinet/in_pcb.c head/sys/netinet/in_pcb.h Modified: head/sys/netinet/in_pcb.c ============================================================================== --- head/sys/netinet/in_pcb.c Wed May 24 17:11:10 2017 (r318792) +++ head/sys/netinet/in_pcb.c Wed May 24 17:47:16 2017 (r318793) @@ -300,7 +300,7 @@ in_pcballoc(struct socket *so, struct in inp = uma_zalloc(pcbinfo->ipi_zone, M_NOWAIT); if (inp == NULL) return (ENOBUFS); - bzero(inp, inp_zero_size); + bzero(&inp->inp_start_zero, inp_zero_size); inp->inp_pcbinfo = pcbinfo; inp->inp_socket = so; inp->inp_cred = crhold(so->so_cred); Modified: head/sys/netinet/in_pcb.h ============================================================================== --- head/sys/netinet/in_pcb.h Wed May 24 17:11:10 2017 (r318792) +++ head/sys/netinet/in_pcb.h Wed May 24 17:47:16 2017 (r318793) @@ -183,26 +183,29 @@ struct icmp6_filter; struct inpcbpolicy; struct m_snd_tag; struct inpcb { + /* Cache line #1 (amd64) */ LIST_ENTRY(inpcb) inp_hash; /* (h/i) hash list */ LIST_ENTRY(inpcb) inp_pcbgrouphash; /* (g/i) hash list */ - LIST_ENTRY(inpcb) inp_list; /* (p/l) list for all PCBs for proto */ - /* (p[w]) for list iteration */ - /* (p[r]/l) for addition/removal */ + struct rwlock inp_lock; + /* Cache line #2 (amd64) */ +#define inp_start_zero inp_refcount +#define inp_zero_size (sizeof(struct inpcb) - \ + offsetof(struct inpcb, inp_start_zero)) + u_int inp_refcount; /* (i) refcount */ + int inp_flags; /* (i) generic IP/datagram flags */ + int inp_flags2; /* (i) generic IP/datagram flags #2*/ void *inp_ppcb; /* (i) pointer to per-protocol pcb */ + struct socket *inp_socket; /* (i) back pointer to socket */ struct inpcbinfo *inp_pcbinfo; /* (c) PCB list info */ struct inpcbgroup *inp_pcbgroup; /* (g/i) PCB group list */ LIST_ENTRY(inpcb) inp_pcbgroup_wild; /* (g/i/h) group wildcard entry */ - struct socket *inp_socket; /* (i) back pointer to socket */ struct ucred *inp_cred; /* (c) cache of socket cred */ u_int32_t inp_flow; /* (i) IPv6 flow information */ - int inp_flags; /* (i) generic IP/datagram flags */ - int inp_flags2; /* (i) generic IP/datagram flags #2*/ u_char inp_vflag; /* (i) IP version flag (v4/v6) */ u_char inp_ip_ttl; /* (i) time to live proto */ u_char inp_ip_p; /* (c) protocol proto */ u_char inp_ip_minttl; /* (i) minimum TTL or drop */ uint32_t inp_flowid; /* (x) flow id / queue id */ - u_int inp_refcount; /* (i) refcount */ struct m_snd_tag *inp_snd_tag; /* (i) send tag for outgoing mbufs */ uint32_t inp_flowtype; /* (x) M_HASHTYPE value */ uint32_t inp_rss_listen_bucket; /* (x) overridden RSS listen bucket */ @@ -235,17 +238,16 @@ struct inpcb { }; LIST_ENTRY(inpcb) inp_portlist; /* (i/h) */ struct inpcbport *inp_phd; /* (i/h) head of this list */ -#define inp_zero_size offsetof(struct inpcb, inp_gencnt) inp_gen_t inp_gencnt; /* (c) generation count */ struct llentry *inp_lle; /* cached L2 information */ - struct rwlock inp_lock; rt_gen_t inp_rt_cookie; /* generation for route entry */ union { /* cached L3 information */ - struct route inpu_route; - struct route_in6 inpu_route6; - } inp_rtu; -#define inp_route inp_rtu.inpu_route -#define inp_route6 inp_rtu.inpu_route6 + struct route inp_route; + struct route_in6 inp_route6; + }; + LIST_ENTRY(inpcb) inp_list; /* (p/l) list for all PCBs for proto */ + /* (p[w]) for list iteration */ + /* (p[r]/l) for addition/removal */ }; #endif /* _KERNEL */ From owner-svn-src-head@freebsd.org Wed May 24 17:47:51 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0237AD7BCF4; Wed, 24 May 2017 17:47:51 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AE0D21638; Wed, 24 May 2017 17:47:50 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OHlnmW035862; Wed, 24 May 2017 17:47:49 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OHlniS035859; Wed, 24 May 2017 17:47:49 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705241747.v4OHlniS035859@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Wed, 24 May 2017 17:47:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318794 - in head: sbin/zfsbootcfg share/man/man9 usr.sbin/efidp 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.23 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, 24 May 2017 17:47:51 -0000 Author: gjb Date: Wed May 24 17:47:49 2017 New Revision: 318794 URL: https://svnweb.freebsd.org/changeset/base/318794 Log: Update the "first appeared in" version in several manual pages. MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/sbin/zfsbootcfg/zfsbootcfg.8 head/share/man/man9/mutex.9 head/usr.sbin/efidp/efidp.8 Modified: head/sbin/zfsbootcfg/zfsbootcfg.8 ============================================================================== --- head/sbin/zfsbootcfg/zfsbootcfg.8 Wed May 24 17:47:16 2017 (r318793) +++ head/sbin/zfsbootcfg/zfsbootcfg.8 Wed May 24 17:47:49 2017 (r318794) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 12, 2016 +.Dd May 24, 2017 .Dt ZFSBOOTCFG 8 .Os .Sh NAME @@ -86,7 +86,7 @@ To clear the boot options: .Sh HISTORY .Nm appeared in -.Fx 12.0 . +.Fx 11.1 . .Sh AUTHORS This manual page was written by .An Andriy Gapon Aq Mt avg@FreeBSD.org . Modified: head/share/man/man9/mutex.9 ============================================================================== --- head/share/man/man9/mutex.9 Wed May 24 17:47:16 2017 (r318793) +++ head/share/man/man9/mutex.9 Wed May 24 17:47:49 2017 (r318794) @@ -28,7 +28,7 @@ .\" from BSDI $Id: mutex.4,v 1.1.2.3 1998/04/27 22:53:13 ewv Exp $ .\" $FreeBSD$ .\" -.Dd July 18, 2016 +.Dd May 24, 2017 .Dt MUTEX 9 .Os .Sh NAME @@ -557,4 +557,4 @@ and The .Fn mtx_trylock_spin function was added in -.Fx 12.0 . +.Fx 11.1 . Modified: head/usr.sbin/efidp/efidp.8 ============================================================================== --- head/usr.sbin/efidp/efidp.8 Wed May 24 17:47:16 2017 (r318793) +++ head/usr.sbin/efidp/efidp.8 Wed May 24 17:47:49 2017 (r318794) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd March 5, 2017 +.Dd May 24, 2017 .Dt EFIDP 8 .Os .Sh NAME @@ -50,4 +50,4 @@ have the format described in RFC 4122. The .Nm utility first appeared in -.Fx 12.0 . +.Fx 11.1 . From owner-svn-src-head@freebsd.org Wed May 24 17:50:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 29F82D7BDBA; Wed, 24 May 2017 17:50:36 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EDD0E17E5; Wed, 24 May 2017 17:50:35 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OHoY2p036024; Wed, 24 May 2017 17:50:34 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OHoYaI036022; Wed, 24 May 2017 17:50:34 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705241750.v4OHoYaI036022@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Wed, 24 May 2017 17:50:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318795 - in head/lib/libc: gen 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.23 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, 24 May 2017 17:50:36 -0000 Author: gjb Date: Wed May 24 17:50:34 2017 New Revision: 318795 URL: https://svnweb.freebsd.org/changeset/base/318795 Log: Update the "first appeared in" version in several manual pages. MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/lib/libc/gen/sem_timedwait.3 head/lib/libc/sys/fsync.2 Modified: head/lib/libc/gen/sem_timedwait.3 ============================================================================== --- head/lib/libc/gen/sem_timedwait.3 Wed May 24 17:47:49 2017 (r318794) +++ head/lib/libc/gen/sem_timedwait.3 Wed May 24 17:50:34 2017 (r318795) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 28, 2017 +.Dd May 24, 2017 .Dt SEM_TIMEDWAIT 3 .Os .Sh NAME @@ -160,4 +160,4 @@ function first appeared in The .Fn sem_clockwait_np function first appeared in -.Fx 12.0 . +.Fx 11.1 . Modified: head/lib/libc/sys/fsync.2 ============================================================================== --- head/lib/libc/sys/fsync.2 Wed May 24 17:47:49 2017 (r318794) +++ head/lib/libc/sys/fsync.2 Wed May 24 17:50:34 2017 (r318795) @@ -34,7 +34,7 @@ .\" @(#)fsync.2 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd August 17, 2016 +.Dd May 24, 2017 .Dt FSYNC 2 .Os .Sh NAME @@ -119,7 +119,7 @@ system call appeared in The .Fn fdatasync system call appeared in -.Fx 12.0 +.Fx 11.1 . .Sh BUGS The .Fn fdatasync From owner-svn-src-head@freebsd.org Wed May 24 18:01:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6CDCFD7C258; Wed, 24 May 2017 18:01:53 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.17.21]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D6786109D; Wed, 24 May 2017 18:01:52 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([85.179.134.189]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MMTZa-1dJeLh2d6U-008HMS; Wed, 24 May 2017 20:01:43 +0200 Date: Wed, 24 May 2017 20:01:36 +0200 From: "O. Hartmann" To: "O. Hartmann" Cc: Larry Rosenman , src-committers@freebsd.org, Ed Maste , svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" , Konstantin Belousov Subject: Re: svn commit: r318757 - head Message-ID: <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/3nYXUifKigH5b4auBUi23i3"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:IY+ZH8oRj94cOpVNOEyN5vTYA//EBVYy7pjbBrIcDbxFkNCx4UN JuliUdPDlko9UXrBGcyghL68MHY0+5Fl8ov6nv3/XS+xbytjFO140gCm++7KKv2K1Fcf3Bq 7La8caticZYMMn/Bu32HBmGzD7HmYZqg3SkhPKNS9ToKFtSRm1VBJTAn3Eb+KAiAvXxnAkl vN9XDOZ12nnBZenzVWF6g== X-UI-Out-Filterresults: notjunk:1;V01:K0:+AFGLqgNgQc=:WWuqxPCtLURBp3iQY5HqVD UCFS98AG9V/zuLMjzbekQ986nycI/JfnNincDeFQ5pkMV2AvpqPSnxmjigaZWY2DbbSr+0hcR sb9jKrAiWuRtbxyEKGOwUNCK+Yy3h+C+Ggenm53KnaNtfxeUVMIk9WqsEKxCU18F6Cpz1H4Q8 8i0M/RRJbXIeDtIc8nnqMylHxoUQgG0kiDM7qDx+GcWg/B2FN0uApJXRqk5XbiYauJT8HD0tN nklhLL9e2ee8LcwztJ21KfJHcp3SP77XArNsphFsOC+DjFMQRN59LOgHIhPgI2Ux5UI8ckqk+ +/q56meBxODXExPpj6kg39H+p7y5gWMrUUqrlc1/QLLxzkqP80iqve/npBJ/nXd5LaSvgIQ5K YInmrkRHp/N3aeE2dsOC+OL1rBLO1rKzRDudjpS5SDZt8Vokmj9VDI7QMQfaBay6doihU9qyW LPfHUa3Pv/yJu6xc15bCJxASSgS7jSlPbSHabLFUgT3eOPdz+1VTHB2GF8rKrgA1kYJd7Cwix C4bJnHAZqDYrusqSFHP//531EDsLF+3gb4cMNV1lGzKOTtB2MkwSWQk6LlPf621rvcAhIVrKq LNYcHFWQaaS2r/hLpHZKqii2dcJL9f226ktGmDtmiCySjSxgl5ix27ow5pgGUtzvL2VlBCiG+ y0S0F0jvob6Ea4gYTwg3ZE2xJjJSutwQNZSITn5ErDzlyw+4XWhys7zQkXhg/o22mdZtUk23i VZvr7fcALJjtr1pYcu4vg/snOACStGjkhl5ZvwjntVvhsa+dQsV6gkS5Iik= X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 18:01:53 -0000 --Sig_/3nYXUifKigH5b4auBUi23i3 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Am Wed, 24 May 2017 19:40:46 +0200 "O. Hartmann" schrieb: > Am Wed, 24 May 2017 12:28:51 -0500 > Larry Rosenman schrieb: >=20 > > I fixed my issues by force-rebuilding perl and all installed p5-* ports= .=20 > >=20 > > =20 >=20 >=20 > This isn't possible in my case :-( >=20 > lang/perl rebuilds all right, but every p5-* ports fails with >=20 > [...] > Checking if your kit is complete... > ListUtil.c: loadable library and perl binaries are mismatched (got handsh= ake key > 0xd200080, needed 0xdf00080)=20 > *** Error code 1 >=20 > I tried to rebuild also via portmaster -f, no success. Now, I growing bun= ch of ports > showing up with this mysterious error. >=20 > To which port "ListUtil.c" might belong to? >=20 > Rebuilding autotools (which I suspected first) also fails ... >=20 >=20 ... it seems, as K. belousov mentioned prior regarding different ABI, all p= 5-* ports need to be deleted by force ... They rebuild properly afterwards. --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/3nYXUifKigH5b4auBUi23i3 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSXKgAAKCRDS528fyFhY lI3oAf9+f0tRnl/GBTmvOa6J9+KZnN7WYFi9X2PbDkrr0R0NYHeJC4avdlf2k8+g 1V2XvIui7Qc0JbounWtAp/03p/qxAf9b4Nob1oei5rCZ+vApXzGPIFUwpjg0EKad GxRrEKkE30I6ngAusHG1ZLG4GdC46BvjZMvZYNo+lmI3gy9FdP89 =sLnN -----END PGP SIGNATURE----- --Sig_/3nYXUifKigH5b4auBUi23i3-- From owner-svn-src-head@freebsd.org Wed May 24 18:05:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7D79DD7C38F; Wed, 24 May 2017 18:05:01 +0000 (UTC) (envelope-from ler@lerctr.org) Received: from thebighonker.lerctr.org (thebighonker.lerctr.org [IPv6:2001:470:1f0f:3ad:223:7dff:fe9e:6e8a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "thebighonker.lerctr.org", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 58F3D1591; Wed, 24 May 2017 18:05:01 +0000 (UTC) (envelope-from ler@lerctr.org) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lerctr.org; s=lerami; h=Content-transfer-encoding:Content-type:Mime-version:In-Reply-To: References:Message-ID:CC:To:From:Subject:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=cWy4zL+BQlSKdAJqSu7mN73OyYO/PaISTgJu7Vh1HrA=; b=hl1n6z74rdVydeuo2YLKeWf6dw t7XddrmI+ElbKi1RKeehHlyk676xAA5SZDBf4JvdicSywzBRLMDA9cjwtx3OLTCuTJc+3KwRCSB2d cMRmgHOq+xIDWWYNmg4ypg3Gf1IJV0cNPFs/5I/JVyLzntPmK7F+r4JfQEeoytILk1Eo=; Received: from [74.203.163.58] (port=33186 helo=[10.106.10.44]) by thebighonker.lerctr.org with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89 (FreeBSD)) (envelope-from ) id 1dDaea-000LkG-Gl; Wed, 24 May 2017 13:05:00 -0500 User-Agent: Microsoft-MacOutlook/f.23.0.170517 Date: Wed, 24 May 2017 13:04:30 -0500 Subject: Re: svn commit: r318757 - head From: Larry Rosenman To: "O. Hartmann" CC: , Ed Maste , , , "freebsd-current@freebsd.org" , Konstantin Belousov Message-ID: <26FCC584-3B24-4F70-9374-C432775844F6@lerctr.org> Thread-Topic: svn commit: r318757 - head References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> In-Reply-To: <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> Mime-version: 1.0 Content-type: text/plain; charset="UTF-8" Content-transfer-encoding: quoted-printable X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 18:05:01 -0000 On 5/24/17, 1:01 PM, "O. Hartmann" wrote: Am Wed, 24 May 2017 19:40:46 +0200 "O. Hartmann" schrieb: =20 > Am Wed, 24 May 2017 12:28:51 -0500 > Larry Rosenman schrieb: >=20 > > I fixed my issues by force-rebuilding perl and all installed p5-* p= orts.=20 > >=20 > > =20 >=20 >=20 > This isn't possible in my case :-( >=20 > lang/perl rebuilds all right, but every p5-* ports fails with >=20 > [...] > Checking if your kit is complete... > ListUtil.c: loadable library and perl binaries are mismatched (got ha= ndshake key > 0xd200080, needed 0xdf00080)=20 > *** Error code 1 >=20 > I tried to rebuild also via portmaster -f, no success. Now, I growing= bunch of ports > showing up with this mysterious error. >=20 > To which port "ListUtil.c" might belong to? >=20 > Rebuilding autotools (which I suspected first) also fails ... >=20 >=20 =20 ... it seems, as K. belousov mentioned prior regarding different ABI, a= ll p5-* ports need to be deleted by force ... They rebuild properly afterwards. =20 Which is essentially what I did re: Poudriere (poudriere bulk =E2=80=93C =E2=80=93j -p -f ) =20 From owner-svn-src-head@freebsd.org Wed May 24 18:10:11 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 74E70D7C511; Wed, 24 May 2017 18:10:11 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id ECB4218DC; Wed, 24 May 2017 18:10:10 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([85.179.134.189]) by mail.gmx.com (mrgmx003 [212.227.17.190]) with ESMTPSA (Nemesis) id 0Lmqxo-1ds9jx2NDg-00h4SH; Wed, 24 May 2017 20:10:01 +0200 Date: Wed, 24 May 2017 20:10:00 +0200 From: "O. Hartmann" To: Larry Rosenman Cc: "O. Hartmann" , , Ed Maste , , , "freebsd-current@freebsd.org" , Konstantin Belousov Subject: Re: svn commit: r318757 - head Message-ID: <20170524201000.5bfc736f@thor.intern.walstatt.dynvpn.de> In-Reply-To: <26FCC584-3B24-4F70-9374-C432775844F6@lerctr.org> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> <26FCC584-3B24-4F70-9374-C432775844F6@lerctr.org> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/B2ftN4AfDQgPu8dljSySCvm"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:w64jR4dxgcE4dVI5al09fmSLtNxxMiua4kc8mP5pFhjKkwiPelS aHaGuzb3etdVH6RdbmAAb9b9o4zRbisp0mTC4Rb3V37LgsF+i5LmqPKNji7aigZiPiprwrJ 1ki6pyy5q5m6YDCegLepK0btDsByILHirxs1AzlVgf65or+2AYfLbmno28/gTL1zNUYVozz HSKUXkmFlcj+CiAMRDyOw== X-UI-Out-Filterresults: notjunk:1;V01:K0:Ns4mbM6nHZY=:cPT0ND3xLjRYb78yz85rFi ZlrdN/LGMIqAieMW3UL4aKZdOy4X01YpRC8scjpjJ/29NuT2laDvCPNSBwrcrwoGukcrNSaQb M8Tf/EW85yM4zyP1NdxOmBhhVG0xFV0PX7KmzRzGsKgAEY//BBTv7nrJad7djQ5iXkLwsE3M8 GxJoVFqs4XjIWU132CMm7ND3Gfg3gcaFW8Ig+obfxS0P/w9ZKTHklLkc5GfjzptX0sUBoQEjF n2jmuZbMltV+8FqfEoVoY4Cnh2PZ2U8WWZg5ZpTSMY4ErybkrbwM4ZRcLsl7Pkh3mH9cPCn9L +etq7UviMOWJYqebbG7anVgdQAc7GLiKfvjaCwgd1jVYoba6yTPU6hweuyU4NViWGycJmpfmy JFkLnnMWRaJjpy0ysrxiea9qveqZMXluuqq9SGCZG0Ta7u3gmEf1+P9WnKOjFibOUzxQTrKb8 0c0UCAeyQ6SbLXLs+5RID4BfCQij0likiCGkjCrfhiSugTmjuDGbPHGgwYK+YWRHbuGA18r98 tSsX2sqPMmPq1VCPXF9zFWxSMKvOctzxnc9X/Ndy3P4NHwfd/A1ji2aknLmAPzhCzmw/Jl7bS fkJmvPRxC3S8LMXEXvvhu69rpgERTxqVaVfQOSi7xTRsbtOfLVas5vjQYFAM8Q7AQqiNpEjaH MltDpKHzNUiMjAXNNOprHSDPg/QA2S9qjYcoglCX8yhCsPddrqcSWKWhZIvHJKtpOp/UrUQ7v 8vYnIIW8zUJgmo7CCnspkQqwT8S8FlkcNcx2oTmFy0WakiEFvfc7XYdr1K0= X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 18:10:11 -0000 --Sig_/B2ftN4AfDQgPu8dljSySCvm Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Am Wed, 24 May 2017 13:04:30 -0500 Larry Rosenman schrieb: > On 5/24/17, 1:01 PM, "O. Hartmann" wrote: >=20 > Am Wed, 24 May 2017 19:40:46 +0200 > "O. Hartmann" schrieb: > =20 > > Am Wed, 24 May 2017 12:28:51 -0500 > > Larry Rosenman schrieb: > > =20 > > > I fixed my issues by force-rebuilding perl and all installed p5-*= ports.=20 > > >=20 > > > =20 > >=20 > >=20 > > This isn't possible in my case :-( > >=20 > > lang/perl rebuilds all right, but every p5-* ports fails with > >=20 > > [...] > > Checking if your kit is complete... > > ListUtil.c: loadable library and perl binaries are mismatched (got = handshake key > > 0xd200080, needed 0xdf00080)=20 > > *** Error code 1 > >=20 > > I tried to rebuild also via portmaster -f, no success. Now, I growi= ng bunch of > > ports showing up with this mysterious error. > >=20 > > To which port "ListUtil.c" might belong to? > >=20 > > Rebuilding autotools (which I suspected first) also fails ... > >=20 > > =20 > =20 > ... it seems, as K. belousov mentioned prior regarding different ABI,= all p5-* > ports need to be deleted by force ... They rebuild properly afterwards. > =20 > Which is essentially what I did re: Poudriere (poudriere bulk =E2=80=93C = =E2=80=93j -p > -f ) I use the traditional "make" way (via portmaster) --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --Sig_/B2ftN4AfDQgPu8dljSySCvm Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSXMeAAKCRDS528fyFhY lC3FAgCjOsC9Vq+JEj7IXCBiDh2tbLfH8I8pZa3UnYCr81dSYV1Lobqu7HE6+Z1F dpkWPJcpsnnsGJvD5UGANLpuvmaQAf9wQs6KToM7mI97tYWpLRI9+a1zeLHBxtJq Qitq0G+CUJB+QDwpMNllasOTtUIlEIcaytsWiD+uVEbgR3G1VHv+ =IYSB -----END PGP SIGNATURE----- --Sig_/B2ftN4AfDQgPu8dljSySCvm-- From owner-svn-src-head@freebsd.org Wed May 24 18:54:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1EE1FD7C69B; Wed, 24 May 2017 18:54:23 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E36951688; Wed, 24 May 2017 18:54:22 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OIsLKR064343; Wed, 24 May 2017 18:54:21 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OIsLJR064342; Wed, 24 May 2017 18:54:21 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201705241854.v4OIsLJR064342@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 24 May 2017 18:54:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318800 - head/sys/x86/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.23 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, 24 May 2017 18:54:23 -0000 Author: jhb Date: Wed May 24 18:54:21 2017 New Revision: 318800 URL: https://svnweb.freebsd.org/changeset/base/318800 Log: Remove constants and comments for unimplemented entries in the default LDT. These entries will never be added to the default LDT in the future. Modified: head/sys/x86/include/segments.h Modified: head/sys/x86/include/segments.h ============================================================================== --- head/sys/x86/include/segments.h Wed May 24 18:16:20 2017 (r318799) +++ head/sys/x86/include/segments.h Wed May 24 18:54:21 2017 (r318800) @@ -247,11 +247,8 @@ union descriptor { */ #define LSYS5CALLS_SEL 0 /* forced by intel BCS */ #define LSYS5SIGR_SEL 1 -#define L43BSDCALLS_SEL 2 /* notyet */ #define LUCODE_SEL 3 #define LUDATA_SEL 5 -/* separate stack, es,fs,gs sels ? */ -/* #define LPOSIXCALLS_SEL 5*/ /* notyet */ #define NLDT (LUDATA_SEL + 1) #else /* !__i386__ */ From owner-svn-src-head@freebsd.org Wed May 24 19:11:09 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C560DD7C8EC; Wed, 24 May 2017 19:11:09 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x243.google.com (mail-pf0-x243.google.com [IPv6:2607:f8b0:400e:c00::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8CDA91C95; Wed, 24 May 2017 19:11:09 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x243.google.com with SMTP id w69so33970602pfk.1; Wed, 24 May 2017 12:11:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=H+hSoUgbGoYg+gFU1DdaAdLjL/Lz0RM/0qJOJeuAtuw=; b=ujR+w3LuizboSxFePmnqsjnR2NAAqU0Bbzghmpe1+RmTqlvlZAhFZ03WJ/T74n+zvK m7ylpg08VQtQjjfAtb/iJf1n7XEXecOdeVQq3KZKA4+kQwByaW/HtO+uRhKQHNxWaZ2y 5YYv3P2g8CEccmgCR2Qcs6O17p400yjs8JaX+RCnU6cx0DkT1ON3UkgGp9/XkMjdShk+ X+htL1R1rIVhw/7E5ggWelvOM6oCesOZmXL6C6pBp5FjfHBui+D/UKYUJZ2cQWM3X4/T rPbS41p7feEjexYGNx7+7/2kN8nXD0WpN1Joz7JydLgCEBnnz/QuquLVJXb8QRMx6Bhe bFrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=H+hSoUgbGoYg+gFU1DdaAdLjL/Lz0RM/0qJOJeuAtuw=; b=ljjIjEKdtdaYnytfRSjB18d/qdZazl/fj0qzQ7lkcJW5Kj5zwjPzCKy2hThgNLomlh 7D9whzC5mKIbty3yXblWIcRtFsUNelFjZqKJ4lwd86XKDRPxixDTKzoAAYeSovBmBQpd KjHZs5Z6Uns9fO4u30tRCgOd3m3pp9VJLQIulFkVN9bQeBUVERR117ocWEVQOS+G+Hms Ju7dvOpqR+SM1vnmOVqJNDxUxiGR1b/wgSglfjl7vfHQX4zbMejNzZ18mZFxs8QcnREa gCmxytRYlxDnAEfHuWZTINDRh49y82nu+D+G344Rl+Xx9goOkCSXsapqg8uMWSpCdavw rAbQ== X-Gm-Message-State: AODbwcD2bQPpIbbDL5G2k5QTp0A9CswDXaQi1mjBR513eYLyDJhPDZ/y pPSDzhtJMGebOnRrDLk= X-Received: by 10.99.103.70 with SMTP id b67mr41521704pgc.96.1495653069049; Wed, 24 May 2017 12:11:09 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id d2sm9321522pfb.110.2017.05.24.12.11.07 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 24 May 2017 12:11:08 -0700 (PDT) Subject: Re: svn commit: r318757 - head Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_3E3916D7-5B6E-40CD-A65A-0D3DE2D153B6"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <20170524201000.5bfc736f@thor.intern.walstatt.dynvpn.de> Date: Wed, 24 May 2017 12:11:06 -0700 Cc: Larry Rosenman , src-committers , Ed Maste , svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" , Konstantin Belousov Message-Id: References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> <26FCC584-3B24-4F70-9374-C432775844F6@lerctr.org> <20170524201000.5bfc736f@thor.intern.walstatt.dynvpn.de> To: "O. Hartmann" X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 19:11:09 -0000 --Apple-Mail=_3E3916D7-5B6E-40CD-A65A-0D3DE2D153B6 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On May 24, 2017, at 11:10, O. Hartmann wrote: >=20 > Am Wed, 24 May 2017 13:04:30 -0500 > Larry Rosenman schrieb: =E2=80=A6 > I use the traditional "make" way (via portmaster) There were some reports about needing to do =E2=80=9Cmake = clean=E2=80=9D before =E2=80=9Cmake install=E2=80=9D. Memory serves me = correctly there are ways in portmaster to bypass =E2=80=9Cmake clean=E2=80= =9D before running =E2=80=9Cmake install=E2=80=9D. Could you please = provide your portmasterrc file? Thanks, -Ngie --Apple-Mail=_3E3916D7-5B6E-40CD-A65A-0D3DE2D153B6 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJZJdrLAAoJEPWDqSZpMIYVTPAP/1vRh+QCPZhNkfcrr1tEcJPi z3dsNAuJPTyhe16osCwSu4MMCPAGnJRqF9Kt8PI6h0WUvRyP0lIfG4t1tlZKl3L3 sezcrNuRrEoAr1/o94RoyWXdQCX8zizRk2nbEL0sDrM9Nc4mPx7KFWIJgXJZm76C moA+7glJU7kNet96BYtzdwfKeaSPTCAOUkdkb68QH8qh+hfIhNwrBMEdV21zNt7M Hw8k+bZZXqJ/ZX9wSeQsjjwHM6l6W8QGcHRBQqEwsRmLYMC0500ucMIsWt9mV33b UFUZMF9SVQOKmfByzTqeuLx9VWHoGz6GF/+NR4UM0MhYPND+WGuqGhtfqwk+Sand pQ44MeX1MZYNTNIGoKYTlMPZygzi13CZmR44XMuZ84KuZTs4H5H7QGUrVRAvh5Cp Efg4YMoCOiXmsvA83FhFltvxLIcU+hTbgD94AycZ7rYKzmuZG/NYWm+isKbMbXne 8Z8WraZBx5/g81ropHtDJuB3jfHpEw552IsKtRQQEXeVodOJOGUWpAAQIOnl6ILK m4bU7rrKfiCxF6qYKOeQpVHyCd+0H+1uJMal/aujPpEyWiRsnSVQDC/tI019os3z 4cCjJVTkzuJuQ/xdIGw4AWcLOwnR1SIHAQ/KIYtqeZ/nbICiToTJTmpY+mH0Eang qKPXimhBGpgDbq+QPpk0 =bpJB -----END PGP SIGNATURE----- --Apple-Mail=_3E3916D7-5B6E-40CD-A65A-0D3DE2D153B6-- From owner-svn-src-head@freebsd.org Wed May 24 19:42:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3AF99D7C4BF; Wed, 24 May 2017 19:42:53 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A953C121F; Wed, 24 May 2017 19:42:52 +0000 (UTC) (envelope-from ohartmann@walstatt.org) Received: from thor.intern.walstatt.dynvpn.de ([85.179.134.189]) by mail.gmx.com (mrgmx003 [212.227.17.190]) with ESMTPSA (Nemesis) id 0M5cpk-1eApbE35K4-00xdY9; Wed, 24 May 2017 21:42:48 +0200 Date: Wed, 24 May 2017 21:42:40 +0200 From: "O. Hartmann" To: "Ngie Cooper (yaneurabeya)" Cc: "O. Hartmann" , Larry Rosenman , src-committers , Ed Maste , svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" , Konstantin Belousov Subject: Re: svn commit: r318757 - head Message-ID: <20170524214240.56898f49@thor.intern.walstatt.dynvpn.de> In-Reply-To: References: <201705232025.v4NKPnrH001395@repo.freebsd.org> <20170524090552.GF1622@kib.kiev.ua> <8A9597FF-FC4B-4998-87A8-F5ED13303474@lerctr.org> <20170524192415.7bb764a7@thor.intern.walstatt.dynvpn.de> <163D09DC-C0B3-4D49-B0BF-C71C26C2807B@lerctr.org> <20170524194046.1226b05b@thor.intern.walstatt.dynvpn.de> <20170524200136.09ac15b1@thor.intern.walstatt.dynvpn.de> <26FCC584-3B24-4F70-9374-C432775844F6@lerctr.org> <20170524201000.5bfc736f@thor.intern.walstatt.dynvpn.de> Organization: WALSTATT User-Agent: OutScare 3.1415926 X-Operating-System: ImNotAnOperatingSystem 3.141592527 MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_//9UtlAXwddK82MsGGgt9aeP"; protocol="application/pgp-signature" X-Provags-ID: V03:K0:eAZVHU55JnQ1NGPFxZtRZrDg1UgnRU8Gra6kxuGjOjqHvO/8djb 0s069pdsS8vas5E39NqoQDYkpG6g1RZFk1N+ZYIS08KM2KuX7/UVFqK72tGZMvywCtiAxXG 14O5GfBt9IlfCkFy2G/Qn798LAhiDBLCN3EtEdLPeb4lmqcF2McW7rBTtjufPYFrdVJUOSq KOotUCF3WGoZqYi5O1kew== X-UI-Out-Filterresults: notjunk:1;V01:K0:/FputYUvTmc=:dca8V8h3yST9OFy2xZ1aF9 BPQpGz9FxGLTqeZfasmZ9o6AjyXQv5s26zJpcBdB6/n3p/BCHffhDvrHtruTZW6QyPrayppku g3Ednf1L5j9OXEzlKR04suJKHE+iQANnDzUZa+cSIGlvCDa7/kYed1TB7pOzfF2n8o1ZBJtYI H5fzovGam+rfxYNdWl6Fmmko6+jNgQjw5ptd5voTuHYnDdpaPJ570UlN9Fk89aXfAxfVIo6FD IbRrk560k5FO4stOqV1YIp2be5TvG8ypi8UOAO5xTtS/S5ROo2rLNmg8bEhcgsT0y7ztAX/vT t58dRFVHQU/5BDWFqBonzzTprS6CSJCzWye+DJAO6XVGfHv52NAAapnKCD2mCjr3nuTfIDoAj Bj5uwVTAEOlD+POgTuyCedcKRC45Btul9SjyLgGDoalE1ieTo+MzIfNzsMY0B3sznFupvU8K8 lZDJIMUFB811gHSy8CyCUjZbjXGIYAz9j4z7FcBRioGS6r4arFy2Up5ltKIFws+TovSYdPz3k G+FRPADdgWxv9ILI7gCPR+fbqMDzj5HylXi4BX6nYS9VogIZKbmBNEHAaHPynn/he6Hjwi7in EjyLVEfSOMx4KgWcik7KOxTsXd+TrvIgFHK5tBUtonGqfc0wYi9/ZZekOdBcSi64mkneB3RUA WCj1tKQPcXt1JG+FQ6Cq26tue1+sC89f4GOkww7sE82WwbNZf3VK/hI6E/LT00+i10u6R7zlg Z/LXXYWzUSYRSjd5S0QmLS7G5RD5Pl7TGsX8mbKznvfBoJH7nay9+F6N+QY= X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 19:42:53 -0000 --Sig_//9UtlAXwddK82MsGGgt9aeP Content-Type: multipart/mixed; boundary="MP_/QXuJWY8+K7cFF5R+jrvtRLx" --MP_/QXuJWY8+K7cFF5R+jrvtRLx Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Am Wed, 24 May 2017 12:11:06 -0700 "Ngie Cooper (yaneurabeya)" schrieb: > > On May 24, 2017, at 11:10, O. Hartmann wrote: > >=20 > > Am Wed, 24 May 2017 13:04:30 -0500 > > Larry Rosenman schrieb: =20 >=20 > =E2=80=A6 >=20 > > I use the traditional "make" way (via portmaster) =20 >=20 > There were some reports about needing to do =E2=80=9Cmake clean=E2=80=9D= before =E2=80=9Cmake install=E2=80=9D. > Memory serves me correctly there are ways in portmaster to bypass =E2=80= =9Cmake clean=E2=80=9D before > running =E2=80=9Cmake install=E2=80=9D. Could you please provide your por= tmasterrc file? Thanks, -Ngie attached, but there is nothing unusual from my point of view. make clean is= also done prior to the make all. --=20 O. Hartmann Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Abs.= 4 BDSG). --MP_/QXuJWY8+K7cFF5R+jrvtRLx Content-Type: application/octet-stream; name=portmaster.rc Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename=portmaster.rc IyAkRnJlZUJTRCQKIwojIFNhbXBsZSBwb3J0bWFzdGVyIHJjIGZpbGUuCiMgUGxhY2UgaW4gJEhP TUUvLnBvcnRtYXN0ZXJyYyBvciAvdXNyL2xvY2FsL2V0Yy9wb3J0bWFzdGVyLnJjCiMKIyBQbGVh c2UgcmVhZCB0aGUgcG9ydG1hc3RlciBtYW4gcGFnZSBmb3IgbW9yZSBpbmZvcm1hdGlvbiBvbgoj IHRoZXNlIG9wdGlvbnMuCiMKIyBEbyBub3QgY3JlYXRlIHRlbXBvcmFyeSBiYWNrdXAgcGFja2Fn ZXMgYmVmb3JlIHBrZ19kZWxldGUgKC1CKQojIE5PX0JBQ0tVUD1Cb3B0CiMKIyBBbHdheXMgc2F2 ZSB0aGUgYmFja3VwIHBhY2thZ2VzIG9mIHRoZSBvbGQgcG9ydCAoLWIpCiMgQkFDS1VQPWJvcHQK IwojIE1ha2UgYW5kIHNhdmUgYSBwYWNrYWdlIG9mIHRoZSBuZXcgcG9ydCAoLWcpCiMgTUFLRV9Q QUNLQUdFPWdvcHQKIwojIERvIG5vdCBwcmVjbGVhbiB0aGUgcG9ydCdzIGJ1aWxkIGRpcmVjdG9y eSAoLUMpCiMgRE9OVF9QUkVfQ0xFQU49Q29wdAojCiMgRG8gbm90IGNsZWFuIHRoZSBwb3J0J3Mg YnVpbGQgZGlyZWN0b3J5IGFmdGVyIGluc3RhbGxhdGlvbiAoLUspCiMgRE9OVF9QT1NUX0NMRUFO PUtvcHQKIwojIE5ldmVyIHNlYXJjaCBmb3Igc3RhbGUgZGlzdGZpbGVzIHRvIGRlbGV0ZSAoLUQp CiMgRE9OVF9TQ1JVQl9ESVNURklMRVM9RG9wdAojCiMgQWx3YXlzIGRlbGV0ZSBzdGFsZSBkaXN0 ZmlsZXMgd2l0aG91dCBwcm9tcHRpbmcgKC1kKQpBTFdBWVNfU0NSVUJfRElTVEZJTEVTPWRvcHQK IwojIERvIG5vdCBydW4gJ21ha2UgY29uZmlnJyBmb3IgcG9ydHMgdGhhdCBuZWVkIHVwZGF0aW5n ICgtRykKIyBQTV9OT19NQUtFX0NPTkZJRz1Hb3B0CiMKIyBIaWRlIHRoZSBidWlsZCBhbmQgaW5z dGFsbCBwcm9jZXNzZXMgaW4gYSBsb2cgZmlsZSAoLUgpCiMgSElERV9CVUlMRD1Ib3B0CiMKIyBB cmd1bWVudHMgdG8gcGFzcyB0byBtYWtlICgtbSkKIyBQTV9NQUtFX0FSR1M9Jy1ERk9SQ0VfUEtH X1JFR0lTVEVSJwojCiMgUmVjdXJzZSB0aHJvdWdoIGV2ZXJ5IGRlcGVuZGVuY3ksIGFuZCBjaGls ZCBkZXBlbmRlbmNpZXMgKC10KQojCiMgTk9URToJVVNFIE9GIFRISVMgT1BUSU9OIElOIFlPVVIg Q09ORklHIEZJTEUgSVMgTk9UIFJFQ09NTUVOREVECiMJSVQgSVMgT05MWSBORUVERUQgSU4gU1BF Q0lBTCBDSVJDVU1TVEFOQ0VTLCBBTkQgU0hPVUxEIEJFCiMJVVNFRCBGUk9NIFRIRSBDT01NQU5E IExJTkUuCiMKIyBSRUNVUlNFX1RIT1JPVUdIPXRvcHQKIwojIEJlIHZlcmJvc2UgKC12KQojIFBN X1ZFUkJPU0U9dm9wdAojCiMgU2F2ZSBjb3BpZXMgb2Ygb2xkIHNoYXJlZCBsaWJyYXJpZXMgKHJl Y29tbWVuZGVkKSAoLXcpCiMgU0FWRV9TSEFSRUQ9d29wdAojCiMgSW5zdGFsbCBhIHBhY2thZ2Ug aWYgYXZhaWxhYmxlICgtUCBvciAtLXBhY2thZ2VzKQojIFBNX1BBQ0tBR0VTPWZpcnN0CiMKIyBP bmx5IGluc3RhbGwgcGFja2FnZXMgKC1QUCBvciAtLXBhY2thZ2VzLW9ubHkpCiMgUE1fUEFDS0FH RVM9b25seQojCiMgSW5zdGFsbCBwYWNrYWdlcyBmb3IgYnVpbGQtb25seSBkZXBlbmRlbmNpZXMg KC0tcGFja2FnZXMtYnVpbGQpCiMgUE1fUEFDS0FHRVNfQlVJTEQ9cG1wX2J1aWxkCiMKIyBEZWxl dGUgYnVpbGQtb25seSBkZXBlbmRlbmNpZXMgd2hlbiBmaW5pc2hlZCAoLS1kZWxldGUtYnVpbGQt b25seSkKIyBQTV9ERUxfQlVJTERfT05MWT1wbV9kYm8KIwojIFVzZSBwYWNrYWdlcyBpZiB0aGV5 IGFyZSBuZXdlciB0aGFuIGluc3RhbGxlZCAoLS1wYWNrYWdlcy1uZXdlcikKIyBQTV9QQUNLQUdF Uz1uZXdlcgojIFBNX1BBQ0tBR0VTX05FV0VSPXBtcF9uZXdlcgojCiMgQWx3YXlzIGZldGNoIG5l dyBwYWNrYWdlIGZpbGVzICgtLWFsd2F5cy1mZXRjaCkKIyBQTV9BTFdBWVNfRkVUQ0g9cG1fYWx3 YXlzX2ZldGNoCiMKIyBTcGVjaWZ5IGEgbG9jYWwgcGFja2FnZSByZXBvc2l0b3J5ICgtLWxvY2Fs LXBhY2thZ2VkaXIpCiMgTE9DQUxfUEFDS0FHRURJUj08cGF0aD4KIwojIE9ubHkgdXNlIHBhY2th Z2VzIGZyb20gLS1sb2NhbC1wYWNrYWdlZGlyICgtLXBhY2thZ2VzLWxvY2FsKQojIFBNX1BBQ0tB R0VTX0xPQ0FMPXBtcF9sb2NhbAojCiMgRGVsZXRlIHBhY2thZ2VzIGFmdGVyIHRoZXkgYXJlIGlu c3RhbGxlZCAoLS1kZWxldGUtcGFja2FnZXMpCiMgUE1fREVMRVRFX1BBQ0tBR0VTPXBtX2RlbGV0 ZV9wYWNrYWdlcwojCiMgU3VwcHJlc3MgdGhlIGJ1aWxkIGNvbmZpcm1hdGlvbiBtZXNzYWdlICgt LW5vLWNvbmZpcm0pCiMgUE1fTk9fQ09ORklSTT1wbV9ub19jb25maXJtCiMKIyBEbyBub3QgdXBk YXRlIHRoZSB4dGVybSB0aXRsZSBiYXIgKC0tbm8tdGVybS10aXRsZSkKIyBQTV9OT19URVJNX1RJ VExFPXBtX25vX3Rlcm1fdGl0bGUKIwojIERvIG5vdCBmZXRjaCB0aGUgSU5ERVggZmlsZSAoLS1u by1pbmRleC1mZXRjaCkKIyBQTV9OT19JTkRFWF9GRVRDSD1wbV9ub19pbmRleF9mZXRjaAojCiMg VXNlIG9ubHkgdGhlIElOREVYIGZpbGUgdG8gY2hlY2sgaWYgYSBwb3J0IGlzIG91dCBvZiBkYXRl ICgtLWluZGV4KQojIFBNX0lOREVYPXBtX2luZGV4CiMKIyBVc2UgdGhlIElOREVYIGZpbGUgZmly c3QsIHRoZW4gY2hlY2sgL3Vzci9wb3J0cyAoLS1pbmRleC1maXJzdCkKIyBQTV9JTkRFWD1wbV9p bmRleAojIFBNX0lOREVYX0ZJUlNUPXBtX2luZGV4X2ZpcnN0CiMKIyBVc2UgdGhlIElOREVYIGZp bGUgaW5zdGVhZCBvZiAvdXNyL3BvcnRzICgtLWluZGV4LW9ubHkpCiMgUE1fSU5ERVg9cG1faW5k ZXgKIyBQTV9JTkRFWF9PTkxZPXBtX2luZGV4X29ubHkKIwojIElmIGJ1aWxkaW5nIGFzIGFuIHVu cHJpdmlsZWdlZCB1c2VyIGFuZCB5b3UgaGF2ZSBTVV9DTUQgaW4gbWFrZS5jb25mKDUpLgojIE5v dGU6IHBvcnRtYXN0ZXIgZG9lcyBub3QgcHJvdmlkZSBjb21tYW5kIGFzIGEgc2luZ2xlIGFyZ3Vt ZW50LCBpLmUuCiMgaWYgeW91ciBtYWtlLmNvbmYoNSkgc3BlY2lmaWVzIGBTVV9DTUQ9c3VkbyAt RSBzaCAtY2AsIHRoZW4gdGhlIGNvcnJlY3QKIyBjb3JyZXNwb25kaW5nIHBvcnRtYXN0ZXIgY29u ZmlndXJhdGlvbiBpcyBgUE1fU1VfQ01EPXN1ZG9gLgojIFBNX1NVX0NNRD1zdWRvCiMKIwojIFRo ZSBmb2xsb3dpbmcgb3B0aW9ucyBhcmUgYXZhaWxhYmxlIGZvciB0aGUgcmMgZmlsZSBvbmx5Ogoj CiMgTG9nIGFjdGlvbnMgdGFrZW4gYnkgcG9ydG1hc3RlciB3aXRoIGEgZGF0ZS90aW1lIHN0YW1w CiMgUE1fTE9HPS9mdWxsL3BhdGgvdG8vZmlsZQojCiMgRG8gbm90IHByb21wdCB0aGUgdXNlciBm b3IgZmFpbGVkIGJhY2t1cCBwYWNrYWdlIGNyZWF0aW9uCiMgUE1fSUdOT1JFX0ZBSUxFRF9CQUNL VVBfUEFDS0FHRT1wbV9pZ25vcmVfZmFpbGVkX2JhY2t1cF9wYWNrYWdlCiMKIyBMaXN0IG9mIGZp bGVzIHRvIHByZXNlcnZlIGFjcm9zcyB1cGdyYWRlcywgYW5kIHRoZSBwb3J0cyB0aGF0IGluc3Rh bGwgdGhlbS4KIyBZb3UgY2FuIGNvbnZlcnQgY2F0ZWdvcnkvcG9ydG5hbWUgdG8gdGhlIHJpZ2h0 IHBhdHRlcm4gZm9yIHRoZSBfZmlsZXMgdmFyaWFibGUKIyBieSB1c2luZyB0aGUgZm9sbG93aW5n OiBlY2hvIGNhdGVnb3J5L3BvcnRuYW1lIHwgc2VkICdzI1stKy9cLl0jXyNnJwojIFBNX1BSRVNF UlZFX1BPUlRTPSJkbnMvcDUtTmV0LUROUyIKIyBkbnNfcDVfTmV0X0ROU19maWxlcz0iL3Vzci9s b2NhbC9zaGFyZS9kb2MvcDUtTmV0LUROUy9UT0RPIgo= --MP_/QXuJWY8+K7cFF5R+jrvtRLx-- --Sig_//9UtlAXwddK82MsGGgt9aeP Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iLUEARMKAB0WIQQZVZMzAtwC2T/86TrS528fyFhYlAUCWSXiMAAKCRDS528fyFhY lKZaAf9Mh/NGbOXlFteO1mCZgevP6TNx+jVtWsNNORsT8yDqnl/AWlObYlo8+jPG BllRgegk9sMlTnGKe6ywabqfd0QKAf9qMxJPu2RpFJuljWWKlr3lLGetMBRTDXn6 6dbjTi5tC061y1OnKSzCapCCzx9FIjybvteqmSIwGm1ZFThKzd4G =JoU6 -----END PGP SIGNATURE----- --Sig_//9UtlAXwddK82MsGGgt9aeP-- From owner-svn-src-head@freebsd.org Wed May 24 20:19:43 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EF293D7CF91; Wed, 24 May 2017 20:19:43 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from smtp-out-no.shaw.ca (smtp-out-no.shaw.ca [64.59.134.13]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "Client", Issuer "CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 8DA541A2E; Wed, 24 May 2017 20:19:42 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from spqr.komquats.com ([96.50.22.10]) by shaw.ca with SMTP id DckldeK0rM9gtDckmdFLty; Wed, 24 May 2017 14:19:35 -0600 X-Authority-Analysis: v=2.2 cv=a+JAzQaF c=1 sm=1 tr=0 a=jvE2nwUzI0ECrNeyr98KWA==:117 a=jvE2nwUzI0ECrNeyr98KWA==:17 a=kj9zAlcOel0A:10 a=tJ8p9aeEuA8A:10 a=6I5d2MoRAAAA:8 a=6VqBrpBaAAAA:8 a=YxBL1-UpAAAA:8 a=QflrKiuasJPXsMzlugIA:9 a=CjuIK1q_8ugA:10 a=IjZwj45LgO3ly-622nXo:22 a=l6wOqGboJC1rSQv2Z1Bd:22 a=Ia-lj3WSrqcvXOmTRaiG:22 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by spqr.komquats.com (Postfix) with ESMTPS id 70FCE196; Wed, 24 May 2017 13:19:31 -0700 (PDT) Received: from slippy (localhost [127.0.0.1]) by slippy.cwsent.com (8.15.2/8.15.2) with ESMTP id v4OKHFbC030278; Wed, 24 May 2017 13:17:15 -0700 (PDT) (envelope-from Cy.Schubert@cschubert.com) Message-Id: <201705242017.v4OKHFbC030278@slippy.cwsent.com> X-Mailer: exmh version 2.8.0 04/21/2012 with nmh-1.6 Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.cschubert.com/ To: Bryan Drewery cc: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Subject: Re: svn commit: r318757 - head In-Reply-To: Message from Bryan Drewery of "Tue, 23 May 2017 16:33:06 -0700." <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 24 May 2017 13:17:15 -0700 X-CMAE-Envelope: MS4wfNjCKTfuCmf/qz4XavPa4oh94E2fIMBgZsLPhJM4ToPk+eG7QotPLp9S5QS2+cCMykuGN8HD3wf5bxkId4XgOtorhDchnBt0GT2PmcvWL6zWjRE/6mLE J7k6pbe6NpP4r5r+JP7rzM53dzQ8i9C1s5gSWzoO1/oQ7b9xdFnuxDlGiU20hnlvHB0o2DsFUetzi04xr2L/lN5qcRMOPm8CGdQpcrO500SGpeT8OhRgSDvw +vIqMwa+53gU/jIZu6dFyBLPfPu8oZJxsTMSocwpHHQxO9tktdN55GVjCaNgG9VlHDyWcGdyuCkSJu2eoA7hnB+wFdCttJPgBauLoZ6rpv8TrTQo9076shMi EG8/MZITQWlXJa/9Wi7gieKxq5xnNw== X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 20:19:44 -0000 In message <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org>, Bryan Drewery wr ites: > This is an OpenPGP/MIME signed message (RFC 4880 and 3156) > --sIw1a8MPU8obGIEqPMSjxuV84b026de6m > Content-Type: multipart/mixed; boundary="8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr"; > protected-headers="v1" > From: Bryan Drewery > To: Larry Rosenman , Ed Maste , > src-committers@freebsd.org, svn-src-all@freebsd.org, > svn-src-head@freebsd.org, > "freebsd-current@freebsd.org" > Message-ID: <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org> > Subject: Re: svn commit: r318757 - head > References: <201705232025.v4NKPnrH001395@repo.freebsd.org> > > > <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> > <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> > In-Reply-To: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> > > --8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr > Content-Type: text/plain; charset=utf-8 > Content-Language: en-US > Content-Transfer-Encoding: quoted-printable > > On 5/23/2017 4:29 PM, Bryan Drewery wrote: > > On 5/23/2017 4:24 PM, Larry Rosenman wrote: > >> borg.lerctr.org /home/ler $ sudo poudriere jail -l > >> JAILNAME VERSION ARCH METHOD TIMESTAMP = > PATH > >> p103amd64 10.3-RELEASE-p18 amd64 http 2017-04-23 08:3= > 9:24 /usr/local/poudriere/jails/p103amd64 > >> p103i386 10.3-RELEASE-p18 i386 http 2017-04-23 08:4= > 0:44 /usr/local/poudriere/jails/p103i386 > >> p110amd64 11.0-RELEASE-p10 amd64 http 2017-05-15 14:5= > 4:58 /usr/local/poudriere/jails/p110amd64 > >> p110i386 11.0-RELEASE-p9 i386 http 2017-04-23 08:4= > 1:48 /usr/local/poudriere/jails/p110i386 > >> live 12.0-CURRENT amd64 src=3D/usr/src 2017-05-23 13= > :39:40 /usr/local/poudriere/jails/live > >> pHEADamd64 12.0-CURRENT amd64 src=3D/usr/src 2017-04-24 17= > :15:13 /usr/local/poudriere/jails/pHEADamd64 > >> p120armv6 12.0-CURRENT r317340 arm.armv6 svn+https 2017-04-23 10:0= > 7:40 /usr/local/poudriere/jails/p110borg.lerctr.org /usr/local/etc/poudri= > ere.d/jails/live $ cat version > >> 12.0-CURRENT > >> borg.lerctr.org /usr/local/etc/poudriere.d/jails/live $armv6 > >> borg.lerctr.org /home/ler $ > >> > >> > >> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ c= > at .jailversion > >> 12.0-CURRENT > >> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $ > >> > >> > >> > >=20 > > That looks like a bug in Poudriere with -m src. It is using 12.0-CURREN= > T > > rather than __FreeBSD_version of 1200031. I'm working on a fix. > >=20 > > Usually Poudriere, for head, will rebuild if the SVN revision changes. > It is very liberal with rebuilds on head and does not usually consider > __FreeBSD_version since it can be forgotten, and historically was not > always bumped on SA/EN either so we used the uname -r output. So this > bug is limited to -m src|null|tar. Hi Bryan, If do you choose to fix this, please provide a facility to override the liberal rebuilds. I for one know when I need to blow away all my package repos and start from scratch, which BTW I commenced with -c this morning after upgrading my poudriere jails. I may update a poudriere jail to address occasional port build failures under 12.0 which are fixed by more recent commits to -CURRENT that don't affect the ABI. Rebuilding packages from scratch is painful. -- Cheers, Cy Schubert FreeBSD UNIX: Web: http://www.FreeBSD.org The need of the many outweighs the greed of the few. From owner-svn-src-head@freebsd.org Wed May 24 20:37:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 24FEAD807C2; Wed, 24 May 2017 20:37:26 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id EAABC1D33; Wed, 24 May 2017 20:37:25 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (unknown [127.0.1.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by freefall.freebsd.org (Postfix) with ESMTPS id D897D56C1; Wed, 24 May 2017 20:37:24 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from mail.xzibition.com (localhost [172.31.3.2]) by mail.xzibition.com (Postfix) with ESMTP id 9D0C972EE; Wed, 24 May 2017 20:37:23 +0000 (UTC) X-Virus-Scanned: amavisd-new at mail.xzibition.com Received: from mail.xzibition.com ([172.31.3.2]) by mail.xzibition.com (mail.xzibition.com [172.31.3.2]) (amavisd-new, port 10026) with LMTP id iEtasI4ylVsa; Wed, 24 May 2017 20:37:18 +0000 (UTC) Subject: Re: svn commit: r318757 - head DKIM-Filter: OpenDKIM Filter v2.9.2 mail.xzibition.com C933B72E8 To: Cy Schubert References: <201705242017.v4OKHFbC030278@slippy.cwsent.com> Cc: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" From: Bryan Drewery Organization: FreeBSD Message-ID: <939f7ce1-b6f0-2ca1-5d83-da100b5727e5@FreeBSD.org> Date: Wed, 24 May 2017 13:37:01 -0700 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <201705242017.v4OKHFbC030278@slippy.cwsent.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="JCUPfB24pL7cutbBkXanSp027BebBqLE2" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 20:37:26 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --JCUPfB24pL7cutbBkXanSp027BebBqLE2 Content-Type: multipart/mixed; boundary="j5V9ka7PD7rxapig3ihA8RJkqXjxWaDSH"; protected-headers="v1" From: Bryan Drewery To: Cy Schubert Cc: Larry Rosenman , Ed Maste , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "freebsd-current@freebsd.org" Message-ID: <939f7ce1-b6f0-2ca1-5d83-da100b5727e5@FreeBSD.org> Subject: Re: svn commit: r318757 - head References: <201705242017.v4OKHFbC030278@slippy.cwsent.com> In-Reply-To: <201705242017.v4OKHFbC030278@slippy.cwsent.com> --j5V9ka7PD7rxapig3ihA8RJkqXjxWaDSH Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 5/24/17 1:17 PM, Cy Schubert wrote: > In message <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org>, Bryan=20 > Drewery wr > ites: >> This is an OpenPGP/MIME signed message (RFC 4880 and 3156) >> --sIw1a8MPU8obGIEqPMSjxuV84b026de6m >> Content-Type: multipart/mixed; boundary=3D"8b3Tlc1Bt9VfscoFw6tX1N8B8aT= eGubhr"; >> protected-headers=3D"v1" >> From: Bryan Drewery >> To: Larry Rosenman , Ed Maste , >> src-committers@freebsd.org, svn-src-all@freebsd.org, >> svn-src-head@freebsd.org, >> "freebsd-current@freebsd.org" >> Message-ID: <1c1ab22c-60bf-4707-f635-8069aa1e0594@FreeBSD.org> >> Subject: Re: svn commit: r318757 - head >> References: <201705232025.v4NKPnrH001395@repo.freebsd.org> >> >> >> <145539DE-59B4-4F21-B699-877DED6A2D1C@lerctr.org> >> <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> >> In-Reply-To: <4fe6fbf4-03e4-804d-784a-67283ed9efd0@FreeBSD.org> >> >> --8b3Tlc1Bt9VfscoFw6tX1N8B8aTeGubhr >> Content-Type: text/plain; charset=3Dutf-8 >> Content-Language: en-US >> Content-Transfer-Encoding: quoted-printable >> >> On 5/23/2017 4:29 PM, Bryan Drewery wrote: >>> On 5/23/2017 4:24 PM, Larry Rosenman wrote: >>>> borg.lerctr.org /home/ler $ sudo poudriere jail -l >>>> JAILNAME VERSION ARCH METHOD TIMESTAMP = =3D >> PATH >>>> p103amd64 10.3-RELEASE-p18 amd64 http 2017-04-23 08= :3=3D >> 9:24 /usr/local/poudriere/jails/p103amd64 >>>> p103i386 10.3-RELEASE-p18 i386 http 2017-04-23 08= :4=3D >> 0:44 /usr/local/poudriere/jails/p103i386 >>>> p110amd64 11.0-RELEASE-p10 amd64 http 2017-05-15 14= :5=3D >> 4:58 /usr/local/poudriere/jails/p110amd64 >>>> p110i386 11.0-RELEASE-p9 i386 http 2017-04-23 08= :4=3D >> 1:48 /usr/local/poudriere/jails/p110i386 >>>> live 12.0-CURRENT amd64 src=3D3D/usr/src 2017-05-2= 3 13=3D >> :39:40 /usr/local/poudriere/jails/live >>>> pHEADamd64 12.0-CURRENT amd64 src=3D3D/usr/src 2017-04-2= 4 17=3D >> :15:13 /usr/local/poudriere/jails/pHEADamd64 >>>> p120armv6 12.0-CURRENT r317340 arm.armv6 svn+https 2017-04-23 10= :0=3D >> 7:40 /usr/local/poudriere/jails/p110borg.lerctr.org /usr/local/etc/pou= dri=3D >> ere.d/jails/live $ cat version >>>> 12.0-CURRENT >>>> borg.lerctr.org /usr/local/etc/poudriere.d/jails/live $armv6 >>>> borg.lerctr.org /home/ler $ >>>> >>>> >>>> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $= c=3D >> at .jailversion >>>> 12.0-CURRENT >>>> borg.lerctr.org /usr/local/poudriere/data/packages/live-host-ports $= >>>> >>>> >>>> >>> =3D20 >>> That looks like a bug in Poudriere with -m src. It is using 12.0-CURR= EN=3D >> T >>> rather than __FreeBSD_version of 1200031. I'm working on a fix. >>> =3D20 >> >> Usually Poudriere, for head, will rebuild if the SVN revision changes.= >> It is very liberal with rebuilds on head and does not usually consider= >> __FreeBSD_version since it can be forgotten, and historically was not >> always bumped on SA/EN either so we used the uname -r output. So this= >> bug is limited to -m src|null|tar. >=20 > Hi Bryan, >=20 > If do you choose to fix this, please provide a facility to override the= =20 > liberal rebuilds. I for one know when I need to blow away all my packag= e=20 > repos and start from scratch, which BTW I commenced with -c this mornin= g=20 > after upgrading my poudriere jails. I may update a poudriere jail to=20 > address occasional port build failures under 12.0 which are fixed by mo= re=20 > recent commits to -CURRENT that don't affect the ABI. >=20 > Rebuilding packages from scratch is painful. >=20 >=20 Agreed, it is painful. I came up with an idea to reduce the massive rebuild needs on arch@ a few years ago. I just haven't had a chance to implement it. https://lists.freebsd.org/pipermail/freebsd-arch/2015-April/017025.html --=20 Regards, Bryan Drewery --j5V9ka7PD7rxapig3ihA8RJkqXjxWaDSH-- --JCUPfB24pL7cutbBkXanSp027BebBqLE2 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJZJe7uAAoJEDXXcbtuRpfPpC4IAI0/ODHDGqXlGj9qXiqmLcJR mvtzCrepymiwwy/2nC5jfv00oD8Q/e2RIzjiHjvpusl/Em9ETh4vm47CbyYnW0PE ZnzK7hMQeeptuK3V2IeJzrPV3dw0MFImSyBCVpv5IMSdE8qQIBQGX/z+qS3YR9PA IEPQcjODbEp2GIWQTh7Boe6z79fEu5hYOYHHPLt4NHGqOB0YkHVYlsEtSnQ5BLhy xWBKZqq2Ge6npoowGPiM26l0lGA4tqAy9UpOZNoiCpz1PQN7QRNfqdX7Rk4d7zuu 9R7BvAtxHZ/7k06xC/JJw7BPiOw1PXYMOP9XVB50358UnH/hhwrsmjq7oRKFu5k= =/s3v -----END PGP SIGNATURE----- --JCUPfB24pL7cutbBkXanSp027BebBqLE2-- From owner-svn-src-head@freebsd.org Wed May 24 20:41:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 04343D80A46; Wed, 24 May 2017 20:41:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A46C41383; Wed, 24 May 2017 20:41:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OKfQpj009392; Wed, 24 May 2017 20:41:26 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OKfQeW009391; Wed, 24 May 2017 20:41:26 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242041.v4OKfQeW009391@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 20:41:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318812 - head/cddl/contrib/opensolaris/cmd/zdb 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.23 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, 24 May 2017 20:41:28 -0000 Author: avg Date: Wed May 24 20:41:26 2017 New Revision: 318812 URL: https://svnweb.freebsd.org/changeset/base/318812 Log: MFV r316860: 7545 zdb should disable reference tracking illumos/illumos-gate@4dd77f9e38ef05b39db128ff7608d926fd3218c6 https://github.com/illumos/illumos-gate/commit/4dd77f9e38ef05b39db128ff7608d926fd3218c6 https://www.illumos.org/issues/7545 When evicting from the ARC, we manipulate some refcount_t's, e.g. arcs_size. When using zdb to examine a large amount of data (e.g. zdb -bb on a large pool with small blocks), the ARC may have a large number of entries. If reference tracking is enabled, there will be ~1 reference for each block in the ARC. When evicting, we decrement the refcount and have to search all the references to find the one that we are removing, which is very slow. Since zdb is typically used to find problems with the on-disk format, and not with the code it is running, we should disable reference tracking in zdb. Reviewed by: Dan Kimmel Reviewed by: Steve Gonczi Reviewed by: George Wilson Approved by: Robert Mustacchi Author: Matthew Ahrens MFC after: 2 weeks Modified: head/cddl/contrib/opensolaris/cmd/zdb/zdb.c Directory Properties: head/cddl/contrib/opensolaris/ (props changed) head/cddl/contrib/opensolaris/cmd/zdb/ (props changed) Modified: head/cddl/contrib/opensolaris/cmd/zdb/zdb.c ============================================================================== --- head/cddl/contrib/opensolaris/cmd/zdb/zdb.c Wed May 24 20:34:19 2017 (r318811) +++ head/cddl/contrib/opensolaris/cmd/zdb/zdb.c Wed May 24 20:41:26 2017 (r318812) @@ -75,10 +75,12 @@ DMU_OT_ZAP_OTHER : DMU_OT_NUMTYPES)) #ifndef lint +extern int reference_tracking_enable; extern boolean_t zfs_recover; extern uint64_t zfs_arc_max, zfs_arc_meta_limit; extern int zfs_vdev_async_read_max_active; #else +int reference_tracking_enable; boolean_t zfs_recover; uint64_t zfs_arc_max, zfs_arc_meta_limit; int zfs_vdev_async_read_max_active; @@ -3696,6 +3698,11 @@ main(int argc, char **argv) */ zfs_vdev_async_read_max_active = 10; + /* + * Disable reference tracking for better performance. + */ + reference_tracking_enable = B_FALSE; + kernel_init(FREAD); g_zfs = libzfs_init(); if (g_zfs == NULL) From owner-svn-src-head@freebsd.org Wed May 24 20:53:02 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E8A9AD7C085; Wed, 24 May 2017 20:53:02 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B8F2910D0; Wed, 24 May 2017 20:53:02 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OKr1jt014753; Wed, 24 May 2017 20:53:01 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OKr1hK014752; Wed, 24 May 2017 20:53:01 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242053.v4OKr1hK014752@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 20:53:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318814 - head/cddl/contrib/opensolaris/lib/libzfs_core/common 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.23 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, 24 May 2017 20:53:03 -0000 Author: avg Date: Wed May 24 20:53:01 2017 New Revision: 318814 URL: https://svnweb.freebsd.org/changeset/base/318814 Log: MFC r316904: 7729 libzfs_core`lzc_rollback() leaks result nvl illumos/illumos-gate@ac428481f96be89add7a1edf43ae47dd71038553 https://github.com/illumos/illumos-gate/commit/ac428481f96be89add7a1edf43ae47dd71038553 https://www.illumos.org/issues/7729 libzfs_core`lzc_rollback() doesn't free the result nvl after lzc_ioctl() call. Reviewed by: Matthew Ahrens Reviewed by: Prakash Surya Approved by: Dan McDonald Author: Yuri Pankov MFC after: 2 weeks Modified: head/cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.c Directory Properties: head/cddl/contrib/opensolaris/ (props changed) Modified: head/cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.c Wed May 24 20:52:47 2017 (r318813) +++ head/cddl/contrib/opensolaris/lib/libzfs_core/common/libzfs_core.c Wed May 24 20:53:01 2017 (r318814) @@ -759,6 +759,8 @@ lzc_rollback(const char *fsname, char *s const char *snapname = fnvlist_lookup_string(result, "target"); (void) strlcpy(snapnamebuf, snapname, snapnamelen); } + nvlist_free(result); + return (err); } From owner-svn-src-head@freebsd.org Wed May 24 21:02:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A32ED7C401; Wed, 24 May 2017 21:02:56 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E98261905; Wed, 24 May 2017 21:02:55 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OL2seI019344; Wed, 24 May 2017 21:02:54 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OL2sn1019335; Wed, 24 May 2017 21:02:54 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201705242102.v4OL2sn1019335@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Wed, 24 May 2017 21:02:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318816 - in head: lib/lib80211 lib/libc/net lib/libc/sys lib/libpmc share/man/man4 share/man/man7 usr.sbin/pmcstudy 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.23 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, 24 May 2017 21:02:56 -0000 Author: trasz Date: Wed May 24 21:02:53 2017 New Revision: 318816 URL: https://svnweb.freebsd.org/changeset/base/318816 Log: Don't end up manpage titles with a full stop. MFC after: 2 weeks Modified: head/lib/lib80211/lib80211.3 head/lib/libc/net/sctp_bindx.3 head/lib/libc/net/sctp_getassocid.3 head/lib/libc/sys/setfib.2 head/lib/libpmc/pmc_event_names_of_class.3 head/share/man/man4/mmcsd.4 head/share/man/man7/growfs.7 head/usr.sbin/pmcstudy/pmcstudy.8 Modified: head/lib/lib80211/lib80211.3 ============================================================================== --- head/lib/lib80211/lib80211.3 Wed May 24 20:54:14 2017 (r318815) +++ head/lib/lib80211/lib80211.3 Wed May 24 21:02:53 2017 (r318816) @@ -36,7 +36,7 @@ .Nm lib80211_regdomain_findbyname , .Nm lib80211_country_findbycc , .Nm lib80211_country_findbyname -.Nd manage net80211 configuration and regulatory database. +.Nd manage net80211 configuration and regulatory database .Sh LIBRARY .Lb lib80211 .Sh SYNOPSIS Modified: head/lib/libc/net/sctp_bindx.3 ============================================================================== --- head/lib/libc/net/sctp_bindx.3 Wed May 24 20:54:14 2017 (r318815) +++ head/lib/libc/net/sctp_bindx.3 Wed May 24 21:02:53 2017 (r318816) @@ -33,7 +33,7 @@ .Os .Sh NAME .Nm sctp_bindx -.Nd bind or unbind an SCTP socket to a list of addresses. +.Nd bind or unbind an SCTP socket to a list of addresses .Sh LIBRARY .Lb libc .Sh SYNOPSIS Modified: head/lib/libc/net/sctp_getassocid.3 ============================================================================== --- head/lib/libc/net/sctp_getassocid.3 Wed May 24 20:54:14 2017 (r318815) +++ head/lib/libc/net/sctp_getassocid.3 Wed May 24 21:02:53 2017 (r318816) @@ -32,7 +32,7 @@ .Os .Sh NAME .Nm sctp_getassocid -.Nd return an association id for a specified socket address. +.Nd return an association id for a specified socket address .Sh LIBRARY .Lb libc .Sh SYNOPSIS Modified: head/lib/libc/sys/setfib.2 ============================================================================== --- head/lib/libc/sys/setfib.2 Wed May 24 20:54:14 2017 (r318815) +++ head/lib/libc/sys/setfib.2 Wed May 24 21:02:53 2017 (r318816) @@ -29,7 +29,7 @@ .Os .Sh NAME .Nm setfib -.Nd set the default FIB (routing table) for the calling process. +.Nd set the default FIB (routing table) for the calling process .Sh LIBRARY .Lb libc .Sh SYNOPSIS Modified: head/lib/libpmc/pmc_event_names_of_class.3 ============================================================================== --- head/lib/libpmc/pmc_event_names_of_class.3 Wed May 24 20:54:14 2017 (r318815) +++ head/lib/libpmc/pmc_event_names_of_class.3 Wed May 24 21:02:53 2017 (r318816) @@ -28,7 +28,7 @@ .Os .Sh NAME .Nm pmc_event_names_of_class -.Nd return a list of event names supported by a PMC class. +.Nd return a list of event names supported by a PMC class .Sh LIBRARY .Lb libpmc .Sh SYNOPSIS Modified: head/share/man/man4/mmcsd.4 ============================================================================== --- head/share/man/man4/mmcsd.4 Wed May 24 20:54:14 2017 (r318815) +++ head/share/man/man4/mmcsd.4 Wed May 24 21:02:53 2017 (r318816) @@ -29,7 +29,7 @@ .Os .Sh NAME .Nm mmcsd -.Nd MMC and SD memory card driver. +.Nd MMC and SD memory card driver .Sh SYNOPSIS .Cd device mmcsd .Sh DESCRIPTION Modified: head/share/man/man7/growfs.7 ============================================================================== --- head/share/man/man7/growfs.7 Wed May 24 20:54:14 2017 (r318815) +++ head/share/man/man7/growfs.7 Wed May 24 21:02:53 2017 (r318816) @@ -29,7 +29,7 @@ .Os .Sh NAME .Nm growfs -.Nd start up script to grow the root file-system. +.Nd start up script to grow the root file-system .Sh DESCRIPTION The following options in .Pa /etc/rc.conf Modified: head/usr.sbin/pmcstudy/pmcstudy.8 ============================================================================== --- head/usr.sbin/pmcstudy/pmcstudy.8 Wed May 24 20:54:14 2017 (r318815) +++ head/usr.sbin/pmcstudy/pmcstudy.8 Wed May 24 21:02:53 2017 (r318816) @@ -29,7 +29,7 @@ .Os .Sh NAME .Nm pmcstudy -.Nd Perform various studies on a system's overall PMCs. +.Nd Perform various studies on a system's overall PMCs .Sh SYNOPSIS .Nm .Oo Fl i Ar inputfile | Fl A | Fl T | Fl v | Fl m Ar max | Fl e exp | Fl Ar E | Fl h | fl H Oc From owner-svn-src-head@freebsd.org Wed May 24 21:08:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 90B0AD7C512; Wed, 24 May 2017 21:08:27 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BE1B1B3D; Wed, 24 May 2017 21:08:27 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x244.google.com with SMTP id u26so34587908pfd.2; Wed, 24 May 2017 14:08:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=tsG1TSiRKkxSvvT1JDbkdhop+oJyZgeP6OxK//dZxiU=; b=Yk3M+ChvVl8+SlF5yve0Hal6Gzq6ofdNtMbIDWVAa6mDOOAkniAK45xwpBX0kh459f pWA2IDUYqcPkziok5H2RF8ETS/hdXa2GU5+cZd0oIPL2yGPou4zgING02mL5vXMUWFvb lKnaKDsbbUaxuI1mjxEOOi6oWSRo2hX193FqDJ4MqU1OI6nLkuJi56LBhjMA02s6J04F 6QOSJniwJQFaQigr9mgH+kxcqWrFO2Kawe1b0MOrSQKJlpPU0SJR41UuaxMu8z6/rsGs AgkITy0wuA80MQMck3dupvVWz7BEZ9ud7za8Fe3/WzxiaFNGmtisJED/YRqj4hhmUJ8P lw4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=tsG1TSiRKkxSvvT1JDbkdhop+oJyZgeP6OxK//dZxiU=; b=FL7iQjRVoNVynUS1HHgN1PThQInQ+0ScoFb+VSVrtgB+VUA3aE8qD1OR9Lfay6W5z5 gXDF9HBaaCNPWqB+A6pADX5rnrT20mkLVV78LCiI+LtyG0X6lLIWg6MTxDQMFgPfM+AZ 97vOgMDs/MwDenk22koKvf6MmcGGZ6gh0JWKzudCtCv5ogEOOLCvW9ab+xQJIKioiRNp sHPW38F/OWGaSJmVdMly029/WSxu92fZI4KhYcO5m96btp6dmydOkZa1nbFyxkQAD9eA NvmbW95brBhupwq75jxht7nTy4ClOmRbWZiPYawdwBQ2NsT38VGOr5IMlbyHmTr0YWa0 olLA== X-Gm-Message-State: AODbwcA4OhVU+8ThQ0kbiaH8VJU6nQEux1H43PoAG4YJubOYyb+hC0km Uc3gScHO4x2uVGknGQ8= X-Received: by 10.84.194.34 with SMTP id g31mr8257455pld.89.1495660106472; Wed, 24 May 2017 14:08:26 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id r73sm8680488pfk.114.2017.05.24.14.08.25 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 24 May 2017 14:08:25 -0700 (PDT) Subject: Re: svn commit: r318736 - in head: cddl/lib/libzfs contrib/compiler-rt/lib/sanitizer_common contrib/openbsm/libbsm include lib/libarchive lib/libc/gen lib/libc/include lib/libc/sys lib/libkvm lib/libmi... Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_D41F78AE-185C-4C04-A79F-65D75918BEC6"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Wed, 24 May 2017 14:08:24 -0700 Cc: Pedro Giffuni , Konstantin Belousov , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: References: <201705230929.v4N9T5g1028124@repo.freebsd.org> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 21:08:27 -0000 --Apple-Mail=_D41F78AE-185C-4C04-A79F-65D75918BEC6 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On May 24, 2017, at 09:26, Ed Maste wrote: >=20 > On 24 May 2017 at 10:53, Pedro Giffuni wrote: >>=20 >> There is now a bunch of coverity issues (OVERFLOW_BEFORE_WIDEN = mostly) >> tied to ino64_t. At least the following CIDs are related: >=20 > On a quick look the OVERFLOW_BEFORE_WIDEN issues are false positives > in practice: for correct operation the product must fit within 32 > bits, because inodes were previously 32 bits. However, it does seem > unusual to perform a multiplication with types that could overflow 32 > bits, and then store the result in a 64-bit variable. So it seems that > a code change to eliminate the warning is likely reasonable. Wouldn=E2=80=99t the proper fix be: - Check the inode value for overflow? - Cast to the smaller historical value? Or: - Widen the type for the smaller historical value to a larger value? Thanks, -Ngie PS I=E2=80=99d have to see how we fixed this internally at Isilon. We = might have a patch kicking around for this. --Apple-Mail=_D41F78AE-185C-4C04-A79F-65D75918BEC6 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJZJfZIAAoJEPWDqSZpMIYV7WsQAKz+vRLrXUUO8eWBRebNOBv6 YBhGZpNNUdWdS++LaOJONt/zKT+ShvtgDWCtosQ7U0Kx1N/ePnQfhSUrWIGSPvMK dBNpa80oScDvU24aEBaw+lOpfImKWgxkKK8Bd5QSjzorY9PPe6pde9kypr8RduCQ MPbC4a9rn4PLYqWdMJWFeWii8oonQToOo6Jlv5SdorkcpSp8KfkP1wfrgcorsS25 +ef29047NMG91Fj5PmLf9tc5znTuBap059ZAohvbVwP5BheJ4bntx36a3FDPacxf sOhshfEi+RuR1lDdOh/VP59Ek8Kt//1k0sNPemc7DnG+4OnISBm+nBUd3VIB/2cU r7q19CeU0rwBIjTygSuaE8G0vdQrTXb660l7BT5X02NK4Cgzw24NR1USmau1FkUt FXLbGEMu+wOS2nElHuaZ4PnRSuImPIpvIVbs+2lgCX6YWavPRVJn/5Jaxy+3MiHl zRqKc+PDpo1H0rIZ2qkAFd+uRdcVkp63lUP9ZGlqaDe2ikxW4VhU004Ul7sf9tVN 11nMCx1clGTh3B99R480iByuGiHS3eJmTAmxxwY9zJH61I4k1QW8n77YVIhYCwUN LQi8N3gz9GocX8VjhbfT5XiIFfFn8pX1DtNNy+GmbeBJcIv88xs7aFN9uTuwvY1K Di0zg1Cv8fpv+5q7O//y =9lgE -----END PGP SIGNATURE----- --Apple-Mail=_D41F78AE-185C-4C04-A79F-65D75918BEC6-- From owner-svn-src-head@freebsd.org Wed May 24 21:29:33 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AB65BD7CAD0; Wed, 24 May 2017 21:29:33 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7A85618B5; Wed, 24 May 2017 21:29:33 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLTWiV027894; Wed, 24 May 2017 21:29:32 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLTVbx027885; Wed, 24 May 2017 21:29:31 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242129.v4OLTVbx027885@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:29:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318818 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 21:29:33 -0000 Author: avg Date: Wed May 24 21:29:31 2017 New Revision: 318818 URL: https://svnweb.freebsd.org/changeset/base/318818 Log: MFC r316907: 1300 filename normalization doesn't work for removes illumos/illumos-gate@1c17160ac558f98048951327f4e9248d8f46acc0 https://github.com/illumos/illumos-gate/commit/1c17160ac558f98048951327f4e9248d8f46acc0 https://www.illumos.org/issues/1300 FreeBSD note: recent FreeBSD was not affected by the issue fixed as the name cache is completely bypassed when normalization is enabled. The change is imported for the sake of ZAP infrastructure modifications. Reviewed by: Yuri Pankov Reviewed by: Pavel Zakharov Reviewed by: Matt Ahrens Approved by: Dan McDonald Author: Kevin Crowe MFC after: 3 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_bookmark.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap_impl.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_leaf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_dir.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 21:29:31 2017 (r318818) @@ -18,15 +18,16 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012, 2016 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. * Copyright (c) 2013, Joyent, Inc. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. - * Copyright 2015 Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2015, STRATO AG, Inc. All rights reserved. * Copyright (c) 2014 Integros [integros.com] + * Copyright 2017 Nexenta Systems, Inc. */ /* Portions Copyright 2010 Robert Milkowski */ @@ -1622,7 +1623,7 @@ dmu_snapshot_realname(objset_t *os, char return (zap_lookup_norm(ds->ds_dir->dd_pool->dp_meta_objset, dsl_dataset_phys(ds)->ds_snapnames_zapobj, name, 8, 1, &ignored, - MT_FIRST, real, maxlen, conflict)); + MT_NORMALIZE, real, maxlen, conflict)); } int Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_bookmark.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_bookmark.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_bookmark.c Wed May 24 21:29:31 2017 (r318818) @@ -12,8 +12,10 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2013, 2014 by Delphix. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. */ #include @@ -59,16 +61,14 @@ dsl_dataset_bmark_lookup(dsl_dataset_t * { objset_t *mos = ds->ds_dir->dd_pool->dp_meta_objset; uint64_t bmark_zapobj = ds->ds_bookmarks; - matchtype_t mt; + matchtype_t mt = 0; int err; if (bmark_zapobj == 0) return (SET_ERROR(ESRCH)); if (dsl_dataset_phys(ds)->ds_flags & DS_FLAG_CI_DATASET) - mt = MT_FIRST; - else - mt = MT_EXACT; + mt = MT_NORMALIZE; err = zap_lookup_norm(mos, bmark_zapobj, shortname, sizeof (uint64_t), sizeof (*bmark_phys) / sizeof (uint64_t), bmark_phys, mt, @@ -339,12 +339,10 @@ dsl_dataset_bookmark_remove(dsl_dataset_ { objset_t *mos = ds->ds_dir->dd_pool->dp_meta_objset; uint64_t bmark_zapobj = ds->ds_bookmarks; - matchtype_t mt; + matchtype_t mt = 0; if (dsl_dataset_phys(ds)->ds_flags & DS_FLAG_CI_DATASET) - mt = MT_FIRST; - else - mt = MT_EXACT; + mt = MT_NORMALIZE; return (zap_remove_norm(mos, bmark_zapobj, name, mt, tx)); } Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c Wed May 24 21:29:31 2017 (r318818) @@ -18,6 +18,7 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Portions Copyright (c) 2011 Martin Matuska @@ -27,6 +28,7 @@ * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] * Copyright 2016, OmniTI Computer Consulting, Inc. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. */ #include @@ -364,17 +366,15 @@ dsl_dataset_snap_lookup(dsl_dataset_t *d { objset_t *mos = ds->ds_dir->dd_pool->dp_meta_objset; uint64_t snapobj = dsl_dataset_phys(ds)->ds_snapnames_zapobj; - matchtype_t mt; + matchtype_t mt = 0; int err; if (dsl_dataset_phys(ds)->ds_flags & DS_FLAG_CI_DATASET) - mt = MT_FIRST; - else - mt = MT_EXACT; + mt = MT_NORMALIZE; err = zap_lookup_norm(mos, snapobj, name, 8, 1, value, mt, NULL, 0, NULL); - if (err == ENOTSUP && mt == MT_FIRST) + if (err == ENOTSUP && (mt & MT_NORMALIZE)) err = zap_lookup(mos, snapobj, name, 8, 1, value); return (err); } @@ -385,18 +385,16 @@ dsl_dataset_snap_remove(dsl_dataset_t *d { objset_t *mos = ds->ds_dir->dd_pool->dp_meta_objset; uint64_t snapobj = dsl_dataset_phys(ds)->ds_snapnames_zapobj; - matchtype_t mt; + matchtype_t mt = 0; int err; dsl_dir_snap_cmtime_update(ds->ds_dir); if (dsl_dataset_phys(ds)->ds_flags & DS_FLAG_CI_DATASET) - mt = MT_FIRST; - else - mt = MT_EXACT; + mt = MT_NORMALIZE; err = zap_remove_norm(mos, snapobj, name, mt, tx); - if (err == ENOTSUP && mt == MT_FIRST) + if (err == ENOTSUP && (mt & MT_NORMALIZE)) err = zap_remove(mos, snapobj, name, tx); if (err == 0 && adj_cnt) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h Wed May 24 21:29:31 2017 (r318818) @@ -18,9 +18,11 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. */ #ifndef _SYS_ZAP_H @@ -88,22 +90,15 @@ extern "C" { /* * Specifies matching criteria for ZAP lookups. - */ -typedef enum matchtype -{ - /* Only find an exact match (non-normalized) */ - MT_EXACT, - /* - * If there is an exact match, find that, otherwise find the - * first normalized match. - */ - MT_BEST, - /* - * Find the "first" normalized (case and Unicode form) match; - * the designated "first" match will not change as long as the - * set of entries with this normalization doesn't change. - */ - MT_FIRST + * MT_NORMALIZE Use ZAP normalization flags, which can include both + * unicode normalization and case-insensitivity. + * MT_MATCH_CASE Do case-sensitive lookups even if MT_NORMALIZE is + * specified and ZAP normalization flags include + * U8_TEXTPREP_TOUPPER. + */ +typedef enum matchtype { + MT_NORMALIZE = 1 << 0, + MT_MATCH_CASE = 1 << 1, } matchtype_t; typedef enum zap_flags { @@ -120,16 +115,6 @@ typedef enum zap_flags { /* * Create a new zapobj with no attributes and return its object number. - * MT_EXACT will cause the zap object to only support MT_EXACT lookups, - * otherwise any matchtype can be used for lookups. - * - * normflags specifies what normalization will be done. values are: - * 0: no normalization (legacy on-disk format, supports MT_EXACT matching - * only) - * U8_TEXTPREP_TOLOWER: case normalization will be performed. - * MT_FIRST/MT_BEST matching will find entries that match without - * regard to case (eg. looking for "foo" can find an entry "Foo"). - * Eventually, other flags will permit unicode normalization as well. */ uint64_t zap_create(objset_t *ds, dmu_object_type_t ot, dmu_object_type_t bonustype, int bonuslen, dmu_tx_t *tx); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap_impl.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap_impl.h Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap_impl.h Wed May 24 21:29:31 2017 (r318818) @@ -18,11 +18,13 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2013, 2016 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] + * Copyright 2017 Nexenta Systems, Inc. */ #ifndef _SYS_ZAP_IMPL_H @@ -189,6 +191,7 @@ typedef struct zap_name { int zn_key_norm_numints; uint64_t zn_hash; matchtype_t zn_matchtype; + int zn_normflags; char zn_normbuf[ZAP_MAXNAMELEN]; } zap_name_t; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_leaf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_leaf.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_leaf.c Wed May 24 21:29:31 2017 (r318818) @@ -18,9 +18,11 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2013, 2015 by Delphix. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. */ /* @@ -361,7 +363,7 @@ zap_leaf_array_match(zap_leaf_t *l, zap_ } ASSERT(zn->zn_key_intlen == 1); - if (zn->zn_matchtype == MT_FIRST) { + if (zn->zn_matchtype & MT_NORMALIZE) { char *thisname = kmem_alloc(array_numints, KM_SLEEP); boolean_t match; @@ -403,7 +405,6 @@ zap_leaf_lookup(zap_leaf_t *l, zap_name_ ASSERT3U(zap_leaf_phys(l)->l_hdr.lh_magic, ==, ZAP_LEAF_MAGIC); -again: for (chunkp = LEAF_HASH_ENTPTR(l, zn->zn_hash); *chunkp != CHAIN_END; chunkp = &le->le_next) { uint16_t chunk = *chunkp; @@ -418,9 +419,9 @@ again: /* * NB: the entry chain is always sorted by cd on * normalized zap objects, so this will find the - * lowest-cd match for MT_FIRST. + * lowest-cd match for MT_NORMALIZE. */ - ASSERT(zn->zn_matchtype == MT_EXACT || + ASSERT((zn->zn_matchtype == 0) || (zap_leaf_phys(l)->l_hdr.lh_flags & ZLF_ENTRIES_CDSORTED)); if (zap_leaf_array_match(l, zn, le->le_name_chunk, le->le_name_numints)) { @@ -434,15 +435,6 @@ again: } } - /* - * NB: we could of course do this in one pass, but that would be - * a pain. We'll see if MT_BEST is even used much. - */ - if (zn->zn_matchtype == MT_BEST) { - zn->zn_matchtype = MT_FIRST; - goto again; - } - return (SET_ERROR(ENOENT)); } @@ -697,7 +689,7 @@ zap_entry_normalization_conflict(zap_ent continue; if (zn == NULL) { - zn = zap_name_alloc(zap, name, MT_FIRST); + zn = zap_name_alloc(zap, name, MT_NORMALIZE); allocdzn = B_TRUE; } if (zap_leaf_array_match(zeh->zeh_leaf, zn, Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Wed May 24 21:29:31 2017 (r318818) @@ -18,11 +18,13 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2016 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] + * Copyright 2017 Nexenta Systems, Inc. */ #include @@ -133,7 +135,7 @@ zap_hash(zap_name_t *zn) } static int -zap_normalize(zap_t *zap, const char *name, char *namenorm) +zap_normalize(zap_t *zap, const char *name, char *namenorm, int normflags) { size_t inlen, outlen; int err; @@ -145,8 +147,8 @@ zap_normalize(zap_t *zap, const char *na err = 0; (void) u8_textprep_str((char *)name, &inlen, namenorm, &outlen, - zap->zap_normflags | U8_TEXTPREP_IGNORE_NULL | - U8_TEXTPREP_IGNORE_INVALID, U8_UNICODE_LATEST, &err); + normflags | U8_TEXTPREP_IGNORE_NULL | U8_TEXTPREP_IGNORE_INVALID, + U8_UNICODE_LATEST, &err); return (err); } @@ -156,15 +158,15 @@ zap_match(zap_name_t *zn, const char *ma { ASSERT(!(zap_getflags(zn->zn_zap) & ZAP_FLAG_UINT64_KEY)); - if (zn->zn_matchtype == MT_FIRST) { + if (zn->zn_matchtype & MT_NORMALIZE) { char norm[ZAP_MAXNAMELEN]; - if (zap_normalize(zn->zn_zap, matchname, norm) != 0) + if (zap_normalize(zn->zn_zap, matchname, norm, + zn->zn_normflags) != 0) return (B_FALSE); return (strcmp(zn->zn_key_norm, norm) == 0); } else { - /* MT_BEST or MT_EXACT */ return (strcmp(zn->zn_key_orig, matchname) == 0); } } @@ -185,15 +187,30 @@ zap_name_alloc(zap_t *zap, const char *k zn->zn_key_orig = key; zn->zn_key_orig_numints = strlen(zn->zn_key_orig) + 1; zn->zn_matchtype = mt; + zn->zn_normflags = zap->zap_normflags; + + /* + * If we're dealing with a case sensitive lookup on a mixed or + * insensitive fs, remove U8_TEXTPREP_TOUPPER or the lookup + * will fold case to all caps overriding the lookup request. + */ + if (mt & MT_MATCH_CASE) + zn->zn_normflags &= ~U8_TEXTPREP_TOUPPER; + if (zap->zap_normflags) { - if (zap_normalize(zap, key, zn->zn_normbuf) != 0) { + /* + * We *must* use zap_normflags because this normalization is + * what the hash is computed from. + */ + if (zap_normalize(zap, key, zn->zn_normbuf, + zap->zap_normflags) != 0) { zap_name_free(zn); return (NULL); } zn->zn_key_norm = zn->zn_normbuf; zn->zn_key_norm_numints = strlen(zn->zn_key_norm) + 1; } else { - if (mt != MT_EXACT) { + if (mt != 0) { zap_name_free(zn); return (NULL); } @@ -202,6 +219,20 @@ zap_name_alloc(zap_t *zap, const char *k } zn->zn_hash = zap_hash(zn); + + if (zap->zap_normflags != zn->zn_normflags) { + /* + * We *must* use zn_normflags because this normalization is + * what the matching is based on. (Not the hash!) + */ + if (zap_normalize(zap, key, zn->zn_normbuf, + zn->zn_normflags) != 0) { + zap_name_free(zn); + return (NULL); + } + zn->zn_key_norm_numints = strlen(zn->zn_key_norm) + 1; + } + return (zn); } @@ -215,7 +246,7 @@ zap_name_alloc_uint64(zap_t *zap, const zn->zn_key_intlen = sizeof (*key); zn->zn_key_orig = zn->zn_key_norm = key; zn->zn_key_orig_numints = zn->zn_key_norm_numints = numints; - zn->zn_matchtype = MT_EXACT; + zn->zn_matchtype = 0; zn->zn_hash = zap_hash(zn); return (zn); @@ -305,7 +336,6 @@ mze_find(zap_name_t *zn) mze_tofind.mze_hash = zn->zn_hash; mze_tofind.mze_cd = 0; -again: mze = avl_find(avl, &mze_tofind, &idx); if (mze == NULL) mze = avl_nearest(avl, idx, AVL_AFTER); @@ -314,10 +344,7 @@ again: if (zap_match(zn, MZE_PHYS(zn->zn_zap, mze)->mze_name)) return (mze); } - if (zn->zn_matchtype == MT_BEST) { - zn->zn_matchtype = MT_FIRST; - goto again; - } + return (NULL); } @@ -422,8 +449,7 @@ mzap_open(objset_t *os, uint64_t obj, dm if (mze->mze_name[0]) { zap_name_t *zn; - zn = zap_name_alloc(zap, mze->mze_name, - MT_EXACT); + zn = zap_name_alloc(zap, mze->mze_name, 0); if (mze_insert(zap, i, zn->zn_hash) == 0) zap->zap_m.zap_num_entries++; else { @@ -629,7 +655,7 @@ mzap_upgrade(zap_t **zapp, void *tag, dm continue; dprintf("adding %s=%llu\n", mze->mze_name, mze->mze_value); - zn = zap_name_alloc(zap, mze->mze_name, MT_EXACT); + zn = zap_name_alloc(zap, mze->mze_name, 0); err = fzap_add_cd(zn, 8, 1, &mze->mze_value, mze->mze_cd, tag, tx); zap = zn->zn_zap; /* fzap_add_cd() may change zap */ @@ -642,6 +668,23 @@ mzap_upgrade(zap_t **zapp, void *tag, dm return (err); } +/* + * The "normflags" determine the behavior of the matchtype_t which is + * passed to zap_lookup_norm(). Names which have the same normalized + * version will be stored with the same hash value, and therefore we can + * perform normalization-insensitive lookups. We can be Unicode form- + * insensitive and/or case-insensitive. The following flags are valid for + * "normflags": + * + * U8_TEXTPREP_NFC + * U8_TEXTPREP_NFD + * U8_TEXTPREP_NFKC + * U8_TEXTPREP_NFKD + * U8_TEXTPREP_TOUPPER + * + * The *_NF* (Normalization Form) flags are mutually exclusive; at most one + * of them may be supplied. + */ void mzap_create_impl(objset_t *os, uint64_t obj, int normflags, zap_flags_t flags, dmu_tx_t *tx) @@ -800,7 +843,7 @@ again: if (zn == NULL) { zn = zap_name_alloc(zap, MZE_PHYS(zap, mze)->mze_name, - MT_FIRST); + MT_NORMALIZE); allocdzn = B_TRUE; } if (zap_match(zn, MZE_PHYS(zap, other)->mze_name)) { @@ -829,7 +872,7 @@ zap_lookup(objset_t *os, uint64_t zapobj uint64_t integer_size, uint64_t num_integers, void *buf) { return (zap_lookup_norm(os, zapobj, name, integer_size, - num_integers, buf, MT_EXACT, NULL, 0, NULL)); + num_integers, buf, 0, NULL, 0, NULL)); } static int @@ -897,7 +940,7 @@ zap_lookup_by_dnode(dnode_t *dn, const c uint64_t integer_size, uint64_t num_integers, void *buf) { return (zap_lookup_norm_by_dnode(dn, name, integer_size, - num_integers, buf, MT_EXACT, NULL, 0, NULL)); + num_integers, buf, 0, NULL, 0, NULL)); } int @@ -970,7 +1013,7 @@ int zap_contains(objset_t *os, uint64_t zapobj, const char *name) { int err = zap_lookup_norm(os, zapobj, name, 0, - 0, NULL, MT_EXACT, NULL, 0, NULL); + 0, NULL, 0, NULL, 0, NULL); if (err == EOVERFLOW || err == EINVAL) err = 0; /* found, but skipped reading the value */ return (err); @@ -988,7 +1031,7 @@ zap_length(objset_t *os, uint64_t zapobj err = zap_lockdir(os, zapobj, NULL, RW_READER, TRUE, FALSE, FTAG, &zap); if (err) return (err); - zn = zap_name_alloc(zap, name, MT_EXACT); + zn = zap_name_alloc(zap, name, 0); if (zn == NULL) { zap_unlockdir(zap, FTAG); return (SET_ERROR(ENOTSUP)); @@ -1091,7 +1134,7 @@ zap_add(objset_t *os, uint64_t zapobj, c err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, TRUE, FTAG, &zap); if (err) return (err); - zn = zap_name_alloc(zap, key, MT_EXACT); + zn = zap_name_alloc(zap, key, 0); if (zn == NULL) { zap_unlockdir(zap, FTAG); return (SET_ERROR(ENOTSUP)); @@ -1170,7 +1213,7 @@ zap_update(objset_t *os, uint64_t zapobj err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, TRUE, FTAG, &zap); if (err) return (err); - zn = zap_name_alloc(zap, name, MT_EXACT); + zn = zap_name_alloc(zap, name, 0); if (zn == NULL) { zap_unlockdir(zap, FTAG); return (SET_ERROR(ENOTSUP)); @@ -1233,7 +1276,7 @@ zap_update_uint64(objset_t *os, uint64_t int zap_remove(objset_t *os, uint64_t zapobj, const char *name, dmu_tx_t *tx) { - return (zap_remove_norm(os, zapobj, name, MT_EXACT, tx)); + return (zap_remove_norm(os, zapobj, name, 0, tx)); } int @@ -1525,7 +1568,7 @@ zap_count_write_by_dnode(dnode_t *dn, co return (err); if (!zap->zap_ismicro) { - zap_name_t *zn = zap_name_alloc(zap, name, MT_EXACT); + zap_name_t *zn = zap_name_alloc(zap, name, 0); if (zn) { err = fzap_count_write(zn, add, towrite, tooverwrite); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_dir.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_dir.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_dir.c Wed May 24 21:29:31 2017 (r318818) @@ -18,9 +18,11 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2013, 2015 by Delphix. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. */ #include @@ -63,12 +65,11 @@ */ static int zfs_match_find(zfsvfs_t *zfsvfs, znode_t *dzp, const char *name, - boolean_t exact, uint64_t *zoid) + matchtype_t mt, uint64_t *zoid) { int error; if (zfsvfs->z_norm) { - matchtype_t mt = exact? MT_EXACT : MT_FIRST; /* * In the non-mixed case we only expect there would ever @@ -108,7 +109,7 @@ int zfs_dirent_lookup(znode_t *dzp, const char *name, znode_t **zpp, int flag) { zfsvfs_t *zfsvfs = dzp->z_zfsvfs; - boolean_t exact; + matchtype_t mt = 0; uint64_t zoid; vnode_t *vp = NULL; int error = 0; @@ -131,15 +132,39 @@ zfs_dirent_lookup(znode_t *dzp, const ch * zfsvfs->z_case and zfsvfs->z_norm fields. These choices * affect how we perform zap lookups. * - * Decide if exact matches should be requested when performing - * a zap lookup on file systems supporting case-insensitive - * access. + * When matching we may need to normalize & change case according to + * FS settings. + * + * Note that a normalized match is necessary for a case insensitive + * filesystem when the lookup request is not exact because normalization + * can fold case independent of normalizing code point sequences. + * + * See the table above zfs_dropname(). + */ + if (zfsvfs->z_norm != 0) { + mt = MT_NORMALIZE; + + /* + * Determine if the match needs to honor the case specified in + * lookup, and if so keep track of that so that during + * normalization we don't fold case. + */ + if (zfsvfs->z_case == ZFS_CASE_MIXED) { + mt |= MT_MATCH_CASE; + } + } + + /* + * Only look in or update the DNLC if we are looking for the + * name on a file system that does not require normalization + * or case folding. We can also look there if we happen to be + * on a non-normalizing, mixed sensitivity file system IF we + * are looking for the exact name. * * NB: we do not need to worry about this flag for ZFS_CASE_SENSITIVE * because in that case MT_EXACT and MT_FIRST should produce exactly * the same result. */ - exact = zfsvfs->z_case == ZFS_CASE_MIXED; if (dzp->z_unlinked && !(flag & ZXATTR)) return (ENOENT); @@ -149,7 +174,7 @@ zfs_dirent_lookup(znode_t *dzp, const ch if (error == 0) error = (zoid == 0 ? ENOENT : 0); } else { - error = zfs_match_find(zfsvfs, dzp, name, exact, &zoid); + error = zfs_match_find(zfsvfs, dzp, name, mt, &zoid); } if (error) { if (error != ENOENT || (flag & ZEXISTS)) { @@ -566,6 +591,28 @@ zfs_link_create(znode_t *dzp, const char return (0); } +/* + * The match type in the code for this function should conform to: + * + * ------------------------------------------------------------------------ + * fs type | z_norm | lookup type | match type + * ---------|-------------|-------------|---------------------------------- + * CS !norm | 0 | 0 | 0 (exact) + * CS norm | formX | 0 | MT_NORMALIZE + * CI !norm | upper | !ZCIEXACT | MT_NORMALIZE + * CI !norm | upper | ZCIEXACT | MT_NORMALIZE | MT_MATCH_CASE + * CI norm | upper|formX | !ZCIEXACT | MT_NORMALIZE + * CI norm | upper|formX | ZCIEXACT | MT_NORMALIZE | MT_MATCH_CASE + * CM !norm | upper | !ZCILOOK | MT_NORMALIZE | MT_MATCH_CASE + * CM !norm | upper | ZCILOOK | MT_NORMALIZE + * CM norm | upper|formX | !ZCILOOK | MT_NORMALIZE | MT_MATCH_CASE + * CM norm | upper|formX | ZCILOOK | MT_NORMALIZE + * + * Abbreviations: + * CS = Case Sensitive, CI = Case Insensitive, CM = Case Mixed + * upper = case folding set by fs type on creation (U8_TEXTPREP_TOUPPER) + * formX = unicode normalization form set on fs creation + */ static int zfs_dropname(znode_t *dzp, const char *name, znode_t *zp, dmu_tx_t *tx, int flag) @@ -573,15 +620,16 @@ zfs_dropname(znode_t *dzp, const char *n int error; if (zp->z_zfsvfs->z_norm) { - if (zp->z_zfsvfs->z_case == ZFS_CASE_MIXED) - error = zap_remove_norm(zp->z_zfsvfs->z_os, - dzp->z_id, name, MT_EXACT, tx); - else - error = zap_remove_norm(zp->z_zfsvfs->z_os, - dzp->z_id, name, MT_FIRST, tx); + matchtype_t mt = MT_NORMALIZE; + + if (zp->z_zfsvfs->z_case == ZFS_CASE_MIXED) { + mt |= MT_MATCH_CASE; + } + + error = zap_remove_norm(zp->z_zfsvfs->z_os, dzp->z_id, + name, mt, tx); } else { - error = zap_remove(zp->z_zfsvfs->z_os, - dzp->z_id, name, tx); + error = zap_remove(zp->z_zfsvfs->z_os, dzp->z_id, name, tx); } return (error); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Wed May 24 21:18:13 2017 (r318817) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Wed May 24 21:29:31 2017 (r318818) @@ -18,11 +18,12 @@ * * CDDL HEADER END */ + /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012, 2015 by Delphix. All rights reserved. - * Copyright 2014 Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2014 Integros [integros.com] + * Copyright 2017 Nexenta Systems, Inc. */ /* Portions Copyright 2007 Jeremy Teo */ @@ -1535,7 +1536,15 @@ zfs_lookup(vnode_t *dvp, char *nm, vnode zfsvfs_t *zfsvfs = zdp->z_zfsvfs; int error = 0; - /* fast path (should be redundant with vfs namecache) */ + /* + * Fast path lookup, however we must skip DNLC lookup + * for case folding or normalizing lookups because the + * DNLC code only stores the passed in name. This means + * creating 'a' and removing 'A' on a case insensitive + * file system would work, but DNLC still thinks 'a' + * exists and won't let you create it again on the next + * pass through fast path. + */ if (!(flags & LOOKUP_XATTR)) { if (dvp->v_type != VDIR) { return (SET_ERROR(ENOTDIR)); From owner-svn-src-head@freebsd.org Wed May 24 21:32:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA1D4D7CD52; Wed, 24 May 2017 21:32:36 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 997971DF2; Wed, 24 May 2017 21:32:36 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLWZM4031908; Wed, 24 May 2017 21:32:35 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLWZUM031906; Wed, 24 May 2017 21:32:35 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242132.v4OLWZUM031906@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:32:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318819 - head/cddl/contrib/opensolaris/lib/libzfs/common 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.23 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, 24 May 2017 21:32:37 -0000 Author: avg Date: Wed May 24 21:32:35 2017 New Revision: 318819 URL: https://svnweb.freebsd.org/changeset/base/318819 Log: MFC r316908: 7541 zpool import/tryimport ioctl returns ENOMEM because provided buffer is too small for config illumos/illumos-gate@8b65a70b763232c90a91f31eb2010314c02ed338 https://github.com/illumos/illumos-gate/commit/8b65a70b763232c90a91f31eb2010314c02ed338 https://www.illumos.org/issues/7541 When calling zpool import, zpool does a few ioctls to ZFS. zpool allocates a buffer in userland and passes it to the kernel so that ZFS can copy info into it. ZFS will use it to put the nvlist that describes the pool configuration. If the allocated buffer is too small, ZFS will return ENOMEM and the call will have to be redone. This wastes CPU time and slows down the import process. This happens very often for the ZFS_IOC_POOL_TRYIMPORT call. Reviewed by: Matthew Ahrens Reviewed by: Dan Kimmel Approved by: Dan McDonald Author: Pavel Zakharov MFC after: 2 weeks Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_impl.h head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c Directory Properties: head/cddl/contrib/opensolaris/ (props changed) head/cddl/contrib/opensolaris/lib/libzfs/ (props changed) Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_impl.h ============================================================================== --- head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_impl.h Wed May 24 21:29:31 2017 (r318818) +++ head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_impl.h Wed May 24 21:32:35 2017 (r318819) @@ -132,6 +132,8 @@ typedef enum { SHARED_SMB = 0x4 } zfs_share_type_t; +#define CONFIG_BUF_MINSIZE 65536 + int zfs_error(libzfs_handle_t *, int, const char *); int zfs_error_fmt(libzfs_handle_t *, int, const char *, ...); void zfs_error_aux(libzfs_handle_t *, const char *, ...); Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c Wed May 24 21:29:31 2017 (r318818) +++ head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_import.c Wed May 24 21:32:35 2017 (r318819) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2015 by Delphix. All rights reserved. + * Copyright (c) 2012, 2016 by Delphix. All rights reserved. * Copyright 2015 RackTop Systems. * Copyright 2016 Nexenta Systems, Inc. */ @@ -379,13 +379,14 @@ refresh_config(libzfs_handle_t *hdl, nvl { nvlist_t *nvl; zfs_cmd_t zc = { 0 }; - int err; + int err, dstbuf_size; if (zcmd_write_conf_nvlist(hdl, &zc, config) != 0) return (NULL); - if (zcmd_alloc_dst_nvlist(hdl, &zc, - zc.zc_nvlist_conf_size * 2) != 0) { + dstbuf_size = MAX(CONFIG_BUF_MINSIZE, zc.zc_nvlist_conf_size * 4); + + if (zcmd_alloc_dst_nvlist(hdl, &zc, dstbuf_size) != 0) { zcmd_free_nvlists(&zc); return (NULL); } From owner-svn-src-head@freebsd.org Wed May 24 21:42:49 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CA7B9D800A4; Wed, 24 May 2017 21:42:49 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7FF5014A2; Wed, 24 May 2017 21:42:49 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLgmwK036265; Wed, 24 May 2017 21:42:48 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLgm02036263; Wed, 24 May 2017 21:42:48 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201705242142.v4OLgm02036263@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Wed, 24 May 2017 21:42:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318820 - in head/sys: dev/sound/pcm tools/sound 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.23 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, 24 May 2017 21:42:49 -0000 Author: hselasky Date: Wed May 24 21:42:48 2017 New Revision: 318820 URL: https://svnweb.freebsd.org/changeset/base/318820 Log: Increase the allowed maximum number of audio channels from 31 to 127 in the PCM feeder mixer. Without this change a value of 32 channels is treated like zero, due to using a mask of 0x1f, causing a kernel assert when trying to playback bitperfect 32-channel audio. Also update the AWK script which is generating the division tables to handle more than 18 channels. This commit complements r282650. MFC after: 3 days Modified: head/sys/dev/sound/pcm/feeder_mixer.c head/sys/tools/sound/snd_fxdiv_gen.awk Modified: head/sys/dev/sound/pcm/feeder_mixer.c ============================================================================== --- head/sys/dev/sound/pcm/feeder_mixer.c Wed May 24 21:32:35 2017 (r318819) +++ head/sys/dev/sound/pcm/feeder_mixer.c Wed May 24 21:42:48 2017 (r318820) @@ -131,10 +131,10 @@ static struct feed_mixer_info feed_mixer sizeof(feed_mixer_info_tab[0]))) #define FEEDMIXER_DATA(i, c) ((void *) \ - ((uintptr_t)((((i) & 0x1f) << 5) | \ - ((c) & 0x1f)))) -#define FEEDMIXER_INFOIDX(d) ((uint32_t)((uintptr_t)(d) >> 5) & 0x1f) -#define FEEDMIXER_CHANNELS(d) ((uint32_t)((uintptr_t)(d)) & 0x1f) + ((uintptr_t)((((i) & 0x1f) << 7) | \ + ((c) & 0x7f)))) +#define FEEDMIXER_INFOIDX(d) ((uint32_t)((uintptr_t)(d) >> 7) & 0x1f) +#define FEEDMIXER_CHANNELS(d) ((uint32_t)((uintptr_t)(d)) & 0x7f) static int feed_mixer_init(struct pcm_feeder *f) Modified: head/sys/tools/sound/snd_fxdiv_gen.awk ============================================================================== --- head/sys/tools/sound/snd_fxdiv_gen.awk Wed May 24 21:32:35 2017 (r318819) +++ head/sys/tools/sound/snd_fxdiv_gen.awk Wed May 24 21:42:48 2017 (r318820) @@ -74,7 +74,7 @@ BEGIN { FXSHIFT = 16; FXONE = shl(1, FXSHIFT); - SND_CHN_MAX = 18; + SND_CHN_MAX = 127; PCM_8_BPS = 1; PCM_16_BPS = 2; @@ -103,9 +103,9 @@ BEGIN { printf("/*\n"); printf(" * Fast unsigned 32bit integer division and rounding, accurate for\n"); printf(" * x = 1 - %d. This table should be enough to handle possible\n", FXONE); - printf(" * division for 1 - 72 (more can be generated though..).\n"); + printf(" * division for 1 - 508 (more can be generated though..).\n"); printf(" *\n"); - printf(" * 72 = SND_CHN_MAX * PCM_32_BPS, which is why....\n"); + printf(" * 508 = SND_CHN_MAX * PCM_32_BPS, which is why....\n"); printf(" */\n\n"); printf("static const uint32_t snd_fxdiv_table[][2] = {\n"); From owner-svn-src-head@freebsd.org Wed May 24 21:43:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 03F23D8014B; Wed, 24 May 2017 21:43:36 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 99E1916DA; Wed, 24 May 2017 21:43:35 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLhY57036341; Wed, 24 May 2017 21:43:34 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLhYkn036336; Wed, 24 May 2017 21:43:34 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242143.v4OLhYkn036336@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:43:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318821 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 21:43:36 -0000 Author: avg Date: Wed May 24 21:43:34 2017 New Revision: 318821 URL: https://svnweb.freebsd.org/changeset/base/318821 Log: MFC r316912: 7793 ztest fails assertion in dmu_tx_willuse_space illumos/illumos-gate@61e255ce7267b52208af9daf434b77d37fb75622 https://github.com/illumos/illumos-gate/commit/61e255ce7267b52208af9daf434b77d37fb75622 https://www.illumos.org/issues/7793 Background information: This assertion about tx_space_* verifies that we are not dirtying more stuff than we thought we would. We “need” to know how much we will dirty so that we can check if we should fail this transaction with ENOSPC/EDQUOT, in dmu_tx_assign(). While the transaction is open (i.e. between dmu_tx_assign() and dmu_tx_commit() — typically less than a millisecond), we call dbuf_dirty() on the exact blocks that will be modified. Once this happens, the temporary accounting in tx_space_* is unnecessary, because we know exactly what blocks are newly dirtied; we call dnode_willuse_space() to track this more exact accounting. The fundamental problem causing this bug is that dmu_tx_hold_*() relies on the current state in the DMU (e.g. dn_nlevels) to predict how much will be dirtied by this transaction, but this state can change before we actually perform the transaction (i.e. call dbuf_dirty()). This bug will be fixed by removing the assertion that the tx_space_* accounting is perfectly accurate (i.e. we never dirty more than was predicted by dmu_tx_hold_*()). By removing the requirement that this accounting be perfectly accurate, we can also vastly simplify it, e.g. removing most of the logic in dmu_tx_count_*(). The new tx space accounting will be very approximate, and may be more or less than what is actually dirtied. It will still be used to determine if this transaction will put us over quota. Transactions that are marked by dmu_tx_mark_netfree() will be excepted from this check. We won’t make an attempt to determine how much space will be freed by the transaction — this was rarely accurate enough to determine if a transaction should be permitted when we are over quota, which is why dmu_tx_mark_netfree() was introduced in 2014. We also won’t attempt to give “credit” when overwriting existing blocks, if those blocks may be freed. This allows us to remove the do_free_accounting logic in dbuf_dirty(), and associated routines. This Reviewed by: Steve Gonczi Reviewed by: George Wilson Reviewed by: Pavel Zakharov Reviewed by: Brian Behlendorf Approved by: Robert Mustacchi Author: Matthew Ahrens MFC after: 3 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dir.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_impl.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_objset.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_tx.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dnode.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_dataset.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_dir.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap_impl.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 21:42:48 2017 (r318820) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 21:43:34 2017 (r318821) @@ -1346,41 +1346,6 @@ dbuf_free_range(dnode_t *dn, uint64_t st mutex_exit(&dn->dn_dbufs_mtx); } -static int -dbuf_block_freeable(dmu_buf_impl_t *db) -{ - dsl_dataset_t *ds = db->db_objset->os_dsl_dataset; - uint64_t birth_txg = 0; - - /* - * We don't need any locking to protect db_blkptr: - * If it's syncing, then db_last_dirty will be set - * so we'll ignore db_blkptr. - * - * This logic ensures that only block births for - * filled blocks are considered. - */ - ASSERT(MUTEX_HELD(&db->db_mtx)); - if (db->db_last_dirty && (db->db_blkptr == NULL || - !BP_IS_HOLE(db->db_blkptr))) { - birth_txg = db->db_last_dirty->dr_txg; - } else if (db->db_blkptr != NULL && !BP_IS_HOLE(db->db_blkptr)) { - birth_txg = db->db_blkptr->blk_birth; - } - - /* - * If this block don't exist or is in a snapshot, it can't be freed. - * Don't pass the bp to dsl_dataset_block_freeable() since we - * are holding the db_mtx lock and might deadlock if we are - * prefetching a dedup-ed block. - */ - if (birth_txg != 0) - return (ds == NULL || - dsl_dataset_block_freeable(ds, NULL, birth_txg)); - else - return (B_FALSE); -} - void dbuf_new_size(dmu_buf_impl_t *db, int size, dmu_tx_t *tx) { @@ -1430,7 +1395,7 @@ dbuf_new_size(dmu_buf_impl_t *db, int si } mutex_exit(&db->db_mtx); - dnode_willuse_space(dn, size-osize, tx); + dmu_objset_willuse_space(dn->dn_objset, size - osize, tx); DB_DNODE_EXIT(db); } @@ -1480,7 +1445,6 @@ dbuf_dirty(dmu_buf_impl_t *db, dmu_tx_t objset_t *os; dbuf_dirty_record_t **drp, *dr; int drop_struct_lock = FALSE; - boolean_t do_free_accounting = B_FALSE; int txgoff = tx->tx_txg & TXG_MASK; ASSERT(tx->tx_txg != 0); @@ -1602,15 +1566,7 @@ dbuf_dirty(dmu_buf_impl_t *db, dmu_tx_t dprintf_dbuf(db, "size=%llx\n", (u_longlong_t)db->db.db_size); if (db->db_blkid != DMU_BONUS_BLKID) { - /* - * Update the accounting. - * Note: we delay "free accounting" until after we drop - * the db_mtx. This keeps us from grabbing other locks - * (and possibly deadlocking) in bp_get_dsize() while - * also holding the db_mtx. - */ - dnode_willuse_space(dn, db->db.db_size, tx); - do_free_accounting = dbuf_block_freeable(db); + dmu_objset_willuse_space(os, db->db.db_size, tx); } /* @@ -1703,21 +1659,13 @@ dbuf_dirty(dmu_buf_impl_t *db, dmu_tx_t drop_struct_lock = TRUE; } - if (do_free_accounting) { - blkptr_t *bp = db->db_blkptr; - int64_t willfree = (bp && !BP_IS_HOLE(bp)) ? - bp_get_dsize(os->os_spa, bp) : db->db.db_size; - /* - * This is only a guess -- if the dbuf is dirty - * in a previous txg, we don't know how much - * space it will use on disk yet. We should - * really have the struct_rwlock to access - * db_blkptr, but since this is just a guess, - * it's OK if we get an odd answer. - */ - ddt_prefetch(os->os_spa, bp); - dnode_willuse_space(dn, -willfree, tx); - } + /* + * If we are overwriting a dedup BP, then unless it is snapshotted, + * when we get to syncing context we will need to decrement its + * refcount in the DDT. Prefetch the relevant DDT block so that + * syncing context won't have to wait for the i/o. + */ + ddt_prefetch(os->os_spa, db->db_blkptr); if (db->db_level == 0) { dnode_new_blkid(dn, db->db_blkid, tx, drop_struct_lock); @@ -2927,19 +2875,6 @@ dmu_buf_user_evict_wait() taskq_wait(dbu_evict_taskq); } -boolean_t -dmu_buf_freeable(dmu_buf_t *dbuf) -{ - boolean_t res = B_FALSE; - dmu_buf_impl_t *db = (dmu_buf_impl_t *)dbuf; - - if (db->db_blkptr) - res = dsl_dataset_block_freeable(db->db_objset->os_dsl_dataset, - db->db_blkptr, db->db_blkptr->blk_birth); - - return (res); -} - blkptr_t * dmu_buf_get_blkptr(dmu_buf_t *db) { Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 21:42:48 2017 (r318820) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 21:43:34 2017 (r318821) @@ -2103,3 +2103,20 @@ dmu_fsname(const char *snapname, char *b (void) strlcpy(buf, snapname, atp - snapname + 1); return (0); } + +/* + * Call when we think we're going to write/free space in open context to track + * the amount of dirty data in the open txg, which is also the amount + * of memory that can not be evicted until this txg syncs. + */ +void +dmu_objset_willuse_space(objset_t *os, int64_t space, dmu_tx_t *tx) +{ + dsl_dataset_t *ds = os->os_dsl_dataset; + int64_t aspace = spa_get_worst_case_asize(os->os_spa, space); + + if (ds != NULL) { + dsl_dir_willuse_space(ds->ds_dir, aspace, tx); + dsl_pool_dirty_space(dmu_tx_pool(tx), space, tx); + } +} Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:42:48 2017 (r318820) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:43:34 2017 (r318821) @@ -30,10 +30,10 @@ #include #include #include -#include /* for dsl_dataset_block_freeable() */ -#include /* for dsl_dir_tempreserve_*() */ +#include +#include #include -#include /* for fzap_default_block_shift */ +#include #include #include #include @@ -56,10 +56,6 @@ dmu_tx_create_dd(dsl_dir_t *dd) list_create(&tx->tx_callbacks, sizeof (dmu_tx_callback_t), offsetof(dmu_tx_callback_t, dcb_node)); tx->tx_start = gethrtime(); -#ifdef ZFS_DEBUG - refcount_create(&tx->tx_space_written); - refcount_create(&tx->tx_space_freed); -#endif return (tx); } @@ -68,7 +64,6 @@ dmu_tx_create(objset_t *os) { dmu_tx_t *tx = dmu_tx_create_dd(os->os_dsl_dataset->ds_dir); tx->tx_objset = os; - tx->tx_lastsnap_txg = dsl_dataset_prev_snap_txg(os->os_dsl_dataset); return (tx); } @@ -130,16 +125,10 @@ dmu_tx_hold_object_impl(dmu_tx_t *tx, ob txh->txh_tx = tx; txh->txh_dnode = dn; refcount_create(&txh->txh_space_towrite); - refcount_create(&txh->txh_space_tofree); - refcount_create(&txh->txh_space_tooverwrite); - refcount_create(&txh->txh_space_tounref); refcount_create(&txh->txh_memory_tohold); - refcount_create(&txh->txh_fudge); -#ifdef ZFS_DEBUG txh->txh_type = type; txh->txh_arg1 = arg1; txh->txh_arg2 = arg2; -#endif list_insert_tail(&tx->tx_holds, txh); return (txh); @@ -158,6 +147,34 @@ dmu_tx_add_new_object(dmu_tx_t *tx, objs } } +/* + * This function reads specified data from disk. The specified data will + * be needed to perform the transaction -- i.e, it will be read after + * we do dmu_tx_assign(). There are two reasons that we read the data now + * (before dmu_tx_assign()): + * + * 1. Reading it now has potentially better performance. The transaction + * has not yet been assigned, so the TXG is not held open, and also the + * caller typically has less locks held when calling dmu_tx_hold_*() than + * after the transaction has been assigned. This reduces the lock (and txg) + * hold times, thus reducing lock contention. + * + * 2. It is easier for callers (primarily the ZPL) to handle i/o errors + * that are detected before they start making changes to the DMU state + * (i.e. now). Once the transaction has been assigned, and some DMU + * state has been changed, it can be difficult to recover from an i/o + * error (e.g. to undo the changes already made in memory at the DMU + * layer). Typically code to do so does not exist in the caller -- it + * assumes that the data has already been cached and thus i/o errors are + * not possible. + * + * It has been observed that the i/o initiated here can be a performance + * problem, and it appears to be optional, because we don't look at the + * data which is read. However, removing this read would only serve to + * move the work elsewhere (after the dmu_tx_assign()), where it may + * have a greater impact on performance (in addition to the impact on + * fault tolerance noted above). + */ static int dmu_tx_check_ioerr(zio_t *zio, dnode_t *dn, int level, uint64_t blkid) { @@ -174,259 +191,84 @@ dmu_tx_check_ioerr(zio_t *zio, dnode_t * return (err); } -static void -dmu_tx_count_twig(dmu_tx_hold_t *txh, dnode_t *dn, dmu_buf_impl_t *db, - int level, uint64_t blkid, boolean_t freeable, uint64_t *history) -{ - objset_t *os = dn->dn_objset; - dsl_dataset_t *ds = os->os_dsl_dataset; - int epbs = dn->dn_indblkshift - SPA_BLKPTRSHIFT; - dmu_buf_impl_t *parent = NULL; - blkptr_t *bp = NULL; - uint64_t space; - - if (level >= dn->dn_nlevels || history[level] == blkid) - return; - - history[level] = blkid; - - space = (level == 0) ? dn->dn_datablksz : (1ULL << dn->dn_indblkshift); - - if (db == NULL || db == dn->dn_dbuf) { - ASSERT(level != 0); - db = NULL; - } else { - ASSERT(DB_DNODE(db) == dn); - ASSERT(db->db_level == level); - ASSERT(db->db.db_size == space); - ASSERT(db->db_blkid == blkid); - bp = db->db_blkptr; - parent = db->db_parent; - } - - freeable = (bp && (freeable || - dsl_dataset_block_freeable(ds, bp, bp->blk_birth))); - - if (freeable) { - (void) refcount_add_many(&txh->txh_space_tooverwrite, - space, FTAG); - } else { - (void) refcount_add_many(&txh->txh_space_towrite, - space, FTAG); - } - - if (bp) { - (void) refcount_add_many(&txh->txh_space_tounref, - bp_get_dsize(os->os_spa, bp), FTAG); - } - - dmu_tx_count_twig(txh, dn, parent, level + 1, - blkid >> epbs, freeable, history); -} - /* ARGSUSED */ static void dmu_tx_count_write(dmu_tx_hold_t *txh, uint64_t off, uint64_t len) { dnode_t *dn = txh->txh_dnode; - uint64_t start, end, i; - int min_bs, max_bs, min_ibs, max_ibs, epbs, bits; int err = 0; if (len == 0) return; - min_bs = SPA_MINBLOCKSHIFT; - max_bs = highbit64(txh->txh_tx->tx_objset->os_recordsize) - 1; - min_ibs = DN_MIN_INDBLKSHIFT; - max_ibs = DN_MAX_INDBLKSHIFT; - - if (dn) { - uint64_t history[DN_MAX_LEVELS]; - int nlvls = dn->dn_nlevels; - int delta; + (void) refcount_add_many(&txh->txh_space_towrite, len, FTAG); - /* - * For i/o error checking, read the first and last level-0 - * blocks (if they are not aligned), and all the level-1 blocks. - */ - if (dn->dn_maxblkid == 0) { - delta = dn->dn_datablksz; - start = (off < dn->dn_datablksz) ? 0 : 1; - end = (off+len <= dn->dn_datablksz) ? 0 : 1; - if (start == 0 && (off > 0 || len < dn->dn_datablksz)) { - err = dmu_tx_check_ioerr(NULL, dn, 0, 0); - if (err) - goto out; - delta -= off; - } - } else { - zio_t *zio = zio_root(dn->dn_objset->os_spa, - NULL, NULL, ZIO_FLAG_CANFAIL); - - /* first level-0 block */ - start = off >> dn->dn_datablkshift; - if (P2PHASE(off, dn->dn_datablksz) || - len < dn->dn_datablksz) { - err = dmu_tx_check_ioerr(zio, dn, 0, start); - if (err) - goto out; - } + if (refcount_count(&txh->txh_space_towrite) > 2 * DMU_MAX_ACCESS) + err = SET_ERROR(EFBIG); - /* last level-0 block */ - end = (off+len-1) >> dn->dn_datablkshift; - if (end != start && end <= dn->dn_maxblkid && - P2PHASE(off+len, dn->dn_datablksz)) { - err = dmu_tx_check_ioerr(zio, dn, 0, end); - if (err) - goto out; - } + if (dn == NULL) + return; - /* level-1 blocks */ - if (nlvls > 1) { - int shft = dn->dn_indblkshift - SPA_BLKPTRSHIFT; - for (i = (start>>shft)+1; i < end>>shft; i++) { - err = dmu_tx_check_ioerr(zio, dn, 1, i); - if (err) - goto out; - } + /* + * For i/o error checking, read the blocks that will be needed + * to perform the write: the first and last level-0 blocks (if + * they are not aligned, i.e. if they are partial-block writes), + * and all the level-1 blocks. + */ + if (dn->dn_maxblkid == 0) { + if (off < dn->dn_datablksz && + (off > 0 || len < dn->dn_datablksz)) { + err = dmu_tx_check_ioerr(NULL, dn, 0, 0); + if (err != 0) { + txh->txh_tx->tx_err = err; } - - err = zio_wait(zio); - if (err) - goto out; - delta = P2NPHASE(off, dn->dn_datablksz); - } - - min_ibs = max_ibs = dn->dn_indblkshift; - if (dn->dn_maxblkid > 0) { - /* - * The blocksize can't change, - * so we can make a more precise estimate. - */ - ASSERT(dn->dn_datablkshift != 0); - min_bs = max_bs = dn->dn_datablkshift; - } else { - /* - * The blocksize can increase up to the recordsize, - * or if it is already more than the recordsize, - * up to the next power of 2. - */ - min_bs = highbit64(dn->dn_datablksz - 1); - max_bs = MAX(max_bs, highbit64(dn->dn_datablksz - 1)); } + } else { + zio_t *zio = zio_root(dn->dn_objset->os_spa, + NULL, NULL, ZIO_FLAG_CANFAIL); - /* - * If this write is not off the end of the file - * we need to account for overwrites/unref. - */ - if (start <= dn->dn_maxblkid) { - for (int l = 0; l < DN_MAX_LEVELS; l++) - history[l] = -1ULL; + /* first level-0 block */ + uint64_t start = off >> dn->dn_datablkshift; + if (P2PHASE(off, dn->dn_datablksz) || len < dn->dn_datablksz) { + err = dmu_tx_check_ioerr(zio, dn, 0, start); + if (err != 0) { + txh->txh_tx->tx_err = err; + } } - while (start <= dn->dn_maxblkid) { - dmu_buf_impl_t *db; - - rw_enter(&dn->dn_struct_rwlock, RW_READER); - err = dbuf_hold_impl(dn, 0, start, - FALSE, FALSE, FTAG, &db); - rw_exit(&dn->dn_struct_rwlock); - if (err) { + /* last level-0 block */ + uint64_t end = (off + len - 1) >> dn->dn_datablkshift; + if (end != start && end <= dn->dn_maxblkid && + P2PHASE(off + len, dn->dn_datablksz)) { + err = dmu_tx_check_ioerr(zio, dn, 0, end); + if (err != 0) { txh->txh_tx->tx_err = err; - return; } + } - dmu_tx_count_twig(txh, dn, db, 0, start, B_FALSE, - history); - dbuf_rele(db, FTAG); - if (++start > end) { - /* - * Account for new indirects appearing - * before this IO gets assigned into a txg. - */ - bits = 64 - min_bs; - epbs = min_ibs - SPA_BLKPTRSHIFT; - for (bits -= epbs * (nlvls - 1); - bits >= 0; bits -= epbs) { - (void) refcount_add_many( - &txh->txh_fudge, - 1ULL << max_ibs, FTAG); + /* level-1 blocks */ + if (dn->dn_nlevels > 1) { + int shft = dn->dn_indblkshift - SPA_BLKPTRSHIFT; + for (uint64_t i = (start >> shft) + 1; + i < end >> shft; i++) { + err = dmu_tx_check_ioerr(zio, dn, 1, i); + if (err != 0) { + txh->txh_tx->tx_err = err; } - goto out; } - off += delta; - if (len >= delta) - len -= delta; - delta = dn->dn_datablksz; } - } - - /* - * 'end' is the last thing we will access, not one past. - * This way we won't overflow when accessing the last byte. - */ - start = P2ALIGN(off, 1ULL << max_bs); - end = P2ROUNDUP(off + len, 1ULL << max_bs) - 1; - (void) refcount_add_many(&txh->txh_space_towrite, - end - start + 1, FTAG); - - start >>= min_bs; - end >>= min_bs; - epbs = min_ibs - SPA_BLKPTRSHIFT; - - /* - * The object contains at most 2^(64 - min_bs) blocks, - * and each indirect level maps 2^epbs. - */ - for (bits = 64 - min_bs; bits >= 0; bits -= epbs) { - start >>= epbs; - end >>= epbs; - ASSERT3U(end, >=, start); - (void) refcount_add_many(&txh->txh_space_towrite, - (end - start + 1) << max_ibs, FTAG); - if (start != 0) { - /* - * We also need a new blkid=0 indirect block - * to reference any existing file data. - */ - (void) refcount_add_many(&txh->txh_space_towrite, - 1ULL << max_ibs, FTAG); + err = zio_wait(zio); + if (err != 0) { + txh->txh_tx->tx_err = err; } } - -out: - if (refcount_count(&txh->txh_space_towrite) + - refcount_count(&txh->txh_space_tooverwrite) > - 2 * DMU_MAX_ACCESS) - err = SET_ERROR(EFBIG); - - if (err) - txh->txh_tx->tx_err = err; } static void dmu_tx_count_dnode(dmu_tx_hold_t *txh) { - dnode_t *dn = txh->txh_dnode; - dnode_t *mdn = DMU_META_DNODE(txh->txh_tx->tx_objset); - uint64_t space = mdn->dn_datablksz + - ((mdn->dn_nlevels-1) << mdn->dn_indblkshift); - - if (dn && dn->dn_dbuf->db_blkptr && - dsl_dataset_block_freeable(dn->dn_objset->os_dsl_dataset, - dn->dn_dbuf->db_blkptr, dn->dn_dbuf->db_blkptr->blk_birth)) { - (void) refcount_add_many(&txh->txh_space_tooverwrite, - space, FTAG); - (void) refcount_add_many(&txh->txh_space_tounref, space, FTAG); - } else { - (void) refcount_add_many(&txh->txh_space_towrite, space, FTAG); - if (dn && dn->dn_dbuf->db_blkptr) { - (void) refcount_add_many(&txh->txh_space_tounref, - space, FTAG); - } - } + (void) refcount_add_many(&txh->txh_space_towrite, DNODE_SIZE, FTAG); } void @@ -434,8 +276,8 @@ dmu_tx_hold_write(dmu_tx_t *tx, uint64_t { dmu_tx_hold_t *txh; - ASSERT(tx->tx_txg == 0); - ASSERT(len < DMU_MAX_ACCESS); + ASSERT0(tx->tx_txg); + ASSERT3U(len, <=, DMU_MAX_ACCESS); ASSERT(len == 0 || UINT64_MAX - off >= len - 1); txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, @@ -447,179 +289,6 @@ dmu_tx_hold_write(dmu_tx_t *tx, uint64_t dmu_tx_count_dnode(txh); } -static void -dmu_tx_count_free(dmu_tx_hold_t *txh, uint64_t off, uint64_t len) -{ - uint64_t blkid, nblks, lastblk; - uint64_t space = 0, unref = 0, skipped = 0; - dnode_t *dn = txh->txh_dnode; - dsl_dataset_t *ds = dn->dn_objset->os_dsl_dataset; - spa_t *spa = txh->txh_tx->tx_pool->dp_spa; - int epbs; - uint64_t l0span = 0, nl1blks = 0; - - if (dn->dn_nlevels == 0) - return; - - /* - * The struct_rwlock protects us against dn_nlevels - * changing, in case (against all odds) we manage to dirty & - * sync out the changes after we check for being dirty. - * Also, dbuf_hold_impl() wants us to have the struct_rwlock. - */ - rw_enter(&dn->dn_struct_rwlock, RW_READER); - epbs = dn->dn_indblkshift - SPA_BLKPTRSHIFT; - if (dn->dn_maxblkid == 0) { - if (off == 0 && len >= dn->dn_datablksz) { - blkid = 0; - nblks = 1; - } else { - rw_exit(&dn->dn_struct_rwlock); - return; - } - } else { - blkid = off >> dn->dn_datablkshift; - nblks = (len + dn->dn_datablksz - 1) >> dn->dn_datablkshift; - - if (blkid > dn->dn_maxblkid) { - rw_exit(&dn->dn_struct_rwlock); - return; - } - if (blkid + nblks > dn->dn_maxblkid) - nblks = dn->dn_maxblkid - blkid + 1; - - } - l0span = nblks; /* save for later use to calc level > 1 overhead */ - if (dn->dn_nlevels == 1) { - int i; - for (i = 0; i < nblks; i++) { - blkptr_t *bp = dn->dn_phys->dn_blkptr; - ASSERT3U(blkid + i, <, dn->dn_nblkptr); - bp += blkid + i; - if (dsl_dataset_block_freeable(ds, bp, bp->blk_birth)) { - dprintf_bp(bp, "can free old%s", ""); - space += bp_get_dsize(spa, bp); - } - unref += BP_GET_ASIZE(bp); - } - nl1blks = 1; - nblks = 0; - } - - lastblk = blkid + nblks - 1; - while (nblks) { - dmu_buf_impl_t *dbuf; - uint64_t ibyte, new_blkid; - int epb = 1 << epbs; - int err, i, blkoff, tochk; - blkptr_t *bp; - - ibyte = blkid << dn->dn_datablkshift; - err = dnode_next_offset(dn, - DNODE_FIND_HAVELOCK, &ibyte, 2, 1, 0); - new_blkid = ibyte >> dn->dn_datablkshift; - if (err == ESRCH) { - skipped += (lastblk >> epbs) - (blkid >> epbs) + 1; - break; - } - if (err) { - txh->txh_tx->tx_err = err; - break; - } - if (new_blkid > lastblk) { - skipped += (lastblk >> epbs) - (blkid >> epbs) + 1; - break; - } - - if (new_blkid > blkid) { - ASSERT((new_blkid >> epbs) > (blkid >> epbs)); - skipped += (new_blkid >> epbs) - (blkid >> epbs) - 1; - nblks -= new_blkid - blkid; - blkid = new_blkid; - } - blkoff = P2PHASE(blkid, epb); - tochk = MIN(epb - blkoff, nblks); - - err = dbuf_hold_impl(dn, 1, blkid >> epbs, - FALSE, FALSE, FTAG, &dbuf); - if (err) { - txh->txh_tx->tx_err = err; - break; - } - - (void) refcount_add_many(&txh->txh_memory_tohold, - dbuf->db.db_size, FTAG); - - /* - * We don't check memory_tohold against DMU_MAX_ACCESS because - * memory_tohold is an over-estimation (especially the >L1 - * indirect blocks), so it could fail. Callers should have - * already verified that they will not be holding too much - * memory. - */ - - err = dbuf_read(dbuf, NULL, DB_RF_HAVESTRUCT | DB_RF_CANFAIL); - if (err != 0) { - txh->txh_tx->tx_err = err; - dbuf_rele(dbuf, FTAG); - break; - } - - bp = dbuf->db.db_data; - bp += blkoff; - - for (i = 0; i < tochk; i++) { - if (dsl_dataset_block_freeable(ds, &bp[i], - bp[i].blk_birth)) { - dprintf_bp(&bp[i], "can free old%s", ""); - space += bp_get_dsize(spa, &bp[i]); - } - unref += BP_GET_ASIZE(bp); - } - dbuf_rele(dbuf, FTAG); - - ++nl1blks; - blkid += tochk; - nblks -= tochk; - } - rw_exit(&dn->dn_struct_rwlock); - - /* - * Add in memory requirements of higher-level indirects. - * This assumes a worst-possible scenario for dn_nlevels and a - * worst-possible distribution of l1-blocks over the region to free. - */ - { - uint64_t blkcnt = 1 + ((l0span >> epbs) >> epbs); - int level = 2; - /* - * Here we don't use DN_MAX_LEVEL, but calculate it with the - * given datablkshift and indblkshift. This makes the - * difference between 19 and 8 on large files. - */ - int maxlevel = 2 + (DN_MAX_OFFSET_SHIFT - dn->dn_datablkshift) / - (dn->dn_indblkshift - SPA_BLKPTRSHIFT); - - while (level++ < maxlevel) { - (void) refcount_add_many(&txh->txh_memory_tohold, - MAX(MIN(blkcnt, nl1blks), 1) << dn->dn_indblkshift, - FTAG); - blkcnt = 1 + (blkcnt >> epbs); - } - } - - /* account for new level 1 indirect blocks that might show up */ - if (skipped > 0) { - (void) refcount_add_many(&txh->txh_fudge, - skipped << dn->dn_indblkshift, FTAG); - skipped = MIN(skipped, DMU_MAX_DELETEBLKCNT >> epbs); - (void) refcount_add_many(&txh->txh_memory_tohold, - skipped << dn->dn_indblkshift, FTAG); - } - (void) refcount_add_many(&txh->txh_space_tofree, space, FTAG); - (void) refcount_add_many(&txh->txh_space_tounref, unref, FTAG); -} - /* * This function marks the transaction as being a "net free". The end * result is that refquotas will be disabled for this transaction, and @@ -631,45 +300,27 @@ dmu_tx_count_free(dmu_tx_hold_t *txh, ui void dmu_tx_mark_netfree(dmu_tx_t *tx) { - dmu_tx_hold_t *txh; - - txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, - DMU_NEW_OBJECT, THT_FREE, 0, 0); - - /* - * Pretend that this operation will free 1GB of space. This - * should be large enough to cancel out the largest write. - * We don't want to use something like UINT64_MAX, because that would - * cause overflows when doing math with these values (e.g. in - * dmu_tx_try_assign()). - */ - (void) refcount_add_many(&txh->txh_space_tofree, - 1024 * 1024 * 1024, FTAG); - (void) refcount_add_many(&txh->txh_space_tounref, - 1024 * 1024 * 1024, FTAG); + tx->tx_netfree = B_TRUE; } void dmu_tx_hold_free(dmu_tx_t *tx, uint64_t object, uint64_t off, uint64_t len) { - dmu_tx_hold_t *txh; - dnode_t *dn; int err; - zio_t *zio; ASSERT(tx->tx_txg == 0); - txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, + dmu_tx_hold_t *txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, object, THT_FREE, off, len); if (txh == NULL) return; - dn = txh->txh_dnode; + dnode_t *dn = txh->txh_dnode; dmu_tx_count_dnode(txh); - if (off >= (dn->dn_maxblkid+1) * dn->dn_datablksz) + if (off >= (dn->dn_maxblkid + 1) * dn->dn_datablksz) return; if (len == DMU_OBJECT_END) - len = (dn->dn_maxblkid+1) * dn->dn_datablksz - off; + len = (dn->dn_maxblkid + 1) * dn->dn_datablksz - off; /* @@ -690,7 +341,7 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t dmu_tx_count_write(txh, off, 1); /* last block will be modified if it is not aligned */ if (!IS_P2ALIGNED(off + len, 1 << dn->dn_datablkshift)) - dmu_tx_count_write(txh, off+len, 1); + dmu_tx_count_write(txh, off + len, 1); } /* @@ -712,7 +363,7 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t if (dn->dn_datablkshift == 0) start = end = 0; - zio = zio_root(tx->tx_pool->dp_spa, + zio_t *zio = zio_root(tx->tx_pool->dp_spa, NULL, NULL, ZIO_FLAG_CANFAIL); for (uint64_t i = start; i <= end; i++) { uint64_t ibyte = i << shift; @@ -720,127 +371,80 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t i = ibyte >> shift; if (err == ESRCH || i > end) break; - if (err) { + if (err != 0) { tx->tx_err = err; + (void) zio_wait(zio); return; } + (void) refcount_add_many(&txh->txh_memory_tohold, + 1 << dn->dn_indblkshift, FTAG); + err = dmu_tx_check_ioerr(zio, dn, 1, i); - if (err) { + if (err != 0) { tx->tx_err = err; + (void) zio_wait(zio); return; } } err = zio_wait(zio); - if (err) { + if (err != 0) { tx->tx_err = err; return; } } - - dmu_tx_count_free(txh, off, len); } void dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t object, int add, const char *name) { - dmu_tx_hold_t *txh; - dnode_t *dn; int err; ASSERT(tx->tx_txg == 0); - txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, + dmu_tx_hold_t *txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, object, THT_ZAP, add, (uintptr_t)name); if (txh == NULL) return; - dn = txh->txh_dnode; + dnode_t *dn = txh->txh_dnode; dmu_tx_count_dnode(txh); - if (dn == NULL) { - /* - * We will be able to fit a new object's entries into one leaf - * block. So there will be at most 2 blocks total, - * including the header block. - */ - dmu_tx_count_write(txh, 0, 2 << fzap_default_block_shift); + /* + * Modifying a almost-full microzap is around the worst case (128KB) + * + * If it is a fat zap, the worst case would be 7*16KB=112KB: + * - 3 blocks overwritten: target leaf, ptrtbl block, header block + * - 4 new blocks written if adding: + * - 2 blocks for possibly split leaves, + * - 2 grown ptrtbl blocks + */ + (void) refcount_add_many(&txh->txh_space_towrite, + MZAP_MAX_BLKSZ, FTAG); + + if (dn == NULL) return; - } ASSERT3P(DMU_OT_BYTESWAP(dn->dn_type), ==, DMU_BSWAP_ZAP); - if (dn->dn_maxblkid == 0 && !add) { - blkptr_t *bp; - + if (dn->dn_maxblkid == 0 || name == NULL) { /* - * If there is only one block (i.e. this is a micro-zap) - * and we are not adding anything, the accounting is simple. + * This is a microzap (only one block), or we don't know + * the name. Check the first block for i/o errors. */ err = dmu_tx_check_ioerr(NULL, dn, 0, 0); - if (err) { + if (err != 0) { tx->tx_err = err; - return; - } - - /* - * Use max block size here, since we don't know how much - * the size will change between now and the dbuf dirty call. - */ - bp = &dn->dn_phys->dn_blkptr[0]; - if (dsl_dataset_block_freeable(dn->dn_objset->os_dsl_dataset, - bp, bp->blk_birth)) { - (void) refcount_add_many(&txh->txh_space_tooverwrite, - MZAP_MAX_BLKSZ, FTAG); - } else { - (void) refcount_add_many(&txh->txh_space_towrite, - MZAP_MAX_BLKSZ, FTAG); } - if (!BP_IS_HOLE(bp)) { - (void) refcount_add_many(&txh->txh_space_tounref, - MZAP_MAX_BLKSZ, FTAG); - } - return; - } - - if (dn->dn_maxblkid > 0 && name) { + } else { /* - * access the name in this fat-zap so that we'll check - * for i/o errors to the leaf blocks, etc. + * Access the name so that we'll check for i/o errors to + * the leaf blocks, etc. We ignore ENOENT, as this name + * may not yet exist. */ err = zap_lookup_by_dnode(dn, name, 8, 0, NULL); - if (err == EIO) { + if (err == EIO || err == ECKSUM || err == ENXIO) { tx->tx_err = err; - return; - } - } - - err = zap_count_write_by_dnode(dn, name, add, - &txh->txh_space_towrite, &txh->txh_space_tooverwrite); - - /* - * If the modified blocks are scattered to the four winds, - * we'll have to modify an indirect twig for each. We can make - * modifications at up to 3 locations: - * - header block at the beginning of the object - * - target leaf block - * - end of the object, where we might need to write: - * - a new leaf block if the target block needs to be split - * - the new pointer table, if it is growing - * - the new cookie table, if it is growing - */ - int epbs = dn->dn_indblkshift - SPA_BLKPTRSHIFT; - dsl_dataset_phys_t *ds_phys = - dsl_dataset_phys(dn->dn_objset->os_dsl_dataset); - for (int lvl = 1; lvl < dn->dn_nlevels; lvl++) { - uint64_t num_indirects = 1 + (dn->dn_maxblkid >> (epbs * lvl)); - uint64_t spc = MIN(3, num_indirects) << dn->dn_indblkshift; - if (ds_phys->ds_prev_snap_obj != 0) { - (void) refcount_add_many(&txh->txh_space_towrite, - spc, FTAG); - } else { - (void) refcount_add_many(&txh->txh_space_tooverwrite, - spc, FTAG); } } } @@ -870,42 +474,15 @@ dmu_tx_hold_space(dmu_tx_t *tx, uint64_t (void) refcount_add_many(&txh->txh_space_towrite, space, FTAG); } -int -dmu_tx_holds(dmu_tx_t *tx, uint64_t object) -{ - dmu_tx_hold_t *txh; - int holds = 0; - - /* - * By asserting that the tx is assigned, we're counting the - * number of dn_tx_holds, which is the same as the number of - * dn_holds. Otherwise, we'd be counting dn_holds, but - * dn_tx_holds could be 0. - */ - ASSERT(tx->tx_txg != 0); - - /* if (tx->tx_anyobj == TRUE) */ - /* return (0); */ - - for (txh = list_head(&tx->tx_holds); txh; - txh = list_next(&tx->tx_holds, txh)) { - if (txh->txh_dnode && txh->txh_dnode->dn_object == object) - holds++; - } - - return (holds); -} - #ifdef ZFS_DEBUG void dmu_tx_dirty_buf(dmu_tx_t *tx, dmu_buf_impl_t *db) { - dmu_tx_hold_t *txh; - int match_object = FALSE, match_offset = FALSE; - dnode_t *dn; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Wed May 24 21:45:53 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E1820D80291; Wed, 24 May 2017 21:45:53 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A133A18DB; Wed, 24 May 2017 21:45:53 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLjqqF036519; Wed, 24 May 2017 21:45:52 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLjqPl036516; Wed, 24 May 2017 21:45:52 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242145.v4OLjqPl036516@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:45:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318822 - 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.23 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, 24 May 2017 21:45:54 -0000 Author: avg Date: Wed May 24 21:45:52 2017 New Revision: 318822 URL: https://svnweb.freebsd.org/changeset/base/318822 Log: MFC r316913: 7869 panic in bpobj_space(): null pointer dereference illumos/illumos-gate@a3905a45920de250d181b66ac0b6b71bd200d9ef https://github.com/illumos/illumos-gate/commit/a3905a45920de250d181b66ac0b6b71bd200d9ef https://www.illumos.org/issues/7869 The issue fixed by this patch is a race condition in the deadlist code. A thread executing an administrative command that uses `dsl_deadlist_space_range()` holds the lock of the whole `deadlist_t` to protect the access of all its entries that the deadlist contains in an avl tree. Sync threads trying to insert a new entry in the deadlist (through `dsl_deadlist_insert()` -> `dle_enqueue()`) do not hold the deadlist lock at that moment. If the `dle_bpobj` is the empty bpobj (our sentinel value), we close and reopen it. Between these two operations, it is possible for the `dsl_deadlist_space_range()` thread to dereference that bpobj which is `NULL` during that window. Threads should hold the a deadlist's `dl_lock` when they manipulate its internal data so scenarios like the one above are avoided. In addition, threads should also hold the bpobj lock whenever they are allocating the subobj list of a bpobj, and not just when they actually insert the subobj to the list. This way we can avoid potential memory leaks. Reviewed by: Matt Ahrens Reviewed by: Dan Kimmel Reviewed by: Steve Gonczi Reviewed by: John Kennedy Reviewed by: George Melikov Reviewed by: Brian Behlendorf Approved by: Dan McDonald Author: Serapheim Dimitropoulos MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/bpobj.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_deadlist.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/bpobj.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/bpobj.c Wed May 24 21:43:34 2017 (r318821) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/bpobj.c Wed May 24 21:45:52 2017 (r318822) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2011, 2014 by Delphix. All rights reserved. + * Copyright (c) 2011, 2016 by Delphix. All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -395,6 +395,7 @@ bpobj_enqueue_subobj(bpobj_t *bpo, uint6 return; } + mutex_enter(&bpo->bpo_lock); dmu_buf_will_dirty(bpo->bpo_dbuf, tx); if (bpo->bpo_phys->bpo_subobjs == 0) { bpo->bpo_phys->bpo_subobjs = dmu_object_alloc(bpo->bpo_os, @@ -406,7 +407,6 @@ bpobj_enqueue_subobj(bpobj_t *bpo, uint6 ASSERT0(dmu_object_info(bpo->bpo_os, bpo->bpo_phys->bpo_subobjs, &doi)); ASSERT3U(doi.doi_type, ==, DMU_OT_BPOBJ_SUBOBJ); - mutex_enter(&bpo->bpo_lock); dmu_write(bpo->bpo_os, bpo->bpo_phys->bpo_subobjs, bpo->bpo_phys->bpo_num_subobjs * sizeof (subobj), sizeof (subobj), &subobj, tx); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_deadlist.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_deadlist.c Wed May 24 21:43:34 2017 (r318821) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_deadlist.c Wed May 24 21:45:52 2017 (r318822) @@ -72,6 +72,8 @@ dsl_deadlist_load_tree(dsl_deadlist_t *d zap_cursor_t zc; zap_attribute_t za; + ASSERT(MUTEX_HELD(&dl->dl_lock)); + ASSERT(!dl->dl_oldfmt); if (dl->dl_havetree) return; @@ -182,6 +184,7 @@ static void dle_enqueue(dsl_deadlist_t *dl, dsl_deadlist_entry_t *dle, const blkptr_t *bp, dmu_tx_t *tx) { + ASSERT(MUTEX_HELD(&dl->dl_lock)); if (dle->dle_bpobj.bpo_object == dmu_objset_pool(dl->dl_os)->dp_empty_bpobj) { uint64_t obj = bpobj_alloc(dl->dl_os, SPA_OLD_MAXBLOCKSIZE, tx); @@ -198,6 +201,7 @@ static void dle_enqueue_subobj(dsl_deadlist_t *dl, dsl_deadlist_entry_t *dle, uint64_t obj, dmu_tx_t *tx) { + ASSERT(MUTEX_HELD(&dl->dl_lock)); if (dle->dle_bpobj.bpo_object != dmu_objset_pool(dl->dl_os)->dp_empty_bpobj) { bpobj_enqueue_subobj(&dle->dle_bpobj, obj, tx); @@ -222,15 +226,14 @@ dsl_deadlist_insert(dsl_deadlist_t *dl, return; } + mutex_enter(&dl->dl_lock); dsl_deadlist_load_tree(dl); dmu_buf_will_dirty(dl->dl_dbuf, tx); - mutex_enter(&dl->dl_lock); dl->dl_phys->dl_used += bp_get_dsize_sync(dmu_objset_spa(dl->dl_os), bp); dl->dl_phys->dl_comp += BP_GET_PSIZE(bp); dl->dl_phys->dl_uncomp += BP_GET_UCSIZE(bp); - mutex_exit(&dl->dl_lock); dle_tofind.dle_mintxg = bp->blk_birth; dle = avl_find(&dl->dl_tree, &dle_tofind, &where); @@ -239,6 +242,7 @@ dsl_deadlist_insert(dsl_deadlist_t *dl, else dle = AVL_PREV(&dl->dl_tree, dle); dle_enqueue(dl, dle, bp, tx); + mutex_exit(&dl->dl_lock); } /* @@ -254,16 +258,19 @@ dsl_deadlist_add_key(dsl_deadlist_t *dl, if (dl->dl_oldfmt) return; - dsl_deadlist_load_tree(dl); - dle = kmem_alloc(sizeof (*dle), KM_SLEEP); dle->dle_mintxg = mintxg; + + mutex_enter(&dl->dl_lock); + dsl_deadlist_load_tree(dl); + obj = bpobj_alloc_empty(dl->dl_os, SPA_OLD_MAXBLOCKSIZE, tx); VERIFY3U(0, ==, bpobj_open(&dle->dle_bpobj, dl->dl_os, obj)); avl_add(&dl->dl_tree, dle); VERIFY3U(0, ==, zap_add_int_key(dl->dl_os, dl->dl_object, mintxg, obj, tx)); + mutex_exit(&dl->dl_lock); } /* @@ -278,6 +285,7 @@ dsl_deadlist_remove_key(dsl_deadlist_t * if (dl->dl_oldfmt) return; + mutex_enter(&dl->dl_lock); dsl_deadlist_load_tree(dl); dle_tofind.dle_mintxg = mintxg; @@ -291,6 +299,7 @@ dsl_deadlist_remove_key(dsl_deadlist_t * kmem_free(dle, sizeof (*dle)); VERIFY3U(0, ==, zap_remove_int(dl->dl_os, dl->dl_object, mintxg, tx)); + mutex_exit(&dl->dl_lock); } /* @@ -334,6 +343,7 @@ dsl_deadlist_clone(dsl_deadlist_t *dl, u return (newobj); } + mutex_enter(&dl->dl_lock); dsl_deadlist_load_tree(dl); for (dle = avl_first(&dl->dl_tree); dle; @@ -347,6 +357,7 @@ dsl_deadlist_clone(dsl_deadlist_t *dl, u VERIFY3U(0, ==, zap_add_int_key(dl->dl_os, newobj, dle->dle_mintxg, obj, tx)); } + mutex_exit(&dl->dl_lock); return (newobj); } @@ -424,6 +435,8 @@ dsl_deadlist_insert_bpobj(dsl_deadlist_t uint64_t used, comp, uncomp; bpobj_t bpo; + ASSERT(MUTEX_HELD(&dl->dl_lock)); + VERIFY3U(0, ==, bpobj_open(&bpo, dl->dl_os, obj)); VERIFY3U(0, ==, bpobj_space(&bpo, &used, &comp, &uncomp)); bpobj_close(&bpo); @@ -431,11 +444,9 @@ dsl_deadlist_insert_bpobj(dsl_deadlist_t dsl_deadlist_load_tree(dl); dmu_buf_will_dirty(dl->dl_dbuf, tx); - mutex_enter(&dl->dl_lock); dl->dl_phys->dl_used += used; dl->dl_phys->dl_comp += comp; dl->dl_phys->dl_uncomp += uncomp; - mutex_exit(&dl->dl_lock); dle_tofind.dle_mintxg = birth; dle = avl_find(&dl->dl_tree, &dle_tofind, &where); @@ -475,6 +486,7 @@ dsl_deadlist_merge(dsl_deadlist_t *dl, u return; } + mutex_enter(&dl->dl_lock); for (zap_cursor_init(&zc, dl->dl_os, obj); zap_cursor_retrieve(&zc, &za) == 0; zap_cursor_advance(&zc)) { @@ -489,6 +501,7 @@ dsl_deadlist_merge(dsl_deadlist_t *dl, u dmu_buf_will_dirty(bonus, tx); bzero(dlp, sizeof (*dlp)); dmu_buf_rele(bonus, FTAG); + mutex_exit(&dl->dl_lock); } /* @@ -503,6 +516,8 @@ dsl_deadlist_move_bpobj(dsl_deadlist_t * avl_index_t where; ASSERT(!dl->dl_oldfmt); + + mutex_enter(&dl->dl_lock); dmu_buf_will_dirty(dl->dl_dbuf, tx); dsl_deadlist_load_tree(dl); @@ -518,14 +533,12 @@ dsl_deadlist_move_bpobj(dsl_deadlist_t * VERIFY3U(0, ==, bpobj_space(&dle->dle_bpobj, &used, &comp, &uncomp)); - mutex_enter(&dl->dl_lock); ASSERT3U(dl->dl_phys->dl_used, >=, used); ASSERT3U(dl->dl_phys->dl_comp, >=, comp); ASSERT3U(dl->dl_phys->dl_uncomp, >=, uncomp); dl->dl_phys->dl_used -= used; dl->dl_phys->dl_comp -= comp; dl->dl_phys->dl_uncomp -= uncomp; - mutex_exit(&dl->dl_lock); VERIFY3U(0, ==, zap_remove_int(dl->dl_os, dl->dl_object, dle->dle_mintxg, tx)); @@ -536,4 +549,5 @@ dsl_deadlist_move_bpobj(dsl_deadlist_t * kmem_free(dle, sizeof (*dle)); dle = dle_next; } + mutex_exit(&dl->dl_lock); } From owner-svn-src-head@freebsd.org Wed May 24 21:49:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D0305D803E5; Wed, 24 May 2017 21:49:23 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9C07F1B29; Wed, 24 May 2017 21:49:23 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLnMdi036705; Wed, 24 May 2017 21:49:22 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLnMTa036698; Wed, 24 May 2017 21:49:22 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242149.v4OLnMTa036698@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:49:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318823 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 21:49:23 -0000 Author: avg Date: Wed May 24 21:49:21 2017 New Revision: 318823 URL: https://svnweb.freebsd.org/changeset/base/318823 Log: MFC r316914: 7801 add more by-dnode routines illumos/illumos-gate@b0c42cd4706ba01ce158bd2bb1004f7e59eca5fe https://github.com/illumos/illumos-gate/commit/b0c42cd4706ba01ce158bd2bb1004f7e59eca5fe https://www.illumos.org/issues/7801 Add *_by_dnode() routines for accessing objects given their dnode_t *, this is more efficient than accessing the object by (objset_t *, uint64_t object). This change converts some but not all of the existing consumers. As performance-sensitive code paths are discovered they should be converted to use these routines. Ported from: https://github.com/zfsonlinux/zfs/commit/0eef1bde31d67091d3deed23fe2394f5a8bf2276 Reviewed by: Matthew Ahrens Reviewed by: Brian Behlendorf Reviewed by: Pavel Zakharov Approved by: Robert Mustacchi Author: bzzz77 MFC after: 24 days Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_object.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_tx.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c Wed May 24 21:49:21 2017 (r318823) @@ -871,17 +871,12 @@ dmu_free_range(objset_t *os, uint64_t ob return (0); } -int -dmu_read(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, +static int +dmu_read_impl(dnode_t *dn, uint64_t offset, uint64_t size, void *buf, uint32_t flags) { - dnode_t *dn; dmu_buf_t **dbp; - int numbufs, err; - - err = dnode_hold(os, object, FTAG, &dn); - if (err) - return (err); + int numbufs, err = 0; /* * Deal with odd block sizes, where there can't be data past the first @@ -926,22 +921,37 @@ dmu_read(objset_t *os, uint64_t object, } dmu_buf_rele_array(dbp, numbufs, FTAG); } - dnode_rele(dn, FTAG); return (err); } -void -dmu_write(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, - const void *buf, dmu_tx_t *tx) +int +dmu_read(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, + void *buf, uint32_t flags) { - dmu_buf_t **dbp; - int numbufs, i; + dnode_t *dn; + int err; - if (size == 0) - return; + err = dnode_hold(os, object, FTAG, &dn); + if (err != 0) + return (err); - VERIFY(0 == dmu_buf_hold_array(os, object, offset, size, - FALSE, FTAG, &numbufs, &dbp)); + err = dmu_read_impl(dn, offset, size, buf, flags); + dnode_rele(dn, FTAG); + return (err); +} + +int +dmu_read_by_dnode(dnode_t *dn, uint64_t offset, uint64_t size, void *buf, + uint32_t flags) +{ + return (dmu_read_impl(dn, offset, size, buf, flags)); +} + +static void +dmu_write_impl(dmu_buf_t **dbp, int numbufs, uint64_t offset, uint64_t size, + const void *buf, dmu_tx_t *tx) +{ + int i; for (i = 0; i < numbufs; i++) { int tocpy; @@ -969,6 +979,37 @@ dmu_write(objset_t *os, uint64_t object, size -= tocpy; buf = (char *)buf + tocpy; } +} + +void +dmu_write(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, + const void *buf, dmu_tx_t *tx) +{ + dmu_buf_t **dbp; + int numbufs; + + if (size == 0) + return; + + VERIFY0(dmu_buf_hold_array(os, object, offset, size, + FALSE, FTAG, &numbufs, &dbp)); + dmu_write_impl(dbp, numbufs, offset, size, buf, tx); + dmu_buf_rele_array(dbp, numbufs, FTAG); +} + +void +dmu_write_by_dnode(dnode_t *dn, uint64_t offset, uint64_t size, + const void *buf, dmu_tx_t *tx) +{ + dmu_buf_t **dbp; + int numbufs; + + if (size == 0) + return; + + VERIFY0(dmu_buf_hold_array_by_dnode(dn, offset, size, + FALSE, FTAG, &numbufs, &dbp, DMU_READ_PREFETCH)); + dmu_write_impl(dbp, numbufs, offset, size, buf, tx); dmu_buf_rele_array(dbp, numbufs, FTAG); } Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_object.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_object.c Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_object.c Wed May 24 21:49:21 2017 (r318823) @@ -93,11 +93,11 @@ dmu_object_alloc(objset_t *os, dmu_objec } dnode_allocate(dn, ot, blocksize, 0, bonustype, bonuslen, tx); - dnode_rele(dn, FTAG); - mutex_exit(&os->os_obj_lock); - dmu_tx_add_new_object(tx, os, object); + dmu_tx_add_new_object(tx, dn); + dnode_rele(dn, FTAG); + return (object); } @@ -115,9 +115,10 @@ dmu_object_claim(objset_t *os, uint64_t if (err) return (err); dnode_allocate(dn, ot, blocksize, 0, bonustype, bonuslen, tx); + dmu_tx_add_new_object(tx, dn); + dnode_rele(dn, FTAG); - dmu_tx_add_new_object(tx, os, object); return (0); } Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:49:21 2017 (r318823) @@ -93,21 +93,14 @@ dmu_tx_private_ok(dmu_tx_t *tx) } static dmu_tx_hold_t * -dmu_tx_hold_object_impl(dmu_tx_t *tx, objset_t *os, uint64_t object, - enum dmu_tx_hold_type type, uint64_t arg1, uint64_t arg2) +dmu_tx_hold_dnode_impl(dmu_tx_t *tx, dnode_t *dn, enum dmu_tx_hold_type type, + uint64_t arg1, uint64_t arg2) { dmu_tx_hold_t *txh; - dnode_t *dn = NULL; - int err; - - if (object != DMU_NEW_OBJECT) { - err = dnode_hold(os, object, tx, &dn); - if (err) { - tx->tx_err = err; - return (NULL); - } - if (err == 0 && tx->tx_txg != 0) { + if (dn != NULL) { + (void) refcount_add(&dn->dn_holds, tx); + if (tx->tx_txg != 0) { mutex_enter(&dn->dn_mtx); /* * dn->dn_assigned_txg == tx->tx_txg doesn't pose a @@ -134,17 +127,36 @@ dmu_tx_hold_object_impl(dmu_tx_t *tx, ob return (txh); } +static dmu_tx_hold_t * +dmu_tx_hold_object_impl(dmu_tx_t *tx, objset_t *os, uint64_t object, + enum dmu_tx_hold_type type, uint64_t arg1, uint64_t arg2) +{ + dnode_t *dn = NULL; + dmu_tx_hold_t *txh; + int err; + + if (object != DMU_NEW_OBJECT) { + err = dnode_hold(os, object, FTAG, &dn); + if (err != 0) { + tx->tx_err = err; + return (NULL); + } + } + txh = dmu_tx_hold_dnode_impl(tx, dn, type, arg1, arg2); + if (dn != NULL) + dnode_rele(dn, FTAG); + return (txh); +} + void -dmu_tx_add_new_object(dmu_tx_t *tx, objset_t *os, uint64_t object) +dmu_tx_add_new_object(dmu_tx_t *tx, dnode_t *dn) { /* * If we're syncing, they can manipulate any object anyhow, and * the hold on the dnode_t can cause problems. */ - if (!dmu_tx_is_syncing(tx)) { - (void) dmu_tx_hold_object_impl(tx, os, - object, THT_NEWOBJECT, 0, 0); - } + if (!dmu_tx_is_syncing(tx)) + (void) dmu_tx_hold_dnode_impl(tx, dn, THT_NEWOBJECT, 0, 0); } /* @@ -282,11 +294,26 @@ dmu_tx_hold_write(dmu_tx_t *tx, uint64_t txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, object, THT_WRITE, off, len); - if (txh == NULL) - return; + if (txh != NULL) { + dmu_tx_count_write(txh, off, len); + dmu_tx_count_dnode(txh); + } +} - dmu_tx_count_write(txh, off, len); - dmu_tx_count_dnode(txh); +void +dmu_tx_hold_write_by_dnode(dmu_tx_t *tx, dnode_t *dn, uint64_t off, int len) +{ + dmu_tx_hold_t *txh; + + ASSERT0(tx->tx_txg); + ASSERT3U(len, <=, DMU_MAX_ACCESS); + ASSERT(len == 0 || UINT64_MAX - off >= len - 1); + + txh = dmu_tx_hold_dnode_impl(tx, dn, THT_WRITE, off, len); + if (txh != NULL) { + dmu_tx_count_write(txh, off, len); + dmu_tx_count_dnode(txh); + } } /* @@ -303,18 +330,18 @@ dmu_tx_mark_netfree(dmu_tx_t *tx) tx->tx_netfree = B_TRUE; } -void -dmu_tx_hold_free(dmu_tx_t *tx, uint64_t object, uint64_t off, uint64_t len) +static void +dmu_tx_hold_free_impl(dmu_tx_hold_t *txh, uint64_t off, uint64_t len) { + dmu_tx_t *tx; + dnode_t *dn; int err; + zio_t *zio; + tx = txh->txh_tx; ASSERT(tx->tx_txg == 0); - dmu_tx_hold_t *txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, - object, THT_FREE, off, len); - if (txh == NULL) - return; - dnode_t *dn = txh->txh_dnode; + dn = txh->txh_dnode; dmu_tx_count_dnode(txh); if (off >= (dn->dn_maxblkid + 1) * dn->dn_datablksz) @@ -396,17 +423,36 @@ dmu_tx_hold_free(dmu_tx_t *tx, uint64_t } void -dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t object, int add, const char *name) +dmu_tx_hold_free(dmu_tx_t *tx, uint64_t object, uint64_t off, uint64_t len) +{ + dmu_tx_hold_t *txh; + + txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, + object, THT_FREE, off, len); + if (txh != NULL) + (void) dmu_tx_hold_free_impl(txh, off, len); +} + +void +dmu_tx_hold_free_by_dnode(dmu_tx_t *tx, dnode_t *dn, uint64_t off, uint64_t len) +{ + dmu_tx_hold_t *txh; + + txh = dmu_tx_hold_dnode_impl(tx, dn, THT_FREE, off, len); + if (txh != NULL) + (void) dmu_tx_hold_free_impl(txh, off, len); +} + +static void +dmu_tx_hold_zap_impl(dmu_tx_hold_t *txh, int add, const char *name) { + dmu_tx_t *tx = txh->txh_tx; + dnode_t *dn; int err; ASSERT(tx->tx_txg == 0); - dmu_tx_hold_t *txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, - object, THT_ZAP, add, (uintptr_t)name); - if (txh == NULL) - return; - dnode_t *dn = txh->txh_dnode; + dn = txh->txh_dnode; dmu_tx_count_dnode(txh); @@ -450,6 +496,32 @@ dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t o } void +dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t object, int add, const char *name) +{ + dmu_tx_hold_t *txh; + + ASSERT0(tx->tx_txg); + + txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, + object, THT_ZAP, add, (uintptr_t)name); + if (txh != NULL) + dmu_tx_hold_zap_impl(txh, add, name); +} + +void +dmu_tx_hold_zap_by_dnode(dmu_tx_t *tx, dnode_t *dn, int add, const char *name) +{ + dmu_tx_hold_t *txh; + + ASSERT0(tx->tx_txg); + ASSERT(dn != NULL); + + txh = dmu_tx_hold_dnode_impl(tx, dn, THT_ZAP, add, (uintptr_t)name); + if (txh != NULL) + dmu_tx_hold_zap_impl(txh, add, name); +} + +void dmu_tx_hold_bonus(dmu_tx_t *tx, uint64_t object) { dmu_tx_hold_t *txh; @@ -463,6 +535,18 @@ dmu_tx_hold_bonus(dmu_tx_t *tx, uint64_t } void +dmu_tx_hold_bonus_by_dnode(dmu_tx_t *tx, dnode_t *dn) +{ + dmu_tx_hold_t *txh; + + ASSERT0(tx->tx_txg); + + txh = dmu_tx_hold_dnode_impl(tx, dn, THT_BONUS, 0, 0); + if (txh) + dmu_tx_count_dnode(txh); +} + +void dmu_tx_hold_space(dmu_tx_t *tx, uint64_t space) { dmu_tx_hold_t *txh; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu.h Wed May 24 21:49:21 2017 (r318823) @@ -669,10 +669,17 @@ void dmu_buf_will_dirty(dmu_buf_t *db, d dmu_tx_t *dmu_tx_create(objset_t *os); void dmu_tx_hold_write(dmu_tx_t *tx, uint64_t object, uint64_t off, int len); +void dmu_tx_hold_write_by_dnode(dmu_tx_t *tx, dnode_t *dn, uint64_t off, + int len); void dmu_tx_hold_free(dmu_tx_t *tx, uint64_t object, uint64_t off, uint64_t len); +void dmu_tx_hold_free_by_dnode(dmu_tx_t *tx, dnode_t *dn, uint64_t off, + uint64_t len); void dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t object, int add, const char *name); +void dmu_tx_hold_zap_by_dnode(dmu_tx_t *tx, dnode_t *dn, int add, + const char *name); void dmu_tx_hold_bonus(dmu_tx_t *tx, uint64_t object); +void dmu_tx_hold_bonus_by_dnode(dmu_tx_t *tx, dnode_t *dn); void dmu_tx_hold_spill(dmu_tx_t *tx, uint64_t object); void dmu_tx_hold_sa(dmu_tx_t *tx, struct sa_handle *hdl, boolean_t may_grow); void dmu_tx_hold_sa_create(dmu_tx_t *tx, int total_size); @@ -722,8 +729,12 @@ int dmu_free_long_object(objset_t *os, u #define DMU_READ_NO_PREFETCH 1 /* don't prefetch */ int dmu_read(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, void *buf, uint32_t flags); +int dmu_read_by_dnode(dnode_t *dn, uint64_t offset, uint64_t size, void *buf, + uint32_t flags); void dmu_write(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, const void *buf, dmu_tx_t *tx); +void dmu_write_by_dnode(dnode_t *dn, uint64_t offset, uint64_t size, + const void *buf, dmu_tx_t *tx); void dmu_prealloc(objset_t *os, uint64_t object, uint64_t offset, uint64_t size, dmu_tx_t *tx); int dmu_read_uio(objset_t *os, uint64_t object, struct uio *uio, uint64_t size); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_tx.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_tx.h Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_tx.h Wed May 24 21:49:21 2017 (r318823) @@ -135,7 +135,7 @@ extern dmu_tx_t *dmu_tx_create_assigned( dmu_tx_t *dmu_tx_create_dd(dsl_dir_t *dd); int dmu_tx_is_syncing(dmu_tx_t *tx); int dmu_tx_private_ok(dmu_tx_t *tx); -void dmu_tx_add_new_object(dmu_tx_t *tx, objset_t *os, uint64_t object); +void dmu_tx_add_new_object(dmu_tx_t *tx, dnode_t *dn); void dmu_tx_dirty_buf(dmu_tx_t *tx, struct dmu_buf_impl *db); void dmu_tx_hold_space(dmu_tx_t *tx, uint64_t space); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zap.h Wed May 24 21:49:21 2017 (r318823) @@ -220,6 +220,9 @@ int zap_count_write_by_dnode(dnode_t *dn int zap_add(objset_t *ds, uint64_t zapobj, const char *key, int integer_size, uint64_t num_integers, const void *val, dmu_tx_t *tx); +int zap_add_by_dnode(dnode_t *dn, const char *key, + int integer_size, uint64_t num_integers, + const void *val, dmu_tx_t *tx); int zap_add_uint64(objset_t *ds, uint64_t zapobj, const uint64_t *key, int key_numints, int integer_size, uint64_t num_integers, const void *val, dmu_tx_t *tx); @@ -259,6 +262,7 @@ int zap_length_uint64(objset_t *os, uint int zap_remove(objset_t *ds, uint64_t zapobj, const char *name, dmu_tx_t *tx); int zap_remove_norm(objset_t *ds, uint64_t zapobj, const char *name, matchtype_t mt, dmu_tx_t *tx); +int zap_remove_by_dnode(dnode_t *dn, const char *name, dmu_tx_t *tx); int zap_remove_uint64(objset_t *os, uint64_t zapobj, const uint64_t *key, int key_numints, dmu_tx_t *tx); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Wed May 24 21:45:52 2017 (r318822) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zap_micro.c Wed May 24 21:49:21 2017 (r318823) @@ -1120,34 +1120,30 @@ again: ASSERT(!"out of entries!"); } -int -zap_add(objset_t *os, uint64_t zapobj, const char *key, +static int +zap_add_impl(zap_t *zap, const char *key, int integer_size, uint64_t num_integers, - const void *val, dmu_tx_t *tx) + const void *val, dmu_tx_t *tx, void *tag) { - zap_t *zap; - int err; + int err = 0; mzap_ent_t *mze; const uint64_t *intval = val; zap_name_t *zn; - err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, TRUE, FTAG, &zap); - if (err) - return (err); zn = zap_name_alloc(zap, key, 0); if (zn == NULL) { - zap_unlockdir(zap, FTAG); + zap_unlockdir(zap, tag); return (SET_ERROR(ENOTSUP)); } if (!zap->zap_ismicro) { - err = fzap_add(zn, integer_size, num_integers, val, FTAG, tx); + err = fzap_add(zn, integer_size, num_integers, val, tag, tx); zap = zn->zn_zap; /* fzap_add() may change zap */ } else if (integer_size != 8 || num_integers != 1 || strlen(key) >= MZAP_NAME_LEN) { - err = mzap_upgrade(&zn->zn_zap, FTAG, tx, 0); + err = mzap_upgrade(&zn->zn_zap, tag, tx, 0); if (err == 0) { err = fzap_add(zn, integer_size, num_integers, val, - FTAG, tx); + tag, tx); } zap = zn->zn_zap; /* fzap_add() may change zap */ } else { @@ -1161,7 +1157,39 @@ zap_add(objset_t *os, uint64_t zapobj, c ASSERT(zap == zn->zn_zap); zap_name_free(zn); if (zap != NULL) /* may be NULL if fzap_add() failed */ - zap_unlockdir(zap, FTAG); + zap_unlockdir(zap, tag); + return (err); +} + +int +zap_add(objset_t *os, uint64_t zapobj, const char *key, + int integer_size, uint64_t num_integers, + const void *val, dmu_tx_t *tx) +{ + zap_t *zap; + int err; + + err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, TRUE, FTAG, &zap); + if (err != 0) + return (err); + err = zap_add_impl(zap, key, integer_size, num_integers, val, tx, FTAG); + /* zap_add_impl() calls zap_unlockdir() */ + return (err); +} + +int +zap_add_by_dnode(dnode_t *dn, const char *key, + int integer_size, uint64_t num_integers, + const void *val, dmu_tx_t *tx) +{ + zap_t *zap; + int err; + + err = zap_lockdir_by_dnode(dn, tx, RW_WRITER, TRUE, TRUE, FTAG, &zap); + if (err != 0) + return (err); + err = zap_add_impl(zap, key, integer_size, num_integers, val, tx, FTAG); + /* zap_add_impl() calls zap_unlockdir() */ return (err); } @@ -1279,23 +1307,17 @@ zap_remove(objset_t *os, uint64_t zapobj return (zap_remove_norm(os, zapobj, name, 0, tx)); } -int -zap_remove_norm(objset_t *os, uint64_t zapobj, const char *name, +static int +zap_remove_impl(zap_t *zap, const char *name, matchtype_t mt, dmu_tx_t *tx) { - zap_t *zap; - int err; mzap_ent_t *mze; zap_name_t *zn; + int err = 0; - err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, FALSE, FTAG, &zap); - if (err) - return (err); zn = zap_name_alloc(zap, name, mt); - if (zn == NULL) { - zap_unlockdir(zap, FTAG); + if (zn == NULL) return (SET_ERROR(ENOTSUP)); - } if (!zap->zap_ismicro) { err = fzap_remove(zn, tx); } else { @@ -1310,6 +1332,34 @@ zap_remove_norm(objset_t *os, uint64_t z } } zap_name_free(zn); + return (err); +} + +int +zap_remove_norm(objset_t *os, uint64_t zapobj, const char *name, + matchtype_t mt, dmu_tx_t *tx) +{ + zap_t *zap; + int err; + + err = zap_lockdir(os, zapobj, tx, RW_WRITER, TRUE, FALSE, FTAG, &zap); + if (err) + return (err); + err = zap_remove_impl(zap, name, mt, tx); + zap_unlockdir(zap, FTAG); + return (err); +} + +int +zap_remove_by_dnode(dnode_t *dn, const char *name, dmu_tx_t *tx) +{ + zap_t *zap; + int err; + + err = zap_lockdir_by_dnode(dn, tx, RW_WRITER, TRUE, FALSE, FTAG, &zap); + if (err) + return (err); + err = zap_remove_impl(zap, name, 0, tx); zap_unlockdir(zap, FTAG); return (err); } From owner-svn-src-head@freebsd.org Wed May 24 21:52:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 223B5D805CC; Wed, 24 May 2017 21:52:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E6B901E2D; Wed, 24 May 2017 21:52:21 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OLqKSi040483; Wed, 24 May 2017 21:52:20 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OLqKsL040482; Wed, 24 May 2017 21:52:20 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242152.v4OLqKsL040482@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 21:52:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318824 - 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.23 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, 24 May 2017 21:52:22 -0000 Author: avg Date: Wed May 24 21:52:20 2017 New Revision: 318824 URL: https://svnweb.freebsd.org/changeset/base/318824 Log: MFC r316915: 7801 add more by-dnode routines (lint) illumos/illumos-gate@411be58a6e030a3b606f1afcc7f2e2459ffda844 https://github.com/illumos/illumos-gate/commit/411be58a6e030a3b606f1afcc7f2e2459ffda844 MFC after: 24 days X-MFC with: r318823 Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:49:21 2017 (r318823) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Wed May 24 21:52:20 2017 (r318824) @@ -336,7 +336,6 @@ dmu_tx_hold_free_impl(dmu_tx_hold_t *txh dmu_tx_t *tx; dnode_t *dn; int err; - zio_t *zio; tx = txh->txh_tx; ASSERT(tx->tx_txg == 0); @@ -444,7 +443,7 @@ dmu_tx_hold_free_by_dnode(dmu_tx_t *tx, } static void -dmu_tx_hold_zap_impl(dmu_tx_hold_t *txh, int add, const char *name) +dmu_tx_hold_zap_impl(dmu_tx_hold_t *txh, const char *name) { dmu_tx_t *tx = txh->txh_tx; dnode_t *dn; @@ -505,7 +504,7 @@ dmu_tx_hold_zap(dmu_tx_t *tx, uint64_t o txh = dmu_tx_hold_object_impl(tx, tx->tx_objset, object, THT_ZAP, add, (uintptr_t)name); if (txh != NULL) - dmu_tx_hold_zap_impl(txh, add, name); + dmu_tx_hold_zap_impl(txh, name); } void @@ -518,7 +517,7 @@ dmu_tx_hold_zap_by_dnode(dmu_tx_t *tx, d txh = dmu_tx_hold_dnode_impl(tx, dn, THT_ZAP, add, (uintptr_t)name); if (txh != NULL) - dmu_tx_hold_zap_impl(txh, add, name); + dmu_tx_hold_zap_impl(txh, name); } void From owner-svn-src-head@freebsd.org Wed May 24 22:15:18 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33D37D80ABE; Wed, 24 May 2017 22:15:18 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 10A831CFE; Wed, 24 May 2017 22:15:17 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMFHFa049318; Wed, 24 May 2017 22:15:17 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMFG8d049313; Wed, 24 May 2017 22:15:16 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242215.v4OMFG8d049313@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:15:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318827 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 22:15:18 -0000 Author: avg Date: Wed May 24 22:15:16 2017 New Revision: 318827 URL: https://svnweb.freebsd.org/changeset/base/318827 Log: MFV r316916: 7970 zfs_arc_num_sublists_per_state should be common to all multilists illumos/illumos-gate@10fbdecb05f411234920f8d3c92c148d39106d7e https://github.com/illumos/illumos-gate/commit/10fbdecb05f411234920f8d3c92c148d39106d7e https://www.illumos.org/issues/7970 The global tunable zfs_arc_num_sublists_per_state is used by the ARC and the dbuf cache, and other users are planned. We should change this tunable to be common to all multilists. Reviewed by: Pavel Zakharov Reviewed by: Brad Lewis Reviewed by: Saso Kiselkov Reviewed by: Brian Behlendorf Approved by: Dan McDonald Author: Matthew Ahrens MFC after: 3 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/arc.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed May 24 21:54:04 2017 (r318826) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed May 24 22:15:16 2017 (r318827) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012, Joyent, Inc. All rights reserved. - * Copyright (c) 2011, 2016 by Delphix. All rights reserved. + * Copyright (c) 2011, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 by Saso Kiselkov. All rights reserved. * Copyright 2015 Nexenta Systems, Inc. All rights reserved. */ @@ -304,13 +304,6 @@ uint_t arc_reduce_dnlc_percent = 3; */ int zfs_arc_evict_batch_limit = 10; -/* - * The number of sublists used for each of the arc state lists. If this - * is not set to a suitable value by the user, it will be configured to - * the number of CPUs on the system in arc_init(). - */ -int zfs_arc_num_sublists_per_state = 0; - /* number of seconds before growing cache again */ static int arc_grow_retry = 60; @@ -6219,43 +6212,43 @@ arc_state_init(void) multilist_create(&arc_mru->arcs_list[ARC_BUFC_METADATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mru->arcs_list[ARC_BUFC_DATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mru_ghost->arcs_list[ARC_BUFC_METADATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mru_ghost->arcs_list[ARC_BUFC_DATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mfu->arcs_list[ARC_BUFC_METADATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mfu->arcs_list[ARC_BUFC_DATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mfu_ghost->arcs_list[ARC_BUFC_METADATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_mfu_ghost->arcs_list[ARC_BUFC_DATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_l2c_only->arcs_list[ARC_BUFC_METADATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); multilist_create(&arc_l2c_only->arcs_list[ARC_BUFC_DATA], sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), - zfs_arc_num_sublists_per_state, arc_state_multilist_index_func); + arc_state_multilist_index_func); refcount_create(&arc_anon->arcs_esize[ARC_BUFC_METADATA]); refcount_create(&arc_anon->arcs_esize[ARC_BUFC_DATA]); @@ -6412,9 +6405,6 @@ arc_init(void) if (zfs_arc_p_min_shift > 0) arc_p_min_shift = zfs_arc_p_min_shift; - if (zfs_arc_num_sublists_per_state < 1) - zfs_arc_num_sublists_per_state = MAX(max_ncpus, 1); - /* if kmem_flags are set, lets try to use less memory */ if (kmem_debugging()) arc_c = arc_c / 2; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 21:54:04 2017 (r318826) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 22:15:16 2017 (r318827) @@ -623,7 +623,6 @@ retry: multilist_create(&dbuf_cache, sizeof (dmu_buf_impl_t), offsetof(dmu_buf_impl_t, db_cache_link), - zfs_arc_num_sublists_per_state, dbuf_cache_multilist_index_func); refcount_create(&dbuf_cache_size); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c Wed May 24 21:54:04 2017 (r318826) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c Wed May 24 22:15:16 2017 (r318827) @@ -13,7 +13,7 @@ * CDDL HEADER END */ /* - * Copyright (c) 2013, 2014 by Delphix. All rights reserved. + * Copyright (c) 2013, 2017 by Delphix. All rights reserved. */ #include @@ -23,6 +23,12 @@ #include /* + * This overrides the number of sublists in each multilist_t, which defaults + * to the number of CPUs in the system (see multilist_create()). + */ +int zfs_multilist_num_sublists = 0; + +/* * Given the object contained on the list, return a pointer to the * object's multilist_node_t structure it contains. */ @@ -59,9 +65,9 @@ multilist_d2l(multilist_t *ml, void *obj * requirement, but a general rule of thumb in order to garner the * best multi-threaded performance out of the data structure. */ -void -multilist_create(multilist_t *ml, size_t size, size_t offset, unsigned int num, - multilist_sublist_index_func_t *index_func) +static void +multilist_create_impl(multilist_t *ml, size_t size, size_t offset, + unsigned int num, multilist_sublist_index_func_t *index_func) { ASSERT3P(ml, !=, NULL); ASSERT3U(size, >, 0); @@ -86,6 +92,26 @@ multilist_create(multilist_t *ml, size_t } /* + * Initialize a new sublist, using the default number of sublists + * (the number of CPUs, or at least 4, or the tunable + * zfs_multilist_num_sublists). + */ +void +multilist_create(multilist_t *ml, size_t size, size_t offset, + multilist_sublist_index_func_t *index_func) +{ + int num_sublists; + + if (zfs_multilist_num_sublists > 0) { + num_sublists = zfs_multilist_num_sublists; + } else { + num_sublists = MAX(max_ncpus, 4); + } + + multilist_create_impl(ml, size, offset, num_sublists, index_func); +} + +/* * Destroy the given multilist object, and free up any memory it holds. */ void Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/arc.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/arc.h Wed May 24 21:54:04 2017 (r318826) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/arc.h Wed May 24 22:15:16 2017 (r318827) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. */ @@ -64,8 +64,6 @@ typedef void arc_done_func_t(zio_t *zio, arc_done_func_t arc_bcopy_func; arc_done_func_t arc_getbuf_func; -extern int zfs_arc_num_sublists_per_state; - typedef enum arc_flags { /* Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h Wed May 24 21:54:04 2017 (r318826) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h Wed May 24 22:15:16 2017 (r318827) @@ -13,7 +13,7 @@ * CDDL HEADER END */ /* - * Copyright (c) 2013, 2014 by Delphix. All rights reserved. + * Copyright (c) 2013, 2017 by Delphix. All rights reserved. */ #ifndef _SYS_MULTILIST_H @@ -73,7 +73,7 @@ struct multilist { }; void multilist_destroy(multilist_t *); -void multilist_create(multilist_t *, size_t, size_t, unsigned int, +void multilist_create(multilist_t *, size_t, size_t, multilist_sublist_index_func_t *); void multilist_insert(multilist_t *, void *); From owner-svn-src-head@freebsd.org Wed May 24 22:21:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A8F88D80C9C; Wed, 24 May 2017 22:21:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 720AB1085; Wed, 24 May 2017 22:21:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMLQZp052468; Wed, 24 May 2017 22:21:26 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMLPFi052453; Wed, 24 May 2017 22:21:25 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242221.v4OMLPFi052453@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:21:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318828 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 22:21:27 -0000 Author: avg Date: Wed May 24 22:21:24 2017 New Revision: 318828 URL: https://svnweb.freebsd.org/changeset/base/318828 Log: MFV r316917: 7968 multi-threaded spa_sync() illumos/illumos-gate@94c2d0eb22e9624151ee84a7edbf7178e1bf4087 https://github.com/illumos/illumos-gate/commit/94c2d0eb22e9624151ee84a7edbf7178e1bf4087 https://www.illumos.org/issues/7968 spa_sync() iterates over all the dirty dnodes and processes each of them by calling dnode_sync(). If there are many dirty dnodes (e.g. because we created or removed a lot of files), the single thread of spa_sync() calling dnode_sync() can become a bottleneck. Additionally, if many dnodes are dirtied concurrently in open context (e.g. due to concurrent file creation), the os_lock will experience lock contention via dnode_setdirty(). The solution is to track dirty dnodes on a multilist_t, and for spa_sync() to use separate threads to process each of the sublists in the multilist. On the concurrent file creation microbenchmark, the performance improvement from dnode_setdirty() is up to 7%. Additionally, the wall clock time spent in spa_sync() is reduced to 15%-40% of the single-threaded case. In terms of cost/ reward, once the other bottlenecks are addressed, fixing this bug will provide a medium-large performance gain and require a medium amount of effort to implement. Reviewed by: Pavel Zakharov Reviewed by: Brad Lewis Reviewed by: Saso Kiselkov Reviewed by: Brian Behlendorf Approved by: Dan McDonald Author: Matthew Ahrens MFC after: 3 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode_sync.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_objset.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dnode.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_pool.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Wed May 24 22:21:24 2017 (r318828) @@ -473,7 +473,7 @@ typedef struct arc_state { /* * list of evictable buffers */ - multilist_t arcs_list[ARC_BUFC_NUMTYPES]; + multilist_t *arcs_list[ARC_BUFC_NUMTYPES]; /* * total amount of evictable data in this state */ @@ -2359,7 +2359,7 @@ add_reference(arc_buf_hdr_t *hdr, void * (state != arc_anon)) { /* We don't use the L2-only state list. */ if (state != arc_l2c_only) { - multilist_remove(&state->arcs_list[arc_buf_type(hdr)], + multilist_remove(state->arcs_list[arc_buf_type(hdr)], hdr); arc_evictable_space_decrement(hdr, state); } @@ -2389,7 +2389,7 @@ remove_reference(arc_buf_hdr_t *hdr, kmu */ if (((cnt = refcount_remove(&hdr->b_l1hdr.b_refcnt, tag)) == 0) && (state != arc_anon)) { - multilist_insert(&state->arcs_list[arc_buf_type(hdr)], hdr); + multilist_insert(state->arcs_list[arc_buf_type(hdr)], hdr); ASSERT3U(hdr->b_l1hdr.b_bufcnt, >, 0); arc_evictable_space_increment(hdr, state); } @@ -2442,7 +2442,7 @@ arc_change_state(arc_state_t *new_state, if (refcnt == 0) { if (old_state != arc_anon && old_state != arc_l2c_only) { ASSERT(HDR_HAS_L1HDR(hdr)); - multilist_remove(&old_state->arcs_list[buftype], hdr); + multilist_remove(old_state->arcs_list[buftype], hdr); if (GHOST_STATE(old_state)) { ASSERT0(bufcnt); @@ -2460,7 +2460,7 @@ arc_change_state(arc_state_t *new_state, * beforehand. */ ASSERT(HDR_HAS_L1HDR(hdr)); - multilist_insert(&new_state->arcs_list[buftype], hdr); + multilist_insert(new_state->arcs_list[buftype], hdr); if (GHOST_STATE(new_state)) { ASSERT0(bufcnt); @@ -2586,8 +2586,8 @@ arc_change_state(arc_state_t *new_state, * L2 headers should never be on the L2 state list since they don't * have L1 headers allocated. */ - ASSERT(multilist_is_empty(&arc_l2c_only->arcs_list[ARC_BUFC_DATA]) && - multilist_is_empty(&arc_l2c_only->arcs_list[ARC_BUFC_METADATA])); + ASSERT(multilist_is_empty(arc_l2c_only->arcs_list[ARC_BUFC_DATA]) && + multilist_is_empty(arc_l2c_only->arcs_list[ARC_BUFC_METADATA])); } void @@ -3671,7 +3671,7 @@ arc_evict_state(arc_state_t *state, uint arc_buf_contents_t type) { uint64_t total_evicted = 0; - multilist_t *ml = &state->arcs_list[type]; + multilist_t *ml = state->arcs_list[type]; int num_sublists; arc_buf_hdr_t **markers; @@ -3875,8 +3875,8 @@ arc_adjust_meta(void) static arc_buf_contents_t arc_adjust_type(arc_state_t *state) { - multilist_t *data_ml = &state->arcs_list[ARC_BUFC_DATA]; - multilist_t *meta_ml = &state->arcs_list[ARC_BUFC_METADATA]; + multilist_t *data_ml = state->arcs_list[ARC_BUFC_DATA]; + multilist_t *meta_ml = state->arcs_list[ARC_BUFC_METADATA]; int data_idx = multilist_get_random_index(data_ml); int meta_idx = multilist_get_random_index(meta_ml); multilist_sublist_t *data_mls; @@ -6209,44 +6209,44 @@ arc_state_init(void) arc_mfu_ghost = &ARC_mfu_ghost; arc_l2c_only = &ARC_l2c_only; - multilist_create(&arc_mru->arcs_list[ARC_BUFC_METADATA], - sizeof (arc_buf_hdr_t), + arc_mru->arcs_list[ARC_BUFC_METADATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mru->arcs_list[ARC_BUFC_DATA], - sizeof (arc_buf_hdr_t), + arc_mru->arcs_list[ARC_BUFC_DATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mru_ghost->arcs_list[ARC_BUFC_METADATA], - sizeof (arc_buf_hdr_t), + arc_mru_ghost->arcs_list[ARC_BUFC_METADATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mru_ghost->arcs_list[ARC_BUFC_DATA], - sizeof (arc_buf_hdr_t), + arc_mru_ghost->arcs_list[ARC_BUFC_DATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mfu->arcs_list[ARC_BUFC_METADATA], - sizeof (arc_buf_hdr_t), + arc_mfu->arcs_list[ARC_BUFC_METADATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mfu->arcs_list[ARC_BUFC_DATA], - sizeof (arc_buf_hdr_t), + arc_mfu->arcs_list[ARC_BUFC_DATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mfu_ghost->arcs_list[ARC_BUFC_METADATA], - sizeof (arc_buf_hdr_t), + arc_mfu_ghost->arcs_list[ARC_BUFC_METADATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_mfu_ghost->arcs_list[ARC_BUFC_DATA], - sizeof (arc_buf_hdr_t), + arc_mfu_ghost->arcs_list[ARC_BUFC_DATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_l2c_only->arcs_list[ARC_BUFC_METADATA], - sizeof (arc_buf_hdr_t), + arc_l2c_only->arcs_list[ARC_BUFC_METADATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); - multilist_create(&arc_l2c_only->arcs_list[ARC_BUFC_DATA], - sizeof (arc_buf_hdr_t), + arc_l2c_only->arcs_list[ARC_BUFC_DATA] = + multilist_create(sizeof (arc_buf_hdr_t), offsetof(arc_buf_hdr_t, b_l1hdr.b_arc_node), arc_state_multilist_index_func); @@ -6294,14 +6294,14 @@ arc_state_fini(void) refcount_destroy(&arc_mfu_ghost->arcs_size); refcount_destroy(&arc_l2c_only->arcs_size); - multilist_destroy(&arc_mru->arcs_list[ARC_BUFC_METADATA]); - multilist_destroy(&arc_mru_ghost->arcs_list[ARC_BUFC_METADATA]); - multilist_destroy(&arc_mfu->arcs_list[ARC_BUFC_METADATA]); - multilist_destroy(&arc_mfu_ghost->arcs_list[ARC_BUFC_METADATA]); - multilist_destroy(&arc_mru->arcs_list[ARC_BUFC_DATA]); - multilist_destroy(&arc_mru_ghost->arcs_list[ARC_BUFC_DATA]); - multilist_destroy(&arc_mfu->arcs_list[ARC_BUFC_DATA]); - multilist_destroy(&arc_mfu_ghost->arcs_list[ARC_BUFC_DATA]); + multilist_destroy(arc_mru->arcs_list[ARC_BUFC_METADATA]); + multilist_destroy(arc_mru_ghost->arcs_list[ARC_BUFC_METADATA]); + multilist_destroy(arc_mfu->arcs_list[ARC_BUFC_METADATA]); + multilist_destroy(arc_mfu_ghost->arcs_list[ARC_BUFC_METADATA]); + multilist_destroy(arc_mru->arcs_list[ARC_BUFC_DATA]); + multilist_destroy(arc_mru_ghost->arcs_list[ARC_BUFC_DATA]); + multilist_destroy(arc_mfu->arcs_list[ARC_BUFC_DATA]); + multilist_destroy(arc_mfu_ghost->arcs_list[ARC_BUFC_DATA]); } uint64_t @@ -7098,16 +7098,16 @@ l2arc_sublist_lock(int list_num) switch (list_num) { case 0: - ml = &arc_mfu->arcs_list[ARC_BUFC_METADATA]; + ml = arc_mfu->arcs_list[ARC_BUFC_METADATA]; break; case 1: - ml = &arc_mru->arcs_list[ARC_BUFC_METADATA]; + ml = arc_mru->arcs_list[ARC_BUFC_METADATA]; break; case 2: - ml = &arc_mfu->arcs_list[ARC_BUFC_DATA]; + ml = arc_mfu->arcs_list[ARC_BUFC_DATA]; break; case 3: - ml = &arc_mru->arcs_list[ARC_BUFC_DATA]; + ml = arc_mru->arcs_list[ARC_BUFC_DATA]; break; } Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 22:21:24 2017 (r318828) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2011 Nexenta Systems, Inc. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. * Copyright (c) 2013, Joyent, Inc. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. @@ -80,7 +80,7 @@ static boolean_t dbuf_evict_thread_exit; * Dbufs that are aged out of the cache will be immediately destroyed and * become eligible for arc eviction. */ -static multilist_t dbuf_cache; +static multilist_t *dbuf_cache; static refcount_t dbuf_cache_size; uint64_t dbuf_cache_max_bytes = 100 * 1024 * 1024; @@ -454,8 +454,8 @@ dbuf_cache_above_lowater(void) static void dbuf_evict_one(void) { - int idx = multilist_get_random_index(&dbuf_cache); - multilist_sublist_t *mls = multilist_sublist_lock(&dbuf_cache, idx); + int idx = multilist_get_random_index(dbuf_cache); + multilist_sublist_t *mls = multilist_sublist_lock(dbuf_cache, idx); ASSERT(!MUTEX_HELD(&dbuf_evict_lock)); @@ -621,7 +621,7 @@ retry: */ dbu_evict_taskq = taskq_create("dbu_evict", 1, minclsyspri, 0, 0, 0); - multilist_create(&dbuf_cache, sizeof (dmu_buf_impl_t), + dbuf_cache = multilist_create(sizeof (dmu_buf_impl_t), offsetof(dmu_buf_impl_t, db_cache_link), dbuf_cache_multilist_index_func); refcount_create(&dbuf_cache_size); @@ -659,7 +659,7 @@ dbuf_fini(void) cv_destroy(&dbuf_evict_cv); refcount_destroy(&dbuf_cache_size); - multilist_destroy(&dbuf_cache); + multilist_destroy(dbuf_cache); } /* @@ -2029,7 +2029,7 @@ dbuf_destroy(dmu_buf_impl_t *db) dbuf_clear_data(db); if (multilist_link_active(&db->db_cache_link)) { - multilist_remove(&dbuf_cache, db); + multilist_remove(dbuf_cache, db); (void) refcount_remove_many(&dbuf_cache_size, db->db.db_size, db); } @@ -2577,7 +2577,7 @@ top: if (multilist_link_active(&db->db_cache_link)) { ASSERT(refcount_is_zero(&db->db_holds)); - multilist_remove(&dbuf_cache, db); + multilist_remove(dbuf_cache, db); (void) refcount_remove_many(&dbuf_cache_size, db->db.db_size, db); } @@ -2796,7 +2796,7 @@ dbuf_rele_and_unlock(dmu_buf_impl_t *db, db->db_pending_evict) { dbuf_destroy(db); } else if (!multilist_link_active(&db->db_cache_link)) { - multilist_insert(&dbuf_cache, db); + multilist_insert(dbuf_cache, db); (void) refcount_add_many(&dbuf_cache_size, db->db.db_size, db); mutex_exit(&db->db_mtx); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_objset.c Wed May 24 22:21:24 2017 (r318828) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. * Copyright (c) 2013, Joyent, Inc. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. @@ -303,6 +303,42 @@ dmu_objset_byteswap(void *buf, size_t si } } +/* + * The hash is a CRC-based hash of the objset_t pointer and the object number. + */ +static uint64_t +dnode_hash(const objset_t *os, uint64_t obj) +{ + uintptr_t osv = (uintptr_t)os; + uint64_t crc = -1ULL; + + ASSERT(zfs_crc64_table[128] == ZFS_CRC64_POLY); + /* + * The low 6 bits of the pointer don't have much entropy, because + * the objset_t is larger than 2^6 bytes long. + */ + crc = (crc >> 8) ^ zfs_crc64_table[(crc ^ (osv >> 6)) & 0xFF]; + crc = (crc >> 8) ^ zfs_crc64_table[(crc ^ (obj >> 0)) & 0xFF]; + crc = (crc >> 8) ^ zfs_crc64_table[(crc ^ (obj >> 8)) & 0xFF]; + crc = (crc >> 8) ^ zfs_crc64_table[(crc ^ (obj >> 16)) & 0xFF]; + + crc ^= (osv>>14) ^ (obj>>24); + + return (crc); +} + +unsigned int +dnode_multilist_index_func(multilist_t *ml, void *obj) +{ + dnode_t *dn = obj; + return (dnode_hash(dn->dn_objset, dn->dn_object) % + multilist_get_num_sublists(ml)); +} + +/* + * Instantiates the objset_t in-memory structure corresponding to the + * objset_phys_t that's pointed to by the specified blkptr_t. + */ int dmu_objset_open_impl(spa_t *spa, dsl_dataset_t *ds, blkptr_t *bp, objset_t **osp) @@ -454,10 +490,9 @@ dmu_objset_open_impl(spa_t *spa, dsl_dat os->os_zil = zil_alloc(os, &os->os_zil_header); for (i = 0; i < TXG_SIZE; i++) { - list_create(&os->os_dirty_dnodes[i], sizeof (dnode_t), - offsetof(dnode_t, dn_dirty_link[i])); - list_create(&os->os_free_dnodes[i], sizeof (dnode_t), - offsetof(dnode_t, dn_dirty_link[i])); + os->os_dirty_dnodes[i] = multilist_create(sizeof (dnode_t), + offsetof(dnode_t, dn_dirty_link[i]), + dnode_multilist_index_func); } list_create(&os->os_dnodes, sizeof (dnode_t), offsetof(dnode_t, dn_link)); @@ -465,6 +500,7 @@ dmu_objset_open_impl(spa_t *spa, dsl_dat offsetof(dmu_buf_impl_t, db_link)); mutex_init(&os->os_lock, NULL, MUTEX_DEFAULT, NULL); + mutex_init(&os->os_userused_lock, NULL, MUTEX_DEFAULT, NULL); mutex_init(&os->os_obj_lock, NULL, MUTEX_DEFAULT, NULL); mutex_init(&os->os_user_ptr_lock, NULL, MUTEX_DEFAULT, NULL); @@ -748,8 +784,12 @@ dmu_objset_evict_done(objset_t *os) rw_exit(&os_lock); mutex_destroy(&os->os_lock); + mutex_destroy(&os->os_userused_lock); mutex_destroy(&os->os_obj_lock); mutex_destroy(&os->os_user_ptr_lock); + for (int i = 0; i < TXG_SIZE; i++) { + multilist_destroy(os->os_dirty_dnodes[i]); + } spa_evicting_os_deregister(os->os_spa, os); kmem_free(os, sizeof (objset_t)); } @@ -1027,11 +1067,11 @@ dmu_objset_snapshot_one(const char *fsna } static void -dmu_objset_sync_dnodes(list_t *list, list_t *newlist, dmu_tx_t *tx) +dmu_objset_sync_dnodes(multilist_sublist_t *list, dmu_tx_t *tx) { dnode_t *dn; - while (dn = list_head(list)) { + while ((dn = multilist_sublist_head(list)) != NULL) { ASSERT(dn->dn_object != DMU_META_DNODE_OBJECT); ASSERT(dn->dn_dbuf->db_data_pending); /* @@ -1042,11 +1082,12 @@ dmu_objset_sync_dnodes(list_t *list, lis ASSERT(dn->dn_zio); ASSERT3U(dn->dn_nlevels, <=, DN_MAX_LEVELS); - list_remove(list, dn); + multilist_sublist_remove(list, dn); - if (newlist) { + multilist_t *newlist = dn->dn_objset->os_synced_dnodes; + if (newlist != NULL) { (void) dnode_add_ref(dn, newlist); - list_insert_tail(newlist, dn); + multilist_insert(newlist, dn); } dnode_sync(dn, tx); @@ -1101,6 +1142,29 @@ dmu_objset_write_done(zio_t *zio, arc_bu kmem_free(bp, sizeof (*bp)); } +typedef struct sync_dnodes_arg { + multilist_t *sda_list; + int sda_sublist_idx; + multilist_t *sda_newlist; + dmu_tx_t *sda_tx; +} sync_dnodes_arg_t; + +static void +sync_dnodes_task(void *arg) +{ + sync_dnodes_arg_t *sda = arg; + + multilist_sublist_t *ms = + multilist_sublist_lock(sda->sda_list, sda->sda_sublist_idx); + + dmu_objset_sync_dnodes(ms, sda->sda_tx); + + multilist_sublist_unlock(ms); + + kmem_free(sda, sizeof (*sda)); +} + + /* called from dsl */ void dmu_objset_sync(objset_t *os, zio_t *pio, dmu_tx_t *tx) @@ -1110,7 +1174,6 @@ dmu_objset_sync(objset_t *os, zio_t *pio zio_prop_t zp; zio_t *zio; list_t *list; - list_t *newlist = NULL; dbuf_dirty_record_t *dr; blkptr_t *blkptr_copy = kmem_alloc(sizeof (*os->os_rootbp), KM_SLEEP); *blkptr_copy = *os->os_rootbp; @@ -1164,20 +1227,36 @@ dmu_objset_sync(objset_t *os, zio_t *pio txgoff = tx->tx_txg & TXG_MASK; if (dmu_objset_userused_enabled(os)) { - newlist = &os->os_synced_dnodes; /* * We must create the list here because it uses the - * dn_dirty_link[] of this txg. + * dn_dirty_link[] of this txg. But it may already + * exist because we call dsl_dataset_sync() twice per txg. */ - list_create(newlist, sizeof (dnode_t), - offsetof(dnode_t, dn_dirty_link[txgoff])); + if (os->os_synced_dnodes == NULL) { + os->os_synced_dnodes = + multilist_create(sizeof (dnode_t), + offsetof(dnode_t, dn_dirty_link[txgoff]), + dnode_multilist_index_func); + } else { + ASSERT3U(os->os_synced_dnodes->ml_offset, ==, + offsetof(dnode_t, dn_dirty_link[txgoff])); + } } - dmu_objset_sync_dnodes(&os->os_free_dnodes[txgoff], newlist, tx); - dmu_objset_sync_dnodes(&os->os_dirty_dnodes[txgoff], newlist, tx); + for (int i = 0; + i < multilist_get_num_sublists(os->os_dirty_dnodes[txgoff]); i++) { + sync_dnodes_arg_t *sda = kmem_alloc(sizeof (*sda), KM_SLEEP); + sda->sda_list = os->os_dirty_dnodes[txgoff]; + sda->sda_sublist_idx = i; + sda->sda_tx = tx; + (void) taskq_dispatch(dmu_objset_pool(os)->dp_sync_taskq, + sync_dnodes_task, sda, 0); + /* callback frees sda */ + } + taskq_wait(dmu_objset_pool(os)->dp_sync_taskq); list = &DMU_META_DNODE(os)->dn_dirty_records[txgoff]; - while (dr = list_head(list)) { + while ((dr = list_head(list)) != NULL) { ASSERT0(dr->dr_dbuf->db_level); list_remove(list, dr); if (dr->dr_zio) @@ -1201,8 +1280,7 @@ dmu_objset_sync(objset_t *os, zio_t *pio boolean_t dmu_objset_is_dirty(objset_t *os, uint64_t txg) { - return (!list_is_empty(&os->os_dirty_dnodes[txg & TXG_MASK]) || - !list_is_empty(&os->os_free_dnodes[txg & TXG_MASK])); + return (!multilist_is_empty(os->os_dirty_dnodes[txg & TXG_MASK])); } static objset_used_cb_t *used_cbs[DMU_OST_NUMTYPES]; @@ -1256,8 +1334,15 @@ do_userquota_cacheflush(objset_t *os, us cookie = NULL; while ((uqn = avl_destroy_nodes(&cache->uqc_user_deltas, &cookie)) != NULL) { + /* + * os_userused_lock protects against concurrent calls to + * zap_increment_int(). It's needed because zap_increment_int() + * is not thread-safe (i.e. not atomic). + */ + mutex_enter(&os->os_userused_lock); VERIFY0(zap_increment_int(os, DMU_USERUSED_OBJECT, uqn->uqn_id, uqn->uqn_delta, tx)); + mutex_exit(&os->os_userused_lock); kmem_free(uqn, sizeof (*uqn)); } avl_destroy(&cache->uqc_user_deltas); @@ -1265,8 +1350,10 @@ do_userquota_cacheflush(objset_t *os, us cookie = NULL; while ((uqn = avl_destroy_nodes(&cache->uqc_group_deltas, &cookie)) != NULL) { + mutex_enter(&os->os_userused_lock); VERIFY0(zap_increment_int(os, DMU_GROUPUSED_OBJECT, uqn->uqn_id, uqn->uqn_delta, tx)); + mutex_exit(&os->os_userused_lock); kmem_free(uqn, sizeof (*uqn)); } avl_destroy(&cache->uqc_group_deltas); @@ -1301,37 +1388,38 @@ do_userquota_update(userquota_cache_t *c } } -void -dmu_objset_do_userquota_updates(objset_t *os, dmu_tx_t *tx) +typedef struct userquota_updates_arg { + objset_t *uua_os; + int uua_sublist_idx; + dmu_tx_t *uua_tx; +} userquota_updates_arg_t; + +static void +userquota_updates_task(void *arg) { + userquota_updates_arg_t *uua = arg; + objset_t *os = uua->uua_os; + dmu_tx_t *tx = uua->uua_tx; dnode_t *dn; - list_t *list = &os->os_synced_dnodes; userquota_cache_t cache = { 0 }; - ASSERT(list_head(list) == NULL || dmu_objset_userused_enabled(os)); + multilist_sublist_t *list = + multilist_sublist_lock(os->os_synced_dnodes, uua->uua_sublist_idx); + ASSERT(multilist_sublist_head(list) == NULL || + dmu_objset_userused_enabled(os)); avl_create(&cache.uqc_user_deltas, userquota_compare, sizeof (userquota_node_t), offsetof(userquota_node_t, uqn_node)); avl_create(&cache.uqc_group_deltas, userquota_compare, sizeof (userquota_node_t), offsetof(userquota_node_t, uqn_node)); - while (dn = list_head(list)) { + while ((dn = multilist_sublist_head(list)) != NULL) { int flags; ASSERT(!DMU_OBJECT_IS_SPECIAL(dn->dn_object)); ASSERT(dn->dn_phys->dn_type == DMU_OT_NONE || dn->dn_phys->dn_flags & DNODE_FLAG_USERUSED_ACCOUNTED); - /* Allocate the user/groupused objects if necessary. */ - if (DMU_USERUSED_DNODE(os)->dn_type == DMU_OT_NONE) { - VERIFY0(zap_create_claim(os, - DMU_USERUSED_OBJECT, - DMU_OT_USERGROUP_USED, DMU_OT_NONE, 0, tx)); - VERIFY0(zap_create_claim(os, - DMU_GROUPUSED_OBJECT, - DMU_OT_USERGROUP_USED, DMU_OT_NONE, 0, tx)); - } - flags = dn->dn_id_flags; ASSERT(flags); if (flags & DN_ID_OLD_EXIST) { @@ -1361,10 +1449,42 @@ dmu_objset_do_userquota_updates(objset_t dn->dn_id_flags &= ~(DN_ID_NEW_EXIST); mutex_exit(&dn->dn_mtx); - list_remove(list, dn); - dnode_rele(dn, list); + multilist_sublist_remove(list, dn); + dnode_rele(dn, os->os_synced_dnodes); } do_userquota_cacheflush(os, &cache, tx); + multilist_sublist_unlock(list); + kmem_free(uua, sizeof (*uua)); +} + +void +dmu_objset_do_userquota_updates(objset_t *os, dmu_tx_t *tx) +{ + if (!dmu_objset_userused_enabled(os)) + return; + + /* Allocate the user/groupused objects if necessary. */ + if (DMU_USERUSED_DNODE(os)->dn_type == DMU_OT_NONE) { + VERIFY0(zap_create_claim(os, + DMU_USERUSED_OBJECT, + DMU_OT_USERGROUP_USED, DMU_OT_NONE, 0, tx)); + VERIFY0(zap_create_claim(os, + DMU_GROUPUSED_OBJECT, + DMU_OT_USERGROUP_USED, DMU_OT_NONE, 0, tx)); + } + + for (int i = 0; + i < multilist_get_num_sublists(os->os_synced_dnodes); i++) { + userquota_updates_arg_t *uua = + kmem_alloc(sizeof (*uua), KM_SLEEP); + uua->uua_os = os; + uua->uua_sublist_idx = i; + uua->uua_tx = tx; + /* note: caller does taskq_wait() */ + (void) taskq_dispatch(dmu_objset_pool(os)->dp_sync_taskq, + userquota_updates_task, uua, 0); + /* callback frees uua */ + } } /* Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode.c Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -1287,13 +1287,14 @@ dnode_setdirty(dnode_t *dn, dmu_tx_t *tx */ dmu_objset_userquota_get_ids(dn, B_TRUE, tx); - mutex_enter(&os->os_lock); + multilist_t *dirtylist = os->os_dirty_dnodes[txg & TXG_MASK]; + multilist_sublist_t *mls = multilist_sublist_lock_obj(dirtylist, dn); /* * If we are already marked dirty, we're done. */ if (list_link_active(&dn->dn_dirty_link[txg & TXG_MASK])) { - mutex_exit(&os->os_lock); + multilist_sublist_unlock(mls); return; } @@ -1307,13 +1308,9 @@ dnode_setdirty(dnode_t *dn, dmu_tx_t *tx dprintf_ds(os->os_dsl_dataset, "obj=%llu txg=%llu\n", dn->dn_object, txg); - if (dn->dn_free_txg > 0 && dn->dn_free_txg <= txg) { - list_insert_tail(&os->os_free_dnodes[txg&TXG_MASK], dn); - } else { - list_insert_tail(&os->os_dirty_dnodes[txg&TXG_MASK], dn); - } + multilist_sublist_insert_head(mls, dn); - mutex_exit(&os->os_lock); + multilist_sublist_unlock(mls); /* * The dnode maintains a hold on its containing dbuf as @@ -1334,13 +1331,6 @@ dnode_setdirty(dnode_t *dn, dmu_tx_t *tx void dnode_free(dnode_t *dn, dmu_tx_t *tx) { - int txgoff = tx->tx_txg & TXG_MASK; - - dprintf("dn=%p txg=%llu\n", dn, tx->tx_txg); - - /* we should be the only holder... hopefully */ - /* ASSERT3U(refcount_count(&dn->dn_holds), ==, 1); */ - mutex_enter(&dn->dn_mtx); if (dn->dn_type == DMU_OT_NONE || dn->dn_free_txg) { mutex_exit(&dn->dn_mtx); @@ -1349,19 +1339,7 @@ dnode_free(dnode_t *dn, dmu_tx_t *tx) dn->dn_free_txg = tx->tx_txg; mutex_exit(&dn->dn_mtx); - /* - * If the dnode is already dirty, it needs to be moved from - * the dirty list to the free list. - */ - mutex_enter(&dn->dn_objset->os_lock); - if (list_link_active(&dn->dn_dirty_link[txgoff])) { - list_remove(&dn->dn_objset->os_dirty_dnodes[txgoff], dn); - list_insert_tail(&dn->dn_objset->os_free_dnodes[txgoff], dn); - mutex_exit(&dn->dn_objset->os_lock); - } else { - mutex_exit(&dn->dn_objset->os_lock); - dnode_setdirty(dn, tx); - } + dnode_setdirty(dn, tx); } /* Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode_sync.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode_sync.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dnode_sync.c Wed May 24 22:21:24 2017 (r318828) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. */ Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_dataset.c Wed May 24 22:21:24 2017 (r318828) @@ -1740,6 +1740,11 @@ dsl_dataset_sync_done(dsl_dataset_t *ds, bplist_iterate(&ds->ds_pending_deadlist, deadlist_enqueue_cb, &ds->ds_deadlist, tx); + if (os->os_synced_dnodes != NULL) { + multilist_destroy(os->os_synced_dnodes); + os->os_synced_dnodes = NULL; + } + ASSERT(!dmu_objset_is_dirty(os, dmu_tx_get_txg(tx))); dmu_buf_rele(ds->ds_dbuf, ds); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2011, 2016 by Delphix. All rights reserved. + * Copyright (c) 2011, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 Steven Hartland. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] @@ -132,6 +132,10 @@ int zfs_delay_min_dirty_percent = 60; */ uint64_t zfs_delay_scale = 1000 * 1000 * 1000 / 2000; +/* + * This determines the number of threads used by the dp_sync_taskq. + */ +int zfs_sync_taskq_batch_pct = 75; #if defined(__FreeBSD__) && defined(_KERNEL) @@ -267,6 +271,10 @@ dsl_pool_open_impl(spa_t *spa, uint64_t txg_list_create(&dp->dp_sync_tasks, offsetof(dsl_sync_task_t, dst_node)); + dp->dp_sync_taskq = taskq_create("dp_sync_taskq", + zfs_sync_taskq_batch_pct, minclsyspri, 1, INT_MAX, + TASKQ_THREADS_CPU_PCT); + mutex_init(&dp->dp_lock, NULL, MUTEX_DEFAULT, NULL); cv_init(&dp->dp_spaceavail_cv, NULL, CV_DEFAULT, NULL); @@ -417,6 +425,8 @@ dsl_pool_close(dsl_pool_t *dp) txg_list_destroy(&dp->dp_sync_tasks); txg_list_destroy(&dp->dp_dirty_dirs); + taskq_destroy(dp->dp_sync_taskq); + /* * We can't set retry to TRUE since we're explicitly specifying * a spa to flush. This is good enough; any missed buffers for @@ -605,12 +615,15 @@ dsl_pool_sync(dsl_pool_t *dp, uint64_t t /* * After the data blocks have been written (ensured by the zio_wait() - * above), update the user/group space accounting. + * above), update the user/group space accounting. This happens + * in tasks dispatched to dp_sync_taskq, so wait for them before + * continuing. */ for (ds = list_head(&synced_datasets); ds != NULL; ds = list_next(&synced_datasets, ds)) { dmu_objset_do_userquota_updates(ds->ds_objset, tx); } + taskq_wait(dp->dp_sync_taskq); /* * Sync the datasets again to push out the changes due to @@ -657,8 +670,7 @@ dsl_pool_sync(dsl_pool_t *dp, uint64_t t dp->dp_mos_uncompressed_delta = 0; } - if (list_head(&mos->os_dirty_dnodes[txg & TXG_MASK]) != NULL || - list_head(&mos->os_free_dnodes[txg & TXG_MASK]) != NULL) { + if (!multilist_is_empty(mos->os_dirty_dnodes[txg & TXG_MASK])) { dsl_pool_sync_mos(dp, tx); } @@ -716,7 +728,8 @@ int dsl_pool_sync_context(dsl_pool_t *dp) { return (curthread == dp->dp_tx.tx_sync_thread || - spa_is_initializing(dp->dp_spa)); + spa_is_initializing(dp->dp_spa) || + taskq_member(dp->dp_sync_taskq, curthread)); } uint64_t Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/multilist.c Wed May 24 22:21:24 2017 (r318828) @@ -65,16 +65,16 @@ multilist_d2l(multilist_t *ml, void *obj * requirement, but a general rule of thumb in order to garner the * best multi-threaded performance out of the data structure. */ -static void -multilist_create_impl(multilist_t *ml, size_t size, size_t offset, +static multilist_t * +multilist_create_impl(size_t size, size_t offset, unsigned int num, multilist_sublist_index_func_t *index_func) { - ASSERT3P(ml, !=, NULL); ASSERT3U(size, >, 0); ASSERT3U(size, >=, offset + sizeof (multilist_node_t)); ASSERT3U(num, >, 0); ASSERT3P(index_func, !=, NULL); + multilist_t *ml = kmem_alloc(sizeof (*ml), KM_SLEEP); ml->ml_offset = offset; ml->ml_num_sublists = num; ml->ml_index_func = index_func; @@ -89,15 +89,16 @@ multilist_create_impl(multilist_t *ml, s mutex_init(&mls->mls_lock, NULL, MUTEX_DEFAULT, NULL); list_create(&mls->mls_list, size, offset); } + return (ml); } /* - * Initialize a new sublist, using the default number of sublists + * Allocate a new multilist, using the default number of sublists * (the number of CPUs, or at least 4, or the tunable * zfs_multilist_num_sublists). */ -void -multilist_create(multilist_t *ml, size_t size, size_t offset, +multilist_t * +multilist_create(size_t size, size_t offset, multilist_sublist_index_func_t *index_func) { int num_sublists; @@ -108,7 +109,7 @@ multilist_create(multilist_t *ml, size_t num_sublists = MAX(max_ncpus, 4); } - multilist_create_impl(ml, size, offset, num_sublists, index_func); + return (multilist_create_impl(size, offset, num_sublists, index_func)); } /* @@ -134,6 +135,7 @@ multilist_destroy(multilist_t *ml) ml->ml_num_sublists = 0; ml->ml_offset = 0; + kmem_free(ml, sizeof (multilist_t)); } /* @@ -285,6 +287,13 @@ multilist_sublist_lock(multilist_t *ml, return (mls); } +/* Lock and return the sublist that would be used to store the specified obj */ +multilist_sublist_t * +multilist_sublist_lock_obj(multilist_t *ml, void *obj) +{ + return (multilist_sublist_lock(ml, ml->ml_index_func(ml, obj))); +} + void multilist_sublist_unlock(multilist_sublist_t *mls) { Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2011, 2015 by Delphix. All rights reserved. + * Copyright (c) 2011, 2017 by Delphix. All rights reserved. * Copyright 2015 Nexenta Systems, Inc. All rights reserved. * Copyright 2013 Martin Matuska . All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. @@ -740,7 +740,7 @@ spa_add(const char *name, nvlist_t *conf spa_active_count++; } - avl_create(&spa->spa_alloc_tree, zio_timestamp_compare, + avl_create(&spa->spa_alloc_tree, zio_bookmark_compare, sizeof (zio_t), offsetof(zio_t, io_alloc_node)); /* Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_objset.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_objset.h Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dmu_objset.h Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] @@ -110,7 +110,7 @@ struct objset { /* no lock needed: */ struct dmu_tx *os_synctx; /* XXX sketchy */ zil_header_t os_zil_header; - list_t os_synced_dnodes; + multilist_t *os_synced_dnodes; uint64_t os_flags; uint64_t os_freed_dnodes; boolean_t os_rescan_dnodes; @@ -121,11 +121,13 @@ struct objset { /* Protected by os_lock */ kmutex_t os_lock; - list_t os_dirty_dnodes[TXG_SIZE]; - list_t os_free_dnodes[TXG_SIZE]; + multilist_t *os_dirty_dnodes[TXG_SIZE]; list_t os_dnodes; list_t os_downgraded_dbufs; + /* Protects changes to DMU_{USER,GROUP}USED_OBJECT */ + kmutex_t os_userused_lock; + /* stuff we store for the user */ kmutex_t os_user_ptr_lock; void *os_user_ptr; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dnode.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dnode.h Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dnode.h Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. */ @@ -35,6 +35,7 @@ #include #include #include +#include #ifdef __cplusplus extern "C" { @@ -203,7 +204,7 @@ struct dnode { uint32_t dn_dbufs_count; /* count of dn_dbufs */ /* protected by os_lock: */ - list_node_t dn_dirty_link[TXG_SIZE]; /* next on dataset's dirty */ + multilist_node_t dn_dirty_link[TXG_SIZE]; /* next on dataset's dirty */ /* protected by dn_mtx: */ kmutex_t dn_mtx; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_pool.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_pool.h Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/dsl_pool.h Wed May 24 22:21:24 2017 (r318828) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2013 by Delphix. All rights reserved. + * Copyright (c) 2013, 2017 by Delphix. All rights reserved. * Copyright 2016 Nexenta Systems, Inc. All rights reserved. */ @@ -121,6 +121,7 @@ typedef struct dsl_pool { txg_list_t dp_dirty_zilogs; txg_list_t dp_dirty_dirs; txg_list_t dp_sync_tasks; + taskq_t *dp_sync_taskq; /* * Protects administrative changes (properties, namespace) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/multilist.h Wed May 24 22:21:24 2017 (r318828) @@ -73,8 +73,7 @@ struct multilist { }; void multilist_destroy(multilist_t *); -void multilist_create(multilist_t *, size_t, size_t, - multilist_sublist_index_func_t *); +multilist_t *multilist_create(size_t, size_t, multilist_sublist_index_func_t *); void multilist_insert(multilist_t *, void *); void multilist_remove(multilist_t *, void *); @@ -84,6 +83,7 @@ unsigned int multilist_get_num_sublists( unsigned int multilist_get_random_index(multilist_t *); multilist_sublist_t *multilist_sublist_lock(multilist_t *, unsigned int); +multilist_sublist_t *multilist_sublist_lock_obj(multilist_t *, void *); void multilist_sublist_unlock(multilist_sublist_t *); void multilist_sublist_insert_head(multilist_sublist_t *, void *); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h Wed May 24 22:15:16 2017 (r318827) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zio.h Wed May 24 22:21:24 2017 (r318828) @@ -22,7 +22,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2011 Nexenta Systems, Inc. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2013 by Saso Kiselkov. All rights reserved. * Copyright 2016 Toomas Soome */ @@ -485,7 +485,7 @@ struct zio { list_node_t io_trim_link; }; -extern int zio_timestamp_compare(const void *, const void *); +extern int zio_bookmark_compare(const void *, const void *); extern zio_t *zio_null(zio_t *pio, spa_t *spa, vdev_t *vd, zio_done_func_t *done, void *priv, enum zio_flag flags); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zio.c Wed May 24 22:15:16 2017 (r318827) *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Wed May 24 22:25:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 42B03D80D80; Wed, 24 May 2017 22:25:28 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 05E951453; Wed, 24 May 2017 22:25:27 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMPRGT053468; Wed, 24 May 2017 22:25:27 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMPQpk053463; Wed, 24 May 2017 22:25:26 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242225.v4OMPQpk053463@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:25:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318829 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 24 May 2017 22:25:28 -0000 Author: avg Date: Wed May 24 22:25:26 2017 New Revision: 318829 URL: https://svnweb.freebsd.org/changeset/base/318829 Log: MFV r316920: 8023 Panic destroying a metaslab deferred range tree illumos/illumos-gate@3991b535a8e990c0369be677746a87c259b13e9f https://github.com/illumos/illumos-gate/commit/3991b535a8e990c0369be677746a87c259b13e9f https://www.illumos.org/issues/8023 $C ffffff0011bc0970 vpanic() ffffff0011bc0a00 strlog() ffffff0011bc0a30 range_tree_destroy+0x72(ffffff043769ad00) ffffff0011bc0a70 metaslab_fini+0xd5(ffffff0449acf380) ffffff0011bc0ab0 vdev_metaslab_fini+0x56(ffffff0462bae800) ffffff0011bc0af0 spa_unload+0x9b(ffffff03e3dac000) ffffff0011bc0b70 spa_export_common+0x115(ffffff047f4b4000, 2, 0, 0, 0) ffffff0011bc0b90 spa_destroy+0x1d(ffffff047f4b4000) ffffff0011bc0bd0 zfs_ioc_pool_destroy+0x20(ffffff047f4b4000) ffffff0011bc0c80 zfsdev_ioctl+0x4d7(11400000000, 5a01, 8040190, 100003, ffffff03e1956b10, ffffff0011bc0e68) ffffff0011bc0cc0 cdev_ioctl+0x39(11400000000, 5a01, 8040190, 100003, ffffff03e1956b10, ffffff0011bc0e68) ffffff0011bc0d10 spec_ioctl+0x60(ffffff03d9153b00, 5a01, 8040190, 100003, ffffff03e1956b10, ffffff0011bc0e68, 0) ffffff0011bc0da0 fop_ioctl+0x55(ffffff03d9153b00, 5a01, 8040190, 100003, ffffff03e1956b10, ffffff0011bc0e68, 0) ffffff0011bc0ec0 ioctl+0x9b(3, 5a01, 8040190) ffffff0011bc0f10 _sys_sysenter_post_swapgs+0x149() Reviewed by: Brad Lewis Reviewed by: Matt Ahrens Reviewed by: Dan Kimmel Reviewed by: Saso Kiselkov Approved by: Dan McDonald Author: George Wilson MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/metaslab.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/space_map.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa.h Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 22:21:24 2017 (r318828) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Wed May 24 22:25:26 2017 (r318829) @@ -1552,6 +1552,7 @@ dbuf_dirty(dmu_buf_impl_t *db, dmu_tx_t * this assertion only if we're not already dirty. */ os = dn->dn_objset; + VERIFY3U(tx->tx_txg, <=, spa_final_dirty_txg(os->os_spa)); #ifdef DEBUG if (dn->dn_objset->os_dsl_dataset != NULL) rrw_enter(&os->os_dsl_dataset->ds_bp_rwlock, RW_READER, FTAG); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/metaslab.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/metaslab.c Wed May 24 22:21:24 2017 (r318828) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/metaslab.c Wed May 24 22:25:26 2017 (r318829) @@ -1652,11 +1652,19 @@ metaslab_set_fragmentation(metaslab_t *m uint64_t txg = spa_syncing_txg(spa); vdev_t *vd = msp->ms_group->mg_vd; - if (spa_writeable(spa)) { + /* + * If we've reached the final dirty txg, then we must + * be shutting down the pool. We don't want to dirty + * any data past this point so skip setting the condense + * flag. We can retry this action the next time the pool + * is imported. + */ + if (spa_writeable(spa) && txg < spa_final_dirty_txg(spa)) { msp->ms_condense_wanted = B_TRUE; vdev_dirty(vd, VDD_METASLAB, msp, txg + 1); spa_dbgmsg(spa, "txg %llu, requesting force condense: " - "msp %p, vd %p", txg, msp, vd); + "ms_id %llu, vdev_id %llu", txg, msp->ms_id, + vd->vdev_id); } msp->ms_fragmentation = ZFS_FRAG_INVALID; return; @@ -2278,13 +2286,17 @@ metaslab_sync(metaslab_t *msp, uint64_t /* * Normally, we don't want to process a metaslab if there * are no allocations or frees to perform. However, if the metaslab - * is being forced to condense we need to let it through. + * is being forced to condense and it's loaded, we need to let it + * through. */ if (range_tree_space(alloctree) == 0 && range_tree_space(msp->ms_freeingtree) == 0 && - !msp->ms_condense_wanted) + !(msp->ms_loaded && msp->ms_condense_wanted)) return; + + VERIFY(txg <= spa_final_dirty_txg(spa)); + /* * The only state that can actually be changing concurrently with * metaslab_sync() is the metaslab's ms_tree. No other thread can Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c Wed May 24 22:21:24 2017 (r318828) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa_misc.c Wed May 24 22:25:26 2017 (r318829) @@ -1737,6 +1737,16 @@ spa_syncing_txg(spa_t *spa) return (spa->spa_syncing_txg); } +/* + * Return the last txg where data can be dirtied. The final txgs + * will be used to just clear out any deferred frees that remain. + */ +uint64_t +spa_final_dirty_txg(spa_t *spa) +{ + return (spa->spa_final_txg - TXG_DEFER_SIZE); +} + pool_state_t spa_state(spa_t *spa) { Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/space_map.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/space_map.c Wed May 24 22:21:24 2017 (r318828) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/space_map.c Wed May 24 22:25:26 2017 (r318829) @@ -23,7 +23,7 @@ * Use is subject to license terms. */ /* - * Copyright (c) 2012, 2014 by Delphix. All rights reserved. + * Copyright (c) 2012, 2016 by Delphix. All rights reserved. */ #include @@ -407,6 +407,7 @@ space_map_truncate(space_map_t *sm, dmu_ ASSERT(dsl_pool_sync_context(dmu_objset_pool(os))); ASSERT(dmu_tx_is_syncing(tx)); + VERIFY3U(dmu_tx_get_txg(tx), <=, spa_final_dirty_txg(spa)); dmu_object_info_from_db(sm->sm_dbuf, &doi); @@ -421,9 +422,10 @@ space_map_truncate(space_map_t *sm, dmu_ if ((spa_feature_is_enabled(spa, SPA_FEATURE_SPACEMAP_HISTOGRAM) && doi.doi_bonus_size != sizeof (space_map_phys_t)) || doi.doi_data_block_size != space_map_blksz) { - zfs_dbgmsg("txg %llu, spa %s, reallocating: " - "old bonus %u, old blocksz %u", dmu_tx_get_txg(tx), - spa_name(spa), doi.doi_bonus_size, doi.doi_data_block_size); + zfs_dbgmsg("txg %llu, spa %s, sm %p, reallocating " + "object[%llu]: old bonus %u, old blocksz %u", + dmu_tx_get_txg(tx), spa_name(spa), sm, sm->sm_object, + doi.doi_bonus_size, doi.doi_data_block_size); space_map_free(sm, tx); dmu_buf_rele(sm->sm_dbuf, sm); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa.h Wed May 24 22:21:24 2017 (r318828) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/spa.h Wed May 24 22:25:26 2017 (r318829) @@ -791,6 +791,7 @@ extern uint64_t spa_load_guid(spa_t *spa extern uint64_t spa_last_synced_txg(spa_t *spa); extern uint64_t spa_first_txg(spa_t *spa); extern uint64_t spa_syncing_txg(spa_t *spa); +extern uint64_t spa_final_dirty_txg(spa_t *spa); extern uint64_t spa_version(spa_t *spa); extern pool_state_t spa_state(spa_t *spa); extern spa_load_state_t spa_load_state(spa_t *spa); From owner-svn-src-head@freebsd.org Wed May 24 22:27:49 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BC79CD80DF2; Wed, 24 May 2017 22:27:49 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 85F0B1629; Wed, 24 May 2017 22:27:49 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMRm21053612; Wed, 24 May 2017 22:27:48 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMRmQO053611; Wed, 24 May 2017 22:27:48 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242227.v4OMRmQO053611@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:27:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318830 - 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.23 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, 24 May 2017 22:27:49 -0000 Author: avg Date: Wed May 24 22:27:48 2017 New Revision: 318830 URL: https://svnweb.freebsd.org/changeset/base/318830 Log: MFC r316921: 8027 tighten up dsl_pool_dirty_delta illumos/illumos-gate@313ae1e182df6e6a04b56c4b73ded33e11b75666 https://github.com/illumos/illumos-gate/commit/313ae1e182df6e6a04b56c4b73ded33e11b75666 https://www.illumos.org/issues/8027 dsl_pool_dirty_delta() should not wake up waiters when dp->dp_dirty_total == zfs_dirty_data_max, because they wait for dp_dirty_total to fall strictly below the threshold. It's probably very rare for that condition to occur, but it's better to have more accurate code. Reviewed by: Matt Ahrens Reviewed by: Serapheim Dimitropoulos Reviewed by: Paul Dagnelie Approved by: Dan McDonald Author: Andriy Gapon MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:25:26 2017 (r318829) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:27:48 2017 (r318830) @@ -559,7 +559,7 @@ dsl_pool_dirty_delta(dsl_pool_t *dp, int * Note: we signal even when increasing dp_dirty_total. * This ensures forward progress -- each thread wakes the next waiter. */ - if (dp->dp_dirty_total <= zfs_dirty_data_max) + if (dp->dp_dirty_total < zfs_dirty_data_max) cv_signal(&dp->dp_spaceavail_cv); } From owner-svn-src-head@freebsd.org Wed May 24 22:30:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DAB38D80EA0; Wed, 24 May 2017 22:30:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8E86B1899; Wed, 24 May 2017 22:30:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMULoS053901; Wed, 24 May 2017 22:30:21 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMULBb053900; Wed, 24 May 2017 22:30:21 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242230.v4OMULBb053900@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:30:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318831 - head/cddl/contrib/opensolaris/lib/libzfs/common 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.23 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, 24 May 2017 22:30:23 -0000 Author: avg Date: Wed May 24 22:30:21 2017 New Revision: 318831 URL: https://svnweb.freebsd.org/changeset/base/318831 Log: MFV r316922: 5380 receive of a send -p stream doesn't need to try renaming snapshots illumos/illumos-gate@471a88e499c660844f4590487ce7c4d5a7090294 https://github.com/illumos/illumos-gate/commit/471a88e499c660844f4590487ce7c4d5a7090294 https://www.illumos.org/issues/5380 A stream created with zfs send -p -I contains properties of all snapshots of a given dataset as opposed to only properties of snapshots in a given range. Not only this is suboptimal but the receive code also does not filter properties by the range. So, properties of earlier snapshots would be updated even though the snapshots themselves are not in the stream (just their properties). Given that modifying the snapshot properties requires a TXG sync and that the snapshots are updated one by one the described behavior may lead to a sever performance penalty. Reviewed by: Paul Dagnelie Reviewed by: Matt Ahrens Approved by: Dan McDonald Author: Andriy Gapon MFC after: 3 weeks Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c Directory Properties: head/cddl/contrib/opensolaris/ (props changed) head/cddl/contrib/opensolaris/lib/libzfs/ (props changed) Modified: head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c ============================================================================== --- head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c Wed May 24 22:27:48 2017 (r318830) +++ head/cddl/contrib/opensolaris/lib/libzfs/common/libzfs_sendrecv.c Wed May 24 22:30:21 2017 (r318831) @@ -2800,7 +2800,7 @@ zfs_receive_package(libzfs_handle_t *hdl goto out; } - if (fromsnap != NULL) { + if (fromsnap != NULL && recursive) { nvlist_t *renamed = NULL; nvpair_t *pair = NULL; @@ -2827,7 +2827,7 @@ zfs_receive_package(libzfs_handle_t *hdl *strchr(tofs, '@') = '\0'; } - if (recursive && !flags->dryrun && !flags->nomount) { + if (!flags->dryrun && !flags->nomount) { VERIFY(0 == nvlist_alloc(&renamed, NV_UNIQUE_NAME, 0)); } @@ -2896,7 +2896,7 @@ zfs_receive_package(libzfs_handle_t *hdl anyerr |= error; } while (error == 0); - if (drr->drr_payloadlen != 0 && fromsnap != NULL) { + if (drr->drr_payloadlen != 0 && recursive && fromsnap != NULL) { /* * Now that we have the fs's they sent us, try the * renames again. From owner-svn-src-head@freebsd.org Wed May 24 22:32:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 528BFD80008; Wed, 24 May 2017 22:32:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 212901CA9; Wed, 24 May 2017 22:32:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMWvH9057637; Wed, 24 May 2017 22:32:57 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMWvbZ057636; Wed, 24 May 2017 22:32:57 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242232.v4OMWvbZ057636@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:32:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318832 - 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.23 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, 24 May 2017 22:32:58 -0000 Author: avg Date: Wed May 24 22:32:56 2017 New Revision: 318832 URL: https://svnweb.freebsd.org/changeset/base/318832 Log: MFV r316923: 8026 retire zfs_throttle_delay and zfs_throttle_resolution illumos/illumos-gate@6b036259815954b7ad86d651af18efba672cb7a9 https://github.com/illumos/illumos-gate/commit/6b036259815954b7ad86d651af18efba672cb7a9 https://www.illumos.org/issues/8026 zfs_throttle_delay and zfs_throttle_resolution became disused since the new write throttling mechanism was introduced. Reviewed by: Matthew Ahrens Reviewed by: Serapheim Dimitropoulos Approved by: Richard Lowe Author: Andriy Gapon MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:30:21 2017 (r318831) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Wed May 24 22:32:56 2017 (r318832) @@ -232,9 +232,6 @@ sysctl_zfs_delay_scale(SYSCTL_HANDLER_AR } #endif -hrtime_t zfs_throttle_delay = MSEC2NSEC(10); -hrtime_t zfs_throttle_resolution = MSEC2NSEC(10); - int dsl_pool_open_special_dir(dsl_pool_t *dp, const char *name, dsl_dir_t **ddp) { From owner-svn-src-head@freebsd.org Wed May 24 22:34:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6F5D2D80079; Wed, 24 May 2017 22:34:56 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3298F1DFB; Wed, 24 May 2017 22:34:56 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMYtnT057787; Wed, 24 May 2017 22:34:55 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMYtaK057785; Wed, 24 May 2017 22:34:55 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242234.v4OMYtaK057785@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:34:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318833 - 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.23 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, 24 May 2017 22:34:56 -0000 Author: avg Date: Wed May 24 22:34:54 2017 New Revision: 318833 URL: https://svnweb.freebsd.org/changeset/base/318833 Log: MFV r316925: 6101 attempt to lzc_create() a filesystem under a volume results in a panic illumos/illumos-gate@b127fe3c059af7adf772735498680b4f2e1405ef https://github.com/illumos/illumos-gate/commit/b127fe3c059af7adf772735498680b4f2e1405ef https://www.illumos.org/issues/6101 lzc_create(), or more correctly, zfs_ioc_create() does not reject an attempt to create a filesystem as a child of a volume, instead it proceeds to a crash. A crash stack obtained on FreeBSD: page fault while in kernel mode zap_leaf_lookup() fzap_lookup() zap_lookup_norm() zap_lookup() zfs_get_zplprop() zfs_fill_zplprops_impl() zfs_ioc_create() zfsdev_ioctl() devfs_ioctl_f() kern_ioctl() sys_ioctl() This crash happened with a kernel without debugging assertions. The immediate cause of crash appears to an attempt to interpret a zvol object as a zap object. For filesystems: #define MASTER_NODE_OBJ 1 For zvols: #define ZVOL_OBJ 1ULL #define ZVOL_ZAP_OBJ 2ULL So, I see two problems here: 1. an attempt to create a filesystem under a zvol should be rejected as early as possible, maybe in zfs_fill_zplprops() 2. maybe zap_lookup / zap_lockdir should reject objects that are not of one of the zap object types Reviewed by: Matthew Ahrens Approved by: Dan McDonald Author: Andriy Gapon MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c Wed May 24 22:32:56 2017 (r318832) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c Wed May 24 22:34:54 2017 (r318833) @@ -3093,6 +3093,9 @@ zfs_fill_zplprops_impl(objset_t *os, uin ASSERT(zplprops != NULL); + if (os != NULL && os->os_phys->os_type != DMU_OST_ZFS) + return (SET_ERROR(EINVAL)); + /* * Pull out creator prop choices, if any. */ Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c Wed May 24 22:32:56 2017 (r318832) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c Wed May 24 22:34:54 2017 (r318833) @@ -2459,8 +2459,10 @@ zfs_get_zplprop(objset_t *os, zfs_prop_t else pname = zfs_prop_to_name(prop); - if (os != NULL) + if (os != NULL) { + ASSERT3U(os->os_phys->os_type, ==, DMU_OST_ZFS); error = zap_lookup(os, MASTER_NODE_OBJ, pname, 8, 1, value); + } if (error == ENOENT) { /* No value set, use the default value */ From owner-svn-src-head@freebsd.org Wed May 24 22:40:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 46847D80146; Wed, 24 May 2017 22:40:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 15D4310B9; Wed, 24 May 2017 22:40:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4OMevrn058776; Wed, 24 May 2017 22:40:57 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4OMevS0058775; Wed, 24 May 2017 22:40:57 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705242240.v4OMevS0058775@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Wed, 24 May 2017 22:40:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318834 - head/sys/cddl/contrib/opensolaris 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.23 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, 24 May 2017 22:40:58 -0000 Author: avg Date: Wed May 24 22:40:56 2017 New Revision: 318834 URL: https://svnweb.freebsd.org/changeset/base/318834 Log: MFV r316930: 5814 bpobj_iterate_impl(): Close a refcount leak iterating on a sublist. illumos/illumos-gate@b67dde11a73a9455d641403cbbb65ec2add41b41 https://github.com/illumos/illumos-gate/commit/b67dde11a73a9455d641403cbbb65ec2add41b41 https://www.illumos.org/issues/5814 Lets pull in this patch from freebsd: http://svnweb.freebsd.org/base?view=revision&revision=271781 bpobj_iterate_impl(): Close a refcount leak iterating on a sublist. If bpobj_space() returned non-zero here, the sublist would have been left open, along with the bonus buffer hold it requires. This call does not invoke any calls to bpobj_close() itself. This bug doesn't have any known vector, but was found on inspection. MFC after: 1 week Sponsored by: Spectra Logic Affects: All ZFS versions starting 21 May 2010 (illumos cde58dbc) MFSpectraBSD: r1050998 on 2014/03/26 Fix bpobj_iterate_impl() to properly call bpobj_close() if bpobj_space() returns an error. Reviewed by: Prakash Surya Reviewed by: Matthew Ahrens Reviewed by: Paul Dagnelie Reviewed by: Simon Klinkert Approved by: Gordon Ross Author: Will Andrews FreeBSD note: this is a "record-only" commit as the actual change was directly committed to FreeBSD by (or on behalf of) the author. Modified: Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) From owner-svn-src-head@freebsd.org Wed May 24 22:45:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A568AD803DD; Wed, 24 May 2017 22:45:30 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citapm.icyb.net.ua (citapm.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 7048016D7; Wed, 24 May 2017 22:45:28 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citapm.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id BAA01651; Thu, 25 May 2017 01:45:22 +0300 (EEST) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1dDf1t-000GNp-Sd; Thu, 25 May 2017 01:45:21 +0300 Subject: Re: svn commit: r318814 - head/cddl/contrib/opensolaris/lib/libzfs_core/common To: src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org References: <201705242053.v4OKr1hK014752@repo.freebsd.org> From: Andriy Gapon Message-ID: <46c5fab5-baff-8ef1-3d89-d362c9bf5345@FreeBSD.org> Date: Thu, 25 May 2017 01:44:25 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: <201705242053.v4OKr1hK014752@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 24 May 2017 22:45:30 -0000 On 24/05/2017 23:53, Andriy Gapon wrote: > MFC r316904: 7729 libzfs_core`lzc_rollback() leaks result nvl This and a few other commits should have MFV instead of MFC in their description. Sorry for any confusion that this mistake of mine might cause. -- Andriy Gapon From owner-svn-src-head@freebsd.org Thu May 25 01:32:55 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 25F59D7C91F; Thu, 25 May 2017 01:32:55 +0000 (UTC) (envelope-from jbtakk@iherebuywisely.com) Received: from aibo.runbox.com (aibo.runbox.com [91.220.196.211]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DB9801F0A; Thu, 25 May 2017 01:32:54 +0000 (UTC) (envelope-from jbtakk@iherebuywisely.com) Received: from [10.9.9.127] (helo=rmmprod05.runbox) by mailtransmit02.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1dDh3M-0000Oi-3P; Thu, 25 May 2017 02:55:00 +0200 Received: from mail by rmmprod05.runbox with local (Exim 4.86_2) (envelope-from ) id 1dDh3M-0004V1-1G; Thu, 25 May 2017 02:55:00 +0200 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Received: from [Authenticated user (846156)] by runbox.com with http (RMM6); Thu, 25 May 2017 00:54:59 GMT From: "Jeffrey Bouquet" To: "O. Hartmann" CC: "Larry Rosenman" , "O. Hartmann" , "src-committers" , "Ed Maste" , "svn-src-all" , "svn-src-head" , "freebsd-current@freebsd.org" , "Konstantin Belousov" Subject: Re: svn commit: r318757 - head Date: Wed, 24 May 2017 17:54:59 -0700 (PDT) X-Mailer: RMM6 In-Reply-To: <20170524201000.5bfc736f@thor.intern.walstatt.dynvpn.de> Message-Id: X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 25 May 2017 01:32:55 -0000 On Wed, 24 May 2017 20:10:00 +0200, "O. Hartmann" = wrote: > Am Wed, 24 May 2017 13:04:30 -0500 > Larry Rosenman schrieb: >=20 > > On 5/24/17, 1:01 PM, "O. Hartmann" wrote: > >=20 > > Am Wed, 24 May 2017 19:40:46 +0200 > > "O. Hartmann" schrieb: > >=20=20=20=20=20 > > > Am Wed, 24 May 2017 12:28:51 -0500 > > > Larry Rosenman schrieb: > > >=20=20=20 > > > > I fixed my issues by force-rebuilding perl and all installed p5= -* ports.=20 > > > >=20 > > > >=20=20=20=20=20 > > >=20 > > >=20 > > > This isn't possible in my case :-( > > >=20 > > > lang/perl rebuilds all right, but every p5-* ports fails with > > >=20 > > > [...] > > > Checking if your kit is complete... > > > ListUtil.c: loadable library and perl binaries are mismatched (go= t handshake key > > > 0xd200080, needed 0xdf00080)=20 > > > *** Error code 1 > > >=20 > > > I tried to rebuild also via portmaster -f, no success. Now, I gro= wing bunch of > > > ports showing up with this mysterious error. > > >=20 > > > To which port "ListUtil.c" might belong to? > > >=20 > > > Rebuilding autotools (which I suspected first) also fails ... > > >=20 > > >=20=20=20 > >=20=20=20=20=20 > > ... it seems, as K. belousov mentioned prior regarding different AB= I, all p5-* > > ports need to be deleted by force ... They rebuild properly afterwards. > >=20=20=20=20=20 > > Which is essentially what I did re: Poudriere (poudriere bulk =E2=80=93= C =E2=80=93j -p > > -f ) >=20 > I use the traditional "make" way (via portmaster) >=20 > --=20 > O. Hartmann >=20 > Ich widerspreche der Nutzung oder =C3=9Cbermittlung meiner Daten f=C3=BCr > Werbezwecke oder f=C3=BCr die Markt- oder Meinungsforschung (=C2=A7 28 Ab= s. 4 BDSG). Would it be worthwhile to have say weeks 1-3 of each month usual, then the = fourth week a 'fix poudriere run of current totally [ or synth ] so that snapshots can be= had monthly of the CURRENT with ALL ports working as packages? And a freeze on CURRENT du= ring that time? so poudriere and/or synth takes precedence over CURRENT? For the sak= e of=20 persons using CURRENT as their principal desktop/dev box?= From owner-svn-src-head@freebsd.org Thu May 25 04:18:49 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 90DF4D81C0B; Thu, 25 May 2017 04:18:49 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 299EE1F89; Thu, 25 May 2017 04:18:49 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P4Imw9004247; Thu, 25 May 2017 04:18:48 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P4IkbT004230; Thu, 25 May 2017 04:18:46 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705250418.v4P4IkbT004230@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Thu, 25 May 2017 04:18:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318856 - in head/sys: dev/ath dev/ath/ath_dfs/null dev/ath/ath_hal dev/ath/ath_rate/sample modules modules/ath modules/ath_dfs modules/ath_hal modules/ath_hal_ar5210 modules/ath_hal_ar... 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.23 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, 25 May 2017 04:18:49 -0000 Author: adrian Date: Thu May 25 04:18:46 2017 New Revision: 318856 URL: https://svnweb.freebsd.org/changeset/base/318856 Log: [ath] [ath_hal] (etc, etc) - begin the task of re-modularising the HAL. In the deep past, when this code compiled as a binary module, ath_hal built as a module. This allowed custom, smaller HAL modules to be built. This was especially beneficial for small embedded platforms where you didn't require /everything/ just to run. However, sometime around the HAL opening fanfare, the HAL landed here as one big driver+HAL thing, and a lot of the (dirty) infrastructure (ie, #ifdef AH_SUPPORT_XXX) to build specific subsets of the HAL went away. This was retained in sys/conf/files as "ath_hal_XXX" but it wasn't really floated up to the modules themselves. I'm now in a position where for the reaaaaaly embedded boards (both the really old and the last couple generation of QCA MIPS boards) having a cut down HAL module and driver loaded at runtime is /actually/ beneficial. This reduces the kernel size down by quite a bit. The MIPS modules look like this: adrian@gertrude:~/work/freebsd/head-embedded/src % ls -l ../root/mips_ap/boot/kernel.CARAMBOLA2/ath*ko -r-xr-xr-x 1 adrian adrian 5076 May 23 23:45 ../root/mips_ap/boot/kernel.CARAMBOLA2/ath_dfs.ko -r-xr-xr-x 1 adrian adrian 100588 May 23 23:45 ../root/mips_ap/boot/kernel.CARAMBOLA2/ath_hal.ko -r-xr-xr-x 1 adrian adrian 627324 May 23 23:45 ../root/mips_ap/boot/kernel.CARAMBOLA2/ath_hal_ar9300.ko -r-xr-xr-x 1 adrian adrian 314588 May 23 23:45 ../root/mips_ap/boot/kernel.CARAMBOLA2/ath_main.ko -r-xr-xr-x 1 adrian adrian 23472 May 23 23:45 ../root/mips_ap/boot/kernel.CARAMBOLA2/ath_rate.ko And the x86 versions, like this: root@gertrude:/home/adrian # ls -l /boot/kernel/ath*ko -r-xr-xr-x 1 root wheel 36632 May 24 18:32 /boot/kernel/ath_dfs.ko -r-xr-xr-x 1 root wheel 134440 May 24 18:32 /boot/kernel/ath_hal.ko -r-xr-xr-x 1 root wheel 82320 May 24 18:32 /boot/kernel/ath_hal_ar5210.ko -r-xr-xr-x 1 root wheel 104976 May 24 18:32 /boot/kernel/ath_hal_ar5211.ko -r-xr-xr-x 1 root wheel 236144 May 24 18:32 /boot/kernel/ath_hal_ar5212.ko -r-xr-xr-x 1 root wheel 336104 May 24 18:32 /boot/kernel/ath_hal_ar5416.ko -r-xr-xr-x 1 root wheel 598336 May 24 18:32 /boot/kernel/ath_hal_ar9300.ko -r-xr-xr-x 1 root wheel 406144 May 24 18:32 /boot/kernel/ath_main.ko -r-xr-xr-x 1 root wheel 55352 May 24 18:32 /boot/kernel/ath_rate.ko .. so you can see, not building the whole HAL can save quite a bit. For example, if you don't need AR9300 support, you can actually avoid wasting half a megabyte of RAM. On embedded routers this is quite a big deal. The AR9300 HAL can be later further shrunk because, hilariously, it indeed supports AH_SUPPORT_ for optionally adding chipset support. (I'll chase that down later as it's quite a big savings if you're only building for a single embedded target.) So: * Create a very hackish way to load/unload HAL modules * Create module metadata for each HAL subtype - ah_osdep_arXXXX.c * Create module metadata for ath_rate and ath_dfs (bluetooth is currently just built as part of it) * .. yes, this means we could actually build multiple rate control modules and pick one at load time, but I'd rather just glue this into net80211's rate control code. Oh well, baby steps. * Main driver is now "ath_main" * Create an "if_ath" module that does what the ye olde one did - load PCI glue, main driver, HAL and all child modules. In this way, if you have "if_ath_load=YES" in /boot/modules.conf it will load everything the old way and stuff should still work. * For module autoloading purposes, I actually /did/ fix up the name of the modules in if_ath_pci and if_ath_ahb. If you want to selectively load things (eg on ye cheape ARM/MIPS platforms where RAM is at a premium) you should: * load ath_hal * load the chip modules in question * load ath_rate, ath_dfs * load ath_main * load if_ath_pci and/or if_ath_ahb depending upon your particular bus bind type - this is where probe/attach is done. TODO: * AR5312 module and associated pieces - yes, we have the SoC side support now so the wifi support would be good to "round things out"; * Just nuke AH_SUPPORT_AR5416 for now and always bloat the packet structures; this'll simplify other things. * Should add a simple refcnt thing to the HAL RF/chip modules so you can't unload them whilst you're using them. * Manpage updates, UPDATING if appropriate, etc. Added: head/sys/dev/ath/ah_osdep_ar5210.c (contents, props changed) head/sys/dev/ath/ah_osdep_ar5211.c (contents, props changed) head/sys/dev/ath/ah_osdep_ar5212.c (contents, props changed) head/sys/dev/ath/ah_osdep_ar5416.c (contents, props changed) head/sys/dev/ath/ah_osdep_ar9300.c (contents, props changed) head/sys/dev/ath/if_ath_dfs.c (contents, props changed) head/sys/dev/ath/if_ath_drv.c (contents, props changed) head/sys/dev/ath/if_ath_rate.c (contents, props changed) head/sys/modules/ath_dfs/ head/sys/modules/ath_dfs/Makefile (contents, props changed) head/sys/modules/ath_hal/ head/sys/modules/ath_hal/Makefile (contents, props changed) head/sys/modules/ath_hal_ar5210/ head/sys/modules/ath_hal_ar5210/Makefile (contents, props changed) head/sys/modules/ath_hal_ar5211/ head/sys/modules/ath_hal_ar5211/Makefile (contents, props changed) head/sys/modules/ath_hal_ar5212/ head/sys/modules/ath_hal_ar5212/Makefile (contents, props changed) head/sys/modules/ath_hal_ar5416/ head/sys/modules/ath_hal_ar5416/Makefile (contents, props changed) head/sys/modules/ath_hal_ar9300/ head/sys/modules/ath_hal_ar9300/Makefile (contents, props changed) head/sys/modules/ath_main/ head/sys/modules/ath_main/Makefile (contents, props changed) head/sys/modules/ath_rate/ head/sys/modules/ath_rate/Makefile (contents, props changed) Modified: head/sys/dev/ath/ah_osdep.c head/sys/dev/ath/ath_dfs/null/dfs_null.c head/sys/dev/ath/ath_hal/ah.c head/sys/dev/ath/ath_hal/ah_internal.h head/sys/dev/ath/ath_rate/sample/sample.c head/sys/dev/ath/if_ath.c head/sys/dev/ath/if_ath_ahb.c head/sys/dev/ath/if_ath_pci.c head/sys/modules/Makefile head/sys/modules/ath/Makefile Modified: head/sys/dev/ath/ah_osdep.c ============================================================================== --- head/sys/dev/ath/ah_osdep.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/ah_osdep.c Thu May 25 04:18:46 2017 (r318856) @@ -41,6 +41,7 @@ #include #include #include +#include #include @@ -420,3 +421,31 @@ ath_hal_assert_failed(const char* filena panic("ath_hal_assert"); } #endif /* AH_ASSERT */ + +static int +ath_hal_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + printf("[ath_hal] loaded\n"); + break; + + case MOD_UNLOAD: + printf("[ath_hal] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal, ath_hal_modevent, NULL); +MODULE_VERSION(ath_hal, 1); Added: head/sys/dev/ath/ah_osdep_ar5210.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/ah_osdep_ar5210.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,74 @@ +/*- + * Copyright 2017 Adrian Chadd . + * + * 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 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 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 "opt_ah.h" +#include "opt_wlan.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +extern struct ath_hal_chip AR5210_chip; + +static int +ath_hal_ar5210_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + ath_hal_add_chip(&AR5210_chip); + printf("[ar5210] loaded\n"); + break; + + case MOD_UNLOAD: + ath_hal_remove_chip(&AR5210_chip); + printf("[ar5210] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal_ar5210, ath_hal_ar5210_modevent, NULL); +MODULE_VERSION(ath_hal_ar5210, 1); +MODULE_DEPEND(ath_hal_ar5210, ath_hal, 1, 1, 1); Added: head/sys/dev/ath/ah_osdep_ar5211.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/ah_osdep_ar5211.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,74 @@ +/*- + * Copyright 2017 Adrian Chadd . + * + * 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 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 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 "opt_ah.h" +#include "opt_wlan.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +extern struct ath_hal_chip AR5211_chip; + +static int +ath_hal_ar5211_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + ath_hal_add_chip(&AR5211_chip); + printf("[ar5211] loaded\n"); + break; + + case MOD_UNLOAD: + ath_hal_remove_chip(&AR5211_chip); + printf("[ar5211] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal_ar5211, ath_hal_ar5211_modevent, NULL); +MODULE_VERSION(ath_hal_ar5211, 1); +MODULE_DEPEND(ath_hal_ar5211, ath_hal, 1, 1, 1); Added: head/sys/dev/ath/ah_osdep_ar5212.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/ah_osdep_ar5212.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,95 @@ +/*- + * Copyright 2017 Adrian Chadd . + * + * 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 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 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 "opt_ah.h" +#include "opt_wlan.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +extern struct ath_hal_chip AR5212_chip; +//extern struct ath_hal_rf RF2316_rf; +//extern struct ath_hal_rf RF2317_rf; +extern struct ath_hal_rf RF2413_rf; +extern struct ath_hal_rf RF2425_rf; +extern struct ath_hal_rf RF5111_rf; +extern struct ath_hal_rf RF5112_rf; +extern struct ath_hal_rf RF5413_rf; + +static int +ath_hal_ar5212_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + ath_hal_add_chip(&AR5212_chip); +// ath_hal_add_rf(&RF2316_rf); +// ath_hal_add_rf(&RF2317_rf); + ath_hal_add_rf(&RF2413_rf); + ath_hal_add_rf(&RF2425_rf); + ath_hal_add_rf(&RF5111_rf); + ath_hal_add_rf(&RF5112_rf); + ath_hal_add_rf(&RF5413_rf); + printf("[ar5212] loaded\n"); + break; + + case MOD_UNLOAD: + ath_hal_remove_chip(&AR5212_chip); +// ath_hal_remove_rf(&RF2316_rf); +// ath_hal_remove_rf(&RF2317_rf); + ath_hal_remove_rf(&RF2413_rf); + ath_hal_remove_rf(&RF2425_rf); + ath_hal_remove_rf(&RF5111_rf); + ath_hal_remove_rf(&RF5112_rf); + ath_hal_remove_rf(&RF5413_rf); + printf("[ar5212] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal_ar5212, ath_hal_ar5212_modevent, NULL); +MODULE_VERSION(ath_hal_ar5212, 1); +MODULE_DEPEND(ath_hal_ar5212, ath_hal, 1, 1, 1); Added: head/sys/dev/ath/ah_osdep_ar5416.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/ah_osdep_ar5416.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,103 @@ +/*- + * Copyright 2017 Adrian Chadd . + * + * 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 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 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 "opt_ah.h" +#include "opt_wlan.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +extern struct ath_hal_chip AR5416_chip; +extern struct ath_hal_chip AR9130_chip; +extern struct ath_hal_chip AR9160_chip; +extern struct ath_hal_chip AR9280_chip; +extern struct ath_hal_chip AR9285_chip; +extern struct ath_hal_chip AR9287_chip; + +extern struct ath_hal_rf RF2133_rf; +extern struct ath_hal_rf RF9280_rf; +extern struct ath_hal_rf RF9285_rf; +extern struct ath_hal_rf RF9287_rf; + +static int +ath_hal_ar5416_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + ath_hal_add_chip(&AR5416_chip); + ath_hal_add_chip(&AR9130_chip); + ath_hal_add_chip(&AR9160_chip); + ath_hal_add_chip(&AR9280_chip); + ath_hal_add_chip(&AR9285_chip); + ath_hal_add_chip(&AR9287_chip); + ath_hal_add_rf(&RF2133_rf); + ath_hal_add_rf(&RF9280_rf); + ath_hal_add_rf(&RF9285_rf); + ath_hal_add_rf(&RF9287_rf); + printf("[ar5416] loaded\n"); + break; + + case MOD_UNLOAD: + ath_hal_remove_chip(&AR5416_chip); + ath_hal_remove_chip(&AR9130_chip); + ath_hal_remove_chip(&AR9160_chip); + ath_hal_remove_chip(&AR9280_chip); + ath_hal_remove_chip(&AR9285_chip); + ath_hal_remove_chip(&AR9287_chip); + ath_hal_remove_rf(&RF2133_rf); + ath_hal_remove_rf(&RF9280_rf); + ath_hal_remove_rf(&RF9285_rf); + ath_hal_remove_rf(&RF9287_rf); + printf("[ar5416] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal_ar5416, ath_hal_ar5416_modevent, NULL); +MODULE_VERSION(ath_hal_ar5416, 1); +MODULE_DEPEND(ath_hal_ar5416, ath_hal, 1, 1, 1); +MODULE_DEPEND(ath_hal_ar5416, ath_hal_ar5212, 1, 1, 1); Added: head/sys/dev/ath/ah_osdep_ar9300.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/ah_osdep_ar9300.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,74 @@ +/*- + * Copyright 2017 Adrian Chadd . + * + * 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 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 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 "opt_ah.h" +#include "opt_wlan.h" + +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +extern struct ath_hal_chip AR9300_chip; + +static int +ath_hal_ar9300_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + ath_hal_add_chip(&AR9300_chip); + printf("[ar9300] loaded\n"); + break; + + case MOD_UNLOAD: + ath_hal_remove_chip(&AR9300_chip); + printf("[ar9300] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_hal_ar9300, ath_hal_ar9300_modevent, NULL); +MODULE_VERSION(ath_hal_ar9300, 1); +MODULE_DEPEND(ath_hal_ar9300, ath_hal, 1, 1, 1); Modified: head/sys/dev/ath/ath_dfs/null/dfs_null.c ============================================================================== --- head/sys/dev/ath/ath_dfs/null/dfs_null.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/ath_dfs/null/dfs_null.c Thu May 25 04:18:46 2017 (r318856) @@ -102,7 +102,7 @@ ath_dfs_detach(struct ath_softc *sc) int ath_dfs_radar_enable(struct ath_softc *sc, struct ieee80211_channel *chan) { -#if 0 +#if 1 HAL_PHYERR_PARAM pe; /* Check if the hardware supports radar reporting */ @@ -155,7 +155,7 @@ ath_dfs_radar_enable(struct ath_softc *s int ath_dfs_radar_disable(struct ath_softc *sc) { -#if 0 +#if 1 HAL_PHYERR_PARAM pe; (void) ath_hal_getdfsthresh(sc->sc_ah, &pe); Modified: head/sys/dev/ath/ath_hal/ah.c ============================================================================== --- head/sys/dev/ath/ath_hal/ah.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/ath_hal/ah.c Thu May 25 04:18:46 2017 (r318856) @@ -28,6 +28,23 @@ /* linker set of registered chips */ OS_SET_DECLARE(ah_chips, struct ath_hal_chip); +TAILQ_HEAD(, ath_hal_chip) ah_chip_list = TAILQ_HEAD_INITIALIZER(ah_chip_list); + +int +ath_hal_add_chip(struct ath_hal_chip *ahc) +{ + + TAILQ_INSERT_TAIL(&ah_chip_list, ahc, node); + return (0); +} + +int +ath_hal_remove_chip(struct ath_hal_chip *ahc) +{ + + TAILQ_REMOVE(&ah_chip_list, ahc, node); + return (0); +} /* * Check the set of registered chips to see if any recognize @@ -37,12 +54,22 @@ const char* ath_hal_probe(uint16_t vendorid, uint16_t devid) { struct ath_hal_chip * const *pchip; + struct ath_hal_chip *pc; + /* Linker set */ OS_SET_FOREACH(pchip, ah_chips) { const char *name = (*pchip)->probe(vendorid, devid); if (name != AH_NULL) return name; } + + /* List */ + TAILQ_FOREACH(pc, &ah_chip_list, node) { + const char *name = pc->probe(vendorid, devid); + if (name != AH_NULL) + return name; + } + return AH_NULL; } @@ -60,6 +87,7 @@ ath_hal_attach(uint16_t devid, HAL_SOFTC HAL_STATUS *error) { struct ath_hal_chip * const *pchip; + struct ath_hal_chip *pc; OS_SET_FOREACH(pchip, ah_chips) { struct ath_hal_chip *chip = *pchip; @@ -82,6 +110,30 @@ ath_hal_attach(uint16_t devid, HAL_SOFTC return ah; } } + + /* List */ + TAILQ_FOREACH(pc, &ah_chip_list, node) { + struct ath_hal_chip *chip = pc; + struct ath_hal *ah; + + /* XXX don't have vendorid, assume atheros one works */ + if (chip->probe(ATHEROS_VENDOR_ID, devid) == AH_NULL) + continue; + ah = chip->attach(devid, sc, st, sh, eepromdata, ah_config, + error); + if (ah != AH_NULL) { + /* copy back private state to public area */ + ah->ah_devid = AH_PRIVATE(ah)->ah_devid; + ah->ah_subvendorid = AH_PRIVATE(ah)->ah_subvendorid; + ah->ah_macVersion = AH_PRIVATE(ah)->ah_macVersion; + ah->ah_macRev = AH_PRIVATE(ah)->ah_macRev; + ah->ah_phyRev = AH_PRIVATE(ah)->ah_phyRev; + ah->ah_analog5GhzRev = AH_PRIVATE(ah)->ah_analog5GhzRev; + ah->ah_analog2GhzRev = AH_PRIVATE(ah)->ah_analog2GhzRev; + return ah; + } + } + return AH_NULL; } @@ -160,6 +212,23 @@ ath_hal_getwirelessmodes(struct ath_hal* /* linker set of registered RF backends */ OS_SET_DECLARE(ah_rfs, struct ath_hal_rf); +TAILQ_HEAD(, ath_hal_rf) ah_rf_list = TAILQ_HEAD_INITIALIZER(ah_rf_list); + +int +ath_hal_add_rf(struct ath_hal_rf *arf) +{ + + TAILQ_INSERT_TAIL(&ah_rf_list, arf, node); + return (0); +} + +int +ath_hal_remove_rf(struct ath_hal_rf *arf) +{ + + TAILQ_REMOVE(&ah_rf_list, arf, node); + return (0); +} /* * Check the set of registered RF backends to see if @@ -169,12 +238,18 @@ struct ath_hal_rf * ath_hal_rfprobe(struct ath_hal *ah, HAL_STATUS *ecode) { struct ath_hal_rf * const *prf; + struct ath_hal_rf * rf; OS_SET_FOREACH(prf, ah_rfs) { struct ath_hal_rf *rf = *prf; if (rf->probe(ah)) return rf; } + + TAILQ_FOREACH(rf, &ah_rf_list, node) { + if (rf->probe(ah)) + return rf; + } *ecode = HAL_ENOTSUPP; return AH_NULL; } Modified: head/sys/dev/ath/ath_hal/ah_internal.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah_internal.h Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/ath_hal/ah_internal.h Thu May 25 04:18:46 2017 (r318856) @@ -28,6 +28,7 @@ #define AH_MAX(a,b) ((a)>(b)?(a):(b)) #include +#include /* XXX for reasons */ #include "opt_ah.h" /* needed for AH_SUPPORT_AR5416 */ #ifndef AH_SUPPORT_AR5416 @@ -85,6 +86,11 @@ typedef enum { /* * Each chip or class of chips registers to offer support. + * + * Compiled-in versions will include a linker set to iterate through the + * linked in code. + * + * Modules will have to register HAL backends separately. */ struct ath_hal_chip { const char *name; @@ -93,13 +99,14 @@ struct ath_hal_chip { HAL_BUS_TAG, HAL_BUS_HANDLE, uint16_t *eepromdata, HAL_OPS_CONFIG *ah, HAL_STATUS *error); + TAILQ_ENTRY(ath_hal_chip) node; }; #ifndef AH_CHIP #define AH_CHIP(_name, _probe, _attach) \ -static struct ath_hal_chip _name##_chip = { \ +struct ath_hal_chip _name##_chip = { \ .name = #_name, \ .probe = _probe, \ - .attach = _attach \ + .attach = _attach, \ }; \ OS_DATA_SET(ah_chips, _name##_chip) #endif @@ -108,18 +115,24 @@ OS_DATA_SET(ah_chips, _name##_chip) * Each RF backend registers to offer support; this is mostly * used by multi-chip 5212 solutions. Single-chip solutions * have a fixed idea about which RF to use. + * + * Compiled in versions will include this linker set to iterate through + * the linked in code. + * + * Modules will have to register RF backends separately. */ struct ath_hal_rf { const char *name; HAL_BOOL (*probe)(struct ath_hal *ah); HAL_BOOL (*attach)(struct ath_hal *ah, HAL_STATUS *ecode); + TAILQ_ENTRY(ath_hal_rf) node; }; #ifndef AH_RF #define AH_RF(_name, _probe, _attach) \ -static struct ath_hal_rf _name##_rf = { \ +struct ath_hal_rf _name##_rf = { \ .name = __STRING(_name), \ .probe = _probe, \ - .attach = _attach \ + .attach = _attach, \ }; \ OS_DATA_SET(ah_rfs, _name##_rf) #endif @@ -1038,4 +1051,12 @@ extern void ath_hal_survey_clear(struct extern void ath_hal_survey_add_sample(struct ath_hal *ah, HAL_SURVEY_SAMPLE *hs); +/* + * Chip registration - for modules. + */ +extern int ath_hal_add_chip(struct ath_hal_chip *ahc); +extern int ath_hal_remove_chip(struct ath_hal_chip *ahc); +extern int ath_hal_add_rf(struct ath_hal_rf *arf); +extern int ath_hal_remove_rf(struct ath_hal_rf *arf); + #endif /* _ATH_AH_INTERAL_H_ */ Modified: head/sys/dev/ath/ath_rate/sample/sample.c ============================================================================== --- head/sys/dev/ath/ath_rate/sample/sample.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/ath_rate/sample/sample.c Thu May 25 04:18:46 2017 (r318856) @@ -775,6 +775,10 @@ update_stats(struct ath_softc *sc, struc * XXX Don't mark the higher bit rates as also having failed; as this * unfortunately stops those rates from being tasted when trying to * TX. This happens with 11n aggregation. + * + * This is valid for higher CCK rates, higher OFDM rates, and higher + * HT rates within the current number of streams (eg MCS0..7, 8..15, + * etc.) */ if (nframes == nbad) { #if 0 Modified: head/sys/dev/ath/if_ath.c ============================================================================== --- head/sys/dev/ath/if_ath.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/if_ath.c Thu May 25 04:18:46 2017 (r318856) @@ -6989,8 +6989,11 @@ ath_node_recv_pspoll(struct ieee80211_no #endif /* ATH_SW_PSQ */ } -MODULE_VERSION(if_ath, 1); -MODULE_DEPEND(if_ath, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_VERSION(ath_main, 1); +MODULE_DEPEND(ath_main, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_DEPEND(ath_main, ath_rate, 1, 1, 1); +MODULE_DEPEND(ath_main, ath_dfs, 1, 1, 1); +MODULE_DEPEND(ath_main, ath_hal, 1, 1, 1); #if defined(IEEE80211_ALQ) || defined(AH_DEBUG_ALQ) || defined(ATH_DEBUG_ALQ) -MODULE_DEPEND(if_ath, alq, 1, 1, 1); +MODULE_DEPEND(ath_main, alq, 1, 1, 1); #endif Modified: head/sys/dev/ath/if_ath_ahb.c ============================================================================== --- head/sys/dev/ath/if_ath_ahb.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/if_ath_ahb.c Thu May 25 04:18:46 2017 (r318856) @@ -343,8 +343,9 @@ static driver_t ath_ahb_driver = { sizeof (struct ath_ahb_softc) }; static devclass_t ath_devclass; -DRIVER_MODULE(ath, nexus, ath_ahb_driver, ath_devclass, 0, 0); -DRIVER_MODULE(ath, apb, ath_ahb_driver, ath_devclass, 0, 0); -MODULE_VERSION(ath, 1); -MODULE_DEPEND(ath, wlan, 1, 1, 1); /* 802.11 media layer */ -MODULE_DEPEND(ath, if_ath, 1, 1, 1); /* if_ath driver */ +DRIVER_MODULE(if_ath_ahb, nexus, ath_ahb_driver, ath_devclass, 0, 0); +DRIVER_MODULE(if_ath_ahb, apb, ath_ahb_driver, ath_devclass, 0, 0); +MODULE_VERSION(if_ath_ahb, 1); +MODULE_DEPEND(if_ath_ahb, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_DEPEND(if_ath_ahb, ath_main, 1, 1, 1); /* if_ath driver */ +MODULE_DEPEND(if_ath_ahb, ath_hal, 1, 1, 1); /* ath HAL */ Added: head/sys/dev/ath/if_ath_dfs.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/if_ath_dfs.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,74 @@ +/*- + * Copyright (c) 2017 Adrian Chadd . + * 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, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any + * redistribution must be conditioned upon including a substantially + * similar Disclaimer requirement for further binary redistribution. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR 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 DAMAGES. + * + * $FreeBSD$ + */ +#include "opt_ah.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +static int +ath_dfs_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + printf("[ath_dfs] loaded\n"); + break; + + case MOD_UNLOAD: + printf("[ath_dfs] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(ath_dfs, ath_dfs_modevent, NULL); +MODULE_VERSION(ath_dfs, 1); +MODULE_DEPEND(ath_dfs, ath_hal, 1, 1, 1); +MODULE_DEPEND(ath_dfs, wlan, 1, 1, 1); Added: head/sys/dev/ath/if_ath_drv.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/if_ath_drv.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,89 @@ +/*- + * Copyright (c) 2017 Adrian Chadd + * 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, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any + * redistribution must be conditioned upon including a substantially + * similar Disclaimer requirement for further binary redistribution. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR 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 DAMAGES. + * + * $FreeBSD$ + */ +#include "opt_ah.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +/* + * This implements the "old" style ath(4) module behaviour, which loaded the + * driver, HAL and PCI glue. + */ + +static int +ath_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + printf("[ath] loaded\n"); + break; + + case MOD_UNLOAD: + printf("[ath] unloaded\n"); + break; + + case MOD_SHUTDOWN: + break; + + default: + error = EOPNOTSUPP; + break; + + } + return (error); +} + +DEV_MODULE(if_ath, ath_modevent, NULL); + +MODULE_VERSION(if_ath, 1); +MODULE_DEPEND(if_ath, ath_hal, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_hal_ar5210, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_hal_ar5211, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_hal_ar5212, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_hal_ar5416, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_hal_ar9300, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_rate, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_dfs, 1, 1, 1); +MODULE_DEPEND(if_ath, wlan, 1, 1, 1); +MODULE_DEPEND(if_ath, ath_main, 1, 1, 1); +MODULE_DEPEND(if_ath, if_ath_pci, 1, 1, 1); Modified: head/sys/dev/ath/if_ath_pci.c ============================================================================== --- head/sys/dev/ath/if_ath_pci.c Thu May 25 02:00:37 2017 (r318855) +++ head/sys/dev/ath/if_ath_pci.c Thu May 25 04:18:46 2017 (r318856) @@ -463,7 +463,8 @@ static driver_t ath_pci_driver = { sizeof (struct ath_pci_softc) }; static devclass_t ath_devclass; -DRIVER_MODULE(ath_pci, pci, ath_pci_driver, ath_devclass, 0, 0); -MODULE_VERSION(ath_pci, 1); -MODULE_DEPEND(ath_pci, wlan, 1, 1, 1); /* 802.11 media layer */ -MODULE_DEPEND(ath_pci, if_ath, 1, 1, 1); /* if_ath driver */ +DRIVER_MODULE(if_ath_pci, pci, ath_pci_driver, ath_devclass, 0, 0); +MODULE_VERSION(if_ath_pci, 1); +MODULE_DEPEND(if_ath_pci, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_DEPEND(if_ath_pci, ath_main, 1, 1, 1); /* if_ath driver */ +MODULE_DEPEND(if_ath_pci, ath_hal, 1, 1, 1); /* ath HAL */ Added: head/sys/dev/ath/if_ath_rate.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/ath/if_ath_rate.c Thu May 25 04:18:46 2017 (r318856) @@ -0,0 +1,74 @@ +/*- + * Copyright (c) 2017 Adrian Chadd . + * 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, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any + * redistribution must be conditioned upon including a substantially + * similar Disclaimer requirement for further binary redistribution. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR 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 DAMAGES. + * + * $FreeBSD$ + */ +#include "opt_ah.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +static int +ath_rate_modevent(module_t mod __unused, int type, void *data __unused) +{ + int error = 0; + + switch (type) { + case MOD_LOAD: + printf("[ath_rate] loaded\n"); + break; + + case MOD_UNLOAD: + printf("[ath_rate] unloaded\n"); + break; + *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Thu May 25 04:26:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 972BCD81F11; Thu, 25 May 2017 04:26:28 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 73BCA14C1; Thu, 25 May 2017 04:26:28 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P4QRqi008334; Thu, 25 May 2017 04:26:27 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P4QRqZ008330; Thu, 25 May 2017 04:26:27 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705250426.v4P4QRqZ008330@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Thu, 25 May 2017 04:26:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318857 - in head/sys/dev/ath: . ath_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.23 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, 25 May 2017 04:26:28 -0000 Author: adrian Date: Thu May 25 04:26:26 2017 New Revision: 318857 URL: https://svnweb.freebsd.org/changeset/base/318857 Log: [ath] [ath_hal] retire AH_SUPPORT_AR5416 changing anything. Yes, the memory bloat is large, but it's 2017 and I'll fix it later by making it runtime configurable / per-chip configurable if I ever need to. Modified: head/sys/dev/ath/ath_hal/ah.c head/sys/dev/ath/ath_hal/ah_desc.h head/sys/dev/ath/ath_hal/ah_internal.h head/sys/dev/ath/if_ath_rx.c Modified: head/sys/dev/ath/ath_hal/ah.c ============================================================================== --- head/sys/dev/ath/ath_hal/ah.c Thu May 25 04:18:46 2017 (r318856) +++ head/sys/dev/ath/ath_hal/ah.c Thu May 25 04:26:26 2017 (r318857) @@ -1188,7 +1188,6 @@ ath_hal_get_mimo_chan_noise(struct ath_h const struct ieee80211_channel *chan, int16_t *nf_ctl, int16_t *nf_ext) { -#ifdef AH_SUPPORT_AR5416 HAL_CHANNEL_INTERNAL *ichan; int i; @@ -1243,9 +1242,6 @@ ath_hal_get_mimo_chan_noise(struct ath_h } return 1; } -#else - return 0; -#endif /* AH_SUPPORT_AR5416 */ } /* Modified: head/sys/dev/ath/ath_hal/ah_desc.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah_desc.h Thu May 25 04:18:46 2017 (r318856) +++ head/sys/dev/ath/ath_hal/ah_desc.h Thu May 25 04:26:26 2017 (r318857) @@ -20,21 +20,6 @@ #ifndef _DEV_ATH_DESC_H #define _DEV_ATH_DESC_H -#include "opt_ah.h" /* NB: required for AH_SUPPORT_AR5416 */ - -/* - * For now, define this for the structure definitions. - * Because of how the HAL / driver module currently builds, - * it's not very feasible to build the module without - * this defined. The rest of the code (eg in the driver - * body) can work fine with these fields being uninitialised; - * they'll be initialised to 0 anyway. - */ - -#ifndef AH_SUPPORT_AR5416 -#define AH_SUPPORT_AR5416 1 -#endif - /* * Transmit descriptor status. This structure is filled * in only after the tx descriptor process method finds a @@ -56,7 +41,6 @@ struct ath_tx_status { uint8_t ts_virtcol; /* virtual collision count */ uint8_t ts_antenna; /* antenna information */ uint8_t ts_finaltsi; /* final transmit series index */ -#ifdef AH_SUPPORT_AR5416 /* 802.11n status */ uint8_t ts_flags; /* misc flags */ uint8_t ts_queue_id; /* AR9300: TX queue id */ @@ -71,7 +55,6 @@ struct ath_tx_status { int8_t ts_rssi_ctl[3]; /* tx ack RSSI [ctl, chain 0-2] */ int8_t ts_rssi_ext[3]; /* tx ack RSSI [ext, chain 0-2] */ uint8_t ts_pad[2]; -#endif /* AH_SUPPORT_AR5416 */ }; /* bits found in ts_status */ @@ -121,7 +104,6 @@ struct ath_rx_status { uint8_t rs_more; /* more descriptors follow */ uint32_t rs_tstamp; /* h/w assigned timestamp */ uint32_t rs_antenna; /* antenna information */ -#ifdef AH_SUPPORT_AR5416 /* 802.11n status */ int8_t rs_rssi_ctl[3]; /* rx frame RSSI [ctl, chain 0-2] */ int8_t rs_rssi_ext[3]; /* rx frame RSSI [ext, chain 0-2] */ @@ -138,7 +120,6 @@ struct ath_rx_status { uint32_t rs_evm2; uint32_t rs_evm3; /* needed for ar9300 and later */ uint32_t rs_evm4; /* needed for ar9300 and later */ -#endif /* AH_SUPPORT_AR5416 */ }; /* bits found in rs_status */ @@ -241,11 +222,7 @@ enum { * to complete the work. Status for completed frames is returned * in a device-independent format. */ -#ifdef AH_SUPPORT_AR5416 #define HAL_DESC_HW_SIZE 20 -#else -#define HAL_DESC_HW_SIZE 4 -#endif /* AH_SUPPORT_AR5416 */ struct ath_desc { /* Modified: head/sys/dev/ath/ath_hal/ah_internal.h ============================================================================== --- head/sys/dev/ath/ath_hal/ah_internal.h Thu May 25 04:18:46 2017 (r318856) +++ head/sys/dev/ath/ath_hal/ah_internal.h Thu May 25 04:26:26 2017 (r318857) @@ -29,11 +29,6 @@ #include #include /* XXX for reasons */ -#include "opt_ah.h" /* needed for AH_SUPPORT_AR5416 */ - -#ifndef AH_SUPPORT_AR5416 -#define AH_SUPPORT_AR5416 1 -#endif #ifndef NBBY #define NBBY 8 /* number of bits/byte */ @@ -201,10 +196,8 @@ typedef struct { int8_t qCoff; int16_t rawNoiseFloor; int16_t noiseFloorAdjust; -#ifdef AH_SUPPORT_AR5416 int16_t noiseFloorCtl[AH_MAX_CHAINS]; int16_t noiseFloorExt[AH_MAX_CHAINS]; -#endif /* AH_SUPPORT_AR5416 */ uint16_t mainSpur; /* cached spur value for this channel */ /*XXX TODO: make these part of privFlags */ Modified: head/sys/dev/ath/if_ath_rx.c ============================================================================== --- head/sys/dev/ath/if_ath_rx.c Thu May 25 04:18:46 2017 (r318856) +++ head/sys/dev/ath/if_ath_rx.c Thu May 25 04:26:26 2017 (r318857) @@ -569,7 +569,8 @@ ath_rx_tap(struct ath_softc *sc, struct rix = rt->rateCodeToIndex[rs->rs_rate]; sc->sc_rx_th.wr_rate = sc->sc_hwmap[rix].ieeerate; sc->sc_rx_th.wr_flags = sc->sc_hwmap[rix].rxflags; -#ifdef AH_SUPPORT_AR5416 + + /* 802.11 specific flags */ sc->sc_rx_th.wr_chan_flags &= ~CHAN_HT; if (rs->rs_status & HAL_RXERR_PHY) { /* @@ -596,7 +597,6 @@ ath_rx_tap(struct ath_softc *sc, struct sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_SHORTGI; } -#endif sc->sc_rx_th.wr_tsf = htole64(ath_extend_tsf(sc, rs->rs_tstamp, tsf)); if (rs->rs_status & HAL_RXERR_CRC) sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_BADFCS; @@ -654,8 +654,7 @@ ath_rx_pkt(struct ath_softc *sc, struct */ rstamp = ath_extend_tsf(sc, rs->rs_tstamp, tsf); - /* These aren't specifically errors */ -#ifdef AH_SUPPORT_AR5416 + /* 802.11 return codes - These aren't specifically errors */ if (rs->rs_flags & HAL_RX_GI) sc->sc_stats.ast_rx_halfgi++; if (rs->rs_flags & HAL_RX_2040) @@ -670,7 +669,6 @@ ath_rx_pkt(struct ath_softc *sc, struct sc->sc_stats.ast_rx_hi_rx_chain++; if (rs->rs_flags & HAL_RX_STBC) sc->sc_stats.ast_rx_stbc++; -#endif /* AH_SUPPORT_AR5416 */ if (rs->rs_status != 0) { if (rs->rs_status & HAL_RXERR_CRC) @@ -906,11 +904,8 @@ rx_accept: IEEE80211_KEYIX_NONE : rs->rs_keyix); sc->sc_lastrs = rs; -#ifdef AH_SUPPORT_AR5416 if (rs->rs_isaggr) sc->sc_stats.ast_rx_agg++; -#endif /* AH_SUPPORT_AR5416 */ - /* * Populate the per-chain RSSI values where appropriate. From owner-svn-src-head@freebsd.org Thu May 25 05:01:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DFEA1D81214; Thu, 25 May 2017 05:01:45 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B06C91579; Thu, 25 May 2017 05:01:45 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P51iCc023540; Thu, 25 May 2017 05:01:44 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P51idC023539; Thu, 25 May 2017 05:01:44 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705250501.v4P51idC023539@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Thu, 25 May 2017 05:01:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318858 - 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.23 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, 25 May 2017 05:01:46 -0000 Author: adrian Date: Thu May 25 05:01:44 2017 New Revision: 318858 URL: https://svnweb.freebsd.org/changeset/base/318858 Log: Bump UPDATING to cover the ath shuffle. Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Thu May 25 04:26:26 2017 (r318857) +++ head/UPDATING Thu May 25 05:01:44 2017 (r318858) @@ -51,6 +51,31 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 ****************************** SPECIAL WARNING: ****************************** +20170524: + The ath(4) and ath_hal(4) modules now build piecemeal to allow for + smaller runtime footprint builds. This is useful for embedded systems + which only require one chipset support. + + If you load it as a module, make sure this is in /boot/loader.conf: + + if_ath_load="YES" + + This will load the HAL, all chip/RF backends and if_ath_pci. + If you have if_ath_pci in /boot/loader.conf, ensure it is after + if_ath or it will not load any HAL chipset support. + + If you want to selectively load things (eg on ye cheape ARM/MIPS + platforms where RAM is at a premium) you should: + + * load ath_hal + * load the chip modules in question + * load ath_rate, ath_dfs + * load ath_main + * load if_ath_pci and/or if_ath_ahb depending upon your particular + bus bind type - this is where probe/attach is done. + + For further comments/feedback, poke adrian@ . + 20170523: The "ino64" 64-bit inode project has been committed, which extends a number of types to 64 bits. Upgrading in place requires care and From owner-svn-src-head@freebsd.org Thu May 25 05:02:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53E5FD812CE; Thu, 25 May 2017 05:02:44 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 25F1018AF; Thu, 25 May 2017 05:02:44 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P52hVt024457; Thu, 25 May 2017 05:02:43 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P52hxs024455; Thu, 25 May 2017 05:02:43 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705250502.v4P52hxs024455@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Thu, 25 May 2017 05:02:43 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318859 - head/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.23 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, 25 May 2017 05:02:44 -0000 Author: adrian Date: Thu May 25 05:02:43 2017 New Revision: 318859 URL: https://svnweb.freebsd.org/changeset/base/318859 Log: [lib] disable libc++experimental on mips platforms for now. This breaks at least mips32 platform builds. Reviewed by: dim Modified: head/lib/Makefile Modified: head/lib/Makefile ============================================================================== --- head/lib/Makefile Thu May 25 05:01:44 2017 (r318858) +++ head/lib/Makefile Thu May 25 05:02:43 2017 (r318859) @@ -157,7 +157,7 @@ _libclang_rt= libclang_rt .if ${MK_LIBCPLUSPLUS} != "no" _libcxxrt= libcxxrt _libcplusplus= libc++ -.if ${MACHINE_CPUARCH} != "arm" +.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" _libcplusplus+= libc++experimental .endif .endif From owner-svn-src-head@freebsd.org Thu May 25 05:23:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A8647D81A72; Thu, 25 May 2017 05:23:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7787B1471; Thu, 25 May 2017 05:23:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P5Nl5T032457; Thu, 25 May 2017 05:23:47 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P5NlJg032455; Thu, 25 May 2017 05:23:47 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201705250523.v4P5NlJg032455@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Thu, 25 May 2017 05:23:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318860 - in head/sys: dev/sound/pcm tools/sound 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.23 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, 25 May 2017 05:23:48 -0000 Author: hselasky Date: Thu May 25 05:23:47 2017 New Revision: 318860 URL: https://svnweb.freebsd.org/changeset/base/318860 Log: Declare the "snd_fxdiv_table" once. This shaves around 24Kbytes of binary data from sound.ko and the kernel. MFC after: 3 days Modified: head/sys/dev/sound/pcm/buffer.c head/sys/tools/sound/snd_fxdiv_gen.awk Modified: head/sys/dev/sound/pcm/buffer.c ============================================================================== --- head/sys/dev/sound/pcm/buffer.c Thu May 25 05:02:43 2017 (r318859) +++ head/sys/dev/sound/pcm/buffer.c Thu May 25 05:23:47 2017 (r318860) @@ -35,6 +35,7 @@ #include "feeder_if.h" #define SND_USE_FXDIV +#define SND_DECLARE_FXDIV #include "snd_fxdiv_gen.h" SND_DECLARE_FILE("$FreeBSD$"); Modified: head/sys/tools/sound/snd_fxdiv_gen.awk ============================================================================== --- head/sys/tools/sound/snd_fxdiv_gen.awk Thu May 25 05:02:43 2017 (r318859) +++ head/sys/tools/sound/snd_fxdiv_gen.awk Thu May 25 05:23:47 2017 (r318860) @@ -108,7 +108,10 @@ BEGIN { printf(" * 508 = SND_CHN_MAX * PCM_32_BPS, which is why....\n"); printf(" */\n\n"); - printf("static const uint32_t snd_fxdiv_table[][2] = {\n"); + printf("extern const uint32_t snd_fxdiv_table[%d][2];\n\n", SND_MAX_ALIGN + 1); + + printf("#ifdef SND_DECLARE_FXDIV\n"); + printf("const uint32_t snd_fxdiv_table[%d][2] = {\n", SND_MAX_ALIGN + 1); for (i = 1; i <= SND_MAX_ALIGN; i++) { if (aligns[i] != 1) @@ -120,7 +123,7 @@ BEGIN { i, r["mul"], r["shift"]); } - printf("};\n\n"); + printf("};\n#endif\n\n"); printf("#define SND_FXDIV_MAX\t\t0x%08x\n", FXONE); printf("#define SND_FXDIV(x, y)\t\t(((uint32_t)(x) *\t\t\t\\\n"); From owner-svn-src-head@freebsd.org Thu May 25 08:34:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 36A6AD725BE; Thu, 25 May 2017 08:34:26 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 088D41A0E; Thu, 25 May 2017 08:34:25 +0000 (UTC) (envelope-from trasz@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P8YP9r008614; Thu, 25 May 2017 08:34:25 GMT (envelope-from trasz@FreeBSD.org) Received: (from trasz@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P8YPIC008613; Thu, 25 May 2017 08:34:25 GMT (envelope-from trasz@FreeBSD.org) Message-Id: <201705250834.v4P8YPIC008613@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: trasz set sender to trasz@FreeBSD.org using -f From: Edward Tomasz Napierala Date: Thu, 25 May 2017 08:34:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318861 - head/etc/mtree 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.23 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, 25 May 2017 08:34:26 -0000 Author: trasz Date: Thu May 25 08:34:24 2017 New Revision: 318861 URL: https://svnweb.freebsd.org/changeset/base/318861 Log: Create /net by default, for autofs. MFC after: 2 weeks Modified: head/etc/mtree/BSD.root.dist Modified: head/etc/mtree/BSD.root.dist ============================================================================== --- head/etc/mtree/BSD.root.dist Thu May 25 05:23:47 2017 (r318860) +++ head/etc/mtree/BSD.root.dist Thu May 25 08:34:24 2017 (r318861) @@ -97,6 +97,8 @@ .. mnt .. + net + .. proc mode=0555 .. rescue From owner-svn-src-head@freebsd.org Thu May 25 09:21:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D602DD81819; Thu, 25 May 2017 09:21:22 +0000 (UTC) (envelope-from jlh@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A844B1248; Thu, 25 May 2017 09:21:22 +0000 (UTC) (envelope-from jlh@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4P9LLaA026246; Thu, 25 May 2017 09:21:21 GMT (envelope-from jlh@FreeBSD.org) Received: (from jlh@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4P9LL5G026245; Thu, 25 May 2017 09:21:21 GMT (envelope-from jlh@FreeBSD.org) Message-Id: <201705250921.v4P9LL5G026245@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jlh set sender to jlh@FreeBSD.org using -f From: Jeremie Le Hen Date: Thu, 25 May 2017 09:21:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318863 - 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.23 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, 25 May 2017 09:21:22 -0000 Author: jlh Date: Thu May 25 09:21:21 2017 New Revision: 318863 URL: https://svnweb.freebsd.org/changeset/base/318863 Log: Replace stale handbook URL with the proper on. MFC after: 0 days Modified: head/UPDATING Modified: head/UPDATING ============================================================================== --- head/UPDATING Thu May 25 08:53:55 2017 (r318862) +++ head/UPDATING Thu May 25 09:21:21 2017 (r318863) @@ -6,7 +6,7 @@ COMMON ITEMS: section later in the file. basically know what you are doing. If not, then please consult the FreeBSD handbook: - http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/makeworld.html + https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/updating-src.html Items affecting the ports and packages system can be found in /usr/ports/UPDATING. Please read that file before running portupgrade. From owner-svn-src-head@freebsd.org Thu May 25 10:49:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1CFC4D80B10; Thu, 25 May 2017 10:49:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DE1DD113D; Thu, 25 May 2017 10:49:57 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PAnuc3062388; Thu, 25 May 2017 10:49:56 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PAnuEX062387; Thu, 25 May 2017 10:49:56 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705251049.v4PAnuEX062387@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Thu, 25 May 2017 10:49:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318867 - head/sys/dev/vmware/vmxnet3 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.23 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, 25 May 2017 10:49:58 -0000 Author: avg Date: Thu May 25 10:49:56 2017 New Revision: 318867 URL: https://svnweb.freebsd.org/changeset/base/318867 Log: fix vmxnet3 crash when LRO is enabled The crash can occur when all of the following conditions are true: - a packet consists of multiple segements (requires LRO enabled) - there has been a failure to allocate an mbuf for the packet and the packet has to be dropped - a host (vmware) still owned at least one segment of the packet, so the driver had to wait for another interrupt to proceed to discarding the remaning segment(s) Reviewed by: rstone MFC after: 2 weeks Sponsored by: Panzura Differential Revision: https://reviews.freebsd.org/D10874 Modified: head/sys/dev/vmware/vmxnet3/if_vmx.c Modified: head/sys/dev/vmware/vmxnet3/if_vmx.c ============================================================================== --- head/sys/dev/vmware/vmxnet3/if_vmx.c Thu May 25 10:47:18 2017 (r318866) +++ head/sys/dev/vmware/vmxnet3/if_vmx.c Thu May 25 10:49:56 2017 (r318867) @@ -2194,6 +2194,20 @@ vmxnet3_rxq_eof(struct vmxnet3_rxqueue * } else { KASSERT(rxd->btype == VMXNET3_BTYPE_BODY, ("%s: non start of frame w/o body buffer", __func__)); + + if (m_head == NULL && m_tail == NULL) { + /* + * This is a continuation of a packet that we + * started to drop, but could not drop entirely + * because this segment was still owned by the + * host. So, drop the remainder now. + */ + vmxnet3_rxq_eof_discard(rxq, rxr, idx); + if (!rxcd->eop) + vmxnet3_rxq_discard_chain(rxq); + goto nextp; + } + KASSERT(m_head != NULL, ("%s: frame not started?", __func__)); From owner-svn-src-head@freebsd.org Thu May 25 12:53:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A8C1BD815C3; Thu, 25 May 2017 12:53:50 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 789C31F9D; Thu, 25 May 2017 12:53:50 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PCrn4b014937; Thu, 25 May 2017 12:53:49 GMT (envelope-from gjb@FreeBSD.org) Received: (from gjb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PCrnfP014936; Thu, 25 May 2017 12:53:49 GMT (envelope-from gjb@FreeBSD.org) Message-Id: <201705251253.v4PCrnfP014936@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gjb set sender to gjb@FreeBSD.org using -f From: Glen Barber Date: Thu, 25 May 2017 12:53:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318872 - head/release/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.23 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, 25 May 2017 12:53:50 -0000 Author: gjb Date: Thu May 25 12:53:49 2017 New Revision: 318872 URL: https://svnweb.freebsd.org/changeset/base/318872 Log: Enable DHCP and IPv6 autoconfig on non-cloud VM images. PR: 203653 MFC after: 3 days Sponsored by: The FreeBSD Foundation Modified: head/release/tools/vmimage.subr Modified: head/release/tools/vmimage.subr ============================================================================== --- head/release/tools/vmimage.subr Thu May 25 12:04:23 2017 (r318871) +++ head/release/tools/vmimage.subr Thu May 25 12:53:49 2017 (r318872) @@ -157,6 +157,11 @@ vm_extra_enable_services() { done fi + if [ -z "${VMCONFIG}" -o -c "${VMCONFIG}" ]; then + echo 'ifconfig_DEFAULT="DHCP inet6 accept_rtadv"' >> \ + ${DESTDIR}/etc/rc.conf + fi + return 0 } From owner-svn-src-head@freebsd.org Thu May 25 12:57:16 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AC1B1D81675; Thu, 25 May 2017 12:57:16 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 733D91194; Thu, 25 May 2017 12:57:16 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PCvFM1015132; Thu, 25 May 2017 12:57:15 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PCvFeB015131; Thu, 25 May 2017 12:57:15 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251257.v4PCvFeB015131@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 12:57:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318873 - head/share/doc/papers/timecounter 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.23 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, 25 May 2017 12:57:16 -0000 Author: bapt Date: Thu May 25 12:57:15 2017 New Revision: 318873 URL: https://svnweb.freebsd.org/changeset/base/318873 Log: Fix rendering with modern groff Reported by: tj Modified: head/share/doc/papers/timecounter/timecounter.ms Modified: head/share/doc/papers/timecounter/timecounter.ms ============================================================================== --- head/share/doc/papers/timecounter/timecounter.ms Thu May 25 12:53:49 2017 (r318872) +++ head/share/doc/papers/timecounter/timecounter.ms Thu May 25 12:57:15 2017 (r318873) @@ -17,7 +17,6 @@ Timecounters: Efficient and precise time .AA .A "Poul-Henning Kamp" "The FreeBSD Project" .AB -.PP The FreeBSD timecounters are an architecture-independent implementation of a binary timescale using whatever hardware support is at hand for tracking time. The binary timescale converts using simple @@ -31,6 +30,7 @@ be detailed as well as the mechanisms us .FS This paper was presented at the EuroBSDcon 2002 conference in Amsterdam. .FE +.1C .SH Introduction .PP From owner-svn-src-head@freebsd.org Thu May 25 14:16:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 40960D814E2; Thu, 25 May 2017 14:16:45 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 12D231577; Thu, 25 May 2017 14:16:45 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEGioG048625; Thu, 25 May 2017 14:16:44 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEGiD2048624; Thu, 25 May 2017 14:16:44 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251416.v4PEGiD2048624@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:16:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318874 - head/sys/arm/mv 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.23 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, 25 May 2017 14:16:45 -0000 Author: zbb Date: Thu May 25 14:16:43 2017 New Revision: 318874 URL: https://svnweb.freebsd.org/changeset/base/318874 Log: Fix memory corruption while configuring CPU windows on Marvell SoCs Resolving CPU windows from localbus entry caused buffer overflow and memory corruption. Fix wrong indexing and ensure the index does not exceed table size. Submitted by: Wojciech Macek Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10720 Modified: head/sys/arm/mv/mv_common.c Modified: head/sys/arm/mv/mv_common.c ============================================================================== --- head/sys/arm/mv/mv_common.c Thu May 25 12:57:15 2017 (r318873) +++ head/sys/arm/mv/mv_common.c Thu May 25 14:16:43 2017 (r318874) @@ -2269,6 +2269,12 @@ win_cpu_from_dt(void) entry_size = tuple_size / sizeof(pcell_t); cpu_wins_no = tuples; + /* Check range */ + if (tuples > nitems(cpu_win_tbl)) { + debugf("too many tuples to fit into cpu_win_tbl\n"); + return (ENOMEM); + } + for (i = 0, t = 0; t < tuples; i += entry_size, t++) { cpu_win_tbl[t].target = 1; cpu_win_tbl[t].attr = fdt32_to_cpu(ranges[i + 1]); @@ -2301,6 +2307,12 @@ moveon: if (fdt_regsize(node, &sram_base, &sram_size) != 0) return (EINVAL); + /* Check range */ + if (t >= nitems(cpu_win_tbl)) { + debugf("cannot fit CESA tuple into cpu_win_tbl\n"); + return (ENOMEM); + } + cpu_win_tbl[t].target = MV_WIN_CESA_TARGET; #ifdef SOC_MV_ARMADA38X cpu_win_tbl[t].attr = MV_WIN_CESA_ATTR(0); From owner-svn-src-head@freebsd.org Thu May 25 14:19:21 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B8B1AD81599; Thu, 25 May 2017 14:19:21 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 88BB81749; Thu, 25 May 2017 14:19:21 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEJK1E048765; Thu, 25 May 2017 14:19:20 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEJKfU048763; Thu, 25 May 2017 14:19:20 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251419.v4PEJKfU048763@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:19:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318875 - in head/sys/arm/mv: . armada38x 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.23 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, 25 May 2017 14:19:21 -0000 Author: zbb Date: Thu May 25 14:19:20 2017 New Revision: 318875 URL: https://svnweb.freebsd.org/changeset/base/318875 Log: Enable SCU Speculative linefills to L2 on Armada 38x Submitted by: Marcin Wojtas Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10709 Modified: head/sys/arm/mv/armada38x/armada38x.c head/sys/arm/mv/mvreg.h Modified: head/sys/arm/mv/armada38x/armada38x.c ============================================================================== --- head/sys/arm/mv/armada38x/armada38x.c Thu May 25 14:16:43 2017 (r318874) +++ head/sys/arm/mv/armada38x/armada38x.c Thu May 25 14:19:20 2017 (r318875) @@ -173,9 +173,13 @@ armada38x_scu_enable(void) /* Enable SCU */ val = bus_space_read_4(fdtbus_bs_tag, vaddr_scu, MV_SCU_REG_CTRL); - if (!(val & MV_SCU_ENABLE)) + if (!(val & MV_SCU_ENABLE)) { + /* Enable SCU Speculative linefills to L2 */ + val |= MV_SCU_SL_L2_ENABLE; + bus_space_write_4(fdtbus_bs_tag, vaddr_scu, 0, val | MV_SCU_ENABLE); + } bus_space_unmap(fdtbus_bs_tag, vaddr_scu, MV_SCU_REGS_LEN); return (0); Modified: head/sys/arm/mv/mvreg.h ============================================================================== --- head/sys/arm/mv/mvreg.h Thu May 25 14:16:43 2017 (r318874) +++ head/sys/arm/mv/mvreg.h Thu May 25 14:19:20 2017 (r318875) @@ -424,7 +424,8 @@ #define MV_SCU_REGS_LEN 0x100 #define MV_SCU_REG_CTRL 0x00 #define MV_SCU_REG_CONFIG 0x04 -#define MV_SCU_ENABLE 1 +#define MV_SCU_ENABLE (1 << 0) +#define MV_SCU_SL_L2_ENABLE (1 << 3) #define SCU_CFG_REG_NCPU_MASK 0x3 #endif From owner-svn-src-head@freebsd.org Thu May 25 14:22:02 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 92CBCD8191F; Thu, 25 May 2017 14:22:02 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 63D811C98; Thu, 25 May 2017 14:22:02 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEM1Q4051945; Thu, 25 May 2017 14:22:01 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEM1SH051942; Thu, 25 May 2017 14:22:01 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251422.v4PEM1SH051942@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:22:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318876 - in head/sys/arm/mv: . armada armada38x 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.23 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, 25 May 2017 14:22:02 -0000 Author: zbb Date: Thu May 25 14:22:00 2017 New Revision: 318876 URL: https://svnweb.freebsd.org/changeset/base/318876 Log: Introduce separate watchdog driver for Armada to fix phony DELAY DELAY is a problematic routine called all over the kernel. Armada38x using CA-9 CPUs are using mpcore timer to count events and measure time but DELAY in the mpcore timer code is a weak function reference and therefore will be replaced by the platform implementation if the one is introduced. Since Armada38x uses on-chip watchdog to which the driver is merged with the on-chip timer driver there will be a platform DELAY implementation. The latter however will not use any HW timers as it will not attempt to configure any. Phony busy loop will be used instead. To fix that we introduce a separate watchdog driver for Armada platforms, (currently only A38X) and stop using Marvell timer driver. That switches DELAY to the desired implementation. Submitted by: Zbigniew Bodek Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10710 Added: head/sys/arm/mv/armada/wdt.c (contents, props changed) Modified: head/sys/arm/mv/armada38x/files.armada38x head/sys/arm/mv/files.mv Added: head/sys/arm/mv/armada/wdt.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/arm/mv/armada/wdt.c Thu May 25 14:22:00 2017 (r318876) @@ -0,0 +1,285 @@ +/*- + * Copyright (c) 2006 Benno Rice. + * Copyright (C) 2007-2008 MARVELL INTERNATIONAL LTD. + * All rights reserved. + * + * Adapted to Marvell SoC by Semihalf. + * + * 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 ``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 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. + * + * from: FreeBSD: //depot/projects/arm/src/sys/arm/xscale/pxa2x0/pxa2x0_timer.c, rev 1 + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include + +#define INITIAL_TIMECOUNTER (0xffffffff) +#define MAX_WATCHDOG_TICKS (0xffffffff) + +#if defined(SOC_MV_ARMADAXP) || defined(SOC_MV_ARMADA38X) +#define MV_CLOCK_SRC 25000000 /* Timers' 25MHz mode */ +#else +#define MV_CLOCK_SRC get_tclk() +#endif + +#if defined(SOC_MV_ARMADA38X) +#define WATCHDOG_TIMER 4 +#else +#define WATCHDOG_TIMER 2 +#endif + +struct mv_wdt_softc { + struct resource * wdt_res; + struct mtx wdt_mtx; +}; + +static struct resource_spec mv_wdt_spec[] = { + { SYS_RES_MEMORY, 0, RF_ACTIVE }, + { -1, 0 } +}; + +static struct ofw_compat_data mv_wdt_compat[] = { + {"marvell,armada-380-wdt", true}, + {NULL, false} +}; + +static struct mv_wdt_softc *wdt_softc = NULL; +int timers_initialized = 0; + +static int mv_wdt_probe(device_t); +static int mv_wdt_attach(device_t); + +static uint32_t mv_get_timer_control(void); +static void mv_set_timer_control(uint32_t); +static void mv_set_timer(uint32_t, uint32_t); + +static void mv_watchdog_enable(void); +static void mv_watchdog_disable(void); +static void mv_watchdog_event(void *, unsigned int, int *); + +static device_method_t mv_wdt_methods[] = { + DEVMETHOD(device_probe, mv_wdt_probe), + DEVMETHOD(device_attach, mv_wdt_attach), + + { 0, 0 } +}; + +static driver_t mv_wdt_driver = { + "wdt", + mv_wdt_methods, + sizeof(struct mv_wdt_softc), +}; + +static devclass_t mv_wdt_devclass; + +DRIVER_MODULE(wdt, simplebus, mv_wdt_driver, mv_wdt_devclass, 0, 0); +static int +mv_wdt_probe(device_t dev) +{ + + if (!ofw_bus_status_okay(dev)) + return (ENXIO); + + if (!ofw_bus_search_compatible(dev, mv_wdt_compat)->ocd_data) + return (ENXIO); + + device_set_desc(dev, "Marvell Watchdog Timer"); + return (0); +} + +static int +mv_wdt_attach(device_t dev) +{ + struct mv_wdt_softc *sc; + int error; + + if (wdt_softc != NULL) + return (ENXIO); + + sc = device_get_softc(dev); + wdt_softc = sc; + + error = bus_alloc_resources(dev, mv_wdt_spec, &sc->wdt_res); + if (error) { + device_printf(dev, "could not allocate resources\n"); + return (ENXIO); + } + + mtx_init(&sc->wdt_mtx, "watchdog", NULL, MTX_DEF); + + mv_watchdog_disable(); + EVENTHANDLER_REGISTER(watchdog_list, mv_watchdog_event, sc, 0); + + return (0); +} + +static __inline uint32_t +mv_get_timer_control(void) +{ + + return (bus_read_4(wdt_softc->wdt_res, CPU_TIMER_CONTROL)); +} + +static __inline void +mv_set_timer_control(uint32_t val) +{ + + bus_write_4(wdt_softc->wdt_res, CPU_TIMER_CONTROL, val); +} + +static __inline void +mv_set_timer(uint32_t timer, uint32_t val) +{ + + bus_write_4(wdt_softc->wdt_res, CPU_TIMER0 + timer * 0x8, val); +} + +static void +mv_watchdog_enable(void) +{ + uint32_t val, irq_cause; +#if !defined(SOC_MV_ARMADAXP) && !defined(SOC_MV_ARMADA38X) + uint32_t irq_mask; +#endif + + irq_cause = read_cpu_ctrl(BRIDGE_IRQ_CAUSE); + irq_cause &= IRQ_TIMER_WD_CLR; + write_cpu_ctrl(BRIDGE_IRQ_CAUSE, irq_cause); + +#if defined(SOC_MV_ARMADAXP) || defined(SOC_MV_ARMADA38X) + val = read_cpu_mp_clocks(WD_RSTOUTn_MASK); + val |= (WD_GLOBAL_MASK | WD_CPU0_MASK); + write_cpu_mp_clocks(WD_RSTOUTn_MASK, val); + + val = read_cpu_misc(RSTOUTn_MASK); + val &= ~RSTOUTn_MASK_WD; + write_cpu_misc(RSTOUTn_MASK, val); +#else + irq_mask = read_cpu_ctrl(BRIDGE_IRQ_MASK); + irq_mask |= IRQ_TIMER_WD_MASK; + write_cpu_ctrl(BRIDGE_IRQ_MASK, irq_mask); + + val = read_cpu_ctrl(RSTOUTn_MASK); + val |= WD_RST_OUT_EN; + write_cpu_ctrl(RSTOUTn_MASK, val); +#endif + + val = mv_get_timer_control(); +#if defined(SOC_MV_ARMADA38X) + val |= CPU_TIMER_WD_EN | CPU_TIMER_WD_AUTO | CPU_TIMER_WD_25MHZ_EN; +#elif defined(SOC_MV_ARMADAXP) + val |= CPU_TIMER2_EN | CPU_TIMER2_AUTO | CPU_TIMER_WD_25MHZ_EN; +#else + val |= CPU_TIMER2_EN | CPU_TIMER2_AUTO; +#endif + mv_set_timer_control(val); +} + +static void +mv_watchdog_disable(void) +{ + uint32_t val, irq_cause; +#if !defined(SOC_MV_ARMADAXP) && !defined(SOC_MV_ARMADA38X) + uint32_t irq_mask; +#endif + + val = mv_get_timer_control(); +#if defined(SOC_MV_ARMADA38X) + val &= ~(CPU_TIMER_WD_EN | CPU_TIMER_WD_AUTO); +#else + val &= ~(CPU_TIMER2_EN | CPU_TIMER2_AUTO); +#endif + mv_set_timer_control(val); + +#if defined(SOC_MV_ARMADAXP) || defined(SOC_MV_ARMADA38X) + val = read_cpu_mp_clocks(WD_RSTOUTn_MASK); + val &= ~(WD_GLOBAL_MASK | WD_CPU0_MASK); + write_cpu_mp_clocks(WD_RSTOUTn_MASK, val); + + val = read_cpu_misc(RSTOUTn_MASK); + val |= RSTOUTn_MASK_WD; + write_cpu_misc(RSTOUTn_MASK, RSTOUTn_MASK_WD); +#else + val = read_cpu_ctrl(RSTOUTn_MASK); + val &= ~WD_RST_OUT_EN; + write_cpu_ctrl(RSTOUTn_MASK, val); + + irq_mask = read_cpu_ctrl(BRIDGE_IRQ_MASK); + irq_mask &= ~(IRQ_TIMER_WD_MASK); + write_cpu_ctrl(BRIDGE_IRQ_MASK, irq_mask); +#endif + + irq_cause = read_cpu_ctrl(BRIDGE_IRQ_CAUSE); + irq_cause &= IRQ_TIMER_WD_CLR; + write_cpu_ctrl(BRIDGE_IRQ_CAUSE, irq_cause); +} + +/* + * Watchdog event handler. + */ +static void +mv_watchdog_event(void *arg, unsigned int cmd, int *error) +{ + struct mv_wdt_softc *sc; + uint64_t ns; + uint64_t ticks; + + sc = arg; + mtx_lock(&sc->wdt_mtx); + if (cmd == 0) + mv_watchdog_disable(); + else { + /* + * Watchdog timeout is in nanosecs, calculation according to + * watchdog(9) + */ + ns = (uint64_t)1 << (cmd & WD_INTERVAL); + ticks = (uint64_t)(ns * MV_CLOCK_SRC) / 1000000000; + if (ticks > MAX_WATCHDOG_TICKS) + mv_watchdog_disable(); + else { + mv_set_timer(WATCHDOG_TIMER, ticks); + mv_watchdog_enable(); + *error = 0; + } + } + mtx_unlock(&sc->wdt_mtx); +} Modified: head/sys/arm/mv/armada38x/files.armada38x ============================================================================== --- head/sys/arm/mv/armada38x/files.armada38x Thu May 25 14:19:20 2017 (r318875) +++ head/sys/arm/mv/armada38x/files.armada38x Thu May 25 14:22:00 2017 (r318876) @@ -2,6 +2,7 @@ arm/mv/mpic.c standard arm/mv/armada/thermal.c optional fdt +arm/mv/armada/wdt.c optional fdt arm/mv/armada38x/armada38x.c standard arm/mv/armada38x/armada38x_mp.c optional smp Modified: head/sys/arm/mv/files.mv ============================================================================== --- head/sys/arm/mv/files.mv Thu May 25 14:19:20 2017 (r318875) +++ head/sys/arm/mv/files.mv Thu May 25 14:22:00 2017 (r318876) @@ -18,7 +18,7 @@ arm/mv/mv_localbus.c standard arm/mv/mv_machdep.c standard arm/mv/mv_pci.c optional pci arm/mv/mv_ts.c standard -arm/mv/timer.c standard +arm/mv/timer.c optional !soc_mv_armada38x dev/cesa/cesa.c optional cesa dev/iicbus/twsi/mv_twsi.c optional twsi From owner-svn-src-head@freebsd.org Thu May 25 14:23:51 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1D866D81A48; Thu, 25 May 2017 14:23:51 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E14FE1FAC; Thu, 25 May 2017 14:23:50 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PENnbp053100; Thu, 25 May 2017 14:23:49 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PENn1w053099; Thu, 25 May 2017 14:23:49 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251423.v4PENn1w053099@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:23:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318877 - head/sys/arm/mv 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.23 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, 25 May 2017 14:23:51 -0000 Author: zbb Date: Thu May 25 14:23:49 2017 New Revision: 318877 URL: https://svnweb.freebsd.org/changeset/base/318877 Log: Fix PM recognition on recent Marvell boards PM status is only supported on Kirkwood and Disvovery. Cleanup the code to properly report its state on other platforms. Submitted by: Wojciech Macek Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10718 Modified: head/sys/arm/mv/mv_common.c Modified: head/sys/arm/mv/mv_common.c ============================================================================== --- head/sys/arm/mv/mv_common.c Thu May 25 14:22:00 2017 (r318876) +++ head/sys/arm/mv/mv_common.c Thu May 25 14:23:49 2017 (r318877) @@ -133,6 +133,16 @@ const struct decode_win *cpu_wins = cpu_ typedef void (*decode_win_setup_t)(u_long); typedef void (*dump_win_t)(u_long); +/* + * The power status of device feature is only supported on + * Kirkwood and Discovery SoCs. + */ +#if defined(SOC_MV_KIRKWOOD) || defined(SOC_MV_DISCOVERY) +#define SOC_MV_POWER_STAT_SUPPORTED 1 +#else +#define SOC_MV_POWER_STAT_SUPPORTED 0 +#endif + struct soc_node_spec { const char *compat; decode_win_setup_t decode_handler; @@ -174,10 +184,10 @@ static struct fdt_pm_mask_entry fdt_pm_m static __inline int pm_is_disabled(uint32_t mask) { -#if defined(SOC_MV_KIRKWOOD) - return (soc_power_ctrl_get(mask) == mask); -#else +#if SOC_MV_POWER_STAT_SUPPORTED return (soc_power_ctrl_get(mask) == mask ? 0 : 1); +#else + return (0); #endif } @@ -364,7 +374,7 @@ uint32_t soc_power_ctrl_get(uint32_t mask) { -#if !defined(SOC_MV_ORION) +#if SOC_MV_POWER_STAT_SUPPORTED if (mask != CPU_PM_CTRL_NONE) mask &= read_cpu_ctrl(CPU_PM_CTRL); @@ -1168,7 +1178,6 @@ decode_win_usb_setup(u_long base) uint32_t br, cr; int i, j; - if (pm_is_disabled(CPU_PM_CTRL_USB(usb_port))) return; From owner-svn-src-head@freebsd.org Thu May 25 14:25:06 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 55641D81B9F; Thu, 25 May 2017 14:25:06 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 27B6112A0; Thu, 25 May 2017 14:25:06 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEP56k053191; Thu, 25 May 2017 14:25:05 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEP5SO053190; Thu, 25 May 2017 14:25:05 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251425.v4PEP5SO053190@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:25:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318878 - head/sys/arm/mv 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.23 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, 25 May 2017 14:25:06 -0000 Author: zbb Date: Thu May 25 14:25:05 2017 New Revision: 318878 URL: https://svnweb.freebsd.org/changeset/base/318878 Log: Add workaround for CESA MBUS windows with 4GB DRAM Armada 38x SoC's equipped with 4GB DRAM suffer freeze during CESA operation, if MBUS window opened at given DRAM CS reaches end of the address space. Apply a workaround by setting the window size to the closest possible value, i.e. divide it by 2 (it has to be power-of-2). Submitted by: Marcin Wojtas Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D10724 Modified: head/sys/arm/mv/mv_common.c Modified: head/sys/arm/mv/mv_common.c ============================================================================== --- head/sys/arm/mv/mv_common.c Thu May 25 14:23:49 2017 (r318877) +++ head/sys/arm/mv/mv_common.c Thu May 25 14:25:05 2017 (r318878) @@ -1116,6 +1116,7 @@ static void decode_win_cesa_setup(u_long base) { uint32_t br, cr; + uint64_t size; int i, j; for (i = 0; i < MV_WIN_CESA_MAX; i++) { @@ -1128,7 +1129,21 @@ decode_win_cesa_setup(u_long base) if (ddr_is_active(i)) { br = ddr_base(i); - cr = (((ddr_size(i) - 1) & 0xffff0000) | + size = ddr_size(i); +#ifdef SOC_MV_ARMADA38X + /* + * Armada 38x SoC's equipped with 4GB DRAM + * suffer freeze during CESA operation, if + * MBUS window opened at given DRAM CS reaches + * end of the address space. Apply a workaround + * by setting the window size to the closest possible + * value, i.e. divide it by 2. + */ + if (size + ddr_base(i) == 0x100000000ULL) + size /= 2; +#endif + + cr = (((size - 1) & 0xffff0000) | (ddr_attr(i) << IO_WIN_ATTR_SHIFT) | (ddr_target(i) << IO_WIN_TGT_SHIFT) | IO_WIN_ENA_MASK); From owner-svn-src-head@freebsd.org Thu May 25 14:27:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2E7FAD81E82; Thu, 25 May 2017 14:27:56 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E59E71713; Thu, 25 May 2017 14:27:55 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PERsZX053454; Thu, 25 May 2017 14:27:54 GMT (envelope-from tuexen@FreeBSD.org) Received: (from tuexen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PERsWK053449; Thu, 25 May 2017 14:27:54 GMT (envelope-from tuexen@FreeBSD.org) Message-Id: <201705251427.v4PERsWK053449@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tuexen set sender to tuexen@FreeBSD.org using -f From: Michael Tuexen Date: Thu, 25 May 2017 14:27:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318879 - in head: lib/libsysdecode usr.bin/truss 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.23 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, 25 May 2017 14:27:56 -0000 Author: tuexen Date: Thu May 25 14:27:54 2017 New Revision: 318879 URL: https://svnweb.freebsd.org/changeset/base/318879 Log: Improve the decoding of the third argument of the socket() call. Decoding of the third argument depends on the first one. For doing this, add a corresponding function to libsysdecode. Thanks to jhb@ for suggesting this. Added: head/lib/libsysdecode/sysdecode_socket_protocol.3 (contents, props changed) Modified: head/lib/libsysdecode/Makefile head/lib/libsysdecode/flags.c head/lib/libsysdecode/sysdecode.h head/usr.bin/truss/syscalls.c Modified: head/lib/libsysdecode/Makefile ============================================================================== --- head/lib/libsysdecode/Makefile Thu May 25 14:25:05 2017 (r318878) +++ head/lib/libsysdecode/Makefile Thu May 25 14:27:54 2017 (r318879) @@ -22,6 +22,7 @@ MAN= sysdecode.3 \ sysdecode_quotactl_cmd.3 \ sysdecode_sigcode.3 \ sysdecode_sockopt_name.3 \ + sysdecode_socket_protocol.3 \ sysdecode_syscallnames.3 \ sysdecode_utrace.3 MLINKS= sysdecode_abi_to_freebsd_errno.3 sysdecode_freebsd_to_abi_errno.3 Modified: head/lib/libsysdecode/flags.c ============================================================================== --- head/lib/libsysdecode/flags.c Thu May 25 14:25:05 2017 (r318878) +++ head/lib/libsysdecode/flags.c Thu May 25 14:27:54 2017 (r318879) @@ -730,6 +730,19 @@ sysdecode_socketdomain(int domain) } const char * +sysdecode_socket_protocol(int domain, int protocol) +{ + + switch (domain) { + case PF_INET: + case PF_INET6: + return (lookup_value(sockipproto, protocol)); + default: + return (NULL); + } +} + +const char * sysdecode_sockaddr_family(int sa_family) { Modified: head/lib/libsysdecode/sysdecode.h ============================================================================== --- head/lib/libsysdecode/sysdecode.h Thu May 25 14:25:05 2017 (r318878) +++ head/lib/libsysdecode/sysdecode.h Thu May 25 14:27:54 2017 (r318879) @@ -99,6 +99,7 @@ const char *sysdecode_sigsegv_code(int _ const char *sysdecode_sigtrap_code(int _si_code); const char *sysdecode_sockaddr_family(int _sa_family); const char *sysdecode_socketdomain(int _domain); +const char *sysdecode_socket_protocol(int _domain, int _protocol); bool sysdecode_socket_type(FILE *_fp, int _type, int *_rem); const char *sysdecode_sockopt_level(int _level); const char *sysdecode_sockopt_name(int _level, int _optname); Added: head/lib/libsysdecode/sysdecode_socket_protocol.3 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libsysdecode/sysdecode_socket_protocol.3 Thu May 25 14:27:54 2017 (r318879) @@ -0,0 +1,54 @@ +.\" +.\" Copyright (c) 2016 John Baldwin +.\" 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$ +.\" +.Dd May 25, 2017 +.Dt sysdecode_socket_protocol 3 +.Os +.Sh NAME +.Nm sysdecode_socket_protocol +.Nd lookup name of socket protocol +.Sh LIBRARY +.Lb libsysdecode +.Sh SYNOPSIS +.In sys/types.h +.In stdbool.h +.In sysdecode.h +.Ft const char * +.Fn sysdecode_socket_protocol "int domain" "int protocol" +.Sh DESCRIPTION +The +.Fn sysdecode_socket_protocol +function returns a text description of the protocol passed in the +.Fa protocol +argument to +.Xr socket 2 . +.Fn sysdecode_socket_protocol +takes the +.Fa protocol +as well as the +.Fa domain +to uniquely identify the protocol. Modified: head/usr.bin/truss/syscalls.c ============================================================================== --- head/usr.bin/truss/syscalls.c Thu May 25 14:25:05 2017 (r318878) +++ head/usr.bin/truss/syscalls.c Thu May 25 14:27:54 2017 (r318879) @@ -1938,13 +1938,20 @@ print_arg(struct syscall_args *sc, unsig fprintf(fp, "%u", (socklen_t)args[sc->offset]); break; case Sockprotocol: { - int protocol; + const char *temp; + int domain, protocol; + domain = args[sc->offset - 2]; protocol = args[sc->offset]; if (protocol == 0) { fputs("0", fp); } else { - print_integer_arg(sysdecode_ipproto, fp, protocol); + temp = sysdecode_socket_protocol(domain, protocol); + if (temp) { + fputs(temp, fp); + } else { + fprintf(fp, "%d", protocol); + } } break; } From owner-svn-src-head@freebsd.org Thu May 25 14:34:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3D178D811D7; Thu, 25 May 2017 14:34:23 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0A4AD1C28; Thu, 25 May 2017 14:34:22 +0000 (UTC) (envelope-from zbb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEYL8q057350; Thu, 25 May 2017 14:34:21 GMT (envelope-from zbb@FreeBSD.org) Received: (from zbb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEYLRb057349; Thu, 25 May 2017 14:34:21 GMT (envelope-from zbb@FreeBSD.org) Message-Id: <201705251434.v4PEYLRb057349@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: zbb set sender to zbb@FreeBSD.org using -f From: Zbigniew Bodek Date: Thu, 25 May 2017 14:34:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318880 - head/sys/arm/mv 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.23 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, 25 May 2017 14:34:23 -0000 Author: zbb Date: Thu May 25 14:34:21 2017 New Revision: 318880 URL: https://svnweb.freebsd.org/changeset/base/318880 Log: Unmask legacy interrupts on Marvell PCIE controller This patch fixes a bug introduced with commit: r294510 "Remove an extra '!' found by clang 3.8." '!' was removed without inverting the logic, which broke PCIe legacy interrupts operation for Marvell controllers. Submitted by: Michal Mazur Obtained from: Semihalf Sponsored by: Netgate Modified: head/sys/arm/mv/mv_pci.c Modified: head/sys/arm/mv/mv_pci.c ============================================================================== --- head/sys/arm/mv/mv_pci.c Thu May 25 14:27:54 2017 (r318879) +++ head/sys/arm/mv/mv_pci.c Thu May 25 14:34:21 2017 (r318880) @@ -918,7 +918,7 @@ static inline void pcib_write_irq_mask(struct mv_pcib_softc *sc, uint32_t mask) { - if (sc->sc_type != MV_TYPE_PCI) + if (sc->sc_type != MV_TYPE_PCIE) return; bus_space_write_4(sc->sc_bst, sc->sc_bsh, PCIE_REG_IRQ_MASK, mask); From owner-svn-src-head@freebsd.org Thu May 25 14:54:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B0323D8194C; Thu, 25 May 2017 14:54:23 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8CFAD1A75; Thu, 25 May 2017 14:54:23 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PEsMKp065923; Thu, 25 May 2017 14:54:22 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PEsMBT065920; Thu, 25 May 2017 14:54:22 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251454.v4PEsMBT065920@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 14:54:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318881 - in head: . share/doc tools/build/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.23 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, 25 May 2017 14:54:23 -0000 Author: bapt Date: Thu May 25 14:54:22 2017 New Revision: 318881 URL: https://svnweb.freebsd.org/changeset/base/318881 Log: In preparation for the removal of the roff toolchain, disconnect the roff documentation from the build. Those documents will be added to the doc tree and distributed as PDF from the documentation website. As they are valuable has history, but do not match current FreeBSD Further more, the ascii format we were using to distribute them is not really accurate for such documents. more details: https://lists.freebsd.org/pipermail/freebsd-arch/2017-May/018211.html Modified: head/ObsoleteFiles.inc head/share/doc/Makefile head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Thu May 25 14:34:21 2017 (r318880) +++ head/ObsoleteFiles.inc Thu May 25 14:54:22 2017 (r318881) @@ -38,6 +38,76 @@ # xargs -n1 | sort | uniq -d; # done +# 20170525: disconnect the roff docs from the build +OLD_FILES+=usr/share/doc/papers/beyond43.ascii.gz +OLD_FILES+=usr/share/doc/papers/bio.ascii.gz +OLD_FILES+=usr/share/doc/papers/contents.ascii.gz +OLD_FILES+=usr/share/doc/papers/devfs.ascii.gz +OLD_FILES+=usr/share/doc/papers/diskperf.ascii.gz +OLD_FILES+=usr/share/doc/papers/fsinterface.ascii.gz +OLD_FILES+=usr/share/doc/papers/hwpmc.ascii.gz +OLD_FILES+=usr/share/doc/papers/jail.ascii.gz +OLD_FILES+=usr/share/doc/papers/kernmalloc.ascii.gz +OLD_FILES+=usr/share/doc/papers/kerntune.ascii.gz +OLD_FILES+=usr/share/doc/papers/malloc.ascii.gz +OLD_FILES+=usr/share/doc/papers/newvm.ascii.gz +OLD_FILES+=usr/share/doc/papers/releng.ascii.gz +OLD_FILES+=usr/share/doc/papers/sysperf.ascii.gz +OLD_FILES+=usr/share/doc/papers/timecounter.ascii.gz +OLD_FILES+=usr/share/doc/psd/01.cacm/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/02.implement/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/03.iosys/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/04.uprog/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/05.sysman/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/06.Clang/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/12.make/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/13.rcs/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/13.rcs/rcs_func.ascii.gz +OLD_FILES+=usr/share/doc/psd/15.yacc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/16.lex/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/17.m4/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/18.gprof/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/20.ipctut/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/21.ipc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/22.rpcgen/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/23.rpc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/24.xdr/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/25.xdrrfc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/26.rpcrfc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/27.nfsrfc/paper.ascii.gz +OLD_FILES+=usr/share/doc/psd/Title.ascii.gz +OLD_FILES+=usr/share/doc/psd/contents.ascii.gz +OLD_FILES+=usr/share/doc/smm/01.setup/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/02.config/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/03.fsck/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/04.quotas/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/05.fastfs/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/06.nfs/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/07.lpd/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/08.sendmailop/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/11.timedop/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/12.timed/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/18.net/paper.ascii.gz +OLD_FILES+=usr/share/doc/smm/Title.ascii.gz +OLD_FILES+=usr/share/doc/smm/contents.ascii.gz +OLD_FILES+=usr/share/doc/usd/04.csh/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/05.dc/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/06.bc/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/07.mail/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/10.exref/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/10.exref/summary.ascii.gz +OLD_FILES+=usr/share/doc/usd/11.edit/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/12.vi/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/12.vi/summary.ascii.gz +OLD_FILES+=usr/share/doc/usd/12.vi/viapwh.ascii.gz +OLD_FILES+=usr/share/doc/usd/13.viref/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/18.msdiffs/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/19.memacros/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/20.meref/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/21.troff/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/22.trofftut/paper.ascii.gz +OLD_FILES+=usr/share/doc/usd/Title.ascii.gz +OLD_FILES+=usr/share/doc/usd/contents.ascii.gz # 20170427: NATM configuration support removed OLD_FILES+=etc/rc.d/atm1 OLD_FILES+=etc/rc.d/atm2 Modified: head/share/doc/Makefile ============================================================================== --- head/share/doc/Makefile Thu May 25 14:34:21 2017 (r318880) +++ head/share/doc/Makefile Thu May 25 14:54:22 2017 (r318881) @@ -23,11 +23,6 @@ _llvm= llvm _IPv6= IPv6 .endif -# FIXME this is not a real solution ... -.if ${MK_GROFF} != "no" -_roffdocs= papers psd smm usd -.endif - SUBDIR_PARALLEL= # Default output format for troff documents is ascii. Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Thu May 25 14:34:21 2017 (r318880) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Thu May 25 14:54:22 2017 (r318881) @@ -2526,75 +2526,6 @@ OLD_FILES+=usr/bin/troff OLD_FILES+=usr/bin/vgrind OLD_FILES+=usr/libexec/vfontedpr OLD_FILES+=usr/share/dict/eign -OLD_FILES+=usr/share/doc/papers/beyond43.ascii.gz -OLD_FILES+=usr/share/doc/papers/bio.ascii.gz -OLD_FILES+=usr/share/doc/papers/contents.ascii.gz -OLD_FILES+=usr/share/doc/papers/devfs.ascii.gz -OLD_FILES+=usr/share/doc/papers/diskperf.ascii.gz -OLD_FILES+=usr/share/doc/papers/fsinterface.ascii.gz -OLD_FILES+=usr/share/doc/papers/hwpmc.ascii.gz -OLD_FILES+=usr/share/doc/papers/jail.ascii.gz -OLD_FILES+=usr/share/doc/papers/kernmalloc.ascii.gz -OLD_FILES+=usr/share/doc/papers/kerntune.ascii.gz -OLD_FILES+=usr/share/doc/papers/malloc.ascii.gz -OLD_FILES+=usr/share/doc/papers/newvm.ascii.gz -OLD_FILES+=usr/share/doc/papers/releng.ascii.gz -OLD_FILES+=usr/share/doc/papers/sysperf.ascii.gz -OLD_FILES+=usr/share/doc/papers/timecounter.ascii.gz -OLD_FILES+=usr/share/doc/psd/01.cacm/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/02.implement/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/03.iosys/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/04.uprog/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/05.sysman/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/06.Clang/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/12.make/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/13.rcs/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/13.rcs/rcs_func.ascii.gz -OLD_FILES+=usr/share/doc/psd/15.yacc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/16.lex/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/17.m4/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/18.gprof/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/20.ipctut/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/21.ipc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/22.rpcgen/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/23.rpc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/24.xdr/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/25.xdrrfc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/26.rpcrfc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/27.nfsrfc/paper.ascii.gz -OLD_FILES+=usr/share/doc/psd/Title.ascii.gz -OLD_FILES+=usr/share/doc/psd/contents.ascii.gz -OLD_FILES+=usr/share/doc/smm/01.setup/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/02.config/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/03.fsck/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/04.quotas/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/05.fastfs/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/06.nfs/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/07.lpd/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/08.sendmailop/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/11.timedop/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/12.timed/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/18.net/paper.ascii.gz -OLD_FILES+=usr/share/doc/smm/Title.ascii.gz -OLD_FILES+=usr/share/doc/smm/contents.ascii.gz -OLD_FILES+=usr/share/doc/usd/04.csh/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/05.dc/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/06.bc/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/07.mail/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/10.exref/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/10.exref/summary.ascii.gz -OLD_FILES+=usr/share/doc/usd/11.edit/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/12.vi/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/12.vi/summary.ascii.gz -OLD_FILES+=usr/share/doc/usd/12.vi/viapwh.ascii.gz -OLD_FILES+=usr/share/doc/usd/13.viref/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/18.msdiffs/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/19.memacros/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/20.meref/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/21.troff/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/22.trofftut/paper.ascii.gz -OLD_FILES+=usr/share/doc/usd/Title.ascii.gz -OLD_FILES+=usr/share/doc/usd/contents.ascii.gz OLD_FILES+=usr/share/groff_font/devX100-12/CB OLD_FILES+=usr/share/groff_font/devX100-12/CBI OLD_FILES+=usr/share/groff_font/devX100-12/CI From owner-svn-src-head@freebsd.org Thu May 25 16:31:54 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A90DCD821DE; Thu, 25 May 2017 16:31:54 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6FA0E1F87; Thu, 25 May 2017 16:31:54 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PGVrsl007056; Thu, 25 May 2017 16:31:53 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PGVrG5007055; Thu, 25 May 2017 16:31:53 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251631.v4PGVrG5007055@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 16:31:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318883 - 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.23 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, 25 May 2017 16:31:54 -0000 Author: bapt Date: Thu May 25 16:31:53 2017 New Revision: 318883 URL: https://svnweb.freebsd.org/changeset/base/318883 Log: Now that roff documentation has been disconnected from the build, it is no longer necessary to have groff(1) as a bootstrap tool Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Thu May 25 16:15:19 2017 (r318882) +++ head/Makefile.inc1 Thu May 25 16:31:53 2017 (r318883) @@ -505,11 +505,6 @@ CROSSENV+= MAKEOBJDIRPREFIX=${OBJTREE} \ # Don't rebuild build-tools targets during normal build. CROSSENV+= BUILD_TOOLS_META=.NOMETA .endif -.if ${MK_GROFF} != "no" -CROSSENV+= GROFF_BIN_PATH=${WORLDTMP}/legacy/usr/bin \ - GROFF_FONT_PATH=${WORLDTMP}/legacy/usr/share/groff_font \ - GROFF_TMAC_PATH=${WORLDTMP}/legacy/usr/share/tmac -.endif .if defined(TARGET_CFLAGS) CROSSENV+= ${TARGET_CFLAGS} .endif @@ -718,10 +713,6 @@ _worldtmp: .PHONY .endfor mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \ -p ${WORLDTMP}/legacy/usr >/dev/null -.if ${MK_GROFF} != "no" - mtree -deU -f ${.CURDIR}/etc/mtree/BSD.groff.dist \ - -p ${WORLDTMP}/legacy/usr >/dev/null -.endif mtree -deU -f ${.CURDIR}/etc/mtree/BSD.include.dist \ -p ${WORLDTMP}/legacy/usr/include >/dev/null mtree -deU -f ${.CURDIR}/etc/mtree/BSD.usr.dist \ @@ -1654,11 +1645,6 @@ _strfile= usr.bin/fortune/strfile _gperf= gnu/usr.bin/gperf .endif -.if ${MK_SHAREDOCS} != "no" && ${MK_GROFF} != "no" -_groff= gnu/usr.bin/groff \ - usr.bin/soelim -.endif - .if ${MK_VT} != "no" _vtfontcvt= usr.bin/vtfontcvt .endif @@ -1765,7 +1751,6 @@ bootstrap-tools: .PHONY ${_kerberos5_bootstrap_tools} \ ${_strfile} \ ${_gperf} \ - ${_groff} \ ${_dtc} \ ${_cat} \ ${_kbdcontrol} \ From owner-svn-src-head@freebsd.org Thu May 25 16:41:09 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2BFB0D8248B; Thu, 25 May 2017 16:41:09 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F002513E3; Thu, 25 May 2017 16:41:08 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PGf7NE007519; Thu, 25 May 2017 16:41:07 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PGf7bI007518; Thu, 25 May 2017 16:41:07 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705251641.v4PGf7bI007518@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Thu, 25 May 2017 16:41:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318884 - head/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD 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.23 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, 25 May 2017 16:41:09 -0000 Author: emaste Date: Thu May 25 16:41:07 2017 New Revision: 318884 URL: https://svnweb.freebsd.org/changeset/base/318884 Log: lldb: map TRAP_CAP to a trace trap In the absense of a more specific handler for TRAP_CAP (generated by ENOTCAPABLE or ECAPMODE while in capability mode) treat it as a trace trap. Example usage (testing the bug in PR219173): % proccontrol -m trapcap lldb usr.bin/hexdump/obj/hexdump -- -Cv -s 1 /bin/ls ... (lldb) run Process 12980 launching Process 12980 launched: '.../usr.bin/hexdump/obj/hexdump' (x86_64) Process 12980 stopped * thread #1, stop reason = trace frame #0: 0x0000004b80c65f1a libc.so.7`__sys_lseek + 10 ... In the future we should have LLDB control the trapcap procctl itself (as it does with ASLR), as well as report a specific stop reason. This change eliminates an assertion failure from LLDB for now. Modified: head/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp Modified: head/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp ============================================================================== --- head/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp Thu May 25 16:31:53 2017 (r318883) +++ head/contrib/llvm/tools/lldb/source/Plugins/Process/FreeBSD/ProcessMonitor.cpp Thu May 25 16:41:07 2017 (r318884) @@ -1132,6 +1132,8 @@ ProcessMessage ProcessMonitor::MonitorSI case 0: case TRAP_TRACE: + // Map TRAP_CAP to a trace trap in the absense of a more specific handler. + case TRAP_CAP: if (log) log->Printf("ProcessMonitor::%s() received trace event, tid = %" PRIu64 " : si_code = %d", From owner-svn-src-head@freebsd.org Thu May 25 17:45:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8F671D81D31; Thu, 25 May 2017 17:45:52 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5B3C31757; Thu, 25 May 2017 17:45:52 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PHjp2k036987; Thu, 25 May 2017 17:45:51 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PHjpZt036983; Thu, 25 May 2017 17:45:51 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251745.v4PHjpZt036983@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 17:45:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318888 - in head/usr.bin/diff3: . tests 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.23 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, 25 May 2017 17:45:52 -0000 Author: bapt Date: Thu May 25 17:45:50 2017 New Revision: 318888 URL: https://svnweb.freebsd.org/changeset/base/318888 Log: Import working progress BSD diff3 import bsd diff3 from OpenBSD. Differences with OpenBSD: - lots of warning fixed - no shell wrapper with diff3 actually living in libexec - capsicumized Keep it disconnected as it is not yet good enough to replace GNU diff The motivation to import it now it to allow other people to jump in and also to have an open development on it Obtained from: OpenBSD Added: head/usr.bin/diff3/ head/usr.bin/diff3/Makefile (contents, props changed) head/usr.bin/diff3/diff3.1 (contents, props changed) head/usr.bin/diff3/diff3.c (contents, props changed) head/usr.bin/diff3/tests/ head/usr.bin/diff3/tests/1.out (contents, props changed) head/usr.bin/diff3/tests/1.txt (contents, props changed) head/usr.bin/diff3/tests/2.out (contents, props changed) head/usr.bin/diff3/tests/2.txt (contents, props changed) head/usr.bin/diff3/tests/3.out (contents, props changed) head/usr.bin/diff3/tests/3.txt (contents, props changed) head/usr.bin/diff3/tests/4.out (contents, props changed) head/usr.bin/diff3/tests/5.out (contents, props changed) head/usr.bin/diff3/tests/6.out (contents, props changed) head/usr.bin/diff3/tests/7.out (contents, props changed) head/usr.bin/diff3/tests/8.out (contents, props changed) head/usr.bin/diff3/tests/9.out (contents, props changed) head/usr.bin/diff3/tests/Makefile (contents, props changed) head/usr.bin/diff3/tests/diff3_test.sh (contents, props changed) Added: head/usr.bin/diff3/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/diff3/Makefile Thu May 25 17:45:50 2017 (r318888) @@ -0,0 +1,11 @@ +# $FreeBSD$ + +.include + +PROG= diff3 + +.if ${MK_TESTS} != "no" +SUBDIR+= tests +.endif + +.include Added: head/usr.bin/diff3/diff3.1 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/diff3/diff3.1 Thu May 25 17:45:50 2017 (r318888) @@ -0,0 +1,202 @@ +.\" $OpenBSD: diff3.1,v 1.7 2007/05/31 19:20:09 jmc Exp $ +.\" +.\" Copyright (c) 1990, 1993, 1994 +.\" The Regents of the University of California. 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. +.\" 3. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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. +.\" +.\" @(#)diff3.1 8.2 (Berkeley) 4/18/94 +.\" $FreeBSD$ +.\" +.Dd $Mdocdate: May 31 2007 $ +.Dt DIFF3 1 +.Os +.Sh NAME +.Nm diff3 +.Nd 3-way differential file comparison +.Sh SYNOPSIS +.Nm diff3 +.Op Fl 3aEeXx +.Ar file1 file2 file3 +.Sh DESCRIPTION +The +.Nm +utility compares the contents of three different versions of a file, +.Ar file1 , +.Ar file2 +and +.Ar file3 , +writing the result to the standard output. +The options describe different methods of merging and +purging +the separate versions into a new file. +.Nm +is used by +.Xr rcs 1 +to merge specific versions or create +new versions. +.Pp +The options are as follows: +.Bl -tag -width "-E, -X" +.It Fl 3 +Produces an output script suitable for +.Xr ed 1 +with changes +specific only to +.Ar file3 . +.It Fl a +Treat all files as ASCII. +.It Fl E , X +Similar to +.Fl e +and +.Fl x , +respectively, but treat overlapping changes (i.e., changes that would +be noted with ==== in the normal listing) differently. +The overlapping lines from both files will be inserted by the edit script, +bracketed by "<<<<<<" and ">>>>>>" lines. +.It Fl e +Produces output in a form suitable as an input script for the +.Xr ed 1 +utility. +The script may then be used to merge differences common between all +three files and differences specific to +.Ar file1 +and +.Ar file3 . +In other words, the +.Fl e +option ignores differences specific to +.Ar file1 +and +.Ar file2 , +and those specific to +.Ar file2 +and +.Ar file3 . +It is useful for backing out changes specific to +.Ar file2 +only. +.It Fl x +Produces an output script suitable for +.Xr ed 1 +with changes +specific only to all three versions. +.El +.Pp +The +.Fl E +option is used by +.Tn RCS +.Xr merge 1 +to ensure that overlapping changes in the merged files are preserved +and brought to someone's attention. +.Pp +For example, suppose lines 7-8 are changed in both +.Ar file1 +and +.Ar file2 . +Applying the edit script generated by the command +.Pp +.Dl $ diff3 -E file1 file2 file3 +.Pp +to +.Ar file1 +results in the file: +.Bd -literal -offset indent +lines 1-6 +of file1 +<<<<<<< file1 +lines 7-8 +of file1 +======= +lines 7-8 +of file3 +>>>>>>> file3 +rest of file1 +.Ed +.Pp +The default output of +.Nm +makes notation of the differences between all files, and those +differences specific to each pair of files. +The changes are described by the commands necessary for +.Xr ed 1 +to create the desired target from the different versions. +See +.Xr diff 1 +for a description of the commands. +.Bl -tag -width "=====" +.It Li \&==== +The lines beneath this notation are ranges of lines which are different +between all files. +.It \&==== Ns Va n +The lines beneath this notation are ranges of lines which are exclusively +different in file +.Va n . +.El +.Sh ENVIRONMENT +.Bl -tag -width TMPDIR +.It Ev TMPDIR +If the environment variable +.Ev TMPDIR +exists, +.Nm +will use the directory specified by +.Ev TMPDIR +as the temporary directory. +.El +.Sh FILES +.Bl -tag -width /usr/libexec/diff3 -compact +.It Pa /tmp/d3a.XXXXXXXXXX +temporary file +.It Pa /tmp/d3b.XXXXXXXXXX +temporary file +.It Pa /usr/libexec/diff3 +the actual executable +.El +.Sh SEE ALSO +.Xr diff 1 , +.Xr ed 1 , +.Xr merge 1 , +.Xr rcs 1 , +.Xr sdiff 1 +.Sh HISTORY +A +.Nm +command appeared in +.At v7 . +.Sh BUGS +The +.Fl e +option cannot catch and change lines which have +.Ql \&. +as the first and only character on the line. +The resulting script will fail on that line +as +.Ql \&. +is an +.Xr ed 1 +editing command. Added: head/usr.bin/diff3/diff3.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/usr.bin/diff3/diff3.c Thu May 25 17:45:50 2017 (r318888) @@ -0,0 +1,787 @@ +/* $OpenBSD: diff3prog.c,v 1.11 2009/10/27 23:59:37 deraadt Exp $ */ + +/* + * Copyright (C) Caldera International Inc. 2001-2002. + * 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 and documentation 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed or owned by Caldera + * International, Inc. + * 4. Neither the name of Caldera International, Inc. nor the names of other + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA + * INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. 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. + */ +/*- + * Copyright (c) 1991, 1993 + * The Regents of the University of California. 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. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS 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 REGENTS 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. + * + * @(#)diff3.c 8.1 (Berkeley) 6/6/93 + */ + +#if 0 +#ifndef lint +static char sccsid[] = "@(#)diff3.c 8.1 (Berkeley) 6/6/93"; +#endif +#endif /* not lint */ +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include + + +/* + * "from" is first in range of changed lines; "to" is last+1 + * from=to=line after point of insertion for added lines. + */ +struct range { + int from; + int to; +}; + +struct diff { + struct range old; + struct range new; +}; + +static size_t szchanges; + +static struct diff *d13; +static struct diff *d23; +/* + * "de" is used to gather editing scripts. These are later spewed out in + * reverse order. Its first element must be all zero, the "new" component + * of "de" contains line positions or byte positions depending on when you + * look (!?). Array overlap indicates which sections in "de" correspond to + * lines that are different in all three files. + */ +static struct diff *de; +static char *overlap; +static int overlapcnt; +static FILE *fp[3]; +static int cline[3]; /* # of the last-read line in each file (0-2) */ +/* + * The latest known correspondence between line numbers of the 3 files + * is stored in last[1-3]; + */ +static int last[4]; +static int Aflag, eflag, iflag, mflag, Tflag; +static int oflag; /* indicates whether to mark overlaps (-E or -X)*/ +static int strip_cr; +static char *f1mark, *f2mark, *f3mark; + +static bool duplicate(struct range *, struct range *); +static int edit(struct diff *, bool, int); +static char *getchange(FILE *); +static char *get_line(FILE *, size_t *); +static int number(char **); +static int readin(int fd, struct diff **); +static int skip(int, int, const char *); +static void change(int, struct range *, bool); +static void keep(int, struct range *); +static void merge(int, int); +static void prange(struct range *); +static void repos(int); +static void edscript(int) __dead2; +static void increase(void); +static void usage(void) __dead2; + +enum { + DIFFPROG_OPT, + STRIPCR_OPT, +}; + +#define MAX_CHECK 768 /* 3 kb of chars */ +#define DIFF_PATH "/usr/bin/diff" + + +#define OPTIONS "3aAeEiL:mTxX" +static struct option longopts[] = { + { "ed", no_argument, NULL, 'e' }, + { "show-overlap", no_argument, NULL, 'E' }, + { "overlap-only", no_argument, NULL, 'x' }, + { "initial-tab", no_argument, NULL, 'T' }, + { "text", no_argument, NULL, 'a' }, + { "strip-trailing-cr", no_argument, NULL, STRIPCR_OPT }, + { "show-all", no_argument, NULL, 'A' }, + { "easy-only", no_argument, NULL, '3' }, + { "merge", no_argument, NULL, 'm' }, + { "label", required_argument, NULL, 'L' }, + { "diff-program", required_argument, NULL, DIFFPROG_OPT }, +}; + +static void +usage(void) +{ + fprintf(stderr, "usage: diff3 [-3aAeEimTxX] [-L lable1] [-L label2] " + "[ -L label3] file1 file2 file3\n"); + exit (2); +} + +static int +readin(int fd, struct diff **dd) +{ + int a, b, c, d; + size_t i; + char kind, *p; + FILE *f; + + f = fdopen(fd, "r"); + if (f == NULL) + err(2, "fdopen"); + for (i=0; (p = getchange(f)); i++) { + if (i >= szchanges - 1) + increase(); + a = b = number(&p); + if (*p == ',') { + p++; + b = number(&p); + } + kind = *p++; + c = d = number(&p); + if (*p==',') { + p++; + d = number(&p); + } + if (kind == 'a') + a++; + if (kind == 'd') + c++; + b++; + d++; + (*dd)[i].old.from = a; + (*dd)[i].old.to = b; + (*dd)[i].new.from = c; + (*dd)[i].new.to = d; + } + if (i) { + (*dd)[i].old.from = (*dd)[i-1].old.to; + (*dd)[i].new.from = (*dd)[i-1].new.to; + } + fclose(f); + return (i); +} + +static int +diffexec(const char *diffprog, char **diffargv, int fd[]) +{ + int pid, pd; + + switch (pid = pdfork(&pd, PD_CLOEXEC)) { + case 0: + close(fd[0]); + if (dup2(fd[1], STDOUT_FILENO) == -1) + err(2, "child could not duplicate descriptor"); + close(fd[1]); + execvp(diffprog, diffargv); + err(2, "could not execute diff: %s", diffprog); + break; + case -1: + err(2, "could not fork"); + break; + } + close(fd[1]); + return (pd); +} + +static int +number(char **lc) +{ + int nn; + + nn = 0; + while (isdigit((unsigned char)(**lc))) + nn = nn*10 + *(*lc)++ - '0'; + return (nn); +} + +static char * +getchange(FILE *b) +{ + char *line; + + while ((line = get_line(b, NULL))) { + if (isdigit((unsigned char)line[0])) + return (line); + } + return (NULL); +} + + +static char * +get_line(FILE *b, size_t *n) +{ + char *cp; + size_t len; + static char *buf; + static size_t bufsize; + + if ((cp = fgetln(b, &len)) == NULL) + return (NULL); + + if (cp[len - 1] != '\n') + len++; + if (len + 1 > bufsize) { + do { + bufsize += 1024; + } while (len + 1 > bufsize); + if ((buf = realloc(buf, bufsize)) == NULL) + err(EXIT_FAILURE, NULL); + } + memcpy(buf, cp, len - 1); + buf[len - 1] = '\n'; + buf[len] = '\0'; + if (n != NULL) + *n = len; + return (buf); +} + +static void +merge(int m1, int m2) +{ + struct diff *d1, *d2, *d3; + int j, t1, t2; + bool dup = false; + + d1 = d13; + d2 = d23; + j = 0; + + while ((t1 = d1 < d13 + m1) | (t2 = d2 < d23 + m2)) { + /* first file is different from the others */ + if (!t2 || (t1 && d1->new.to < d2->new.from)) { + /* stuff peculiar to 1st file */ + if (eflag == 0) { + printf("====1\n"); + change(1, &d1->old, false); + keep(2, &d1->new); + change(3, &d1->new, false); + } + d1++; + continue; + } + /* second file is different from others */ + if (!t1 || (t2 && d2->new.to < d1->new.from)) { + if (eflag == 0) { + printf("====2\n"); + keep(1, &d2->new); + change(3, &d2->new, false); + change(2, &d2->old, false); + } + d2++; + continue; + } + /* + * Merge overlapping changes in first file + * this happens after extension (see below). + */ + if (d1 + 1 < d13 + m1 && d1->new.to >= d1[1].new.from) { + d1[1].old.from = d1->old.from; + d1[1].new.from = d1->new.from; + d1++; + continue; + } + + /* merge overlapping changes in second */ + if (d2 + 1 < d23 + m2 && d2->new.to >= d2[1].new.from) { + d2[1].old.from = d2->old.from; + d2[1].new.from = d2->new.from; + d2++; + continue; + } + /* stuff peculiar to third file or different in all */ + if (d1->new.from == d2->new.from && d1->new.to == d2->new.to) { + dup = duplicate(&d1->old, &d2->old); + /* + * dup = 0 means all files differ + * dup = 1 means files 1 and 2 identical + */ + if (eflag == 0) { + printf("====%s\n", dup ? "3" : ""); + change(1, &d1->old, dup); + change(2, &d2->old, false); + d3 = d1->old.to > d1->old.from ? d1 : d2; + change(3, &d3->new, false); + } else + j = edit(d1, dup, j); + d1++; + d2++; + continue; + } + /* + * Overlapping changes from file 1 and 2; extend changes + * appropriately to make them coincide. + */ + if (d1->new.from < d2->new.from) { + d2->old.from -= d2->new.from - d1->new.from; + d2->new.from = d1->new.from; + } else if (d2->new.from < d1->new.from) { + d1->old.from -= d1->new.from - d2->new.from; + d1->new.from = d2->new.from; + } + if (d1->new.to > d2->new.to) { + d2->old.to += d1->new.to - d2->new.to; + d2->new.to = d1->new.to; + } else if (d2->new.to > d1->new.to) { + d1->old.to += d2->new.to - d1->new.to; + d1->new.to = d2->new.to; + } + } + if (eflag) + edscript(j); +} + +/* + * The range of lines rold.from thru rold.to in file i is to be changed. + * It is to be printed only if it does not duplicate something to be + * printed later. + */ +static void +change(int i, struct range *rold, bool dup) +{ + + printf("%d:", i); + last[i] = rold->to; + prange(rold); + if (dup) + return; + i--; + skip(i, rold->from, NULL); + skip(i, rold->to, " "); +} + +/* + * Print the range of line numbers, rold.from thru rold.to, as n1,n2 or + * n1. + */ +static void +prange(struct range *rold) +{ + + if (rold->to <= rold->from) + printf("%da\n", rold->from - 1); + else { + printf("%d", rold->from); + if (rold->to > rold->from+1) + printf(",%d", rold->to - 1); + printf("c\n"); + } +} + +/* + * No difference was reported by diff between file 1 (or 2) and file 3, + * and an artificial dummy difference (trange) must be ginned up to + * correspond to the change reported in the other file. + */ +static void +keep(int i, struct range *rnew) +{ + int delta; + struct range trange; + + delta = last[3] - last[i]; + trange.from = rnew->from - delta; + trange.to = rnew->to - delta; + change(i, &trange, true); +} + +/* + * skip to just before line number from in file "i". If "pr" is non-NULL, + * print all skipped stuff with string pr as a prefix. + */ +static int +skip(int i, int from, const char *pr) +{ + size_t j, n; + char *line; + + for (n = 0; cline[i] < from - 1; n += j) { + if ((line = get_line(fp[i], &j)) == NULL) + errx(EXIT_FAILURE, "logic error"); + if (pr != NULL) + printf("%s%s", Tflag == 1? "\t" : pr, line); + cline[i]++; + } + return ((int) n); +} + +/* + * Return 1 or 0 according as the old range (in file 1) contains exactly + * the same data as the new range (in file 2). + */ +static bool +duplicate(struct range *r1, struct range *r2) +{ + int c, d; + int nchar; + int nline; + + if (r1->to-r1->from != r2->to-r2->from) + return (0); + skip(0, r1->from, NULL); + skip(1, r2->from, NULL); + nchar = 0; + for (nline=0; nline < r1->to - r1->from; nline++) { + do { + c = getc(fp[0]); + d = getc(fp[1]); + if (c == -1 || d== -1) + errx(EXIT_FAILURE, "logic error"); + nchar++; + if (c != d) { + repos(nchar); + return (0); + } + } while (c != '\n'); + } + repos(nchar); + return (1); +} + +static void +repos(int nchar) +{ + int i; + + for (i = 0; i < 2; i++) + (void)fseek(fp[i], (long)-nchar, SEEK_CUR); +} +/* + * collect an editing script for later regurgitation + */ +static int +edit(struct diff *diff, bool dup, int j) +{ + + if (((dup + 1) & eflag) == 0) + return (j); + j++; + overlap[j] = !dup; + if (!dup) + overlapcnt++; + de[j].old.from = diff->old.from; + de[j].old.to = diff->old.to; + de[j].new.from = de[j-1].new.to + skip(2, diff->new.from, NULL); + de[j].new.to = de[j].new.from + skip(2, diff->new.to, NULL); + return (j); +} + +/* regurgitate */ +static void +edscript(int n) +{ + int k; + size_t j; + char block[BUFSIZ]; + + for (; n > 0; n--) { + if (!oflag || !overlap[n]) { + prange(&de[n].old); + } else { + printf("%da\n", de[n].old.to -1); + if (Aflag) { + printf("%s\n", f2mark); + fseek(fp[1], de[n].old.from, SEEK_SET); + for (k = de[n].old.to - de[n].old.from; k > 0; k -= j) { + j = k > BUFSIZ ? BUFSIZ : k; + if (fread(block, 1, j, fp[1]) != j) + errx(2, "logic error"); + fwrite(block, 1, j, stdout); + } + printf("\n"); + } + printf("=======\n"); + } + fseek(fp[2], (long)de[n].new.from, SEEK_SET); + for (k = de[n].new.to - de[n].new.from; k > 0; k-= j) { + j = k > BUFSIZ ? BUFSIZ : k; + if (fread(block, 1, j, fp[2]) != j) + errx(2, "logic error"); + fwrite(block, 1, j, stdout); + } + if (!oflag || !overlap[n]) + printf(".\n"); + else { + printf("%s\n.\n", f3mark); + printf("%da\n%s\n.\n", de[n].old.from - 1, f1mark); + } + } + if (iflag) + printf("w\nq\n"); + + exit(eflag == 0 ? overlapcnt : 0); +} + +static void +increase(void) +{ + struct diff *p; + char *q; + size_t newsz, incr; + + /* are the memset(3) calls needed? */ + newsz = szchanges == 0 ? 64 : 2 * szchanges; + incr = newsz - szchanges; + + p = realloc(d13, newsz * sizeof(struct diff)); + if (p == NULL) + err(1, NULL); + memset(p + szchanges, 0, incr * sizeof(struct diff)); + d13 = p; + p = realloc(d23, newsz * sizeof(struct diff)); + if (p == NULL) + err(1, NULL); + memset(p + szchanges, 0, incr * sizeof(struct diff)); + d23 = p; + p = realloc(de, newsz * sizeof(struct diff)); + if (p == NULL) + err(1, NULL); + memset(p + szchanges, 0, incr * sizeof(struct diff)); + de = p; + q = realloc(overlap, newsz * sizeof(char)); + if (q == NULL) + err(1, NULL); + memset(q + szchanges, 0, incr * sizeof(char)); + overlap = q; + szchanges = newsz; +} + + +int +main(int argc, char **argv) +{ + int ch, nblabels, status, m, n, kq, nke, nleft, i; + char *labels[] = { NULL, NULL, NULL }; + const char *diffprog = DIFF_PATH; + char *file1, *file2, *file3; + char *diffargv[6]; + int diffargc = 0; + int fd13[2], fd23[2]; + int pd13, pd23; + cap_rights_t rights_ro; + struct kevent *e; + + nblabels = 0; + eflag = 0; + oflag = 0; + diffargv[diffargc++] = __DECONST(char *, diffprog); + while ((ch = getopt_long(argc, argv, OPTIONS, longopts, NULL)) != -1) { + switch (ch) { + case '3': + eflag = 2; + break; + case 'a': + diffargv[diffargc++] = __DECONST(char *, "-a"); + break; + case 'A': + Aflag = 1; + break; + case 'e': + eflag = 3; + break; + case 'E': + eflag = 3; + oflag = 1; + break; + case 'i': + iflag = 1; + break; + case 'L': + oflag = 1; + if (nblabels >= 3) + errx(2, "too many file label options"); + labels[nblabels++] = optarg; + break; + case 'm': + Aflag = 1; + oflag = 1; + mflag = 1; + break; + case 'T': + Tflag = 1; + break; + case 'x': + eflag = 1; + break; + case 'X': + oflag = 1; + eflag = 1; + break; + case DIFFPROG_OPT: + diffprog = optarg; + break; + case STRIPCR_OPT: + strip_cr = 1; + break; + } + } + argc -= optind; + argv += optind; + + if (Aflag) { + eflag = 3; + oflag = 1; + } + + if (argc != 3) + usage(); + + if (caph_limit_stdio() == -1) + err(2, "unable to limit stdio"); + + cap_rights_init(&rights_ro, CAP_READ, CAP_FSTAT, CAP_SEEK); + + kq = kqueue(); + if (kq == -1) + err(2, "kqueue"); + + e = malloc(2 * sizeof(struct kevent)); + if (e == NULL) + err(2, "malloc"); + + /* TODO stdio */ + file1 = argv[0]; + file2 = argv[1]; + file3 = argv[2]; + + if (oflag) { + asprintf(&f1mark, "<<<<<<< %s", + labels[0] != NULL ? labels[0] : file1); + if (f1mark == NULL) + err(2, "asprintf"); + asprintf(&f2mark, "||||||| %s", + labels[1] != NULL ? labels[1] : file2); + if (f2mark == NULL) + err(2, "asprintf"); + asprintf(&f3mark, ">>>>>>> %s", + labels[2] != NULL ? labels[2] : file3); + if (f3mark == NULL) + err(2, "asprintf"); + } + fp[0] = fopen(file1, "r"); + if (fp[0] == NULL) + err(2, "Can't open %s", file1); + if (cap_rights_limit(fileno(fp[0]), &rights_ro) < 0) + err(2, "unable to limit rights on: %s", file1); + + fp[1] = fopen(file2, "r"); + if (fp[1] == NULL) + err(2, "Can't open %s", file2); + if (cap_rights_limit(fileno(fp[1]), &rights_ro) < 0) + err(2, "unable to limit rights on: %s", file2); + + fp[2] = fopen(file3, "r"); + if (fp[2] == NULL) + err(2, "Can't open %s", file3); + if (cap_rights_limit(fileno(fp[2]), &rights_ro) < 0) + err(2, "unable to limit rights on: %s", file3); + + if (pipe(fd13)) + err(2, "pipe"); + if (pipe(fd23)) + err(2, "pipe"); + + diffargv[diffargc] = file1; + diffargv[diffargc + 1] = file3; + diffargv[diffargc + 2] = NULL; + + nleft = 0; + pd13 = diffexec(diffprog, diffargv, fd13); + EV_SET(e + nleft , pd13, EVFILT_PROCDESC, EV_ADD, NOTE_EXIT, 0, NULL); + if (kevent(kq, e + nleft, 1, NULL, 0, NULL) == -1) + err(2, "kevent1"); + nleft++; + + diffargv[diffargc] = file2; + pd23 = diffexec(diffprog, diffargv, fd23); + EV_SET(e + nleft , pd23, EVFILT_PROCDESC, EV_ADD, NOTE_EXIT, 0, NULL); + if (kevent(kq, e + nleft, 1, NULL, 0, NULL) == -1) + err(2, "kevent2"); + nleft++; + + caph_cache_catpages(); + if (cap_enter() < 0 && errno != ENOSYS) + err(2, "unable to enter capability mode"); + + /* parse diffs */ + increase(); + m = readin(fd13[0], &d13); + n = readin(fd23[0], &d23); + + /* waitpid cooked over pdforks */ + while (nleft > 0) { + nke = kevent(kq, NULL, 0, e, nleft, NULL); + if (nke == -1) + err(2, "kevent"); + for (i = 0; i < nke; i++) { + status = e[i].data; + if (WIFEXITED(status) && WEXITSTATUS(status) >= 2) + errx(2, "diff exited abormally"); + else if (WIFSIGNALED(status)) *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Thu May 25 17:55:42 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F2A23D81FC5; Thu, 25 May 2017 17:55:41 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B5B2C1CEA; Thu, 25 May 2017 17:55:41 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PHte5V041201; Thu, 25 May 2017 17:55:40 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PHteJ0041200; Thu, 25 May 2017 17:55:40 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251755.v4PHteJ0041200@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 17:55:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318889 - head/usr.bin/diff3 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.23 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, 25 May 2017 17:55:42 -0000 Author: bapt Date: Thu May 25 17:55:40 2017 New Revision: 318889 URL: https://svnweb.freebsd.org/changeset/base/318889 Log: Remove the MAX_CHECK macro, it was initially used to test if a file was a text file or not. The check is not done by diff3 but by diff (the argument -a is directly passed to diff(1)) Modified: head/usr.bin/diff3/diff3.c Modified: head/usr.bin/diff3/diff3.c ============================================================================== --- head/usr.bin/diff3/diff3.c Thu May 25 17:45:50 2017 (r318888) +++ head/usr.bin/diff3/diff3.c Thu May 25 17:55:40 2017 (r318889) @@ -149,10 +149,8 @@ enum { STRIPCR_OPT, }; -#define MAX_CHECK 768 /* 3 kb of chars */ #define DIFF_PATH "/usr/bin/diff" - #define OPTIONS "3aAeEiL:mTxX" static struct option longopts[] = { { "ed", no_argument, NULL, 'e' }, From owner-svn-src-head@freebsd.org Thu May 25 17:58:03 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 00DF5D82079; Thu, 25 May 2017 17:58:03 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C53DC1E8B; Thu, 25 May 2017 17:58:02 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PHw1o0041359; Thu, 25 May 2017 17:58:01 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PHw1BH041358; Thu, 25 May 2017 17:58:01 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251758.v4PHw1BH041358@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 17:58:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318890 - head/usr.bin/diff3/tests 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.23 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, 25 May 2017 17:58:03 -0000 Author: bapt Date: Thu May 25 17:58:01 2017 New Revision: 318890 URL: https://svnweb.freebsd.org/changeset/base/318890 Log: For now comment tests for arguments which are not in par with GNU diff3 yet Modified: head/usr.bin/diff3/tests/diff3_test.sh Modified: head/usr.bin/diff3/tests/diff3_test.sh ============================================================================== --- head/usr.bin/diff3/tests/diff3_test.sh Thu May 25 17:55:40 2017 (r318889) +++ head/usr.bin/diff3/tests/diff3_test.sh Thu May 25 17:58:01 2017 (r318890) @@ -26,11 +26,11 @@ diff3_body() atf_check -o file:$(atf_get_srcdir)/7.out \ diff3 -i $(atf_get_srcdir)/1.txt $(atf_get_srcdir)/2.txt $(atf_get_srcdir)/3.txt - atf_check -o file:$(atf_get_srcdir)/8.out \ - diff3 -A -L 1 -L 2 -L 3 $(atf_get_srcdir)/1.txt $(atf_get_srcdir)/2.txt $(atf_get_srcdir)/3.txt +# atf_check -o file:$(atf_get_srcdir)/8.out \ +# diff3 -A -L 1 -L 2 -L 3 $(atf_get_srcdir)/1.txt $(atf_get_srcdir)/2.txt $(atf_get_srcdir)/3.txt - atf_check -s exit:1 -o file:$(atf_get_srcdir)/9.out \ - diff3 -m -L 1 -L 2 -L 3 $(atf_get_srcdir)/1.txt $(atf_get_srcdir)/2.txt $(atf_get_srcdir)/3.txt +# atf_check -s exit:1 -o file:$(atf_get_srcdir)/9.out \ +# diff3 -m -L 1 -L 2 -L 3 $(atf_get_srcdir)/1.txt $(atf_get_srcdir)/2.txt $(atf_get_srcdir)/3.txt } diff3_lesssimple_body() @@ -42,5 +42,5 @@ diff3_lesssimple_body() atf_init_test_cases() { atf_add_test_case diff3 - atf_add_test_case diff3_lesssimple +# atf_add_test_case diff3_lesssimple } From owner-svn-src-head@freebsd.org Thu May 25 18:16:19 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8199FD8268C; Thu, 25 May 2017 18:16:19 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 432621AE9; Thu, 25 May 2017 18:16:19 +0000 (UTC) (envelope-from dteske@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PIGIil049729; Thu, 25 May 2017 18:16:18 GMT (envelope-from dteske@FreeBSD.org) Received: (from dteske@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PIGIdJ049727; Thu, 25 May 2017 18:16:18 GMT (envelope-from dteske@FreeBSD.org) Message-Id: <201705251816.v4PIGIdJ049727@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dteske set sender to dteske@FreeBSD.org using -f From: Devin Teske Date: Thu, 25 May 2017 18:16:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318891 - in head/usr.sbin/bsdconfig: console 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.23 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, 25 May 2017 18:16:19 -0000 Author: dteske Date: Thu May 25 18:16:17 2017 New Revision: 318891 URL: https://svnweb.freebsd.org/changeset/base/318891 Log: Fix long standing issue in bsdconfig's keymap selection Since the translation to vt as terminal emulator, the keymaps files path has changed and this change does not get followed in bsdconfig. This implicates boot time warnings about a wrong keymap file, what is very confusing for the new users and for me too, so initialize the default keymaps search path depending on terminal type. Differential Revision: https://reviews.freebsd.org/D8734 Submitted by: Oliver Pinter Reviewed by: ed, jilles, dteske MFC after: 3 days X-MFC-to: stable/11 Sponsored by: HardenedBSD Signed-off-by: Oliver Pinter Modified: head/usr.sbin/bsdconfig/console/keymap head/usr.sbin/bsdconfig/share/keymap.subr Modified: head/usr.sbin/bsdconfig/console/keymap ============================================================================== --- head/usr.sbin/bsdconfig/console/keymap Thu May 25 17:58:01 2017 (r318890) +++ head/usr.sbin/bsdconfig/console/keymap Thu May 25 18:16:17 2017 (r318891) @@ -172,6 +172,7 @@ dialog_menu_main() uk.iso) defaultitem="$msg_uk_iso" ;; ua.koi8-u) defaultitem="$msg_ukrainian_koi8_u" ;; ua.koi8-u.shift.alt) defaultitem="$msg_ukrainian_koi8_u_koi8_r" ;; + us.ctrl) defaultitem="$msg_usa_capslock_ctrl" ;; us.pc-ctrl) defaultitem="$msg_usa_capslock_ctrl" ;; us.dvorak) defaultitem="$msg_usa_dvorak" ;; us.dvorakl) defaultitem="$msg_usa_dvorak_left" ;; @@ -307,7 +308,12 @@ while :; do uk_iso) keymap_to_set="uk.iso" ;; ukrainian_koi8_u) keymap_to_set="ua.koi8-u" ;; ukrainian_koi8_u_koi8_r) keymap_to_set="ua.koi8-u.shift.alt" ;; - usa_capslock_ctrl) keymap_to_set="us.pc-ctrl" ;; + usa_capslock_ctrl) + case "$( sysctl -n kern.vty )" in + vt) keymap_to_set="us.ctrl" ;; + *) keymap_to_set="us.pc-ctrl" ;; + esac + ;; usa_dvorak) keymap_to_set="us.dvorak" ;; usa_dvorak_left) keymap_to_set="us.dvorakl" ;; usa_dvorak_right) keymap_to_set="us.dvorakr" ;; Modified: head/usr.sbin/bsdconfig/share/keymap.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/keymap.subr Thu May 25 17:58:01 2017 (r318890) +++ head/usr.sbin/bsdconfig/share/keymap.subr Thu May 25 18:16:17 2017 (r318891) @@ -39,7 +39,10 @@ f_include $BSDCFG_SHARE/struct.subr # Defaults taken from usr.sbin/kbdmap/kbdmap.h # : ${DEFAULT_LANG:=en} -: ${DEFAULT_KEYMAP_DIR:=/usr/share/syscons/keymaps} +case "$( sysctl -n kern.vty )" in +vt) : ${DEFAULT_KEYMAP_DIR:=/usr/share/vt/keymaps} ;; +*) : ${DEFAULT_KEYMAP_DIR:=/usr/share/syscons/keymaps} ;; +esac ############################################################ GLOBALS From owner-svn-src-head@freebsd.org Thu May 25 18:46:15 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1D497D8228E; Thu, 25 May 2017 18:46:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E1C081CFF; Thu, 25 May 2017 18:46:14 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PIkDGt062097; Thu, 25 May 2017 18:46:13 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PIkDrv062096; Thu, 25 May 2017 18:46:13 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705251846.v4PIkDrv062096@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 18:46:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318892 - head/usr.bin/diff3 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.23 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, 25 May 2017 18:46:15 -0000 Author: bapt Date: Thu May 25 18:46:13 2017 New Revision: 318892 URL: https://svnweb.freebsd.org/changeset/base/318892 Log: Update the diff3 manpage to reflect the fact the version in freebsd does not use temporary files nor uses a /usr/libexec/diff3prog Modified: head/usr.bin/diff3/diff3.1 Modified: head/usr.bin/diff3/diff3.1 ============================================================================== --- head/usr.bin/diff3/diff3.1 Thu May 25 18:16:17 2017 (r318891) +++ head/usr.bin/diff3/diff3.1 Thu May 25 18:46:13 2017 (r318892) @@ -30,7 +30,7 @@ .\" @(#)diff3.1 8.2 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" -.Dd $Mdocdate: May 31 2007 $ +.Dd May 25, 2017 .Dt DIFF3 1 .Os .Sh NAME @@ -157,26 +157,6 @@ The lines beneath this notation are rang different in file .Va n . .El -.Sh ENVIRONMENT -.Bl -tag -width TMPDIR -.It Ev TMPDIR -If the environment variable -.Ev TMPDIR -exists, -.Nm -will use the directory specified by -.Ev TMPDIR -as the temporary directory. -.El -.Sh FILES -.Bl -tag -width /usr/libexec/diff3 -compact -.It Pa /tmp/d3a.XXXXXXXXXX -temporary file -.It Pa /tmp/d3b.XXXXXXXXXX -temporary file -.It Pa /usr/libexec/diff3 -the actual executable -.El .Sh SEE ALSO .Xr diff 1 , .Xr ed 1 , From owner-svn-src-head@freebsd.org Thu May 25 19:02:55 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CFA1ED82A3B; Thu, 25 May 2017 19:02:55 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9EE521D87; Thu, 25 May 2017 19:02:55 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PJ2s53070762; Thu, 25 May 2017 19:02:54 GMT (envelope-from cperciva@FreeBSD.org) Received: (from cperciva@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PJ2s1q070760; Thu, 25 May 2017 19:02:54 GMT (envelope-from cperciva@FreeBSD.org) Message-Id: <201705251902.v4PJ2s1q070760@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cperciva set sender to cperciva@FreeBSD.org using -f From: Colin Percival Date: Thu, 25 May 2017 19:02:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318894 - in head/release: . 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.23 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, 25 May 2017 19:02:55 -0000 Author: cperciva Date: Thu May 25 19:02:54 2017 New Revision: 318894 URL: https://svnweb.freebsd.org/changeset/base/318894 Log: Turn on support for the Amazon "Elastic Network Adapter" in EC2 AMIs. X-MFC-after: 318647 + fixes for some lock ordering warnings Modified: head/release/Makefile.ec2 head/release/tools/ec2.conf Modified: head/release/Makefile.ec2 ============================================================================== --- head/release/Makefile.ec2 Thu May 25 18:55:10 2017 (r318893) +++ head/release/Makefile.ec2 Thu May 25 19:02:54 2017 (r318894) @@ -51,7 +51,7 @@ ec2ami: cw-ec2 ${CW_EC2_PORTINSTALL} @echo "--------------------------------------------------------------" @false .endif - /usr/local/bin/bsdec2-image-upload ${PUBLISH} --sriov \ + /usr/local/bin/bsdec2-image-upload ${PUBLISH} --sriov --ena \ ${.OBJDIR}/ec2.raw \ "${TYPE} ${REVISION}-${BRANCH}-${TARGET}${AMINAMESUFFIX}" \ "${TYPE} ${REVISION}-${BRANCH}-${TARGET}" \ Modified: head/release/tools/ec2.conf ============================================================================== --- head/release/tools/ec2.conf Thu May 25 18:55:10 2017 (r318893) +++ head/release/tools/ec2.conf Thu May 25 19:02:54 2017 (r318894) @@ -78,6 +78,9 @@ vm_extra_pre_umount() { # nodes, but apply the workaround just in case. echo 'hw.broken_txfifo="1"' >> ${DESTDIR}/boot/loader.conf + # Load the kernel module for the Amazon "Elastic Network Adapter" + echo 'if_ena_load="YES"' >> ${DESTDIR}/boot/loader.conf + # The first time the AMI boots, the installed "first boot" scripts # should be allowed to run: # * ec2_configinit (download and process EC2 user-data) From owner-svn-src-head@freebsd.org Thu May 25 19:14:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AD785D82D66; Thu, 25 May 2017 19:14:45 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 770421591; Thu, 25 May 2017 19:14:45 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PJEiKs075187; Thu, 25 May 2017 19:14:44 GMT (envelope-from slm@FreeBSD.org) Received: (from slm@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PJEi3l075183; Thu, 25 May 2017 19:14:44 GMT (envelope-from slm@FreeBSD.org) Message-Id: <201705251914.v4PJEi3l075183@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: slm set sender to slm@FreeBSD.org using -f From: Stephen McConnell Date: Thu, 25 May 2017 19:14:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318895 - in head: share/man/man4 sys/dev/mps 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.23 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, 25 May 2017 19:14:45 -0000 Author: slm Date: Thu May 25 19:14:44 2017 New Revision: 318895 URL: https://svnweb.freebsd.org/changeset/base/318895 Log: Fix several problems with mapping code. Reviewed by: ken, scottl, asomers, ambrisko, mav Approved by: ken, mav MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D10878 Modified: head/share/man/man4/mps.4 head/sys/dev/mps/mps.c head/sys/dev/mps/mps_mapping.c head/sys/dev/mps/mps_sas.c head/sys/dev/mps/mps_sas_lsi.c head/sys/dev/mps/mps_user.c head/sys/dev/mps/mpsvar.h Modified: head/share/man/man4/mps.4 ============================================================================== --- head/share/man/man4/mps.4 Thu May 25 19:02:54 2017 (r318894) +++ head/share/man/man4/mps.4 Thu May 25 19:14:44 2017 (r318895) @@ -1,8 +1,8 @@ .\" .\" Copyright (c) 2010 Spectra Logic Corporation .\" Copyright (c) 2014 LSI Corp -.\" Copyright (c) 2016 Avago Technologies -.\" Copyright (c) 2016 Broadcom Ltd. +.\" Copyright (c) 2015-2017 Avago Technologies +.\" Copyright (c) 2015-2017 Broadcom Ltd. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -38,7 +38,7 @@ .\" $Id: //depot/SpectraBSD/head/share/man/man4/mps.4#6 $ .\" $FreeBSD$ .\" -.Dd July 5, 2016 +.Dd May 25, 2017 .Dt MPS 4 .Os .Sh NAME @@ -241,13 +241,13 @@ Send SSU to HDDs, but not to SSDs. Send SSU to both HDDs and SSDs. .El .Pp -To control the feature for a specific adapter, set this tunable value in +To control this feature for a specific adapter, set this tunable value in .Xr loader.conf 5 : .Bd -literal -offset indent dev.mps.X.enable_ssu .Ed .Pp -The same set of values are valid when setting this tunable for all adapters. +The same set of values are valid as when setting this tunable for all adapters. .Pp SATA disks that take several seconds to spin up and fail the SATA Identify command might not be discovered by the driver. @@ -273,6 +273,45 @@ dev.mps.X.spinup_wait_time=NNNN tunable. NNNN is the number of seconds to wait for SATA devices to spin up when they fail the initial SATA Identify command. +.Pp +The driver can map devices discovered by the adapter so that target IDs +corresponding to a specific device persist across resets and reboots. +In some cases it is possible for devices to lose their mapped IDs due to +unexpected behavior from certain hardware, such as some types of enclosures. +To overcome this problem, a tunable is provided that will force the driver to +map devices using the Phy number associated with the device. +This feature is not recommended if the topology includes multiple +enclosures/expanders. +If multiple enclosures/expanders are present in the topology, Phy numbers are +repeated, causing all devices at these Phy numbers except the first device to +fail enumeration. +To control this feature for all adapters, set the +.Bd -literal -offset indent +hw.mps.use_phy_num +.Ed +.Pp +tunable in +.Xr loader.conf 5 +to one of these values: +.Bl -tag -width 6n -offset indent +.It -1 +Only use Phy numbers to map devices and bypass the driver's mapping logic. +.It 0 +Never use Phy numbers to map devices. +.It 1 +Use Phy numbers to map devices, but only if the driver's mapping logic fails +to map the device that is being enumerated. +This is the default value. +.El +.Pp +To control this feature for a specific adapter, set this tunable value in +.Xr loader.conf 5 : +.Bd -literal -offset indent +dev.mps.X.use_phy_num +.Ed +.Pp +The same set of values are valid as when setting this tunable for all adapters. +.Pp .Sh DEBUGGING To enable debugging prints from the .Nm Modified: head/sys/dev/mps/mps.c ============================================================================== --- head/sys/dev/mps/mps.c Thu May 25 19:02:54 2017 (r318894) +++ head/sys/dev/mps/mps.c Thu May 25 19:14:44 2017 (r318895) @@ -505,7 +505,8 @@ mps_iocfacts_allocate(struct mps_softc * */ if (reallocating) { mps_iocfacts_free(sc); - mpssas_realloc_targets(sc, saved_facts.MaxTargets); + mpssas_realloc_targets(sc, saved_facts.MaxTargets + + saved_facts.MaxVolumes); } /* @@ -1518,6 +1519,7 @@ mps_attach(struct mps_softc *sc) mtx_init(&sc->mps_mtx, "MPT2SAS lock", NULL, MTX_DEF); callout_init_mtx(&sc->periodic, &sc->mps_mtx, 0); + callout_init_mtx(&sc->device_check_callout, &sc->mps_mtx, 0); TAILQ_INIT(&sc->event_list); timevalclear(&sc->lastfail); @@ -1682,6 +1684,7 @@ mps_free(struct mps_softc *sc) mps_unlock(sc); /* Lock must not be held for this */ callout_drain(&sc->periodic); + callout_drain(&sc->device_check_callout); if (((error = mps_detach_log(sc)) != 0) || ((error = mps_detach_sas(sc)) != 0)) Modified: head/sys/dev/mps/mps_mapping.c ============================================================================== --- head/sys/dev/mps/mps_mapping.c Thu May 25 19:02:54 2017 (r318894) +++ head/sys/dev/mps/mps_mapping.c Thu May 25 19:14:44 2017 (r318895) @@ -60,7 +60,7 @@ __FBSDID("$FreeBSD$"); #include /** - * _mapping_clear_entry - Clear a particular mapping entry. + * _mapping_clear_map_entry - Clear a particular mapping entry. * @map_entry: map table entry * * Returns nothing. @@ -73,7 +73,6 @@ _mapping_clear_map_entry(struct dev_mapp map_entry->phy_bits = 0; map_entry->dpm_entry_num = MPS_DPM_BAD_IDX; map_entry->dev_handle = 0; - map_entry->channel = -1; map_entry->id = -1; map_entry->missing_count = 0; map_entry->init_complete = 0; @@ -140,12 +139,15 @@ _mapping_commit_enc_entry(struct mps_sof dpm_entry->PhysicalBitsMapping = htole32(et_entry->phy_bits); dpm_entry->Reserved1 = 0; + mps_dprint(sc, MPS_MAPPING, "%s: Writing DPM entry %d for enclosure.\n", + __func__, et_entry->dpm_entry_num); memcpy(&config_page.Entry, (u8 *)dpm_entry, sizeof(Mpi2DriverMap0Entry_t)); if (mps_config_set_dpm_pg0(sc, &mpi_reply, &config_page, et_entry->dpm_entry_num)) { - printf("%s: write of dpm entry %d for enclosure failed\n", - __func__, et_entry->dpm_entry_num); + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: Write of DPM " + "entry %d for enclosure failed.\n", __func__, + et_entry->dpm_entry_num); dpm_entry->MappingInformation = le16toh(dpm_entry-> MappingInformation); dpm_entry->DeviceIndex = le16toh(dpm_entry->DeviceIndex); @@ -164,7 +166,7 @@ _mapping_commit_enc_entry(struct mps_sof /** * _mapping_commit_map_entry - write a particular map table entry in DPM page0. * @sc: per adapter object - * @enc_entry: enclosure table entry + * @mt_entry: mapping table entry * * Returns 0 for success, non-zero for failure. */ @@ -180,6 +182,19 @@ _mapping_commit_map_entry(struct mps_sof if (!sc->is_dpm_enable) return 0; + /* + * It's possible that this Map Entry points to a BAD DPM index. This + * can happen if the Map Entry is a for a missing device and the DPM + * entry that was being used by this device is now being used by some + * new device. So, check for a BAD DPM index and just return if so. + */ + if (mt_entry->dpm_entry_num == MPS_DPM_BAD_IDX) { + mps_dprint(sc, MPS_MAPPING, "%s: DPM entry location for target " + "%d is invalid. DPM will not be written.\n", __func__, + mt_entry->id); + return 0; + } + memset(&config_page, 0, sizeof(Mpi2DriverMappingPage0_t)); memcpy(&config_page.Header, (u8 *)sc->dpm_pg0, sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -193,13 +208,16 @@ _mapping_commit_map_entry(struct mps_sof dpm_entry->MappingInformation = htole16(mt_entry->missing_count); dpm_entry->PhysicalBitsMapping = 0; dpm_entry->Reserved1 = 0; - dpm_entry->MappingInformation = htole16(dpm_entry->MappingInformation); memcpy(&config_page.Entry, (u8 *)dpm_entry, sizeof(Mpi2DriverMap0Entry_t)); + + mps_dprint(sc, MPS_MAPPING, "%s: Writing DPM entry %d for target %d.\n", + __func__, mt_entry->dpm_entry_num, mt_entry->id); if (mps_config_set_dpm_pg0(sc, &mpi_reply, &config_page, mt_entry->dpm_entry_num)) { - printf("%s: write of dpm entry %d for device failed\n", - __func__, mt_entry->dpm_entry_num); + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: Write of DPM " + "entry %d for target %d failed.\n", __func__, + mt_entry->dpm_entry_num, mt_entry->id); dpm_entry->MappingInformation = le16toh(dpm_entry-> MappingInformation); dpm_entry->DeviceIndex = le16toh(dpm_entry->DeviceIndex); @@ -307,7 +325,7 @@ _mapping_get_high_missing_et_idx(struct et_entry = &sc->enclosure_table[enc_idx]; if ((et_entry->missing_count > high_missing_count) && !et_entry->skip_search) { - high_missing_count = et_entry->missing_count; + high_missing_count = et_entry->missing_count; high_idx = enc_idx; } } @@ -326,7 +344,7 @@ _mapping_get_high_missing_et_idx(struct static u32 _mapping_get_high_missing_mt_idx(struct mps_softc *sc) { - u32 map_idx, high_idx = MPS_ENCTABLE_BAD_IDX; + u32 map_idx, high_idx = MPS_MAPTABLE_BAD_IDX; u8 high_missing_count = 0; u32 start_idx, end_idx, start_idx_ir, end_idx_ir; struct dev_mapping_table *mt_entry; @@ -370,7 +388,7 @@ _mapping_get_ir_mt_idx_from_wwid(struct _mapping_get_ir_maprange(sc, &start_idx, &end_idx); mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) + for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) if (mt_entry->physical_id == wwid) return map_idx; @@ -458,20 +476,32 @@ _mapping_get_free_ir_mt_idx(struct mps_s u32 high_idx = MPS_MAPTABLE_BAD_IDX; struct dev_mapping_table *mt_entry; + /* + * The IN_USE flag should be clear if the entry is available to use. + * This flag is cleared on initialization and and when a volume is + * deleted. All other times this flag should be set. If, for some + * reason, a free entry cannot be found, look for the entry with the + * highest missing count just in case there is one. + */ _mapping_get_ir_maprange(sc, &start_idx, &end_idx); mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) + for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) { if (!(mt_entry->device_info & MPS_MAP_IN_USE)) return map_idx; - mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) { if (mt_entry->missing_count > high_missing_count) { high_missing_count = mt_entry->missing_count; high_idx = map_idx; } } + + if (high_idx == MPS_MAPTABLE_BAD_IDX) { + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: Could not find a " + "free entry in the mapping table for a Volume. The mapping " + "table is probably corrupt.\n", __func__); + } + return high_idx; } @@ -494,6 +524,7 @@ _mapping_get_free_mt_idx(struct mps_soft if (sc->ir_firmware && (volume_mapping_flags == MPI2_IOCPAGE8_IRFLAGS_HIGH_VOLUME_MAPPING)) max_idx -= sc->max_volumes; + for (map_idx = start_idx; map_idx < max_idx; map_idx++, mt_entry++) if (!(mt_entry->device_info & (MPS_MAP_IN_USE | MPS_DEV_RESERVED))) @@ -542,12 +573,66 @@ static u32 _mapping_get_free_dpm_idx(struct mps_softc *sc) { u16 entry_num; + Mpi2DriverMap0Entry_t *dpm_entry; + u16 current_entry = MPS_DPM_BAD_IDX, missing_cnt, high_missing_cnt = 0; + u64 physical_id; + struct dev_mapping_table *mt_entry; + u32 map_idx; - for (entry_num = 0; entry_num < sc->max_dpm_entries; entry_num++) { - if (!sc->dpm_entry_used[entry_num]) - return entry_num; + for (entry_num = 0; entry_num < sc->max_dpm_entries; entry_num++) { + dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); + dpm_entry += entry_num; + missing_cnt = dpm_entry->MappingInformation & + MPI2_DRVMAP0_MAPINFO_MISSING_MASK; + + /* + * If entry is used and not missing, then this entry can't be + * used. Look at next one. + */ + if (sc->dpm_entry_used[entry_num] && !missing_cnt) + continue; + + /* + * If this entry is not used at all, then the missing count + * doesn't matter. Just use this one. Otherwise, keep looking + * and make sure the entry with the highest missing count is + * used. + */ + if (!sc->dpm_entry_used[entry_num]) { + current_entry = entry_num; + break; + } + if ((current_entry == MPS_DPM_BAD_IDX) || + (missing_cnt > high_missing_cnt)) { + current_entry = entry_num; + high_missing_cnt = missing_cnt; + } + } + + /* + * If an entry has been found to use and it's already marked as used + * it means that some device was already using this entry but it's + * missing, and that means that the connection between the missing + * device's DPM entry and the mapping table needs to be cleared. To do + * this, use the Physical ID of the old device still in the DPM entry + * to find its mapping table entry, then mark its DPM entry as BAD. + */ + if ((current_entry != MPS_DPM_BAD_IDX) && + sc->dpm_entry_used[current_entry]) { + dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); + dpm_entry += current_entry; + physical_id = dpm_entry->PhysicalIdentifier.High; + physical_id = (physical_id << 32) | + dpm_entry->PhysicalIdentifier.Low; + map_idx = _mapping_get_mt_idx_from_id(sc, physical_id); + if (map_idx != MPS_MAPTABLE_BAD_IDX) { + mt_entry = &sc->mapping_table[map_idx]; + mt_entry->dpm_entry_num = MPS_DPM_BAD_IDX; + } } - return MPS_DPM_BAD_IDX; + return current_entry; } /** @@ -566,40 +651,57 @@ _mapping_update_ir_missing_cnt(struct mp Mpi2EventIrConfigElement_t *element, u64 wwid) { struct dev_mapping_table *mt_entry; - u8 missing_cnt, reason = element->ReasonCode; + u8 missing_cnt, reason = element->ReasonCode, update_dpm = 1; u16 dpm_idx; Mpi2DriverMap0Entry_t *dpm_entry; - if (!sc->is_dpm_enable) - return; + /* + * Depending on the reason code, update the missing count. Always set + * the init_complete flag when here, so just do it first. That flag is + * used for volumes to make sure that the DPM entry has been updated. + * When a volume is deleted, clear the map entry's IN_USE flag so that + * the entry can be used again if another volume is created. Also clear + * its dev_handle entry so that other functions can't find this volume + * by the handle, since it's not defined any longer. + */ mt_entry = &sc->mapping_table[map_idx]; - if (reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) { + mt_entry->init_complete = 1; + if ((reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) || + (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_CREATED)) { mt_entry->missing_count = 0; - } else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_CREATED) { - mt_entry->missing_count = 0; - mt_entry->init_complete = 0; - } else if ((reason == MPI2_EVENT_IR_CHANGE_RC_REMOVED) || - (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED)) { - if (!mt_entry->init_complete) { - if (mt_entry->missing_count < MPS_MAX_MISSING_COUNT) - mt_entry->missing_count++; - else - mt_entry->init_complete = 1; - } - if (!mt_entry->missing_count) + } else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) { + if (mt_entry->missing_count < MPS_MAX_MISSING_COUNT) mt_entry->missing_count++; + + mt_entry->device_info &= ~MPS_MAP_IN_USE; mt_entry->dev_handle = 0; } + /* + * If persistent mapping is enabled, update the DPM with the new missing + * count for the volume. If the DPM index is bad, get a free one. If + * it's bad for a volume that's being deleted do nothing because that + * volume doesn't have a DPM entry. + */ + if (!sc->is_dpm_enable) + return; dpm_idx = mt_entry->dpm_entry_num; if (dpm_idx == MPS_DPM_BAD_IDX) { - if ((reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) || - (reason == MPI2_EVENT_IR_CHANGE_RC_REMOVED)) - dpm_idx = _mapping_get_dpm_idx_from_id(sc, - mt_entry->physical_id, 0); - else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) + if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) + { + mps_dprint(sc, MPS_MAPPING, "%s: Volume being deleted " + "is not in DPM so DPM missing count will not be " + "updated.\n", __func__); return; + } } + if (dpm_idx == MPS_DPM_BAD_IDX) + dpm_idx = _mapping_get_free_dpm_idx(sc); + + /* + * Got the DPM entry for the volume or found a free DPM entry if this is + * a new volume. Check if the current information is outdated. + */ if (dpm_idx != MPS_DPM_BAD_IDX) { dpm_entry = (Mpi2DriverMap0Entry_t *)((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -607,17 +709,25 @@ _mapping_update_ir_missing_cnt(struct mp missing_cnt = dpm_entry->MappingInformation & MPI2_DRVMAP0_MAPINFO_MISSING_MASK; if ((mt_entry->physical_id == - le64toh((u64)dpm_entry->PhysicalIdentifier.High | - dpm_entry->PhysicalIdentifier.Low)) && (missing_cnt == - mt_entry->missing_count)) - mt_entry->init_complete = 1; - } else { - dpm_idx = _mapping_get_free_dpm_idx(sc); - mt_entry->init_complete = 0; + le64toh(((u64)dpm_entry->PhysicalIdentifier.High << 32) | + (u64)dpm_entry->PhysicalIdentifier.Low)) && (missing_cnt == + mt_entry->missing_count)) { + mps_dprint(sc, MPS_MAPPING, "%s: DPM entry for volume " + "with target ID %d does not require an update.\n", + __func__, mt_entry->id); + update_dpm = 0; + } } - if ((dpm_idx != MPS_DPM_BAD_IDX) && !mt_entry->init_complete) { - mt_entry->init_complete = 1; + /* + * Update the volume's persistent info if it's new or the ID or missing + * count has changed. If a good DPM index has not been found by now, + * there is no space left in the DPM table. + */ + if ((dpm_idx != MPS_DPM_BAD_IDX) && update_dpm) { + mps_dprint(sc, MPS_MAPPING, "%s: Update DPM entry for volume " + "with target ID %d.\n", __func__, mt_entry->id); + mt_entry->dpm_entry_num = dpm_idx; dpm_entry = (Mpi2DriverMap0Entry_t *)((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -633,44 +743,47 @@ _mapping_update_ir_missing_cnt(struct mp sc->dpm_flush_entry[dpm_idx] = 1; sc->dpm_entry_used[dpm_idx] = 1; } else if (dpm_idx == MPS_DPM_BAD_IDX) { - printf("%s: no space to add entry in DPM table\n", __func__); - mt_entry->init_complete = 1; + mps_dprint(sc, MPS_INFO | MPS_MAPPING, "%s: No space to add an " + "entry in the DPM table for volume with target ID %d.\n", + __func__, mt_entry->id); } } /** - * _mapping_add_to_removal_table - mark an entry for removal + * _mapping_add_to_removal_table - add DPM index to the removal table * @sc: per adapter object - * @handle: Handle of enclosures/device/volume + * @dpm_idx: Index of DPM entry to remove * - * Adds the handle or DPM entry number in removal table. + * Adds a DPM entry number to the removal table. * * Returns nothing. */ static void -_mapping_add_to_removal_table(struct mps_softc *sc, u16 handle, - u16 dpm_idx) +_mapping_add_to_removal_table(struct mps_softc *sc, u16 dpm_idx) { struct map_removal_table *remove_entry; u32 i; - u16 ioc_pg8_flags = le16toh(sc->ioc_pg8.Flags); + /* + * This is only used to remove entries from the DPM in the controller. + * If DPM is not enabled, just return. + */ + if (!sc->is_dpm_enable) + return; + + /* + * Find the first available removal_table entry and add the new entry + * there. + */ remove_entry = sc->removal_table; for (i = 0; i < sc->max_devices; i++, remove_entry++) { - if (remove_entry->dev_handle || remove_entry->dpm_entry_num != - MPS_DPM_BAD_IDX) + if (remove_entry->dpm_entry_num != MPS_DPM_BAD_IDX) continue; - if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == - MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { - if (dpm_idx) - remove_entry->dpm_entry_num = dpm_idx; - if (remove_entry->dpm_entry_num == MPS_DPM_BAD_IDX) - remove_entry->dev_handle = handle; - } else if ((ioc_pg8_flags & - MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == - MPI2_IOCPAGE8_FLAGS_DEVICE_PERSISTENCE_MAPPING) - remove_entry->dev_handle = handle; + + mps_dprint(sc, MPS_MAPPING, "%s: Adding DPM entry %d to table " + "for removal.\n", __func__, dpm_idx); + remove_entry->dpm_entry_num = dpm_idx; break; } @@ -681,8 +794,13 @@ _mapping_add_to_removal_table(struct mps * @sc: per adapter object * @topo_change: Topology change event entry * - * Search through the topology change list and if any device is found not - * responding it's associated map table entry and DPM entry is updated + * Increment the missing count in the mapping table for a device that is not + * responding. If Persitent Mapping is used, increment the DPM entry as well. + * Currently, this function only increments the missing count if the device + * goes missing, so after initialization has completed. This means that the + * missing count can only go from 0 to 1 here. The missing count is incremented + * during initialization as well, so that's where a target's missing count can + * go past 1. * * Returns nothing. */ @@ -706,34 +824,45 @@ _mapping_update_missing_count(struct mps dev_handle); phy_change->is_processed = 1; if (map_idx == MPS_MAPTABLE_BAD_IDX) { - printf("%s: device is already removed from mapping " - "table\n", __func__); + mps_dprint(sc, MPS_INFO | MPS_MAPPING, "%s: device is " + "already removed from mapping table\n", __func__); continue; } mt_entry = &sc->mapping_table[map_idx]; - if (!mt_entry->init_complete) { - if (mt_entry->missing_count < MPS_MAX_MISSING_COUNT) - mt_entry->missing_count++; - else - mt_entry->init_complete = 1; - } - if (!mt_entry->missing_count) + if (mt_entry->missing_count < MPS_MAX_MISSING_COUNT) mt_entry->missing_count++; - _mapping_add_to_removal_table(sc, mt_entry->dev_handle, 0); - mt_entry->dev_handle = 0; + /* + * When using Enc/Slot mapping, when a device is removed, it's + * mapping table information should be cleared. Otherwise, the + * target ID will be incorrect if this same device is re-added + * to a different slot. + */ + if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == + MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { + _mapping_clear_map_entry(mt_entry); + } + + /* + * When using device mapping, update the missing count in the + * DPM entry, but only if the missing count has changed. + */ if (((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_DEVICE_PERSISTENCE_MAPPING) && - sc->is_dpm_enable && !mt_entry->init_complete && + sc->is_dpm_enable && mt_entry->dpm_entry_num != MPS_DPM_BAD_IDX) { dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); dpm_entry += mt_entry->dpm_entry_num; - dpm_entry->MappingInformation = mt_entry->missing_count; - sc->dpm_flush_entry[mt_entry->dpm_entry_num] = 1; + if (dpm_entry->MappingInformation != + mt_entry->missing_count) { + dpm_entry->MappingInformation = + mt_entry->missing_count; + sc->dpm_flush_entry[mt_entry->dpm_entry_num] = + 1; + } } - mt_entry->init_complete = 1; } } @@ -766,6 +895,10 @@ _mapping_find_enc_map_space(struct mps_s vol_mapping_flags = le16toh(sc->ioc_pg8.IRVolumeMappingFlags) & MPI2_IOCPAGE8_IRFLAGS_MASK_VOLUME_MAPPING_MODE; + /* + * The end of the mapping table depends on where volumes are kept, if + * IR is enabled. + */ if (!sc->ir_firmware) end_of_table = sc->max_devices; else if (vol_mapping_flags == MPI2_IOCPAGE8_IRFLAGS_LOW_VOLUME_MAPPING) @@ -773,6 +906,17 @@ _mapping_find_enc_map_space(struct mps_s else end_of_table = sc->max_devices - sc->max_volumes; + /* + * The skip_count is the number of entries that are reserved at the + * beginning of the mapping table. But, it does not include the number + * of Physical IDs that are reserved for direct attached devices. Look + * through the mapping table after these reserved entries to see if + * the devices for this enclosure are already mapped. The PHY bit check + * is used to make sure that at least one PHY bit is common between the + * enclosure and the device that is already mapped. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Looking for space in the mapping " + "table for added enclosure.\n", __func__); for (map_idx = (max_num_phy_ids + skip_count); map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; @@ -782,11 +926,21 @@ _mapping_find_enc_map_space(struct mps_s num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; + mps_dprint(sc, MPS_MAPPING, "%s: Found space " + "in the mapping for enclosure at map index " + "%d.\n", __func__, start_idx); return start_idx; } } else num_found = 0; } + + /* + * If the enclosure's devices are not mapped already, look for + * contiguous entries in the mapping table that are not reserved. If + * enough entries are found, return the starting index for that space. + */ + num_found = 0; for (map_idx = (max_num_phy_ids + skip_count); map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; @@ -794,40 +948,91 @@ _mapping_find_enc_map_space(struct mps_s num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; + mps_dprint(sc, MPS_MAPPING, "%s: Found space " + "in the mapping for enclosure at map index " + "%d.\n", __func__, start_idx); return start_idx; } } else num_found = 0; } + /* + * If here, it means that not enough space in the mapping table was + * found to support this enclosure, so go through the enclosure table to + * see if any enclosure entries have a missing count. If so, get the + * enclosure with the highest missing count and check it to see if there + * is enough space for the new enclosure. + */ while (!done_flag) { enc_idx = _mapping_get_high_missing_et_idx(sc); - if (enc_idx == MPS_ENCTABLE_BAD_IDX) + if (enc_idx == MPS_ENCTABLE_BAD_IDX) { + mps_dprint(sc, MPS_MAPPING, "%s: Not enough space was " + "found in the mapping for the added enclosure.\n", + __func__); return MPS_MAPTABLE_BAD_IDX; + } + + /* + * Found a missing enclosure. Set the skip_search flag so this + * enclosure is not checked again for a high missing count if + * the loop continues. This way, all missing enclosures can + * have their space added together to find enough space in the + * mapping table for the added enclosure. The space must be + * contiguous. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Space from a missing " + "enclosure was found.\n", __func__); enc_entry = &sc->enclosure_table[enc_idx]; - /*VSP FIXME*/ enc_entry->skip_search = 1; + + /* + * Unmark all of the missing enclosure's device's reserved + * space. These will be remarked as reserved if this missing + * enclosure's space is not used. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Clear the reserved flag for " + "all of the map entries for the enclosure.\n", __func__); mt_entry = &sc->mapping_table[enc_entry->start_index]; for (map_idx = enc_entry->start_index; map_idx < (enc_entry->start_index + enc_entry->num_slots); map_idx++, mt_entry++) - mt_entry->device_info &= ~MPS_DEV_RESERVED; + mt_entry->device_info &= ~MPS_DEV_RESERVED; + + /* + * Now that space has been unreserved, check again to see if + * enough space is available for the new enclosure. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Check if new mapping space is " + "enough for the new enclosure.\n", __func__); found_space = 0; - for (map_idx = (max_num_phy_ids + - skip_count); map_idx < end_of_table; map_idx++) { + num_found = 0; + for (map_idx = (max_num_phy_ids + skip_count); + map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; if (!(mt_entry->device_info & MPS_DEV_RESERVED)) { num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; found_space = 1; + break; } } else num_found = 0; } - if (!found_space) continue; + + /* + * If enough space was found, all of the missing enclosures that + * will be used for the new enclosure must be added to the + * removal table. Then all mappings for the enclosure's devices + * and for the enclosure itself need to be cleared. There may be + * more than one enclosure to add to the removal table and + * clear. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Found space in the mapping " + "for enclosure at map index %d.\n", __func__, start_idx); for (map_idx = start_idx; map_idx < (start_idx + num_found); map_idx++) { enc_entry = sc->enclosure_table; @@ -838,26 +1043,38 @@ _mapping_find_enc_map_space(struct mps_s enc_entry->num_slots)) continue; if (!enc_entry->removal_flag) { + mps_dprint(sc, MPS_MAPPING, "%s: " + "Enclosure %d will be removed from " + "the mapping table.\n", __func__, + enc_idx); enc_entry->removal_flag = 1; - _mapping_add_to_removal_table(sc, 0, + _mapping_add_to_removal_table(sc, enc_entry->dpm_entry_num); } mt_entry = &sc->mapping_table[map_idx]; - if (mt_entry->device_info & - MPS_MAP_IN_USE) { - _mapping_add_to_removal_table(sc, - mt_entry->dev_handle, 0); - _mapping_clear_map_entry(mt_entry); - } + _mapping_clear_map_entry(mt_entry); if (map_idx == (enc_entry->start_index + enc_entry->num_slots - 1)) _mapping_clear_enc_entry(et_entry); } } + + /* + * During the search for space for this enclosure, some entries + * in the mapping table may have been unreserved. Go back and + * change all of these to reserved again. Only the enclosures + * with the removal_flag set should be left as unreserved. The + * skip_search flag needs to be cleared as well so that the + * enclosure's space will be looked at the next time space is + * needed. + */ enc_entry = sc->enclosure_table; for (enc_idx = 0; enc_idx < sc->num_enc_table_entries; enc_idx++, enc_entry++) { if (!enc_entry->removal_flag) { + mps_dprint(sc, MPS_MAPPING, "%s: Reset the " + "reserved flag for all of the map entries " + "for enclosure %d.\n", __func__, enc_idx); mt_entry = &sc->mapping_table[enc_entry-> start_index]; for (map_idx = enc_entry->start_index; map_idx < @@ -905,6 +1122,7 @@ _mapping_get_dev_info(struct mps_softc * if (phy_change->is_processed || !phy_change->dev_handle || phy_change->reason != MPI2_EVENT_SAS_TOPO_RC_TARG_ADDED) continue; + if (mps_config_get_sas_device_pg0(sc, &mpi_reply, &sas_device_pg0, MPI2_SAS_DEVICE_PGAD_FORM_HANDLE, phy_change->dev_handle)) { @@ -918,9 +1136,9 @@ _mapping_get_dev_info(struct mps_softc * * when the system is shutdown. */ device_info = le32toh(sas_device_pg0.DeviceInfo); - sas_address = sas_device_pg0.SASAddress.High; + sas_address = le32toh(sas_device_pg0.SASAddress.High); sas_address = (sas_address << 32) | - sas_device_pg0.SASAddress.Low; + le32toh(sas_device_pg0.SASAddress.Low); if ((device_info & MPI2_SAS_DEVICE_INFO_END_DEVICE) && (device_info & MPI2_SAS_DEVICE_INFO_SATA_DEVICE)) { rc = mpssas_get_sas_address_for_sata_disk(sc, @@ -939,18 +1157,29 @@ _mapping_get_dev_info(struct mps_softc * phy_change->physical_id = sas_address; phy_change->slot = le16toh(sas_device_pg0.Slot); - phy_change->device_info = le32toh(sas_device_pg0.DeviceInfo); + phy_change->device_info = device_info; + /* + * When using Enc/Slot mapping, if this device is an enclosure + * make sure that all of its slots can fit into the mapping + * table. + */ if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { + /* + * The enclosure should already be in the enclosure + * table due to the Enclosure Add event. If not, just + * continue, nothing can be done. + */ enc_idx = _mapping_get_enc_idx_from_handle(sc, topo_change->enc_handle); if (enc_idx == MPS_ENCTABLE_BAD_IDX) { phy_change->is_processed = 1; - mps_dprint(sc, MPS_MAPPING, "%s: failed to add " - "the device with handle 0x%04x because the " - "enclosure is not in the mapping table\n", - __func__, phy_change->dev_handle); + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because the enclosure is not in " + "the mapping table\n", __func__, + phy_change->dev_handle); continue; } if (!((phy_change->device_info & @@ -963,8 +1192,20 @@ _mapping_get_dev_info(struct mps_softc * continue; } et_entry = &sc->enclosure_table[enc_idx]; + + /* + * If the enclosure already has a start_index, it's been + * mapped, so go to the next Topo change. + */ if (et_entry->start_index != MPS_MAPTABLE_BAD_IDX) continue; + + /* + * If the Expander Handle is 0, the devices are direct + * attached. In that case, the start_index must be just + * after the reserved entries. Otherwise, find space in + * the mapping table for the enclosure's devices. + */ if (!topo_change->exp_handle) { map_idx = sc->num_rsvd_entries; et_entry->start_index = map_idx; @@ -972,8 +1213,26 @@ _mapping_get_dev_info(struct mps_softc * map_idx = _mapping_find_enc_map_space(sc, et_entry); et_entry->start_index = map_idx; + + /* + * If space cannot be found to hold all of the + * enclosure's devices in the mapping table, + * there's no need to continue checking the + * other devices in this event. Set all of the + * phy_details for this event (if the change is + * for an add) as already processed because none + * of these devices can be added to the mapping + * table. + */ if (et_entry->start_index == MPS_MAPTABLE_BAD_IDX) { + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, + "%s: failed to add the enclosure " + "with ID 0x%016jx because there is " + "no free space available in the " + "mapping table for all of the " + "enclosure's devices.\n", __func__, + (uintmax_t)et_entry->enclosure_id); phy_change->is_processed = 1; for (phy_idx = 0; phy_idx < topo_change->num_entries; @@ -989,12 +1248,22 @@ _mapping_get_dev_info(struct mps_softc * break; } } + + /* + * Found space in the mapping table for this enclosure. + * Initialize each mapping table entry for the + * enclosure. + */ + mps_dprint(sc, MPS_MAPPING, "%s: Initialize %d map " + "entries for the enclosure, starting at map index " + " %d.\n", __func__, et_entry->num_slots, map_idx); mt_entry = &sc->mapping_table[map_idx]; for (index = map_idx; index < (et_entry->num_slots + map_idx); index++, mt_entry++) { mt_entry->device_info = MPS_DEV_RESERVED; mt_entry->physical_id = et_entry->enclosure_id; mt_entry->phy_bits = et_entry->phy_bits; + mt_entry->missing_count = 0; } } } @@ -1014,6 +1283,7 @@ _mapping_set_mid_to_eid(struct mps_softc struct dev_mapping_table *mt_entry; u16 slots = et_entry->num_slots, map_idx; u32 start_idx = et_entry->start_index; + if (start_idx != MPS_MAPTABLE_BAD_IDX) { mt_entry = &sc->mapping_table[start_idx]; for (map_idx = 0; map_idx < slots; map_idx++, mt_entry++) @@ -1063,6 +1333,13 @@ _mapping_clear_removed_entries(struct mp } } } + + /* + * When using Enc/Slot mapping, if a new enclosure was added and old + * enclosure space was needed, the enclosure table may now have gaps + * that need to be closed. All enclosure mappings need to be contiguous + * so that space can be reused correctly if available. + */ if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { num_entries = sc->num_enc_table_entries; @@ -1105,8 +1382,8 @@ _mapping_clear_removed_entries(struct mp * @sc: per adapter object * @topo_change: Topology change event entry * - * Search through the topology change event list and updates map table, - * enclosure table and DPM pages for for the newly added devices. + * Search through the topology change event list and update map table, + * enclosure table and DPM pages for the newly added devices. * * Returns nothing */ @@ -1143,30 +1420,41 @@ _mapping_add_new_device(struct mps_softc (sc, topo_change->enc_handle); if (enc_idx == MPS_ENCTABLE_BAD_IDX) { phy_change->is_processed = 1; - printf("%s: failed to add the device with " - "handle 0x%04x because the enclosure is " - "not in the mapping table\n", __func__, + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because the enclosure is not in " + "the mapping table\n", __func__, phy_change->dev_handle); continue; } + + /* + * If the enclosure's start_index is BAD here, it means + * that there is no room in the mapping table to cover + * all of the devices that could be in the enclosure. + * There's no reason to process any of the devices for + * this enclosure since they can't be mapped. + */ et_entry = &sc->enclosure_table[enc_idx]; if (et_entry->start_index == MPS_MAPTABLE_BAD_IDX) { phy_change->is_processed = 1; - if (!sc->mt_full_retry) { - sc->mt_add_device_failed = 1; - continue; - } - printf("%s: failed to add the device with " - "handle 0x%04x because there is no free " - "space available in the mapping table\n", + mps_dprint(sc, MPS_ERROR | MPS_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because there is no free space " + "available in the mapping table\n", __func__, phy_change->dev_handle); continue; } + + /* + * Add this device to the mapping table at the correct + * offset where space was found to map the enclosure. + * Then setup the DPM entry information if being used. + */ map_idx = et_entry->start_index + phy_change->slot - et_entry->start_slot; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Thu May 25 19:17:03 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8F3ADD82EC8; Thu, 25 May 2017 19:17:03 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 71BFF1846; Thu, 25 May 2017 19:17:03 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id 98188493E; Thu, 25 May 2017 19:17:02 +0000 (UTC) Date: Thu, 25 May 2017 19:17:02 +0000 From: Alexey Dokuchaev To: Stephen McConnell Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318895 - in head: share/man/man4 sys/dev/mps Message-ID: <20170525191702.GB27521@FreeBSD.org> References: <201705251914.v4PJEi3l075183@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705251914.v4PJEi3l075183@repo.freebsd.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 25 May 2017 19:17:03 -0000 On Thu, May 25, 2017 at 07:14:44PM +0000, Stephen McConnell wrote: > New Revision: 318895 > URL: https://svnweb.freebsd.org/changeset/base/318895 > > Log: > Fix several problems with mapping code. > > Reviewed by: ken, scottl, asomers, ambrisko, mav > Approved by: ken, mav > MFC after: 1 week > Differential Revision: https://reviews.freebsd.org/D10878 It would be nice to mention, at least briefly, what were those problems in the commit log. ./danfe From owner-svn-src-head@freebsd.org Thu May 25 19:20:07 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8BDB1D82087; Thu, 25 May 2017 19:20:07 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 551AB1AC1; Thu, 25 May 2017 19:20:07 +0000 (UTC) (envelope-from slm@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PJK6bF075434; Thu, 25 May 2017 19:20:06 GMT (envelope-from slm@FreeBSD.org) Received: (from slm@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PJK6AL075430; Thu, 25 May 2017 19:20:06 GMT (envelope-from slm@FreeBSD.org) Message-Id: <201705251920.v4PJK6AL075430@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: slm set sender to slm@FreeBSD.org using -f From: Stephen McConnell Date: Thu, 25 May 2017 19:20:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318896 - in head: share/man/man4 sys/dev/mpr 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.23 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, 25 May 2017 19:20:07 -0000 Author: slm Date: Thu May 25 19:20:06 2017 New Revision: 318896 URL: https://svnweb.freebsd.org/changeset/base/318896 Log: Fix several problems with mapping code. Reviewed by: ken, scottl, asomers, ambrisko, mav Approved by: ken, mav MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D10861 Modified: head/share/man/man4/mpr.4 head/sys/dev/mpr/mpr.c head/sys/dev/mpr/mpr_mapping.c head/sys/dev/mpr/mpr_sas.c head/sys/dev/mpr/mpr_sas_lsi.c head/sys/dev/mpr/mpr_user.c head/sys/dev/mpr/mprvar.h Modified: head/share/man/man4/mpr.4 ============================================================================== --- head/share/man/man4/mpr.4 Thu May 25 19:14:44 2017 (r318895) +++ head/share/man/man4/mpr.4 Thu May 25 19:20:06 2017 (r318896) @@ -1,8 +1,8 @@ .\" .\" Copyright (c) 2010 Spectra Logic Corporation .\" Copyright (c) 2014 LSI Corp -.\" Copyright (c) 2017 Avago Technologies -.\" Copyright (c) 2017 Broadcom Ltd. +.\" Copyright (c) 2015-2017 Avago Technologies +.\" Copyright (c) 2015-2017 Broadcom Ltd. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -38,7 +38,7 @@ .\" $Id$ .\" $FreeBSD$ .\" -.Dd May 17, 2017 +.Dd May 25, 2017 .Dt MPR 4 .Os .Sh NAME Modified: head/sys/dev/mpr/mpr.c ============================================================================== --- head/sys/dev/mpr/mpr.c Thu May 25 19:14:44 2017 (r318895) +++ head/sys/dev/mpr/mpr.c Thu May 25 19:20:06 2017 (r318896) @@ -520,7 +520,8 @@ mpr_iocfacts_allocate(struct mpr_softc * */ if (reallocating) { mpr_iocfacts_free(sc); - mprsas_realloc_targets(sc, saved_facts.MaxTargets); + mprsas_realloc_targets(sc, saved_facts.MaxTargets + + saved_facts.MaxVolumes); } /* @@ -1663,6 +1664,7 @@ mpr_attach(struct mpr_softc *sc) mtx_init(&sc->mpr_mtx, "MPR lock", NULL, MTX_DEF); callout_init_mtx(&sc->periodic, &sc->mpr_mtx, 0); + callout_init_mtx(&sc->device_check_callout, &sc->mpr_mtx, 0); TAILQ_INIT(&sc->event_list); timevalclear(&sc->lastfail); @@ -1832,6 +1834,7 @@ mpr_free(struct mpr_softc *sc) mpr_unlock(sc); /* Lock must not be held for this */ callout_drain(&sc->periodic); + callout_drain(&sc->device_check_callout); if (((error = mpr_detach_log(sc)) != 0) || ((error = mpr_detach_sas(sc)) != 0)) Modified: head/sys/dev/mpr/mpr_mapping.c ============================================================================== --- head/sys/dev/mpr/mpr_mapping.c Thu May 25 19:14:44 2017 (r318895) +++ head/sys/dev/mpr/mpr_mapping.c Thu May 25 19:20:06 2017 (r318896) @@ -60,7 +60,7 @@ __FBSDID("$FreeBSD$"); #include /** - * _mapping_clear_entry - Clear a particular mapping entry. + * _mapping_clear_map_entry - Clear a particular mapping entry. * @map_entry: map table entry * * Returns nothing. @@ -73,7 +73,6 @@ _mapping_clear_map_entry(struct dev_mapp map_entry->phy_bits = 0; map_entry->dpm_entry_num = MPR_DPM_BAD_IDX; map_entry->dev_handle = 0; - map_entry->channel = -1; map_entry->id = -1; map_entry->missing_count = 0; map_entry->init_complete = 0; @@ -140,12 +139,15 @@ _mapping_commit_enc_entry(struct mpr_sof dpm_entry->PhysicalBitsMapping = htole32(et_entry->phy_bits); dpm_entry->Reserved1 = 0; + mpr_dprint(sc, MPR_MAPPING, "%s: Writing DPM entry %d for enclosure.\n", + __func__, et_entry->dpm_entry_num); memcpy(&config_page.Entry, (u8 *)dpm_entry, sizeof(Mpi2DriverMap0Entry_t)); if (mpr_config_set_dpm_pg0(sc, &mpi_reply, &config_page, et_entry->dpm_entry_num)) { - printf("%s: write of dpm entry %d for enclosure failed\n", - __func__, et_entry->dpm_entry_num); + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: Write of DPM " + "entry %d for enclosure failed.\n", __func__, + et_entry->dpm_entry_num); dpm_entry->MappingInformation = le16toh(dpm_entry-> MappingInformation); dpm_entry->DeviceIndex = le16toh(dpm_entry->DeviceIndex); @@ -164,7 +166,7 @@ _mapping_commit_enc_entry(struct mpr_sof /** * _mapping_commit_map_entry - write a particular map table entry in DPM page0. * @sc: per adapter object - * @enc_entry: enclosure table entry + * @mt_entry: mapping table entry * * Returns 0 for success, non-zero for failure. */ @@ -180,6 +182,19 @@ _mapping_commit_map_entry(struct mpr_sof if (!sc->is_dpm_enable) return 0; + /* + * It's possible that this Map Entry points to a BAD DPM index. This + * can happen if the Map Entry is a for a missing device and the DPM + * entry that was being used by this device is now being used by some + * new device. So, check for a BAD DPM index and just return if so. + */ + if (mt_entry->dpm_entry_num == MPR_DPM_BAD_IDX) { + mpr_dprint(sc, MPR_MAPPING, "%s: DPM entry location for target " + "%d is invalid. DPM will not be written.\n", __func__, + mt_entry->id); + return 0; + } + memset(&config_page, 0, sizeof(Mpi2DriverMappingPage0_t)); memcpy(&config_page.Header, (u8 *)sc->dpm_pg0, sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -193,13 +208,16 @@ _mapping_commit_map_entry(struct mpr_sof dpm_entry->MappingInformation = htole16(mt_entry->missing_count); dpm_entry->PhysicalBitsMapping = 0; dpm_entry->Reserved1 = 0; - dpm_entry->MappingInformation = htole16(dpm_entry->MappingInformation); memcpy(&config_page.Entry, (u8 *)dpm_entry, sizeof(Mpi2DriverMap0Entry_t)); + + mpr_dprint(sc, MPR_MAPPING, "%s: Writing DPM entry %d for target %d.\n", + __func__, mt_entry->dpm_entry_num, mt_entry->id); if (mpr_config_set_dpm_pg0(sc, &mpi_reply, &config_page, mt_entry->dpm_entry_num)) { - printf("%s: write of dpm entry %d for device failed\n", - __func__, mt_entry->dpm_entry_num); + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: Write of DPM " + "entry %d for target %d failed.\n", __func__, + mt_entry->dpm_entry_num, mt_entry->id); dpm_entry->MappingInformation = le16toh(dpm_entry-> MappingInformation); dpm_entry->DeviceIndex = le16toh(dpm_entry->DeviceIndex); @@ -307,7 +325,7 @@ _mapping_get_high_missing_et_idx(struct et_entry = &sc->enclosure_table[enc_idx]; if ((et_entry->missing_count > high_missing_count) && !et_entry->skip_search) { - high_missing_count = et_entry->missing_count; + high_missing_count = et_entry->missing_count; high_idx = enc_idx; } } @@ -326,7 +344,7 @@ _mapping_get_high_missing_et_idx(struct static u32 _mapping_get_high_missing_mt_idx(struct mpr_softc *sc) { - u32 map_idx, high_idx = MPR_ENCTABLE_BAD_IDX; + u32 map_idx, high_idx = MPR_MAPTABLE_BAD_IDX; u8 high_missing_count = 0; u32 start_idx, end_idx, start_idx_ir, end_idx_ir; struct dev_mapping_table *mt_entry; @@ -370,7 +388,7 @@ _mapping_get_ir_mt_idx_from_wwid(struct _mapping_get_ir_maprange(sc, &start_idx, &end_idx); mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) + for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) if (mt_entry->physical_id == wwid) return map_idx; @@ -458,20 +476,31 @@ _mapping_get_free_ir_mt_idx(struct mpr_s u32 high_idx = MPR_MAPTABLE_BAD_IDX; struct dev_mapping_table *mt_entry; + /* + * The IN_USE flag should be clear if the entry is available to use. + * This flag is cleared on initialization and and when a volume is + * deleted. All other times this flag should be set. If, for some + * reason, a free entry cannot be found, look for the entry with the + * highest missing count just in case there is one. + */ _mapping_get_ir_maprange(sc, &start_idx, &end_idx); - mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) + for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) { if (!(mt_entry->device_info & MPR_MAP_IN_USE)) return map_idx; - mt_entry = &sc->mapping_table[start_idx]; - for (map_idx = start_idx; map_idx <= end_idx; map_idx++, mt_entry++) { if (mt_entry->missing_count > high_missing_count) { high_missing_count = mt_entry->missing_count; high_idx = map_idx; } } + + if (high_idx == MPR_MAPTABLE_BAD_IDX) { + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: Could not find a " + "free entry in the mapping table for a Volume. The mapping " + "table is probably corrupt.\n", __func__); + } + return high_idx; } @@ -494,6 +523,7 @@ _mapping_get_free_mt_idx(struct mpr_soft if (sc->ir_firmware && (volume_mapping_flags == MPI2_IOCPAGE8_IRFLAGS_HIGH_VOLUME_MAPPING)) max_idx -= sc->max_volumes; + for (map_idx = start_idx; map_idx < max_idx; map_idx++, mt_entry++) if (!(mt_entry->device_info & (MPR_MAP_IN_USE | MPR_DEV_RESERVED))) @@ -542,12 +572,66 @@ static u32 _mapping_get_free_dpm_idx(struct mpr_softc *sc) { u16 entry_num; + Mpi2DriverMap0Entry_t *dpm_entry; + u16 current_entry = MPR_DPM_BAD_IDX, missing_cnt, high_missing_cnt = 0; + u64 physical_id; + struct dev_mapping_table *mt_entry; + u32 map_idx; for (entry_num = 0; entry_num < sc->max_dpm_entries; entry_num++) { - if (!sc->dpm_entry_used[entry_num]) - return entry_num; + dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); + dpm_entry += entry_num; + missing_cnt = dpm_entry->MappingInformation & + MPI2_DRVMAP0_MAPINFO_MISSING_MASK; + + /* + * If entry is used and not missing, then this entry can't be + * used. Look at next one. + */ + if (sc->dpm_entry_used[entry_num] && !missing_cnt) + continue; + + /* + * If this entry is not used at all, then the missing count + * doesn't matter. Just use this one. Otherwise, keep looking + * and make sure the entry with the highest missing count is + * used. + */ + if (!sc->dpm_entry_used[entry_num]) { + current_entry = entry_num; + break; + } + if ((current_entry == MPR_DPM_BAD_IDX) || + (missing_cnt > high_missing_cnt)) { + current_entry = entry_num; + high_missing_cnt = missing_cnt; + } } - return MPR_DPM_BAD_IDX; + + /* + * If an entry has been found to use and it's already marked as used + * it means that some device was already using this entry but it's + * missing, and that means that the connection between the missing + * device's DPM entry and the mapping table needs to be cleared. To do + * this, use the Physical ID of the old device still in the DPM entry + * to find its mapping table entry, then mark its DPM entry as BAD. + */ + if ((current_entry != MPR_DPM_BAD_IDX) && + sc->dpm_entry_used[current_entry]) { + dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); + dpm_entry += current_entry; + physical_id = dpm_entry->PhysicalIdentifier.High; + physical_id = (physical_id << 32) | + dpm_entry->PhysicalIdentifier.Low; + map_idx = _mapping_get_mt_idx_from_id(sc, physical_id); + if (map_idx != MPR_MAPTABLE_BAD_IDX) { + mt_entry = &sc->mapping_table[map_idx]; + mt_entry->dpm_entry_num = MPR_DPM_BAD_IDX; + } + } + return current_entry; } /** @@ -566,40 +650,57 @@ _mapping_update_ir_missing_cnt(struct mp Mpi2EventIrConfigElement_t *element, u64 wwid) { struct dev_mapping_table *mt_entry; - u8 missing_cnt, reason = element->ReasonCode; + u8 missing_cnt, reason = element->ReasonCode, update_dpm = 1; u16 dpm_idx; Mpi2DriverMap0Entry_t *dpm_entry; - if (!sc->is_dpm_enable) - return; + /* + * Depending on the reason code, update the missing count. Always set + * the init_complete flag when here, so just do it first. That flag is + * used for volumes to make sure that the DPM entry has been updated. + * When a volume is deleted, clear the map entry's IN_USE flag so that + * the entry can be used again if another volume is created. Also clear + * its dev_handle entry so that other functions can't find this volume + * by the handle, since it's not defined any longer. + */ mt_entry = &sc->mapping_table[map_idx]; - if (reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) { - mt_entry->missing_count = 0; - } else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_CREATED) { + mt_entry->init_complete = 1; + if ((reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) || + (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_CREATED)) { mt_entry->missing_count = 0; - mt_entry->init_complete = 0; - } else if ((reason == MPI2_EVENT_IR_CHANGE_RC_REMOVED) || - (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED)) { - if (!mt_entry->init_complete) { - if (mt_entry->missing_count < MPR_MAX_MISSING_COUNT) - mt_entry->missing_count++; - else - mt_entry->init_complete = 1; - } - if (!mt_entry->missing_count) + } else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) { + if (mt_entry->missing_count < MPR_MAX_MISSING_COUNT) mt_entry->missing_count++; + + mt_entry->device_info &= ~MPR_MAP_IN_USE; mt_entry->dev_handle = 0; } + /* + * If persistent mapping is enabled, update the DPM with the new missing + * count for the volume. If the DPM index is bad, get a free one. If + * it's bad for a volume that's being deleted do nothing because that + * volume doesn't have a DPM entry. + */ + if (!sc->is_dpm_enable) + return; dpm_idx = mt_entry->dpm_entry_num; if (dpm_idx == MPR_DPM_BAD_IDX) { - if ((reason == MPI2_EVENT_IR_CHANGE_RC_ADDED) || - (reason == MPI2_EVENT_IR_CHANGE_RC_REMOVED)) - dpm_idx = _mapping_get_dpm_idx_from_id(sc, - mt_entry->physical_id, 0); - else if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) + if (reason == MPI2_EVENT_IR_CHANGE_RC_VOLUME_DELETED) + { + mpr_dprint(sc, MPR_MAPPING, "%s: Volume being deleted " + "is not in DPM so DPM missing count will not be " + "updated.\n", __func__); return; + } } + if (dpm_idx == MPR_DPM_BAD_IDX) + dpm_idx = _mapping_get_free_dpm_idx(sc); + + /* + * Got the DPM entry for the volume or found a free DPM entry if this is + * a new volume. Check if the current information is outdated. + */ if (dpm_idx != MPR_DPM_BAD_IDX) { dpm_entry = (Mpi2DriverMap0Entry_t *)((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -607,17 +708,24 @@ _mapping_update_ir_missing_cnt(struct mp missing_cnt = dpm_entry->MappingInformation & MPI2_DRVMAP0_MAPINFO_MISSING_MASK; if ((mt_entry->physical_id == - le64toh((u64)dpm_entry->PhysicalIdentifier.High | - dpm_entry->PhysicalIdentifier.Low)) && (missing_cnt == - mt_entry->missing_count)) - mt_entry->init_complete = 1; - } else { - dpm_idx = _mapping_get_free_dpm_idx(sc); - mt_entry->init_complete = 0; + le64toh(((u64)dpm_entry->PhysicalIdentifier.High << 32) | + (u64)dpm_entry->PhysicalIdentifier.Low)) && (missing_cnt == + mt_entry->missing_count)) { + mpr_dprint(sc, MPR_MAPPING, "%s: DPM entry for volume " + "with target ID %d does not require an update.\n", + __func__, mt_entry->id); + update_dpm = 0; + } } - if ((dpm_idx != MPR_DPM_BAD_IDX) && !mt_entry->init_complete) { - mt_entry->init_complete = 1; + /* + * Update the volume's persistent info if it's new or the ID or missing + * count has changed. If a good DPM index has not been found by now, + * there is no space left in the DPM table. + */ + if ((dpm_idx != MPR_DPM_BAD_IDX) && update_dpm) { + mpr_dprint(sc, MPR_MAPPING, "%s: Update DPM entry for volume " + "with target ID %d.\n", __func__, mt_entry->id); mt_entry->dpm_entry_num = dpm_idx; dpm_entry = (Mpi2DriverMap0Entry_t *)((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); @@ -633,44 +741,46 @@ _mapping_update_ir_missing_cnt(struct mp sc->dpm_flush_entry[dpm_idx] = 1; sc->dpm_entry_used[dpm_idx] = 1; } else if (dpm_idx == MPR_DPM_BAD_IDX) { - printf("%s: no space to add entry in DPM table\n", __func__); - mt_entry->init_complete = 1; + mpr_dprint(sc, MPR_INFO | MPR_MAPPING, "%s: No space to add an " + "entry in the DPM table for volume with target ID %d.\n", + __func__, mt_entry->id); } } /** - * _mapping_add_to_removal_table - mark an entry for removal + * _mapping_add_to_removal_table - add DPM index to the removal table * @sc: per adapter object - * @handle: Handle of enclosures/device/volume + * @dpm_idx: Index of DPM entry to remove * - * Adds the handle or DPM entry number in removal table. + * Adds a DPM entry number to the removal table. * * Returns nothing. */ static void -_mapping_add_to_removal_table(struct mpr_softc *sc, u16 handle, - u16 dpm_idx) +_mapping_add_to_removal_table(struct mpr_softc *sc, u16 dpm_idx) { struct map_removal_table *remove_entry; u32 i; - u16 ioc_pg8_flags = le16toh(sc->ioc_pg8.Flags); - remove_entry = sc->removal_table; + /* + * This is only used to remove entries from the DPM in the controller. + * If DPM is not enabled, just return. + */ + if (!sc->is_dpm_enable) + return; + /* + * Find the first available removal_table entry and add the new entry + * there. + */ + remove_entry = sc->removal_table; for (i = 0; i < sc->max_devices; i++, remove_entry++) { - if (remove_entry->dev_handle || remove_entry->dpm_entry_num != - MPR_DPM_BAD_IDX) + if (remove_entry->dpm_entry_num != MPR_DPM_BAD_IDX) continue; - if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == - MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { - if (dpm_idx) - remove_entry->dpm_entry_num = dpm_idx; - if (remove_entry->dpm_entry_num == MPR_DPM_BAD_IDX) - remove_entry->dev_handle = handle; - } else if ((ioc_pg8_flags & - MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == - MPI2_IOCPAGE8_FLAGS_DEVICE_PERSISTENCE_MAPPING) - remove_entry->dev_handle = handle; + + mpr_dprint(sc, MPR_MAPPING, "%s: Adding DPM entry %d to table " + "for removal.\n", __func__, dpm_idx); + remove_entry->dpm_entry_num = dpm_idx; break; } @@ -683,8 +793,11 @@ _mapping_add_to_removal_table(struct mpr * * Increment the missing count in the mapping table for a SAS, SATA, or PCIe * device that is not responding. If Persitent Mapping is used, increment the - * DPM entry as well. Also, add this device to the removal table for possible - * removal if a new device is added. + * DPM entry as well. Currently, this function is only called if the target + * goes missing, so after initialization has completed. This means that the + * missing count can only go from 0 to 1 here. The missing count is incremented + * during initialization as well, so that's where a target's missing count can + * go past 1. * * Returns nothing. */ @@ -696,33 +809,40 @@ _mapping_inc_missing_count(struct mpr_so Mpi2DriverMap0Entry_t *dpm_entry; if (map_idx == MPR_MAPTABLE_BAD_IDX) { - mpr_dprint(sc, MPR_INFO, "%s: device is already removed from " - "mapping table\n", __func__); + mpr_dprint(sc, MPR_INFO | MPR_MAPPING, "%s: device is already " + "removed from mapping table\n", __func__); return; } mt_entry = &sc->mapping_table[map_idx]; - if (!mt_entry->init_complete) { - if (mt_entry->missing_count < MPR_MAX_MISSING_COUNT) - mt_entry->missing_count++; - else - mt_entry->init_complete = 1; - } - if (!mt_entry->missing_count) + if (mt_entry->missing_count < MPR_MAX_MISSING_COUNT) mt_entry->missing_count++; - _mapping_add_to_removal_table(sc, mt_entry->dev_handle, 0); - mt_entry->dev_handle = 0; + /* + * When using Enc/Slot mapping, when a device is removed, it's mapping + * table information should be cleared. Otherwise, the target ID will + * be incorrect if this same device is re-added to a different slot. + */ + if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == + MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { + _mapping_clear_map_entry(mt_entry); + } + + /* + * When using device mapping, update the missing count in the DPM entry, + * but only if the missing count has changed. + */ if (((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_DEVICE_PERSISTENCE_MAPPING) && - sc->is_dpm_enable && !mt_entry->init_complete && + sc->is_dpm_enable && mt_entry->dpm_entry_num != MPR_DPM_BAD_IDX) { dpm_entry = (Mpi2DriverMap0Entry_t *) ((u8 *)sc->dpm_pg0 + sizeof(MPI2_CONFIG_EXTENDED_PAGE_HEADER)); dpm_entry += mt_entry->dpm_entry_num; - dpm_entry->MappingInformation = mt_entry->missing_count; - sc->dpm_flush_entry[mt_entry->dpm_entry_num] = 1; + if (dpm_entry->MappingInformation != mt_entry->missing_count) { + dpm_entry->MappingInformation = mt_entry->missing_count; + sc->dpm_flush_entry[mt_entry->dpm_entry_num] = 1; + } } - mt_entry->init_complete = 1; } /** @@ -814,6 +934,10 @@ _mapping_find_enc_map_space(struct mpr_s vol_mapping_flags = le16toh(sc->ioc_pg8.IRVolumeMappingFlags) & MPI2_IOCPAGE8_IRFLAGS_MASK_VOLUME_MAPPING_MODE; + /* + * The end of the mapping table depends on where volumes are kept, if + * IR is enabled. + */ if (!sc->ir_firmware) end_of_table = sc->max_devices; else if (vol_mapping_flags == MPI2_IOCPAGE8_IRFLAGS_LOW_VOLUME_MAPPING) @@ -821,6 +945,17 @@ _mapping_find_enc_map_space(struct mpr_s else end_of_table = sc->max_devices - sc->max_volumes; + /* + * The skip_count is the number of entries that are reserved at the + * beginning of the mapping table. But, it does not include the number + * of Physical IDs that are reserved for direct attached devices. Look + * through the mapping table after these reserved entries to see if + * the devices for this enclosure are already mapped. The PHY bit check + * is used to make sure that at least one PHY bit is common between the + * enclosure and the device that is already mapped. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Looking for space in the mapping " + "table for added enclosure.\n", __func__); for (map_idx = (max_num_phy_ids + skip_count); map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; @@ -830,11 +965,21 @@ _mapping_find_enc_map_space(struct mpr_s num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; + mpr_dprint(sc, MPR_MAPPING, "%s: Found space " + "in the mapping for enclosure at map index " + "%d.\n", __func__, start_idx); return start_idx; } } else num_found = 0; } + + /* + * If the enclosure's devices are not mapped already, look for + * contiguous entries in the mapping table that are not reserved. If + * enough entries are found, return the starting index for that space. + */ + num_found = 0; for (map_idx = (max_num_phy_ids + skip_count); map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; @@ -842,40 +987,91 @@ _mapping_find_enc_map_space(struct mpr_s num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; + mpr_dprint(sc, MPR_MAPPING, "%s: Found space " + "in the mapping for enclosure at map index " + "%d.\n", __func__, start_idx); return start_idx; } } else num_found = 0; } + /* + * If here, it means that not enough space in the mapping table was + * found to support this enclosure, so go through the enclosure table to + * see if any enclosure entries have a missing count. If so, get the + * enclosure with the highest missing count and check it to see if there + * is enough space for the new enclosure. + */ while (!done_flag) { enc_idx = _mapping_get_high_missing_et_idx(sc); - if (enc_idx == MPR_ENCTABLE_BAD_IDX) + if (enc_idx == MPR_ENCTABLE_BAD_IDX) { + mpr_dprint(sc, MPR_MAPPING, "%s: Not enough space was " + "found in the mapping for the added enclosure.\n", + __func__); return MPR_MAPTABLE_BAD_IDX; + } + + /* + * Found a missing enclosure. Set the skip_search flag so this + * enclosure is not checked again for a high missing count if + * the loop continues. This way, all missing enclosures can + * have their space added together to find enough space in the + * mapping table for the added enclosure. The space must be + * contiguous. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Space from a missing " + "enclosure was found.\n", __func__); enc_entry = &sc->enclosure_table[enc_idx]; - /*VSP FIXME*/ enc_entry->skip_search = 1; + + /* + * Unmark all of the missing enclosure's device's reserved + * space. These will be remarked as reserved if this missing + * enclosure's space is not used. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Clear the reserved flag for " + "all of the map entries for the enclosure.\n", __func__); mt_entry = &sc->mapping_table[enc_entry->start_index]; for (map_idx = enc_entry->start_index; map_idx < (enc_entry->start_index + enc_entry->num_slots); map_idx++, mt_entry++) - mt_entry->device_info &= ~MPR_DEV_RESERVED; + mt_entry->device_info &= ~MPR_DEV_RESERVED; + + /* + * Now that space has been unreserved, check again to see if + * enough space is available for the new enclosure. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Check if new mapping space is " + "enough for the new enclosure.\n", __func__); found_space = 0; - for (map_idx = (max_num_phy_ids + - skip_count); map_idx < end_of_table; map_idx++) { + num_found = 0; + for (map_idx = (max_num_phy_ids + skip_count); + map_idx < end_of_table; map_idx++) { mt_entry = &sc->mapping_table[map_idx]; if (!(mt_entry->device_info & MPR_DEV_RESERVED)) { num_found += 1; if (num_found == et_entry->num_slots) { start_idx = (map_idx - num_found) + 1; found_space = 1; + break; } } else num_found = 0; } - if (!found_space) continue; + + /* + * If enough space was found, all of the missing enclosures that + * will be used for the new enclosure must be added to the + * removal table. Then all mappings for the enclosure's devices + * and for the enclosure itself need to be cleared. There may be + * more than one enclosure to add to the removal table and + * clear. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Found space in the mapping " + "for enclosure at map index %d.\n", __func__, start_idx); for (map_idx = start_idx; map_idx < (start_idx + num_found); map_idx++) { enc_entry = sc->enclosure_table; @@ -886,26 +1082,38 @@ _mapping_find_enc_map_space(struct mpr_s enc_entry->num_slots)) continue; if (!enc_entry->removal_flag) { + mpr_dprint(sc, MPR_MAPPING, "%s: " + "Enclosure %d will be removed from " + "the mapping table.\n", __func__, + enc_idx); enc_entry->removal_flag = 1; - _mapping_add_to_removal_table(sc, 0, + _mapping_add_to_removal_table(sc, enc_entry->dpm_entry_num); } mt_entry = &sc->mapping_table[map_idx]; - if (mt_entry->device_info & - MPR_MAP_IN_USE) { - _mapping_add_to_removal_table(sc, - mt_entry->dev_handle, 0); - _mapping_clear_map_entry(mt_entry); - } + _mapping_clear_map_entry(mt_entry); if (map_idx == (enc_entry->start_index + enc_entry->num_slots - 1)) _mapping_clear_enc_entry(et_entry); } } + + /* + * During the search for space for this enclosure, some entries + * in the mapping table may have been unreserved. Go back and + * change all of these to reserved again. Only the enclosures + * with the removal_flag set should be left as unreserved. The + * skip_search flag needs to be cleared as well so that the + * enclosure's space will be looked at the next time space is + * needed. + */ enc_entry = sc->enclosure_table; for (enc_idx = 0; enc_idx < sc->num_enc_table_entries; enc_idx++, enc_entry++) { if (!enc_entry->removal_flag) { + mpr_dprint(sc, MPR_MAPPING, "%s: Reset the " + "reserved flag for all of the map entries " + "for enclosure %d.\n", __func__, enc_idx); mt_entry = &sc->mapping_table[enc_entry-> start_index]; for (map_idx = enc_entry->start_index; map_idx < @@ -939,7 +1147,7 @@ _mapping_get_dev_info(struct mpr_softc * u16 ioc_pg8_flags = le16toh(sc->ioc_pg8.Flags); Mpi2ConfigReply_t mpi_reply; Mpi2SasDevicePage0_t sas_device_pg0; - u8 entry, enc_idx, phy_idx, sata_end_device; + u8 entry, enc_idx, phy_idx; u32 map_idx, index, device_info; struct _map_phy_change *phy_change, *tmp_phy_change; uint64_t sas_address; @@ -953,6 +1161,7 @@ _mapping_get_dev_info(struct mpr_softc * if (phy_change->is_processed || !phy_change->dev_handle || phy_change->reason != MPI2_EVENT_SAS_TOPO_RC_TARG_ADDED) continue; + if (mpr_config_get_sas_device_pg0(sc, &mpi_reply, &sas_device_pg0, MPI2_SAS_DEVICE_PGAD_FORM_HANDLE, phy_change->dev_handle)) { @@ -966,13 +1175,11 @@ _mapping_get_dev_info(struct mpr_softc * * when the system is shutdown. */ device_info = le32toh(sas_device_pg0.DeviceInfo); - sas_address = sas_device_pg0.SASAddress.High; + sas_address = le32toh(sas_device_pg0.SASAddress.High); sas_address = (sas_address << 32) | - sas_device_pg0.SASAddress.Low; - sata_end_device = 0; + le32toh(sas_device_pg0.SASAddress.Low); if ((device_info & MPI2_SAS_DEVICE_INFO_END_DEVICE) && (device_info & MPI2_SAS_DEVICE_INFO_SATA_DEVICE)) { - sata_end_device = 1; rc = mprsas_get_sas_address_for_sata_disk(sc, &sas_address, phy_change->dev_handle, device_info, &phy_change->is_SATA_SSD); @@ -991,16 +1198,27 @@ _mapping_get_dev_info(struct mpr_softc * phy_change->slot = le16toh(sas_device_pg0.Slot); phy_change->device_info = device_info; + /* + * When using Enc/Slot mapping, if this device is an enclosure + * make sure that all of its slots can fit into the mapping + * table. + */ if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { + /* + * The enclosure should already be in the enclosure + * table due to the Enclosure Add event. If not, just + * continue, nothing can be done. + */ enc_idx = _mapping_get_enc_idx_from_handle(sc, topo_change->enc_handle); if (enc_idx == MPR_ENCTABLE_BAD_IDX) { phy_change->is_processed = 1; - mpr_dprint(sc, MPR_MAPPING, "%s: failed to add " - "the device with handle 0x%04x because the " - "enclosure is not in the mapping table\n", - __func__, phy_change->dev_handle); + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because the enclosure is not in " + "the mapping table\n", __func__, + phy_change->dev_handle); continue; } if (!((phy_change->device_info & @@ -1013,8 +1231,20 @@ _mapping_get_dev_info(struct mpr_softc * continue; } et_entry = &sc->enclosure_table[enc_idx]; + + /* + * If the enclosure already has a start_index, it's been + * mapped, so go to the next Topo change. + */ if (et_entry->start_index != MPR_MAPTABLE_BAD_IDX) continue; + + /* + * If the Expander Handle is 0, the devices are direct + * attached. In that case, the start_index must be just + * after the reserved entries. Otherwise, find space in + * the mapping table for the enclosure's devices. + */ if (!topo_change->exp_handle) { map_idx = sc->num_rsvd_entries; et_entry->start_index = map_idx; @@ -1022,8 +1252,26 @@ _mapping_get_dev_info(struct mpr_softc * map_idx = _mapping_find_enc_map_space(sc, et_entry); et_entry->start_index = map_idx; + + /* + * If space cannot be found to hold all of the + * enclosure's devices in the mapping table, + * there's no need to continue checking the + * other devices in this event. Set all of the + * phy_details for this event (if the change is + * for an add) as already processed because none + * of these devices can be added to the mapping + * table. + */ if (et_entry->start_index == MPR_MAPTABLE_BAD_IDX) { + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, + "%s: failed to add the enclosure " + "with ID 0x%016jx because there is " + "no free space available in the " + "mapping table for all of the " + "enclosure's devices.\n", __func__, + (uintmax_t)et_entry->enclosure_id); phy_change->is_processed = 1; for (phy_idx = 0; phy_idx < topo_change->num_entries; @@ -1040,7 +1288,14 @@ _mapping_get_dev_info(struct mpr_softc * } } - /* Found space in enclosure for mapping entry */ + /* + * Found space in the mapping table for this enclosure. + * Initialize each mapping table entry for the + * enclosure. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Initialize %d map " + "entries for the enclosure, starting at map index " + " %d.\n", __func__, et_entry->num_slots, map_idx); mt_entry = &sc->mapping_table[map_idx]; for (index = map_idx; index < (et_entry->num_slots + map_idx); index++, mt_entry++) { @@ -1098,16 +1353,27 @@ _mapping_get_pcie_dev_info(struct mpr_so port_change->slot = le16toh(pcie_device_pg0.Slot); port_change->device_info = le32toh(pcie_device_pg0.DeviceInfo); + /* + * When using Enc/Slot mapping, if this device is an enclosure + * make sure that all of its slots can fit into the mapping + * table. + */ if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { + /* + * The enclosure should already be in the enclosure + * table due to the Enclosure Add event. If not, just + * continue, nothing can be done. + */ enc_idx = _mapping_get_enc_idx_from_handle(sc, topo_change->enc_handle); if (enc_idx == MPR_ENCTABLE_BAD_IDX) { port_change->is_processed = 1; - mpr_dprint(sc, MPR_MAPPING, "%s: failed to add " - "the device with handle 0x%04x because the " - "enclosure is not in the mapping table\n", - __func__, port_change->dev_handle); + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because the enclosure is not in " + "the mapping table\n", __func__, + port_change->dev_handle); continue; } if (!(port_change->device_info & @@ -1116,8 +1382,20 @@ _mapping_get_pcie_dev_info(struct mpr_so continue; } et_entry = &sc->enclosure_table[enc_idx]; + + /* + * If the enclosure already has a start_index, it's been + * mapped, so go to the next Topo change. + */ if (et_entry->start_index != MPR_MAPTABLE_BAD_IDX) continue; + + /* + * If the Switch Handle is 0, the devices are direct + * attached. In that case, the start_index must be just + * after the reserved entries. Otherwise, find space in + * the mapping table for the enclosure's devices. + */ if (!topo_change->switch_dev_handle) { map_idx = sc->num_rsvd_entries; et_entry->start_index = map_idx; @@ -1125,8 +1403,26 @@ _mapping_get_pcie_dev_info(struct mpr_so map_idx = _mapping_find_enc_map_space(sc, et_entry); et_entry->start_index = map_idx; + + /* + * If space cannot be found to hold all of the + * enclosure's devices in the mapping table, + * there's no need to continue checking the + * other devices in this event. Set all of the + * port_details for this event (if the change is + * for an add) as already processed because none + * of these devices can be added to the mapping + * table. + */ if (et_entry->start_index == MPR_MAPTABLE_BAD_IDX) { + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, + "%s: failed to add the enclosure " + "with ID 0x%016jx because there is " + "no free space available in the " + "mapping table for all of the " + "enclosure's devices.\n", __func__, + (uintmax_t)et_entry->enclosure_id); port_change->is_processed = 1; for (port_idx = 0; port_idx < topo_change->num_entries; @@ -1143,7 +1439,14 @@ _mapping_get_pcie_dev_info(struct mpr_so } } - /* Found space in enclosure for mapping entry */ + /* + * Found space in the mapping table for this enclosure. + * Initialize each mapping table entry for the + * enclosure. + */ + mpr_dprint(sc, MPR_MAPPING, "%s: Initialize %d map " + "entries for the enclosure, starting at map index " + " %d.\n", __func__, et_entry->num_slots, map_idx); mt_entry = &sc->mapping_table[map_idx]; for (index = map_idx; index < (et_entry->num_slots + map_idx); index++, mt_entry++) { @@ -1170,6 +1473,7 @@ _mapping_set_mid_to_eid(struct mpr_softc struct dev_mapping_table *mt_entry; u16 slots = et_entry->num_slots, map_idx; u32 start_idx = et_entry->start_index; + if (start_idx != MPR_MAPTABLE_BAD_IDX) { mt_entry = &sc->mapping_table[start_idx]; for (map_idx = 0; map_idx < slots; map_idx++, mt_entry++) @@ -1219,6 +1523,13 @@ _mapping_clear_removed_entries(struct mp } } } + + /* + * When using Enc/Slot mapping, if a new enclosure was added and old + * enclosure space was needed, the enclosure table may now have gaps + * that need to be closed. All enclosure mappings need to be contiguous + * so that space can be reused correctly if available. + */ if ((ioc_pg8_flags & MPI2_IOCPAGE8_FLAGS_MASK_MAPPING_MODE) == MPI2_IOCPAGE8_FLAGS_ENCLOSURE_SLOT_MAPPING) { num_entries = sc->num_enc_table_entries; @@ -1299,31 +1610,41 @@ _mapping_add_new_device(struct mpr_softc (sc, topo_change->enc_handle); if (enc_idx == MPR_ENCTABLE_BAD_IDX) { phy_change->is_processed = 1; - mpr_dprint(sc, MPR_ERROR, "%s: failed to add " - "the device with handle 0x%04x because the " - "enclosure is not in the mapping table\n", - __func__, phy_change->dev_handle); + mpr_dprint(sc, MPR_ERROR | MPR_MAPPING, "%s: " + "failed to add the device with handle " + "0x%04x because the enclosure is not in " + "the mapping table\n", __func__, + phy_change->dev_handle); continue; } + + /* + * If the enclosure's start_index is BAD here, it means + * that there is no room in the mapping table to cover + * all of the devices that could be in the enclosure. + * There's no reason to process any of the devices for + * this enclosure since they can't be mapped. + */ et_entry = &sc->enclosure_table[enc_idx]; if (et_entry->start_index == MPR_MAPTABLE_BAD_IDX) { phy_change->is_processed = 1; - if (!sc->mt_full_retry) { - sc->mt_add_device_failed = 1; - continue; - } *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Thu May 25 20:52:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7F5C6D82264; Thu, 25 May 2017 20:52:22 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2549B1953; Thu, 25 May 2017 20:52:22 +0000 (UTC) (envelope-from jkim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PKqLDr016300; Thu, 25 May 2017 20:52:21 GMT (envelope-from jkim@FreeBSD.org) Received: (from jkim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PKqG5W016258; Thu, 25 May 2017 20:52:16 GMT (envelope-from jkim@FreeBSD.org) Message-Id: <201705252052.v4PKqG5W016258@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jkim set sender to jkim@FreeBSD.org using -f From: Jung-uk Kim Date: Thu, 25 May 2017 20:52:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318899 - in head: crypto/openssl crypto/openssl/apps crypto/openssl/crypto crypto/openssl/crypto/aes crypto/openssl/crypto/aes/asm crypto/openssl/crypto/asn1 crypto/openssl/crypto/bio ... 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.23 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, 25 May 2017 20:52:22 -0000 Author: jkim Date: Thu May 25 20:52:16 2017 New Revision: 318899 URL: https://svnweb.freebsd.org/changeset/base/318899 Log: Merge OpenSSL 1.0.2l. Added: head/crypto/openssl/doc/man3/ - copied from r318897, vendor-crypto/openssl/dist/doc/man3/ head/secure/lib/libssl/man/SSL_CTX_set_tlsext_servername_callback.3 (contents, props changed) Modified: head/crypto/openssl/CHANGES head/crypto/openssl/Configure head/crypto/openssl/LICENSE head/crypto/openssl/Makefile head/crypto/openssl/Makefile.org head/crypto/openssl/NEWS head/crypto/openssl/README head/crypto/openssl/apps/ca.c head/crypto/openssl/apps/dhparam.c head/crypto/openssl/apps/enc.c head/crypto/openssl/apps/engine.c head/crypto/openssl/apps/pkeyutl.c head/crypto/openssl/apps/prime.c head/crypto/openssl/apps/progs.h head/crypto/openssl/apps/progs.pl head/crypto/openssl/apps/req.c head/crypto/openssl/apps/s_client.c head/crypto/openssl/apps/s_server.c head/crypto/openssl/apps/srp.c head/crypto/openssl/appveyor.yml head/crypto/openssl/config head/crypto/openssl/crypto/aes/Makefile head/crypto/openssl/crypto/aes/asm/aesni-sha1-x86_64.pl head/crypto/openssl/crypto/aes/asm/aesni-sha256-x86_64.pl head/crypto/openssl/crypto/aes/asm/bsaes-armv7.pl head/crypto/openssl/crypto/asn1/a_bitstr.c head/crypto/openssl/crypto/asn1/a_digest.c head/crypto/openssl/crypto/asn1/a_gentm.c head/crypto/openssl/crypto/asn1/a_strnid.c head/crypto/openssl/crypto/asn1/a_time.c head/crypto/openssl/crypto/asn1/a_utctm.c head/crypto/openssl/crypto/asn1/f_enum.c head/crypto/openssl/crypto/asn1/f_int.c head/crypto/openssl/crypto/asn1/tasn_dec.c head/crypto/openssl/crypto/asn1/tasn_new.c head/crypto/openssl/crypto/asn1/x_long.c head/crypto/openssl/crypto/asn1/x_name.c head/crypto/openssl/crypto/bio/b_print.c head/crypto/openssl/crypto/bio/bio_cb.c head/crypto/openssl/crypto/bio/bss_file.c head/crypto/openssl/crypto/bn/Makefile head/crypto/openssl/crypto/bn/asm/sparcv9-mont.pl head/crypto/openssl/crypto/bn/bn_prime.c head/crypto/openssl/crypto/bn/bn_prime.h head/crypto/openssl/crypto/bn/bn_prime.pl head/crypto/openssl/crypto/bn/bn_print.c head/crypto/openssl/crypto/comp/c_rle.c head/crypto/openssl/crypto/conf/conf.h head/crypto/openssl/crypto/conf/conf_def.c head/crypto/openssl/crypto/conf/conf_err.c head/crypto/openssl/crypto/des/Makefile head/crypto/openssl/crypto/des/set_key.c head/crypto/openssl/crypto/dh/dh.h head/crypto/openssl/crypto/ec/ec_ameth.c head/crypto/openssl/crypto/ec/ec_asn1.c head/crypto/openssl/crypto/ec/ec_mult.c head/crypto/openssl/crypto/ec/eck_prn.c head/crypto/openssl/crypto/engine/eng_cryptodev.c head/crypto/openssl/crypto/err/err.c head/crypto/openssl/crypto/err/err.h head/crypto/openssl/crypto/evp/e_aes.c head/crypto/openssl/crypto/evp/e_aes_cbc_hmac_sha1.c head/crypto/openssl/crypto/evp/e_aes_cbc_hmac_sha256.c head/crypto/openssl/crypto/evp/e_des3.c head/crypto/openssl/crypto/evp/evp_enc.c head/crypto/openssl/crypto/evp/pmeth_lib.c head/crypto/openssl/crypto/ex_data.c head/crypto/openssl/crypto/hmac/hm_pmeth.c head/crypto/openssl/crypto/md5/Makefile head/crypto/openssl/crypto/mem.c head/crypto/openssl/crypto/modes/Makefile head/crypto/openssl/crypto/o_dir.c head/crypto/openssl/crypto/o_time.c head/crypto/openssl/crypto/opensslv.h head/crypto/openssl/crypto/perlasm/x86_64-xlate.pl head/crypto/openssl/crypto/pkcs12/p12_mutl.c head/crypto/openssl/crypto/ppccap.c head/crypto/openssl/crypto/rand/md_rand.c head/crypto/openssl/crypto/rc4/Makefile head/crypto/openssl/crypto/rsa/rsa_pmeth.c head/crypto/openssl/crypto/rsa/rsa_pss.c head/crypto/openssl/crypto/sha/Makefile head/crypto/openssl/crypto/srp/srp_vfy.c head/crypto/openssl/crypto/txt_db/txt_db.c head/crypto/openssl/crypto/ui/ui_lib.c head/crypto/openssl/crypto/x509/x509_lu.c head/crypto/openssl/crypto/x509v3/v3_alt.c head/crypto/openssl/crypto/x509v3/v3_cpols.c head/crypto/openssl/crypto/x509v3/v3_info.c head/crypto/openssl/crypto/x509v3/v3_purp.c head/crypto/openssl/crypto/x86_64cpuid.pl head/crypto/openssl/crypto/x86cpuid.pl head/crypto/openssl/doc/apps/ciphers.pod head/crypto/openssl/doc/apps/config.pod head/crypto/openssl/doc/apps/genrsa.pod head/crypto/openssl/doc/apps/req.pod head/crypto/openssl/doc/apps/s_client.pod head/crypto/openssl/doc/apps/s_server.pod head/crypto/openssl/doc/crypto/EVP_EncryptInit.pod head/crypto/openssl/doc/crypto/RSA_private_encrypt.pod head/crypto/openssl/doc/crypto/RSA_public_encrypt.pod head/crypto/openssl/doc/crypto/X509_STORE_CTX_new.pod head/crypto/openssl/doc/crypto/des.pod head/crypto/openssl/ssl/d1_both.c head/crypto/openssl/ssl/d1_clnt.c head/crypto/openssl/ssl/d1_pkt.c head/crypto/openssl/ssl/d1_srvr.c head/crypto/openssl/ssl/s23_clnt.c head/crypto/openssl/ssl/s23_srvr.c head/crypto/openssl/ssl/s3_clnt.c head/crypto/openssl/ssl/s3_enc.c head/crypto/openssl/ssl/s3_lib.c head/crypto/openssl/ssl/s3_pkt.c head/crypto/openssl/ssl/s3_srvr.c head/crypto/openssl/ssl/ssl_cert.c head/crypto/openssl/ssl/ssl_ciph.c head/crypto/openssl/ssl/ssl_lib.c head/crypto/openssl/ssl/ssl_locl.h head/crypto/openssl/ssl/ssl_rsa.c head/crypto/openssl/ssl/ssl_sess.c head/crypto/openssl/ssl/ssltest.c head/crypto/openssl/ssl/t1_ext.c head/crypto/openssl/ssl/t1_lib.c head/crypto/openssl/util/domd head/crypto/openssl/util/mk1mf.pl head/secure/lib/libcrypto/Makefile.inc head/secure/lib/libcrypto/Makefile.man head/secure/lib/libcrypto/amd64/aesni-sha1-x86_64.S head/secure/lib/libcrypto/amd64/aesni-sha256-x86_64.S head/secure/lib/libcrypto/amd64/x86_64cpuid.S head/secure/lib/libcrypto/arm/bsaes-armv7.S head/secure/lib/libcrypto/i386/x86cpuid.S head/secure/lib/libcrypto/man/ASN1_OBJECT_new.3 head/secure/lib/libcrypto/man/ASN1_STRING_length.3 head/secure/lib/libcrypto/man/ASN1_STRING_new.3 head/secure/lib/libcrypto/man/ASN1_STRING_print_ex.3 head/secure/lib/libcrypto/man/ASN1_TIME_set.3 head/secure/lib/libcrypto/man/ASN1_generate_nconf.3 head/secure/lib/libcrypto/man/BIO_ctrl.3 head/secure/lib/libcrypto/man/BIO_f_base64.3 head/secure/lib/libcrypto/man/BIO_f_buffer.3 head/secure/lib/libcrypto/man/BIO_f_cipher.3 head/secure/lib/libcrypto/man/BIO_f_md.3 head/secure/lib/libcrypto/man/BIO_f_null.3 head/secure/lib/libcrypto/man/BIO_f_ssl.3 head/secure/lib/libcrypto/man/BIO_find_type.3 head/secure/lib/libcrypto/man/BIO_new.3 head/secure/lib/libcrypto/man/BIO_new_CMS.3 head/secure/lib/libcrypto/man/BIO_push.3 head/secure/lib/libcrypto/man/BIO_read.3 head/secure/lib/libcrypto/man/BIO_s_accept.3 head/secure/lib/libcrypto/man/BIO_s_bio.3 head/secure/lib/libcrypto/man/BIO_s_connect.3 head/secure/lib/libcrypto/man/BIO_s_fd.3 head/secure/lib/libcrypto/man/BIO_s_file.3 head/secure/lib/libcrypto/man/BIO_s_mem.3 head/secure/lib/libcrypto/man/BIO_s_null.3 head/secure/lib/libcrypto/man/BIO_s_socket.3 head/secure/lib/libcrypto/man/BIO_set_callback.3 head/secure/lib/libcrypto/man/BIO_should_retry.3 head/secure/lib/libcrypto/man/BN_BLINDING_new.3 head/secure/lib/libcrypto/man/BN_CTX_new.3 head/secure/lib/libcrypto/man/BN_CTX_start.3 head/secure/lib/libcrypto/man/BN_add.3 head/secure/lib/libcrypto/man/BN_add_word.3 head/secure/lib/libcrypto/man/BN_bn2bin.3 head/secure/lib/libcrypto/man/BN_cmp.3 head/secure/lib/libcrypto/man/BN_copy.3 head/secure/lib/libcrypto/man/BN_generate_prime.3 head/secure/lib/libcrypto/man/BN_mod_inverse.3 head/secure/lib/libcrypto/man/BN_mod_mul_montgomery.3 head/secure/lib/libcrypto/man/BN_mod_mul_reciprocal.3 head/secure/lib/libcrypto/man/BN_new.3 head/secure/lib/libcrypto/man/BN_num_bytes.3 head/secure/lib/libcrypto/man/BN_rand.3 head/secure/lib/libcrypto/man/BN_set_bit.3 head/secure/lib/libcrypto/man/BN_swap.3 head/secure/lib/libcrypto/man/BN_zero.3 head/secure/lib/libcrypto/man/CMS_add0_cert.3 head/secure/lib/libcrypto/man/CMS_add1_recipient_cert.3 head/secure/lib/libcrypto/man/CMS_add1_signer.3 head/secure/lib/libcrypto/man/CMS_compress.3 head/secure/lib/libcrypto/man/CMS_decrypt.3 head/secure/lib/libcrypto/man/CMS_encrypt.3 head/secure/lib/libcrypto/man/CMS_final.3 head/secure/lib/libcrypto/man/CMS_get0_RecipientInfos.3 head/secure/lib/libcrypto/man/CMS_get0_SignerInfos.3 head/secure/lib/libcrypto/man/CMS_get0_type.3 head/secure/lib/libcrypto/man/CMS_get1_ReceiptRequest.3 head/secure/lib/libcrypto/man/CMS_sign.3 head/secure/lib/libcrypto/man/CMS_sign_receipt.3 head/secure/lib/libcrypto/man/CMS_uncompress.3 head/secure/lib/libcrypto/man/CMS_verify.3 head/secure/lib/libcrypto/man/CMS_verify_receipt.3 head/secure/lib/libcrypto/man/CONF_modules_free.3 head/secure/lib/libcrypto/man/CONF_modules_load_file.3 head/secure/lib/libcrypto/man/CRYPTO_set_ex_data.3 head/secure/lib/libcrypto/man/DH_generate_key.3 head/secure/lib/libcrypto/man/DH_generate_parameters.3 head/secure/lib/libcrypto/man/DH_get_ex_new_index.3 head/secure/lib/libcrypto/man/DH_new.3 head/secure/lib/libcrypto/man/DH_set_method.3 head/secure/lib/libcrypto/man/DH_size.3 head/secure/lib/libcrypto/man/DSA_SIG_new.3 head/secure/lib/libcrypto/man/DSA_do_sign.3 head/secure/lib/libcrypto/man/DSA_dup_DH.3 head/secure/lib/libcrypto/man/DSA_generate_key.3 head/secure/lib/libcrypto/man/DSA_generate_parameters.3 head/secure/lib/libcrypto/man/DSA_get_ex_new_index.3 head/secure/lib/libcrypto/man/DSA_new.3 head/secure/lib/libcrypto/man/DSA_set_method.3 head/secure/lib/libcrypto/man/DSA_sign.3 head/secure/lib/libcrypto/man/DSA_size.3 head/secure/lib/libcrypto/man/EC_GFp_simple_method.3 head/secure/lib/libcrypto/man/EC_GROUP_copy.3 head/secure/lib/libcrypto/man/EC_GROUP_new.3 head/secure/lib/libcrypto/man/EC_KEY_new.3 head/secure/lib/libcrypto/man/EC_POINT_add.3 head/secure/lib/libcrypto/man/EC_POINT_new.3 head/secure/lib/libcrypto/man/ERR_GET_LIB.3 head/secure/lib/libcrypto/man/ERR_clear_error.3 head/secure/lib/libcrypto/man/ERR_error_string.3 head/secure/lib/libcrypto/man/ERR_get_error.3 head/secure/lib/libcrypto/man/ERR_load_crypto_strings.3 head/secure/lib/libcrypto/man/ERR_load_strings.3 head/secure/lib/libcrypto/man/ERR_print_errors.3 head/secure/lib/libcrypto/man/ERR_put_error.3 head/secure/lib/libcrypto/man/ERR_remove_state.3 head/secure/lib/libcrypto/man/ERR_set_mark.3 head/secure/lib/libcrypto/man/EVP_BytesToKey.3 head/secure/lib/libcrypto/man/EVP_DigestInit.3 head/secure/lib/libcrypto/man/EVP_DigestSignInit.3 head/secure/lib/libcrypto/man/EVP_DigestVerifyInit.3 head/secure/lib/libcrypto/man/EVP_EncodeInit.3 head/secure/lib/libcrypto/man/EVP_EncryptInit.3 head/secure/lib/libcrypto/man/EVP_OpenInit.3 head/secure/lib/libcrypto/man/EVP_PKEY_CTX_ctrl.3 head/secure/lib/libcrypto/man/EVP_PKEY_CTX_new.3 head/secure/lib/libcrypto/man/EVP_PKEY_cmp.3 head/secure/lib/libcrypto/man/EVP_PKEY_decrypt.3 head/secure/lib/libcrypto/man/EVP_PKEY_derive.3 head/secure/lib/libcrypto/man/EVP_PKEY_encrypt.3 head/secure/lib/libcrypto/man/EVP_PKEY_get_default_digest.3 head/secure/lib/libcrypto/man/EVP_PKEY_keygen.3 head/secure/lib/libcrypto/man/EVP_PKEY_new.3 head/secure/lib/libcrypto/man/EVP_PKEY_print_private.3 head/secure/lib/libcrypto/man/EVP_PKEY_set1_RSA.3 head/secure/lib/libcrypto/man/EVP_PKEY_sign.3 head/secure/lib/libcrypto/man/EVP_PKEY_verify.3 head/secure/lib/libcrypto/man/EVP_PKEY_verify_recover.3 head/secure/lib/libcrypto/man/EVP_SealInit.3 head/secure/lib/libcrypto/man/EVP_SignInit.3 head/secure/lib/libcrypto/man/EVP_VerifyInit.3 head/secure/lib/libcrypto/man/OBJ_nid2obj.3 head/secure/lib/libcrypto/man/OPENSSL_Applink.3 head/secure/lib/libcrypto/man/OPENSSL_VERSION_NUMBER.3 head/secure/lib/libcrypto/man/OPENSSL_config.3 head/secure/lib/libcrypto/man/OPENSSL_ia32cap.3 head/secure/lib/libcrypto/man/OPENSSL_instrument_bus.3 head/secure/lib/libcrypto/man/OPENSSL_load_builtin_modules.3 head/secure/lib/libcrypto/man/OpenSSL_add_all_algorithms.3 head/secure/lib/libcrypto/man/PEM_write_bio_CMS_stream.3 head/secure/lib/libcrypto/man/PEM_write_bio_PKCS7_stream.3 head/secure/lib/libcrypto/man/PKCS12_create.3 head/secure/lib/libcrypto/man/PKCS12_parse.3 head/secure/lib/libcrypto/man/PKCS7_decrypt.3 head/secure/lib/libcrypto/man/PKCS7_encrypt.3 head/secure/lib/libcrypto/man/PKCS7_sign.3 head/secure/lib/libcrypto/man/PKCS7_sign_add_signer.3 head/secure/lib/libcrypto/man/PKCS7_verify.3 head/secure/lib/libcrypto/man/RAND_add.3 head/secure/lib/libcrypto/man/RAND_bytes.3 head/secure/lib/libcrypto/man/RAND_cleanup.3 head/secure/lib/libcrypto/man/RAND_egd.3 head/secure/lib/libcrypto/man/RAND_load_file.3 head/secure/lib/libcrypto/man/RAND_set_rand_method.3 head/secure/lib/libcrypto/man/RSA_blinding_on.3 head/secure/lib/libcrypto/man/RSA_check_key.3 head/secure/lib/libcrypto/man/RSA_generate_key.3 head/secure/lib/libcrypto/man/RSA_get_ex_new_index.3 head/secure/lib/libcrypto/man/RSA_new.3 head/secure/lib/libcrypto/man/RSA_padding_add_PKCS1_type_1.3 head/secure/lib/libcrypto/man/RSA_print.3 head/secure/lib/libcrypto/man/RSA_private_encrypt.3 head/secure/lib/libcrypto/man/RSA_public_encrypt.3 head/secure/lib/libcrypto/man/RSA_set_method.3 head/secure/lib/libcrypto/man/RSA_sign.3 head/secure/lib/libcrypto/man/RSA_sign_ASN1_OCTET_STRING.3 head/secure/lib/libcrypto/man/RSA_size.3 head/secure/lib/libcrypto/man/SMIME_read_CMS.3 head/secure/lib/libcrypto/man/SMIME_read_PKCS7.3 head/secure/lib/libcrypto/man/SMIME_write_CMS.3 head/secure/lib/libcrypto/man/SMIME_write_PKCS7.3 head/secure/lib/libcrypto/man/X509_NAME_ENTRY_get_object.3 head/secure/lib/libcrypto/man/X509_NAME_add_entry_by_txt.3 head/secure/lib/libcrypto/man/X509_NAME_get_index_by_NID.3 head/secure/lib/libcrypto/man/X509_NAME_print_ex.3 head/secure/lib/libcrypto/man/X509_STORE_CTX_get_error.3 head/secure/lib/libcrypto/man/X509_STORE_CTX_get_ex_new_index.3 head/secure/lib/libcrypto/man/X509_STORE_CTX_new.3 head/secure/lib/libcrypto/man/X509_STORE_CTX_set_verify_cb.3 head/secure/lib/libcrypto/man/X509_STORE_set_verify_cb_func.3 head/secure/lib/libcrypto/man/X509_VERIFY_PARAM_set_flags.3 head/secure/lib/libcrypto/man/X509_check_host.3 head/secure/lib/libcrypto/man/X509_new.3 head/secure/lib/libcrypto/man/X509_verify_cert.3 head/secure/lib/libcrypto/man/bio.3 head/secure/lib/libcrypto/man/blowfish.3 head/secure/lib/libcrypto/man/bn.3 head/secure/lib/libcrypto/man/bn_internal.3 head/secure/lib/libcrypto/man/buffer.3 head/secure/lib/libcrypto/man/crypto.3 head/secure/lib/libcrypto/man/d2i_ASN1_OBJECT.3 head/secure/lib/libcrypto/man/d2i_CMS_ContentInfo.3 head/secure/lib/libcrypto/man/d2i_DHparams.3 head/secure/lib/libcrypto/man/d2i_DSAPublicKey.3 head/secure/lib/libcrypto/man/d2i_ECPKParameters.3 head/secure/lib/libcrypto/man/d2i_ECPrivateKey.3 head/secure/lib/libcrypto/man/d2i_PKCS8PrivateKey.3 head/secure/lib/libcrypto/man/d2i_PrivateKey.3 head/secure/lib/libcrypto/man/d2i_RSAPublicKey.3 head/secure/lib/libcrypto/man/d2i_X509.3 head/secure/lib/libcrypto/man/d2i_X509_ALGOR.3 head/secure/lib/libcrypto/man/d2i_X509_CRL.3 head/secure/lib/libcrypto/man/d2i_X509_NAME.3 head/secure/lib/libcrypto/man/d2i_X509_REQ.3 head/secure/lib/libcrypto/man/d2i_X509_SIG.3 head/secure/lib/libcrypto/man/des.3 head/secure/lib/libcrypto/man/dh.3 head/secure/lib/libcrypto/man/dsa.3 head/secure/lib/libcrypto/man/ec.3 head/secure/lib/libcrypto/man/ecdsa.3 head/secure/lib/libcrypto/man/engine.3 head/secure/lib/libcrypto/man/err.3 head/secure/lib/libcrypto/man/evp.3 head/secure/lib/libcrypto/man/hmac.3 head/secure/lib/libcrypto/man/i2d_CMS_bio_stream.3 head/secure/lib/libcrypto/man/i2d_PKCS7_bio_stream.3 head/secure/lib/libcrypto/man/lh_stats.3 head/secure/lib/libcrypto/man/lhash.3 head/secure/lib/libcrypto/man/md5.3 head/secure/lib/libcrypto/man/mdc2.3 head/secure/lib/libcrypto/man/pem.3 head/secure/lib/libcrypto/man/rand.3 head/secure/lib/libcrypto/man/rc4.3 head/secure/lib/libcrypto/man/ripemd.3 head/secure/lib/libcrypto/man/rsa.3 head/secure/lib/libcrypto/man/sha.3 head/secure/lib/libcrypto/man/threads.3 head/secure/lib/libcrypto/man/ui.3 head/secure/lib/libcrypto/man/ui_compat.3 head/secure/lib/libcrypto/man/x509.3 head/secure/lib/libssl/Makefile.man head/secure/lib/libssl/man/SSL_CIPHER_get_name.3 head/secure/lib/libssl/man/SSL_COMP_add_compression_method.3 head/secure/lib/libssl/man/SSL_CONF_CTX_new.3 head/secure/lib/libssl/man/SSL_CONF_CTX_set1_prefix.3 head/secure/lib/libssl/man/SSL_CONF_CTX_set_flags.3 head/secure/lib/libssl/man/SSL_CONF_CTX_set_ssl_ctx.3 head/secure/lib/libssl/man/SSL_CONF_cmd.3 head/secure/lib/libssl/man/SSL_CONF_cmd_argv.3 head/secure/lib/libssl/man/SSL_CTX_add1_chain_cert.3 head/secure/lib/libssl/man/SSL_CTX_add_extra_chain_cert.3 head/secure/lib/libssl/man/SSL_CTX_add_session.3 head/secure/lib/libssl/man/SSL_CTX_ctrl.3 head/secure/lib/libssl/man/SSL_CTX_flush_sessions.3 head/secure/lib/libssl/man/SSL_CTX_free.3 head/secure/lib/libssl/man/SSL_CTX_get0_param.3 head/secure/lib/libssl/man/SSL_CTX_get_ex_new_index.3 head/secure/lib/libssl/man/SSL_CTX_get_verify_mode.3 head/secure/lib/libssl/man/SSL_CTX_load_verify_locations.3 head/secure/lib/libssl/man/SSL_CTX_new.3 head/secure/lib/libssl/man/SSL_CTX_sess_number.3 head/secure/lib/libssl/man/SSL_CTX_sess_set_cache_size.3 head/secure/lib/libssl/man/SSL_CTX_sess_set_get_cb.3 head/secure/lib/libssl/man/SSL_CTX_sessions.3 head/secure/lib/libssl/man/SSL_CTX_set1_curves.3 head/secure/lib/libssl/man/SSL_CTX_set1_verify_cert_store.3 head/secure/lib/libssl/man/SSL_CTX_set_alpn_select_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_cert_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_cert_store.3 head/secure/lib/libssl/man/SSL_CTX_set_cert_verify_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_cipher_list.3 head/secure/lib/libssl/man/SSL_CTX_set_client_CA_list.3 head/secure/lib/libssl/man/SSL_CTX_set_client_cert_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_custom_cli_ext.3 head/secure/lib/libssl/man/SSL_CTX_set_default_passwd_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_generate_session_id.3 head/secure/lib/libssl/man/SSL_CTX_set_info_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_max_cert_list.3 head/secure/lib/libssl/man/SSL_CTX_set_mode.3 head/secure/lib/libssl/man/SSL_CTX_set_msg_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_options.3 head/secure/lib/libssl/man/SSL_CTX_set_psk_client_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_quiet_shutdown.3 head/secure/lib/libssl/man/SSL_CTX_set_read_ahead.3 head/secure/lib/libssl/man/SSL_CTX_set_session_cache_mode.3 head/secure/lib/libssl/man/SSL_CTX_set_session_id_context.3 head/secure/lib/libssl/man/SSL_CTX_set_ssl_version.3 head/secure/lib/libssl/man/SSL_CTX_set_timeout.3 head/secure/lib/libssl/man/SSL_CTX_set_tlsext_status_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_tlsext_ticket_key_cb.3 head/secure/lib/libssl/man/SSL_CTX_set_tmp_dh_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_tmp_rsa_callback.3 head/secure/lib/libssl/man/SSL_CTX_set_verify.3 head/secure/lib/libssl/man/SSL_CTX_use_certificate.3 head/secure/lib/libssl/man/SSL_CTX_use_psk_identity_hint.3 head/secure/lib/libssl/man/SSL_CTX_use_serverinfo.3 head/secure/lib/libssl/man/SSL_SESSION_free.3 head/secure/lib/libssl/man/SSL_SESSION_get_ex_new_index.3 head/secure/lib/libssl/man/SSL_SESSION_get_time.3 head/secure/lib/libssl/man/SSL_accept.3 head/secure/lib/libssl/man/SSL_alert_type_string.3 head/secure/lib/libssl/man/SSL_check_chain.3 head/secure/lib/libssl/man/SSL_clear.3 head/secure/lib/libssl/man/SSL_connect.3 head/secure/lib/libssl/man/SSL_do_handshake.3 head/secure/lib/libssl/man/SSL_free.3 head/secure/lib/libssl/man/SSL_get_SSL_CTX.3 head/secure/lib/libssl/man/SSL_get_ciphers.3 head/secure/lib/libssl/man/SSL_get_client_CA_list.3 head/secure/lib/libssl/man/SSL_get_current_cipher.3 head/secure/lib/libssl/man/SSL_get_default_timeout.3 head/secure/lib/libssl/man/SSL_get_error.3 head/secure/lib/libssl/man/SSL_get_ex_data_X509_STORE_CTX_idx.3 head/secure/lib/libssl/man/SSL_get_ex_new_index.3 head/secure/lib/libssl/man/SSL_get_fd.3 head/secure/lib/libssl/man/SSL_get_peer_cert_chain.3 head/secure/lib/libssl/man/SSL_get_peer_certificate.3 head/secure/lib/libssl/man/SSL_get_psk_identity.3 head/secure/lib/libssl/man/SSL_get_rbio.3 head/secure/lib/libssl/man/SSL_get_session.3 head/secure/lib/libssl/man/SSL_get_verify_result.3 head/secure/lib/libssl/man/SSL_get_version.3 head/secure/lib/libssl/man/SSL_library_init.3 head/secure/lib/libssl/man/SSL_load_client_CA_file.3 head/secure/lib/libssl/man/SSL_new.3 head/secure/lib/libssl/man/SSL_pending.3 head/secure/lib/libssl/man/SSL_read.3 head/secure/lib/libssl/man/SSL_rstate_string.3 head/secure/lib/libssl/man/SSL_session_reused.3 head/secure/lib/libssl/man/SSL_set_bio.3 head/secure/lib/libssl/man/SSL_set_connect_state.3 head/secure/lib/libssl/man/SSL_set_fd.3 head/secure/lib/libssl/man/SSL_set_session.3 head/secure/lib/libssl/man/SSL_set_shutdown.3 head/secure/lib/libssl/man/SSL_set_verify_result.3 head/secure/lib/libssl/man/SSL_shutdown.3 head/secure/lib/libssl/man/SSL_state_string.3 head/secure/lib/libssl/man/SSL_want.3 head/secure/lib/libssl/man/SSL_write.3 head/secure/lib/libssl/man/d2i_SSL_SESSION.3 head/secure/lib/libssl/man/ssl.3 head/secure/usr.bin/openssl/Makefile.man head/secure/usr.bin/openssl/man/CA.pl.1 head/secure/usr.bin/openssl/man/asn1parse.1 head/secure/usr.bin/openssl/man/c_rehash.1 head/secure/usr.bin/openssl/man/ca.1 head/secure/usr.bin/openssl/man/ciphers.1 head/secure/usr.bin/openssl/man/cms.1 head/secure/usr.bin/openssl/man/crl.1 head/secure/usr.bin/openssl/man/crl2pkcs7.1 head/secure/usr.bin/openssl/man/dgst.1 head/secure/usr.bin/openssl/man/dhparam.1 head/secure/usr.bin/openssl/man/dsa.1 head/secure/usr.bin/openssl/man/dsaparam.1 head/secure/usr.bin/openssl/man/ec.1 head/secure/usr.bin/openssl/man/ecparam.1 head/secure/usr.bin/openssl/man/enc.1 head/secure/usr.bin/openssl/man/errstr.1 head/secure/usr.bin/openssl/man/gendsa.1 head/secure/usr.bin/openssl/man/genpkey.1 head/secure/usr.bin/openssl/man/genrsa.1 head/secure/usr.bin/openssl/man/nseq.1 head/secure/usr.bin/openssl/man/ocsp.1 head/secure/usr.bin/openssl/man/openssl.1 head/secure/usr.bin/openssl/man/passwd.1 head/secure/usr.bin/openssl/man/pkcs12.1 head/secure/usr.bin/openssl/man/pkcs7.1 head/secure/usr.bin/openssl/man/pkcs8.1 head/secure/usr.bin/openssl/man/pkey.1 head/secure/usr.bin/openssl/man/pkeyparam.1 head/secure/usr.bin/openssl/man/pkeyutl.1 head/secure/usr.bin/openssl/man/rand.1 head/secure/usr.bin/openssl/man/req.1 head/secure/usr.bin/openssl/man/rsa.1 head/secure/usr.bin/openssl/man/rsautl.1 head/secure/usr.bin/openssl/man/s_client.1 head/secure/usr.bin/openssl/man/s_server.1 head/secure/usr.bin/openssl/man/s_time.1 head/secure/usr.bin/openssl/man/sess_id.1 head/secure/usr.bin/openssl/man/smime.1 head/secure/usr.bin/openssl/man/speed.1 head/secure/usr.bin/openssl/man/spkac.1 head/secure/usr.bin/openssl/man/ts.1 head/secure/usr.bin/openssl/man/tsget.1 head/secure/usr.bin/openssl/man/verify.1 head/secure/usr.bin/openssl/man/version.1 head/secure/usr.bin/openssl/man/x509.1 head/secure/usr.bin/openssl/man/x509v3_config.1 Directory Properties: head/crypto/openssl/ (props changed) Modified: head/crypto/openssl/CHANGES ============================================================================== --- head/crypto/openssl/CHANGES Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/CHANGES Thu May 25 20:52:16 2017 (r318899) @@ -2,6 +2,12 @@ OpenSSL CHANGES _______________ + Changes between 1.0.2k and 1.0.2l [25 May 2017] + + *) Have 'config' recognise 64-bit mingw and choose 'mingw64' as the target + platform rather than 'mingw'. + [Richard Levitte] + Changes between 1.0.2j and 1.0.2k [26 Jan 2017] *) Truncated packet could crash via OOB read Modified: head/crypto/openssl/Configure ============================================================================== --- head/crypto/openssl/Configure Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/Configure Thu May 25 20:52:16 2017 (r318899) @@ -109,7 +109,7 @@ my $usage="Usage: Configure [no- # Minimum warning options... any contributions to OpenSSL should at least get # past these. -my $gcc_devteam_warn = "-Wall -pedantic -DPEDANTIC -Wno-long-long -Wsign-compare -Wmissing-prototypes -Wshadow -Wformat -Werror -DCRYPTO_MDEBUG_ALL -DCRYPTO_MDEBUG_ABORT -DREF_CHECK -DOPENSSL_NO_DEPRECATED"; +my $gcc_devteam_warn = "-Wall -pedantic -DPEDANTIC -Wno-long-long -Wsign-compare -Wmissing-prototypes -Wshadow -Wformat -Wundef -Werror -DCRYPTO_MDEBUG_ALL -DCRYPTO_MDEBUG_ABORT -DREF_CHECK -DOPENSSL_NO_DEPRECATED"; # TODO(openssl-team): fix problems and investigate if (at least) the following # warnings can also be enabled: @@ -2041,12 +2041,13 @@ EOF close(OUT); } else { my $make_command = "$make PERL=\'$perl\'"; - my $make_targets = ""; - $make_targets .= " links" if $symlink; - $make_targets .= " depend" if $depflags ne $default_depflags && $make_depend; - $make_targets .= " gentests" if $symlink; - (system $make_command.$make_targets) == 0 or exit $? - if $make_targets ne ""; + my @make_targets = (); + push @make_targets, "links" if $symlink; + push @make_targets, "depend" if $depflags ne $default_depflags && $make_depend; + push @make_targets, "gentests" if $symlink; + foreach my $make_target (@make_targets) { + (system "$make_command $make_target") == 0 or exit $?; + } if ( $perl =~ m@^/@) { &dofile("tools/c_rehash",$perl,'^#!/', '#!%s','^my \$dir;$', 'my $dir = "' . $openssldir . '";', '^my \$prefix;$', 'my $prefix = "' . $prefix . '";'); &dofile("apps/CA.pl",$perl,'^#!/', '#!%s'); @@ -2056,8 +2057,8 @@ EOF &dofile("apps/CA.pl",'/usr/local/bin/perl','^#!/', '#!%s'); } if ($depflags ne $default_depflags && !$make_depend) { - $warn_make_depend++; - } + $warn_make_depend++; + } } # create the ms/version32.rc file if needed Modified: head/crypto/openssl/LICENSE ============================================================================== --- head/crypto/openssl/LICENSE Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/LICENSE Thu May 25 20:52:16 2017 (r318899) @@ -2,7 +2,7 @@ LICENSE ISSUES ============== - The OpenSSL toolkit stays under a dual license, i.e. both the conditions of + The OpenSSL toolkit stays under a double license, i.e. both the conditions of the OpenSSL License and the original SSLeay license apply to the toolkit. See below for the actual license texts. Actually both licenses are BSD-style Open Source licenses. In case of any license issues related to OpenSSL @@ -12,7 +12,7 @@ --------------- /* ==================================================================== - * Copyright (c) 1998-2016 The OpenSSL Project. All rights reserved. + * Copyright (c) 1998-2017 The OpenSSL Project. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions Modified: head/crypto/openssl/Makefile ============================================================================== --- head/crypto/openssl/Makefile Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/Makefile Thu May 25 20:52:16 2017 (r318899) @@ -4,7 +4,7 @@ ## Makefile for OpenSSL ## -VERSION=1.0.2k +VERSION=1.0.2l MAJOR=1 MINOR=0.2 SHLIB_VERSION_NUMBER=1.0.0 @@ -426,6 +426,14 @@ clean: libclean rm -fr $$i/*; \ done +distclean: clean + -$(RM) `find . -name .git -prune -o -type l -print` + $(RM) apps/CA.pl + $(RM) test/evptests.txt test/newkey.pem test/testkey.pem test/testreq.pem + $(RM) tools/c_rehash + $(RM) crypto/opensslconf.h + $(RM) Makefile Makefile.bak + makefile.one: files $(PERL) util/mk1mf.pl >makefile.one; \ sh util/do_ms.sh Modified: head/crypto/openssl/Makefile.org ============================================================================== --- head/crypto/openssl/Makefile.org Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/Makefile.org Thu May 25 20:52:16 2017 (r318899) @@ -424,6 +424,14 @@ clean: libclean rm -fr $$i/*; \ done +distclean: clean + -$(RM) `find . -name .git -prune -o -type l -print` + $(RM) apps/CA.pl + $(RM) test/evptests.txt test/newkey.pem test/testkey.pem test/testreq.pem + $(RM) tools/c_rehash + $(RM) crypto/opensslconf.h + $(RM) Makefile Makefile.bak + makefile.one: files $(PERL) util/mk1mf.pl >makefile.one; \ sh util/do_ms.sh Modified: head/crypto/openssl/NEWS ============================================================================== --- head/crypto/openssl/NEWS Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/NEWS Thu May 25 20:52:16 2017 (r318899) @@ -5,6 +5,10 @@ This file gives a brief overview of the major changes between each OpenSSL release. For more details please read the CHANGES file. + Major changes between OpenSSL 1.0.2k and OpenSSL 1.0.2l [25 May 2017] + + o config now recognises 64-bit mingw and chooses mingw64 instead of mingw + Major changes between OpenSSL 1.0.2j and OpenSSL 1.0.2k [26 Jan 2017] o Truncated packet could crash via OOB read (CVE-2017-3731) Modified: head/crypto/openssl/README ============================================================================== --- head/crypto/openssl/README Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/README Thu May 25 20:52:16 2017 (r318899) @@ -1,5 +1,5 @@ - OpenSSL 1.0.2k 26 Jan 2017 + OpenSSL 1.0.2l 25 May 2017 Copyright (c) 1998-2015 The OpenSSL Project Copyright (c) 1995-1998 Eric A. Young, Tim J. Hudson Modified: head/crypto/openssl/apps/ca.c ============================================================================== --- head/crypto/openssl/apps/ca.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/ca.c Thu May 25 20:52:16 2017 (r318899) @@ -2126,10 +2126,8 @@ static int do_body(X509 **xret, EVP_PKEY goto err; } - for (i = 0; i < DB_NUMBER; i++) { + for (i = 0; i < DB_NUMBER; i++) irow[i] = row[i]; - row[i] = NULL; - } irow[DB_NUMBER] = NULL; if (!TXT_DB_insert(db->db, irow)) { @@ -2137,11 +2135,14 @@ static int do_body(X509 **xret, EVP_PKEY BIO_printf(bio_err, "TXT_DB error number %ld\n", db->db->error); goto err; } + irow = NULL; ok = 1; err: - for (i = 0; i < DB_NUMBER; i++) - if (row[i] != NULL) + if (irow != NULL) { + for (i = 0; i < DB_NUMBER; i++) OPENSSL_free(row[i]); + OPENSSL_free(irow); + } if (CAname != NULL) X509_NAME_free(CAname); @@ -2396,18 +2397,20 @@ static int do_revoke(X509 *x509, CA_DB * goto err; } - for (i = 0; i < DB_NUMBER; i++) { + for (i = 0; i < DB_NUMBER; i++) irow[i] = row[i]; - row[i] = NULL; - } irow[DB_NUMBER] = NULL; if (!TXT_DB_insert(db->db, irow)) { BIO_printf(bio_err, "failed to update database\n"); BIO_printf(bio_err, "TXT_DB error number %ld\n", db->db->error); + OPENSSL_free(irow); goto err; } + for (i = 0; i < DB_NUMBER; i++) + row[i] = NULL; + /* Revoke Certificate */ if (type == -1) ok = 1; Modified: head/crypto/openssl/apps/dhparam.c ============================================================================== --- head/crypto/openssl/apps/dhparam.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/dhparam.c Thu May 25 20:52:16 2017 (r318899) @@ -381,10 +381,19 @@ int MAIN(int argc, char **argv) } else # endif { - if (informat == FORMAT_ASN1) + if (informat == FORMAT_ASN1) { + /* + * We have no PEM header to determine what type of DH params it + * is. We'll just try both. + */ dh = d2i_DHparams_bio(in, NULL); - else /* informat == FORMAT_PEM */ + /* BIO_reset() returns 0 for success for file BIOs only!!! */ + if (dh == NULL && BIO_reset(in) == 0) + dh = d2i_DHxparams_bio(in, NULL); + } else { + /* informat == FORMAT_PEM */ dh = PEM_read_bio_DHparams(in, NULL, NULL, NULL); + } if (dh == NULL) { BIO_printf(bio_err, "unable to load DH parameters\n"); @@ -484,10 +493,13 @@ int MAIN(int argc, char **argv) } if (!noout) { - if (outformat == FORMAT_ASN1) - i = i2d_DHparams_bio(out, dh); - else if (outformat == FORMAT_PEM) { - if (dh->q) + if (outformat == FORMAT_ASN1) { + if (dh->q != NULL) + i = i2d_DHxparams_bio(out, dh); + else + i = i2d_DHparams_bio(out, dh); + } else if (outformat == FORMAT_PEM) { + if (dh->q != NULL) i = PEM_write_bio_DHxparams(out, dh); else i = PEM_write_bio_DHparams(out, dh); Modified: head/crypto/openssl/apps/enc.c ============================================================================== --- head/crypto/openssl/apps/enc.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/enc.c Thu May 25 20:52:16 2017 (r318899) @@ -81,20 +81,32 @@ int set_hex(char *in, unsigned char *out #define BSIZE (8*1024) #define PROG enc_main -static void show_ciphers(const OBJ_NAME *name, void *bio_) +struct doall_enc_ciphers { + BIO *bio; + int n; +}; + +static void show_ciphers(const OBJ_NAME *name, void *arg) { - BIO *bio = bio_; - static int n; + struct doall_enc_ciphers *dec = (struct doall_enc_ciphers *)arg; + const EVP_CIPHER *cipher; if (!islower((unsigned char)*name->name)) return; - BIO_printf(bio, "-%-25s", name->name); - if (++n == 3) { - BIO_printf(bio, "\n"); - n = 0; + /* Filter out ciphers that we cannot use */ + cipher = EVP_get_cipherbyname(name->name); + if (cipher == NULL || + (EVP_CIPHER_flags(cipher) & EVP_CIPH_FLAG_AEAD_CIPHER) != 0 || + EVP_CIPHER_mode(cipher) == EVP_CIPH_XTS_MODE) + return; + + BIO_printf(dec->bio, "-%-25s", name->name); + if (++dec->n == 3) { + BIO_printf(dec->bio, "\n"); + dec->n = 0; } else - BIO_printf(bio, " "); + BIO_printf(dec->bio, " "); } int MAIN(int, char **); @@ -130,6 +142,7 @@ int MAIN(int argc, char **argv) ENGINE *e = NULL; const EVP_MD *dgst = NULL; int non_fips_allow = 0; + struct doall_enc_ciphers dec; apps_startup(); @@ -311,8 +324,10 @@ int MAIN(int argc, char **argv) #endif BIO_printf(bio_err, "Cipher Types\n"); + dec.n = 0; + dec.bio = bio_err; OBJ_NAME_do_all_sorted(OBJ_NAME_TYPE_CIPHER_METH, - show_ciphers, bio_err); + show_ciphers, &dec); BIO_printf(bio_err, "\n"); goto end; Modified: head/crypto/openssl/apps/engine.c ============================================================================== --- head/crypto/openssl/apps/engine.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/engine.c Thu May 25 20:52:16 2017 (r318899) @@ -108,13 +108,16 @@ static int append_buf(char **buf, const } if (strlen(*buf) + strlen(s) >= (unsigned int)*size) { + char *p = *buf; + *size += step; *buf = OPENSSL_realloc(*buf, *size); + if (*buf == NULL) { + OPENSSL_free(p); + return 0; + } } - if (*buf == NULL) - return 0; - if (**buf != '\0') BUF_strlcat(*buf, ", ", *size); BUF_strlcat(*buf, s, *size); Modified: head/crypto/openssl/apps/pkeyutl.c ============================================================================== --- head/crypto/openssl/apps/pkeyutl.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/pkeyutl.c Thu May 25 20:52:16 2017 (r318899) @@ -322,8 +322,10 @@ int MAIN(int argc, char **argv) buf_in, (size_t)buf_inlen); if (rv == 0) BIO_puts(out, "Signature Verification Failure\n"); - else if (rv == 1) + else if (rv == 1) { BIO_puts(out, "Signature Verified Successfully\n"); + ret = 0; + } if (rv >= 0) goto end; } else { Modified: head/crypto/openssl/apps/prime.c ============================================================================== --- head/crypto/openssl/apps/prime.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/prime.c Thu May 25 20:52:16 2017 (r318899) @@ -155,5 +155,8 @@ int MAIN(int argc, char **argv) BIO_printf(bio_err, "options are\n"); BIO_printf(bio_err, "%-14s hex\n", "-hex"); BIO_printf(bio_err, "%-14s number of checks\n", "-checks "); + BIO_printf(bio_err, "%-14s generate prime\n", "-generate"); + BIO_printf(bio_err, "%-14s number of bits\n", "-bits "); + BIO_printf(bio_err, "%-14s safe prime\n", "-safe"); return 1; } Modified: head/crypto/openssl/apps/progs.h ============================================================================== --- head/crypto/openssl/apps/progs.h Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/progs.h Thu May 25 20:52:16 2017 (r318899) @@ -58,7 +58,7 @@ extern int srp_main(int argc, char *argv typedef struct { int type; const char *name; - int (*func) (int argc, char *argv[]); + int (*func)(int argc, char *argv[]); } FUNCTION; DECLARE_LHASH_OF(FUNCTION); Modified: head/crypto/openssl/apps/progs.pl ============================================================================== --- head/crypto/openssl/apps/progs.pl Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/progs.pl Thu May 25 20:52:16 2017 (r318899) @@ -6,22 +6,22 @@ print "/* automatically generated by pro grep(s/^asn1pars$/asn1parse/,@ARGV); foreach (@ARGV) - { printf "extern int %s_main(int argc,char *argv[]);\n",$_; } + { printf "extern int %s_main(int argc, char *argv[]);\n",$_; } print <<'EOF'; -#define FUNC_TYPE_GENERAL 1 -#define FUNC_TYPE_MD 2 -#define FUNC_TYPE_CIPHER 3 -#define FUNC_TYPE_PKEY 4 -#define FUNC_TYPE_MD_ALG 5 -#define FUNC_TYPE_CIPHER_ALG 6 +#define FUNC_TYPE_GENERAL 1 +#define FUNC_TYPE_MD 2 +#define FUNC_TYPE_CIPHER 3 +#define FUNC_TYPE_PKEY 4 +#define FUNC_TYPE_MD_ALG 5 +#define FUNC_TYPE_CIPHER_ALG 6 typedef struct { - int type; - const char *name; - int (*func)(int argc,char *argv[]); - } FUNCTION; + int type; + const char *name; + int (*func)(int argc, char *argv[]); +} FUNCTION; DECLARE_LHASH_OF(FUNCTION); FUNCTION functions[] = { @@ -30,7 +30,7 @@ EOF foreach (@ARGV) { push(@files,$_); - $str="\t{FUNC_TYPE_GENERAL,\"$_\",${_}_main},\n"; + $str=" {FUNC_TYPE_GENERAL, \"$_\", ${_}_main},\n"; if (($_ =~ /^s_/) || ($_ =~ /^ciphers$/)) { print "#if !defined(OPENSSL_NO_SOCK)\n${str}#endif\n"; } elsif ( ($_ =~ /^speed$/)) @@ -60,7 +60,7 @@ foreach (@ARGV) foreach ("md2","md4","md5","sha","sha1","mdc2","rmd160") { push(@files,$_); - printf "#ifndef OPENSSL_NO_".uc($_)."\n\t{FUNC_TYPE_MD,\"".$_."\",dgst_main},\n#endif\n"; + printf "#ifndef OPENSSL_NO_".uc($_)."\n {FUNC_TYPE_MD, \"".$_."\", dgst_main},\n#endif\n"; } foreach ( @@ -86,7 +86,7 @@ foreach ( { push(@files,$_); - $t=sprintf("\t{FUNC_TYPE_CIPHER,\"%s\",enc_main},\n",$_); + $t=sprintf(" {FUNC_TYPE_CIPHER, \"%s\", enc_main},\n",$_); if ($_ =~ /des/) { $t="#ifndef OPENSSL_NO_DES\n${t}#endif\n"; } elsif ($_ =~ /aes/) { $t="#ifndef OPENSSL_NO_AES\n${t}#endif\n"; } elsif ($_ =~ /camellia/) { $t="#ifndef OPENSSL_NO_CAMELLIA\n${t}#endif\n"; } @@ -101,4 +101,4 @@ foreach ( print $t; } -print "\t{0,NULL,NULL}\n\t};\n"; +print " {0, NULL, NULL}\n};\n"; Modified: head/crypto/openssl/apps/req.c ============================================================================== --- head/crypto/openssl/apps/req.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/req.c Thu May 25 20:52:16 2017 (r318899) @@ -331,7 +331,6 @@ int MAIN(int argc, char **argv) else if (strcmp(*argv, "-text") == 0) text = 1; else if (strcmp(*argv, "-x509") == 0) { - newreq = 1; x509 = 1; } else if (strcmp(*argv, "-asn1-kludge") == 0) kludge = 1; @@ -447,6 +446,9 @@ int MAIN(int argc, char **argv) goto end; } + if (x509 && infile == NULL) + newreq = 1; + ERR_load_crypto_strings(); if (!app_passwd(bio_err, passargin, passargout, &passin, &passout)) { BIO_printf(bio_err, "Error getting passwords\n"); @@ -753,7 +755,7 @@ int MAIN(int argc, char **argv) } } - if (newreq) { + if (newreq || x509) { if (pkey == NULL) { BIO_printf(bio_err, "you need to specify a private key\n"); goto end; Modified: head/crypto/openssl/apps/s_client.c ============================================================================== --- head/crypto/openssl/apps/s_client.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/s_client.c Thu May 25 20:52:16 2017 (r318899) @@ -2132,6 +2132,7 @@ int MAIN(int argc, char **argv) BIO_free(bio_c_msg); bio_c_msg = NULL; } + SSL_COMP_free_compression_methods(); apps_shutdown(); OPENSSL_EXIT(ret); } Modified: head/crypto/openssl/apps/s_server.c ============================================================================== --- head/crypto/openssl/apps/s_server.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/s_server.c Thu May 25 20:52:16 2017 (r318899) @@ -2132,6 +2132,7 @@ int MAIN(int argc, char *argv[]) BIO_free(bio_s_msg); bio_s_msg = NULL; } + SSL_COMP_free_compression_methods(); apps_shutdown(); OPENSSL_EXIT(ret); } Modified: head/crypto/openssl/apps/srp.c ============================================================================== --- head/crypto/openssl/apps/srp.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/apps/srp.c Thu May 25 20:52:16 2017 (r318899) @@ -183,10 +183,8 @@ static int update_index(CA_DB *db, BIO * return 0; } - for (i = 0; i < DB_NUMBER; i++) { + for (i = 0; i < DB_NUMBER; i++) irow[i] = row[i]; - row[i] = NULL; - } irow[DB_NUMBER] = NULL; if (!TXT_DB_insert(db->db, irow)) { Modified: head/crypto/openssl/appveyor.yml ============================================================================== --- head/crypto/openssl/appveyor.yml Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/appveyor.yml Thu May 25 20:52:16 2017 (r318899) @@ -50,11 +50,3 @@ build_script: test_script: - nmake /f ms\%MAK% test - -notifications: - - provider: Email - to: - - openssl-commits@openssl.org - on_build_success: false - on_build_failure: true - on_build_status_changed: true Modified: head/crypto/openssl/config ============================================================================== --- head/crypto/openssl/config Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/config Thu May 25 20:52:16 2017 (r318899) @@ -344,6 +344,15 @@ case "${SYSTEM}:${RELEASE}:${VERSION}:${ echo "mips-sony-newsos4"; exit 0; ;; + # The following combinations are supported + # MINGW64* on x86_64 => mingw64 + # MINGW32* on x86_64 => mingw + # MINGW32* on i?86 => mingw + # + # MINGW64* on i?86 isn't expected to work... + MINGW64*:*:*:x86_64) + echo "${MACHINE}-whatever-mingw64"; exit 0; + ;; MINGW*) echo "${MACHINE}-whatever-mingw"; exit 0; ;; Modified: head/crypto/openssl/crypto/aes/Makefile ============================================================================== --- head/crypto/openssl/crypto/aes/Makefile Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/aes/Makefile Thu May 25 20:52:16 2017 (r318899) @@ -133,7 +133,7 @@ dclean: mv -f Makefile.new $(MAKEFILE) clean: - rm -f *.s *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff + rm -f *.s *.S *.o *.obj lib tags core .pure .nfs* *.old *.bak fluff # DO NOT DELETE THIS LINE -- make depend depends on it. Modified: head/crypto/openssl/crypto/aes/asm/aesni-sha1-x86_64.pl ============================================================================== --- head/crypto/openssl/crypto/aes/asm/aesni-sha1-x86_64.pl Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/aes/asm/aesni-sha1-x86_64.pl Thu May 25 20:52:16 2017 (r318899) @@ -1702,6 +1702,7 @@ $code.=<<___; mov 240($key),$rounds sub $in0,$out movups ($key),$rndkey0 # $key[0] + movups ($ivp),$iv # load IV movups 16($key),$rndkey[0] # forward reference lea 112($key),$key # size optimization Modified: head/crypto/openssl/crypto/aes/asm/aesni-sha256-x86_64.pl ============================================================================== --- head/crypto/openssl/crypto/aes/asm/aesni-sha256-x86_64.pl Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/aes/asm/aesni-sha256-x86_64.pl Thu May 25 20:52:16 2017 (r318899) @@ -1299,6 +1299,7 @@ $code.=<<___; mov 240($key),$rounds sub $in0,$out movups ($key),$rndkey0 # $key[0] + movups ($ivp),$iv # load IV movups 16($key),$rndkey[0] # forward reference lea 112($key),$key # size optimization Modified: head/crypto/openssl/crypto/aes/asm/bsaes-armv7.pl ============================================================================== --- head/crypto/openssl/crypto/aes/asm/bsaes-armv7.pl Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/aes/asm/bsaes-armv7.pl Thu May 25 20:52:16 2017 (r318899) @@ -1333,7 +1333,7 @@ bsaes_cbc_encrypt: vmov @XMM[4],@XMM[15] @ just in case ensure that IV vmov @XMM[5],@XMM[0] @ and input are preserved bl AES_decrypt - vld1.8 {@XMM[0]}, [$fp,:64] @ load result + vld1.8 {@XMM[0]}, [$fp] @ load result veor @XMM[0], @XMM[0], @XMM[4] @ ^= IV vmov @XMM[15], @XMM[5] @ @XMM[5] holds input vst1.8 {@XMM[0]}, [$rounds] @ write output Modified: head/crypto/openssl/crypto/asn1/a_bitstr.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_bitstr.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_bitstr.c Thu May 25 20:52:16 2017 (r318899) @@ -114,10 +114,11 @@ int i2c_ASN1_BIT_STRING(ASN1_BIT_STRING *(p++) = (unsigned char)bits; d = a->data; - memcpy(p, d, len); - p += len; - if (len > 0) + if (len > 0) { + memcpy(p, d, len); + p += len; p[-1] &= (0xff << bits); + } *pp = p; return (ret); } Modified: head/crypto/openssl/crypto/asn1/a_digest.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_digest.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_digest.c Thu May 25 20:52:16 2017 (r318899) @@ -86,8 +86,10 @@ int ASN1_digest(i2d_of_void *i2d, const p = str; i2d(data, &p); - if (!EVP_Digest(str, i, md, len, type, NULL)) + if (!EVP_Digest(str, i, md, len, type, NULL)) { + OPENSSL_free(str); return 0; + } OPENSSL_free(str); return (1); } @@ -104,8 +106,10 @@ int ASN1_item_digest(const ASN1_ITEM *it if (!str) return (0); - if (!EVP_Digest(str, i, md, len, type, NULL)) + if (!EVP_Digest(str, i, md, len, type, NULL)) { + OPENSSL_free(str); return 0; + } OPENSSL_free(str); return (1); } Modified: head/crypto/openssl/crypto/asn1/a_gentm.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_gentm.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_gentm.c Thu May 25 20:52:16 2017 (r318899) @@ -202,7 +202,7 @@ int asn1_generalizedtime_to_tm(struct tm if (a[o] == 'Z') o++; else if ((a[o] == '+') || (a[o] == '-')) { - int offsign = a[o] == '-' ? -1 : 1, offset = 0; + int offsign = a[o] == '-' ? 1 : -1, offset = 0; o++; if (o + 4 > l) goto err; Modified: head/crypto/openssl/crypto/asn1/a_strnid.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_strnid.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_strnid.c Thu May 25 20:52:16 2017 (r318899) @@ -192,7 +192,8 @@ static const ASN1_STRING_TABLE tbl_stand {NID_name, 1, ub_name, DIRSTRING_TYPE, 0}, {NID_dnQualifier, -1, -1, B_ASN1_PRINTABLESTRING, STABLE_NO_MASK}, {NID_domainComponent, 1, -1, B_ASN1_IA5STRING, STABLE_NO_MASK}, - {NID_ms_csp_name, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK} + {NID_ms_csp_name, -1, -1, B_ASN1_BMPSTRING, STABLE_NO_MASK}, + {NID_jurisdictionCountryName, 2, 2, B_ASN1_PRINTABLESTRING, STABLE_NO_MASK} }; static int sk_table_cmp(const ASN1_STRING_TABLE *const *a, Modified: head/crypto/openssl/crypto/asn1/a_time.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_time.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_time.c Thu May 25 20:52:16 2017 (r318899) @@ -137,7 +137,7 @@ int ASN1_TIME_check(ASN1_TIME *t) ASN1_GENERALIZEDTIME *ASN1_TIME_to_generalizedtime(ASN1_TIME *t, ASN1_GENERALIZEDTIME **out) { - ASN1_GENERALIZEDTIME *ret; + ASN1_GENERALIZEDTIME *ret = NULL; char *str; int newlen; @@ -146,22 +146,21 @@ ASN1_GENERALIZEDTIME *ASN1_TIME_to_gener if (!out || !*out) { if (!(ret = ASN1_GENERALIZEDTIME_new())) - return NULL; - if (out) - *out = ret; - } else + goto err; + } else { ret = *out; + } /* If already GeneralizedTime just copy across */ if (t->type == V_ASN1_GENERALIZEDTIME) { if (!ASN1_STRING_set(ret, t->data, t->length)) - return NULL; - return ret; + goto err; + goto done; } /* grow the string */ if (!ASN1_STRING_set(ret, NULL, t->length + 2)) - return NULL; + goto err; /* ASN1_STRING_set() allocated 'len + 1' bytes. */ newlen = t->length + 2 + 1; str = (char *)ret->data; @@ -173,9 +172,18 @@ ASN1_GENERALIZEDTIME *ASN1_TIME_to_gener BUF_strlcat(str, (char *)t->data, newlen); - return ret; + done: + if (out != NULL && *out == NULL) + *out = ret; + return ret; + + err: + if (out == NULL || *out != ret) + ASN1_GENERALIZEDTIME_free(ret); + return NULL; } + int ASN1_TIME_set_string(ASN1_TIME *s, const char *str) { ASN1_TIME t; Modified: head/crypto/openssl/crypto/asn1/a_utctm.c ============================================================================== --- head/crypto/openssl/crypto/asn1/a_utctm.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/a_utctm.c Thu May 25 20:52:16 2017 (r318899) @@ -172,7 +172,7 @@ int asn1_utctime_to_tm(struct tm *tm, co if (a[o] == 'Z') o++; else if ((a[o] == '+') || (a[o] == '-')) { - int offsign = a[o] == '-' ? -1 : 1, offset = 0; + int offsign = a[o] == '-' ? 1 : -1, offset = 0; o++; if (o + 4 > l) goto err; Modified: head/crypto/openssl/crypto/asn1/f_enum.c ============================================================================== --- head/crypto/openssl/crypto/asn1/f_enum.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/f_enum.c Thu May 25 20:52:16 2017 (r318899) @@ -138,7 +138,7 @@ int a2i_ASN1_ENUMERATED(BIO *bp, ASN1_EN bufp = (unsigned char *)buf; if (first) { first = 0; - if ((bufp[0] == '0') && (buf[1] == '0')) { + if ((bufp[0] == '0') && (bufp[1] == '0')) { bufp += 2; i -= 2; } Modified: head/crypto/openssl/crypto/asn1/f_int.c ============================================================================== --- head/crypto/openssl/crypto/asn1/f_int.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/f_int.c Thu May 25 20:52:16 2017 (r318899) @@ -152,7 +152,7 @@ int a2i_ASN1_INTEGER(BIO *bp, ASN1_INTEG bufp = (unsigned char *)buf; if (first) { first = 0; - if ((bufp[0] == '0') && (buf[1] == '0')) { + if ((bufp[0] == '0') && (bufp[1] == '0')) { bufp += 2; i -= 2; } Modified: head/crypto/openssl/crypto/asn1/tasn_dec.c ============================================================================== --- head/crypto/openssl/crypto/asn1/tasn_dec.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/tasn_dec.c Thu May 25 20:52:16 2017 (r318899) @@ -673,6 +673,7 @@ static int asn1_template_noexp_d2i(ASN1_ } len -= p - q; if (!sk_ASN1_VALUE_push((STACK_OF(ASN1_VALUE) *)*val, skfield)) { + ASN1_item_ex_free(&skfield, ASN1_ITEM_ptr(tt->item)); ASN1err(ASN1_F_ASN1_TEMPLATE_NOEXP_D2I, ERR_R_MALLOC_FAILURE); goto err; } Modified: head/crypto/openssl/crypto/asn1/tasn_new.c ============================================================================== --- head/crypto/openssl/crypto/asn1/tasn_new.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/tasn_new.c Thu May 25 20:52:16 2017 (r318899) @@ -158,7 +158,7 @@ static int asn1_item_ex_combine_new(ASN1 } asn1_set_choice_selector(pval, -1, it); if (asn1_cb && !asn1_cb(ASN1_OP_NEW_POST, pval, it, NULL)) - goto auxerr; + goto auxerr2; break; case ASN1_ITYPE_NDEF_SEQUENCE: @@ -186,10 +186,10 @@ static int asn1_item_ex_combine_new(ASN1 for (i = 0, tt = it->templates; i < it->tcount; tt++, i++) { pseqval = asn1_get_field_ptr(pval, tt); if (!ASN1_template_new(pseqval, tt)) - goto memerr; + goto memerr2; } if (asn1_cb && !asn1_cb(ASN1_OP_NEW_POST, pval, it, NULL)) - goto auxerr; + goto auxerr2; break; } #ifdef CRYPTO_MDEBUG @@ -198,6 +198,8 @@ static int asn1_item_ex_combine_new(ASN1 #endif return 1; + memerr2: + ASN1_item_ex_free(pval, it); memerr: ASN1err(ASN1_F_ASN1_ITEM_EX_COMBINE_NEW, ERR_R_MALLOC_FAILURE); #ifdef CRYPTO_MDEBUG @@ -206,9 +208,10 @@ static int asn1_item_ex_combine_new(ASN1 #endif return 0; + auxerr2: + ASN1_item_ex_free(pval, it); auxerr: ASN1err(ASN1_F_ASN1_ITEM_EX_COMBINE_NEW, ASN1_R_AUX_ERROR); - ASN1_item_ex_free(pval, it); #ifdef CRYPTO_MDEBUG if (it->sname) CRYPTO_pop_info(); Modified: head/crypto/openssl/crypto/asn1/x_long.c ============================================================================== --- head/crypto/openssl/crypto/asn1/x_long.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/x_long.c Thu May 25 20:52:16 2017 (r318899) @@ -126,7 +126,7 @@ static int long_i2c(ASN1_VALUE **pval, u * set. */ if (ltmp < 0) - utmp = -ltmp - 1; + utmp = 0 - (unsigned long)ltmp - 1; else utmp = ltmp; clen = BN_num_bits_word(utmp); @@ -155,19 +155,41 @@ static int long_i2c(ASN1_VALUE **pval, u static int long_c2i(ASN1_VALUE **pval, const unsigned char *cont, int len, int utype, char *free_cont, const ASN1_ITEM *it) { - int neg, i; + int neg = -1, i; long ltmp; unsigned long utmp = 0; char *cp = (char *)pval; + + if (len) { + /* + * Check possible pad byte. Worst case, we're skipping past actual + * content, but since that's only with 0x00 and 0xff and we set neg + * accordingly, the result will be correct in the end anyway. + */ + switch (cont[0]) { + case 0xff: + cont++; + len--; + neg = 1; + break; + case 0: + cont++; + len--; + neg = 0; + break; + } + } if (len > (int)sizeof(long)) { ASN1err(ASN1_F_LONG_C2I, ASN1_R_INTEGER_TOO_LARGE_FOR_LONG); return 0; } - /* Is it negative? */ - if (len && (cont[0] & 0x80)) - neg = 1; - else - neg = 0; + if (neg == -1) { + /* Is it negative? */ + if (len && (cont[0] & 0x80)) + neg = 1; + else + neg = 0; + } utmp = 0; for (i = 0; i < len; i++) { utmp <<= 8; @@ -178,8 +200,8 @@ static int long_c2i(ASN1_VALUE **pval, c } ltmp = (long)utmp; if (neg) { - ltmp++; ltmp = -ltmp; + ltmp--; } if (ltmp == it->size) { ASN1err(ASN1_F_LONG_C2I, ASN1_R_INTEGER_TOO_LARGE_FOR_LONG); Modified: head/crypto/openssl/crypto/asn1/x_name.c ============================================================================== --- head/crypto/openssl/crypto/asn1/x_name.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/asn1/x_name.c Thu May 25 20:52:16 2017 (r318899) @@ -178,6 +178,16 @@ static void x509_name_ex_free(ASN1_VALUE *pval = NULL; } +static void local_sk_X509_NAME_ENTRY_free(STACK_OF(X509_NAME_ENTRY) *ne) +{ + sk_X509_NAME_ENTRY_free(ne); +} + +static void local_sk_X509_NAME_ENTRY_pop_free(STACK_OF(X509_NAME_ENTRY) *ne) +{ + sk_X509_NAME_ENTRY_pop_free(ne, X509_NAME_ENTRY_free); +} + static int x509_name_ex_d2i(ASN1_VALUE **val, const unsigned char **in, long len, const ASN1_ITEM *it, int tag, int aclass, @@ -228,13 +238,14 @@ static int x509_name_ex_d2i(ASN1_VALUE * entry->set = i; if (!sk_X509_NAME_ENTRY_push(nm.x->entries, entry)) goto err; + sk_X509_NAME_ENTRY_set(entries, j, NULL); } - sk_X509_NAME_ENTRY_free(entries); } - sk_STACK_OF_X509_NAME_ENTRY_free(intname.s); ret = x509_name_canon(nm.x); if (!ret) goto err; + sk_STACK_OF_X509_NAME_ENTRY_pop_free(intname.s, + local_sk_X509_NAME_ENTRY_free); nm.x->modified = 0; *val = nm.a; *in = p; @@ -242,6 +253,8 @@ static int x509_name_ex_d2i(ASN1_VALUE * err: if (nm.x != NULL) X509_NAME_free(nm.x); + sk_STACK_OF_X509_NAME_ENTRY_pop_free(intname.s, + local_sk_X509_NAME_ENTRY_pop_free); ASN1err(ASN1_F_X509_NAME_EX_D2I, ERR_R_NESTED_ASN1_ERROR); return 0; } @@ -267,16 +280,6 @@ static int x509_name_ex_i2d(ASN1_VALUE * return ret; } -static void local_sk_X509_NAME_ENTRY_free(STACK_OF(X509_NAME_ENTRY) *ne) -{ - sk_X509_NAME_ENTRY_free(ne); -} - -static void local_sk_X509_NAME_ENTRY_pop_free(STACK_OF(X509_NAME_ENTRY) *ne) -{ - sk_X509_NAME_ENTRY_pop_free(ne, X509_NAME_ENTRY_free); -} - static int x509_name_encode(X509_NAME *a) { union { @@ -299,8 +302,10 @@ static int x509_name_encode(X509_NAME *a entries = sk_X509_NAME_ENTRY_new_null(); if (!entries) goto memerr; - if (!sk_STACK_OF_X509_NAME_ENTRY_push(intname.s, entries)) + if (!sk_STACK_OF_X509_NAME_ENTRY_push(intname.s, entries)) { + sk_X509_NAME_ENTRY_free(entries); goto memerr; + } set = entry->set; } if (!sk_X509_NAME_ENTRY_push(entries, entry)) @@ -370,8 +375,10 @@ static int x509_name_canon(X509_NAME *a) entries = sk_X509_NAME_ENTRY_new_null(); if (!entries) goto err; - if (!sk_STACK_OF_X509_NAME_ENTRY_push(intname, entries)) + if (!sk_STACK_OF_X509_NAME_ENTRY_push(intname, entries)) { + sk_X509_NAME_ENTRY_free(entries); goto err; + } set = entry->set; } tmpentry = X509_NAME_ENTRY_new(); Modified: head/crypto/openssl/crypto/bio/b_print.c ============================================================================== --- head/crypto/openssl/crypto/bio/b_print.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/bio/b_print.c Thu May 25 20:52:16 2017 (r318899) @@ -502,7 +502,7 @@ fmtint(char **sbuffer, if (!(flags & DP_F_UNSIGNED)) { if (value < 0) { signvalue = '-'; - uvalue = -value; + uvalue = -(unsigned LLONG)value; } else if (flags & DP_F_PLUS) signvalue = '+'; else if (flags & DP_F_SPACE) Modified: head/crypto/openssl/crypto/bio/bio_cb.c ============================================================================== --- head/crypto/openssl/crypto/bio/bio_cb.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/bio/bio_cb.c Thu May 25 20:52:16 2017 (r318899) @@ -78,6 +78,9 @@ long MS_CALLBACK BIO_debug_callback(BIO len = BIO_snprintf(buf,sizeof buf,"BIO[%p]: ",(void *)bio); + /* Ignore errors and continue printing the other information. */ + if (len < 0) + len = 0; p = buf + len; p_maxlen = sizeof(buf) - len; Modified: head/crypto/openssl/crypto/bio/bss_file.c ============================================================================== --- head/crypto/openssl/crypto/bio/bss_file.c Thu May 25 19:39:16 2017 (r318898) +++ head/crypto/openssl/crypto/bio/bss_file.c Thu May 25 20:52:16 2017 (r318899) @@ -251,7 +251,7 @@ static int MS_CALLBACK file_read(BIO *b, ret = fread(out, 1, (int)outl, (FILE *)b->ptr); if (ret == 0 && (b->flags & BIO_FLAGS_UPLINK) ? UP_ferror((FILE *)b->ptr) : - ferror((FILE *)b->ptr)) { + ferror((FILE *)b->ptr)) { SYSerr(SYS_F_FREAD, get_last_sys_error()); BIOerr(BIO_F_FILE_READ, ERR_R_SYS_LIB); ret = -1; @@ -287,6 +287,7 @@ static long MS_CALLBACK file_ctrl(BIO *b FILE *fp = (FILE *)b->ptr; FILE **fpp; char p[4]; + int st; switch (cmd) { case BIO_C_FILE_SEEK: @@ -318,8 +319,11 @@ static long MS_CALLBACK file_ctrl(BIO *b # if defined(__MINGW32__) && defined(__MSVCRT__) && !defined(_IOB_ENTRIES) # define _IOB_ENTRIES 20 # endif -# if defined(_IOB_ENTRIES) /* Safety net to catch purely internal BIO_set_fp calls */ +# if defined(_MSC_VER) && _MSC_VER>=1900 + if (ptr == stdin || ptr == stdout || ptr == stderr) + BIO_clear_flags(b, BIO_FLAGS_UPLINK); +# elif defined(_IOB_ENTRIES) if ((size_t)ptr >= (size_t)stdin && (size_t)ptr < (size_t)(stdin + _IOB_ENTRIES)) BIO_clear_flags(b, BIO_FLAGS_UPLINK); @@ -424,10 +428,14 @@ static long MS_CALLBACK file_ctrl(BIO *b b->shutdown = (int)num; break; case BIO_CTRL_FLUSH: - if (b->flags & BIO_FLAGS_UPLINK) - UP_fflush(b->ptr); - else - fflush((FILE *)b->ptr); + st = b->flags & BIO_FLAGS_UPLINK + ? UP_fflush(b->ptr) : fflush((FILE *)b->ptr); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-head@freebsd.org Thu May 25 21:11:26 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D5C74D82E17; Thu, 25 May 2017 21:11:26 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9A3281A18; Thu, 25 May 2017 21:11:26 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PLBPpU023931; Thu, 25 May 2017 21:11:25 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PLBPPq023930; Thu, 25 May 2017 21:11:25 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705252111.v4PLBPPq023930@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 21:11:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318900 - 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.23 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, 25 May 2017 21:11:26 -0000 Author: bapt Date: Thu May 25 21:11:25 2017 New Revision: 318900 URL: https://svnweb.freebsd.org/changeset/base/318900 Log: update to 2017.05.25 MFC after: 2 days Modified: head/share/misc/pci_vendors Modified: head/share/misc/pci_vendors ============================================================================== --- head/share/misc/pci_vendors Thu May 25 20:52:16 2017 (r318899) +++ head/share/misc/pci_vendors Thu May 25 21:11:25 2017 (r318900) @@ -3,8 +3,8 @@ # # List of PCI ID's # -# Version: 2017.04.03 -# Date: 2017-04-03 03:15:02 +# Version: 2017.05.25 +# Date: 2017-05-25 03:15:02 # # Maintained by Albert Pool, Martin Mares, and other volunteers from # the PCI ID Project at http://pci-ids.ucw.cz/. @@ -76,16 +76,16 @@ 0925 VIA Technologies, Inc. (Wrong ID) 0a89 BREA Technologies Inc 0b0b Rhino Equipment Corp. - 0105 Rhino R1T1 - 0205 Rhino R4FXO + 0105 R1T1 + 0205 R4FXO 0206 RCB4FXO 4-channel FXO analog telphony card - 0305 Rhino R4T1 - 0405 Rhino R8FXX + 0305 R4T1 + 0405 R8FXX 0406 RCB8FXX 8-channel modular analog telphony card - 0505 Rhino R24FXX + 0505 R24FXX 0506 RCB24FXS 24-Channel FXS analog telphony card - 0605 Rhino R2T1 - 0705 Rhino R24FXS + 0605 R2T1 + 0705 R24FXS 0706 RCB24FXO 24-Channel FXO analog telphony card 0905 R1T3 Single T3 Digital Telephony Card 0906 RCB24FXX 24-channel modular analog telphony card @@ -249,6 +249,7 @@ 0014 MegaRAID Tri-Mode SAS3516 1028 1fd4 PERC H745P MX 1d49 0602 ThinkSystem RAID 930-16i 4GB Flash PCIe 12Gb Adapter + 1d49 0604 ThinkSystem RAID 930-8e 4GB Flash PCIe 12Gb Adapter 0015 MegaRAID Tri-Mode SAS3416 0016 MegaRAID Tri-Mode SAS3508 1028 1fc9 PERC H840 Adapter @@ -430,6 +431,7 @@ 0062 SAS1078 PCI-Express Fusion-MPT SAS 1000 0062 SAS1078 PCI-Express Fusion-MPT SAS 0064 SAS2116 PCI-Express Fusion-MPT SAS-2 [Meteor] + 1000 30c0 SAS 9201-16i 0065 SAS2116 PCI-Express Fusion-MPT SAS-2 [Meteor] 006e SAS2308 PCI-Express Fusion-MPT SAS-2 0070 SAS2004 PCI-Express Fusion-MPT SAS-2 [Spitfire] @@ -544,6 +546,7 @@ 0097 SAS3008 PCI-Express Fusion-MPT SAS-3 1000 3090 SAS9311-8i 1000 30e0 SAS9300-8i + 1000 3130 SAS 9300-16i 1028 1f45 HBA330 Adapter 1028 1f46 12Gbps HBA 1028 1f53 HBA330 Mini @@ -1100,7 +1103,7 @@ 1028 0085 Rage 3D LT Pro 4c46 Rage Mobility 128 AGP 2X/Mobility M3 1002 0155 IBM Thinkpad A22p - 1014 0155 IBM Thinkpad A22p + 1014 0155 Thinkpad A22p 1028 00b1 Latitude C600 4c47 3D Rage IIC PCI / Mobility Radeon 7500/7500C 4c49 3D Rage LT PRO PCI @@ -2213,6 +2216,7 @@ 1043 04a8 Radeon RX 480 1043 04b0 Radeon RX 470 1043 04fb Radeon RX 480 + 1043 04fd Radeon RX 480 8GB 1462 3411 Radeon RX 470 1462 3413 Radeon RX 480 148c 2372 Radeon RX 480 @@ -2939,7 +2943,7 @@ 6985 Polaris12 6986 Polaris12 6987 Polaris12 - 699f Polaris12 + 699f Lexa PRO [Radeon RX 550] 700f RS100 AGP Bridge 7010 RS200/RS250 AGP Bridge 7100 R520 [Radeon X1800 XT] @@ -3955,6 +3959,7 @@ 1438 Liverpool Processor Root Port 1439 Family 16h Processor Functions 5:1 145b Zeppelin Non-Transparent Bridge + 145c USB3 Host Controller 1510 Family 14h Processor Root Complex 174b 1001 PURE Fusion Mini 1512 Family 14h Processor Root Port @@ -4039,6 +4044,7 @@ 43a1 Hudson PCI to PCI bridge (PCIE port 1) 43a2 Hudson PCI to PCI bridge (PCIE port 2) 43a3 Hudson PCI to PCI bridge (PCIE port 3) + 43bb USB 3.1 XHCI Controller 7006 AMD-751 [Irongate] System Controller 7007 AMD-751 [Irongate] AGP Bridge 700a AMD-IGR4 AGP Host to PCI Bridge @@ -6025,9 +6031,9 @@ 1077 e4f8 FastLinQ QL45611H 100GbE Adapter (SR-IOV VF) 2020 ISP2020A Fast!SCSI Basic Adapter 2031 ISP8324-based 16Gb Fibre Channel to PCI Express Adapter - 103c 17e7 HP SN1000Q 16Gb Single Port Fibre Channel Adapter - 103c 17e8 HP SN1000Q 16Gb Dual Port Fibre Channel Adapter - 103c 1939 HP QMH2672 16Gb Dual Port Fibre Channel Adapter + 103c 17e7 SN1000Q 16Gb Single Port Fibre Channel Adapter + 103c 17e8 SN1000Q 16Gb Dual Port Fibre Channel Adapter + 103c 1939 QMH2672 16Gb Dual Port Fibre Channel Adapter 103c 8002 3830C 16G Fibre Channel Host Bus Adapter 2071 ISP2714-based 16/32Gb Fibre Channel to PCIe Adapter 1077 0283 QLE2764 Quad Port 32Gb Fibre Channel to PCIe Adapter @@ -6047,10 +6053,10 @@ 1077 02a8 QLE2692 Dual Port 16Gb FC to PCIe Gen3 x8 Adapter 1077 02ab QLE2740 Single Port 32Gb FC to PCIe Gen3 x8 Adapter 1077 02ac QLE2742 Dual Port 32Gb FC to PCIe Gen3 x8 Adapter - 1590 00f9 HPE StoreFabric SN1100Q 16Gb Single Port Fibre Channel Host Bus Adapter - 1590 00fa HPE StoreFabric SN1100Q 16Gb Dual Port Fibre Channel Host Bus Adapter - 1590 0203 HPE StoreFabric SN1600Q 32Gb Single Port Fibre Channel Host Bus Adapter - 1590 0204 HPE StoreFabric SN1600Q 32Gb Dual Port Fibre Channel Host Bus Adapter + 1590 00f9 StoreFabric SN1100Q 16Gb Single Port Fibre Channel Host Bus Adapter + 1590 00fa StoreFabric SN1100Q 16Gb Dual Port Fibre Channel Host Bus Adapter + 1590 0203 StoreFabric SN1600Q 32Gb Single Port Fibre Channel Host Bus Adapter + 1590 0204 StoreFabric SN1600Q 32Gb Dual Port Fibre Channel Host Bus Adapter 2300 QLA2300 64-bit Fibre Channel Adapter 2312 ISP2312-based 2Gb Fibre Channel to PCI-X HBA 103c 0131 2Gb Fibre Channel - Single port [A7538A] @@ -6065,7 +6071,7 @@ 103c 3262 StorageWorks 81Q 103c 3263 StorageWorks 82Q 1077 0167 QME2572 Dual Port FC8 HBA Mezzanine - 1590 00fc HPE StoreFabric 84Q 8Gb Quad Port Fibre Channel Host Bus Adapter + 1590 00fc StoreFabric 84Q 8Gb Quad Port Fibre Channel Host Bus Adapter 3022 ISP4022-based Ethernet NIC 3032 ISP4032-based Ethernet IPv6 NIC 4010 ISP4010-based iSCSI TOE HBA @@ -8954,7 +8960,7 @@ 0396 G73 0397 G73M [GeForce Go 7700] 0398 G73M [GeForce Go 7600] - 1025 006c Acer 9814 WKMI + 1025 006c Aspire 9814WKMi 0399 G73M [GeForce Go 7600 GT] 039a G73M [Quadro NVS 300M] 039b G73M [GeForce Go 7900 SE] @@ -9912,6 +9918,7 @@ 0dfa GF108GLM [Quadro 1000M] 0dfc GF108GLM [NVS 5200M] 0e08 GF119 HDMI Audio Controller + 1043 83a0 ENGT520 SILENT # 1024MB with passive cooling (heatsink) 10b0 104a Gainward GeForce GT 610 0e09 GF110 High Definition Audio Controller @@ -10045,6 +10052,7 @@ 103a GK110GL [Quadro K6000] 103c GK110GL [Quadro K5200] 1040 GF119 [GeForce GT 520] + 1043 83a0 ENGT520 SILENT 1042 GF119 [GeForce 510] 1048 GF119 [GeForce 605] 1049 GF119 [GeForce GT 620 OEM] @@ -10694,6 +10702,7 @@ 17fd GM200GL [Tesla M40] 1b00 GP102 [TITAN X] 1b01 GP102 + 1b02 GP102 [TITAN Xp] 1b06 GP102 [GeForce GTX 1080 Ti] 1b30 GP102GL [Quadro P6000] 1b38 GP102GL [Tesla P40] @@ -10738,7 +10747,7 @@ 1cb1 GP107GL [Quardo P1000] 1cb2 GP107GL [Quardo P600] 1cb3 GP107GL [Quardo P400] - 1d01 GP108 + 1d01 GP108 [GeForce GT 1030] 1d81 GV100 10df Emulex Corporation 0720 OneConnect NIC (Skyhawk) @@ -10771,6 +10780,12 @@ e260 OneConnect FCoE Initiator (Lancer) e268 OneConnect 10Gb FCoE Converged Network Adapter (Lancer-VF) e300 Lancer Gen6: LPe32000 Fibre Channel Host Adapter + 10df e310 Lancer Gen6: LPe31000 Fibre Channel Host Adapter + 10df e311 Lancer Gen6: LPe31000 Fibre Channel Host Adapter + 10df e312 Lancer Gen6: LPe31000 Fibre Channel Host Adapter + 10df e322 Lancer Gen6: LPe31000 Fibre Channel Host Adapter + 10df e323 Lancer Gen6: LPe31000 Fibre Channel Host Adapter + 10df e325 Lancer Gen6: LPe31000 Fibre Channel Host Adapter f011 Saturn: LightPulse Fibre Channel Host Adapter f015 Saturn: LightPulse Fibre Channel Host Adapter f085 LP850 Fibre Channel Host Adapter @@ -11562,8 +11577,8 @@ 1043 8095 A7V8X Motherboard (Realtek ALC650 codec) 1043 80a1 A7V8X-X Motherboard 1043 80b0 A7V600/K8V-X/K8V Deluxe motherboard (ADI AD1980 codec [SoundMAX]) - 1043 80f3 ASUSTek SK8V motherboard - 1043 810d Asus P5VD1-X (AD1888 codec [SoundMax]) + 1043 80f3 SK8V motherboard + 1043 810d P5VD1-X (AD1888 codec [SoundMax]) 1043 812a A8V Deluxe motherboard (Realtek ALC850 codec) 10ec 8168 High Definition Audio 1106 3059 L7VMM2 Motherboard @@ -12248,7 +12263,7 @@ 0070 6701 WinTV HVR-1110 1019 4cb5 Elitegroup ECS TVP3XP FM1236 Tuner Card (NTSC,FM) 1043 0210 FlyTV mini Asus Digimatrix - 1043 4843 ASUS TV-FM 7133 + 1043 4843 TV-FM 7133 1043 4845 TV-FM 7135 1043 4862 P7131 Dual 1043 4876 My Cinema-P7131 Hybrid @@ -12322,7 +12337,7 @@ 0000 4071 Behold TV 407 FM 1019 4cb4 Elitegroup ECS TVP3XP FM1216 Tuner Card(PAL-BG,FM) 1043 0210 Digimatrix TV - 1043 4840 ASUS TV-FM 7134 + 1043 4840 TV-FM 7134 1043 4842 TV-FM 7134 1131 0000 SAA713x-based TV tuner card 1131 2004 EUROPA V3 reference design @@ -13039,7 +13054,7 @@ 103c 30c1 Compaq 6910p 1043 1237 A6J-Q008 1043 1967 V6800V - 1043 1987 Asus A4K and Z81K notebooks, possibly others ( mid-2005 machines ) + 1043 1987 A4K and Z81K notebooks, possibly others ( mid-2005 machines ) 104d 80df Vaio PCG-FX403 104d 80e7 VAIO PCG-GR214EP/GR214MP/GR215MP/GR314MP/GR315MP 104d 814e VAIO GRZ390Z @@ -13048,7 +13063,7 @@ 144d c00c P30/P35 notebook 14ef 0220 PCD-RP-220S 17aa 201c ThinkPad X60/X60s - 17aa 20c4 ThinkPad T61 + 17aa 20c4 ThinkPad T61/R61 17aa 20c6 ThinkPad R61 0477 RL5c477 0478 RL5c478 @@ -13098,7 +13113,7 @@ 103c 30cc Pavilion dv6700 103c 30cf Pavilion dv9668eg Laptop 1043 1237 A6J-Q008 - 1043 1967 ASUS V6800V + 1043 1967 V6800V 10f7 8338 Panasonic CF-Y5 laptop 144d c018 X20 IV 17aa 201d ThinkPad X60/X60s @@ -13114,14 +13129,15 @@ 103c 30c1 Compaq 6910p 103c 30cc Pavilion dv6700 103c 30cf Pavilion dv9668eg Laptop + 17aa 20c5 ThinkPad R61 17aa 20c7 ThinkPad R61 0841 R5C841 CardBus/SD/SDIO/MMC/MS/MSPro/xD/IEEE1394 0843 R5C843 MMC Host Controller 1025 0121 Aspire 5920G 1028 01d7 XPS M1210 1028 01f3 Inspiron 1420 - 1028 01f5 Dell Inspiron 1501 - 1028 024f Dell Latitude e6500 + 1028 01f5 Inspiron 1501 + 1028 024f Latitude e6500 103c 03b5 Presario V3242AU 103c 30b7 Presario V6133CL 103c 30cf Pavilion dv9500/9600/9700 series @@ -13144,9 +13160,11 @@ 1028 040a Latitude E6410 1028 040b Latitude E6510 e823 PCIe SDXC/MMC Host Controller + 17aa 21cf ThinkPad T520 e832 R5C832 PCIe IEEE 1394 Controller 1028 040a Latitude E6410 1028 040b Latitude E6510 + 17aa 21cf ThinkPad T520 e852 PCIe xD-Picture Card Controller 1181 Telmatics International 1183 Fujikura Ltd @@ -15143,7 +15161,7 @@ 0206 GPS180PEX GPS Receiver (PCI Express) 0207 GLN180PEX GPS/GLONASS receiver (PCI Express) 0208 GPS180AMC GPS Receiver (PCI Express / MicroTCA / AdvancedMC) - 0209 GRC181PEX GPS/GLONASS/BEIDOU receiver (PCI Express) + 0209 GNS181PEX GPS/Galileo/GLONASS/BEIDOU receiver (PCI Express) 0301 TCR510PCI IRIG Timecode Reader 0302 TCR167PCI IRIG Timecode Reader 0303 TCR511PCI IRIG Timecode Reader @@ -15746,8 +15764,8 @@ 1409 0103 PAR4008A 1409 0104 PAR4018A 140a DSP Research Inc -# Formerly RAMiX, Inc. -140b GE Intelligent Platforms +# Formerly RAMiX, GE Fanuc, GE Intelligent Platforms +140b Abaco Systems, Inc. 140c Elmic Systems Inc 140d Matsushita Electric Works Ltd 140e Goepel Electronic GmbH @@ -16062,6 +16080,7 @@ 509e T520-509E Unified Wire Ethernet Controller 509f T540-509F Unified Wire Ethernet Controller 50a0 T540-50A0 Unified Wire Ethernet Controller + 50a1 T540-50A1 Unified Wire Ethernet Controller 5401 T520-CR Unified Wire Ethernet Controller 5402 T522-CR Unified Wire Ethernet Controller 5403 T540-CR Unified Wire Ethernet Controller @@ -16113,6 +16132,7 @@ 549e T520-509E Unified Wire Ethernet Controller 549f T540-509F Unified Wire Ethernet Controller 54a0 T540-50A0 Unified Wire Ethernet Controller + 54a1 T540-50A1 Unified Wire Ethernet Controller 5501 T520-CR Unified Wire Storage Controller 5502 T522-CR Unified Wire Storage Controller 5503 T540-CR Unified Wire Storage Controller @@ -16164,6 +16184,7 @@ 559e T520-509E Unified Wire Storage Controller 559f T540-509F Unified Wire Storage Controller 55a0 T540-50A0 Unified Wire Storage Controller + 55a1 T540-50A1 Unified Wire Storage Controller 5601 T520-CR Unified Wire Storage Controller 5602 T522-CR Unified Wire Storage Controller 5603 T540-CR Unified Wire Storage Controller @@ -16215,6 +16236,7 @@ 569e T520-509E Unified Wire Storage Controller 569f T540-509F Unified Wire Storage Controller 56a0 T540-50A0 Unified Wire Storage Controller + 56a1 T540-50A1 Unified Wire Storage Controller 5701 T520-CR Unified Wire Ethernet Controller 5702 T522-CR Unified Wire Ethernet Controller 5703 T540-CR Unified Wire Ethernet Controller @@ -16305,6 +16327,7 @@ 589e T520-509E Unified Wire Ethernet Controller [VF] 589f T540-509F Unified Wire Ethernet Controller [VF] 58a0 T540-50A0 Unified Wire Ethernet Controller [VF] + 58a1 T540-50A1 Unified Wire Ethernet Controller [VF] 6001 T6225-CR Unified Wire Ethernet Controller 6002 T6225-SO-CR Unified Wire Ethernet Controller 6003 T6425-CR Unified Wire Ethernet Controller @@ -16470,6 +16493,8 @@ 1028 1fc2 Express Flash NVMe PM1725 1.6TB SFF 1028 1fc4 Express Flash NVMe PM1725 1.6TB AIC a822 NVMe SSD Controller 172Xa + 1014 0621 PCIe3 1.6TB NVMe Flash Adapter II x8 + 1014 0622 PCIe3 3.2TB NVMe Flash Adapter II x8 1028 1fd9 Express Flash PM1725a 800GB SFF 1028 1fda Express Flash PM1725a 1.6TB SFF 1028 1fdb Express Flash PM1725a 3.2TB SFF @@ -16663,7 +16688,10 @@ 14ca PE Logic Corp. 14cb Billionton Systems Inc 14cc NAKAYO Telecommunications Inc -14cd Universal Scientific Ind. +14cd Universal Global Scientific Industrial Co.,Ltd + 0001 USI-1514-1GbaseT [OCP1] + 0002 USI-4227-SFP [OCP2] + 0003 USI-X557-10GbaseT [OCP3] 14ce Whistle Communications 14cf TEK Microsystems Inc. 14d0 Ericsson Axe R & D @@ -16767,6 +16795,7 @@ 1028 02f1 PowerEdge R510 BCM5716 Gigabit Ethernet 163c NetXtreme II BCM5716S Gigabit Ethernet 163d NetXtreme II BCM57811 10-Gigabit Ethernet + 1043 858a PEB-10G/57811-1S 163e NetXtreme II BCM57811 10 Gigabit Ethernet Multi Function 163f NetXtreme II BCM57811 10-Gigabit Ethernet Virtual Function 1641 NetXtreme BCM57787 Gigabit Ethernet PCIe @@ -16892,7 +16921,7 @@ 1734 1061 PRIMERGY RX/TX S2 series onboard LAN 165a NetXtreme BCM5722 Gigabit Ethernet PCI Express # Dual NIC server - 1014 0378 IBM System x3350 (Machine type 4192) + 1014 0378 System x3350 (Machine type 4192) 1028 020f PowerEdge R300 Broadcom NetXtreme 5722 1028 0210 PowerEdge T300 Broadcom NetXtreme 5722 1028 0225 PowerEdge T105 Broadcom NetXtreme 5722 @@ -16992,6 +17021,7 @@ 1693 NetLink BCM5787M Gigabit Ethernet PCI Express 1025 0121 Aspire 5920G 103c 30c0 6710b + 17aa 20d5 ThinkPad R61 1694 NetLink BCM57790 Gigabit Ethernet PCIe 1696 NetXtreme BCM5782 Gigabit Ethernet 103c 12bc d530 CMT (DG746A) @@ -17128,6 +17158,8 @@ 16d5 BCM57407 NetXtreme-E 10GBase-T Ethernet Controller 16d6 BCM57412 NetXtreme-E 10Gb RDMA Ethernet Controller 16d7 BCM57414 NetXtreme-E 10Gb/25Gb RDMA Ethernet Controller + 14e4 1202 BCM957412M4122 OCP 1x25G Type1 wRoCE + 14e4 1404 BCM957414M4142 OCP 2x25G Type1 wRoCE 1590 020e Ethernet 25Gb 2-port 631SFP28 Adapter 1590 0211 Ethernet 25Gb 2-port 631FLR-SFP28 Adapter 16d8 BCM57416 NetXtreme-E 10GBase-T RDMA Ethernet Controller @@ -17622,7 +17654,7 @@ 1002 00f8 ATI TV Wonder Pro 1002 00f9 ATI TV Wonder 1002 a101 HDTV Wonder - 1043 4823 ASUS PVR-416 + 1043 4823 PVR-416 107d 6611 Winfast TV 2000XP Expert 107d 6613 Leadtek Winfast 2000XP Expert 107d 6620 Leadtek Winfast DV2000 @@ -17668,7 +17700,7 @@ 0070 9002 Nova-T DVB-T Model 909 0070 9402 WinTV-HVR1100 DVB-T/Hybrid 0070 9600 WinTV 88x MPEG Encoder - 1043 4823 ASUS PVR-416 + 1043 4823 PVR-416 107d 663c Leadtek PVR 2000 107d 665f WinFast DTV1000-T 14f1 0187 Conexant DVB-T reference design @@ -18099,6 +18131,18 @@ 103c 18ce InfiniBand QDR/EN 10Gb Dual Port 544M Adapter 103c 18cf InfiniBand FDR/EN 10/40Gb Dual Port 544M Adapter 103c 18d6 InfiniBand FDR/EN 10/40Gb Dual Port 544QSFP Adapter + 15b3 0025 ConnectX-3 IB QDR Dual Port Mezzanine Card + 15b3 0026 ConnectX-3 IB FDR Dual Port Mezzanine Card + 15b3 0059 ConnectX-3 VPI IB FDR/40 GbE Single Port QSFP+ Mezzanine Card + 15b3 0065 ConnectX-3 VPI IB FDR/40 GbE Dual Port QSFP+ Adapter + 15b3 0066 ConnectX-3 IB FDR10 Dual Port Mezzanine Card + 15b3 0067 ConnectX-3 VPI IB FDR/40 GbE Single Port QSFP+ Adapter + 15b3 0071 ConnectX-3 VPI IB FDR/40 GbE Dual Port QSFP+ Mezzanine Card +# SVID = 15B3 SSID = 0078 + 15b3 0078 ConnectX-3 10 GbE Dual Port KR Mezzanine Card + 15b3 0079 ConnectX-3 40 GbE Dual Port QSFP+ Adapter +# SVID = 15B3 SSID = 0080 + 15b3 0080 ConnectX-3 10 GbE Dual Port SFP+ Adapter 1004 MT27500/MT27520 Family [ConnectX-3/ConnectX-3 Pro Virtual Function] 1005 MT27510 Family 1006 MT27511 Family @@ -18111,6 +18155,9 @@ 117c 0091 FastFrame NQ42 117c 0092 FastFrame NQ11 117c 0093 FastFrame NQ12 + 15b3 0078 ConnectX-3 Pro 10 GbE Dual Port KR Mezzanine Card + 15b3 0079 ConnectX-3 Pro 40 GbE Dual Port QSFP+ Adapter + 15b3 0080 ConnectX-3 Pro 10 GbE Dual Port SFP+ Adapter 1009 MT27530 Family 100a MT27531 Family 100b MT27540 Family @@ -18122,8 +18169,16 @@ 1011 MT27600 [Connect-IB] 1012 MT27600 Family [Connect-IB Virtual Function] 1013 MT27700 Family [ConnectX-4] + 15b3 0006 MCX416A-BCAT, ConnectX-4 EN, 40/56GbE 2P, PCIe3.0 x16 + 15b3 0033 ConnectX-4 VPI IB EDR/100 GbE Single Port QSFP28 Adapter + 15b3 0034 ConnectX-4 VPI IB EDR/100 GbE Dual Port QSFP28 Adapter + 15b3 0050 ConnectX-4 100 GbE Dual Port QSFP28 Adapter 1014 MT27700 Family [ConnectX-4 Virtual Function] 1015 MT27710 Family [ConnectX-4 Lx] + 15b3 0016 ConnectX-4 Lx 25 GbE Dual Port SFP28 Adapter + 15b3 0020 MCX4411A-ACQN, ConnectX-4 Lx EN OCP, 1x25Gb + 15b3 0021 MCX4421A-ACQN ConnectX-4 Lx EN OCP,2x25G + 15b3 0025 ConnectX-4 Lx 25 GbE Dual Port SFP28 rNDC 1016 MT27710 Family [ConnectX-4 Lx Virtual Function] 1017 MT27800 Family [ConnectX-5] 1018 MT27800 Family [ConnectX-5 Virtual Function] @@ -18711,6 +18766,7 @@ 0033 AR958x 802.11abgn Wireless Network Adapter 168c a120 AR9582 802.11a/n WLAN Mini-PCIe Adapter 0034 AR9462 Wireless Network Adapter + 1028 020b Wireless 1601 802.11abgn Adapter 1028 0300 Wireless 1802 802.11abgn Adapter 1a56 2003 Killer Wireless-N 1202 Half-size Mini PCIe Card 0036 QCA9565 / AR9565 Wireless Network Adapter @@ -20220,7 +20276,12 @@ 1af4 1100 QEMU Virtual Machine 0006 PCI Rocker Ethernet switch device 0007 PCI SD Card Host Controller Interface + 0008 QEMU PCIe Host bridge + 0009 QEMU PCI Expander bridge 000a PCI-PCI bridge (multiseat) + 000b QEMU PCIe Expander bridge + 000c QEMU PCIe Root port + 000d QEMU XHCI Host Controller 0100 QXL paravirtual graphic card 1af4 1100 QEMU Virtual Machine 1b37 Signal Processing Devices Sweden AB @@ -20446,6 +20507,8 @@ 0006 ExaNIC X10-HPT 1cf7 Subspace Dynamics 1d00 Pure Storage +1d18 RME + 0001 Fireface UFX+ 1d1d CNEX Labs 1f1f QEMU NVM Express LightNVM Controller 2807 8800 series NVMe SSD @@ -20460,6 +20523,7 @@ 1d44 DPT a400 PM2x24/PM3224 1d49 Lenovo +1d4c Diamanti, Inc. 1d5c Fantasia Trading LLC 1d61 Technobox, Inc. 1d62 Nebbiolo Technologies @@ -21148,10 +21212,13 @@ 0001 I-30xx Scanner Interface 5555 Genroco, Inc 0003 TURBOstor HFP-832 [HiPPI NIC] + 3b00 Epiphan DVI2PCIe video capture card 5646 Vector Fabrics BV 5654 VoiceTronix Pty Ltd 5678 Dawicontrol Computersysteme GmbH 5700 Netpower +# alternately Extreme Engineering Solutions, Inc. +5845 X-ES, Inc. 584d AuzenTech Co., Ltd. 5851 Exacq Technologies 8008 tDVR8008 8-port video capture card @@ -21261,7 +21328,7 @@ 8086 1315 Centrino Wireless-N 1000 BGN 8086 1316 Centrino Wireless-N 1000 BG 0085 Centrino Advanced-N 6205 [Taylor Peak] - 8086 1311 Centrino Advanced-N 6205 AGN + 8086 1311 Centrino Advanced-N 6205 (802.11a/b/g/n) 8086 1316 Centrino Advanced-N 6205 ABG 0087 Centrino Advanced-N + WiMAX 6250 [Kilmer Peak] 8086 1301 Centrino Advanced-N + WiMAX 6250 2x2 AGN @@ -21307,6 +21374,7 @@ 1028 04da Vostro 3750 106b 00dc MacBookPro8,2 [Core i7, 15", 2011] 144d c652 NP300E5C series laptop + 17aa 21cf ThinkPad T520 0105 Xeon E3-1200/2nd Generation Core Processor Family PCI Express Root Port 106b 00dc MacBookPro8,2 [Core i7, 15", 2011] 0106 2nd Generation Core Processor Family Integrated Graphics Controller @@ -21324,6 +21392,7 @@ 0122 2nd Generation Core Processor Family Integrated Graphics Controller 0126 2nd Generation Core Processor Family Integrated Graphics Controller 1028 04cc Vostro 3350 + 17aa 21cf ThinkPad T520 0150 Xeon E3-1200 v2/3rd Gen Core processor DRAM Controller 1043 84ca P8 series motherboard 15d9 0624 X9SCM-F Motherboard @@ -22821,8 +22890,9 @@ 4c53 1090 Cx9/Vx9 mainboard 1462 82870P2 P64H2 Hot Plug Controller 1501 82567V-3 Gigabit Network Connection - 1502 82579LM Gigabit Network Connection + 1502 82579LM Gigabit Network Connection (Lewisville) 1028 04a3 Precision M4600 + 17aa 21ce ThinkPad T520 8086 357a Server Board S1200BTS 1503 82579V Gigabit Network Connection 1043 849c P8P67 Deluxe Motherboard @@ -22961,6 +23031,8 @@ 1059 0111 T4007 1GbE interface 1059 0120 T4008 1GbE interface 1059 0130 T4009 1GbE interface + 1059 0140 T2035 1GbE interface + 1059 0150 RD-01068 1GbE interface 1538 I210 Gigabit Network Connection 1539 I211 Gigabit Network Connection 153a Ethernet Connection I217-LM @@ -23021,8 +23093,8 @@ 1028 1f99 Ethernet 10G 4P X710/I350 rNDC 1028 1f9c Ethernet 10G 4P X710 SFP+ rNDC 103c 0000 Ethernet 10Gb 562SFP+ Adapter - 103c 22fc HP Ethernet 10Gb 2-port 562FLR-SFP+ Adapter - 103c 22fd HP Ethernet 10Gb 2-port 562SFP+ Adapter + 103c 22fc Ethernet 10Gb 2-port 562FLR-SFP+ Adapter + 103c 22fd Ethernet 10Gb 2-port 562SFP+ Adapter 1137 0000 Ethernet Converged NIC X710-DA 1137 013b Ethernet Converged NIC X710-DA4 1137 020a Ethernet Converged NIC X710-DA2 @@ -23044,9 +23116,11 @@ 8086 000a Ethernet Controller X710 for 10GbE SFP+ 8086 000b Ethernet Server Adapter X710-DA2 for OCP 8086 000d Ethernet Controller X710 for 10GbE SFP+ + 8086 000e Ethernet Server Adapter OCP X710-2 8086 0010 Ethernet Converged Network Adapter X710 8086 4005 Ethernet Controller X710 for 10GbE SFP+ 8086 4006 Ethernet Controller X710 for 10GbE SFP+ + 8086 4007 Ethernet Controller X710 for 10GbE SFP+ 1575 DSL6340 Thunderbolt 3 NHI [Alpine Ridge 2C 2015] 1576 DSL6340 Thunderbolt 3 Bridge [Alpine Ridge 2C 2015] 1577 DSL6540 Thunderbolt 3 NHI [Alpine Ridge 4C 2015] @@ -23060,6 +23134,7 @@ 1028 0000 Ethernet 10G X710-k bNDC 1028 1f98 Ethernet 10G 4P X710-k bNDC 1028 1f9e Ethernet 10G 2P X710-k bNDC + 1059 0150 RD-01068 10GbE-KR interface 1590 0000 Ethernet 2-port 563i Adapter 1590 00f8 Ethernet 2-port 563i Adapter 8086 0000 Ethernet Converged Network Adapter XL710-Q2 @@ -23087,8 +23162,8 @@ 108e 0000 Ethernet Controller X710 for 10GBASE-T 108e 4857 Ethernet Controller X710 for 10GBASE-T 1587 Ethernet Controller XL710 for 20GbE backplane - 103c 0000 HPE Ethernet 10/20Gb 2-port 660FLB Adapter - 103c 22fe HPE Ethernet 10/20Gb 2-port 660FLB Adapter + 103c 0000 Ethernet 10/20Gb 2-port 660FLB Adapter + 103c 22fe Ethernet 10/20Gb 2-port 660FLB Adapter 1588 Ethernet Controller XL710 for 20GbE backplane 103c 0000 Ethernet 10/20Gb 2-port 660M Adapter 103c 22ff Ethernet 10/20Gb 2-port 660M Adapter @@ -23099,6 +23174,7 @@ 8086 0001 Ethernet Converged Network Adapter X710-T4 8086 0002 Ethernet Converged Network Adapter X710-T4 8086 0003 Ethernet Converged Network Adapter X710-T + 8086 00a0 Ethernet Converged Network Adapter X710-T4 8086 1003 Ethernet Converged Network Adapter X710-T 158a Ethernet Controller XXV710 for 25GbE backplane 158b Ethernet Controller XXV710 for 25GbE SFP28 @@ -23111,6 +23187,7 @@ 8086 0006 Ethernet Network Adapter OCP XXV710-2 8086 0007 Ethernet Network Adapter OCP XXV710-1 8086 0008 Ethernet Network Adapter OCP XXV710-1 + 8086 4001 Ethernet Network Adapter XXV710-2 15a0 Ethernet Connection (2) I218-LM 15a1 Ethernet Connection (2) I218-V 15a2 Ethernet Connection (3) I218-LM @@ -23121,6 +23198,7 @@ 15a9 X552 Virtual Function 15aa Ethernet Connection X552 10 GbE Backplane 1059 0120 T4008 10GbE interface + 1059 0150 RD-01068 10GbE interface 15ab Ethernet Connection X552 10 GbE Backplane 15ac Ethernet Connection X552 10 GbE SFP+ 15ad Ethernet Connection X552/X557-AT 10GBASE-T @@ -23192,6 +23270,7 @@ 163b Broadwell-U Integrated Graphics 163d Broadwell-U Integrated Graphics 163e Broadwell-U Integrated Graphics + 1889 Ethernet Adaptive Virtual Function 1900 Skylake Host Bridge/DRAM Registers 1901 Skylake PCIe Controller (x16) 1902 HD Graphics 510 @@ -23294,37 +23373,43 @@ 1b48 82597EX 10GbE Ethernet Controller 8086 a01f PRO/10GbE LR Server Adapter 8086 a11f PRO/10GbE LR Server Adapter - 1c00 6 Series/C200 Series Chipset Family 4 port SATA IDE Controller - 1c01 6 Series/C200 Series Chipset Family 4 port SATA IDE Controller - 1c02 6 Series/C200 Series Chipset Family SATA AHCI Controller + 1c00 6 Series/C200 Series Chipset Family Desktop SATA Controller (IDE mode, ports 0-3) + 1c01 6 Series/C200 Series Chipset Family Mobile SATA Controller (IDE mode, ports 0-3) + 1c02 6 Series/C200 Series Chipset Family 6 port Desktop SATA AHCI Controller 1028 04aa XPS 8300 1043 844d P8 series motherboard 8086 7270 Server Board S1200BTS - 1c03 6 Series/C200 Series Chipset Family 6 port SATA AHCI Controller + 1c03 6 Series/C200 Series Chipset Family 6 port Mobile SATA AHCI Controller 1028 04a3 Precision M4600 1028 04b2 Vostro 3350 1028 04da Vostro 3750 + 17aa 21cf ThinkPad T520 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] - 1c04 6 Series/C200 Series Chipset Family SATA RAID Controller + 1c04 6 Series/C200 Series Desktop SATA RAID Controller 103c 3118 Smart Array B110i SATA RAID Controller - 1c05 6 Series/C200 Series Chipset Family SATA RAID Controller - 1c08 6 Series/C200 Series Chipset Family 2 port SATA IDE Controller - 1c09 6 Series/C200 Series Chipset Family 2 port SATA IDE Controller + 1c05 6 Series/C200 Series Mobile SATA RAID Controller + 1c06 Z68 Express Chipset SATA RAID Controller + 1c08 6 Series/C200 Series Chipset Family Desktop SATA Controller (IDE mode, ports 4-5) + 1c09 6 Series/C200 Series Chipset Family Mobile SATA Controller (IDE mode, ports 4-5) 1c10 6 Series/C200 Series Chipset Family PCI Express Root Port 1 1028 04aa XPS 8300 1028 04da Vostro 3750 1043 844d P8 series motherboard + 17aa 21cf ThinkPad T520 8086 7270 Server Board S1200BTS / Apple MacBook Pro 8,1/8,2 1c12 6 Series/C200 Series Chipset Family PCI Express Root Port 2 1028 04aa XPS 8300 + 17aa 21cf ThinkPad T520 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] 1c14 6 Series/C200 Series Chipset Family PCI Express Root Port 3 1028 04da Vostro 3750 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] 1c16 6 Series/C200 Series Chipset Family PCI Express Root Port 4 1028 04aa XPS 8300 + 17aa 21cf ThinkPad T520 1c18 6 Series/C200 Series Chipset Family PCI Express Root Port 5 1028 04da Vostro 3750 + 17aa 21cf ThinkPad T520 8086 7270 Server Board S1200BTS 1c1a 6 Series/C200 Series Chipset Family PCI Express Root Port 6 1028 04da Vostro 3750 @@ -23340,6 +23425,7 @@ 1028 04da Vostro 3750 1043 8418 P8P67 Deluxe Motherboard 1043 841b P8H67 Series Motherboard + 17aa 21cf ThinkPad T520 # Realtek ALC888 audio codec 8086 2008 DQ67SW board 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] @@ -23349,6 +23435,7 @@ 1028 04b2 Vostro 3350 1028 04da Vostro 3750 1043 844d P8 series motherboard + 17aa 21cf ThinkPad T520 8086 7270 Server Board S1200BTS / Apple MacBook Pro 8,1/8,2 1c24 6 Series/C200 Series Chipset Family Thermal Management Controller 1c25 6 Series/C200 Series Chipset Family DMI to PCI Bridge @@ -23358,6 +23445,7 @@ 1028 04b2 Vostro 3350 1028 04da Vostro 3750 1043 844d P8 series motherboard + 17aa 21cf ThinkPad T520 8086 7270 Server Board S1200BTS / Apple MacBook Pro 8,1/8,2 1c27 6 Series/C200 Series Chipset Family USB Universal Host Controller #1 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] @@ -23369,6 +23457,7 @@ 1028 04b2 Vostro 3350 1028 04da Vostro 3750 1043 844d P8 series motherboard + 17aa 21cf ThinkPad T520 8086 7270 Server Board S1200BTS / Apple MacBook Pro 8,1/8,2 1c33 6 Series/C200 Series Chipset Family LAN Controller 1c35 6 Series/C200 Series Chipset Family VECI Controller @@ -23378,6 +23467,7 @@ 1028 04b2 Vostro 3350 1028 04da Vostro 3750 1043 844d P8 series motherboard + 17aa 21cf ThinkPad T520 8086 7270 Apple MacBookPro8,2 [Core i7, 15", 2011] 1c3b 6 Series/C200 Series Chipset Family MEI Controller #2 1c3c 6 Series/C200 Series Chipset Family IDE-r Controller @@ -23405,6 +23495,7 @@ 1c4e Q67 Express Chipset Family LPC Controller 1c4f QM67 Express Chipset Family LPC Controller 1028 04a3 Precision M4600 + 17aa 21cf ThinkPad T520 1c50 B65 Express Chipset Family LPC Controller 1c51 6 Series/C200 Series Chipset Family LPC Controller 1c52 C202 Chipset Family LPC Controller @@ -23532,12 +23623,12 @@ 1e1e 7 Series/C210 Series Chipset Family PCI Express Root Port 8 1849 1e1e Motherboard 1e20 7 Series/C216 Chipset Family High Definition Audio Controller - 1028 054b Dell XPS One 2710 + 1028 054b XPS One 2710 1043 108d VivoBook X202EV 1043 1477 N56VZ 1043 1517 Zenbook Prime UX31A 1043 8415 P8H77-I Motherboard - 1043 8445 ASUS P8Z77-V LX Motherboard + 1043 8445 P8Z77-V LX Motherboard 144d c652 NP300E5C series laptop 1849 1898 Z77 Extreme4 motherboard 1e22 7 Series/C216 Chipset Family SMBus Controller @@ -23685,10 +23776,10 @@ 201c Sky Lake-E Non-Transparent Bridge Registers 2021 Sky Lake-E CBDMA Registers 2024 Sky Lake-E MM/Vt-d Configuration Registers - 2030 Sky Lake-E PCI Express Root Port 1A - 2031 Sky Lake-E PCI Express Root Port 1B - 2032 Sky Lake-E PCI Express Root Port 1C - 2033 Sky Lake-E PCI Express Root Port 1D + 2030 Sky Lake-E PCI Express Root Port A + 2031 Sky Lake-E PCI Express Root Port B + 2032 Sky Lake-E PCI Express Root Port C + 2033 Sky Lake-E PCI Express Root Port D 2035 Sky Lake-E RAS Configuration Registers 204c Sky Lake-E M3KTI Registers 204d Sky Lake-E M3KTI Registers @@ -24533,7 +24624,7 @@ 258a E7221 Integrated Graphics Controller 2590 Mobile 915GM/PM/GMS/910GML Express Processor to DRAM Controller 1014 0575 ThinkPad X41 / Z60t - 1028 0182 Dell Latitude C610 + 1028 0182 Latitude C610 103c 0934 Compaq nw8240/nx8220 103c 099c NX6110/NC6120 104d 81b7 Vaio VGN-S3XP @@ -24822,7 +24913,7 @@ 1014 05b7 ThinkPad Z60t # based on the PTGD1-LA motherboard 103c 2a09 PufferM-UL8E - 1043 1173 Asus A6VC + 1043 1173 A6VC 1043 814e P5GD1-VW Mainboard 1462 7028 915P/G Neo2 1af4 1100 QEMU Virtual Machine @@ -24848,7 +24939,7 @@ 1028 0177 Dimension 8400 1028 0179 Optiplex GX280 1028 0182 Latitude D610 Laptop - 1028 0187 Dell Precision M70 Laptop + 1028 0187 Precision M70 Laptop 1028 0188 Inspiron 6000 laptop 103c 0934 Compaq nw8240/nx8220 103c 0944 Compaq NC6220 @@ -25222,7 +25313,7 @@ 103c 30a3 Compaq nw8440 103c 30d5 530 Laptop 1043 1123 A6J-Q008 - 1043 13c4 Asus G2P + 1043 13c4 G2P 1043 817f P5LD2-VM Mainboard (Realtek ALC 882 codec) 1043 8290 P5KPL-VM Motherboard 1043 82ea P5KPL-CM Motherboard @@ -25240,7 +25331,7 @@ 152d 0753 Softmodem 1734 10ad Conexant softmodem SmartCP 17aa 2010 ThinkPad R60/T60/X60 series - 17aa 3802 Lenovo 3000 C200 audio [Realtek ALC861VD] + 17aa 3802 3000 C200 audio [Realtek ALC861VD] 8086 1112 DeskTop Board D945GTP 8086 27d8 DeskTop Board D945GTP 8086 d618 DeskTop Board D510MO @@ -25311,6 +25402,7 @@ 103c 30d9 Presario C700 104d 9005 Vaio VGN-FZ260E 104d 902d VAIO VGN-NR120E + 17aa 20a5 ThinkPad R61 17c0 4083 Medion WIM 2210 Notebook PC [MD96850] 2820 82801H (ICH8 Family) 4 port SATA Controller [IDE mode] 1028 01da OptiPlex 745 @@ -25337,6 +25429,7 @@ 2828 82801HM/HEM (ICH8M/ICH8M-E) SATA Controller [IDE mode] 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b + 17aa 20a8 ThinkPad R61 e4bf cc47 CCG-RUMBA 2829 82801HM/HEM (ICH8M/ICH8M-E) SATA Controller [AHCI mode] 1025 0121 Aspire 5920G @@ -25353,7 +25446,7 @@ 1028 040b Latitude E6510 e4bf 50c1 PC1-GROOVE 2830 82801H (ICH8 Family) USB UHCI Controller #1 - 1025 0121 Acer Aspire 5920G + 1025 0121 Aspire 5920G 1028 01da OptiPlex 745 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b @@ -25413,7 +25506,7 @@ 17c0 4083 Medion WIM 2210 Notebook PC [MD96850] e4bf cc47 CCG-RUMBA 2835 82801H (ICH8 Family) USB UHCI Controller #5 - 1025 0121 Acer Aspire 5920G + 1025 0121 Aspire 5920G 1028 01da OptiPlex 745 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b @@ -25441,7 +25534,7 @@ 17c0 4083 Medion WIM 2210 Notebook PC [MD96850] e4bf cc47 CCG-RUMBA 283a 82801H (ICH8 Family) USB2 EHCI Controller #2 - 1025 0121 Acer Aspire 5920G + 1025 0121 Aspire 5920G 1028 01da OptiPlex 745 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b @@ -25496,14 +25589,14 @@ 1025 0145 Realtek ALC889 (Aspire 8920G w. Dolby Theather) 1028 01da OptiPlex 745 1028 01f3 Inspiron 1420 - 1028 01f9 Dell Latitude D630 - 1028 01ff Dell Precision M4300 + 1028 01f9 Latitude D630 + 1028 01ff Precision M4300 1028 0256 Studio 1735 103c 2802 Compaq dc7700p 103c 30c0 Compaq 6710b 103c 30c1 Compaq 6910p 103c 30cc Pavilion dv6700 - 1043 1339 Asus M51S series + 1043 1339 M51S series 1043 81ec P5B 104d 9005 Vaio VGN-FZ260E 104d 9008 Vaio VGN-SZ79SN_C @@ -25843,7 +25936,7 @@ 29f7 3200/3210 Chipset Serial KT Controller 29f9 3210 Chipset Host-Secondary PCI Express Bridge 2a00 Mobile PM965/GM965/GL960 Memory Controller Hub - 1025 0121 Acer Aspire 5920G + 1025 0121 Aspire 5920G 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b 103c 30c1 Compaq 6910p @@ -25862,16 +25955,16 @@ 103c 30c0 Compaq 6710b 103c 30d9 Presario C700 104d 902d VAIO VGN-NR120E - 17aa 20b5 ThinkPad T61/R61 - 17c0 4082 Medion WIM 2210 Notebook PC [MD96850] + 17aa 20b5 GM965 [X3100] on ThinkPad T61/R61 + 17c0 4082 GM965 on Medion WIM 2210 Notebook PC [MD96850] e4bf cc47 CCG-RUMBA 2a03 Mobile GM965/GL960 Integrated Graphics Controller (secondary) 1028 01f3 Inspiron 1420 103c 30c0 Compaq 6710b 103c 30d9 Presario C700 104d 902d VAIO VGN-NR120E - 17aa 20b5 ThinkPad T61/R61 - 17c0 4082 Medion WIM 2210 Notebook PC [MD96850] + 17aa 20b5 GM965 [X3100] on ThinkPad T61/R61 + 17c0 4082 GM965 on Medion WIM 2210 Notebook PC [MD96850] e4bf cc47 CCG-RUMBA 2a04 Mobile PM965/GM965 MEI Controller 103c 30c1 Compaq 6910p @@ -26074,7 +26167,7 @@ 2e16 4 Series Chipset PT IDER Controller 2e17 4 Series Chipset Serial KT Controller 2e20 4 Series Chipset DRAM Controller - 1028 0283 Dell Vostro 220 + 1028 0283 Vostro 220 1043 82d3 P5Q Deluxe Motherboard 1458 5000 GA-EP45-DS5/GA-EG45M-DS2H Motherboard 2e21 4 Series Chipset PCI Express Root Port @@ -26585,16 +26678,20 @@ 37d1 Ethernet Connection X722 for 1GbE 1590 0216 Ethernet 1Gb 2-port 368i Adapter 1590 0217 Ethernet 1Gb 2-port 368FLR-MMT Adapter + 1590 0247 Ethernet 1Gb 4-port 369i Adapter 17aa 4020 Intel Ethernet Connection X722 for 1GbE 17aa 4021 Intel Ethernet Connection X722 for 1GbE 17aa 4022 Intel Ethernet Connection X722 for 1GbE 37d2 Ethernet Connection X722 for 10GBASE-T + 14cd 0030 Ethernet OCP 2x10G RJ45 Phy Card [USI-X557-10GbaseT] 1590 0218 Ethernet 10Gb 2-port 568FLR-MMT Adapter - 17aa 4020 Intel Ethernet Connection X722 for 10GBASE - 17aa 4021 Intel Ethernet Connection X722 for 10GBASE + 17aa 4020 Ethernet Connection X722 for 10GBASE-T + 17aa 4021 Ethernet Connection X722 for 10GBASE-T 17aa 4022 Ethernet Connection X722 for 10GBASE-T 37d3 Ethernet Connection X722 for 10GbE SFP+ 1590 0219 Ethernet 10Gb 2-port 568FLR-MMSFP+ Adapter + 17aa 4020 Ethernet Connection X722 for 10GbE SFP+ + 17aa 4021 Ethernet Connection X722 for 10GbE SFP+ 37d4 Ethernet Connection X722 for 10GbE QSFP+ 37d9 X722 Hyper-V Virtual Function 3a00 82801JD/DO (ICH10 Family) 4-port SATA IDE Controller @@ -26865,7 +26962,7 @@ 1028 02da OptiPlex 980 1028 040a Latitude E6410 1028 040b Latitude E6510 - 1043 1373 ASUSTek G73-series gaming laptop + 1043 1373 G73-series gaming laptop 144d c06a R730 Laptop 15d9 060d C7SIM-Q Motherboard 17c0 10d2 Medion Akoya E7214 Notebook PC [MD98410] @@ -27013,7 +27110,7 @@ 4224 PRO/Wireless 2915ABG [Calexico2] Network Connection 4227 PRO/Wireless 3945ABG [Golan] Network Connection 8086 1010 ThinkPad R60e - 8086 1011 ThinkPad T60/R60e/X60s + 8086 1011 ThinkPad T60/R60e/X60s/R61 8086 1014 PRO/Wireless 3945BG Network Connection 4229 PRO/Wireless 4965 AG or AGN [Kedron] Network Connection 8086 1100 Vaio VGN-SZ79SN_C @@ -27132,6 +27229,8 @@ 5845 QEMU NVM Express Controller 1af4 1100 QEMU Virtual Machine 5902 HD Graphics 610 + 590f Xeon E3-1200 v6/7th Gen Core Processor Host Bridge/DRAM Registers + 5910 Xeon E3-1200 v6/7th Gen Core Processor Host Bridge/DRAM Registers 5912 HD Graphics 630 5a84 Celeron N3350/Pentium N4200/Atom E3900 Series Integrated Graphics Controller 5a88 Celeron N3350/Pentium N4200/Atom E3900 Series Imaging Unit @@ -28223,7 +28322,7 @@ 9004 7888 AHA-2930UW SCSI Controller 8b78 ABA-1030 ec78 AHA-4944W/UW -# acquired by PMC-Sierra +# acquired by Microsemi 9005 Adaptec 0010 AHA-2940U2/U2W 9005 2180 AHA-2940U2 SCSI Controller @@ -28835,9 +28934,11 @@ f1d0 AJA Video cafe Kona SD cfee Xena LS/SD-22-DA/SD-DA daff KONA LHi + db01 Corvid22 db09 Corvid 24 dcaf Kona HD dfee Xena HD-DA + eb0e Corvid 44 efac Xena SD-MM/SD-22-MM facd Xena HD-MM f5f5 F5 Networks, Inc. From owner-svn-src-head@freebsd.org Thu May 25 21:16:40 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 82D33D82076; Thu, 25 May 2017 21:16:40 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 54D101ED6; Thu, 25 May 2017 21:16:40 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PLGdCp027598; Thu, 25 May 2017 21:16:39 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PLGdbC027596; Thu, 25 May 2017 21:16:39 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705252116.v4PLGdbC027596@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Thu, 25 May 2017 21:16:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318901 - in 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.23 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, 25 May 2017 21:16:40 -0000 Author: bapt Date: Thu May 25 21:16:39 2017 New Revision: 318901 URL: https://svnweb.freebsd.org/changeset/base/318901 Log: Remove the old man.template In FreeBSD we only use mdoc(7) format. A template is available as mdoc.template The usage of man(7) format is discouraged and this file was driving people into the front direction as a template to use. Deleted: head/share/misc/man.template Modified: head/ObsoleteFiles.inc head/share/misc/Makefile Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Thu May 25 21:11:25 2017 (r318900) +++ head/ObsoleteFiles.inc Thu May 25 21:16:39 2017 (r318901) @@ -38,6 +38,8 @@ # xargs -n1 | sort | uniq -d; # done +# 20170525: remove misleading template +OLD_FILES+=usr/share/misc/man.template # 20170525: disconnect the roff docs from the build OLD_FILES+=usr/share/doc/papers/beyond43.ascii.gz OLD_FILES+=usr/share/doc/papers/bio.ascii.gz Modified: head/share/misc/Makefile ============================================================================== --- head/share/misc/Makefile Thu May 25 21:11:25 2017 (r318900) +++ head/share/misc/Makefile Thu May 25 21:16:39 2017 (r318901) @@ -7,7 +7,7 @@ FILES= ascii birthtoken bsd-family-tree committers-doc.dot committers-ports.dot \ committers-src.dot eqnchar flowers init.ee \ - iso3166 iso639 latin1 man.template mdoc.template operator pci_vendors \ + iso3166 iso639 latin1 mdoc.template operator pci_vendors \ scsi_modes \ organization.dot From owner-svn-src-head@freebsd.org Thu May 25 21:41:08 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A29F1D826DE; Thu, 25 May 2017 21:41:08 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 723BB1C53; Thu, 25 May 2017 21:41:08 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PLf7Mb038185; Thu, 25 May 2017 21:41:07 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PLf6xk038179; Thu, 25 May 2017 21:41:06 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705252141.v4PLf6xk038179@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Thu, 25 May 2017 21:41:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318902 - in head/usr.sbin/makefs: . ffs 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.23 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, 25 May 2017 21:41:08 -0000 Author: emaste Date: Thu May 25 21:41:06 2017 New Revision: 318902 URL: https://svnweb.freebsd.org/changeset/base/318902 Log: makefs: make buf generic it has nothing to do with ffs and will eventually be moved. gc sectorsize. This is a corrected version of r317744. NetBSD versions: ffs.c 1.58 ffs/buf.c 1.14 1.18 ffs/buf.h 1.8 Submitted by: Siva Mahadevan Obtained from: NetBSD Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10803 Modified: head/usr.sbin/makefs/ffs.c head/usr.sbin/makefs/ffs/buf.c head/usr.sbin/makefs/ffs/buf.h head/usr.sbin/makefs/ffs/ffs_alloc.c head/usr.sbin/makefs/ffs/ffs_balloc.c head/usr.sbin/makefs/ffs/ufs_inode.h Modified: head/usr.sbin/makefs/ffs.c ============================================================================== --- head/usr.sbin/makefs/ffs.c Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs.c Thu May 25 21:41:06 2017 (r318902) @@ -143,7 +143,6 @@ static void *ffs_build_dinode2(struct u fsnode *, fsinfo_t *); -int sectorsize; /* XXX: for buf.c::getblk() */ /* publicly visible functions */ void @@ -429,8 +428,6 @@ ffs_validate(const char *dir, fsnode *ro printf("ffs_validate: dir %s; %lld bytes, %lld inodes\n", dir, (long long)fsopts->size, (long long)fsopts->inodes); } - sectorsize = fsopts->sectorsize; /* XXX - see earlier */ - /* now check calculated sizes vs requested sizes */ if (fsopts->maxsize > 0 && fsopts->size > fsopts->maxsize) { errx(1, "`%s' size of %lld is larger than the maxsize of %lld.", @@ -480,13 +477,13 @@ ffs_create_image(const char *image, fsin int i, bufsize; off_t bufrem; time_t tstamp; + int oflags = O_RDWR | O_CREAT | O_TRUNC; assert (image != NULL); assert (fsopts != NULL); /* create image */ - if ((fsopts->fd = open(image, O_RDWR | O_CREAT | O_TRUNC, 0666)) - == -1) { + if ((fsopts->fd = open(image, oflags, 0666)) == -1) { warn("Can't open `%s' for writing", image); return (-1); } @@ -878,6 +875,7 @@ ffs_write_file(union dinode *din, uint32 struct inode in; struct buf * bp; ffs_opt_t *ffs_opts = fsopts->fs_specific; + struct vnode vp = { fsopts, NULL }; assert (din != NULL); assert (buf != NULL); @@ -890,6 +888,7 @@ ffs_write_file(union dinode *din, uint32 p = NULL; in.i_fs = (struct fs *)fsopts->superblock; + in.i_devvp = &vp; if (debug & DEBUG_FS_WRITE_FILE) { printf( @@ -910,7 +909,6 @@ ffs_write_file(union dinode *din, uint32 else memcpy(&in.i_din.ffs2_din, &din->ffs2_din, sizeof(in.i_din.ffs2_din)); - in.i_fd = fsopts->fd; if (DIP(din, size) == 0) goto write_inode_and_leave; /* mmm, cheating */ Modified: head/usr.sbin/makefs/ffs/buf.c ============================================================================== --- head/usr.sbin/makefs/ffs/buf.c Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs/buf.c Thu May 25 21:41:06 2017 (r318902) @@ -52,8 +52,6 @@ __FBSDID("$FreeBSD$"); #include "makefs.h" #include "buf.h" -extern int sectorsize; /* XXX: from ffs.c & mkfs.c */ - static TAILQ_HEAD(buftailhead,buf) buftail; int @@ -62,6 +60,7 @@ bread(struct vnode *vp, daddr_t blkno, i { off_t offset; ssize_t rv; + fsinfo_t *fsinfo = vp->fs; assert (bpp != NULL); @@ -69,15 +68,15 @@ bread(struct vnode *vp, daddr_t blkno, i printf("%s: blkno %lld size %d\n", __func__, (long long)blkno, size); *bpp = getblk(vp, blkno, size, 0, 0, 0); - offset = (*bpp)->b_blkno * sectorsize; /* XXX */ + offset = (*bpp)->b_blkno * fsinfo->sectorsize; if (debug & DEBUG_BUF_BREAD) printf("%s: blkno %lld offset %lld bcount %ld\n", __func__, (long long)(*bpp)->b_blkno, (long long) offset, (*bpp)->b_bcount); - if (lseek((*bpp)->b_fd, offset, SEEK_SET) == -1) + if (lseek((*bpp)->b_fs->fd, offset, SEEK_SET) == -1) err(1, "%s: lseek %lld (%lld)", __func__, (long long)(*bpp)->b_blkno, (long long)offset); - rv = read((*bpp)->b_fd, (*bpp)->b_data, (*bpp)->b_bcount); + rv = read((*bpp)->b_fs->fd, (*bpp)->b_data, (*bpp)->b_bcount); if (debug & DEBUG_BUF_BREAD) printf("%s: read %ld (%lld) returned %d\n", __func__, (*bpp)->b_bcount, (long long)offset, (int)rv); @@ -126,16 +125,17 @@ bwrite(struct buf *bp) { off_t offset; ssize_t rv; + fsinfo_t *fs = bp->b_fs; assert (bp != NULL); - offset = bp->b_blkno * sectorsize; /* XXX */ + offset = bp->b_blkno * fs->sectorsize; if (debug & DEBUG_BUF_BWRITE) printf("bwrite: blkno %lld offset %lld bcount %ld\n", (long long)bp->b_blkno, (long long) offset, bp->b_bcount); - if (lseek(bp->b_fd, offset, SEEK_SET) == -1) + if (lseek(bp->b_fs->fd, offset, SEEK_SET) == -1) return (errno); - rv = write(bp->b_fd, bp->b_data, bp->b_bcount); + rv = write(bp->b_fs->fd, bp->b_data, bp->b_bcount); if (debug & DEBUG_BUF_BWRITE) printf("bwrite: write %ld (offset %lld) returned %lld\n", bp->b_bcount, (long long)offset, (long long)rv); @@ -198,7 +198,6 @@ getblk(struct vnode *vp, daddr_t blkno, bp = ecalloc(1, sizeof(*bp)); bp->b_bufsize = 0; bp->b_blkno = bp->b_lblkno = blkno; - bp->b_fd = vp->fd; bp->b_fs = vp->fs; bp->b_data = NULL; TAILQ_INSERT_HEAD(&buftail, bp, b_tailq); Modified: head/usr.sbin/makefs/ffs/buf.h ============================================================================== --- head/usr.sbin/makefs/ffs/buf.h Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs/buf.h Thu May 25 21:41:06 2017 (r318902) @@ -43,13 +43,12 @@ #include #include +struct makefs_fsinfo; struct ucred; struct vnode { - int fd; - void *fs; + struct makefs_fsinfo *fs; void *v_data; - int offset; }; struct buf { @@ -58,8 +57,7 @@ struct buf { long b_bcount; daddr_t b_blkno; daddr_t b_lblkno; - int b_fd; - void * b_fs; + struct makefs_fsinfo *b_fs; TAILQ_ENTRY(buf) b_tailq; }; Modified: head/usr.sbin/makefs/ffs/ffs_alloc.c ============================================================================== --- head/usr.sbin/makefs/ffs/ffs_alloc.c Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs/ffs_alloc.c Thu May 25 21:41:06 2017 (r318902) @@ -297,11 +297,10 @@ ffs_alloccg(struct inode *ip, int cg, da int error, frags, allocsiz, i; struct fs *fs = ip->i_fs; const int needswap = UFS_FSNEEDSWAP(fs); - struct vnode vp = { ip->i_fd, ip->i_fs, NULL, 0 }; if (fs->fs_cs(fs, cg).cs_nbfree == 0 && size == fs->fs_bsize) return (0); - error = bread(&vp, fsbtodb(fs, cgtod(fs, cg)), (int)fs->fs_cgsize, + error = bread(ip->i_devvp, fsbtodb(fs, cgtod(fs, cg)), (int)fs->fs_cgsize, NULL, &bp); if (error) { brelse(bp, 0); @@ -433,7 +432,6 @@ ffs_blkfree(struct inode *ip, daddr_t bn int i, error, cg, blk, frags, bbase; struct fs *fs = ip->i_fs; const int needswap = UFS_FSNEEDSWAP(fs); - struct vnode vp = { ip->i_fd, ip->i_fs, NULL, 0 }; if (size > fs->fs_bsize || fragoff(fs, size) != 0 || fragnum(fs, bno) + numfrags(fs, size) > fs->fs_frag) { @@ -446,7 +444,7 @@ ffs_blkfree(struct inode *ip, daddr_t bn (uintmax_t)ip->i_number); return; } - error = bread(&vp, fsbtodb(fs, cgtod(fs, cg)), (int)fs->fs_cgsize, + error = bread(ip->i_devvp, fsbtodb(fs, cgtod(fs, cg)), (int)fs->fs_cgsize, NULL, &bp); if (error) { brelse(bp, 0); Modified: head/usr.sbin/makefs/ffs/ffs_balloc.c ============================================================================== --- head/usr.sbin/makefs/ffs/ffs_balloc.c Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs/ffs_balloc.c Thu May 25 21:41:06 2017 (r318902) @@ -89,7 +89,6 @@ ffs_balloc_ufs1(struct inode *ip, off_t int32_t *allocblk, allociblk[UFS_NIADDR + 1]; int32_t *allocib; const int needswap = UFS_FSNEEDSWAP(fs); - struct vnode vp = { ip->i_fd, ip->i_fs, NULL, 0 }; lbn = lblkno(fs, offset); size = blkoff(fs, offset) + bufsize; @@ -134,8 +133,8 @@ ffs_balloc_ufs1(struct inode *ip, off_t */ if (bpp != NULL) { - error = bread(&vp, lbn, fs->fs_bsize, NULL, - bpp); + error = bread(ip->i_devvp, lbn, fs->fs_bsize, + NULL, bpp); if (error) { brelse(*bpp, 0); return (error); @@ -160,8 +159,8 @@ ffs_balloc_ufs1(struct inode *ip, off_t */ if (bpp != NULL) { - error = bread(&vp, lbn, osize, NULL, - bpp); + error = bread(ip->i_devvp, lbn, osize, + NULL, bpp); if (error) { brelse(*bpp, 0); return (error); @@ -190,7 +189,7 @@ ffs_balloc_ufs1(struct inode *ip, off_t if (error) return (error); if (bpp != NULL) { - bp = getblk(&vp, lbn, nsize, 0, 0, 0); + bp = getblk(ip->i_devvp, lbn, nsize, 0, 0, 0); bp->b_blkno = fsbtodb(fs, newb); clrbuf(bp); *bpp = bp; @@ -228,7 +227,7 @@ ffs_balloc_ufs1(struct inode *ip, off_t return error; nb = newb; *allocblk++ = nb; - bp = getblk(&vp, indirs[1].in_lbn, fs->fs_bsize, 0, 0, 0); + bp = getblk(ip->i_devvp, indirs[1].in_lbn, fs->fs_bsize, 0, 0, 0); bp->b_blkno = fsbtodb(fs, nb); clrbuf(bp); /* @@ -246,7 +245,8 @@ ffs_balloc_ufs1(struct inode *ip, off_t */ for (i = 1;;) { - error = bread(&vp, indirs[i].in_lbn, fs->fs_bsize, NULL, &bp); + error = bread(ip->i_devvp, indirs[i].in_lbn, fs->fs_bsize, + NULL, &bp); if (error) { brelse(bp, 0); return error; @@ -269,7 +269,7 @@ ffs_balloc_ufs1(struct inode *ip, off_t } nb = newb; *allocblk++ = nb; - nbp = getblk(&vp, indirs[i].in_lbn, fs->fs_bsize, 0, 0, 0); + nbp = getblk(ip->i_devvp, indirs[i].in_lbn, fs->fs_bsize, 0, 0, 0); nbp->b_blkno = fsbtodb(fs, nb); clrbuf(nbp); /* @@ -300,7 +300,7 @@ ffs_balloc_ufs1(struct inode *ip, off_t nb = newb; *allocblk++ = nb; if (bpp != NULL) { - nbp = getblk(&vp, lbn, fs->fs_bsize, 0, 0, 0); + nbp = getblk(ip->i_devvp, lbn, fs->fs_bsize, 0, 0, 0); nbp->b_blkno = fsbtodb(fs, nb); clrbuf(nbp); *bpp = nbp; @@ -316,7 +316,7 @@ ffs_balloc_ufs1(struct inode *ip, off_t } brelse(bp, 0); if (bpp != NULL) { - error = bread(&vp, lbn, (int)fs->fs_bsize, NULL, &nbp); + error = bread(ip->i_devvp, lbn, (int)fs->fs_bsize, NULL, &nbp); if (error) { brelse(nbp, 0); return error; @@ -340,7 +340,6 @@ ffs_balloc_ufs2(struct inode *ip, off_t int64_t *allocblk, allociblk[UFS_NIADDR + 1]; int64_t *allocib; const int needswap = UFS_FSNEEDSWAP(fs); - struct vnode vp = { ip->i_fd, ip->i_fs, NULL, 0 }; lbn = lblkno(fs, offset); size = blkoff(fs, offset) + bufsize; @@ -385,8 +384,8 @@ ffs_balloc_ufs2(struct inode *ip, off_t */ if (bpp != NULL) { - error = bread(&vp, lbn, fs->fs_bsize, NULL, - bpp); + error = bread(ip->i_devvp, lbn, fs->fs_bsize, + NULL, bpp); if (error) { brelse(*bpp, 0); return (error); @@ -411,8 +410,8 @@ ffs_balloc_ufs2(struct inode *ip, off_t */ if (bpp != NULL) { - error = bread(&vp, lbn, osize, NULL, - bpp); + error = bread(ip->i_devvp, lbn, osize, + NULL, bpp); if (error) { brelse(*bpp, 0); return (error); @@ -441,7 +440,7 @@ ffs_balloc_ufs2(struct inode *ip, off_t if (error) return (error); if (bpp != NULL) { - bp = getblk(&vp, lbn, nsize, 0, 0, 0); + bp = getblk(ip->i_devvp, lbn, nsize, 0, 0, 0); bp->b_blkno = fsbtodb(fs, newb); clrbuf(bp); *bpp = bp; @@ -479,7 +478,7 @@ ffs_balloc_ufs2(struct inode *ip, off_t return error; nb = newb; *allocblk++ = nb; - bp = getblk(&vp, indirs[1].in_lbn, fs->fs_bsize, 0, 0, 0); + bp = getblk(ip->i_devvp, indirs[1].in_lbn, fs->fs_bsize, 0, 0, 0); bp->b_blkno = fsbtodb(fs, nb); clrbuf(bp); /* @@ -497,7 +496,8 @@ ffs_balloc_ufs2(struct inode *ip, off_t */ for (i = 1;;) { - error = bread(&vp, indirs[i].in_lbn, fs->fs_bsize, NULL, &bp); + error = bread(ip->i_devvp, indirs[i].in_lbn, fs->fs_bsize, + NULL, &bp); if (error) { brelse(bp, 0); return error; @@ -520,7 +520,7 @@ ffs_balloc_ufs2(struct inode *ip, off_t } nb = newb; *allocblk++ = nb; - nbp = getblk(&vp, indirs[i].in_lbn, fs->fs_bsize, 0, 0, 0); + nbp = getblk(ip->i_devvp, indirs[i].in_lbn, fs->fs_bsize, 0, 0, 0); nbp->b_blkno = fsbtodb(fs, nb); clrbuf(nbp); /* @@ -551,7 +551,7 @@ ffs_balloc_ufs2(struct inode *ip, off_t nb = newb; *allocblk++ = nb; if (bpp != NULL) { - nbp = getblk(&vp, lbn, fs->fs_bsize, 0, 0, 0); + nbp = getblk(ip->i_devvp, lbn, fs->fs_bsize, 0, 0, 0); nbp->b_blkno = fsbtodb(fs, nb); clrbuf(nbp); *bpp = nbp; @@ -567,7 +567,7 @@ ffs_balloc_ufs2(struct inode *ip, off_t } brelse(bp, 0); if (bpp != NULL) { - error = bread(&vp, lbn, (int)fs->fs_bsize, NULL, &nbp); + error = bread(ip->i_devvp, lbn, (int)fs->fs_bsize, NULL, &nbp); if (error) { brelse(nbp, 0); return error; Modified: head/usr.sbin/makefs/ffs/ufs_inode.h ============================================================================== --- head/usr.sbin/makefs/ffs/ufs_inode.h Thu May 25 21:16:39 2017 (r318901) +++ head/usr.sbin/makefs/ffs/ufs_inode.h Thu May 25 21:41:06 2017 (r318902) @@ -45,9 +45,9 @@ union dinode { struct inode { ino_t i_number; /* The identity of the inode. */ + struct vnode *i_devvp; /* vnode pointer (contains fsopts) */ struct fs *i_fs; /* File system */ union dinode i_din; - int i_fd; /* File descriptor */ uint64_t i_size; }; From owner-svn-src-head@freebsd.org Thu May 25 21:59:20 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 784DED82A6B; Thu, 25 May 2017 21:59:20 +0000 (UTC) (envelope-from phk@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5555415F1; Thu, 25 May 2017 21:59:20 +0000 (UTC) (envelope-from phk@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PLxJDQ044262; Thu, 25 May 2017 21:59:19 GMT (envelope-from phk@FreeBSD.org) Received: (from phk@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PLxJ2a044261; Thu, 25 May 2017 21:59:19 GMT (envelope-from phk@FreeBSD.org) Message-Id: <201705252159.v4PLxJ2a044261@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: phk set sender to phk@FreeBSD.org using -f From: Poul-Henning Kamp Date: Thu, 25 May 2017 21:59:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318903 - head/tools/tools/sysbuild 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.23 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, 25 May 2017 21:59:20 -0000 Author: phk Date: Thu May 25 21:59:19 2017 New Revision: 318903 URL: https://svnweb.freebsd.org/changeset/base/318903 Log: Try to keep up with the ports system Makefiles. Modified: head/tools/tools/sysbuild/sysbuild.sh Modified: head/tools/tools/sysbuild/sysbuild.sh ============================================================================== --- head/tools/tools/sysbuild/sysbuild.sh Thu May 25 21:41:06 2017 (r318902) +++ head/tools/tools/sysbuild/sysbuild.sh Thu May 25 21:59:19 2017 (r318903) @@ -95,6 +95,9 @@ PORTS_WE_WANT=' PORTS_OPTS="BATCH=YES A4=yes" +PORTS_WITHOUT="" +PORTS_WITH="" + CONFIGFILES=' ' @@ -174,6 +177,9 @@ log_it() ( ####################################################################### +ports_make() { + make $* WITH="${PORTS_WITH}" WITHOUT="${PORTS_WITHOUT}" ${PORTS_OPTS} +} ports_recurse() ( cd /usr/ports @@ -191,7 +197,7 @@ ports_recurse() ( for d do if [ ! -d $d ] ; then - echo "Missing port $d" 1>&2 + echo "Missing port $d ($t)" 1>&2 continue fi d=`cd /usr/ports && cd $d && /bin/pwd` @@ -210,15 +216,12 @@ ports_recurse() ( ( cd $d l="" - for a in `make -V _UNIFIED_DEPENDS ${PORTS_OPTS}` + for a in `ports_make -V _UNIFIED_DEPENDS` do x=`expr "$a" : '.*:\(.*\)'` l="${l} ${x}" done ports_recurse $d $l - # -> _UNIFIED_DEPENDS - #ports_recurse $d `make -V _DEPEND_DIRS ${PORTS_OPTS}` - #ports_recurse $d `make all-depends-list` ) echo "$d" >> /tmp/_.plist fi @@ -242,14 +245,14 @@ ports_build() ( do b=`echo $p | tr / _` t=`echo $p | sed "s,${pd},,"` - pn=`cd $p && make package-name ${PORTS_OPTS}` + pn=`cd $p && ports_make package-name` if [ "x`basename $p`" == "xpkg" ] ; then log_it "Very Special: $t ($pn)" ( cd $p - make clean all install ${PORTS_OPTS} + ports_make clean all install ) > _.$b 2>&1 < /dev/null continue fi @@ -270,7 +273,7 @@ ports_build() ( fi fi - miss=`(cd $p ; make missing ${PORTS_OPTS}) || true` + miss=`(cd $p ; ports_make missing) || true` if [ "x${miss}" != "x" ] ; then log_it "NB: MISSING for $p:" $miss @@ -280,15 +283,16 @@ ports_build() ( ( set +e cd $p - make clean ${PORTS_OPTS} - if make install ${PORTS_OPTS} ; then + ports_make clean + if ports_make install ; then if [ "x${PKG_DIR}" != "x" ] ; then - make package ${PORTS_OPTS} + ports_make package fi else log_it FAIL build $p fi - make clean ${PORTS_OPTS} + ports_make clean + ) > _.$b 2>&1 < /dev/null done ) @@ -309,15 +313,15 @@ ports_prefetch() ( b=`echo $p | tr / _` ( cd $p - if make checksum $PORTS_OPTS ; then + if ports_make checksum ; then rm -f /${ldir}/_.prefetch.$b echo "OK $p" >> /${ldir}/_.prefetch exit 0 fi - make distclean - make checksum $PORTS_OPTS || true + ports_make distclean + ports_make checksum || true - if make checksum $PORTS_OPTS > /dev/null 2>&1 ; then + if ports_make checksum > /dev/null 2>&1 ; then rm -f /${ldir}/_.prefetch.$b echo "OK $p" >> /${ldir}/_.prefetch else @@ -472,8 +476,7 @@ ln -s /freebsd/${SRC_PATH} /usr/src if $do_world ; then if [ "x${OBJ_PATH}" != "x" ] ; then rm -rf /usr/obj - mkdir -p /freebsd/${OBJ_PATH} - ln -s /freebsd/${OBJ_PATH} /usr/obj + (cd /freebsd && mkdir -p ${OBJ_PATH} && ln -s ${OBJ_PATH} /usr/obj) else rm -rf /usr/obj mkdir -p /usr/obj @@ -493,8 +496,8 @@ do ) done -export PORTS_WE_WANT -export PORTS_OPTS +#export PORTS_WE_WANT +#export PORTS_OPTS ####################################################################### @@ -548,7 +551,7 @@ log_it Installkernel if [ "x${OBJ_PATH}" != "x" ] ; then rmdir ${SBMNT}/usr/obj - ln -s /freebsd/${OBJ_PATH} ${SBMNT}/usr/obj + ( cd /freebsd && mkdir -p ${OBJ_PATH} && ln -s ${OBJ_PATH} ${SBMNT}/usr/obj ) fi log_it Wait for ports prefetch From owner-svn-src-head@freebsd.org Thu May 25 23:14:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E1815D810FE; Thu, 25 May 2017 23:14:52 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 89E89197D; Thu, 25 May 2017 23:14:52 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PNEpW5076249; Thu, 25 May 2017 23:14:51 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PNEpi9076248; Thu, 25 May 2017 23:14:51 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705252314.v4PNEpi9076248@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Thu, 25 May 2017 23:14:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318906 - head/contrib/llvm/lib/Target/PowerPC 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.23 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, 25 May 2017 23:14:53 -0000 Author: dim Date: Thu May 25 23:14:51 2017 New Revision: 318906 URL: https://svnweb.freebsd.org/changeset/base/318906 Log: Pull in r303257 from upstream llvm trunk (by Krzysztof Parzyszek) [PPC] Properly update register save area offsets The variables MinGPR/MinG8R were not updated properly when resetting the offsets, which in the included testcase lead to saving the CR register in the same location as R30. This fixes another issue reported in PR26519. Differential Revision: https://reviews.llvm.org/D33017 Reported by: Mark Millard PR: 206990 MFC after: 3 days Modified: head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp Modified: head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp ============================================================================== --- head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp Thu May 25 22:41:34 2017 (r318905) +++ head/contrib/llvm/lib/Target/PowerPC/PPCFrameLowering.cpp Thu May 25 23:14:51 2017 (r318906) @@ -1775,32 +1775,37 @@ void PPCFrameLowering::processFunctionBe // Check whether the frame pointer register is allocated. If so, make sure it // is spilled to the correct offset. if (needsFP(MF)) { - HasGPSaveArea = true; - int FI = PFI->getFramePointerSaveIndex(); assert(FI && "No Frame Pointer Save Slot!"); - MFI.setObjectOffset(FI, LowerBound + MFI.getObjectOffset(FI)); + // FP is R31/X31, so no need to update MinGPR/MinG8R. + HasGPSaveArea = true; } if (PFI->usesPICBase()) { - HasGPSaveArea = true; - int FI = PFI->getPICBasePointerSaveIndex(); assert(FI && "No PIC Base Pointer Save Slot!"); - MFI.setObjectOffset(FI, LowerBound + MFI.getObjectOffset(FI)); + + MinGPR = std::min(MinGPR, PPC::R30); + HasGPSaveArea = true; } const PPCRegisterInfo *RegInfo = static_cast(Subtarget.getRegisterInfo()); if (RegInfo->hasBasePointer(MF)) { - HasGPSaveArea = true; - int FI = PFI->getBasePointerSaveIndex(); assert(FI && "No Base Pointer Save Slot!"); - MFI.setObjectOffset(FI, LowerBound + MFI.getObjectOffset(FI)); + + unsigned BP = RegInfo->getBaseRegister(MF); + if (PPC::G8RCRegClass.contains(BP)) { + MinG8R = std::min(MinG8R, BP); + HasG8SaveArea = true; + } else if (PPC::GPRCRegClass.contains(BP)) { + MinGPR = std::min(MinGPR, BP); + HasGPSaveArea = true; + } } // General register save area starts right below the Floating-point From owner-svn-src-head@freebsd.org Thu May 25 23:19:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B20DFD8130B; Thu, 25 May 2017 23:19:10 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6B47B1BF6; Thu, 25 May 2017 23:19:10 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4PNJ9pv076448; Thu, 25 May 2017 23:19:09 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4PNJ9Ps076446; Thu, 25 May 2017 23:19:09 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201705252319.v4PNJ9Ps076446@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Thu, 25 May 2017 23:19:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318907 - 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.23 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, 25 May 2017 23:19:10 -0000 Author: mav Date: Thu May 25 23:19:09 2017 New Revision: 318907 URL: https://svnweb.freebsd.org/changeset/base/318907 Log: Remove some code, dead from the day one. Modified: head/sys/net/if_lagg.c head/sys/net/if_lagg.h Modified: head/sys/net/if_lagg.c ============================================================================== --- head/sys/net/if_lagg.c Thu May 25 23:14:51 2017 (r318906) +++ head/sys/net/if_lagg.c Thu May 25 23:19:09 2017 (r318907) @@ -1773,7 +1773,6 @@ struct lagg_port * lagg_link_active(struct lagg_softc *sc, struct lagg_port *lp) { struct lagg_port *lp_next, *rval = NULL; - // int new_link = LINK_STATE_DOWN; /* * Search a port which reports an active link state. @@ -1800,22 +1799,6 @@ search: } found: - if (rval != NULL) { - /* - * The IEEE 802.1D standard assumes that a lagg with - * multiple ports is always full duplex. This is valid - * for load sharing laggs and if at least two links - * are active. Unfortunately, checking the latter would - * be too expensive at this point. - XXX - if ((sc->sc_capabilities & IFCAP_LAGG_FULLDUPLEX) && - (sc->sc_count > 1)) - new_link = LINK_STATE_FULL_DUPLEX; - else - new_link = rval->lp_link_state; - */ - } - return (rval); } @@ -1832,7 +1815,6 @@ lagg_enqueue(struct ifnet *ifp, struct m static void lagg_rr_attach(struct lagg_softc *sc) { - sc->sc_capabilities = IFCAP_LAGG_FULLDUPLEX; sc->sc_seq = 0; sc->sc_bkt_count = sc->sc_bkt; } @@ -2001,9 +1983,6 @@ lagg_lb_attach(struct lagg_softc *sc) struct lagg_lb *lb; lb = malloc(sizeof(struct lagg_lb), M_DEVBUF, M_WAITOK | M_ZERO); - - sc->sc_capabilities = IFCAP_LAGG_FULLDUPLEX; - lb->lb_key = m_ether_tcpip_hash_init(); sc->sc_psc = lb; Modified: head/sys/net/if_lagg.h ============================================================================== --- head/sys/net/if_lagg.h Thu May 25 23:14:51 2017 (r318906) +++ head/sys/net/if_lagg.h Thu May 25 23:19:09 2017 (r318907) @@ -185,10 +185,6 @@ struct lagg_ifreq { #define sc_ifflags sc_ifp->if_flags /* flags */ #define sc_ifname sc_ifp->if_xname /* name */ -#define sc_capabilities sc_ifp->if_capabilities /* capabilities */ - -#define IFCAP_LAGG_MASK 0xffff0000 /* private capabilities */ -#define IFCAP_LAGG_FULLDUPLEX 0x00010000 /* full duplex with >1 ports */ /* Private data used by the loadbalancing protocol */ struct lagg_lb { From owner-svn-src-head@freebsd.org Fri May 26 00:19:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 00311D7A711; Fri, 26 May 2017 00:19:51 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A8D0E17CF; Fri, 26 May 2017 00:19:51 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q0Joua000731; Fri, 26 May 2017 00:19:50 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q0JoOw000730; Fri, 26 May 2017 00:19:50 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705260019.v4Q0JoOw000730@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 00:19:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318908 - head/contrib/netbsd-tests/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.23 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, 26 May 2017 00:19:52 -0000 Author: emaste Date: Fri May 26 00:19:50 2017 New Revision: 318908 URL: https://svnweb.freebsd.org/changeset/base/318908 Log: bsdgrep: add --mmap tests Basic sanity tests as well as coverage for the bug fixed in r318565. Submitted by: Kyle Evans Reviewed by: bapt, ngie Differential Revision: https://reviews.freebsd.org/D10827 Modified: head/contrib/netbsd-tests/usr.bin/grep/t_grep.sh Modified: head/contrib/netbsd-tests/usr.bin/grep/t_grep.sh ============================================================================== --- head/contrib/netbsd-tests/usr.bin/grep/t_grep.sh Thu May 25 23:19:09 2017 (r318907) +++ head/contrib/netbsd-tests/usr.bin/grep/t_grep.sh Fri May 26 00:19:50 2017 (r318908) @@ -627,6 +627,46 @@ binary_flags_body() atf_check -o inline:"A\000B\000C\n" grep --binary-files=text 'B' test1 atf_check -s exit:1 grep --binary-files=without-match 'B' test2 } + +atf_test_case mmap +mmap_head() +{ + atf_set "descr" "Check basic matching with --mmap flag" +} +mmap_body() +{ + grep_type + if [ $? -eq $GREP_TYPE_GNU ]; then + atf_expect_fail "gnu grep from ports has no --mmap option" + fi + + printf "A\nB\nC\n" > test1 + + atf_check -s exit:0 -o inline:"B\n" grep --mmap -oe "B" test1 + atf_check -s exit:1 grep --mmap -e "Z" test1 +} + +atf_test_case mmap_eof_not_eol +mmap_eof_not_eol_head() +{ + atf_set "descr" "Check --mmap flag handling of encountering EOF without EOL (PR 165471, 219402)" +} +mmap_eof_not_eol_body() +{ + grep_type + if [ $? -eq $GREP_TYPE_GNU ]; then + atf_expect_fail "gnu grep from ports has no --mmap option" + fi + + printf "ABC" > test1 + jot -b " " -s "" 4096 >> test2 + + atf_check -s exit:0 -o inline:"B\n" grep --mmap -oe "B" test1 + # Dependency on jemalloc(3) to detect buffer overflow, otherwise this + # unreliably produces a SIGSEGV or SIGBUS + atf_check -s exit:0 -o not-empty \ + env MALLOC_CONF="redzone:true" grep --mmap -e " " test2 +} # End FreeBSD atf_init_test_cases() @@ -665,5 +705,7 @@ atf_init_test_cases() atf_add_test_case grep_nomatch_flags atf_add_test_case binary_flags atf_add_test_case badcontext + atf_add_test_case mmap + atf_add_test_case mmap_eof_not_eol # End FreeBSD } From owner-svn-src-head@freebsd.org Fri May 26 00:48:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 11C55D824AC; Fri, 26 May 2017 00:48:23 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D624B1956; Fri, 26 May 2017 00:48:22 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q0mLWU013150; Fri, 26 May 2017 00:48:21 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q0mLTL013149; Fri, 26 May 2017 00:48:21 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201705260048.v4Q0mLTL013149@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Fri, 26 May 2017 00:48:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318911 - 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.23 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, 26 May 2017 00:48:23 -0000 Author: adrian Date: Fri May 26 00:48:21 2017 New Revision: 318911 URL: https://svnweb.freebsd.org/changeset/base/318911 Log: [ath] fix short-GI wireshark flag. Yes, HAL_RX_GI means "short guard interval." Modified: head/sys/dev/ath/if_ath_rx.c Modified: head/sys/dev/ath/if_ath_rx.c ============================================================================== --- head/sys/dev/ath/if_ath_rx.c Fri May 26 00:26:08 2017 (r318910) +++ head/sys/dev/ath/if_ath_rx.c Fri May 26 00:48:21 2017 (r318911) @@ -593,7 +593,8 @@ ath_rx_tap(struct ath_softc *sc, struct sc->sc_rx_th.wr_chan_flags |= CHAN_HT40U; else sc->sc_rx_th.wr_chan_flags |= CHAN_HT40D; - if ((rs->rs_flags & HAL_RX_GI) == 0) + + if (rs->rs_flags & HAL_RX_GI) sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_SHORTGI; } From owner-svn-src-head@freebsd.org Fri May 26 00:51:06 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F253D82595; Fri, 26 May 2017 00:51:06 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 311B31B44; Fri, 26 May 2017 00:51:06 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q0p5uR013301; Fri, 26 May 2017 00:51:05 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q0p5XM013300; Fri, 26 May 2017 00:51:05 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705260051.v4Q0p5XM013300@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 00:51:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318912 - 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.23 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, 26 May 2017 00:51:06 -0000 Author: emaste Date: Fri May 26 00:51:05 2017 New Revision: 318912 URL: https://svnweb.freebsd.org/changeset/base/318912 Log: libc: rm stale generated files which are no longer syscalls This is an attempt to help -DNO_CLEAN builds after r302092 (which removed the pipe libc syscall wrapper) and r318736 (which removed getdents, lstat, mknod, and stat). Dependencies cannot cope with certain source tree changes, particularly with respect to removing source files and replacing generated files. Handle these cases from _worldtmp in an ad-hoc fashion. Reviewed by: bdrewery, cem Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10876 Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Fri May 26 00:48:21 2017 (r318911) +++ head/Makefile.inc1 Fri May 26 00:51:05 2017 (r318912) @@ -707,6 +707,21 @@ _worldtmp: .PHONY .else rm -rf ${WORLDTMP}/legacy/usr/include .endif +# Dependencies cannot cope with certain source tree changes, particularly +# with respect to removing source files and replacing generated files. +# Handle these cases here in an ad-hoc fashion. +# 20170523 remove stale generated asm files for functions which are no longer +# syscalls after r302092 (pipe) and r318736 (others) +.for f in getdents lstat mknod pipe stat +.if exists(${OBJTREE}${.CURDIR}/lib/libc/${f}.s) || \ + exists(${OBJTREE}${.CURDIR}/lib/libc/${f}.S) + @echo Removing stale generated ${f} syscall files + @rm -f ${OBJTREE}${.CURDIR}/lib/libc/${f}.* \ + ${OBJTREE}${.CURDIR}/lib/libc/.depend.${f}.* \ + ${OBJTREE}${.CURDIR}/world32/${.CURDIR}/lib/libc/${f}.* \ + ${OBJTREE}${.CURDIR}/world32/${.CURDIR}/lib/libc/.depend.${f}.* +.endif +.endfor .for _dir in \ lib lib/casper usr legacy/bin legacy/usr mkdir -p ${WORLDTMP}/${_dir} From owner-svn-src-head@freebsd.org Fri May 26 01:15:00 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1752BD82BE0; Fri, 26 May 2017 01:15:00 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BEF7E16B7; Fri, 26 May 2017 01:14:59 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q1Ewb6025185; Fri, 26 May 2017 01:14:58 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q1Ewcp025182; Fri, 26 May 2017 01:14:58 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201705260114.v4Q1Ewcp025182@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Fri, 26 May 2017 01:14:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318913 - head/lib/libc/gen 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.23 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, 26 May 2017 01:15:00 -0000 Author: pfg Date: Fri May 26 01:14:58 2017 New Revision: 318913 URL: https://svnweb.freebsd.org/changeset/base/318913 Log: fts_open: move bogus initialization further below, before it is used. Move an unneeded initialization, introduced in r54770 to quiet down GCC, to a place nearer to its first use. This has no practical effect, it just keeps the garbage better sorted. Hinted by: OpenBSD (CVS rev. 1.56, without obfuscations) Modified: head/lib/libc/gen/fts-compat.c head/lib/libc/gen/fts-compat11.c head/lib/libc/gen/fts.c Modified: head/lib/libc/gen/fts-compat.c ============================================================================== --- head/lib/libc/gen/fts-compat.c Fri May 26 00:51:05 2017 (r318912) +++ head/lib/libc/gen/fts-compat.c Fri May 26 01:14:58 2017 (r318913) @@ -146,9 +146,6 @@ __fts_open_44bsd(char * const *argv, int sp->fts_compar = compar; sp->fts_options = options; - /* Shush, GCC. */ - tmp = NULL; - /* Logical walks turn on NOCHDIR; symbolic links are too hard. */ if (ISSET(FTS_LOGICAL)) SET(FTS_NOCHDIR); @@ -165,6 +162,9 @@ __fts_open_44bsd(char * const *argv, int goto mem2; parent->fts_level = FTS_ROOTPARENTLEVEL; + /* Shush, GCC. */ + tmp = NULL; + /* Allocate/initialize root(s). */ for (root = NULL, nitems = 0; *argv != NULL; ++argv, ++nitems) { /* Don't allow zero-length paths. */ Modified: head/lib/libc/gen/fts-compat11.c ============================================================================== --- head/lib/libc/gen/fts-compat11.c Fri May 26 00:51:05 2017 (r318912) +++ head/lib/libc/gen/fts-compat11.c Fri May 26 01:14:58 2017 (r318913) @@ -142,9 +142,6 @@ freebsd11_fts_open(char * const *argv, i sp->fts_compar = compar; sp->fts_options = options; - /* Shush, GCC. */ - tmp = NULL; - /* Logical walks turn on NOCHDIR; symbolic links are too hard. */ if (ISSET(FTS_LOGICAL)) SET(FTS_NOCHDIR); @@ -161,6 +158,9 @@ freebsd11_fts_open(char * const *argv, i goto mem2; parent->fts_level = FTS_ROOTPARENTLEVEL; + /* Shush, GCC. */ + tmp = NULL; + /* Allocate/initialize root(s). */ for (root = NULL, nitems = 0; *argv != NULL; ++argv, ++nitems) { len = strlen(*argv); Modified: head/lib/libc/gen/fts.c ============================================================================== --- head/lib/libc/gen/fts.c Fri May 26 00:51:05 2017 (r318912) +++ head/lib/libc/gen/fts.c Fri May 26 01:14:58 2017 (r318913) @@ -137,9 +137,6 @@ fts_open(char * const *argv, int options sp->fts_compar = compar; sp->fts_options = options; - /* Shush, GCC. */ - tmp = NULL; - /* Logical walks turn on NOCHDIR; symbolic links are too hard. */ if (ISSET(FTS_LOGICAL)) SET(FTS_NOCHDIR); @@ -156,6 +153,9 @@ fts_open(char * const *argv, int options goto mem2; parent->fts_level = FTS_ROOTPARENTLEVEL; + /* Shush, GCC. */ + tmp = NULL; + /* Allocate/initialize root(s). */ for (root = NULL, nitems = 0; *argv != NULL; ++argv, ++nitems) { len = strlen(*argv); From owner-svn-src-head@freebsd.org Fri May 26 02:30:27 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F183DD82DD2; Fri, 26 May 2017 02:30:27 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B14311487; Fri, 26 May 2017 02:30:27 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q2UQK7053437; Fri, 26 May 2017 02:30:26 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q2UQGr053434; Fri, 26 May 2017 02:30:26 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705260230.v4Q2UQGr053434@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 02:30:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318914 - 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.23 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, 26 May 2017 02:30:28 -0000 Author: emaste Date: Fri May 26 02:30:26 2017 New Revision: 318914 URL: https://svnweb.freebsd.org/changeset/base/318914 Log: bsdgrep: correct assumptions to prepare for chunking Correct a couple of minor BSD grep assumptions that are valid for line processing but not future chunk-based processing. Submitted by: Kyle Evans Reviewed by: bapt, cem Differential Revision: https://reviews.freebsd.org/D10824 Modified: head/usr.bin/grep/grep.c head/usr.bin/grep/grep.h head/usr.bin/grep/util.c Modified: head/usr.bin/grep/grep.c ============================================================================== --- head/usr.bin/grep/grep.c Fri May 26 01:14:58 2017 (r318913) +++ head/usr.bin/grep/grep.c Fri May 26 02:30:26 2017 (r318914) @@ -78,7 +78,7 @@ const char *errstr[] = { }; /* Flags passed to regcomp() and regexec() */ -int cflags = REG_NOSUB; +int cflags = REG_NOSUB | REG_NEWLINE; int eflags = REG_STARTEND; /* XXX TODO: Get rid of this flag. Modified: head/usr.bin/grep/grep.h ============================================================================== --- head/usr.bin/grep/grep.h Fri May 26 01:14:58 2017 (r318913) +++ head/usr.bin/grep/grep.h Fri May 26 02:30:26 2017 (r318914) @@ -82,7 +82,7 @@ extern const char *errstr[]; #define EXCL_PAT 0 #define INCL_PAT 1 -#define MAX_LINE_MATCHES 32 +#define MAX_MATCHES 32 struct file { int fd; Modified: head/usr.bin/grep/util.c ============================================================================== --- head/usr.bin/grep/util.c Fri May 26 01:14:58 2017 (r318913) +++ head/usr.bin/grep/util.c Fri May 26 02:30:26 2017 (r318914) @@ -61,7 +61,7 @@ static bool first_match = true; * other useful bits */ struct parsec { - regmatch_t matches[MAX_LINE_MATCHES]; /* Matches made */ + regmatch_t matches[MAX_MATCHES]; /* Matches made */ struct str ln; /* Current line */ size_t lnstart; /* Position in line */ size_t matchidx; /* Latest match index */ @@ -295,7 +295,7 @@ procfile(const char *fn) /* Print the matching line, but only if not quiet/binary */ if (t == 0 && printmatch) { printline(&pc, ':'); - while (pc.matchidx >= MAX_LINE_MATCHES) { + while (pc.matchidx >= MAX_MATCHES) { /* Reset matchidx and try again */ pc.matchidx = 0; if (procline(&pc) == 0) @@ -401,7 +401,7 @@ procline(struct parsec *pc) lastmatches = 0; startm = matchidx; retry = 0; - if (st > 0) + if (st > 0 && pc->ln.dat[st - 1] != fileeol) leflags |= REG_NOTBOL; /* Loop to compare with all the patterns */ for (i = 0; i < patterns; i++) { @@ -483,7 +483,7 @@ procline(struct parsec *pc) } /* avoid excessive matching - skip further patterns */ if ((color == NULL && !oflag) || qflag || lflag || - matchidx >= MAX_LINE_MATCHES) { + matchidx >= MAX_MATCHES) { pc->lnstart = nst; lastmatches = 0; break; From owner-svn-src-head@freebsd.org Fri May 26 03:27:07 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 995ABD82137; Fri, 26 May 2017 03:27:07 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6984E1483; Fri, 26 May 2017 03:27:07 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q3R6qo078366; Fri, 26 May 2017 03:27:06 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q3R6Uw078365; Fri, 26 May 2017 03:27:06 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201705260327.v4Q3R6Uw078365@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Fri, 26 May 2017 03:27:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318915 - head/usr.sbin/ypldap 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.23 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, 26 May 2017 03:27:07 -0000 Author: araujo Date: Fri May 26 03:27:06 2017 New Revision: 318915 URL: https://svnweb.freebsd.org/changeset/base/318915 Log: Simplify parseval() by allocating a buffer the size of the input string, which will always be big enough to hold the output string. Obtained from: OpenBSD (revision 1.36) Modified: head/usr.sbin/ypldap/aldap.c Modified: head/usr.sbin/ypldap/aldap.c ============================================================================== --- head/usr.sbin/ypldap/aldap.c Fri May 26 02:30:26 2017 (r318914) +++ head/usr.sbin/ypldap/aldap.c Fri May 26 03:27:06 2017 (r318915) @@ -1212,30 +1212,19 @@ char * parseval(char *p, size_t len) { char hex[3]; - char *cp = p, *buffer, *newbuffer; - size_t size, newsize, i, j; + char *buffer; + size_t i, j; - size = 50; - if ((buffer = calloc(1, size)) == NULL) + if ((buffer = calloc(1, len + 1)) == NULL) return NULL; for (i = j = 0; j < len; i++) { - if (i >= size) { - newsize = size + 1024; - if ((newbuffer = realloc(buffer, newsize)) == NULL) { - free(buffer); - return (NULL); - } - buffer = newbuffer; - size = newsize; - } - - if (cp[j] == '\\') { - strlcpy(hex, cp + j + 1, sizeof(hex)); + if (p[j] == '\\') { + strlcpy(hex, p + j + 1, sizeof(hex)); buffer[i] = (char)strtoumax(hex, NULL, 16); j += 3; } else { - buffer[i] = cp[j]; + buffer[i] = p[j]; j++; } } From owner-svn-src-head@freebsd.org Fri May 26 03:36:00 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6D5FAD8236B; Fri, 26 May 2017 03:36:00 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3DA811922; Fri, 26 May 2017 03:36:00 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q3Zxex082426; Fri, 26 May 2017 03:35:59 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q3ZxAL082425; Fri, 26 May 2017 03:35:59 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705260335.v4Q3ZxAL082425@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 03:35:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318916 - head/usr.bin/grep/regex 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.23 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, 26 May 2017 03:36:00 -0000 Author: emaste Date: Fri May 26 03:35:59 2017 New Revision: 318916 URL: https://svnweb.freebsd.org/changeset/base/318916 Log: bsdgrep: use safer sizeof() construct Submitted by: Kyle Evans Modified: head/usr.bin/grep/regex/tre-fastmatch.c Modified: head/usr.bin/grep/regex/tre-fastmatch.c ============================================================================== --- head/usr.bin/grep/regex/tre-fastmatch.c Fri May 26 03:27:06 2017 (r318915) +++ head/usr.bin/grep/regex/tre-fastmatch.c Fri May 26 03:35:59 2017 (r318916) @@ -351,7 +351,7 @@ static int fastcmp(const fastmatch_t *fg #define FILL_BMGS \ if (fg->len > 0 && !fg->hasdot) \ { \ - fg->sbmGs = malloc(fg->len * sizeof(int)); \ + fg->sbmGs = malloc(fg->len * sizeof(*fg->sbmGs)); \ if (!fg->sbmGs) \ return REG_ESPACE; \ if (fg->len == 1) \ @@ -367,7 +367,7 @@ static int fastcmp(const fastmatch_t *fg #define FILL_BMGS_WIDE \ if (fg->wlen > 0 && !fg->hasdot) \ { \ - fg->bmGs = malloc(fg->wlen * sizeof(int)); \ + fg->bmGs = malloc(fg->wlen * sizeof(*fg->bmGs)); \ if (!fg->bmGs) \ return REG_ESPACE; \ if (fg->wlen == 1) \ From owner-svn-src-head@freebsd.org Fri May 26 06:09:12 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B97AED826D3; Fri, 26 May 2017 06:09:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 899661796; Fri, 26 May 2017 06:09:12 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4Q69BHh042945; Fri, 26 May 2017 06:09:11 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4Q69Bqp042944; Fri, 26 May 2017 06:09:11 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201705260609.v4Q69Bqp042944@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Fri, 26 May 2017 06:09:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318917 - head/kerberos5/lib/libroken 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.23 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, 26 May 2017 06:09:12 -0000 Author: delphij Date: Fri May 26 06:09:11 2017 New Revision: 318917 URL: https://svnweb.freebsd.org/changeset/base/318917 Log: Disconnect heimdal version of qsort.c from build because we are already using libc's version of qsort. PR: bin/213922 MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D10814 Modified: head/kerberos5/lib/libroken/Makefile Modified: head/kerberos5/lib/libroken/Makefile ============================================================================== --- head/kerberos5/lib/libroken/Makefile Fri May 26 03:35:59 2017 (r318916) +++ head/kerberos5/lib/libroken/Makefile Fri May 26 06:09:11 2017 (r318917) @@ -52,7 +52,6 @@ SRCS= base64.c \ parse_bytes.c \ parse_time.c \ parse_units.c \ - qsort.c \ rand.c \ realloc.c \ resolve.c \ From owner-svn-src-head@freebsd.org Fri May 26 10:27:37 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 69044D8136E; Fri, 26 May 2017 10:27:37 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2142E18A2; Fri, 26 May 2017 10:27:37 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QARaGd051027; Fri, 26 May 2017 10:27:36 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QARaeH051026; Fri, 26 May 2017 10:27:36 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261027.v4QARaeH051026@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 10:27:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318920 - 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.23 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, 26 May 2017 10:27:37 -0000 Author: avg Date: Fri May 26 10:27:35 2017 New Revision: 318920 URL: https://svnweb.freebsd.org/changeset/base/318920 Log: MFC r316924: 8061 sa_find_idx_tab can be declared more type-safely illumos/illumos-gate@7f0bdb4257bb4f1f76390b72665961e411da24c6 https://github.com/illumos/illumos-gate/commit/7f0bdb4257bb4f1f76390b72665961e411da24c6 https://www.illumos.org/issues/8061 sa_find_idx_tab() is declared as taking and returning "void *" parameters. These can be declared to be the specific types. Reviewed by: George Wilson Reviewed by: Chris Williamson Approved by: Dan McDonald Author: Matthew Ahrens MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c Fri May 26 08:59:16 2017 (r318919) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sa.c Fri May 26 10:27:35 2017 (r318920) @@ -22,7 +22,7 @@ /* * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. * Portions Copyright 2011 iXsystems, Inc - * Copyright (c) 2013, 2016 by Delphix. All rights reserved. + * Copyright (c) 2013, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -131,8 +131,8 @@ typedef void (sa_iterfunc_t)(void *hdr, static int sa_build_index(sa_handle_t *hdl, sa_buf_type_t buftype); static void sa_idx_tab_hold(objset_t *os, sa_idx_tab_t *idx_tab); -static void *sa_find_idx_tab(objset_t *os, dmu_object_type_t bonustype, - void *data); +static sa_idx_tab_t *sa_find_idx_tab(objset_t *os, dmu_object_type_t bonustype, + sa_hdr_phys_t *hdr); static void sa_idx_tab_rele(objset_t *os, void *arg); static void sa_copy_data(sa_data_locator_t *func, void *start, void *target, int buflen); @@ -1486,11 +1486,10 @@ sa_lookup_uio(sa_handle_t *hdl, sa_attr_ } #endif -void * -sa_find_idx_tab(objset_t *os, dmu_object_type_t bonustype, void *data) +static sa_idx_tab_t * +sa_find_idx_tab(objset_t *os, dmu_object_type_t bonustype, sa_hdr_phys_t *hdr) { sa_idx_tab_t *idx_tab; - sa_hdr_phys_t *hdr = (sa_hdr_phys_t *)data; sa_os_t *sa = os->os_sa; sa_lot_t *tb, search; avl_index_t loc; From owner-svn-src-head@freebsd.org Fri May 26 10:31:06 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C7298D81582; Fri, 26 May 2017 10:31:06 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7B2CC1BE8; Fri, 26 May 2017 10:31:06 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QAV5Nw054192; Fri, 26 May 2017 10:31:05 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QAV5pf054191; Fri, 26 May 2017 10:31:05 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261031.v4QAV5pf054191@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 10:31:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318921 - 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.23 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, 26 May 2017 10:31:06 -0000 Author: avg Date: Fri May 26 10:31:05 2017 New Revision: 318921 URL: https://svnweb.freebsd.org/changeset/base/318921 Log: MFV r316928: 7256 low probability race in zfs_get_data illumos/illumos-gate@0c94e1af6784c69a1dea25e0e35dd13b2b91e2e5 https://github.com/illumos/illumos-gate/commit/0c94e1af6784c69a1dea25e0e35dd13b2b91e2e5 https://www.illumos.org/issues/7256 error = dmu_sync(zio, lr->lr_common.lrc_txg, zfs_get_done, zgd); ASSERT(error || lr->lr_length <= zp->z_blksz); It's possible, although extremely rare, that the zfs_get_done() callback is executed before dmu_sync() returns. In that case the znode's range lock is dropped and the znode is unreferenced. Thus, the assertion can access some invalid or wrong data via the zp pointer. size variable caches the correct value of z_blksz and can be safely used here. Reviewed by: Matt Ahrens Reviewed by: Pavel Zakharov Approved by: Dan McDonald Author: Andriy Gapon MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Fri May 26 10:27:35 2017 (r318920) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Fri May 26 10:31:05 2017 (r318921) @@ -1386,7 +1386,7 @@ zfs_get_data(void *arg, lr_write_t *lr, error = dmu_sync(zio, lr->lr_common.lrc_txg, zfs_get_done, zgd); - ASSERT(error || lr->lr_length <= zp->z_blksz); + ASSERT(error || lr->lr_length <= size); /* * On success, we need to wait for the write I/O From owner-svn-src-head@freebsd.org Fri May 26 10:34:34 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85172D8175F; Fri, 26 May 2017 10:34:34 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 569981F8B; Fri, 26 May 2017 10:34:34 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QAYXtl055126; Fri, 26 May 2017 10:34:33 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QAYX02055125; Fri, 26 May 2017 10:34:33 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261034.v4QAYX02055125@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 10:34:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318922 - head/sys/cddl/contrib/opensolaris 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.23 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, 26 May 2017 10:34:34 -0000 Author: avg Date: Fri May 26 10:34:33 2017 New Revision: 318922 URL: https://svnweb.freebsd.org/changeset/base/318922 Log: MFV r316927: 5379 modifying a mmap()-ed file does not update its timestamps FreeBSD note: this is a record-only merge as the FreeBSD putpages code is quite different from the upstream. illumos/illumos-gate@80e10fd0d22bbf0d18bfdae035e06f44c68ae8e6 https://github.com/illumos/illumos-gate/commit/80e10fd0d22bbf0d18bfdae035e06f44c68ae8e6 https://www.illumos.org/issues/5379 The following is based on a review of the illumos code and on a similar problem reported for FreeBSD where the relevant code is different. Looking at this block of code http://src.illumos.org/source/xref/illumos-gate/ usr/src/uts/common/fs/zfs/zfs_vnops.c#4187 I see code to set up an sa_bulk_attr_t object, I see code to set up mtime and ctime values, but I do not see code to actually apply the attributes... I would expect there to be a call to sa_bulk_update(), there is such a call in zfs_write() for instance. mmap_write.c [Magnifier] - demo (1.42 KB) Andriy Gapon, 2015-11-11 01:53 PM Reviewed by: Matthew Ahrens Reviewed by: Prashanth Sreenivasa Reviewed by: Dan McDonald Approved by: Gordon Ross Author: Andriy Gapon Modified: Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) From owner-svn-src-head@freebsd.org Fri May 26 10:37:56 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6353D81885; Fri, 26 May 2017 10:37:56 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9586E11A6; Fri, 26 May 2017 10:37:56 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QAbtGw055294; Fri, 26 May 2017 10:37:55 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QAbtak055293; Fri, 26 May 2017 10:37:55 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261037.v4QAbtak055293@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 10:37:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318923 - 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.23 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, 26 May 2017 10:37:56 -0000 Author: avg Date: Fri May 26 10:37:55 2017 New Revision: 318923 URL: https://svnweb.freebsd.org/changeset/base/318923 Log: zfs_putpages: assert that sa_bulk_update() must succeed Same as the upstream does in r316927. MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Fri May 26 10:34:33 2017 (r318922) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Fri May 26 10:37:55 2017 (r318923) @@ -4758,7 +4758,8 @@ zfs_putpages(struct vnode *vp, vm_page_t &zp->z_pflags, 8); zfs_tstamp_update_setup(zp, CONTENT_MODIFIED, mtime, ctime, B_TRUE); - (void)sa_bulk_update(zp->z_sa_hdl, bulk, count, tx); + err = sa_bulk_update(zp->z_sa_hdl, bulk, count, tx); + ASSERT0(err); zfs_log_write(zfsvfs->z_log, tx, TX_WRITE, zp, off, len, 0); zfs_vmobject_wlock(object); From owner-svn-src-head@freebsd.org Fri May 26 11:05:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1B881D7B821; Fri, 26 May 2017 11:05:58 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D13E01432; Fri, 26 May 2017 11:05:57 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QB5uMF067673; Fri, 26 May 2017 11:05:56 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QB5ui3067672; Fri, 26 May 2017 11:05:56 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261105.v4QB5ui3067672@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:05:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318924 - 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.23 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, 26 May 2017 11:05:58 -0000 Author: avg Date: Fri May 26 11:05:56 2017 New Revision: 318924 URL: https://svnweb.freebsd.org/changeset/base/318924 Log: arc_init: make code closer to upstream by introducing 'allmem' variable All the differences in calculations are kept. A comment about arc_max being 1/2 of all memory is fixed to reflect the actual code that uses 5/8 as a factor. MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Fri May 26 10:37:55 2017 (r318923) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Fri May 26 11:05:56 2017 (r318924) @@ -6315,6 +6315,20 @@ arc_init(void) { int i, prefetch_tunable_set = 0; + /* + * allmem is "all memory that we could possibly use". + */ +#ifdef illumos +#ifdef _KERNEL + uint64_t allmem = ptob(physmem - swapfs_minfree); +#else + uint64_t allmem = (physmem * PAGESIZE) / 2; +#endif +#else + uint64_t allmem = kmem_size(); +#endif + + mutex_init(&arc_reclaim_lock, NULL, MUTEX_DEFAULT, NULL); cv_init(&arc_reclaim_thread_cv, NULL, CV_DEFAULT, NULL); cv_init(&arc_reclaim_waiters_cv, NULL, CV_DEFAULT, NULL); @@ -6326,7 +6340,7 @@ arc_init(void) arc_min_prefetch_lifespan = 1 * hz; /* Start out with 1/8 of all memory */ - arc_c = kmem_size() / 8; + arc_c = allmem / 8; #ifdef illumos #ifdef _KERNEL @@ -6339,13 +6353,13 @@ arc_init(void) #endif #endif /* illumos */ /* set min cache to 1/32 of all memory, or arc_abs_min, whichever is more */ - arc_c_min = MAX(arc_c / 4, arc_abs_min); - /* set max to 1/2 of all memory, or all but 1GB, whichever is more */ - if (arc_c * 8 >= 1 << 30) - arc_c_max = (arc_c * 8) - (1 << 30); + arc_c_min = MAX(allmem / 32, arc_abs_min); + /* set max to 5/8 of all memory, or all but 1GB, whichever is more */ + if (allmem >= 1 << 30) + arc_c_max = allmem - (1 << 30); else arc_c_max = arc_c_min; - arc_c_max = MAX(arc_c * 5, arc_c_max); + arc_c_max = MAX(allmem * 5 / 8, arc_c_max); /* * In userland, there's only the memory pressure that we artificially @@ -6362,7 +6376,7 @@ arc_init(void) * Allow the tunables to override our calculations if they are * reasonable. */ - if (zfs_arc_max > arc_abs_min && zfs_arc_max < kmem_size()) { + if (zfs_arc_max > arc_abs_min && zfs_arc_max < allmem) { arc_c_max = zfs_arc_max; arc_c_min = MIN(arc_c_min, arc_c_max); } @@ -6485,7 +6499,7 @@ arc_init(void) printf("ZFS WARNING: Recommended minimum RAM size is 512MB; " "expect unstable behavior.\n"); } - if (kmem_size() < 512 * (1 << 20)) { + if (allmem < 512 * (1 << 20)) { printf("ZFS WARNING: Recommended minimum kmem_size is 512MB; " "expect unstable behavior.\n"); printf(" Consider tuning vm.kmem_size and " From owner-svn-src-head@freebsd.org Fri May 26 11:23:18 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4ABEFD82169; Fri, 26 May 2017 11:23:18 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F3DDD1EE6; Fri, 26 May 2017 11:23:17 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBNHZJ075651; Fri, 26 May 2017 11:23:17 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBNHWR075650; Fri, 26 May 2017 11:23:17 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261123.v4QBNHWR075650@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:23:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318925 - 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.23 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, 26 May 2017 11:23:18 -0000 Author: avg Date: Fri May 26 11:23:16 2017 New Revision: 318925 URL: https://svnweb.freebsd.org/changeset/base/318925 Log: MFV r316929: 6914 kernel virtual memory fragmentation leads to hang illumos/illumos-gate@af868f46a5b794687741d5424de9e3a2d684a84a https://github.com/illumos/illumos-gate/commit/af868f46a5b794687741d5424de9e3a2d684a84a https://www.illumos.org/issues/6914 FreeBSD note: only a ZFS part of the change is merged, changes to the VM subsystem are not ported (obviously). Also, now that FreeBSD has vmem(9) we don't have to ifdef-out the code that uses it. MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Fri May 26 11:05:56 2017 (r318924) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Fri May 26 11:23:16 2017 (r318925) @@ -6339,19 +6339,6 @@ arc_init(void) /* Convert seconds to clock ticks */ arc_min_prefetch_lifespan = 1 * hz; - /* Start out with 1/8 of all memory */ - arc_c = allmem / 8; - -#ifdef illumos -#ifdef _KERNEL - /* - * On architectures where the physical memory can be larger - * than the addressable space (intel in 32-bit mode), we may - * need to limit the cache to 1/8 of VM size. - */ - arc_c = MIN(arc_c, vmem_size(heap_arena, VMEM_ALLOC | VMEM_FREE) / 8); -#endif -#endif /* illumos */ /* set min cache to 1/32 of all memory, or arc_abs_min, whichever is more */ arc_c_min = MAX(allmem / 32, arc_abs_min); /* set max to 5/8 of all memory, or all but 1GB, whichever is more */ @@ -6391,6 +6378,15 @@ arc_init(void) /* limit meta-data to 1/4 of the arc capacity */ arc_meta_limit = arc_c_max / 4; +#ifdef _KERNEL + /* + * Metadata is stored in the kernel's heap. Don't let us + * use more than half the heap for the ARC. + */ + arc_meta_limit = MIN(arc_meta_limit, + vmem_size(heap_arena, VMEM_ALLOC | VMEM_FREE) / 2); +#endif + /* Allow the tunable to override if it is reasonable */ if (zfs_arc_meta_limit > 0 && zfs_arc_meta_limit <= arc_c_max) arc_meta_limit = zfs_arc_meta_limit; From owner-svn-src-head@freebsd.org Fri May 26 11:25:45 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BC6BAD82288; Fri, 26 May 2017 11:25:45 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8CDE511A3; Fri, 26 May 2017 11:25:45 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBPixx075908; Fri, 26 May 2017 11:25:44 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBPivJ075907; Fri, 26 May 2017 11:25:44 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261125.v4QBPivJ075907@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:25:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318926 - head/sys/cddl/contrib/opensolaris 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.23 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, 26 May 2017 11:25:45 -0000 Author: avg Date: Fri May 26 11:25:44 2017 New Revision: 318926 URL: https://svnweb.freebsd.org/changeset/base/318926 Log: MFV r316919: 7885 zpool list can report 16.0e for expandsz FreeBSD note: this is a record-only change, the actual change was directly committed by smh. illumos/illumos-gate@c040c10cdd1e4eab0fc88203758367dd81e057b7 https://github.com/illumos/illumos-gate/commit/c040c10cdd1e4eab0fc88203758367dd81e057b7 https://www.illumos.org/issues/7885 When a member of a RAIDZ has been replaced with a device smaller than the original, then the top level vdev can report its expand size as 16.0E. The reduced child asize causes the RAIDZ to have a vdev_asize lower than its vdev_max_asize which then results in an underflow during the calculation of the parents expand size. Also for RAIDZ vdevs the sum of their child vdev_min_asize could be smaller than the parents vdev_min_size. Fixed by: https://github.com/openzfs/openzfs/pull/296 Reviewed by: Matthew Ahrens Reviewed by: George Wilson Approved by: Gordon Ross Author: Steven Hartland Modified: Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) From owner-svn-src-head@freebsd.org Fri May 26 11:30:57 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3D909D824AF; Fri, 26 May 2017 11:30:57 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E82EE170A; Fri, 26 May 2017 11:30:56 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBUtj3076389; Fri, 26 May 2017 11:30:55 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBUt8S076388; Fri, 26 May 2017 11:30:55 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261130.v4QBUt8S076388@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:30:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318928 - 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.23 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, 26 May 2017 11:30:57 -0000 Author: avg Date: Fri May 26 11:30:55 2017 New Revision: 318928 URL: https://svnweb.freebsd.org/changeset/base/318928 Log: MFV r318927: 8025 dbuf_read() creates unnecessary zio_root() for bonus buf illumos/illumos-gate@def4fac5882b4ca67bd0f4a53509b6d1fa8ae14e https://github.com/illumos/illumos-gate/commit/def4fac5882b4ca67bd0f4a53509b6d1fa8ae14e https://www.illumos.org/issues/8025 dbuf_read() creates a zio_root() to track and wait for all the zio's that may happen as part of this call. However, if the blkptr_t for this buffer is NULL or a hole, we will not create any more zio's, so this zio_root() is unnecessary. This is always the case when calling dbuf_read() on a bonus buffer, because it has no blkptr (it's part of the containing dnode). For workloads that read a lot of bonus buffers (e.g. file creation and removal), creating and destroying these unnecessary zio's can decrease performance by around 3%. Reviewed by: Dan Kimmel Reviewed by: Pavel Zakharov Reviewed by: Prashanth Sreenivasa Approved by: Robert Mustacchi Author: Matthew Ahrens Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Fri May 26 11:29:31 2017 (r318927) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Fri May 26 11:30:55 2017 (r318928) @@ -1088,7 +1088,6 @@ int dbuf_read(dmu_buf_impl_t *db, zio_t *zio, uint32_t flags) { int err = 0; - boolean_t havepzio = (zio != NULL); boolean_t prefetch; dnode_t *dn; @@ -1132,9 +1131,13 @@ dbuf_read(dmu_buf_impl_t *db, zio_t *zio DB_DNODE_EXIT(db); } else if (db->db_state == DB_UNCACHED) { spa_t *spa = dn->dn_objset->os_spa; + boolean_t need_wait = B_FALSE; - if (zio == NULL) + if (zio == NULL && + db->db_blkptr != NULL && !BP_IS_HOLE(db->db_blkptr)) { zio = zio_root(spa, NULL, NULL, ZIO_FLAG_CANFAIL); + need_wait = B_TRUE; + } dbuf_read_impl(db, zio, flags); /* dbuf_read_impl has dropped db_mtx for us */ @@ -1146,7 +1149,7 @@ dbuf_read(dmu_buf_impl_t *db, zio_t *zio rw_exit(&dn->dn_struct_rwlock); DB_DNODE_EXIT(db); - if (!havepzio) + if (need_wait) err = zio_wait(zio); } else { /* @@ -1181,7 +1184,6 @@ dbuf_read(dmu_buf_impl_t *db, zio_t *zio mutex_exit(&db->db_mtx); } - ASSERT(err || havepzio || db->db_state == DB_CACHED); return (err); } From owner-svn-src-head@freebsd.org Fri May 26 11:33:35 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F1BFFD82896; Fri, 26 May 2017 11:33:35 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B02581C60; Fri, 26 May 2017 11:33:35 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBXYHx080088; Fri, 26 May 2017 11:33:34 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBXYG4080087; Fri, 26 May 2017 11:33:34 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261133.v4QBXYG4080087@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:33:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318930 - 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.23 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, 26 May 2017 11:33:36 -0000 Author: avg Date: Fri May 26 11:33:34 2017 New Revision: 318930 URL: https://svnweb.freebsd.org/changeset/base/318930 Log: MFV r318929: 7786 zfs`vdev_online() needs better notification about state changes illumos/illumos-gate@5f368aef86387d6ef4eda84030ae9b402313ee4c https://github.com/illumos/illumos-gate/commit/5f368aef86387d6ef4eda84030ae9b402313ee4c https://www.illumos.org/issues/7786 Currently, vdev_online() will only post sysevent if previous state was "offline". It should also post the event when the state changes from "removed" or "faulted" to "healthy" or "degraded". This will fix the following scenario: - pull disk from slot A - check that hotspare has taken its place (if available) - insert disk into slot B - check that hotspare moved back to "avail" state (if spare was used) The problem here is that we don't get any ESC_ZFS_VDEV_* notification and fail to update the vdev FRU. Reviewed by: Matthew Ahrens mahrens@delphix.com Reviewed by: George Wilson george.wilson@delphix.com Approved by: Albert Lee Author: Yuri Pankov MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 11:32:05 2017 (r318929) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 11:33:34 2017 (r318930) @@ -22,7 +22,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2011, 2015 by Delphix. All rights reserved. - * Copyright 2015 Nexenta Systems, Inc. All rights reserved. + * Copyright 2017 Nexenta Systems, Inc. * Copyright 2013 Martin Matuska . All rights reserved. * Copyright (c) 2014 Integros [integros.com] * Copyright 2016 Toomas Soome @@ -2595,7 +2595,8 @@ int vdev_online(spa_t *spa, uint64_t guid, uint64_t flags, vdev_state_t *newstate) { vdev_t *vd, *tvd, *pvd, *rvd = spa->spa_root_vdev; - boolean_t postevent = B_FALSE; + boolean_t wasoffline; + vdev_state_t oldstate; spa_vdev_state_enter(spa, SCL_NONE); @@ -2605,9 +2606,8 @@ vdev_online(spa_t *spa, uint64_t guid, u if (!vd->vdev_ops->vdev_op_leaf) return (spa_vdev_state_exit(spa, NULL, ENOTSUP)); - postevent = - (vd->vdev_offline == B_TRUE || vd->vdev_tmpoffline == B_TRUE) ? - B_TRUE : B_FALSE; + wasoffline = (vd->vdev_offline || vd->vdev_tmpoffline); + oldstate = vd->vdev_state; tvd = vd->vdev_top; vd->vdev_offline = B_FALSE; @@ -2645,7 +2645,9 @@ vdev_online(spa_t *spa, uint64_t guid, u spa_async_request(spa, SPA_ASYNC_CONFIG_UPDATE); } - if (postevent) + if (wasoffline || + (oldstate < VDEV_STATE_DEGRADED && + vd->vdev_state >= VDEV_STATE_DEGRADED)) spa_event_notify(spa, vd, ESC_ZFS_VDEV_ONLINE); return (spa_vdev_state_exit(spa, vd, 0)); From owner-svn-src-head@freebsd.org Fri May 26 11:37:13 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 78C84D82A5C; Fri, 26 May 2017 11:37:13 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 481BB1F3B; Fri, 26 May 2017 11:37:13 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBbCje080341; Fri, 26 May 2017 11:37:12 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBbBwZ080333; Fri, 26 May 2017 11:37:11 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261137.v4QBbBwZ080333@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:37:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318932 - in head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs: . 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.23 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, 26 May 2017 11:37:13 -0000 Author: avg Date: Fri May 26 11:37:11 2017 New Revision: 318932 URL: https://svnweb.freebsd.org/changeset/base/318932 Log: MFV r318931: 8063 verify that we do not attempt to access inactive txg illumos/illumos-gate@b7b2590dd9f11b12a0b4878db3886068cce176af https://github.com/illumos/illumos-gate/commit/b7b2590dd9f11b12a0b4878db3886068cce176af https://www.illumos.org/issues/8063 A standard practice in ZFS is to keep track of "per-txg" state. Any of the 3 active TXG's (open, quiescing, syncing) can have different values for this state. We should assert that we do not attempt to modify other (inactive) TXG's. Reviewed by: Serapheim Dimitropoulos Reviewed by: Pavel Zakharov Approved by: Robert Mustacchi Author: Matthew Ahrens MFC after: 2 weeks Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/txg.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zil.h head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/txg.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zil.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_tx.c Fri May 26 11:37:11 2017 (r318932) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Copyright 2011 Nexenta Systems, Inc. All rights reserved. - * Copyright (c) 2012, 2016 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -72,7 +72,7 @@ dmu_tx_create_assigned(struct dsl_pool * { dmu_tx_t *tx = dmu_tx_create_dd(NULL); - ASSERT3U(txg, <=, dp->dp_tx.tx_open_txg); + txg_verify(dp->dp_spa, txg); tx->tx_pool = dp; tx->tx_txg = txg; tx->tx_anyobj = TRUE; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_pool.c Fri May 26 11:37:11 2017 (r318932) @@ -259,13 +259,13 @@ dsl_pool_open_impl(spa_t *spa, uint64_t rrw_init(&dp->dp_config_rwlock, B_TRUE); txg_init(dp, txg); - txg_list_create(&dp->dp_dirty_datasets, + txg_list_create(&dp->dp_dirty_datasets, spa, offsetof(dsl_dataset_t, ds_dirty_link)); - txg_list_create(&dp->dp_dirty_zilogs, + txg_list_create(&dp->dp_dirty_zilogs, spa, offsetof(zilog_t, zl_dirty_link)); - txg_list_create(&dp->dp_dirty_dirs, + txg_list_create(&dp->dp_dirty_dirs, spa, offsetof(dsl_dir_t, dd_dirty_link)); - txg_list_create(&dp->dp_sync_tasks, + txg_list_create(&dp->dp_sync_tasks, spa, offsetof(dsl_sync_task_t, dst_node)); dp->dp_sync_taskq = taskq_create("dp_sync_taskq", Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/spa.c Fri May 26 11:37:11 2017 (r318932) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2011, 2014 by Delphix. All rights reserved. + * Copyright (c) 2011, 2017 by Delphix. All rights reserved. * Copyright (c) 2015, Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2013 Martin Matuska . All rights reserved. * Copyright (c) 2014 Spectra Logic Corporation, All rights reserved. @@ -1136,7 +1136,7 @@ spa_activate(spa_t *spa, int mode) list_create(&spa->spa_state_dirty_list, sizeof (vdev_t), offsetof(vdev_t, vdev_state_dirty_node)); - txg_list_create(&spa->spa_vdev_txg_list, + txg_list_create(&spa->spa_vdev_txg_list, spa, offsetof(struct vdev, vdev_txg_node)); avl_create(&spa->spa_errlist_scrub, Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/txg.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/txg.h Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/txg.h Fri May 26 11:37:11 2017 (r318932) @@ -23,7 +23,7 @@ * Use is subject to license terms. */ /* - * Copyright (c) 2012, 2014 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. */ #ifndef _SYS_TXG_H @@ -60,6 +60,7 @@ typedef struct txg_node { typedef struct txg_list { kmutex_t tl_lock; size_t tl_offset; + spa_t *tl_spa; txg_node_t *tl_head[TXG_SIZE]; } txg_list_t; @@ -103,13 +104,15 @@ extern boolean_t txg_stalled(struct dsl_ /* returns TRUE if someone is waiting for the next txg to sync */ extern boolean_t txg_sync_waiting(struct dsl_pool *dp); +extern void txg_verify(spa_t *spa, uint64_t txg); + /* * Per-txg object lists. */ #define TXG_CLEAN(txg) ((txg) - 1) -extern void txg_list_create(txg_list_t *tl, size_t offset); +extern void txg_list_create(txg_list_t *tl, spa_t *spa, size_t offset); extern void txg_list_destroy(txg_list_t *tl); extern boolean_t txg_list_empty(txg_list_t *tl, uint64_t txg); extern boolean_t txg_all_lists_empty(txg_list_t *tl); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zil.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zil.h Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zil.h Fri May 26 11:37:11 2017 (r318932) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2012 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -96,6 +96,15 @@ typedef struct zil_chain { #define ZIL_MIN_BLKSZ 4096ULL /* + * ziltest is by and large an ugly hack, but very useful in + * checking replay without tedious work. + * When running ziltest we want to keep all itx's and so maintain + * a single list in the zl_itxg[] that uses a high txg: ZILTEST_TXG + * We subtract TXG_CONCURRENT_STATES to allow for common code. + */ +#define ZILTEST_TXG (UINT64_MAX - TXG_CONCURRENT_STATES) + +/* * The words of a log block checksum. */ #define ZIL_ZC_GUID_0 0 Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/txg.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/txg.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/txg.c Fri May 26 11:37:11 2017 (r318932) @@ -21,7 +21,7 @@ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. * Portions Copyright 2011 Martin Matuska - * Copyright (c) 2012, 2014 by Delphix. All rights reserved. + * Copyright (c) 2012, 2017 by Delphix. All rights reserved. */ #include @@ -30,6 +30,7 @@ #include #include #include +#include #include /* @@ -693,16 +694,32 @@ txg_sync_waiting(dsl_pool_t *dp) } /* + * Verify that this txg is active (open, quiescing, syncing). Non-active + * txg's should not be manipulated. + */ +void +txg_verify(spa_t *spa, uint64_t txg) +{ + dsl_pool_t *dp = spa_get_dsl(spa); + if (txg <= TXG_INITIAL || txg == ZILTEST_TXG) + return; + ASSERT3U(txg, <=, dp->dp_tx.tx_open_txg); + ASSERT3U(txg, >=, dp->dp_tx.tx_synced_txg); + ASSERT3U(txg, >=, dp->dp_tx.tx_open_txg - TXG_CONCURRENT_STATES); +} + +/* * Per-txg object lists. */ void -txg_list_create(txg_list_t *tl, size_t offset) +txg_list_create(txg_list_t *tl, spa_t *spa, size_t offset) { int t; mutex_init(&tl->tl_lock, NULL, MUTEX_DEFAULT, NULL); tl->tl_offset = offset; + tl->tl_spa = spa; for (t = 0; t < TXG_SIZE; t++) tl->tl_head[t] = NULL; @@ -722,15 +739,16 @@ txg_list_destroy(txg_list_t *tl) boolean_t txg_list_empty(txg_list_t *tl, uint64_t txg) { + txg_verify(tl->tl_spa, txg); return (tl->tl_head[txg & TXG_MASK] == NULL); } /* * Returns true if all txg lists are empty. * - * Warning: this is inherently racy (an item could be added immediately after this - * function returns). We don't bother with the lock because it wouldn't change the - * semantics. + * Warning: this is inherently racy (an item could be added immediately + * after this function returns). We don't bother with the lock because + * it wouldn't change the semantics. */ boolean_t txg_all_lists_empty(txg_list_t *tl) @@ -754,6 +772,7 @@ txg_list_add(txg_list_t *tl, void *p, ui txg_node_t *tn = (txg_node_t *)((char *)p + tl->tl_offset); boolean_t add; + txg_verify(tl->tl_spa, txg); mutex_enter(&tl->tl_lock); add = (tn->tn_member[t] == 0); if (add) { @@ -778,6 +797,7 @@ txg_list_add_tail(txg_list_t *tl, void * txg_node_t *tn = (txg_node_t *)((char *)p + tl->tl_offset); boolean_t add; + txg_verify(tl->tl_spa, txg); mutex_enter(&tl->tl_lock); add = (tn->tn_member[t] == 0); if (add) { @@ -805,6 +825,7 @@ txg_list_remove(txg_list_t *tl, uint64_t txg_node_t *tn; void *p = NULL; + txg_verify(tl->tl_spa, txg); mutex_enter(&tl->tl_lock); if ((tn = tl->tl_head[t]) != NULL) { p = (char *)tn - tl->tl_offset; @@ -826,6 +847,7 @@ txg_list_remove_this(txg_list_t *tl, voi int t = txg & TXG_MASK; txg_node_t *tn, **tp; + txg_verify(tl->tl_spa, txg); mutex_enter(&tl->tl_lock); for (tp = &tl->tl_head[t]; (tn = *tp) != NULL; tp = &tn->tn_next[t]) { @@ -849,6 +871,7 @@ txg_list_member(txg_list_t *tl, void *p, int t = txg & TXG_MASK; txg_node_t *tn = (txg_node_t *)((char *)p + tl->tl_offset); + txg_verify(tl->tl_spa, txg); return (tn->tn_member[t] != 0); } @@ -861,6 +884,7 @@ txg_list_head(txg_list_t *tl, uint64_t t int t = txg & TXG_MASK; txg_node_t *tn = tl->tl_head[t]; + txg_verify(tl->tl_spa, txg); return (tn == NULL ? NULL : (char *)tn - tl->tl_offset); } @@ -870,6 +894,7 @@ txg_list_next(txg_list_t *tl, void *p, u int t = txg & TXG_MASK; txg_node_t *tn = (txg_node_t *)((char *)p + tl->tl_offset); + txg_verify(tl->tl_spa, txg); tn = tn->tn_next[t]; return (tn == NULL ? NULL : (char *)tn - tl->tl_offset); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 11:37:11 2017 (r318932) @@ -448,9 +448,9 @@ vdev_alloc_common(spa_t *spa, uint_t id, vd->vdev_dtl[t] = range_tree_create(NULL, NULL, &vd->vdev_dtl_lock); } - txg_list_create(&vd->vdev_ms_list, + txg_list_create(&vd->vdev_ms_list, spa, offsetof(struct metaslab, ms_txg_node)); - txg_list_create(&vd->vdev_dtl_list, + txg_list_create(&vd->vdev_dtl_list, spa, offsetof(struct vdev, vdev_dtl_node)); vd->vdev_stat.vs_timestamp = gethrtime(); vdev_queue_init(vd); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zil.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zil.c Fri May 26 11:35:34 2017 (r318931) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zil.c Fri May 26 11:37:11 2017 (r318932) @@ -20,7 +20,7 @@ */ /* * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. - * Copyright (c) 2011, 2016 by Delphix. All rights reserved. + * Copyright (c) 2011, 2017 by Delphix. All rights reserved. * Copyright (c) 2014 Integros [integros.com] */ @@ -101,16 +101,6 @@ static kmem_cache_t *zil_lwb_cache; #define LWB_EMPTY(lwb) ((BP_GET_LSIZE(&lwb->lwb_blk) - \ sizeof (zil_chain_t)) == (lwb->lwb_sz - lwb->lwb_nused)) - -/* - * ziltest is by and large an ugly hack, but very useful in - * checking replay without tedious work. - * When running ziltest we want to keep all itx's and so maintain - * a single list in the zl_itxg[] that uses a high txg: ZILTEST_TXG - * We subtract TXG_CONCURRENT_STATES to allow for common code. - */ -#define ZILTEST_TXG (UINT64_MAX - TXG_CONCURRENT_STATES) - static int zil_bp_compare(const void *x1, const void *x2) { From owner-svn-src-head@freebsd.org Fri May 26 11:49:44 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1505FD82E6B; Fri, 26 May 2017 11:49:44 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C0AA31903; Fri, 26 May 2017 11:49:43 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QBngvf085187; Fri, 26 May 2017 11:49:42 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QBngfn085185; Fri, 26 May 2017 11:49:42 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261149.v4QBngfn085185@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 11:49:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318935 - 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.23 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, 26 May 2017 11:49:44 -0000 Author: avg Date: Fri May 26 11:49:42 2017 New Revision: 318935 URL: https://svnweb.freebsd.org/changeset/base/318935 Log: MFV r318934: 8070 Add some ZFS comments illumos/illumos-gate@40713f2b249d289022c715107b3951055a63aef0 https://github.com/illumos/illumos-gate/commit/40713f2b249d289022c715107b3951055a63aef0 https://www.illumos.org/issues/8070 Add some ZFS comments left by various developers at different times Reviewed by: Yuri Pankov Reviewed by: Matthew Ahrens Approved by: Robert Mustacchi Author: Alan Somers MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_scan.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Fri May 26 11:48:29 2017 (r318934) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dbuf.c Fri May 26 11:49:42 2017 (r318935) @@ -1219,6 +1219,11 @@ dbuf_unoverride(dbuf_dirty_record_t *dr) uint64_t txg = dr->dr_txg; ASSERT(MUTEX_HELD(&db->db_mtx)); + /* + * This assert is valid because dmu_sync() expects to be called by + * a zilog's get_data while holding a range lock. This call only + * comes from dbuf_dirty() callers who must also hold a range lock. + */ ASSERT(dr->dt.dl.dr_override_state != DR_IN_DMU_SYNC); ASSERT(db->db_level == 0); Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_scan.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_scan.c Fri May 26 11:48:29 2017 (r318934) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dsl_scan.c Fri May 26 11:49:42 2017 (r318935) @@ -807,7 +807,7 @@ dsl_scan_visitbp(blkptr_t *bp, const zbo return; /* - * If dsl_scan_ddt() has aready visited this block, it will have + * If dsl_scan_ddt() has already visited this block, it will have * already done any translations or scrubbing, so don't call the * callback again. */ @@ -1474,6 +1474,7 @@ dsl_scan_active(dsl_scan_t *scn) return (used != 0); } +/* Called whenever a txg syncs. */ void dsl_scan_sync(dsl_pool_t *dp, dmu_tx_t *tx) { @@ -1892,6 +1893,7 @@ dsl_scan_scrub_cb(dsl_pool_t *dp, return (0); } +/* Called by the ZFS_IOC_POOL_SCAN ioctl to start a scrub or resilver */ int dsl_scan(dsl_pool_t *dp, pool_scan_func_t func) { From owner-svn-src-head@freebsd.org Fri May 26 12:04:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 362D0D83B82; Fri, 26 May 2017 12:04:23 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E04041EBE; Fri, 26 May 2017 12:04:22 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QC4LAg093265; Fri, 26 May 2017 12:04:21 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QC4LWB093264; Fri, 26 May 2017 12:04:21 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261204.v4QC4LWB093264@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 12:04:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318943 - 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.23 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, 26 May 2017 12:04:23 -0000 Author: avg Date: Fri May 26 12:04:21 2017 New Revision: 318943 URL: https://svnweb.freebsd.org/changeset/base/318943 Log: MFV r318942: 8166 zpool scrub thinks it repaired offline device illumos/illumos-gate@2d2f193a21231a58c583466dc23ba71f1a25f424 https://github.com/illumos/illumos-gate/commit/2d2f193a21231a58c583466dc23ba71f1a25f424 https://www.illumos.org/issues/8166 If we do a scrub while a leaf device is offline (via "zpool offline"), we will inadvertently clear the DTL (dirty time log) of the offline device, even though it is still damaged. When the device comes back online, we will incompletely resilver it, thinking that the scrub repaired blocks written before the scrub was started. The incomplete resilver can lead to data loss if there is a subsequent failure of a different leaf device. The fix is to never clear the DTL of offline devices. Note that if a device is onlined while a scrub is in progress, the scrub will be restarted. The problem can be worked around by running "zpool scrub" after "zpool online". See also https://github.com/zfsonlinux/zfs/issues/5806 Reviewed by: George Wilson george.wilson@delphix.com Reviewed by: Brad Lewis Approved by: Richard Lowe Author: Matthew Ahrens Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 12:02:51 2017 (r318942) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev.c Fri May 26 12:04:21 2017 (r318943) @@ -1930,6 +1930,9 @@ vdev_dtl_should_excise(vdev_t *vd) ASSERT0(scn->scn_phys.scn_errors); ASSERT0(vd->vdev_children); + if (vd->vdev_state < VDEV_STATE_DEGRADED) + return (B_FALSE); + if (vd->vdev_resilver_txg == 0 || range_tree_space(vd->vdev_dtl[DTL_MISSING]) == 0) return (B_TRUE); From owner-svn-src-head@freebsd.org Fri May 26 12:08:39 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7868AD83C9B; Fri, 26 May 2017 12:08:39 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4516211F4; Fri, 26 May 2017 12:08:39 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QC8cOC093516; Fri, 26 May 2017 12:08:38 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QC8c3F093515; Fri, 26 May 2017 12:08:38 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261208.v4QC8c3F093515@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 12:08:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318945 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/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.23 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, 26 May 2017 12:08:39 -0000 Author: avg Date: Fri May 26 12:08:38 2017 New Revision: 318945 URL: https://svnweb.freebsd.org/changeset/base/318945 Log: MFV r318944: 8265 Reserve send stream flag for large dnode feature illumos/illumos-gate@bc83969fdbd1cb0d97ba00218c0a3de5c89fba92 https://github.com/illumos/illumos-gate/commit/bc83969fdbd1cb0d97ba00218c0a3de5c89fba92 https://www.illumos.org/issues/8265 Reserve bit 23 in the zfs send stream flags for the large dnode feature which has been implemented for Linux. Reviewed by: Matthew Ahrens Approved by: Robert Mustacchi Author: Brian Behlendorf MFC after: 1 week Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zfs_ioctl.h Directory Properties: head/sys/cddl/contrib/opensolaris/ (props changed) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zfs_ioctl.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zfs_ioctl.h Fri May 26 12:07:47 2017 (r318944) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/zfs_ioctl.h Fri May 26 12:08:38 2017 (r318945) @@ -93,6 +93,7 @@ typedef enum drr_headertype { #define DMU_BACKUP_FEATURE_RESUMING (1 << 20) /* flag #21 is reserved for a Delphix feature */ #define DMU_BACKUP_FEATURE_COMPRESSED (1 << 22) +/* flag #23 is reserved for the large dnode feature */ /* * Mask of all supported backup features From owner-svn-src-head@freebsd.org Fri May 26 15:49:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F9DFD83681; Fri, 26 May 2017 15:49:22 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 39DBE10BA; Fri, 26 May 2017 15:49:22 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFnL5V084333; Fri, 26 May 2017 15:49:21 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFnKFA084327; Fri, 26 May 2017 15:49:20 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705261549.v4QFnKFA084327@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 15:49:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318951 - in head/usr.sbin/makefs: . ffs 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.23 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, 26 May 2017 15:49:22 -0000 Author: emaste Date: Fri May 26 15:49:20 2017 New Revision: 318951 URL: https://svnweb.freebsd.org/changeset/base/318951 Log: makefs: add -O (offset) option NetBSD revs: ffs.c 1.60 makefs.8 1.44 makefs.c 1.48 makefs.h 1.33 ffs/buf.c 1.20 ffs/mkfs.c 1.27 Obtained from: NetBSD Relnotes: Yes Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10780 Modified: head/usr.sbin/makefs/ffs.c head/usr.sbin/makefs/ffs/buf.c head/usr.sbin/makefs/ffs/mkfs.c head/usr.sbin/makefs/makefs.8 head/usr.sbin/makefs/makefs.c head/usr.sbin/makefs/makefs.h Modified: head/usr.sbin/makefs/ffs.c ============================================================================== --- head/usr.sbin/makefs/ffs.c Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/ffs.c Fri May 26 15:49:20 2017 (r318951) @@ -476,13 +476,15 @@ ffs_create_image(const char *image, fsin char *buf; int i, bufsize; off_t bufrem; + int oflags = O_RDWR | O_CREAT; time_t tstamp; - int oflags = O_RDWR | O_CREAT | O_TRUNC; assert (image != NULL); assert (fsopts != NULL); /* create image */ + if (fsopts->offset == 0) + oflags |= O_TRUNC; if ((fsopts->fd = open(image, oflags, 0666)) == -1) { warn("Can't open `%s' for writing", image); return (-1); @@ -517,6 +519,13 @@ ffs_create_image(const char *image, fsin bufsize); buf = ecalloc(1, bufsize); } + + if (fsopts->offset != 0) + if (lseek(fsopts->fd, fsopts->offset, SEEK_SET) == -1) { + warn("can't seek"); + return -1; + } + while (bufrem > 0) { i = write(fsopts->fd, buf, MIN(bufsize, bufrem)); if (i == -1) { Modified: head/usr.sbin/makefs/ffs/buf.c ============================================================================== --- head/usr.sbin/makefs/ffs/buf.c Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/ffs/buf.c Fri May 26 15:49:20 2017 (r318951) @@ -68,7 +68,7 @@ bread(struct vnode *vp, daddr_t blkno, i printf("%s: blkno %lld size %d\n", __func__, (long long)blkno, size); *bpp = getblk(vp, blkno, size, 0, 0, 0); - offset = (*bpp)->b_blkno * fsinfo->sectorsize; + offset = (*bpp)->b_blkno * fsinfo->sectorsize + fsinfo->offset; if (debug & DEBUG_BUF_BREAD) printf("%s: blkno %lld offset %lld bcount %ld\n", __func__, (long long)(*bpp)->b_blkno, (long long) offset, @@ -128,7 +128,7 @@ bwrite(struct buf *bp) fsinfo_t *fs = bp->b_fs; assert (bp != NULL); - offset = bp->b_blkno * fs->sectorsize; + offset = bp->b_blkno * fs->sectorsize + fs->offset; if (debug & DEBUG_BUF_BWRITE) printf("bwrite: blkno %lld offset %lld bcount %ld\n", (long long)bp->b_blkno, (long long) offset, Modified: head/usr.sbin/makefs/ffs/mkfs.c ============================================================================== --- head/usr.sbin/makefs/ffs/mkfs.c Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/ffs/mkfs.c Fri May 26 15:49:20 2017 (r318951) @@ -774,8 +774,7 @@ ffs_rdfs(daddr_t bno, int size, void *bf int n; off_t offset; - offset = bno; - offset *= fsopts->sectorsize; + offset = bno * fsopts->sectorsize + fsopts->offset; if (lseek(fsopts->fd, offset, SEEK_SET) < 0) err(1, "%s: seek error for sector %lld", __func__, (long long)bno); @@ -799,11 +798,10 @@ ffs_wtfs(daddr_t bno, int size, void *bf int n; off_t offset; - offset = bno; - offset *= fsopts->sectorsize; + offset = bno * fsopts->sectorsize + fsopts->offset; if (lseek(fsopts->fd, offset, SEEK_SET) < 0) err(1, "%s: seek error for sector %lld", __func__, - (long long)bno ); + (long long)bno); n = write(fsopts->fd, bf, size); if (n == -1) err(1, "%s: write error for sector %lld", __func__, Modified: head/usr.sbin/makefs/makefs.8 ============================================================================== --- head/usr.sbin/makefs/makefs.8 Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/makefs.8 Fri May 26 15:49:20 2017 (r318951) @@ -35,7 +35,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 17, 2017 +.Dd May 26, 2017 .Dt MAKEFS 8 .Os .Sh NAME @@ -52,6 +52,7 @@ .Op Fl M Ar minimum-size .Op Fl m Ar maximum-size .Op Fl N Ar userdb-dir +.Op Fl O Ar offset .Op Fl o Ar fs-options .Op Fl R Ar roundup-size .Op Fl S Ar sector-size @@ -193,6 +194,11 @@ rather than using the results from the s and .Xr getgrnam 3 (and related) library calls. +.It Fl O Ar offset +Instead of creating the filesystem at the beginning of the file, start +at offset. +Valid only for +.Sy ffs . .It Fl o Ar fs-options Set file system specific options. .Ar fs-options Modified: head/usr.sbin/makefs/makefs.c ============================================================================== --- head/usr.sbin/makefs/makefs.c Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/makefs.c Fri May 26 15:49:20 2017 (r318951) @@ -124,7 +124,7 @@ main(int argc, char *argv[]) err(1, "Unable to get system time"); - while ((ch = getopt(argc, argv, "B:b:Dd:f:F:M:m:N:o:pR:s:S:t:T:xZ")) != -1) { + while ((ch = getopt(argc, argv, "B:b:Dd:f:F:M:m:N:O:o:pR:s:S:t:T:xZ")) != -1) { switch (ch) { case 'B': @@ -202,7 +202,12 @@ main(int argc, char *argv[]) fsoptions.maxsize = strsuftoll("maximum size", optarg, 1LL, LLONG_MAX); break; - + + case 'O': + fsoptions.offset = + strsuftoll("offset", optarg, 0LL, LLONG_MAX); + break; + case 'o': { char *p; @@ -479,8 +484,8 @@ usage(fstype_t *fstype, fsinfo_t *fsopti fprintf(stderr, "Usage: %s [-xZ] [-B endian] [-b free-blocks] [-d debug-mask]\n" "\t[-F mtree-specfile] [-f free-files] [-M minimum-size] [-m maximum-size]\n" -"\t[-N userdb-dir] [-o fs-options] [-R roundup-size] [-S sector-size]\n" -"\t[-s image-size] [-T ] [-t fs-type]\n" +"\t[-N userdb-dir] [-O offset] [-o fs-options] [-R roundup-size]\n" +"\t[-S sector-size] [-s image-size] [-T ] [-t fs-type]\n" "\timage-file directory | manifest [extra-directory ...]\n", prog); Modified: head/usr.sbin/makefs/makefs.h ============================================================================== --- head/usr.sbin/makefs/makefs.h Fri May 26 15:13:46 2017 (r318950) +++ head/usr.sbin/makefs/makefs.h Fri May 26 15:49:20 2017 (r318951) @@ -151,6 +151,7 @@ typedef struct makefs_fsinfo { off_t maxsize; /* maximum size image can be */ off_t freefiles; /* free file entries to leave */ off_t freeblocks; /* free blocks to leave */ + off_t offset; /* offset from start of file */ off_t roundup; /* round image size up to this value */ int freefilepc; /* free file % */ int freeblockpc; /* free block % */ From owner-svn-src-head@freebsd.org Fri May 26 15:51:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EC4FDD838DE; Fri, 26 May 2017 15:51:52 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BC72D157D; Fri, 26 May 2017 15:51:52 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFppHi085871; Fri, 26 May 2017 15:51:51 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFppcf085870; Fri, 26 May 2017 15:51:51 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705261551.v4QFppcf085870@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Fri, 26 May 2017 15:51:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318952 - head/lib/libthr/thread 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.23 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, 26 May 2017 15:51:53 -0000 Author: vangyzen Date: Fri May 26 15:51:51 2017 New Revision: 318952 URL: https://svnweb.freebsd.org/changeset/base/318952 Log: libthr: prevent setcontext() from masking SIGTHR __thr_setcontext() mistakenly tested for the presence of SIGCANCEL in its local ucontext_t instead of the parameter. Therefore, if a thread calls setcontext() with a context whose signal mask contains SIGTHR (a.k.a. SIGCANCEL), that signal will be blocked, preventing the thread from being cancelled or suspended. Reported by: gcc 6.1 via RISC-V tinderbox Reviewed by: kib MFC after: 3 days Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10933 Modified: head/lib/libthr/thread/thr_sig.c Modified: head/lib/libthr/thread/thr_sig.c ============================================================================== --- head/lib/libthr/thread/thr_sig.c Fri May 26 15:49:20 2017 (r318951) +++ head/lib/libthr/thread/thr_sig.c Fri May 26 15:51:51 2017 (r318952) @@ -736,7 +736,7 @@ __thr_setcontext(const ucontext_t *ucp) errno = EINVAL; return (-1); } - if (!SIGISMEMBER(uc.uc_sigmask, SIGCANCEL)) + if (!SIGISMEMBER(ucp->uc_sigmask, SIGCANCEL)) return __sys_setcontext(ucp); (void) memcpy(&uc, ucp, sizeof(uc)); SIGDELSET(uc.uc_sigmask, SIGCANCEL); From owner-svn-src-head@freebsd.org Fri May 26 15:53:29 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0B770D83957; Fri, 26 May 2017 15:53:29 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D0E9B177B; Fri, 26 May 2017 15:53:28 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFrRRt088083; Fri, 26 May 2017 15:53:27 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFrRbZ088082; Fri, 26 May 2017 15:53:27 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705261553.v4QFrRbZ088082@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Fri, 26 May 2017 15:53:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318953 - head/lib/libthr/thread 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.23 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, 26 May 2017 15:53:29 -0000 Author: vangyzen Date: Fri May 26 15:53:27 2017 New Revision: 318953 URL: https://svnweb.freebsd.org/changeset/base/318953 Log: libthr: fix style in previous commit I intended to add this to the previous commit. Reviewed by: kib MFC after: 3 days Sponsored by: Dell EMC Modified: head/lib/libthr/thread/thr_sig.c Modified: head/lib/libthr/thread/thr_sig.c ============================================================================== --- head/lib/libthr/thread/thr_sig.c Fri May 26 15:51:51 2017 (r318952) +++ head/lib/libthr/thread/thr_sig.c Fri May 26 15:53:27 2017 (r318953) @@ -737,7 +737,7 @@ __thr_setcontext(const ucontext_t *ucp) return (-1); } if (!SIGISMEMBER(ucp->uc_sigmask, SIGCANCEL)) - return __sys_setcontext(ucp); + return (__sys_setcontext(ucp)); (void) memcpy(&uc, ucp, sizeof(uc)); SIGDELSET(uc.uc_sigmask, SIGCANCEL); return (__sys_setcontext(&uc)); From owner-svn-src-head@freebsd.org Fri May 26 15:55:05 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7785BD839C8; Fri, 26 May 2017 15:55:05 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 52AA1190F; Fri, 26 May 2017 15:55:05 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFt4kj088215; Fri, 26 May 2017 15:55:04 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFt37L088210; Fri, 26 May 2017 15:55:03 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705261555.v4QFt37L088210@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Fri, 26 May 2017 15:55:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318954 - in head/libexec/rtld-elf: arm mips powerpc powerpc64 riscv 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.23 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, 26 May 2017 15:55:05 -0000 Author: vangyzen Date: Fri May 26 15:55:03 2017 New Revision: 318954 URL: https://svnweb.freebsd.org/changeset/base/318954 Log: rtld: fix warnings about redundant declarations Fix warnings about redundant declarations in rtld when libthr in increased to WARNS=6. Reviewed by: kib MFC after: 3 days Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10934 Modified: head/libexec/rtld-elf/arm/rtld_machdep.h head/libexec/rtld-elf/mips/rtld_machdep.h head/libexec/rtld-elf/powerpc/rtld_machdep.h head/libexec/rtld-elf/powerpc64/rtld_machdep.h head/libexec/rtld-elf/riscv/rtld_machdep.h Modified: head/libexec/rtld-elf/arm/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/arm/rtld_machdep.h Fri May 26 15:53:27 2017 (r318953) +++ head/libexec/rtld-elf/arm/rtld_machdep.h Fri May 26 15:55:03 2017 (r318954) @@ -67,11 +67,6 @@ typedef struct { round(prev_offset + prev_size, align) #define calculate_tls_end(off, size) ((off) + (size)) -/* - * Lazy binding entry point, called via PLT. - */ -void _rtld_bind_start(void); - extern void *__tls_get_addr(tls_index *ti); #define RTLD_DEFAULT_STACK_PF_EXEC PF_X Modified: head/libexec/rtld-elf/mips/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/mips/rtld_machdep.h Fri May 26 15:53:27 2017 (r318953) +++ head/libexec/rtld-elf/mips/rtld_machdep.h Fri May 26 15:55:03 2017 (r318954) @@ -67,11 +67,6 @@ typedef struct { round(prev_offset + prev_size, align) #define calculate_tls_end(off, size) ((off) + (size)) -/* - * Lazy binding entry point, called via PLT. - */ -void _rtld_bind_start(void); - extern void *__tls_get_addr(tls_index *ti); #define RTLD_DEFAULT_STACK_PF_EXEC PF_X Modified: head/libexec/rtld-elf/powerpc/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/powerpc/rtld_machdep.h Fri May 26 15:53:27 2017 (r318953) +++ head/libexec/rtld-elf/powerpc/rtld_machdep.h Fri May 26 15:55:03 2017 (r318954) @@ -54,11 +54,6 @@ Elf_Addr reloc_jmpslot(Elf_Addr *where, (((Elf_Addr (*)(void))ptr)()) /* - * Lazy binding entry point, called via PLT. - */ -void _rtld_bind_start(void); - -/* * PLT functions. Not really correct prototypes, but the * symbol values are needed. */ Modified: head/libexec/rtld-elf/powerpc64/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/powerpc64/rtld_machdep.h Fri May 26 15:53:27 2017 (r318953) +++ head/libexec/rtld-elf/powerpc64/rtld_machdep.h Fri May 26 15:55:03 2017 (r318954) @@ -54,11 +54,6 @@ Elf_Addr reloc_jmpslot(Elf_Addr *where, (((Elf_Addr (*)(void))ptr)()) /* - * Lazy binding entry point, called via PLT. - */ -void _rtld_bind_start(void); - -/* * TLS */ Modified: head/libexec/rtld-elf/riscv/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/riscv/rtld_machdep.h Fri May 26 15:53:27 2017 (r318953) +++ head/libexec/rtld-elf/riscv/rtld_machdep.h Fri May 26 15:55:03 2017 (r318954) @@ -80,11 +80,6 @@ Elf_Addr reloc_jmpslot(Elf_Addr *where, (((Elf_Addr (*)(void))ptr)()) /* - * Lazy binding entry point, called via PLT. - */ -void _rtld_bind_start(void); - -/* * TLS */ #define TLS_TP_OFFSET 0x0 From owner-svn-src-head@freebsd.org Fri May 26 15:56:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48B44D83A5C; Fri, 26 May 2017 15:56:30 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 234031AB4; Fri, 26 May 2017 15:56:30 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFuTL8088312; Fri, 26 May 2017 15:56:29 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFuSBF088306; Fri, 26 May 2017 15:56:28 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705261556.v4QFuSBF088306@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Fri, 26 May 2017 15:56:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318955 - in head/lib/libthr: arch/aarch64/include arch/arm/include arch/mips/include arch/powerpc/include arch/riscv/include thread 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.23 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, 26 May 2017 15:56:30 -0000 Author: vangyzen Date: Fri May 26 15:56:28 2017 New Revision: 318955 URL: https://svnweb.freebsd.org/changeset/base/318955 Log: libthr: fix warnings at WARNS=6 Fix more warnings about redundant declarations. Reviewed by: kib emaste MFC after: 3 days Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10932 Modified: head/lib/libthr/arch/aarch64/include/pthread_md.h head/lib/libthr/arch/arm/include/pthread_md.h head/lib/libthr/arch/mips/include/pthread_md.h head/lib/libthr/arch/powerpc/include/pthread_md.h head/lib/libthr/arch/riscv/include/pthread_md.h head/lib/libthr/thread/thr_private.h Modified: head/lib/libthr/arch/aarch64/include/pthread_md.h ============================================================================== --- head/lib/libthr/arch/aarch64/include/pthread_md.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/arch/aarch64/include/pthread_md.h Fri May 26 15:56:28 2017 (r318955) @@ -72,8 +72,6 @@ _tcb_get(void) return (tcb); } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { Modified: head/lib/libthr/arch/arm/include/pthread_md.h ============================================================================== --- head/lib/libthr/arch/arm/include/pthread_md.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/arch/arm/include/pthread_md.h Fri May 26 15:56:28 2017 (r318955) @@ -75,8 +75,6 @@ _tcb_get(void) #endif } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { Modified: head/lib/libthr/arch/mips/include/pthread_md.h ============================================================================== --- head/lib/libthr/arch/mips/include/pthread_md.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/arch/mips/include/pthread_md.h Fri May 26 15:56:28 2017 (r318955) @@ -120,8 +120,6 @@ _tcb_get(void) # endif /* ! __mips_n64 */ #endif /* ! TLS_USE_SYSARCH */ -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { Modified: head/lib/libthr/arch/powerpc/include/pthread_md.h ============================================================================== --- head/lib/libthr/arch/powerpc/include/pthread_md.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/arch/powerpc/include/pthread_md.h Fri May 26 15:56:28 2017 (r318955) @@ -80,8 +80,6 @@ _tcb_get(void) return ((struct tcb *)(_tp - TP_OFFSET)); } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { Modified: head/lib/libthr/arch/riscv/include/pthread_md.h ============================================================================== --- head/lib/libthr/arch/riscv/include/pthread_md.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/arch/riscv/include/pthread_md.h Fri May 26 15:56:28 2017 (r318955) @@ -78,8 +78,6 @@ _tcb_get(void) return ((struct tcb *)(_tp - TP_OFFSET)); } -extern struct pthread *_thr_initial; - static __inline struct pthread * _get_curthread(void) { Modified: head/lib/libthr/thread/thr_private.h ============================================================================== --- head/lib/libthr/thread/thr_private.h Fri May 26 15:55:03 2017 (r318954) +++ head/lib/libthr/thread/thr_private.h Fri May 26 15:56:28 2017 (r318955) @@ -69,6 +69,9 @@ __NULLABILITY_PRAGMA_PUSH WEAK_REF(func, SYM_FBP10(sym)); \ SYM_DEFAULT(sym, SYM_FBP10(sym), FBSDprivate_1.0) +struct pthread; +extern struct pthread *_thr_initial __hidden; + #include "pthread_md.h" #include "thr_umtx.h" #include "thread_db.h" @@ -711,7 +714,6 @@ extern int __isthreaded; */ extern char *_usrstack __hidden; -extern struct pthread *_thr_initial __hidden; /* For debugger */ extern int _libthr_debug; From owner-svn-src-head@freebsd.org Fri May 26 15:57:55 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 98C6CD83B00; Fri, 26 May 2017 15:57:55 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6ABA21C7B; Fri, 26 May 2017 15:57:55 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QFvsml088402; Fri, 26 May 2017 15:57:54 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QFvsK2088401; Fri, 26 May 2017 15:57:54 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201705261557.v4QFvsK2088401@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Fri, 26 May 2017 15:57:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318956 - head/lib/libthr 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.23 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, 26 May 2017 15:57:55 -0000 Author: vangyzen Date: Fri May 26 15:57:54 2017 New Revision: 318956 URL: https://svnweb.freebsd.org/changeset/base/318956 Log: libthr: increase WARNS to the default (6) ...and silence cast-align warnings from gcc. Reviewed by: kib MFC after: 3 days Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10935 Modified: head/lib/libthr/Makefile Modified: head/lib/libthr/Makefile ============================================================================== --- head/lib/libthr/Makefile Fri May 26 15:56:28 2017 (r318955) +++ head/lib/libthr/Makefile Fri May 26 15:57:54 2017 (r318956) @@ -16,8 +16,8 @@ MK_SSP= no LIB=thr SHLIB_MAJOR= 3 -WARNS?= 3 NO_WTHREAD_SAFETY=1 +NO_WCAST_ALIGN.gcc=1 # for gcc 4.2 CFLAGS+=-DPTHREAD_KERNEL CFLAGS+=-I${SRCTOP}/lib/libc/include -I${.CURDIR}/thread \ -I${SRCTOP}/include From owner-svn-src-head@freebsd.org Fri May 26 16:03:30 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 216B4D83D80; Fri, 26 May 2017 16:03:30 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E2501121E; Fri, 26 May 2017 16:03:29 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QG3SZr092577; Fri, 26 May 2017 16:03:28 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QG3SH0092576; Fri, 26 May 2017 16:03:28 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705261603.v4QG3SH0092576@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Fri, 26 May 2017 16:03:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318957 - 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.23 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, 26 May 2017 16:03:30 -0000 Author: emaste Date: Fri May 26 16:03:28 2017 New Revision: 318957 URL: https://svnweb.freebsd.org/changeset/base/318957 Log: rm stale ptrace dependencies after r305012 This is similar to r318912, except that ptrace.[sS] was previously a file in the source tree, not a generated assembly wrapper. Check for the existence of ptrace.[sS] in the .depend file to determine if we have to clean it up. This is a bit hackish and will not be left in place indefinitely, but provides a useful example case when investigating a better solution in bmake. Reviewed by: bdrewery Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D10930 Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Fri May 26 15:57:54 2017 (r318956) +++ head/Makefile.inc1 Fri May 26 16:03:28 2017 (r318957) @@ -710,6 +710,18 @@ _worldtmp: .PHONY # Dependencies cannot cope with certain source tree changes, particularly # with respect to removing source files and replacing generated files. # Handle these cases here in an ad-hoc fashion. +# 20160829 remove stale dependencies for ptrace stub, rewritten in C +# in r305012 +.for f in ptrace +.if exists(${OBJTREE}${.CURDIR}/lib/libc/.depend.${f}.o) + @if egrep -q '/${f}.[sS]' \ + ${OBJTREE}${.CURDIR}/lib/libc/.depend.${f}.o; then \ + echo Removing stale dependencies for ${f} syscall wrappers; \ + rm -f ${OBJTREE}${.CURDIR}/lib/libc/.depend.${f}.* \ + ${OBJTREE}${.CURDIR}/world32/${.CURDIR}/lib/libc/.depend.${f}.*; \ + fi +.endif +.endfor # 20170523 remove stale generated asm files for functions which are no longer # syscalls after r302092 (pipe) and r318736 (others) .for f in getdents lstat mknod pipe stat From owner-svn-src-head@freebsd.org Fri May 26 16:29:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EE568D832C2; Fri, 26 May 2017 16:29:01 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B162B10FF; Fri, 26 May 2017 16:29:01 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QGT0Z6000800; Fri, 26 May 2017 16:29:00 GMT (envelope-from tuexen@FreeBSD.org) Received: (from tuexen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QGT0K9000794; Fri, 26 May 2017 16:29:00 GMT (envelope-from tuexen@FreeBSD.org) Message-Id: <201705261629.v4QGT0K9000794@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tuexen set sender to tuexen@FreeBSD.org using -f From: Michael Tuexen Date: Fri, 26 May 2017 16:29:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318958 - 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.23 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, 26 May 2017 16:29:02 -0000 Author: tuexen Date: Fri May 26 16:29:00 2017 New Revision: 318958 URL: https://svnweb.freebsd.org/changeset/base/318958 Log: Use the SCTP_PCB_FLAGS_ACCEPTING flags to check for listeners. While there, use a macro for checking the listen state to allow for easier changes if required. This done to help glebius@ with his listen changes. Modified: head/sys/netinet/sctp_input.c head/sys/netinet/sctp_os_bsd.h head/sys/netinet/sctp_output.c head/sys/netinet/sctp_pcb.c head/sys/netinet/sctp_sysctl.c head/sys/netinet/sctp_usrreq.c Modified: head/sys/netinet/sctp_input.c ============================================================================== --- head/sys/netinet/sctp_input.c Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_input.c Fri May 26 16:29:00 2017 (r318958) @@ -161,13 +161,11 @@ sctp_handle_init(struct mbuf *m, int iph *abort_no_unlock = 1; goto outnow; } - /* We are only accepting if we have a socket with positive - * so_qlimit. */ + /* We are only accepting if we have a listening socket. */ if ((stcb == NULL) && ((inp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_GONE) || (inp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_ALLGONE) || - (inp->sctp_socket == NULL) || - (inp->sctp_socket->so_qlimit == 0))) { + (!SCTP_IS_LISTENING(inp)))) { /* * FIX ME ?? What about TCP model and we have a * match/restart case? Actually no fix is needed. the lookup @@ -1605,8 +1603,7 @@ sctp_process_cookie_existing(struct mbuf sctp_stop_all_cookie_timers(stcb); if (((stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) || (stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_IN_TCPPOOL)) && - (inp->sctp_socket->so_qlimit == 0) - ) { + (!SCTP_IS_LISTENING(inp))) { #if defined(__APPLE__) || defined(SCTP_SO_LOCK_TESTING) struct socket *so; #endif @@ -1806,7 +1803,7 @@ sctp_process_cookie_existing(struct mbuf if (((stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) || (stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_IN_TCPPOOL)) && - (inp->sctp_socket->so_qlimit == 0)) { + (!SCTP_IS_LISTENING(inp))) { #if defined(__APPLE__) || defined(SCTP_SO_LOCK_TESTING) struct socket *so; #endif @@ -2317,7 +2314,7 @@ sctp_process_cookie_new(struct mbuf *m, *notification = SCTP_NOTIFY_ASSOC_UP; if (((stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) || (stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_IN_TCPPOOL)) && - (inp->sctp_socket->so_qlimit == 0)) { + (!SCTP_IS_LISTENING(inp))) { /* * This is an endpoint that called connect() how it got a * cookie that is NEW is a bit of a mystery. It must be that @@ -2343,7 +2340,7 @@ sctp_process_cookie_new(struct mbuf *m, SCTP_SOCKET_UNLOCK(so, 1); #endif } else if ((stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) && - (inp->sctp_socket->so_qlimit)) { + (SCTP_IS_LISTENING(inp))) { /* * We don't want to do anything with this one. Since it is * the listening guy. The timer will get started for @@ -5205,7 +5202,9 @@ process_control_chunks: * longer listening. */ - if ((stcb == NULL) && (inp->sctp_socket->so_qlen >= inp->sctp_socket->so_qlimit)) { + if ((stcb == NULL) && + (!SCTP_IS_LISTENING(inp) || + inp->sctp_socket->so_qlen >= inp->sctp_socket->so_qlimit)) { if ((inp->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) && (SCTP_BASE_SYSCTL(sctp_abort_if_one_2_one_hits_limit))) { op_err = sctp_generate_cause(SCTP_CAUSE_OUT_OF_RESC, ""); Modified: head/sys/netinet/sctp_os_bsd.h ============================================================================== --- head/sys/netinet/sctp_os_bsd.h Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_os_bsd.h Fri May 26 16:29:00 2017 (r318958) @@ -462,8 +462,6 @@ sctp_get_mbuf_for_msg(unsigned int space #define SCTP_SHA256_UPDATE SHA256_Update #define SCTP_SHA256_FINAL(x,y) SHA256_Final((caddr_t)x, y) -#endif - #define SCTP_DECREMENT_AND_CHECK_REFCOUNT(addr) (atomic_fetchadd_int(addr, -1) == 1) #if defined(INVARIANTS) #define SCTP_SAVE_ATOMIC_DECREMENT(addr, val) \ @@ -484,3 +482,7 @@ sctp_get_mbuf_for_msg(unsigned int space } \ } #endif + +#define SCTP_IS_LISTENING(inp) ((inp->sctp_flags & SCTP_PCB_FLAGS_ACCEPTING) != 0) + +#endif Modified: head/sys/netinet/sctp_output.c ============================================================================== --- head/sys/netinet/sctp_output.c Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_output.c Fri May 26 16:29:00 2017 (r318958) @@ -12595,7 +12595,7 @@ sctp_lower_sosend(struct socket *so, (void *)addr, sndlen); if ((inp->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) && - (inp->sctp_socket->so_qlimit)) { + SCTP_IS_LISTENING(inp)) { /* The listener can NOT send */ SCTP_LTRACE_ERR_RET(NULL, NULL, NULL, SCTP_FROM_SCTP_OUTPUT, ENOTCONN); error = ENOTCONN; Modified: head/sys/netinet/sctp_pcb.c ============================================================================== --- head/sys/netinet/sctp_pcb.c Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_pcb.c Fri May 26 16:29:00 2017 (r318958) @@ -1311,7 +1311,7 @@ sctp_findassociation_ep_addr(struct sctp * it is the acceptor, then do the special_lookup to hash * and find the real inp. */ - if ((inp->sctp_socket) && (inp->sctp_socket->so_qlimit)) { + if ((inp->sctp_socket) && SCTP_IS_LISTENING(inp)) { /* to is peer addr, from is my addr */ stcb = sctp_tcb_special_locate(inp_p, remote, local, netp, inp->def_vrf_id); @@ -1884,7 +1884,7 @@ sctp_swap_inpcb_for_listen(struct sctp_i if (tinp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_GONE) { continue; } - if (tinp->sctp_socket->so_qlimit) { + if (SCTP_IS_LISTENING(tinp)) { continue; } SCTP_INP_WLOCK(tinp); Modified: head/sys/netinet/sctp_sysctl.c ============================================================================== --- head/sys/netinet/sctp_sysctl.c Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_sysctl.c Fri May 26 16:29:00 2017 (r318958) @@ -410,6 +410,7 @@ sctp_sysctl_handle_assoclist(SYSCTL_HAND xinpcb.socket = inp->sctp_socket; so = inp->sctp_socket; if ((so == NULL) || + (!SCTP_IS_LISTENING(inp)) || (inp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_GONE)) { xinpcb.qlen = 0; xinpcb.maxqlen = 0; Modified: head/sys/netinet/sctp_usrreq.c ============================================================================== --- head/sys/netinet/sctp_usrreq.c Fri May 26 16:03:28 2017 (r318957) +++ head/sys/netinet/sctp_usrreq.c Fri May 26 16:29:00 2017 (r318958) @@ -7039,7 +7039,7 @@ sctp_listen(struct socket *so, int backl if (tinp && (tinp != inp) && ((tinp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_ALLGONE) == 0) && ((tinp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_GONE) == 0) && - (tinp->sctp_socket->so_qlimit)) { + (SCTP_IS_LISTENING(tinp))) { /* * we have a listener already and * its not this inp. @@ -7083,7 +7083,7 @@ sctp_listen(struct socket *so, int backl if (tinp && (tinp != inp) && ((tinp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_ALLGONE) == 0) && ((tinp->sctp_flags & SCTP_PCB_FLAGS_SOCKET_GONE) == 0) && - (tinp->sctp_socket->so_qlimit)) { + (SCTP_IS_LISTENING(tinp))) { /* * we have a listener already and its not * this inp. @@ -7137,6 +7137,7 @@ sctp_listen(struct socket *so, int backl return (error); } } + SCTP_INP_WLOCK(inp); SOCK_LOCK(so); /* It appears for 7.0 and on, we must always call this. */ solisten_proto(so, backlog); @@ -7144,11 +7145,13 @@ sctp_listen(struct socket *so, int backl /* remove the ACCEPTCONN flag for one-to-many sockets */ so->so_options &= ~SO_ACCEPTCONN; } - if (backlog == 0) { - /* turning off listen */ - so->so_options &= ~SO_ACCEPTCONN; + if (backlog > 0) { + inp->sctp_flags |= SCTP_PCB_FLAGS_ACCEPTING; + } else { + inp->sctp_flags &= ~SCTP_PCB_FLAGS_ACCEPTING; } SOCK_UNLOCK(so); + SCTP_INP_WUNLOCK(inp); return (error); } From owner-svn-src-head@freebsd.org Fri May 26 16:29:57 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 52BD9D8335C; Fri, 26 May 2017 16:29:57 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2346B129F; Fri, 26 May 2017 16:29:57 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QGTuKT000869; Fri, 26 May 2017 16:29:56 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QGTuLc000868; Fri, 26 May 2017 16:29:56 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201705261629.v4QGTuLc000868@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Fri, 26 May 2017 16:29:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318959 - 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.23 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, 26 May 2017 16:29:57 -0000 Author: dim Date: Fri May 26 16:29:55 2017 New Revision: 318959 URL: https://svnweb.freebsd.org/changeset/base/318959 Log: Define a new __INO64 macro in , to indicate the system uses 64-bit inode numbers. Programs can use this to avoid including , with its associated namespace pollution. Reviewed by: kib Modified: head/sys/sys/_types.h Modified: head/sys/sys/_types.h ============================================================================== --- head/sys/sys/_types.h Fri May 26 16:29:00 2017 (r318958) +++ head/sys/sys/_types.h Fri May 26 16:29:55 2017 (r318959) @@ -120,4 +120,11 @@ typedef union { typedef __uintmax_t __rman_res_t; +/* + * When the following macro is defined, the system uses 64-bit inode numbers. + * Programs can use this to avoid including , with its associated + * namespace pollution. + */ +#define __INO64 + #endif /* !_SYS__TYPES_H_ */ From owner-svn-src-head@freebsd.org Fri May 26 16:36:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5675BD8359D; Fri, 26 May 2017 16:36:32 +0000 (UTC) (envelope-from dab@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 229F61766; Fri, 26 May 2017 16:36:32 +0000 (UTC) (envelope-from dab@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QGaVq4004780; Fri, 26 May 2017 16:36:31 GMT (envelope-from dab@FreeBSD.org) Received: (from dab@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QGaU5L004774; Fri, 26 May 2017 16:36:30 GMT (envelope-from dab@FreeBSD.org) Message-Id: <201705261636.v4QGaU5L004774@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dab set sender to dab@FreeBSD.org using -f From: David Bright Date: Fri, 26 May 2017 16:36:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318960 - in head/usr.sbin/newsyslog: . tests 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.23 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, 26 May 2017 16:36:32 -0000 Author: dab Date: Fri May 26 16:36:30 2017 New Revision: 318960 URL: https://svnweb.freebsd.org/changeset/base/318960 Log: Add newsyslog capability to write RFC5424 compliant rotation message. This modification adds the capability to newsyslog to write the rotation message in a format that is compliant with RFC5424. This capability is enabled on a per-log file basis through a new value ("T") in the flags field in newsyslog.conf. This is useful on systems that use the RFC5424 format for log files so that the rotation message format matches that of the other log messages. There has been recent mention of adding an RFC5424 compliant mode to syslogd and at least one alternative system log daemon (rsyslogd) that already has the capability to use that format. Reviewed by: vangyzen, ngie Approved by: vangyzen (mentor) MFC after: 2 months Relnotes: yes Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D10253 Modified: head/usr.sbin/newsyslog/extern.h head/usr.sbin/newsyslog/newsyslog.8 head/usr.sbin/newsyslog/newsyslog.c head/usr.sbin/newsyslog/newsyslog.conf.5 head/usr.sbin/newsyslog/ptimes.c head/usr.sbin/newsyslog/tests/legacy_test.sh Modified: head/usr.sbin/newsyslog/extern.h ============================================================================== --- head/usr.sbin/newsyslog/extern.h Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/extern.h Fri May 26 16:36:30 2017 (r318960) @@ -60,6 +60,8 @@ int ptime_free(struct ptime_data *_pti int ptime_relparse(struct ptime_data *_ptime, int _parseopts, time_t _basetime, const char *_str); const char *ptimeget_ctime(const struct ptime_data *_ptime); +char *ptimeget_ctime_rfc5424(const struct ptime_data *_ptime, + char *timebuf, size_t bufsize); double ptimeget_diff(const struct ptime_data *_minuend, const struct ptime_data *_subtrahend); time_t ptimeget_secs(const struct ptime_data *_ptime); Modified: head/usr.sbin/newsyslog/newsyslog.8 ============================================================================== --- head/usr.sbin/newsyslog/newsyslog.8 Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/newsyslog.8 Fri May 26 16:36:30 2017 (r318960) @@ -17,7 +17,7 @@ .\" the suitability of this software for any purpose. It is .\" provided "as is" without express or implied warranty. .\" -.Dd April 15, 2017 +.Dd May 19, 2017 .Dt NEWSYSLOG 8 .Os .Sh NAME @@ -125,7 +125,8 @@ reasons for either trimming that log or Cause .Nm not to trim the logs, but to print out what it would do if this option -were not specified. This option implies the +were not specified. +This option implies the .Fl r option. .It Fl r Modified: head/usr.sbin/newsyslog/newsyslog.c ============================================================================== --- head/usr.sbin/newsyslog/newsyslog.c Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/newsyslog.c Fri May 26 16:36:30 2017 (r318960) @@ -79,6 +79,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -132,6 +133,8 @@ __FBSDID("$FreeBSD$"); #define CE_NODUMP 0x0200 /* Set 'nodump' on newly created log file. */ #define CE_PID2CMD 0x0400 /* Replace PID file with a shell command.*/ +#define CE_RFC5424 0x0800 /* Use RFC5424 format rotation message */ + #define MIN_PID 5 /* Don't touch pids lower than this */ #define MAX_PID 99999 /* was lower, see /usr/include/sys/proc.h */ @@ -247,6 +250,15 @@ static struct ptime_data *timenow; /* Th #define DAYTIME_LEN 16 static char daytime[DAYTIME_LEN];/* The current time in human readable form, * used for rotation-tracking messages. */ + +/* Another buffer to hold the current time in RFC5424 format. Fractional + * seconds are allowed by the RFC, but are not included in the + * rotation-tracking messages written by newsyslog and so are not accounted for + * in the length below. + */ +#define DAYTIME_RFC5424_LEN sizeof("YYYY-MM-DDTHH:MM:SS+00:00") +static char daytime_rfc5424[DAYTIME_RFC5424_LEN]; + static char hostname[MAXHOSTNAMELEN]; /* hostname */ static const char *path_syslogpid = _PATH_SYSLOGPID; @@ -630,6 +642,7 @@ parse_args(int argc, char **argv) timenow = ptime_init(NULL); ptimeset_time(timenow, time(NULL)); strlcpy(daytime, ptimeget_ctime(timenow) + 4, DAYTIME_LEN); + ptimeget_ctime_rfc5424(timenow, daytime_rfc5424, DAYTIME_RFC5424_LEN); /* Let's get our hostname */ (void)gethostname(hostname, sizeof(hostname)); @@ -1296,11 +1309,14 @@ no_trimat: case 'r': working->flags |= CE_PID2CMD; break; + case 't': + working->flags |= CE_RFC5424; + break; case 'u': working->flags |= CE_SIGNALGROUP; break; case 'w': - /* Depreciated flag - keep for compatibility purposes */ + /* Deprecated flag - keep for compatibility purposes */ break; case 'x': working->compress = COMPRESS_XZ; @@ -2101,7 +2117,7 @@ save_sigwork(const struct conf_entry *en tmpsiz = sizeof(struct sigwork_entry) + strlen(ent->pid_cmd_file) + 1; stmp = malloc(tmpsiz); - + stmp->sw_runcmd = 0; /* If this is a command to run we just set the flag and run command */ if (ent->flags & CE_PID2CMD) { @@ -2257,15 +2273,34 @@ log_trim(const char *logname, const stru xtra = ""; if (log_ent->def_cfg) xtra = " using rule"; - if (log_ent->firstcreate) - fprintf(f, "%s %s newsyslog[%d]: logfile first created%s\n", - daytime, hostname, (int) getpid(), xtra); - else if (log_ent->r_reason != NULL) - fprintf(f, "%s %s newsyslog[%d]: logfile turned over%s%s\n", - daytime, hostname, (int) getpid(), log_ent->r_reason, xtra); - else - fprintf(f, "%s %s newsyslog[%d]: logfile turned over%s\n", - daytime, hostname, (int) getpid(), xtra); + if (log_ent->flags & CE_RFC5424) { + if (log_ent->firstcreate) { + fprintf(f, "<%d>1 %s %s newsyslog %d - - %s%s\n", + LOG_MAKEPRI(LOG_USER, LOG_INFO), + daytime_rfc5424, hostname, getpid(), + "logfile first created", xtra); + } else if (log_ent->r_reason != NULL) { + fprintf(f, "<%d>1 %s %s newsyslog %d - - %s%s%s\n", + LOG_MAKEPRI(LOG_USER, LOG_INFO), + daytime_rfc5424, hostname, getpid(), + "logfile turned over", log_ent->r_reason, xtra); + } else { + fprintf(f, "<%d>1 %s %s newsyslog %d - - %s%s\n", + LOG_MAKEPRI(LOG_USER, LOG_INFO), + daytime_rfc5424, hostname, getpid(), + "logfile turned over", xtra); + } + } else { + if (log_ent->firstcreate) + fprintf(f, "%s %s newsyslog[%d]: logfile first created%s\n", + daytime, hostname, getpid(), xtra); + else if (log_ent->r_reason != NULL) + fprintf(f, "%s %s newsyslog[%d]: logfile turned over%s%s\n", + daytime, hostname, getpid(), log_ent->r_reason, xtra); + else + fprintf(f, "%s %s newsyslog[%d]: logfile turned over%s\n", + daytime, hostname, getpid(), xtra); + } if (fclose(f) == EOF) err(1, "log_trim: fclose"); return (0); Modified: head/usr.sbin/newsyslog/newsyslog.conf.5 ============================================================================== --- head/usr.sbin/newsyslog/newsyslog.conf.5 Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/newsyslog.conf.5 Fri May 26 16:36:30 2017 (r318960) @@ -21,7 +21,7 @@ .\" the suitability of this software for any purpose. It is .\" provided "as is" without express or implied warranty. .\" -.Dd April 15, 2017 +.Dd May 19, 2017 .Dt NEWSYSLOG.CONF 5 .Os .Sh NAME @@ -242,7 +242,7 @@ rotate at the first day of every month a (i.e., the start of the day; same as .Li @01T00 ) .It Li $M5D6 -rotate on every 5th day of month at 6:00 +rotate on every fifth day of month at 6:00 (same as .Li @05T06 ) .El @@ -319,6 +319,11 @@ will run shell command defined in .Ar path_to_pid_cmd_file after rotation instead of trying to send signal to a process id stored in the file. +.It Cm T +if this flag is set the informational rotation message written to +the log file will be in the format specified by RFC5424. +Normally, the rotation message is written in the traditional (RFC3164) +syslog format. .It Cm U indicates that the file specified by .Ar path_to_pid_cmd_file @@ -395,6 +400,17 @@ entry: .Xr chown 8 , .Xr newsyslog 8 , .Xr syslogd 8 +.Pp +.Rs +.%A C. Lonvick +.%T The BSD syslog Protocol +.%O RFC3164 +.Re +.Rs +.%A R. Gerhards +.%T The Syslog Protocol +.%O RFC5424 +.Re .Sh HISTORY This manual page first appeared in .Fx 4.10 . Modified: head/usr.sbin/newsyslog/ptimes.c ============================================================================== --- head/usr.sbin/newsyslog/ptimes.c Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/ptimes.c Fri May 26 16:36:30 2017 (r318960) @@ -478,6 +478,75 @@ ptimeget_ctime(const struct ptime_data * return (ctime(&ptime->tsecs)); } +/* + * Generate a time of day string in an RFC5424 compatible format. Return a + * pointer to the buffer with the timestamp string or NULL if an error. If the + * time is not supplied, cannot be converted to local time, or the resulting + * string would overflow the buffer, the returned string will be the RFC5424 + * NILVALUE. + */ +char * +ptimeget_ctime_rfc5424(const struct ptime_data *ptime, + char *timebuf, size_t bufsize) +{ + static const char NILVALUE[] = {"-"}; /* RFC5424 specified NILVALUE */ + int chars; + struct tm tm; + int tz_hours; + int tz_mins; + long tz_offset; + char tz_sign; + + if (timebuf == NULL) { + return (NULL); + } + + if (bufsize < sizeof(NILVALUE)) { + return (NULL); + } + + /* + * Convert to localtime. RFC5424 mandates the use of the NILVALUE if + * the time cannot be obtained, so use that if there is an error in the + * conversion. + */ + if (ptime == NULL || localtime_r(&(ptime->tsecs), &tm) == NULL) { + strlcpy(timebuf, NILVALUE, bufsize); + return (timebuf); + } + + /* + * Convert the time to a string in RFC5424 format. The conversion + * cannot be done with strftime() because it cannot produce the correct + * timezone offset format. + */ + if (tm.tm_gmtoff < 0) { + tz_sign = '-'; + tz_offset = -tm.tm_gmtoff; + } else { + tz_sign = '+'; + tz_offset = tm.tm_gmtoff; + } + + tz_hours = tz_offset / 3600; + tz_mins = (tz_offset % 3600) / 60; + + chars = snprintf(timebuf, bufsize, + "%04d-%02d-%02d" /* date */ + "T%02d:%02d:%02d" /* time */ + "%c%02d:%02d", /* time zone offset */ + tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday, + tm.tm_hour, tm.tm_min, tm.tm_sec, + tz_sign, tz_hours, tz_mins); + + /* If the timestamp is too big for timebuf, return the NILVALUE. */ + if (chars >= (int)bufsize) { + strlcpy(timebuf, NILVALUE, bufsize); + } + + return (timebuf); +} + double ptimeget_diff(const struct ptime_data *minuend, const struct ptime_data *subtrahend) Modified: head/usr.sbin/newsyslog/tests/legacy_test.sh ============================================================================== --- head/usr.sbin/newsyslog/tests/legacy_test.sh Fri May 26 16:29:55 2017 (r318959) +++ head/usr.sbin/newsyslog/tests/legacy_test.sh Fri May 26 16:36:30 2017 (r318960) @@ -2,6 +2,15 @@ # $FreeBSD$ +# A regular expression matching the format of an RFC-5424 log line header, +# including the timestamp up through the seconds indicator; it does not include +# the (optional) timezone offset. +RFC5424_FMT='^<[0-9][0-9]*>1 [0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}' + +# A regular expression matching the format of an RFC-3164 (traditional syslog) +# log line header, including the timestamp. +RFC3164_FMT='^[A-Z][a-z]{2} [ 0-9][0-9] [0-9]{2}:[0-9]{2}:[0-9]{2}' + COUNT=0 TMPDIR=$(pwd)/work if [ $? -ne 0 ]; then @@ -98,6 +107,32 @@ ckntfe() fi } +# Verify that the specified file has RFC-5424 rotation messages. +ckrfc5424() +{ + local lc=$(wc -l $1 | cut -w -f2) + local rc=$(grep -cE "${RFC5424_FMT}" $1) + if [ "$lc" -eq 0 -o "$rc" -eq 0 -o "$lc" -ne "$rc" ] + then + notok + else + ok + fi +} + + +# Verify that the specified file has RFC-3164 rotation messages. +ckrfc3164() +{ + local lc=$(wc -l $1 | cut -w -f2) + local rc=$(grep -cE "${RFC3164_FMT}" $1) + if [ "$lc" -eq 0 -o "$rc" -eq 0 -o "$lc" -ne "$rc" ] + then + notok + else + ok + fi +} # A part of a test succeeds @@ -381,6 +416,45 @@ tests_time_rotate() { tmpdir_clean } +tests_rfc5424() { + ext="$1" + dir="$2" + + if [ -n "$dir" ]; then + newsyslog_args=" -a ${dir}" + name_postfix="${ext} archive dir" + else + newsyslog_args="" + name_postfix="${ext}" + fi + + tmpdir_create + + begin "RFC-5424 - create file ${name_postfix}" -newdir + run_newsyslog -C + ckfe $LOGFNAME + cknt ${dir}${LOGFNAME}.0${ext} + ckfe $LOGFNAME5424 + cknt ${dir}${LOGFNAME5424}.0${ext} + ckrfc3164 ${LOGFNAME} + ckrfc5424 ${LOGFNAME5424} + end + + begin "RFC-5424 - rotate normal 1 ${name_postfix}" + run_newsyslog $newsyslog_args + ckfe ${LOGFNAME} + ckfe ${dir}${LOGFNAME}.0${ext} + ckfe $LOGFNAME5424 + ckfe ${dir}${LOGFNAME5424}.0${ext} + ckrfc3164 ${LOGFNAME} + ckrfc3164 ${dir}${LOGFNAME}.0${ext} + ckrfc5424 ${LOGFNAME5424} + ckrfc5424 ${dir}${LOGFNAME5424}.0${ext} + end + + tmpdir_clean +} + echo 1..126 mkdir -p ${TMPDIR} cd ${TMPDIR} @@ -388,6 +462,10 @@ cd ${TMPDIR} LOGFNAME=foo.log LOGFPATH=${TMPDIR}/log/${LOGFNAME} +# Log file for RFC-5424 testing +LOGFNAME5424=foo5424.log +LOGFPATH5424=${TMPDIR}/log/${LOGFNAME5424} + # Normal, no archive dir, keep X files echo "$LOGFPATH 640 0 * @T00 NC" > newsyslog.conf tests_normal_rotate_keepn 0 @@ -454,4 +532,9 @@ tests_time_rotate "gz" "${TMPDIR}/alog/" echo "$LOGFPATH 640 3 * @T00 NCJ" > newsyslog.conf tests_time_rotate "bz2" "${TMPDIR}/alog/" +# RFC-5424; Normal, no archive dir +echo "$LOGFPATH5424 640 3 * @T00 NCT" > newsyslog.conf +echo "$LOGFPATH 640 3 * @T00 NC" >> newsyslog.conf +tests_rfc5424 + rm -rf "${TMPDIR}" From owner-svn-src-head@freebsd.org Fri May 26 17:03:28 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5DA59D83E62; Fri, 26 May 2017 17:03:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from mail.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3E2E81F4F; Fri, 26 May 2017 17:03:28 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by mail.baldwin.cx (Postfix) with ESMTPSA id DCE5A10AFA2; Fri, 26 May 2017 13:03:26 -0400 (EDT) From: John Baldwin To: Michael Tuexen Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318879 - in head: lib/libsysdecode usr.bin/truss Date: Fri, 26 May 2017 09:48:12 -0700 Message-ID: <2215249.57b5qTibQB@ralph.baldwin.cx> User-Agent: KMail/4.14.10 (FreeBSD/11.0-STABLE; KDE/4.14.10; amd64; ; ) In-Reply-To: <201705251427.v4PERsWK053449@repo.freebsd.org> References: <201705251427.v4PERsWK053449@repo.freebsd.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.4.3 (mail.baldwin.cx); Fri, 26 May 2017 13:03:26 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.99.2 at mail.baldwin.cx X-Virus-Status: Clean X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 26 May 2017 17:03:28 -0000 On Thursday, May 25, 2017 02:27:54 PM Michael Tuexen wrote: > Author: tuexen > Date: Thu May 25 14:27:54 2017 > New Revision: 318879 > URL: https://svnweb.freebsd.org/changeset/base/318879 > > Log: > Improve the decoding of the third argument of the socket() call. > > Decoding of the third argument depends on the first one. For doing this, > add a corresponding function to libsysdecode. > > Thanks to jhb@ for suggesting this. Thanks! -- John Baldwin From owner-svn-src-head@freebsd.org Fri May 26 17:44:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BECDCD83674; Fri, 26 May 2017 17:44:48 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7E1C612AA; Fri, 26 May 2017 17:44:48 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QHilde034077; Fri, 26 May 2017 17:44:47 GMT (envelope-from avg@FreeBSD.org) Received: (from avg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QHilml034076; Fri, 26 May 2017 17:44:47 GMT (envelope-from avg@FreeBSD.org) Message-Id: <201705261744.v4QHilml034076@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: avg set sender to avg@FreeBSD.org using -f From: Andriy Gapon Date: Fri, 26 May 2017 17:44:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318962 - head/sys/cam/ata 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.23 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, 26 May 2017 17:44:48 -0000 Author: avg Date: Fri May 26 17:44:47 2017 New Revision: 318962 URL: https://svnweb.freebsd.org/changeset/base/318962 Log: Allow PROBE_SPINUP to fail in CAM ATA transport The motivation for this is two-fold. 1. Some old WD SATA disks may appear as if they need to be spun up when they are already spinning. Those disks would respond with an error to the spin-up request. 2. Even if we really fail to spin up the disk, we still can try to proceed to the subsequent phases. If we fail later on, then no difference. Otherwise we get a chance to communicate with the disk which is better than completely ignoring it, because a user can try to recover the disk. Reviewed by: mav MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D10896 Modified: head/sys/cam/ata/ata_xpt.c Modified: head/sys/cam/ata/ata_xpt.c ============================================================================== --- head/sys/cam/ata/ata_xpt.c Fri May 26 17:11:27 2017 (r318961) +++ head/sys/cam/ata/ata_xpt.c Fri May 26 17:44:47 2017 (r318962) @@ -800,6 +800,16 @@ out: goto noerror; /* + * Some old WD SATA disks have broken SPINUP handling. + * If we really fail to spin up the disk, then there will be + * some media access errors later on, but at least we will + * have a device to interact with for recovery attempts. + */ + } else if (softc->action == PROBE_SPINUP && + status == CAM_ATA_STATUS_ERROR) { + goto noerror; + + /* * Some HP SATA disks report supported DMA Auto-Activation, * but return ABORT on attempt to enable it. */ From owner-svn-src-head@freebsd.org Fri May 26 20:15:35 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 12BD9D831FA; Fri, 26 May 2017 20:15:35 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BBA7C1C0F; Fri, 26 May 2017 20:15:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QKFXhf096293; Fri, 26 May 2017 20:15:33 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QKFXeK096292; Fri, 26 May 2017 20:15:33 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201705262015.v4QKFXeK096292@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Fri, 26 May 2017 20:15:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318966 - 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.23 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, 26 May 2017 20:15:35 -0000 Author: mav Date: Fri May 26 20:15:33 2017 New Revision: 318966 URL: https://svnweb.freebsd.org/changeset/base/318966 Log: Improve applying unified capabilities to the lagg ports. Some NICs have some capabilities dependent, so that disabling one require disabling some other (TXCSUM/RXCSUM on em). This code tries to reach the consensus more insistently. PR: 219453 MFC after: 1 week Modified: head/sys/net/if_lagg.c Modified: head/sys/net/if_lagg.c ============================================================================== --- head/sys/net/if_lagg.c Fri May 26 19:19:47 2017 (r318965) +++ head/sys/net/if_lagg.c Fri May 26 20:15:33 2017 (r318966) @@ -572,24 +572,41 @@ static void lagg_capabilities(struct lagg_softc *sc) { struct lagg_port *lp; - int cap = ~0, ena = ~0; - u_long hwa = ~0UL; + int cap, ena, pena; + uint64_t hwa; struct ifnet_hw_tsomax hw_tsomax; LAGG_XLOCK_ASSERT(sc); - memset(&hw_tsomax, 0, sizeof(hw_tsomax)); + /* Get common enabled capabilities for the lagg ports */ + ena = ~0; + SLIST_FOREACH(lp, &sc->sc_ports, lp_entries) + ena &= lp->lp_ifp->if_capenable; + ena = (ena == ~0 ? 0 : ena); + + /* + * Apply common enabled capabilities back to the lagg ports. + * May require several iterations if they are dependent. + */ + do { + pena = ena; + SLIST_FOREACH(lp, &sc->sc_ports, lp_entries) { + lagg_setcaps(lp, ena); + ena &= lp->lp_ifp->if_capenable; + } + } while (pena != ena); - /* Get capabilities from the lagg ports */ + /* Get other capabilities from the lagg ports */ + cap = ~0; + hwa = ~(uint64_t)0; + memset(&hw_tsomax, 0, sizeof(hw_tsomax)); SLIST_FOREACH(lp, &sc->sc_ports, lp_entries) { cap &= lp->lp_ifp->if_capabilities; - ena &= lp->lp_ifp->if_capenable; hwa &= lp->lp_ifp->if_hwassist; if_hw_tsomax_common(lp->lp_ifp, &hw_tsomax); } cap = (cap == ~0 ? 0 : cap); - ena = (ena == ~0 ? 0 : ena); - hwa = (hwa == ~0 ? 0 : hwa); + hwa = (hwa == ~(uint64_t)0 ? 0 : hwa); if (sc->sc_ifp->if_capabilities != cap || sc->sc_ifp->if_capenable != ena || @@ -604,10 +621,6 @@ lagg_capabilities(struct lagg_softc *sc) if_printf(sc->sc_ifp, "capabilities 0x%08x enabled 0x%08x\n", cap, ena); } - - /* Apply unified capabilities back to the lagg ports. */ - SLIST_FOREACH(lp, &sc->sc_ports, lp_entries) - lagg_setcaps(lp, ena); } static int From owner-svn-src-head@freebsd.org Fri May 26 20:20:41 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B536BD83440; Fri, 26 May 2017 20:20:41 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 909161F3F; Fri, 26 May 2017 20:20:41 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QKKekQ096649; Fri, 26 May 2017 20:20:40 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QKKecL096648; Fri, 26 May 2017 20:20:40 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201705262020.v4QKKecL096648@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Fri, 26 May 2017 20:20:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318967 - head/sys/dev/cxgbe/crypto 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.23 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, 26 May 2017 20:20:41 -0000 Author: jhb Date: Fri May 26 20:20:40 2017 New Revision: 318967 URL: https://svnweb.freebsd.org/changeset/base/318967 Log: Fail large requests with EFBIG. The adapter firmware in general does not accept PDUs larger than 64k - 1 bytes in size. Sending crypto requests larger than this size result in hangs or incorrect output, so reject them with EFBIG. For requests chaining an AES cipher with an HMAC, the firmware appears to require slightly smaller requests (around 512 bytes). Sponsored by: Chelsio Communications Modified: head/sys/dev/cxgbe/crypto/t4_crypto.c Modified: head/sys/dev/cxgbe/crypto/t4_crypto.c ============================================================================== --- head/sys/dev/cxgbe/crypto/t4_crypto.c Fri May 26 20:15:33 2017 (r318966) +++ head/sys/dev/cxgbe/crypto/t4_crypto.c Fri May 26 20:20:40 2017 (r318967) @@ -117,6 +117,13 @@ __FBSDID("$FreeBSD$"); #define MAX_RX_PHYS_DSGL_SGE 32 #define DSGL_SGE_MAXLEN 65535 +/* + * The adapter only supports requests with a total input or output + * length of 64k-1 or smaller. Longer requests either result in hung + * requests or incorrect results. + */ +#define MAX_REQUEST_SIZE 65535 + static MALLOC_DEFINE(M_CCR, "ccr", "Chelsio T6 crypto"); struct ccr_session_hmac { @@ -412,6 +419,12 @@ ccr_hmac(struct ccr_softc *sc, uint32_t u_int imm_len, iopad_size; int error, sgl_nsegs, sgl_len; + crd = crp->crp_desc; + + /* Reject requests with too large of an input buffer. */ + if (crd->crd_len > MAX_REQUEST_SIZE) + return (EFBIG); + axf = s->hmac.auth_hash; /* PADs must be 128-bit aligned. */ @@ -425,7 +438,6 @@ ccr_hmac(struct ccr_softc *sc, uint32_t hash_size_in_response = axf->hashsize; transhdr_len = HASH_TRANSHDR_SIZE(kctx_len); - crd = crp->crp_desc; if (ccr_use_imm_data(transhdr_len, crd->crd_len)) { imm_len = crd->crd_len; sgl_nsegs = 0; @@ -538,6 +550,10 @@ ccr_blkcipher(struct ccr_softc *sc, uint (crd->crd_len % AES_BLOCK_LEN) != 0) return (EINVAL); + /* Reject requests with too large of an input buffer. */ + if (crd->crd_len > MAX_REQUEST_SIZE) + return (EFBIG); + iv_loc = IV_NOP; if (crd->crd_flags & CRD_F_ENCRYPT) { op_type = CHCR_ENCRYPT_OP; @@ -785,6 +801,13 @@ ccr_authenc(struct ccr_softc *sc, uint32 * the hash when encrypting. For decryption it only contains * the plain text. */ + if (op_type == CHCR_ENCRYPT_OP) { + if (crde->crd_len + hash_size_in_response > MAX_REQUEST_SIZE) + return (EFBIG); + } else { + if (crde->crd_len > MAX_REQUEST_SIZE) + return (EFBIG); + } sglist_reset(sc->sg_dsgl); error = sglist_append_sglist(sc->sg_dsgl, sc->sg_crp, crde->crd_skip, crde->crd_len); @@ -824,6 +847,17 @@ ccr_authenc(struct ccr_softc *sc, uint32 } else aad_len = 0; input_len = aad_len + crde->crd_len; + + /* + * The firmware hangs if sent a request which is a + * bit smaller than MAX_REQUEST_SIZE. In particular, the + * firmware appears to require 512 - 16 bytes of spare room + * along with the size of the hash even if the hash isn't + * included in the input buffer. + */ + if (input_len + roundup2(axf->hashsize, 16) + (512 - 16) > + MAX_REQUEST_SIZE) + return (EFBIG); if (op_type == CHCR_DECRYPT_OP) input_len += hash_size_in_response; if (ccr_use_imm_data(transhdr_len, s->blkcipher.iv_len + input_len)) { @@ -1105,6 +1139,13 @@ ccr_gcm(struct ccr_softc *sc, uint32_t s * the tag when encrypting. For decryption it only contains * the plain text. */ + if (op_type == CHCR_ENCRYPT_OP) { + if (crde->crd_len + hash_size_in_response > MAX_REQUEST_SIZE) + return (EFBIG); + } else { + if (crde->crd_len > MAX_REQUEST_SIZE) + return (EFBIG); + } sglist_reset(sc->sg_dsgl); error = sglist_append_sglist(sc->sg_dsgl, sc->sg_crp, crde->crd_skip, crde->crd_len); @@ -1136,6 +1177,8 @@ ccr_gcm(struct ccr_softc *sc, uint32_t s input_len = crda->crd_len + crde->crd_len; if (op_type == CHCR_DECRYPT_OP) input_len += hash_size_in_response; + if (input_len > MAX_REQUEST_SIZE) + return (EFBIG); if (ccr_use_imm_data(transhdr_len, iv_len + input_len)) { imm_len = input_len; sgl_nsegs = 0; From owner-svn-src-head@freebsd.org Fri May 26 21:10:02 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BE69DD830C0; Fri, 26 May 2017 21:10:02 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 73D911769; Fri, 26 May 2017 21:10:02 +0000 (UTC) (envelope-from brooks@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QLA17M017080; Fri, 26 May 2017 21:10:01 GMT (envelope-from brooks@FreeBSD.org) Received: (from brooks@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QLA15h017078; Fri, 26 May 2017 21:10:01 GMT (envelope-from brooks@FreeBSD.org) Message-Id: <201705262110.v4QLA15h017078@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: brooks set sender to brooks@FreeBSD.org using -f From: Brooks Davis Date: Fri, 26 May 2017 21:10:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318968 - head/usr.bin/procstat 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.23 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, 26 May 2017 21:10:02 -0000 Author: brooks Date: Fri May 26 21:10:01 2017 New Revision: 318968 URL: https://svnweb.freebsd.org/changeset/base/318968 Log: Add missing usage and getopt(3) options - Add the missing option 'n' to the getopt(3) string - Add the missing options 'libxo' and 'N' to the usage message - Add the missing options 'M' and 'N' to the man-page Submitted by: Keegan Drake H.P. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D10915 Modified: head/usr.bin/procstat/procstat.1 head/usr.bin/procstat/procstat.c Modified: head/usr.bin/procstat/procstat.1 ============================================================================== --- head/usr.bin/procstat/procstat.1 Fri May 26 20:20:40 2017 (r318967) +++ head/usr.bin/procstat/procstat.1 Fri May 26 21:10:01 2017 (r318968) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 11, 2017 +.Dd May 26, 2017 .Dt PROCSTAT 1 .Os .Sh NAME @@ -35,6 +35,8 @@ .Nm .Op Fl -libxo .Op Fl CHhn +.Op Fl M Ar core +.Op Fl N Ar system .Op Fl w Ar interval .Op Fl b | c | e | f | i | j | k | l | L | r | s | S | t | v | x .Op Fl a | Ar pid | Ar core ... Modified: head/usr.bin/procstat/procstat.c ============================================================================== --- head/usr.bin/procstat/procstat.c Fri May 26 20:20:40 2017 (r318967) +++ head/usr.bin/procstat/procstat.c Fri May 26 21:10:01 2017 (r318968) @@ -50,10 +50,11 @@ static void usage(void) { - xo_error("usage: procstat [-CHhn] [-M core] [-N system] " - "[-w interval]\n" + xo_error("usage: procstat [--libxo] [-CHhn] [-M core] " + "[-N system] [-w interval]\n" " [-b | -c | -e | -f | -i | -j | -k | " - "-l | -r | -s | -S | -t | -v | -x]\n" + "-l | -L | -r | -s | \n" + " -S | -t | -v | -x]\n" " [-a | pid | core ...]\n"); xo_finish(); exit(EX_USAGE); @@ -164,7 +165,7 @@ main(int argc, char *argv[]) argc = xo_parse_args(argc, argv); xocontainer = "basic"; - while ((ch = getopt(argc, argv, "CHN:M:abcefijklLhrsStvw:x")) != -1) { + while ((ch = getopt(argc, argv, "abCcefHhijkLlM:N:nrSstvw:x")) != -1) { switch (ch) { case 'C': Cflag++; From owner-svn-src-head@freebsd.org Fri May 26 22:17:46 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 905D3D82A1D; Fri, 26 May 2017 22:17:46 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 67E921B7F; Fri, 26 May 2017 22:17:46 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QMHjB1045280; Fri, 26 May 2017 22:17:45 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QMHiSd045273; Fri, 26 May 2017 22:17:44 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201705262217.v4QMHiSd045273@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: Conrad Meyer Date: Fri, 26 May 2017 22:17:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318969 - in head: lib/libprocstat sys/kern sys/sys usr.bin/procstat 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.23 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, 26 May 2017 22:17:46 -0000 Author: cem Date: Fri May 26 22:17:44 2017 New Revision: 318969 URL: https://svnweb.freebsd.org/changeset/base/318969 Log: procstat(1): Add TCP socket send/recv buffer size Add TCP socket send and receive buffer size to procstat -f output. Reviewed by: kib, markj Sponsored by: Dell EMC Isilon Differential Revision: https://reviews.freebsd.org/D10689 Modified: head/lib/libprocstat/Symbol.map head/lib/libprocstat/libprocstat.c head/lib/libprocstat/libprocstat.h head/lib/libprocstat/libprocstat_compat.c head/sys/kern/sys_socket.c head/sys/sys/user.h head/usr.bin/procstat/procstat_files.c Modified: head/lib/libprocstat/Symbol.map ============================================================================== --- head/lib/libprocstat/Symbol.map Fri May 26 21:10:01 2017 (r318968) +++ head/lib/libprocstat/Symbol.map Fri May 26 22:17:44 2017 (r318969) @@ -6,7 +6,6 @@ FBSD_1.2 { procstat_freefiles; procstat_freeprocs; procstat_get_pipe_info; - procstat_get_socket_info; procstat_getfiles; procstat_getprocs; procstat_open_kvm; @@ -39,5 +38,6 @@ FBSD_1.5 { procstat_get_pts_info; procstat_get_sem_info; procstat_get_shm_info; + procstat_get_socket_info; procstat_get_vnode_info; }; Modified: head/lib/libprocstat/libprocstat.c ============================================================================== --- head/lib/libprocstat/libprocstat.c Fri May 26 21:10:01 2017 (r318968) +++ head/lib/libprocstat/libprocstat.c Fri May 26 22:17:44 2017 (r318969) @@ -1497,6 +1497,8 @@ procstat_get_socket_info_kvm(kvm_t *kd, } else sock->inp_ppcb = (uintptr_t)inpcb.inp_ppcb; + sock->sendq = s.so_snd.sb_ccc; + sock->recvq = s.so_rcv.sb_ccc; } } break; @@ -1510,6 +1512,8 @@ procstat_get_socket_info_kvm(kvm_t *kd, sock->so_rcv_sb_state = s.so_rcv.sb_state; sock->so_snd_sb_state = s.so_snd.sb_state; sock->unp_conn = (uintptr_t)unpcb.unp_conn; + sock->sendq = s.so_snd.sb_ccc; + sock->recvq = s.so_rcv.sb_ccc; } } break; @@ -1556,17 +1560,22 @@ procstat_get_socket_info_sysctl(struct f switch(sock->dom_family) { case AF_INET: case AF_INET6: - if (sock->proto == IPPROTO_TCP) + if (sock->proto == IPPROTO_TCP) { sock->inp_ppcb = kif->kf_un.kf_sock.kf_sock_inpcb; + sock->sendq = kif->kf_un.kf_sock.kf_sock_sendq; + sock->recvq = kif->kf_un.kf_sock.kf_sock_recvq; + } break; case AF_UNIX: if (kif->kf_un.kf_sock.kf_sock_unpconn != 0) { - sock->so_rcv_sb_state = - kif->kf_un.kf_sock.kf_sock_rcv_sb_state; - sock->so_snd_sb_state = - kif->kf_un.kf_sock.kf_sock_snd_sb_state; - sock->unp_conn = - kif->kf_un.kf_sock.kf_sock_unpconn; + sock->so_rcv_sb_state = + kif->kf_un.kf_sock.kf_sock_rcv_sb_state; + sock->so_snd_sb_state = + kif->kf_un.kf_sock.kf_sock_snd_sb_state; + sock->unp_conn = + kif->kf_un.kf_sock.kf_sock_unpconn; + sock->sendq = kif->kf_un.kf_sock.kf_sock_sendq; + sock->recvq = kif->kf_un.kf_sock.kf_sock_recvq; } break; default: Modified: head/lib/libprocstat/libprocstat.h ============================================================================== --- head/lib/libprocstat/libprocstat.h Fri May 26 21:10:01 2017 (r318968) +++ head/lib/libprocstat/libprocstat.h Fri May 26 22:17:44 2017 (r318969) @@ -157,6 +157,8 @@ struct sockstat { struct sockaddr_storage sa_peer; /* Peer address. */ int type; char dname[32]; + unsigned int sendq; + unsigned int recvq; }; STAILQ_HEAD(filestat_list, filestat); Modified: head/lib/libprocstat/libprocstat_compat.c ============================================================================== --- head/lib/libprocstat/libprocstat_compat.c Fri May 26 21:10:01 2017 (r318968) +++ head/lib/libprocstat/libprocstat_compat.c Fri May 26 22:17:44 2017 (r318969) @@ -60,12 +60,29 @@ struct freebsd11_shmstat { uint16_t mode; }; +struct freebsd11_sockstat { + uint64_t inp_ppcb; + uint64_t so_addr; + uint64_t so_pcb; + uint64_t unp_conn; + int dom_family; + int proto; + int so_rcv_sb_state; + int so_snd_sb_state; + struct sockaddr_storage sa_local; /* Socket address. */ + struct sockaddr_storage sa_peer; /* Peer address. */ + int type; + char dname[32]; +}; + int freebsd11_procstat_get_pts_info(struct procstat *procstat, struct filestat *fst, struct freebsd11_ptsstat *pts, char *errbuf); int freebsd11_procstat_get_sem_info(struct procstat *procstat, struct filestat *fst, struct freebsd11_semstat *sem, char *errbuf); int freebsd11_procstat_get_shm_info(struct procstat *procstat, struct filestat *fst, struct freebsd11_shmstat *shm, char *errbuf); +int freebsd11_procstat_get_socket_info(struct procstat *procstat, + struct filestat *fst, struct freebsd11_sockstat *sock, char *errbuf); int freebsd11_procstat_get_vnode_info(struct procstat *procstat, struct filestat *fst, struct freebsd11_vnstat *vn, char *errbuf); @@ -116,6 +133,31 @@ freebsd11_procstat_get_shm_info(struct p } int +freebsd11_procstat_get_socket_info(struct procstat *procstat, struct filestat *fst, + struct freebsd11_sockstat *sock_compat, char *errbuf) +{ + struct sockstat sock; + int r; + + r = procstat_get_socket_info(procstat, fst, &sock, errbuf); + if (r != 0) + return (r); + sock_compat->inp_ppcb = sock.inp_ppcb; + sock_compat->so_addr = sock.so_addr; + sock_compat->so_pcb = sock.so_pcb; + sock_compat->unp_conn = sock.unp_conn; + sock_compat->dom_family = sock.dom_family; + sock_compat->proto = sock.proto; + sock_compat->so_rcv_sb_state = sock.so_rcv_sb_state; + sock_compat->so_snd_sb_state = sock.so_snd_sb_state; + sock_compat->sa_local = sock.sa_local; + sock_compat->sa_peer = sock.sa_peer; + sock_compat->type = sock.type; + memcpy(sock_compat->dname, sock.dname, sizeof(sock.dname)); + return (0); +} + +int freebsd11_procstat_get_vnode_info(struct procstat *procstat, struct filestat *fst, struct freebsd11_vnstat *vn_compat, char *errbuf) { @@ -138,6 +180,8 @@ freebsd11_procstat_get_vnode_info(struct } __sym_compat(procstat_get_pts_info, freebsd11_procstat_get_pts_info, FBSD_1.2); +__sym_compat(procstat_get_socket_info, freebsd11_procstat_get_socket_info, + FBSD_1.2); __sym_compat(procstat_get_vnode_info, freebsd11_procstat_get_vnode_info, FBSD_1.2); __sym_compat(procstat_get_sem_info, freebsd11_procstat_get_sem_info, FBSD_1.3); Modified: head/sys/kern/sys_socket.c ============================================================================== --- head/sys/kern/sys_socket.c Fri May 26 21:10:01 2017 (r318968) +++ head/sys/kern/sys_socket.c Fri May 26 22:17:44 2017 (r318969) @@ -359,6 +359,10 @@ soo_fill_kinfo(struct file *fp, struct k inpcb = (struct inpcb *)(so->so_pcb); kif->kf_un.kf_sock.kf_sock_inpcb = (uintptr_t)inpcb->inp_ppcb; + kif->kf_un.kf_sock.kf_sock_sendq = + sbused(&so->so_snd); + kif->kf_un.kf_sock.kf_sock_recvq = + sbused(&so->so_rcv); } } break; @@ -372,6 +376,10 @@ soo_fill_kinfo(struct file *fp, struct k so->so_rcv.sb_state; kif->kf_un.kf_sock.kf_sock_snd_sb_state = so->so_snd.sb_state; + kif->kf_un.kf_sock.kf_sock_sendq = + sbused(&so->so_snd); + kif->kf_un.kf_sock.kf_sock_recvq = + sbused(&so->so_rcv); } } break; Modified: head/sys/sys/user.h ============================================================================== --- head/sys/sys/user.h Fri May 26 21:10:01 2017 (r318968) +++ head/sys/sys/user.h Fri May 26 22:17:44 2017 (r318969) @@ -344,7 +344,8 @@ struct kinfo_file { int64_t kf_offset; /* Seek location. */ union { struct { - uint32_t kf_spareint; + /* Sendq size */ + uint32_t kf_sock_sendq; /* Socket domain. */ int kf_sock_domain0; /* Socket type. */ @@ -365,8 +366,8 @@ struct kinfo_file { uint16_t kf_sock_snd_sb_state; /* Receive buffer state. */ uint16_t kf_sock_rcv_sb_state; - /* Round to 64 bit alignment. */ - uint32_t kf_sock_pad0; + /* Recvq size. */ + uint32_t kf_sock_recvq; } kf_sock; struct { /* Vnode type. */ Modified: head/usr.bin/procstat/procstat_files.c ============================================================================== --- head/usr.bin/procstat/procstat_files.c Fri May 26 21:10:01 2017 (r318968) +++ head/usr.bin/procstat/procstat_files.c Fri May 26 22:17:44 2017 (r318969) @@ -534,6 +534,12 @@ procstat_files(struct procstat *procstat xo_emit("{:protocol/%-3s/%s} ", protocol_to_string(sock.dom_family, sock.type, sock.proto)); + if (sock.proto == IPPROTO_TCP || + sock.proto == IPPROTO_SCTP || + sock.type == SOCK_STREAM) { + xo_emit("{:sendq/%u} ", sock.sendq); + xo_emit("{:recvq/%u} ", sock.recvq); + } /* * While generally we like to print two addresses, * local and peer, for sockets, it turns out to be From owner-svn-src-head@freebsd.org Fri May 26 22:22:50 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2B601D82C2D; Fri, 26 May 2017 22:22:50 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F1ABA1FA5; Fri, 26 May 2017 22:22:49 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4QMMnph049225; Fri, 26 May 2017 22:22:49 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4QMMnLs049224; Fri, 26 May 2017 22:22:49 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201705262222.v4QMMnLs049224@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Fri, 26 May 2017 22:22:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318970 - 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.23 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, 26 May 2017 22:22:50 -0000 Author: mav Date: Fri May 26 22:22:48 2017 New Revision: 318970 URL: https://svnweb.freebsd.org/changeset/base/318970 Log: Call VLAN_CAPABILITIES() when LAGG capabilities change. This makes VLAN on top of LAGG to expose proper capabilities if they are changed after creation. MFC after: 1 week Modified: head/sys/net/if_lagg.c Modified: head/sys/net/if_lagg.c ============================================================================== --- head/sys/net/if_lagg.c Fri May 26 22:17:44 2017 (r318969) +++ head/sys/net/if_lagg.c Fri May 26 22:22:48 2017 (r318970) @@ -901,6 +901,7 @@ lagg_port_ioctl(struct ifnet *ifp, u_lon LAGG_XLOCK(sc); lagg_capabilities(sc); LAGG_XUNLOCK(sc); + VLAN_CAPABILITIES(sc->sc_ifp); break; case SIOCSIFMTU: @@ -1014,6 +1015,7 @@ lagg_port_ifdetach(void *arg __unused, s lp->lp_detaching = 1; lagg_port_destroy(lp, 1); LAGG_XUNLOCK(sc); + VLAN_CAPABILITIES(sc->sc_ifp); } static void @@ -1373,6 +1375,7 @@ lagg_ioctl(struct ifnet *ifp, u_long cmd error = lagg_port_create(sc, tpif); LAGG_XUNLOCK(sc); if_rele(tpif); + VLAN_CAPABILITIES(ifp); break; case SIOCSLAGGDELPORT: error = priv_check(td, PRIV_NET_LAGG); @@ -1396,6 +1399,7 @@ lagg_ioctl(struct ifnet *ifp, u_long cmd error = lagg_port_destroy(lp, 1); LAGG_XUNLOCK(sc); if_rele(tpif); + VLAN_CAPABILITIES(ifp); break; case SIOCSIFFLAGS: /* Set flags on ports too */ @@ -1446,6 +1450,7 @@ lagg_ioctl(struct ifnet *ifp, u_long cmd } lagg_capabilities(sc); LAGG_XUNLOCK(sc); + VLAN_CAPABILITIES(ifp); error = 0; break; From owner-svn-src-head@freebsd.org Sat May 27 02:05:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 14C90D8313E; Sat, 27 May 2017 02:05:23 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BDED814A6; Sat, 27 May 2017 02:05:22 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4R25Leq038630; Sat, 27 May 2017 02:05:21 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4R25LWu038629; Sat, 27 May 2017 02:05:21 GMT (envelope-from np@FreeBSD.org) Message-Id: <201705270205.v4R25LWu038629@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Sat, 27 May 2017 02:05:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318973 - head/contrib/ofed/libcxgb4/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.23 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, 27 May 2017 02:05:23 -0000 Author: np Date: Sat May 27 02:05:21 2017 New Revision: 318973 URL: https://svnweb.freebsd.org/changeset/base/318973 Log: libcxgb4: Use memcpy instead of copying WRs 8B at a time in the userspace RDMA library for cxgbe(4). MFC after: 3 days Sponsored by: Chelsio Communications Modified: head/contrib/ofed/libcxgb4/src/qp.c Modified: head/contrib/ofed/libcxgb4/src/qp.c ============================================================================== --- head/contrib/ofed/libcxgb4/src/qp.c Sat May 27 01:35:59 2017 (r318972) +++ head/contrib/ofed/libcxgb4/src/qp.c Sat May 27 02:05:21 2017 (r318973) @@ -47,39 +47,49 @@ struct c4iw_stats c4iw_stats; static void copy_wr_to_sq(struct t4_wq *wq, union t4_wr *wqe, u8 len16) { - u64 *src, *dst; - - src = (u64 *)wqe; - dst = (u64 *)((u8 *)wq->sq.queue + wq->sq.wq_pidx * T4_EQ_ENTRY_SIZE); + void *src, *dst; + uintptr_t end; + int total, len; + + src = &wqe->flits[0]; + dst = &wq->sq.queue->flits[wq->sq.wq_pidx * + (T4_EQ_ENTRY_SIZE / sizeof(__be64))]; if (t4_sq_onchip(wq)) { len16 = align(len16, 4); wc_wmb(); } - while (len16) { - *dst++ = *src++; - if (dst == (u64 *)&wq->sq.queue[wq->sq.size]) - dst = (u64 *)wq->sq.queue; - *dst++ = *src++; - if (dst == (u64 *)&wq->sq.queue[wq->sq.size]) - dst = (u64 *)wq->sq.queue; - len16--; + + total = len16 * 16; + end = (uintptr_t)&wq->sq.queue[wq->sq.size]; + if (__predict_true((uintptr_t)dst + total <= end)) { + /* Won't wrap around. */ + memcpy(dst, src, total); + } else { + len = end - (uintptr_t)dst; + memcpy(dst, src, len); + memcpy(wq->sq.queue, src + len, total - len); } } static void copy_wr_to_rq(struct t4_wq *wq, union t4_recv_wr *wqe, u8 len16) { - u64 *src, *dst; - - src = (u64 *)wqe; - dst = (u64 *)((u8 *)wq->rq.queue + wq->rq.wq_pidx * T4_EQ_ENTRY_SIZE); - while (len16) { - *dst++ = *src++; - if (dst >= (u64 *)&wq->rq.queue[wq->rq.size]) - dst = (u64 *)wq->rq.queue; - *dst++ = *src++; - if (dst >= (u64 *)&wq->rq.queue[wq->rq.size]) - dst = (u64 *)wq->rq.queue; - len16--; + void *src, *dst; + uintptr_t end; + int total, len; + + src = &wqe->flits[0]; + dst = &wq->rq.queue->flits[wq->rq.wq_pidx * + (T4_EQ_ENTRY_SIZE / sizeof(__be64))]; + + total = len16 * 16; + end = (uintptr_t)&wq->rq.queue[wq->rq.size]; + if (__predict_true((uintptr_t)dst + total <= end)) { + /* Won't wrap around. */ + memcpy(dst, src, total); + } else { + len = end - (uintptr_t)dst; + memcpy(dst, src, len); + memcpy(wq->rq.queue, src + len, total - len); } } From owner-svn-src-head@freebsd.org Sat May 27 02:07:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AB85AD83226; Sat, 27 May 2017 02:07:23 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7B23715E0; Sat, 27 May 2017 02:07:23 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4R27MWp038742; Sat, 27 May 2017 02:07:22 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4R27MYZ038741; Sat, 27 May 2017 02:07:22 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201705270207.v4R27MYZ038741@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Sat, 27 May 2017 02:07:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318974 - head/sys/dev/uart 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.23 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, 27 May 2017 02:07:23 -0000 Author: emaste Date: Sat May 27 02:07:22 2017 New Revision: 318974 URL: https://svnweb.freebsd.org/changeset/base/318974 Log: uart: add AMT SOL PCI ID I adjusted the description to be similar to existing AMT entries. PR: 219384 Submitted by: "Tooker" MFC after: 1 week Modified: head/sys/dev/uart/uart_bus_pci.c Modified: head/sys/dev/uart/uart_bus_pci.c ============================================================================== --- head/sys/dev/uart/uart_bus_pci.c Sat May 27 02:05:21 2017 (r318973) +++ head/sys/dev/uart/uart_bus_pci.c Sat May 27 02:07:22 2017 (r318974) @@ -127,6 +127,7 @@ static const struct pci_id pci_ns8250_id 24 * DEFAULT_RCLK, 2 }, { 0x8086, 0x0f0c, 0xffff, 0, "Intel ValleyView LPIO1 HSUART#2", 0x10, 24 * DEFAULT_RCLK, 2 }, +{ 0x8086, 0x108f, 0xffff, 0, "Intel AMT - SOL", 0x10 }, { 0x8086, 0x1c3d, 0xffff, 0, "Intel AMT - KT Controller", 0x10 }, { 0x8086, 0x1d3d, 0xffff, 0, "Intel C600/X79 Series Chipset KT Controller", 0x10 }, { 0x8086, 0x1e3d, 0xffff, 0, "Intel Panther Point KT Controller", 0x10 }, From owner-svn-src-head@freebsd.org Sat May 27 06:24:07 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 81102D84B3D; Sat, 27 May 2017 06:24:07 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 531F4115F; Sat, 27 May 2017 06:24:07 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4R6O6PS044167; Sat, 27 May 2017 06:24:06 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4R6O6Lq044166; Sat, 27 May 2017 06:24:06 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201705270624.v4R6O6Lq044166@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Sat, 27 May 2017 06:24:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318975 - head/etc/rc.d 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.23 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, 27 May 2017 06:24:07 -0000 Author: delphij Date: Sat May 27 06:24:06 2017 New Revision: 318975 URL: https://svnweb.freebsd.org/changeset/base/318975 Log: Tighten /entropy permissions. PR: 219527 Reported by: Lu Tung-Pin Submitted by: jilles MFC after: 3 days Modified: head/etc/rc.d/random Modified: head/etc/rc.d/random ============================================================================== --- head/etc/rc.d/random Sat May 27 02:07:22 2017 (r318974) +++ head/etc/rc.d/random Sat May 27 06:24:06 2017 (r318975) @@ -20,12 +20,14 @@ saveseed_cmd="${name}_stop" save_dev_random() { + oumask=`umask` + umask 077 for f ; do - if :>>"$f" ; then - debug "saving entropy to $f" - dd if=/dev/random of="$f" bs=4096 count=1 2>/dev/null - fi + debug "saving entropy to $f" + dd if=/dev/random of="$f" bs=4096 count=1 status=none && + chmod 600 "$f" done + umask ${oumask} } feed_dev_random() From owner-svn-src-head@freebsd.org Sat May 27 10:50:36 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5DBBD83ED4; Sat, 27 May 2017 10:50:36 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9E2331196; Sat, 27 May 2017 10:50:36 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RAoZXY051186; Sat, 27 May 2017 10:50:35 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RAoZDC051184; Sat, 27 May 2017 10:50:35 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271050.v4RAoZDC051184@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 10:50:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318982 - head/lib/libstand 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.23 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, 27 May 2017 10:50:37 -0000 Author: bapt Date: Sat May 27 10:50:35 2017 New Revision: 318982 URL: https://svnweb.freebsd.org/changeset/base/318982 Log: Pass a "FREEBSD" user-class in PXE dhcp request rfc3004 allows to pass multiple user classes on dhcp requests this is used by dhcp servers to differentiate the caller if needed. As an example with isc dhcp server it will be possible to make options only for the FreeBSD loaders: if exists user-class and option user-class = "FREEBSD" { option root-path "tftp://192.168.42.1/FreeBSD; } Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D10951 Modified: head/lib/libstand/bootp.c head/lib/libstand/bootp.h Modified: head/lib/libstand/bootp.c ============================================================================== --- head/lib/libstand/bootp.c Sat May 27 08:30:32 2017 (r318981) +++ head/lib/libstand/bootp.c Sat May 27 10:50:35 2017 (r318982) @@ -146,16 +146,20 @@ bootp(int sock, int flag) bp->bp_vend[7] = TAG_CLASSID; bp->bp_vend[8] = 9; bcopy("PXEClient", &bp->bp_vend[9], 9); - bp->bp_vend[18] = TAG_PARAM_REQ; - bp->bp_vend[19] = 7; - bp->bp_vend[20] = TAG_ROOTPATH; - bp->bp_vend[21] = TAG_HOSTNAME; - bp->bp_vend[22] = TAG_SWAPSERVER; - bp->bp_vend[23] = TAG_GATEWAY; - bp->bp_vend[24] = TAG_SUBNET_MASK; - bp->bp_vend[25] = TAG_INTF_MTU; - bp->bp_vend[26] = TAG_SERVERID; - bp->bp_vend[27] = TAG_END; + bp->bp_vend[18] = TAG_USER_CLASS; + bp->bp_vend[19] = 8; + bp->bp_vend[20] = 7; + bcopy("FREEBSD", &bp->bp_vend[21], 7); + bp->bp_vend[28] = TAG_PARAM_REQ; + bp->bp_vend[29] = 7; + bp->bp_vend[30] = TAG_ROOTPATH; + bp->bp_vend[31] = TAG_HOSTNAME; + bp->bp_vend[32] = TAG_SWAPSERVER; + bp->bp_vend[33] = TAG_GATEWAY; + bp->bp_vend[34] = TAG_SUBNET_MASK; + bp->bp_vend[35] = TAG_INTF_MTU; + bp->bp_vend[36] = TAG_SERVERID; + bp->bp_vend[37] = TAG_END; } else bp->bp_vend[7] = TAG_END; #else Modified: head/lib/libstand/bootp.h ============================================================================== --- head/lib/libstand/bootp.h Sat May 27 08:30:32 2017 (r318981) +++ head/lib/libstand/bootp.h Sat May 27 10:50:35 2017 (r318982) @@ -108,6 +108,7 @@ struct bootp { #define TAG_T2 ((unsigned char) 59) #define TAG_CLASSID ((unsigned char) 60) #define TAG_CLIENTID ((unsigned char) 61) +#define TAG_USER_CLASS ((unsigned char) 77) #endif #define TAG_END ((unsigned char) 255) From owner-svn-src-head@freebsd.org Sat May 27 11:41:55 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BBD4DD84793; Sat, 27 May 2017 11:41:55 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8B795163A; Sat, 27 May 2017 11:41:55 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RBfsrI074330; Sat, 27 May 2017 11:41:54 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RBfsEk074329; Sat, 27 May 2017 11:41:54 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271141.v4RBfsEk074329@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 11:41:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318986 - head/lib/libstand 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.23 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, 27 May 2017 11:41:55 -0000 Author: bapt Date: Sat May 27 11:41:54 2017 New Revision: 318986 URL: https://svnweb.freebsd.org/changeset/base/318986 Log: add a comment on vendor index 19 and 20 to avoid confusion Suggested by: tsoome Modified: head/lib/libstand/bootp.c Modified: head/lib/libstand/bootp.c ============================================================================== --- head/lib/libstand/bootp.c Sat May 27 11:25:21 2017 (r318985) +++ head/lib/libstand/bootp.c Sat May 27 11:41:54 2017 (r318986) @@ -147,7 +147,9 @@ bootp(int sock, int flag) bp->bp_vend[8] = 9; bcopy("PXEClient", &bp->bp_vend[9], 9); bp->bp_vend[18] = TAG_USER_CLASS; + /* len of each user class + number of user class */ bp->bp_vend[19] = 8; + /* len of the first user class */ bp->bp_vend[20] = 7; bcopy("FREEBSD", &bp->bp_vend[21], 7); bp->bp_vend[28] = TAG_PARAM_REQ; From owner-svn-src-head@freebsd.org Sat May 27 12:06:54 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2100FD84C2B; Sat, 27 May 2017 12:06:54 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D82281925; Sat, 27 May 2017 12:06:53 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RC6qZR084339; Sat, 27 May 2017 12:06:52 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RC6qCs084338; Sat, 27 May 2017 12:06:52 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271206.v4RC6qCs084338@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 12:06:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318987 - head/sys/boot/common 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.23 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, 27 May 2017 12:06:54 -0000 Author: bapt Date: Sat May 27 12:06:52 2017 New Revision: 318987 URL: https://svnweb.freebsd.org/changeset/base/318987 Log: Support URI scheme for root-path in netbooting Rather that previous attempts to add tftpfs support at the same time as NFS support. This time decide on a proper URI parser rather than hacks. root-path can now be define the following way: For tftpfs: tftp://ip/path tftp:/path (this one will consider the tftp server is the same as the one where the pxeboot file was fetched from) For nfs: nfs:/path nfs://ip/path The historical ip:/path /path are kept on NFS Reviewed by: tsoom, rgrimes Differential Revision: https://reviews.freebsd.org/D10947 Modified: head/sys/boot/common/dev_net.c Modified: head/sys/boot/common/dev_net.c ============================================================================== --- head/sys/boot/common/dev_net.c Sat May 27 11:41:54 2017 (r318986) +++ head/sys/boot/common/dev_net.c Sat May 27 12:06:52 2017 (r318987) @@ -97,6 +97,14 @@ struct devsw netdev = { net_cleanup }; +static struct uri_scheme { + const char *scheme; + int proto; +} uri_schemes[] = { + { "tftp:/", NET_TFTP }, + { "nfs:/", NET_NFS }, +}; + static int net_init(void) { @@ -334,11 +342,8 @@ net_getparams(int sock) return (EIO); } exit: - netproto = NET_TFTP; - if ((rootaddr = net_parse_rootpath()) != INADDR_NONE) { - netproto = NET_NFS; + if ((rootaddr = net_parse_rootpath()) != INADDR_NONE) rootip.s_addr = rootaddr; - } #ifdef NETIF_DEBUG if (debug) { @@ -387,14 +392,51 @@ net_print(int verbose) uint32_t net_parse_rootpath() { - n_long addr = INADDR_NONE; - char *ptr; + n_long addr = htonl(INADDR_NONE); + size_t i; + char ip[FNAME_SIZE]; + char *ptr, *val; + + netproto = NET_NONE; + + for (i = 0; i < nitems(uri_schemes); i++) { + if (strncmp(rootpath, uri_schemes[i].scheme, + strlen(uri_schemes[i].scheme)) != 0) + continue; + netproto = uri_schemes[i].proto; + break; + } ptr = rootpath; - (void)strsep(&ptr, ":"); - if (ptr != NULL) { - addr = inet_addr(rootpath); - bcopy(ptr, rootpath, strlen(ptr) + 1); + /* Fallback for compatibility mode */ + if (netproto == NET_NONE) { + netproto = NET_NFS; + (void)strsep(&ptr, ":"); + if (ptr != NULL) { + addr = inet_addr(rootpath); + bcopy(ptr, rootpath, strlen(ptr) + 1); + } + } else { + ptr += strlen(uri_schemes[i].scheme); + if (*ptr == '/') { + /* we are in the form ://, we do expect an ip */ + ptr++; + /* + * XXX when http will be there we will need to check for + * a port, but right now we do not need it yet + */ + val = strchr(ptr, '/'); + if (val != NULL) { + snprintf(ip, sizeof(ip), "%.*s", + (int)((uintptr_t)val - (uintptr_t)ptr), ptr); + printf("%s\n", ip); + addr = inet_addr(ip); + bcopy(val, rootpath, strlen(val) + 1); + } + } else { + ptr--; + bcopy(ptr, rootpath, strlen(ptr) + 1); + } } return (addr); From owner-svn-src-head@freebsd.org Sat May 27 12:20:15 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 46410D84EC9; Sat, 27 May 2017 12:20:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 169A31F2A; Sat, 27 May 2017 12:20:15 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RCKECA088592; Sat, 27 May 2017 12:20:14 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RCKESw088591; Sat, 27 May 2017 12:20:14 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271220.v4RCKESw088591@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 12:20:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318988 - head/sys/boot/i386/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.23 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, 27 May 2017 12:20:15 -0000 Author: bapt Date: Sat May 27 12:20:13 2017 New Revision: 318988 URL: https://svnweb.freebsd.org/changeset/base/318988 Log: Always build tftpfs support along with nfs for pxeboot This change was already done for loader.efi Modified: head/sys/boot/i386/loader/Makefile Modified: head/sys/boot/i386/loader/Makefile ============================================================================== --- head/sys/boot/i386/loader/Makefile Sat May 27 12:06:52 2017 (r318987) +++ head/sys/boot/i386/loader/Makefile Sat May 27 12:20:13 2017 (r318988) @@ -10,6 +10,8 @@ INTERNALPROG= NEWVERSWHAT?= "bootstrap loader" x86 VERSION_FILE= ${.CURDIR}/../loader/version LOADER_NET_SUPPORT?= yes +LOADER_NFS_SUPPORT?= yes +LOADER_TFTP_SUPPORT?= yes # architecture-specific loader code SRCS= main.c conf.c vers.c @@ -30,10 +32,10 @@ LIBZFSBOOT= ${.OBJDIR}/../../zfs/libzfsb CFLAGS+= -I${.CURDIR}/../../../../lib/libstand .endif -# Enable PXE TFTP or NFS support, not both. .if defined(LOADER_TFTP_SUPPORT) CFLAGS+= -DLOADER_TFTP_SUPPORT -.else +.endif +.if defined(LOADER_NFS_SUPPORT) CFLAGS+= -DLOADER_NFS_SUPPORT .endif From owner-svn-src-head@freebsd.org Sat May 27 12:35:03 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 307B7D856BD; Sat, 27 May 2017 12:35:03 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E5C1418CF; Sat, 27 May 2017 12:35:02 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RCZ1SG096599; Sat, 27 May 2017 12:35:01 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RCZ1Ni096595; Sat, 27 May 2017 12:35:01 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271235.v4RCZ1Ni096595@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 12:35:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318989 - in head: lib/libstand sys/boot/common 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.23 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, 27 May 2017 12:35:03 -0000 Author: bapt Date: Sat May 27 12:35:01 2017 New Revision: 318989 URL: https://svnweb.freebsd.org/changeset/base/318989 Log: Always issue the pxe request All the code are now only issueing one single dhcp request at startup of the loader meaning we can always request a the PXE informations from the dhcp server. Previous code lost that information, meaning no option 55 anymore (meaning not working with the kea dhcp server) and no request for rootpath etc, no user class Remove the flags from the bootp function which is not needed anymore Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D10952 Modified: head/lib/libstand/bootp.c head/lib/libstand/bootp.h head/lib/libstand/net.h head/sys/boot/common/dev_net.c Modified: head/lib/libstand/bootp.c ============================================================================== --- head/lib/libstand/bootp.c Sat May 27 12:20:13 2017 (r318988) +++ head/lib/libstand/bootp.c Sat May 27 12:35:01 2017 (r318989) @@ -95,7 +95,7 @@ size_t bootp_response_size; /* Fetch required bootp infomation */ void -bootp(int sock, int flag) +bootp(int sock) { void *pkt; struct iodesc *d; @@ -138,32 +138,29 @@ bootp(int sock, int flag) bp->bp_vend[6] = DHCPDISCOVER; /* - * If we are booting from PXE, we want to send the string + * We are booting from PXE, we want to send the string * 'PXEClient' to the DHCP server so you have the option of * only responding to PXE aware dhcp requests. */ - if (flag & BOOTP_PXE) { - bp->bp_vend[7] = TAG_CLASSID; - bp->bp_vend[8] = 9; - bcopy("PXEClient", &bp->bp_vend[9], 9); - bp->bp_vend[18] = TAG_USER_CLASS; - /* len of each user class + number of user class */ - bp->bp_vend[19] = 8; - /* len of the first user class */ - bp->bp_vend[20] = 7; - bcopy("FREEBSD", &bp->bp_vend[21], 7); - bp->bp_vend[28] = TAG_PARAM_REQ; - bp->bp_vend[29] = 7; - bp->bp_vend[30] = TAG_ROOTPATH; - bp->bp_vend[31] = TAG_HOSTNAME; - bp->bp_vend[32] = TAG_SWAPSERVER; - bp->bp_vend[33] = TAG_GATEWAY; - bp->bp_vend[34] = TAG_SUBNET_MASK; - bp->bp_vend[35] = TAG_INTF_MTU; - bp->bp_vend[36] = TAG_SERVERID; - bp->bp_vend[37] = TAG_END; - } else - bp->bp_vend[7] = TAG_END; + bp->bp_vend[7] = TAG_CLASSID; + bp->bp_vend[8] = 9; + bcopy("PXEClient", &bp->bp_vend[9], 9); + bp->bp_vend[18] = TAG_USER_CLASS; + /* len of each user class + number of user class */ + bp->bp_vend[19] = 8; + /* len of the first user class */ + bp->bp_vend[20] = 7; + bcopy("FREEBSD", &bp->bp_vend[21], 7); + bp->bp_vend[28] = TAG_PARAM_REQ; + bp->bp_vend[29] = 7; + bp->bp_vend[30] = TAG_ROOTPATH; + bp->bp_vend[31] = TAG_HOSTNAME; + bp->bp_vend[32] = TAG_SWAPSERVER; + bp->bp_vend[33] = TAG_GATEWAY; + bp->bp_vend[34] = TAG_SUBNET_MASK; + bp->bp_vend[35] = TAG_INTF_MTU; + bp->bp_vend[36] = TAG_SERVERID; + bp->bp_vend[37] = TAG_END; #else bp->bp_vend[4] = TAG_END; #endif @@ -199,13 +196,10 @@ bootp(int sock, int flag) bp->bp_vend[20] = 4; leasetime = htonl(300); bcopy(&leasetime, &bp->bp_vend[21], 4); - if (flag & BOOTP_PXE) { - bp->bp_vend[25] = TAG_CLASSID; - bp->bp_vend[26] = 9; - bcopy("PXEClient", &bp->bp_vend[27], 9); - bp->bp_vend[36] = TAG_END; - } else - bp->bp_vend[25] = TAG_END; + bp->bp_vend[25] = TAG_CLASSID; + bp->bp_vend[26] = 9; + bcopy("PXEClient", &bp->bp_vend[27], 9); + bp->bp_vend[36] = TAG_END; expected_dhcpmsgtype = DHCPACK; Modified: head/lib/libstand/bootp.h ============================================================================== --- head/lib/libstand/bootp.h Sat May 27 12:20:13 2017 (r318988) +++ head/lib/libstand/bootp.h Sat May 27 12:35:01 2017 (r318989) @@ -124,12 +124,6 @@ struct bootp { #endif /* - * bootp flags - */ -#define BOOTP_NONE 0x0000 /* No flags */ -#define BOOTP_PXE 0x0001 /* Booting from PXE. */ - -/* * "vendor" data permitted for CMU bootp clients. */ Modified: head/lib/libstand/net.h ============================================================================== --- head/lib/libstand/net.h Sat May 27 12:20:13 2017 (r318988) +++ head/lib/libstand/net.h Sat May 27 12:35:01 2017 (r318989) @@ -119,7 +119,7 @@ ssize_t sendrecv(struct iodesc *, void **, void **); /* bootp/DHCP */ -void bootp(int, int); +void bootp(int); /* Utilities: */ char *ether_sprintf(u_char *); Modified: head/sys/boot/common/dev_net.c ============================================================================== --- head/sys/boot/common/dev_net.c Sat May 27 12:20:13 2017 (r318988) +++ head/sys/boot/common/dev_net.c Sat May 27 12:35:01 2017 (r318989) @@ -284,7 +284,7 @@ net_getparams(int sock) d->myip = myip; } if (rc < 0) - bootp(sock, BOOTP_NONE); + bootp(sock); } if (myip.s_addr != 0) goto exit; From owner-svn-src-head@freebsd.org Sat May 27 12:46:47 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7D8C9D858DD; Sat, 27 May 2017 12:46:47 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4F8DE1D94; Sat, 27 May 2017 12:46:47 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RCkkbl001047; Sat, 27 May 2017 12:46:46 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RCkkoQ001046; Sat, 27 May 2017 12:46:46 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271246.v4RCkkoQ001046@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 12:46:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318990 - head/sys/boot/common 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.23 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, 27 May 2017 12:46:47 -0000 Author: bapt Date: Sat May 27 12:46:46 2017 New Revision: 318990 URL: https://svnweb.freebsd.org/changeset/base/318990 Log: Partially revert r314948 While it sounds like a good idea to extract the RFC1048 data from PXE, in the end it is not and it is causing lots of issues. Our pxeloader might need options which are incompatible with other pxe servers (for example iPXE, but not only). Our pxe loaders are also now settings their own user class, so it is useful to issue our own pxe request at startup Reviewed by: tsoome Differential Revision: https://reviews.freebsd.org/D10953 Modified: head/sys/boot/common/dev_net.c Modified: head/sys/boot/common/dev_net.c ============================================================================== --- head/sys/boot/common/dev_net.c Sat May 27 12:35:01 2017 (r318989) +++ head/sys/boot/common/dev_net.c Sat May 27 12:46:46 2017 (r318990) @@ -256,7 +256,6 @@ net_getparams(int sock) { char buf[MAXHOSTNAMELEN]; n_long rootaddr, smask; - struct iodesc *d = socktodesc(sock); extern struct in_addr servip; #ifdef SUPPORT_BOOTP @@ -266,26 +265,8 @@ net_getparams(int sock) * be initialized. If any remain uninitialized, we will * use RARP and RPC/bootparam (the Sun way) to get them. */ - if (try_bootp) { - int rc = -1; - if (bootp_response != NULL) { - rc = dhcp_try_rfc1048(bootp_response->bp_vend, - bootp_response_size - - offsetof(struct bootp, bp_vend)); - - if (servip.s_addr == 0) - servip = bootp_response->bp_siaddr; - if (rootip.s_addr == 0) - rootip = bootp_response->bp_siaddr; - if (gateip.s_addr == 0) - gateip = bootp_response->bp_giaddr; - if (myip.s_addr == 0) - myip = bootp_response->bp_yiaddr; - d->myip = myip; - } - if (rc < 0) - bootp(sock); - } + if (try_bootp) + bootp(sock); if (myip.s_addr != 0) goto exit; #ifdef NETIF_DEBUG From owner-svn-src-head@freebsd.org Sat May 27 13:26:19 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 81669D8215B; Sat, 27 May 2017 13:26:19 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 394511E4A; Sat, 27 May 2017 13:26:19 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RDQIkI017159; Sat, 27 May 2017 13:26:18 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RDQI5L017158; Sat, 27 May 2017 13:26:18 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271326.v4RDQI5L017158@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 13:26:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318991 - head/sys/boot/i386/pxeldr 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.23 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, 27 May 2017 13:26:19 -0000 Author: bapt Date: Sat May 27 13:26:18 2017 New Revision: 318991 URL: https://svnweb.freebsd.org/changeset/base/318991 Log: Document recent changes on pxeboot Modified: head/sys/boot/i386/pxeldr/pxeboot.8 Modified: head/sys/boot/i386/pxeldr/pxeboot.8 ============================================================================== --- head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 12:46:46 2017 (r318990) +++ head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 13:26:18 2017 (r318991) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 16, 2017 +.Dd May 27, 2017 .Dt PXEBOOT 8 .Os .Sh NAME @@ -39,6 +39,11 @@ configured to run under Intel's Preboot PXE is a form of smart boot ROM, built into Intel EtherExpress Pro/100 and 3Com 3c905c Ethernet cards, and Ethernet-equipped Intel motherboards. PXE supports DHCP configuration and provides low-level NIC access services. +.Pp +The DHCP client will set a DHCP user class named +.Va FREEBSD +to allow flexible configuration of the dhcp server. +.Pp The .Nm bootloader retrieves the kernel, modules, @@ -69,6 +74,9 @@ max-lease-time 120; subnet 10.0.0.0 netmask 255.255.255.0 { filename "pxeboot"; range 10.0.0.10 10.0.0.254; + if exists user-class and option user-class = "FREEBSD" { + option root-path "tftp://10.0.0.1/FreeBSD"; + } } .Ed @@ -85,6 +93,27 @@ expects to fetch .Pa /boot/loader.rc from the specified server before loading any other files. .Pp +Valid +.Va option root-path +Syntax is the following +.Bl -tag -width ://ip/path indent +.It /path +path to the root filesystem on the NFS server +.It ip:/path +path to the root filesystem on the NFS server +.Ar ip +.It nfs:/path +path to the root filesystem on the NFS server +.It nfs://ip/path +path to the root filesystem on the NFS server +.Ar ip +.It tftp:/path +path to the root filesystem on the TFTP server +.It tftp://ip/path +path to the root filesystem on the TFTP server +.Ar ip +.El +.Pp .Nm defaults to a conservative 1024 byte NFS data packet size. This may be changed by setting the From owner-svn-src-head@freebsd.org Sat May 27 13:51:38 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6DE21D8288F; Sat, 27 May 2017 13:51:38 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [96.47.72.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 45F48195A; Sat, 27 May 2017 13:51:38 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id 6F1AE47BD; Sat, 27 May 2017 13:51:37 +0000 (UTC) Date: Sat, 27 May 2017 13:51:37 +0000 From: Alexey Dokuchaev To: Baptiste Daroussin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318991 - head/sys/boot/i386/pxeldr Message-ID: <20170527135137.GA31549@FreeBSD.org> References: <201705271326.v4RDQI5L017158@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705271326.v4RDQI5L017158@repo.freebsd.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 27 May 2017 13:51:38 -0000 On Sat, May 27, 2017 at 01:26:18PM +0000, Baptiste Daroussin wrote: > New Revision: 318991 > URL: https://svnweb.freebsd.org/changeset/base/318991 > > Log: > Document recent changes on pxeboot > > Modified: > head/sys/boot/i386/pxeldr/pxeboot.8 > ... > @@ -39,6 +39,11 @@ configured to run under Intel's Preboot > PXE is a form of smart boot ROM, built into Intel EtherExpress Pro/100 and > 3Com 3c905c Ethernet cards, and Ethernet-equipped Intel motherboards. > PXE supports DHCP configuration and provides low-level NIC access services. > +.Pp > +The DHCP client will set a DHCP user class named > +.Va FREEBSD > +to allow flexible configuration of the dhcp server. > +.Pp Inconsistent DHCP/dhcp spelling within a single sentence does not look good. ./danfe From owner-svn-src-head@freebsd.org Sat May 27 13:55:22 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 220EDD82AA1; Sat, 27 May 2017 13:55:22 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E5AD31BA3; Sat, 27 May 2017 13:55:21 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RDtKdr029285; Sat, 27 May 2017 13:55:20 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RDtKav029284; Sat, 27 May 2017 13:55:20 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271355.v4RDtKav029284@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 13:55:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318992 - head/sys/boot/i386/pxeldr 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.23 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, 27 May 2017 13:55:22 -0000 Author: bapt Date: Sat May 27 13:55:20 2017 New Revision: 318992 URL: https://svnweb.freebsd.org/changeset/base/318992 Log: Capitalize DHCP Reported by: danfe Modified: head/sys/boot/i386/pxeldr/pxeboot.8 Modified: head/sys/boot/i386/pxeldr/pxeboot.8 ============================================================================== --- head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 13:26:18 2017 (r318991) +++ head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 13:55:20 2017 (r318992) @@ -42,7 +42,7 @@ PXE supports DHCP configuration and prov .Pp The DHCP client will set a DHCP user class named .Va FREEBSD -to allow flexible configuration of the dhcp server. +to allow flexible configuration of the DHCP server. .Pp The .Nm From owner-svn-src-head@freebsd.org Sat May 27 14:04:34 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B8A19D82D32; Sat, 27 May 2017 14:04:34 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2610:1c1:1:6074::16:84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "freefall.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 89C961032; Sat, 27 May 2017 14:04:34 +0000 (UTC) (envelope-from danfe@freebsd.org) Received: by freefall.freebsd.org (Postfix, from userid 1033) id BA2734A93; Sat, 27 May 2017 14:04:33 +0000 (UTC) Date: Sat, 27 May 2017 14:04:33 +0000 From: Alexey Dokuchaev To: Baptiste Daroussin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318992 - head/sys/boot/i386/pxeldr Message-ID: <20170527140433.GB31549@FreeBSD.org> References: <201705271355.v4RDtKav029284@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201705271355.v4RDtKav029284@repo.freebsd.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 27 May 2017 14:04:34 -0000 On Sat, May 27, 2017 at 01:55:20PM +0000, Baptiste Daroussin wrote: > New Revision: 318992 > URL: https://svnweb.freebsd.org/changeset/base/318992 > > Log: > Capitalize DHCP Thank you. ./danfe From owner-svn-src-head@freebsd.org Sat May 27 14:06:58 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 95B33D82DE0; Sat, 27 May 2017 14:06:58 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 66346119E; Sat, 27 May 2017 14:06:58 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RE6vWs033256; Sat, 27 May 2017 14:06:57 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RE6veW033255; Sat, 27 May 2017 14:06:57 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271406.v4RE6veW033255@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 14:06:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318993 - head/lib/libstand 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.23 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, 27 May 2017 14:06:58 -0000 Author: bapt Date: Sat May 27 14:06:57 2017 New Revision: 318993 URL: https://svnweb.freebsd.org/changeset/base/318993 Log: Use the usual FreeBSD spelling for the DHCP user class Reported by: lidl Modified: head/lib/libstand/bootp.c Modified: head/lib/libstand/bootp.c ============================================================================== --- head/lib/libstand/bootp.c Sat May 27 13:55:20 2017 (r318992) +++ head/lib/libstand/bootp.c Sat May 27 14:06:57 2017 (r318993) @@ -150,7 +150,7 @@ bootp(int sock) bp->bp_vend[19] = 8; /* len of the first user class */ bp->bp_vend[20] = 7; - bcopy("FREEBSD", &bp->bp_vend[21], 7); + bcopy("FreeBSD", &bp->bp_vend[21], 7); bp->bp_vend[28] = TAG_PARAM_REQ; bp->bp_vend[29] = 7; bp->bp_vend[30] = TAG_ROOTPATH; From owner-svn-src-head@freebsd.org Sat May 27 14:07:48 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0972CD82E7A; Sat, 27 May 2017 14:07:48 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CF9001372; Sat, 27 May 2017 14:07:47 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RE7kuk033327; Sat, 27 May 2017 14:07:46 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RE7kij033326; Sat, 27 May 2017 14:07:46 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271407.v4RE7kij033326@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 14:07:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318994 - head/sys/boot/i386/pxeldr 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.23 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, 27 May 2017 14:07:48 -0000 Author: bapt Date: Sat May 27 14:07:46 2017 New Revision: 318994 URL: https://svnweb.freebsd.org/changeset/base/318994 Log: Catch with the change in the user class Modified: head/sys/boot/i386/pxeldr/pxeboot.8 Modified: head/sys/boot/i386/pxeldr/pxeboot.8 ============================================================================== --- head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 14:06:57 2017 (r318993) +++ head/sys/boot/i386/pxeldr/pxeboot.8 Sat May 27 14:07:46 2017 (r318994) @@ -41,7 +41,7 @@ PXE is a form of smart boot ROM, built i PXE supports DHCP configuration and provides low-level NIC access services. .Pp The DHCP client will set a DHCP user class named -.Va FREEBSD +.Va FreeBSD to allow flexible configuration of the DHCP server. .Pp The From owner-svn-src-head@freebsd.org Sat May 27 16:40:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B87A4D83876; Sat, 27 May 2017 16:40:01 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8A873192E; Sat, 27 May 2017 16:40:01 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RGe0R6095664; Sat, 27 May 2017 16:40:00 GMT (envelope-from alc@FreeBSD.org) Received: (from alc@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RGe0v3095663; Sat, 27 May 2017 16:40:00 GMT (envelope-from alc@FreeBSD.org) Message-Id: <201705271640.v4RGe0v3095663@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: alc set sender to alc@FreeBSD.org using -f From: Alan Cox Date: Sat, 27 May 2017 16:40:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318995 - head/sys/vm 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.23 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, 27 May 2017 16:40:01 -0000 Author: alc Date: Sat May 27 16:40:00 2017 New Revision: 318995 URL: https://svnweb.freebsd.org/changeset/base/318995 Log: In r118390, the swap pager's approach to striping swap allocation over multiple devices was changed. However, swapoff_one() was not fully and correctly converted. In particular, with r118390's introduction of a per- device blist, the maximum swap block size, "dmmax", became irrelevant to swapoff_one()'s operation. Moreover, swapoff_one() was performing out-of- range operations on the per-device blist that were silently ignored by blist_fill(). This change corrects both of these problems with swapoff_one(), which will allow us to potentially increase MAX_PAGEOUT_CLUSTER. Previously, swapoff_one() would panic inside of blist_fill() if you increased MAX_PAGEOUT_CLUSTER. Reviewed by: kib, markj MFC after: 3 days Modified: head/sys/vm/swap_pager.c Modified: head/sys/vm/swap_pager.c ============================================================================== --- head/sys/vm/swap_pager.c Sat May 27 14:07:46 2017 (r318994) +++ head/sys/vm/swap_pager.c Sat May 27 16:40:00 2017 (r318995) @@ -2310,9 +2310,13 @@ swapoff_one(struct swdevt *sp, struct uc */ mtx_lock(&sw_dev_mtx); sp->sw_flags |= SW_CLOSING; - for (dvbase = 0; dvbase < sp->sw_end; dvbase += dmmax) { + for (dvbase = 0; dvbase < nblks; dvbase += BLIST_BMAP_RADIX) { + /* + * blist_fill() cannot allocate more than BLIST_BMAP_RADIX + * blocks per call. + */ swap_pager_avail -= blist_fill(sp->sw_blist, - dvbase, dmmax); + dvbase, ulmin(nblks - dvbase, BLIST_BMAP_RADIX)); } swap_total -= (vm_ooffset_t)nblks * PAGE_SIZE; mtx_unlock(&sw_dev_mtx); From owner-svn-src-head@freebsd.org Sat May 27 16:53:41 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 45E99D83EC1; Sat, 27 May 2017 16:53:41 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 08B871507; Sat, 27 May 2017 16:53:40 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RGrejg003786; Sat, 27 May 2017 16:53:40 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RGread003785; Sat, 27 May 2017 16:53:40 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201705271653.v4RGread003785@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Sat, 27 May 2017 16:53:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318996 - 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.23 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, 27 May 2017 16:53:41 -0000 Author: jhb Date: Sat May 27 16:53:39 2017 New Revision: 318996 URL: https://svnweb.freebsd.org/changeset/base/318996 Log: Add descriptions for AES-GCM IPSec authentication (AH) counters. MFC after: 1 week Sponsored by: Chelsio Communications Modified: head/usr.bin/netstat/ipsec.c Modified: head/usr.bin/netstat/ipsec.c ============================================================================== --- head/usr.bin/netstat/ipsec.c Sat May 27 16:40:00 2017 (r318995) +++ head/usr.bin/netstat/ipsec.c Sat May 27 16:53:39 2017 (r318996) @@ -141,6 +141,15 @@ static struct val2str ipsec_ahnames[] = #ifdef SADB_X_AALG_AES_XCBC_MAC { SADB_X_AALG_AES_XCBC_MAC, "aes-xcbc-mac", }, #endif +#ifdef SADB_X_AALG_AES128GMAC + { SADB_X_AALG_AES128GMAC, "aes-gmac-128", }, +#endif +#ifdef SADB_X_AALG_AES192GMAC + { SADB_X_AALG_AES192GMAC, "aes-gmac-192", }, +#endif +#ifdef SADB_X_AALG_AES256GMAC + { SADB_X_AALG_AES256GMAC, "aes-gmac-256", }, +#endif { -1, NULL }, }; From owner-svn-src-head@freebsd.org Sat May 27 17:00:32 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2A5A5D84064; Sat, 27 May 2017 17:00:32 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 05C461810; Sat, 27 May 2017 17:00:31 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RH0VmH004315; Sat, 27 May 2017 17:00:31 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RH0USD004310; Sat, 27 May 2017 17:00:30 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201705271700.v4RH0USD004310@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sat, 27 May 2017 17:00:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318997 - in head/sys: cddl/contrib/opensolaris/uts/common/fs/zfs fs/nfsclient 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.23 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, 27 May 2017 17:00:32 -0000 Author: kib Date: Sat May 27 17:00:30 2017 New Revision: 318997 URL: https://svnweb.freebsd.org/changeset/base/318997 Log: Use whole mnt_stat.f_fsid bits for st_dev. Since ino64 expanded dev_t to 64bit, make VOP_GETATTR(9) provide all bits of mnt_stat.f_fsid as va_fsid for vnodes on filesystems which use f_fsid. In particular, NFSv3 and sometimes NFSv4, and ZFS use this method or reporting st_dev by stat(2). Provide a new helper vn_fsid() to avoid duplicating code to copy f_fsid to va_fsid. Note that the change is mostly cosmetic. Its motivation is to avoid sign-extension of f_fsid[0] into 64bit dev_t value which happens after dev_t becomes 64bit.. Reviewed by: avg(zfs), rmacklem (nfs) (both for previous version) Sponsored by: The FreeBSD Foundation Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c head/sys/fs/nfsclient/nfs_clport.c head/sys/kern/vfs_vnops.c head/sys/sys/vnode.h Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c Sat May 27 16:53:39 2017 (r318996) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ctldir.c Sat May 27 17:00:30 2017 (r318997) @@ -497,7 +497,7 @@ zfsctl_common_getattr(vnode_t *vp, vattr vap->va_blksize = 0; vap->va_nblocks = 0; vap->va_seq = 0; - vap->va_fsid = vp->v_mount->mnt_stat.f_fsid.val[0]; + vn_fsid(vp, vap); vap->va_mode = S_IRUSR | S_IXUSR | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH; vap->va_type = VDIR; Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Sat May 27 16:53:39 2017 (r318996) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c Sat May 27 17:00:30 2017 (r318997) @@ -2708,7 +2708,7 @@ zfs_getattr(vnode_t *vp, vattr_t *vap, i #ifdef illumos vap->va_fsid = zp->z_zfsvfs->z_vfs->vfs_dev; #else - vap->va_fsid = vp->v_mount->mnt_stat.f_fsid.val[0]; + vn_fsid(vp, vap); #endif vap->va_nodeid = zp->z_id; if ((vp->v_flag & VROOT) && zfs_show_ctldir(zp)) Modified: head/sys/fs/nfsclient/nfs_clport.c ============================================================================== --- head/sys/fs/nfsclient/nfs_clport.c Sat May 27 16:53:39 2017 (r318996) +++ head/sys/fs/nfsclient/nfs_clport.c Sat May 27 17:00:30 2017 (r318997) @@ -490,14 +490,13 @@ nfscl_loadattrcache(struct vnode **vpp, * from the value used for the top level server volume * in the mounted subtree. */ - if (vp->v_mount->mnt_stat.f_fsid.val[0] != - (uint32_t)np->n_vattr.na_filesid[0]) - vap->va_fsid = (uint32_t)np->n_vattr.na_filesid[0]; - else - vap->va_fsid = (uint32_t)hash32_buf( + vn_fsid(vp, vap); + vap->va_fsid = np->n_vattr.na_filesid[0]; + if (vap->va_fsid == np->n_vattr.na_filesid[0]) + vap->va_fsid = hash32_buf( np->n_vattr.na_filesid, 2 * sizeof(uint64_t), 0); } else - vap->va_fsid = vp->v_mount->mnt_stat.f_fsid.val[0]; + vn_fsid(vp, vap); np->n_attrstamp = time_second; if (vap->va_size != np->n_size) { if (vap->va_type == VREG) { Modified: head/sys/kern/vfs_vnops.c ============================================================================== --- head/sys/kern/vfs_vnops.c Sat May 27 16:53:39 2017 (r318996) +++ head/sys/kern/vfs_vnops.c Sat May 27 17:00:30 2017 (r318997) @@ -2493,3 +2493,14 @@ vn_mmap(struct file *fp, vm_map_t map, v #endif return (error); } + +void +vn_fsid(struct vnode *vp, struct vattr *va) +{ + fsid_t *f; + + f = &vp->v_mount->mnt_stat.f_fsid; + va->va_fsid = (uint32_t)f->val[1]; + va->va_fsid <<= sizeof(f->val[1]) * NBBY; + va->va_fsid += (uint32_t)f->val[0]; +} Modified: head/sys/sys/vnode.h ============================================================================== --- head/sys/sys/vnode.h Sat May 27 16:53:39 2017 (r318996) +++ head/sys/sys/vnode.h Sat May 27 17:00:30 2017 (r318997) @@ -885,6 +885,8 @@ int vn_chmod(struct file *fp, mode_t mod int vn_chown(struct file *fp, uid_t uid, gid_t gid, struct ucred *active_cred, struct thread *td); +void vn_fsid(struct vnode *vp, struct vattr *va); + #endif /* _KERNEL */ #endif /* !_SYS_VNODE_H_ */ From owner-svn-src-head@freebsd.org Sat May 27 18:01:16 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53321D852D5; Sat, 27 May 2017 18:01:16 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 238A81734; Sat, 27 May 2017 18:01:16 +0000 (UTC) (envelope-from cy@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RI1FCk030869; Sat, 27 May 2017 18:01:15 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RI1FV7030868; Sat, 27 May 2017 18:01:15 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201705271801.v4RI1FV7030868@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Sat, 27 May 2017 18:01:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318998 - head/sys/contrib/ipfilter/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.23 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, 27 May 2017 18:01:16 -0000 Author: cy Date: Sat May 27 18:01:14 2017 New Revision: 318998 URL: https://svnweb.freebsd.org/changeset/base/318998 Log: Fix return value of ip_sync_nat. Previously, regardless of error it always returned a return code of 0. Obtained from: NetBSD ip_sync.c r1.5 MFC after: 1 week Modified: head/sys/contrib/ipfilter/netinet/ip_sync.c Modified: head/sys/contrib/ipfilter/netinet/ip_sync.c ============================================================================== --- head/sys/contrib/ipfilter/netinet/ip_sync.c Sat May 27 17:00:30 2017 (r318997) +++ head/sys/contrib/ipfilter/netinet/ip_sync.c Sat May 27 18:01:14 2017 (r318998) @@ -939,7 +939,7 @@ ipf_sync_nat(softc, sp, data) nat_t *n, *nat; synclist_t *sl; u_int hv = 0; - int err; + int err = 0; READ_ENTER(&softs->ipf_syncnat); @@ -1016,7 +1016,7 @@ ipf_sync_nat(softc, sp, data) } RWLOCK_EXIT(&softs->ipf_syncnat); - return 0; + return err; } From owner-svn-src-head@freebsd.org Sat May 27 18:46:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAEACD85B98; Sat, 27 May 2017 18:46:01 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B2C2C1909; Sat, 27 May 2017 18:46:01 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RIk0Af049070; Sat, 27 May 2017 18:46:00 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RIk0ks049069; Sat, 27 May 2017 18:46:00 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201705271846.v4RIk0ks049069@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 27 May 2017 18:46:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318999 - head/sys/boot/common 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.23 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, 27 May 2017 18:46:02 -0000 Author: bapt Date: Sat May 27 18:46:00 2017 New Revision: 318999 URL: https://svnweb.freebsd.org/changeset/base/318999 Log: Update the comments concerning net_parse_rootpath to reflect what it is now really doing Reported by: rgrimes Reviewed by: rgrimes Differential Revision: https://reviews.freebsd.org/D10959 Modified: head/sys/boot/common/dev_net.c Modified: head/sys/boot/common/dev_net.c ============================================================================== --- head/sys/boot/common/dev_net.c Sat May 27 18:01:14 2017 (r318998) +++ head/sys/boot/common/dev_net.c Sat May 27 18:46:00 2017 (r318999) @@ -367,8 +367,20 @@ net_print(int verbose) } /* - * Strip the server's address off of the rootpath if present and return it in - * network byte order, leaving just the pathname part in the global rootpath. + * Parses the rootpath if present + * + * The rootpath format can be in the form + * ://ip/path + * :/path + * + * For compatibility with previous behaviour it also accepts as an NFS scheme + * ip:/path + * /path + * + * If an ip is set it returns it in network byte order. + * The default scheme defined in the global netproto, if not set it defaults to + * NFS. + * It leaves just the pathname in the global rootpath. */ uint32_t net_parse_rootpath() From owner-svn-src-head@freebsd.org Sat May 27 20:01:52 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3656FD85EC6; Sat, 27 May 2017 20:01:52 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 05D401E61; Sat, 27 May 2017 20:01:51 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RK1p1I081490; Sat, 27 May 2017 20:01:51 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RK1pV6081489; Sat, 27 May 2017 20:01:51 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201705272001.v4RK1pV6081489@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sat, 27 May 2017 20:01:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319000 - head/contrib/binutils/ld 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.23 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, 27 May 2017 20:01:52 -0000 Author: pfg Date: Sat May 27 20:01:50 2017 New Revision: 319000 URL: https://svnweb.freebsd.org/changeset/base/319000 Log: Align text correctly by using tabs instead of spaces. The text was copy-pasted from the lines that carry the bogus spaces. This is a non-functional change. Modified: head/contrib/binutils/ld/configure.tgt Modified: head/contrib/binutils/ld/configure.tgt ============================================================================== --- head/contrib/binutils/ld/configure.tgt Sat May 27 18:46:00 2017 (r318999) +++ head/contrib/binutils/ld/configure.tgt Sat May 27 20:01:50 2017 (r319000) @@ -480,7 +480,7 @@ powerpc-*-lynxos*) targ_emul=ppclynx ;; rs6000-*-aix5*) targ_emul=aix5rs6 ;; rs6000-*-aix*) targ_emul=aixrs6 ;; -s390x-*-freebsd*) targ_emul=elf64_s390 +s390x-*-freebsd*) targ_emul=elf64_s390 targ_extra_emuls=elf_s390 targ_extra_libpath=$targ_extra_emuls tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; @@ -490,7 +490,7 @@ s390x-*-linux*) targ_emul=elf64_ tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; s390x-*-tpf*) targ_emul=elf64_s390 tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'` ;; -s390-*-freebsd*) targ_emul=elf_s390 +s390-*-freebsd*) targ_emul=elf_s390 targ64_extra_emuls=elf64_s390 targ64_extra_libpath=elf64_s390 tdir_elf64_s390=`echo ${targ_alias} | sed -e 's/s390/s390x/'` From owner-svn-src-head@freebsd.org Sat May 27 21:46:01 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C730FD85A41; Sat, 27 May 2017 21:46:01 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 97A7C1F41; Sat, 27 May 2017 21:46:01 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RLk0Dt024294; Sat, 27 May 2017 21:46:00 GMT (envelope-from alc@FreeBSD.org) Received: (from alc@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RLk0hP024293; Sat, 27 May 2017 21:46:00 GMT (envelope-from alc@FreeBSD.org) Message-Id: <201705272146.v4RLk0hP024293@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: alc set sender to alc@FreeBSD.org using -f From: Alan Cox Date: Sat, 27 May 2017 21:46:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319001 - head/sys/vm 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.23 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, 27 May 2017 21:46:01 -0000 Author: alc Date: Sat May 27 21:46:00 2017 New Revision: 319001 URL: https://svnweb.freebsd.org/changeset/base/319001 Log: After r118390, the variable "dmmax" was neither the correct strip size nor the correct maximum block size. Moreover, after r318995, it serves no purpose except to provide information to user space through a read- sysctl. This change eliminates the variable "dmmax" but retains the sysctl. It also corrects the value returned by the sysctl. Reviewed by: kib, markj MFC after: 3 days Modified: head/sys/vm/swap_pager.c Modified: head/sys/vm/swap_pager.c ============================================================================== --- head/sys/vm/swap_pager.c Sat May 27 20:01:50 2017 (r319000) +++ head/sys/vm/swap_pager.c Sat May 27 21:46:00 2017 (r319001) @@ -381,18 +381,14 @@ struct pagerops swappagerops = { }; /* - * dmmax is in page-sized chunks with the new swap system. It was - * dev-bsized chunks in the old. dmmax is always a power of 2. - * * swap_*() routines are externally accessible. swp_*() routines are * internal. */ -static int dmmax; static int nswap_lowat = 128; /* in pages, swap_pager_almost_full warn */ static int nswap_hiwat = 512; /* in pages, swap_pager_almost_full warn */ -SYSCTL_INT(_vm, OID_AUTO, dmmax, CTLFLAG_RD, &dmmax, 0, - "Maximum size of a swap block"); +SYSCTL_INT(_vm, OID_AUTO, dmmax, CTLFLAG_RD, &nsw_cluster_max, 0, + "Maximum size of a swap block in pages"); static void swp_sizecheck(void); static void swp_pager_async_iodone(struct buf *bp); @@ -489,11 +485,6 @@ swap_pager_init(void) mtx_init(&sw_dev_mtx, "swapdev", NULL, MTX_DEF); sx_init(&sw_alloc_sx, "swspsx"); sx_init(&swdev_syscall_lock, "swsysc"); - - /* - * Device Stripe, in PAGE_SIZE'd blocks - */ - dmmax = SWB_NPAGES * 2; } /* From owner-svn-src-head@freebsd.org Sat May 27 22:40:21 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D2B38D85606; Sat, 27 May 2017 22:40:21 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A24EF1764; Sat, 27 May 2017 22:40:21 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RMeKS7045088; Sat, 27 May 2017 22:40:20 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RMeKap045087; Sat, 27 May 2017 22:40:20 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705272240.v4RMeKap045087@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 27 May 2017 22:40:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319002 - head/usr.bin/grep/tests 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.23 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, 27 May 2017 22:40:21 -0000 Author: ngie Date: Sat May 27 22:40:20 2017 New Revision: 319002 URL: https://svnweb.freebsd.org/changeset/base/319002 Log: :rgrep : use atf-check to check the exit code/save the output of grep -r instead of calling grep -r without it, and saving the output to a file This ensures that any errors thrown via grep -r are caught, not lost, and uses existing atf-sh idioms for saving files. Tested with: bsdgrep, gnu grep (base, ports) Sponsored by: Dell EMC Isilon Modified: head/usr.bin/grep/tests/grep_freebsd_test.sh Modified: head/usr.bin/grep/tests/grep_freebsd_test.sh ============================================================================== --- head/usr.bin/grep/tests/grep_freebsd_test.sh Sat May 27 21:46:00 2017 (r319001) +++ head/usr.bin/grep/tests/grep_freebsd_test.sh Sat May 27 22:40:20 2017 (r319002) @@ -77,8 +77,7 @@ rgrep_head() } rgrep_body() { - grep -r --exclude="*.out" -e "test" "$(atf_get_srcdir)" > d_grep_r_implied.out - + atf_check -o save:d_grep_r_implied.out grep -r --exclude="*.out" -e "test" "$(atf_get_srcdir)" atf_check -o file:d_grep_r_implied.out rgrep --exclude="*.out" -e "test" "$(atf_get_srcdir)" } From owner-svn-src-head@freebsd.org Sat May 27 23:19:33 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CE0DDD85E89; Sat, 27 May 2017 23:19:33 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9B0B81B78; Sat, 27 May 2017 23:19:33 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RNJWXK061397; Sat, 27 May 2017 23:19:32 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RNJWuZ061396; Sat, 27 May 2017 23:19:32 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705272319.v4RNJWuZ061396@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 27 May 2017 23:19:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319008 - head/lib/libkvm/tests 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.23 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, 27 May 2017 23:19:33 -0000 Author: ngie Date: Sat May 27 23:19:32 2017 New Revision: 319008 URL: https://svnweb.freebsd.org/changeset/base/319008 Log: kvm_geterr_test: Compile out the portions that require kvm_open2(3) on systems that lack the libcall, based on __FreeBSD_version. kvm_open2(3) wasn't made available until r291406, which is in ^/stable/11, but not ^/stable/10. This makes some of kvm_geterr_test available for testing on ^/stable/10. MFC after: now Sponsored by: Dell EMC Isilon Modified: head/lib/libkvm/tests/kvm_geterr_test.c Modified: head/lib/libkvm/tests/kvm_geterr_test.c ============================================================================== --- head/lib/libkvm/tests/kvm_geterr_test.c Sat May 27 23:04:48 2017 (r319007) +++ head/lib/libkvm/tests/kvm_geterr_test.c Sat May 27 23:19:32 2017 (r319008) @@ -65,6 +65,8 @@ ATF_TC_HEAD(kvm_geterr_positive_test_err atf_tc_set_md_var(tc, "require.user", "root"); } +/* 1100090 was where kvm_open2(3) was introduced. */ +#if __FreeBSD_version >= 1100091 ATF_TC_BODY(kvm_geterr_positive_test_error, tc) { kvm_t *kd; @@ -125,13 +127,16 @@ ATF_TC_BODY(kvm_geterr_positive_test_no_ ATF_REQUIRE_MSG(kvm_close(kd) == 0, "kvm_close failed: %s", strerror(errno)); } +#endif ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, kvm_geterr_negative_test_NULL); +#if __FreeBSD_version >= 1100091 ATF_TP_ADD_TC(tp, kvm_geterr_positive_test_error); ATF_TP_ADD_TC(tp, kvm_geterr_positive_test_no_error); +#endif return (atf_no_error()); } From owner-svn-src-head@freebsd.org Sat May 27 23:23:23 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 83B4BD84118; Sat, 27 May 2017 23:23:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 534EC10EC; Sat, 27 May 2017 23:23:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RNNM6g065565; Sat, 27 May 2017 23:23:22 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RNNMYI065564; Sat, 27 May 2017 23:23:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705272323.v4RNNMYI065564@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 27 May 2017 23:23:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319010 - head/lib/libkvm/tests 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.23 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, 27 May 2017 23:23:23 -0000 Author: ngie Date: Sat May 27 23:23:22 2017 New Revision: 319010 URL: https://svnweb.freebsd.org/changeset/base/319010 Log: Fix #if conditional added in r319008 I committed an earlier version of the file by accident This is a no-op on ^/head and ^/stable/11. MFC after: now Sponsored by: Dell EMC Isilon Modified: head/lib/libkvm/tests/kvm_geterr_test.c Modified: head/lib/libkvm/tests/kvm_geterr_test.c ============================================================================== --- head/lib/libkvm/tests/kvm_geterr_test.c Sat May 27 23:20:28 2017 (r319009) +++ head/lib/libkvm/tests/kvm_geterr_test.c Sat May 27 23:23:22 2017 (r319010) @@ -56,6 +56,8 @@ ATF_TC_BODY(kvm_geterr_negative_test_NUL ATF_REQUIRE(!errbuf_has_error(kvm_geterr(NULL))); } +/* 1100090 was where kvm_open2(3) was introduced. */ +#if __FreeBSD_version >= 1100091 ATF_TC(kvm_geterr_positive_test_error); ATF_TC_HEAD(kvm_geterr_positive_test_error, tc) { @@ -65,8 +67,6 @@ ATF_TC_HEAD(kvm_geterr_positive_test_err atf_tc_set_md_var(tc, "require.user", "root"); } -/* 1100090 was where kvm_open2(3) was introduced. */ -#if __FreeBSD_version >= 1100091 ATF_TC_BODY(kvm_geterr_positive_test_error, tc) { kvm_t *kd; From owner-svn-src-head@freebsd.org Sat May 27 23:57:10 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BDBA0D84D34; Sat, 27 May 2017 23:57:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8DF5B1383; Sat, 27 May 2017 23:57:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4RNv9DA078143; Sat, 27 May 2017 23:57:09 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4RNv9Vb078142; Sat, 27 May 2017 23:57:09 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201705272357.v4RNv9Vb078142@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 27 May 2017 23:57:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r319015 - head/tools/regression/geom_gpt 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.23 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, 27 May 2017 23:57:10 -0000 Author: ngie Date: Sat May 27 23:57:09 2017 New Revision: 319015 URL: https://svnweb.freebsd.org/changeset/base/319015 Log: Use calloc instead of malloc + memset MFC after: 3 days Sponsored by: Dell EMC Isilon Modified: head/tools/regression/geom_gpt/gctl_test_helper.c Modified: head/tools/regression/geom_gpt/gctl_test_helper.c ============================================================================== --- head/tools/regression/geom_gpt/gctl_test_helper.c Sat May 27 23:31:59 2017 (r319014) +++ head/tools/regression/geom_gpt/gctl_test_helper.c Sat May 27 23:57:09 2017 (r319015) @@ -87,10 +87,9 @@ parse(char *arg, char **param, char **va return (EINVAL); if (*len <= 0 || *len > PATH_MAX) return (EINVAL); - *value = malloc(*len); + *value = calloc(*len, sizeof(char)); if (*value == NULL) return (ENOMEM); - memset(*value, 0, *len); if (equal != NULL) { if (strlen(equal) >= PATH_MAX) return (ENOMEM);