From owner-svn-src-stable-11@freebsd.org Sun Dec 17 06:00:51 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1B458EA4229; Sun, 17 Dec 2017 06:00:51 +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 E6F2264382; Sun, 17 Dec 2017 06:00:50 +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 vBH60n75015476; Sun, 17 Dec 2017 06:00:49 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBH60nNT015473; Sun, 17 Dec 2017 06:00:49 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201712170600.vBH60nNT015473@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Sun, 17 Dec 2017 06:00:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326918 - in stable: 10 10/usr.sbin/fdformat 11 11/usr.sbin/fdformat X-SVN-Group: stable-11 X-SVN-Commit-Author: cy X-SVN-Commit-Paths: in stable: 10 10/usr.sbin/fdformat 11 11/usr.sbin/fdformat X-SVN-Commit-Revision: 326918 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Dec 2017 06:00:51 -0000 Author: cy Date: Sun Dec 17 06:00:49 2017 New Revision: 326918 URL: https://svnweb.freebsd.org/changeset/base/326918 Log: MFC r326558, r326566: fdformat is a sysadmin command and thus its man page should be in volume 8 instead of volume 1. Reviewed by: imp Added: stable/11/usr.sbin/fdformat/fdformat.8 - copied unchanged from r326558, head/usr.sbin/fdformat/fdformat.8 Deleted: stable/11/usr.sbin/fdformat/fdformat.1 Modified: stable/11/ObsoleteFiles.inc stable/11/usr.sbin/fdformat/Makefile Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Added: stable/10/usr.sbin/fdformat/fdformat.8 - copied unchanged from r326558, head/usr.sbin/fdformat/fdformat.8 Deleted: stable/10/usr.sbin/fdformat/fdformat.1 Modified: stable/10/ObsoleteFiles.inc stable/10/usr.sbin/fdformat/Makefile Directory Properties: stable/10/ (props changed) Modified: stable/11/ObsoleteFiles.inc ============================================================================== --- stable/11/ObsoleteFiles.inc Sun Dec 17 04:19:19 2017 (r326917) +++ stable/11/ObsoleteFiles.inc Sun Dec 17 06:00:49 2017 (r326918) @@ -38,6 +38,8 @@ # xargs -n1 | sort | uniq -d; # done +# 20171204: Move fdformat man page from volume 1 to volume 8. +OLD_FILES+=usr/share/man/man1/fdformat.1.gz # 20170926: new clang import which bumps version from 4.0.0 to 5.0.0. OLD_FILES+=usr/lib/clang/4.0.0/include/sanitizer/allocator_interface.h OLD_FILES+=usr/lib/clang/4.0.0/include/sanitizer/asan_interface.h Modified: stable/11/usr.sbin/fdformat/Makefile ============================================================================== --- stable/11/usr.sbin/fdformat/Makefile Sun Dec 17 04:19:19 2017 (r326917) +++ stable/11/usr.sbin/fdformat/Makefile Sun Dec 17 06:00:49 2017 (r326918) @@ -3,6 +3,7 @@ .PATH: ${.CURDIR:H}/fdread PROG= fdformat +MAN= fdformat.8 SRCS= fdformat.c fdutil.c CFLAGS+= -I${.CURDIR:H}/fdread Copied: stable/11/usr.sbin/fdformat/fdformat.8 (from r326558, head/usr.sbin/fdformat/fdformat.8) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/usr.sbin/fdformat/fdformat.8 Sun Dec 17 06:00:49 2017 (r326918, copy of r326558, head/usr.sbin/fdformat/fdformat.8) @@ -0,0 +1,180 @@ +.\" Copyright (C) 1993, 1994, 1995, 2001 by Joerg Wunsch, Dresden +.\" 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(S) ``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(S) 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 December 4, 2017 +.Dt FDFORMAT 8 +.Os +.Sh NAME +.Nm fdformat +.Nd format floppy disks +.Sh SYNOPSIS +.Nm +.Op Fl F Ar fill +.Op Fl f Ar fmt +.Op Fl s Ar fmtstr +.Op Fl nqvy +.Ar device +.Sh DESCRIPTION +The +.Nm +utility formats a floppy disk at +.Ar device , +where +.Ar device +may either be given as a full path +name of a device node for a floppy disk drive +(e.g.\& +.Pa /dev/fd0 ) , +or using an abbreviated name that will be looked up +under +.Pa /dev +(e.g.\& +.Dq Li fd0 ) . +.Pp +The options are as follows: +.Bl -tag -width ".Fl s Ar fmtstr" +.It Fl F Ar fill +Use +.Ar fill +as the fill byte for newly formatted sectors. +The +.Ar fill +argument +must be a number in the range 0 through 255 using common C +language notation. +The default value is +.Dq Li 0xf6 . +.It Fl f Ar fmt +Specify the density settings for a +.Ar fmt +kilobyte format, as described in +.Xr fdcontrol 8 . +.It Fl s Ar fmtstr +Specify the density settings using explicit parameters, as +described in +.Xr fdcontrol 8 . +.It Fl n +Do not verify floppy after formatting. +.It Fl q +Suppress any normal output from the command, and do not ask the +user for a confirmation whether to format the floppy disk at +.Ar device . +.It Fl v +Do not format, verify only. +.It Fl y +Do not ask for confirmation whether to format the floppy disk but +still report formatting status. +.El +.Pp +For non-autoselecting subdevices, neither +.Fl f Ar fmt +nor +.Fl s Ar fmtstr +may be specified, since the preconfigured media density settings +from the kernel driver will always be used. +However, if +.Ar device +is a device with automatic media density selection (see +.Xr fdc 4 ) , +both methods can be used to override the density settings for the +newly formatted medium (without permanently changing the density +settings of +.Ar device ) . +.Pp +If the +.Fl q +flag has not been specified, the user is asked for a confirmation +of the intended formatting process. +In order to continue, an answer +of +.Ql y +must be given. +.Pp +Note that +.Nm +does only perform low-level formatting. +In order to create +a file system on the medium, see the commands +.Xr newfs 8 +for a +.Tn UFS +file system, or +.Xr newfs_msdos 8 +for an +.Tn MS-DOS +(FAT) +file system. +.Sh EXIT STATUS +An exit status of 0 is returned upon successful operation. +Exit status +1 is returned on any errors during floppy formatting, and an exit status +of 2 reflects invalid arguments given to the program (along with an +appropriate information written to diagnostic output). +.Sh DIAGNOSTICS +Unless +.Fl q +has been specified, a single letter is printed to standard output +to inform the user about the progress of work. +First, an +.Ql F +is printed when the track is being formatted, then a +.Ql V +while it is being verified, and if an error has been detected, it +will finally change to +.Ql E . +Detailed status information (cylinder, head and sector number, and the +exact cause of the error) will be printed for up to 10 errors after the +entire formatting process has completed. +.Sh SEE ALSO +.Xr fdc 4 , +.Xr fdcontrol 8 , +.Xr newfs 8 , +.Xr newfs_msdos 8 +.Sh HISTORY +The +.Nm +utility +has been developed for +.Bx 386 0.1 +and upgraded to the new +.Xr fdc 4 +floppy disk driver. +It later became part of the +.Fx 1.1 +system. +Starting with +.Fx 5.0 , +it uses the unified density specifications as described in +.Xr fdcontrol 8 . +.Sh AUTHORS +.An -nosplit +The program has been contributed by +.An J\(:org Wunsch , +Dresden, with changes by +.An Serge Vakulenko +and +.An Andrey A. Chernov , +Moscow. From owner-svn-src-stable-11@freebsd.org Sun Dec 17 19:48:37 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0C371E939D0; Sun, 17 Dec 2017 19:48:37 +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 CA3287B93C; Sun, 17 Dec 2017 19:48:36 +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 vBHJmZel064153; Sun, 17 Dec 2017 19:48:35 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBHJmZB9064152; Sun, 17 Dec 2017 19:48:35 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712171948.vBHJmZB9064152@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Sun, 17 Dec 2017 19:48:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326920 - stable/11/sys/vm X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/vm X-SVN-Commit-Revision: 326920 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Dec 2017 19:48:37 -0000 Author: markj Date: Sun Dec 17 19:48:35 2017 New Revision: 326920 URL: https://svnweb.freebsd.org/changeset/base/326920 Log: MFC r326732: Fix the act_scan_laundry_weight mechanism. Modified: stable/11/sys/vm/vm_pageout.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/vm/vm_pageout.c ============================================================================== --- stable/11/sys/vm/vm_pageout.c Sun Dec 17 18:21:40 2017 (r326919) +++ stable/11/sys/vm/vm_pageout.c Sun Dec 17 19:48:35 2017 (r326920) @@ -1339,7 +1339,7 @@ drop_page: inactq_shortage = vm_cnt.v_inactive_target - (vm_cnt.v_inactive_count + vm_cnt.v_laundry_count / act_scan_laundry_weight) + vm_paging_target() + deficit + addl_page_shortage; - page_shortage *= act_scan_laundry_weight; + inactq_shortage *= act_scan_laundry_weight; pq = &vmd->vmd_pagequeues[PQ_ACTIVE]; vm_pagequeue_lock(pq); From owner-svn-src-stable-11@freebsd.org Sun Dec 17 19:49:39 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3210FE93B41; Sun, 17 Dec 2017 19:49:39 +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 F06F67BBC7; Sun, 17 Dec 2017 19:49:38 +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 vBHJncYv064240; Sun, 17 Dec 2017 19:49:38 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBHJncXe064239; Sun, 17 Dec 2017 19:49:38 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712171949.vBHJncXe064239@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Sun, 17 Dec 2017 19:49:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326921 - stable/11/sys/ufs/ffs X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/ufs/ffs X-SVN-Commit-Revision: 326921 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Dec 2017 19:49:39 -0000 Author: markj Date: Sun Dec 17 19:49:37 2017 New Revision: 326921 URL: https://svnweb.freebsd.org/changeset/base/326921 Log: MFC r326731: Provide a sysctl to force synchronous initialization of inode blocks. Modified: stable/11/sys/ufs/ffs/ffs_alloc.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/ufs/ffs/ffs_alloc.c ============================================================================== --- stable/11/sys/ufs/ffs/ffs_alloc.c Sun Dec 17 19:48:35 2017 (r326920) +++ stable/11/sys/ufs/ffs/ffs_alloc.c Sun Dec 17 19:49:37 2017 (r326921) @@ -1974,6 +1974,16 @@ getinobuf(struct inode *ip, u_int cg, u_int32_t cginob } /* + * Synchronous inode initialization is needed only when barrier writes do not + * work as advertised, and will impose a heavy cost on file creation in a newly + * created filesystem. + */ +static int doasyncinodeinit = 1; +SYSCTL_INT(_vfs_ffs, OID_AUTO, doasyncinodeinit, CTLFLAG_RWTUN, + &doasyncinodeinit, 0, + "Perform inode block initialization using asynchronous writes"); + +/* * Determine whether an inode can be allocated. * * Check to see if an inode is available, and if it is, @@ -2086,6 +2096,7 @@ gotit: dp2->di_gen = arc4random(); dp2++; } + /* * Rather than adding a soft updates dependency to ensure * that the new inode block is written before it is claimed @@ -2095,7 +2106,10 @@ gotit: * written. The barrier write should only slow down bulk * loading of newly created filesystems. */ - babarrierwrite(ibp); + if (doasyncinodeinit) + babarrierwrite(ibp); + else + bwrite(ibp); /* * After the inode block is written, try to update the From owner-svn-src-stable-11@freebsd.org Sun Dec 17 19:58:49 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9D3E9E9422C; Sun, 17 Dec 2017 19:58:49 +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 675277C337; Sun, 17 Dec 2017 19:58:49 +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 vBHJwmwA068220; Sun, 17 Dec 2017 19:58:48 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBHJwmo0068219; Sun, 17 Dec 2017 19:58:48 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712171958.vBHJwmo0068219@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Sun, 17 Dec 2017 19:58:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326922 - stable/11/sys/kern X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/kern X-SVN-Commit-Revision: 326922 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Dec 2017 19:58:49 -0000 Author: markj Date: Sun Dec 17 19:58:48 2017 New Revision: 326922 URL: https://svnweb.freebsd.org/changeset/base/326922 Log: MFC r326438: Plug a name cache lock leak. Modified: stable/11/sys/kern/vfs_cache.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/vfs_cache.c ============================================================================== --- stable/11/sys/kern/vfs_cache.c Sun Dec 17 19:49:37 2017 (r326921) +++ stable/11/sys/kern/vfs_cache.c Sun Dec 17 19:58:48 2017 (r326922) @@ -1151,6 +1151,8 @@ retry_dotdot: SDT_PROBE3(vfs, namecache, lookup, miss, dvp, "..", NULL); mtx_unlock(dvlp); + if (dvlp2 != NULL) + mtx_unlock(dvlp2); return (0); } if ((cnp->cn_flags & MAKEENTRY) == 0) { From owner-svn-src-stable-11@freebsd.org Mon Dec 18 05:29:39 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 67DA4EA1C91; Mon, 18 Dec 2017 05:29:39 +0000 (UTC) (envelope-from karels@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 2B9426C23C; Mon, 18 Dec 2017 05:29:39 +0000 (UTC) (envelope-from karels@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBI5TcDm007402; Mon, 18 Dec 2017 05:29:38 GMT (envelope-from karels@FreeBSD.org) Received: (from karels@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBI5TceV007401; Mon, 18 Dec 2017 05:29:38 GMT (envelope-from karels@FreeBSD.org) Message-Id: <201712180529.vBI5TceV007401@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: karels set sender to karels@FreeBSD.org using -f From: Mike Karels Date: Mon, 18 Dec 2017 05:29:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326928 - stable/11/share/man/man5 X-SVN-Group: stable-11 X-SVN-Commit-Author: karels X-SVN-Commit-Paths: stable/11/share/man/man5 X-SVN-Commit-Revision: 326928 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 05:29:39 -0000 Author: karels Date: Mon Dec 18 05:29:38 2017 New Revision: 326928 URL: https://svnweb.freebsd.org/changeset/base/326928 Log: MFC r326734: gifconfig_gif0 no longer works, document replacement rc.conf(5) documents the gifconfig_ keyword, which is no longer implemented. Document the replacement, which works with cloned_interfaces as well. Reviewed by: dab Group Reviwers: manpages Differential Revision: https://reviews.freebsd.org/D13130 Modified: stable/11/share/man/man5/rc.conf.5 Modified: stable/11/share/man/man5/rc.conf.5 ============================================================================== --- stable/11/share/man/man5/rc.conf.5 Mon Dec 18 04:51:45 2017 (r326927) +++ stable/11/share/man/man5/rc.conf.5 Mon Dec 18 05:29:38 2017 (r326928) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd June 8, 2016 +.Dd December 17, 2017 .Dt RC.CONF 5 .Os .Sh NAME @@ -1778,21 +1778,40 @@ This variable is deprecated in favor of Set to the list of .Xr gif 4 tunnel interfaces to configure on this host. -A -.Va gifconfig_ Ns Aq Ar interface -variable is assumed to exist for each value of -.Ar interface . +For each +.Xr gif +tunnel interface, set a variable named +.Va ifconfig_ Ns Aq Ar interface +with the parameters for the +.Xr ifconfig 8 +command to configure the link level for +.Ar interface +with the +.Cm tunnel +option. The value of this variable is used to configure the link layer of the -tunnel according to the syntax of the +tunnel using the .Cm tunnel option to -.Xr ifconfig 8 . +.Xr ifconfig . +For example, configure two +.Xr gif +interfaces with: +.Bd -literal -offset indent +gif_interfaces="gif0 gif1" +ifconfig_gif0="tunnel src_addr0 dst_addr0" +ifconfig_gif1="tunnel src_addr1 dst_addr1" +.Ed +.Pp Additionally, this option ensures that each listed interface is created via the .Cm create option to -.Xr ifconfig 8 -before attempting to configure it. +.Xr ifconfig . +This example also works with +.Va cloned_interfaces +instead of +.Va gif_interfaces . .It Va sppp_interfaces .Pq Vt str Set to the list of From owner-svn-src-stable-11@freebsd.org Mon Dec 18 17:17:08 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8DD71E9CA28; Mon, 18 Dec 2017 17:17:08 +0000 (UTC) (envelope-from ian@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 655BF647B1; Mon, 18 Dec 2017 17:17:08 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBIHH7KL007749; Mon, 18 Dec 2017 17:17:07 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBIHH75G007747; Mon, 18 Dec 2017 17:17:07 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201712181717.vBIHH75G007747@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Mon, 18 Dec 2017 17:17:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326934 - in stable/11/sys/boot: arm/uboot uboot/lib X-SVN-Group: stable-11 X-SVN-Commit-Author: ian X-SVN-Commit-Paths: in stable/11/sys/boot: arm/uboot uboot/lib X-SVN-Commit-Revision: 326934 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 17:17:08 -0000 Author: ian Date: Mon Dec 18 17:17:07 2017 New Revision: 326934 URL: https://svnweb.freebsd.org/changeset/base/326934 Log: MFC (conceptually) r326752, r326754: This is a direct commit to 11-stable, because the code has moved and the directories have been restructured in 12-current, but it just hand- applies the same patches to the corresponding files in their old locations. r326752: Save and restore r9 register in arm ubldr. In old gcc 4.2, r9 was a callee- saved register, but in arm EABI it may be either callee-saved or dedicated to some special purpose (such as a TLS pointer). It appears clang does not treat it as a callee-saved register (instead using it as another work register, similar to r12). Another important side effect of these changes is that saving an extra register in the push/pop statements keeps the stack aligned to an 8-byte boundary during the self_reloc() call, as it always should have been. As stated in the PR... Essentially the important caller-saved registers are pushed (r0, r1, r9, lr) before the relocation call, and popped after. Then r8/r9 are saved as usual for the syscall trampoline, and lr is stored in r8 (now free) as a callee-saved value before calling into `main`. The call to `main` can no longer be a tail call because we must restore r9 especially after main returns (although since we have used r8 to hold lr we must also restore this). r326754: When building for arm arches, set PKTALIGN to the max cache line size supported by the arch, to meet u-boot's requirement that I/O be done in cache-aligned chunks. PR: 223977 224008 Modified: stable/11/sys/boot/arm/uboot/start.S stable/11/sys/boot/uboot/lib/libuboot.h Modified: stable/11/sys/boot/arm/uboot/start.S ============================================================================== --- stable/11/sys/boot/arm/uboot/start.S Mon Dec 18 14:29:48 2017 (r326933) +++ stable/11/sys/boot/arm/uboot/start.S Mon Dec 18 17:17:07 2017 (r326934) @@ -46,11 +46,8 @@ _start: mcr p15, 0, ip, c1, c0, 0 #endif - /* - * Save r0 and r1 (argc and argv passed from u-boot), and lr (trashed - * by the call to self_reloc below) until we're ready to call main(). - */ - push {r0, r1, lr} + /* Save the arguments and return register before calling self_reloc */ + push {r0, r1, r9, lr} /* * Do self-relocation when the weak external symbol _DYNAMIC is non-NULL. @@ -68,22 +65,31 @@ _start: addne r1, r1, r0 /* r1 = dynamic section physaddr. */ blne _C_LABEL(self_reloc) /* Do reloc if _DYNAMIC is non-NULL. */ + /* Restore saved arguments */ + pop {r0, r1, r9, lr} + /* Hint where to look for the API signature */ ldr ip, =uboot_address str sp, [ip] - /* Save U-Boot's r8 and r9 */ + /* Save U-Boot's r8 and r9 for syscall trampoline */ ldr ip, =saved_regs - str r8, [ip, #0] - str r9, [ip, #4] + str r8, [ip, #0] /* old gd pointer (use to hold lr) */ + str r9, [ip, #4] /* new gd pointer */ /* - * First restore argc, argv, and the u-boot return address, then - * Start loader. This is basically a tail-recursion call; if main() - * returns, it returns to u-boot (which reports the value returned r0). + * Start loader. Save return address first (r8 is available from + * trampoline save). */ - pop {r0, r1, lr} - b main + mov r8, lr + bl main + mov lr, r8 + + /* Restore U-Boot environment */ + ldr ip, =saved_regs + ldr r8, [ip, #0] + ldr r9, [ip, #4] + mov pc, lr /* * Data for self-relocation, in the text segment for pc-rel access. Modified: stable/11/sys/boot/uboot/lib/libuboot.h ============================================================================== --- stable/11/sys/boot/uboot/lib/libuboot.h Mon Dec 18 14:29:48 2017 (r326933) +++ stable/11/sys/boot/uboot/lib/libuboot.h Mon Dec 18 17:17:07 2017 (r326934) @@ -45,9 +45,16 @@ struct uboot_devdesc #define d_disk d_kind.disk /* - * Default network packet alignment in memory + * Default network packet alignment in memory. On arm arches packets must be + * aligned to cacheline boundaries. */ +#if defined(__aarch64__) +#define PKTALIGN 128 +#elif defined(__arm__) +#define PKTALIGN 64 +#else #define PKTALIGN 32 +#endif int uboot_getdev(void **vdev, const char *devspec, const char **path); char *uboot_fmtdev(void *vdev); From owner-svn-src-stable-11@freebsd.org Mon Dec 18 20:17:56 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0E58EE83E47; Mon, 18 Dec 2017 20:17:56 +0000 (UTC) (envelope-from manu@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 D98C56DBFC; Mon, 18 Dec 2017 20:17:55 +0000 (UTC) (envelope-from manu@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBIKHsmc086002; Mon, 18 Dec 2017 20:17:54 GMT (envelope-from manu@FreeBSD.org) Received: (from manu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBIKHsp9085998; Mon, 18 Dec 2017 20:17:54 GMT (envelope-from manu@FreeBSD.org) Message-Id: <201712182017.vBIKHsp9085998@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: manu set sender to manu@FreeBSD.org using -f From: Emmanuel Vadot Date: Mon, 18 Dec 2017 20:17:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326951 - in stable/11/sys: boot/fdt/dts/arm conf modules/dtb/rpi X-SVN-Group: stable-11 X-SVN-Commit-Author: manu X-SVN-Commit-Paths: in stable/11/sys: boot/fdt/dts/arm conf modules/dtb/rpi X-SVN-Commit-Revision: 326951 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 20:17:56 -0000 Author: manu Date: Mon Dec 18 20:17:54 2017 New Revision: 326951 URL: https://svnweb.freebsd.org/changeset/base/326951 Log: MFC r312914, r322694 r312914 by imp: Honor LINKS=x y in dtb modules. We need this for compatibility links for old, FreeBSD names. r322694: RPI DTS: Add value previously set by VideoCore and DTB links Using latest U-Boot for RPI 1 or 2 the DTB loaded by the firmware is discarded. The DTB was previously patched by the firmware to contain the DMA channel mask. DTB provided by the rpi firmware or DTS in the Linux tree contain the raw value directly. Do the same for our DTS as we cannot switch to the upstream ones yet. Not having the DMA channel mask setup properly cause mmc not to be detected (and probably other problems on driver using DMA). Also, add links for rpi dtb to the name used by u-boot. This way the dtb can be loaded by ubldr using the U-Boot env variable fdtfile. Tested On: RPI B Rev2, RPI Zero, RPI 2 v1.1 RPI 2 v1.2 Thanks to Sylvain Garrigues for the help. PR: 218344 Modified: stable/11/sys/boot/fdt/dts/arm/bcm2835.dtsi stable/11/sys/boot/fdt/dts/arm/bcm2836.dtsi stable/11/sys/conf/dtb.mk stable/11/sys/modules/dtb/rpi/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/boot/fdt/dts/arm/bcm2835.dtsi ============================================================================== --- stable/11/sys/boot/fdt/dts/arm/bcm2835.dtsi Mon Dec 18 20:12:43 2017 (r326950) +++ stable/11/sys/boot/fdt/dts/arm/bcm2835.dtsi Mon Dec 18 20:17:54 2017 (r326951) @@ -431,7 +431,7 @@ interrupts = <24 25 26 27 28 29 30 31 32 33 34 35 36>; interrupt-parent = <&intc>; - broadcom,channels = <0>; /* Set by VideoCore */ + broadcom,channels = <0x7f35>; }; vc_mbox: mbox { Modified: stable/11/sys/boot/fdt/dts/arm/bcm2836.dtsi ============================================================================== --- stable/11/sys/boot/fdt/dts/arm/bcm2836.dtsi Mon Dec 18 20:12:43 2017 (r326950) +++ stable/11/sys/boot/fdt/dts/arm/bcm2836.dtsi Mon Dec 18 20:17:54 2017 (r326951) @@ -424,7 +424,7 @@ interrupts = <24 25 26 27 28 29 30 31 32 33 34 35 36>; interrupt-parent = <&intc>; - broadcom,channels = <0>; /* Set by VideoCore */ + broadcom,channels = <0x7f35>; }; vc_mbox: mbox { Modified: stable/11/sys/conf/dtb.mk ============================================================================== --- stable/11/sys/conf/dtb.mk Mon Dec 18 20:12:43 2017 (r326950) +++ stable/11/sys/conf/dtb.mk Mon Dec 18 20:17:54 2017 (r326951) @@ -76,3 +76,4 @@ _dtbinstall: .include .include +.include Modified: stable/11/sys/modules/dtb/rpi/Makefile ============================================================================== --- stable/11/sys/modules/dtb/rpi/Makefile Mon Dec 18 20:12:43 2017 (r326950) +++ stable/11/sys/modules/dtb/rpi/Makefile Mon Dec 18 20:17:54 2017 (r326951) @@ -2,4 +2,11 @@ # DTS files for the Raspberry Pi-B DTS=rpi.dts rpi2.dts +LINKS= \ + ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b.dtb \ + ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b-rev2.dtb \ + ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b-plus.dtb \ + ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-zero.dtb \ + ${DTBDIR}/rpi2.dtb ${DTBDIR}/bcm2836-rpi-2-b.dtb + .include From owner-svn-src-stable-11@freebsd.org Mon Dec 18 22:55:21 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 34EA0E8FC63; Mon, 18 Dec 2017 22:55:21 +0000 (UTC) (envelope-from rmacklem@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 0E3E275550; Mon, 18 Dec 2017 22:55:20 +0000 (UTC) (envelope-from rmacklem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBIMtK8q054606; Mon, 18 Dec 2017 22:55:20 GMT (envelope-from rmacklem@FreeBSD.org) Received: (from rmacklem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBIMtKVv054605; Mon, 18 Dec 2017 22:55:20 GMT (envelope-from rmacklem@FreeBSD.org) Message-Id: <201712182255.vBIMtKVv054605@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rmacklem set sender to rmacklem@FreeBSD.org using -f From: Rick Macklem Date: Mon, 18 Dec 2017 22:55:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326952 - stable/11/sys/fs/nfsserver X-SVN-Group: stable-11 X-SVN-Commit-Author: rmacklem X-SVN-Commit-Paths: stable/11/sys/fs/nfsserver X-SVN-Commit-Revision: 326952 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Dec 2017 22:55:21 -0000 Author: rmacklem Date: Mon Dec 18 22:55:19 2017 New Revision: 326952 URL: https://svnweb.freebsd.org/changeset/base/326952 Log: MFC: r326544 Avoid the overhead of acquiring a lock in nfsrv_checkgetattr() when there are no write delegations issued. manu@ reported on the freebsd-current@ mailing list that there was a significant performance hit in nfsrv_checkgetattr() caused by the acquisition/release of a state lock, even when there were no write delegations issued. This patch add a count of outstanding issued write delegations to the NFSv4 server. This count allows nfsrv_checkgetattr() to return without acquiring any lock when the count is 0, avoiding the performance hit for the case where no write delegations are issued. Modified: stable/11/sys/fs/nfsserver/nfs_nfsdstate.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/fs/nfsserver/nfs_nfsdstate.c ============================================================================== --- stable/11/sys/fs/nfsserver/nfs_nfsdstate.c Mon Dec 18 20:17:54 2017 (r326951) +++ stable/11/sys/fs/nfsserver/nfs_nfsdstate.c Mon Dec 18 22:55:19 2017 (r326952) @@ -93,6 +93,7 @@ static time_t nfsrvboottime; static int nfsrv_returnoldstateid = 0, nfsrv_clients = 0; static int nfsrv_clienthighwater = NFSRV_CLIENTHIGHWATER; static int nfsrv_nogsscallback = 0; +static volatile int nfsrv_writedelegcnt = 0; /* local functions */ static void nfsrv_dumpaclient(struct nfsclient *clp, @@ -1261,6 +1262,8 @@ nfsrv_freedeleg(struct nfsstate *stp) LIST_REMOVE(stp, ls_hash); LIST_REMOVE(stp, ls_list); LIST_REMOVE(stp, ls_file); + if ((stp->ls_flags & NFSLCK_DELEGWRITE) != 0) + nfsrv_writedelegcnt--; lfp = stp->ls_lfp; if (LIST_EMPTY(&lfp->lf_open) && LIST_EMPTY(&lfp->lf_lock) && LIST_EMPTY(&lfp->lf_deleg) && @@ -2905,6 +2908,7 @@ tryagain: new_deleg->ls_flags = (NFSLCK_DELEGWRITE | NFSLCK_READACCESS | NFSLCK_WRITEACCESS); *rflagsp |= NFSV4OPEN_WRITEDELEGATE; + nfsrv_writedelegcnt++; } else { new_deleg->ls_flags = (NFSLCK_DELEGREAD | NFSLCK_READACCESS); @@ -3035,6 +3039,7 @@ tryagain: new_deleg->ls_clp = clp; new_deleg->ls_filerev = filerev; new_deleg->ls_compref = nd->nd_compref; + nfsrv_writedelegcnt++; LIST_INSERT_HEAD(&lfp->lf_deleg, new_deleg, ls_file); LIST_INSERT_HEAD(NFSSTATEHASH(clp, new_deleg->ls_stateid), new_deleg, ls_hash); @@ -3092,6 +3097,7 @@ tryagain: new_deleg->ls_flags = (NFSLCK_DELEGWRITE | NFSLCK_READACCESS | NFSLCK_WRITEACCESS); *rflagsp |= NFSV4OPEN_WRITEDELEGATE; + nfsrv_writedelegcnt++; } else { new_deleg->ls_flags = (NFSLCK_DELEGREAD | NFSLCK_READACCESS); @@ -3168,6 +3174,7 @@ tryagain: NFSLCK_READACCESS | NFSLCK_WRITEACCESS); *rflagsp |= NFSV4OPEN_WRITEDELEGATE; + nfsrv_writedelegcnt++; } else { new_deleg->ls_flags = (NFSLCK_DELEGREAD | @@ -5297,6 +5304,8 @@ nfsrv_checkgetattr(struct nfsrv_descript *nd, vnode_t NFSCBGETATTR_ATTRBIT(attrbitp, &cbbits); if (!NFSNONZERO_ATTRBIT(&cbbits)) + goto out; + if (nfsrv_writedelegcnt == 0) goto out; /* From owner-svn-src-stable-11@freebsd.org Tue Dec 19 11:39:07 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26779EA1C98; Tue, 19 Dec 2017 11:39:07 +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 E4EC774166; Tue, 19 Dec 2017 11:39:06 +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 vBJBd5dY075268; Tue, 19 Dec 2017 11:39:05 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBJBd5FU075266; Tue, 19 Dec 2017 11:39:05 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201712191139.vBJBd5FU075266@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Tue, 19 Dec 2017 11:39:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326975 - in stable/11/contrib/llvm/tools/clang: include/clang/Sema lib/Sema X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable/11/contrib/llvm/tools/clang: include/clang/Sema lib/Sema X-SVN-Commit-Revision: 326975 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 11:39:07 -0000 Author: dim Date: Tue Dec 19 11:39:05 2017 New Revision: 326975 URL: https://svnweb.freebsd.org/changeset/base/326975 Log: MFC r326776: Pull in r320396 from upstream clang trunk (by Malcolm Parsons): [Sema] Fix crash in unused-lambda-capture warning for VLAs Summary: Clang was crashing when diagnosing an unused-lambda-capture for a VLA because From.getVariable() is null for the capture of a VLA bound. Warning about the VLA bound capture is not helpful, so only warn for the VLA itself. Fixes: PR35555 Reviewers: aaron.ballman, dim, rsmith Reviewed By: aaron.ballman, dim Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D41016 This fixes a segfault when building recent audio/zynaddsubfx port versions. Reported by: hps Modified: stable/11/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp Directory Properties: stable/11/ (props changed) Modified: stable/11/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h ============================================================================== --- stable/11/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h Tue Dec 19 10:06:55 2017 (r326974) +++ stable/11/contrib/llvm/tools/clang/include/clang/Sema/ScopeInfo.h Tue Dec 19 11:39:05 2017 (r326975) @@ -560,6 +560,7 @@ class CapturingScopeInfo : public FunctionScopeInfo { void markUsed(bool IsODRUse) { (IsODRUse ? ODRUsed : NonODRUsed) = true; } VarDecl *getVariable() const { + assert(isVariableCapture()); return VarAndNestedAndThis.getPointer(); } Modified: stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp ============================================================================== --- stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp Tue Dec 19 10:06:55 2017 (r326974) +++ stable/11/contrib/llvm/tools/clang/lib/Sema/SemaLambda.cpp Tue Dec 19 11:39:05 2017 (r326975) @@ -1469,6 +1469,9 @@ void Sema::DiagnoseUnusedLambdaCapture(const LambdaSco if (CaptureHasSideEffects(From)) return; + if (From.isVLATypeCapture()) + return; + auto diag = Diag(From.getLocation(), diag::warn_unused_lambda_capture); if (From.isThisCapture()) diag << "'this'"; From owner-svn-src-stable-11@freebsd.org Tue Dec 19 11:44:25 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8F0ABEA22A2; Tue, 19 Dec 2017 11:44:25 +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 6979774607; Tue, 19 Dec 2017 11:44:25 +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 vBJBiOhA079359; Tue, 19 Dec 2017 11:44:24 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBJBiOnF079358; Tue, 19 Dec 2017 11:44:24 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201712191144.vBJBiOnF079358@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Tue, 19 Dec 2017 11:44:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326976 - in stable: 10/contrib/llvm/tools/clang/lib/Sema 11/contrib/llvm/tools/clang/lib/Sema 9/contrib/llvm/tools/clang/lib/Sema X-SVN-Group: stable-11 X-SVN-Commit-Author: dim X-SVN-Commit-Paths: in stable: 10/contrib/llvm/tools/clang/lib/Sema 11/contrib/llvm/tools/clang/lib/Sema 9/contrib/llvm/tools/clang/lib/Sema X-SVN-Commit-Revision: 326976 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 11:44:25 -0000 Author: dim Date: Tue Dec 19 11:44:24 2017 New Revision: 326976 URL: https://svnweb.freebsd.org/changeset/base/326976 Log: MFC r326880: Pull in r320755 from upstream clang trunk (by me): Don't trigger -Wuser-defined-literals for system headers Summary: In D41064, I proposed adding `#pragma clang diagnostic ignored "-Wuser-defined-literals"` to some of libc++'s headers, since these warnings are now triggered by clang's new `-std=gnu++14` default: $ cat test.cpp #include $ clang -std=c++14 -Wsystem-headers -Wall -Wextra -c test.cpp In file included from test.cpp:1: In file included from /usr/include/c++/v1/string:470: /usr/include/c++/v1/string_view:763:29: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string_view operator "" sv(const char *__str, size_t __len) ^ /usr/include/c++/v1/string_view:769:32: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string_view operator "" sv(const wchar_t *__str, size_t __len) ^ /usr/include/c++/v1/string_view:775:33: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string_view operator "" sv(const char16_t *__str, size_t __len) ^ /usr/include/c++/v1/string_view:781:33: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string_view operator "" sv(const char32_t *__str, size_t __len) ^ In file included from test.cpp:1: /usr/include/c++/v1/string:4012:24: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string operator "" s( const char *__str, size_t __len ) ^ /usr/include/c++/v1/string:4018:27: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string operator "" s( const wchar_t *__str, size_t __len ) ^ /usr/include/c++/v1/string:4024:28: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string operator "" s( const char16_t *__str, size_t __len ) ^ /usr/include/c++/v1/string:4030:28: warning: user-defined literal suffixes not starting with '_' are reserved [-Wuser-defined-literals] basic_string operator "" s( const char32_t *__str, size_t __len ) ^ 8 warnings generated. Both @aaron.ballman and @mclow.lists felt that adding this workaround to the libc++ headers was the wrong way, and it should be fixed in clang instead. Here is a proposal to do just that. I verified that this suppresses the warning, even when -Wsystem-headers is used, and that the warning is still emitted for a declaration outside of system headers. Reviewers: aaron.ballman, mclow.lists, rsmith Reviewed By: aaron.ballman Subscribers: mclow.lists, aaron.ballman, andrew, emaste, cfe-commits Differential Revision: https://reviews.llvm.org/D41080 This will allow to compile some of the libc++ headers in C++14 mode (which is the default for gcc 6 and higher, and will be the default for clang 6.0.0 and higher), with -Wsystem-headers and -Werror enabled. Reported by: andrew Modified: stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/10/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp stable/9/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp Directory Properties: stable/10/ (props changed) stable/9/ (props changed) stable/9/contrib/ (props changed) stable/9/contrib/llvm/ (props changed) stable/9/contrib/llvm/tools/clang/ (props changed) Modified: stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp ============================================================================== --- stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp Tue Dec 19 11:39:05 2017 (r326975) +++ stable/11/contrib/llvm/tools/clang/lib/Sema/SemaDeclCXX.cpp Tue Dec 19 11:44:24 2017 (r326976) @@ -12997,7 +12997,8 @@ bool Sema::CheckLiteralOperatorDeclaration(FunctionDec StringRef LiteralName = FnDecl->getDeclName().getCXXLiteralIdentifier()->getName(); - if (LiteralName[0] != '_') { + if (LiteralName[0] != '_' && + !getSourceManager().isInSystemHeader(FnDecl->getLocation())) { // C++11 [usrlit.suffix]p1: // Literal suffix identifiers that do not start with an underscore // are reserved for future standardization. From owner-svn-src-stable-11@freebsd.org Tue Dec 19 12:57:28 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2A4C2E80F07; Tue, 19 Dec 2017 12:57:28 +0000 (UTC) (envelope-from agapon@gmail.com) Received: from mail-lf0-f52.google.com (mail-lf0-f52.google.com [209.85.215.52]) (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 AC93E7750D; Tue, 19 Dec 2017 12:57:27 +0000 (UTC) (envelope-from agapon@gmail.com) Received: by mail-lf0-f52.google.com with SMTP id w196so2137910lff.5; Tue, 19 Dec 2017 04:57:26 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Ralsuzk5UGk2RODLKIm8A6i/5IPbi9d/530oXIVKW+M=; b=dD2+Xo6EvXXbUSAG3oNJZ/vxxDvjh+kVPKaNxSE/v5w5UYm/3f92Rtd78/QOdQIFwL eS64+mp1f0GYEmey3iNYkMSj6vd03U+c317ow79fAePsQS1cTQON2ZOxmj8wH/JGnZim Kd4NWRw+iNwitOUVui3JkgkM4NBf/W2ySnafSWIP7+S5K8bdMoC2GSMzTk+xhbE3JmVR o73nA5m6x1/c5IqOqeQxvGJib8xRaH5CRomhnAL1NGLdp6Zqoc0OfQL/gBppp7I6p09s OnYbKLNvTilfgfLx6rNh5pkPblfJkKRpmh6ESsc2cfaohFpqJGqCJrUVI1DVAbv3S3vG EZew== X-Gm-Message-State: AKGB3mJi8AI5bUY2l/E1yHwB00z45+X3MREanVrdA+GXmsywPPhPPVdL Lx7aPjqR4/591Y+fSNDuS3W2EqmqBm0= X-Google-Smtp-Source: ACJfBouQ0ckxb0szSTRbnZlp/dt6sdTTBru6kpPF6y3EAMtq9c93HqYEFX4r/Cptds/I6vVovncGDA== X-Received: by 10.46.4.13 with SMTP id 13mr2137917lje.82.1513687860019; Tue, 19 Dec 2017 04:51:00 -0800 (PST) Received: from [192.168.0.88] (east.meadow.volia.net. [93.72.151.96]) by smtp.googlemail.com with ESMTPSA id p5sm3107016ljc.7.2017.12.19.04.50.58 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 Dec 2017 04:50:58 -0800 (PST) Subject: Re: svn commit: r326619 - stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs To: Peter Jeremy Cc: Baptiste Daroussin , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org References: <201712061001.vB6A12Ot032201@repo.freebsd.org> <20171213185214.GA12026@server.rulingia.com> From: Andriy Gapon Message-ID: Date: Tue, 19 Dec 2017 14:50:57 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <20171213185214.GA12026@server.rulingia.com> Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 12:57:28 -0000 On 13/12/2017 20:52, Peter Jeremy wrote: > On 2017-Dec-06 10:01:02 +0000, Baptiste Daroussin wrote: >> Author: bapt >> Date: Wed Dec 6 10:01:02 2017 >> New Revision: 326619 >> URL: https://svnweb.freebsd.org/changeset/base/326619 >> >> Log: >> MFC r325851: >> >> remove the poor emulation of the IllumOS needfree global variable to prevent >> the ARC reclaim thread running longer than needed. >> > > This change appears to break the backpressure mechanism that forces > ARC to release wired memory. Running FreeBSD/amd64 r326743, I found > that my system was thrashing badly with almost all memory (~31GB out > of 32GB) wired (including 19GB ARC, 7GB VBox guests). Running a tool > that just allocates and dirties a large amount of memory had no effect > on the ARC size. Reverting this change only restores normal behaviour > where ARC will shrink under pressure. > > My ZFS boot tunables are: > vfs.zfs.arc_max="24G" > vfs.zfs.arc_meta_limit="12G" > Peter, could you please try to monitor 'arc-needfree' DTrace probe during periods when you are trying to put a pressure on the memory? The probe's argument (signed) tells the ARC's idea of the memory availability / shortage. bapt wrote: >> @@ -6310,9 +6294,7 @@ arc_lowmem(void *arg __unused, int howto __unused) >> { >> >> mutex_enter(&arc_reclaim_lock); >> - /* XXX: Memory deficit should be passed as argument. */ >> - needfree = btoc(arc_c >> arc_shrink_shift); >> - DTRACE_PROBE(arc__needfree); >> + DTRACE_PROBE1(arc__needfree, int64_t, ((int64_t)freemem - zfs_arc_free_target) * PAGESIZE); >> cv_signal(&arc_reclaim_thread_cv); >> >> /* -- Andriy Gapon From owner-svn-src-stable-11@freebsd.org Tue Dec 19 14:15:39 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6BF1E858E9; Tue, 19 Dec 2017 14:15:39 +0000 (UTC) (envelope-from bapt@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 A34677A373; Tue, 19 Dec 2017 14:15:39 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: by freefall.freebsd.org (Postfix, from userid 1235) id D694841E3; Tue, 19 Dec 2017 14:15:38 +0000 (UTC) Date: Tue, 19 Dec 2017 15:15:38 +0100 From: Baptiste Daroussin To: Peter Jeremy Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: Re: svn commit: r326619 - stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <20171219141538.f7o2ujntckaguhq2@ivaldir.net> References: <201712061001.vB6A12Ot032201@repo.freebsd.org> <20171213185214.GA12026@server.rulingia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="vcfjnrpoxjsx5ujp" Content-Disposition: inline In-Reply-To: <20171213185214.GA12026@server.rulingia.com> User-Agent: NeoMutt/20171208 X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 14:15:39 -0000 --vcfjnrpoxjsx5ujp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Dec 14, 2017 at 05:52:15AM +1100, Peter Jeremy wrote: > On 2017-Dec-06 10:01:02 +0000, Baptiste Daroussin wrot= e: > >Author: bapt > >Date: Wed Dec 6 10:01:02 2017 > >New Revision: 326619 > >URL: https://svnweb.freebsd.org/changeset/base/326619 > > > >Log: > > MFC r325851: > > =20 > > remove the poor emulation of the IllumOS needfree global variable to p= revent > > the ARC reclaim thread running longer than needed. > > =20 >=20 > This change appears to break the backpressure mechanism that forces > ARC to release wired memory. Running FreeBSD/amd64 r326743, I found > that my system was thrashing badly with almost all memory (~31GB out > of 32GB) wired (including 19GB ARC, 7GB VBox guests). Running a tool > that just allocates and dirties a large amount of memory had no effect > on the ARC size. Reverting this change only restores normal behaviour > where ARC will shrink under pressure. >=20 > My ZFS boot tunables are: > vfs.zfs.arc_max=3D"24G" > vfs.zfs.arc_meta_limit=3D"12G" >=20 You are running an issue on head? or on stable/11? Given you are reporting = the issue on the MFC commit Best regards, Bapt --vcfjnrpoxjsx5ujp Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEgOTj3suS2urGXVU3Y4mL3PG3PloFAlo5HwcACgkQY4mL3PG3 PlrF0w//fMh0ivtsF5qGzELvIwk0pPpXb2NJ/NyXHcaBUrPfx8h64KP/67ylXJHo Ecpc1hq+YlbE4cO7xnkMIJzVEoIbSTXz/CE795dWMEseUhrNYeOA+APjcL1NvmrK 9r2T0yM/BC683clCSqtqvFAcBnanIdoDBV+rtAU1AJ2ldjZBFiEZ29opgqj0Vnw1 mHRQWsPmEhJE9maKYA5eU/BZRvhYGq9CDGl4I6D6UFA+/wuC/viAcrEV+55DKoYP 5RLUgDMcx9jY0uK8gLbDUDV+3yMgfS4UKSv2S2lyyf7bhHqQvtsCKBSAVRMdlGnZ dzP9CxHAx9l2FeJy1j1otzyMWQhbbnOMj3rTMlzdi8D9Kl9yZy+fo2r3naRDxU8e EAYxtRDMYHBe5r6VhbsxpBAhArWVXGs7MEsTdiJusnY8/mMo1VYzEz8AazEVe5wc AavG+VSz1TwxMTqxITser9AFcnnlJRCEN8oU39Eil6izCKHz3ebErkqcx8nMhTW4 kR8a027nVuM9Msihf6zxjfNMMPlOOlNzJF1JAiBd5otl+RKbBc90VBUbjKN5B+UK YZQSuPTGQNvpABHWMxfq0pmPdbydwVyDZEJLWcP2hJHNo8AJAV7tkebTG8MaPeEk +xKkzfnUYHnzFUbJ/2gGDEoJfzXUEKsP1lTd8VrEcTKXzf2I+3Y= =OpGO -----END PGP SIGNATURE----- --vcfjnrpoxjsx5ujp-- From owner-svn-src-stable-11@freebsd.org Tue Dec 19 16:16:35 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 68481E8D207; Tue, 19 Dec 2017 16:16:35 +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 2ED847F4C1; Tue, 19 Dec 2017 16:16:35 +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 vBJGGY7C093398; Tue, 19 Dec 2017 16:16:34 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBJGGYP7093397; Tue, 19 Dec 2017 16:16:34 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712191616.vBJGGYP7093397@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Tue, 19 Dec 2017 16:16:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326979 - stable/11/sys/geom/mirror X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/geom/mirror X-SVN-Commit-Revision: 326979 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 16:16:35 -0000 Author: markj Date: Tue Dec 19 16:16:34 2017 New Revision: 326979 URL: https://svnweb.freebsd.org/changeset/base/326979 Log: MFC r326796-r326798: Fix sc_writes tracking, and address a lost wakeup. Modified: stable/11/sys/geom/mirror/g_mirror.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/geom/mirror/g_mirror.c ============================================================================== --- stable/11/sys/geom/mirror/g_mirror.c Tue Dec 19 15:50:46 2017 (r326978) +++ stable/11/sys/geom/mirror/g_mirror.c Tue Dec 19 16:16:34 2017 (r326979) @@ -213,7 +213,7 @@ g_mirror_event_send(void *arg, int state, int flags) } static struct g_mirror_event * -g_mirror_event_get(struct g_mirror_softc *sc) +g_mirror_event_first(struct g_mirror_softc *sc) { struct g_mirror_event *ep; @@ -548,7 +548,7 @@ g_mirror_destroy_device(struct g_mirror_softc *sc) g_mirror_update_metadata(disk); g_mirror_destroy_disk(disk); } - while ((ep = g_mirror_event_get(sc)) != NULL) { + while ((ep = g_mirror_event_first(sc)) != NULL) { g_mirror_event_remove(sc, ep); if ((ep->e_flags & G_MIRROR_EVENT_DONTWAIT) != 0) g_mirror_event_free(ep); @@ -930,7 +930,7 @@ g_mirror_regular_request(struct bio *bp) pbp = bp->bio_parent; sc = pbp->bio_to->private; bp->bio_from->index--; - if (bp->bio_cmd == BIO_WRITE) + if (bp->bio_cmd == BIO_WRITE || bp->bio_cmd == BIO_DELETE) sc->sc_writes--; disk = bp->bio_from->private; if (disk == NULL) { @@ -1869,7 +1869,7 @@ g_mirror_worker(void *arg) * First take a look at events. * This is important to handle events before any I/O requests. */ - ep = g_mirror_event_get(sc); + ep = g_mirror_event_first(sc); if (ep != NULL) { g_mirror_event_remove(sc, ep); if ((ep->e_flags & G_MIRROR_EVENT_DEVICE) != 0) { @@ -1937,16 +1937,9 @@ g_mirror_worker(void *arg) continue; } } + if (g_mirror_event_first(sc) != NULL) + continue; sx_xunlock(&sc->sc_lock); - /* - * XXX: We can miss an event here, because an event - * can be added without sx-device-lock and without - * mtx-queue-lock. Maybe I should just stop using - * dedicated mutex for events synchronization and - * stick with the queue lock? - * The event will hang here until next I/O request - * or next event is received. - */ MSLEEP(sc, &sc->sc_queue_mtx, PRIBIO | PDROP, "m:w1", timeout * hz); sx_xlock(&sc->sc_lock); From owner-svn-src-stable-11@freebsd.org Tue Dec 19 16:20:15 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2CF42E8D658; Tue, 19 Dec 2017 16:20:15 +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 E7E937F8C2; Tue, 19 Dec 2017 16:20:14 +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 vBJGKDm4093713; Tue, 19 Dec 2017 16:20:13 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBJGKDWT093712; Tue, 19 Dec 2017 16:20:13 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712191620.vBJGKDWT093712@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Tue, 19 Dec 2017 16:20:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r326980 - stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace X-SVN-Commit-Revision: 326980 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Dec 2017 16:20:15 -0000 Author: markj Date: Tue Dec 19 16:20:13 2017 New Revision: 326980 URL: https://svnweb.freebsd.org/changeset/base/326980 Log: MFC r326813: MFV r326785: 8880 improve DTrace error checking Modified: stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c ============================================================================== --- stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c Tue Dec 19 16:16:34 2017 (r326979) +++ stable/11/sys/cddl/contrib/opensolaris/uts/common/dtrace/dtrace.c Tue Dec 19 16:20:13 2017 (r326980) @@ -13838,6 +13838,7 @@ static int dtrace_dof_relocate(dof_hdr_t *dof, dof_sec_t *sec, uint64_t ubase) { uintptr_t daddr = (uintptr_t)dof; + uintptr_t ts_end; dof_relohdr_t *dofr = (dof_relohdr_t *)(uintptr_t)(daddr + sec->dofs_offset); dof_sec_t *ss, *rs, *ts; @@ -13853,6 +13854,7 @@ dtrace_dof_relocate(dof_hdr_t *dof, dof_sec_t *sec, ui ss = dtrace_dof_sect(dof, DOF_SECT_STRTAB, dofr->dofr_strtab); rs = dtrace_dof_sect(dof, DOF_SECT_RELTAB, dofr->dofr_relsec); ts = dtrace_dof_sect(dof, DOF_SECT_NONE, dofr->dofr_tgtsec); + ts_end = (uintptr_t)ts + sizeof (dof_sec_t); if (ss == NULL || rs == NULL || ts == NULL) return (-1); /* dtrace_dof_error() has been called already */ @@ -13875,6 +13877,11 @@ dtrace_dof_relocate(dof_hdr_t *dof, dof_sec_t *sec, ui case DOF_RELO_SETX: if (r->dofr_offset >= ts->dofs_size || r->dofr_offset + sizeof (uint64_t) > ts->dofs_size) { + dtrace_dof_error(dof, "bad relocation offset"); + return (-1); + } + + if (taddr >= (uintptr_t)ts && taddr < ts_end) { dtrace_dof_error(dof, "bad relocation offset"); return (-1); } From owner-svn-src-stable-11@freebsd.org Wed Dec 20 00:30:32 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6F024E85DDD; Wed, 20 Dec 2017 00:30:32 +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 3AEF773058; Wed, 20 Dec 2017 00:30:32 +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 vBK0UV3L009393; Wed, 20 Dec 2017 00:30:31 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBK0UVQp009391; Wed, 20 Dec 2017 00:30:31 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201712200030.vBK0UVQp009391@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 20 Dec 2017 00:30:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327010 - in stable/11: lib usr.bin X-SVN-Group: stable-11 X-SVN-Commit-Author: emaste X-SVN-Commit-Paths: in stable/11: lib usr.bin X-SVN-Commit-Revision: 327010 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 00:30:32 -0000 Author: emaste Date: Wed Dec 20 00:30:31 2017 New Revision: 327010 URL: https://svnweb.freebsd.org/changeset/base/327010 Log: MFC r326030: Install strings unconditionally Previously it was enabled by WITH_/WITHOUT_TOOLCHAIN, but it is commonly expected to be available and may have non-toolchain consumers. As it is now taken from the BSD-licensed ELF Tool Chain project, just install it unconditionally. PR: 213665, 223725 Sponsored by: The FreeBSD Foundation Modified: stable/11/lib/Makefile stable/11/usr.bin/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/Makefile ============================================================================== --- stable/11/lib/Makefile Tue Dec 19 23:54:44 2017 (r327009) +++ stable/11/lib/Makefile Wed Dec 20 00:30:31 2017 (r327010) @@ -49,7 +49,7 @@ SUBDIR= ${SUBDIR_BOOTSTRAP} \ libdwarf \ libedit \ ${_libefivar} \ - ${_libelftc} \ + libelftc \ libevent \ libexecinfo \ libexpat \ @@ -188,7 +188,6 @@ _cuse= libcuse .endif .if ${MK_TOOLCHAIN} != "no" -_libelftc= libelftc _libpe= libpe .endif Modified: stable/11/usr.bin/Makefile ============================================================================== --- stable/11/usr.bin/Makefile Tue Dec 19 23:54:44 2017 (r327009) +++ stable/11/usr.bin/Makefile Wed Dec 20 00:30:31 2017 (r327010) @@ -148,6 +148,7 @@ SUBDIR= alias \ split \ stat \ stdbuf \ + strings \ su \ systat \ tabs \ @@ -285,7 +286,6 @@ SUBDIR.${MK_TOOLCHAIN}+= readelf SUBDIR.${MK_TOOLCHAIN}+= rpcgen SUBDIR.${MK_TOOLCHAIN}+= unifdef SUBDIR.${MK_TOOLCHAIN}+= size -SUBDIR.${MK_TOOLCHAIN}+= strings .if ${MACHINE_ARCH} != "aarch64" # ARM64TODO xlint does not build SUBDIR.${MK_TOOLCHAIN}+= xlint .endif From owner-svn-src-stable-11@freebsd.org Wed Dec 20 07:16:42 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6BE9E9B158; Wed, 20 Dec 2017 07:16:42 +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 9355710F9; Wed, 20 Dec 2017 07:16:42 +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 vBK7GfHg079131; Wed, 20 Dec 2017 07:16:41 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBK7Gf3C079130; Wed, 20 Dec 2017 07:16:41 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712200716.vBK7Gf3C079130@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Wed, 20 Dec 2017 07:16:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327018 - stable/11/libexec/ftpd X-SVN-Group: stable-11 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/11/libexec/ftpd X-SVN-Commit-Revision: 327018 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 07:16:42 -0000 Author: delphij Date: Wed Dec 20 07:16:41 2017 New Revision: 327018 URL: https://svnweb.freebsd.org/changeset/base/327018 Log: MFC r326562: Use strlcpy(). Modified: stable/11/libexec/ftpd/ftpd.c Directory Properties: stable/11/ (props changed) Modified: stable/11/libexec/ftpd/ftpd.c ============================================================================== --- stable/11/libexec/ftpd/ftpd.c Wed Dec 20 06:08:16 2017 (r327017) +++ stable/11/libexec/ftpd/ftpd.c Wed Dec 20 07:16:41 2017 (r327018) @@ -1075,7 +1075,7 @@ user(char *name) } } if (logging) - strncpy(curname, name, sizeof(curname)-1); + strlcpy(curname, name, sizeof(curname)); pwok = 0; #ifdef USE_PAM From owner-svn-src-stable-11@freebsd.org Wed Dec 20 07:43:34 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 374E8E9C9F7; Wed, 20 Dec 2017 07:43:34 +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 03C01214D; Wed, 20 Dec 2017 07:43:33 +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 vBK7hXPm091435; Wed, 20 Dec 2017 07:43:33 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBK7hXMZ091434; Wed, 20 Dec 2017 07:43:33 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712200743.vBK7hXMZ091434@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Wed, 20 Dec 2017 07:43:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327020 - stable/11/usr.bin/gzip X-SVN-Group: stable-11 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/11/usr.bin/gzip X-SVN-Commit-Revision: 327020 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 07:43:34 -0000 Author: delphij Date: Wed Dec 20 07:43:32 2017 New Revision: 327020 URL: https://svnweb.freebsd.org/changeset/base/327020 Log: MFC r326560: Create links for xzdiff. Modified: stable/11/usr.bin/gzip/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.bin/gzip/Makefile ============================================================================== --- stable/11/usr.bin/gzip/Makefile Wed Dec 20 07:18:07 2017 (r327019) +++ stable/11/usr.bin/gzip/Makefile Wed Dec 20 07:43:32 2017 (r327020) @@ -20,11 +20,13 @@ MLINKS+= gzip.1 gunzip.1 \ gzip.1 gzcat.1 \ gzip.1 zcat.1 \ zdiff.1 zcmp.1 \ + zdiff.1 xzdiff.1 \ zmore.1 zless.1 LINKS+= ${BINDIR}/gzip ${BINDIR}/gunzip \ ${BINDIR}/gzip ${BINDIR}/gzcat \ ${BINDIR}/gzip ${BINDIR}/zcat \ + ${BINDIR}/zdiff ${BINDIR}/xzdiff \ ${BINDIR}/zdiff ${BINDIR}/zcmp .if ${MK_TESTS} != "no" From owner-svn-src-stable-11@freebsd.org Wed Dec 20 07:55:48 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 91BB2E9D3F6; Wed, 20 Dec 2017 07:55:48 +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 5BC9B27D8; Wed, 20 Dec 2017 07:55:48 +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 vBK7tl9r095719; Wed, 20 Dec 2017 07:55:47 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBK7tlpg095718; Wed, 20 Dec 2017 07:55:47 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201712200755.vBK7tlpg095718@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Wed, 20 Dec 2017 07:55:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327021 - stable/11/usr.bin/su X-SVN-Group: stable-11 X-SVN-Commit-Author: delphij X-SVN-Commit-Paths: stable/11/usr.bin/su X-SVN-Commit-Revision: 327021 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 07:55:48 -0000 Author: delphij Date: Wed Dec 20 07:55:47 2017 New Revision: 327021 URL: https://svnweb.freebsd.org/changeset/base/327021 Log: MFC r326561: Use strlcpy(). Modified: stable/11/usr.bin/su/su.c Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.bin/su/su.c ============================================================================== --- stable/11/usr.bin/su/su.c Wed Dec 20 07:43:32 2017 (r327020) +++ stable/11/usr.bin/su/su.c Wed Dec 20 07:55:47 2017 (r327021) @@ -275,9 +275,9 @@ main(int argc, char *argv[]) if (asme) { if (pwd->pw_shell != NULL && *pwd->pw_shell != '\0') { /* must copy - pwd memory is recycled */ - shell = strncpy(shellbuf, pwd->pw_shell, + strlcpy(shellbuf, pwd->pw_shell, sizeof(shellbuf)); - shellbuf[sizeof(shellbuf) - 1] = '\0'; + shell = shellbuf; } else { shell = _PATH_BSHELL; From owner-svn-src-stable-11@freebsd.org Wed Dec 20 10:06:04 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9332AEA40B2; Wed, 20 Dec 2017 10:06:04 +0000 (UTC) (envelope-from des@des.no) Received: from smtp.des.no (smtp.des.no [194.63.250.102]) by mx1.freebsd.org (Postfix) with ESMTP id 5A33165EB3; Wed, 20 Dec 2017 10:06:04 +0000 (UTC) (envelope-from des@des.no) Received: from desk.des.no (smtp.des.no [194.63.250.102]) by smtp.des.no (Postfix) with ESMTP id 562FC104BD; Wed, 20 Dec 2017 10:06:03 +0000 (UTC) Received: by desk.des.no (Postfix, from userid 1001) id EDA8E5C08D; Wed, 20 Dec 2017 10:04:46 +0000 (UTC) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Ed Maste Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: Re: svn commit: r327010 - in stable/11: lib usr.bin References: <201712200030.vBK0UVQp009391@repo.freebsd.org> Date: Wed, 20 Dec 2017 11:04:46 +0100 In-Reply-To: <201712200030.vBK0UVQp009391@repo.freebsd.org> (Ed Maste's message of "Wed, 20 Dec 2017 00:30:31 +0000 (UTC)") Message-ID: <864lolbtq9.fsf@desk.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 10:06:04 -0000 Ed Maste writes: > Log: > MFC r326030: Install strings unconditionally >=20=20=20 > Previously it was enabled by WITH_/WITHOUT_TOOLCHAIN, but it is commonly > expected to be available and may have non-toolchain consumers. As it > is now taken from the BSD-licensed ELF Tool Chain project, just install > it unconditionally. >=20=20=20 > PR: 213665, 223725 > Sponsored by: The FreeBSD Foundation freebsd-version doesn't use strings(1) and hasn't for a year: ------------------------------------------------------------------------ r308297 | des | 2016-11-04 18:02:42 +0100 (Fri, 04 Nov 2016) | 6 lines Changed paths: M /head/bin/freebsd-version/freebsd-version.sh.in Use what(1) instead of strings(1). It's simpler and always available. PR: 213665 Submitted by: Pawel Worach MFC after: 1 week ------------------------------------------------------------------------ r309828 | des | 2016-12-10 21:20:33 +0100 (Sat, 10 Dec 2016) | 5 lines Changed paths: M /stable/11 M /stable/11/bin/freebsd-version/freebsd-version.sh.in MFH (r308297): use what(1) instead of strings(1). PR: 213665 Submitted by: Pawel Worach ------------------------------------------------------------------------ DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-svn-src-stable-11@freebsd.org Wed Dec 20 18:42:45 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8AB9BE9C105; Wed, 20 Dec 2017 18:42:45 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io0-x233.google.com (mail-io0-x233.google.com [IPv6:2607:f8b0:4001:c06::233]) (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 51E327B66D; Wed, 20 Dec 2017 18:42:45 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io0-x233.google.com with SMTP id x129so18367451iod.13; Wed, 20 Dec 2017 10:42:45 -0800 (PST) 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:content-transfer-encoding; bh=/Xk0VB+M+lDXc5V9ClAU7aPvlpLLyslXFs7O+UiAVhY=; b=TR17LKXC4TbZuKxJqUe3VPi8AbIMHEAGzCorrS/s7aw/4BmIyNZOKwpby8txvlEOM5 o4x7OYl5p3nzQEbe+5i10IxQv05Z02Nux4D/qFBuEZEHcUUgVvAG8Y0yOJly2qe3HKwQ ZnBgthm9u3+T73qCVdKHzqSLbAg/2x+58wQlb0htpuwEPNiNzrKKSPCt4wAQZXd4R4Jk HNGhrk9ZGv6PheftUsFrP2B+Af0ouQDwio+I3L5vTxkwRt4Q532HCdwfy9XUpDfwQirv stU4DRbil8xG3ZQiVcn9PrgXlKtv2skr/hDY2U3MvdmvhKO+zzKJ8LmHaDD6iOvDZa7R zWxQ== 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:content-transfer-encoding; bh=/Xk0VB+M+lDXc5V9ClAU7aPvlpLLyslXFs7O+UiAVhY=; b=Xnt492xRzv5ZRPCaw28caIh+KlnzMoRnUViFhT198Sc5ptqv8Vy4WJEECjsSVgxXOn r3frFyoykNyChGtNMoUOlvC+21YYcndLVOioiBDP2S+rmVDArhM76C90AJcefECl3DD6 ObgCdTxQSkijW9ZwCENY1BvKiRVdcxisDG0b/ik6hwW1kQxbtmWaHNQAZhhZaxF/v4hc XvslOqhZx8m8544d7h9NKLyRqOgclz94itXsMuyU9mfWYxGOF5JxxgPcHdOaYfSouiEC xsVsOtAoA4CMzTAFA4IIt423JsXi7PnKUyCOJLvtLfuA0LsUHr47d8mUYj9oPgkqF0fu lRRQ== X-Gm-Message-State: AKGB3mKeCRpFYTSAzW8Pw2yPN+OLm9uzK6HHeo0Nn85H9FKwU8pPXPq3 mBi4f+No34C83uhYhPV9tO8ucZ/mDyxs/k0Kq68mlQ== X-Google-Smtp-Source: ACJfBouBOUUYw1ENaXK8CLZJig0tpGU3sASUruYmjRXkXRv2BgIsj+obufzPzxlH2OYPhlZvIQk8LtyLeH66v9gty5M= X-Received: by 10.107.83.8 with SMTP id h8mr9465441iob.63.1513795364473; Wed, 20 Dec 2017 10:42:44 -0800 (PST) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.131.163 with HTTP; Wed, 20 Dec 2017 10:42:23 -0800 (PST) In-Reply-To: <864lolbtq9.fsf@desk.des.no> References: <201712200030.vBK0UVQp009391@repo.freebsd.org> <864lolbtq9.fsf@desk.des.no> From: Ed Maste Date: Wed, 20 Dec 2017 13:42:23 -0500 X-Google-Sender-Auth: vJIHjgZ5YxjvXZAcfswjhjY6O8Q Message-ID: Subject: Re: svn commit: r327010 - in stable/11: lib usr.bin To: =?UTF-8?Q?Dag=2DErling_Sm=C3=B8rgrav?= Cc: src-committers , svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 18:42:45 -0000 On 20 December 2017 at 05:04, Dag-Erling Sm=C3=B8rgrav wrote: > > freebsd-version doesn't use strings(1) and hasn't for a year: Right, this was just another example of a case where strings was expected to be available. I committed and MFC'd this not to fix freebsd-version, but to satisfy the expectation that it's included. From owner-svn-src-stable-11@freebsd.org Wed Dec 20 18:55:24 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D0E4E9CC3D; Wed, 20 Dec 2017 18:55:24 +0000 (UTC) (envelope-from peter@rulingia.com) Received: from vps.rulingia.com (vps.rulingia.com [103.243.244.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.rulingia.com", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id ECBCF7BCB7; Wed, 20 Dec 2017 18:55:23 +0000 (UTC) (envelope-from peter@rulingia.com) Received: from server.rulingia.com (ppp59-167-167-3.static.internode.on.net [59.167.167.3]) by vps.rulingia.com (8.15.2/8.15.2) with ESMTPS id vBKIt86j093691 (version=TLSv1.2 cipher=DHE-RSA-CHACHA20-POLY1305 bits=256 verify=OK); Thu, 21 Dec 2017 05:55:14 +1100 (AEDT) (envelope-from peter@rulingia.com) X-Bogosity: Ham, spamicity=0.000000 Received: from server.rulingia.com (localhost.rulingia.com [127.0.0.1]) by server.rulingia.com (8.15.2/8.15.2) with ESMTPS id vBKIt25O013312 (version=TLSv1.2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256 verify=NO); Thu, 21 Dec 2017 05:55:02 +1100 (AEDT) (envelope-from peter@server.rulingia.com) Received: (from peter@localhost) by server.rulingia.com (8.15.2/8.15.2/Submit) id vBKIt2n5013311; Thu, 21 Dec 2017 05:55:02 +1100 (AEDT) (envelope-from peter) Date: Thu, 21 Dec 2017 05:55:02 +1100 From: Peter Jeremy To: Andriy Gapon Cc: Baptiste Daroussin , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: Re: svn commit: r326619 - stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <20171220185502.GA5042@server.rulingia.com> References: <201712061001.vB6A12Ot032201@repo.freebsd.org> <20171213185214.GA12026@server.rulingia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ikeVEW9yuYc//A+q" Content-Disposition: inline In-Reply-To: X-PGP-Key: http://www.rulingia.com/keys/peter.pgp User-Agent: Mutt/1.9.1 (2017-09-22) X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 18:55:24 -0000 --ikeVEW9yuYc//A+q Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2017-Dec-19 14:50:57 +0200, Andriy Gapon wrote: >On 13/12/2017 20:52, Peter Jeremy wrote: >> This change appears to break the backpressure mechanism that forces >> ARC to release wired memory. Running FreeBSD/amd64 r326743, I found =2E.. >could you please try to monitor 'arc-needfree' DTrace probe during periods= when >you are trying to put a pressure on the memory? >The probe's argument (signed) tells the ARC's idea of the memory availabil= ity / >shortage. I will see if I can reproduce the issue in a VBox to remove the need to revert my reversion. Give me a couple of days. --=20 Peter Jeremy --ikeVEW9yuYc//A+q Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJaOrIGXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRFRUIyOTg2QzMwNjcxRTc0RTY1QzIyN0Ux NkE1OTdBMEU0QTIwQjM0AAoJEBall6Dkogs05a0P/j1nZBNy8hkIlIxNi1DMhQYQ Y4sxX1dMHEi7gdjsO9Ex8qMic9dmeYISmlR7Rqu5G5nzntUWS12CID0AVq5OpvL9 u6SZT1h/HLt/T8E17801t/CReuJ5IbdyGkI9BrTJDNxdl2pQ4mmw0tmpiQ7CsStN YNfTPsNgGkqd8YaHJE4u6fXmWEtomFz7GNM1nYO7MtIp4Dml/f84esIewoJ53qjx l8deMUOU3Ilz9t/I1pxP7q5dwBalbU3bkhVeyo/9bSBrWCEtUrZQjSLrAnSnqtXj A8hozEUx7NhB1bRBIuhR/69B9WngIrth76oU05mOXw4uUMZv1CdU6Gw+k/DdJPht 994zOmZEJCz3JIw6BUaq6v+ceE7vBuq8upTlAMkaXByAqw4l/roxjXUDXRndXRjJ wHW4cXlkl6+cUcVHfQNm7hCqGmgLZVBSen67W0oKTzbKYTul5vICJErg5/4gKHmW feiNeGfZXdwxNmZG/UifM8HerX0M7/gTmUQejYPXGVKCATir0HcT6qEtrYukrxsU /7snCdAFTXr6lR1QMgG+BQfkYnRvyCeLFUBmpEr3yrL1FlgEl3YiIIfchDnEFUzc yfDRKIPlN/LRO9oHXksjtYd3hJJ2VqYV+szBj+wNa03/zYinbhP3lC9jnO6TZk+Z srFZuhjirS0rRnM7u0FM =a9aN -----END PGP SIGNATURE----- --ikeVEW9yuYc//A+q-- From owner-svn-src-stable-11@freebsd.org Wed Dec 20 18:56:10 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 96BA9E9CD57; Wed, 20 Dec 2017 18:56:10 +0000 (UTC) (envelope-from peter@rulingia.com) Received: from vps.rulingia.com (vps.rulingia.com [103.243.244.15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mail.rulingia.com", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2BD857BE04; Wed, 20 Dec 2017 18:56:09 +0000 (UTC) (envelope-from peter@rulingia.com) Received: from server.rulingia.com (ppp59-167-167-3.static.internode.on.net [59.167.167.3]) by vps.rulingia.com (8.15.2/8.15.2) with ESMTPS id vBKIu2Ie093702 (version=TLSv1.2 cipher=DHE-RSA-CHACHA20-POLY1305 bits=256 verify=OK); Thu, 21 Dec 2017 05:56:07 +1100 (AEDT) (envelope-from peter@rulingia.com) X-Bogosity: Ham, spamicity=0.000000 Received: from server.rulingia.com (localhost.rulingia.com [127.0.0.1]) by server.rulingia.com (8.15.2/8.15.2) with ESMTPS id vBKItuOC013333 (version=TLSv1.2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256 verify=NO); Thu, 21 Dec 2017 05:55:56 +1100 (AEDT) (envelope-from peter@server.rulingia.com) Received: (from peter@localhost) by server.rulingia.com (8.15.2/8.15.2/Submit) id vBKItuCV013332; Thu, 21 Dec 2017 05:55:56 +1100 (AEDT) (envelope-from peter) Date: Thu, 21 Dec 2017 05:55:56 +1100 From: Peter Jeremy To: Baptiste Daroussin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: Re: svn commit: r326619 - stable/11/sys/cddl/contrib/opensolaris/uts/common/fs/zfs Message-ID: <20171220185556.GB5042@server.rulingia.com> References: <201712061001.vB6A12Ot032201@repo.freebsd.org> <20171213185214.GA12026@server.rulingia.com> <20171219141538.f7o2ujntckaguhq2@ivaldir.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="3lcZGd9BuhuYXNfi" Content-Disposition: inline In-Reply-To: <20171219141538.f7o2ujntckaguhq2@ivaldir.net> X-PGP-Key: http://www.rulingia.com/keys/peter.pgp User-Agent: Mutt/1.9.1 (2017-09-22) X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Dec 2017 18:56:10 -0000 --3lcZGd9BuhuYXNfi Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2017-Dec-19 15:15:38 +0100, Baptiste Daroussin wrote: >On Thu, Dec 14, 2017 at 05:52:15AM +1100, Peter Jeremy wrote: >> On 2017-Dec-06 10:01:02 +0000, Baptiste Daroussin wro= te: >> >Author: bapt >> >Date: Wed Dec 6 10:01:02 2017 >> >New Revision: 326619 >> >URL: https://svnweb.freebsd.org/changeset/base/326619 >> > >> >Log: >> > MFC r325851: >> > =20 >> > remove the poor emulation of the IllumOS needfree global variable to = prevent >> > the ARC reclaim thread running longer than needed. >> > =20 >>=20 >> This change appears to break the backpressure mechanism that forces >> ARC to release wired memory. Running FreeBSD/amd64 r326743, I found >> that my system was thrashing badly with almost all memory (~31GB out >> of 32GB) wired (including 19GB ARC, 7GB VBox guests). Running a tool >> that just allocates and dirties a large amount of memory had no effect >> on the ARC size. Reverting this change only restores normal behaviour >> where ARC will shrink under pressure. >>=20 >> My ZFS boot tunables are: >> vfs.zfs.arc_max=3D"24G" >> vfs.zfs.arc_meta_limit=3D"12G" >>=20 > >You are running an issue on head? or on stable/11? Given you are reporting= the >issue on the MFC commit I'm running into the problem on stable/11. Sorry for not making that clear. --=20 Peter Jeremy --3lcZGd9BuhuYXNfi Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJaOrI8XxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRFRUIyOTg2QzMwNjcxRTc0RTY1QzIyN0Ux NkE1OTdBMEU0QTIwQjM0AAoJEBall6Dkogs0SBgP/0QeT0gCgBGguJyeDjFsMkIz eMYBxLynUkDYMQPLwzdHIOAsHOEYLdz3ghq3SeXZg/QFv11fFNsiKUvS/GAx6Xye YrL59imyOucjNMYqFZ6GEKlExBGp7Cnshis7LMNc6DdvKeDxiabHckrEYwEybaNy a38IPqmqc2s7gbtN+p/H6OsqVlVnOhd0oENPsFwiso8pHMaRlD89cqyHSC7+k5F3 Bzr1/b1Aao/WmlHrNLBP8Z52jG5YJ0yiSYTAsFHqG5TkPms9x/EgDkt2PRw2I0ny SPI6DDHZSX+hG00zw5u9HWNN2mnUvgyKgUB1XptZWcK47vVBQFggb6uETM2/UaZp MBmtwbLUheSCrEKEciVL6Sr8PZLcCDHuttP6Jw2APZZXhK2UcAFUhM0X7koAO0Kk bUmF2oLSUPFjtizQpfOutWE0MsSwfcmAYoHD5REhXhPKeEF6i/B2be6G7gTfB0t9 7jpQLlM/LBjy+KB7bRF/mliASWKIu7F658cBGgSzW28yX7/4wiBr8YnzmCIPLgVP 7mnbatcVbdhKQnoOZe01isDGah/7uuiH1janIEKTSjZYTsW9r/bRb3Fb6le0w1Be qcYtGTnH48ZrEfu8cGmoxOivWvRrjKnyBYjju9OSVUUjZDVBd8x5LVKxPQyi8pIH kRc+khIsxhAcQvYAUvQD =QTeW -----END PGP SIGNATURE----- --3lcZGd9BuhuYXNfi-- From owner-svn-src-stable-11@freebsd.org Thu Dec 21 13:30:57 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E7EE6E96F67; Thu, 21 Dec 2017 13:30:57 +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 ADF9D6655E; Thu, 21 Dec 2017 13:30:57 +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 vBLDUuuk049424; Thu, 21 Dec 2017 13:30:56 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBLDUu7m049423; Thu, 21 Dec 2017 13:30:56 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201712211330.vBLDUu7m049423@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Thu, 21 Dec 2017 13:30:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327059 - stable/11/sys/fs/devfs X-SVN-Group: stable-11 X-SVN-Commit-Author: kib X-SVN-Commit-Paths: stable/11/sys/fs/devfs X-SVN-Commit-Revision: 327059 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Dec 2017 13:30:58 -0000 Author: kib Date: Thu Dec 21 13:30:56 2017 New Revision: 327059 URL: https://svnweb.freebsd.org/changeset/base/327059 Log: MFC r326851: In devfs_lookupx() dotdot lookup case, avoid dereferencing dvp->v_mount after dvp is unlocked. Modified: stable/11/sys/fs/devfs/devfs_vnops.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/fs/devfs/devfs_vnops.c ============================================================================== --- stable/11/sys/fs/devfs/devfs_vnops.c Thu Dec 21 12:21:35 2017 (r327058) +++ stable/11/sys/fs/devfs/devfs_vnops.c Thu Dec 21 13:30:56 2017 (r327059) @@ -880,6 +880,7 @@ devfs_lookupx(struct vop_lookup_args *ap, int *dm_unlo struct devfs_dirent *de, *dd; struct devfs_dirent **dde; struct devfs_mount *dmp; + struct mount *mp; struct cdev *cdev; int error, flags, nameiop, dvplocked; char specname[SPECNAMELEN + 1], *pname; @@ -891,7 +892,8 @@ devfs_lookupx(struct vop_lookup_args *ap, int *dm_unlo td = cnp->cn_thread; flags = cnp->cn_flags; nameiop = cnp->cn_nameiop; - dmp = VFSTODEVFS(dvp->v_mount); + mp = dvp->v_mount; + dmp = VFSTODEVFS(mp); dd = dvp->v_data; *vpp = NULLVP; @@ -924,8 +926,8 @@ devfs_lookupx(struct vop_lookup_args *ap, int *dm_unlo return (ENOENT); dvplocked = VOP_ISLOCKED(dvp); VOP_UNLOCK(dvp, 0); - error = devfs_allocv(de, dvp->v_mount, - cnp->cn_lkflags & LK_TYPE_MASK, vpp); + error = devfs_allocv(de, mp, cnp->cn_lkflags & LK_TYPE_MASK, + vpp); *dm_unlock = 0; vn_lock(dvp, dvplocked | LK_RETRY); return (error); @@ -1010,8 +1012,7 @@ devfs_lookupx(struct vop_lookup_args *ap, int *dm_unlo return (0); } } - error = devfs_allocv(de, dvp->v_mount, cnp->cn_lkflags & LK_TYPE_MASK, - vpp); + error = devfs_allocv(de, mp, cnp->cn_lkflags & LK_TYPE_MASK, vpp); *dm_unlock = 0; return (error); } From owner-svn-src-stable-11@freebsd.org Thu Dec 21 14:09:07 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C0189E9916B; Thu, 21 Dec 2017 14:09:07 +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 88ABE67E53; Thu, 21 Dec 2017 14:09:07 +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 vBLE96WO064072; Thu, 21 Dec 2017 14:09:06 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBLE96BA064071; Thu, 21 Dec 2017 14:09:06 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201712211409.vBLE96BA064071@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Thu, 21 Dec 2017 14:09:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327061 - stable/11/sys/netinet X-SVN-Group: stable-11 X-SVN-Commit-Author: ae X-SVN-Commit-Paths: stable/11/sys/netinet X-SVN-Commit-Revision: 327061 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Dec 2017 14:09:07 -0000 Author: ae Date: Thu Dec 21 14:09:06 2017 New Revision: 327061 URL: https://svnweb.freebsd.org/changeset/base/327061 Log: MFC r326847: Fix mbuf leak when TCPMD5_OUTPUT() method returns error. PR: 223817 Modified: stable/11/sys/netinet/tcp_output.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/netinet/tcp_output.c ============================================================================== --- stable/11/sys/netinet/tcp_output.c Thu Dec 21 13:32:49 2017 (r327060) +++ stable/11/sys/netinet/tcp_output.c Thu Dec 21 14:09:06 2017 (r327061) @@ -1275,12 +1275,13 @@ send: * NOTE: since TCP options buffer doesn't point into * mbuf's data, calculate offset and use it. */ - if (!TCPMD5_ENABLED() || TCPMD5_OUTPUT(m, th, - (u_char *)(th + 1) + (to.to_signature - opt)) != 0) { + if (!TCPMD5_ENABLED() || (error = TCPMD5_OUTPUT(m, th, + (u_char *)(th + 1) + (to.to_signature - opt))) != 0) { /* * Do not send segment if the calculation of MD5 * digest has failed. */ + m_freem(m); goto out; } } From owner-svn-src-stable-11@freebsd.org Thu Dec 21 22:47:05 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BC6DEE909D7; Thu, 21 Dec 2017 22:47:05 +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 941E77C2E0; Thu, 21 Dec 2017 22:47:05 +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 vBLMl4IU083279; Thu, 21 Dec 2017 22:47:04 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBLMl4xL083277; Thu, 21 Dec 2017 22:47:04 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712212247.vBLMl4xL083277@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Thu, 21 Dec 2017 22:47:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327070 - stable/11/sys/geom/mirror X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/geom/mirror X-SVN-Commit-Revision: 327070 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Dec 2017 22:47:05 -0000 Author: markj Date: Thu Dec 21 22:47:04 2017 New Revision: 327070 URL: https://svnweb.freebsd.org/changeset/base/327070 Log: MFC r326409: Update gmirror metadata less frequently when synchronizing. Modified: stable/11/sys/geom/mirror/g_mirror.c stable/11/sys/geom/mirror/g_mirror.h Modified: stable/11/sys/geom/mirror/g_mirror.c ============================================================================== --- stable/11/sys/geom/mirror/g_mirror.c Thu Dec 21 21:24:52 2017 (r327069) +++ stable/11/sys/geom/mirror/g_mirror.c Thu Dec 21 22:47:04 2017 (r327070) @@ -69,6 +69,10 @@ SYSCTL_UINT(_kern_geom_mirror, OID_AUTO, disconnect_on static u_int g_mirror_syncreqs = 2; SYSCTL_UINT(_kern_geom_mirror, OID_AUTO, sync_requests, CTLFLAG_RDTUN, &g_mirror_syncreqs, 0, "Parallel synchronization I/O requests."); +static u_int g_mirror_sync_period = 5; +SYSCTL_UINT(_kern_geom_mirror, OID_AUTO, sync_update_period, CTLFLAG_RWTUN, + &g_mirror_sync_period, 0, + "Metadata update period during synchroniztion, in seconds"); #define MSLEEP(ident, mtx, priority, wmesg, timeout) do { \ G_MIRROR_DEBUG(4, "%s: Sleeping %p.", __func__, (ident)); \ @@ -463,6 +467,7 @@ g_mirror_init_disk(struct g_mirror_softc *sc, struct g disk->d_sync.ds_consumer = NULL; disk->d_sync.ds_offset = md->md_sync_offset; disk->d_sync.ds_offset_done = md->md_sync_offset; + disk->d_sync.ds_update_ts = time_uptime; disk->d_genid = md->md_genid; disk->d_sync.ds_syncid = md->md_syncid; if (errorp != NULL) @@ -1457,10 +1462,11 @@ g_mirror_sync_request(struct bio *bp) if (bp != NULL && bp->bio_offset < offset) offset = bp->bio_offset; } - if (sync->ds_offset_done + (MAXPHYS * 100) < offset) { - /* Update offset_done on every 100 blocks. */ + if (g_mirror_sync_period > 0 && + time_uptime - sync->ds_update_ts > g_mirror_sync_period) { sync->ds_offset_done = offset; g_mirror_update_metadata(disk); + sync->ds_update_ts = time_uptime; } return; } Modified: stable/11/sys/geom/mirror/g_mirror.h ============================================================================== --- stable/11/sys/geom/mirror/g_mirror.h Thu Dec 21 21:24:52 2017 (r327069) +++ stable/11/sys/geom/mirror/g_mirror.h Thu Dec 21 22:47:04 2017 (r327070) @@ -108,6 +108,7 @@ struct g_mirror_disk_sync { off_t ds_offset; /* Offset of next request to send. */ off_t ds_offset_done; /* Offset of already synchronized region. */ + time_t ds_update_ts; /* Time of last metadata update. */ u_int ds_syncid; /* Disk's synchronization ID. */ u_int ds_inflight; /* Number of in-flight sync requests. */ struct bio **ds_bios; /* BIOs for synchronization I/O. */ From owner-svn-src-stable-11@freebsd.org Thu Dec 21 22:48:04 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1BD09E90B1F; Thu, 21 Dec 2017 22:48:04 +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 E77127C441; Thu, 21 Dec 2017 22:48:03 +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 vBLMm2eK083367; Thu, 21 Dec 2017 22:48:02 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBLMm2EG083366; Thu, 21 Dec 2017 22:48:02 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712212248.vBLMm2EG083366@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Thu, 21 Dec 2017 22:48:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327071 - stable/11/sbin/geom/class/mirror X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sbin/geom/class/mirror X-SVN-Commit-Revision: 327071 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Dec 2017 22:48:04 -0000 Author: markj Date: Thu Dec 21 22:48:02 2017 New Revision: 327071 URL: https://svnweb.freebsd.org/changeset/base/327071 Log: MFC r326410: Document gmirror sysctls. Modified: stable/11/sbin/geom/class/mirror/gmirror.8 Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/geom/class/mirror/gmirror.8 ============================================================================== --- stable/11/sbin/geom/class/mirror/gmirror.8 Thu Dec 21 22:47:04 2017 (r327070) +++ stable/11/sbin/geom/class/mirror/gmirror.8 Thu Dec 21 22:48:02 2017 (r327071) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 27, 2016 +.Dd November 30, 2017 .Dt GMIRROR 8 .Os .Sh NAME @@ -179,7 +179,7 @@ Defaults to 4096 bytes. Clear metadata on the given providers. .It Cm create Similar to -.Cm label, +.Cm label , but creates mirror without storing on-disk metadata in last sector. This special "manual" operation mode assumes some external control to manage mirror detection after reboot, device hot-plug and other external events. @@ -337,6 +337,45 @@ gmirror deactivate data da1 dd if=/dev/da1 of=/backup/data.img bs=1m gmirror activate data da1 .Ed +.Sh SYSCTL VARIABLES +The following +.Xr sysctl 8 +variables can be used to configure behavior for all mirrors. +.Bl -tag -width indent +.It Va kern.geom.mirror.debug +Control the verbosity of kernel logging related to mirrors. +A value larger than 0 will enable debug logging. +.It Va kern.geom.mirror.timeout +The amount of time, in seconds, to wait for all copies of a mirror to +appear before starting the mirror. +Disks that appear after the mirror has been started are not automatically +added to the mirror. +.It Va kern.geom.mirror.idletime +The amount of time, in seconds, which must elapse after the last write to +a mirror before that mirror is marked clean. +Clean mirrors do not need to be synchronized after a power failure or +system crash. +A small value may result in frequent overwrites of the disks' metadata +sectors, and thus may reduce the longevity of the disks. +.It Va kern.geom.mirror.disconnect_on_failure +Determine whether a disk is automatically removed from its mirror when an +I/O request to that disk fails. +.It Va kern.geom.mirror.sync_requests +The number of parallel I/O requests used while synchronizing a mirror. +This parameter may only be configured as a +.Xr loader.conf 5 +tunable. +.It Va kern.geom.mirror.sync_update_period +The period, in seconds, at which a synchronizing mirror's metadata is +updated. +Periodic updates are used to record a synchronization's progress so that +an interrupted synchronization may be resumed starting at the recorded +offset, rather than at the beginning. +A smaller value results in more accurate progress tracking, but also +increases the number of non-sequential writes to the disk being synchronized. +If the sysctl value is 0, no updates are performed until the synchronization +is complete. +.El .Sh NOTES Doing kernel dumps to .Nm @@ -382,6 +421,7 @@ there. .Xr mount 8 , .Xr newfs 8 , .Xr savecore 8 , +.Xr sysctl 8 , .Xr umount 8 .Sh HISTORY The @@ -394,7 +434,3 @@ utility appeared in There should be a way to change a component's priority inside a running mirror. .Pp There should be a section with an implementation description. -.Pp -Documentation for sysctls -.Va kern.geom.mirror.* -is missing. From owner-svn-src-stable-11@freebsd.org Fri Dec 22 16:14:22 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 50587EA2616; Fri, 22 Dec 2017 16:14:22 +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 1A7AA7C91B; Fri, 22 Dec 2017 16:14:22 +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 vBMGEL0a021340; Fri, 22 Dec 2017 16:14:21 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBMGELJq021339; Fri, 22 Dec 2017 16:14:21 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712221614.vBMGELJq021339@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Fri, 22 Dec 2017 16:14:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327080 - stable/11/sys/geom/mirror X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/sys/geom/mirror X-SVN-Commit-Revision: 327080 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Dec 2017 16:14:22 -0000 Author: markj Date: Fri Dec 22 16:14:20 2017 New Revision: 327080 URL: https://svnweb.freebsd.org/changeset/base/327080 Log: MFC r326881, r326882: Minor cleanup. Modified: stable/11/sys/geom/mirror/g_mirror.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/geom/mirror/g_mirror.c ============================================================================== --- stable/11/sys/geom/mirror/g_mirror.c Fri Dec 22 13:35:26 2017 (r327079) +++ stable/11/sys/geom/mirror/g_mirror.c Fri Dec 22 16:14:20 2017 (r327080) @@ -72,7 +72,7 @@ SYSCTL_UINT(_kern_geom_mirror, OID_AUTO, sync_requests static u_int g_mirror_sync_period = 5; SYSCTL_UINT(_kern_geom_mirror, OID_AUTO, sync_update_period, CTLFLAG_RWTUN, &g_mirror_sync_period, 0, - "Metadata update period during synchroniztion, in seconds"); + "Metadata update period during synchronization, in seconds"); #define MSLEEP(ident, mtx, priority, wmesg, timeout) do { \ G_MIRROR_DEBUG(4, "%s: Sleeping %p.", __func__, (ident)); \ @@ -1202,7 +1202,7 @@ g_mirror_start(struct bio *bp) * Return TRUE if the given request is colliding with a in-progress * synchronization request. */ -static int +static bool g_mirror_sync_collision(struct g_mirror_softc *sc, struct bio *bp) { struct g_mirror_disk *disk; @@ -1211,7 +1211,7 @@ g_mirror_sync_collision(struct g_mirror_softc *sc, str u_int i; if (sc->sc_sync.ds_ndisks == 0) - return (0); + return (false); rstart = bp->bio_offset; rend = bp->bio_offset + bp->bio_length; LIST_FOREACH(disk, &sc->sc_disks, d_next) { @@ -1224,33 +1224,33 @@ g_mirror_sync_collision(struct g_mirror_softc *sc, str sstart = sbp->bio_offset; send = sbp->bio_offset + sbp->bio_length; if (rend > sstart && rstart < send) - return (1); + return (true); } } - return (0); + return (false); } /* * Return TRUE if the given sync request is colliding with a in-progress regular * request. */ -static int +static bool g_mirror_regular_collision(struct g_mirror_softc *sc, struct bio *sbp) { off_t rstart, rend, sstart, send; struct bio *bp; if (sc->sc_sync.ds_ndisks == 0) - return (0); + return (false); sstart = sbp->bio_offset; send = sbp->bio_offset + sbp->bio_length; TAILQ_FOREACH(bp, &sc->sc_inflight.queue, bio_queue) { rstart = bp->bio_offset; rend = bp->bio_offset + bp->bio_length; if (rend > sstart && rstart < send) - return (1); + return (true); } - return (0); + return (false); } /* From owner-svn-src-stable-11@freebsd.org Fri Dec 22 16:15:01 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EA967EA26D8; Fri, 22 Dec 2017 16:15:01 +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 B40AA7CA80; Fri, 22 Dec 2017 16:15:01 +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 vBMGF0SZ021425; Fri, 22 Dec 2017 16:15:00 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBMGF05r021424; Fri, 22 Dec 2017 16:15:00 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712221615.vBMGF05r021424@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Fri, 22 Dec 2017 16:15:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327081 - stable/11/tests/sys/geom/class/nop X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/tests/sys/geom/class/nop X-SVN-Commit-Revision: 327081 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Dec 2017 16:15:02 -0000 Author: markj Date: Fri Dec 22 16:15:00 2017 New Revision: 327081 URL: https://svnweb.freebsd.org/changeset/base/327081 Log: MFC r326877: Skip gnop tests if the corresponding kernel module isn't available. Modified: stable/11/tests/sys/geom/class/nop/nop_test.sh Directory Properties: stable/11/ (props changed) Modified: stable/11/tests/sys/geom/class/nop/nop_test.sh ============================================================================== --- stable/11/tests/sys/geom/class/nop/nop_test.sh Fri Dec 22 16:14:20 2017 (r327080) +++ stable/11/tests/sys/geom/class/nop/nop_test.sh Fri Dec 22 16:15:00 2017 (r327081) @@ -36,6 +36,7 @@ diskinfo_head() } diskinfo_body() { + load_gnop us=$(alloc_md) atf_check gnop create /dev/${us} md_secsize=$(diskinfo ${us} | cut -wf 2) @@ -62,6 +63,7 @@ io_head() } io_body() { + load_gnop us=$(alloc_md) atf_check gnop create /dev/${us} @@ -87,6 +89,7 @@ size_head() } size_body() { + load_gnop us=$(alloc_md) for mediasize in 65536 524288 1048576; do atf_check gnop create -s ${mediasize} /dev/${us} @@ -111,6 +114,7 @@ stripesize_head() } stripesize_body() { + load_gnop us=$(alloc_md) for ss in 512 1024 2048 4096 8192; do for sofs in `seq 0 512 ${ss}`; do @@ -163,4 +167,11 @@ common_cleanup() rm ${PLAINFILES} fi true +} + +load_gnop() +{ + if ! kldstat -q -m g_nop; then + geom nop load || atf_skip "could not load module for geom nop" + fi } From owner-svn-src-stable-11@freebsd.org Fri Dec 22 16:15:45 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CDDF1EA27B1; Fri, 22 Dec 2017 16:15:45 +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 935F57CBE9; Fri, 22 Dec 2017 16:15:45 +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 vBMGFiJC021500; Fri, 22 Dec 2017 16:15:44 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBMGFisY021499; Fri, 22 Dec 2017 16:15:44 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201712221615.vBMGFisY021499@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Fri, 22 Dec 2017 16:15:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327082 - stable/11/cddl/usr.sbin/dtrace/tests/tools X-SVN-Group: stable-11 X-SVN-Commit-Author: markj X-SVN-Commit-Paths: stable/11/cddl/usr.sbin/dtrace/tests/tools X-SVN-Commit-Revision: 327082 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Dec 2017 16:15:45 -0000 Author: markj Date: Fri Dec 22 16:15:44 2017 New Revision: 327082 URL: https://svnweb.freebsd.org/changeset/base/327082 Log: MFC r326878: Mark uctf/err.user64mode.ksh as EXFAIL for now. Modified: stable/11/cddl/usr.sbin/dtrace/tests/tools/exclude.sh Directory Properties: stable/11/ (props changed) Modified: stable/11/cddl/usr.sbin/dtrace/tests/tools/exclude.sh ============================================================================== --- stable/11/cddl/usr.sbin/dtrace/tests/tools/exclude.sh Fri Dec 22 16:15:00 2017 (r327081) +++ stable/11/cddl/usr.sbin/dtrace/tests/tools/exclude.sh Fri Dec 22 16:15:44 2017 (r327082) @@ -175,6 +175,9 @@ exclude EXFAIL common/vars/tst.ucaller.ksh exclude EXFAIL common/scripting/tst.projid.ksh exclude EXFAIL common/scripting/tst.taskid.ksh +# Depends on tst.chasestrings.exe being ELF32. See r326181 and r326285. +exclude EXFAIL common/uctf/err.user64mode.ksh + # This test expects its test program to be installed without CTF data, but # the rest of the programs for this feature need CTF data. Not yet sure how # to build that. From owner-svn-src-stable-11@freebsd.org Fri Dec 22 17:19:09 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5C7BAEA56D5; Fri, 22 Dec 2017 17:19:09 +0000 (UTC) (envelope-from fsu@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 3671D7F4C6; Fri, 22 Dec 2017 17:19:09 +0000 (UTC) (envelope-from fsu@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBMHJ8EM047071; Fri, 22 Dec 2017 17:19:08 GMT (envelope-from fsu@FreeBSD.org) Received: (from fsu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBMHJ8d8047070; Fri, 22 Dec 2017 17:19:08 GMT (envelope-from fsu@FreeBSD.org) Message-Id: <201712221719.vBMHJ8d8047070@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: fsu set sender to fsu@FreeBSD.org using -f From: Fedor Uporov Date: Fri, 22 Dec 2017 17:19:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327087 - stable/11/sys/kern X-SVN-Group: stable-11 X-SVN-Commit-Author: fsu X-SVN-Commit-Paths: stable/11/sys/kern X-SVN-Commit-Revision: 327087 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Dec 2017 17:19:09 -0000 Author: fsu Date: Fri Dec 22 17:19:08 2017 New Revision: 327087 URL: https://svnweb.freebsd.org/changeset/base/327087 Log: MFC r326808, r326824: Move buffer size checks outside of the vnode locks. Reviewed by: kib, cem, pfg (mentor) Approved by: pfg (mentor) Differential Revision: https://reviews.freebsd.org/D13405 Modified: stable/11/sys/kern/vfs_extattr.c Modified: stable/11/sys/kern/vfs_extattr.c ============================================================================== --- stable/11/sys/kern/vfs_extattr.c Fri Dec 22 17:15:02 2017 (r327086) +++ stable/11/sys/kern/vfs_extattr.c Fri Dec 22 17:19:08 2017 (r327087) @@ -165,6 +165,9 @@ extattr_set_vp(struct vnode *vp, int attrnamespace, co ssize_t cnt; int error; + if (nbytes > IOSIZE_MAX) + return (EINVAL); + error = vn_start_write(vp, &mp, V_WAIT | PCATCH); if (error) return (error); @@ -175,10 +178,6 @@ extattr_set_vp(struct vnode *vp, int attrnamespace, co auio.uio_iov = &aiov; auio.uio_iovcnt = 1; auio.uio_offset = 0; - if (nbytes > IOSIZE_MAX) { - error = EINVAL; - goto done; - } auio.uio_resid = nbytes; auio.uio_rw = UIO_WRITE; auio.uio_segflg = UIO_USERSPACE; @@ -197,7 +196,9 @@ extattr_set_vp(struct vnode *vp, int attrnamespace, co cnt -= auio.uio_resid; td->td_retval[0] = cnt; +#ifdef MAC done: +#endif VOP_UNLOCK(vp, 0); vn_finished_write(mp); return (error); @@ -328,6 +329,9 @@ extattr_get_vp(struct vnode *vp, int attrnamespace, co size_t size, *sizep; int error; + if (nbytes > IOSIZE_MAX) + return (EINVAL); + vn_lock(vp, LK_SHARED | LK_RETRY); /* @@ -344,10 +348,6 @@ extattr_get_vp(struct vnode *vp, int attrnamespace, co auio.uio_iov = &aiov; auio.uio_iovcnt = 1; auio.uio_offset = 0; - if (nbytes > IOSIZE_MAX) { - error = EINVAL; - goto done; - } auio.uio_resid = nbytes; auio.uio_rw = UIO_READ; auio.uio_segflg = UIO_USERSPACE; @@ -372,8 +372,9 @@ extattr_get_vp(struct vnode *vp, int attrnamespace, co td->td_retval[0] = cnt; } else td->td_retval[0] = size; - +#ifdef MAC done: +#endif VOP_UNLOCK(vp, 0); return (error); } @@ -636,6 +637,9 @@ extattr_list_vp(struct vnode *vp, int attrnamespace, v ssize_t cnt; int error; + if (nbytes > IOSIZE_MAX) + return (EINVAL); + vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); auiop = NULL; @@ -647,10 +651,6 @@ extattr_list_vp(struct vnode *vp, int attrnamespace, v auio.uio_iov = &aiov; auio.uio_iovcnt = 1; auio.uio_offset = 0; - if (nbytes > IOSIZE_MAX) { - error = EINVAL; - goto done; - } auio.uio_resid = nbytes; auio.uio_rw = UIO_READ; auio.uio_segflg = UIO_USERSPACE; @@ -674,8 +674,9 @@ extattr_list_vp(struct vnode *vp, int attrnamespace, v td->td_retval[0] = cnt; } else td->td_retval[0] = size; - +#ifdef MAC done: +#endif VOP_UNLOCK(vp, 0); return (error); } From owner-svn-src-stable-11@freebsd.org Fri Dec 22 18:14:57 2017 Return-Path: Delivered-To: svn-src-stable-11@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 15BD6E811FD; Fri, 22 Dec 2017 18:14:57 +0000 (UTC) (envelope-from eugen@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 D0F431C5A; Fri, 22 Dec 2017 18:14:56 +0000 (UTC) (envelope-from eugen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vBMIEtmQ071795; Fri, 22 Dec 2017 18:14:55 GMT (envelope-from eugen@FreeBSD.org) Received: (from eugen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vBMIEtUL071794; Fri, 22 Dec 2017 18:14:55 GMT (envelope-from eugen@FreeBSD.org) Message-Id: <201712221814.vBMIEtUL071794@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: eugen set sender to eugen@FreeBSD.org using -f From: Eugene Grosbein Date: Fri, 22 Dec 2017 18:14:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r327090 - stable/11/usr.sbin/pw X-SVN-Group: stable-11 X-SVN-Commit-Author: eugen X-SVN-Commit-Paths: stable/11/usr.sbin/pw X-SVN-Commit-Revision: 327090 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-11@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for only the 11-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Dec 2017 18:14:57 -0000 Author: eugen Date: Fri Dec 22 18:14:55 2017 New Revision: 327090 URL: https://svnweb.freebsd.org/changeset/base/327090 Log: MFC r326872: fix expiration arithmetic after r326738 and MFC. Approved by: mav (mentor) Modified: stable/11/usr.sbin/pw/pw_user.c Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.sbin/pw/pw_user.c ============================================================================== --- stable/11/usr.sbin/pw/pw_user.c Fri Dec 22 17:53:27 2017 (r327089) +++ stable/11/usr.sbin/pw/pw_user.c Fri Dec 22 18:14:55 2017 (r327090) @@ -1383,11 +1383,12 @@ pw_user_add(int argc, char **argv, char *arg1) pwd->pw_uid = pw_uidpolicy(cmdcnf, id); pwd->pw_gid = pw_gidpolicy(cnf, grname, pwd->pw_name, (gid_t) pwd->pw_uid, dryrun); - + + /* cmdcnf->password_days and cmdcnf->expire_days hold unixtime here */ if (cmdcnf->password_days > 0) - pwd->pw_change = now + cmdcnf->password_days * 86400L; + pwd->pw_change = cmdcnf->password_days; if (cmdcnf->expire_days > 0) - pwd->pw_expire = now + cmdcnf->expire_days * 86400L; + pwd->pw_expire = cmdcnf->expire_days; pwd->pw_dir = pw_homepolicy(cmdcnf, homedir, pwd->pw_name); pwd->pw_shell = pw_shellpolicy(cmdcnf); @@ -1521,9 +1522,9 @@ pw_user_mod(int argc, char **argv, char *arg1) bool quiet, createhome, pretty, dryrun, nis, edited; bool precrypted; mode_t homemode = 0; - time_t expire_days, password_days, now; + time_t expire_time, password_time, now; - expire_days = password_days = -1; + expire_time = password_time = -1; gecos = homedir = grname = name = newname = skel = shell =NULL; passwd = NULL; class = nispasswd = NULL; @@ -1559,10 +1560,10 @@ pw_user_mod(int argc, char **argv, char *arg1) homedir = optarg; break; case 'e': - expire_days = parse_date(now, optarg); + expire_time = parse_date(now, optarg); break; case 'p': - password_days = parse_date(now, optarg); + password_time = parse_date(now, optarg); break; case 'g': group_from_name_or_id(optarg); @@ -1697,13 +1698,13 @@ pw_user_mod(int argc, char **argv, char *arg1) } - if (password_days >= 0) { - pwd->pw_change = now + password_days * 86400L; + if (password_time >= 0 && pwd->pw_change != password_time) { + pwd->pw_change = password_time; edited = true; } - if (expire_days >= 0) { - pwd->pw_expire = now + expire_days * 86400L; + if (expire_time >= 0 && pwd->pw_expire != expire_time) { + pwd->pw_expire = expire_time; edited = true; }