From owner-svn-src-all@freebsd.org Sun Mar 12 00:37:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ED1C3CF9561; Sun, 12 Mar 2017 00:37:46 +0000 (UTC) (envelope-from rgrimes@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 B198014A9; Sun, 12 Mar 2017 00:37:46 +0000 (UTC) (envelope-from rgrimes@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C0bjWU045398; Sun, 12 Mar 2017 00:37:45 GMT (envelope-from rgrimes@FreeBSD.org) Received: (from rgrimes@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C0bjdq045397; Sun, 12 Mar 2017 00:37:45 GMT (envelope-from rgrimes@FreeBSD.org) Message-Id: <201703120037.v2C0bjdq045397@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rgrimes set sender to rgrimes@FreeBSD.org using -f From: "Rodney W. Grimes" Date: Sun, 12 Mar 2017 00:37:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315091 - head/share/termcap X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 00:37:47 -0000 Author: rgrimes Date: Sun Mar 12 00:37:45 2017 New Revision: 315091 URL: https://svnweb.freebsd.org/changeset/base/315091 Log: Revert r314833 until the problem with INSTALL_RSYMLINKS can be found as it appears to break arm release builds. PR: 217705 Reported by: cyclaero@gmail.com Approved by: grehan (mentor) implict as reverting Modified: head/share/termcap/Makefile Modified: head/share/termcap/Makefile ============================================================================== --- head/share/termcap/Makefile Sat Mar 11 22:34:02 2017 (r315090) +++ head/share/termcap/Makefile Sun Mar 12 00:37:45 2017 (r315091) @@ -24,6 +24,6 @@ termcap.db: termcap cap_mkdb ${CAP_MKDB_ENDIAN} -f ${.TARGET:R} ${.ALLSRC} etc-termcap: - ${INSTALL_RSYMLINK} ${BINDIR}/misc/termcap ${DESTDIR}/etc/termcap + ${INSTALL_SYMLINK} ${BINDIR}/misc/termcap ${DESTDIR}/etc/termcap .include From owner-svn-src-all@freebsd.org Sun Mar 12 00:46:50 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C219CCF9877; Sun, 12 Mar 2017 00:46:50 +0000 (UTC) (envelope-from lwhsu@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 839681A51; Sun, 12 Mar 2017 00:46:50 +0000 (UTC) (envelope-from lwhsu@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C0knfk049595; Sun, 12 Mar 2017 00:46:49 GMT (envelope-from lwhsu@FreeBSD.org) Received: (from lwhsu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C0knGT049594; Sun, 12 Mar 2017 00:46:49 GMT (envelope-from lwhsu@FreeBSD.org) Message-Id: <201703120046.v2C0knGT049594@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: lwhsu set sender to lwhsu@FreeBSD.org using -f From: Li-Wen Hsu Date: Sun, 12 Mar 2017 00:46: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: r315092 - stable/11/release/tools X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 00:46:50 -0000 Author: lwhsu (ports committer) Date: Sun Mar 12 00:46:49 2017 New Revision: 315092 URL: https://svnweb.freebsd.org/changeset/base/315092 Log: MFC 308106: - Use virtualbox-ose-additions-nox11 for vagrant image to reduce size Modified: stable/11/release/tools/vagrant-virtualbox.conf Directory Properties: stable/11/ (props changed) Modified: stable/11/release/tools/vagrant-virtualbox.conf ============================================================================== --- stable/11/release/tools/vagrant-virtualbox.conf Sun Mar 12 00:37:45 2017 (r315091) +++ stable/11/release/tools/vagrant-virtualbox.conf Sun Mar 12 00:46:49 2017 (r315092) @@ -5,11 +5,11 @@ . ${WORLDDIR}/release/tools/vagrant.conf -export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} virtualbox-ose-additions" +export VM_EXTRA_PACKAGES="${VM_EXTRA_PACKAGES} virtualbox-ose-additions-nox11" vm_extra_pre_umount () { # VirtualBox first boot pkgs - echo 'firstboot_pkgs_list="sudo rsync virtualbox-ose-additions"' >> ${DESTDIR}/etc/rc.conf + echo 'firstboot_pkgs_list="sudo rsync virtualbox-ose-additions-nox11"' >> ${DESTDIR}/etc/rc.conf echo 'vboxguest_enable="YES"' >> ${DESTDIR}/etc/rc.conf echo 'vboxservice_enable="YES"' >> ${DESTDIR}/etc/rc.conf From owner-svn-src-all@freebsd.org Sun Mar 12 00:52:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5AA21CF9B08; Sun, 12 Mar 2017 00:52:18 +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 329D21F6D; Sun, 12 Mar 2017 00:52:18 +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 v2C0qHC3053607; Sun, 12 Mar 2017 00:52:17 GMT (envelope-from manu@FreeBSD.org) Received: (from manu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C0qH44053604; Sun, 12 Mar 2017 00:52:17 GMT (envelope-from manu@FreeBSD.org) Message-Id: <201703120052.v2C0qH44053604@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: manu set sender to manu@FreeBSD.org using -f From: Emmanuel Vadot Date: Sun, 12 Mar 2017 00:52:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315093 - in head/sys: amd64/conf conf i386/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 00:52:18 -0000 Author: manu Date: Sun Mar 12 00:52:16 2017 New Revision: 315093 URL: https://svnweb.freebsd.org/changeset/base/315093 Log: Remove i915drm and radeondrm from NOTES and conf. This unbreak LINT kernel. Reported by: lwhsu Modified: head/sys/amd64/conf/NOTES head/sys/conf/files head/sys/i386/conf/NOTES Modified: head/sys/amd64/conf/NOTES ============================================================================== --- head/sys/amd64/conf/NOTES Sun Mar 12 00:46:49 2017 (r315092) +++ head/sys/amd64/conf/NOTES Sun Mar 12 00:52:16 2017 (r315093) @@ -288,11 +288,9 @@ device cpufreq # Direct Rendering modules for 3D acceleration. device drm # DRM core module required by DRM drivers -device i915drm # Intel i830 through i915 device mach64drm # ATI Rage Pro, Rage Mobility P/M, Rage XL device mgadrm # AGP Matrox G200, G400, G450, G550 device r128drm # ATI Rage 128 -device radeondrm # ATI Radeon device savagedrm # S3 Savage3D, Savage4 device sisdrm # SiS 300/305, 540, 630 device tdfxdrm # 3dfx Voodoo 3/4/5 and Banshee Modified: head/sys/conf/files ============================================================================== --- head/sys/conf/files Sun Mar 12 00:46:49 2017 (r315092) +++ head/sys/conf/files Sun Mar 12 00:52:16 2017 (r315093) @@ -1458,11 +1458,6 @@ dev/drm/drm_scatter.c optional drm dev/drm/drm_sman.c optional drm dev/drm/drm_sysctl.c optional drm dev/drm/drm_vm.c optional drm -dev/drm/i915_dma.c optional i915drm -dev/drm/i915_drv.c optional i915drm -dev/drm/i915_irq.c optional i915drm -dev/drm/i915_mem.c optional i915drm -dev/drm/i915_suspend.c optional i915drm dev/drm/mach64_dma.c optional mach64drm dev/drm/mach64_drv.c optional mach64drm dev/drm/mach64_irq.c optional mach64drm @@ -1477,17 +1472,6 @@ dev/drm/r128_cce.c optional r128drm \ dev/drm/r128_drv.c optional r128drm dev/drm/r128_irq.c optional r128drm dev/drm/r128_state.c optional r128drm -dev/drm/r300_cmdbuf.c optional radeondrm -dev/drm/r600_blit.c optional radeondrm -dev/drm/r600_cp.c optional radeondrm \ - compile-with "${NORMAL_C} ${NO_WCONSTANT_CONVERSION}" -dev/drm/radeon_cp.c optional radeondrm \ - compile-with "${NORMAL_C} ${NO_WCONSTANT_CONVERSION}" -dev/drm/radeon_cs.c optional radeondrm -dev/drm/radeon_drv.c optional radeondrm -dev/drm/radeon_irq.c optional radeondrm -dev/drm/radeon_mem.c optional radeondrm -dev/drm/radeon_state.c optional radeondrm dev/drm/savage_bci.c optional savagedrm dev/drm/savage_drv.c optional savagedrm dev/drm/savage_state.c optional savagedrm Modified: head/sys/i386/conf/NOTES ============================================================================== --- head/sys/i386/conf/NOTES Sun Mar 12 00:46:49 2017 (r315092) +++ head/sys/i386/conf/NOTES Sun Mar 12 00:52:16 2017 (r315093) @@ -508,11 +508,9 @@ device cpufreq # Direct Rendering modules for 3D acceleration. device drm # DRM core module required by DRM drivers -device i915drm # Intel i830 through i915 device mach64drm # ATI Rage Pro, Rage Mobility P/M, Rage XL device mgadrm # AGP Matrox G200, G400, G450, G550 device r128drm # ATI Rage 128 -device radeondrm # ATI Radeon device savagedrm # S3 Savage3D, Savage4 device sisdrm # SiS 300/305, 540, 630 device tdfxdrm # 3dfx Voodoo 3/4/5 and Banshee From owner-svn-src-all@freebsd.org Sun Mar 12 01:55:39 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 24663D06A0F; Sun, 12 Mar 2017 01:55:39 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: from mail-wr0-f180.google.com (mail-wr0-f180.google.com [209.85.128.180]) (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 B99ED14C8; Sun, 12 Mar 2017 01:55:38 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: by mail-wr0-f180.google.com with SMTP id l37so84824730wrc.1; Sat, 11 Mar 2017 17:55:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc; bh=QsQn46hoXATFR5tZ3TsWMamSuz6ZD5C6ZqZKOBZYQYE=; b=DxahLPlRZh6ZwFNU1Xe+Y+QXueDihaguoyCaGyGhkhKglMBvWr6SBdnoVIPXg5cdj3 sm9kUKmUVoQ8boz3MU4pzoPyQc3vNzoaN56ZOTe/WNEy4XYMFQskQFOSc15UYI1y+uIp iSA3lZKzGzmQk+Uaba7URMWckOWtvJhmMfxrJh3QHsNwpJ85+eMc5J5E1DHqYsyQo6ov DrZJxZL1r4CsubXsx86Ly/k24GreKg6LK34Ni43agsmlh5Z/Wn5iary2QwFIbFdJT+YK 4buLRERXo/TA0nwQ34fq/ZWha/kRUn8NLDie9PtEbBh5ijbvkRm0W4nfrsxu9R6tC51B kW1g== X-Gm-Message-State: AMke39nKzfEQMVo6K8PAGy4K7GNC7ltyhG0CNHz8IA7Tzi8nQ5HLcp3PrwnDHZfjR1xqoQ== X-Received: by 10.223.179.216 with SMTP id x24mr21995186wrd.171.1489283422813; Sat, 11 Mar 2017 17:50:22 -0800 (PST) Received: from mail-wr0-f180.google.com (mail-wr0-f180.google.com. [209.85.128.180]) by smtp.gmail.com with ESMTPSA id z70sm19341235wrc.2.2017.03.11.17.50.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 11 Mar 2017 17:50:22 -0800 (PST) Received: by mail-wr0-f180.google.com with SMTP id u48so84826987wrc.0; Sat, 11 Mar 2017 17:50:22 -0800 (PST) X-Received: by 10.223.133.6 with SMTP id 6mr22356358wrh.57.1489283422477; Sat, 11 Mar 2017 17:50:22 -0800 (PST) MIME-Version: 1.0 Reply-To: cem@freebsd.org Received: by 10.80.169.4 with HTTP; Sat, 11 Mar 2017 17:50:21 -0800 (PST) In-Reply-To: <201703110436.v2B4aF6Z037011@repo.freebsd.org> References: <201703110436.v2B4aF6Z037011@repo.freebsd.org> From: Conrad Meyer Date: Sat, 11 Mar 2017 17:50:21 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r315049 - head/usr.bin/vmstat To: Marcelo Araujo Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 01:55:39 -0000 Hi Marcelo, Should we add WARNS=2 in vmstat's Makefile so that developers notice when they break warnings at that level? Thanks, Conrad On Fri, Mar 10, 2017 at 8:36 PM, Marcelo Araujo wrote: > Author: araujo > Date: Sat Mar 11 04:36:15 2017 > New Revision: 315049 > URL: https://svnweb.freebsd.org/changeset/base/315049 > > Log: > Bring back the cast removed in my previous commit to allow us build vmstat > with WARNS 2. This cast was first introduced at r87690. > > Reported by: bde, pfg and ngie > MFC after: 3 weeks. > > Modified: > head/usr.bin/vmstat/vmstat.c > > Modified: head/usr.bin/vmstat/vmstat.c > ============================================================================== > --- head/usr.bin/vmstat/vmstat.c Sat Mar 11 04:03:13 2017 (r315048) > +++ head/usr.bin/vmstat/vmstat.c Sat Mar 11 04:36:15 2017 (r315049) > @@ -288,13 +288,13 @@ retry_nlist: > namelist[X_SUM].n_name = "_cnt"; > goto retry_nlist; > } > - for (c = 0; c < nitems(namelist); c++) > + for (c = 0; c < (int)(nitems(namelist)); c++) > if (namelist[c].n_type == 0) > bufsize += strlen(namelist[c].n_name) + 1; > bufsize += len + 1; > buf = bp = alloca(bufsize); > > - for (c = 0; c < nitems(namelist); c++) > + for (c = 0; c < (int)(nitems(namelist)); c++) > if (namelist[c].n_type == 0) { > xo_error(" %s", > namelist[c].n_name); > From owner-svn-src-all@freebsd.org Sun Mar 12 02:05:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CB36CD06CB3; Sun, 12 Mar 2017 02:05:26 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x243.google.com (mail-pg0-x243.google.com [IPv6:2607:f8b0:400e:c05::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 9604A19D3; Sun, 12 Mar 2017 02:05:26 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x243.google.com with SMTP id 77so14379705pgc.0; Sat, 11 Mar 2017 18:05:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=Zq66uekQD968FcDrYHijXl0zYs5Sc7kb60OrkPt2lxI=; b=XDaBpWigV7P5bvuqwZlt3zaxanxptLI5s9Jr38xTR+uzzJ0Z4ddsT0YIW2IG5UK3BX q+3n7DgvTAH1zvRbPMm8C1dOwnminRmYCxNU101ISPTFbnhwCaayU3xelva/lhRNq1xC sBlZwWa3s7Mh9XH/Cv/C+KQlugfwFT2yyiN3XxoN04yjroSMzvqv7pgTVMqdrJpMrHnY HpdDHzmI3nknYVP0mKh1nnxeovcdP/Y11kcLngroh7spYTRe4udlol2s1C/e4aZAdYDv aex2Gv1Ad3wnmNNMGQQkFq3rv8MbNCGWE1+qjYfvcG60EZPfPmiZR6yGYl8JimIPdCUa 8jzQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=Zq66uekQD968FcDrYHijXl0zYs5Sc7kb60OrkPt2lxI=; b=MPwwOlCwBwwM+wcaQFaW+NXJcIUnxXJdmeMP4Voepxb+M8Kq1tZB4tCbmqpU/fG2rp 6NVXvSMVTfp5yoa4F8bS/GqbHy5+/4LDtCfOUKUAHBQEYj81cC/NFAM4Jz/gtWgi4Z8X +iBkJokYbtlXS47nMXCRU7cWF97rDRUcnMzVIzmRyRs8fJD62rjUKxeXxS0sOSgHWG68 KVx/pp1exYyc/38ZlRd5YdEKI/2s+UpZnkwev0KoHhwuwBl0vvvtNp2VHM+oir7F1b29 9P460IQMc+/8tTMJygEfREaq0QTLUbwDtWarAzwwTrnW/KKZzTPuQffvpnV26K17XMrK SCMA== X-Gm-Message-State: AMke39n8N4Tl+PtPDLIHwl23H7/SW1DGQvEMr4utyDcOBYpZLu+v/iyq+oay+W6QG4UxCw== X-Received: by 10.84.141.1 with SMTP id 1mr37544683plu.178.1489284325882; Sat, 11 Mar 2017 18:05:25 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id b190sm26109815pfa.110.2017.03.11.18.05.24 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 18:05:25 -0800 (PST) Subject: Re: svn commit: r315049 - head/usr.bin/vmstat Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_FC515EDB-8367-485B-BD6B-2CAD794F7857"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703110436.v2B4aF6Z037011@repo.freebsd.org> Date: Sat, 11 Mar 2017 18:05:23 -0800 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703110436.v2B4aF6Z037011@repo.freebsd.org> To: Marcelo Araujo X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 02:05:26 -0000 --Apple-Mail=_FC515EDB-8367-485B-BD6B-2CAD794F7857 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 10, 2017, at 20:36, Marcelo Araujo wrote: >=20 > Author: araujo > Date: Sat Mar 11 04:36:15 2017 > New Revision: 315049 > URL: https://svnweb.freebsd.org/changeset/base/315049 >=20 > Log: > Bring back the cast removed in my previous commit to allow us build = vmstat > with WARNS 2. This cast was first introduced at r87690. >=20 > Reported by: bde, pfg and ngie > MFC after: 3 weeks. >=20 > Modified: > head/usr.bin/vmstat/vmstat.c >=20 > Modified: head/usr.bin/vmstat/vmstat.c > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/usr.bin/vmstat/vmstat.c Sat Mar 11 04:03:13 2017 = (r315048) > +++ head/usr.bin/vmstat/vmstat.c Sat Mar 11 04:36:15 2017 = (r315049) > @@ -288,13 +288,13 @@ retry_nlist: > namelist[X_SUM].n_name =3D "_cnt"; > goto retry_nlist; > } > - for (c =3D 0; c < nitems(namelist); c++) > + for (c =3D 0; c < (int)(nitems(namelist)); c++) Before bde@ notes this, it=E2=80=99s stylistically incorrect (additional = unnecessary parentheses around the nitems call. Thanks, -Ngie --Apple-Mail=_FC515EDB-8367-485B-BD6B-2CAD794F7857 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxKzkAAoJEPWDqSZpMIYVIsIP/izalFLh6BHf/ZjsPiWc7F2e cGvkvLhQiWt/Ojc8FIWNml2JaCOTiDiCjmW1ii+JJA5pHh7dQv9z/+uGMZPRRWyv A67HQ7qDDPyRLNVhIEGmbHsp6bVBq7MTBducdOHTkoTTHLzyJkASqX4NtUhrrLbE md5awRhWLNugP6xWQdIP1T53FyedHc9rhuYoWlLtkuiGZ4ARe+BoTpIIBPnP4n1M 2jMJrAgWxdiXhpFPkkUbHRdTpXXW7dj9owm2uICUx29FbU+JhbOHpK4RU38rYRB4 imEQzajQkkAra7KenCGvyBLkosVsfS0Y9oSJ0gnZa3dtfBpaiUifJYryVXyXuy2/ UiLw3ZzZnkiABi8d6SMHiOl+0etNRP9ROEPc5af4RApsNLqrau4KO1hPR2FO7BDv MwUE6AF+wBe5Nr34Ic8c4rOe48i68GKi10Y5Y7RzB/KvZhgU+tMpust1K5w/J3R1 5tGiXTjF54PO7Lw8EGV3gocdrd+7W9ZM3rhD3NwJ23DKj1MGVQFTi0jJKclaZa99 g/c3DpOP3AiAHLxKXw7kbYMc5X9DQmAZcol5WnzWQv19rRklUKNbpLJeVw0ogSVl nPnA8z1aJyrHtInuzDZ/VqOWmWolCDmE1oAxRuHHsDMLSul+EtPpogunTiiCgkxc JrI4w+3ceQf9H+83n5LV =59ce -----END PGP SIGNATURE----- --Apple-Mail=_FC515EDB-8367-485B-BD6B-2CAD794F7857-- From owner-svn-src-all@freebsd.org Sun Mar 12 02:06:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 561BDD06D5F; Sun, 12 Mar 2017 02:06:46 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x242.google.com (mail-pg0-x242.google.com [IPv6:2607:f8b0:400e:c05::242]) (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 234CD1B6F; Sun, 12 Mar 2017 02:06:46 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x242.google.com with SMTP id 25so14413563pgy.3; Sat, 11 Mar 2017 18:06:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=tQ9jznwfkrvgsvvwmSnAED57+GMCIClmrleT4SuLgRI=; b=KMKClxVVl2KajUiCEtWZ6HiwZIPunQbQg8m7l/Md8obVkA6Am+yMV1lch7tB03kLiE zXOiXrF9HJW+CKVf7W0ZF6QgbUvP6BnH7Ulg7aVChKmrC55mjPbJKpkziKiDfYGSrns5 u49++7yed3ZqwrDvRMNY7Kt9vUIRipuvQkPJGT+AMiodJ6T7Ghgr9L1swxCNg4hBKD0a M0WRw+JccfOVf8cV1G+tDjEqx3/Qvs8n2offvxN9rb0o+/do+SgM7sGnnu7wRfvU0cIc gLdZYL2Wf25mSX8vcXQwXOSUyj0s+zbnYHF85nSiA2rBQVMsuxZB9PfHgukBMXwwyCzb 8cyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=tQ9jznwfkrvgsvvwmSnAED57+GMCIClmrleT4SuLgRI=; b=QW4LypLi9Uigpw4YBuMcsuEyMpTcrNdwQ5vAczsUOLhbFx4oC50D+7Ev40+9OR/R/2 vJvT1RiqHQt9knqNigJGi50SReLVrkmRbi//akJ1LG3v09EuPdOjSAsZkjm7yWfNfGyN RDSKiH3qHfod/Al4BfFhL+PULWts5rWwHgw6YyWbUPAf5xEu6oGY4SjMuQ+uEOQCKEHX J6DIH49Le9b5i8Buq25WeGI2KzirmIxWcM0XXp3PiKMQkfJHvzZIgUdFplueYkTln6mo m9ez8qPo73XQcPhyX2MeYIERJEb5kmh2FyvEBemFPR1zvZWcqHwa7jwzoPPRKRXmEJcB 5sIA== X-Gm-Message-State: AMke39nTBe3XdR21Eb1+P6e5DJp1osh9WPFyWZ8u4BTln78ZxptV/Ti3EHwjCta0BSfosg== X-Received: by 10.99.104.199 with SMTP id d190mr28904670pgc.59.1489284405487; Sat, 11 Mar 2017 18:06:45 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id b7sm26181557pfg.53.2017.03.11.18.06.44 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 18:06:44 -0800 (PST) Subject: Re: svn commit: r315045 - in head/sys: dev/drm modules/drm modules/drm/i915 modules/drm/radeon Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_3175E089-11FE-4ED1-9FBE-0C8FFD224996"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703110301.v2B31I2Q096339@repo.freebsd.org> Date: Sat, 11 Mar 2017 18:06:44 -0800 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703110301.v2B31I2Q096339@repo.freebsd.org> To: Emmanuel Vadot X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 02:06:46 -0000 --Apple-Mail=_3175E089-11FE-4ED1-9FBE-0C8FFD224996 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii > On Mar 10, 2017, at 19:01, Emmanuel Vadot wrote: > > Author: manu > Date: Sat Mar 11 03:01:18 2017 > New Revision: 315045 > URL: https://svnweb.freebsd.org/changeset/base/315045 > > Log: > drm(old): Remove i915 and radeon drivers > > They cannot be used anymore with the userland bits we provide. > Furthermore, their KMS versions support the same hardware. > > Submitted by: dumbbell > Reviewed by: emaste, manu > Sponsored by: AsiaBSDCon > Differential Revision: https://reviews.freebsd.org/D5614 Relnotes: yes Please add an entry to UPDATING if possible too. Thank you :)!! -Ngie --Apple-Mail=_3175E089-11FE-4ED1-9FBE-0C8FFD224996 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxK00AAoJEPWDqSZpMIYVDbsP/RmsPGvzB97GngPiq0gFrtT0 7i3dQPddOpCjkaoTnIE19Pc+03vvQtTHSTEUVWUuYRqhoyX7+boSM3P2yJskcqaq UkGRtkWNtomPzxvti8v8vNCtvnMuUmdvzTvPRIOhMsoqWFFUkD4ZpUutJ6kOShxy Cp/PpOltaR+fWsKWg8jyP7fhrQkOu69g/oJVUtvop0hcFYOheu0o7ur/a5TsFI59 nqJFQ/hdvjogJB25fw66dGgkfJxvzl6XNtVeRKcuuw2JtUEsLhHviC+zyJVO4gYt Nv+0vf9I5fhrQhMqDy7EGjPFRq+TRrnhE9Ui4jbBGZ+X6OKxZtbSoBgNln7gmAhw fWl8EHocULQJlRGA+4ZyHmR0ymAL2+CAbsKkmcX1n4GO5EaTK72SCob10uj/ETRG +0qfSqZPbK6X8txfoZxte/E2hxdFBvosA1wEtlptQPezV7NsJUzMS21pIB8ij2nL VIgTizoiUg3hDtR5gHbjDLWqP/tXzIKtu43bLfG91hnp1QvsHAwoZjKLbvQppbG+ ywvofLAbSkxcFG86/YaiW0YgzYMijjMur7bg5l9V+L2ziiaQuSBvHvVCZIqiLqgE urN4mxcV8XawrSDbmYf2EkTIvMtVSuvJeuCQuuLCH9bZ8hFBmn2l0jnNB9/rcTuI Q5Fo/yhbCoovsVL59P/J =XxXj -----END PGP SIGNATURE----- --Apple-Mail=_3175E089-11FE-4ED1-9FBE-0C8FFD224996-- From owner-svn-src-all@freebsd.org Sun Mar 12 02:21:17 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E112ED071F3; Sun, 12 Mar 2017 02:21:17 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B0C5F14F2; Sun, 12 Mar 2017 02:21:17 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C2LGth088909; Sun, 12 Mar 2017 02:21:16 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C2LGp1088908; Sun, 12 Mar 2017 02:21:16 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120221.v2C2LGp1088908@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 02:21:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315094 - head/sbin/setkey X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 02:21:18 -0000 Author: ngie Date: Sun Mar 12 02:21:16 2017 New Revision: 315094 URL: https://svnweb.freebsd.org/changeset/base/315094 Log: Delete duplicate -I /lib/libipsec added in r171135 It's already handled earlier on in the Makefile, per the change made in r80029. MFC after: 1 month Sponsored by: Dell EMC Isilon Modified: head/sbin/setkey/Makefile Modified: head/sbin/setkey/Makefile ============================================================================== --- head/sbin/setkey/Makefile Sun Mar 12 00:52:16 2017 (r315093) +++ head/sbin/setkey/Makefile Sun Mar 12 02:21:16 2017 (r315094) @@ -46,7 +46,7 @@ CLEANFILES= y.tab.c y.tab.h key_test.o k # ipsec_strerror.c is for avoiding shlib reference to non-exported function. .PATH: ${SRCTOP}/lib/libipsec ${SRCTOP}/sys/netipsec SRCS+= pfkey.c pfkey_dump.c key_debug.c ipsec_strerror.c -CFLAGS+= -I${SRCTOP}/lib/libipsec -I${SRCTOP}/sys/netipsec +CFLAGS+= -I${SRCTOP}/sys/netipsec SRCS+= y.tab.h y.tab.h: parse.y From owner-svn-src-all@freebsd.org Sun Mar 12 02:44:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C69ACD07D22; Sun, 12 Mar 2017 02:44:59 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail110.syd.optusnet.com.au (mail110.syd.optusnet.com.au [211.29.132.97]) by mx1.freebsd.org (Postfix) with ESMTP id 90A371561; Sun, 12 Mar 2017 02:44:58 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c122-106-153-191.carlnfd1.nsw.optusnet.com.au [122.106.153.191]) by mail110.syd.optusnet.com.au (Postfix) with ESMTPS id 5A209102F2F; Sun, 12 Mar 2017 13:44:51 +1100 (AEDT) Date: Sun, 12 Mar 2017 13:44:50 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Andriy Gapon cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315068 - head/sys/modules/qlxgbe In-Reply-To: <201703111516.v2BFGtkn006959@repo.freebsd.org> Message-ID: <20170312124945.C4483@besplex.bde.org> References: <201703111516.v2BFGtkn006959@repo.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=AYLBJzfG c=1 sm=1 tr=0 a=Tj3pCpwHnMupdyZSltBt7Q==:117 a=Tj3pCpwHnMupdyZSltBt7Q==:17 a=kj9zAlcOel0A:10 a=TpLjFTHyFfqqnH7asFwA:9 a=CjuIK1q_8ugA:10 a=HzLR6qCuIIUA:10 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 02:44:59 -0000 On Sat, 11 Mar 2017, Andriy Gapon wrote: > Log: > revert r314862, use of GCC_MS_EXTENSIONS in qlxgbe > > Commit r278913 made explicit use of GCC_MS_EXTENSIONS unnecessary. > > Requested by: glebius Does this module actually use ms extensions? This seems unlikely, since only gcc supports them. My kernels compile correctly with the correct CFLAGS (gcc -std=gnu99 -fno-ms-extensions). Bruce From owner-svn-src-all@freebsd.org Sun Mar 12 02:57:43 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 782F8D07081 for ; Sun, 12 Mar 2017 02:57:43 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound1a.eu.mailhop.org (outbound1a.eu.mailhop.org [52.58.109.202]) (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 1625F1B99 for ; Sun, 12 Mar 2017 02:57:42 +0000 (UTC) (envelope-from ian@freebsd.org) X-MHO-User: a9973b53-06cf-11e7-95b5-6dfd7dbb0ee5 X-Report-Abuse-To: https://support.duocircle.com/support/solutions/articles/5000540958-duocircle-standard-smtp-abuse-information X-Originating-IP: 73.78.92.27 X-Mail-Handler: DuoCircle Outbound SMTP Received: from ilsoft.org (unknown [73.78.92.27]) by outbound1.eu.mailhop.org (Halon) with ESMTPSA id a9973b53-06cf-11e7-95b5-6dfd7dbb0ee5; Sun, 12 Mar 2017 02:57:44 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.15.2) with ESMTP id v2C2vXB9002472; Sat, 11 Mar 2017 19:57:33 -0700 (MST) (envelope-from ian@freebsd.org) Message-ID: <1489287453.40576.75.camel@freebsd.org> Subject: Re: svn commit: r315091 - head/share/termcap From: Ian Lepore To: "Rodney W. Grimes" , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Date: Sat, 11 Mar 2017 19:57:33 -0700 In-Reply-To: <201703120037.v2C0bjdq045397@repo.freebsd.org> References: <201703120037.v2C0bjdq045397@repo.freebsd.org> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.1 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 02:57:43 -0000 On Sun, 2017-03-12 at 00:37 +0000, Rodney W. Grimes wrote: > Author: rgrimes > Date: Sun Mar 12 00:37:45 2017 > New Revision: 315091 > URL: https://svnweb.freebsd.org/changeset/base/315091 > > Log: >   Revert r314833 until the problem with INSTALL_RSYMLINKS can be > found >   as it appears to break arm release builds. >    >   PR: 217705 >   Reported by: cyclaero@gmail.com >   Approved by: grehan (mentor) implict as reverting > > Modified: >   head/share/termcap/Makefile > > Modified: head/share/termcap/Makefile > ===================================================================== > ========= > --- head/share/termcap/Makefile Sat Mar 11 22:34:02 2017 > (r315090) > +++ head/share/termcap/Makefile Sun Mar 12 00:37:45 2017 > (r315091) > @@ -24,6 +24,6 @@ termcap.db: termcap >   cap_mkdb ${CAP_MKDB_ENDIAN} -f ${.TARGET:R} ${.ALLSRC} >   >  etc-termcap: > - ${INSTALL_RSYMLINK} ${BINDIR}/misc/termcap > ${DESTDIR}/etc/termcap > + ${INSTALL_SYMLINK} ${BINDIR}/misc/termcap > ${DESTDIR}/etc/termcap >   >  .include > In an arm build sandbox I ran "make distribution DESTDIR=/tmp/ian" and this is what happened with termcap: --- etc-termcap --- install -l rs /usr/share/misc/termcap /tmp/ian/etc/termcap ... revolution > file /tmp/ian/etc/termcap /tmp/ian/etc/termcap: symbolic link to ../../../usr/share/misc/termcap Then I changed the rsymlink in share/termcap/Makefile to: ${INSTALL_RSYMLINK} ${DESTDIR}/${BINDIR}/misc/termcap ${DESTDIR}/etc/termcap and it did the right thing: --- etc-termcap --- install -l rs /tmp/ian//usr/share/misc/termcap /tmp/ian/etc/termcap ... revolution > file /tmp/ian/etc/termcap /tmp/ian/etc/termcap: symbolic link to ../usr/share/misc/termcap I haven't thought hard about whether adding DESTDIR like that would always fix the problem the right way. -- Ian From owner-svn-src-all@freebsd.org Sun Mar 12 03:00:22 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3E7A0D07146; Sun, 12 Mar 2017 03:00:22 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x242.google.com (mail-pf0-x242.google.com [IPv6:2607:f8b0:400e:c00::242]) (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 0BF321D15; Sun, 12 Mar 2017 03:00:22 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x242.google.com with SMTP id j5so15185839pfb.3; Sat, 11 Mar 2017 19:00:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=ok24xQy1vRtIRo9fh44lfRcECeaZoBRLzWgaA3ltyJQ=; b=vG/FuZjibcnd9Tjp9OhcuZM2C9rvdO7aJaI2Ws1cplvNht/Rz0qj6kRUo8EQIm+BQN rdDUdTEJeRioHQwjTDsLGZSNxMNPLSC/fclHIeP5NJGWMjc0JB2WM5OSpU1ZYViFA63s 9jvp6d3+s5/L/TL4Hpyr4xWjWePZqwj9x9cHpY7WzdROZDcWoVPnzV6d9HWxe9FbZ5zY cMPov/D/8rLapRhluX3gsV+SO7b8YiBfW6oiw7+lcS1aOBcnh/UREzSzb6inRSoCyLzc 0PfzY/aPJq/EPaLN/7Jm7V1nTcuKCi2SmmvnjJtLOxk1xqD/CNXdmOxSmPY2qjr8rsOn 232A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=ok24xQy1vRtIRo9fh44lfRcECeaZoBRLzWgaA3ltyJQ=; b=Y3CDw3/Og4C8O67VmA8OJJxccr5s//1ejHNlayxxxr71yq4KSyhFU7Tn7oN8wZ6XyX Ac9yW32MPzJaPVft23B2zNF5DKM5lS2HFQoiQ2zNdohv938aMEjvq6txHQWl6w/pa4nk Yt6trkxexjNbN0Jdwz/wjergg4s2I/hM5a70rRvExvWOQK4yerDWuSZCy0q+H7POPuQY /bPm2eLm/lFD8XtgmxZCFqGhjSe6DXfA3dNymRGokXuTsAmxeB9xHsb711EagNn9bc1e d2XQ67Mdo3GvlmcHPfYkejX+WAMTrfGP0ys1uzOJ5yNQV7FwM5w4ZFalKjiCXZtGTKRK kK1A== X-Gm-Message-State: AMke39kvYDWLtl24rt/n7ZI5m5T4sb6bt07dmG9GkDAfhGn3O2O1kIomJLtBNhv6E7BtJQ== X-Received: by 10.98.84.67 with SMTP id i64mr30389798pfb.44.1489287621315; Sat, 11 Mar 2017 19:00:21 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id g78sm26335615pfe.5.2017.03.11.19.00.20 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 19:00:20 -0800 (PST) Subject: Re: svn commit: r315091 - head/share/termcap Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_24BC341D-78D2-44F3-BBC5-79EC88AEDAE2"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703120037.v2C0bjdq045397@repo.freebsd.org> Date: Sat, 11 Mar 2017 19:00:19 -0800 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <58F3A212-D538-4D21-A2ED-29DB934CA040@gmail.com> References: <201703120037.v2C0bjdq045397@repo.freebsd.org> To: "Rodney W. Grimes" X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:00:22 -0000 --Apple-Mail=_24BC341D-78D2-44F3-BBC5-79EC88AEDAE2 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 11, 2017, at 16:37, Rodney W. Grimes = wrote: >=20 > Author: rgrimes > Date: Sun Mar 12 00:37:45 2017 > New Revision: 315091 > URL: https://svnweb.freebsd.org/changeset/base/315091 >=20 > Log: > Revert r314833 until the problem with INSTALL_RSYMLINKS can be found > as it appears to break arm release builds. >=20 > PR: 217705 > Reported by: cyclaero@gmail.com > Approved by: grehan (mentor) implict as reverting >=20 > Modified: > head/share/termcap/Makefile >=20 > Modified: head/share/termcap/Makefile > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/share/termcap/Makefile Sat Mar 11 22:34:02 2017 = (r315090) > +++ head/share/termcap/Makefile Sun Mar 12 00:37:45 2017 = (r315091) > @@ -24,6 +24,6 @@ termcap.db: termcap > cap_mkdb ${CAP_MKDB_ENDIAN} -f ${.TARGET:R} ${.ALLSRC} >=20 > etc-termcap: > - ${INSTALL_RSYMLINK} ${BINDIR}/misc/termcap = ${DESTDIR}/etc/termcap > + ${INSTALL_SYMLINK} ${BINDIR}/misc/termcap ${DESTDIR}/etc/termcap Rod, You needed to add ${DESTDIR} to both the source and the = destination target, as I=E2=80=99ve said more than once in other = reviews/emails. This is how install -l rs determines the relative path = from the source to the destination =E2=80=94 otherwise you=E2=80=99re = creating a relative path from ${BINDIR}/misc -> ${DESTDIR}/etc . Thanks, -Ngie --Apple-Mail=_24BC341D-78D2-44F3-BBC5-79EC88AEDAE2 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxLnEAAoJEPWDqSZpMIYVz+UP/38Oss3qGtfvWojwKljM+0fi K7onKbR+XjQ8qS1cVSFctOaX2OcJPLxKlxJ3tyb+mHxu+EvJrpPxIBRQ8KKBu0P1 p1k0WPGUBvAG4mlP6dt2uY51YzuMkVWPQlU2PtweMvPqb/2g36l6S3+bQs+57y8p R48dMXx0I8Z9sJl8AQktGQuJ6bq4w75Jn2VIpUUDvPJ/Jfp7fehX+mL3b8IT85lF BtrgXAIo5rs+rOd1K/WNyOyKnWi7pnWfIZuzWxEFdz/ZmmoFqO4YUwYy4EUwKylh ZixgounCMCAfUHgP8knLVDW2Qx8eGQIV3XazwWaa27f9Mlgdj7b2yMreNimgrZwC KJ8lDPUS/JcrQ9R9ybJcywK9tGwArOvoMYMPP0H/UKNQQA3w08JBju65Ti4o/Yxa rb+7Q65eom4sd1ZI6zFlYmBpUFc3akOBzkLIuBuy7QTZlonuwT8VN1MRxv0530E5 FOaGOsJe8dVDepqMjWzqgAcvIxfuv4UY189fFpZx/Gn8YBXayoptaTdbWq07PzNz Zl82DIcHsG1FNNuig4QnVfoWQoyuF1HXxJlcWYKOpw8OTNL0SFL8w6fcc+xlMySZ Hk1Ljrqdy6kvZS8W3Zb8jMpV77NJNJwF7+iVck0T1nNGPCiHN+5zwvZwQc8tHj+v Rerl3USh+qmyr0GG86bq =9jyF -----END PGP SIGNATURE----- --Apple-Mail=_24BC341D-78D2-44F3-BBC5-79EC88AEDAE2-- From owner-svn-src-all@freebsd.org Sun Mar 12 03:06:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3EBC6D077EC; Sun, 12 Mar 2017 03:06:04 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x241.google.com (mail-pf0-x241.google.com [IPv6:2607:f8b0:400e:c00::241]) (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 0AEB316D2; Sun, 12 Mar 2017 03:06:04 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x241.google.com with SMTP id o126so15215137pfb.1; Sat, 11 Mar 2017 19:06:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=F0tXN0X0Vix+nsuZE+19QpZX91o9by88OSeSnomhVSg=; b=SPOZJPJMWfJrcr7yS8dee1MRo7q0EqUcK/b7i9FsL1tbvBjbUrV614LlLWVhlzf2ur F1H+Lf1dOPosjhMypsSiqJcyjsTQNG0/OMMR3ZfSfyD4fpq3ImEdJFmSEijs8agwbYiO GbzF6ZyDEqZAdHqAiYCOCVWOcpPZcs30kRcGQulICtkcwykPA3wuzqnnQH5IHEU6hE2X H9fYr4f0d/8GlFzCrCHsPFWIhiM4JYZrT7kCDmwip4y75jDBDRoLlLmb5GpWVU6MAN6G 8vAawAoGS/lkJatLvc9wvJjpNFb5A9lVcUxGugqBOqBgsOme9iLpJA2XlS0Ey8SL+PGM 3KpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=F0tXN0X0Vix+nsuZE+19QpZX91o9by88OSeSnomhVSg=; b=HbNJzhRjvaTDXK8kL+B5hWLc+UkXMCctPn6L7QmSeDpzwTNgO3BbFX+SLvCE+h07fT bi2uHBtNJnjApnwfJAqayAw19E3VwiOjowOQDUVMh850EaL8RyVutejMMYeTWVbvodkN Tad0aFJEH2trqGF+ZSdd3dfTVn7o0Q37XvCEuyQ/V/uUurQAPjIgxovpUEY8dLdLtVPF 0JuLgj+N2CjFboDeXUdWbaRJ5wIMjgM8nJ2i35PUAgwGgD+w4To/8pS+6yuSRbOlQGjy 8T+SQhmDtKkOmr7Chx8e/XxFpX+YekspuDq8Zoky9i6/zo1F0EIz4TeMFom5UyqkCAv9 Yz+g== X-Gm-Message-State: AMke39kRT8rwa0LNpjpp5Zxxy7U883msw+K5mRStKW0gomXXjvXKwjN/unDESAvp/Md9Bg== X-Received: by 10.99.8.4 with SMTP id 4mr29161891pgi.204.1489287963472; Sat, 11 Mar 2017 19:06:03 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id i15sm26344019pfj.0.2017.03.11.19.06.02 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 19:06:02 -0800 (PST) Subject: Re: svn commit: r315091 - head/share/termcap Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_9AB7A29B-FDE6-4B97-9B25-B4218B992969"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <1489287453.40576.75.camel@freebsd.org> Date: Sat, 11 Mar 2017 19:06:02 -0800 Cc: "Rodney W. Grimes" , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <0EAE6C58-4573-4A71-97C8-0D672C814945@gmail.com> References: <201703120037.v2C0bjdq045397@repo.freebsd.org> <1489287453.40576.75.camel@freebsd.org> To: Ian Lepore X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:06:04 -0000 --Apple-Mail=_9AB7A29B-FDE6-4B97-9B25-B4218B992969 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 11, 2017, at 18:57, Ian Lepore wrote: =E2=80=A6 > In an arm build sandbox I ran "make distribution DESTDIR=3D/tmp/ian" = and > this is what happened with termcap: >=20 > --- etc-termcap --- > install -l rs /usr/share/misc/termcap /tmp/ian/etc/termcap > ... > revolution > file /tmp/ian/etc/termcap > /tmp/ian/etc/termcap: symbolic link to = ../../../usr/share/misc/termcap >=20 >=20 > Then I changed the rsymlink in share/termcap/Makefile to: >=20 > ${INSTALL_RSYMLINK} ${DESTDIR}/${BINDIR}/misc/termcap = ${DESTDIR}/etc/termcap >=20 > and it did the right thing: >=20 > --- etc-termcap --- > install -l rs /tmp/ian//usr/share/misc/termcap /tmp/ian/etc/termcap > ... > revolution > file /tmp/ian/etc/termcap > /tmp/ian/etc/termcap: symbolic link to ../usr/share/misc/termcap >=20 >=20 > I haven't thought hard about whether adding DESTDIR like that would > always fix the problem the right way. DESTDIR !=3D =E2=80=9C=E2=80=9D is the key point to triggering = the bug that was causing the failures I noted in my other email (it has = nothing to do with arm specifically). Rod=E2=80=99s code will only work = for DESTDIR =3D=3D =E2=80=9C=E2=80=9D. Thanks, -Ngie --Apple-Mail=_9AB7A29B-FDE6-4B97-9B25-B4218B992969 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxLsaAAoJEPWDqSZpMIYVNq4P/15F2TXTjynMO/EZAx2NGUDi 1ARd6dynMGxR+5uuiU910Rj010SyA6lodRAanZ4wLDNiXsTHbhf5smWGuIie/8yV rUss5AzUDS9dCHvCis3eOOm9F8uR48q712VBIvCiq9lhZhS2uzfSvsmQFsdVnTff VRwkGs/UrQ11ur30nePHqZLY+VThjHl03VvoNcnjrILbhi2EHSr9ArDPjSEx4Z0R i4rsh8nm8ckRWmtrCwCfVfV9tQCp3hK1GTEYXxXq1FdLmtgiTO/2kWF7Nutk4ZH1 HnvI/p8c4ty1gheo86Duu46UKH/KHn6L+qRahl1xdvoFAbWqrjEYUEABB/jKucqo +mBQT0VAhn6fDDs28Atm4ZtCJli83vsBI/1pD2BxuZTVwjXkc3MdALK+oel1cpsB WZcvTaNnbEcx5/trD2tDHK1fMZG2N+8pFTuLc0CeG/BFKcVIDnxKgkMukW4hEs0C JFdqqipAb3JiypzfYJXa+LOOuRzqwJZAYPxdiJvoCQ5R1VBywuTLwV8DcrA8R3nK eD5w3GfKaXCff8+DBQDaGOYPqWEkQYIU/qZ1JKdUHivty7WX/UDasfxt8qlIJeA6 RriNeOizPPSNI+UnlnzKpf2IMZ/b0v3TJ+BPFyMhpovpnBpYw0TVYXT2Mi37MMo+ YOyUwG7ZD1SUAE5O9Aen =Rh+E -----END PGP SIGNATURE----- --Apple-Mail=_9AB7A29B-FDE6-4B97-9B25-B4218B992969-- From owner-svn-src-all@freebsd.org Sun Mar 12 03:07:40 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 96B16D0787A; Sun, 12 Mar 2017 03:07:40 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail105.syd.optusnet.com.au (mail105.syd.optusnet.com.au [211.29.132.249]) by mx1.freebsd.org (Postfix) with ESMTP id 61D6E184D; Sun, 12 Mar 2017 03:07:39 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c122-106-153-191.carlnfd1.nsw.optusnet.com.au [122.106.153.191]) by mail105.syd.optusnet.com.au (Postfix) with ESMTPS id 4AAAB10439CF; Sun, 12 Mar 2017 14:07:33 +1100 (AEDT) Date: Sun, 12 Mar 2017 14:07:32 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Emmanuel Vadot cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315093 - in head/sys: amd64/conf conf i386/conf In-Reply-To: <201703120052.v2C0qH44053604@repo.freebsd.org> Message-ID: <20170312134913.W4632@besplex.bde.org> References: <201703120052.v2C0qH44053604@repo.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=VbSHBBh9 c=1 sm=1 tr=0 a=Tj3pCpwHnMupdyZSltBt7Q==:117 a=Tj3pCpwHnMupdyZSltBt7Q==:17 a=kj9zAlcOel0A:10 a=OCxMDMbtnObn2ko5xekA:9 a=CjuIK1q_8ugA:10 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:07:40 -0000 On Sun, 12 Mar 2017, Emmanuel Vadot wrote: > Log: > Remove i915drm and radeondrm from NOTES and conf. > This unbreak LINT kernel. i915kms is too broken to even be puttable in LINT, since it is not in conf/files*. Only 44 of 157 .c files in dev/drm2 are in conf/files*. It is puttable in NOTES as comments, but isn't. According to apropos, even old drm and radeon are not in any man page. I don't want modules, but when I tried to build some, new i915 had many more build errors than old i915, do to the bug that makeoptions in kernel config files doesn't work for modules and new i915 having more unportabilities affected by CC and CFLAGS. i915kms seemed to depend on lots of other modules that I don't want. With no NOTES, no dependency lists in conf/files* and no man page, it is hard to find which ones. Bruce From owner-svn-src-all@freebsd.org Sun Mar 12 03:22:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9989DD07C7D; Sun, 12 Mar 2017 03:22:19 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 505AF100B; Sun, 12 Mar 2017 03:22:19 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3MIq4016365; Sun, 12 Mar 2017 03:22:18 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3MIxW016364; Sun, 12 Mar 2017 03:22:18 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120322.v2C3MIxW016364@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 03:22:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315095 - head/lib/libc/gen X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:22:19 -0000 Author: pfg Date: Sun Mar 12 03:22:18 2017 New Revision: 315095 URL: https://svnweb.freebsd.org/changeset/base/315095 Log: libc: small cleanups. Rename nitems to numitems: it shares the anme with an existing macro in sys/params.h. Also initialize the value later which avoids asigning the value if we exit early. Reviewed by: ngie MFC after: 3 days Modified: head/lib/libc/gen/scandir.c Modified: head/lib/libc/gen/scandir.c ============================================================================== --- head/lib/libc/gen/scandir.c Sun Mar 12 02:21:16 2017 (r315094) +++ head/lib/libc/gen/scandir.c Sun Mar 12 03:22:18 2017 (r315095) @@ -82,7 +82,7 @@ scandir(const char *dirname, struct dire #endif { struct dirent *d, *p, **names = NULL; - size_t nitems = 0; + size_t numitems; long arraysz; DIR *dirp; @@ -94,6 +94,7 @@ scandir(const char *dirname, struct dire if (names == NULL) goto fail; + numitems = 0; while ((d = readdir(dirp)) != NULL) { if (select != NULL && !SELECT(d)) continue; /* just selected names */ @@ -112,7 +113,7 @@ scandir(const char *dirname, struct dire * Check to make sure the array has space left and * realloc the maximum size. */ - if (nitems >= arraysz) { + if (numitems >= arraysz) { struct dirent **names2; names2 = (struct dirent **)realloc((char *)names, @@ -124,22 +125,22 @@ scandir(const char *dirname, struct dire names = names2; arraysz *= 2; } - names[nitems++] = p; + names[numitems++] = p; } closedir(dirp); - if (nitems && dcomp != NULL) + if (numitems && dcomp != NULL) #ifdef I_AM_SCANDIR_B - qsort_b(names, nitems, sizeof(struct dirent *), (void*)dcomp); + qsort_b(names, numitems, sizeof(struct dirent *), (void*)dcomp); #else - qsort_r(names, nitems, sizeof(struct dirent *), + qsort_r(names, numitems, sizeof(struct dirent *), &dcomp, alphasort_thunk); #endif *namelist = names; - return (nitems); + return (numitems); fail: - while (nitems > 0) - free(names[--nitems]); + while (numitems > 0) + free(names[--numitems]); free(names); closedir(dirp); return (-1); From owner-svn-src-all@freebsd.org Sun Mar 12 03:26:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 726B6D07D1D; Sun, 12 Mar 2017 03:26:26 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 421CE11CF; Sun, 12 Mar 2017 03:26:26 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3QP3e016564; Sun, 12 Mar 2017 03:26:25 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3QPVb016563; Sun, 12 Mar 2017 03:26:25 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120326.v2C3QPVb016563@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 03:26:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315096 - head/lib/libc/gen X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:26:26 -0000 Author: pfg Date: Sun Mar 12 03:26:25 2017 New Revision: 315096 URL: https://svnweb.freebsd.org/changeset/base/315096 Log: libc: small cleanups. Unsign setlen: it is local and will never be negative. Having one more bit for growth is beneficial and it avoids a cast when it's going to be used for allocation. Reviewed by: ngie MFC after: 3 days Modified: head/lib/libc/gen/setmode.c Modified: head/lib/libc/gen/setmode.c ============================================================================== --- head/lib/libc/gen/setmode.c Sun Mar 12 03:22:18 2017 (r315095) +++ head/lib/libc/gen/setmode.c Sun Mar 12 03:26:25 2017 (r315096) @@ -175,7 +175,7 @@ setmode(const char *p) mode_t mask, perm, permXbits, who; long perml; int equalopdone; - int setlen; + u_int setlen; if (!*p) { errno = EINVAL; @@ -190,7 +190,7 @@ setmode(const char *p) setlen = SET_LEN + 2; - if ((set = malloc((u_int)(sizeof(BITCMD) * setlen))) == NULL) + if ((set = malloc(setlen * sizeof(BITCMD))) == NULL) return (NULL); saveset = set; endset = set + (setlen - 2); From owner-svn-src-all@freebsd.org Sun Mar 12 03:29:24 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 564BCD07DC2; Sun, 12 Mar 2017 03:29:24 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2613C1359; Sun, 12 Mar 2017 03:29:24 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3TNuX016756; Sun, 12 Mar 2017 03:29:23 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3TNg5016755; Sun, 12 Mar 2017 03:29:23 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120329.v2C3TNg5016755@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 03:29:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315097 - head/lib/libc/iconv X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:29:24 -0000 Author: pfg Date: Sun Mar 12 03:29:23 2017 New Revision: 315097 URL: https://svnweb.freebsd.org/changeset/base/315097 Log: libc: small cleanups. Remove unused initialization: "num" is properly defined before use. Reviewed by: ngie MFC after: 3 days Modified: head/lib/libc/iconv/citrus_esdb.c Modified: head/lib/libc/iconv/citrus_esdb.c ============================================================================== --- head/lib/libc/iconv/citrus_esdb.c Sun Mar 12 03:26:25 2017 (r315096) +++ head/lib/libc/iconv/citrus_esdb.c Sun Mar 12 03:29:23 2017 (r315097) @@ -263,8 +263,6 @@ _citrus_esdb_get_list(char ***rlist, siz size_t num; int ret; - num = 0; - ret = _lookup_seq_open(&cla, _PATH_ESDB "/" ESDB_ALIAS, _LOOKUP_CASE_IGNORE); if (ret) From owner-svn-src-all@freebsd.org Sun Mar 12 03:29:50 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E489CD07E5A; Sun, 12 Mar 2017 03:29:50 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B44D41501; Sun, 12 Mar 2017 03:29:50 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3Tnu1016830; Sun, 12 Mar 2017 03:29:49 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3TnKO016829; Sun, 12 Mar 2017 03:29:49 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120329.v2C3TnKO016829@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 03:29:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315098 - head/usr.bin/xinstall/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:29:51 -0000 Author: ngie Date: Sun Mar 12 03:29:49 2017 New Revision: 315098 URL: https://svnweb.freebsd.org/changeset/base/315098 Log: Clarify src vs dest path mismatch in :symbolic_link_{absolute,relative}_body Unfortunately kyua does not omit the path mismatch on failure, so it must be coded into the error message. Cache the values, run the test(1) call, then print out the values in an atf_fail call to emit the required diagnostics to debug why things are failing. MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/usr.bin/xinstall/tests/install_test.sh Modified: head/usr.bin/xinstall/tests/install_test.sh ============================================================================== --- head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 03:29:23 2017 (r315097) +++ head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 03:29:49 2017 (r315098) @@ -283,7 +283,11 @@ symbolic_link_absolute_body() { atf_check install -l sa testf copyf [ testf -ef copyf ] || atf_fail "not same file" [ -L copyf ] || atf_fail "copy is not symlink" - [ "$(readlink copyf)" = "$(pwd -P)/testf" ] || atf_fail "unexpected symlink contents" + copyf_path=$(readlink copyf) + testf_path="$(pwd -P)/testf" + if [ "$copyf_path" != "$testf_path" ]; then + atf_fail "unexpected symlink ('$copyf_path' != '$testf_path')" + fi } atf_test_case symbolic_link_relative @@ -292,7 +296,11 @@ symbolic_link_relative_body() { atf_check install -l sr testf copyf [ testf -ef copyf ] || atf_fail "not same file" [ -L copyf ] || atf_fail "copy is not symlink" - [ "$(readlink copyf)" = "testf" ] || atf_fail "unexpected symlink contents" + copyf_path=$(readlink copyf) + testf_path="testf" + if [ "$copyf_path" != "$testf_path" ]; then + atf_fail "unexpected symlink ('$copyf_path' != '$testf_path')" + fi } atf_test_case mkdir_simple From owner-svn-src-all@freebsd.org Sun Mar 12 03:33:22 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 16569D08011; Sun, 12 Mar 2017 03:33:22 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CCD081952; Sun, 12 Mar 2017 03:33:21 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3XK4C020635; Sun, 12 Mar 2017 03:33:20 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3XKfV020634; Sun, 12 Mar 2017 03:33:20 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120333.v2C3XKfV020634@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:33:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315099 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:33:22 -0000 Author: bapt Date: Sun Mar 12 03:33:20 2017 New Revision: 315099 URL: https://svnweb.freebsd.org/changeset/base/315099 Log: Fix native-xtools after replacement of GNU diff Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 ============================================================================== --- head/Makefile.inc1 Sun Mar 12 03:29:49 2017 (r315098) +++ head/Makefile.inc1 Sun Mar 12 03:33:20 2017 (r315099) @@ -1936,7 +1936,7 @@ native-xtools: .PHONY ${_clang} \ sbin/md5 \ sbin/sysctl \ - gnu/usr.bin/diff \ + usr.bin/diff \ usr.bin/awk \ usr.bin/basename \ usr.bin/bmake \ From owner-svn-src-all@freebsd.org Sun Mar 12 03:35:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3C262D0807C; Sun, 12 Mar 2017 03:35:03 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0BE131ACE; Sun, 12 Mar 2017 03:35:02 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3Z2iq020757; Sun, 12 Mar 2017 03:35:02 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3Z2vZ020755; Sun, 12 Mar 2017 03:35:02 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120335.v2C3Z2vZ020755@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:35:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315100 - in head: . share/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:35:03 -0000 Author: bapt Date: Sun Mar 12 03:35:01 2017 New Revision: 315100 URL: https://svnweb.freebsd.org/changeset/base/315100 Log: Finish removal of WITHOUT_MANDOCDB Modified: head/ObsoleteFiles.inc head/share/mk/src.opts.mk Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Sun Mar 12 03:33:20 2017 (r315099) +++ head/ObsoleteFiles.inc Sun Mar 12 03:35:01 2017 (r315100) @@ -38,6 +38,8 @@ # xargs -n1 | sort | uniq -d; # done +# 20170311: Remove WITHOUT_MANDOCDB option +OLD_FILES=/usr/share/man/man1/makewhatis.1.gz # 20170311: remove GNU diff OLD_FILES+=usr/share/man/man7/diff.7.gz # 20170308: rename some tests Modified: head/share/mk/src.opts.mk ============================================================================== --- head/share/mk/src.opts.mk Sun Mar 12 03:33:20 2017 (r315099) +++ head/share/mk/src.opts.mk Sun Mar 12 03:35:01 2017 (r315100) @@ -131,7 +131,6 @@ __DEFAULT_YES_OPTIONS = \ MAIL \ MAILWRAPPER \ MAKE \ - MANDOCDB \ NDIS \ NETCAT \ NETGRAPH \ From owner-svn-src-all@freebsd.org Sun Mar 12 03:35:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B820BD080DD; Sun, 12 Mar 2017 03:35:49 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x241.google.com (mail-pf0-x241.google.com [IPv6:2607:f8b0:400e:c00::241]) (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 856B91C4C; Sun, 12 Mar 2017 03:35:49 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x241.google.com with SMTP id v190so15251847pfb.0; Sat, 11 Mar 2017 19:35:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=PlcMZVYiKqr8b1xxqIyEu24i/pK7yKo1VOHz0cSEjds=; b=HdW3Ofhejv4tl/7fcrc0gr4cPwbjlIzTysNnMt1I1Z/kAm0F/fobhdEMFTq/ux3Gah qr909fEXq7uCoKzBHPBvXp6L52Y+7PtzGXvQq8Xtrp9BWw9BuFq3xx354I9Lqhw+F93b NtkxQVLPLhZNyF4LO6nB776sTHvHHiJftFI+ZP2aTI42JPt5Ql/3K6fgE/T0vk9DUKQA hX3PfGjP1H6jRpoV45/7JeFiesWYg4bVJ/sI6gk19cI5wv4WA8sXLzX9xN45QfPKulGU 2yqs9NqMKvfVbhpWrYgNJypzJN/50HaegAAegAGTC6Ofozx4Z0HOZFRfyR07i7mCilum obFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=PlcMZVYiKqr8b1xxqIyEu24i/pK7yKo1VOHz0cSEjds=; b=ZdQLFuLsKhp57jBIw3ykgCmbe6MnDtQX7arqvpXbKBAQX1kopJz8MYb1WcF7T261EK 5/3etoUhIke1oxJdHM/HeubelATvqIIYnTwtW4xSmryt1nk4t27Bf8i+MVnoTVd926nV apGg0ZUrbPa+FjJDA8KtBhNiskdy5HAcKHbkeM5dV+llF1U+b8/hreB+1fjJB0rFmk+0 zzuH0VofHjqpbYgc2R4OXwZInk8rp/ZQroBRYVMc6anV7gQt82JqPKH7WIBmVJFeFqjg 7dEK9mmZ+vMjBVBxqthmZXMXSHO7m34Cf+mhGLala5JeQPS7WnL8S268mQkqCWi0jYK8 6VQw== X-Gm-Message-State: AMke39lmOt8V9kibK6Jq5q18UdjsyS8XxNdSOEPMpdxh8kDXZuIYd+TzJhnxPLqKdXdlkQ== X-Received: by 10.99.154.9 with SMTP id o9mr29509718pge.69.1489289748933; Sat, 11 Mar 2017 19:35:48 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id g29sm26397925pfg.37.2017.03.11.19.35.48 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 19:35:48 -0800 (PST) Subject: Re: svn commit: r315100 - in head: . share/mk Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_FA76B0E4-B7DC-4A1C-BEE7-7E039471C489"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703120335.v2C3Z2vZ020755@repo.freebsd.org> Date: Sat, 11 Mar 2017 19:35:47 -0800 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <32D8FF24-5239-4524-8BA1-F4D6284A5926@gmail.com> References: <201703120335.v2C3Z2vZ020755@repo.freebsd.org> To: Baptiste Daroussin X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:35:49 -0000 --Apple-Mail=_FA76B0E4-B7DC-4A1C-BEE7-7E039471C489 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On Mar 11, 2017, at 19:35, Baptiste Daroussin = wrote: >=20 > Author: bapt > Date: Sun Mar 12 03:35:01 2017 > New Revision: 315100 > URL: https://svnweb.freebsd.org/changeset/base/315100 >=20 > Log: > Finish removal of WITHOUT_MANDOCDB >=20 > Modified: > head/ObsoleteFiles.inc > head/share/mk/src.opts.mk >=20 > Modified: head/ObsoleteFiles.inc > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/ObsoleteFiles.inc Sun Mar 12 03:33:20 2017 = (r315099) > +++ head/ObsoleteFiles.inc Sun Mar 12 03:35:01 2017 = (r315100) > @@ -38,6 +38,8 @@ > # xargs -n1 | sort | uniq -d; > # done >=20 > +# 20170311: Remove WITHOUT_MANDOCDB option > +OLD_FILES=3D/usr/share/man/man1/makewhatis.1.gz Bad leading slash. -Ngie --Apple-Mail=_FA76B0E4-B7DC-4A1C-BEE7-7E039471C489 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxMITAAoJEPWDqSZpMIYV6YAQAKfAe7HVkioI5eGSWQwbCLe/ HZUYDEN8Kio5ojKBEuIROkWA5cjufCrrjSiMc9fKswuXQlZPA9IQg6uwKG0HAN+v s7TqXc7uL6QvzNKghI7dkeduNPdou2Nt/trc1ArT5c0uacWKs7JJmDf1TzudJ5rP QIMDv8Lut8mpuuzr8oTqCzL0YDjGaDXlohZup0fbtg6gR4XqxahrdAM4RyAvSbrJ 7CiOVVG0RRBEmeLsWZFwqtF5O0Jqkj7a+/RGD3JQY3h2dGlGr+8Or1TM00+kYmDz ahL+oYsvvofmuLvZG17oMH7Yjd5MbmK39fyd9XMqbjM4GcxGhKCpGjNkoxOFeGvd g1Fj71SCJVnHaMGmg1Dfa1kPS0ki6OfNQbrcddA5ALvowl0gd8Rt/r5SS8lgKvw0 lIxy4oZ6QpIh0aAylJ750RwM4ma93Mukgy9RzU9tIwEFPiBe2kXBsXU0zGrAtsVS 2mDqTryjeGk3QjiT205RW9th2KZBYy+9FYcweTVuUFYYkWWIkFITunScvD4D8FBX XsGyqxYbp8wobQ/ViVM4QMZCdnndY6GP5zcQp/gMndUBk+ZQUz6qnsV0gJ1Bk+Xo /c1kggx6m1pQxHJQYq3SQBLZEAHN4zsVHgMnyD1v5AZrDsNYGDIFrxczDja0hCWn Y06YklSwD6bWEhuJ9dh2 =fzES -----END PGP SIGNATURE----- --Apple-Mail=_FA76B0E4-B7DC-4A1C-BEE7-7E039471C489-- From owner-svn-src-all@freebsd.org Sun Mar 12 03:36:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3AA5AD0816F; Sun, 12 Mar 2017 03:36:35 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 07DCB1DCC; Sun, 12 Mar 2017 03:36:34 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3aYAU020858; Sun, 12 Mar 2017 03:36:34 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3aY30020857; Sun, 12 Mar 2017 03:36:34 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120336.v2C3aY30020857@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:36:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315101 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:36:35 -0000 Author: bapt Date: Sun Mar 12 03:36:33 2017 New Revision: 315101 URL: https://svnweb.freebsd.org/changeset/base/315101 Log: Fix wrong date in diff(1) Reported by: rgrimes Modified: head/usr.bin/diff/diff.1 Modified: head/usr.bin/diff/diff.1 ============================================================================== --- head/usr.bin/diff/diff.1 Sun Mar 12 03:35:01 2017 (r315100) +++ head/usr.bin/diff/diff.1 Sun Mar 12 03:36:33 2017 (r315101) @@ -30,7 +30,7 @@ .\" @(#)diff.1 8.1 (Berkeley) 6/30/93 .\" $FreeBSD$ .\" -.Dd Septembr 03, 2017 +.Dd March 11, 2017 .Dt DIFF 1 .Os .Sh NAME From owner-svn-src-all@freebsd.org Sun Mar 12 03:43:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 40792D0837F; Sun, 12 Mar 2017 03:43:30 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0CEFF125E; Sun, 12 Mar 2017 03:43:29 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3hTWs024838; Sun, 12 Mar 2017 03:43:29 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3hTIL024837; Sun, 12 Mar 2017 03:43:29 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201703120343.v2C3hTIL024837@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Sun, 12 Mar 2017 03:43:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315102 - head/usr.sbin/bsnmpd/modules/snmp_hostres X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:43:30 -0000 Author: araujo Date: Sun Mar 12 03:43:28 2017 New Revision: 315102 URL: https://svnweb.freebsd.org/changeset/base/315102 Log: Use nitems() from sys/param.h. Reviewed by: ngie Differential Revision: https://reviews.freebsd.org/D9943 Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c Modified: head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c ============================================================================== --- head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c Sun Mar 12 03:36:33 2017 (r315101) +++ head/usr.sbin/bsnmpd/modules/snmp_hostres/hostres_fs_tbl.c Sun Mar 12 03:43:28 2017 (r315102) @@ -143,7 +143,7 @@ static const struct { { "hpfs", &OIDX_hrFSHPFS_c }, { "smbfs", &OIDX_hrFSOther_c }, }; -#define N_FS_TYPE_MAP (sizeof(fs_type_map) / sizeof(fs_type_map[0])) +#define N_FS_TYPE_MAP nitems(fs_type_map) /** * Create an entry into the FS table and an entry in the map (if needed). From owner-svn-src-all@freebsd.org Sun Mar 12 03:46:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C26C6D084BC; Sun, 12 Mar 2017 03:46:41 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x22f.google.com (mail-pg0-x22f.google.com [IPv6:2607:f8b0:400e:c05::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 881B71437; Sun, 12 Mar 2017 03:46:41 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x22f.google.com with SMTP id 25so52166632pgy.0; Sat, 11 Mar 2017 19:46:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=kLjEi8lA2WJ6kxLIWBXSRsE9yOlfHQJcKiz7uDZSOws=; b=p5blGvdynrwRERh+9G9bd4St65iw8RtIRTAwzQmWRHn2uDz+A+NiSqHAkiBbflOX0J W4/yjjseticmcF+iY7QCtooWfPguqlVxMpCBDkejgtMgag9CMZSV6Q5mJ8mL1yy+9sAn 1J478r28ASZiY/p1i4xVxikEPATziwYIB4Q29rvjGWM2/jj49rqaeaGFR36+/GeRIbk5 2PtzY8fYI7cN77sU666LinsTM9KK7qPvY+ksWFujeDwYqr4dAmLknm7bZnoheUeHGSJy g4Ly5aeDrOmQZNTigUV3ipq7MXIpdfGL12PCJ4vI3skkdRYBcglZaFC4T/c4+BYv9BYb XAYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=kLjEi8lA2WJ6kxLIWBXSRsE9yOlfHQJcKiz7uDZSOws=; b=thiDBP0tnPnUbqp7MOvpaWClneMWnl2h/OMM0RsiaU8NugFV0IdxBkefaYDoNr+cUK eRP1XsSCGCwaZ9Nf66qlX7jALmM+QFTP4h2OBat8Sq5z4AHsJOi5MaLbVhT2rktqkIxM wU7PTWmDGpSVGuZaXcN7/0Udir752GWTM/S+mhucLMPy1nKUqHaXH1ZvXgocAnOxasWP N/dRwObf4RItTp/vEJwYsToXJtDL3PvawHGuFfJTsm+M5Vb7MIW3lIWC7LJpw10O/j0r 14e967zliuA5oFUn/XVbq+oAzK0TRM88X4JsMb2wyMFJFwlfzDS46pYqhhTb/sBCzdlw xvKw== X-Gm-Message-State: AMke39mIfvIy0S6YhBn17XzBWpPlMoO2Xz2d3RKURVxKHwOKUpUwYEqFDSZvLmQkP4m/Ng== X-Received: by 10.84.232.72 with SMTP id f8mr36831626pln.85.1489290400960; Sat, 11 Mar 2017 19:46:40 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id d63sm26340451pfg.132.2017.03.11.19.46.40 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 19:46:40 -0800 (PST) Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_8C620D9C-1AA0-475D-894B-2D8BB011CD0B"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703110501.v2B51UJQ045535@repo.freebsd.org> Date: Sat, 11 Mar 2017 19:46:39 -0800 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703110501.v2B51UJQ045535@repo.freebsd.org> To: Baptiste Daroussin X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:46:41 -0000 --Apple-Mail=_8C620D9C-1AA0-475D-894B-2D8BB011CD0B Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On Mar 10, 2017, at 21:01, Baptiste Daroussin = wrote: >=20 > Author: bapt > Date: Sat Mar 11 05:01:29 2017 > New Revision: 315051 > URL: https://svnweb.freebsd.org/changeset/base/315051 >=20 > Log: > Import diff from OpenBSD and remove GNU diff >=20 > Some of the modifications from the previous summer of code has been = integrated > Modification for compatibility with GNU diff output has been added >=20 > Main difference with OpenBSD: > Implement multiple GNU diff options: > * --ignore-file-name-case > * --no-ignore-file-name-case > * --normal > * --tabsize > * --strip-trailing-cr > Make diff -p compatible with GNU diff > Implement diff -l > Make diff -r compatible with GNU diff >=20 > Capsicumize diffing 2 regular files > Add a simple test suite >=20 > Approved by: AsiaBSDcon devsummit > Obtained from: OpenBSD, GSoC > Relnotes: yes >=20 > Added: > head/usr.bin/diff/ > head/usr.bin/diff/Makefile (contents, props changed) > head/usr.bin/diff/TODO (contents, props changed) > head/usr.bin/diff/diff.1 (contents, props changed) > head/usr.bin/diff/diff.c (contents, props changed) > head/usr.bin/diff/diff.h (contents, props changed) > head/usr.bin/diff/diffdir.c (contents, props changed) > head/usr.bin/diff/diffreg.c (contents, props changed) > head/usr.bin/diff/tests/ > head/usr.bin/diff/tests/Makefile (contents, props changed) > head/usr.bin/diff/tests/diff.sh (contents, props changed) > head/usr.bin/diff/tests/input1.in (contents, props changed) > head/usr.bin/diff/tests/input2.in (contents, props changed) > head/usr.bin/diff/tests/input_c1.in (contents, props changed) > head/usr.bin/diff/tests/input_c2.in (contents, props changed) > head/usr.bin/diff/tests/simple.out (contents, props changed) > head/usr.bin/diff/tests/simple_b.out (contents, props changed) > head/usr.bin/diff/tests/simple_e.out (contents, props changed) > head/usr.bin/diff/tests/simple_i.out (contents, props changed) > head/usr.bin/diff/tests/simple_n.out (contents, props changed) > head/usr.bin/diff/tests/simple_p.out (contents, props changed) > head/usr.bin/diff/tests/simple_u.out (contents, props changed) > head/usr.bin/diff/tests/simple_w.out (contents, props changed) > head/usr.bin/diff/tests/unified_9999.out (contents, props changed) > head/usr.bin/diff/tests/unified_c9999.out (contents, props changed) > head/usr.bin/diff/tests/unified_p.out (contents, props changed) > head/usr.bin/diff/xmalloc.c (contents, props changed) > head/usr.bin/diff/xmalloc.h (contents, props changed) > Deleted: > head/gnu/usr.bin/diff/ > Modified: > head/ObsoleteFiles.inc > head/UPDATING > head/gnu/usr.bin/Makefile > head/usr.bin/Makefile Hi Baptiste, This change fails with gcc riscv due to some -Wunused errors: = https://ci.freebsd.org/job/FreeBSD-head-riscv64-build/697/console . Thanks, -Ngie --Apple-Mail=_8C620D9C-1AA0-475D-894B-2D8BB011CD0B Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxMSfAAoJEPWDqSZpMIYVaysP/1kebQmRPDl9Jhpu0gdcxiMk 3m/BhjYFsb4lHDz4LL7TICaU6yfGUdly5/EZpIIRPO4EInCeDD+8SE0kVuzMEL1i 1cW6k+TX8gylqJoNG34+As0fj4/jHXeDmQhFrcAlAdVKXZ2G34MXdYEYD2txOcfl V/YYOomt72ej8BtieUBTp1hA5fmkklwYpSh8CiwRvqVRfV6XyBIKTkC8rap7QSze 0bmD5Q4bWtApSgE++TjPTl7l0HFqggvHAR0eUmorO4kYZWUDvAyRcSu6Zepfz5xX e7sUfMZrdBIArGiU3dX45UVbtYX/7OVNSE7jwWSQ1NnjiU+ML2B+m1UaG3LGZina S+8R4ZPVL8RWDDPCsStwjzOGxaIXjoU9DcM/Jo/NC5hVQLGGdVWtAo7cqStsSxYy AvxULA60AYJWKjJcf8Cb8p1HjG6WeECdu1YmYSWdOnumxplSOkOrS45kWyX8ICCG vGHn9q7Pqw9BkXP2pENkYf51ggAYdqKYMTD3fABr0URWh+i4Hub2EGfqKtCDb/pl ZTNU+Wm0rbziGbdpOIo8JBwwsiDj7CbU6qv8p01nx1ZOfkHE2Kcv0Ri7lgSSUl6u 26/HIlfrI1ZAuIgqBWkfT6X3vPfbvnCHh0ICGO447g6BKfcFYpi8l6XWV+feTWz0 fYHT6qu7faeXkahJFN// =XNF6 -----END PGP SIGNATURE----- --Apple-Mail=_8C620D9C-1AA0-475D-894B-2D8BB011CD0B-- From owner-svn-src-all@freebsd.org Sun Mar 12 03:49:07 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0A617D08603; Sun, 12 Mar 2017 03:49:07 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CBA801616; Sun, 12 Mar 2017 03:49:06 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3n5qG025103; Sun, 12 Mar 2017 03:49:05 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3n5gK025102; Sun, 12 Mar 2017 03:49:05 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120349.v2C3n5gK025102@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:49:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315103 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:49:07 -0000 Author: bapt Date: Sun Mar 12 03:49:05 2017 New Revision: 315103 URL: https://svnweb.freebsd.org/changeset/base/315103 Log: Implement a stub --horizon-lines=NUM for compatibility with GNU diff3 some options of GNU diff3 would call diff with --horizon-lines, rcs is depending on that. Reported by: antoine Modified: head/usr.bin/diff/diff.c Modified: head/usr.bin/diff/diff.c ============================================================================== --- head/usr.bin/diff/diff.c Sun Mar 12 03:43:28 2017 (r315102) +++ head/usr.bin/diff/diff.c Sun Mar 12 03:49:05 2017 (r315103) @@ -54,6 +54,7 @@ enum { OPT_IGN_FN_CASE, OPT_NO_IGN_FN_CASE, OPT_NORMAL, + OPT_HORIZON_LINES, }; static struct option longopts[] = { @@ -83,6 +84,7 @@ static struct option longopts[] = { { "exclude", required_argument, 0, 'x' }, { "exclude-from", required_argument, 0, 'X' }, { "ignore-file-name-case", no_argument, NULL, OPT_IGN_FN_CASE }, + { "horizon-lines", required_argument, NULL, OPT_HORIZON_LINES }, { "no-ignore-file-name-case", no_argument, NULL, OPT_NO_IGN_FN_CASE }, { "normal", no_argument, NULL, OPT_NORMAL }, { "strip-trailing-cr", no_argument, NULL, OPT_STRIPCR }, @@ -225,6 +227,8 @@ main(int argc, char **argv) case 'x': push_excludes(optarg); break; + case OPT_HORIZON_LINES: + break; /* XXX TODO for compatibility with GNU diff3 */ case OPT_IGN_FN_CASE: ignore_file_case = 1; break; From owner-svn-src-all@freebsd.org Sun Mar 12 03:50:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F0B7DD08746; Sun, 12 Mar 2017 03:50:14 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C07F6177D; Sun, 12 Mar 2017 03:50:14 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3oDmF025208; Sun, 12 Mar 2017 03:50:13 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3oDwP025207; Sun, 12 Mar 2017 03:50:13 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120350.v2C3oDwP025207@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 03:50:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315104 - head/lib/libc/stdio X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:50:15 -0000 Author: pfg Date: Sun Mar 12 03:50:13 2017 New Revision: 315104 URL: https://svnweb.freebsd.org/changeset/base/315104 Log: libc: small cleanup. Initialize newsize in the code section so we avoids asigning the value if we exit early. Modified: head/lib/libc/stdio/printf-pos.c Modified: head/lib/libc/stdio/printf-pos.c ============================================================================== --- head/lib/libc/stdio/printf-pos.c Sun Mar 12 03:49:05 2017 (r315103) +++ head/lib/libc/stdio/printf-pos.c Sun Mar 12 03:50:13 2017 (r315104) @@ -641,12 +641,13 @@ __grow_type_table(struct typetable *type enum typeid *const oldtable = types->table; const int oldsize = types->tablesize; enum typeid *newtable; - u_int n, newsize = oldsize * 2; + u_int n, newsize; /* Detect overflow */ if (types->nextarg > NL_ARGMAX) return (-1); + newsize = oldsize * 2; if (newsize < types->nextarg + 1) newsize = types->nextarg + 1; if (oldsize == STATIC_ARG_TBL_SIZE) { From owner-svn-src-all@freebsd.org Sun Mar 12 03:53:42 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 712ADD0897E; Sun, 12 Mar 2017 03:53:42 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3A8571C5F; Sun, 12 Mar 2017 03:53:42 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3rfZW029114; Sun, 12 Mar 2017 03:53:41 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3rfYT029113; Sun, 12 Mar 2017 03:53:41 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120353.v2C3rfYT029113@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:53:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315105 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:53:42 -0000 Author: bapt Date: Sun Mar 12 03:53:41 2017 New Revision: 315105 URL: https://svnweb.freebsd.org/changeset/base/315105 Log: Fix bad latest entry Reported by: ngie Modified: head/ObsoleteFiles.inc Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Sun Mar 12 03:50:13 2017 (r315104) +++ head/ObsoleteFiles.inc Sun Mar 12 03:53:41 2017 (r315105) @@ -39,7 +39,7 @@ # done # 20170311: Remove WITHOUT_MANDOCDB option -OLD_FILES=/usr/share/man/man1/makewhatis.1.gz +OLD_FILES+=usr/share/man/man1/makewhatis.1.gz # 20170311: remove GNU diff OLD_FILES+=usr/share/man/man7/diff.7.gz # 20170308: rename some tests From owner-svn-src-all@freebsd.org Sun Mar 12 03:58:55 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 70585D08A97; Sun, 12 Mar 2017 03:58:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 42DE81E1C; Sun, 12 Mar 2017 03:58:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3wsOY029360; Sun, 12 Mar 2017 03:58:54 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3wsKW029359; Sun, 12 Mar 2017 03:58:54 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120358.v2C3wsKW029359@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 03:58:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315106 - head/usr.bin/xinstall/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:58:55 -0000 Author: ngie Date: Sun Mar 12 03:58:54 2017 New Revision: 315106 URL: https://svnweb.freebsd.org/changeset/base/315106 Log: Add 3 more testcases demonstrating how install -l sr works The additional testcases use absolute paths for sources and targets, as the other testcase which tested `-l sr` used flat relative paths in the same directory. Please note that these testcases do not test `-l a` -- that's already addressed in the battery of tests. MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/usr.bin/xinstall/tests/install_test.sh Modified: head/usr.bin/xinstall/tests/install_test.sh ============================================================================== --- head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 03:53:41 2017 (r315105) +++ head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 03:58:54 2017 (r315106) @@ -303,6 +303,69 @@ symbolic_link_relative_body() { fi } +atf_test_case symbolic_link_relative_absolute_source_and_dest1 +symbolic_link_relative_absolute_source_and_dest1_head() { + atf_set "descr" "Verify -l rs with absolute paths (.../copyf -> .../a/b/c/testf)" +} +symbolic_link_relative_absolute_source_and_dest1_body() { + src_path=a/b/c/testf + src_path_prefixed=$PWD/$src_path + dest_path=$PWD/copyf + + atf_check mkdir -p a/b/c + atf_check touch $src_path + atf_check install -l sr $src_path_prefixed $dest_path + [ $src_path_prefixed -ef $dest_path ] || atf_fail "not same file" + [ -L $dest_path ] || atf_fail "copy is not symlink" + dest_path_relative=$(readlink $dest_path) + src_path_relative="$src_path" + if [ "$src_path_relative" != "$dest_path_relative" ]; then + atf_fail "unexpected symlink contents ('$src_path_relative' != '$dest_path_relative')" + fi +} + +atf_test_case symbolic_link_relative_absolute_source_and_dest1_double_slash +symbolic_link_relative_absolute_source_and_dest1_double_slash_head() { + atf_set "descr" "Verify -l rs with absolute paths (.../copyf -> .../a/b/c/testf), using double-slashes" +} +symbolic_link_relative_absolute_source_and_dest1_double_slash_body() { + src_path=a//b//c//testf + src_path_prefixed=$PWD/$src_path + dest_path=$PWD/copyf + + atf_check mkdir -p a/b/c + atf_check touch $src_path + atf_check install -l sr $src_path_prefixed $dest_path + [ $src_path_prefixed -ef $dest_path ] || atf_fail "not same file" + [ -L $dest_path ] || atf_fail "copy is not symlink" + dest_path_relative=$(readlink $dest_path) + src_path_relative="$(echo $src_path | sed -e 's,//,/,g')" + if [ "$src_path_relative" != "$dest_path_relative" ]; then + atf_fail "unexpected symlink contents ('$src_path_relative' != '$dest_path_relative')" + fi +} + +atf_test_case symbolic_link_relative_absolute_source_and_dest2 +symbolic_link_relative_absolute_source_and_dest2_head() { + atf_set "descr" "Verify -l rs with absolute paths (.../a/b/c/copyf -> .../testf)" +} +symbolic_link_relative_absolute_source_and_dest2_body() { + src_path=testf + src_path_prefixed=$PWD/$src_path + dest_path=$PWD/a/b/c/copyf + + atf_check mkdir -p a/b/c + atf_check touch $src_path + atf_check install -l sr $src_path_prefixed $dest_path + [ $src_path_prefixed -ef $dest_path ] || atf_fail "not same file" + [ -L $dest_path ] || atf_fail "copy is not symlink" + dest_path_relative=$(readlink $dest_path) + src_path_relative="../../../$src_path" + if [ "$src_path_relative" != "$dest_path_relative" ]; then + atf_fail "unexpected symlink contents ('$src_path_relative' != '$dest_path_relative')" + fi +} + atf_test_case mkdir_simple mkdir_simple_body() { atf_check install -d dir1/dir2 @@ -349,5 +412,8 @@ atf_init_test_cases() { atf_add_test_case symbolic_link atf_add_test_case symbolic_link_absolute atf_add_test_case symbolic_link_relative + atf_add_test_case symbolic_link_relative_absolute_source_and_dest1 + atf_add_test_case symbolic_link_relative_absolute_source_and_dest1_double_slash + atf_add_test_case symbolic_link_relative_absolute_source_and_dest2 atf_add_test_case mkdir_simple } From owner-svn-src-all@freebsd.org Sun Mar 12 04:04:17 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E8184D08CBC; Sun, 12 Mar 2017 04:04:17 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9DD4912AE; Sun, 12 Mar 2017 04:04:17 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C44G1N033089; Sun, 12 Mar 2017 04:04:16 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C44GZZ033087; Sun, 12 Mar 2017 04:04:16 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120404.v2C44GZZ033087@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 04:04:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315107 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:04:18 -0000 Author: bapt Date: Sun Mar 12 04:04:16 2017 New Revision: 315107 URL: https://svnweb.freebsd.org/changeset/base/315107 Log: Fix building with recent gcc Reported by: lwhsu, ngie Modified: head/usr.bin/diff/diffdir.c head/usr.bin/diff/diffreg.c Modified: head/usr.bin/diff/diffdir.c ============================================================================== --- head/usr.bin/diff/diffdir.c Sun Mar 12 03:58:54 2017 (r315106) +++ head/usr.bin/diff/diffdir.c Sun Mar 12 04:04:16 2017 (r315107) @@ -57,6 +57,8 @@ diffdir(char *p1, char *p2, int flags) char path1[PATH_MAX], path2[PATH_MAX]; int pos; + edp1 = edp2 = NULL; + dirlen1 = strlcpy(path1, *p1 ? p1 : ".", sizeof(path1)); if (dirlen1 >= sizeof(path1) - 1) { warnc(ENAMETOOLONG, "%s", p1); Modified: head/usr.bin/diff/diffreg.c ============================================================================== --- head/usr.bin/diff/diffreg.c Sun Mar 12 03:58:54 2017 (r315106) +++ head/usr.bin/diff/diffreg.c Sun Mar 12 04:04:16 2017 (r315107) @@ -200,7 +200,7 @@ static void range(int, int, const char static void uni_range(int, int); static void dump_context_vec(FILE *, FILE *, int); static void dump_unified_vec(FILE *, FILE *, int); -static void prepare(int, FILE *, off_t, int); +static void prepare(int, FILE *, size_t, int); static void prune(void); static void equiv(struct line *, int, struct line *, int, int *); static void unravel(int); @@ -315,6 +315,8 @@ diffreg(char *file1, char *file2, int fl struct kevent *e; cap_rights_t rights_ro; + e = NULL; + kq = -1; f1 = f2 = NULL; rval = D_SAME; anychange = 0; @@ -474,7 +476,7 @@ diffreg(char *file1, char *file2, int fl ixnew = xreallocarray(ixnew, len[1] + 2, sizeof(*ixnew)); check(f1, f2, flags); output(file1, f1, file2, f2, flags); - if (ostdout != -1) { + if (ostdout != -1 && e != NULL) { /* close the pipe to pr and restore stdout */ int wstatus; @@ -555,7 +557,7 @@ splice(char *dir, char *path) } static void -prepare(int i, FILE *fd, off_t filesize, int flags) +prepare(int i, FILE *fd, size_t filesize, int flags) { struct line *p; int h; From owner-svn-src-all@freebsd.org Sun Mar 12 04:05:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 61C65D08D6C; Sun, 12 Mar 2017 04:05:45 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x241.google.com (mail-pg0-x241.google.com [IPv6:2607:f8b0:400e:c05::241]) (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 2F6CC1470; Sun, 12 Mar 2017 04:05:45 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x241.google.com with SMTP id b5so14588092pgg.1; Sat, 11 Mar 2017 20:05:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=JIuvlzmuvNoqbz4lpUWUV03El5zKJXoLKdyQ0VYbDU0=; b=FWYqZM78IpJhxR+4EpKtz2Zj4xdhlafQZjI5sJKxnHXMY46ww8xzVtZ2pxi1Zpm4gZ pQdnmsKrET7GRLYDnPcNOwvqw6cwp/dbCiAGWQU3HelQAnbENqU9kTHVCVHOXRAva8GU B8LIAKOgcZ4QJUhh5A3bl9oCxQ7kO+ngFYU/DsLMWjnLilh34sM57Bkb995Ziro/kOww pwx4IIphYdLCnvFy8PCwP9ttDlu84wtk/NTidZ9OtyYeI7Wihlt8FTtrRQmYnXtcut22 HXu/JWsC1+iQbj6eJ7m8EtBwdqxiHm/NoSuZ8HAP3g1xJATzSBmOWUBIOQjxarrP7Qg0 rhdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=JIuvlzmuvNoqbz4lpUWUV03El5zKJXoLKdyQ0VYbDU0=; b=LSjpeVOMjF5oCBojAJZHvvcJpFbr7Q52BuQidH91SkIcKUPB9SdoVmNX402HyZ5WWb a6Qxsj4MEaR13xYB21TY00Z6WfMoxy6izja9PE4xxg0bT/NRHhaDlXTLLo2N/LXfC117 cMMQbd6PBGrWcCFfytRGMVqb8iWTwx3KB4e4oQmbnSrhL6cVK0a8OCAvrV8Hhr7wOEd5 cF/pauxzdTyJvuep0bJ5fioIRNekTOj3VsB9+uslmoPT3GUsSIk1eDgn14CDOT8bVgUW K4aTT3IAIjbPNCCIjinXYD+0LOVdGiFMrzl16uUT3hP9XfwL0XX1+2gnt7zDAGnSaPnD A/iw== X-Gm-Message-State: AMke39nE4Oz4eALae16ja3RrryvywbF98U8dB2uN+6uM4Q0y+8iQMoW99WBNReocTWZVwQ== X-Received: by 10.99.173.69 with SMTP id y5mr29415856pgo.35.1489291544550; Sat, 11 Mar 2017 20:05:44 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id 15sm26594962pgh.21.2017.03.11.20.05.43 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 20:05:43 -0800 (PST) Subject: Re: svn commit: r315107 - head/usr.bin/diff Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_99C629C9-58E2-4D3F-AC54-01FB88CB34BC"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703120404.v2C44GZZ033087@repo.freebsd.org> Date: Sat, 11 Mar 2017 20:05:42 -0800 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703120404.v2C44GZZ033087@repo.freebsd.org> To: Baptiste Daroussin X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:05:45 -0000 --Apple-Mail=_99C629C9-58E2-4D3F-AC54-01FB88CB34BC Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On Mar 11, 2017, at 20:04, Baptiste Daroussin = wrote: >=20 > Author: bapt > Date: Sun Mar 12 04:04:16 2017 > New Revision: 315107 > URL: https://svnweb.freebsd.org/changeset/base/315107 >=20 > Log: > Fix building with recent gcc >=20 > Reported by: lwhsu, ngie Technically, gcc 4.2.1 was broken as well, as I saw with make = tinderbox TARGET=3Dpowerpc TARGET_ARCH=3Dpowerpc :/. Thanks for the quick fix! -Ngie /scratch/tmp/ngie/svn/usr.bin/diff/diffdir.c: In function 'diffdir': /scratch/tmp/ngie/svn/usr.bin/diff/diffdir.c:55: warning: 'edp2' may be = used uninitialized in this function /scratch/tmp/ngie/svn/usr.bin/diff/diffdir.c:54: warning: 'edp1' may be = used uninitialized in this function --Apple-Mail=_99C629C9-58E2-4D3F-AC54-01FB88CB34BC Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxMkXAAoJEPWDqSZpMIYVpmMP/A1clDp/XLOhyz5MD2s6cnC6 XN0MFfOI9IS16M94cpypss0d/9kKBvUKcl5ToVj2Oc3m6PQ4slX64bqqh9Wjiauy iRxabYR3lr3Mr7MuWr4UzzvKI+qD/M+kYGFRILduhNZg16iDGyFAT1hUjGGfuWR9 0jsrgTjQ6Y1go1MNw0nxdQt+4BZQKxc5ZpYNdo12vIR70Uc9y6Z8OWB8JY4ZWJYn ZHtfZhXJyb24aErdK4wVAvVpt6wh/yVzR+a489KIpRi3t64xepJ9icIulSrecLmi 3OmwbyaO1jr/WGMD9Zrpqe11+yY+CrXivEQh66TlSbwPIMwS/iMukky9teJ1MA0U IqEz7jbbTsdS4HXQHPm+5JYLuMepuGV3MkVSHKBo30dYAZ/Pgyd6E5xYCzvN1viv 1fRtTt/RMLJxdavko7FVDrU+59uYvYzzUUrW9i7oO7EdE6WMA8FzOkWjMaN1exxv 2E1YgyBCbAugM54b1zQGJpYiD1mDl5CddoR9X8vze/2Kbgyhtn3KXnXlzz0zgsXY 3765hu2UOBm5eQN8psQAJWK6uE8GWQIsN78aDsY1O/nW4uYnlKAhZyYIvMAUYw19 NB1fxvqDJwwsAQS1DV+LTfAVvAdzeTlBfnesqvrgZuSktKPYfUaTTUegWCNidrOm m7gZCt1Ky+6lMqE9RroZ =qwKM -----END PGP SIGNATURE----- --Apple-Mail=_99C629C9-58E2-4D3F-AC54-01FB88CB34BC-- From owner-svn-src-all@freebsd.org Sun Mar 12 04:08:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 286A3D08E07; Sun, 12 Mar 2017 04:08:38 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E9A1E1608; Sun, 12 Mar 2017 04:08:37 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C48bAr033263; Sun, 12 Mar 2017 04:08:37 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C48adc033262; Sun, 12 Mar 2017 04:08:36 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120408.v2C48adc033262@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:08:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315108 - head/usr.bin/xinstall/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:08:38 -0000 Author: ngie Date: Sun Mar 12 04:08:36 2017 New Revision: 315108 URL: https://svnweb.freebsd.org/changeset/base/315108 Log: Restore some of the error message text accidentally removed in r315098 "unexpected symlink contents" is more pedantically correct than "unexpected symlink". MFC after: 1 week X-MFC with: r315098 Sponsored by: Dell EMC Isilon Modified: head/usr.bin/xinstall/tests/install_test.sh Modified: head/usr.bin/xinstall/tests/install_test.sh ============================================================================== --- head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 04:04:16 2017 (r315107) +++ head/usr.bin/xinstall/tests/install_test.sh Sun Mar 12 04:08:36 2017 (r315108) @@ -286,7 +286,7 @@ symbolic_link_absolute_body() { copyf_path=$(readlink copyf) testf_path="$(pwd -P)/testf" if [ "$copyf_path" != "$testf_path" ]; then - atf_fail "unexpected symlink ('$copyf_path' != '$testf_path')" + atf_fail "unexpected symlink contents ('$copyf_path' != '$testf_path')" fi } @@ -299,7 +299,7 @@ symbolic_link_relative_body() { copyf_path=$(readlink copyf) testf_path="testf" if [ "$copyf_path" != "$testf_path" ]; then - atf_fail "unexpected symlink ('$copyf_path' != '$testf_path')" + atf_fail "unexpected symlink contents ('$copyf_path' != '$testf_path')" fi } From owner-svn-src-all@freebsd.org Sun Mar 12 04:12:24 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3E8C8D09090; Sun, 12 Mar 2017 04:12:24 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E0A711A6B; Sun, 12 Mar 2017 04:12:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4CMuL037105; Sun, 12 Mar 2017 04:12:22 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4CM3l037103; Sun, 12 Mar 2017 04:12:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120412.v2C4CM3l037103@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:12:22 +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: r315109 - in stable/11: rescue/rescue tools/build/mk X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:12:24 -0000 Author: ngie Date: Sun Mar 12 04:12:22 2017 New Revision: 315109 URL: https://svnweb.freebsd.org/changeset/base/315109 Log: MFC r314240: Conditionally compile certain programs into rescue(8) if requested MK_CCD - ccdconfig MK_ROUTED - routed, rtquery Modified: stable/11/rescue/rescue/Makefile stable/11/tools/build/mk/OptionalObsoleteFiles.inc Directory Properties: stable/11/ (props changed) Modified: stable/11/rescue/rescue/Makefile ============================================================================== --- stable/11/rescue/rescue/Makefile Sun Mar 12 04:08:36 2017 (r315108) +++ stable/11/rescue/rescue/Makefile Sun Mar 12 04:12:22 2017 (r315109) @@ -90,7 +90,7 @@ CRUNCH_SUPPRESS_LINK_-tcsh= 1 # CRUNCH_SRCDIRS+= sbin CRUNCH_PROGS_sbin= badsect \ - camcontrol ccdconfig clri devfs dmesg dump \ + camcontrol clri devfs dmesg dump \ dumpfs dumpon fsck fsck_ffs fsck_msdosfs fsdb \ fsirand gbde geom ifconfig init \ kldconfig kldload kldstat kldunload ldconfig \ @@ -98,13 +98,17 @@ CRUNCH_PROGS_sbin= badsect \ mount_msdosfs mount_nfs mount_nullfs \ mount_udf mount_unionfs newfs \ newfs_msdos nos-tun ping reboot \ - restore rcorder route routed rtquery rtsol savecore \ + restore rcorder route rtsol savecore \ spppcontrol swapon sysctl tunefs umount .if ${MK_ATM} != "no" CRUNCH_PROGS_sbin+= atmconfig .endif +.if ${MK_CCD} != "no" +CRUNCH_PROGS_sbin+= ccdconfig +.endif + .if ${MK_INET6_SUPPORT} != "no" CRUNCH_PROGS_sbin+= ping6 .endif @@ -112,6 +116,11 @@ CRUNCH_PROGS_sbin+= ping6 .if ${MK_IPFILTER} != "no" CRUNCH_PROGS_sbin+= ipf .endif + +.if ${MK_ROUTED} != "no" +CRUNCH_PROGS_sbin+= routed rtquery +.endif + .if ${MK_ZFS} != "no" CRUNCH_PROGS_sbin+= zfs CRUNCH_PROGS_sbin+= zpool Modified: stable/11/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- stable/11/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:08:36 2017 (r315108) +++ stable/11/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:12:22 2017 (r315109) @@ -1201,6 +1201,7 @@ OLD_FILES+=usr/share/man/man8/casperd.8. .if ${MK_CCD} == no OLD_FILES+=etc/rc.d/ccd +OLD_FILES+=rescue/ccdconfig OLD_FILES+=sbin/ccdconfig OLD_FILES+=usr/share/man/man4/ccd.4.gz OLD_FILES+=usr/share/man/man8/ccdconfig.8.gz @@ -7130,6 +7131,8 @@ OLD_FILES+=usr/share/man/man5/rcsfile.5. #.endif .if ${MK_ROUTED} == no +OLD_FILES+=rescue/routed +OLD_FILES+=rescue/rtquery OLD_FILES+=sbin/routed OLD_FILES+=sbin/rtquery OLD_FILES+=usr/share/man/man8/routed.8.gz From owner-svn-src-all@freebsd.org Sun Mar 12 04:12:43 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2EB12D09131; Sun, 12 Mar 2017 04:12:43 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D345F1BE4; Sun, 12 Mar 2017 04:12:42 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4CfFt037162; Sun, 12 Mar 2017 04:12:41 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4Cf74037160; Sun, 12 Mar 2017 04:12:41 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120412.v2C4Cf74037160@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:12:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315110 - in stable/10: rescue/rescue tools/build/mk X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:12:43 -0000 Author: ngie Date: Sun Mar 12 04:12:41 2017 New Revision: 315110 URL: https://svnweb.freebsd.org/changeset/base/315110 Log: MFC r314240: Conditionally compile certain programs into rescue(8) if requested MK_CCD - ccdconfig MK_ROUTED - routed, rtquery Modified: stable/10/rescue/rescue/Makefile stable/10/tools/build/mk/OptionalObsoleteFiles.inc Directory Properties: stable/10/ (props changed) Modified: stable/10/rescue/rescue/Makefile ============================================================================== --- stable/10/rescue/rescue/Makefile Sun Mar 12 04:12:22 2017 (r315109) +++ stable/10/rescue/rescue/Makefile Sun Mar 12 04:12:41 2017 (r315110) @@ -89,7 +89,7 @@ CRUNCH_SUPPRESS_LINK_-tcsh= 1 # CRUNCH_SRCDIRS+= sbin CRUNCH_PROGS_sbin= badsect \ - camcontrol ccdconfig clri devfs dmesg dump \ + camcontrol clri devfs dmesg dump \ dumpfs dumpon fsck fsck_ffs fsck_msdosfs fsdb \ fsirand gbde geom ifconfig init \ kldconfig kldload kldstat kldunload ldconfig \ @@ -97,13 +97,17 @@ CRUNCH_PROGS_sbin= badsect \ mount_msdosfs mount_nfs mount_nullfs \ mount_udf mount_unionfs newfs \ newfs_msdos nos-tun ping reboot \ - restore rcorder route routed rtquery rtsol savecore \ + restore rcorder route rtsol savecore \ spppcontrol swapon sysctl tunefs umount .if ${MK_ATM} != "no" CRUNCH_PROGS_sbin+= atmconfig .endif +.if ${MK_CCD} != "no" +CRUNCH_PROGS_sbin+= ccdconfig +.endif + .if ${MK_INET6_SUPPORT} != "no" CRUNCH_PROGS_sbin+= ping6 .endif @@ -111,6 +115,11 @@ CRUNCH_PROGS_sbin+= ping6 .if ${MK_IPFILTER} != "no" CRUNCH_PROGS_sbin+= ipf .endif + +.if ${MK_ROUTED} != "no" +CRUNCH_PROGS_sbin+= routed rtquery +.endif + .if ${MK_ZFS} != "no" CRUNCH_PROGS_sbin+= zfs CRUNCH_PROGS_sbin+= zpool Modified: stable/10/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- stable/10/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:12:22 2017 (r315109) +++ stable/10/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:12:41 2017 (r315110) @@ -801,6 +801,7 @@ OLD_DIRS+=usr/tests/usr.bin/calendar .if ${MK_CCD} == no OLD_FILES+=etc/rc.d/ccd +OLD_FILES+=rescue/ccdconfig OLD_FILES+=sbin/ccdconfig OLD_FILES+=usr/share/man/man4/ccd.4.gz OLD_FILES+=usr/share/man/man8/ccdconfig.8.gz @@ -4437,6 +4438,8 @@ OLD_DIRS+=usr/tests/usr.sbin/etcupdate #.endif .if ${MK_ROUTED} == no +OLD_FILES+=rescue/routed +OLD_FILES+=rescue/rtquery OLD_FILES+=sbin/routed OLD_FILES+=sbin/rtquery OLD_FILES+=usr/share/man/man8/routed.8.gz From owner-svn-src-all@freebsd.org Sun Mar 12 04:14:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 41657D091B1; Sun, 12 Mar 2017 04:14:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0E68E1D3E; Sun, 12 Mar 2017 04:14:22 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4EMmq037258; Sun, 12 Mar 2017 04:14:22 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4EM0e037257; Sun, 12 Mar 2017 04:14:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120414.v2C4EM0e037257@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:14:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315111 - head/tools/build/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:14:23 -0000 Author: ngie Date: Sun Mar 12 04:14:21 2017 New Revision: 315111 URL: https://svnweb.freebsd.org/changeset/base/315111 Log: Remove /rescue/iscsictl and /rescue/iscsid if MK_ISCSI == no MFC after: 3 days Sponsored by: Dell EMC Isilon Modified: head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:12:41 2017 (r315110) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:14:21 2017 (r315111) @@ -3444,6 +3444,8 @@ OLD_FILES+=usr/share/man/man8/natd.8.gz .if ${MK_ISCSI} == no OLD_FILES+=etc/rc.d/iscsictl OLD_FILES+=etc/rc.d/iscsid +OLD_FILES+=rescue/iscsictl +OLD_FILES+=rescue/iscsid OLD_FILES+=sbin/iscontrol OLD_FILES+=usr/bin/iscsictl OLD_FILES+=usr/sbin/iscsid From owner-svn-src-all@freebsd.org Sun Mar 12 04:15:57 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 806A6D0921A; Sun, 12 Mar 2017 04:15:57 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5B06F1E8F; Sun, 12 Mar 2017 04:15:57 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4Fu2Y037361; Sun, 12 Mar 2017 04:15:56 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4Fuiq037358; Sun, 12 Mar 2017 04:15:56 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201703120415.v2C4Fuiq037358@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Sun, 12 Mar 2017 04:15:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:15:57 -0000 Author: araujo Date: Sun Mar 12 04:15:56 2017 New Revision: 315112 URL: https://svnweb.freebsd.org/changeset/base/315112 Log: Add the capability to refresh the gpart(8) label without need a reboot. gpart(8) has functionality to change the label of an GPT partition. This functionality works like it should, however, after a label change the /dev/gpt/ entries remain unchanged. glabel(8) status output remains unchanged. The change only takes effect after a reboot. PR: 162690 Submitted by: sub.mesa@gmail, Ben RUBSON , ae Reviewed by: allanjude, bapt, bcr MFC after: 6 weeks. Differential Revision: https://reviews.freebsd.org/D9935 Modified: head/sbin/geom/class/label/geom_label.c head/sbin/geom/class/label/glabel.8 head/sys/geom/part/g_part.c Modified: head/sbin/geom/class/label/geom_label.c ============================================================================== --- head/sbin/geom/class/label/geom_label.c Sun Mar 12 04:14:21 2017 (r315111) +++ head/sbin/geom/class/label/geom_label.c Sun Mar 12 04:15:56 2017 (r315112) @@ -53,6 +53,7 @@ static void label_main(struct gctl_req * static void label_clear(struct gctl_req *req); static void label_dump(struct gctl_req *req); static void label_label(struct gctl_req *req); +static void label_refresh(struct gctl_req *req); struct g_command PUBSYM(class_commands)[] = { { "clear", G_FLAG_VERBOSE, label_main, G_NULL_OPTS, @@ -74,6 +75,9 @@ struct g_command PUBSYM(class_commands)[ { "label", G_FLAG_VERBOSE | G_FLAG_LOADKLD, label_main, G_NULL_OPTS, "[-v] name dev" }, + { "refresh", 0, label_main, G_NULL_OPTS, + "dev ..." + }, { "stop", G_FLAG_VERBOSE, NULL, { { 'f', "force", NULL, G_TYPE_BOOL }, @@ -105,6 +109,8 @@ label_main(struct gctl_req *req, unsigne label_clear(req); else if (strcmp(name, "dump") == 0) label_dump(req); + else if (strcmp(name, "refresh") == 0) + label_refresh(req); else gctl_error(req, "Unknown command: %s.", name); } @@ -223,3 +229,28 @@ label_dump(struct gctl_req *req) printf("\n"); } } + +static void +label_refresh(struct gctl_req *req) +{ + const char *name; + int i, nargs, fd; + + nargs = gctl_get_int(req, "nargs"); + if (nargs < 1) { + gctl_error(req, "Too few arguments."); + return; + } + + for (i = 0; i < nargs; i++) { + name = gctl_get_ascii(req, "arg%d", i); + fd = g_open(name, 1); + if (fd == -1) { + printf("Can't refresh metadata from %s: %s.\n", + name, strerror(errno)); + } else { + printf("Metadata from %s refreshed.\n", name); + (void)g_close(fd); + } + } +} Modified: head/sbin/geom/class/label/glabel.8 ============================================================================== --- head/sbin/geom/class/label/glabel.8 Sun Mar 12 04:14:21 2017 (r315111) +++ head/sbin/geom/class/label/glabel.8 Sun Mar 12 04:15:56 2017 (r315112) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 22, 2013 +.Dd March 12, 2017 .Dt GLABEL 8 .Os .Sh NAME @@ -57,6 +57,9 @@ .Cm dump .Ar dev ... .Nm +.Cm refresh +.Ar dev ... +.Nm .Cm list .Nm .Cm status @@ -186,6 +189,8 @@ Same as Clear metadata on the given devices. .It Cm dump Dump metadata stored on the given devices. +.It Cm refresh +Refresh / rediscover metadata from the given devices. .It Cm list See .Xr geom 8 . Modified: head/sys/geom/part/g_part.c ============================================================================== --- head/sys/geom/part/g_part.c Sun Mar 12 04:14:21 2017 (r315111) +++ head/sys/geom/part/g_part.c Sun Mar 12 04:15:56 2017 (r315112) @@ -888,6 +888,10 @@ g_part_ctl_commit(struct gctl_req *req, LIST_FOREACH_SAFE(entry, &table->gpt_entry, gpe_entry, tmp) { if (!entry->gpe_deleted) { + /* Notify consumers that provider might be changed. */ + if (entry->gpe_modified && ( + entry->gpe_pp->acw + entry->gpe_pp->ace) == 0) + g_media_changed(entry->gpe_pp, 0); entry->gpe_created = 0; entry->gpe_modified = 0; continue; From owner-svn-src-all@freebsd.org Sun Mar 12 04:24:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4EA48D094D7; Sun, 12 Mar 2017 04:24:31 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 05CD41436; Sun, 12 Mar 2017 04:24:30 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4OUeK041409; Sun, 12 Mar 2017 04:24:30 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4OU3m041407; Sun, 12 Mar 2017 04:24:30 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120424.v2C4OU3m041407@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:24:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315113 - in head: rescue/rescue tools/build/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:24:31 -0000 Author: ngie Date: Sun Mar 12 04:24:29 2017 New Revision: 315113 URL: https://svnweb.freebsd.org/changeset/base/315113 Log: Conditionally compile [additional] programs into rescue(8) if requested Trivial oversight missed in r314240 cleanup because I enable these knobs on my test machines. MK_INET6_SUPPORT - rtsol MK_NETCAT - nc MFC after: 3 days Sponsored by: Dell EMC Isilon Modified: head/rescue/rescue/Makefile head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/rescue/rescue/Makefile ============================================================================== --- head/rescue/rescue/Makefile Sun Mar 12 04:15:56 2017 (r315112) +++ head/rescue/rescue/Makefile Sun Mar 12 04:24:29 2017 (r315113) @@ -98,7 +98,7 @@ CRUNCH_PROGS_sbin= badsect \ mount_msdosfs mount_nfs mount_nullfs \ mount_udf mount_unionfs newfs \ newfs_msdos nos-tun ping reboot \ - restore rcorder route rtsol savecore \ + restore rcorder route savecore \ shutdown spppcontrol swapon sysctl tunefs umount .if ${MK_ATM} != "no" @@ -111,6 +111,7 @@ CRUNCH_PROGS_sbin+= ccdconfig .if ${MK_INET6_SUPPORT} != "no" CRUNCH_PROGS_sbin+= ping6 +CRUNCH_PROGS_sbin+= rtsol .endif .if ${MK_IPFILTER} != "no" @@ -186,7 +187,7 @@ CRUNCH_BUILDOPTS_dhclient= -DRELEASE_CRU # CRUNCH_SRCDIRS+= usr.bin -CRUNCH_PROGS_usr.bin= head mt nc sed tail tee +CRUNCH_PROGS_usr.bin= head mt sed tail tee CRUNCH_PROGS_usr.bin+= gzip CRUNCH_ALIAS_gzip= gunzip gzcat zcat @@ -208,6 +209,10 @@ CRUNCH_LIBS+= -lcrypto .endif CRUNCH_LIBS+= -lmd +.if ${MK_NETCAT} != "no" +CRUNCH_PROGS_usr.bin= nc +.endif + .if ${MK_VI} != "no" CRUNCH_PROGS_usr.bin+= vi CRUNCH_ALIAS_vi= ex Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:15:56 2017 (r315112) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:24:29 2017 (r315113) @@ -3338,6 +3338,7 @@ OLD_FILES+=usr/share/man/man8/traceroute .if ${MK_INET6_SUPPORT} == no OLD_FILES+=rescue/ping6 +OLD_FILES+=rescue/rtsol .endif .if ${MK_INETD} == no @@ -6682,6 +6683,7 @@ OLD_FILES+=usr/share/misc/windrv_stub.c .endif .if ${MK_NETCAT} == no +OLD_FILES+=rescue/nc OLD_FILES+=usr/bin/nc OLD_FILES+=usr/share/man/man1/nc.1.gz .endif From owner-svn-src-all@freebsd.org Sun Mar 12 04:28:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5A81DD095F4; Sun, 12 Mar 2017 04:28:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A1F61703; Sun, 12 Mar 2017 04:28:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4SjsS041756; Sun, 12 Mar 2017 04:28:45 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4SjiW041755; Sun, 12 Mar 2017 04:28:45 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120428.v2C4SjiW041755@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:28:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315114 - head/tools/build/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:28:46 -0000 Author: ngie Date: Sun Mar 12 04:28:45 2017 New Revision: 315114 URL: https://svnweb.freebsd.org/changeset/base/315114 Log: Remove /rescue/zdb if MK_ZFS == no Missed in r202452. MFC after: 3 days Sponsored by: Dell EMC Isilon Modified: head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:24:29 2017 (r315113) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Sun Mar 12 04:28:45 2017 (r315114) @@ -1311,6 +1311,7 @@ OLD_FILES+=etc/periodic/daily/800.scrub- OLD_LIBS+=lib/libzfs.so.2 OLD_LIBS+=lib/libzfs_core.so.2 OLD_LIBS+=lib/libzpool.so.2 +OLD_FILES+=rescue/zdb OLD_FILES+=rescue/zfs OLD_FILES+=rescue/zpool OLD_FILES+=sbin/zfs From owner-svn-src-all@freebsd.org Sun Mar 12 04:32:16 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E64E9D09762; Sun, 12 Mar 2017 04:32:16 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B31561B16; Sun, 12 Mar 2017 04:32:16 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4WFbw045695; Sun, 12 Mar 2017 04:32:15 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4WFH1045694; Sun, 12 Mar 2017 04:32:15 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120432.v2C4WFH1045694@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:32:15 +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: r315115 - stable/11/rescue/rescue X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:32:17 -0000 Author: ngie Date: Sun Mar 12 04:32:15 2017 New Revision: 315115 URL: https://svnweb.freebsd.org/changeset/base/315115 Log: MFC r314239: Add shutdown/poweroff support to rescue(8) shutdown is a safer way to power off than reboot (in general), because of the added shutdown process that it executes via /etc/rc.shutdown . It was odd that it was missing from rescue(8) since reboot and friends were added in past commits. While here, alias poweroff to shutdown for parity with sbin/shutdown/Makefile Modified: stable/11/rescue/rescue/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/rescue/rescue/Makefile ============================================================================== --- stable/11/rescue/rescue/Makefile Sun Mar 12 04:28:45 2017 (r315114) +++ stable/11/rescue/rescue/Makefile Sun Mar 12 04:32:15 2017 (r315115) @@ -99,7 +99,7 @@ CRUNCH_PROGS_sbin= badsect \ mount_udf mount_unionfs newfs \ newfs_msdos nos-tun ping reboot \ restore rcorder route rtsol savecore \ - spppcontrol swapon sysctl tunefs umount + shutdown spppcontrol swapon sysctl tunefs umount .if ${MK_ATM} != "no" CRUNCH_PROGS_sbin+= atmconfig @@ -179,6 +179,7 @@ CRUNCH_ALIAS_restore= rrestore CRUNCH_ALIAS_dump= rdump CRUNCH_ALIAS_fsck_ffs= fsck_4.2bsd fsck_ufs CRUNCH_ALIAS_geom= glabel gpart +CRUNCH_ALIAS_shutdown= poweroff # dhclient has historically been troublesome... CRUNCH_PROGS_sbin+= dhclient From owner-svn-src-all@freebsd.org Sun Mar 12 04:32:32 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 84D8DD097B0; Sun, 12 Mar 2017 04:32:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 51A2F1C51; Sun, 12 Mar 2017 04:32:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4WVkW045756; Sun, 12 Mar 2017 04:32:31 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4WVaX045755; Sun, 12 Mar 2017 04:32:31 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120432.v2C4WVaX045755@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:32:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315116 - stable/10/rescue/rescue X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:32:32 -0000 Author: ngie Date: Sun Mar 12 04:32:31 2017 New Revision: 315116 URL: https://svnweb.freebsd.org/changeset/base/315116 Log: MFC r314239: Add shutdown/poweroff support to rescue(8) shutdown is a safer way to power off than reboot (in general), because of the added shutdown process that it executes via /etc/rc.shutdown . It was odd that it was missing from rescue(8) since reboot and friends were added in past commits. While here, alias poweroff to shutdown for parity with sbin/shutdown/Makefile Modified: stable/10/rescue/rescue/Makefile Directory Properties: stable/10/ (props changed) Modified: stable/10/rescue/rescue/Makefile ============================================================================== --- stable/10/rescue/rescue/Makefile Sun Mar 12 04:32:15 2017 (r315115) +++ stable/10/rescue/rescue/Makefile Sun Mar 12 04:32:31 2017 (r315116) @@ -98,7 +98,7 @@ CRUNCH_PROGS_sbin= badsect \ mount_udf mount_unionfs newfs \ newfs_msdos nos-tun ping reboot \ restore rcorder route rtsol savecore \ - spppcontrol swapon sysctl tunefs umount + shutdown spppcontrol swapon sysctl tunefs umount .if ${MK_ATM} != "no" CRUNCH_PROGS_sbin+= atmconfig @@ -185,6 +185,7 @@ CRUNCH_ALIAS_restore= rrestore CRUNCH_ALIAS_dump= rdump CRUNCH_ALIAS_fsck_ffs= fsck_4.2bsd fsck_ufs CRUNCH_ALIAS_geom= glabel gpart +CRUNCH_ALIAS_shutdown= poweroff # dhclient has historically been troublesome... CRUNCH_PROGS_sbin+= dhclient From owner-svn-src-all@freebsd.org Sun Mar 12 04:33:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 84110D09822; Sun, 12 Mar 2017 04:33:45 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 50BB21DD4; Sun, 12 Mar 2017 04:33:45 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4Xi1R045903; Sun, 12 Mar 2017 04:33:44 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4XicF045902; Sun, 12 Mar 2017 04:33:44 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120433.v2C4XicF045902@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:33: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: r315117 - stable/11/sys/modules/nvme X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:33:45 -0000 Author: ngie Date: Sun Mar 12 04:33:44 2017 New Revision: 315117 URL: https://svnweb.freebsd.org/changeset/base/315117 Log: MFC r314645: Fix "make depend" with nvme.ko: add opt_cam.h to SRCS Modified: stable/11/sys/modules/nvme/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/modules/nvme/Makefile ============================================================================== --- stable/11/sys/modules/nvme/Makefile Sun Mar 12 04:32:31 2017 (r315116) +++ stable/11/sys/modules/nvme/Makefile Sun Mar 12 04:33:44 2017 (r315117) @@ -16,6 +16,7 @@ SRCS = nvme.c \ \ bus_if.h \ device_if.h \ + opt_cam.h \ pci_if.h .include From owner-svn-src-all@freebsd.org Sun Mar 12 04:36:17 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 40448D0989F; Sun, 12 Mar 2017 04:36:17 +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 133271F32; Sun, 12 Mar 2017 04:36:17 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: by freefall.freebsd.org (Postfix, from userid 1235) id 531733DA2; Sun, 12 Mar 2017 04:36:16 +0000 (UTC) Date: Sun, 12 Mar 2017 05:36:16 +0100 From: Baptiste Daroussin To: Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= Cc: "Bjoern A. Zeeb" , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Li-Wen Hsu Subject: Re: svn commit: r308996 - head/lib/libfetch Message-ID: <20170312043615.ax5a6xtuf2zmebc2@ivaldir.net> References: <201611221330.uAMDU7fg052989@repo.freebsd.org> <77B1B45A-D837-4853-B1E9-958D3B0DD519@lists.zabbadoz.net> <867f468rx5.fsf@desk.des.no> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="g2vx6qbgkf4owmri" Content-Disposition: inline In-Reply-To: <867f468rx5.fsf@desk.des.no> User-Agent: NeoMutt/20170225 (1.8.0) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:36:17 -0000 --g2vx6qbgkf4owmri Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Mar 03, 2017 at 01:29:26PM +0100, Dag-Erling Sm=C3=B8rgrav wrote: > "Bjoern A. Zeeb" writes: > > Dag-Erling Sm=C3=B8rgrav writes: > >> + /* split address if necessary */ > >> + err =3D EAI_SYSTEM; > >> + if ((sep =3D strchr(addr, ':')) !=3D NULL) { > >> + len =3D snprintf(hbuf, sizeof(hbuf), > >> + "%.*s", (int)(sep - addr), addr); > > I believe this code is what broke > > fetch http://[::1]:6666/ > > just to give an example; and the printf traces will not reveal this > > but =E2=80=9Caddr=E2=80=9D at this point has no more addr:port in it gi= ven the > > function arguments, right? >=20 > I think you're right, I'll look into it. It means replacing strchr() > with a loop. Is there a ticket for this bug, and if not, could you > please open one? >=20 This causes breakage on the cluster for everything using libfetch: On the jenkins cluster we cannot run anymore fetch inside i386 chroots # chroot ufs fetch -v http://pkg.freebsd.org resolving server address: pkg.freebsd.org:80 fetch: http://pkg.freebsd.org: Non-recoverable resolver failure What is specific is the host only have ipv6 is amd64 and the chroot is i386 I can't figure out the issue can you have a look? Best regards, Bapt --g2vx6qbgkf4owmri Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEgOTj3suS2urGXVU3Y4mL3PG3PloFAljE0DwACgkQY4mL3PG3 PloCVBAAqg1bx98kzoBl0nkt0kn5//jKwvw8y5IBVgqO6kmloihvoMItx3JGeGrr c2UQ9FXyaHI5zpyUBlp5hQnf7KrLKAoqjegqsqqf3maf6eJQBD8L2xfmys50fNjp 7E9xI7vQ3T8jB+CQS3t4oAXRiCGb9Ic3a8bN3vKubA3Ib4Ce4L89e0KHV3p8W3M/ vOJ+2ou9EA9n/2DRW5KcrVCjfdtN0KRf+Lz7zJ5trBJ45sjMPwUI8qDkjUakl+35 YllESg4YyorAyh4+2IVEJP1MBXMO25R5aqNgfGaEKAKc+Td2f5xDvZBDmMORAblY p7CQvF8kPCGLNN4SJm+5BQkKpPfT0GrUgK0mcS4oiVuCawxo5qXnKF2h5I4e5LwK 5UyuHxwm6wBFIu1Xg6MjDkPep7oABuHYmVHAWHmik2H2fm6Q3OnVe+VzUzwmQYh4 zn3oHU5WIssmDNtfkOCU4w5pS6NuoO1Iv+ZIGzOdcxodO/fRxhez7fxpMdQGqDBG 8791VAy56OsVj/qP/bEpHH+dsLc9cM1eyxDrkeFYbxFuG0sW+vrr99HZjDrym6Ru vIxfBHHi95IQN1VIc2VzhE+lcUEZVpuppGyk/VrLok2lBbi3NJOp/y6izmuXAFWH hkKl+uaN5ji4HcoztclHcGifjdB/bAh9z87KEhFHywIg4mYjfA8= =J3yS -----END PGP SIGNATURE----- --g2vx6qbgkf4owmri-- From owner-svn-src-all@freebsd.org Sun Mar 12 04:40:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 44000D0997A; Sun, 12 Mar 2017 04:40:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1BF3A10C1; Sun, 12 Mar 2017 04:40:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4e2YV046279; Sun, 12 Mar 2017 04:40:02 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4e2dT046277; Sun, 12 Mar 2017 04:40:02 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120440.v2C4e2dT046277@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:40: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: r315118 - stable/11/lib/msun/tests X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:40:03 -0000 Author: ngie Date: Sun Mar 12 04:40:01 2017 New Revision: 315118 URL: https://svnweb.freebsd.org/changeset/base/315118 Log: MFC r305283,r314649: r305283: Skip :test_large on i386 More assertions are failing on ^/head now. PR: 205446 r314649: Convert lib/msun/ctrig_test from TAP to ATF This is being done as a precursor for work needed to annontate failing testcases with clang 4.0+. PR: 217528 Modified: stable/11/lib/msun/tests/Makefile stable/11/lib/msun/tests/ctrig_test.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/msun/tests/Makefile ============================================================================== --- stable/11/lib/msun/tests/Makefile Sun Mar 12 04:33:44 2017 (r315117) +++ stable/11/lib/msun/tests/Makefile Sun Mar 12 04:40:01 2017 (r315118) @@ -51,7 +51,7 @@ TAP_TESTS_C+= conj_test # https://llvm.org/bugs/show_bug.cgi?id=26081 TAP_TESTS_C+= csqrt_test .endif -TAP_TESTS_C+= ctrig_test +ATF_TESTS_C+= ctrig_test TAP_TESTS_C+= exponential_test TAP_TESTS_C+= fenv_test TAP_TESTS_C+= fma_test Modified: stable/11/lib/msun/tests/ctrig_test.c ============================================================================== --- stable/11/lib/msun/tests/ctrig_test.c Sun Mar 12 04:33:44 2017 (r315117) +++ stable/11/lib/msun/tests/ctrig_test.c Sun Mar 12 04:40:01 2017 (r315118) @@ -31,13 +31,14 @@ #include __FBSDID("$FreeBSD$"); -#include #include #include #include #include #include +#include + #include "test-utils.h" #pragma STDC FENV_ACCESS ON @@ -60,9 +61,9 @@ __FBSDID("$FreeBSD$"); volatile long double complex _d = z; \ debug(" testing %s(%Lg + %Lg I) == %Lg + %Lg I\n", #func, \ creall(_d), cimagl(_d), creall(result), cimagl(result)); \ - assert(feclearexcept(FE_ALL_EXCEPT) == 0); \ - assert(cfpequal_cs((func)(_d), (result), (checksign))); \ - assert(((void)(func), fetestexcept(exceptmask) == (excepts))); \ + ATF_CHECK(feclearexcept(FE_ALL_EXCEPT) == 0); \ + ATF_CHECK(cfpequal_cs((func)(_d), (result), (checksign))); \ + ATF_CHECK(((void)(func), fetestexcept(exceptmask) == (excepts))); \ } while (0) /* @@ -74,7 +75,7 @@ __FBSDID("$FreeBSD$"); volatile long double complex _d = z; \ debug(" testing %s(%Lg + %Lg I) ~= %Lg + %Lg I\n", #func, \ creall(_d), cimagl(_d), creall(result), cimagl(result)); \ - assert(cfpequal_tol((func)(_d), (result), (tol), FPE_ABS_ZERO)); \ + ATF_CHECK(cfpequal_tol((func)(_d), (result), (tol), FPE_ABS_ZERO)); \ } while (0) /* These wrappers apply the identities f(conj(z)) = conj(f(z)). */ @@ -127,9 +128,12 @@ __FBSDID("$FreeBSD$"); } while (0) -/* Tests for 0 */ -void -test_zero(void) +ATF_TC(test_zero_input); +ATF_TC_HEAD(test_zero_input, tc) +{ + atf_tc_set_md_var(tc, "descr", "test 0 input"); +} +ATF_TC_BODY(test_zero_input, tc) { long double complex zero = CMPLXL(0.0, 0.0); @@ -142,11 +146,12 @@ test_zero(void) testall_odd(ctan, zero, zero, ALL_STD_EXCEPT, 0, CS_BOTH); } -/* - * Tests for NaN inputs. - */ -void -test_nan() +ATF_TC(test_nan_inputs); +ATF_TC_HEAD(test_nan_inputs, tc) +{ + atf_tc_set_md_var(tc, "descr", "test NaN inputs"); +} +ATF_TC_BODY(test_nan_inputs, tc) { long double complex nan_nan = CMPLXL(NAN, NAN); long double complex z; @@ -222,8 +227,12 @@ test_nan() testall_odd(ctan, z, nan_nan, OPT_INVALID, 0, 0); } -void -test_inf(void) +ATF_TC(test_inf_inputs); +ATF_TC_HEAD(test_inf_inputs, tc) +{ + atf_tc_set_md_var(tc, "descr", "test infinity inputs"); +} +ATF_TC_BODY(test_inf_inputs, tc) { static const long double finites[] = { 0, M_PI / 4, 3 * M_PI / 4, 5 * M_PI / 4, @@ -287,9 +296,12 @@ test_inf(void) testall_odd(ctan, z, CMPLXL(NAN, NAN), OPT_INEXACT, FE_INVALID, 0); } -/* Tests along the real and imaginary axes. */ -void -test_axes(void) +ATF_TC(test_axes); +ATF_TC_HEAD(test_axes, tc) +{ + atf_tc_set_md_var(tc, "descr", "test along the real/imaginary axes"); +} +ATF_TC_BODY(test_axes, tc) { static const long double nums[] = { M_PI / 4, M_PI / 2, 3 * M_PI / 4, @@ -347,8 +359,12 @@ test_axes(void) } } -void -test_small(void) +ATF_TC(test_small_inputs); +ATF_TC_HEAD(test_small_inputs, tc) +{ + atf_tc_set_md_var(tc, "descr", "test underflow inputs"); +} +ATF_TC_BODY(test_small_inputs, tc) { /* * z = 0.5 + i Pi/4 @@ -409,12 +425,20 @@ test_small(void) } } -/* Test inputs that might cause overflow in a sloppy implementation. */ -void -test_large(void) +ATF_TC(test_large_inputs); +ATF_TC_HEAD(test_large_inputs, tc) +{ + atf_tc_set_md_var(tc, "descr", + "Test inputs that might cause overflow in a sloppy implementation"); +} +ATF_TC_BODY(test_large_inputs, tc) { long double complex z; +#ifdef __i386__ + atf_tc_expect_fail("test fails on i386 - bug 205446"); +#endif + /* tanh() uses a threshold around x=22, so check both sides. */ z = CMPLXL(21, 0.78539816339744830961566084581987572L); testall_odd_tol(ctanh, z, @@ -427,7 +451,6 @@ test_large(void) test_odd_tol(ctanh, z, CMPLXL(1.0, 8.95257245135025991216632140458264468e-309L), DBL_ULP()); -#if !defined(__i386__) z = CMPLXL(30, 0x1p1023L); test_odd_tol(ctanh, z, CMPLXL(1.0, -1.62994325413993477997492170229268382e-26L), @@ -437,7 +460,6 @@ test_large(void) CMPLXL(0.878606311888306869546254022621986509L, -0.225462792499754505792678258169527424L), DBL_ULP()); -#endif z = CMPLXL(710.6, 0.78539816339744830961566084581987572L); test_odd_tol(csinh, z, @@ -454,29 +476,15 @@ test_large(void) FE_OVERFLOW, CS_BOTH); } -int -main(int argc, char *argv[]) +ATF_TP_ADD_TCS(tp) { - printf("1..6\n"); - - test_zero(); - printf("ok 1 - ctrig zero\n"); - - test_nan(); - printf("ok 2 - ctrig nan\n"); - - test_inf(); - printf("ok 3 - ctrig inf\n"); - - test_axes(); - printf("ok 4 - ctrig axes\n"); - - test_small(); - printf("ok 5 - ctrig small\n"); - - test_large(); - printf("ok 6 - ctrig large\n"); + ATF_TP_ADD_TC(tp, test_zero_input); + ATF_TP_ADD_TC(tp, test_nan_inputs); + ATF_TP_ADD_TC(tp, test_inf_inputs); + ATF_TP_ADD_TC(tp, test_axes); + ATF_TP_ADD_TC(tp, test_small_inputs); + ATF_TP_ADD_TC(tp, test_large_inputs); - return (0); + return (atf_no_error()); } From owner-svn-src-all@freebsd.org Sun Mar 12 04:41:28 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AD53FD09B1F; Sun, 12 Mar 2017 04:41:28 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 79F711313; Sun, 12 Mar 2017 04:41:28 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4fROZ047827; Sun, 12 Mar 2017 04:41:27 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4fRR1047826; Sun, 12 Mar 2017 04:41:27 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120441.v2C4fRR1047826@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:41:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315119 - stable/10/sys/modules/geom/geom_uzip X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:41:28 -0000 Author: ngie Date: Sun Mar 12 04:41:27 2017 New Revision: 315119 URL: https://svnweb.freebsd.org/changeset/base/315119 Log: MFC r314644: Fix "make depend" with geom_uzip.ko: add opt_geom.h to SRCS Modified: stable/10/sys/modules/geom/geom_uzip/Makefile Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/modules/geom/geom_uzip/Makefile ============================================================================== --- stable/10/sys/modules/geom/geom_uzip/Makefile Sun Mar 12 04:40:01 2017 (r315118) +++ stable/10/sys/modules/geom/geom_uzip/Makefile Sun Mar 12 04:41:27 2017 (r315119) @@ -20,5 +20,6 @@ CFLAGS+= -I${.CURDIR}/../../../contrib/x SRCS+= xz_crc32.c xz_dec_bcj.c xz_dec_lzma2.c xz_dec_stream.c \ xz_malloc.c SRCS+= xz.h xz_config.h xz_lzma2.h xz_malloc.h xz_private.h xz_stream.h +SRCS+= opt_geom.h .include From owner-svn-src-all@freebsd.org Sun Mar 12 04:41:40 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A327D09B61; Sun, 12 Mar 2017 04:41:40 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DB39C13C1; Sun, 12 Mar 2017 04:41:39 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4fc45049969; Sun, 12 Mar 2017 04:41:38 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4fcCB049968; Sun, 12 Mar 2017 04:41:38 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120441.v2C4fcCB049968@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:41: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: r315120 - stable/11/sys/modules/geom/geom_uzip X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:41:40 -0000 Author: ngie Date: Sun Mar 12 04:41:38 2017 New Revision: 315120 URL: https://svnweb.freebsd.org/changeset/base/315120 Log: MFC r314644: Fix "make depend" with geom_uzip.ko: add opt_geom.h to SRCS Modified: stable/11/sys/modules/geom/geom_uzip/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/modules/geom/geom_uzip/Makefile ============================================================================== --- stable/11/sys/modules/geom/geom_uzip/Makefile Sun Mar 12 04:41:27 2017 (r315119) +++ stable/11/sys/modules/geom/geom_uzip/Makefile Sun Mar 12 04:41:38 2017 (r315120) @@ -18,5 +18,6 @@ CFLAGS+= -I${.CURDIR}/../../../contrib/x SRCS+= xz_crc32.c xz_dec_bcj.c xz_dec_lzma2.c xz_dec_stream.c \ xz_malloc.c SRCS+= xz.h xz_config.h xz_lzma2.h xz_malloc.h xz_private.h xz_stream.h +SRCS+= opt_geom.h .include From owner-svn-src-all@freebsd.org Sun Mar 12 04:46:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E1DE5D09C5A; Sun, 12 Mar 2017 04:46:18 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x241.google.com (mail-pf0-x241.google.com [IPv6:2607:f8b0:400e:c00::241]) (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 A42ED1892; Sun, 12 Mar 2017 04:46:18 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x241.google.com with SMTP id o126so15357710pfb.1; Sat, 11 Mar 2017 20:46:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=sOPMdydurtUWTYRfkdW1S24IA3FbStDkhZ3l3bt56yo=; b=thKGU37cTW/EyR/eURdBEB+1FRbmUjk9VsZ7DDBsUUHBsrXkzOohfZLdsdtXFtR6I+ QcEjRBZX5MGuE/z63+SEwBXweumMBULJN8GQ2JY4HyHdOHXaOQNjI49i7MrM9ZA0rtoP /KO+kPtWbd9k015pVKbAL4hnBcrQpVUNprMm2EBsx14PiSKDvmlMGwEXenYug23CpZHQ U2B1ji3O+uhB4VXgMJCbRr5eOmFKAjydwPuKFzWyfKA+Xt52WTy2JPTzOkOeR/XQ20XJ hdBThbYele6QJqR7oA3qGzx1SxMThvwk7ZjK/Rsqa7yjMZldpxPVndofFrr5gpAnGWLB 2VUA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=sOPMdydurtUWTYRfkdW1S24IA3FbStDkhZ3l3bt56yo=; b=PF3SoUOSA6mlyc40CsG2uU9torFZG7/uUtaat5+naVekU7pS7W7KRHyRIvbcCbirGD vbBFUecSL/n0uI/h0dr9UIEVdN/Aa8/odUzpkSWeag6g9C/pMhK+bvUee0ig5jFMORSF h6vjBohy4QTflYxRUSZet5v4WmUyLQh5/+G3o5j2VjjxixtoeG6NjRLiyNfJXnGFx0C0 Sh2MdumkFHbhnC6d/9Es52WSKajen2gf3BFL+2LB1eDYl1CPGUeZEvSmFT0S5rW07v2i 1Y2Jb738chQBNq6ZTJ/pepXpePE27AVMO53OzHRbC7JFa/63nmcb6Th4lJ5GIdtv7Hxl En+Q== X-Gm-Message-State: AMke39l3vXKSRsafQdQ94oVCE8Tnrr6H+NJ7F5s6COg9lJRniZ09SoZIOpBSUjYnj1i89Q== X-Received: by 10.99.225.5 with SMTP id z5mr28966171pgh.145.1489293978052; Sat, 11 Mar 2017 20:46:18 -0800 (PST) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id d3sm26579782pfc.51.2017.03.11.20.46.17 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 11 Mar 2017 20:46:17 -0800 (PST) Subject: Re: svn commit: r308996 - head/lib/libfetch Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_D5E517D9-231F-4316-98E0-B939EF01E241"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201611221330.uAMDU7fg052989@repo.freebsd.org> Date: Sat, 11 Mar 2017 20:46:16 -0800 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <93505FD7-FB42-4BD5-834C-6F73EFD9B1CF@gmail.com> References: <201611221330.uAMDU7fg052989@repo.freebsd.org> To: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:46:19 -0000 --Apple-Mail=_D5E517D9-231F-4316-98E0-B939EF01E241 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Nov 22, 2016, at 05:30, Dag-Erling Sm=C3=B8rgrav = wrote: >=20 > Author: des > Date: Tue Nov 22 13:30:07 2016 > New Revision: 308996 > URL: https://svnweb.freebsd.org/changeset/base/308996 >=20 > Log: > Refactor fetch_connect() and fetch_bind() to improve readability and = avoid > repeating the same DNS lookups. >=20 > MFC after: 3 weeks >=20 > Modified: > head/lib/libfetch/common.c > head/lib/libfetch/common.h > head/lib/libfetch/ftp.c >=20 > Modified: head/lib/libfetch/common.c > = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D > --- head/lib/libfetch/common.c Tue Nov 22 13:24:57 2016 = (r308995) > +++ head/lib/libfetch/common.c Tue Nov 22 13:30:07 2016 = (r308996) > @@ -1,5 +1,5 @@ > /*- > - * Copyright (c) 1998-2014 Dag-Erling Sm=C3=B8rgrav > + * Copyright (c) 1998-2016 Dag-Erling Sm=C3=B8rgrav > * Copyright (c) 2013 Michael Gmelin > * All rights reserved. > * > @@ -241,27 +241,83 @@ fetch_ref(conn_t *conn) >=20 >=20 > /* > + * Resolve an address > + */ > +struct addrinfo * > +fetch_resolve(const char *addr, int port, int af) > +{ > + char hbuf[256], sbuf[8]; > + struct addrinfo hints, *res; > + const char *sep, *host, *service; > + int err, len; > + > + /* split address if necessary */ > + err =3D EAI_SYSTEM; > + if ((sep =3D strchr(addr, ':')) !=3D NULL) { Hi Bjoern, Shouldn=E2=80=99t this be strrchr instead of strchr since = you=E2=80=99re scanning for the service from the right side of the host, = e.g. =E2=80=9Cfoo:service=E2=80=9D or =E2=80=9C[::1]:service=E2=80=9D? = This code would match index 3 in the first example, but it would match = index 2 in the second example. Thanks, -Ngie --Apple-Mail=_D5E517D9-231F-4316-98E0-B939EF01E241 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxNKYAAoJEPWDqSZpMIYV3J0QALZxTlr5dYE2gmWTfsURk/Py nUPfo5voDiFEZPDtkQZ1uXL5cydYirByBZxRDTFLqOxzSfaro5xLC512w4aOD5Fv LL4GyH+nVYLfEi4Wo3j7JxR81QMCDpVgGFCuk5cA1c3yvV7v0F8hAfDhNekMEY6k nkO7gUmAL3pOW7NSjeotI8/kVal0nKRVvkg3+QlLbHZixNhThXuhLgIZSaYOjEan 1fUmEyHdGRuzCp7DELjXEvElCaycZe7jSEWHDJydw2VJvVYb3RQQv8nHuGmA3yq9 tvUagd5wd+sCy4l9hXanrzuZs7D8O5MHvQXCUoH/rMUKtjfOs7l9AZdpWf9wFmz9 NmHL0BMxrbRJ+UN/N6eH+dqK8j9YuV8G+b+5C0S2e3llY+pnyGNnAcv2h/ouWgUy H6zrrJJHU/ZNP28QtEvgYVedWHQprTLVmfah5I9evQ723kL6mNtmRCZVTgx+IfoB VvwVITru8DcYs63B5IU4B09bnguIg4MtnHpMIIu5f36CibfBGFV+kUzvsgiVqZGY 4IgXqByjDFUL8DwGlTEOZiU0z+z3KfETCw23XpWCmPRPnyY6nJxitL4UpuPBUQGj aLj+Xojq2jiSC7/mgmxO/WSRf0h/tQxcDnEa3C2CKcn4DIP6z8aF1fyo+njJDHsu o1djBBUk1kk188glJp3b =lVHI -----END PGP SIGNATURE----- --Apple-Mail=_D5E517D9-231F-4316-98E0-B939EF01E241-- From owner-svn-src-all@freebsd.org Sun Mar 12 04:52:12 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 070D9D09E48; Sun, 12 Mar 2017 04:52:12 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BC14F1BB6; Sun, 12 Mar 2017 04:52:11 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4qAkC054046; Sun, 12 Mar 2017 04:52:10 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4q9Ru054028; Sun, 12 Mar 2017 04:52:09 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120452.v2C4q9Ru054028@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:52:09 +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: r315121 - stable/11/lib/msun/tests X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:52:12 -0000 Author: ngie Date: Sun Mar 12 04:52:09 2017 New Revision: 315121 URL: https://svnweb.freebsd.org/changeset/base/315121 Log: MFC r314650: Fix warnings in lib/msun/tests/... to help pave way for WARNS?= 6. - Staticize variables. - Use nitems liberally. Wherever nitems is used, use unsigned integers - Remove unused variables (argc, argv, etc) This fixes most issues -- some issues remain in logarithm_test though. Modified: stable/11/lib/msun/tests/cexp_test.c stable/11/lib/msun/tests/conj_test.c stable/11/lib/msun/tests/csqrt_test.c stable/11/lib/msun/tests/ctrig_test.c stable/11/lib/msun/tests/exponential_test.c stable/11/lib/msun/tests/fenv_test.c stable/11/lib/msun/tests/fma_test.c stable/11/lib/msun/tests/fmaxmin_test.c stable/11/lib/msun/tests/invctrig_test.c stable/11/lib/msun/tests/invtrig_test.c stable/11/lib/msun/tests/logarithm_test.c stable/11/lib/msun/tests/lrint_test.c stable/11/lib/msun/tests/nan_test.c stable/11/lib/msun/tests/nearbyint_test.c stable/11/lib/msun/tests/next_test.c stable/11/lib/msun/tests/rem_test.c stable/11/lib/msun/tests/test-utils.h stable/11/lib/msun/tests/trig_test.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/msun/tests/cexp_test.c ============================================================================== --- stable/11/lib/msun/tests/cexp_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/cexp_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -94,7 +94,7 @@ static const float finites[] = /* Tests for 0 */ -void +static void test_zero(void) { @@ -109,10 +109,10 @@ test_zero(void) * Tests for NaN. The signs of the results are indeterminate unless the * imaginary part is 0. */ -void -test_nan() +static void +test_nan(void) { - int i; + unsigned i; /* cexp(x + NaNi) = NaN + NaNi and optionally raises invalid */ /* cexp(NaN + yi) = NaN + NaNi and optionally raises invalid (|y|>0) */ @@ -142,10 +142,10 @@ test_nan() ALL_STD_EXCEPT, 0, 0); } -void +static void test_inf(void) { - int i; + unsigned i; /* cexp(x + inf i) = NaN + NaNi and raises invalid */ for (i = 0; i < nitems(finites); i++) { @@ -184,10 +184,10 @@ test_inf(void) ALL_STD_EXCEPT, 0, 1); } -void +static void test_reals(void) { - int i; + unsigned i; for (i = 0; i < nitems(finites); i++) { /* XXX could check exceptions more meticulously */ @@ -207,10 +207,10 @@ test_reals(void) } } -void +static void test_imaginaries(void) { - int i; + unsigned i; for (i = 0; i < nitems(finites); i++) { printf("# Run %d..\n", i); @@ -229,7 +229,7 @@ test_imaginaries(void) } } -void +static void test_small(void) { static const double tests[] = { @@ -242,7 +242,7 @@ test_small(void) }; double a, b; double x, y; - int i; + unsigned i; for (i = 0; i < nitems(tests); i += 4) { printf("# Run %d..\n", i); @@ -260,7 +260,7 @@ test_small(void) } /* Test inputs with a real part r that would overflow exp(r). */ -void +static void test_large(void) { @@ -288,7 +288,7 @@ test_large(void) } int -main(int argc, char *argv[]) +main(void) { printf("1..7\n"); Modified: stable/11/lib/msun/tests/conj_test.c ============================================================================== --- stable/11/lib/msun/tests/conj_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/conj_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -71,7 +71,7 @@ static const double tests[] = { }; int -main(int argc, char *argv[]) +main(void) { static const int ntests = sizeof(tests) / sizeof(tests[0]) / 2; complex float in; @@ -90,7 +90,7 @@ main(int argc, char *argv[]) assert(fpequal(libcreall(in), __real__ in)); assert(fpequal(libcimagf(in), __imag__ in)); assert(fpequal(libcimag(in), __imag__ in)); - assert(fpequal(libcimagl(in), __imag__ in)); + assert(fpequal(libcimagl(in), __imag__ in)); feclearexcept(FE_ALL_EXCEPT); if (!cfpequal(libconjf(in), expected)) { Modified: stable/11/lib/msun/tests/csqrt_test.c ============================================================================== --- stable/11/lib/msun/tests/csqrt_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/csqrt_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -46,7 +46,7 @@ __FBSDID("$FreeBSD$"); * The latter two convert to float or double, respectively, and test csqrtf() * and csqrt() with the same arguments. */ -long double complex (*t_csqrt)(long double complex); +static long double complex (*t_csqrt)(long double complex); static long double complex _csqrtf(long double complex d) @@ -82,7 +82,7 @@ assert_equal(long double complex d1, lon * exceptions.) */ static void -test_finite() +test_finite(void) { static const double tests[] = { /* csqrt(a + bI) = x + yI */ @@ -125,7 +125,7 @@ test_finite() double a, b; double x, y; - int i, j; + unsigned i, j; for (i = 0; i < nitems(tests); i += 4) { for (j = 0; j < nitems(mults); j++) { @@ -143,7 +143,7 @@ test_finite() * Test the handling of +/- 0. */ static void -test_zeros() +test_zeros(void) { assert_equal(t_csqrt(CMPLXL(0.0, 0.0)), CMPLXL(0.0, 0.0)); @@ -156,7 +156,7 @@ test_zeros() * Test the handling of infinities when the other argument is not NaN. */ static void -test_infinities() +test_infinities(void) { static const double vals[] = { 0.0, @@ -167,7 +167,7 @@ test_infinities() -INFINITY, }; - int i; + unsigned i; for (i = 0; i < nitems(vals); i++) { if (isfinite(vals[i])) { @@ -187,7 +187,7 @@ test_infinities() * Test the handling of NaNs. */ static void -test_nans() +test_nans(void) { assert(creall(t_csqrt(CMPLXL(INFINITY, NAN))) == INFINITY); @@ -232,7 +232,7 @@ test_overflow(int maxexp) } int -main(int argc, char *argv[]) +main(void) { printf("1..15\n"); Modified: stable/11/lib/msun/tests/ctrig_test.c ============================================================================== --- stable/11/lib/msun/tests/ctrig_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/ctrig_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -31,6 +31,7 @@ #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -238,7 +239,7 @@ ATF_TC_BODY(test_inf_inputs, tc) 0, M_PI / 4, 3 * M_PI / 4, 5 * M_PI / 4, }; long double complex z, c, s; - int i; + unsigned i; /* * IN CSINH CCOSH CTANH @@ -260,7 +261,7 @@ ATF_TC_BODY(test_inf_inputs, tc) testall_odd(ctan, z, CMPLXL(0, 1), ALL_STD_EXCEPT, 0, CS_REAL); /* XXX We allow spurious inexact exceptions here (hard to avoid). */ - for (i = 0; i < sizeof(finites) / sizeof(finites[0]); i++) { + for (i = 0; i < nitems(finites); i++) { z = CMPLXL(INFINITY, finites[i]); c = INFINITY * cosl(finites[i]); s = finites[i] == 0 ? finites[i] : INFINITY * sinl(finites[i]); @@ -308,9 +309,9 @@ ATF_TC_BODY(test_axes, tc) 5 * M_PI / 4, 3 * M_PI / 2, 7 * M_PI / 4, }; long double complex z; - int i; + unsigned i; - for (i = 0; i < sizeof(nums) / sizeof(nums[0]); i++) { + for (i = 0; i < nitems(nums); i++) { /* Real axis */ z = CMPLXL(nums[i], 0.0); test_odd_tol(csinh, z, CMPLXL(sinh(nums[i]), 0), DBL_ULP()); @@ -412,9 +413,9 @@ ATF_TC_BODY(test_small_inputs, tc) -0.26580222883407969212086273981988897L } }; long double complex z; - int i; + unsigned i; - for (i = 0; i < sizeof(tests) / sizeof(tests[0]); i++) { + for (i = 0; i < nitems(tests); i++) { z = CMPLXL(tests[i].a, tests[i].b); testall_odd_tol(csinh, z, CMPLXL(tests[i].sinh_a, tests[i].sinh_b), 1.1); Modified: stable/11/lib/msun/tests/exponential_test.c ============================================================================== --- stable/11/lib/msun/tests/exponential_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/exponential_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -89,7 +89,7 @@ __FBSDID("$FreeBSD$"); test(expm1f, x, result, exceptmask, excepts); \ } while (0) -void +static void run_generic_tests(void) { @@ -122,10 +122,10 @@ run_generic_tests(void) testall1(-50000.0, -1.0, ALL_STD_EXCEPT, FE_INEXACT); } -void +static void run_exp2_tests(void) { - int i; + unsigned i; /* * We should insist that exp2() return exactly the correct @@ -148,7 +148,7 @@ run_exp2_tests(void) } int -main(int argc, char *argv[]) +main(void) { printf("1..3\n"); Modified: stable/11/lib/msun/tests/fenv_test.c ============================================================================== --- stable/11/lib/msun/tests/fenv_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/fenv_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -64,56 +64,15 @@ static const int std_excepts[] = { /* init_exceptsets() initializes this to the power set of std_excepts[] */ static int std_except_sets[1 << NEXCEPTS]; -static void init_exceptsets(void); - -static void test_dfl_env(void); -static void test_fegsetenv(void); -static void test_fegsetexceptflag(void); -static void test_masking(void); -static void test_fegsetround(void); -static void test_feholdupdate(void); -static void test_feraiseexcept(void); -static void test_fetestclearexcept(void); - -static int getround(void); -static void raiseexcept(int excepts); -static void trap_handler(int sig); - #pragma STDC FENV_ACCESS ON -int -main(int argc, char *argv[]) -{ - - printf("1..8\n"); - init_exceptsets(); - test_dfl_env(); - printf("ok 1 - fenv\n"); - test_fetestclearexcept(); - printf("ok 2 - fenv\n"); - test_fegsetexceptflag(); - printf("ok 3 - fenv\n"); - test_feraiseexcept(); - printf("ok 4 - fenv\n"); - test_fegsetround(); - printf("ok 5 - fenv\n"); - test_fegsetenv(); - printf("ok 6 - fenv\n"); - test_masking(); - printf("ok 7 - fenv\n"); - test_feholdupdate(); - printf("ok 8 - fenv\n"); - - return (0); -} - /* * Initialize std_except_sets[] to the power set of std_excepts[] */ -void +static void init_exceptsets(void) { - int i, j, sr; + unsigned i, j, sr; for (i = 0; i < 1 << NEXCEPTS; i++) { for (sr = i, j = 0; sr != 0; sr >>= 1, j++) @@ -122,6 +81,90 @@ init_exceptsets(void) } /* + * Raise a floating-point exception without relying on the standard + * library routines, which we are trying to test. + * + * XXX We can't raise an {over,under}flow without also raising an + * inexact exception. + */ +static void +raiseexcept(int excepts) +{ + volatile double d; + + /* + * With a compiler that supports the FENV_ACCESS pragma + * properly, simple expressions like '0.0 / 0.0' should + * be sufficient to generate traps. Unfortunately, we + * need to bring a volatile variable into the equation + * to prevent incorrect optimizations. + */ + if (excepts & FE_INVALID) { + d = 0.0; + d = 0.0 / d; + } + if (excepts & FE_DIVBYZERO) { + d = 0.0; + d = 1.0 / d; + } + if (excepts & FE_OVERFLOW) { + d = DBL_MAX; + d *= 2.0; + } + if (excepts & FE_UNDERFLOW) { + d = DBL_MIN; + d /= DBL_MAX; + } + if (excepts & FE_INEXACT) { + d = DBL_MIN; + d += 1.0; + } + + /* + * On the x86 (and some other architectures?) the FPU and + * integer units are decoupled. We need to execute an FWAIT + * or a floating-point instruction to get synchronous exceptions. + */ + d = 1.0; + d += 1.0; +} + +/* + * Determine the current rounding mode without relying on the fenv + * routines. This function may raise an inexact exception. + */ +static int +getround(void) +{ + volatile double d; + + /* + * This test works just as well with 0.0 - 0.0, except on ia64 + * where 0.0 - 0.0 gives the wrong sign when rounding downwards. + */ + d = 1.0; + d -= 1.0; + if (copysign(1.0, d) < 0.0) + return (FE_DOWNWARD); + + d = 1.0; + if (d + (DBL_EPSILON * 3.0 / 4.0) == 1.0) + return (FE_TOWARDZERO); + if (d + (DBL_EPSILON * 1.0 / 4.0) > 1.0) + return (FE_UPWARD); + + return (FE_TONEAREST); +} + +static void +trap_handler(int sig) +{ + + assert(sig == SIGFPE); + _exit(0); +} + +/* * This tests checks the default FP environment, so it must be first. * The memcmp() test below may be too much to ask for, since there * could be multiple machine-specific default environments. @@ -347,7 +390,8 @@ static void test_masking(void) { struct sigaction act; - int except, i, pass, raise, status; + int except, pass, raise, status; + unsigned i; assert((fegetexcept() & ALL_STD_EXCEPT) == 0); assert((feenableexcept(FE_INVALID|FE_OVERFLOW) & ALL_STD_EXCEPT) == 0); @@ -427,7 +471,8 @@ test_feholdupdate(void) fenv_t env; struct sigaction act; - int except, i, pass, status, raise; + int except, pass, status, raise; + unsigned i; sigemptyset(&act.sa_mask); act.sa_flags = 0; @@ -452,7 +497,7 @@ test_feholdupdate(void) * We don't want to cause a fatal exception in * the child until the second pass, so we can * check other properties of feupdateenv(). - */ + */ if (pass == 1) assert((feenableexcept(except) & ALL_STD_EXCEPT) == 0); @@ -491,86 +536,28 @@ test_feholdupdate(void) assert(fetestexcept(FE_ALL_EXCEPT) == 0); } -/* - * Raise a floating-point exception without relying on the standard - * library routines, which we are trying to test. - * - * XXX We can't raise an {over,under}flow without also raising an - * inexact exception. - */ -static void -raiseexcept(int excepts) -{ - volatile double d; - - /* - * With a compiler that supports the FENV_ACCESS pragma - * properly, simple expressions like '0.0 / 0.0' should - * be sufficient to generate traps. Unfortunately, we - * need to bring a volatile variable into the equation - * to prevent incorrect optimizations. - */ - if (excepts & FE_INVALID) { - d = 0.0; - d = 0.0 / d; - } - if (excepts & FE_DIVBYZERO) { - d = 0.0; - d = 1.0 / d; - } - if (excepts & FE_OVERFLOW) { - d = DBL_MAX; - d *= 2.0; - } - if (excepts & FE_UNDERFLOW) { - d = DBL_MIN; - d /= DBL_MAX; - } - if (excepts & FE_INEXACT) { - d = DBL_MIN; - d += 1.0; - } - - /* - * On the x86 (and some other architectures?) the FPU and - * integer units are decoupled. We need to execute an FWAIT - * or a floating-point instruction to get synchronous exceptions. - */ - d = 1.0; - d += 1.0; -} - -/* - * Determine the current rounding mode without relying on the fenv - * routines. This function may raise an inexact exception. - */ -static int -getround(void) +int +main(void) { - volatile double d; - /* - * This test works just as well with 0.0 - 0.0, except on ia64 - * where 0.0 - 0.0 gives the wrong sign when rounding downwards. - */ - d = 1.0; - d -= 1.0; - if (copysign(1.0, d) < 0.0) - return (FE_DOWNWARD); - - d = 1.0; - if (d + (DBL_EPSILON * 3.0 / 4.0) == 1.0) - return (FE_TOWARDZERO); - if (d + (DBL_EPSILON * 1.0 / 4.0) > 1.0) - return (FE_UPWARD); - - return (FE_TONEAREST); -} - -static void -trap_handler(int sig) -{ + printf("1..8\n"); + init_exceptsets(); + test_dfl_env(); + printf("ok 1 - fenv\n"); + test_fetestclearexcept(); + printf("ok 2 - fenv\n"); + test_fegsetexceptflag(); + printf("ok 3 - fenv\n"); + test_feraiseexcept(); + printf("ok 4 - fenv\n"); + test_fegsetround(); + printf("ok 5 - fenv\n"); + test_fegsetenv(); + printf("ok 6 - fenv\n"); + test_masking(); + printf("ok 7 - fenv\n"); + test_feholdupdate(); + printf("ok 8 - fenv\n"); - assert(sig == SIGFPE); - _exit(0); + return (0); } Modified: stable/11/lib/msun/tests/fma_test.c ============================================================================== --- stable/11/lib/msun/tests/fma_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/fma_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -84,7 +84,7 @@ __FBSDID("$FreeBSD$"); * This is needed because clang constant-folds fma in ways that are incorrect * in rounding modes other than FE_TONEAREST. */ -volatile double one = 1.0; +static volatile double one = 1.0; static void test_zeroes(void) @@ -472,10 +472,10 @@ test_double_rounding(void) } int -main(int argc, char *argv[]) +main(void) { int rmodes[] = { FE_TONEAREST, FE_UPWARD, FE_DOWNWARD, FE_TOWARDZERO }; - int i, j; + unsigned i, j; #if defined(__i386__) printf("1..0 # SKIP all testcases fail on i386\n"); Modified: stable/11/lib/msun/tests/fmaxmin_test.c ============================================================================== --- stable/11/lib/msun/tests/fmaxmin_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/fmaxmin_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -61,7 +61,7 @@ __FBSDID("$FreeBSD$"); } \ } while (0) -int +static int testall_r(long double big, long double small) { int ok; @@ -86,14 +86,14 @@ testall_r(long double big, long double s return (ok); } -const char *comment = NULL; +static const char *comment = NULL; /* * Test all the functions: fmaxf, fmax, fmaxl, fminf, fmin, and fminl, * in all rounding modes and with the arguments in different orders. * The input 'big' must be >= 'small'. */ -void +static void testall(int testnum, long double big, long double small) { static const int rmodes[] = { @@ -122,7 +122,7 @@ testall(int testnum, long double big, lo #endif int -main(int argc, char *argv[]) +main(void) { printf("1..12\n"); Modified: stable/11/lib/msun/tests/invctrig_test.c ============================================================================== --- stable/11/lib/msun/tests/invctrig_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/invctrig_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -31,6 +31,7 @@ #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -123,7 +124,7 @@ c3pi = 9.4247779607693797153879301498385 /* Tests for 0 */ -void +static void test_zero(void) { long double complex zero = CMPLXL(0.0, 0.0); @@ -143,8 +144,8 @@ test_zero(void) /* * Tests for NaN inputs. */ -void -test_nan() +static void +test_nan(void) { long double complex nan_nan = CMPLXL(NAN, NAN); long double complex z; @@ -154,7 +155,7 @@ test_nan() * NaN,NaN NaN,NaN NaN,NaN NaN,NaN NaN,NaN * finite,NaN NaN,NaN* NaN,NaN* NaN,NaN* NaN,NaN* * NaN,finite NaN,NaN* NaN,NaN* NaN,NaN* NaN,NaN* - * NaN,Inf Inf,NaN NaN,-Inf ?Inf,NaN ?0,pi/2 + * NaN,Inf Inf,NaN NaN,-Inf ?Inf,NaN ?0,pi/2 * +-Inf,NaN Inf,NaN NaN,?Inf +-Inf,NaN +-0,NaN * +-0,NaN NaN,NaN* pi/2,NaN NaN,NaN* +-0,NaN * NaN,0 NaN,NaN* NaN,NaN* NaN,0 NaN,NaN* @@ -222,7 +223,7 @@ test_nan() testall(catan, z, CMPLXL(NAN, 0.0), ALL_STD_EXCEPT, 0, 0); } -void +static void test_inf(void) { long double complex z; @@ -269,16 +270,16 @@ test_inf(void) } /* Tests along the real and imaginary axes. */ -void +static void test_axes(void) { static const long double nums[] = { -2, -1, -0.5, 0.5, 1, 2 }; long double complex z; - int i; + unsigned i; - for (i = 0; i < sizeof(nums) / sizeof(nums[0]); i++) { + for (i = 0; i < nitems(nums); i++) { /* Real axis */ z = CMPLXL(nums[i], 0.0); if (fabsl(nums[i]) <= 1) { @@ -306,7 +307,7 @@ test_axes(void) } } -void +static void test_small(void) { /* @@ -332,7 +333,7 @@ test_small(void) } /* Test inputs that might cause overflow in a sloppy implementation. */ -void +static void test_large(void) { @@ -340,7 +341,7 @@ test_large(void) } int -main(int argc, char *argv[]) +main(void) { printf("1..6\n"); Modified: stable/11/lib/msun/tests/invtrig_test.c ============================================================================== --- stable/11/lib/msun/tests/invtrig_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/invtrig_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -110,11 +110,10 @@ __FBSDID("$FreeBSD$"); #define testall2(prefix, y, x, result, excepts) \ testall2_tol(prefix, (y), (x), (result), 0, (excepts)) -long double +static long double pi = 3.14159265358979323846264338327950280e+00L, pio3 = 1.04719755119659774615421446109316766e+00L, c3pi = 9.42477796076937971538793014983850839e+00L, -c5pi = 1.57079632679489661923132169163975140e+01L, c7pi = 2.19911485751285526692385036829565196e+01L, c5pio3 = 5.23598775598298873077107230546583851e+00L, sqrt2m1 = 4.14213562373095048801688724209698081e-01L; @@ -444,7 +443,7 @@ test_inverse(void) } int -main(int argc, char *argv[]) +main(void) { #if defined(__i386__) Modified: stable/11/lib/msun/tests/logarithm_test.c ============================================================================== --- stable/11/lib/msun/tests/logarithm_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/logarithm_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -31,6 +31,7 @@ #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -98,7 +99,7 @@ __FBSDID("$FreeBSD$"); test(log1pl, x, result, exceptmask, excepts); \ } while (0) -void +static void run_generic_tests(void) { @@ -127,10 +128,10 @@ run_generic_tests(void) testall1(-1.0, -INFINITY, ALL_STD_EXCEPT & ~FE_INEXACT, FE_DIVBYZERO); } -void +static void run_log2_tests(void) { - int i; + unsigned i; /* * We should insist that log2() return exactly the correct @@ -154,7 +155,7 @@ run_log2_tests(void) } } -void +static void run_roundingmode_tests(void) { @@ -188,7 +189,7 @@ run_roundingmode_tests(void) fesetround(FE_TONEAREST); } -void +static void run_accuracy_tests(void) { static const struct { @@ -219,9 +220,9 @@ run_accuracy_tests(void) 7.229787154734166181706169344438271459e1L, 3.139856666636059855894123306947856631e1L }, }; - int i; + unsigned i; - for (i = 0; i < sizeof(tests) / sizeof(tests[0]); i++) { + for (i = 0; i < nitems(tests); i++) { test_tol(log2, tests[i].x, tests[i].log2x, DBL_ULP()); test_tol(log2f, tests[i].x, tests[i].log2x, FLT_ULP()); test_tol(log2l, tests[i].x, tests[i].log2x, LDBL_ULP()); @@ -242,7 +243,7 @@ run_accuracy_tests(void) } } -void +static void run_log1p_accuracy_tests(void) { @@ -262,7 +263,7 @@ run_log1p_accuracy_tests(void) } int -main(int argc, char *argv[]) +main(void) { printf("1..5\n"); Modified: stable/11/lib/msun/tests/lrint_test.c ============================================================================== --- stable/11/lib/msun/tests/lrint_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/lrint_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -65,7 +65,7 @@ __FBSDID("$FreeBSD$"); #pragma STDC FENV_ACCESS ON -void +static void run_tests(void) { @@ -132,7 +132,7 @@ run_tests(void) } int -main(int argc, char *argv[]) +main(void) { printf("1..1\n"); Modified: stable/11/lib/msun/tests/nan_test.c ============================================================================== --- stable/11/lib/msun/tests/nan_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/nan_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -32,6 +32,7 @@ #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -41,7 +42,7 @@ __FBSDID("$FreeBSD$"); #include #include -void +static void testnan(const char *nan_format) { char nan_str[128]; @@ -49,10 +50,10 @@ testnan(const char *nan_format) long double ald[4]; double ad[4]; float af[4]; - int i; + unsigned i; snprintf(nan_str, sizeof(nan_str), "nan(%s)", nan_format); - for (i = 0; i < 4; i++) { + for (i = 0; i < nitems(ad); i++) { /* * x86 has an 80-bit long double stored in 96 bits, * so we need to initialize the memory for the memcmp() @@ -61,7 +62,6 @@ testnan(const char *nan_format) bzero(&af[i], sizeof(float)); bzero(&ad[i], sizeof(double)); bzero(&ald[i], sizeof(long double)); - } af[0] = nanf(nan_format); @@ -105,7 +105,7 @@ testnan(const char *nan_format) } int -main(int argc, char *argv[]) +main(void) { printf("1..1\n"); Modified: stable/11/lib/msun/tests/nearbyint_test.c ============================================================================== --- stable/11/lib/msun/tests/nearbyint_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/nearbyint_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -35,6 +35,7 @@ #include __FBSDID("$FreeBSD$"); +#include #include #include #include @@ -49,9 +50,9 @@ static const int rmodes[] = { }; /* Make sure we're testing the library, not some broken compiler built-ins. */ -double (*libnearbyint)(double) = nearbyint; -float (*libnearbyintf)(float) = nearbyintf; -long double (*libnearbyintl)(long double) = nearbyintl; +static double (*libnearbyint)(double) = nearbyint; +static float (*libnearbyintf)(float) = nearbyintf; +static long double (*libnearbyintl)(long double) = nearbyintl; #define nearbyintf libnearbyintf #define nearbyint libnearbyint #define nearbyintl libnearbyintl @@ -69,8 +70,6 @@ static const struct { { NAN, { NAN, NAN, NAN }}, }; -static const int ntests = sizeof(tests) / sizeof(tests[0]); - /* Get the appropriate result for the current rounding mode. */ static float get_output(int testindex, int rmodeindex, int negative) @@ -93,7 +92,7 @@ static void test_nearby(int testindex) { float in, out; - int i; + unsigned i; for (i = 0; i < sizeof(rmodes) / sizeof(rmodes[0]); i++) { fesetround(rmodes[i]); @@ -124,7 +123,7 @@ test_modf(int testindex) float ipartf, ipart_expected; double ipart; long double ipartl; - int i; + unsigned i; for (i = 0; i < sizeof(rmodes) / sizeof(rmodes[0]); i++) { fesetround(rmodes[i]); @@ -161,13 +160,13 @@ test_modf(int testindex) } int -main(int argc, char *argv[]) +main(void) { - int i; + unsigned i; - printf("1..%d\n", ntests * 2); + printf("1..%zu\n", (size_t)(nitems(tests) * 2)); testnum = 1; - for (i = 0; i < ntests; i++) { + for (i = 0; i < nitems(tests); i++) { test_nearby(i); test_modf(i); } Modified: stable/11/lib/msun/tests/next_test.c ============================================================================== --- stable/11/lib/msun/tests/next_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/next_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -73,7 +73,7 @@ static double idd(double); static float idf(float); int -main(int argc, char *argv[]) +main(void) { static const int ex_under = FE_UNDERFLOW | FE_INEXACT; /* shorthand */ static const int ex_over = FE_OVERFLOW | FE_INEXACT; Modified: stable/11/lib/msun/tests/rem_test.c ============================================================================== --- stable/11/lib/msun/tests/rem_test.c Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/rem_test.c Sun Mar 12 04:52:09 2017 (r315121) @@ -52,7 +52,7 @@ static void testf(float, float, float, i } while (0) int -main(int argc, char *argv[]) +main(void) { printf("1..3\n"); Modified: stable/11/lib/msun/tests/test-utils.h ============================================================================== --- stable/11/lib/msun/tests/test-utils.h Sun Mar 12 04:41:38 2017 (r315120) +++ stable/11/lib/msun/tests/test-utils.h Sun Mar 12 04:52:09 2017 (r315121) @@ -88,6 +88,13 @@ CMPLXL(long double x, long double y) } #endif +static int fpequal(long double, long double) __used; +static int cfpequal(long double complex, long double complex) __used; +static int cfpequal_cs(long double complex, long double complex, + int) __used; +static int cfpequal_tol(long double complex, long double complex, + long double, unsigned int) __used; + *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Sun Mar 12 04:53:28 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAC46D09EF5; Sun, 12 Mar 2017 04:53:28 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AA56C1E5A; Sun, 12 Mar 2017 04:53:28 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4rRgD054223; Sun, 12 Mar 2017 04:53:27 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4rR9Z054222; Sun, 12 Mar 2017 04:53:27 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120453.v2C4rR9Z054222@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:53:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315122 - stable/10/lib/libcam X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:53:29 -0000 Author: ngie Date: Sun Mar 12 04:53:27 2017 New Revision: 315122 URL: https://svnweb.freebsd.org/changeset/base/315122 Log: MFC r314189,r314190,r314191: r314189: Fix up NULL/'\0' uses and fix 2 derefs after NULL CID: 1018898, 1018899 r314190: Fix some minor style nits: put parentheses around return values r314191: Fix up r314189 The conditional in do_buff_decode(..) after the while loop was accidentally inverted. Only increment the pointer for fmt if it's not NUL. Modified: stable/10/lib/libcam/scsi_cmdparse.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libcam/scsi_cmdparse.c ============================================================================== --- stable/10/lib/libcam/scsi_cmdparse.c Sun Mar 12 04:52:09 2017 (r315121) +++ stable/10/lib/libcam/scsi_cmdparse.c Sun Mar 12 04:53:27 2017 (r315122) @@ -128,14 +128,14 @@ do_buff_decode(u_int8_t *buff, size_t le *(va_arg(*ap, int *)) = (ARG); \ assigned++; \ } \ - field_name[0] = 0; \ + field_name[0] = '\0'; \ suppress = 0; \ } while (0) u_char bits = 0; /* For bit fields */ int shift = 0; /* Bits already shifted out */ suppress = 0; - field_name[0] = 0; + field_name[0] = '\0'; while (!done) { switch(letter = *fmt) { @@ -169,9 +169,9 @@ do_buff_decode(u_int8_t *buff, size_t le fmt++; } - if (fmt) + if (*fmt != '\0') fmt++; /* Skip '}' */ - field_name[i] = 0; + field_name[i] = '\0'; break; } @@ -255,7 +255,7 @@ do_buff_decode(u_int8_t *buff, size_t le break; } if (!suppress) { - if (arg_put) + if (arg_put != NULL) (*arg_put)(puthook, (letter == 't' ? 'b' : letter), &buff[ind], width, field_name); @@ -268,7 +268,7 @@ do_buff_decode(u_int8_t *buff, size_t le for (p = dest + width - 1; p >= dest && *p == ' '; p--) - *p = 0; + *p = '\0'; } } assigned++; @@ -379,22 +379,22 @@ next_field(const char **pp, char *fmt, i field_size = 8; /* Default to byte field type... */ *fmt = 'i'; field_width = 1; /* 1 byte wide */ - if (name) - *name = 0; + if (name != NULL) + *name = '\0'; state = BETWEEN_FIELDS; while (state != DONE) { switch(state) { case BETWEEN_FIELDS: - if (*p == 0) + if (*p == '\0') state = DONE; else if (isspace(*p)) p++; else if (*p == '#') { while (*p && *p != '\n') p++; - if (p) + if (*p != '\0') p++; } else if (*p == '{') { int i = 0; @@ -410,7 +410,7 @@ next_field(const char **pp, char *fmt, i } if(name && i < n_name) - name[i] = 0; + name[i] = '\0'; if (*p == '}') p++; @@ -530,7 +530,7 @@ next_field(const char **pp, char *fmt, i if (is_error) { *error_p = 1; - return 0; + return (0); } *error_p = 0; @@ -568,7 +568,7 @@ do_encode(u_char *buff, size_t vec_max, if (suppress) value = 0; else - value = arg_get ? + value = arg_get != NULL ? (*arg_get)(gethook, field_name) : va_arg(*ap, int); } @@ -659,9 +659,9 @@ do_encode(u_char *buff, size_t vec_max, *used = ind; if (error) - return -1; + return (-1); - return encoded; + return (encoded); } int @@ -672,8 +672,8 @@ csio_decode(struct ccb_scsiio *csio, con va_start(ap, fmt); - retval = do_buff_decode(csio->data_ptr, (size_t)csio->dxfer_len, 0, 0, - fmt, &ap); + retval = do_buff_decode(csio->data_ptr, (size_t)csio->dxfer_len, + NULL, NULL, fmt, &ap); va_end(ap); @@ -705,7 +705,7 @@ buff_decode(u_int8_t *buff, size_t len, va_start(ap, fmt); - retval = do_buff_decode(buff, len, 0, 0, fmt, &ap); + retval = do_buff_decode(buff, len, NULL, NULL, fmt, &ap); va_end(ap); @@ -723,7 +723,7 @@ buff_decode_visit(u_int8_t *buff, size_t * the arg_put function. */ if (arg_put == NULL) - return(-1); + return (-1); return (do_buff_decode(buff, len, arg_put, puthook, fmt, NULL)); } @@ -779,20 +779,20 @@ csio_build_visit(struct ccb_scsiio *csio int retval; if (csio == NULL) - return(0); + return (0); /* * We need something to encode, but we can't get it without the * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); bzero(csio, sizeof(struct ccb_scsiio)); if ((retval = do_encode(csio->cdb_io.cdb_bytes, SCSI_MAX_CDBLEN, &cmdlen, arg_get, gethook, cmd_spec, NULL)) == -1) - return(retval); + return (retval); cam_fill_csio(csio, /* retries */ retry_count, @@ -805,7 +805,7 @@ csio_build_visit(struct ccb_scsiio *csio /* cdb_len */ cmdlen, /* timeout */ timeout ? timeout : 5000); - return(retval); + return (retval); } int @@ -819,7 +819,8 @@ csio_encode(struct ccb_scsiio *csio, con va_start(ap, fmt); - retval = do_encode(csio->data_ptr, csio->dxfer_len, 0, 0, 0, fmt, &ap); + retval = do_encode(csio->data_ptr, csio->dxfer_len, NULL, NULL, NULL, + fmt, &ap); va_end(ap); @@ -836,9 +837,9 @@ buff_encode_visit(u_int8_t *buff, size_t * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); - return (do_encode(buff, len, 0, arg_get, gethook, fmt, NULL)); + return (do_encode(buff, len, NULL, arg_get, gethook, fmt, NULL)); } int @@ -851,8 +852,8 @@ csio_encode_visit(struct ccb_scsiio *csi * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); - return (do_encode(csio->data_ptr, csio->dxfer_len, 0, arg_get, + return (do_encode(csio->data_ptr, csio->dxfer_len, NULL, arg_get, gethook, fmt, NULL)); } From owner-svn-src-all@freebsd.org Sun Mar 12 04:53:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9B540D09F41; Sun, 12 Mar 2017 04:53:49 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5C1801F96; Sun, 12 Mar 2017 04:53:49 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4rmjY054279; Sun, 12 Mar 2017 04:53:48 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4rmGf054278; Sun, 12 Mar 2017 04:53:48 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120453.v2C4rmGf054278@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:53: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: r315123 - stable/11/lib/libcam X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:53:49 -0000 Author: ngie Date: Sun Mar 12 04:53:48 2017 New Revision: 315123 URL: https://svnweb.freebsd.org/changeset/base/315123 Log: MFC r314189,r314190,r314191: r314189: Fix up NULL/'\0' uses and fix 2 derefs after NULL CID: 1018898, 1018899 r314190: Fix some minor style nits: put parentheses around return values r314191: Fix up r314189 The conditional in do_buff_decode(..) after the while loop was accidentally inverted. Only increment the pointer for fmt if it's not NUL. Modified: stable/11/lib/libcam/scsi_cmdparse.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/libcam/scsi_cmdparse.c ============================================================================== --- stable/11/lib/libcam/scsi_cmdparse.c Sun Mar 12 04:53:27 2017 (r315122) +++ stable/11/lib/libcam/scsi_cmdparse.c Sun Mar 12 04:53:48 2017 (r315123) @@ -128,14 +128,14 @@ do_buff_decode(u_int8_t *buff, size_t le *(va_arg(*ap, int *)) = (ARG); \ assigned++; \ } \ - field_name[0] = 0; \ + field_name[0] = '\0'; \ suppress = 0; \ } while (0) u_char bits = 0; /* For bit fields */ int shift = 0; /* Bits already shifted out */ suppress = 0; - field_name[0] = 0; + field_name[0] = '\0'; while (!done) { switch(letter = *fmt) { @@ -169,9 +169,9 @@ do_buff_decode(u_int8_t *buff, size_t le fmt++; } - if (fmt) + if (*fmt != '\0') fmt++; /* Skip '}' */ - field_name[i] = 0; + field_name[i] = '\0'; break; } @@ -255,7 +255,7 @@ do_buff_decode(u_int8_t *buff, size_t le break; } if (!suppress) { - if (arg_put) + if (arg_put != NULL) (*arg_put)(puthook, (letter == 't' ? 'b' : letter), &buff[ind], width, field_name); @@ -268,7 +268,7 @@ do_buff_decode(u_int8_t *buff, size_t le for (p = dest + width - 1; p >= dest && *p == ' '; p--) - *p = 0; + *p = '\0'; } } assigned++; @@ -379,22 +379,22 @@ next_field(const char **pp, char *fmt, i field_size = 8; /* Default to byte field type... */ *fmt = 'i'; field_width = 1; /* 1 byte wide */ - if (name) - *name = 0; + if (name != NULL) + *name = '\0'; state = BETWEEN_FIELDS; while (state != DONE) { switch(state) { case BETWEEN_FIELDS: - if (*p == 0) + if (*p == '\0') state = DONE; else if (isspace(*p)) p++; else if (*p == '#') { while (*p && *p != '\n') p++; - if (p) + if (*p != '\0') p++; } else if (*p == '{') { int i = 0; @@ -410,7 +410,7 @@ next_field(const char **pp, char *fmt, i } if(name && i < n_name) - name[i] = 0; + name[i] = '\0'; if (*p == '}') p++; @@ -530,7 +530,7 @@ next_field(const char **pp, char *fmt, i if (is_error) { *error_p = 1; - return 0; + return (0); } *error_p = 0; @@ -568,7 +568,7 @@ do_encode(u_char *buff, size_t vec_max, if (suppress) value = 0; else - value = arg_get ? + value = arg_get != NULL ? (*arg_get)(gethook, field_name) : va_arg(*ap, int); } @@ -659,9 +659,9 @@ do_encode(u_char *buff, size_t vec_max, *used = ind; if (error) - return -1; + return (-1); - return encoded; + return (encoded); } int @@ -672,8 +672,8 @@ csio_decode(struct ccb_scsiio *csio, con va_start(ap, fmt); - retval = do_buff_decode(csio->data_ptr, (size_t)csio->dxfer_len, 0, 0, - fmt, &ap); + retval = do_buff_decode(csio->data_ptr, (size_t)csio->dxfer_len, + NULL, NULL, fmt, &ap); va_end(ap); @@ -705,7 +705,7 @@ buff_decode(u_int8_t *buff, size_t len, va_start(ap, fmt); - retval = do_buff_decode(buff, len, 0, 0, fmt, &ap); + retval = do_buff_decode(buff, len, NULL, NULL, fmt, &ap); va_end(ap); @@ -723,7 +723,7 @@ buff_decode_visit(u_int8_t *buff, size_t * the arg_put function. */ if (arg_put == NULL) - return(-1); + return (-1); return (do_buff_decode(buff, len, arg_put, puthook, fmt, NULL)); } @@ -779,20 +779,20 @@ csio_build_visit(struct ccb_scsiio *csio int retval; if (csio == NULL) - return(0); + return (0); /* * We need something to encode, but we can't get it without the * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); bzero(csio, sizeof(struct ccb_scsiio)); if ((retval = do_encode(csio->cdb_io.cdb_bytes, SCSI_MAX_CDBLEN, &cmdlen, arg_get, gethook, cmd_spec, NULL)) == -1) - return(retval); + return (retval); cam_fill_csio(csio, /* retries */ retry_count, @@ -805,7 +805,7 @@ csio_build_visit(struct ccb_scsiio *csio /* cdb_len */ cmdlen, /* timeout */ timeout ? timeout : 5000); - return(retval); + return (retval); } int @@ -819,7 +819,8 @@ csio_encode(struct ccb_scsiio *csio, con va_start(ap, fmt); - retval = do_encode(csio->data_ptr, csio->dxfer_len, 0, 0, 0, fmt, &ap); + retval = do_encode(csio->data_ptr, csio->dxfer_len, NULL, NULL, NULL, + fmt, &ap); va_end(ap); @@ -836,9 +837,9 @@ buff_encode_visit(u_int8_t *buff, size_t * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); - return (do_encode(buff, len, 0, arg_get, gethook, fmt, NULL)); + return (do_encode(buff, len, NULL, arg_get, gethook, fmt, NULL)); } int @@ -851,8 +852,8 @@ csio_encode_visit(struct ccb_scsiio *csi * arg_get function. */ if (arg_get == NULL) - return(-1); + return (-1); - return (do_encode(csio->data_ptr, csio->dxfer_len, 0, arg_get, + return (do_encode(csio->data_ptr, csio->dxfer_len, NULL, arg_get, gethook, fmt, NULL)); } From owner-svn-src-all@freebsd.org Sun Mar 12 04:55:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6961BD09FC6; Sun, 12 Mar 2017 04:55:04 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1CB7510EC; Sun, 12 Mar 2017 04:55:04 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4t32s054431; Sun, 12 Mar 2017 04:55:03 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4t3N6054430; Sun, 12 Mar 2017 04:55:03 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120455.v2C4t3N6054430@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:55:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315124 - stable/10/usr.sbin/syslogd X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:55:04 -0000 Author: ngie Date: Sun Mar 12 04:55:02 2017 New Revision: 315124 URL: https://svnweb.freebsd.org/changeset/base/315124 Log: MFC r314233: Parameterize out the length of struct filed->f_lasttime as `MAXDATELEN` This removes the hardcoded value for the field (16) and the equivalent hardcoded lengths in logmsg(..). This change is being done to help stage future work to add RFC5424/RFC5434 support to syslogd(8). Obtained from: Isilon OneFS (dcd33d13da) (as part of a larger change) Modified: stable/10/usr.sbin/syslogd/syslogd.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/syslogd/syslogd.c ============================================================================== --- stable/10/usr.sbin/syslogd/syslogd.c Sun Mar 12 04:53:48 2017 (r315123) +++ stable/10/usr.sbin/syslogd/syslogd.c Sun Mar 12 04:55:02 2017 (r315124) @@ -68,6 +68,8 @@ __FBSDID("$FreeBSD$"); * Priority comparison code by Harlan Stenn. */ +/* Maximum number of characters in time of last occurrence */ +#define MAXDATELEN 16 #define MAXLINE 1024 /* maximum line length */ #define MAXSVLINE MAXLINE /* maximum saved line length */ #define DEFUPRI (LOG_USER|LOG_NOTICE) @@ -185,7 +187,7 @@ struct filed { } f_pipe; } f_un; char f_prevline[MAXSVLINE]; /* last message logged */ - char f_lasttime[16]; /* time of last occurrence */ + char f_lasttime[MAXDATELEN]; /* time of last occurrence */ char f_prevhost[MAXHOSTNAMELEN]; /* host from which recd. */ int f_prevpri; /* pri of f_prevline */ int f_prevlen; /* length of f_prevline */ @@ -939,7 +941,7 @@ logmsg(int pri, const char *msg, const c * Check to see if msg looks non-standard. */ msglen = strlen(msg); - if (msglen < 16 || msg[3] != ' ' || msg[6] != ' ' || + if (msglen < MAXDATELEN || msg[3] != ' ' || msg[6] != ' ' || msg[9] != ':' || msg[12] != ':' || msg[15] != ' ') flags |= ADDDATE; @@ -948,8 +950,8 @@ logmsg(int pri, const char *msg, const c timestamp = ctime(&now) + 4; } else { timestamp = msg; - msg += 16; - msglen -= 16; + msg += MAXDATELEN; + msglen -= MAXDATELEN; } /* skip leading blanks */ From owner-svn-src-all@freebsd.org Sun Mar 12 04:55:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 43220D09FFE; Sun, 12 Mar 2017 04:55:08 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EBDD91104; Sun, 12 Mar 2017 04:55:07 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4t7pd054479; Sun, 12 Mar 2017 04:55:07 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4t7nC054478; Sun, 12 Mar 2017 04:55:07 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120455.v2C4t7nC054478@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:55: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: r315125 - stable/11/usr.sbin/syslogd X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:55:08 -0000 Author: ngie Date: Sun Mar 12 04:55:06 2017 New Revision: 315125 URL: https://svnweb.freebsd.org/changeset/base/315125 Log: MFC r314233: Parameterize out the length of struct filed->f_lasttime as `MAXDATELEN` This removes the hardcoded value for the field (16) and the equivalent hardcoded lengths in logmsg(..). This change is being done to help stage future work to add RFC5424/RFC5434 support to syslogd(8). Obtained from: Isilon OneFS (dcd33d13da) (as part of a larger change) Modified: stable/11/usr.sbin/syslogd/syslogd.c Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.sbin/syslogd/syslogd.c ============================================================================== --- stable/11/usr.sbin/syslogd/syslogd.c Sun Mar 12 04:55:02 2017 (r315124) +++ stable/11/usr.sbin/syslogd/syslogd.c Sun Mar 12 04:55:06 2017 (r315125) @@ -68,6 +68,8 @@ __FBSDID("$FreeBSD$"); * Priority comparison code by Harlan Stenn. */ +/* Maximum number of characters in time of last occurrence */ +#define MAXDATELEN 16 #define MAXLINE 1024 /* maximum line length */ #define MAXSVLINE MAXLINE /* maximum saved line length */ #define DEFUPRI (LOG_USER|LOG_NOTICE) @@ -197,7 +199,7 @@ struct filed { } f_pipe; } f_un; char f_prevline[MAXSVLINE]; /* last message logged */ - char f_lasttime[16]; /* time of last occurrence */ + char f_lasttime[MAXDATELEN]; /* time of last occurrence */ char f_prevhost[MAXHOSTNAMELEN]; /* host from which recd. */ int f_prevpri; /* pri of f_prevline */ int f_prevlen; /* length of f_prevline */ @@ -974,7 +976,7 @@ logmsg(int pri, const char *msg, const c * Check to see if msg looks non-standard. */ msglen = strlen(msg); - if (msglen < 16 || msg[3] != ' ' || msg[6] != ' ' || + if (msglen < MAXDATELEN || msg[3] != ' ' || msg[6] != ' ' || msg[9] != ':' || msg[12] != ':' || msg[15] != ' ') flags |= ADDDATE; @@ -983,8 +985,8 @@ logmsg(int pri, const char *msg, const c timestamp = ctime(&now) + 4; } else { timestamp = msg; - msg += 16; - msglen -= 16; + msg += MAXDATELEN; + msglen -= MAXDATELEN; } /* skip leading blanks */ From owner-svn-src-all@freebsd.org Sun Mar 12 04:56:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 401A8D080D0; Sun, 12 Mar 2017 04:56:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 183241385; Sun, 12 Mar 2017 04:56:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4uM14054775; Sun, 12 Mar 2017 04:56:22 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4uMHV054774; Sun, 12 Mar 2017 04:56:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120456.v2C4uMHV054774@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:56:22 +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: r315126 - stable/11/share/man/man4 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:56:23 -0000 Author: ngie Date: Sun Mar 12 04:56:21 2017 New Revision: 315126 URL: https://svnweb.freebsd.org/changeset/base/315126 Log: MFC r314610: Clean up ddb(4) slightly - Delete empty Li macro uses [1]. This removes some spaces between the optional command/subcommand arguments. - Attempt to clarify "show lock" subcommand by being more terse/direct. This addresses an issue with a contraction [2]. Modified: stable/11/share/man/man4/ddb.4 Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/ddb.4 ============================================================================== --- stable/11/share/man/man4/ddb.4 Sun Mar 12 04:55:06 2017 (r315125) +++ stable/11/share/man/man4/ddb.4 Sun Mar 12 04:56:21 2017 (r315126) @@ -60,7 +60,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 13, 2016 +.Dd March 3, 2017 .Dt DDB 4 .Os .Sh NAME @@ -146,7 +146,7 @@ to be the same as .Pp The general command syntax is: .Ar command Ns Op Li / Ns Ar modifier -.Oo Ar addr Oc Ns Op Li , Ns Ar count +.Oo Ar addr Oc Ns Op , Ns Ar count .Pp A blank line repeats the previous command from the address .Va next @@ -213,11 +213,11 @@ current line. .Bl -tag -width indent -compact .It Xo .Ic examine Ns Op Li / Ns Cm AISabcdghilmorsuxz ... -.Oo Ar addr Oc Ns Op Li , Ns Ar count +.Oo Ar addr Oc Ns Op , Ns Ar count .Xc .It Xo .Ic x Ns Op Li / Ns Cm AISabcdghilmorsuxz ... -.Oo Ar addr Oc Ns Op Li , Ns Ar count +.Oo Ar addr Oc Ns Op , Ns Ar count .Xc Display the addressed locations according to the formats in the modifier. Multiple modifier formats display multiple locations. @@ -343,8 +343,8 @@ Set the named variable or register with .Ar expr . Valid variable names are described below. .Pp -.It Ic break Ns Oo Li / Ns Cm u Oc Oo Ar addr Oc Ns Op Li , Ns Ar count -.It Ic b Ns Oo Li / Ns Cm u Oc Oo Ar addr Oc Ns Op Li , Ns Ar count +.It Ic break Ns Oo Li / Ns Cm u Oc Oo Ar addr Oc Ns Op , Ns Ar count +.It Ic b Ns Oo Li / Ns Cm u Oc Oo Ar addr Oc Ns Op , Ns Ar count Set a break point at .Ar addr . If @@ -394,7 +394,7 @@ command, or by omitting to get the default address of .Va dot . .Pp -.It Ic watch Oo Ar addr Oc Ns Op Li , Ns Ar size +.It Ic watch Oo Ar addr Oc Ns Op , Ns Ar size Set a watchpoint for a region. Execution stops when an attempt to modify the region occurs. The @@ -408,7 +408,7 @@ Attempts to watch wired kernel memory may cause unrecoverable error in some systems such as i386. Watchpoints on user addresses work best. .Pp -.It Ic hwatch Oo Ar addr Oc Ns Op Li , Ns Ar size +.It Ic hwatch Oo Ar addr Oc Ns Op , Ns Ar size Set a hardware watchpoint for a region if supported by the architecture. Execution stops when an attempt to modify the region occurs. @@ -424,11 +424,11 @@ Use for setting watchpoints on kernel address locations only, and avoid its use on user mode address spaces. .Pp -.It Ic dhwatch Oo Ar addr Oc Ns Op Li , Ns Ar size +.It Ic dhwatch Oo Ar addr Oc Ns Op , Ns Ar size Delete specified hardware watchpoint. .Pp -.It Ic step Ns Oo Li / Ns Cm p Oc Ns Op Li , Ns Ar count -.It Ic s Ns Oo Li / Ns Cm p Oc Ns Op Li , Ns Ar count +.It Ic step Ns Oo Li / Ns Cm p Oc Ns Op , Ns Ar count +.It Ic s Ns Oo Li / Ns Cm p Oc Ns Op , Ns Ar count Single step .Ar count times. @@ -478,22 +478,22 @@ Otherwise, only print when the matching .It Xo .Ic trace Ns Op Li / Ns Cm u .Op Ar pid | tid Ns -.Op Li , Ns Ar count +.Op , Ns Ar count .Xc .It Xo .Ic t Ns Op Li / Ns Cm u .Op Ar pid | tid Ns -.Op Li , Ns Ar count +.Op , Ns Ar count .Xc .It Xo .Ic where Ns Op Li / Ns Cm u .Op Ar pid | tid Ns -.Op Li , Ns Ar count +.Op , Ns Ar count .Xc .It Xo .Ic bt Ns Op Li / Ns Cm u .Op Ar pid | tid Ns -.Op Li , Ns Ar count +.Op , Ns Ar count .Xc Stack trace. The @@ -518,7 +518,7 @@ only if the machine dependent code suppo .Ar addr .Ar value .Op Ar mask Ns -.Op Li , Ns Ar count +.Op , Ns Ar count .Xc Search memory for .Ar value . @@ -768,12 +768,12 @@ Possible types include Name of the lock. .It Ic flags: Flags passed to the lock initialization function. -For exact possibilities see manual pages of possible lock types. +.Em flags +values are lock class specific. .It Ic state: Current state of a lock. -As well as -.Ic flags -it's lock-specific. +.Em state +values are lock class specific. .It Ic owner: Lock owner. .El From owner-svn-src-all@freebsd.org Sun Mar 12 04:57:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2217AD0815B; Sun, 12 Mar 2017 04:57:23 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E57031612; Sun, 12 Mar 2017 04:57:22 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4vMsD054909; Sun, 12 Mar 2017 04:57:22 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4vMK6054908; Sun, 12 Mar 2017 04:57:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120457.v2C4vMK6054908@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:57:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315127 - stable/10/share/man/man4 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:57:23 -0000 Author: ngie Date: Sun Mar 12 04:57:21 2017 New Revision: 315127 URL: https://svnweb.freebsd.org/changeset/base/315127 Log: MFC r314545: Add missing section to .Xr macro calls for wpifw(4) The driver manpage for wpifw(4) is missing, but will be added soon. This fixes the other 2 .Xr calls lacking sections to match the 3rd, syntactically correct, reference in the SEE ALSO section. Modified: stable/10/share/man/man4/wpi.4 Directory Properties: stable/10/ (props changed) Modified: stable/10/share/man/man4/wpi.4 ============================================================================== --- stable/10/share/man/man4/wpi.4 Sun Mar 12 04:56:21 2017 (r315126) +++ stable/10/share/man/man4/wpi.4 Sun Mar 12 04:57:21 2017 (r315127) @@ -69,7 +69,7 @@ For more information on configuring this .Xr ifconfig 8 . .Pp This driver requires the firmware built with the -.Nm wpifw +.Nm wpifw 4 module to work. .Sh FILES .Bl -tag -width ".Pa /usr/share/doc/legal/intel_wpi/LICENSE" -compact @@ -107,7 +107,7 @@ The driver failed to load the firmware i .Xr firmware 9 subsystem. Verify the -.Xr wpifw +.Xr wpifw 4 firmware module is installed. .It "wpi%d: fatal firmware error" An unknown error has occurred in the uploaded firmware, you may have to From owner-svn-src-all@freebsd.org Sun Mar 12 04:57:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6FF8DD081B8; Sun, 12 Mar 2017 04:57:36 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3A93C16E3; Sun, 12 Mar 2017 04:57:36 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4vZcM054962; Sun, 12 Mar 2017 04:57:35 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4vZmW054961; Sun, 12 Mar 2017 04:57:35 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120457.v2C4vZmW054961@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:57: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: r315128 - stable/11/share/man/man4 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:57:36 -0000 Author: ngie Date: Sun Mar 12 04:57:35 2017 New Revision: 315128 URL: https://svnweb.freebsd.org/changeset/base/315128 Log: MFC r314545: Add missing section to .Xr macro calls for wpifw(4) The driver manpage for wpifw(4) is missing, but will be added soon. This fixes the other 2 .Xr calls lacking sections to match the 3rd, syntactically correct, reference in the SEE ALSO section. Modified: stable/11/share/man/man4/wpi.4 Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/wpi.4 ============================================================================== --- stable/11/share/man/man4/wpi.4 Sun Mar 12 04:57:21 2017 (r315127) +++ stable/11/share/man/man4/wpi.4 Sun Mar 12 04:57:35 2017 (r315128) @@ -85,7 +85,7 @@ driver offloads both encryption and decr hardware for the CCMP cipher. .Pp This driver requires the firmware built with the -.Nm wpifw +.Nm wpifw 4 module to work. .Pp The @@ -144,7 +144,7 @@ The driver failed to load the firmware i .Xr firmware 9 subsystem. Verify the -.Xr wpifw +.Xr wpifw 4 firmware module is installed. .It "wpi%d: %s: timeout waiting for adapter to initialize, error %d" The onboard microcontroller failed to initialize in time. From owner-svn-src-all@freebsd.org Sun Mar 12 04:58:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2BE4DD08277; Sun, 12 Mar 2017 04:58:59 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ECB1C18C8; Sun, 12 Mar 2017 04:58:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4wwsD055118; Sun, 12 Mar 2017 04:58:58 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4wwIc055117; Sun, 12 Mar 2017 04:58:58 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120458.v2C4wwIc055117@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:58:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315129 - stable/10/share/man/man4 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:58:59 -0000 Author: ngie Date: Sun Mar 12 04:58:57 2017 New Revision: 315129 URL: https://svnweb.freebsd.org/changeset/base/315129 Log: MFC r314542: kern.cam.da.X.delete_method: add -width to .Bl macro call Now the section width is set appropriately per the BIO_DELETE parameter being described. Modified: stable/10/share/man/man4/da.4 Directory Properties: stable/10/ (props changed) Modified: stable/10/share/man/man4/da.4 ============================================================================== --- stable/10/share/man/man4/da.4 Sun Mar 12 04:57:35 2017 (r315128) +++ stable/10/share/man/man4/da.4 Sun Mar 12 04:58:57 2017 (r315129) @@ -156,7 +156,7 @@ Set to 1 to enable sorting, 0 to disable The default is sorting enabled for HDDs and disabled for SSDs. .It Va kern.cam.da. Ns Ar X Ns Va .delete_method This variable specifies method to handle BIO_DELETE requests: -.Bl -tag +.Bl -tag -width "ATA_TRIM" .It ATA_TRIM ATA TRIM via ATA COMMAND PASS THROUGH command, .It UNMAP From owner-svn-src-all@freebsd.org Sun Mar 12 04:59:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E7C79D082AA; Sun, 12 Mar 2017 04:59:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B409718EE; Sun, 12 Mar 2017 04:59:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C4x2oZ055170; Sun, 12 Mar 2017 04:59:02 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C4x2AA055169; Sun, 12 Mar 2017 04:59:02 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120459.v2C4x2AA055169@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 04:59: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: r315130 - stable/11/share/man/man4 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 04:59:04 -0000 Author: ngie Date: Sun Mar 12 04:59:02 2017 New Revision: 315130 URL: https://svnweb.freebsd.org/changeset/base/315130 Log: MFC r314542: kern.cam.da.X.delete_method: add -width to .Bl macro call Now the section width is set appropriately per the BIO_DELETE parameter being described. Modified: stable/11/share/man/man4/da.4 Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/da.4 ============================================================================== --- stable/11/share/man/man4/da.4 Sun Mar 12 04:58:57 2017 (r315129) +++ stable/11/share/man/man4/da.4 Sun Mar 12 04:59:02 2017 (r315130) @@ -156,7 +156,7 @@ Set to 1 to enable sorting, 0 to disable The default is sorting enabled for HDDs and disabled for SSDs. .It Va kern.cam.da. Ns Ar X Ns Va .delete_method This variable specifies method to handle BIO_DELETE requests: -.Bl -tag +.Bl -tag -width "ATA_TRIM" .It ATA_TRIM ATA TRIM via ATA COMMAND PASS THROUGH command, .It UNMAP From owner-svn-src-all@freebsd.org Sun Mar 12 05:00:05 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8B4FAD0836F; Sun, 12 Mar 2017 05:00:05 +0000 (UTC) (envelope-from kp@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 5B3021B6D; Sun, 12 Mar 2017 05:00:05 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C504e9055296; Sun, 12 Mar 2017 05:00:04 GMT (envelope-from kp@FreeBSD.org) Received: (from kp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C504fH055295; Sun, 12 Mar 2017 05:00:04 GMT (envelope-from kp@FreeBSD.org) Message-Id: <201703120500.v2C504fH055295@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kp set sender to kp@FreeBSD.org using -f From: Kristof Provost Date: Sun, 12 Mar 2017 05:00:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315131 - head/sys/netpfil/pf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:00:05 -0000 Author: kp Date: Sun Mar 12 05:00:04 2017 New Revision: 315131 URL: https://svnweb.freebsd.org/changeset/base/315131 Log: pf: Do not lose the VNET lock when ending the purge thread When the pf_purge_thread() exits it must make sure to release the VNET_LIST_RLOCK it still holds. kproc_exit() does not return. Modified: head/sys/netpfil/pf/pf.c Modified: head/sys/netpfil/pf/pf.c ============================================================================== --- head/sys/netpfil/pf/pf.c Sun Mar 12 04:59:02 2017 (r315130) +++ head/sys/netpfil/pf/pf.c Sun Mar 12 05:00:04 2017 (r315131) @@ -1440,6 +1440,7 @@ pf_purge_thread(void *unused __unused) if (pf_end_threads) { pf_end_threads++; wakeup(pf_purge_thread); + VNET_LIST_RUNLOCK(); kproc_exit(0); } From owner-svn-src-all@freebsd.org Sun Mar 12 05:07:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 64551D08829; Sun, 12 Mar 2017 05:07:35 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 11F2E101D; Sun, 12 Mar 2017 05:07:34 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C57Yr9059279; Sun, 12 Mar 2017 05:07:34 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C57Ysa059278; Sun, 12 Mar 2017 05:07:34 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120507.v2C57Ysa059278@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 05:07:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315132 - head/lib/libcam X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:07:35 -0000 Author: ngie Date: Sun Mar 12 05:07:33 2017 New Revision: 315132 URL: https://svnweb.freebsd.org/changeset/base/315132 Log: Use .Dv when referencing NULL This is the correct markup macro, as opposed to .Va (variable names) While here, annotate several bare references to `NULL` with .Dv. MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/lib/libcam/cam.3 Modified: head/lib/libcam/cam.3 ============================================================================== --- head/lib/libcam/cam.3 Sun Mar 12 05:00:04 2017 (r315131) +++ head/lib/libcam/cam.3 Sun Mar 12 05:07:33 2017 (r315132) @@ -27,7 +27,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 10, 1998 +.Dd March 11, 2017 .Dt CAM 3 .Os .Sh NAME @@ -208,7 +208,7 @@ structure. If the .Ar device argument is -.Va NULL , +.Dv NULL , .Fn cam_open_spec_device will allocate space for the .Va cam_device @@ -258,7 +258,9 @@ argument, as with .Fn cam_open_spec_device and .Fn cam_open_btl , -should be NULL if the user wants the CAM library to allocate space for the +should be +.Dv NULL +if the user wants the CAM library to allocate space for the .Va cam_device structure. .Fn cam_close_device @@ -365,11 +367,14 @@ and .Fn cam_open_pass return a pointer to a .Va cam_device -structure, or NULL if there was an error. +structure, or +.Dv NULL +if there was an error. .Pp .Fn cam_getccb -returns an allocated and partially initialized CCB, or NULL if allocation -of the CCB failed. +returns an allocated and partially initialized CCB, or +.Dv NULL +if allocation of the CCB failed. .Pp .Fn cam_send_ccb returns a value of -1 if an error occurred, and @@ -386,7 +391,9 @@ that is passed into .Fn cam_device_dup returns a copy of the .Va device -passed in, or NULL if an error occurred. +passed in, or +.Dv NULL +if an error occurred. .Pp .Fn cam_get_device returns 0 for success, and -1 to indicate failure. From owner-svn-src-all@freebsd.org Sun Mar 12 05:20:50 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EA3ADD08ADE; Sun, 12 Mar 2017 05:20:50 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B070B1637; Sun, 12 Mar 2017 05:20:50 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C5KnKw063482; Sun, 12 Mar 2017 05:20:49 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C5KnPW063481; Sun, 12 Mar 2017 05:20:49 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703120520.v2C5KnPW063481@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sun, 12 Mar 2017 05:20:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315133 - head/lib/libcam X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:20:51 -0000 Author: ngie Date: Sun Mar 12 05:20:49 2017 New Revision: 315133 URL: https://svnweb.freebsd.org/changeset/base/315133 Log: lib/libcam/cam.3: fix manpage warnings - spelling: "mis-named" should be "misnamed". - delete spaces interspersed in literal representation of `struct cam_device` as hard-tabs separate the types and fields. - Add commas after `e.g.`. Reported by: igor MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/lib/libcam/cam.3 Modified: head/lib/libcam/cam.3 ============================================================================== --- head/lib/libcam/cam.3 Sun Mar 12 05:07:33 2017 (r315132) +++ head/lib/libcam/cam.3 Sun Mar 12 05:20:49 2017 (r315133) @@ -132,7 +132,7 @@ Many of the CAM library functions use th structure: .Bd -literal struct cam_device { - char device_path[MAXPATHLEN+1];/* + char device_path[MAXPATHLEN+1];/* * Pathname of the * device given by the * user. This may be @@ -151,7 +151,7 @@ struct cam_device { */ char device_name[DEV_IDLEN+1];/* * Name of the device, - * e.g. 'pass' + * e.g., 'pass' */ uint32_t dev_unit_num; /* Unit number of the passthrough * device associated with this @@ -159,7 +159,7 @@ struct cam_device { */ char sim_name[SIM_IDLEN+1];/* - * Controller name, e.g.'ahc' + * Controller name, e.g., 'ahc' */ uint32_t sim_unit_number; /* Controller unit number */ uint32_t bus_id; /* Controller bus number */ @@ -429,4 +429,4 @@ require a definitive way to identify a d .Xr pass 4 device. .Pp -Some of the functions are possibly mis-named or poorly named. +Some of the functions are possibly misnamed or poorly named. From owner-svn-src-all@freebsd.org Sun Mar 12 05:35:29 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CB15ACF9134; Sun, 12 Mar 2017 05:35:29 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8BB6D1E5D; Sun, 12 Mar 2017 05:35:29 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C5ZSjN071496; Sun, 12 Mar 2017 05:35:28 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C5ZSYE071493; Sun, 12 Mar 2017 05:35:28 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120535.v2C5ZSYE071493@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 05:35:28 +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: r315134 - stable/11/usr.bin/dc X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:35:29 -0000 Author: pfg Date: Sun Mar 12 05:35:28 2017 New Revision: 315134 URL: https://svnweb.freebsd.org/changeset/base/315134 Log: MFC r314321: dc(1): Merge minor changes from OpenBSD. Prefer setvbuf() to setlinebuf() for portability. Some style(9) and redundant tests for NULL. These are only meant to ease up merging newer changes. Obtained from: OpenBSD Modified: stable/11/usr.bin/dc/bcode.c stable/11/usr.bin/dc/dc.c stable/11/usr.bin/dc/stack.c Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.bin/dc/bcode.c ============================================================================== --- stable/11/usr.bin/dc/bcode.c Sun Mar 12 05:20:49 2017 (r315133) +++ stable/11/usr.bin/dc/bcode.c Sun Mar 12 05:35:28 2017 (r315134) @@ -960,9 +960,8 @@ badd(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -987,9 +986,8 @@ bsub(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1035,9 +1033,8 @@ bmul(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1060,9 +1057,8 @@ bdiv(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1097,9 +1093,8 @@ bmod(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1134,9 +1129,8 @@ bdivmod(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1176,9 +1170,8 @@ bexp(void) u_int rscale; p = pop_number(); - if (p == NULL) { + if (p == NULL) return; - } a = pop_number(); if (a == NULL) { push_number(p); @@ -1299,9 +1292,8 @@ bsqrt(void) onecount = 0; n = pop_number(); - if (n == NULL) { + if (n == NULL) return; - } if (BN_is_zero(n->number)) { r = new_number(); push_number(r); @@ -1342,9 +1334,8 @@ not(void) struct number *a; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } a->scale = 0; bn_check(BN_set_word(a->number, BN_get_word(a->number) ? 0 : 1)); push_number(a); @@ -1363,9 +1354,8 @@ equal_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1383,9 +1373,8 @@ less_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1403,9 +1392,8 @@ lesseq_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1736,9 +1724,8 @@ eval_tos(void) char *p; p = pop_string(); - if (p == NULL) - return; - eval_string(p); + if (p != NULL) + eval_string(p); } void Modified: stable/11/usr.bin/dc/dc.c ============================================================================== --- stable/11/usr.bin/dc/dc.c Sun Mar 12 05:20:49 2017 (r315133) +++ stable/11/usr.bin/dc/dc.c Sun Mar 12 05:35:28 2017 (r315134) @@ -120,8 +120,8 @@ main(int argc, char *argv[]) if (!preproc_done) init_bmachine(extended_regs); - setlinebuf(stdout); - setlinebuf(stderr); + (void)setvbuf(stdout, NULL, _IOLBF, 0); + (void)setvbuf(stderr, NULL, _IOLBF, 0); if (argc > 1) usage(); Modified: stable/11/usr.bin/dc/stack.c ============================================================================== --- stable/11/usr.bin/dc/stack.c Sun Mar 12 05:20:49 2017 (r315133) +++ stable/11/usr.bin/dc/stack.c Sun Mar 12 05:35:28 2017 (r315134) @@ -68,10 +68,8 @@ stack_free_value(struct value *v) free(v->u.string); break; } - if (v->array != NULL) { - array_free(v->array); - v->array = NULL; - } + array_free(v->array); + v->array = NULL; } /* Copy number or string content into already allocated target */ @@ -225,10 +223,8 @@ stack_popnumber(struct stack *stack) if (stack_empty(stack)) return (NULL); - if (stack->stack[stack->sp].array != NULL) { - array_free(stack->stack[stack->sp].array); - stack->stack[stack->sp].array = NULL; - } + array_free(stack->stack[stack->sp].array); + stack->stack[stack->sp].array = NULL; if (stack->stack[stack->sp].type != BCODE_NUMBER) { warnx("not a number"); /* XXX remove */ return (NULL); @@ -242,10 +238,8 @@ stack_popstring(struct stack *stack) if (stack_empty(stack)) return (NULL); - if (stack->stack[stack->sp].array != NULL) { - array_free(stack->stack[stack->sp].array); - stack->stack[stack->sp].array = NULL; - } + array_free(stack->stack[stack->sp].array); + stack->stack[stack->sp].array = NULL; if (stack->stack[stack->sp].type != BCODE_STRING) { warnx("not a string"); /* XXX remove */ return (NULL); @@ -257,9 +251,8 @@ void stack_clear(struct stack *stack) { - while (stack->sp >= 0) { + while (stack->sp >= 0) stack_free_value(&stack->stack[stack->sp--]); - } free(stack->stack); stack_init(stack); } From owner-svn-src-all@freebsd.org Sun Mar 12 05:36:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 718CBCF91B2; Sun, 12 Mar 2017 05:36:33 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 33DD81FB4; Sun, 12 Mar 2017 05:36:33 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C5aWts071577; Sun, 12 Mar 2017 05:36:32 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C5aW9K071574; Sun, 12 Mar 2017 05:36:32 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703120536.v2C5aW9K071574@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 05:36:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315135 - stable/10/usr.bin/dc X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:36:33 -0000 Author: pfg Date: Sun Mar 12 05:36:31 2017 New Revision: 315135 URL: https://svnweb.freebsd.org/changeset/base/315135 Log: MFC r314321: dc(1): Merge minor changes from OpenBSD. Prefer setvbuf() to setlinebuf() for portability. Some style(9) and redundant tests for NULL. These are only meant to ease up merging newer changes. Obtained from: OpenBSD Modified: stable/10/usr.bin/dc/bcode.c stable/10/usr.bin/dc/dc.c stable/10/usr.bin/dc/stack.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.bin/dc/bcode.c ============================================================================== --- stable/10/usr.bin/dc/bcode.c Sun Mar 12 05:35:28 2017 (r315134) +++ stable/10/usr.bin/dc/bcode.c Sun Mar 12 05:36:31 2017 (r315135) @@ -960,9 +960,8 @@ badd(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -987,9 +986,8 @@ bsub(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1035,9 +1033,8 @@ bmul(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1060,9 +1057,8 @@ bdiv(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1097,9 +1093,8 @@ bmod(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1134,9 +1129,8 @@ bdivmod(void) u_int scale; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1176,9 +1170,8 @@ bexp(void) u_int rscale; p = pop_number(); - if (p == NULL) { + if (p == NULL) return; - } a = pop_number(); if (a == NULL) { push_number(p); @@ -1299,9 +1292,8 @@ bsqrt(void) onecount = 0; n = pop_number(); - if (n == NULL) { + if (n == NULL) return; - } if (BN_is_zero(n->number)) { r = new_number(); push_number(r); @@ -1342,9 +1334,8 @@ not(void) struct number *a; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } a->scale = 0; bn_check(BN_set_word(a->number, BN_get_word(a->number) ? 0 : 1)); push_number(a); @@ -1363,9 +1354,8 @@ equal_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1383,9 +1373,8 @@ less_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1403,9 +1392,8 @@ lesseq_numbers(void) struct number *a, *b, *r; a = pop_number(); - if (a == NULL) { + if (a == NULL) return; - } b = pop_number(); if (b == NULL) { push_number(a); @@ -1736,9 +1724,8 @@ eval_tos(void) char *p; p = pop_string(); - if (p == NULL) - return; - eval_string(p); + if (p != NULL) + eval_string(p); } void Modified: stable/10/usr.bin/dc/dc.c ============================================================================== --- stable/10/usr.bin/dc/dc.c Sun Mar 12 05:35:28 2017 (r315134) +++ stable/10/usr.bin/dc/dc.c Sun Mar 12 05:36:31 2017 (r315135) @@ -120,8 +120,8 @@ main(int argc, char *argv[]) if (!preproc_done) init_bmachine(extended_regs); - setlinebuf(stdout); - setlinebuf(stderr); + (void)setvbuf(stdout, NULL, _IOLBF, 0); + (void)setvbuf(stderr, NULL, _IOLBF, 0); if (argc > 1) usage(); Modified: stable/10/usr.bin/dc/stack.c ============================================================================== --- stable/10/usr.bin/dc/stack.c Sun Mar 12 05:35:28 2017 (r315134) +++ stable/10/usr.bin/dc/stack.c Sun Mar 12 05:36:31 2017 (r315135) @@ -68,10 +68,8 @@ stack_free_value(struct value *v) free(v->u.string); break; } - if (v->array != NULL) { - array_free(v->array); - v->array = NULL; - } + array_free(v->array); + v->array = NULL; } /* Copy number or string content into already allocated target */ @@ -225,10 +223,8 @@ stack_popnumber(struct stack *stack) if (stack_empty(stack)) return (NULL); - if (stack->stack[stack->sp].array != NULL) { - array_free(stack->stack[stack->sp].array); - stack->stack[stack->sp].array = NULL; - } + array_free(stack->stack[stack->sp].array); + stack->stack[stack->sp].array = NULL; if (stack->stack[stack->sp].type != BCODE_NUMBER) { warnx("not a number"); /* XXX remove */ return (NULL); @@ -242,10 +238,8 @@ stack_popstring(struct stack *stack) if (stack_empty(stack)) return (NULL); - if (stack->stack[stack->sp].array != NULL) { - array_free(stack->stack[stack->sp].array); - stack->stack[stack->sp].array = NULL; - } + array_free(stack->stack[stack->sp].array); + stack->stack[stack->sp].array = NULL; if (stack->stack[stack->sp].type != BCODE_STRING) { warnx("not a string"); /* XXX remove */ return (NULL); @@ -257,9 +251,8 @@ void stack_clear(struct stack *stack) { - while (stack->sp >= 0) { + while (stack->sp >= 0) stack_free_value(&stack->stack[stack->sp--]); - } free(stack->stack); stack_init(stack); } From owner-svn-src-all@freebsd.org Sun Mar 12 05:42:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85863CF9430; Sun, 12 Mar 2017 05:42:58 +0000 (UTC) (envelope-from kp@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 52C5F143B; Sun, 12 Mar 2017 05:42:58 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C5gvWg075393; Sun, 12 Mar 2017 05:42:57 GMT (envelope-from kp@FreeBSD.org) Received: (from kp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C5gvM4075391; Sun, 12 Mar 2017 05:42:57 GMT (envelope-from kp@FreeBSD.org) Message-Id: <201703120542.v2C5gvM4075391@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kp set sender to kp@FreeBSD.org using -f From: Kristof Provost Date: Sun, 12 Mar 2017 05:42:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315136 - head/sys/netpfil/pf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 05:42:58 -0000 Author: kp Date: Sun Mar 12 05:42:57 2017 New Revision: 315136 URL: https://svnweb.freebsd.org/changeset/base/315136 Log: pf: Fix incorrect rw_sleep() in pf_unload() When we unload we don't hold the pf_rules_lock, so we cannot call rw_sleep() with it, because it would release a lock we do not hold. There's no need for the lock either, so we can just tsleep(). While here also make the same change in pf_purge_thread(), because it explicitly takes the lock before rw_sleep() and then immediately releases it afterwards. Modified: head/sys/netpfil/pf/pf.c head/sys/netpfil/pf/pf_ioctl.c Modified: head/sys/netpfil/pf/pf.c ============================================================================== --- head/sys/netpfil/pf/pf.c Sun Mar 12 05:36:31 2017 (r315135) +++ head/sys/netpfil/pf/pf.c Sun Mar 12 05:42:57 2017 (r315136) @@ -1429,9 +1429,7 @@ pf_purge_thread(void *unused __unused) u_int idx = 0; for (;;) { - PF_RULES_RLOCK(); - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftm", hz / 10); - PF_RULES_RUNLOCK(); + tsleep(pf_purge_thread, 0, "pftm", hz / 10); VNET_LIST_RLOCK(); VNET_FOREACH(vnet_iter) { Modified: head/sys/netpfil/pf/pf_ioctl.c ============================================================================== --- head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:36:31 2017 (r315135) +++ head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:42:57 2017 (r315136) @@ -3791,7 +3791,7 @@ pf_unload(void) pf_end_threads = 1; while (pf_end_threads < 2) { wakeup_one(pf_purge_thread); - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftmo", 0); + tsleep(pf_purge_thread, 0, "pftmo", 0); } if (pf_dev != NULL) From owner-svn-src-all@freebsd.org Sun Mar 12 06:18:09 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B92F7CF9C6C; Sun, 12 Mar 2017 06:18:09 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8750D118C; Sun, 12 Mar 2017 06:18:09 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C6I8t0087882; Sun, 12 Mar 2017 06:18:08 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C6I8MU087881; Sun, 12 Mar 2017 06:18:08 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703120618.v2C6I8MU087881@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 06:18: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: r315137 - stable/11/sys/cam/ctl X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 06:18:09 -0000 Author: mav Date: Sun Mar 12 06:18:08 2017 New Revision: 315137 URL: https://svnweb.freebsd.org/changeset/base/315137 Log: MFC r314307: Add support for SIMs without autosense. If we asked to send sense data by setting CAM_SEND_SENSE, but SIM didn't confirm transmission by setting CAM_SENT_SENSE, assume it was not sent. Queue the I/O back to CTL for later REQUEST SENSE with ctl_queue_sense(). This is needed for error reporting on SPI HBAs like ahc(4)/ahd(4). Modified: stable/11/sys/cam/ctl/scsi_ctl.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/cam/ctl/scsi_ctl.c ============================================================================== --- stable/11/sys/cam/ctl/scsi_ctl.c Sun Mar 12 05:42:57 2017 (r315136) +++ stable/11/sys/cam/ctl/scsi_ctl.c Sun Mar 12 06:18:08 2017 (r315137) @@ -1229,6 +1229,20 @@ ctlfedone(struct cam_periph *periph, uni * datamove done routine. */ if ((io->io_hdr.flags & CTL_FLAG_DMA_INPROG) == 0) { + /* + * If we asked to send sense data but it wasn't sent, + * queue the I/O back to CTL for later REQUEST SENSE. + */ + if ((done_ccb->ccb_h.flags & CAM_SEND_SENSE) != 0 && + (done_ccb->ccb_h.status & CAM_STATUS_MASK) == CAM_REQ_CMP && + (done_ccb->ccb_h.status & CAM_SENT_SENSE) == 0 && + (io = ctl_alloc_io_nowait(bus_softc->port.ctl_pool_ref)) != NULL) { + PRIV_INFO(io) = PRIV_INFO( + (union ctl_io *)atio->ccb_h.io_ptr); + ctl_queue_sense(atio->ccb_h.io_ptr); + atio->ccb_h.io_ptr = io; + } + /* Abort ATIO if CTIO sending status has failed. */ if ((done_ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) { From owner-svn-src-all@freebsd.org Sun Mar 12 06:18:42 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7DE53CF9CDB; Sun, 12 Mar 2017 06:18:42 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4A78512C5; Sun, 12 Mar 2017 06:18:42 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C6IfTY087956; Sun, 12 Mar 2017 06:18:41 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C6Ifii087955; Sun, 12 Mar 2017 06:18:41 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703120618.v2C6Ifii087955@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 06:18:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315138 - stable/10/sys/cam/ctl X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 06:18:42 -0000 Author: mav Date: Sun Mar 12 06:18:41 2017 New Revision: 315138 URL: https://svnweb.freebsd.org/changeset/base/315138 Log: MFC r314307: Add support for SIMs without autosense. If we asked to send sense data by setting CAM_SEND_SENSE, but SIM didn't confirm transmission by setting CAM_SENT_SENSE, assume it was not sent. Queue the I/O back to CTL for later REQUEST SENSE with ctl_queue_sense(). This is needed for error reporting on SPI HBAs like ahc(4)/ahd(4). Modified: stable/10/sys/cam/ctl/scsi_ctl.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/cam/ctl/scsi_ctl.c ============================================================================== --- stable/10/sys/cam/ctl/scsi_ctl.c Sun Mar 12 06:18:08 2017 (r315137) +++ stable/10/sys/cam/ctl/scsi_ctl.c Sun Mar 12 06:18:41 2017 (r315138) @@ -1229,6 +1229,20 @@ ctlfedone(struct cam_periph *periph, uni * datamove done routine. */ if ((io->io_hdr.flags & CTL_FLAG_DMA_INPROG) == 0) { + /* + * If we asked to send sense data but it wasn't sent, + * queue the I/O back to CTL for later REQUEST SENSE. + */ + if ((done_ccb->ccb_h.flags & CAM_SEND_SENSE) != 0 && + (done_ccb->ccb_h.status & CAM_STATUS_MASK) == CAM_REQ_CMP && + (done_ccb->ccb_h.status & CAM_SENT_SENSE) == 0 && + (io = ctl_alloc_io_nowait(bus_softc->port.ctl_pool_ref)) != NULL) { + PRIV_INFO(io) = PRIV_INFO( + (union ctl_io *)atio->ccb_h.io_ptr); + ctl_queue_sense(atio->ccb_h.io_ptr); + atio->ccb_h.io_ptr = io; + } + /* Abort ATIO if CTIO sending status has failed. */ if ((done_ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) { From owner-svn-src-all@freebsd.org Sun Mar 12 06:20:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 420A5CF9D93; Sun, 12 Mar 2017 06:20:00 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0E9C41456; Sun, 12 Mar 2017 06:19:59 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C6Jx26088060; Sun, 12 Mar 2017 06:19:59 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C6JwUG088058; Sun, 12 Mar 2017 06:19:58 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703120619.v2C6JwUG088058@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 06:19:58 +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: r315139 - stable/11/sys/dev/aic7xxx X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 06:20:00 -0000 Author: mav Date: Sun Mar 12 06:19:58 2017 New Revision: 315139 URL: https://svnweb.freebsd.org/changeset/base/315139 Log: MFC r314308: Fix LUN enabling on wildcard target, as done by CTL. Modified: stable/11/sys/dev/aic7xxx/aic79xx.c stable/11/sys/dev/aic7xxx/aic7xxx.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/aic7xxx/aic79xx.c ============================================================================== --- stable/11/sys/dev/aic7xxx/aic79xx.c Sun Mar 12 06:18:41 2017 (r315138) +++ stable/11/sys/dev/aic7xxx/aic79xx.c Sun Mar 12 06:19:58 2017 (r315139) @@ -9918,7 +9918,8 @@ ahd_handle_en_lun(struct ahd_softc *ahd, u_int our_id; our_id = ahd->our_id; - if (ccb->ccb_h.target_id != our_id) { + if (ccb->ccb_h.target_id != our_id + && ccb->ccb_h.target_id != CAM_TARGET_WILDCARD) { if ((ahd->features & AHD_MULTI_TID) != 0 && (ahd->flags & AHD_INITIATORROLE) != 0) { /* Modified: stable/11/sys/dev/aic7xxx/aic7xxx.c ============================================================================== --- stable/11/sys/dev/aic7xxx/aic7xxx.c Sun Mar 12 06:18:41 2017 (r315138) +++ stable/11/sys/dev/aic7xxx/aic7xxx.c Sun Mar 12 06:19:58 2017 (r315139) @@ -7347,7 +7347,8 @@ ahc_handle_en_lun(struct ahc_softc *ahc, else our_id = ahc->our_id_b; - if (ccb->ccb_h.target_id != our_id) { + if (ccb->ccb_h.target_id != our_id + && ccb->ccb_h.target_id != CAM_TARGET_WILDCARD) { /* * our_id represents our initiator ID, or * the ID of the first target to have an From owner-svn-src-all@freebsd.org Sun Mar 12 06:20:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 43BB0CF9E02; Sun, 12 Mar 2017 06:20:30 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 106D915CE; Sun, 12 Mar 2017 06:20:29 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C6KTcC088159; Sun, 12 Mar 2017 06:20:29 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C6KSZB088157; Sun, 12 Mar 2017 06:20:29 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703120620.v2C6KSZB088157@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 06:20:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315140 - stable/10/sys/dev/aic7xxx X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 06:20:30 -0000 Author: mav Date: Sun Mar 12 06:20:28 2017 New Revision: 315140 URL: https://svnweb.freebsd.org/changeset/base/315140 Log: MFC r314308: Fix LUN enabling on wildcard target, as done by CTL. Modified: stable/10/sys/dev/aic7xxx/aic79xx.c stable/10/sys/dev/aic7xxx/aic7xxx.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/aic7xxx/aic79xx.c ============================================================================== --- stable/10/sys/dev/aic7xxx/aic79xx.c Sun Mar 12 06:19:58 2017 (r315139) +++ stable/10/sys/dev/aic7xxx/aic79xx.c Sun Mar 12 06:20:28 2017 (r315140) @@ -9927,7 +9927,8 @@ ahd_handle_en_lun(struct ahd_softc *ahd, u_int our_id; our_id = ahd->our_id; - if (ccb->ccb_h.target_id != our_id) { + if (ccb->ccb_h.target_id != our_id + && ccb->ccb_h.target_id != CAM_TARGET_WILDCARD) { if ((ahd->features & AHD_MULTI_TID) != 0 && (ahd->flags & AHD_INITIATORROLE) != 0) { /* Modified: stable/10/sys/dev/aic7xxx/aic7xxx.c ============================================================================== --- stable/10/sys/dev/aic7xxx/aic7xxx.c Sun Mar 12 06:19:58 2017 (r315139) +++ stable/10/sys/dev/aic7xxx/aic7xxx.c Sun Mar 12 06:20:28 2017 (r315140) @@ -7353,7 +7353,8 @@ ahc_handle_en_lun(struct ahc_softc *ahc, else our_id = ahc->our_id_b; - if (ccb->ccb_h.target_id != our_id) { + if (ccb->ccb_h.target_id != our_id + && ccb->ccb_h.target_id != CAM_TARGET_WILDCARD) { /* * our_id represents our initiator ID, or * the ID of the first target to have an From owner-svn-src-all@freebsd.org Sun Mar 12 07:09:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 46D63D09855; Sun, 12 Mar 2017 07:09:53 +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 1E7C41762; Sun, 12 Mar 2017 07:09:53 +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 v2C79qGb008252; Sun, 12 Mar 2017 07:09:52 GMT (envelope-from manu@FreeBSD.org) Received: (from manu@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C79p2H008242; Sun, 12 Mar 2017 07:09:51 GMT (envelope-from manu@FreeBSD.org) Message-Id: <201703120709.v2C79p2H008242@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: manu set sender to manu@FreeBSD.org using -f From: Emmanuel Vadot Date: Sun, 12 Mar 2017 07:09:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315141 - head/sys/mips/conf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 07:09:53 -0000 Author: manu Date: Sun Mar 12 07:09:50 2017 New Revision: 315141 URL: https://svnweb.freebsd.org/changeset/base/315141 Log: Use 'options EXT_RESOURCES' instead of 'device ext_resources' for FDT enabled MIPS kernel config. Modified: head/sys/mips/conf/JZ4780 head/sys/mips/conf/MT7620A_FDT head/sys/mips/conf/MT7620N_FDT head/sys/mips/conf/MT7621_FDT head/sys/mips/conf/MT7628_FDT head/sys/mips/conf/RT3050_FDT head/sys/mips/conf/RT3352_FDT head/sys/mips/conf/RT3883_FDT head/sys/mips/conf/RT5350_FDT head/sys/mips/conf/X1000 Modified: head/sys/mips/conf/JZ4780 ============================================================================== --- head/sys/mips/conf/JZ4780 Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/JZ4780 Sun Mar 12 07:09:50 2017 (r315141) @@ -71,7 +71,7 @@ device fdt_pinctrl device clk device regulator -device ext_resources +options EXT_RESOURCES device gpio Modified: head/sys/mips/conf/MT7620A_FDT ============================================================================== --- head/sys/mips/conf/MT7620A_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/MT7620A_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -73,5 +73,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/MT7620N_FDT ============================================================================== --- head/sys/mips/conf/MT7620N_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/MT7620N_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -70,5 +70,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/MT7621_FDT ============================================================================== --- head/sys/mips/conf/MT7621_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/MT7621_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -69,5 +69,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/MT7628_FDT ============================================================================== --- head/sys/mips/conf/MT7628_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/MT7628_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -72,5 +72,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/RT3050_FDT ============================================================================== --- head/sys/mips/conf/RT3050_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/RT3050_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -74,5 +74,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/RT3352_FDT ============================================================================== --- head/sys/mips/conf/RT3352_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/RT3352_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -70,5 +70,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/RT3883_FDT ============================================================================== --- head/sys/mips/conf/RT3883_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/RT3883_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -74,7 +74,7 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk # For now there's no etherswitch support for RT3662/RT3883 Modified: head/sys/mips/conf/RT5350_FDT ============================================================================== --- head/sys/mips/conf/RT5350_FDT Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/RT5350_FDT Sun Mar 12 07:09:50 2017 (r315141) @@ -70,5 +70,5 @@ device bpf device if_bridge # Extres -device ext_resources +options EXT_RESOURCES device clk Modified: head/sys/mips/conf/X1000 ============================================================================== --- head/sys/mips/conf/X1000 Sun Mar 12 06:20:28 2017 (r315140) +++ head/sys/mips/conf/X1000 Sun Mar 12 07:09:50 2017 (r315141) @@ -68,7 +68,7 @@ device fdt_pinctrl device clk device regulator -device ext_resources +options EXT_RESOURCES device gpio From owner-svn-src-all@freebsd.org Sun Mar 12 09:05:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EAB03D07810; Sun, 12 Mar 2017 09:05:44 +0000 (UTC) (envelope-from ronald-lists@klop.ws) Received: from smarthost1.greenhost.nl (smarthost1.greenhost.nl [195.190.28.81]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B6F9B1904; Sun, 12 Mar 2017 09:05:44 +0000 (UTC) (envelope-from ronald-lists@klop.ws) Received: from smtp.greenhost.nl ([213.108.104.138]) by smarthost1.greenhost.nl with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1cmzRZ-0007hM-6L; Sun, 12 Mar 2017 10:05:37 +0100 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, "Emmanuel Vadot" Subject: Re: svn commit: r315141 - head/sys/mips/conf References: <201703120709.v2C79p2H008242@repo.freebsd.org> Date: Sun, 12 Mar 2017 10:05:36 +0100 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Ronald Klop" Message-ID: In-Reply-To: <201703120709.v2C79p2H008242@repo.freebsd.org> User-Agent: Opera Mail/12.16 (FreeBSD) X-Authenticated-As-Hash: 398f5522cb258ce43cb679602f8cfe8b62a256d1 X-Virus-Scanned: by clamav at smarthost1.samage.net X-Spam-Level: / X-Spam-Score: -0.2 X-Spam-Status: No, score=-0.2 required=5.0 tests=ALL_TRUSTED, BAYES_50 autolearn=disabled version=3.4.0 X-Scan-Signature: 96329e479c93ffb0716cf569fedf443d X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 09:05:45 -0000 Hi, Your commit message shows in English what the diff already shows: the 'what changed'. IMHO it would add more value to the commit message to describe the 'why it changed'. What are your ideas about that? Regards, Ronald. On Sun, 12 Mar 2017 08:09:51 +0100, Emmanuel Vadot wrote: > Author: manu > Date: Sun Mar 12 07:09:50 2017 > New Revision: 315141 > URL: https://svnweb.freebsd.org/changeset/base/315141 > > Log: > Use 'options EXT_RESOURCES' instead of 'device ext_resources' for FDT > enabled > MIPS kernel config. > > Modified: > head/sys/mips/conf/JZ4780 > head/sys/mips/conf/MT7620A_FDT > head/sys/mips/conf/MT7620N_FDT > head/sys/mips/conf/MT7621_FDT > head/sys/mips/conf/MT7628_FDT > head/sys/mips/conf/RT3050_FDT > head/sys/mips/conf/RT3352_FDT > head/sys/mips/conf/RT3883_FDT > head/sys/mips/conf/RT5350_FDT > head/sys/mips/conf/X1000 > > Modified: head/sys/mips/conf/JZ4780 > ============================================================================== > --- head/sys/mips/conf/JZ4780 Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/JZ4780 Sun Mar 12 07:09:50 2017 (r315141) > @@ -71,7 +71,7 @@ device fdt_pinctrl > device clk > device regulator > -device ext_resources > +options EXT_RESOURCES > device gpio > > Modified: head/sys/mips/conf/MT7620A_FDT > ============================================================================== > --- head/sys/mips/conf/MT7620A_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/MT7620A_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -73,5 +73,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/MT7620N_FDT > ============================================================================== > --- head/sys/mips/conf/MT7620N_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/MT7620N_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -70,5 +70,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/MT7621_FDT > ============================================================================== > --- head/sys/mips/conf/MT7621_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/MT7621_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -69,5 +69,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/MT7628_FDT > ============================================================================== > --- head/sys/mips/conf/MT7628_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/MT7628_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -72,5 +72,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/RT3050_FDT > ============================================================================== > --- head/sys/mips/conf/RT3050_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/RT3050_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -74,5 +74,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/RT3352_FDT > ============================================================================== > --- head/sys/mips/conf/RT3352_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/RT3352_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -70,5 +70,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/RT3883_FDT > ============================================================================== > --- head/sys/mips/conf/RT3883_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/RT3883_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -74,7 +74,7 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > # For now there's no etherswitch support for RT3662/RT3883 > > Modified: head/sys/mips/conf/RT5350_FDT > ============================================================================== > --- head/sys/mips/conf/RT5350_FDT Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/RT5350_FDT Sun Mar 12 07:09:50 2017 (r315141) > @@ -70,5 +70,5 @@ device bpf > device if_bridge > # Extres > -device ext_resources > +options EXT_RESOURCES > device clk > > Modified: head/sys/mips/conf/X1000 > ============================================================================== > --- head/sys/mips/conf/X1000 Sun Mar 12 06:20:28 2017 (r315140) > +++ head/sys/mips/conf/X1000 Sun Mar 12 07:09:50 2017 (r315141) > @@ -68,7 +68,7 @@ device fdt_pinctrl > device clk > device regulator > -device ext_resources > +options EXT_RESOURCES > device gpio > _______________________________________________ > svn-src-all@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" From owner-svn-src-all@freebsd.org Sun Mar 12 09:32:32 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D7C40D07FC2; Sun, 12 Mar 2017 09:32:32 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from citapm.icyb.net.ua (citapm.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id ACDAB1611; Sun, 12 Mar 2017 09:32:31 +0000 (UTC) (envelope-from avg@FreeBSD.org) Received: from porto.starpoint.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citapm.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id LAA25952; Sun, 12 Mar 2017 11:32:28 +0200 (EET) (envelope-from avg@FreeBSD.org) Received: from localhost ([127.0.0.1]) by porto.starpoint.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1cmzrY-000MIC-3j; Sun, 12 Mar 2017 11:32:28 +0200 Subject: Re: svn commit: r315068 - head/sys/modules/qlxgbe To: Bruce Evans References: <201703111516.v2BFGtkn006959@repo.freebsd.org> <20170312124945.C4483@besplex.bde.org> Cc: src-committers@FreeBSD.org, svn-src-all@FreeBSD.org, svn-src-head@FreeBSD.org From: Andriy Gapon Message-ID: <18e52ee7-0b27-7aff-6b69-75b27673a8f4@FreeBSD.org> Date: Sun, 12 Mar 2017 11:31:31 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <20170312124945.C4483@besplex.bde.org> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 09:32:32 -0000 On 12/03/2017 04:44, Bruce Evans wrote: > On Sat, 11 Mar 2017, Andriy Gapon wrote: > >> Log: >> revert r314862, use of GCC_MS_EXTENSIONS in qlxgbe >> >> Commit r278913 made explicit use of GCC_MS_EXTENSIONS unnecessary. >> >> Requested by: glebius > > Does this module actually use ms extensions? This seems unlikely, since > only gcc supports them. It probably doesn't. > My kernels compile correctly with the correct CFLAGS (gcc -std=gnu99 > -fno-ms-extensions). How did you manage to pass -std=gnu99 to the module build? No matter what flags I tried to modify the actual compiler invocations still had -std=iso9899:1999 after -std=gnu99 in them, so my modifications had no effect. GCC_MS_EXTENSIONS was the easiest way to get the job done. -- Andriy Gapon From owner-svn-src-all@freebsd.org Sun Mar 12 10:56:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 56CABD08947; Sun, 12 Mar 2017 10:56:21 +0000 (UTC) (envelope-from tijl@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 09CF11A58; Sun, 12 Mar 2017 10:56:20 +0000 (UTC) (envelope-from tijl@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CAuKRo001003; Sun, 12 Mar 2017 10:56:20 GMT (envelope-from tijl@FreeBSD.org) Received: (from tijl@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CAuJ3T001001; Sun, 12 Mar 2017 10:56:19 GMT (envelope-from tijl@FreeBSD.org) Message-Id: <201703121056.v2CAuJ3T001001@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tijl set sender to tijl@FreeBSD.org using -f From: Tijl Coosemans Date: Sun, 12 Mar 2017 10:56:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315142 - head/usr.bin/man X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 10:56:21 -0000 Author: tijl Date: Sun Mar 12 10:56:19 2017 New Revision: 315142 URL: https://svnweb.freebsd.org/changeset/base/315142 Log: - Remove separate handling of /bin and /usr/bin in manpath. They are no longer a special case. - Prefer PREFIX/share/man over PREFIX/man. - Add /usr/local/share/man to man_default_path. - Update manpath man page. Reviewed by: bapt Modified: head/usr.bin/man/man.sh head/usr.bin/man/manpath.1 Modified: head/usr.bin/man/man.sh ============================================================================== --- head/usr.bin/man/man.sh Sun Mar 12 07:09:50 2017 (r315141) +++ head/usr.bin/man/man.sh Sun Mar 12 10:56:19 2017 (r315142) @@ -778,26 +778,19 @@ search_path() { IFS=: for path in $PATH; do - # Do a little special casing since the base manpages - # are in /usr/share/man instead of /usr/man or /man. - case "$path" in - /bin|/usr/bin) add_to_manpath "/usr/share/man" ;; - *) if add_to_manpath "$path/man"; then - : - elif add_to_manpath "$path/MAN"; then - : - else - case "$path" in - */bin) p="${path%/bin}/man" - add_to_manpath "$p" - p="${path%/bin}/share/man" - add_to_manpath "$p" - ;; - *) ;; - esac - fi - ;; - esac + if add_to_manpath "$path/man"; then + : + elif add_to_manpath "$path/MAN"; then + : + else + case "$path" in + */bin) p="${path%/bin}/share/man" + add_to_manpath "$p" + p="${path%/bin}/man" + add_to_manpath "$p" + ;; + esac + fi done unset IFS @@ -1007,7 +1000,7 @@ SYSCTL=/sbin/sysctl debug=0 man_default_sections='1:8:2:3:n:4:5:6:7:9:l' -man_default_path='/usr/share/man:/usr/share/openssl/man:/usr/local/man' +man_default_path='/usr/share/man:/usr/share/openssl/man:/usr/local/share/man:/usr/local/man' cattool='/usr/bin/zcat -f' config_global='/etc/man.conf' Modified: head/usr.bin/man/manpath.1 ============================================================================== --- head/usr.bin/man/manpath.1 Sun Mar 12 07:09:50 2017 (r315141) +++ head/usr.bin/man/manpath.1 Sun Mar 12 10:56:19 2017 (r315142) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 1, 2010 +.Dd March 11, 2017 .Dt MANPATH 1 .Os .Sh NAME @@ -66,15 +66,10 @@ for the first of: .Pa pathname/MAN .It If pathname ends with /bin: +.Pa pathname/../share/man +and .Pa pathname/../man .El -Note: Special logic exists to make -.Pa /bin -and -.Pa /usr/bin -look in -.Pa /usr/share/man -for manual files. .It The configuration files listed in the .Sx FILES From owner-svn-src-all@freebsd.org Sun Mar 12 11:26:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2A2F9CF94B0; Sun, 12 Mar 2017 11:26:35 +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 E7F4C18ED; Sun, 12 Mar 2017 11:26:34 +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 7868D9C89; Sun, 12 Mar 2017 11:26:27 +0000 (UTC) Received: by desk.des.no (Postfix, from userid 1001) id 48F477357; Sun, 12 Mar 2017 12:26:27 +0100 (CET) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: "Ngie Cooper \(yaneurabeya\)" Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r308996 - head/lib/libfetch References: <201611221330.uAMDU7fg052989@repo.freebsd.org> <93505FD7-FB42-4BD5-834C-6F73EFD9B1CF@gmail.com> Date: Sun, 12 Mar 2017 12:26:26 +0100 In-Reply-To: <93505FD7-FB42-4BD5-834C-6F73EFD9B1CF@gmail.com> (Ngie Cooper's message of "Sat, 11 Mar 2017 20:46:16 -0800") Message-ID: <86shmid9ct.fsf@desk.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 11:26:35 -0000 "Ngie Cooper (yaneurabeya)" writes: > Hi Bjoern, No, that was my father :) > Shouldn=E2=80=99t this be strrchr instead of strchr since you=E2=80=99re > scanning for the service from the right side of the host, > e.g. =E2=80=9Cfoo:service=E2=80=9D or =E2=80=9C[::1]:service=E2=80=9D? Th= is code would match index 3 > in the first example, but it would match index 2 in the second > example. Correct, although it may be slightly more complicated, which is why I didn't immediately jump on it when bz@ pointed it out. I'm working on it right now. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-svn-src-all@freebsd.org Sun Mar 12 11:54:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E035CF9DC3; Sun, 12 Mar 2017 11:54:36 +0000 (UTC) (envelope-from des@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 6AD1D16F6; Sun, 12 Mar 2017 11:54:36 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CBsZ9L025364; Sun, 12 Mar 2017 11:54:35 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CBsZZN025363; Sun, 12 Mar 2017 11:54:35 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121154.v2CBsZZN025363@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 11:54:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315143 - head/lib/libfetch X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 11:54:36 -0000 Author: des Date: Sun Mar 12 11:54:35 2017 New Revision: 315143 URL: https://svnweb.freebsd.org/changeset/base/315143 Log: Add a __printflike() that would have caught the bug fixed in r314396. Modified: head/lib/libfetch/common.h Modified: head/lib/libfetch/common.h ============================================================================== --- head/lib/libfetch/common.h Sun Mar 12 10:56:19 2017 (r315142) +++ head/lib/libfetch/common.h Sun Mar 12 11:54:35 2017 (r315143) @@ -73,7 +73,7 @@ struct iovec; void fetch_seterr(struct fetcherr *, int); void fetch_syserr(void); -void fetch_info(const char *, ...); +void fetch_info(const char *, ...) __printflike(1, 2); int fetch_default_port(const char *); int fetch_default_proxy_port(const char *); struct addrinfo *fetch_resolve(const char *, int, int); From owner-svn-src-all@freebsd.org Sun Mar 12 12:11:13 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 397C2D08C83; Sun, 12 Mar 2017 12:11:13 +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 05ED616DC; Sun, 12 Mar 2017 12:11:12 +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 v2CCBCwQ030404; Sun, 12 Mar 2017 12:11:12 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CCBCSB030403; Sun, 12 Mar 2017 12:11:12 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121211.v2CCBCSB030403@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 12:11:12 +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: r315144 - stable/11/sys/sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 12:11:13 -0000 Author: kib Date: Sun Mar 12 12:11:11 2017 New Revision: 315144 URL: https://svnweb.freebsd.org/changeset/base/315144 Log: MFC r314960: Fix typo in comment. Modified: stable/11/sys/sys/signalvar.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/sys/signalvar.h ============================================================================== --- stable/11/sys/sys/signalvar.h Sun Mar 12 11:54:35 2017 (r315143) +++ stable/11/sys/sys/signalvar.h Sun Mar 12 12:11:11 2017 (r315144) @@ -235,7 +235,7 @@ typedef struct ksiginfo { #define KSI_TRAP 0x01 /* Generated by trap. */ #define KSI_EXT 0x02 /* Externally managed ksi. */ #define KSI_INS 0x04 /* Directly insert ksi, not the copy */ -#define KSI_SIGQ 0x08 /* Generated by sigqueue, might ret EGAIN. */ +#define KSI_SIGQ 0x08 /* Generated by sigqueue, might ret EAGAIN. */ #define KSI_HEAD 0x10 /* Insert into head, not tail. */ #define KSI_COPYMASK (KSI_TRAP|KSI_SIGQ) From owner-svn-src-all@freebsd.org Sun Mar 12 12:13:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A5EFAD08D22; Sun, 12 Mar 2017 12:13:00 +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 71FC81958; Sun, 12 Mar 2017 12:13:00 +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 v2CCCxZi033535; Sun, 12 Mar 2017 12:12:59 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CCCx6f033534; Sun, 12 Mar 2017 12:12:59 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121212.v2CCCx6f033534@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 12:12:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315145 - stable/10/sys/sys X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 12:13:00 -0000 Author: kib Date: Sun Mar 12 12:12:59 2017 New Revision: 315145 URL: https://svnweb.freebsd.org/changeset/base/315145 Log: MFC r314960: Fix typo in comment. Modified: stable/10/sys/sys/signalvar.h Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/sys/signalvar.h ============================================================================== --- stable/10/sys/sys/signalvar.h Sun Mar 12 12:11:11 2017 (r315144) +++ stable/10/sys/sys/signalvar.h Sun Mar 12 12:12:59 2017 (r315145) @@ -233,7 +233,7 @@ typedef struct ksiginfo { #define KSI_TRAP 0x01 /* Generated by trap. */ #define KSI_EXT 0x02 /* Externally managed ksi. */ #define KSI_INS 0x04 /* Directly insert ksi, not the copy */ -#define KSI_SIGQ 0x08 /* Generated by sigqueue, might ret EGAIN. */ +#define KSI_SIGQ 0x08 /* Generated by sigqueue, might ret EAGAIN. */ #define KSI_HEAD 0x10 /* Insert into head, not tail. */ #define KSI_COPYMASK (KSI_TRAP|KSI_SIGQ) From owner-svn-src-all@freebsd.org Sun Mar 12 12:38:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 11BD7D0951A; Sun, 12 Mar 2017 12:38:18 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B939F13B5; Sun, 12 Mar 2017 12:38:17 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CCcGnY041767; Sun, 12 Mar 2017 12:38:16 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CCcG85041766; Sun, 12 Mar 2017 12:38:16 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703121238.v2CCcG85041766@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 12:38:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315146 - head/share/man/man4 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 12:38:18 -0000 Author: mav Date: Sun Mar 12 12:38:16 2017 New Revision: 315146 URL: https://svnweb.freebsd.org/changeset/base/315146 Log: Some more polishing. MFC after: 13 days Modified: head/share/man/man4/ctl.4 Modified: head/share/man/man4/ctl.4 ============================================================================== --- head/share/man/man4/ctl.4 Sun Mar 12 12:12:59 2017 (r315145) +++ head/share/man/man4/ctl.4 Sun Mar 12 12:38:16 2017 (r315146) @@ -31,7 +31,8 @@ .Nm ctl .Nd CAM Target Layer / SCSI target subsystem .Sh SYNOPSIS -To compile this driver into the kernel, place the following line in your +To compile this driver into the kernel, +place the following line in your kernel configuration file: .Bd -ragged -offset indent .Cd "device iscsi" @@ -47,15 +48,14 @@ ctl_load="YES" .Sh DESCRIPTION The .Nm -subsystem provides featured, performant and reliable SCSI target devices -emulation. +subsystem provides SCSI target devices emulation. It supports features such as: .Pp .Bl -bullet -compact .It -Disk, processor and cdrom device emulation +Disk, CD-ROM and processor device emulation .It -Tagged and untagged queueing +Tagged queueing .It SCSI task attribute support (ordered, head of queue, simple tags) .It @@ -122,7 +122,7 @@ subsystem includes two backends to creat kinds of backing stores: .Bl -tag -width ramdisk .It block -Stores data on ZFS ZVOLs, files or raw block devices. +Stores data in ZFS ZVOLs, files or raw block devices. .It ramdisk Stores data in RAM, that makes it mostly useful for performance testing. Depending on configured capacity can work as black hole, thin or thick @@ -187,7 +187,7 @@ primary; .It 1 secondary. .El -This role can be overriden on per-LUN basis using "ha_role" LUN option, +This role can be overridden on per-LUN basis using "ha_role" LUN option, so that for one LUN one node is primary, while for another -- another. Role change from primary to secondary for HA modes 0 and 2 closes backends, the opposite change -- opens. From owner-svn-src-all@freebsd.org Sun Mar 12 13:14:50 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E314D09059; Sun, 12 Mar 2017 13:14:50 +0000 (UTC) (envelope-from des@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 6D1571888; Sun, 12 Mar 2017 13:14:50 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDEnD5057779; Sun, 12 Mar 2017 13:14:49 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDEnWa057778; Sun, 12 Mar 2017 13:14:49 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121314.v2CDEnWa057778@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:14: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: r315147 - stable/11/sbin/md5 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:14:50 -0000 Author: des Date: Sun Mar 12 13:14:49 2017 New Revision: 315147 URL: https://svnweb.freebsd.org/changeset/base/315147 Log: MFH (r314528): update to reflect the state of SHA-1 Modified: stable/11/sbin/md5/md5.1 Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/md5/md5.1 ============================================================================== --- stable/11/sbin/md5/md5.1 Sun Mar 12 12:38:16 2017 (r315146) +++ stable/11/sbin/md5/md5.1 Sun Mar 12 13:14:49 2017 (r315147) @@ -67,21 +67,17 @@ in a secure manner before being encrypte key under a public-key cryptosystem such as .Tn RSA . .Pp +The .Tn MD5 -has been completely broken as far as finding collisions is -concerned, and should not be relied upon to produce unique outputs. -This also means that -.Tn MD5 -should not be used as part of a cryptographic signature scheme. -At the current time (2014-05-17) there is no publicly known method to -.Dq reverse -MD5, i.e., to find an input given a hash value. -.Pp -.Tn SHA-1 -currently (2014-05-17) has no known collisions, but an attack has been -found which is faster than a brute-force search, placing the security of +and .Tn SHA-1 -in doubt. +algorithms have been proven to be vulnerable to practical collision +attacks and should not be relied upon to produce unique outputs, nor +should they be used as part of a cryptographic signature scheme. +As of 2016-03-02, there is no publicly known method to +.Em reverse +either algorithm, i.e. to find an input that produces a specific +output. .Pp .Tn SHA-512t256 is a version of @@ -94,6 +90,8 @@ The hashes are not interchangeable. .Pp It is recommended that all new applications use .Tn SHA-512 +or +.Tn SKEIN-512 instead of one of the other hash functions. .Pp The following options may be used in any combination and must From owner-svn-src-all@freebsd.org Sun Mar 12 13:15:27 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3C47D090BD; Sun, 12 Mar 2017 13:15:27 +0000 (UTC) (envelope-from des@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 92CDC19D1; Sun, 12 Mar 2017 13:15:27 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDFQkW057889; Sun, 12 Mar 2017 13:15:26 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDFQwn057888; Sun, 12 Mar 2017 13:15:26 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121315.v2CDFQwn057888@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:15:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315148 - stable/10/sbin/md5 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:15:27 -0000 Author: des Date: Sun Mar 12 13:15:26 2017 New Revision: 315148 URL: https://svnweb.freebsd.org/changeset/base/315148 Log: MFH (r314528): update to reflect the state of SHA-1 Modified: stable/10/sbin/md5/md5.1 Directory Properties: stable/10/ (props changed) Modified: stable/10/sbin/md5/md5.1 ============================================================================== --- stable/10/sbin/md5/md5.1 Sun Mar 12 13:14:49 2017 (r315147) +++ stable/10/sbin/md5/md5.1 Sun Mar 12 13:15:26 2017 (r315148) @@ -67,21 +67,17 @@ in a secure manner before being encrypte key under a public-key cryptosystem such as .Tn RSA . .Pp +The .Tn MD5 -has been completely broken as far as finding collisions is -concerned, and should not be relied upon to produce unique outputs. -This also means that -.Tn MD5 -should not be used as part of a cryptographic signature scheme. -At the current time (2014-05-17) there is no publicly known method to -.Dq reverse -MD5, i.e., to find an input given a hash value. -.Pp -.Tn SHA-1 -currently (2014-05-17) has no known collisions, but an attack has been -found which is faster than a brute-force search, placing the security of +and .Tn SHA-1 -in doubt. +algorithms have been proven to be vulnerable to practical collision +attacks and should not be relied upon to produce unique outputs, nor +should they be used as part of a cryptographic signature scheme. +As of 2016-03-02, there is no publicly known method to +.Em reverse +either algorithm, i.e. to find an input that produces a specific +output. .Pp .Tn SHA-512t256 is a version of @@ -94,6 +90,8 @@ The hashes are not interchangeable. .Pp It is recommended that all new applications use .Tn SHA-512 +or +.Tn SKEIN-512 instead of one of the other hash functions. .Pp The following options may be used in any combination and must From owner-svn-src-all@freebsd.org Sun Mar 12 13:18:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A6099D09141; Sun, 12 Mar 2017 13:18:49 +0000 (UTC) (envelope-from des@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 6E4381B6F; Sun, 12 Mar 2017 13:18:49 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDImHA058068; Sun, 12 Mar 2017 13:18:48 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDImk6058067; Sun, 12 Mar 2017 13:18:48 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121318.v2CDImk6058067@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:18: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: r315149 - stable/11/sbin/md5 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:18:49 -0000 Author: des Date: Sun Mar 12 13:18:48 2017 New Revision: 315149 URL: https://svnweb.freebsd.org/changeset/base/315149 Log: MFH (r314554): fix date in previous commit Modified: stable/11/sbin/md5/md5.1 Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/md5/md5.1 ============================================================================== --- stable/11/sbin/md5/md5.1 Sun Mar 12 13:15:26 2017 (r315148) +++ stable/11/sbin/md5/md5.1 Sun Mar 12 13:18:48 2017 (r315149) @@ -74,7 +74,7 @@ and algorithms have been proven to be vulnerable to practical collision attacks and should not be relied upon to produce unique outputs, nor should they be used as part of a cryptographic signature scheme. -As of 2016-03-02, there is no publicly known method to +As of 2017-03-02, there is no publicly known method to .Em reverse either algorithm, i.e. to find an input that produces a specific output. From owner-svn-src-all@freebsd.org Sun Mar 12 13:20:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 575B2D091EB; Sun, 12 Mar 2017 13:20:08 +0000 (UTC) (envelope-from des@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 2648D1CE2; Sun, 12 Mar 2017 13:20:08 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDK70D058189; Sun, 12 Mar 2017 13:20:07 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDK7Po058188; Sun, 12 Mar 2017 13:20:07 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121320.v2CDK7Po058188@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:20:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315150 - stable/10/sbin/md5 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:20:08 -0000 Author: des Date: Sun Mar 12 13:20:07 2017 New Revision: 315150 URL: https://svnweb.freebsd.org/changeset/base/315150 Log: MFH (r314554): fix date in previous commit Also remove mention of SKEIN-512 since it is not available in 10. Modified: stable/10/sbin/md5/md5.1 Directory Properties: stable/10/ (props changed) Modified: stable/10/sbin/md5/md5.1 ============================================================================== --- stable/10/sbin/md5/md5.1 Sun Mar 12 13:18:48 2017 (r315149) +++ stable/10/sbin/md5/md5.1 Sun Mar 12 13:20:07 2017 (r315150) @@ -74,7 +74,7 @@ and algorithms have been proven to be vulnerable to practical collision attacks and should not be relied upon to produce unique outputs, nor should they be used as part of a cryptographic signature scheme. -As of 2016-03-02, there is no publicly known method to +As of 2017-03-02, there is no publicly known method to .Em reverse either algorithm, i.e. to find an input that produces a specific output. @@ -90,8 +90,6 @@ The hashes are not interchangeable. .Pp It is recommended that all new applications use .Tn SHA-512 -or -.Tn SKEIN-512 instead of one of the other hash functions. .Pp The following options may be used in any combination and must From owner-svn-src-all@freebsd.org Sun Mar 12 13:22:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77290D0938F; Sun, 12 Mar 2017 13:22:36 +0000 (UTC) (envelope-from des@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 3C74D10C5; Sun, 12 Mar 2017 13:22:36 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDMZ5U061821; Sun, 12 Mar 2017 13:22:35 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDMZlT061820; Sun, 12 Mar 2017 13:22:35 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121322.v2CDMZlT061820@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:22: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: r315151 - stable/11/lib/libpam/modules/pam_krb5 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:22:36 -0000 Author: des Date: Sun Mar 12 13:22:35 2017 New Revision: 315151 URL: https://svnweb.freebsd.org/changeset/base/315151 Log: MFH (r314598): load default options before requesting ticket PR: 213909 Modified: stable/11/lib/libpam/modules/pam_krb5/pam_krb5.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/libpam/modules/pam_krb5/pam_krb5.c ============================================================================== --- stable/11/lib/libpam/modules/pam_krb5/pam_krb5.c Sun Mar 12 13:20:07 2017 (r315150) +++ stable/11/lib/libpam/modules/pam_krb5/pam_krb5.c Sun Mar 12 13:22:35 2017 (r315151) @@ -239,6 +239,8 @@ pam_sm_authenticate(pam_handle_t *pamh, retval = PAM_SERVICE_ERR; goto cleanup2; } + krb5_get_init_creds_opt_set_default_flags(pam_context, + service, NULL, opts); if (openpam_get_option(pamh, PAM_OPT_FORWARDABLE)) krb5_get_init_creds_opt_set_forwardable(opts, 1); From owner-svn-src-all@freebsd.org Sun Mar 12 13:23:24 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B3BB7D0941B; Sun, 12 Mar 2017 13:23:24 +0000 (UTC) (envelope-from des@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 829831244; Sun, 12 Mar 2017 13:23:24 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDNNTU061910; Sun, 12 Mar 2017 13:23:23 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDNN2l061909; Sun, 12 Mar 2017 13:23:23 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121323.v2CDNN2l061909@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:23:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315152 - stable/10/lib/libpam/modules/pam_krb5 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:23:24 -0000 Author: des Date: Sun Mar 12 13:23:23 2017 New Revision: 315152 URL: https://svnweb.freebsd.org/changeset/base/315152 Log: MFH (r314598): load default options before requesting ticket PR: 213909 Modified: stable/10/lib/libpam/modules/pam_krb5/pam_krb5.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libpam/modules/pam_krb5/pam_krb5.c ============================================================================== --- stable/10/lib/libpam/modules/pam_krb5/pam_krb5.c Sun Mar 12 13:22:35 2017 (r315151) +++ stable/10/lib/libpam/modules/pam_krb5/pam_krb5.c Sun Mar 12 13:23:23 2017 (r315152) @@ -239,6 +239,8 @@ pam_sm_authenticate(pam_handle_t *pamh, retval = PAM_SERVICE_ERR; goto cleanup2; } + krb5_get_init_creds_opt_set_default_flags(pam_context, + service, NULL, opts); if (openpam_get_option(pamh, PAM_OPT_FORWARDABLE)) krb5_get_init_creds_opt_set_forwardable(opts, 1); From owner-svn-src-all@freebsd.org Sun Mar 12 13:36:15 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B79FED09A19; Sun, 12 Mar 2017 13:36:15 +0000 (UTC) (envelope-from des@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 86AA21AEA; Sun, 12 Mar 2017 13:36:15 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDaEfh066741; Sun, 12 Mar 2017 13:36:14 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDaECI066740; Sun, 12 Mar 2017 13:36:14 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121336.v2CDaECI066740@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:36:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315153 - stable/10/lib/libradius X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:36:15 -0000 Author: des Date: Sun Mar 12 13:36:14 2017 New Revision: 315153 URL: https://svnweb.freebsd.org/changeset/base/315153 Log: MFH (r300602): the NAS identifier is a string, not an integer Modified: stable/10/lib/libradius/radlib.h Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libradius/radlib.h ============================================================================== --- stable/10/lib/libradius/radlib.h Sun Mar 12 13:23:23 2017 (r315152) +++ stable/10/lib/libradius/radlib.h Sun Mar 12 13:36:14 2017 (r315153) @@ -98,7 +98,7 @@ #define RAD_TERMINATION_ACTION 29 /* Integer */ #define RAD_CALLED_STATION_ID 30 /* String */ #define RAD_CALLING_STATION_ID 31 /* String */ -#define RAD_NAS_IDENTIFIER 32 /* Integer */ +#define RAD_NAS_IDENTIFIER 32 /* String */ #define RAD_PROXY_STATE 33 /* Integer */ #define RAD_LOGIN_LAT_SERVICE 34 /* Integer */ #define RAD_LOGIN_LAT_NODE 35 /* Integer */ From owner-svn-src-all@freebsd.org Sun Mar 12 13:42:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E6919D09D75; Sun, 12 Mar 2017 13:42:41 +0000 (UTC) (envelope-from des@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 A73D510EB; Sun, 12 Mar 2017 13:42:41 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDgeuR070497; Sun, 12 Mar 2017 13:42:40 GMT (envelope-from des@FreeBSD.org) Received: (from des@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDgeT5070496; Sun, 12 Mar 2017 13:42:40 GMT (envelope-from des@FreeBSD.org) Message-Id: <201703121342.v2CDgeT5070496@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: des set sender to des@FreeBSD.org using -f From: =?UTF-8?Q?Dag-Erling_Sm=c3=b8rgrav?= Date: Sun, 12 Mar 2017 13:42:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315154 - stable/10/sbin/geom/class/part X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:42:42 -0000 Author: des Date: Sun Mar 12 13:42:40 2017 New Revision: 315154 URL: https://svnweb.freebsd.org/changeset/base/315154 Log: MFH (r303289): update example section PR: 211361 Modified: stable/10/sbin/geom/class/part/gpart.8 Directory Properties: stable/10/ (props changed) Modified: stable/10/sbin/geom/class/part/gpart.8 ============================================================================== --- stable/10/sbin/geom/class/part/gpart.8 Sun Mar 12 13:36:14 2017 (r315153) +++ stable/10/sbin/geom/class/part/gpart.8 Sun Mar 12 13:42:40 2017 (r315154) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 10, 2015 +.Dd July 25, 2016 .Dt GPART 8 .Os .Sh NAME @@ -1193,86 +1193,112 @@ Otherwise the values will be left unchan .Sh EXIT STATUS Exit status is 0 on success, and 1 if the command fails. .Sh EXAMPLES -Create a GPT scheme on -.Pa ada0 : +The examples below assume that the disk's logical block size is 512 +bytes, regardless of its physical block size. +.Ss GPT +In this example, we will format +.Pa ada0 +with the GPT scheme and create boot, swap and root partitions. +First, we need to create the partition table: .Bd -literal -offset indent /sbin/gpart create -s GPT ada0 .Ed .Pp -Embed GPT bootstrap code into a protective MBR: +Next, we install a protective MBR with the first-stage bootstrap code. +The protective MBR lists a single, bootable partition spanning the +entire disk, thus allowing non-GPT-aware BIOSes to boot from the disk +and preventing tools which do not understand the GPT scheme from +considering the disk to be unformatted. .Bd -literal -offset indent /sbin/gpart bootcode -b /boot/pmbr ada0 .Ed .Pp -Create a dedicated +We then create a dedicated .Cm freebsd-boot -partition that can boot +partition to hold the second-stage boot loader, which will load the .Fx -from a -.Cm freebsd-ufs -partition, and install bootstrap code into it. +kernel and modules from a UFS or ZFS filesystem. This partition must be larger than the bootstrap code .Po -usually either +either .Pa /boot/gptboot -or +for UFS or .Pa /boot/gptzfsboot +for ZFS .Pc , but smaller than 545 kB since the first-stage loader will load the entire partition into memory during boot, regardless of how much data it actually contains. -This example uses 88 blocks (44 kB) so the next partition will be -aligned on a 64 kB boundary without the need to specify an explicit -offset or alignment. -The boot partition itself is aligned on a 4 kB boundary. +We create a 472-block (236 kB) boot partition at offset 40, which is +the size of the partition table (34 blocks or 17 kB) rounded up to the +nearest 4 kB boundary. .Bd -literal -offset indent -/sbin/gpart add -b 40 -s 88 -t freebsd-boot ada0 +/sbin/gpart add -b 40 -s 472 -t freebsd-boot ada0 /sbin/gpart bootcode -p /boot/gptboot -i 1 ada0 .Ed .Pp -Create a 512MB-sized +We now create a 4 GB swap partition at the first available offset, +which is 40 + 472 = 512 blocks (256 kB). +.Bd -literal -offset indent +/sbin/gpart add -s 4G -t freebsd-swap ada0 +.Ed +.Pp +Aligning the swap partition and all subsequent partitions on a 256 kB +boundary ensures optimal performance on a wide range of media, from +plain old disks with 512-byte blocks, through modern +.Dq advanced format +disks with 4096-byte physical blocks, to RAID volumes with stripe +sizes of up to 256 kB. +.Pp +Finally, we create and format an 8 GB .Cm freebsd-ufs -partition to contain a UFS filesystem from which the system can boot. +partition for the root filesystem, leaving the rest of the slice free +for additional filesystems: .Bd -literal -offset indent -/sbin/gpart add -s 512M -t freebsd-ufs ada0 +/sbin/gpart add -s 8G -t freebsd-ufs ada0 +/sbin/newfs -Uj /dev/ada0p3 .Ed +.Ss MBR +In this example, we will format +.Pa ada0 +with the MBR scheme and create a single partition which we subdivide +using a traditional +.Bx +disklabel. .Pp -Create an MBR scheme on -.Pa ada0 , -then create a 30GB-sized -.Fx -slice, mark it active and -install the -.Nm boot0 -boot manager: +First, we create the partition table and a single 64 GB partition, +then we mark that partition active (bootable) and install the +first-stage boot loader: .Bd -literal -offset indent /sbin/gpart create -s MBR ada0 -/sbin/gpart add -t freebsd -s 30G ada0 +/sbin/gpart add -t freebsd -s 64G ada0 /sbin/gpart set -a active -i 1 ada0 /sbin/gpart bootcode -b /boot/boot0 ada0 .Ed .Pp -Now create a -.Bx -scheme -.Pf ( Bx -label) with space for up to 20 partitions: +Next, we create a disklabel in that partition +.Po +.Dq slice +in disklabel terminology +.Pc +with room for up to 20 partitions: .Bd -literal -offset indent /sbin/gpart create -s BSD -n 20 ada0s1 .Ed .Pp -Create a 1GB-sized UFS partition and a 4GB-sized swap partition: +We then create an 8 GB root partition and a 4 GB swap partition: .Bd -literal -offset indent -/sbin/gpart add -t freebsd-ufs -s 1G ada0s1 +/sbin/gpart add -t freebsd-ufs -s 8G ada0s1 /sbin/gpart add -t freebsd-swap -s 4G ada0s1 .Ed .Pp -Install bootstrap code for the +Finally, we install the appropriate boot loader for the .Bx label: .Bd -literal -offset indent /sbin/gpart bootcode -b /boot/boot ada0s1 .Ed +.Ss VTOC8 .Pp Create a VTOC8 scheme on .Pa da0 : @@ -1298,6 +1324,7 @@ After creating all required partitions, .Bd -literal -offset indent /sbin/gpart bootcode -p /boot/boot1 da0 .Ed +.Ss Backup and Restore .Pp Create a backup of the partition table from .Pa da0 : From owner-svn-src-all@freebsd.org Sun Mar 12 13:46:11 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DE2E2D09EEE; Sun, 12 Mar 2017 13:46:11 +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 A79AD1376; Sun, 12 Mar 2017 13:46:11 +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 333AB5330; Sun, 12 Mar 2017 13:46:10 +0000 (UTC) Received: by desk.des.no (Postfix, from userid 1001) id 07556736F; Sun, 12 Mar 2017 14:46:09 +0100 (CET) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Ravi Pokala Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: Re: svn commit: r313433 - stable/10/usr.sbin/bsdinstall/partedit References: <201702080837.v188bir1055373@repo.freebsd.org> Date: Sun, 12 Mar 2017 14:46:09 +0100 In-Reply-To: <201702080837.v188bir1055373@repo.freebsd.org> (Ravi Pokala's message of "Wed, 8 Feb 2017 08:37:44 +0000 (UTC)") Message-ID: <86o9x6d2vy.fsf@desk.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:46:12 -0000 Ravi Pokala writes: > Log: > MFC r304142: ensure stripe size is non-zero multiple of 4096 > [...] Please include the PR number in the commit message when you merge a commit associated with a PR. DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-svn-src-all@freebsd.org Sun Mar 12 13:48:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1B720D09F6C; Sun, 12 Mar 2017 13:48:26 +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 EA3081517; Sun, 12 Mar 2017 13:48:25 +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 v2CDmPTG070777; Sun, 12 Mar 2017 13:48:25 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDmOpp070774; Sun, 12 Mar 2017 13:48:24 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121348.v2CDmOpp070774@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 13:48:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315155 - in head/sys: kern sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:48:26 -0000 Author: kib Date: Sun Mar 12 13:48:24 2017 New Revision: 315155 URL: https://svnweb.freebsd.org/changeset/base/315155 Log: Ktracing kevent(2) calls with unusual arguments might leads to an overly large allocation requests. When ktrace-ing io, sys_kevent() allocates memory to copy the requested changes and reported events. Allocations are sized by the incoming syscall lengths arguments, which are user-controlled, and might cause overflow in calculations or too large allocations. Since io trace chunks are limited by ktr_geniosize, there is no sense it even trying to satisfy unbounded allocations. Export ktr_geniosize and clamp the buffers sizes in advance. PR: 217435 Reported by: Tim Newsham Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/kern/kern_event.c head/sys/kern/kern_ktrace.c head/sys/sys/ktrace.h Modified: head/sys/kern/kern_event.c ============================================================================== --- head/sys/kern/kern_event.c Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/kern/kern_event.c Sun Mar 12 13:48:24 2017 (r315155) @@ -887,6 +887,15 @@ kern_kqueue(struct thread *td, int flags return (0); } +static size_t +kev_iovlen(int n, u_int kgio) +{ + + if (n < 0 || n >= kgio / sizeof(struct kevent)) + return (kgio); + return (n * sizeof(struct kevent)); +} + #ifndef _SYS_SYSPROTO_H_ struct kevent_args { int fd; @@ -910,6 +919,7 @@ sys_kevent(struct thread *td, struct kev struct iovec ktriov; struct uio *ktruioin = NULL; struct uio *ktruioout = NULL; + u_int kgio; #endif if (uap->timeout != NULL) { @@ -922,13 +932,15 @@ sys_kevent(struct thread *td, struct kev #ifdef KTRACE if (KTRPOINT(td, KTR_GENIO)) { + kgio = ktr_geniosize; ktriov.iov_base = uap->changelist; - ktriov.iov_len = uap->nchanges * sizeof(struct kevent); + ktriov.iov_len = kev_iovlen(uap->nchanges, kgio); ktruio = (struct uio){ .uio_iov = &ktriov, .uio_iovcnt = 1, .uio_segflg = UIO_USERSPACE, .uio_rw = UIO_READ, .uio_td = td }; ktruioin = cloneuio(&ktruio); ktriov.iov_base = uap->eventlist; + ktriov.iov_len = kev_iovlen(uap->nevents, kgio); ktriov.iov_len = uap->nevents * sizeof(struct kevent); ktruioout = cloneuio(&ktruio); } @@ -939,9 +951,9 @@ sys_kevent(struct thread *td, struct kev #ifdef KTRACE if (ktruioin != NULL) { - ktruioin->uio_resid = uap->nchanges * sizeof(struct kevent); + ktruioin->uio_resid = kev_iovlen(uap->nchanges, kgio); ktrgenio(uap->fd, UIO_WRITE, ktruioin, 0); - ktruioout->uio_resid = td->td_retval[0] * sizeof(struct kevent); + ktruioout->uio_resid = kev_iovlen(td->td_retval[0], kgio); ktrgenio(uap->fd, UIO_READ, ktruioout, error); } #endif Modified: head/sys/kern/kern_ktrace.c ============================================================================== --- head/sys/kern/kern_ktrace.c Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/kern/kern_ktrace.c Sun Mar 12 13:48:24 2017 (r315155) @@ -132,7 +132,7 @@ static SYSCTL_NODE(_kern, OID_AUTO, ktra static u_int ktr_requestpool = KTRACE_REQUEST_POOL; TUNABLE_INT("kern.ktrace.request_pool", &ktr_requestpool); -static u_int ktr_geniosize = PAGE_SIZE; +u_int ktr_geniosize = PAGE_SIZE; SYSCTL_UINT(_kern_ktrace, OID_AUTO, genio_size, CTLFLAG_RWTUN, &ktr_geniosize, 0, "Maximum size of genio event payload"); Modified: head/sys/sys/ktrace.h ============================================================================== --- head/sys/sys/ktrace.h Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/sys/ktrace.h Sun Mar 12 13:48:24 2017 (r315155) @@ -276,7 +276,7 @@ void ktrcapfail(enum ktr_cap_fail_type, ktrstruct("sockaddr", (s), ((struct sockaddr *)(s))->sa_len) #define ktrstat(s) \ ktrstruct("stat", (s), sizeof(struct stat)) - +extern u_int ktr_geniosize; #else #include From owner-svn-src-all@freebsd.org Sun Mar 12 13:49:43 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CC3C2D09025; Sun, 12 Mar 2017 13:49:43 +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 9BFF816F3; Sun, 12 Mar 2017 13:49:43 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDngSP070871; Sun, 12 Mar 2017 13:49:42 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDng6r070870; Sun, 12 Mar 2017 13:49:42 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121349.v2CDng6r070870@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 13:49:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315156 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:49:43 -0000 Author: kib Date: Sun Mar 12 13:49:42 2017 New Revision: 315156 URL: https://svnweb.freebsd.org/changeset/base/315156 Log: Style. Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sun Mar 12 13:48:24 2017 (r315155) +++ head/sys/kern/imgact_elf.c Sun Mar 12 13:49:42 2017 (r315156) @@ -508,7 +508,7 @@ __elfN(load_section)(struct image_params size_t map_len; vm_map_t map; vm_object_t object; - vm_offset_t map_addr; + vm_offset_t off, map_addr; int error, rv, cow; size_t copy_len; vm_ooffset_t file_addr; @@ -559,9 +559,8 @@ __elfN(load_section)(struct image_params return (EINVAL); /* we can stop now if we've covered it all */ - if (memsz == filsz) { + if (memsz == filsz) return (0); - } } @@ -580,14 +579,11 @@ __elfN(load_section)(struct image_params if (map_len != 0) { rv = __elfN(map_insert)(imgp, map, NULL, 0, map_addr, map_addr + map_len, VM_PROT_ALL, 0); - if (rv != KERN_SUCCESS) { + if (rv != KERN_SUCCESS) return (EINVAL); - } } if (copy_len != 0) { - vm_offset_t off; - sf = vm_imgact_map_page(object, offset + filsz); if (sf == NULL) return (EIO); @@ -598,14 +594,12 @@ __elfN(load_section)(struct image_params error = copyout((caddr_t)sf_buf_kva(sf) + off, (caddr_t)map_addr, copy_len); vm_imgact_unmap_page(sf); - if (error) { + if (error != 0) return (error); - } } /* * set it to the specified protection. - * XXX had better undo the damage from pasting over the cracks here! */ vm_map_protect(map, trunc_page(map_addr), round_page(map_addr + map_len), prot, FALSE); From owner-svn-src-all@freebsd.org Sun Mar 12 13:51:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EBE07D0909D; Sun, 12 Mar 2017 13:51:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A02CF18EC; Sun, 12 Mar 2017 13:51:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDpDRg070987; Sun, 12 Mar 2017 13:51:13 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDpDWe070986; Sun, 12 Mar 2017 13:51:13 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121351.v2CDpDWe070986@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 13:51:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315157 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:51:15 -0000 Author: kib Date: Sun Mar 12 13:51:13 2017 New Revision: 315157 URL: https://svnweb.freebsd.org/changeset/base/315157 Log: Accept linkers representation for ELF segments with zero on-disk length. For such segments, GNU bfd linker writes knowingly incorrect value into the the file offset field of the program header entry, with the motivation that file should not be mapped for creation of this segment at all. Relax checks for the ELF structure validity when on-disk segment length is zero, and explicitely set mapping length to zero for such segments to avoid validating rounding arithmetic. PR: 217610 Reported by: Robert Clausecker Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/kern/imgact_elf.c Modified: head/sys/kern/imgact_elf.c ============================================================================== --- head/sys/kern/imgact_elf.c Sun Mar 12 13:49:42 2017 (r315156) +++ head/sys/kern/imgact_elf.c Sun Mar 12 13:51:13 2017 (r315157) @@ -522,7 +522,8 @@ __elfN(load_section)(struct image_params * While I'm here, might as well check for something else that * is invalid: filsz cannot be greater than memsz. */ - if ((off_t)filsz + offset > imgp->attr->va_size || filsz > memsz) { + if ((filsz != 0 && (off_t)filsz + offset > imgp->attr->va_size) || + filsz > memsz) { uprintf("elf_load_section: truncated ELF file\n"); return (ENOEXEC); } @@ -538,7 +539,9 @@ __elfN(load_section)(struct image_params * early and copy the initialized data into that first page. We * choose the second. */ - if (memsz > filsz) + if (filsz == 0) + map_len = 0; + else if (memsz > filsz) map_len = trunc_page_ps(offset + filsz, pagesize) - file_addr; else map_len = round_page_ps(offset + filsz, pagesize) - file_addr; @@ -570,7 +573,8 @@ __elfN(load_section)(struct image_params * segment in the file is extended to provide bss. It's a neat idea * to try and save a page, but it's a pain in the behind to implement. */ - copy_len = (offset + filsz) - trunc_page_ps(offset + filsz, pagesize); + copy_len = filsz == 0 ? 0 : (offset + filsz) - trunc_page_ps(offset + + filsz, pagesize); map_addr = trunc_page_ps((vm_offset_t)vmaddr + filsz, pagesize); map_len = round_page_ps((vm_offset_t)vmaddr + memsz, pagesize) - map_addr; From owner-svn-src-all@freebsd.org Sun Mar 12 13:53:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 94692D092E1; Sun, 12 Mar 2017 13:53:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 61BD81DB7; Sun, 12 Mar 2017 13:53:14 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CDrDg4074588; Sun, 12 Mar 2017 13:53:13 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDrDq0074587; Sun, 12 Mar 2017 13:53:13 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121353.v2CDrDq0074587@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 13:53:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315158 - head/sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:53:14 -0000 Author: kib Date: Sun Mar 12 13:53:13 2017 New Revision: 315158 URL: https://svnweb.freebsd.org/changeset/base/315158 Log: Follow-up to r313690. Fix two missed places where vm_object offset to index calculation should use unsigned shift, to allow handling of full range of unsigned offsets used to create device mappings. Reported and tested by: royger (previous version) Reviewed by: alc (previous version) Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/vm/vm_map.c Modified: head/sys/vm/vm_map.c ============================================================================== --- head/sys/vm/vm_map.c Sun Mar 12 13:51:13 2017 (r315157) +++ head/sys/vm/vm_map.c Sun Mar 12 13:53:13 2017 (r315158) @@ -4122,7 +4122,7 @@ RetryLookup:; * Return the object/offset from this entry. If the entry was * copy-on-write or empty, it has been fixed up. */ - *pindex = OFF_TO_IDX((vaddr - entry->start) + entry->offset); + *pindex = UOFF_TO_IDX((vaddr - entry->start) + entry->offset); *object = entry->object.vm_object; *out_prot = prot; @@ -4203,7 +4203,7 @@ vm_map_lookup_locked(vm_map_t *var_map, * Return the object/offset from this entry. If the entry was * copy-on-write or empty, it has been fixed up. */ - *pindex = OFF_TO_IDX((vaddr - entry->start) + entry->offset); + *pindex = UOFF_TO_IDX((vaddr - entry->start) + entry->offset); *object = entry->object.vm_object; *out_prot = prot; From owner-svn-src-all@freebsd.org Sun Mar 12 13:58:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 42B03D0946F; Sun, 12 Mar 2017 13:58:53 +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 E9EED103E; Sun, 12 Mar 2017 13:58:52 +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 v2CDwq5K074834; Sun, 12 Mar 2017 13:58:52 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CDwpxU074833; Sun, 12 Mar 2017 13:58:51 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703121358.v2CDwpxU074833@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Sun, 12 Mar 2017 13:58:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315159 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 13:58:53 -0000 Author: kib Date: Sun Mar 12 13:58:51 2017 New Revision: 315159 URL: https://svnweb.freebsd.org/changeset/base/315159 Log: Avoid reusing p_ksi while it is on queue. When sending SIGCHLD informing reaper that a zombie was reparented to it, we might race with the situation where the previous parent still not finished delivering SIGCHLD and having its p_ksi structure on the signal queue. While on queue, the ksi should not be used for another send. Fix this by copying p_ksi into newly allocated ksi, which is directly put onto reaper sigqueue. The later ensures that siginfo for reaper SIGCHLD is always present, similar to guarantees for siginfo of child. Reported by: bdrewery Discussed with: jilles Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/kern/kern_exit.c Modified: head/sys/kern/kern_exit.c ============================================================================== --- head/sys/kern/kern_exit.c Sun Mar 12 13:53:13 2017 (r315158) +++ head/sys/kern/kern_exit.c Sun Mar 12 13:58:51 2017 (r315159) @@ -189,6 +189,7 @@ exit1(struct thread *td, int rval, int s { struct proc *p, *nq, *q, *t; struct thread *tdt; + ksiginfo_t *ksi, *ksi1; mtx_assert(&Giant, MA_NOTOWNED); KASSERT(rval == 0 || signo == 0, ("exit1 rv %d sig %d", rval, signo)); @@ -449,14 +450,32 @@ exit1(struct thread *td, int rval, int s wakeup(q->p_reaper); for (; q != NULL; q = nq) { nq = LIST_NEXT(q, p_sibling); + ksi = ksiginfo_alloc(TRUE); PROC_LOCK(q); q->p_sigparent = SIGCHLD; if (!(q->p_flag & P_TRACED)) { proc_reparent(q, q->p_reaper); if (q->p_state == PRS_ZOMBIE) { + /* + * Inform reaper about the reparented + * zombie, since wait(2) has something + * new to report. Guarantee queueing + * of the SIGCHLD signal, similar to + * the _exit() behaviour, by providing + * our ksiginfo. Ksi is freed by the + * signal delivery. + */ + if (q->p_ksi == NULL) { + ksi1 = NULL; + } else { + ksiginfo_copy(q->p_ksi, ksi); + ksi->ksi_flags |= KSI_INS; + ksi1 = ksi; + ksi = NULL; + } PROC_LOCK(q->p_reaper); - pksignal(q->p_reaper, SIGCHLD, q->p_ksi); + pksignal(q->p_reaper, SIGCHLD, ksi1); PROC_UNLOCK(q->p_reaper); } } else { @@ -489,6 +508,8 @@ exit1(struct thread *td, int rval, int s kern_psignal(q, SIGKILL); } PROC_UNLOCK(q); + if (ksi != NULL) + ksiginfo_free(ksi); } /* From owner-svn-src-all@freebsd.org Sun Mar 12 14:07:06 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DC03DD09741; Sun, 12 Mar 2017 14:07:06 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x242.google.com (mail-pf0-x242.google.com [IPv6:2607:f8b0:400e:c00::242]) (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 AC30D14FD; Sun, 12 Mar 2017 14:07:06 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x242.google.com with SMTP id v190so16162728pfb.0; Sun, 12 Mar 2017 07:07:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=rxJRkaeJfAoUmFV6Mr/iEpc3SryLnvquE3YtNw7gRgY=; b=CNeEVSmlKYUCJjgUtimQPKtLmuIB8hcPSJeFPgiQZU2GqXLn/I5HWAQdpuLJqYS6AE 5i1Lb9bTEh8YZd3rFmQ3PJqLnJyA6qLp+75ucma68YbwnuRYzp4kfsXaswjoi8W8mzhS gCu79Dihl4v5Wc5vK50+v5V1Q52c71yIpMC0puJ+wIzedgHQqTCM3SoBMPN6fnnYv8fr KB+5OY9dsurPPZCKbeVyXp5Idhv5STJK2V5rkXXq+N1O7Xlg69NoHRBNEjL1PgtkZ3NR ek1oWFBsoMQbOsC2jBIKddE/oDksVIb1FU3vEQkka+d0by9qRvTq6mxtuuIs80qfwMMJ X3sw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=rxJRkaeJfAoUmFV6Mr/iEpc3SryLnvquE3YtNw7gRgY=; b=E956WJko2ZGm9U1nZTF+GhvxXnpQGRikTR/teQofxGDIEd2JMErcnKJgGZWuiZ0PUc +/kncnDV2eWvsEXt7HAprgjpkcoRZT+rnUUjGKtvbj4YpH6dSZSKjSyPgYkwzFZgc5W2 1eFxTOWbFSPBr0Qk8wBK+5xHplrARnueBsmxEEmex/iNG3YwXcLSED9B5ZuUtGiEE9bg +/No/IQQlpnTLb+x8m67XtYisS8RYSCp67QjIM5Vcsy37TAWdWYTn0FjshQj4jpzbpqy C8H46Al6dUPTfWpg/6xyrM/qDXqHyCvVAQ6kAEYyFFmesyjkJPwWdtR83izn/N7HQarK /x4A== X-Gm-Message-State: AMke39nSLLwxTF0mxsQPRU/jdYFKmJGRIHwumRCeM/dqifnRWS2/B30S9QFBBs2pSh2fWA== X-Received: by 10.84.128.98 with SMTP id 89mr41270995pla.24.1489327626185; Sun, 12 Mar 2017 07:07:06 -0700 (PDT) Received: from [192.168.20.13] (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id 80sm28632746pfn.61.2017.03.12.07.07.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 12 Mar 2017 07:07:05 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (1.0) Subject: Re: svn commit: r308996 - head/lib/libfetch From: Ngie Cooper X-Mailer: iPhone Mail (14D27) In-Reply-To: <86shmid9ct.fsf@desk.des.no> Date: Sun, 12 Mar 2017 07:07:05 -0700 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: <92F67C24-E539-4810-9014-DCC019DD0CBB@gmail.com> References: <201611221330.uAMDU7fg052989@repo.freebsd.org> <93505FD7-FB42-4BD5-834C-6F73EFD9B1CF@gmail.com> <86shmid9ct.fsf@desk.des.no> To: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 14:07:07 -0000 > On Mar 12, 2017, at 04:26, Dag-Erling Sm=C3=B8rgrav wrote: >=20 > "Ngie Cooper (yaneurabeya)" writes: >> Hi Bjoern, >=20 > No, that was my father :) :D.. >> Shouldn=E2=80=99t this be strrchr instead of strchr since you=E2=80=99= re >> scanning for the service from the right side of the host, >> e.g. =E2=80=9Cfoo:service=E2=80=9D or =E2=80=9C[::1]:service=E2=80=9D? Th= is code would match index 3 >> in the first example, but it would match index 2 in the second >> example. >=20 > Correct, although it may be slightly more complicated, which is why I > didn't immediately jump on it when bz@ pointed it out. I'm working on > it right now. Awesome! Great teamwork! -Ngie= From owner-svn-src-all@freebsd.org Sun Mar 12 14:17:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6A805D09A60; Sun, 12 Mar 2017 14:17:59 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2AE061A98; Sun, 12 Mar 2017 14:17:59 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CEHw6D082984; Sun, 12 Mar 2017 14:17:58 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CEHvSv082980; Sun, 12 Mar 2017 14:17:57 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703121417.v2CEHvSv082980@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 14:17:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315160 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 14:17:59 -0000 Author: mav Date: Sun Mar 12 14:17:57 2017 New Revision: 315160 URL: https://svnweb.freebsd.org/changeset/base/315160 Log: Remove code for unsupported FreeBSD versions. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h head/sys/dev/isp/isp_target.c Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Sun Mar 12 13:58:51 2017 (r315159) +++ head/sys/dev/isp/isp.c Sun Mar 12 14:17:57 2017 (r315160) @@ -4514,15 +4514,7 @@ isp_start(XS_T *xs) t7->req_tidlo = lp->portid; t7->req_tidhi = lp->portid >> 16; t7->req_vpidx = ISP_GET_VPIDX(isp, XS_CHANNEL(xs)); -#if __FreeBSD_version >= 1000700 be64enc(t7->req_lun, CAM_EXTLUN_BYTE_SWIZZLE(XS_LUN(xs))); -#else - if (XS_LUN(xs) >= 256) { - t7->req_lun[0] = XS_LUN(xs) >> 8; - t7->req_lun[0] |= 0x40; - } - t7->req_lun[1] = XS_LUN(xs); -#endif if (FCPARAM(isp, XS_CHANNEL(xs))->fctape_enabled && (lp->prli_word3 & PRLI_WD3_RETRY)) { if (FCP_NEXT_CRN(isp, &t7->req_crn, xs)) { isp_prt(isp, ISP_LOG_WARN1, @@ -4555,19 +4547,11 @@ isp_start(XS_T *xs) ispreqt2e_t *t2e = (ispreqt2e_t *)local; t2e->req_target = lp->handle; t2e->req_scclun = XS_LUN(xs); -#if __FreeBSD_version < 1000700 - if (XS_LUN(xs) >= 256) - t2e->req_scclun |= 0x4000; -#endif cdbp = t2e->req_cdb; } else if (ISP_CAP_SCCFW(isp)) { ispreqt2_t *t2 = (ispreqt2_t *)local; t2->req_target = lp->handle; t2->req_scclun = XS_LUN(xs); -#if __FreeBSD_version < 1000700 - if (XS_LUN(xs) >= 256) - t2->req_scclun |= 0x4000; -#endif cdbp = t2->req_cdb; } else { t2->req_target = lp->handle; Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Sun Mar 12 13:58:51 2017 (r315159) +++ head/sys/dev/isp/isp_freebsd.c Sun Mar 12 14:17:57 2017 (r315160) @@ -391,9 +391,7 @@ isp_freeze_loopdown(ispsoftc_t *isp, int isp_prt(isp, ISP_LOGDEBUG0, "Chan %d Freeze simq (loopdown)", chan); fc->simqfrozen = SIMQFRZ_LOOPDOWN; -#if __FreeBSD_version >= 1000039 xpt_hold_boot(); -#endif xpt_freeze_simq(fc->sim, 1); } else { isp_prt(isp, ISP_LOGDEBUG0, @@ -414,9 +412,7 @@ isp_unfreeze_loopdown(ispsoftc_t *isp, i isp_prt(isp, ISP_LOGDEBUG0, "Chan %d Release simq", chan); xpt_release_simq(fc->sim, 1); -#if __FreeBSD_version >= 1000039 xpt_release_boot(); -#endif } } } @@ -1736,10 +1732,6 @@ isp_target_putback_atio(union ccb *ccb) at->at_header.rqs_entry_count = 1; if (ISP_CAP_SCCFW(isp)) { at->at_scclun = (uint16_t) ccb->ccb_h.target_lun; -#if __FreeBSD_version < 1000700 - if (at->at_scclun >= 256) - at->at_scclun |= 0x4000; -#endif } else { at->at_lun = (uint8_t) ccb->ccb_h.target_lun; } @@ -1788,9 +1780,6 @@ isp_handle_platform_atio2(ispsoftc_t *is fcp = FCPARAM(isp, 0); if (ISP_CAP_SCCFW(isp)) { lun = aep->at_scclun; -#if __FreeBSD_version < 1000700 - lun &= 0x3fff; -#endif } else { lun = aep->at_lun; } @@ -1926,12 +1915,7 @@ isp_handle_platform_atio7(ispsoftc_t *is did = (aep->at_hdr.d_id[0] << 16) | (aep->at_hdr.d_id[1] << 8) | aep->at_hdr.d_id[2]; sid = (aep->at_hdr.s_id[0] << 16) | (aep->at_hdr.s_id[1] << 8) | aep->at_hdr.s_id[2]; -#if __FreeBSD_version >= 1000700 lun = CAM_EXTLUN_BYTE_SWIZZLE(be64dec(aep->at_cmnd.fcp_cmnd_lun)); -#else - lun = (aep->at_cmnd.fcp_cmnd_lun[0] & 0x3f << 8) | - aep->at_cmnd.fcp_cmnd_lun[1]; -#endif /* * Find the N-port handle, and Virtual Port Index for this command. @@ -2419,9 +2403,6 @@ isp_handle_platform_notify_fc(ispsoftc_t if (ISP_CAP_SCCFW(isp)) { lun = inp->in_scclun; -#if __FreeBSD_version < 1000700 - lun &= 0x3fff; -#endif } else { lun = inp->in_lun; } @@ -3879,12 +3860,7 @@ isp_action(struct cam_sim *sim, union cc fcparam *fcp = FCPARAM(isp, bus); cpi->hba_misc = PIM_NOBUSRESET | PIM_UNMAPPED; -#if __FreeBSD_version >= 1000700 - cpi->hba_misc |= PIM_EXTLUNS; -#endif -#if __FreeBSD_version >= 1000039 - cpi->hba_misc |= PIM_NOSCAN; -#endif + cpi->hba_misc |= PIM_EXTLUNS | PIM_NOSCAN; /* * Because our loop ID can shift from time to time, Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Sun Mar 12 13:58:51 2017 (r315159) +++ head/sys/dev/isp/isp_freebsd.h Sun Mar 12 14:17:57 2017 (r315160) @@ -384,13 +384,8 @@ struct isposinfo { #define ISP_MEMCPY memcpy #define ISP_SNPRINTF snprintf #define ISP_DELAY(x) DELAY(x) -#if __FreeBSD_version < 1000029 -#define ISP_SLEEP(isp, x) msleep(&(isp)->isp_osinfo.is_exiting, \ - &(isp)->isp_osinfo.lock, 0, "isp_sleep", ((x) + tick - 1) / tick) -#else #define ISP_SLEEP(isp, x) msleep_sbt(&(isp)->isp_osinfo.is_exiting, \ &(isp)->isp_osinfo.lock, 0, "isp_sleep", (x) * SBT_1US, 0, 0) -#endif #define ISP_MIN imin Modified: head/sys/dev/isp/isp_target.c ============================================================================== --- head/sys/dev/isp/isp_target.c Sun Mar 12 13:58:51 2017 (r315159) +++ head/sys/dev/isp/isp_target.c Sun Mar 12 14:17:57 2017 (r315160) @@ -726,9 +726,6 @@ isp_got_msg_fc(ispsoftc_t *isp, in_fcent /* nt_tgt set in outer layers */ if (ISP_CAP_SCCFW(isp)) { notify.nt_lun = inp->in_scclun; -#if __FreeBSD_version < 1000700 - notify.nt_lun &= 0x3fff; -#endif } else { notify.nt_lun = inp->in_lun; } @@ -1017,9 +1014,6 @@ isp_handle_atio2(ispsoftc_t *isp, at2_en if (ISP_CAP_SCCFW(isp)) { lun = aep->at_scclun; -#if __FreeBSD_version < 1000700 - lun &= 0x3fff; -#endif } else { lun = aep->at_lun; } From owner-svn-src-all@freebsd.org Sun Mar 12 15:35:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 30558D09032; Sun, 12 Mar 2017 15:35:30 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail109.syd.optusnet.com.au (mail109.syd.optusnet.com.au [211.29.132.80]) by mx1.freebsd.org (Postfix) with ESMTP id EDE57114B; Sun, 12 Mar 2017 15:35:29 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c122-106-153-191.carlnfd1.nsw.optusnet.com.au [122.106.153.191]) by mail109.syd.optusnet.com.au (Postfix) with ESMTPS id 9AB73D64DCB; Mon, 13 Mar 2017 02:35:20 +1100 (AEDT) Date: Mon, 13 Mar 2017 02:35:19 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Andriy Gapon cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315068 - head/sys/modules/qlxgbe In-Reply-To: <18e52ee7-0b27-7aff-6b69-75b27673a8f4@FreeBSD.org> Message-ID: <20170313020809.P31989@besplex.bde.org> References: <201703111516.v2BFGtkn006959@repo.freebsd.org> <20170312124945.C4483@besplex.bde.org> <18e52ee7-0b27-7aff-6b69-75b27673a8f4@FreeBSD.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=AYLBJzfG c=1 sm=1 tr=0 a=Tj3pCpwHnMupdyZSltBt7Q==:117 a=Tj3pCpwHnMupdyZSltBt7Q==:17 a=kj9zAlcOel0A:10 a=I_GFfGCxctvMgBUQ9gcA:9 a=CjuIK1q_8ugA:10 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 15:35:30 -0000 On Sun, 12 Mar 2017, Andriy Gapon wrote: > On 12/03/2017 04:44, Bruce Evans wrote: >> On Sat, 11 Mar 2017, Andriy Gapon wrote: >> >>> Log: >>> revert r314862, use of GCC_MS_EXTENSIONS in qlxgbe >>> >>> Commit r278913 made explicit use of GCC_MS_EXTENSIONS unnecessary. >>> >>> Requested by: glebius >> >> Does this module actually use ms extensions? This seems unlikely, since >> only gcc supports them. > > It probably doesn't. > >> My kernels compile correctly with the correct CFLAGS (gcc -std=gnu99 >> -fno-ms-extensions). > > How did you manage to pass -std=gnu99 to the module build? I edited kern.mk to change CSTD together with removing -fms-extensions. > No matter what flags I tried to modify the actual compiler invocations still had > -std=iso9899:1999 after -std=gnu99 in them, so my modifications had no effect. > GCC_MS_EXTENSIONS was the easiest way to get the job done. Hmm, more bugs: - kern.mk forces its wrong CSTD using '='. bsd.sys.mk uses '?=' as well as the correct CSTD. - -fms-extensions is now hard-coded too. However, it is a bit earlier in CFLAGS so might be easier to override. Controlling the order of CFLAGS has always been a problem. There are many undocumented macros and it isn't clear which ones are implementation details. Now I get -std second last and -Werror last CFLAGS. -Werror is set by WERROR?=, so WERROR can be used for overrides. Overriding -std is accepted and hopefully works. WERROR is before PROF in NORMAL_C, but PROF is not in NORMAL_S or PROFILE_C, so of you want to override PROF then you have to fix this or duplicate the overrides in WERROR and PROF. There are further problems with special rules. The ones for aesni are of nearly the lowest quality. These ensure breaking gcc using the order WERROR, NO_CAST_QUAL, PROF, then main unportable -m's (with at least -msse4 unsupported by gcc-4.2.1), then .IMPSRC. Bruce From owner-svn-src-all@freebsd.org Sun Mar 12 15:36:09 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0C233D090A5; Sun, 12 Mar 2017 15:36:09 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C203C12AE; Sun, 12 Mar 2017 15:36:08 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CFa7As016636; Sun, 12 Mar 2017 15:36:07 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CFa78J016633; Sun, 12 Mar 2017 15:36:07 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703121536.v2CFa78J016633@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 15:36:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315161 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 15:36:09 -0000 Author: mav Date: Sun Mar 12 15:36:07 2017 New Revision: 315161 URL: https://svnweb.freebsd.org/changeset/base/315161 Log: Try to slight untangle I/O and loop status handling. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Sun Mar 12 14:17:57 2017 (r315160) +++ head/sys/dev/isp/isp.c Sun Mar 12 15:36:07 2017 (r315161) @@ -4343,13 +4343,6 @@ isp_start(XS_T *xs) return (CMD_COMPLETE); } - /* - * Try again later. - */ - if (fcp->isp_loopstate != LOOP_READY) { - return (CMD_RQLATER); - } - isp_prt(isp, ISP_LOGDEBUG2, "XS_TGT(xs)=%d", target); lp = &fcp->portdb[target]; if (target < 0 || target >= MAX_FC_TARG || @@ -4357,6 +4350,12 @@ isp_start(XS_T *xs) XS_SETERR(xs, HBA_SELTIMEOUT); return (CMD_COMPLETE); } + if (fcp->isp_loopstate != LOOP_READY) { + isp_prt(isp, ISP_LOGDEBUG1, + "%d.%d.%jx loop is not ready", + XS_CHANNEL(xs), target, (uintmax_t)XS_LUN(xs)); + return (CMD_RQLATER); + } if (lp->state == FC_PORTDB_STATE_ZOMBIE) { isp_prt(isp, ISP_LOGDEBUG1, "%d.%d.%jx target zombie", @@ -6544,7 +6543,8 @@ isp_parse_status(ispsoftc_t *isp, ispsta case RQCS_PORT_CHANGED: isp_prt(isp, ISP_LOGWARN, "port changed for target %d", XS_TGT(xs)); if (XS_NOERR(xs)) { - XS_SETERR(xs, HBA_SELTIMEOUT); + *XS_STSP(xs) = SCSI_BUSY; + XS_SETERR(xs, HBA_TGTBSY); } return; @@ -6693,11 +6693,11 @@ isp_parse_status_24xx(ispsoftc_t *isp, i case RQCS_PORT_CHANGED: isp_prt(isp, ISP_LOGWARN, "port changed for target %d chan %d", XS_TGT(xs), chan); if (XS_NOERR(xs)) { - XS_SETERR(xs, HBA_SELTIMEOUT); + *XS_STSP(xs) = SCSI_BUSY; + XS_SETERR(xs, HBA_TGTBSY); } return; - case RQCS_24XX_ENOMEM: /* f/w resource unavailable */ isp_prt(isp, ISP_LOGWARN, "f/w resource unavailable for target %d chan %d", XS_TGT(xs), chan); if (XS_NOERR(xs)) { Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Sun Mar 12 14:17:57 2017 (r315160) +++ head/sys/dev/isp/isp_freebsd.c Sun Mar 12 15:36:07 2017 (r315161) @@ -3073,7 +3073,6 @@ isp_loop_changed(ispsoftc_t *isp, int ch isp_prt(isp, ISP_LOG_SANCFG|ISP_LOGDEBUG0, "Chan %d Loop changed", chan); if (fcp->role & ISP_ROLE_INITIATOR) isp_freeze_loopdown(isp, chan); - fc->loop_dead = 0; fc->loop_down_time = time_uptime; wakeup(fc); } @@ -3085,7 +3084,6 @@ isp_loop_up(ispsoftc_t *isp, int chan) isp_prt(isp, ISP_LOG_SANCFG|ISP_LOGDEBUG0, "Chan %d Loop is up", chan); fc->loop_seen_once = 1; - fc->loop_dead = 0; fc->loop_down_time = 0; isp_unfreeze_loopdown(isp, chan); } @@ -3149,7 +3147,6 @@ isp_loop_dead(ispsoftc_t *isp, int chan) } isp_unfreeze_loopdown(isp, chan); - fc->loop_dead = 1; fc->loop_down_time = 0; } @@ -3377,18 +3374,6 @@ isp_action(struct cam_sim *sim, union cc callout_reset(&PISP_PCMD(ccb)->wdog, ts, isp_watchdog, ccb); break; case CMD_RQLATER: - /* - * We get this result if the loop isn't ready - * or if the device in question has gone zombie. - */ - if (ISP_FC_PC(isp, bus)->loop_dead) { - isp_prt(isp, ISP_LOGDEBUG0, - "%d.%jx loop is dead", - XS_TGT(ccb), (uintmax_t)XS_LUN(ccb)); - ccb->ccb_h.status = CAM_SEL_TIMEOUT; - isp_done((struct ccb_scsiio *) ccb); - break; - } isp_prt(isp, ISP_LOGDEBUG0, "%d.%jx retry later", XS_TGT(ccb), (uintmax_t)XS_LUN(ccb)); cam_freeze_devq(ccb->ccb_h.path); @@ -3913,8 +3898,6 @@ isp_action(struct cam_sim *sim, union cc } } -#define ISPDDB (CAM_DEBUG_INFO|CAM_DEBUG_TRACE|CAM_DEBUG_CDB) - void isp_done(XS_T *sccb) { @@ -3935,27 +3918,10 @@ isp_done(XS_T *sccb) sccb->ccb_h.status &= ~CAM_SIM_QUEUED; status = sccb->ccb_h.status & CAM_STATUS_MASK; - if (status != CAM_REQ_CMP) { - if (status != CAM_SEL_TIMEOUT) - isp_prt(isp, ISP_LOGDEBUG0, - "target %d lun %jx CAM status 0x%x SCSI status 0x%x", - XS_TGT(sccb), (uintmax_t)XS_LUN(sccb), - sccb->ccb_h.status, sccb->scsi_status); - else if ((IS_FC(isp)) - && (XS_TGT(sccb) < MAX_FC_TARG)) { - fcparam *fcp; - - fcp = FCPARAM(isp, XS_CHANNEL(sccb)); - fcp->portdb[XS_TGT(sccb)].is_target = 0; - } - if ((sccb->ccb_h.status & CAM_DEV_QFRZN) == 0) { - sccb->ccb_h.status |= CAM_DEV_QFRZN; - xpt_freeze_devq(sccb->ccb_h.path, 1); - } - } - - if ((CAM_DEBUGGED(sccb->ccb_h.path, ISPDDB)) && (sccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) { - xpt_print(sccb->ccb_h.path, "cam completion status 0x%x\n", sccb->ccb_h.status); + if (status != CAM_REQ_CMP && + (sccb->ccb_h.status & CAM_DEV_QFRZN) == 0) { + sccb->ccb_h.status |= CAM_DEV_QFRZN; + xpt_freeze_devq(sccb->ccb_h.path, 1); } if (ISP_PCMD(sccb)) { Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Sun Mar 12 14:17:57 2017 (r315160) +++ head/sys/dev/isp/isp_freebsd.h Sun Mar 12 15:36:07 2017 (r315161) @@ -225,8 +225,6 @@ struct isp_fc { simqfrozen : 3, default_id : 8, def_role : 2, /* default role */ - gdt_running : 1, - loop_dead : 1, loop_seen_once : 1, fcbsy : 1, ready : 1; From owner-svn-src-all@freebsd.org Sun Mar 12 16:03:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D1A18D09BFB; Sun, 12 Mar 2017 16:03:36 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8F9401157; Sun, 12 Mar 2017 16:03:36 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CG3ZgT028604; Sun, 12 Mar 2017 16:03:35 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CG3YdU028591; Sun, 12 Mar 2017 16:03:34 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703121603.v2CG3YdU028591@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 16:03:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315162 - in head/lib/libc: gen iconv net regex rpc stdio stdlib X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 16:03:36 -0000 Author: pfg Date: Sun Mar 12 16:03:34 2017 New Revision: 315162 URL: https://svnweb.freebsd.org/changeset/base/315162 Log: libc: provide some bounds-checking through reallocarray(3). reallocarray(3) is a non portable extension that originated in OpenBSD. Given that it is already in FreeBSD's libc it is useful for the cases where reallocation involves a multiplication. MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D9955 Modified: head/lib/libc/gen/glob.c head/lib/libc/gen/scandir.c head/lib/libc/gen/setmode.c head/lib/libc/gen/wordexp.c head/lib/libc/iconv/citrus_esdb.c head/lib/libc/net/nsdispatch.c head/lib/libc/regex/regcomp.c head/lib/libc/rpc/getnetconfig.c head/lib/libc/stdio/open_wmemstream.c head/lib/libc/stdio/printf-pos.c head/lib/libc/stdio/ungetc.c head/lib/libc/stdlib/getenv.c Modified: head/lib/libc/gen/glob.c ============================================================================== --- head/lib/libc/gen/glob.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/gen/glob.c Sun Mar 12 16:03:34 2017 (r315162) @@ -850,7 +850,7 @@ globextend(const Char *path, glob_t *pgl const char *origpat) { char **pathv; - size_t i, newsize, len; + size_t i, newn, len; char *copy; const Char *p; @@ -860,9 +860,9 @@ globextend(const Char *path, glob_t *pgl return (GLOB_NOSPACE); } - newsize = sizeof(*pathv) * (2 + pglob->gl_pathc + pglob->gl_offs); - /* realloc(NULL, newsize) is equivalent to malloc(newsize). */ - pathv = realloc((void *)pglob->gl_pathv, newsize); + newn = 2 + pglob->gl_pathc + pglob->gl_offs; + /* reallocarray(NULL, newn, size) is equivalent to malloc(newn*size). */ + pathv = reallocarray(pglob->gl_pathv, newn, sizeof(*pathv)); if (pathv == NULL) return (GLOB_NOSPACE); Modified: head/lib/libc/gen/scandir.c ============================================================================== --- head/lib/libc/gen/scandir.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/gen/scandir.c Sun Mar 12 16:03:34 2017 (r315162) @@ -116,8 +116,8 @@ scandir(const char *dirname, struct dire if (numitems >= arraysz) { struct dirent **names2; - names2 = (struct dirent **)realloc((char *)names, - (arraysz * 2) * sizeof(struct dirent *)); + names2 = reallocarray(names, arraysz, + 2 * sizeof(struct dirent *)); if (names2 == NULL) { free(p); goto fail; Modified: head/lib/libc/gen/setmode.c ============================================================================== --- head/lib/libc/gen/setmode.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/gen/setmode.c Sun Mar 12 16:03:34 2017 (r315162) @@ -155,7 +155,7 @@ common: if (set->cmd2 & CMD2_CLR) { if (set >= endset) { \ BITCMD *newset; \ setlen += SET_LEN_INCR; \ - newset = realloc(saveset, sizeof(BITCMD) * setlen); \ + newset = reallocarray(saveset, setlen, sizeof(BITCMD)); \ if (newset == NULL) \ goto out; \ set = newset + (set - saveset); \ Modified: head/lib/libc/gen/wordexp.c ============================================================================== --- head/lib/libc/gen/wordexp.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/gen/wordexp.c Sun Mar 12 16:03:34 2017 (r315162) @@ -234,8 +234,8 @@ we_askshell(const char *words, wordexp_t vofs += we->we_offs; we->we_wordc += nwords; we->we_nbytes += nbytes; - if ((nwv = realloc(we->we_wordv, (we->we_wordc + 1 + - (flags & WRDE_DOOFFS ? we->we_offs : 0)) * + if ((nwv = reallocarray(we->we_wordv, (we->we_wordc + 1 + + (flags & WRDE_DOOFFS ? we->we_offs : 0)), sizeof(char *))) == NULL) { error = WRDE_NOSPACE; goto cleanup; Modified: head/lib/libc/iconv/citrus_esdb.c ============================================================================== --- head/lib/libc/iconv/citrus_esdb.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/iconv/citrus_esdb.c Sun Mar 12 16:03:34 2017 (r315162) @@ -347,7 +347,7 @@ _citrus_esdb_get_list(char ***rlist, siz ret = 0; /* XXX: why reallocing the list space posteriorly? shouldn't be done earlier? */ - q = realloc(list, num * sizeof(char *)); + q = reallocarray(list, num, sizeof(char *)); if (!q) { ret = ENOMEM; goto quit3; Modified: head/lib/libc/net/nsdispatch.c ============================================================================== --- head/lib/libc/net/nsdispatch.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/net/nsdispatch.c Sun Mar 12 16:03:34 2017 (r315162) @@ -213,7 +213,7 @@ vector_append(const void *elem, void *ve void *p; if ((*count % ELEMSPERCHUNK) == 0) { - p = realloc(vec, (*count + ELEMSPERCHUNK) * esize); + p = reallocarray(vec, *count + ELEMSPERCHUNK, esize); if (p == NULL) { nss_log_simple(LOG_ERR, "memory allocation failure"); return (vec); Modified: head/lib/libc/regex/regcomp.c ============================================================================== --- head/lib/libc/regex/regcomp.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/regex/regcomp.c Sun Mar 12 16:03:34 2017 (r315162) @@ -1143,7 +1143,7 @@ allocset(struct parse *p) { cset *cs, *ncs; - ncs = realloc(p->g->sets, (p->g->ncsets + 1) * sizeof(*ncs)); + ncs = reallocarray(p->g->sets, p->g->ncsets + 1, sizeof(*ncs)); if (ncs == NULL) { SETERROR(REG_ESPACE); return (NULL); @@ -1206,7 +1206,7 @@ CHadd(struct parse *p, cset *cs, wint_t if (ch < NC) cs->bmp[ch >> 3] |= 1 << (ch & 7); else { - newwides = realloc(cs->wides, (cs->nwides + 1) * + newwides = reallocarray(cs->wides, cs->nwides + 1, sizeof(*cs->wides)); if (newwides == NULL) { SETERROR(REG_ESPACE); @@ -1235,7 +1235,7 @@ CHaddrange(struct parse *p, cset *cs, wi CHadd(p, cs, min); if (min >= max) return; - newranges = realloc(cs->ranges, (cs->nranges + 1) * + newranges = reallocarray(cs->ranges, cs->nranges + 1, sizeof(*cs->ranges)); if (newranges == NULL) { SETERROR(REG_ESPACE); @@ -1259,7 +1259,7 @@ CHaddtype(struct parse *p, cset *cs, wct for (i = 0; i < NC; i++) if (iswctype(i, wct)) CHadd(p, cs, i); - newtypes = realloc(cs->types, (cs->ntypes + 1) * + newtypes = reallocarray(cs->types, cs->ntypes + 1, sizeof(*cs->types)); if (newtypes == NULL) { SETERROR(REG_ESPACE); @@ -1382,7 +1382,7 @@ enlarge(struct parse *p, sopno size) if (p->ssize >= size) return 1; - sp = (sop *)realloc(p->strip, size*sizeof(sop)); + sp = reallocarray(p->strip, size, sizeof(sop)); if (sp == NULL) { SETERROR(REG_ESPACE); return 0; @@ -1400,7 +1400,7 @@ static void stripsnug(struct parse *p, struct re_guts *g) { g->nstates = p->slen; - g->strip = (sop *)realloc((char *)p->strip, p->slen * sizeof(sop)); + g->strip = reallocarray((char *)p->strip, p->slen, sizeof(sop)); if (g->strip == NULL) { SETERROR(REG_ESPACE); g->strip = p->strip; Modified: head/lib/libc/rpc/getnetconfig.c ============================================================================== --- head/lib/libc/rpc/getnetconfig.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/rpc/getnetconfig.c Sun Mar 12 16:03:34 2017 (r315162) @@ -630,8 +630,8 @@ parse_ncp(char *stringp, struct netconfi ncp->nc_lookups = NULL; ncp->nc_nlookups = 0; while ((cp = tokenp) != NULL) { - if ((nc_lookups = realloc(ncp->nc_lookups, - (ncp->nc_nlookups + 1) * sizeof *ncp->nc_lookups)) == NULL) { + if ((nc_lookups = reallocarray(ncp->nc_lookups, + ncp->nc_nlookups + 1, sizeof(*ncp->nc_lookups))) == NULL) { free(ncp->nc_lookups); ncp->nc_lookups = NULL; return (-1); Modified: head/lib/libc/stdio/open_wmemstream.c ============================================================================== --- head/lib/libc/stdio/open_wmemstream.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/stdio/open_wmemstream.c Sun Mar 12 16:03:34 2017 (r315162) @@ -63,7 +63,7 @@ wmemstream_grow(struct wmemstream *ms, f else newsize = newoff; if (newsize > ms->len) { - buf = realloc(*ms->bufp, (newsize + 1) * sizeof(wchar_t)); + buf = reallocarray(*ms->bufp, newsize + 1, sizeof(wchar_t)); if (buf != NULL) { #ifdef DEBUG fprintf(stderr, "WMS: %p growing from %zd to %zd\n", Modified: head/lib/libc/stdio/printf-pos.c ============================================================================== --- head/lib/libc/stdio/printf-pos.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/stdio/printf-pos.c Sun Mar 12 16:03:34 2017 (r315162) @@ -655,7 +655,7 @@ __grow_type_table(struct typetable *type return (-1); bcopy(oldtable, newtable, oldsize * sizeof(enum typeid)); } else { - newtable = realloc(oldtable, newsize * sizeof(enum typeid)); + newtable = reallocarray(oldtable, newsize, sizeof(enum typeid)); if (newtable == NULL) return (-1); } Modified: head/lib/libc/stdio/ungetc.c ============================================================================== --- head/lib/libc/stdio/ungetc.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/stdio/ungetc.c Sun Mar 12 16:03:34 2017 (r315162) @@ -73,14 +73,14 @@ __submore(FILE *fp) return (0); } i = fp->_ub._size; - p = realloc(fp->_ub._base, (size_t)(i << 1)); + p = reallocarray(fp->_ub._base, i, 2); if (p == NULL) return (EOF); /* no overlap (hence can use memcpy) because we doubled the size */ (void)memcpy((void *)(p + i), (void *)p, (size_t)i); fp->_p = p + i; fp->_ub._base = p; - fp->_ub._size = i << 1; + fp->_ub._size = i * 2; return (0); } Modified: head/lib/libc/stdlib/getenv.c ============================================================================== --- head/lib/libc/stdlib/getenv.c Sun Mar 12 15:36:07 2017 (r315161) +++ head/lib/libc/stdlib/getenv.c Sun Mar 12 16:03:34 2017 (r315162) @@ -272,8 +272,8 @@ __rebuild_environ(int newEnvironSize) /* Resize environ. */ if (newEnvironSize > environSize) { tmpEnvironSize = newEnvironSize * 2; - tmpEnviron = realloc(intEnviron, sizeof (*intEnviron) * - (tmpEnvironSize + 1)); + tmpEnviron = reallocarray(intEnviron, tmpEnvironSize + 1, + sizeof(*intEnviron)); if (tmpEnviron == NULL) return (-1); environSize = tmpEnvironSize; @@ -306,8 +306,8 @@ __enlarge_env(void) envVarsTotal++; if (envVarsTotal > envVarsSize) { newEnvVarsSize = envVarsTotal * 2; - tmpEnvVars = realloc(envVars, sizeof (*envVars) * - newEnvVarsSize); + tmpEnvVars = reallocarray(envVars, newEnvVarsSize, + sizeof(*envVars)); if (tmpEnvVars == NULL) { envVarsTotal--; return (false); From owner-svn-src-all@freebsd.org Sun Mar 12 16:55:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2FD60D09940; Sun, 12 Mar 2017 16:55:20 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 07F6217F5; Sun, 12 Mar 2017 16:55:19 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CGtJBp049533; Sun, 12 Mar 2017 16:55:19 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CGtIjX049531; Sun, 12 Mar 2017 16:55:18 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703121655.v2CGtIjX049531@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Sun, 12 Mar 2017 16:55:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315163 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 16:55:20 -0000 Author: mav Date: Sun Mar 12 16:55:18 2017 New Revision: 315163 URL: https://svnweb.freebsd.org/changeset/base/315163 Log: Remove strange config_intrhook_establish() magic. Interrupts are enabled as part of chip reset just during driver attach. Later "enabling" of already enabled interrupts is useless. MFC after: 2 weeks Modified: head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Sun Mar 12 16:03:34 2017 (r315162) +++ head/sys/dev/isp/isp_freebsd.c Sun Mar 12 16:55:18 2017 (r315163) @@ -278,25 +278,11 @@ isp_attach(ispsoftc_t *isp) int du = device_get_unit(isp->isp_dev); int chan; - isp->isp_osinfo.ehook.ich_func = isp_intr_enable; - isp->isp_osinfo.ehook.ich_arg = isp; - /* - * Haha. Set this first, because if we're loaded as a module isp_intr_enable - * will be called right awawy, which will clear isp_osinfo.ehook_active, - * which would be unwise to then set again later. - */ - isp->isp_osinfo.ehook_active = 1; - if (config_intrhook_establish(&isp->isp_osinfo.ehook) != 0) { - isp_prt(isp, ISP_LOGERR, "could not establish interrupt enable hook"); - return (-EIO); - } - /* * Create the device queue for our SIM(s). */ isp->isp_osinfo.devq = cam_simq_alloc(isp->isp_maxcmds); if (isp->isp_osinfo.devq == NULL) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); return (EIO); } @@ -330,10 +316,6 @@ unwind: ISP_UNLOCK(isp); cam_sim_free(sim, FALSE); } - if (isp->isp_osinfo.ehook_active) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); - isp->isp_osinfo.ehook_active = 0; - } if (isp->isp_osinfo.cdev) { destroy_dev(isp->isp_osinfo.cdev); isp->isp_osinfo.cdev = NULL; @@ -371,10 +353,6 @@ isp_detach(ispsoftc_t *isp) destroy_dev(isp->isp_osinfo.cdev); isp->isp_osinfo.cdev = NULL; } - if (isp->isp_osinfo.ehook_active) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); - isp->isp_osinfo.ehook_active = 0; - } if (isp->isp_osinfo.devq != NULL) { cam_simq_free(isp->isp_osinfo.devq); isp->isp_osinfo.devq = NULL; @@ -786,28 +764,6 @@ ispioctl(struct cdev *dev, u_long c, cad return (retval); } -static void -isp_intr_enable(void *arg) -{ - int chan; - ispsoftc_t *isp = arg; - ISP_LOCK(isp); - if (IS_FC(isp)) { - for (chan = 0; chan < isp->isp_nchan; chan++) { - if (FCPARAM(isp, chan)->role != ISP_ROLE_NONE) { - ISP_ENABLE_INTS(isp); - break; - } - } - } else { - ISP_ENABLE_INTS(isp); - } - isp->isp_osinfo.ehook_active = 0; - ISP_UNLOCK(isp); - /* Release our hook so that the boot can continue. */ - config_intrhook_disestablish(&isp->isp_osinfo.ehook); -} - /* * Local Inlines */ Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Sun Mar 12 16:03:34 2017 (r315162) +++ head/sys/dev/isp/isp_freebsd.h Sun Mar 12 16:55:18 2017 (r315163) @@ -270,7 +270,6 @@ struct isposinfo { struct mtx lock; device_t dev; struct cdev * cdev; - struct intr_config_hook ehook; struct cam_devq * devq; /* @@ -310,7 +309,6 @@ struct isposinfo { sixtyfourbit : 1, /* sixtyfour bit platform */ timer_active : 1, autoconf : 1, - ehook_active : 1, mbox_sleeping : 1, mbox_sleep_ok : 1, mboxcmd_done : 1, From owner-svn-src-all@freebsd.org Sun Mar 12 17:15:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9098BD0915B; Sun, 12 Mar 2017 17:15:56 +0000 (UTC) (envelope-from lstewart@freebsd.org) Received: from lauren.room52.net (unknown [IPv6:2001:19f0:5801:2ba:5400:ff:fe59:15d6]) (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 511081305; Sun, 12 Mar 2017 17:15:56 +0000 (UTC) (envelope-from lstewart@freebsd.org) Received: from lgwl-lstewart2.corp.netflix.com (c110-22-60-167.eburwd6.vic.optusnet.com.au [110.22.60.167]) by lauren.room52.net (Postfix) with ESMTPSA id B375AC71; Mon, 13 Mar 2017 04:15:39 +1100 (AEDT) Subject: Re: svn commit: r314780 - head/lib/libpam/modules/pam_exec To: "Pedro F. Giffuni" , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201703061545.v26FjkNI027057@repo.freebsd.org> From: Lawrence Stewart Message-ID: <739617a4-3eed-28d1-73e4-86d25d6d5fed@freebsd.org> Date: Mon, 13 Mar 2017 04:14:14 +1100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <201703061545.v26FjkNI027057@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 17:15:56 -0000 Hi Pedro, On 07/03/2017 02:45, Pedro F. Giffuni wrote: > Author: pfg > Date: Mon Mar 6 15:45:46 2017 > New Revision: 314780 > URL: https://svnweb.freebsd.org/changeset/base/314780 > > Log: > libpam: extra bounds checking through reallocarray(3). > > Reviewed by: des > MFC after: 1 week > > Modified: > head/lib/libpam/modules/pam_exec/pam_exec.c > > Modified: head/lib/libpam/modules/pam_exec/pam_exec.c > ============================================================================== > --- head/lib/libpam/modules/pam_exec/pam_exec.c Mon Mar 6 15:42:03 2017 (r314779) > +++ head/lib/libpam/modules/pam_exec/pam_exec.c Mon Mar 6 15:45:46 2017 (r314780) > @@ -138,7 +138,7 @@ _pam_exec(pam_handle_t *pamh __unused, > nitems = sizeof(env_items) / sizeof(*env_items); > /* Count PAM return values put in the environment. */ > nitems_rv = options->return_prog_exit_status ? PAM_RV_COUNT : 0; > - tmp = realloc(envlist, (envlen + nitems + 1 + nitems_rv + 1) * > + tmp = reallocarray(envlist, envlen + nitems + 1 + nitems_rv + 1, > sizeof(*envlist)); > if (tmp == NULL) { > openpam_free_envlist(envlist); > This commit breaks pam_exec for me... without this change I see the expected PAM_* environment variables from my execed script, but with this change I no longer see any of them. Cheers, Lawrence From owner-svn-src-all@freebsd.org Sun Mar 12 17:41:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 232D6D09AA0; Sun, 12 Mar 2017 17:41:53 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E45CA1BCF; Sun, 12 Mar 2017 17:41:52 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CHfp8U070218; Sun, 12 Mar 2017 17:41:51 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CHfpSA070217; Sun, 12 Mar 2017 17:41:51 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703121741.v2CHfpSA070217@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Sun, 12 Mar 2017 17:41:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315164 - head/lib/libpam/modules/pam_exec X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 17:41:53 -0000 Author: pfg Date: Sun Mar 12 17:41:51 2017 New Revision: 315164 URL: https://svnweb.freebsd.org/changeset/base/315164 Log: Revert r314780 libpam: extra bounds checking through reallocarray(3). It appears to be causing brokenness when reporting PAM_* environment variables. This requires more investigation. Reported by: lstewart Modified: head/lib/libpam/modules/pam_exec/pam_exec.c Modified: head/lib/libpam/modules/pam_exec/pam_exec.c ============================================================================== --- head/lib/libpam/modules/pam_exec/pam_exec.c Sun Mar 12 16:55:18 2017 (r315163) +++ head/lib/libpam/modules/pam_exec/pam_exec.c Sun Mar 12 17:41:51 2017 (r315164) @@ -138,7 +138,7 @@ _pam_exec(pam_handle_t *pamh __unused, nitems = sizeof(env_items) / sizeof(*env_items); /* Count PAM return values put in the environment. */ nitems_rv = options->return_prog_exit_status ? PAM_RV_COUNT : 0; - tmp = reallocarray(envlist, envlen + nitems + 1 + nitems_rv + 1, + tmp = realloc(envlist, (envlen + nitems + 1 + nitems_rv + 1) * sizeof(*envlist)); if (tmp == NULL) { openpam_free_envlist(envlist); From owner-svn-src-all@freebsd.org Sun Mar 12 17:43:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1C1E0D09C62; Sun, 12 Mar 2017 17:43:47 +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 E01951EA9; Sun, 12 Mar 2017 17:43:46 +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 v2CHhkV6072604; Sun, 12 Mar 2017 17:43:46 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CHhk7c072603; Sun, 12 Mar 2017 17:43:46 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201703121743.v2CHhk7c072603@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Sun, 12 Mar 2017 17:43:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315165 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 17:43:47 -0000 Author: ian Date: Sun Mar 12 17:43:45 2017 New Revision: 315165 URL: https://svnweb.freebsd.org/changeset/base/315165 Log: Correct the abbreviations for microseconds (us, not ms), and for Hz (not HZ). Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Sun Mar 12 17:41:51 2017 (r315164) +++ head/sys/kern/vfs_subr.c Sun Mar 12 17:43:45 2017 (r315165) @@ -767,7 +767,7 @@ enum { TSP_SEC, TSP_HZ, TSP_USEC, TSP_NS static int timestamp_precision = TSP_USEC; SYSCTL_INT(_vfs, OID_AUTO, timestamp_precision, CTLFLAG_RW, ×tamp_precision, 0, "File timestamp precision (0: seconds, " - "1: sec + ns accurate to 1/HZ, 2: sec + ns truncated to ms, " + "1: sec + ns accurate to 1/Hz, 2: sec + ns truncated to us, " "3+: sec + ns (max. precision))"); /* From owner-svn-src-all@freebsd.org Sun Mar 12 17:45:22 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7F587D09CE9; Sun, 12 Mar 2017 17:45:22 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: from mail-ot0-x229.google.com (mail-ot0-x229.google.com [IPv6:2607:f8b0:4003:c0f::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 441371011; Sun, 12 Mar 2017 17:45:22 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: by mail-ot0-x229.google.com with SMTP id 19so101668734oti.0; Sun, 12 Mar 2017 10:45:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=NBBjiDuWRbPz6YrVAoCrEK9wB7pO5K1vScXrcev1ohw=; b=CZsknlM9HeOmYc1abEixGq43prkDuKtJeJjsSZ0J9mSJO006MaCPRQu5fnXneLsFBK MQTjrEBZJMQHjjOJHiMRap5taQi2gBkSYum1nklvs6DyvVjupO8dZnnNWlLdU90ooPlT U752pL2JZsJ9nVQDL5VE8UAXTdPFU2hzems2iM3/T5gcAMbxy4bzjZWzf73U0rXD1Gyz DI/wyzuPk3ddxM5KKfFa2AF7frQ9NR5tWuP1AwH2ll5JaVKKiDlFMspKRf/nW6u1iT+9 pPdx7q+8FsMPqUuAmP6bmm4yRg5+rnV2y1rG0VIqpwUQ47VMmAKx9aXddQel00GPf+Lh 6RvA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=NBBjiDuWRbPz6YrVAoCrEK9wB7pO5K1vScXrcev1ohw=; b=Cu9V/jUShc10QU4JJqmnJjjsb453xUrynSTtKkrcagNH2xuxMuyzGXEIzGmUwCiZId cQPyhkLGdU4OknU4U6RIt4xi6MrRCz9WDPj8uUyCqx4MLIVZbrDIfjEGFGY2g5Py8T5x ztay/oj0JerArp+Z4JPTvXxq6VWVhhYctyCWgohtJ0YLK/xrYWtv9qc1jQFJ4joEVko1 CGiy9XJi4rkRMUfwR3Fl64ol4lS3LBNpK2C8RxmiR/uLnduI4KGZvaCtSPcRK+GXRsaG yyNfeY2rscvDI0HP2X91DrF8q/KEdaVD61HeQrhmcRj16XoSbOaniKa/B1jqfFrUAkiW jv6A== X-Gm-Message-State: AFeK/H0KmAnCUHnke6BRDzbZFL+U6wkaJLh64Xv3XMYHNz3+/t6JWi2Ap47OABVXKiXFCr5OyQXmG+SwaB5LKA== X-Received: by 10.157.43.19 with SMTP id o19mr13985493otb.149.1489340721037; Sun, 12 Mar 2017 10:45:21 -0700 (PDT) MIME-Version: 1.0 Received: by 10.182.88.138 with HTTP; Sun, 12 Mar 2017 10:45:20 -0700 (PDT) In-Reply-To: <201703121743.v2CHhk7c072603@repo.freebsd.org> References: <201703121743.v2CHhk7c072603@repo.freebsd.org> From: Benjamin Kaduk Date: Sun, 12 Mar 2017 12:45:20 -0500 Message-ID: Subject: Re: svn commit: r315165 - head/sys/kern To: Ian Lepore Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 17:45:22 -0000 On Sun, Mar 12, 2017 at 12:43 PM, Ian Lepore wrote: > Author: ian > Date: Sun Mar 12 17:43:45 2017 > New Revision: 315165 > URL: https://svnweb.freebsd.org/changeset/base/315165 > > Log: > Correct the abbreviations for microseconds (us, not ms), and for Hz (not > HZ). > > Modified: > head/sys/kern/vfs_subr.c > > Modified: head/sys/kern/vfs_subr.c > ============================================================ > ================== > --- head/sys/kern/vfs_subr.c Sun Mar 12 17:41:51 2017 (r315164) > +++ head/sys/kern/vfs_subr.c Sun Mar 12 17:43:45 2017 (r315165) > @@ -767,7 +767,7 @@ enum { TSP_SEC, TSP_HZ, TSP_USEC, TSP_NS > static int timestamp_precision = TSP_USEC; > SYSCTL_INT(_vfs, OID_AUTO, timestamp_precision, CTLFLAG_RW, > ×tamp_precision, 0, "File timestamp precision (0: seconds, " > - "1: sec + ns accurate to 1/HZ, 2: sec + ns truncated to ms, " > + "1: sec + ns accurate to 1/Hz, 2: sec + ns truncated to us, " > HZ looks like the kernel configuration parameter here, not the unit. -Ben > "3+: sec + ns (max. precision))"); > > /* > _______________________________________________ > svn-src-all@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" > From owner-svn-src-all@freebsd.org Sun Mar 12 18:00:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DDC1BD092A5; Sun, 12 Mar 2017 18:00:03 +0000 (UTC) (envelope-from imp@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 AAFEB1AE6; Sun, 12 Mar 2017 18:00:03 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CI02jN077072; Sun, 12 Mar 2017 18:00:02 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CI02gr077071; Sun, 12 Mar 2017 18:00:02 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121800.v2CI02gr077071@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:00:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315166 - head/sys/dev/acpica X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:00:04 -0000 Author: imp Date: Sun Mar 12 18:00:02 2017 New Revision: 315166 URL: https://svnweb.freebsd.org/changeset/base/315166 Log: Export the actual LID state via sysctl. This allows more complex policies about when to suspend based on other events happening AND the lid being closed through the use of clever devd or other scripts. Modified: head/sys/dev/acpica/acpi_lid.c Modified: head/sys/dev/acpica/acpi_lid.c ============================================================================== --- head/sys/dev/acpica/acpi_lid.c Sun Mar 12 17:43:45 2017 (r315165) +++ head/sys/dev/acpica/acpi_lid.c Sun Mar 12 18:00:02 2017 (r315166) @@ -122,6 +122,14 @@ acpi_lid_attach(device_t dev) if (acpi_parse_prw(sc->lid_handle, &prw) == 0) AcpiEnableGpe(prw.gpe_handle, prw.gpe_bit); + /* + * Export the lid status + */ + SYSCTL_ADD_INT(device_get_sysctl_ctx(dev), + SYSCTL_CHILDREN(device_get_sysctl_tree(dev)), OID_AUTO, + "state", CTLFLAG_RD, &sc->lid_status, 0, + "Device set to wake the system"); + return (0); } From owner-svn-src-all@freebsd.org Sun Mar 12 18:05:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 27F75D09550 for ; Sun, 12 Mar 2017 18:05:31 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from pmta2.delivery6.ore.mailhop.org (pmta2.delivery6.ore.mailhop.org [54.200.129.228]) (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 0BCB611F0 for ; Sun, 12 Mar 2017 18:05:30 +0000 (UTC) (envelope-from ian@freebsd.org) X-MHO-User: 613e88e4-074e-11e7-b3c2-c9f38144898e X-Report-Abuse-To: https://support.duocircle.com/support/solutions/articles/5000540958-duocircle-standard-smtp-abuse-information X-Originating-IP: 73.78.92.27 X-Mail-Handler: DuoCircle Outbound SMTP Received: from ilsoft.org (unknown [73.78.92.27]) by outbound2.ore.mailhop.org (Halon) with ESMTPSA id 613e88e4-074e-11e7-b3c2-c9f38144898e; Sun, 12 Mar 2017 18:04:48 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.15.2) with ESMTP id v2CI5SPX001638; Sun, 12 Mar 2017 12:05:28 -0600 (MDT) (envelope-from ian@freebsd.org) Message-ID: <1489341928.40576.89.camel@freebsd.org> Subject: Re: svn commit: r315165 - head/sys/kern From: Ian Lepore To: Benjamin Kaduk Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Date: Sun, 12 Mar 2017 12:05:28 -0600 In-Reply-To: References: <201703121743.v2CHhk7c072603@repo.freebsd.org> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.1 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:05:31 -0000 On Sun, 2017-03-12 at 12:45 -0500, Benjamin Kaduk wrote: > On Sun, Mar 12, 2017 at 12:43 PM, Ian Lepore wrote: > > > > > Author: ian > > Date: Sun Mar 12 17:43:45 2017 > > New Revision: 315165 > > URL: https://svnweb.freebsd.org/changeset/base/315165 > > > > Log: > >   Correct the abbreviations for microseconds (us, not ms), and for > > Hz (not > > HZ). > > > > Modified: > >   head/sys/kern/vfs_subr.c > > > > Modified: head/sys/kern/vfs_subr.c > > ============================================================ > > ================== > > --- head/sys/kern/vfs_subr.c    Sun Mar 12 17:41:51 > > 2017        (r315164) > > +++ head/sys/kern/vfs_subr.c    Sun Mar 12 17:43:45 > > 2017        (r315165) > > @@ -767,7 +767,7 @@ enum { TSP_SEC, TSP_HZ, TSP_USEC, TSP_NS > >  static int timestamp_precision = TSP_USEC; > >  SYSCTL_INT(_vfs, OID_AUTO, timestamp_precision, CTLFLAG_RW, > >      ×tamp_precision, 0, "File timestamp precision (0: > > seconds, " > > -    "1: sec + ns accurate to 1/HZ, 2: sec + ns truncated to ms, " > > +    "1: sec + ns accurate to 1/Hz, 2: sec + ns truncated to us, " > > > HZ looks like the kernel configuration parameter here, not the unit. > > -Ben > > > > > >      "3+: sec + ns (max. precision))"); > > > >  /* > > _______________________________________________ Doh!  Now that you mention it, I'm sure you're right. -- Ian From owner-svn-src-all@freebsd.org Sun Mar 12 18:07:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9C067D095D7; Sun, 12 Mar 2017 18:07:04 +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 66A9B1354; Sun, 12 Mar 2017 18:07:04 +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 v2CI73Wi080843; Sun, 12 Mar 2017 18:07:03 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CI73gK080842; Sun, 12 Mar 2017 18:07:03 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201703121807.v2CI73gK080842@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Sun, 12 Mar 2017 18:07:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315167 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:07:04 -0000 Author: ian Date: Sun Mar 12 18:07:03 2017 New Revision: 315167 URL: https://svnweb.freebsd.org/changeset/base/315167 Log: Change 'Hz' back to 'HZ'... it's referring to the kernel config option named HZ, not being used as an abbreviation of the unit of measure. Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c ============================================================================== --- head/sys/kern/vfs_subr.c Sun Mar 12 18:00:02 2017 (r315166) +++ head/sys/kern/vfs_subr.c Sun Mar 12 18:07:03 2017 (r315167) @@ -767,7 +767,7 @@ enum { TSP_SEC, TSP_HZ, TSP_USEC, TSP_NS static int timestamp_precision = TSP_USEC; SYSCTL_INT(_vfs, OID_AUTO, timestamp_precision, CTLFLAG_RW, ×tamp_precision, 0, "File timestamp precision (0: seconds, " - "1: sec + ns accurate to 1/Hz, 2: sec + ns truncated to us, " + "1: sec + ns accurate to 1/HZ, 2: sec + ns truncated to us, " "3+: sec + ns (max. precision))"); /* From owner-svn-src-all@freebsd.org Sun Mar 12 18:24:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A1C8BD09FA7; Sun, 12 Mar 2017 18:24:47 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 609441FA2; Sun, 12 Mar 2017 18:24:47 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIOknc089207; Sun, 12 Mar 2017 18:24:46 GMT (envelope-from jilles@FreeBSD.org) Received: (from jilles@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIOkix089203; Sun, 12 Mar 2017 18:24:46 GMT (envelope-from jilles@FreeBSD.org) Message-Id: <201703121824.v2CIOkix089203@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jilles set sender to jilles@FreeBSD.org using -f From: Jilles Tjoelker Date: Sun, 12 Mar 2017 18:24:46 +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: r315168 - stable/11/bin/sh/tests/expansion X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:24:47 -0000 Author: jilles Date: Sun Mar 12 18:24:45 2017 New Revision: 315168 URL: https://svnweb.freebsd.org/changeset/base/315168 Log: MFC r314637: sh: Add some already working tests that exercise new code paths Added: stable/11/bin/sh/tests/expansion/cmdsubst18.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst18.0 stable/11/bin/sh/tests/expansion/cmdsubst19.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst19.0 stable/11/bin/sh/tests/expansion/cmdsubst20.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst20.0 Modified: stable/11/bin/sh/tests/expansion/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/bin/sh/tests/expansion/Makefile ============================================================================== --- stable/11/bin/sh/tests/expansion/Makefile Sun Mar 12 18:07:03 2017 (r315167) +++ stable/11/bin/sh/tests/expansion/Makefile Sun Mar 12 18:24:45 2017 (r315168) @@ -39,6 +39,9 @@ ${PACKAGE}FILES+= cmdsubst14.0 ${PACKAGE}FILES+= cmdsubst15.0 ${PACKAGE}FILES+= cmdsubst16.0 ${PACKAGE}FILES+= cmdsubst17.0 +${PACKAGE}FILES+= cmdsubst18.0 +${PACKAGE}FILES+= cmdsubst19.0 +${PACKAGE}FILES+= cmdsubst20.0 ${PACKAGE}FILES+= export1.0 ${PACKAGE}FILES+= export2.0 ${PACKAGE}FILES+= export3.0 Copied: stable/11/bin/sh/tests/expansion/cmdsubst18.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst18.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/bin/sh/tests/expansion/cmdsubst18.0 Sun Mar 12 18:24:45 2017 (r315168, copy of r314637, head/bin/sh/tests/expansion/cmdsubst18.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +x=X +unset n +r=${x+$(echo a)}${x-$(echo b)}${n+$(echo c)}${n-$(echo d)}$(echo e) +[ "$r" = aXde ] Copied: stable/11/bin/sh/tests/expansion/cmdsubst19.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst19.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/bin/sh/tests/expansion/cmdsubst19.0 Sun Mar 12 18:24:45 2017 (r315168, copy of r314637, head/bin/sh/tests/expansion/cmdsubst19.0) @@ -0,0 +1,5 @@ +# $FreeBSD$ + +b=200 c=30 d=5 x=4 +r=$(echo a)$(($(echo b) + ${x+$(echo c)} + ${x-$(echo d)}))$(echo e) +[ "$r" = a234e ] Copied: stable/11/bin/sh/tests/expansion/cmdsubst20.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst20.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/bin/sh/tests/expansion/cmdsubst20.0 Sun Mar 12 18:24:45 2017 (r315168, copy of r314637, head/bin/sh/tests/expansion/cmdsubst20.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +set -T +trapped='' +trap "trapped=x$trapped" USR1 +[ "x$(kill -USR1 $$)y" = xy ] && [ "$trapped" = x ] From owner-svn-src-all@freebsd.org Sun Mar 12 18:38:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C619CD083A8; Sun, 12 Mar 2017 18:38:04 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A0A4F15E7; Sun, 12 Mar 2017 18:38:04 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIc3kj093374; Sun, 12 Mar 2017 18:38:03 GMT (envelope-from jilles@FreeBSD.org) Received: (from jilles@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIc3di093370; Sun, 12 Mar 2017 18:38:03 GMT (envelope-from jilles@FreeBSD.org) Message-Id: <201703121838.v2CIc3di093370@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jilles set sender to jilles@FreeBSD.org using -f From: Jilles Tjoelker Date: Sun, 12 Mar 2017 18:38:03 +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: r315169 - in stable/11/bin/sh: . tests/expansion X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:38:04 -0000 Author: jilles Date: Sun Mar 12 18:38:03 2017 New Revision: 315169 URL: https://svnweb.freebsd.org/changeset/base/315169 Log: MFC r314686: sh: Fix crash if a -T trap is taken during command substitution Code like t=$(stat -f %m "$file") segfaulted if -T was active and a trap was taken while the shell was waiting for the child process to finish. What happened was that the dotrap() call in waitforjob() was hit. This re-entered command execution (including expand.c) at a point not expected by expbackq(), and global state (unallocated stack string and argbackq) was corrupted. To fix this, change expbackq() to prepare for command execution to be re-entered. Reported by: bdrewery Added: stable/11/bin/sh/tests/expansion/cmdsubst21.0 - copied unchanged from r314686, head/bin/sh/tests/expansion/cmdsubst21.0 stable/11/bin/sh/tests/expansion/cmdsubst22.0 - copied unchanged from r314686, head/bin/sh/tests/expansion/cmdsubst22.0 Modified: stable/11/bin/sh/expand.c stable/11/bin/sh/tests/expansion/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/bin/sh/expand.c ============================================================================== --- stable/11/bin/sh/expand.c Sun Mar 12 18:24:45 2017 (r315168) +++ stable/11/bin/sh/expand.c Sun Mar 12 18:38:03 2017 (r315169) @@ -460,7 +460,6 @@ expbackq(union node *cmd, int quoted, in p = grabstackstr(dest); evalbackcmd(cmd, &in); ungrabstackstr(p, dest); - argbackq = saveargbackq; p = in.buf; nnl = 0; @@ -513,12 +512,16 @@ expbackq(union node *cmd, int quoted, in close(in.fd); if (in.buf) ckfree(in.buf); - if (in.jp) + if (in.jp) { + p = grabstackstr(dest); exitstatus = waitforjob(in.jp, (int *)NULL); + ungrabstackstr(p, dest); + } TRACE(("expbackq: size=%td: \"%.*s\"\n", ((dest - stackblock()) - startloc), (int)((dest - stackblock()) - startloc), stackblock() + startloc)); + argbackq = saveargbackq; expdest = dest; INTON; } Modified: stable/11/bin/sh/tests/expansion/Makefile ============================================================================== --- stable/11/bin/sh/tests/expansion/Makefile Sun Mar 12 18:24:45 2017 (r315168) +++ stable/11/bin/sh/tests/expansion/Makefile Sun Mar 12 18:38:03 2017 (r315169) @@ -42,6 +42,8 @@ ${PACKAGE}FILES+= cmdsubst17.0 ${PACKAGE}FILES+= cmdsubst18.0 ${PACKAGE}FILES+= cmdsubst19.0 ${PACKAGE}FILES+= cmdsubst20.0 +${PACKAGE}FILES+= cmdsubst21.0 +${PACKAGE}FILES+= cmdsubst22.0 ${PACKAGE}FILES+= export1.0 ${PACKAGE}FILES+= export2.0 ${PACKAGE}FILES+= export3.0 Copied: stable/11/bin/sh/tests/expansion/cmdsubst21.0 (from r314686, head/bin/sh/tests/expansion/cmdsubst21.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/bin/sh/tests/expansion/cmdsubst21.0 Sun Mar 12 18:38:03 2017 (r315169, copy of r314686, head/bin/sh/tests/expansion/cmdsubst21.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +set -T +trapped='' +trap "trapped=x$trapped" TERM +[ "x$($SH -c "kill $$")y" = xy ] && [ "$trapped" = x ] Copied: stable/11/bin/sh/tests/expansion/cmdsubst22.0 (from r314686, head/bin/sh/tests/expansion/cmdsubst22.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/11/bin/sh/tests/expansion/cmdsubst22.0 Sun Mar 12 18:38:03 2017 (r315169, copy of r314686, head/bin/sh/tests/expansion/cmdsubst22.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +set -T +trapped='' +trap "trapped=x$trapped" TERM +[ "x$(:; kill $$)y" = xy ] && [ "$trapped" = x ] From owner-svn-src-all@freebsd.org Sun Mar 12 18:41:50 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CB7EDD085CE; Sun, 12 Mar 2017 18:41:50 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x243.google.com (mail-pg0-x243.google.com [IPv6:2607:f8b0:400e:c05::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 9C3DF183E; Sun, 12 Mar 2017 18:41:50 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x243.google.com with SMTP id g2so11391230pge.2; Sun, 12 Mar 2017 11:41:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=10TIkoQsjViCO44T0saWVbB6TKSnl0AhlPe4nBv7dto=; b=ZUAm6mKTEuxr3ckzvDI3A3a6eY2CwZAki4RppLYW2BRLCpA/Kk8r5TuOotkIw9R9dZ 7A0i2c6eXsVaQMOrEWpu6gJfBsIkgjTXkHzqqf5fJk8xNoxqIWnY8CKn+rHXQr53DE2p pLuNVdhCaMnGv8SdhyQwtSTORkF/B+4ecQJlkf0HbhZ9QBZt5qrTmTH0pfhrccE93i9p ALqa8ebVUI/9SLp7DGkcdIBmor7nzs37Iz/4k0Y+yU1aeO9utm1kI0aLe6ZQbKBjiMkq hn0OD2ly4/H/1g0hzB5zmlqmSewwjkOpTrSh8fdsx/fAFsonAom8B3RgsqI3Ob4f2+Pn 1Kdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=10TIkoQsjViCO44T0saWVbB6TKSnl0AhlPe4nBv7dto=; b=MjxQLKAYIsO3jqp9eUXDqwde3/Ac3fzv/ZTeseFeT+KClcJGiP9xE3VBqKNjz8AVZh aE1HRRF8RKpcnH8+xzw54XM699X8zrNEIS9ohnwqCLN1gb4aqvGZBMDwG1e3wO17P5CH S+USzG0fQgCE5g3QtnxiPUpN4QRTURzR0q+ggDyJTujtF7JY1FsX8GpPPi5bH9w0F98k cwQJObHVkDgDU8OYh6aYeYIZ8UTdoKH192uIQW4fpwZDh5JGswqLLtWU/ZgNIQ6fEhQK LStwo006VePfA41J7C1zeYtYQgbLaRwgqoFI/EuEAmhfhTPMJFlobaGkylefCrdYdjOp 2wKQ== X-Gm-Message-State: AMke39lOtzddKJxZBdagdzBkY+I6PQb0ufWf6IiacSBp55HQphVSDuP51hdlyLCeeaqa7w== X-Received: by 10.99.54.7 with SMTP id d7mr23163656pga.186.1489344110043; Sun, 12 Mar 2017 11:41:50 -0700 (PDT) Received: from ?IPv6:2607:fb90:8117:a021:701c:cd2:10ac:ee5f? ([2607:fb90:8117:a021:701c:cd2:10ac:ee5f]) by smtp.gmail.com with ESMTPSA id n185sm29564569pga.9.2017.03.12.11.41.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 12 Mar 2017 11:41:49 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (1.0) Subject: Re: svn commit: r315164 - head/lib/libpam/modules/pam_exec From: Ngie Cooper X-Mailer: iPhone Mail (14D27) In-Reply-To: <201703121741.v2CHfpSA070217@repo.freebsd.org> Date: Sun, 12 Mar 2017 11:41:48 -0700 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <201703121741.v2CHfpSA070217@repo.freebsd.org> To: "Pedro F. Giffuni" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:41:50 -0000 > On Mar 12, 2017, at 10:41, Pedro F. Giffuni wrote: >=20 > Author: pfg > Date: Sun Mar 12 17:41:51 2017 > New Revision: 315164 > URL: https://svnweb.freebsd.org/changeset/base/315164 >=20 > Log: > Revert r314780 > libpam: extra bounds checking through reallocarray(3). >=20 > It appears to be causing brokenness when reporting PAM_* environment > variables. This requires more investigation. >=20 > Reported by: lstewart >=20 > Modified: > head/lib/libpam/modules/pam_exec/pam_exec.c >=20 > Modified: head/lib/libpam/modules/pam_exec/pam_exec.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D > --- head/lib/libpam/modules/pam_exec/pam_exec.c Sun Mar 12 16:55:18 201= 7 (r315163) > +++ head/lib/libpam/modules/pam_exec/pam_exec.c Sun Mar 12 17:41:51 201= 7 (r315164) > @@ -138,7 +138,7 @@ _pam_exec(pam_handle_t *pamh __unused, > nitems =3D sizeof(env_items) / sizeof(*env_items); > /* Count PAM return values put in the environment. */ > nitems_rv =3D options->return_prog_exit_status ? PAM_RV_COUNT : 0; > - tmp =3D reallocarray(envlist, envlen + nitems + 1 + nitems_rv + 1, > + tmp =3D realloc(envlist, (envlen + nitems + 1 + nitems_rv + 1) * Eep. nitems variable use here too (masking nitems macro). -Ngie= From owner-svn-src-all@freebsd.org Sun Mar 12 18:58:51 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E301CD08ADD; Sun, 12 Mar 2017 18:58:51 +0000 (UTC) (envelope-from imp@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 726AC1039; Sun, 12 Mar 2017 18:58:51 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIwokY001658; Sun, 12 Mar 2017 18:58:50 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIwi2a001598; Sun, 12 Mar 2017 18:58:44 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121858.v2CIwi2a001598@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:58:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315170 - in head/usr.bin: bsdiff/bsdiff bzip2 bzip2recover chkey chpass compile_et cpio ctlstat drill ee elfcopy factor file ftp host ipcrm iscsictl kdump less lessecho lesskey lex lex... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:58:52 -0000 Author: imp Date: Sun Mar 12 18:58:44 2017 New Revision: 315170 URL: https://svnweb.freebsd.org/changeset/base/315170 Log: Adopt SRCTOP in usr.bin Prefer ${SRCTOP}/foo over ${.CURDIR}/../../foo and ${SRCTOP}/usr.bin/foo over ${.CURDIR}/../foo for paths in Makefiles. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence on: arch@ (twice) Modified: head/usr.bin/bsdiff/bsdiff/Makefile head/usr.bin/bzip2/Makefile head/usr.bin/bzip2recover/Makefile head/usr.bin/chkey/Makefile head/usr.bin/chpass/Makefile head/usr.bin/compile_et/Makefile head/usr.bin/cpio/Makefile head/usr.bin/ctlstat/Makefile head/usr.bin/drill/Makefile head/usr.bin/ee/Makefile head/usr.bin/elfcopy/Makefile head/usr.bin/factor/Makefile head/usr.bin/file/Makefile head/usr.bin/ftp/Makefile head/usr.bin/host/Makefile head/usr.bin/ipcrm/Makefile head/usr.bin/iscsictl/Makefile head/usr.bin/kdump/Makefile head/usr.bin/less/Makefile.common head/usr.bin/lessecho/Makefile head/usr.bin/lesskey/Makefile head/usr.bin/lex/Makefile head/usr.bin/lex/lib/Makefile head/usr.bin/locale/Makefile head/usr.bin/localedef/Makefile head/usr.bin/lzmainfo/Makefile head/usr.bin/m4/Makefile head/usr.bin/mandoc/Makefile head/usr.bin/minigzip/Makefile head/usr.bin/mkcsmapper/Makefile head/usr.bin/mkcsmapper/Makefile.inc head/usr.bin/mkcsmapper_static/Makefile head/usr.bin/mkesdb/Makefile head/usr.bin/mkesdb_static/Makefile head/usr.bin/mklocale/Makefile head/usr.bin/nc/Makefile head/usr.bin/opieinfo/Makefile head/usr.bin/opiekey/Makefile head/usr.bin/opiepasswd/Makefile head/usr.bin/pamtest/Makefile head/usr.bin/readelf/Makefile head/usr.bin/rsh/Makefile head/usr.bin/smbutil/Makefile head/usr.bin/svn/lib/Makefile.inc head/usr.bin/tar/Makefile head/usr.bin/telnet/Makefile head/usr.bin/tftp/Makefile head/usr.bin/top/Makefile head/usr.bin/truss/Makefile head/usr.bin/unvis/Makefile head/usr.bin/vacation/Makefile head/usr.bin/vi/Makefile head/usr.bin/vis/Makefile head/usr.bin/w/Makefile head/usr.bin/xinstall/Makefile head/usr.bin/xz/Makefile head/usr.bin/xzdec/Makefile head/usr.bin/yacc/Makefile head/usr.bin/ypwhich/Makefile Modified: head/usr.bin/bsdiff/bsdiff/Makefile ============================================================================== --- head/usr.bin/bsdiff/bsdiff/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/bsdiff/bsdiff/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -4,11 +4,11 @@ PROG= bsdiff # libdivsufsort configured with: # cmake -DCMAKE_BUILD_TYPE="Release" -DBUILD_DIVSUFSORT64=ON -.PATH: ${.CURDIR}/../../../contrib/libdivsufsort/lib +.PATH: ${SRCTOP}/contrib/libdivsufsort/lib CFLAGS+= -DHAVE_CONFIG_H=1 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE CFLAGS+= -D_LARGE_FILES -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS CFLAGS+= -D__STDC_LIMIT_MACROS -DBUILD_DIVSUFSORT64 -CFLAGS+= -I${.CURDIR}/../../../contrib/libdivsufsort/include -I${.CURDIR} +CFLAGS+= -I${SRCTOP}/contrib/libdivsufsort/include -I${.CURDIR} SRCS= divsufsort.c sssort.c trsort.c utils.c SRCS+= bsdiff.c Modified: head/usr.bin/bzip2/Makefile ============================================================================== --- head/usr.bin/bzip2/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/bzip2/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -BZ2DIR= ${.CURDIR}/../../contrib/bzip2 +BZ2DIR= ${SRCTOP}/contrib/bzip2 .PATH: ${BZ2DIR} PROG= bzip2 Modified: head/usr.bin/bzip2recover/Makefile ============================================================================== --- head/usr.bin/bzip2recover/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/bzip2recover/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -BZ2DIR= ${.CURDIR}/../../contrib/bzip2 +BZ2DIR= ${SRCTOP}/contrib/bzip2 .PATH: ${BZ2DIR} PROG= bzip2recover Modified: head/usr.bin/chkey/Makefile ============================================================================== --- head/usr.bin/chkey/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/chkey/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,11 +2,11 @@ .include -.PATH: ${.CURDIR}/../newkey +.PATH: ${SRCTOP}/usr.bin/newkey PROG= chkey SRCS= chkey.c generic.c update.c -CFLAGS+= -I${.CURDIR}/../newkey +CFLAGS+= -I${SRCTOP}/usr.bin/newkey .if ${MK_NIS} != "no" CFLAGS+= -DYP .endif Modified: head/usr.bin/chpass/Makefile ============================================================================== --- head/usr.bin/chpass/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/chpass/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,7 +3,7 @@ .include -.PATH: ${.CURDIR}/../../usr.sbin/pwd_mkdb ${.CURDIR}/../../lib/libc/gen +.PATH: ${SRCTOP}/usr.sbin/pwd_mkdb ${SRCTOP}/lib/libc/gen PROG= chpass SRCS= chpass.c edit.c field.c pw_scan.c table.c util.c @@ -15,7 +15,7 @@ CFLAGS+= -DYP .endif #Some people need this, uncomment to activate #CFLAGS+=-DRESTRICT_FULLNAME_CHANGE -CFLAGS+=-I${.CURDIR}/../../usr.sbin/pwd_mkdb -I${.CURDIR}/../../lib/libc/gen -I. +CFLAGS+=-I${SRCTOP}/usr.sbin/pwd_mkdb -I${SRCTOP}/lib/libc/gen -I. LIBADD= crypt util .if ${MK_NIS} != "no" Modified: head/usr.bin/compile_et/Makefile ============================================================================== --- head/usr.bin/compile_et/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/compile_et/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,11 +1,11 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../contrib/com_err +.PATH: ${SRCTOP}/contrib/com_err PROG= compile_et SRCS= compile_et.c parse.y lex.l LIBADD= roken vers -CFLAGS+=-I. -I${.CURDIR}/../../contrib/com_err +CFLAGS+=-I. -I${SRCTOP}/contrib/com_err WARNS?= 0 Modified: head/usr.bin/cpio/Makefile ============================================================================== --- head/usr.bin/cpio/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/cpio/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,8 +2,8 @@ .include -_LIBARCHIVEDIR= ${.CURDIR}/../../contrib/libarchive -_LIBARCHIVECONFDIR= ${.CURDIR}/../../lib/libarchive +_LIBARCHIVEDIR= ${SRCTOP}/contrib/libarchive +_LIBARCHIVECONFDIR= ${SRCTOP}/lib/libarchive PROG= bsdcpio BSDCPIO_VERSION_STRING= 3.3.1 Modified: head/usr.bin/ctlstat/Makefile ============================================================================== --- head/usr.bin/ctlstat/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/ctlstat/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,7 +2,7 @@ PROG= ctlstat MAN= ctlstat.8 -SDIR= ${.CURDIR}/../../sys +SDIR= ${SRCTOP}/sys CFLAGS+= -I${SDIR} .include Modified: head/usr.bin/drill/Makefile ============================================================================== --- head/usr.bin/drill/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/drill/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,7 +1,7 @@ # $FreeBSD$ # Vendor sources and generated files -LDNSDIR= ${.CURDIR}/../../contrib/ldns +LDNSDIR= ${SRCTOP}/contrib/ldns .PATH: ${LDNSDIR}/drill Modified: head/usr.bin/ee/Makefile ============================================================================== --- head/usr.bin/ee/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/ee/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../contrib/ee +.PATH: ${SRCTOP}/contrib/ee CFLAGS+= -DHAS_NCURSES -DHAS_UNISTD -DHAS_STDARG -DHAS_STDLIB \ -DHAS_SYS_WAIT @@ -29,7 +29,7 @@ NLSSRCFILES=ee.msg . if exists(${.CURDIR}/nls/${lang}/ee.msg) NLSSRCDIR_${lang}= ${.CURDIR}/nls/${lang} . else -NLSSRCDIR_${lang}= ${.CURDIR}/../../contrib/ee +NLSSRCDIR_${lang}= ${SRCTOP}/contrib/ee . endif .endfor Modified: head/usr.bin/elfcopy/Makefile ============================================================================== --- head/usr.bin/elfcopy/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/elfcopy/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -28,7 +28,7 @@ LINKS= ${BINDIR}/${PROG} ${BINDIR}/strip # This same hack is in lib/libelf/Makefile and usr.bin/readelf/Makefile # We need to link against the correct version of these files. One -# solution is to include ../../sys in the include path. This causes +# solution is to include SRCTOP/sys in the include path. This causes # problems when a header file in sys depends on a file in another # part of the tree, e.g. a machine dependent header. # Modified: head/usr.bin/factor/Makefile ============================================================================== --- head/usr.bin/factor/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/factor/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -5,7 +5,7 @@ PROG= factor SRCS= factor.c pr_tbl.c -CFLAGS+=-I${.CURDIR}/../primes +CFLAGS+=-I${SRCTOP}/usr.bin/primes .if ${MK_OPENSSL} != "no" CFLAGS+=-DHAVE_OPENSSL @@ -14,6 +14,6 @@ LIBADD+=crypto MAN= factor.6 MLINKS+=factor.6 primes.6 -.PATH: ${.CURDIR}/../primes +.PATH: ${SRCTOP}/usr.bin/primes .include Modified: head/usr.bin/file/Makefile ============================================================================== --- head/usr.bin/file/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/file/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -20,7 +20,7 @@ # ever read sources, credits must appear in the documentation. # 4. This notice may not be removed or altered. -SRCDIR= ${.CURDIR}/../../contrib/file +SRCDIR= ${SRCTOP}/contrib/file .PATH: ${SRCDIR}/src .PATH: ${SRCDIR}/doc @@ -29,12 +29,12 @@ PROG= file MAGICPATH?= /usr/share/misc CFLAGS+= -DMAGIC='"${MAGICPATH}/magic"' -DHAVE_CONFIG_H -CFLAGS+= -I${.CURDIR}/../../lib/libmagic +CFLAGS+= -I${SRCTOP}/lib/libmagic LIBADD= magic FILEVER!= awk '$$1 == "\#define" && $$2 == "VERSION" { print $$3; exit }' \ - ${.CURDIR}/../../lib/libmagic/config.h + ${SRCTOP}/lib/libmagic/config.h CLEANFILES+= ${MAN} Modified: head/usr.bin/ftp/Makefile ============================================================================== --- head/usr.bin/ftp/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/ftp/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -8,7 +8,7 @@ # #CFLAGS+=-DGATE_SERVER=\"ftp-gw.host\" # -DGATE_PORT=21 -TNFTP= ${.CURDIR}/../../contrib/tnftp +TNFTP= ${SRCTOP}/contrib/tnftp .PATH: ${TNFTP}/src PROG= ftp Modified: head/usr.bin/host/Makefile ============================================================================== --- head/usr.bin/host/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/host/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,7 +1,7 @@ # $FreeBSD$ -LDNSDIR= ${.CURDIR}/../../contrib/ldns -LDNSHOSTDIR= ${.CURDIR}/../../contrib/ldns-host +LDNSDIR= ${SRCTOP}/contrib/ldns +LDNSHOSTDIR= ${SRCTOP}/contrib/ldns-host .PATH: ${LDNSHOSTDIR} Modified: head/usr.bin/ipcrm/Makefile ============================================================================== --- head/usr.bin/ipcrm/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/ipcrm/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,8 +3,8 @@ PROG= ipcrm SRCS= ipcrm.c ipc.c LIBADD= kvm -CFLAGS+=-I${.CURDIR}/../ipcs -.PATH: ${.CURDIR}/../ipcs +CFLAGS+=-I${SRCTOP}/usr.bin/ipcs +.PATH: ${SRCTOP}/usr.bin/ipcs WARNS?= 0 Modified: head/usr.bin/iscsictl/Makefile ============================================================================== --- head/usr.bin/iscsictl/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/iscsictl/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -4,7 +4,7 @@ PACKAGE= iscsi PROG= iscsictl SRCS= iscsictl.c periphs.c parse.y token.l y.tab.h CFLAGS+= -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../sys/dev/iscsi +CFLAGS+= -I${SRCTOP}/sys/dev/iscsi MAN= iscsi.conf.5 iscsictl.8 LIBADD= xo Modified: head/usr.bin/kdump/Makefile ============================================================================== --- head/usr.bin/kdump/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/kdump/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,11 +3,11 @@ .include -.PATH: ${.CURDIR}/../ktrace +.PATH: ${SRCTOP}/usr.bin/ktrace PROG= kdump SRCS= kdump.c subr.c -CFLAGS+= -I${.CURDIR}/../ktrace #-I${.CURDIR}/../... +CFLAGS+= -I${SRCTOP}/usr.bin/ktrace LIBADD= sysdecode .if ${MK_CASPER} != "no" Modified: head/usr.bin/less/Makefile.common ============================================================================== --- head/usr.bin/less/Makefile.common Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/less/Makefile.common Sun Mar 12 18:58:44 2017 (r315170) @@ -1,9 +1,9 @@ # $FreeBSD$ -LSDIR= ${.CURDIR}/../../contrib/less +LSDIR= ${SRCTOP}/contrib/less .PATH: ${LSDIR} -CFLAGS+=-I${.CURDIR}/../less -I${LSDIR} +CFLAGS+=-I${SRCTOP}/usr.bin/less -I${LSDIR} WARNS?= 1 .SUFFIXES: .nro .1 Modified: head/usr.bin/lessecho/Makefile ============================================================================== --- head/usr.bin/lessecho/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/lessecho/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -4,5 +4,5 @@ PROG= lessecho SRCS= lessecho.c version.c CLEANFILES= lessecho.1 -.include "${.CURDIR}/../less/Makefile.common" +.include "${SRCTOP}/usr.bin/less/Makefile.common" .include Modified: head/usr.bin/lesskey/Makefile ============================================================================== --- head/usr.bin/lesskey/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/lesskey/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -4,5 +4,5 @@ PROG= lesskey SRCS= lesskey.c version.c CLEANFILES= lesskey.1 -.include "${.CURDIR}/../less/Makefile.common" +.include "${SRCTOP}/usr.bin/less/Makefile.common" .include Modified: head/usr.bin/lex/Makefile ============================================================================== --- head/usr.bin/lex/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/lex/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -14,7 +14,7 @@ LINKS+= ${BINDIR}/lex ${BINDIR}/lex++ LINKS+= ${BINDIR}/lex ${BINDIR}/flex LINKS+= ${BINDIR}/lex ${BINDIR}/flex++ -FLEXDIR= ${.CURDIR}/../../contrib/flex +FLEXDIR= ${SRCTOP}/contrib/flex .PATH: ${FLEXDIR} Modified: head/usr.bin/lex/lib/Makefile ============================================================================== --- head/usr.bin/lex/lib/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/lex/lib/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,7 +2,7 @@ .include -.PATH: ${.CURDIR}/../../../contrib/flex +.PATH: ${SRCTOP}/contrib/flex LIB= ln SRCS= libmain.c libyywrap.c Modified: head/usr.bin/locale/Makefile ============================================================================== --- head/usr.bin/locale/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/locale/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ PROG= locale -CFLAGS+= -I${.CURDIR}/../../lib/libc/locale +CFLAGS+= -I${SRCTOP}/lib/libc/locale .include Modified: head/usr.bin/localedef/Makefile ============================================================================== --- head/usr.bin/localedef/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/localedef/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -20,7 +20,7 @@ parser.h: parser.y IGNORE_PRAGMA= yes CFLAGS+= -I. -I${.CURDIR} -CFLAGS+= -I${.CURDIR}/../../lib/libc/locale -CFLAGS+= -I${.CURDIR}/../../lib/libc/stdtime +CFLAGS+= -I${SRCTOP}/lib/libc/locale +CFLAGS+= -I${SRCTOP}/lib/libc/stdtime .include Modified: head/usr.bin/lzmainfo/Makefile ============================================================================== --- head/usr.bin/lzmainfo/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/lzmainfo/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,8 +2,8 @@ PROG= lzmainfo -XZDIR= ${.CURDIR}/../../contrib/xz/src -LZMALIBDIR= ${.CURDIR}/../../lib/liblzma +XZDIR= ${SRCTOP}/contrib/xz/src +LZMALIBDIR= ${SRCTOP}/lib/liblzma .PATH: ${XZDIR}/lzmainfo SRCS+= lzmainfo.c Modified: head/usr.bin/m4/Makefile ============================================================================== --- head/usr.bin/m4/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/m4/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -7,7 +7,7 @@ .include PROG= m4 -CFLAGS+=-DEXTENDED -I${.CURDIR} -I${.CURDIR}/../../lib/libopenbsd +CFLAGS+=-DEXTENDED -I${.CURDIR} -I${SRCTOP}/lib/libopenbsd LIBADD= y l m openbsd NO_WMISSING_VARIABLE_DECLARATIONS= Modified: head/usr.bin/mandoc/Makefile ============================================================================== --- head/usr.bin/mandoc/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mandoc/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,7 +2,7 @@ .include -MDOCMLDIR= ${.CURDIR}/../../contrib/mdocml +MDOCMLDIR= ${SRCTOP}/contrib/mdocml .PATH: ${MDOCMLDIR} PROG= mandoc @@ -89,7 +89,7 @@ SRCS= ${LIB_SRCS} \ WARNS?= 3 CFLAGS+= -DHAVE_CONFIG_H \ - -I${.CURDIR}/../../lib/libopenbsd/ + -I${SRCTOP}/lib/libopenbsd/ LIBADD= openbsd z .include Modified: head/usr.bin/minigzip/Makefile ============================================================================== --- head/usr.bin/minigzip/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/minigzip/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -SRCDIR= ${.CURDIR}/../../contrib/zlib/test +SRCDIR= ${SRCTOP}/contrib/zlib/test .PATH: ${SRCDIR} PROG= minigzip Modified: head/usr.bin/mkcsmapper/Makefile ============================================================================== --- head/usr.bin/mkcsmapper/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mkcsmapper/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,9 +1,9 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../lib/libc/iconv +.PATH: ${SRCTOP}/lib/libc/iconv PROG= mkcsmapper -LDFLAGS+= -L${.CURDIR}/../../lib/libc +LDFLAGS+= -L${SRCTOP}/lib/libc NO_WMISSING_VARIABLE_DECLARATIONS= Modified: head/usr.bin/mkcsmapper/Makefile.inc ============================================================================== --- head/usr.bin/mkcsmapper/Makefile.inc Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mkcsmapper/Makefile.inc Sun Mar 12 18:58:44 2017 (r315170) @@ -3,7 +3,7 @@ .include SRCS+= lex.l yacc.y -CFLAGS+= -I${.CURDIR} -I${.CURDIR}/../mkcsmapper \ - -I${.CURDIR}/../../lib/libc/iconv \ - -I${.CURDIR}/../../lib/libiconv_modules/mapper_std +CFLAGS+= -I${.CURDIR} -I${SRCTOP}/usr.bin/mkcsmapper \ + -I${SRCTOP}/lib/libc/iconv \ + -I${SRCTOP}/lib/libiconv_modules/mapper_std CFLAGS.gcc+= --param max-inline-insns-single=64 Modified: head/usr.bin/mkcsmapper_static/Makefile ============================================================================== --- head/usr.bin/mkcsmapper_static/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mkcsmapper_static/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../lib/libc/iconv ${.CURDIR}/../mkcsmapper +.PATH: ${SRCTOP}/lib/libc/iconv ${SRCTOP}/usr.bin/mkcsmapper PROG= mkcsmapper_static SRCS= citrus_bcs.c citrus_db_factory.c citrus_db_hash.c \ @@ -11,7 +11,7 @@ NO_WMISSING_VARIABLE_DECLARATIONS= build-tools: mkcsmapper_static -.include "${.CURDIR}/../mkcsmapper/Makefile.inc" +.include "${SRCTOP}/usr.bin/mkcsmapper/Makefile.inc" .include ${PROG}: ${BUILD_TOOLS_META} Modified: head/usr.bin/mkesdb/Makefile ============================================================================== --- head/usr.bin/mkesdb/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mkesdb/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../lib/libc/iconv +.PATH: ${SRCTOP}/lib/libc/iconv PROG= mkesdb Modified: head/usr.bin/mkesdb_static/Makefile ============================================================================== --- head/usr.bin/mkesdb_static/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mkesdb_static/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../lib/libc/iconv ${.CURDIR}/../mkesdb +.PATH: ${SRCTOP}/lib/libc/iconv ${SRCTOP}/usr.bin/mkesdb PROG= mkesdb_static SRCS= citrus_bcs.c citrus_db_factory.c citrus_db_hash.c \ @@ -11,7 +11,7 @@ NO_WMISSING_VARIABLE_DECLARATIONS= build-tools: mkesdb_static -.include "${.CURDIR}/../mkesdb/Makefile.inc" +.include "${SRCTOP}/usr.bin/mkesdb/Makefile.inc" .include ${PROG}: ${BUILD_TOOLS_META} Modified: head/usr.bin/mklocale/Makefile ============================================================================== --- head/usr.bin/mklocale/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/mklocale/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,7 +3,7 @@ PROG= mklocale SRCS= yacc.y lex.l y.tab.h -CFLAGS+= -I. -I${.CURDIR} -I${.CURDIR}/../../lib/libc/locale +CFLAGS+= -I. -I${.CURDIR} -I${SRCTOP}/lib/libc/locale NO_WMISSING_VARIABLE_DECLARATIONS= Modified: head/usr.bin/nc/Makefile ============================================================================== --- head/usr.bin/nc/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/nc/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -.PATH: ${.CURDIR}/../../contrib/netcat +.PATH: ${SRCTOP}/contrib/netcat PROG= nc SRCS= netcat.c atomicio.c socks.c Modified: head/usr.bin/opieinfo/Makefile ============================================================================== --- head/usr.bin/opieinfo/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/opieinfo/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,10 +1,10 @@ # $FreeBSD$ # -OPIE_DIST?= ${.CURDIR}/../../contrib/opie +OPIE_DIST?= ${SRCTOP}/contrib/opie PROG= opieinfo -CFLAGS+=-I${.CURDIR}/../../lib/libopie +CFLAGS+=-I${SRCTOP}/lib/libopie CFLAGS+=-I${OPIE_DIST} CFLAGS+=-DINSECURE_OVERRIDE Modified: head/usr.bin/opiekey/Makefile ============================================================================== --- head/usr.bin/opiekey/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/opiekey/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,10 +1,10 @@ # $FreeBSD$ # -OPIE_DIST?= ${.CURDIR}/../../contrib/opie +OPIE_DIST?= ${SRCTOP}/contrib/opie PROG= opiekey -CFLAGS+=-I${.CURDIR}/../../lib/libopie +CFLAGS+=-I${SRCTOP}/lib/libopie CFLAGS+=-I${OPIE_DIST} CFLAGS+=-DINSECURE_OVERRIDE Modified: head/usr.bin/opiepasswd/Makefile ============================================================================== --- head/usr.bin/opiepasswd/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/opiepasswd/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,10 +1,10 @@ # $FreeBSD$ # -OPIE_DIST?= ${.CURDIR}/../../contrib/opie +OPIE_DIST?= ${SRCTOP}/contrib/opie PROG= opiepasswd -CFLAGS+=-I${.CURDIR}/../../lib/libopie +CFLAGS+=-I${SRCTOP}/lib/libopie CFLAGS+=-I${OPIE_DIST} CFLAGS+=-DINSECURE_OVERRIDE Modified: head/usr.bin/pamtest/Makefile ============================================================================== --- head/usr.bin/pamtest/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/pamtest/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -OPENPAM= ${.CURDIR}/../../contrib/openpam +OPENPAM= ${SRCTOP}/contrib/openpam .PATH: ${OPENPAM}/include ${OPENPAM}/bin/pamtest PROG= pamtest Modified: head/usr.bin/readelf/Makefile ============================================================================== --- head/usr.bin/readelf/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/readelf/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -14,7 +14,7 @@ CFLAGS+=-I${ELFTCDIR}/libelftc -I${ELFTC # This same hack is in lib/libelf/Makefile and lib/libdwarf/Makefile # We need to link against the correct version of these files. One -# solution is to include ../../sys in the include path. This causes +# solution is to include SRCTOP/sys in the include path. This causes # problems when a header file in sys depends on a file in another # part of the tree, e.g. a machine dependent header. # Modified: head/usr.bin/rsh/Makefile ============================================================================== --- head/usr.bin/rsh/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/rsh/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,7 +2,7 @@ # $FreeBSD$ PROG= rsh -CFLAGS+=-I${.CURDIR}/../../libexec/rlogind +CFLAGS+=-I${SRCTOP}/libexec/rlogind PACKAGE=rcmds Modified: head/usr.bin/smbutil/Makefile ============================================================================== --- head/usr.bin/smbutil/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/smbutil/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -5,7 +5,7 @@ SRCS= smbutil.c dumptree.c login.c looku LIBADD= smb -CONTRIBDIR= ${.CURDIR}/../../contrib/smbfs +CONTRIBDIR= ${SRCTOP}/contrib/smbfs CFLAGS+= -I${CONTRIBDIR}/include WARNS?= 0 Modified: head/usr.bin/svn/lib/Makefile.inc ============================================================================== --- head/usr.bin/svn/lib/Makefile.inc Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/svn/lib/Makefile.inc Sun Mar 12 18:58:44 2017 (r315170) @@ -2,11 +2,11 @@ .if !defined(SVNDIR) -SVNDIR= ${.CURDIR}/../../../../contrib/subversion/subversion -APRU= ${.CURDIR}/../../../../contrib/apr-util -APR= ${.CURDIR}/../../../../contrib/apr -SQLITE= ${.CURDIR}/../../../../contrib/sqlite3 -SERF= ${.CURDIR}/../../../../contrib/serf +SVNDIR= ${SRCTOP}/contrib/subversion/subversion +APRU= ${SRCTOP}/contrib/apr-util +APR= ${SRCTOP}/contrib/apr +SQLITE= ${SRCTOP}/contrib/sqlite3 +SERF= ${SRCTOP}/contrib/serf WARNS?= 0 # definitely not ready Modified: head/usr.bin/tar/Makefile ============================================================================== --- head/usr.bin/tar/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/tar/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,7 +1,7 @@ # $FreeBSD$ .include -_LIBARCHIVEDIR= ${.CURDIR}/../../contrib/libarchive +_LIBARCHIVEDIR= ${SRCTOP}/contrib/libarchive PROG= bsdtar BSDTAR_VERSION_STRING= 3.3.1 @@ -27,7 +27,7 @@ CFLAGS+= -DHAVE_ICONV=1 -DHAVE_ICONV_H=1 .endif CFLAGS+= -DBSDTAR_VERSION_STRING=\"${BSDTAR_VERSION_STRING}\" -CFLAGS+= -DPLATFORM_CONFIG_H=\"${.CURDIR}/../../lib/libarchive/config_freebsd.h\" +CFLAGS+= -DPLATFORM_CONFIG_H=\"${SRCTOP}/lib/libarchive/config_freebsd.h\" CFLAGS+= -I${_LIBARCHIVEDIR}/tar -I${_LIBARCHIVEDIR}/libarchive CFLAGS+= -I${_LIBARCHIVEDIR}/libarchive_fe SYMLINKS= bsdtar ${BINDIR}/tar Modified: head/usr.bin/telnet/Makefile ============================================================================== --- head/usr.bin/telnet/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/telnet/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -2,7 +2,7 @@ .include -TELNETDIR= ${.CURDIR}/../../contrib/telnet +TELNETDIR= ${SRCTOP}/contrib/telnet .PATH: ${TELNETDIR}/telnet PROG= telnet Modified: head/usr.bin/tftp/Makefile ============================================================================== --- head/usr.bin/tftp/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/tftp/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,12 +1,12 @@ # @(#)Makefile 8.1 (Berkeley) 6/6/93 # $FreeBSD$ -.PATH: ${.CURDIR}/../../libexec/tftpd +.PATH: ${SRCTOP}/libexec/tftpd PROG= tftp SRCS= main.c tftp-file.c tftp-io.c tftp-options.c tftp-transfer.c SRCS+= tftp-utils.c tftp.c -CFLAGS+=-I${.CURDIR}/../../libexec/tftpd +CFLAGS+=-I${SRCTOP}/libexec/tftpd LIBADD= edit Modified: head/usr.bin/top/Makefile ============================================================================== --- head/usr.bin/top/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/top/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -TOPDIR= ${.CURDIR}/../../contrib/top +TOPDIR= ${SRCTOP}/contrib/top .PATH: ${TOPDIR} PROG= top @@ -24,7 +24,7 @@ CFLAGS+= -D"Table_size=${TOP_TABLE_SIZE} LIBADD= ncursesw m kvm jail CLEANFILES= sigdesc.h -SIGCONV_AWK= ${.CURDIR}/../../contrib/top/sigconv.awk +SIGCONV_AWK= ${SRCTOP}/contrib/top/sigconv.awk STAGED_INCLUDE_DIR?= ${DESTDIR}/usr/include SIGNAL_H= ${STAGED_INCLUDE_DIR}/sys/signal.h sigdesc.h: ${SIGCONV_AWK} ${SIGNAL_H} Modified: head/usr.bin/truss/Makefile ============================================================================== --- head/usr.bin/truss/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/truss/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -6,8 +6,8 @@ SRCS= main.c setup.c syscalls.c LIBADD= sysdecode -#CFLAGS+= -I${.CURDIR} -I. -I${.CURDIR}/../../sys -CFLAGS+= -I${.CURDIR}/../../sys +#CFLAGS+= -I${.CURDIR} -I. -I${SRCTOP}/sys +CFLAGS+= -I${SRCTOP}/sys ABIS+= freebsd # Each ABI is expected to have an ABI.c, MACHINE_ARCH-ABI.c or Modified: head/usr.bin/unvis/Makefile ============================================================================== --- head/usr.bin/unvis/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/unvis/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,6 +3,6 @@ PROG= unvis -.PATH: ${.CURDIR}/../../contrib/unvis +.PATH: ${SRCTOP}/contrib/unvis .include Modified: head/usr.bin/vacation/Makefile ============================================================================== --- head/usr.bin/vacation/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/vacation/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,6 +1,6 @@ # $FreeBSD$ -SENDMAIL_DIR=${.CURDIR}/../../contrib/sendmail +SENDMAIL_DIR=${SRCTOP}/contrib/sendmail .PATH: ${SENDMAIL_DIR}/vacation PROG= vacation Modified: head/usr.bin/vi/Makefile ============================================================================== --- head/usr.bin/vi/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/vi/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -5,7 +5,7 @@ .include PACKAGE= vi -SRCDIR= ${.CURDIR}/../../contrib/nvi +SRCDIR= ${SRCTOP}/contrib/nvi SUBDIR+= catalog WARNS?= 0 # some warn issues on 32 bit machines Modified: head/usr.bin/vis/Makefile ============================================================================== --- head/usr.bin/vis/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/vis/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -4,7 +4,7 @@ PROG= vis SRCS= vis.c foldit.c -.PATH: ${.CURDIR}/../../contrib/vis -CFLAGS+= -I${.CURDIR}/../../contrib/vis +.PATH: ${SRCTOP}/contrib/vis +CFLAGS+= -I${SRCTOP}/contrib/vis .include Modified: head/usr.bin/w/Makefile ============================================================================== --- head/usr.bin/w/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/w/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -7,6 +7,6 @@ MAN= w.1 uptime.1 LIBADD= kvm sbuf xo util LINKS= ${BINDIR}/w ${BINDIR}/uptime -.PATH: ${.CURDIR}/../../bin/ps +.PATH: ${SRCTOP}/bin/ps .include Modified: head/usr.bin/xinstall/Makefile ============================================================================== --- head/usr.bin/xinstall/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/xinstall/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -8,9 +8,9 @@ PROGNAME= install SRCS= xinstall.c getid.c MAN= install.1 -.PATH: ${.CURDIR}/../../contrib/mtree -CFLAGS+= -I${.CURDIR}/../../contrib/mtree -CFLAGS+= -I${.CURDIR}/../../lib/libnetbsd +.PATH: ${SRCTOP}/contrib/mtree +CFLAGS+= -I${SRCTOP}/contrib/mtree +CFLAGS+= -I${SRCTOP}/lib/libnetbsd LIBADD= md Modified: head/usr.bin/xz/Makefile ============================================================================== --- head/usr.bin/xz/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/xz/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -10,8 +10,8 @@ LINKS+= ${BINDIR}/xz ${BINDIR}/lzcat MLINKS= xz.1 unxz.1 xz.1 lzma.1 xz.1 unlzma.1 xz.1 xzcat.1 xz.1 lzcat.1 -XZDIR= ${.CURDIR}/../../contrib/xz/src -LZMALIBDIR= ${.CURDIR}/../../lib/liblzma +XZDIR= ${SRCTOP}/contrib/xz/src +LZMALIBDIR= ${SRCTOP}/lib/liblzma .PATH: ${XZDIR}/xz Modified: head/usr.bin/xzdec/Makefile ============================================================================== --- head/usr.bin/xzdec/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/xzdec/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -6,8 +6,8 @@ LINKS= ${BINDIR}/xzdec ${BINDIR}/lzdec MLINKS= xzdec.1 lzmadec.1 -XZDIR= ${.CURDIR}/../../contrib/xz/src -LZMALIBDIR= ${.CURDIR}/../../lib/liblzma +XZDIR= ${SRCTOP}/contrib/xz/src +LZMALIBDIR= ${SRCTOP}/lib/liblzma .PATH: ${XZDIR}/xzdec Modified: head/usr.bin/yacc/Makefile ============================================================================== --- head/usr.bin/yacc/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/yacc/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -3,7 +3,7 @@ .include -BYACC_SRC= ${.CURDIR}/../../contrib/byacc +BYACC_SRC= ${SRCTOP}/contrib/byacc .PATH: ${BYACC_SRC} PROG= yacc Modified: head/usr.bin/ypwhich/Makefile ============================================================================== --- head/usr.bin/ypwhich/Makefile Sun Mar 12 18:38:03 2017 (r315169) +++ head/usr.bin/ypwhich/Makefile Sun Mar 12 18:58:44 2017 (r315170) @@ -1,7 +1,7 @@ # from: @(#)Makefile 5.8 (Berkeley) 7/28/90 # $FreeBSD$ -YPSERV=${.CURDIR}/../../usr.sbin/ypserv/common +YPSERV=${SRCTOP}/usr.sbin/ypserv/common .PATH: ${YPSERV} PROG= ypwhich From owner-svn-src-all@freebsd.org Sun Mar 12 18:58:57 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 12872D08B01; Sun, 12 Mar 2017 18:58:57 +0000 (UTC) (envelope-from imp@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 E1977104F; Sun, 12 Mar 2017 18:58:56 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIwufQ001711; Sun, 12 Mar 2017 18:58:56 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIwtI1001709; Sun, 12 Mar 2017 18:58:55 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121858.v2CIwtI1001709@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:58:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315171 - in head/etc: . sendmail X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:58:57 -0000 Author: imp Date: Sun Mar 12 18:58:55 2017 New Revision: 315171 URL: https://svnweb.freebsd.org/changeset/base/315171 Log: Move /etc/ to SRCTOP Prefer ${SRCTOP}/ to ${.CURDIR}/../ and ${.CURDIR}/../../ as appropriate. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence On: arch@ (twice) Modified: head/etc/Makefile head/etc/sendmail/Makefile Modified: head/etc/Makefile ============================================================================== --- head/etc/Makefile Sun Mar 12 18:58:44 2017 (r315170) +++ head/etc/Makefile Sun Mar 12 18:58:55 2017 (r315171) @@ -64,7 +64,7 @@ BIN1+= etc.${MACHINE_CPUARCH}/ttys .error etc.MACHINE/ttys missing .endif -OPENBSMDIR= ${.CURDIR}/../contrib/openbsm +OPENBSMDIR= ${SRCTOP}/contrib/openbsm BSM_ETC_OPEN_FILES= ${OPENBSMDIR}/etc/audit_class \ ${OPENBSMDIR}/etc/audit_event BSM_ETC_RESTRICTED_FILES= ${OPENBSMDIR}/etc/audit_control \ @@ -103,7 +103,7 @@ BIN1+= inetd.conf .endif .if ${MK_LOCATE} != "no" -BIN1+= ${.CURDIR}/../usr.bin/locate/locate/locate.rc +BIN1+= ${SRCTOP}/usr.bin/locate/locate/locate.rc .endif .if ${MK_LPR} != "no" @@ -111,7 +111,7 @@ BIN1+= hosts.lpd printcap .endif .if ${MK_MAIL} != "no" -BIN1+= ${.CURDIR}/../usr.bin/mail/misc/mail.rc +BIN1+= ${SRCTOP}/usr.bin/mail/misc/mail.rc .endif .if ${MK_NTP} != "no" @@ -119,12 +119,12 @@ BIN1+= ntp.conf .endif .if ${MK_OPENSSH} != "no" -SSH= ${.CURDIR}/../crypto/openssh/ssh_config \ - ${.CURDIR}/../crypto/openssh/sshd_config \ - ${.CURDIR}/../crypto/openssh/moduli +SSH= ${SRCTOP}/crypto/openssh/ssh_config \ + ${SRCTOP}/crypto/openssh/sshd_config \ + ${SRCTOP}/crypto/openssh/moduli .endif .if ${MK_OPENSSL} != "no" -SSL= ${.CURDIR}/../crypto/openssl/apps/openssl.cnf +SSL= ${SRCTOP}/crypto/openssl/apps/openssl.cnf .endif .if ${MK_NS_CACHING} != "no" @@ -185,7 +185,7 @@ DESTDIR:= ${DESTDIR:C://*:/:g} afterinstall: .if ${MK_MAN} != "no" - ${_+_}cd ${.CURDIR}/../share/man; ${MAKE} makedb + ${_+_}cd ${SRCTOP}/share/man; ${MAKE} makedb .endif distribute: @@ -263,8 +263,8 @@ distribution: ${_+_}cd ${.CURDIR}/pkg; ${MAKE} install .endif ${_+_}cd ${.CURDIR}/rc.d; ${MAKE} install - ${_+_}cd ${.CURDIR}/../share/termcap; ${MAKE} etc-termcap - ${_+_}cd ${.CURDIR}/../usr.sbin/rmt; ${MAKE} etc-rmt + ${_+_}cd ${SRCTOP}/share/termcap; ${MAKE} etc-termcap + ${_+_}cd ${SRCTOP}/usr.sbin/rmt; ${MAKE} etc-rmt ${_+_}cd ${.CURDIR}/pam.d; ${MAKE} install cd ${.CURDIR}; ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 0444 \ ${BSM_ETC_OPEN_FILES} ${BSM_ETC_DIR} @@ -328,9 +328,9 @@ distribution: cd ${.CURDIR}/..; ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \ ${FREEBSD} ${DESTDIR}/ .if ${MK_BOOT} != "no" -.if exists(${.CURDIR}/../sys/${MACHINE}/conf/GENERIC.hints) +.if exists(${SRCTOP}/sys/${MACHINE}/conf/GENERIC.hints) ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 444 \ - ${.CURDIR}/../sys/${MACHINE}/conf/GENERIC.hints \ + ${SRCTOP}/sys/${MACHINE}/conf/GENERIC.hints \ ${DESTDIR}/boot/device.hints .endif .endif Modified: head/etc/sendmail/Makefile ============================================================================== --- head/etc/sendmail/Makefile Sun Mar 12 18:58:44 2017 (r315170) +++ head/etc/sendmail/Makefile Sun Mar 12 18:58:55 2017 (r315171) @@ -6,7 +6,7 @@ CHMOD= chmod ROMODE= 444 RM= rm -f -SENDMAIL_DIR= ${.CURDIR}/../../contrib/sendmail +SENDMAIL_DIR= ${SRCTOP}/contrib/sendmail SMDIR= ${SENDMAIL_DIR}/src SENDMAIL_CF_DIR?=${SENDMAIL_DIR}/cf From owner-svn-src-all@freebsd.org Sun Mar 12 18:59:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BBEB5D08B2F; Sun, 12 Mar 2017 18:59:01 +0000 (UTC) (envelope-from imp@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 95CEB10BF; Sun, 12 Mar 2017 18:59:01 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIx0E1001769; Sun, 12 Mar 2017 18:59:00 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIx0OT001768; Sun, 12 Mar 2017 18:59:00 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121859.v2CIx0OT001768@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:59:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315172 - head/include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:59:01 -0000 Author: imp Date: Sun Mar 12 18:59:00 2017 New Revision: 315172 URL: https://svnweb.freebsd.org/changeset/base/315172 Log: Convert include over to SRCTOP Use SRCTOP in place of .CURDIR/.. as appropriate. The hand-crafted relative paths for the "links" option remain, though, since those are relative to /usr/include/sys/ not to the source tree. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence On: arch@ (twice) Modified: head/include/Makefile Modified: head/include/Makefile ============================================================================== --- head/include/Makefile Sun Mar 12 18:58:55 2017 (r315171) +++ head/include/Makefile Sun Mar 12 18:59:00 2017 (r315172) @@ -29,7 +29,7 @@ INCS= a.out.h ar.h assert.h bitstring.h uchar.h ulimit.h unistd.h utime.h utmpx.h uuid.h varargs.h \ wchar.h wctype.h wordexp.h xlocale.h -.PATH: ${.CURDIR}/../contrib/libc-vis +.PATH: ${SRCTOP}/contrib/libc-vis INCS+= vis.h MHDRS= float.h floatingpoint.h stdarg.h @@ -103,7 +103,7 @@ SHARED?= copies INCS+= osreldate.h -SYSDIR= ${.CURDIR}/../sys +SYSDIR= ${SRCTOP}/sys NEWVERS_SH= ${SYSDIR}/conf/newvers.sh PARAM_H= ${SYSDIR}/sys/param.h MK_OSRELDATE_SH= ${.CURDIR}/mk-osreldate.sh @@ -142,7 +142,7 @@ compat: fi .endfor mtree -deU ${MTREE_FOLLOWS_SYMLINKS} \ - -f ${.CURDIR}/../etc/mtree/BSD.include.dist \ + -f ${SRCTOP}/etc/mtree/BSD.include.dist \ -p ${DESTDIR}${INCLUDEDIR} > /dev/null copies: .PHONY .META @@ -156,101 +156,101 @@ copies: .PHONY .META fi .endfor .for i in ${LDIRS} ${LSUBDIRS:Ndev/agp:Ndev/acpica:Ndev/bktr:Ndev/evdev:Ndev/hyperv:Ndev/nand:Ndev/pci} ${LSUBSUBDIRS} - cd ${.CURDIR}/../sys; \ + cd ${SRCTOP}/sys; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 $i/*.h \ ${DESTDIR}${INCLUDEDIR}/$i .endfor - cd ${.CURDIR}/../sys/dev/acpica; \ + cd ${SRCTOP}/sys/dev/acpica; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 acpiio.h \ ${DESTDIR}${INCLUDEDIR}/dev/acpica; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 acpi_hpet.h \ ${DESTDIR}${INCLUDEDIR}/dev/acpica - cd ${.CURDIR}/../sys/dev/agp; \ + cd ${SRCTOP}/sys/dev/agp; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 agpreg.h \ ${DESTDIR}${INCLUDEDIR}/dev/agp - cd ${.CURDIR}/../sys/dev/bktr; \ + cd ${SRCTOP}/sys/dev/bktr; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 ioctl_*.h \ ${DESTDIR}${INCLUDEDIR}/dev/bktr .if ${MK_NAND} != "no" - cd ${.CURDIR}/../sys/dev/nand; \ + cd ${SRCTOP}/sys/dev/nand; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 nandsim.h \ ${DESTDIR}${INCLUDEDIR}/dev/nand; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 nand_dev.h \ ${DESTDIR}${INCLUDEDIR}/dev/nand .endif - cd ${.CURDIR}/../sys/dev/evdev; \ + cd ${SRCTOP}/sys/dev/evdev; \ ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 input.h \ ${DESTDIR}${INCLUDEDIR}/dev/evdev; \ ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 input-event-codes.h \ ${DESTDIR}${INCLUDEDIR}/dev/evdev; \ ${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 uinput.h \ ${DESTDIR}${INCLUDEDIR}/dev/evdev - cd ${.CURDIR}/../sys/dev/hyperv/include; \ + cd ${SRCTOP}/sys/dev/hyperv/include; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 hyperv.h \ ${DESTDIR}${INCLUDEDIR}/dev/hyperv - cd ${.CURDIR}/../sys/dev/hyperv/utilities; \ + cd ${SRCTOP}/sys/dev/hyperv/utilities; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 hv_snapshot.h \ ${DESTDIR}${INCLUDEDIR}/dev/hyperv - cd ${.CURDIR}/../sys/dev/pci; \ + cd ${SRCTOP}/sys/dev/pci; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 pcireg.h \ ${DESTDIR}${INCLUDEDIR}/dev/pci - cd ${.CURDIR}/../sys/fs/cd9660/; \ + cd ${SRCTOP}/sys/fs/cd9660/; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/isofs/cd9660 .if ${MK_IPFILTER} != "no" - cd ${.CURDIR}/../sys/contrib/ipfilter/netinet; \ + cd ${SRCTOP}/sys/contrib/ipfilter/netinet; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/netinet .endif .if ${MK_PF} != "no" - cd ${.CURDIR}/../sys/netpfil/pf; \ + cd ${SRCTOP}/sys/netpfil/pf; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/netpfil/pf .endif - cd ${.CURDIR}/../sys/crypto; \ + cd ${SRCTOP}/sys/crypto; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 rijndael/rijndael.h \ ${DESTDIR}${INCLUDEDIR}/crypto - cd ${.CURDIR}/../sys/opencrypto; \ + cd ${SRCTOP}/sys/opencrypto; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/crypto - cd ${.CURDIR}/../sys/${MACHINE}/include; \ + cd ${SRCTOP}/sys/${MACHINE}/include; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/machine -.if exists(${.CURDIR}/../sys/${MACHINE}/include/pc) - cd ${.CURDIR}/../sys/${MACHINE}/include/pc; \ +.if exists(${SRCTOP}/sys/${MACHINE}/include/pc) + cd ${SRCTOP}/sys/${MACHINE}/include/pc; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/machine/pc .endif .for _MARCH in ${_MARCHS} -.if exists(${.CURDIR}/../sys/${_MARCH}/include) +.if exists(${SRCTOP}/sys/${_MARCH}/include) ${INSTALL} -d ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 755 \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}; \ - cd ${.CURDIR}/../sys/${_MARCH}/include; \ + cd ${SRCTOP}/sys/${_MARCH}/include; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/${_MARCH} -.if exists(${.CURDIR}/../sys/${_MARCH}/include/pc) +.if exists(${SRCTOP}/sys/${_MARCH}/include/pc) ${INSTALL} -d ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 755 \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}/pc; \ - cd ${.CURDIR}/../sys/${_MARCH}/include/pc; \ + cd ${SRCTOP}/sys/${_MARCH}/include/pc; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 *.h \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}/pc .endif .endif .endfor - cd ${.CURDIR}/../sys/rpc; \ + cd ${SRCTOP}/sys/rpc; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 types.h \ ${DESTDIR}${INCLUDEDIR}/rpc - cd ${.CURDIR}/../sys/teken; \ + cd ${SRCTOP}/sys/teken; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 teken.h \ ${DESTDIR}${INCLUDEDIR}/teken .if ${MK_CDDL} != "no" - cd ${.CURDIR}/../cddl/contrib/opensolaris/lib/libzfs_core/common; \ + cd ${SRCTOP}/cddl/contrib/opensolaris/lib/libzfs_core/common; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 libzfs_core.h \ ${DESTDIR}${INCLUDEDIR} - cd ${.CURDIR}/../cddl/contrib/opensolaris/lib/libnvpair; \ + cd ${SRCTOP}/cddl/contrib/opensolaris/lib/libnvpair; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 libnvpair.h \ ${DESTDIR}${INCLUDEDIR} - cd ${.CURDIR}/../sys/cddl/contrib/opensolaris/uts/common/sys; \ + cd ${SRCTOP}/sys/cddl/contrib/opensolaris/uts/common/sys; \ ${INSTALL} -C ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 444 nvpair.h \ ${DESTDIR}${INCLUDEDIR}/sys .endif @@ -258,114 +258,114 @@ copies: .PHONY .META symlinks: .PHONY .META @${ECHO} "Setting up symlinks to kernel source tree..." .for i in ${LDIRS} - cd ${.CURDIR}/../sys/$i; \ + cd ${SRCTOP}/sys/$i; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/$i/$$h ${DESTDIR}${INCLUDEDIR}/$i; \ done .endfor .for i in ${LSUBDIRS:Ndev/agp:Ndev/acpica:Ndev/bktr:Ndev/evdev:Ndev/hyperv:Ndev/nand:Ndev/pci} - cd ${.CURDIR}/../sys/$i; \ + cd ${SRCTOP}/sys/$i; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/$i/$$h ${DESTDIR}${INCLUDEDIR}/$i; \ done .endfor - cd ${.CURDIR}/../sys/dev/acpica; \ + cd ${SRCTOP}/sys/dev/acpica; \ for h in acpiio.h acpi_hpet.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/acpica/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/acpica; \ done - cd ${.CURDIR}/../sys/dev/agp; \ + cd ${SRCTOP}/sys/dev/agp; \ for h in agpreg.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/agp/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/agp; \ done - cd ${.CURDIR}/../sys/dev/bktr; \ + cd ${SRCTOP}/sys/dev/bktr; \ for h in ioctl_*.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/bktr/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/bktr; \ done .if ${MK_NAND} != "no" - cd ${.CURDIR}/../sys/dev/nand; \ + cd ${SRCTOP}/sys/dev/nand; \ for h in nandsim.h nand_dev.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/nand/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/nand; \ done .endif - cd ${.CURDIR}/../sys/dev/evdev; \ + cd ${SRCTOP}/sys/dev/evdev; \ for h in input.h input-event-codes.h uinput.h; do \ ln -fs ../../../../sys/dev/evdev/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/evdev; \ done - cd ${.CURDIR}/../sys/dev/hyperv/include; \ + cd ${SRCTOP}/sys/dev/hyperv/include; \ for h in hyperv.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/hyperv/include/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/hyperv; \ done - cd ${.CURDIR}/../sys/dev/hyperv/utilities; \ + cd ${SRCTOP}/sys/dev/hyperv/utilities; \ for h in hv_snapshot.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/hyperv/utilities/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/hyperv; \ done - cd ${.CURDIR}/../sys/dev/pci; \ + cd ${SRCTOP}/sys/dev/pci; \ for h in pcireg.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/dev/pci/$$h \ ${DESTDIR}${INCLUDEDIR}/dev/pci; \ done .for i in ${LSUBSUBDIRS} - cd ${.CURDIR}/../sys/$i; \ + cd ${SRCTOP}/sys/$i; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../../sys/$i/$$h ${DESTDIR}${INCLUDEDIR}/$i; \ done .endfor .if ${MK_IPFILTER} != "no" - cd ${.CURDIR}/../sys/contrib/ipfilter/netinet; \ + cd ${SRCTOP}/sys/contrib/ipfilter/netinet; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/contrib/ipfilter/netinet/$$h \ ${DESTDIR}${INCLUDEDIR}/netinet; \ done .endif .if ${MK_PF} != "no" - cd ${.CURDIR}/../sys/netpfil/pf; \ + cd ${SRCTOP}/sys/netpfil/pf; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/netpfil/pf/$$h \ ${DESTDIR}${INCLUDEDIR}/netpfil/pf; \ done .endif - cd ${.CURDIR}/../sys/crypto; \ + cd ${SRCTOP}/sys/crypto; \ for h in rijndael/rijndael.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/crypto/$$h \ ${DESTDIR}${INCLUDEDIR}/crypto; \ done - cd ${.CURDIR}/../sys/opencrypto; \ + cd ${SRCTOP}/sys/opencrypto; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/opencrypto/$$h \ ${DESTDIR}${INCLUDEDIR}/crypto; \ done - cd ${.CURDIR}/../sys/${MACHINE}/include; \ + cd ${SRCTOP}/sys/${MACHINE}/include; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/${MACHINE}/include/$$h \ ${DESTDIR}${INCLUDEDIR}/machine; \ done -.if exists(${.CURDIR}/../sys/${MACHINE}/include/pc) - cd ${.CURDIR}/../sys/${MACHINE}/include/pc; \ +.if exists(${SRCTOP}/sys/${MACHINE}/include/pc) + cd ${SRCTOP}/sys/${MACHINE}/include/pc; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/${MACHINE}/include/pc/$$h \ ${DESTDIR}${INCLUDEDIR}/machine/pc; \ done .endif .for _MARCH in ${_MARCHS} -.if exists(${.CURDIR}/../sys/${_MARCH}/include) +.if exists(${SRCTOP}/sys/${_MARCH}/include) ${INSTALL} -d ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 755 \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}; \ - cd ${.CURDIR}/../sys/${_MARCH}/include; \ + cd ${SRCTOP}/sys/${_MARCH}/include; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/${_MARCH}/include/$$h \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}; \ done -.if exists(${.CURDIR}/../sys/${_MARCH}/include/pc) +.if exists(${SRCTOP}/sys/${_MARCH}/include/pc) ${INSTALL} -d ${TAG_ARGS} -o ${BINOWN} -g ${BINGRP} -m 755 \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}/pc; \ - cd ${.CURDIR}/../sys/${_MARCH}/include/pc; \ + cd ${SRCTOP}/sys/${_MARCH}/include/pc; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/${_MARCH}/include/pc/$$h \ ${DESTDIR}${INCLUDEDIR}/${_MARCH}/pc; \ @@ -373,12 +373,12 @@ symlinks: .PHONY .META .endif .endif .endfor - cd ${.CURDIR}/../sys/fs/cd9660; \ + cd ${SRCTOP}/sys/fs/cd9660; \ for h in *.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../../sys/fs/cd9660/$$h \ ${DESTDIR}${INCLUDEDIR}/isofs/cd9660; \ done - cd ${.CURDIR}/../sys/rpc; \ + cd ${SRCTOP}/sys/rpc; \ for h in types.h; do \ ${INSTALL_SYMLINK} ${TAG_ARGS} ../../../sys/rpc/$$h \ ${DESTDIR}${INCLUDEDIR}/rpc; \ From owner-svn-src-all@freebsd.org Sun Mar 12 18:59:06 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AF2E9D08B5C; Sun, 12 Mar 2017 18:59:06 +0000 (UTC) (envelope-from imp@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 7ADD51151; Sun, 12 Mar 2017 18:59:06 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIx5VQ001823; Sun, 12 Mar 2017 18:59:05 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIx5qm001821; Sun, 12 Mar 2017 18:59:05 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121859.v2CIx5qm001821@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:59:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315173 - in head/lib: libipsec libpathconv X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:59:06 -0000 Author: imp Date: Sun Mar 12 18:59:05 2017 New Revision: 315173 URL: https://svnweb.freebsd.org/changeset/base/315173 Log: Fix two CURDIR references in comments that should be SRCTOP references. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence On: arch@ (twice) Modified: head/lib/libipsec/Makefile head/lib/libpathconv/Makefile Modified: head/lib/libipsec/Makefile ============================================================================== --- head/lib/libipsec/Makefile Sun Mar 12 18:59:00 2017 (r315172) +++ head/lib/libipsec/Makefile Sun Mar 12 18:59:05 2017 (r315173) @@ -40,7 +40,7 @@ CFLAGS+=-DIPSEC_DEBUG -DIPSEC CFLAGS+=-DINET6 .endif -#.PATH: ${.CURDIR}/../../sys/netipsec +#.PATH: ${SRCTOP}/sys/netipsec #SRCS= pfkey.c pfkey_dump.c SRCS+= ipsec_strerror.c policy_parse.y policy_token.l SRCS+= ipsec_dump_policy.c ipsec_get_policylen.c Modified: head/lib/libpathconv/Makefile ============================================================================== --- head/lib/libpathconv/Makefile Sun Mar 12 18:59:00 2017 (r315172) +++ head/lib/libpathconv/Makefile Sun Mar 12 18:59:05 2017 (r315173) @@ -10,7 +10,7 @@ INCS= pathconv.h SRCS= abs2rel.c rel2abs.c -#VERSION_DEF= ${.CURDIR}/../libc/Versions.def +#VERSION_DEF= ${SRCTOP/lib/libc/Versions.def #SYMBOL_MAPS= ${.CURDIR}/Symbol.map .if ${MK_TESTS} != "no" From owner-svn-src-all@freebsd.org Sun Mar 12 18:59:11 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5E1B0D08B99; Sun, 12 Mar 2017 18:59:11 +0000 (UTC) (envelope-from imp@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 13FA711D4; Sun, 12 Mar 2017 18:59:11 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIxAvt001877; Sun, 12 Mar 2017 18:59:10 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIxA3R001875; Sun, 12 Mar 2017 18:59:10 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121859.v2CIxA3R001875@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:59:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315174 - in head/rescue: librescue rescue X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:59:11 -0000 Author: imp Date: Sun Mar 12 18:59:09 2017 New Revision: 315174 URL: https://svnweb.freebsd.org/changeset/base/315174 Log: Make rescue use SRCTOP Transition to SRCTOP. Also, standardize of {} instead of () variable deliminators while I'm here. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence On: arch@ (twice) Modified: head/rescue/librescue/Makefile head/rescue/rescue/Makefile Modified: head/rescue/librescue/Makefile ============================================================================== --- head/rescue/librescue/Makefile Sun Mar 12 18:59:05 2017 (r315173) +++ head/rescue/librescue/Makefile Sun Mar 12 18:59:09 2017 (r315174) @@ -13,10 +13,10 @@ MK_SSP= no # This library should never be installed, and isn't even linked # with in the normal way. (See ../rescue/Makefile for details.) -.PATH: ${.CURDIR}/../../lib/libc/gen \ - ${.CURDIR}/../../lib/libc/net \ - ${.CURDIR}/../../lib/libc/stdlib \ - ${.CURDIR}/../../lib/libutil +.PATH: ${SRCTOP}/lib/libc/gen \ + ${SRCTOP}/lib/libc/net \ + ${SRCTOP}/lib/libc/stdlib \ + ${SRCTOP}/lib/libutil LIB= rescue INTERNALLIB= # Don't install this library @@ -42,6 +42,6 @@ CFLAGS+= -DYP .if ${MK_HESIOD} != "no" CFLAGS+= -DHESIOD .endif -CFLAGS+= -I${.CURDIR}/../../lib/libc/include +CFLAGS+= -I${SRCTOP}/lib/libc/include .include Modified: head/rescue/rescue/Makefile ============================================================================== --- head/rescue/rescue/Makefile Sun Mar 12 18:59:05 2017 (r315173) +++ head/rescue/rescue/Makefile Sun Mar 12 18:59:09 2017 (r315174) @@ -160,16 +160,16 @@ CRUNCH_PROGS_sbin+= bsdlabel fdisk CRUNCH_ALIAS_bsdlabel= disklabel .endif -CRUNCH_SRCDIR_atm= $(.CURDIR)/../../sbin/atm/atm -CRUNCH_SRCDIR_atmconfig= $(.CURDIR)/../../sbin/atm/atmconfig -CRUNCH_SRCDIR_fore_dnld= $(.CURDIR)/../../sbin/atm/fore_dnld -CRUNCH_SRCDIR_ilmid= $(.CURDIR)/../../sbin/atm/ilmid -CRUNCH_SRCDIR_rtquery= $(.CURDIR)/../../sbin/routed/rtquery -CRUNCH_SRCDIR_ipf= $(.CURDIR)/../../sbin/ipf/ipf +CRUNCH_SRCDIR_atm= ${SRCTOP}/sbin/atm/atm +CRUNCH_SRCDIR_atmconfig= ${SRCTOP}/sbin/atm/atmconfig +CRUNCH_SRCDIR_fore_dnld= ${SRCTOP}/sbin/atm/fore_dnld +CRUNCH_SRCDIR_ilmid= ${SRCTOP}/sbin/atm/ilmid +CRUNCH_SRCDIR_rtquery= ${SRCTOP}/sbin/routed/rtquery +CRUNCH_SRCDIR_ipf= ${SRCTOP}/sbin/ipf/ipf .if ${MK_ZFS} != "no" -CRUNCH_SRCDIR_zfs= ${.CURDIR}/../../cddl/sbin/zfs -CRUNCH_SRCDIR_zpool= ${.CURDIR}/../../cddl/sbin/zpool -CRUNCH_SRCDIR_zdb= ${.CURDIR}/../../cddl/usr.sbin/zdb +CRUNCH_SRCDIR_zfs= ${SRCTOP}/cddl/sbin/zfs +CRUNCH_SRCDIR_zpool= ${SRCTOP}/cddl/sbin/zpool +CRUNCH_SRCDIR_zdb= ${SRCTOP}/cddl/usr.sbin/zdb .endif CRUNCH_ALIAS_reboot= fastboot halt fasthalt CRUNCH_ALIAS_restore= rrestore From owner-svn-src-all@freebsd.org Sun Mar 12 18:59:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1807BD08BF7; Sun, 12 Mar 2017 18:59:19 +0000 (UTC) (envelope-from imp@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 E3A4312D8; Sun, 12 Mar 2017 18:59:18 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CIxHg2001946; Sun, 12 Mar 2017 18:59:17 GMT (envelope-from imp@FreeBSD.org) Received: (from imp@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CIxGFh001931; Sun, 12 Mar 2017 18:59:16 GMT (envelope-from imp@FreeBSD.org) Message-Id: <201703121859.v2CIxGFh001931@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: imp set sender to imp@FreeBSD.org using -f From: Warner Losh Date: Sun, 12 Mar 2017 18:59:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315175 - in head/gnu: lib/csu lib/libdialog lib/libgcov lib/libgomp lib/libreadline lib/libregex lib/libssp lib/libssp/libssp_nonshared lib/libstdc++ usr.bin/cc usr.bin/cc/include usr.... X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 18:59:19 -0000 Author: imp Date: Sun Mar 12 18:59:16 2017 New Revision: 315175 URL: https://svnweb.freebsd.org/changeset/base/315175 Log: Convert gnu to using SRCTOP Prefer SRCTOP over CURDIR/../../contrib, etc. However, retain the "up one level" instances of ../ because they are really relative to this part of the tree and not a means to find the root of the tree. As such, it's better to leave them since that further the goal of being able to move directories if watned to in the future. Differential Revision: https://reviews.freebsd.org/D9932 Sponsored by: Netflix Silence On: arch@ (twice) Modified: head/gnu/lib/csu/Makefile head/gnu/lib/libdialog/Makefile head/gnu/lib/libgcov/Makefile head/gnu/lib/libgomp/Makefile head/gnu/lib/libreadline/Makefile.inc head/gnu/lib/libregex/Makefile head/gnu/lib/libssp/Makefile head/gnu/lib/libssp/libssp_nonshared/Makefile head/gnu/lib/libstdc++/Makefile head/gnu/usr.bin/cc/Makefile.inc head/gnu/usr.bin/cc/include/Makefile head/gnu/usr.bin/dialog/Makefile head/gnu/usr.bin/diff3/Makefile head/gnu/usr.bin/gperf/Makefile Modified: head/gnu/lib/csu/Makefile ============================================================================== --- head/gnu/lib/csu/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/csu/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -3,9 +3,9 @@ .include MK_SSP= no -GCCDIR= ${.CURDIR}/../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../contrib/gcclibs -CCDIR= ${.CURDIR}/../../usr.bin/cc +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs +CCDIR= ${SRCTOP}/gnu/usr.bin/cc .include "${CCDIR}/Makefile.tgt" .include "${CCDIR}/cc_tools/Makefile.hdrs" Modified: head/gnu/lib/libdialog/Makefile ============================================================================== --- head/gnu/lib/libdialog/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libdialog/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,6 +1,6 @@ # $FreeBSD$ -DIALOG= ${.CURDIR}/../../../contrib/dialog +DIALOG= ${SRCTOP}/contrib/dialog LIB= dialog SHLIB_MAJOR= 8 Modified: head/gnu/lib/libgcov/Makefile ============================================================================== --- head/gnu/lib/libgcov/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libgcov/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -5,9 +5,9 @@ MK_SSP= no .include -GCCDIR= ${.CURDIR}/../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../contrib/gcclibs -CCDIR= ${.CURDIR}/../../usr.bin/cc +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs +CCDIR= ${SRCTOP}/gnu/usr.bin/cc .include "${CCDIR}/Makefile.tgt" .include "${CCDIR}/cc_tools/Makefile.hdrs" Modified: head/gnu/lib/libgomp/Makefile ============================================================================== --- head/gnu/lib/libgomp/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libgomp/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,7 +1,7 @@ # $FreeBSD$ -GCCDIR= ${.CURDIR}/../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../contrib/gcclibs +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs SRCDIR= ${GCCLIB}/libgomp .PATH: ${SRCDIR} ${SRCDIR}/config/posix Modified: head/gnu/lib/libreadline/Makefile.inc ============================================================================== --- head/gnu/lib/libreadline/Makefile.inc Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libreadline/Makefile.inc Sun Mar 12 18:59:16 2017 (r315175) @@ -3,7 +3,7 @@ SHLIB_MAJOR=8 RL_LIBRARY_VERSION=5.2 -SRCDIR= ${.CURDIR}/../../../../contrib/libreadline +SRCDIR= ${SRCTOP}/contrib/libreadline .PATH: ${SRCDIR} ${.CURDIR}/.. LOCAL_CFLAGS= -DRL_LIBRARY_VERSION='"$(RL_LIBRARY_VERSION)"' Modified: head/gnu/lib/libregex/Makefile ============================================================================== --- head/gnu/lib/libregex/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libregex/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -3,7 +3,7 @@ LIB= gnuregex SHLIB_MAJOR= 5 -REGEXDIR= ${.CURDIR}/../../../contrib/libgnuregex +REGEXDIR= ${SRCTOP}/contrib/libgnuregex .PATH: ${REGEXDIR} SRCS= gnuregex.c Modified: head/gnu/lib/libssp/Makefile ============================================================================== --- head/gnu/lib/libssp/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libssp/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -7,8 +7,8 @@ MK_SSP= no .include -GCCDIR= ${.CURDIR}/../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../contrib/gcclibs +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs SRCDIR= ${GCCLIB}/libssp .PATH: ${SRCDIR} ${SRCDIR}/ssp Modified: head/gnu/lib/libssp/libssp_nonshared/Makefile ============================================================================== --- head/gnu/lib/libssp/libssp_nonshared/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libssp/libssp_nonshared/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,7 +1,7 @@ # $FreeBSD$ -GCCDIR= ${.CURDIR}/../../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../../contrib/gcclibs +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs .PATH: ${GCCLIB}/libssp ${GCCLIB}/libssp/ssp Modified: head/gnu/lib/libstdc++/Makefile ============================================================================== --- head/gnu/lib/libstdc++/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/lib/libstdc++/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -3,9 +3,9 @@ .include GCCVER= 4.2 -GCCDIR= ${.CURDIR}/../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../contrib/gcclibs -SRCDIR= ${.CURDIR}/../../../contrib/libstdc++ +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs +SRCDIR= ${SRCTOP}/contrib/libstdc++ SUPDIR= ${SRCDIR}/libsupc++ .PATH: ${SRCDIR}/src ${SRCDIR}/libmath ${SRCDIR}/config/io \ Modified: head/gnu/usr.bin/cc/Makefile.inc ============================================================================== --- head/gnu/usr.bin/cc/Makefile.inc Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/usr.bin/cc/Makefile.inc Sun Mar 12 18:59:16 2017 (r315175) @@ -8,8 +8,8 @@ __CC_MAKEFILE_INC__= ${MFILE} GCCVER= 4.2 -GCCDIR= ${.CURDIR}/../../../../contrib/gcc -GCCLIB= ${.CURDIR}/../../../../contrib/gcclibs +GCCDIR= ${SRCTOP}/contrib/gcc +GCCLIB= ${SRCTOP}/contrib/gcclibs .include "Makefile.tgt" Modified: head/gnu/usr.bin/cc/include/Makefile ============================================================================== --- head/gnu/usr.bin/cc/include/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/usr.bin/cc/include/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -6,7 +6,7 @@ INCSDIR=${INCLUDEDIR}/gcc/${GCCVER} -.PATH: ${GCCDIR}/config/${GCC_CPU} ${.CURDIR}/../../../../contrib/llvm/tools/clang/lib/Headers +.PATH: ${GCCDIR}/config/${GCC_CPU} ${SRCTOP}/contrib/llvm/tools/clang/lib/Headers .if ${TARGET_ARCH} == "i386" || ${TARGET_ARCH} == "amd64" INCS= ammintrin.h emmintrin.h mmintrin.h mm3dnow.h pmmintrin.h \ Modified: head/gnu/usr.bin/dialog/Makefile ============================================================================== --- head/gnu/usr.bin/dialog/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/usr.bin/dialog/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,6 +1,6 @@ # $FreeBSD$ -DIALOG= ${.CURDIR}/../../../contrib/dialog +DIALOG= ${SRCTOP}/contrib/dialog PROG= dialog LIBADD= dialog ncursesw m Modified: head/gnu/usr.bin/diff3/Makefile ============================================================================== --- head/gnu/usr.bin/diff3/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/usr.bin/diff3/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,9 +1,9 @@ # $FreeBSD$ -DIFFSRC=${.CURDIR}/../../../contrib/diff/src +DIFFSRC=${SRCTOP}/contrib/diff/src .PATH: ${DIFFSRC} \ - ${.CURDIR}/../../../contrib/diff/lib \ - ${.CURDIR}/../../../contrib/diff/man + ${SRCTOP}/contrib/diff/lib \ + ${SRCTOP}/contrib/diff/man PROG= diff3 SRCS= diff3.c version-etc.c \ @@ -12,9 +12,9 @@ SRCS= diff3.c version-etc.c \ # Important for ctype macros! CFLAGS+=-funsigned-char -CFLAGS+=-I${.CURDIR}/../../../contrib/diff/ -CFLAGS+=-I${.CURDIR}/../../../contrib/diff/src -CFLAGS+=-I${.CURDIR}/../../../contrib/diff/lib +CFLAGS+=-I${SRCTOP}/contrib/diff/ +CFLAGS+=-I${SRCTOP}/contrib/diff/src +CFLAGS+=-I${SRCTOP}/contrib/diff/lib CFLAGS+=-DHAVE_CONFIG_H CFLAGS+=-DDEFAULT_DIFF_PROGRAM=\"/usr/bin/diff\" Modified: head/gnu/usr.bin/gperf/Makefile ============================================================================== --- head/gnu/usr.bin/gperf/Makefile Sun Mar 12 18:59:09 2017 (r315174) +++ head/gnu/usr.bin/gperf/Makefile Sun Mar 12 18:59:16 2017 (r315175) @@ -1,7 +1,7 @@ # $FreeBSD$ .include -GPERFDIR= ${.CURDIR}/../../../contrib/gperf +GPERFDIR= ${SRCTOP}/contrib/gperf .PATH: ${GPERFDIR}/src ${GPERFDIR}/lib ${GPERFDIR}/doc From owner-svn-src-all@freebsd.org Sun Mar 12 19:26:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 549D4D098EA; Sun, 12 Mar 2017 19:26:26 +0000 (UTC) (envelope-from gonzo@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 1BB4C1888; Sun, 12 Mar 2017 19:26:26 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CJQP7p015188; Sun, 12 Mar 2017 19:26:25 GMT (envelope-from gonzo@FreeBSD.org) Received: (from gonzo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CJQPXS015187; Sun, 12 Mar 2017 19:26:25 GMT (envelope-from gonzo@FreeBSD.org) Message-Id: <201703121926.v2CJQPXS015187@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gonzo set sender to gonzo@FreeBSD.org using -f From: Oleksandr Tymoshenko Date: Sun, 12 Mar 2017 19:26:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315176 - head/sys/dev/evdev X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 19:26:26 -0000 Author: gonzo Date: Sun Mar 12 19:26:24 2017 New Revision: 315176 URL: https://svnweb.freebsd.org/changeset/base/315176 Log: [evdev] Do not ignore result evdev_register in UI_DEV_CREATE handler Make sure that uinput state field reflects actual state by checking evdev_register result for errors Submitted by: Vladimir Kondratiev Differential Revision: https://reviews.freebsd.org/D9320 Modified: head/sys/dev/evdev/uinput.c Modified: head/sys/dev/evdev/uinput.c ============================================================================== --- head/sys/dev/evdev/uinput.c Sun Mar 12 18:59:16 2017 (r315175) +++ head/sys/dev/evdev/uinput.c Sun Mar 12 19:26:24 2017 (r315176) @@ -501,9 +501,10 @@ uinput_ioctl_sub(struct uinput_cdev_stat evdev_set_methods(state->ucs_evdev, state, &uinput_ev_methods); evdev_set_flag(state->ucs_evdev, EVDEV_FLAG_SOFTREPEAT); - evdev_register(state->ucs_evdev); - state->ucs_state = UINPUT_RUNNING; - return (0); + ret = evdev_register(state->ucs_evdev); + if (ret == 0) + state->ucs_state = UINPUT_RUNNING; + return (ret); case UI_DEV_DESTROY: if (state->ucs_state != UINPUT_RUNNING) From owner-svn-src-all@freebsd.org Sun Mar 12 19:27:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 041A6D0999C; Sun, 12 Mar 2017 19:27:46 +0000 (UTC) (envelope-from gonzo@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 C7E831A31; Sun, 12 Mar 2017 19:27:45 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CJRibm015277; Sun, 12 Mar 2017 19:27:44 GMT (envelope-from gonzo@FreeBSD.org) Received: (from gonzo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CJRitH015276; Sun, 12 Mar 2017 19:27:44 GMT (envelope-from gonzo@FreeBSD.org) Message-Id: <201703121927.v2CJRitH015276@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gonzo set sender to gonzo@FreeBSD.org using -f From: Oleksandr Tymoshenko Date: Sun, 12 Mar 2017 19:27:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315177 - head/sys/dev/evdev X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 19:27:46 -0000 Author: gonzo Date: Sun Mar 12 19:27:44 2017 New Revision: 315177 URL: https://svnweb.freebsd.org/changeset/base/315177 Log: [evdev] Fix race condition between client's event queue reading and dropping Submitted by: Vladimir Kondratiev MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D9320 Modified: head/sys/dev/evdev/cdev.c Modified: head/sys/dev/evdev/cdev.c ============================================================================== --- head/sys/dev/evdev/cdev.c Sun Mar 12 19:26:24 2017 (r315176) +++ head/sys/dev/evdev/cdev.c Sun Mar 12 19:27:44 2017 (r315177) @@ -162,7 +162,7 @@ static int evdev_read(struct cdev *dev, struct uio *uio, int ioflag) { struct evdev_client *client; - struct input_event *event; + struct input_event event; int ret = 0; int remaining; @@ -197,13 +197,14 @@ evdev_read(struct cdev *dev, struct uio } while (ret == 0 && !EVDEV_CLIENT_EMPTYQ(client) && remaining > 0) { - event = &client->ec_buffer[client->ec_buffer_head]; + memcpy(&event, &client->ec_buffer[client->ec_buffer_head], + sizeof(struct input_event)); client->ec_buffer_head = (client->ec_buffer_head + 1) % client->ec_buffer_size; remaining--; EVDEV_CLIENT_UNLOCKQ(client); - ret = uiomove(event, sizeof(struct input_event), uio); + ret = uiomove(&event, sizeof(struct input_event), uio); EVDEV_CLIENT_LOCKQ(client); } From owner-svn-src-all@freebsd.org Sun Mar 12 19:28:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 94D2AD09A33; Sun, 12 Mar 2017 19:28:45 +0000 (UTC) (envelope-from gonzo@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 648311CD3; Sun, 12 Mar 2017 19:28:45 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CJSiE8015362; Sun, 12 Mar 2017 19:28:44 GMT (envelope-from gonzo@FreeBSD.org) Received: (from gonzo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CJSiEq015361; Sun, 12 Mar 2017 19:28:44 GMT (envelope-from gonzo@FreeBSD.org) Message-Id: <201703121928.v2CJSiEq015361@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gonzo set sender to gonzo@FreeBSD.org using -f From: Oleksandr Tymoshenko Date: Sun, 12 Mar 2017 19:28:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315178 - head/sys/dev/evdev X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 19:28:45 -0000 Author: gonzo Date: Sun Mar 12 19:28:44 2017 New Revision: 315178 URL: https://svnweb.freebsd.org/changeset/base/315178 Log: [evdev] Fix Right Alt and Keypad Enter event codes for atkbd(4) and kbdmux(4) drivers Submitted by: Vladimir Kondratiev MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D9320 Modified: head/sys/dev/evdev/evdev_utils.c Modified: head/sys/dev/evdev/evdev_utils.c ============================================================================== --- head/sys/dev/evdev/evdev_utils.c Sun Mar 12 19:27:44 2017 (r315177) +++ head/sys/dev/evdev/evdev_utils.c Sun Mar 12 19:28:44 2017 (r315178) @@ -159,7 +159,7 @@ static uint16_t evdev_at_set1_scancodes[ KEY_PREVIOUSSONG, NONE, NONE, NONE, NONE, NONE, NONE, NONE, NONE, KEY_NEXTSONG, NONE, NONE, - NONE, KEY_KPENTER, KEY_RIGHTCTRL, NONE, + KEY_KPENTER, KEY_RIGHTCTRL, NONE, NONE, /* 0x20 - 0x3f. 0xE0 prefixed */ KEY_MUTE, KEY_CALC, KEY_PLAYPAUSE, NONE, KEY_STOPCD, NONE, NONE, NONE, From owner-svn-src-all@freebsd.org Sun Mar 12 19:49:10 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7BF2AD09184; Sun, 12 Mar 2017 19:49:10 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3CB681C62; Sun, 12 Mar 2017 19:49:10 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CJn9d6023873; Sun, 12 Mar 2017 19:49:09 GMT (envelope-from jilles@FreeBSD.org) Received: (from jilles@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CJn9gZ023869; Sun, 12 Mar 2017 19:49:09 GMT (envelope-from jilles@FreeBSD.org) Message-Id: <201703121949.v2CJn9gZ023869@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jilles set sender to jilles@FreeBSD.org using -f From: Jilles Tjoelker Date: Sun, 12 Mar 2017 19:49:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315179 - stable/10/bin/sh/tests/expansion X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 19:49:10 -0000 Author: jilles Date: Sun Mar 12 19:49:08 2017 New Revision: 315179 URL: https://svnweb.freebsd.org/changeset/base/315179 Log: MFC r314637: sh: Add some already working tests that exercise new code paths Added: stable/10/bin/sh/tests/expansion/cmdsubst18.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst18.0 stable/10/bin/sh/tests/expansion/cmdsubst19.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst19.0 stable/10/bin/sh/tests/expansion/cmdsubst20.0 - copied unchanged from r314637, head/bin/sh/tests/expansion/cmdsubst20.0 Modified: stable/10/bin/sh/tests/expansion/Makefile Directory Properties: stable/10/ (props changed) Modified: stable/10/bin/sh/tests/expansion/Makefile ============================================================================== --- stable/10/bin/sh/tests/expansion/Makefile Sun Mar 12 19:28:44 2017 (r315178) +++ stable/10/bin/sh/tests/expansion/Makefile Sun Mar 12 19:49:08 2017 (r315179) @@ -38,6 +38,9 @@ FILES+= cmdsubst14.0 FILES+= cmdsubst15.0 FILES+= cmdsubst16.0 FILES+= cmdsubst17.0 +FILES+= cmdsubst18.0 +FILES+= cmdsubst19.0 +FILES+= cmdsubst20.0 FILES+= export1.0 FILES+= export2.0 FILES+= export3.0 Copied: stable/10/bin/sh/tests/expansion/cmdsubst18.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst18.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/bin/sh/tests/expansion/cmdsubst18.0 Sun Mar 12 19:49:08 2017 (r315179, copy of r314637, head/bin/sh/tests/expansion/cmdsubst18.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +x=X +unset n +r=${x+$(echo a)}${x-$(echo b)}${n+$(echo c)}${n-$(echo d)}$(echo e) +[ "$r" = aXde ] Copied: stable/10/bin/sh/tests/expansion/cmdsubst19.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst19.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/bin/sh/tests/expansion/cmdsubst19.0 Sun Mar 12 19:49:08 2017 (r315179, copy of r314637, head/bin/sh/tests/expansion/cmdsubst19.0) @@ -0,0 +1,5 @@ +# $FreeBSD$ + +b=200 c=30 d=5 x=4 +r=$(echo a)$(($(echo b) + ${x+$(echo c)} + ${x-$(echo d)}))$(echo e) +[ "$r" = a234e ] Copied: stable/10/bin/sh/tests/expansion/cmdsubst20.0 (from r314637, head/bin/sh/tests/expansion/cmdsubst20.0) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/bin/sh/tests/expansion/cmdsubst20.0 Sun Mar 12 19:49:08 2017 (r315179, copy of r314637, head/bin/sh/tests/expansion/cmdsubst20.0) @@ -0,0 +1,6 @@ +# $FreeBSD$ + +set -T +trapped='' +trap "trapped=x$trapped" USR1 +[ "x$(kill -USR1 $$)y" = xy ] && [ "$trapped" = x ] From owner-svn-src-all@freebsd.org Sun Mar 12 20:19:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ADFD8D09A0C; Sun, 12 Mar 2017 20:19:38 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6416B1CBD; Sun, 12 Mar 2017 20:19:38 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2CKJbsA036746; Sun, 12 Mar 2017 20:19:37 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2CKJb04036745; Sun, 12 Mar 2017 20:19:37 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703122019.v2CKJb04036745@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 20:19:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315180 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 20:19:38 -0000 Author: bapt Date: Sun Mar 12 20:19:37 2017 New Revision: 315180 URL: https://svnweb.freebsd.org/changeset/base/315180 Log: Readd codes that creates a tmp file for diffing stdout or devices Modified: head/usr.bin/diff/diffreg.c Modified: head/usr.bin/diff/diffreg.c ============================================================================== --- head/usr.bin/diff/diffreg.c Sun Mar 12 19:49:08 2017 (r315179) +++ head/usr.bin/diff/diffreg.c Sun Mar 12 20:19:37 2017 (r315180) @@ -194,6 +194,7 @@ struct context_vec { }; #define diff_output printf +static FILE *opentemp(const char *); static void output(char *, FILE *, char *, FILE *, int); static void check(FILE *, FILE *, int); static void range(int, int, const char *); @@ -335,7 +336,14 @@ diffreg(char *file1, char *file2, int fl if (flags & D_EMPTY1) f1 = fopen(_PATH_DEVNULL, "r"); else { - if (strcmp(file1, "-") == 0) + if (!S_ISREG(stb1.st_mode)) { + if ((f1 = opentemp(file1)) == NULL || + fstat(fileno(f1), &stb1) < 0) { + warn("%s", file1); + status |= 2; + goto closem; + } + } else if (strcmp(file1, "-") == 0) f1 = stdin; else f1 = fopen(file1, "r"); @@ -349,7 +357,14 @@ diffreg(char *file1, char *file2, int fl if (flags & D_EMPTY2) f2 = fopen(_PATH_DEVNULL, "r"); else { - if (strcmp(file2, "-") == 0) + if (!S_ISREG(stb2.st_mode)) { + if ((f2 = opentemp(file2)) == NULL || + fstat(fileno(f2), &stb2) < 0) { + warn("%s", file2); + status |= 2; + goto closem; + } + } else if (strcmp(file2, "-") == 0) f2 = stdin; else f2 = fopen(file2, "r"); @@ -539,6 +554,37 @@ files_differ(FILE *f1, FILE *f2, int fla } } +static FILE * +opentemp(const char *f) +{ + char buf[BUFSIZ], tempfile[PATH_MAX]; + ssize_t nread; + int ifd, ofd; + + if (strcmp(f, "-") == 0) + ifd = STDIN_FILENO; + else if ((ifd = open(f, O_RDONLY, 0644)) < 0) + return (NULL); + + (void)strlcpy(tempfile, _PATH_TMP "/diff.XXXXXXXX", sizeof(tempfile)); + + if ((ofd = mkstemp(tempfile)) < 0) { + close(ifd); + return (NULL); + } + unlink(tempfile); + while ((nread = read(ifd, buf, BUFSIZ)) > 0) { + if (write(ofd, buf, nread) != nread) { + close(ifd); + close(ofd); + return (NULL); + } + } + close(ifd); + lseek(ofd, (off_t)0, SEEK_SET); + return (fdopen(ofd, "r")); +} + char * splice(char *dir, char *path) { From owner-svn-src-all@freebsd.org Mon Mar 13 01:05:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5D2D9D07AE0; Mon, 13 Mar 2017 01:05:26 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A2D41D6D; Mon, 13 Mar 2017 01:05:26 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D15PUQ056345; Mon, 13 Mar 2017 01:05:25 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D15PQK056344; Mon, 13 Mar 2017 01:05:25 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130105.v2D15PQK056344@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 01:05:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315181 - head/sbin/setkey X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:05:26 -0000 Author: ngie Date: Mon Mar 13 01:05:25 2017 New Revision: 315181 URL: https://svnweb.freebsd.org/changeset/base/315181 Log: Fix CFLAGS for including netipsec headers #includes The netipsec headers are referenced via netipsec/..., not ./... . Thus, assuming that the netipsec/... is nested under ${SRCTOP}/sys/netipsec is wrong. This tripped up some individuals building ^/head on systems pre-r314812. MFC after: 1 week Reported by: Roberto Rodriguez Jr Sponsored by: Dell EMC Isilon Modified: head/sbin/setkey/Makefile Modified: head/sbin/setkey/Makefile ============================================================================== --- head/sbin/setkey/Makefile Sun Mar 12 20:19:37 2017 (r315180) +++ head/sbin/setkey/Makefile Mon Mar 13 01:05:25 2017 (r315181) @@ -46,7 +46,7 @@ CLEANFILES= y.tab.c y.tab.h key_test.o k # ipsec_strerror.c is for avoiding shlib reference to non-exported function. .PATH: ${SRCTOP}/lib/libipsec ${SRCTOP}/sys/netipsec SRCS+= pfkey.c pfkey_dump.c key_debug.c ipsec_strerror.c -CFLAGS+= -I${SRCTOP}/sys/netipsec +CFLAGS+= -I${SRCTOP}/sys SRCS+= y.tab.h y.tab.h: parse.y From owner-svn-src-all@freebsd.org Mon Mar 13 01:17:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1D149D08146; Mon, 13 Mar 2017 01:17:35 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E91976BA; Mon, 13 Mar 2017 01:17:34 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D1HX4v060814; Mon, 13 Mar 2017 01:17:33 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D1HXrk060808; Mon, 13 Mar 2017 01:17:33 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130117.v2D1HXrk060808@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 01:17: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: r315182 - in stable/11/contrib/atf: atf-c atf-c++ atf-sh doc X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:17:35 -0000 Author: ngie Date: Mon Mar 13 01:17:33 2017 New Revision: 315182 URL: https://svnweb.freebsd.org/changeset/base/315182 Log: MFC r314793,r314796,r314797,r314798,r314799,r314800,r314801,r314802,r314803,r314804,r314805: r314793: Fix ATF_TP_ADD_TCS example in atf-c-api(3) ATF_TP_ADD_TC should use `tp` as the second argument, not `tcs`, as ATF_TP_ADD_TCS uses `tp` as its first argument. Bump .Dd for the change. r314796: Fix atf-sh(3) manpage issues - Fix spelling errors (specifiying -> specifying) [1] - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314797: Fix grammar warning noted by igor Remove surrounding ellipses in e.g. section and add a comma before and after the e.g. reference. r314798: Fix out-of-order sections in atf-sh(1) - `.Op` must be used in the SYNOPSIS section, not the NAME section. - Move ATF_SHELL environment variable description up to first ENVIRONMENT section. Garbage collect the duplicate ENVIRONMENT section. Bump .Dd for the change r314799: Fix manlint issues with atf-check(1) - Use `.Bf Em`/`.Ef` instead of prefixing lines with `.Em`. The forms are equivalent with traditional roff, but unnecessarily verbose. The former form applies the .Em macro to the enclosed block. - Move EXIT_STATUS section down so the section complies with section ordering specified by mdoc(7) and enforced by manlint(1). Bump .Dd for the change r314800: Fix issues with atf-check(1) found by igor and refer to atf-check(1) - Fix typo (specifiying -> specifying) - Add atf-check(1) to SEE ALSO section for completeness. It's mentioned above, but by convention the SEE ALSO section should list all relevant references to other tools and APIs. Bump .Dd for the change r314801: Fix igor/manlint issues with atf-c(3) - Remove surrounding ellipses in i.e. section and add a comma before and after the i.e. reference [1]. - Fix typo (specifiying -> specifying) [1]. - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314802: Fix atf-c-api(3) manpage issues - Fix typo (specifiying -> specifying). - Remove surrounding ellipses in i.e. section and add a comma before and after the i.e. reference. Bump .Dd for the change r314803: Fix typos - specifiying -> specifying - manged -> managed Bump .Dd for the change r314804: Fix issues noted by igor/manlint - Fix typos [1]: -- manged -> managed -- specifiying -> specifying - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314805: Remove *-api(3) manpages removed in ATF 0.21 I overlooked the fact that these manpages had been removed upstream and replaced with their non *-api(3) equivalents. Follow upstream's lead and remove the unused manpages. Deleted: stable/11/contrib/atf/atf-c++/atf-c++-api.3 stable/11/contrib/atf/atf-c/atf-c-api.3 stable/11/contrib/atf/atf-sh/atf-sh-api.3 Modified: stable/11/contrib/atf/atf-c++/atf-c++.3 stable/11/contrib/atf/atf-c/atf-c.3 stable/11/contrib/atf/atf-sh/atf-check.1 stable/11/contrib/atf/atf-sh/atf-sh.1 stable/11/contrib/atf/atf-sh/atf-sh.3 stable/11/contrib/atf/doc/atf-test-case.4 Directory Properties: stable/11/ (props changed) Modified: stable/11/contrib/atf/atf-c++/atf-c++.3 ============================================================================== --- stable/11/contrib/atf/atf-c++/atf-c++.3 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/atf-c++/atf-c++.3 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-C++ 3 .Os .Sh NAME @@ -145,10 +145,10 @@ ATF provides a C++ programming interface C++-based test programs follow this template: .Bd -literal -offset indent extern "C" { -.Ns ... C-specific includes go here ... +\&... C-specific includes go here ... } -.Ns ... C++-specific includes go here ... +\&... C++-specific includes go here ... #include @@ -182,7 +182,7 @@ ATF_TEST_CASE_BODY(tc3) ... third test case's body ... } -.Ns ... additional test cases ... +\&... additional test cases ... ATF_INIT_TEST_CASES(tcs) { @@ -202,7 +202,7 @@ To define test cases, one can use the .Fn ATF_TEST_CASE_WITH_CLEANUP or the .Fn ATF_TEST_CASE_WITHOUT_HEAD -macros, which take a single parameter specifiying the test case's +macros, which take a single parameter specifying the test case's name. .Fn ATF_TEST_CASE , requires to define a head and a body for the test case, @@ -232,7 +232,7 @@ opening and closing brackets. Additionally, the .Fn ATF_TEST_CASE_NAME macro can be used to obtain the name of the class corresponding to a -particular test case, as the name is internally manged by the library to +particular test case, as the name is internally managed by the library to prevent clashes with other user identifiers. Similarly, the .Fn ATF_TEST_CASE_USE Modified: stable/11/contrib/atf/atf-c/atf-c.3 ============================================================================== --- stable/11/contrib/atf/atf-c/atf-c.3 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/atf-c/atf-c.3 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-C 3 .Os .Sh NAME @@ -203,7 +203,7 @@ ATF provides a C programming interface to implement test programs. C-based test programs follow this template: .Bd -literal -offset indent -.Ns ... C-specific includes go here ... +\&... C-specific includes go here ... #include @@ -237,7 +237,7 @@ ATF_TC_BODY(tc3, tc) ... third test case's body ... } -.Ns ... additional test cases ... +\&... additional test cases ... ATF_TP_ADD_TCS(tp) { @@ -259,7 +259,7 @@ To define test cases, one can use the .Fn ATF_TC_WITH_CLEANUP or the .Fn ATF_TC_WITHOUT_HEAD -macros, which take a single parameter specifiying the test case's name. +macros, which take a single parameter specifying the test case's name. .Fn ATF_TC , requires to define a head and a body for the test case, .Fn ATF_TC_WITH_CLEANUP @@ -299,7 +299,7 @@ library to do it for you. This is done by using the .Fn ATF_TP_ADD_TCS macro, which is passed the name of the object that will hold the test -cases; i.e. the test program instance. +cases, i.e., the test program instance. This name can be whatever you want as long as it is a valid variable identifier. .Pp Modified: stable/11/contrib/atf/atf-sh/atf-check.1 ============================================================================== --- stable/11/contrib/atf/atf-sh/atf-check.1 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/atf-sh/atf-check.1 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 5, 2014 +.Dd March 6, 2017 .Dt ATF-CHECK 1 .Os .Sh NAME @@ -40,10 +40,12 @@ executes a given command and analyzes its results, including exit code, stdout and stderr. .Pp -.Em Test cases must use -.Em Xr atf-sh 3 Ns ' Ns s -.Em Nm atf_check -.Em builtin function instead of calling this utility directly. +.Bf Em +Test cases must use +.Xr atf-sh 3 Ns ' Ns s +.Nm atf_check +builtin function instead of calling this utility directly. +.Ef .Pp In the first synopsis form, .Nm @@ -119,9 +121,6 @@ as a shell command line, executing it wi You should avoid using this flag if at all possible to prevent shell quoting issues. .El -.Sh EXIT STATUS -.Nm -exits 0 on success, and other (unspecified) value on failure. .Sh ENVIRONMENT .Bl -tag -width ATFXSHELLXX -compact .It Va ATF_SHELL @@ -129,6 +128,9 @@ Path to the system shell to be used when .Fl x is given to run commands. .El +.Sh EXIT STATUS +.Nm +exits 0 on success, and other (unspecified) value on failure. .Sh EXAMPLES The following are sample invocations from within a test case. Note that we use the Modified: stable/11/contrib/atf/atf-sh/atf-sh.1 ============================================================================== --- stable/11/contrib/atf/atf-sh/atf-sh.1 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/atf-sh/atf-sh.1 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,15 +22,15 @@ .\" 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. -.Dd September 27, 2014 +.Dd March 6, 2017 .Dt ATF-SH 1 .Os .Sh NAME .Nm atf-sh -.Op Fl s Ar shell .Nd interpreter for shell-based test programs .Sh SYNOPSIS .Nm +.Op Fl s Ar shell .Ar script .Sh DESCRIPTION .Nm @@ -75,6 +75,8 @@ Should not be overridden other than for Path to the system shell to be used in the generated scripts. Scripts must not rely on this variable being set to select a specific interpreter. +.It Va ATF_SHELL +Path to the system shell to be used in the generated scripts. .El .Sh EXAMPLES Scripts using @@ -98,10 +100,5 @@ option afterwards as a .Bd -literal -offset indent #! /path/to/bin/atf-sh -s/bin/bash .Ed -.Sh ENVIRONMENT -.Bl -tag -width ATFXSHELLXX -compact -.It Va ATF_SHELL -Path to the system shell to be used in the generated scripts. -.El .Sh SEE ALSO .Xr atf-sh 3 Modified: stable/11/contrib/atf/atf-sh/atf-sh.3 ============================================================================== --- stable/11/contrib/atf/atf-sh/atf-sh.3 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/atf-sh/atf-sh.3 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-SH 3 .Os .Sh NAME @@ -129,7 +129,7 @@ tc2_cleanup() { ... second test case's cleanup ... } -.Ns ... additional test cases ... +\&... additional test cases ... atf_init_test_cases() { atf_add_test_case tc1 @@ -144,7 +144,7 @@ described in .Xr atf-test-case 4 . To define test cases, one can use the .Nm atf_test_case -function, which takes a first parameter specifiying the test case's +function, which takes a first parameter specifying the test case's name and instructs the library to set things up to accept it as a valid test case. The second parameter is optional and, if provided, must be @@ -334,7 +334,7 @@ atf_init_test_cases() { This other example shows how to include a file with extra helper functions in the test program: .Bd -literal -offset indent -.Ns ... definition of test cases ... +\&... definition of test cases ... atf_init_test_cases() { . $(atf_get_srcdir)/helper_functions.sh Modified: stable/11/contrib/atf/doc/atf-test-case.4 ============================================================================== --- stable/11/contrib/atf/doc/atf-test-case.4 Mon Mar 13 01:05:25 2017 (r315181) +++ stable/11/contrib/atf/doc/atf-test-case.4 Mon Mar 13 01:17:33 2017 (r315182) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 5, 2014 +.Dd March 6, 2017 .Dt ATF-TEST-CASE 4 .Os .Sh NAME @@ -79,8 +79,8 @@ Upon termination, a test case reports a reason describing why the test reported such status. The caller must ensure that the test case really performed the task that its status describes, as the test program may be bogus and therefore providing a -misleading result (e.g. providing a result that indicates success but the -error code of the program says otherwise). +misleading result, e.g., providing a result that indicates success but the +error code of the program says otherwise. .Pp The possible exit status of a test case are one of the following: .Bl -tag -width expectedXfailureXX From owner-svn-src-all@freebsd.org Mon Mar 13 01:17:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0854AD08200; Mon, 13 Mar 2017 01:17:59 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D6ECE87F; Mon, 13 Mar 2017 01:17:58 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D1Hv04060891; Mon, 13 Mar 2017 01:17:57 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D1Hv1n060885; Mon, 13 Mar 2017 01:17:57 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130117.v2D1Hv1n060885@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 01:17:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315183 - in stable/10/contrib/atf: atf-c atf-c++ atf-sh doc X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:17:59 -0000 Author: ngie Date: Mon Mar 13 01:17:57 2017 New Revision: 315183 URL: https://svnweb.freebsd.org/changeset/base/315183 Log: MFC r314793,r314796,r314797,r314798,r314799,r314800,r314801,r314802,r314803,r314804,r314805: r314793: Fix ATF_TP_ADD_TCS example in atf-c-api(3) ATF_TP_ADD_TC should use `tp` as the second argument, not `tcs`, as ATF_TP_ADD_TCS uses `tp` as its first argument. Bump .Dd for the change. r314796: Fix atf-sh(3) manpage issues - Fix spelling errors (specifiying -> specifying) [1] - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314797: Fix grammar warning noted by igor Remove surrounding ellipses in e.g. section and add a comma before and after the e.g. reference. r314798: Fix out-of-order sections in atf-sh(1) - `.Op` must be used in the SYNOPSIS section, not the NAME section. - Move ATF_SHELL environment variable description up to first ENVIRONMENT section. Garbage collect the duplicate ENVIRONMENT section. Bump .Dd for the change r314799: Fix manlint issues with atf-check(1) - Use `.Bf Em`/`.Ef` instead of prefixing lines with `.Em`. The forms are equivalent with traditional roff, but unnecessarily verbose. The former form applies the .Em macro to the enclosed block. - Move EXIT_STATUS section down so the section complies with section ordering specified by mdoc(7) and enforced by manlint(1). Bump .Dd for the change r314800: Fix issues with atf-check(1) found by igor and refer to atf-check(1) - Fix typo (specifiying -> specifying) - Add atf-check(1) to SEE ALSO section for completeness. It's mentioned above, but by convention the SEE ALSO section should list all relevant references to other tools and APIs. Bump .Dd for the change r314801: Fix igor/manlint issues with atf-c(3) - Remove surrounding ellipses in i.e. section and add a comma before and after the i.e. reference [1]. - Fix typo (specifiying -> specifying) [1]. - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314802: Fix atf-c-api(3) manpage issues - Fix typo (specifiying -> specifying). - Remove surrounding ellipses in i.e. section and add a comma before and after the i.e. reference. Bump .Dd for the change r314803: Fix typos - specifiying -> specifying - manged -> managed Bump .Dd for the change r314804: Fix issues noted by igor/manlint - Fix typos [1]: -- manged -> managed -- specifiying -> specifying - Escape '.' at start of lines using & to tell the roff processor that the line isn't meant to be treated as a command [2]. Bump .Dd for the change r314805: Remove *-api(3) manpages removed in ATF 0.21 I overlooked the fact that these manpages had been removed upstream and replaced with their non *-api(3) equivalents. Follow upstream's lead and remove the unused manpages. Deleted: stable/10/contrib/atf/atf-c++/atf-c++-api.3 stable/10/contrib/atf/atf-c/atf-c-api.3 stable/10/contrib/atf/atf-sh/atf-sh-api.3 Modified: stable/10/contrib/atf/atf-c++/atf-c++.3 stable/10/contrib/atf/atf-c/atf-c.3 stable/10/contrib/atf/atf-sh/atf-check.1 stable/10/contrib/atf/atf-sh/atf-sh.1 stable/10/contrib/atf/atf-sh/atf-sh.3 stable/10/contrib/atf/doc/atf-test-case.4 Directory Properties: stable/10/ (props changed) Modified: stable/10/contrib/atf/atf-c++/atf-c++.3 ============================================================================== --- stable/10/contrib/atf/atf-c++/atf-c++.3 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/atf-c++/atf-c++.3 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-C++ 3 .Os .Sh NAME @@ -145,10 +145,10 @@ ATF provides a C++ programming interface C++-based test programs follow this template: .Bd -literal -offset indent extern "C" { -.Ns ... C-specific includes go here ... +\&... C-specific includes go here ... } -.Ns ... C++-specific includes go here ... +\&... C++-specific includes go here ... #include @@ -182,7 +182,7 @@ ATF_TEST_CASE_BODY(tc3) ... third test case's body ... } -.Ns ... additional test cases ... +\&... additional test cases ... ATF_INIT_TEST_CASES(tcs) { @@ -202,7 +202,7 @@ To define test cases, one can use the .Fn ATF_TEST_CASE_WITH_CLEANUP or the .Fn ATF_TEST_CASE_WITHOUT_HEAD -macros, which take a single parameter specifiying the test case's +macros, which take a single parameter specifying the test case's name. .Fn ATF_TEST_CASE , requires to define a head and a body for the test case, @@ -232,7 +232,7 @@ opening and closing brackets. Additionally, the .Fn ATF_TEST_CASE_NAME macro can be used to obtain the name of the class corresponding to a -particular test case, as the name is internally manged by the library to +particular test case, as the name is internally managed by the library to prevent clashes with other user identifiers. Similarly, the .Fn ATF_TEST_CASE_USE Modified: stable/10/contrib/atf/atf-c/atf-c.3 ============================================================================== --- stable/10/contrib/atf/atf-c/atf-c.3 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/atf-c/atf-c.3 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-C 3 .Os .Sh NAME @@ -203,7 +203,7 @@ ATF provides a C programming interface to implement test programs. C-based test programs follow this template: .Bd -literal -offset indent -.Ns ... C-specific includes go here ... +\&... C-specific includes go here ... #include @@ -237,7 +237,7 @@ ATF_TC_BODY(tc3, tc) ... third test case's body ... } -.Ns ... additional test cases ... +\&... additional test cases ... ATF_TP_ADD_TCS(tp) { @@ -259,7 +259,7 @@ To define test cases, one can use the .Fn ATF_TC_WITH_CLEANUP or the .Fn ATF_TC_WITHOUT_HEAD -macros, which take a single parameter specifiying the test case's name. +macros, which take a single parameter specifying the test case's name. .Fn ATF_TC , requires to define a head and a body for the test case, .Fn ATF_TC_WITH_CLEANUP @@ -299,7 +299,7 @@ library to do it for you. This is done by using the .Fn ATF_TP_ADD_TCS macro, which is passed the name of the object that will hold the test -cases; i.e. the test program instance. +cases, i.e., the test program instance. This name can be whatever you want as long as it is a valid variable identifier. .Pp Modified: stable/10/contrib/atf/atf-sh/atf-check.1 ============================================================================== --- stable/10/contrib/atf/atf-sh/atf-check.1 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/atf-sh/atf-check.1 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 5, 2014 +.Dd March 6, 2017 .Dt ATF-CHECK 1 .Os .Sh NAME @@ -40,10 +40,12 @@ executes a given command and analyzes its results, including exit code, stdout and stderr. .Pp -.Em Test cases must use -.Em Xr atf-sh 3 Ns ' Ns s -.Em Nm atf_check -.Em builtin function instead of calling this utility directly. +.Bf Em +Test cases must use +.Xr atf-sh 3 Ns ' Ns s +.Nm atf_check +builtin function instead of calling this utility directly. +.Ef .Pp In the first synopsis form, .Nm @@ -119,9 +121,6 @@ as a shell command line, executing it wi You should avoid using this flag if at all possible to prevent shell quoting issues. .El -.Sh EXIT STATUS -.Nm -exits 0 on success, and other (unspecified) value on failure. .Sh ENVIRONMENT .Bl -tag -width ATFXSHELLXX -compact .It Va ATF_SHELL @@ -129,6 +128,9 @@ Path to the system shell to be used when .Fl x is given to run commands. .El +.Sh EXIT STATUS +.Nm +exits 0 on success, and other (unspecified) value on failure. .Sh EXAMPLES The following are sample invocations from within a test case. Note that we use the Modified: stable/10/contrib/atf/atf-sh/atf-sh.1 ============================================================================== --- stable/10/contrib/atf/atf-sh/atf-sh.1 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/atf-sh/atf-sh.1 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,15 +22,15 @@ .\" 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. -.Dd September 27, 2014 +.Dd March 6, 2017 .Dt ATF-SH 1 .Os .Sh NAME .Nm atf-sh -.Op Fl s Ar shell .Nd interpreter for shell-based test programs .Sh SYNOPSIS .Nm +.Op Fl s Ar shell .Ar script .Sh DESCRIPTION .Nm @@ -75,6 +75,8 @@ Should not be overridden other than for Path to the system shell to be used in the generated scripts. Scripts must not rely on this variable being set to select a specific interpreter. +.It Va ATF_SHELL +Path to the system shell to be used in the generated scripts. .El .Sh EXAMPLES Scripts using @@ -98,10 +100,5 @@ option afterwards as a .Bd -literal -offset indent #! /path/to/bin/atf-sh -s/bin/bash .Ed -.Sh ENVIRONMENT -.Bl -tag -width ATFXSHELLXX -compact -.It Va ATF_SHELL -Path to the system shell to be used in the generated scripts. -.El .Sh SEE ALSO .Xr atf-sh 3 Modified: stable/10/contrib/atf/atf-sh/atf-sh.3 ============================================================================== --- stable/10/contrib/atf/atf-sh/atf-sh.3 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/atf-sh/atf-sh.3 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 13, 2014 +.Dd March 6, 2017 .Dt ATF-SH 3 .Os .Sh NAME @@ -129,7 +129,7 @@ tc2_cleanup() { ... second test case's cleanup ... } -.Ns ... additional test cases ... +\&... additional test cases ... atf_init_test_cases() { atf_add_test_case tc1 @@ -144,7 +144,7 @@ described in .Xr atf-test-case 4 . To define test cases, one can use the .Nm atf_test_case -function, which takes a first parameter specifiying the test case's +function, which takes a first parameter specifying the test case's name and instructs the library to set things up to accept it as a valid test case. The second parameter is optional and, if provided, must be @@ -334,7 +334,7 @@ atf_init_test_cases() { This other example shows how to include a file with extra helper functions in the test program: .Bd -literal -offset indent -.Ns ... definition of test cases ... +\&... definition of test cases ... atf_init_test_cases() { . $(atf_get_srcdir)/helper_functions.sh Modified: stable/10/contrib/atf/doc/atf-test-case.4 ============================================================================== --- stable/10/contrib/atf/doc/atf-test-case.4 Mon Mar 13 01:17:33 2017 (r315182) +++ stable/10/contrib/atf/doc/atf-test-case.4 Mon Mar 13 01:17:57 2017 (r315183) @@ -22,7 +22,7 @@ .\" 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. -.Dd October 5, 2014 +.Dd March 6, 2017 .Dt ATF-TEST-CASE 4 .Os .Sh NAME @@ -79,8 +79,8 @@ Upon termination, a test case reports a reason describing why the test reported such status. The caller must ensure that the test case really performed the task that its status describes, as the test program may be bogus and therefore providing a -misleading result (e.g. providing a result that indicates success but the -error code of the program says otherwise). +misleading result, e.g., providing a result that indicates success but the +error code of the program says otherwise. .Pp The possible exit status of a test case are one of the following: .Bl -tag -width expectedXfailureXX From owner-svn-src-all@freebsd.org Mon Mar 13 01:34:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EA766D08574; Mon, 13 Mar 2017 01:34:41 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AC7E2F6F; Mon, 13 Mar 2017 01:34:41 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D1YeoX068748; Mon, 13 Mar 2017 01:34:40 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D1Yerm068747; Mon, 13 Mar 2017 01:34:40 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130134.v2D1Yerm068747@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 01:34:40 +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: r315184 - stable/11/lib/libc/tests/nss X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:34:42 -0000 Author: ngie Date: Mon Mar 13 01:34:40 2017 New Revision: 315184 URL: https://svnweb.freebsd.org/changeset/base/315184 Log: MFC r314807: Move ATF_TC_WITHOUT_HEAD(getgrent) near the testcase it annotates Modified: stable/11/lib/libc/tests/nss/getgr_test.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/libc/tests/nss/getgr_test.c ============================================================================== --- stable/11/lib/libc/tests/nss/getgr_test.c Mon Mar 13 01:17:57 2017 (r315183) +++ stable/11/lib/libc/tests/nss/getgr_test.c Mon Mar 13 01:34:40 2017 (r315184) @@ -479,6 +479,7 @@ fin: #define SNAPSHOT_FILE "snapshot_grp" +ATF_TC_WITHOUT_HEAD(getgrent); ATF_TC_BODY(getgrent, tc) { @@ -530,7 +531,6 @@ ATF_TC_BODY(getgrnam_with_snapshot, tc) ATF_REQUIRE(run_tests(SNAPSHOT_FILE, TEST_GETGRNAM) == 0); } -ATF_TC_WITHOUT_HEAD(getgrent); ATF_TP_ADD_TCS(tp) { From owner-svn-src-all@freebsd.org Mon Mar 13 01:34:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0EE47D085B1; Mon, 13 Mar 2017 01:34:44 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CFC37F70; Mon, 13 Mar 2017 01:34:43 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D1Yg7d068794; Mon, 13 Mar 2017 01:34:42 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D1Yg4o068793; Mon, 13 Mar 2017 01:34:42 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130134.v2D1Yg4o068793@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 01:34:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315185 - stable/10/lib/libc/tests/nss X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:34:44 -0000 Author: ngie Date: Mon Mar 13 01:34:42 2017 New Revision: 315185 URL: https://svnweb.freebsd.org/changeset/base/315185 Log: MFC r314807: Move ATF_TC_WITHOUT_HEAD(getgrent) near the testcase it annotates Modified: stable/10/lib/libc/tests/nss/getgr_test.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libc/tests/nss/getgr_test.c ============================================================================== --- stable/10/lib/libc/tests/nss/getgr_test.c Mon Mar 13 01:34:40 2017 (r315184) +++ stable/10/lib/libc/tests/nss/getgr_test.c Mon Mar 13 01:34:42 2017 (r315185) @@ -474,6 +474,7 @@ fin: #define SNAPSHOT_FILE "snapshot_grp" +ATF_TC_WITHOUT_HEAD(getgrent); ATF_TC_BODY(getgrent, tc) { @@ -525,7 +526,6 @@ ATF_TC_BODY(getgrnam_with_snapshot, tc) ATF_REQUIRE(run_tests(SNAPSHOT_FILE, TEST_GETGRNAM) == 0); } -ATF_TC_WITHOUT_HEAD(getgrent); ATF_TP_ADD_TCS(tp) { From owner-svn-src-all@freebsd.org Mon Mar 13 01:54:43 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8213CD08CD3; Mon, 13 Mar 2017 01:54:43 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x241.google.com (mail-pg0-x241.google.com [IPv6:2607:f8b0:400e:c05::241]) (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 526101BE7; Mon, 13 Mar 2017 01:54:43 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x241.google.com with SMTP id g2so12031344pge.2; Sun, 12 Mar 2017 18:54:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=TgeqhQBZBfMGnepk7sBmRYcV9r02dFZxfnsEsc7eG50=; b=vPMkYAFPTx/X46+Rw6Oz/aglzPjBaoBZEEEhHbtNTf0517/WX/cpg0WQeChUkqnZFX p8IlE0F1vFoCX2dUGuZHAtmAMf1bKmNbXGjK0WE0WKQ3x2eqXfzKaqILdKzx6QgNDcKH RenvgmKhUnq/vynyQ5MaFELBxGe2wdTq5rmI1Nz4//26JkRg8Ymfm5ty3wh52Uy3LV8M o9WnViBrUiAK4lIyp6QaXnApmNh5/Q9LgztEquPAtvpfca0duUnf2alxwrAgt45Nbcf/ doYxIdCCpb13lVsVe/5OyDtBGcUIgvFto53atbV5f7xnNw/kykzvkegqDdcNK341bE/H oMsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=TgeqhQBZBfMGnepk7sBmRYcV9r02dFZxfnsEsc7eG50=; b=JUMKNgYQqS/TzrIDceSEeIWpRvfqXogYqZan4/YhE+0i+9feOOTq3pwE9+fN5uqROs IoiAVrmgnACWo7Rn1poXoO0Jo3V0FYj1LjqfMAIjLXSKeUHtQsnQhhDdjfHJ4wSZZpjy 5cHsCvYsS8q0aNX9X+3ydlS8CaDYotZq+l8uMWhyLxfhm8dSxOEw7ojTJOsg5+gVH6RE mTtbPTzBt/V78szEUg0GqMvtoqp0QU01O7lZWPuNU/hrXwpiTjBYrTsa1UhC7Syg/16P 4ABPnPgslNSl6ftROQp7rUQEip/HPWwM6R9XLVnkklMC2g9PAI7YKMDcTFkZKyNMNjvT IvTQ== X-Gm-Message-State: AMke39kJduWHIS2M5sKuqq6LVSs3fOPeoB4vmwYhPnNFWKhtvfer7bhQAKdGEP+SFXRVLA== X-Received: by 10.99.66.193 with SMTP id p184mr33989919pga.213.1489370082635; Sun, 12 Mar 2017 18:54:42 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id e2sm30380133pga.61.2017.03.12.18.54.41 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 12 Mar 2017 18:54:41 -0700 (PDT) Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_29B2CF87-A514-47F3-8684-DDED9DE479C5"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703120415.v2C4Fuiq037358@repo.freebsd.org> Date: Sun, 12 Mar 2017 18:54:40 -0700 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> To: Marcelo Araujo X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 01:54:43 -0000 --Apple-Mail=_29B2CF87-A514-47F3-8684-DDED9DE479C5 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On Mar 11, 2017, at 20:15, Marcelo Araujo wrote: >=20 > Author: araujo > Date: Sun Mar 12 04:15:56 2017 > New Revision: 315112 > URL: https://svnweb.freebsd.org/changeset/base/315112 >=20 > Log: > Add the capability to refresh the gpart(8) label without need a = reboot. >=20 > gpart(8) has functionality to change the label of an GPT partition. > This functionality works like it should, however, after a label = change > the /dev/gpt/ entries remain unchanged. glabel(8) status output = remains > unchanged. The change only takes effect after a reboot. >=20 > PR: 162690 > Submitted by: sub.mesa@gmail, Ben RUBSON = , ae > Reviewed by: allanjude, bapt, bcr > MFC after: 6 weeks. > Differential Revision: https://reviews.freebsd.org/D9935 Hi Marcel, This change broke GENERIC when running the eli tests with a = KASSERT: https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console = .Please fix or revert and fix later. Thanks, -Ngie --Apple-Mail=_29B2CF87-A514-47F3-8684-DDED9DE479C5 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYxfvhAAoJEPWDqSZpMIYVu/oP/1ivNdrRbOFCK01jRVoIhO7d rg4D55deIlmKRlLK1VFLO2wFjXvOL/X1Kha+jUDEHbalUBd5YbU2Q+bXeMKdXout To5My4yywPSX63th6gHjW/7KYS9PYD7i2dCuvblMHlWxgWAzWVkbih+MdiOSaTw3 JoLDSojOvVI11dfrbb1edgP/ddY1u/Jcy5TJ693Uh/XOM1wyYOQPlfg2roUrHS/J M0gZE0hSh4+KK+heBij0GqNUpry90EU1s2ZDmyHeXRF/7DEZAdx6e9Z+sXTWIxsX GTvKvtDnSIp0eeYIYnUz5kzsJlQVeP7ROuLxA5Yn1vSnc6VcFJNF/VU9nNObe2+n frsI2SJSS+DEyNTKfQyoz3cg6hM4DfGZxu7kMOv5pfhy7LA3D9hYThsu5gYbhMoO X50ZssqQAX2yE4UogFHs3MQWCqjbdi0xwGw/CRrboU8yq2hegd4IX5U7VdJgj1Oj 1IsOFsjM8IHOedLFoaBLQwPZ0P8QTgXbclMolRWmemX8J2kK6D7WgCcTBYCrX9ws CqIbKw2QTDLOux4R0yZ2iXxxlyi9lYJdvWZIOrZuEGMBnBXlYyRg1JRhV865oOyV 6soAfGx1flee02uDxJhWsiSC6LKAzTpOnuabRDH/62imfKqmvFf7HGp2HoBynvKL azJgr0muEhS0AVumUiOf =8e/p -----END PGP SIGNATURE----- --Apple-Mail=_29B2CF87-A514-47F3-8684-DDED9DE479C5-- From owner-svn-src-all@freebsd.org Mon Mar 13 02:12:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4E838D07196; Mon, 13 Mar 2017 02:12:35 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 189E0790; Mon, 13 Mar 2017 02:12:35 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D2CYJ6084696; Mon, 13 Mar 2017 02:12:34 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D2CYPP084695; Mon, 13 Mar 2017 02:12:34 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703130212.v2D2CYPP084695@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 02:12:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315186 - head/lib/libcam X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 02:12:35 -0000 Author: ngie Date: Mon Mar 13 02:12:33 2017 New Revision: 315186 URL: https://svnweb.freebsd.org/changeset/base/315186 Log: lib/libcam/cam.3: note that cam_freeccb(3) with ccb == NULL is a no-op This allows me to accurately test this scenario, and for others to rely on the behavior, instead of relying on knowledge obtained via code inspection. Wording borrowed from free(3). MFC after: 1 week Requested by: ken (D9928) Reviewed by: imp Sponsored by: Dell EMC Isilon Differential Revision: D9969 Modified: head/lib/libcam/cam.3 Modified: head/lib/libcam/cam.3 ============================================================================== --- head/lib/libcam/cam.3 Mon Mar 13 01:34:42 2017 (r315185) +++ head/lib/libcam/cam.3 Mon Mar 13 02:12:33 2017 (r315186) @@ -302,6 +302,11 @@ structure. .Fn cam_freeccb frees CCBs allocated by .Fn cam_getccb . +If +.Va ccb +is +.Dv NULL , +no action is taken. .Pp .Fn cam_path_string takes as arguments a From owner-svn-src-all@freebsd.org Mon Mar 13 04:14:05 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 523E6D0ADF0; Mon, 13 Mar 2017 04:14:05 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1DD6CA95; Mon, 13 Mar 2017 04:14:05 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D4E4AV035181; Mon, 13 Mar 2017 04:14:04 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D4E4KG035180; Mon, 13 Mar 2017 04:14:04 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703130414.v2D4E4KG035180@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 13 Mar 2017 04:14:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315187 - head/lib/libc/stdlib X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 04:14:05 -0000 Author: pfg Date: Mon Mar 13 04:14:03 2017 New Revision: 315187 URL: https://svnweb.freebsd.org/changeset/base/315187 Log: Minor libc cleanup: let calloc(3) do the multiplication. MFC after: 3 days Modified: head/lib/libc/stdlib/getenv.c Modified: head/lib/libc/stdlib/getenv.c ============================================================================== --- head/lib/libc/stdlib/getenv.c Mon Mar 13 02:12:33 2017 (r315186) +++ head/lib/libc/stdlib/getenv.c Mon Mar 13 04:14:03 2017 (r315187) @@ -342,7 +342,7 @@ __build_env(void) envVarsSize = envVarsTotal * 2; /* Create new environment. */ - envVars = calloc(1, sizeof (*envVars) * envVarsSize); + envVars = calloc(envVarsSize, sizeof(*envVars)); if (envVars == NULL) goto Failure; From owner-svn-src-all@freebsd.org Mon Mar 13 06:51:52 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2AE0FD0AEEB; Mon, 13 Mar 2017 06:51:52 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F1001F63; Mon, 13 Mar 2017 06:51:51 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D6pp0v095706; Mon, 13 Mar 2017 06:51:51 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D6po97095702; Mon, 13 Mar 2017 06:51:50 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703130651.v2D6po97095702@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Mon, 13 Mar 2017 06:51:50 +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: r315188 - in stable/11/sys/dev/mpr: . mpi X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 06:51:52 -0000 Author: mav Date: Mon Mar 13 06:51:50 2017 New Revision: 315188 URL: https://svnweb.freebsd.org/changeset/base/315188 Log: MFC r314786: Import mpr(4) driver P12 to P14 diff from vendor site. This is mostly a version bump to stay in version number sync with firmware. The only change there was cosmetic: Display degraded speed message upon receiving Active Cable Exception Event with DEGRADED reason code. Modified: stable/11/sys/dev/mpr/mpi/mpi2_ioc.h stable/11/sys/dev/mpr/mpr_sas_lsi.c stable/11/sys/dev/mpr/mpr_table.c stable/11/sys/dev/mpr/mprvar.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/mpr/mpi/mpi2_ioc.h ============================================================================== --- stable/11/sys/dev/mpr/mpi/mpi2_ioc.h Mon Mar 13 04:14:03 2017 (r315187) +++ stable/11/sys/dev/mpr/mpi/mpi2_ioc.h Mon Mar 13 06:51:50 2017 (r315188) @@ -688,7 +688,10 @@ typedef struct _MPI26_EVENT_DATA_ACTIVE_ MPI2_POINTER pMpi26EventDataActiveCableExcept_t; /* defines for ReasonCode field */ -#define MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER (0x00) +#define MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER (0x00) +#define MPI26_EVENT_ACTIVE_CABLE_PRESENT (0x01) +#define MPI26_EVENT_ACTIVE_CABLE_DEGRADED (0x02) + /* Hard Reset Received Event data */ Modified: stable/11/sys/dev/mpr/mpr_sas_lsi.c ============================================================================== --- stable/11/sys/dev/mpr/mpr_sas_lsi.c Mon Mar 13 04:14:03 2017 (r315187) +++ stable/11/sys/dev/mpr/mpr_sas_lsi.c Mon Mar 13 06:51:50 2017 (r315188) @@ -651,14 +651,26 @@ skip_fp_send: ace_event_data = (pMpi26EventDataActiveCableExcept_t)fw_event->event_data; - if (ace_event_data->ReasonCode == - MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER) { - mpr_printf(sc, "Currently an active cable with " + switch(ace_event_data->ReasonCode) { + case MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER: + { + mpr_printf(sc, "Currently a cable with " "ReceptacleID %d cannot be powered and device " "connected to this active cable will not be seen. " "This active cable requires %d mW of power.\n", ace_event_data->ReceptacleID, ace_event_data->ActiveCablePowerRequirement); + break; + } + case MPI26_EVENT_ACTIVE_CABLE_DEGRADED: + { + mpr_printf(sc, "Currently a cable with " + "ReceptacleID %d is not running at optimal speed " + "(12 Gb/s rate)\n", ace_event_data->ReceptacleID); + break; + } + default: + break; } break; } Modified: stable/11/sys/dev/mpr/mpr_table.c ============================================================================== --- stable/11/sys/dev/mpr/mpr_table.c Mon Mar 13 04:14:03 2017 (r315187) +++ stable/11/sys/dev/mpr/mpr_table.c Mon Mar 13 06:51:50 2017 (r315188) @@ -95,6 +95,12 @@ struct mpr_table_lookup mpr_event_names[ {"SasPhyCounter", 0x22}, {"GpioInterrupt", 0x23}, {"HbdPhyEvent", 0x24}, + {"SasQuiesce", 0x25}, + {"SasNotifyPrimitive", 0x26}, + {"TempThreshold", 0x27}, + {"HostMessage", 0x28}, + {"PowerPerformanceChange", 0x29}, + {"CableEvent", 0x34}, {NULL, 0}, {"Unknown Event", 0} }; Modified: stable/11/sys/dev/mpr/mprvar.h ============================================================================== --- stable/11/sys/dev/mpr/mprvar.h Mon Mar 13 04:14:03 2017 (r315187) +++ stable/11/sys/dev/mpr/mprvar.h Mon Mar 13 06:51:50 2017 (r315188) @@ -33,7 +33,7 @@ #ifndef _MPRVAR_H #define _MPRVAR_H -#define MPR_DRIVER_VERSION "13.01.00.00-fbsd" +#define MPR_DRIVER_VERSION "15.01.00.00-fbsd" #define MPR_DB_MAX_WAIT 2500 From owner-svn-src-all@freebsd.org Mon Mar 13 06:52:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5581CD0AF60; Mon, 13 Mar 2017 06:52:31 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2DAE41150; Mon, 13 Mar 2017 06:52:31 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D6qUeA099132; Mon, 13 Mar 2017 06:52:30 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D6qTap098556; Mon, 13 Mar 2017 06:52:29 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703130652.v2D6qTap098556@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Mon, 13 Mar 2017 06:52:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315189 - in stable/10/sys/dev/mpr: . mpi X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 06:52:31 -0000 Author: mav Date: Mon Mar 13 06:52:29 2017 New Revision: 315189 URL: https://svnweb.freebsd.org/changeset/base/315189 Log: MFC r314786: Import mpr(4) driver P12 to P14 diff from vendor site. This is mostly a version bump to stay in version number sync with firmware. The only change there was cosmetic: Display degraded speed message upon receiving Active Cable Exception Event with DEGRADED reason code. Modified: stable/10/sys/dev/mpr/mpi/mpi2_ioc.h stable/10/sys/dev/mpr/mpr_sas_lsi.c stable/10/sys/dev/mpr/mpr_table.c stable/10/sys/dev/mpr/mprvar.h Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/mpr/mpi/mpi2_ioc.h ============================================================================== --- stable/10/sys/dev/mpr/mpi/mpi2_ioc.h Mon Mar 13 06:51:50 2017 (r315188) +++ stable/10/sys/dev/mpr/mpi/mpi2_ioc.h Mon Mar 13 06:52:29 2017 (r315189) @@ -688,7 +688,10 @@ typedef struct _MPI26_EVENT_DATA_ACTIVE_ MPI2_POINTER pMpi26EventDataActiveCableExcept_t; /* defines for ReasonCode field */ -#define MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER (0x00) +#define MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER (0x00) +#define MPI26_EVENT_ACTIVE_CABLE_PRESENT (0x01) +#define MPI26_EVENT_ACTIVE_CABLE_DEGRADED (0x02) + /* Hard Reset Received Event data */ Modified: stable/10/sys/dev/mpr/mpr_sas_lsi.c ============================================================================== --- stable/10/sys/dev/mpr/mpr_sas_lsi.c Mon Mar 13 06:51:50 2017 (r315188) +++ stable/10/sys/dev/mpr/mpr_sas_lsi.c Mon Mar 13 06:52:29 2017 (r315189) @@ -651,14 +651,26 @@ skip_fp_send: ace_event_data = (pMpi26EventDataActiveCableExcept_t)fw_event->event_data; - if (ace_event_data->ReasonCode == - MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER) { - mpr_printf(sc, "Currently an active cable with " + switch(ace_event_data->ReasonCode) { + case MPI26_EVENT_ACTIVE_CABLE_INSUFFICIENT_POWER: + { + mpr_printf(sc, "Currently a cable with " "ReceptacleID %d cannot be powered and device " "connected to this active cable will not be seen. " "This active cable requires %d mW of power.\n", ace_event_data->ReceptacleID, ace_event_data->ActiveCablePowerRequirement); + break; + } + case MPI26_EVENT_ACTIVE_CABLE_DEGRADED: + { + mpr_printf(sc, "Currently a cable with " + "ReceptacleID %d is not running at optimal speed " + "(12 Gb/s rate)\n", ace_event_data->ReceptacleID); + break; + } + default: + break; } break; } Modified: stable/10/sys/dev/mpr/mpr_table.c ============================================================================== --- stable/10/sys/dev/mpr/mpr_table.c Mon Mar 13 06:51:50 2017 (r315188) +++ stable/10/sys/dev/mpr/mpr_table.c Mon Mar 13 06:52:29 2017 (r315189) @@ -95,6 +95,12 @@ struct mpr_table_lookup mpr_event_names[ {"SasPhyCounter", 0x22}, {"GpioInterrupt", 0x23}, {"HbdPhyEvent", 0x24}, + {"SasQuiesce", 0x25}, + {"SasNotifyPrimitive", 0x26}, + {"TempThreshold", 0x27}, + {"HostMessage", 0x28}, + {"PowerPerformanceChange", 0x29}, + {"CableEvent", 0x34}, {NULL, 0}, {"Unknown Event", 0} }; Modified: stable/10/sys/dev/mpr/mprvar.h ============================================================================== --- stable/10/sys/dev/mpr/mprvar.h Mon Mar 13 06:51:50 2017 (r315188) +++ stable/10/sys/dev/mpr/mprvar.h Mon Mar 13 06:52:29 2017 (r315189) @@ -33,7 +33,7 @@ #ifndef _MPRVAR_H #define _MPRVAR_H -#define MPR_DRIVER_VERSION "13.01.00.00-fbsd" +#define MPR_DRIVER_VERSION "15.01.00.00-fbsd" #define MPR_DB_MAX_WAIT 2500 From owner-svn-src-all@freebsd.org Mon Mar 13 07:45:17 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 21F50D0A9E7; Mon, 13 Mar 2017 07:45:17 +0000 (UTC) (envelope-from scottl@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 E59D4925; Mon, 13 Mar 2017 07:45:16 +0000 (UTC) (envelope-from scottl@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2D7jGSj019943; Mon, 13 Mar 2017 07:45:16 GMT (envelope-from scottl@FreeBSD.org) Received: (from scottl@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D7jFtL019941; Mon, 13 Mar 2017 07:45:15 GMT (envelope-from scottl@FreeBSD.org) Message-Id: <201703130745.v2D7jFtL019941@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: scottl set sender to scottl@FreeBSD.org using -f From: Scott Long Date: Mon, 13 Mar 2017 07:45:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315190 - in head: sys/dev/pci usr.sbin/pciconf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 07:45:17 -0000 Author: scottl Date: Mon Mar 13 07:45:15 2017 New Revision: 315190 URL: https://svnweb.freebsd.org/changeset/base/315190 Log: Add constants and descriptions for some new PCI class definitions Modified: head/sys/dev/pci/pcireg.h head/usr.sbin/pciconf/pciconf.c Modified: head/sys/dev/pci/pcireg.h ============================================================================== --- head/sys/dev/pci/pcireg.h Mon Mar 13 06:52:29 2017 (r315189) +++ head/sys/dev/pci/pcireg.h Mon Mar 13 07:45:15 2017 (r315190) @@ -478,6 +478,11 @@ #define PCIS_DASP_MGMT_CARD 0x20 #define PCIS_DASP_OTHER 0x80 +#define PCIC_ACCEL 0x12 +#define PCIS_ACCEL_PROCESSING 0x00 + +#define PCIC_INSTRUMENT 0x13 + #define PCIC_OTHER 0xff /* Bridge Control Values. */ Modified: head/usr.sbin/pciconf/pciconf.c ============================================================================== --- head/usr.sbin/pciconf/pciconf.c Mon Mar 13 06:52:29 2017 (r315189) +++ head/usr.sbin/pciconf/pciconf.c Mon Mar 13 07:45:15 2017 (r315190) @@ -700,6 +700,9 @@ static struct {PCIC_DASP, PCIS_DASP_PERFCNTRS, "performance counters"}, {PCIC_DASP, PCIS_DASP_COMM_SYNC, "communication synchronizer"}, {PCIC_DASP, PCIS_DASP_MGMT_CARD, "signal processing management"}, + {PCIC_ACCEL, -1, "processing accelerators"}, + {PCIC_ACCEL, PCIS_ACCEL_PROCESSING, "processing accelerators"}, + {PCIC_INSTRUMENT, -1, "non-essential instrumentation"}, {0, 0, NULL} }; From owner-svn-src-all@freebsd.org Mon Mar 13 08:04:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6CD10D0AF02; Mon, 13 Mar 2017 08:04:26 +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 3BFB51178; Mon, 13 Mar 2017 08:04:26 +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 v2D84PSl027899; Mon, 13 Mar 2017 08:04:25 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D84PPu027898; Mon, 13 Mar 2017 08:04:25 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201703130804.v2D84PPu027898@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Mon, 13 Mar 2017 08:04:25 +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: r315191 - stable/11/sys/netpfil/ipfw X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 08:04:26 -0000 Author: ae Date: Mon Mar 13 08:04:25 2017 New Revision: 315191 URL: https://svnweb.freebsd.org/changeset/base/315191 Log: MFC r314715: Reject invalid object types that can not be used with specific opcodes. When we doing reference counting of named objects in the new rule, for existing objects check that opcode references to correct object, otherwise return EINVAL. PR: 217391 Modified: stable/11/sys/netpfil/ipfw/ip_fw_sockopt.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/netpfil/ipfw/ip_fw_sockopt.c ============================================================================== --- stable/11/sys/netpfil/ipfw/ip_fw_sockopt.c Mon Mar 13 07:45:15 2017 (r315190) +++ stable/11/sys/netpfil/ipfw/ip_fw_sockopt.c Mon Mar 13 08:04:25 2017 (r315191) @@ -2662,7 +2662,14 @@ ref_opcode_object(struct ip_fw_chain *ch return (0); } - /* Found. Bump refcount and update kidx. */ + /* + * Object is already exist. + * Its subtype should match with expected value. + */ + if (ti->type != no->subtype) + return (EINVAL); + + /* Bump refcount and update kidx. */ no->refcnt++; rw->update(cmd, no->kidx); return (0); From owner-svn-src-all@freebsd.org Mon Mar 13 08:55:57 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2ACFBD0A480; Mon, 13 Mar 2017 08:55:57 +0000 (UTC) (envelope-from melounmichal@gmail.com) Received: from mail-wr0-x244.google.com (mail-wr0-x244.google.com [IPv6:2a00:1450:400c:c0c::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B202810B5; Mon, 13 Mar 2017 08:55:56 +0000 (UTC) (envelope-from melounmichal@gmail.com) Received: by mail-wr0-x244.google.com with SMTP id u108so19167535wrb.2; Mon, 13 Mar 2017 01:55:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:subject:references:to:reply-to:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=alHdyCbxJot/kQlRQ0UPqIcdCPE96C4uMUDjPstw+w4=; b=oiTOFRrJlUOko3x5xAT5kKIkgKYFdflLVbrFxQEqdrubFOuBrPwQGl3OaJcYm6K4xh bf7qNSN0i8vrx7Ia8Xz+ia3TyFcdLx/4xgyI04txYaUdkqhQBpV4Erc83W9q6F03cP7r veMLC4YNEXO9SUcpeo59cbx8qOlqS4JWVww8R7xEnCX4+4FwvbK+5TS9ebIr9lzWyEk8 VI/a++r6pxAEaOaTqTV1GR2A1NByqG4c7UY5YVAQM4xGI11FP/UhedN32qvPHfiehDGX /vOYV9WCEjfUkahRe62xJoQDy7mfu/yOvvmIybBIwlO/kgROGE8JYyv7dBSE1Ap0XbCs vgHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:subject:references:to:reply-to:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=alHdyCbxJot/kQlRQ0UPqIcdCPE96C4uMUDjPstw+w4=; b=VOcLRLH+32hwP1ORC9M3Bx9AZNGruD11YQt4rUteGHMjxq4wFwfpfNeii0M86Wd81D 46SbGMQPM17pSipNpl3yHtyRjZJWLbVS6bJGTihTyft+Q2aYO8V5btzASJAdJTFLVHWi HaEZKzXSDjq9nK9ABqYK4eOQC7kFAVKvqzj0+0oB82RmXvnwlzV5yb19rq/QrobwAiLP ZPbz31QFNq7JNC4khjMQUB6EM8wvm0u8W2n39WRq6kCbcHG6dsauVJ3sBTroMYudkW2E FWdX7J0Ns3S4Z7VWwotz3QLK8xgSWyioUKxQNCB/dfm4FzuxhaqvqFsxZryABrPFadsj 68Bg== X-Gm-Message-State: AMke39loGJGE4/adQYSiZjNEcj0WwgBm2/t4qL1Gyz/7tAq9Xmcj5zFPO8RpVwRklfA1YA== X-Received: by 10.223.141.148 with SMTP id o20mr28089511wrb.75.1489395354232; Mon, 13 Mar 2017 01:55:54 -0700 (PDT) Received: from [88.208.79.100] (halouny.humusoft.cz. [88.208.79.100]) by smtp.gmail.com with ESMTPSA id 32sm23974799wrr.64.2017.03.13.01.55.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 13 Mar 2017 01:55:53 -0700 (PDT) From: Michal Meloun X-Google-Original-From: Michal Meloun Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests References: <201703110501.v2B51UJQ045535@repo.freebsd.org> To: Baptiste Daroussin , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Reply-To: mmel@freebsd.org Message-ID: <758cfa1c-0985-f392-aa74-228f257a676c@freebsd.org> Date: Mon, 13 Mar 2017 09:55:52 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <201703110501.v2B51UJQ045535@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 08:55:57 -0000 On 11.03.2017 6:01, Baptiste Daroussin wrote: > Author: bapt > Date: Sat Mar 11 05:01:29 2017 > New Revision: 315051 > URL: https://svnweb.freebsd.org/changeset/base/315051 > > Log: > Import diff from OpenBSD and remove GNU diff > > Some of the modifications from the previous summer of code has been integrated > Modification for compatibility with GNU diff output has been added > > Main difference with OpenBSD: > Implement multiple GNU diff options: > * --ignore-file-name-case > * --no-ignore-file-name-case > * --normal > * --tabsize > * --strip-trailing-cr > Make diff -p compatible with GNU diff > Implement diff -l > Make diff -r compatible with GNU diff > > Capsicumize diffing 2 regular files > Add a simple test suite > > Approved by: AsiaBSDcon devsummit > Obtained from: OpenBSD, GSoC > Relnotes: yes > It seems that this commit breaks mergemaster (but I'm not sure): ----- diff: unable to limit rights on: /etc/casper/system.dns: Function not implemented --- Michal > Added: > head/usr.bin/diff/ > head/usr.bin/diff/Makefile (contents, props changed) > head/usr.bin/diff/TODO (contents, props changed) > head/usr.bin/diff/diff.1 (contents, props changed) > head/usr.bin/diff/diff.c (contents, props changed) > head/usr.bin/diff/diff.h (contents, props changed) > head/usr.bin/diff/diffdir.c (contents, props changed) > head/usr.bin/diff/diffreg.c (contents, props changed) > head/usr.bin/diff/tests/ > head/usr.bin/diff/tests/Makefile (contents, props changed) > head/usr.bin/diff/tests/diff.sh (contents, props changed) > head/usr.bin/diff/tests/input1.in (contents, props changed) > head/usr.bin/diff/tests/input2.in (contents, props changed) > head/usr.bin/diff/tests/input_c1.in (contents, props changed) > head/usr.bin/diff/tests/input_c2.in (contents, props changed) > head/usr.bin/diff/tests/simple.out (contents, props changed) > head/usr.bin/diff/tests/simple_b.out (contents, props changed) > head/usr.bin/diff/tests/simple_e.out (contents, props changed) > head/usr.bin/diff/tests/simple_i.out (contents, props changed) > head/usr.bin/diff/tests/simple_n.out (contents, props changed) > head/usr.bin/diff/tests/simple_p.out (contents, props changed) > head/usr.bin/diff/tests/simple_u.out (contents, props changed) > head/usr.bin/diff/tests/simple_w.out (contents, props changed) > head/usr.bin/diff/tests/unified_9999.out (contents, props changed) > head/usr.bin/diff/tests/unified_c9999.out (contents, props changed) > head/usr.bin/diff/tests/unified_p.out (contents, props changed) > head/usr.bin/diff/xmalloc.c (contents, props changed) > head/usr.bin/diff/xmalloc.h (contents, props changed) > Deleted: > head/gnu/usr.bin/diff/ > Modified: > head/ObsoleteFiles.inc > head/UPDATING > head/gnu/usr.bin/Makefile > head/usr.bin/Makefile > > Modified: head/ObsoleteFiles.inc > ============================================================================== > --- head/ObsoleteFiles.inc Sat Mar 11 04:57:52 2017 (r315050) > +++ head/ObsoleteFiles.inc Sat Mar 11 05:01:29 2017 (r315051) > @@ -38,6 +38,8 @@ > # xargs -n1 | sort | uniq -d; > # done > > +# 20170311: remove GNU diff > +OLD_FILES+=usr/share/man/man7/diff.7.gz > # 20170308: rename some tests > OLD_FILES+=usr/tests/bin/pwait/pwait > OLD_FILES+=usr/tests/usr.bin/timeout/timeout > > Modified: head/UPDATING > ============================================================================== > --- head/UPDATING Sat Mar 11 04:57:52 2017 (r315050) > +++ head/UPDATING Sat Mar 11 05:01:29 2017 (r315051) > @@ -51,6 +51,11 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 > > ****************************** SPECIAL WARNING: ****************************** > > +20170311: > + GNU diff has been replaced by a BSD licensed diff. Some features of GNU > + diff has not been implemented, if those are needed a newer version of > + GNU diff is available via the diffutils package under the gdiff name. > + > 20170302: > Clang, llvm, lldb, compiler-rt and libc++ have been upgraded to 4.0.0. > Please see the 20141231 entry below for information about prerequisites > > Modified: head/gnu/usr.bin/Makefile > ============================================================================== > --- head/gnu/usr.bin/Makefile Sat Mar 11 04:57:52 2017 (r315050) > +++ head/gnu/usr.bin/Makefile Sat Mar 11 05:01:29 2017 (r315051) > @@ -17,7 +17,7 @@ SUBDIR.${MK_GDB}+= gdb > .endif > > SUBDIR.${MK_GCC}+= cc > -SUBDIR.${MK_GNU_DIFF}+= diff diff3 > +SUBDIR.${MK_GNU_DIFF}+= diff3 > SUBDIR.${MK_GNU_GREP}+= grep > SUBDIR.${MK_GPL_DTC}+= dtc > SUBDIR.${MK_TESTS}+= tests > > Modified: head/usr.bin/Makefile > ============================================================================== > --- head/usr.bin/Makefile Sat Mar 11 04:57:52 2017 (r315050) > +++ head/usr.bin/Makefile Sat Mar 11 05:01:29 2017 (r315051) > @@ -34,6 +34,7 @@ SUBDIR= alias \ > csplit \ > ctlstat \ > cut \ > + diff \ > dirname \ > du \ > elf2aout \ > > Added: head/usr.bin/diff/Makefile > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/usr.bin/diff/Makefile Sat Mar 11 05:01:29 2017 (r315051) > @@ -0,0 +1,12 @@ > +# $FreeBSD$ > + > +.include > + > +PROG= diff > +SRCS= diff.c diffdir.c diffreg.c xmalloc.c > + > +.if ${MK_TESTS} != "no" > +SUBDIR+= tests > +.endif > + > +.include > > Added: head/usr.bin/diff/TODO > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/usr.bin/diff/TODO Sat Mar 11 05:01:29 2017 (r315051) > @@ -0,0 +1,18 @@ > +-y: > + * soc implemented it via calling sdiff directly, but some options are > + incompatible so it is fragile > + * just recommend the user to run sdiff directly and do not implement it > + * make a libsdiff and use that directly to avoid duplicating the code > + > +to be implemented: > +--suppress-common-lines: depends on -y > +--ignore-blank-lines > +--horizon-lines > +--ignore-tab-expansion > +--line-format > + > +Will probably be not implemented: > +--GTYPE-group-format > +--LTYPE-line-format > +--speed-large-file: (Do we need that? only a stub?) > +--help (We have a manpage already) > > Added: head/usr.bin/diff/diff.1 > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/usr.bin/diff/diff.1 Sat Mar 11 05:01:29 2017 (r315051) > @@ -0,0 +1,506 @@ > +.\" $OpenBSD: diff.1,v 1.47 2015/11/24 19:35:41 jmc Exp $ > +.\" > +.\" Copyright (c) 1980, 1990, 1993 > +.\" The Regents of the University of California. All rights reserved. > +.\" > +.\" Redistribution and use in source and binary forms, with or without > +.\" modification, are permitted provided that the following conditions > +.\" are met: > +.\" 1. Redistributions of source code must retain the above copyright > +.\" notice, this list of conditions and the following disclaimer. > +.\" 2. Redistributions in binary form must reproduce the above copyright > +.\" notice, this list of conditions and the following disclaimer in the > +.\" documentation and/or other materials provided with the distribution. > +.\" 3. Neither the name of the University nor the names of its contributors > +.\" may be used to endorse or promote products derived from this software > +.\" without specific prior written permission. > +.\" > +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND > +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE > +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE > +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE > +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL > +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS > +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) > +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT > +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY > +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF > +.\" SUCH DAMAGE. > +.\" > +.\" @(#)diff.1 8.1 (Berkeley) 6/30/93 > +.\" $FreeBSD$ > +.\" > +.Dd Septembr 03, 2017 > +.Dt DIFF 1 > +.Os > +.Sh NAME > +.Nm diff > +.Nd differential file and directory comparator > +.Sh SYNOPSIS > +.Nm diff > +.Op Fl abdipTtw > +.Oo > +.Fl c | e | f | > +.Fl n | q | u > +.Oc > +.Op Fl -ignore-case > +.Op Fl -no-ignore-case > +.Op Fl -normal > +.Op Fl -strip-trailing-cr > +.Op Fl -tabsize > +.Op Fl I Ar pattern > +.Op Fl L Ar label > +.Ar file1 file2 > +.Nm diff > +.Op Fl abdilpTtw > +.Op Fl I Ar pattern > +.Op Fl L Ar label > +.Op Fl -ignore-case > +.Op Fl -no-ignore-case > +.Op Fl -normal > +.Op Fl -strip-trailing-cr > +.Op Fl -tabsize > +.Fl C Ar number > +.Ar file1 file2 > +.Nm diff > +.Op Fl abdiltw > +.Op Fl I Ar pattern > +.Op Fl -ignore-case > +.Op Fl -no-ignore-case > +.Op Fl -normal > +.Op Fl -strip-trailing-cr > +.Op Fl -tabsize > +.Fl D Ar string > +.Ar file1 file2 > +.Nm diff > +.Op Fl abdilpTtw > +.Op Fl I Ar pattern > +.Op Fl L Ar label > +.Op Fl -ignore-case > +.Op Fl -no-ignore-case > +.Op Fl -normal > +.Op Fl -tabsize > +.Op Fl -strip-trailing-cr > +.Fl U Ar number > +.Ar file1 file2 > +.Nm diff > +.Op Fl abdilNPprsTtw > +.Oo > +.Fl c | e | f | > +.Fl n | q | u > +.Oc > +.Op Fl -ignore-case > +.Op Fl -no-ignore-case > +.Op Fl -normal > +.Op Fl -tabsize > +.Op Fl I Ar pattern > +.Bk -words > +.Op Fl L Ar label > +.Op Fl S Ar name > +.Op Fl X Ar file > +.Op Fl x Ar pattern > +.Ek > +.Ar dir1 dir2 > +.Sh DESCRIPTION > +The > +.Nm > +utility compares the contents of > +.Ar file1 > +and > +.Ar file2 > +and writes to the standard output the list of changes necessary to > +convert one file into the other. > +No output is produced if the files are identical. > +.Pp > +Output options (mutually exclusive): > +.Bl -tag -width Ds > +.It Fl C Ar number > +Like > +.Fl c > +but produces a diff with > +.Ar number > +lines of context. > +.It Fl c > +Produces a diff with 3 lines of context. > +With > +.Fl c > +the output format is modified slightly: > +the output begins with identification of the files involved and > +their creation dates and then each change is separated > +by a line with fifteen > +.Li * Ns 's . > +The lines removed from > +.Ar file1 > +are marked with > +.Sq \&-\ \& ; > +those added to > +.Ar file2 > +are marked > +.Sq \+\ \& . > +Lines which are changed from one file to the other are marked in > +both files with > +.Sq !\ \& . > +Changes which lie within 3 lines of each other are grouped together on > +output. > +.It Fl D Ar string > +Creates a merged version of > +.Ar file1 > +and > +.Ar file2 > +on the standard output, with C preprocessor controls included so that > +a compilation of the result without defining > +.Ar string > +is equivalent to compiling > +.Ar file1 , > +while defining > +.Ar string > +will yield > +.Ar file2 . > +.It Fl e > +Produces output in a form suitable as input for the editor utility, > +.Xr ed 1 , > +which can then be used to convert file1 into file2. > +.Pp > +Extra commands are added to the output when comparing directories with > +.Fl e , > +so that the result is a > +.Xr sh 1 > +script for converting text files which are common to the two directories > +from their state in > +.Ar dir1 > +to their state in > +.Ar dir2 . > +.It Fl f > +Identical output to that of the > +.Fl e > +flag, but in reverse order. > +It cannot be digested by > +.Xr ed 1 . > +.It Fl n > +Produces a script similar to that of > +.Fl e , > +but in the opposite order and with a count of changed lines on each > +insert or delete command. > +This is the form used by > +.Xr rcsdiff 1 . > +.It Fl q > +Just print a line when the files differ. > +Does not output a list of changes. > +.It Fl U Ar number > +Like > +.Fl u > +but produces a diff with > +.Ar number > +lines of context. > +.It Fl u > +Produces a > +.Em unified > +diff with 3 lines of context. > +A unified diff is similar to the context diff produced by the > +.Fl c > +option. > +However, unlike with > +.Fl c , > +all lines to be changed (added and/or removed) are present in > +a single section. > +.El > +.Pp > +Comparison options: > +.Bl -tag -width Ds > +.It Fl a > +Treat all files as > +.Tn ASCII > +text. > +Normally > +.Nm > +will simply print > +.Dq Binary files ... differ > +if files contain binary characters. > +Use of this option forces > +.Nm > +to produce a diff. > +.It Fl b > +Causes trailing blanks (spaces and tabs) to be ignored, and other > +strings of blanks to compare equal. > +.It Fl d > +Try very hard to produce a diff as small as possible. > +This may consume a lot of processing power and memory when processing > +large files with many changes. > +.It Fl I Ar pattern > +Ignores changes, insertions, and deletions whose lines match the > +extended regular expression > +.Ar pattern . > +Multiple > +.Fl I > +patterns may be specified. > +All lines in the change must match some pattern for the change to be > +ignored. > +See > +.Xr re_format 7 > +for more information on regular expression patterns. > +.It Fl i > +Ignores the case of letters. > +E.g., > +.Dq A > +will compare equal to > +.Dq a . > +.It Fl l > +Pass the output through > +.Xr pr 1 > +to paginate it. > +.It Fl L Ar label > +Print > +.Ar label > +instead of the first (and second, if this option is specified twice) > +file name and time in the context or unified diff header. > +.It Fl p > +With unified and context diffs, show with each change > +the first 40 characters of the last line before the context beginning > +with a letter, an underscore or a dollar sign. > +For C source code following standard layout conventions, this will > +show the prototype of the function the change applies to. > +.It Fl T > +Print a tab rather than a space before the rest of the line for the > +normal, context or unified output formats. > +This makes the alignment of tabs in the line consistent. > +.It Fl t > +Will expand tabs in output lines. > +Normal or > +.Fl c > +output adds character(s) to the front of each line which may screw up > +the indentation of the original source lines and make the output listing > +difficult to interpret. > +This option will preserve the original source's indentation. > +.It Fl w > +Is similar to > +.Fl b > +but causes whitespace (blanks and tabs) to be totally ignored. > +E.g., > +.Dq if (\ \&a == b \&) > +will compare equal to > +.Dq if(a==b) . > +.El > +.Pp > +Directory comparison options: > +.Bl -tag -width Ds > +.It Fl N > +If a file is found in only one directory, act as if it was found in the > +other directory too but was of zero size. > +.It Fl P > +If a file is found only in > +.Ar dir2 , > +act as if it was found in > +.Ar dir1 > +too but was of zero size. > +.It Fl r > +Causes application of > +.Nm > +recursively to common subdirectories encountered. > +.It Fl S Ar name > +Re-starts a directory > +.Nm > +in the middle, beginning with file > +.Ar name . > +.It Fl s > +Causes > +.Nm > +to report files which are the same, which are otherwise not mentioned. > +.It Fl X Ar file > +Exclude files and subdirectories from comparison whose basenames match > +lines in > +.Ar file . > +Multiple > +.Fl X > +options may be specified. > +.It Fl x Ar pattern > +Exclude files and subdirectories from comparison whose basenames match > +.Ar pattern . > +Patterns are matched using shell-style globbing via > +.Xr fnmatch 3 . > +Multiple > +.Fl x > +options may be specified. > +.El > +.Pp > +If both arguments are directories, > +.Nm > +sorts the contents of the directories by name, and then runs the > +regular file > +.Nm > +algorithm, producing a change list, > +on text files which are different. > +Binary files which differ, > +common subdirectories, and files which appear in only one directory > +are described as such. > +In directory mode only regular files and directories are compared. > +If a non-regular file such as a device special file or > +.Tn FIFO > +is encountered, a diagnostic message is printed. > +.Pp > +If only one of > +.Ar file1 > +and > +.Ar file2 > +is a directory, > +.Nm > +is applied to the non-directory file and the file contained in > +the directory file with a filename that is the same as the > +last component of the non-directory file. > +.Pp > +If either > +.Ar file1 > +or > +.Ar file2 > +is > +.Sq - , > +the standard input is > +used in its place. > +.Ss Output Style > +The default (without > +.Fl e , > +.Fl c , > +or > +.Fl n > +.\" -C > +options) > +output contains lines of these forms, where > +.Va XX , YY , ZZ , QQ > +are line numbers respective of file order. > +.Pp > +.Bl -tag -width "XX,YYcZZ,QQ" -compact > +.It Li XX Ns Ic a Ns Li YY > +At (the end of) line > +.Va XX > +of > +.Ar file1 , > +append the contents > +of line > +.Va YY > +of > +.Ar file2 > +to make them equal. > +.It Li XX Ns Ic a Ns Li YY,ZZ > +Same as above, but append the range of lines, > +.Va YY > +through > +.Va ZZ > +of > +.Ar file2 > +to line > +.Va XX > +of file1. > +.It Li XX Ns Ic d Ns Li YY > +At line > +.Va XX > +delete > +the line. > +The value > +.Va YY > +tells to which line the change would bring > +.Ar file1 > +in line with > +.Ar file2 . > +.It Li XX,YY Ns Ic d Ns Li ZZ > +Delete the range of lines > +.Va XX > +through > +.Va YY > +in > +.Ar file1 . > +.It Li XX Ns Ic c Ns Li YY > +Change the line > +.Va XX > +in > +.Ar file1 > +to the line > +.Va YY > +in > +.Ar file2 . > +.It Li XX,YY Ns Ic c Ns Li ZZ > +Replace the range of specified lines with the line > +.Va ZZ . > +.It Li XX,YY Ns Ic c Ns Li ZZ,QQ > +Replace the range > +.Va XX , Ns Va YY > +from > +.Ar file1 > +with the range > +.Va ZZ , Ns Va QQ > +from > +.Ar file2 . > +.El > +.Pp > +These lines resemble > +.Xr ed 1 > +subcommands to convert > +.Ar file1 > +into > +.Ar file2 . > +The line numbers before the action letters pertain to > +.Ar file1 ; > +those after pertain to > +.Ar file2 . > +Thus, by exchanging > +.Ic a > +for > +.Ic d > +and reading the line in reverse order, one can also > +determine how to convert > +.Ar file2 > +into > +.Ar file1 . > +As in > +.Xr ed 1 , > +identical > +pairs (where num1 = num2) are abbreviated as a single > +number. > +.Sh FILES > +.Bl -tag -width /tmp/diff.XXXXXXXX -compact > +.It Pa /tmp/diff. Ns Ar XXXXXXXX > +Temporary file used when comparing a device or the standard input. > +Note that the temporary file is unlinked as soon as it is created > +so it will not show up in a directory listing. > +.El > +.Sh EXIT STATUS > +The > +.Nm > +utility exits with one of the following values: > +.Pp > +.Bl -tag -width Ds -offset indent -compact > +.It 0 > +No differences were found. > +.It 1 > +Differences were found. > +.It >1 > +An error occurred. > +.El > +.Sh SEE ALSO > +.Xr cmp 1 , > +.Xr comm 1 , > +.Xr diff3 1 , > +.Xr ed 1 , > +.Xr patch 1 , > +.Xr sdiff 1 > +.Rs > +.%A James W. Hunt > +.%A M. Douglas McIlroy > +.%T "An Algorithm for Differential File Comparison" > +.%J Computing Science Technical Report > +.%Q Bell Laboratories 41 > +.%D June 1976 > +.Re > +.Sh STANDARDS > +The > +.Nm > +utility is compliant with the > +.St -p1003.1-2008 > +specification. > +.Pp > +The flags > +.Op Fl aDdIiLlNnPpqSsTtwXx > +are extensions to that specification. > +.Sh HISTORY > +A > +.Nm > +command appeared in > +.At v6 . > > Added: head/usr.bin/diff/diff.c > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/usr.bin/diff/diff.c Sat Mar 11 05:01:29 2017 (r315051) > @@ -0,0 +1,454 @@ > +/* $OpenBSD: diff.c,v 1.65 2015/12/29 19:04:46 gsoares Exp $ */ > + > +/* > + * Copyright (c) 2003 Todd C. Miller > + * > + * Permission to use, copy, modify, and distribute this software for any > + * purpose with or without fee is hereby granted, provided that the above > + * copyright notice and this permission notice appear in all copies. > + * > + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES > + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF > + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR > + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES > + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN > + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF > + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. > + * > + * Sponsored in part by the Defense Advanced Research Projects > + * Agency (DARPA) and Air Force Research Laboratory, Air Force > + * Materiel Command, USAF, under agreement number F39502-99-1-0512. > + */ > + > +#include > +__FBSDID("$FreeBSD$"); > + > +#include > + > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include "diff.h" > +#include "xmalloc.h" > + > +int lflag, Nflag, Pflag, rflag, sflag, Tflag, cflag; > +int diff_format, diff_context, status, ignore_file_case; > +int tabsize = 8; > +char *start, *ifdefname, *diffargs, *label[2], *ignore_pats; > +struct stat stb1, stb2; > +struct excludes *excludes_list; > +regex_t ignore_re; > + > +#define OPTIONS "0123456789aBbC:cdD:efhI:iL:lnNPpqrS:sTtU:uwX:x:" > +enum { > + OPT_TSIZE = CHAR_MAX + 1, > + OPT_STRIPCR, > + OPT_IGN_FN_CASE, > + OPT_NO_IGN_FN_CASE, > + OPT_NORMAL, > +}; > + > +static struct option longopts[] = { > + { "text", no_argument, 0, 'a' }, > + { "ignore-space-change", no_argument, 0, 'b' }, > + { "context", optional_argument, 0, 'C' }, > + { "ifdef", required_argument, 0, 'D' }, > + { "minimal", no_argument, 0, 'd' }, > + { "ed", no_argument, 0, 'e' }, > + { "forward-ed", no_argument, 0, 'f' }, > + { "ignore-matching-lines", required_argument, 0, 'I' }, > + { "ignore-case", no_argument, 0, 'i' }, > + { "paginate", no_argument, NULL, 'l' }, > + { "label", required_argument, 0, 'L' }, > + { "new-file", no_argument, 0, 'N' }, > + { "rcs", no_argument, 0, 'n' }, > + { "unidirectional-new-file", no_argument, 0, 'P' }, > + { "show-c-function", no_argument, 0, 'p' }, > + { "brief", no_argument, 0, 'q' }, > + { "recursive", no_argument, 0, 'r' }, > + { "report-identical-files", no_argument, 0, 's' }, > + { "starting-file", required_argument, 0, 'S' }, > + { "expand-tabs", no_argument, 0, 't' }, > + { "initial-tab", no_argument, 0, 'T' }, > + { "unified", optional_argument, 0, 'U' }, > + { "ignore-all-space", no_argument, 0, 'w' }, > + { "exclude", required_argument, 0, 'x' }, > + { "exclude-from", required_argument, 0, 'X' }, > + { "ignore-file-name-case", no_argument, NULL, OPT_IGN_FN_CASE }, > + { "no-ignore-file-name-case", no_argument, NULL, OPT_NO_IGN_FN_CASE }, > + { "normal", no_argument, NULL, OPT_NORMAL }, > + { "strip-trailing-cr", no_argument, NULL, OPT_STRIPCR }, > + { "tabsize", optional_argument, NULL, OPT_TSIZE }, > + { NULL, 0, 0, '\0'} > +}; > + > +void usage(void) __dead2; > +void push_excludes(char *); > +void push_ignore_pats(char *); > +void read_excludes_file(char *file); > +void set_argstr(char **, char **); > + > +int > +main(int argc, char **argv) > +{ > + const char *errstr = NULL; > + char *ep, **oargv; > + long l; > + int ch, dflags, lastch, gotstdin, prevoptind, newarg; > + > + oargv = argv; > + gotstdin = 0; > + dflags = 0; > + lastch = '\0'; > + prevoptind = 1; > + newarg = 1; > + diff_context = 3; > + diff_format = 0; > + while ((ch = getopt_long(argc, argv, OPTIONS, longopts, NULL)) != -1) { > + switch (ch) { > + case '0': case '1': case '2': case '3': case '4': > + case '5': case '6': case '7': case '8': case '9': > + if (newarg) > + usage(); /* disallow -[0-9]+ */ > + else if (lastch == 'c' || lastch == 'u') > + diff_context = 0; > + else if (!isdigit(lastch) || diff_context > INT_MAX / 10) > + usage(); > + diff_context = (diff_context * 10) + (ch - '0'); > + break; > + case 'a': > + dflags |= D_FORCEASCII; > + break; > + case 'b': > + dflags |= D_FOLDBLANKS; > + break; > + case 'C': > + case 'c': > + cflag = 1; > + diff_format = D_CONTEXT; > + if (optarg != NULL) { > + l = strtol(optarg, &ep, 10); > + if (*ep != '\0' || l < 0 || l >= INT_MAX) > + usage(); > + diff_context = (int)l; > + } > + break; > + case 'd': > + dflags |= D_MINIMAL; > + break; > + case 'D': > + diff_format = D_IFDEF; > + ifdefname = optarg; > + break; > + case 'e': > + diff_format = D_EDIT; > + break; > + case 'f': > + diff_format = D_REVERSE; > + break; > + case 'h': > + /* silently ignore for backwards compatibility */ > + break; > + case 'I': > + push_ignore_pats(optarg); > + break; > + case 'i': > + dflags |= D_IGNORECASE; > + break; > + case 'L': > + if (label[0] == NULL) > + label[0] = optarg; > + else if (label[1] == NULL) > + label[1] = optarg; > + else > + usage(); > + break; > + case 'l': > + lflag = 1; > + break; > + case 'N': > + Nflag = 1; > + break; > + case 'n': > + diff_format = D_NREVERSE; > + break; > + case 'p': > + if (diff_format == 0) > + diff_format = D_CONTEXT; > + dflags |= D_PROTOTYPE; > + break; > + case 'P': > + Pflag = 1; > + break; > + case 'r': > + rflag = 1; > + break; > + case 'q': > + diff_format = D_BRIEF; > + break; > + case 'S': > + start = optarg; > + break; > + case 's': > + sflag = 1; > + break; > + case 'T': > + Tflag = 1; > + break; > + case 't': > + dflags |= D_EXPANDTABS; > + break; > + case 'U': > + case 'u': > + diff_format = D_UNIFIED; > + if (optarg != NULL) { > + l = strtol(optarg, &ep, 10); > + if (*ep != '\0' || l < 0 || l >= INT_MAX) > + usage(); > + diff_context = (int)l; > + } > + break; > + case 'w': > + dflags |= D_IGNOREBLANKS; > + break; > + case 'X': > + read_excludes_file(optarg); > + break; > + case 'x': > + push_excludes(optarg); > + break; > + case OPT_IGN_FN_CASE: > + ignore_file_case = 1; > + break; > + case OPT_NO_IGN_FN_CASE: > + ignore_file_case = 0; > + break; > + case OPT_NORMAL: > + diff_format = D_NORMAL; > + break; > + case OPT_TSIZE: > + tabsize = (int) strtonum(optarg, 1, INT_MAX, &errstr); > + if (errstr) { > + warnx("Invalid argument for tabsize"); > + usage(); > + } > + break; > + case OPT_STRIPCR: > + dflags |= D_STRIPCR; > + break; > + default: > + usage(); > + break; > + } > + lastch = ch; > + newarg = optind != prevoptind; > + prevoptind = optind; > + } > + argc -= optind; > + argv += optind; > + > +#ifdef __OpenBSD__ > + if (pledge("stdio rpath tmppath", NULL) == -1) > + err(2, "pledge"); > +#endif > + > + /* > + * Do sanity checks, fill in stb1 and stb2 and call the appropriate > + * driver routine. Both drivers use the contents of stb1 and stb2. > + */ > + if (argc != 2) > + usage(); > + if (ignore_pats != NULL) { > + char buf[BUFSIZ]; > + int error; > + > + if ((error = regcomp(&ignore_re, ignore_pats, > + REG_NEWLINE | REG_EXTENDED)) != 0) { > + regerror(error, &ignore_re, buf, sizeof(buf)); > + if (*ignore_pats != '\0') > + errx(2, "%s: %s", ignore_pats, buf); > + else > + errx(2, "%s", buf); > + } > + } > + if (strcmp(argv[0], "-") == 0) { > + fstat(STDIN_FILENO, &stb1); > + gotstdin = 1; > + } else if (stat(argv[0], &stb1) != 0) > + err(2, "%s", argv[0]); > + if (strcmp(argv[1], "-") == 0) { > + fstat(STDIN_FILENO, &stb2); > + gotstdin = 1; > + } else if (stat(argv[1], &stb2) != 0) > + err(2, "%s", argv[1]); > + if (gotstdin && (S_ISDIR(stb1.st_mode) || S_ISDIR(stb2.st_mode))) > + errx(2, "can't compare - to a directory"); > + set_argstr(oargv, argv); > + if (S_ISDIR(stb1.st_mode) && S_ISDIR(stb2.st_mode)) { > + if (diff_format == D_IFDEF) > + errx(2, "-D option not supported with directories"); > + diffdir(argv[0], argv[1], dflags); > + } else { > + if (S_ISDIR(stb1.st_mode)) { > + argv[0] = splice(argv[0], argv[1]); > + if (stat(argv[0], &stb1) < 0) > + err(2, "%s", argv[0]); > + } > + if (S_ISDIR(stb2.st_mode)) { > + argv[1] = splice(argv[1], argv[0]); > + if (stat(argv[1], &stb2) < 0) > + err(2, "%s", argv[1]); > + } > + print_status(diffreg(argv[0], argv[1], dflags, 1), argv[0], > + argv[1], ""); > + } > + exit(status); > +} > + > +void > +set_argstr(char **av, char **ave) > +{ > + size_t argsize; > + char **ap; > + > + argsize = 4 + *ave - *av + 1; > + diffargs = xmalloc(argsize); > + strlcpy(diffargs, "diff", argsize); > + for (ap = av + 1; ap < ave; ap++) { > + if (strcmp(*ap, "--") != 0) { > + strlcat(diffargs, " ", argsize); > + strlcat(diffargs, *ap, argsize); > + } > + } > +} > + > +/* > + * Read in an excludes file and push each line. > + */ > +void > +read_excludes_file(char *file) > +{ > + FILE *fp; > + char *buf, *pattern; > + size_t len; > + > + if (strcmp(file, "-") == 0) > + fp = stdin; > + else if ((fp = fopen(file, "r")) == NULL) > + err(2, "%s", file); > + while ((buf = fgetln(fp, &len)) != NULL) { > + if (buf[len - 1] == '\n') > + len--; > + pattern = xmalloc(len + 1); > + memcpy(pattern, buf, len); > + pattern[len] = '\0'; > + push_excludes(pattern); > + } > + if (strcmp(file, "-") != 0) > + fclose(fp); > +} > + > +/* > + * Push a pattern onto the excludes list. > + */ > +void > +push_excludes(char *pattern) > +{ > + struct excludes *entry; > + > + entry = xmalloc(sizeof(*entry)); > + entry->pattern = pattern; > + entry->next = excludes_list; > + excludes_list = entry; > +} > + > +void > +push_ignore_pats(char *pattern) > +{ > + size_t len; > + > + if (ignore_pats == NULL) > + ignore_pats = xstrdup(pattern); > + else { > + /* old + "|" + new + NUL */ > + len = strlen(ignore_pats) + strlen(pattern) + 2; > + ignore_pats = xreallocarray(ignore_pats, 1, len); > + strlcat(ignore_pats, "|", len); > + strlcat(ignore_pats, pattern, len); > + } > +} > + > +void > +print_only(const char *path, size_t dirlen, const char *entry) > +{ > + if (dirlen > 1) > + dirlen--; > + printf("Only in %.*s: %s\n", (int)dirlen, path, entry); > +} > + > +void > +print_status(int val, char *path1, char *path2, const char *entry) > +{ > + switch (val) { > + case D_BINARY: > + printf("Binary files %s%s and %s%s differ\n", > + path1, entry, path2, entry); > + break; > + case D_DIFFER: > + if (diff_format == D_BRIEF) > > *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** > From owner-svn-src-all@freebsd.org Mon Mar 13 09:04:11 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7C2D3D0A83F; Mon, 13 Mar 2017 09:04:11 +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 4968216B3; Mon, 13 Mar 2017 09:04:11 +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 v2D94Ax7052099; Mon, 13 Mar 2017 09:04:10 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2D94AwZ052098; Mon, 13 Mar 2017 09:04:10 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201703130904.v2D94AwZ052098@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Mon, 13 Mar 2017 09:04:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315192 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 09:04:11 -0000 Author: ae Date: Mon Mar 13 09:04:10 2017 New Revision: 315192 URL: https://svnweb.freebsd.org/changeset/base/315192 Log: Ignore ifnet renaming in the bpf ifnet departure handler. PR: 213015 MFC after: 1 week Modified: head/sys/net/bpf.c Modified: head/sys/net/bpf.c ============================================================================== --- head/sys/net/bpf.c Mon Mar 13 08:04:25 2017 (r315191) +++ head/sys/net/bpf.c Mon Mar 13 09:04:10 2017 (r315192) @@ -2678,6 +2678,10 @@ bpf_ifdetach(void *arg __unused, struct struct bpf_if *bp, *bp_temp; int nmatched = 0; + /* Ignore ifnet renaming. */ + if (ifp->if_flags & IFF_RENAMING) + return; + BPF_LOCK(); /* * Find matching entries in free list. From owner-svn-src-all@freebsd.org Mon Mar 13 09:50:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 99C0AD084CE; Mon, 13 Mar 2017 09:50:33 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward1j.cmail.yandex.net (forward1j.cmail.yandex.net [IPv6:2a02:6b8:0:1630::14]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "forwards.mail.yandex.net", Issuer "Yandex CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 1DC7C1057; Mon, 13 Mar 2017 09:50:32 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from smtp3p.mail.yandex.net (smtp3p.mail.yandex.net [IPv6:2a02:6b8:0:1472:2741:0:8b6:8]) by forward1j.cmail.yandex.net (Yandex) with ESMTP id 0D66920F3B; Mon, 13 Mar 2017 12:50:20 +0300 (MSK) Received: from smtp3p.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp3p.mail.yandex.net (Yandex) with ESMTP id D3A9C132007C; Mon, 13 Mar 2017 12:50:17 +0300 (MSK) Received: by smtp3p.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id apcWlxyu0E-oGF8nYAx; Mon, 13 Mar 2017 12:50:16 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1489398616; bh=TotyL6jaACZ6LFYjSBCX4S/W8fNf0emZgZRBZjJP8Lc=; h=Subject:To:References:Cc:From:Message-ID:Date:In-Reply-To; b=TuyirByxf6MObWAu2i0KK4z3O6MA37Uelkb8j4a+LGMIke/enLJ/n7beaEATGUNmc +krN/29eq7Xf23OpqJzvB05WN8KGKm4Ew8Jtr70k6Ci9GtFkjYRypm7nIL48y+9GAI ldGIwF2T+d8sXR+EVQzyWWjziCGz6ni/o09IO0zc= Authentication-Results: smtp3p.mail.yandex.net; dkim=pass header.i=@yandex.ru X-Yandex-Suid-Status: 1 0,1 0,1 0,1 0,1 0 Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part To: "Ngie Cooper (yaneurabeya)" , Marcelo Araujo References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org From: "Andrey V. Elsukov" Openpgp: id=E6591E1B41DA1516F0C9BC0001C5EA0410C8A17A Message-ID: Date: Mon, 13 Mar 2017 12:48:45 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="2DRKml0lVsCcHoU79tMuqtKh6Vg4LXLCD" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 09:50:33 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --2DRKml0lVsCcHoU79tMuqtKh6Vg4LXLCD Content-Type: multipart/mixed; boundary="xoVIjhAVTJE7jC984WhiHPNwUaIW5KM8D"; protected-headers="v1" From: "Andrey V. Elsukov" To: "Ngie Cooper (yaneurabeya)" , Marcelo Araujo Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-ID: Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> In-Reply-To: <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> --xoVIjhAVTJE7jC984WhiHPNwUaIW5KM8D Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 13.03.2017 04:54, Ngie Cooper (yaneurabeya) wrote: > Hi Marcel, This change broke GENERIC when running the eli tests with > a KASSERT: > https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console > .Please fix or revert and fix later. Thanks, -Ngie >=20 It seems g_media_changed() should be called with M_NOWAIT flag instead of zero. --=20 WBR, Andrey V. Elsukov --xoVIjhAVTJE7jC984WhiHPNwUaIW5KM8D-- --2DRKml0lVsCcHoU79tMuqtKh6Vg4LXLCD Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEzBAEBCAAdFiEE5lkeG0HaFRbwybwAAcXqBBDIoXoFAljGav0ACgkQAcXqBBDI oXol1AgAuijf7Bxt65MsKE2zfk/0GR/gS8l4GiGiVz8ZLNvzLk495GGLHvFh4PXo QDkdFcImkMUAVvQtflXDkG/JGYdrNE7PTqsW8Z3HNS9JUAZSH+KTtxm1tyd5ANxf irGislXvus5tme0WNnp0D8PvwN2o4VOpsZ4STsrznOnkKQOg9Mj5UoP2Jgzigvzk wQ9E0/kd070qVlwYcPfcl5Rl9AexFcr4oj+Dret862UVuRKFazO+5nAYBBlFHDvb lg8C7NDyY7Ii1B9IWts0u/6AWrpUVxh+s/mxGchk533ixVM3y04gIQ/u3R/UGGUR wVPxYRnqQlk2k7gr7T3jNxmwIRvrlQ== =/50u -----END PGP SIGNATURE----- --2DRKml0lVsCcHoU79tMuqtKh6Vg4LXLCD-- From owner-svn-src-all@freebsd.org Mon Mar 13 10:41:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 01778D09A3B; Mon, 13 Mar 2017 10:41:49 +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 A8773171C; Mon, 13 Mar 2017 10:41:48 +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 v2DAflkw093678; Mon, 13 Mar 2017 10:41:47 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DAfl3o093677; Mon, 13 Mar 2017 10:41:47 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703131041.v2DAfl3o093677@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 13 Mar 2017 10:41: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: r315193 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 10:41:49 -0000 Author: kib Date: Mon Mar 13 10:41:47 2017 New Revision: 315193 URL: https://svnweb.freebsd.org/changeset/base/315193 Log: MFC r314486: When deallocating the vm object in elf_map_insert() due to vm_map_insert() failure, drop the vnode lock around the call to vm_object_deallocate(). Modified: stable/11/sys/kern/imgact_elf.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/imgact_elf.c ============================================================================== --- stable/11/sys/kern/imgact_elf.c Mon Mar 13 09:04:10 2017 (r315192) +++ stable/11/sys/kern/imgact_elf.c Mon Mar 13 10:41:47 2017 (r315193) @@ -421,13 +421,14 @@ __elfN(map_partial)(vm_map_t map, vm_obj } static int -__elfN(map_insert)(vm_map_t map, vm_object_t object, vm_ooffset_t offset, - vm_offset_t start, vm_offset_t end, vm_prot_t prot, int cow) +__elfN(map_insert)(struct image_params *imgp, vm_map_t map, vm_object_t object, + vm_ooffset_t offset, vm_offset_t start, vm_offset_t end, vm_prot_t prot, + int cow) { struct sf_buf *sf; vm_offset_t off; vm_size_t sz; - int error, rv; + int error, locked, rv; if (start != trunc_page(start)) { rv = __elfN(map_partial)(map, object, offset, start, @@ -479,8 +480,12 @@ __elfN(map_insert)(vm_map_t map, vm_obje rv = vm_map_insert(map, object, offset, start, end, prot, VM_PROT_ALL, cow); vm_map_unlock(map); - if (rv != KERN_SUCCESS) + if (rv != KERN_SUCCESS) { + locked = VOP_ISLOCKED(imgp->vp); + VOP_UNLOCK(imgp->vp, 0); vm_object_deallocate(object); + vn_lock(imgp->vp, locked | LK_RETRY); + } } return (rv); } else { @@ -537,7 +542,7 @@ __elfN(load_section)(struct image_params cow = MAP_COPY_ON_WRITE | MAP_PREFAULT | (prot & VM_PROT_WRITE ? 0 : MAP_DISABLE_COREDUMP); - rv = __elfN(map_insert)(map, + rv = __elfN(map_insert)(imgp, map, object, file_addr, /* file offset */ map_addr, /* virtual start */ @@ -567,8 +572,8 @@ __elfN(load_section)(struct image_params /* This had damn well better be true! */ if (map_len != 0) { - rv = __elfN(map_insert)(map, NULL, 0, map_addr, map_addr + - map_len, VM_PROT_ALL, 0); + rv = __elfN(map_insert)(imgp, map, NULL, 0, map_addr, + map_addr + map_len, VM_PROT_ALL, 0); if (rv != KERN_SUCCESS) { return (EINVAL); } From owner-svn-src-all@freebsd.org Mon Mar 13 10:49:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5CAA4C32102; Mon, 13 Mar 2017 10:49:38 +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 11FF01CFB; Mon, 13 Mar 2017 10:49:37 +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 v2DAnb1G095061; Mon, 13 Mar 2017 10:49:37 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DAnbcl095060; Mon, 13 Mar 2017 10:49:37 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703131049.v2DAnbcl095060@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Mon, 13 Mar 2017 10:49:37 +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: r315194 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 10:49:38 -0000 Author: kib Date: Mon Mar 13 10:49:36 2017 New Revision: 315194 URL: https://svnweb.freebsd.org/changeset/base/315194 Log: Switch from the usage of vm_map_find()/vm_map_insert() to vm_map_fixed(). MFC r314487: Use vm_map_insert() instead of vm_map_find() in elf_map_insert(). MFC r314773: Instead of direct use of vm_map_insert(), call vm_map_fixed(MAP_CHECK_EXCL). Modified: stable/11/sys/kern/imgact_elf.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/imgact_elf.c ============================================================================== --- stable/11/sys/kern/imgact_elf.c Mon Mar 13 10:41:47 2017 (r315193) +++ stable/11/sys/kern/imgact_elf.c Mon Mar 13 10:49:36 2017 (r315194) @@ -397,10 +397,8 @@ __elfN(map_partial)(vm_map_t map, vm_obj /* * Create the page if it doesn't exist yet. Ignore errors. */ - vm_map_lock(map); - vm_map_insert(map, NULL, 0, trunc_page(start), round_page(end), - VM_PROT_ALL, VM_PROT_ALL, 0); - vm_map_unlock(map); + vm_map_fixed(map, NULL, 0, trunc_page(start), round_page(end) - + trunc_page(start), VM_PROT_ALL, VM_PROT_ALL, MAP_CHECK_EXCL); /* * Find the page from the underlying object. @@ -451,9 +449,8 @@ __elfN(map_insert)(struct image_params * * The mapping is not page aligned. This means we have * to copy the data. Sigh. */ - rv = vm_map_find(map, NULL, 0, &start, end - start, 0, - VMFS_NO_SPACE, prot | VM_PROT_WRITE, VM_PROT_ALL, - 0); + rv = vm_map_fixed(map, NULL, 0, start, end - start, + prot | VM_PROT_WRITE, VM_PROT_ALL, MAP_CHECK_EXCL); if (rv != KERN_SUCCESS) return (rv); if (object == NULL) @@ -476,10 +473,9 @@ __elfN(map_insert)(struct image_params * rv = KERN_SUCCESS; } else { vm_object_reference(object); - vm_map_lock(map); - rv = vm_map_insert(map, object, offset, start, end, - prot, VM_PROT_ALL, cow); - vm_map_unlock(map); + rv = vm_map_fixed(map, object, offset, start, + end - start, prot, VM_PROT_ALL, + cow | MAP_CHECK_EXCL); if (rv != KERN_SUCCESS) { locked = VOP_ISLOCKED(imgp->vp); VOP_UNLOCK(imgp->vp, 0); From owner-svn-src-all@freebsd.org Mon Mar 13 11:09:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C5CF2C32980; Mon, 13 Mar 2017 11:09:18 +0000 (UTC) (envelope-from scottl@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 9556B10EC; Mon, 13 Mar 2017 11:09:18 +0000 (UTC) (envelope-from scottl@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DB9Hkb004886; Mon, 13 Mar 2017 11:09:17 GMT (envelope-from scottl@FreeBSD.org) Received: (from scottl@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DB9Hdv004885; Mon, 13 Mar 2017 11:09:17 GMT (envelope-from scottl@FreeBSD.org) Message-Id: <201703131109.v2DB9Hdv004885@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: scottl set sender to scottl@FreeBSD.org using -f From: Scott Long Date: Mon, 13 Mar 2017 11:09:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315195 - head/sys/geom X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 11:09:18 -0000 Author: scottl Date: Mon Mar 13 11:09:17 2017 New Revision: 315195 URL: https://svnweb.freebsd.org/changeset/base/315195 Log: Report disk flags via the sysctl tree Modified: head/sys/geom/geom_disk.c Modified: head/sys/geom/geom_disk.c ============================================================================== --- head/sys/geom/geom_disk.c Mon Mar 13 10:49:36 2017 (r315194) +++ head/sys/geom/geom_disk.c Mon Mar 13 11:09:17 2017 (r315195) @@ -77,6 +77,8 @@ static g_ioctl_t g_disk_ioctl; static g_dumpconf_t g_disk_dumpconf; static g_provgone_t g_disk_providergone; +static int g_disk_sysctl_flags(SYSCTL_HANDLER_ARGS); + static struct g_class g_disk_class = { .name = G_DISK_CLASS_NAME, .version = G_VERSION, @@ -725,6 +727,10 @@ g_disk_create(void *arg, int flag) SYSCTL_CHILDREN(sc->sysctl_tree), OID_AUTO, "led", CTLFLAG_RWTUN, sc->led, sizeof(sc->led), "LED name"); + SYSCTL_ADD_PROC(&sc->sysctl_ctx, + SYSCTL_CHILDREN(sc->sysctl_tree), OID_AUTO, "flags", + CTLTYPE_STRING | CTLFLAG_RD, dp, 0, g_disk_sysctl_flags, + "A", "Report disk flags"); } pp->private = sc; dp->d_geom = gp; @@ -995,6 +1001,30 @@ g_kern_disks(void *p, int flag __unused) } static int +g_disk_sysctl_flags(SYSCTL_HANDLER_ARGS) +{ + struct disk *dp; + struct sbuf *sb; + int error; + + sb = sbuf_new_auto(); + dp = (struct disk *)arg1; + sbuf_printf(sb, "%b", dp->d_flags, + "\20" + "\2OPEN" + "\3CANDELETE" + "\4CANFLUSHCACHE" + "\5UNMAPPEDBIO" + "\6DIRECTCOMPLETION" + "\10CANZONE"); + + sbuf_finish(sb); + error = SYSCTL_OUT(req, sbuf_data(sb), sbuf_len(sb) + 1); + sbuf_delete(sb); + return (error); +} + +static int sysctl_disks(SYSCTL_HANDLER_ARGS) { int error; From owner-svn-src-all@freebsd.org Mon Mar 13 13:25:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E2DA0D08360; Mon, 13 Mar 2017 13:25:36 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-oi0-x235.google.com (mail-oi0-x235.google.com [IPv6:2607:f8b0:4003:c06::235]) (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 A5C2B1155; Mon, 13 Mar 2017 13:25:36 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-oi0-x235.google.com with SMTP id 62so77539355oih.2; Mon, 13 Mar 2017 06:25:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:in-reply-to:references:from:date:message-id :subject:to:cc; bh=I4XB12x+TmR/4QfLMPnt9xMTNYyE0XpjHiBdMrVgUyE=; b=VeTjiDrVHeZencdg3lZ9ZZYJXkCOze7QHATwW7BQxeonROOeFLi5fu4xDJ+Sm0JLRz 7p50m63/IXNKNGCqFnytqnAatmTcQe4SSAAImV18pSkhzsej24Eb8AWKiDqyli8f6/ns FVPEcqA+spT3hJLS1mPraIwJ23FlABPlIF5M9j8s8TwimPhMjGO++WG3YdAb+8ME0TES dFy3hwS+DyuEpOq1jXnSN272T1r8YKSu8plXzMuS/8/6vU+RPXstDxUoJ3Gu+oTukZg2 0IMnPJxBXf6y0U2M0rzP68zjEHZbbzXiFTaLTuqm9BAzrFn1exfBS6NTGOIBZBmPpwT/ P3Vg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc; bh=I4XB12x+TmR/4QfLMPnt9xMTNYyE0XpjHiBdMrVgUyE=; b=WWYpgfRYUHshg0iSNF/042uLjqyWNKpMfvcOq97rfFwsu84glaCikutQ6jDYHkvS5r Sm9YQX2C0/8qmYLyOTXGOFsf22e0xSLQbyzu2in+QeOB9WTJNmVltWQzDud3nD0vyTVd vP65J7GwuXPmNBJl4Kv7eFnE9REnqQIkbTalE6l4ayV+a01OCHSYK+fCp8i9jkcHFov4 66c3w+t5PHU9C3sEidTnWzQRmKvaqFAtf7CixvAD/KacLgIYgWMd8pIexG0UyXCr5neq UlEJIhK8kOCo0DP9F31M4Xc3AeO0Y0GNJGUiwBILT0R844mx2kNtc7OsOVBiWUT5xo/v yqag== X-Gm-Message-State: AMke39mkR8E+y6LvOPAAUBlsWnDABaUsHY7gok3TAkGLoSAJLcD6jdOVO4WawmGmAei7Y9ME2gsOi5RL0K3bVw== X-Received: by 10.202.181.11 with SMTP id e11mr17237934oif.57.1489411536032; Mon, 13 Mar 2017 06:25:36 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.34.229 with HTTP; Mon, 13 Mar 2017 06:25:35 -0700 (PDT) Received: by 10.157.34.229 with HTTP; Mon, 13 Mar 2017 06:25:35 -0700 (PDT) Reply-To: araujo@freebsd.org In-Reply-To: References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> From: Marcelo Araujo Date: Mon, 13 Mar 2017 21:25:35 +0800 Message-ID: Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part To: "Andrey V. Elsukov" Cc: Garrett Cooper , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers , Marcelo Araujo Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 13:25:37 -0000 Yes, I saw it too. I'm back to my hotel in Japan, and I will commit it soon. Thank you all for the hands up. Best, On Mar 13, 2017 6:50 PM, "Andrey V. Elsukov" wrote: > On 13.03.2017 04:54, Ngie Cooper (yaneurabeya) wrote: > > Hi Marcel, This change broke GENERIC when running the eli tests with > > a KASSERT: > > https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console > > .Please fix or revert and fix later. Thanks, -Ngie > > > > It seems g_media_changed() should be called with M_NOWAIT flag instead > of zero. > > -- > WBR, Andrey V. Elsukov > > From owner-svn-src-all@freebsd.org Mon Mar 13 13:56:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26212D0A10F; Mon, 13 Mar 2017 13:56:03 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E9AB8145A; Mon, 13 Mar 2017 13:56:02 +0000 (UTC) (envelope-from araujo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DDu2or073711; Mon, 13 Mar 2017 13:56:02 GMT (envelope-from araujo@FreeBSD.org) Received: (from araujo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DDu2iB073710; Mon, 13 Mar 2017 13:56:02 GMT (envelope-from araujo@FreeBSD.org) Message-Id: <201703131356.v2DDu2iB073710@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: araujo set sender to araujo@FreeBSD.org using -f From: Marcelo Araujo Date: Mon, 13 Mar 2017 13:56:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315196 - head/sys/geom/part X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 13:56:03 -0000 Author: araujo Date: Mon Mar 13 13:56:01 2017 New Revision: 315196 URL: https://svnweb.freebsd.org/changeset/base/315196 Log: After r315112 I broke the tests with eli, instead to pass 0, I should pass M_NOWAIT to g_media_changed() that will call g_post_event() with this flag. Reported by: lwhsu, ngie and ae Modified: head/sys/geom/part/g_part.c Modified: head/sys/geom/part/g_part.c ============================================================================== --- head/sys/geom/part/g_part.c Mon Mar 13 11:09:17 2017 (r315195) +++ head/sys/geom/part/g_part.c Mon Mar 13 13:56:01 2017 (r315196) @@ -891,7 +891,7 @@ g_part_ctl_commit(struct gctl_req *req, /* Notify consumers that provider might be changed. */ if (entry->gpe_modified && ( entry->gpe_pp->acw + entry->gpe_pp->ace) == 0) - g_media_changed(entry->gpe_pp, 0); + g_media_changed(entry->gpe_pp, M_NOWAIT); entry->gpe_created = 0; entry->gpe_modified = 0; continue; From owner-svn-src-all@freebsd.org Mon Mar 13 13:59:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D9D21D0A18A; Mon, 13 Mar 2017 13:59:21 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-ot0-x233.google.com (mail-ot0-x233.google.com [IPv6:2607:f8b0:4003:c0f::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 9D42A1626; Mon, 13 Mar 2017 13:59:21 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-ot0-x233.google.com with SMTP id x37so113043485ota.2; Mon, 13 Mar 2017 06:59:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:in-reply-to:references:from:date:message-id :subject:to:cc; bh=Kn4qYl7Ra/yFpCf9MewMm+FRrXsASUSbWUEpVGk3Twk=; b=FnZRfxksyoEDitNRJSlQyBkockAbHm8H2P67mkuLB40+g7CEiRFsm6Q/ag5ZYSxlMZ mHdr1K53YFL+txhAVxLjfVFH61h8ii+/hgLFRFsuwsERUsQ7rKsvR1fo29cr6ZTTjLjS N35zKGVckg6bEmSmo14joyPAezwU7hejh3cX6U1XxSVlSkX8fUARIK1Txu8+z079he42 fWVTlT1ON6A4g3+qouUz4FizYgMq1jlQQ7J6l8wcKcfNWvD36Hyrq0j4OD0XZnQC9q1I qf+/XhtCA8b6ocCLf+tT4ASYoco5itKsuLpy/xPT2vcyfIhgKGMEWIkGTdDlncHbbjf6 boHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc; bh=Kn4qYl7Ra/yFpCf9MewMm+FRrXsASUSbWUEpVGk3Twk=; b=kAWt4q9SQRuuk7HX8xZAIe1fAh4jlDGj1H8GVjUBr2kklVOa9gw2QP2pFSY/Ujd6A/ ZHnK81QBlD+esJS9noqBFt0PZWWf+XrV2RhHCxliJI+mpBxLFCGWM6VF7ZSGVIw8Jp1S DPcn7r3NbZNLIfG81wkjXR5qt6ukRlXENc5/xJVqU71oXTJUecUHUzwwuRZF25WSTAvN TAq1EEtBvQ9tgwlvQAooo7aMRsI9zxyeMjHBKGq//MJaTyRRsyFK4ayATtvepYorHc4t dbkNVr8ipHxl9DIvJfDMNU7l4pM+DFekKaFvM3IgoI9QTfp72sBS+dnRnh0YZTXOFE1r ip8A== X-Gm-Message-State: AFeK/H1hsXC8/2sUsm4ixnzYOu5TJ0P3DESPCkVAcWl1G14Ikxp2YtPHglApAFITUsIFFPe4DavVfmXKVAqucA== X-Received: by 10.157.53.103 with SMTP id l36mr17361558ote.57.1489413561052; Mon, 13 Mar 2017 06:59:21 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.34.229 with HTTP; Mon, 13 Mar 2017 06:59:20 -0700 (PDT) Reply-To: araujo@freebsd.org In-Reply-To: References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> From: Marcelo Araujo Date: Mon, 13 Mar 2017 21:59:20 +0800 Message-ID: Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part To: "Andrey V. Elsukov" Cc: "Ngie Cooper (yaneurabeya)" , src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 13:59:22 -0000 Hi, Commit r315196 shall fix it! Let me know if it is fixed or not, or otherwise I need to revert those bits from sys/geom till I figure out a better solution. And taking the opportunity, ngie@ how I can run only that geli(8) test manually? Best, 2017-03-13 17:48 GMT+08:00 Andrey V. Elsukov : > On 13.03.2017 04:54, Ngie Cooper (yaneurabeya) wrote: > > Hi Marcel, This change broke GENERIC when running the eli tests with > > a KASSERT: > > https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console > > .Please fix or revert and fix later. Thanks, -Ngie > > > > It seems g_media_changed() should be called with M_NOWAIT flag instead > of zero. > > -- > WBR, Andrey V. Elsukov > > -- -- Marcelo Araujo (__)araujo@FreeBSD.org \\\'',)http://www.FreeBSD.org \/ \ ^ Power To Server. .\. /_) From owner-svn-src-all@freebsd.org Mon Mar 13 14:02:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CEB60D0A38A; Mon, 13 Mar 2017 14:02:44 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x244.google.com (mail-pg0-x244.google.com [IPv6:2607:f8b0:400e:c05::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 9B6391A66; Mon, 13 Mar 2017 14:02:44 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x244.google.com with SMTP id g2so13674462pge.2; Mon, 13 Mar 2017 07:02:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=KFzUZZWp+j8yGHV6oJ+0UW2MIa9KyqHRia8C/fdZXio=; b=bGA5MnF/peD7pybu9Qnelqtj6ykcGav47yYI5aSU5RIBlCd7cLiOQFg1HTJDW5lY1b 2SD4zJ9JVWndVG8qSs4IR0XMHuy4Ibs6h8WnqnvpXsHAGcrLojAUxHQ90eXMTZVzS7ZZ npWsQJhSeeyXIchYGz11rJWfzMBBTWCeNVn8dK922pUUivtsvDp7PWfwa6juXwind0Fs EDFnOtzJmBGOjo4WQIwpLBHy193csPK1k6nsHmpXxLFZ+YpoYxVrAIH350VzRkfd1Alt /BSXtnI+tPaNQmqtsUut+nT8MgylgE4usuQs8pJA/vELwhoMwyatgvERf9V/XkbiIy8k GBEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=KFzUZZWp+j8yGHV6oJ+0UW2MIa9KyqHRia8C/fdZXio=; b=oESgT6mIwoXpknQqjbbyl3XeGbHWvh9+213JtkoaM4REyoAgQduLi8onZBsz5HjcjF 29pKa/w3FsxqCO2jUVrOzrmSe7Sv2cppkuoivp51/tkZLfgJu795tijwcOK1ZB6qncS2 /nfYTrdxPFBrA4hwVd2dE/W449XiehSjI6Zd4AYBbNPzDvMjA5M3s/RtGSjyt4+FnIIg FcndDPIVYCz8UH4tdzH8hU0+JuJmmRUYJ3+5VLENAA8CZSDV6gbBacD4yZLFWork6TLw yjw4dE7fJjj1U/ZKFeTDu52iwXoV3FnPJdYTmL/R4MnR1yxt5BSqcAooi8J2pUAlJmFG Rprw== X-Gm-Message-State: AMke39lSDMJaV1oCzZLIqZlRb00srujOjQtZxATMj8e0EQIgz6G+YLRrgLr1qKqbJhEffA== X-Received: by 10.99.169.17 with SMTP id u17mr36379623pge.191.1489413763914; Mon, 13 Mar 2017 07:02:43 -0700 (PDT) Received: from [192.168.20.13] (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id 19sm33177498pfo.50.2017.03.13.07.02.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 13 Mar 2017 07:02:43 -0700 (PDT) Mime-Version: 1.0 (1.0) Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part From: Ngie Cooper X-Mailer: iPhone Mail (14D27) In-Reply-To: Date: Mon, 13 Mar 2017 07:02:42 -0700 Cc: "Andrey V. Elsukov" , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers Message-Id: <2437BADD-CD01-456E-9DAC-E0237BF5FED5@gmail.com> References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> To: araujo@freebsd.org Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 14:02:44 -0000 > On Mar 13, 2017, at 06:25, Marcelo Araujo wrote:= >=20 > Yes, I saw it too. > I'm back to my hotel in Japan, and I will commit it soon. >=20 > Thank you all for the hands up. https://img.clipartfest.com/6aa6e076f5af13d0dd77062e11c691fc_now-hands-in-ai= r-roller-coaster-fun-clipart_400-408.jpeg Thanks :}... -Ngie= From owner-svn-src-all@freebsd.org Mon Mar 13 14:05:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C0C27D0A49D; Mon, 13 Mar 2017 14:05:31 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x236.google.com (mail-pg0-x236.google.com [IPv6:2607:f8b0:400e:c05::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8C1031CDF; Mon, 13 Mar 2017 14:05:31 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x236.google.com with SMTP id g2so46687793pge.3; Mon, 13 Mar 2017 07:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=B6ZenjmIgGE7Vwr4MF86WYoYaqtMOUteZf7Bqa9cphU=; b=TRsp0KJUSBfaWH14rkuYJp2KhMKato+amprSz7B3e7J7XYu0buIcagd2/uxTDSlLLh wJP9cKqEbY+LQbo98EWeNBZ/XhArCzJY4i/PHKXTAAfcDMGZSPVkLIf6+OhdDAIwvNWI dh3VghRdk5y91Y/rH/9nluccK7iuzNWmqSBqVB3sGAyE8/+kPSUvyeMxSF1550KkDLhA H7mxnMwEhBfRRRe2FuObZmKE6Xa8TYYCFLHiSkS3uY/YEBGjyUGZ4dJLVurcFDnaOTiF yIUL9PTNei0RhsaDGZ8Rt4OvtM9bWYUYQl2wegFCY5nMRXt7886oKNTJ8qXECCP/CzR3 8+DA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=B6ZenjmIgGE7Vwr4MF86WYoYaqtMOUteZf7Bqa9cphU=; b=aHF7Rg/JJeRx4eYiI90eI0cgCICq776svcBDFJ5mRfAY+VoFbhvisyUE2V71uMmWTD VDqldjCub39rx3j+z6KLnRg+70kYFpT9bba1GolVZPiwTLrYJbdoxpbZBtL6EpWtR3v6 uAfeThdjlBgQeFGrpwx5Ul8DnRY8o9pO5DwU8Rlyo67/NI3lKBiLTCuEW5i/gqyVCnWN 9ytCB0UrTSkmmM+Qx05JF23UpBerOW+Q5jwNi2+NRxLN0EUWAQ2yCamCgC2C6GGb2La9 n865yR1n/iG25JTE8/EcExwUohQp0Ffy7f8ofkgupBrfO6bMe6xGhdRhELL7CopuknZe svPQ== X-Gm-Message-State: AMke39ld80MWh5xHZXVlW5nfgeSAdr4YdeuObXJ94SJFvfIwFSttOMkkmj8PuYEib/FqxQ== X-Received: by 10.84.216.15 with SMTP id m15mr48700492pli.22.1489413931177; Mon, 13 Mar 2017 07:05:31 -0700 (PDT) Received: from [192.168.20.13] (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id t189sm33152617pfb.81.2017.03.13.07.05.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 13 Mar 2017 07:05:30 -0700 (PDT) Mime-Version: 1.0 (1.0) Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part From: Ngie Cooper X-Mailer: iPhone Mail (14D27) In-Reply-To: Date: Mon, 13 Mar 2017 07:05:30 -0700 Cc: "Andrey V. Elsukov" , src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: <76669C12-0CD3-4549-B9D1-BD9E8114D511@gmail.com> References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> To: araujo@freebsd.org Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 14:05:31 -0000 > On Mar 13, 2017, at 06:59, Marcelo Araujo wrote:= >=20 > Hi, >=20 > Commit r315196 shall fix it! Let me know if it is fixed or not, or otherwi= se I need to revert those bits from sys/geom till I figure out a better solu= tion. >=20 > And taking the opportunity, ngie@ how I can run only that geli(8) test man= ually? sudo make -C tests/sys/geom/class/eli check ... is probably one of the easier ways. HTH! -Ngie > 2017-03-13 17:48 GMT+08:00 Andrey V. Elsukov : >> On 13.03.2017 04:54, Ngie Cooper (yaneurabeya) wrote: >> > Hi Marcel, This change broke GENERIC when running the eli tests with >> > a KASSERT: >> > https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console >> > .Please fix or revert and fix later. Thanks, -Ngie >> > >>=20 >> It seems g_media_changed() should be called with M_NOWAIT flag instead >> of zero. >>=20 >> -- >> WBR, Andrey V. Elsukov >>=20 >=20 >=20 >=20 > --=20 >=20 > --=20 > Marcelo Araujo (__) > araujo@FreeBSD.org \\\'',) > http://www.FreeBSD.org \/ \ ^ > Power To Server. .\. /_) From owner-svn-src-all@freebsd.org Mon Mar 13 15:29:43 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4B659D0AD78; Mon, 13 Mar 2017 15:29:43 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: from mail-oi0-x22a.google.com (mail-oi0-x22a.google.com [IPv6:2607:f8b0:4003:c06::22a]) (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 0BE7F1951; Mon, 13 Mar 2017 15:29:43 +0000 (UTC) (envelope-from araujobsdport@gmail.com) Received: by mail-oi0-x22a.google.com with SMTP id 126so79304405oig.3; Mon, 13 Mar 2017 08:29:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:in-reply-to:references:from:date:message-id :subject:to:cc; bh=WfTzzNW/GM7ZH6RvPk84Z9VuS3F+8UF1hbPcrPhXUeo=; b=cb3l5pCl5674egWAew9sxlG4U87kgqr0rgCUmz3Y70JuqO7i1hkF8G6I42AbCn4/qd NYmBNDIgDiknf+JKJVLnQNZIEe5Afhv2nbtr+PIa4oEHV5dF5OkQ2CLB1mPlYBTVbfLy Cnqo8D/gYm9Ks+dGWmtvhqVh7BVX/SywZTKoXnoeCJKr1Nr4V/qxqcI8bcXqayM2Me5W nm8GdnmdwPoQelipGUvcFvCUlCJaqHkDRFy7g5XcQTtnObeAiDhWltj59nea9gJ4lqxt MlDBbU41WqP8QgRWd2BIbX/4LMBsZqynIDxYsB9CgdFEx4rJsXsT+k8H5JSslVs3DJzQ zCkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc; bh=WfTzzNW/GM7ZH6RvPk84Z9VuS3F+8UF1hbPcrPhXUeo=; b=SHAboq8kRQlxmUkHVxEayCLFB62bsdCmIC10VIOL4KvT50RLx1uN/LI8ycgK6nIh/F 08AO9lzW1ylgTWPdW+y/47JyenwpYDHm55SKT5wNVBjI1C73SAqE3umTK+yTsFX71yfg qLEBq+5oKiPsOk+jvvTIfdiniMsganjGGWosL3Y34jX0M8kClEVfaQZwvsdgm4Fl+3w/ lzA3Xvs3VG4kmk1TqDBY0MKc78DmHYPvo6jzpIxtHrogpasQ/Yb6ncdDvCA1T/KeWI6p hHybSym6OzJOOH3pGPUF/HNoKRd6hCZLNLVw/Q7cEULNivbIMep0qE98dv6FdKZGjgd8 wZdQ== X-Gm-Message-State: AMke39m13ElCuv/AJRRL2ru2HZi0F2eknwCjVMz7r3mjh7FHaNjHcp9WGO+XkRFbUkejK3URDfxedyXNxduJog== X-Received: by 10.202.240.70 with SMTP id o67mr17834326oih.195.1489418982479; Mon, 13 Mar 2017 08:29:42 -0700 (PDT) MIME-Version: 1.0 Received: by 10.157.34.229 with HTTP; Mon, 13 Mar 2017 08:29:40 -0700 (PDT) Received: by 10.157.34.229 with HTTP; Mon, 13 Mar 2017 08:29:40 -0700 (PDT) Reply-To: araujo@freebsd.org In-Reply-To: <76669C12-0CD3-4549-B9D1-BD9E8114D511@gmail.com> References: <201703120415.v2C4Fuiq037358@repo.freebsd.org> <5BE954A3-C6A1-4001-BEAD-914DCD9C6714@gmail.com> <76669C12-0CD3-4549-B9D1-BD9E8114D511@gmail.com> From: Marcelo Araujo Date: Mon, 13 Mar 2017 23:29:40 +0800 Message-ID: Subject: Re: svn commit: r315112 - in head: sbin/geom/class/label sys/geom/part To: Garrett Cooper Cc: "Andrey V. Elsukov" , Marcelo Araujo , "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , src-committers Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 15:29:43 -0000 Thank you! Seems we are good now. Br, On Mar 13, 2017 11:05 PM, "Ngie Cooper" wrote: > > On Mar 13, 2017, at 06:59, Marcelo Araujo wrote: > > Hi, > > Commit r315196 shall fix it! Let me know if it is fixed or not, or > otherwise I need to revert those bits from sys/geom till I figure out a > better solution. > > And taking the opportunity, ngie@ how I can run only that geli(8) test > manually? > > > sudo make -C tests/sys/geom/class/eli check > > ... is probably one of the easier ways. > > HTH! > -Ngie > > 2017-03-13 17:48 GMT+08:00 Andrey V. Elsukov : > >> On 13.03.2017 04:54, Ngie Cooper (yaneurabeya) wrote: >> > Hi Marcel, This change broke GENERIC when running the eli tests with >> > a KASSERT: >> > https://ci.freebsd.org/job/FreeBSD-head-amd64-test/2104/console >> > .Please fix or revert and fix later. Thanks, -Ngie >> > >> >> It seems g_media_changed() should be called with M_NOWAIT flag instead >> of zero. >> >> -- >> WBR, Andrey V. Elsukov >> >> > > > -- > > -- > Marcelo Araujo (__)araujo@FreeBSD.org \\\'',)http://www.FreeBSD.org \/ \ ^ > Power To Server. .\. /_) > > From owner-svn-src-all@freebsd.org Mon Mar 13 15:34:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0E603D0A06F; Mon, 13 Mar 2017 15:34:23 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CFA001F0D; Mon, 13 Mar 2017 15:34:22 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DFYLQ7013626; Mon, 13 Mar 2017 15:34:21 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DFYLbq013625; Mon, 13 Mar 2017 15:34:21 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703131534.v2DFYLbq013625@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Mon, 13 Mar 2017 15:34:21 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315197 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 15:34:23 -0000 Author: bapt Date: Mon Mar 13 15:34:21 2017 New Revision: 315197 URL: https://svnweb.freebsd.org/changeset/base/315197 Log: Do not die if cap_rights_limit reports ENOSYS Reported by: mmel Modified: head/usr.bin/diff/diffreg.c Modified: head/usr.bin/diff/diffreg.c ============================================================================== --- head/usr.bin/diff/diffreg.c Mon Mar 13 13:56:01 2017 (r315196) +++ head/usr.bin/diff/diffreg.c Mon Mar 13 15:34:21 2017 (r315197) @@ -424,9 +424,11 @@ diffreg(char *file1, char *file2, int fl if (capsicum) { cap_rights_init(&rights_ro, CAP_READ, CAP_FSTAT, CAP_SEEK); - if (cap_rights_limit(fileno(f1), &rights_ro) < 0) + if (cap_rights_limit(fileno(f1), &rights_ro) < 0 + && errno != ENOSYS) err(2, "unable to limit rights on: %s", file1); - if (cap_rights_limit(fileno(f2), &rights_ro) < 0) + if (cap_rights_limit(fileno(f2), &rights_ro) < 0 && + errno != ENOSYS) err(2, "unable to limit rights on: %s", file2); if (fileno(f1) == STDIN_FILENO || fileno(f2) == STDIN_FILENO) { /* stding has already been limited */ From owner-svn-src-all@freebsd.org Mon Mar 13 15:41:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B4A6DD0A20C; Mon, 13 Mar 2017 15:41:00 +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 851941339; Mon, 13 Mar 2017 15:41:00 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: by freefall.freebsd.org (Postfix, from userid 1235) id CD1695C7F; Mon, 13 Mar 2017 15:40:59 +0000 (UTC) Date: Mon, 13 Mar 2017 16:40:59 +0100 From: Baptiste Daroussin To: mmel@freebsd.org Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests Message-ID: <20170313154059.ibzxffsw46uz73lk@ivaldir.net> References: <201703110501.v2B51UJQ045535@repo.freebsd.org> <758cfa1c-0985-f392-aa74-228f257a676c@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="o4igkzfpgvy7d5ao" Content-Disposition: inline In-Reply-To: <758cfa1c-0985-f392-aa74-228f257a676c@freebsd.org> User-Agent: NeoMutt/20170225 (1.8.0) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 15:41:00 -0000 --o4igkzfpgvy7d5ao Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Mar 13, 2017 at 09:55:52AM +0100, Michal Meloun wrote: >=20 >=20 > On 11.03.2017 6:01, Baptiste Daroussin wrote: > > Author: bapt > > Date: Sat Mar 11 05:01:29 2017 > > New Revision: 315051 > > URL: https://svnweb.freebsd.org/changeset/base/315051 > >=20 > > Log: > > Import diff from OpenBSD and remove GNU diff > > =20 > > Some of the modifications from the previous summer of code has been i= ntegrated > > Modification for compatibility with GNU diff output has been added > > =20 > > Main difference with OpenBSD: > > Implement multiple GNU diff options: > > * --ignore-file-name-case > > * --no-ignore-file-name-case > > * --normal > > * --tabsize > > * --strip-trailing-cr > > Make diff -p compatible with GNU diff > > Implement diff -l > > Make diff -r compatible with GNU diff > > =20 > > Capsicumize diffing 2 regular files > > Add a simple test suite > > =20 > > Approved by: AsiaBSDcon devsummit > > Obtained from: OpenBSD, GSoC > > Relnotes: yes > >=20 >=20 > It seems that this commit breaks mergemaster (but I'm not sure): >=20 > ----- > diff: unable to limit rights on: /etc/casper/system.dns: Function not > implemented > --- >=20 > Michal Yes you were right I forgot a test against systems without capsicum, but th= at makes me wonder why you do build your system without capsicum? Best regards, Bapt --o4igkzfpgvy7d5ao Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEgOTj3suS2urGXVU3Y4mL3PG3PloFAljGvW4ACgkQY4mL3PG3 Plrlvw//fYzrrHjyZ/sDad81lFVCO5J45bI5pgNOnFLzuCXy+pm4AzGFyF/RZL5Q kKtk2zKirhfuMKHMJXxl2Rt2cErkjLm43wCk4E7MAyFT50KD/i6ntGbyXFgFnAvd lXFdQ7vptJVnr12h/30SfZsr91hBXNQedIKFyaqhA/qeb8xhdeD4hux5+cI5Wmpy uLJMl4KZLNYFIbR47vfz0UhtvKvYAkcx5Rzmb6aYzsyC1tL2gYuilJLUqXCw1iSW 6rKeX9brd5OYSwrhNY0ayH69pW32j3R8B+NWXWvqCW+0+N1Lue5yEORD9ZOsGHtl 0lspexmlqrdcjGqjO5ipTYwiahcnmg6qa9cTqrzuyMHWgzJcBWdfPG7Oun2e8pt5 TriaqZoNshMCwzX5vEyqYQ96Qs9RU8hq5dkpF1reKxAp7Iq7iOLq8bFC/ao/DGDz 0gXWn0nHs7NTmNlkk8QZDM8tgeBchPRtG8vJEpL9kMDR6FjiCfmn5a1nMRJeR7pc 3x1furz2WBrUJxt1MzROR0HKJRZxTr/M30QJEIzpL3V0u/3ybzOyA+bw2EKTGAQF dg/P5K377qjt+eQENqklEZiMQ50Re8YKREWvIxYqQKfFcz2IklJFGJv+fnKpszpH OrkRGSLXVCr3yhdP0n/qLnM2CEkEPcV0DE4WLOorm/7v1xe0iJE= =zK7Y -----END PGP SIGNATURE----- --o4igkzfpgvy7d5ao-- From owner-svn-src-all@freebsd.org Mon Mar 13 16:44:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8E51FD0A521; Mon, 13 Mar 2017 16:44:08 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4C7A7153D; Mon, 13 Mar 2017 16:44:08 +0000 (UTC) (envelope-from adrian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DGi7Rb041763; Mon, 13 Mar 2017 16:44:07 GMT (envelope-from adrian@FreeBSD.org) Received: (from adrian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DGi7mY041759; Mon, 13 Mar 2017 16:44:07 GMT (envelope-from adrian@FreeBSD.org) Message-Id: <201703131644.v2DGi7mY041759@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: adrian set sender to adrian@FreeBSD.org using -f From: Adrian Chadd Date: Mon, 13 Mar 2017 16:44:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315198 - head/sys/net80211 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 16:44:08 -0000 Author: adrian Date: Mon Mar 13 16:44:06 2017 New Revision: 315198 URL: https://svnweb.freebsd.org/changeset/base/315198 Log: [net80211] begin fleshing out per-VAP WME configurations. As part of (eventual) p2p/tdls/multi-STA support, a lot of global configuration parameters (WME, ERP (slot, preamble), channel width, HT protmode, etc are the biggest offenders) should be per-VAP. For multi-BSS VAP operation they may be linked, but for p2p/TDLS operation that can be off-channel they can definitely be different (think: 2GHz STA, 5GHz p2p.) The global configuration view of these is mostly a "configure the current non-smart-firmware NIC" view. This should be split up into per-VAP state, then a global non-smart-firmware-NIC management layer to handle channel changes and such in software. This is step one in a loooong road for this. It should be a big non-functional change for everyone. * create a per-VAP WME update call. * call it if its set, and call the global callback if it isn't This still uses global WME state - it's just preparation for a future change which will make the WME state per-VAP and fall through to a shared WME configuration for hostap operation. Note: this requires a full kernel recompile; the internal net80211 ABI has changed. Reviewed by: avos Differential Revision: https://reviews.freebsd.org/D9986 Modified: head/sys/net80211/ieee80211.c head/sys/net80211/ieee80211_proto.c head/sys/net80211/ieee80211_var.h Modified: head/sys/net80211/ieee80211.c ============================================================================== --- head/sys/net80211/ieee80211.c Mon Mar 13 15:34:21 2017 (r315197) +++ head/sys/net80211/ieee80211.c Mon Mar 13 16:44:06 2017 (r315198) @@ -727,6 +727,7 @@ ieee80211_vap_detach(struct ieee80211vap */ ieee80211_draintask(ic, &vap->iv_nstate_task); ieee80211_draintask(ic, &vap->iv_swbmiss_task); + ieee80211_draintask(ic, &vap->iv_wme_task); /* XXX band-aid until ifnet handles this for us */ taskqueue_drain(taskqueue_swi, &ifp->if_linktask); Modified: head/sys/net80211/ieee80211_proto.c ============================================================================== --- head/sys/net80211/ieee80211_proto.c Mon Mar 13 15:34:21 2017 (r315197) +++ head/sys/net80211/ieee80211_proto.c Mon Mar 13 16:44:06 2017 (r315198) @@ -241,7 +241,7 @@ static void update_mcast(void *, int); static void update_promisc(void *, int); static void update_channel(void *, int); static void update_chw(void *, int); -static void update_wme(void *, int); +static void vap_update_wme(void *, int); static void restart_vaps(void *, int); static void ieee80211_newstate_cb(void *, int); @@ -280,7 +280,6 @@ ieee80211_proto_attach(struct ieee80211c TASK_INIT(&ic->ic_chan_task, 0, update_channel, ic); TASK_INIT(&ic->ic_bmiss_task, 0, beacon_miss, ic); TASK_INIT(&ic->ic_chw_task, 0, update_chw, ic); - TASK_INIT(&ic->ic_wme_task, 0, update_wme, ic); TASK_INIT(&ic->ic_restart_task, 0, restart_vaps, ic); ic->ic_wme.wme_hipri_switch_hysteresis = @@ -338,6 +337,7 @@ ieee80211_proto_vattach(struct ieee80211 callout_init(&vap->iv_mgtsend, 1); TASK_INIT(&vap->iv_nstate_task, 0, ieee80211_newstate_cb, vap); TASK_INIT(&vap->iv_swbmiss_task, 0, beacon_swmiss, vap); + TASK_INIT(&vap->iv_wme_task, 0, vap_update_wme, vap); /* * Install default tx rate handling: no fixed rate, lowest * supported rate for mgmt and multicast frames. Default @@ -1285,7 +1285,7 @@ ieee80211_wme_updateparams_locked(struct } /* schedule the deferred WME update */ - ieee80211_runtask(ic, &ic->ic_wme_task); + ieee80211_runtask(ic, &vap->iv_wme_task); IEEE80211_DPRINTF(vap, IEEE80211_MSG_WME, "%s: WME params updated, cap_info 0x%x\n", __func__, @@ -1350,15 +1350,25 @@ update_chw(void *arg, int npending) ic->ic_update_chw(ic); } +/* + * Deferred WME update. + * + * In preparation for per-VAP WME configuration, call the VAP + * method if the VAP requires it. Otherwise, just call the + * older global method. There isn't a per-VAP WME configuration + * just yet so for now just use the global configuration. + */ static void -update_wme(void *arg, int npending) +vap_update_wme(void *arg, int npending) { - struct ieee80211com *ic = arg; + struct ieee80211vap *vap = arg; + struct ieee80211com *ic = vap->iv_ic; - /* - * XXX should we defer the WME configuration update until now? - */ - ic->ic_wme.wme_update(ic); + if (vap->iv_wme_update != NULL) + vap->iv_wme_update(vap, + ic->ic_wme.wme_chanParams.cap_wmeParams); + else + ic->ic_wme.wme_update(ic); } static void @@ -1385,7 +1395,6 @@ ieee80211_waitfor_parent(struct ieee8021 ieee80211_draintask(ic, &ic->ic_chan_task); ieee80211_draintask(ic, &ic->ic_bmiss_task); ieee80211_draintask(ic, &ic->ic_chw_task); - ieee80211_draintask(ic, &ic->ic_wme_task); taskqueue_unblock(ic->ic_tq); } Modified: head/sys/net80211/ieee80211_var.h ============================================================================== --- head/sys/net80211/ieee80211_var.h Mon Mar 13 15:34:21 2017 (r315197) +++ head/sys/net80211/ieee80211_var.h Mon Mar 13 16:44:06 2017 (r315198) @@ -149,7 +149,6 @@ struct ieee80211com { struct task ic_chan_task; /* deferred channel change */ struct task ic_bmiss_task; /* deferred beacon miss hndlr */ struct task ic_chw_task; /* deferred HT CHW update */ - struct task ic_wme_task; /* deferred WME update */ struct task ic_restart_task; /* deferred device restart */ counter_u64_t ic_ierrors; /* input errors */ @@ -557,6 +556,10 @@ struct ieee80211vap { int (*iv_output)(struct ifnet *, struct mbuf *, const struct sockaddr *, struct route *); + int (*iv_wme_update)(struct ieee80211vap *, + const struct wmeParams *wme_params); + struct task iv_wme_task; /* deferred VAP WME update */ + uint64_t iv_spare[6]; }; MALLOC_DECLARE(M_80211_VAP); From owner-svn-src-all@freebsd.org Mon Mar 13 16:45:27 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C7CE1D0A5EB; Mon, 13 Mar 2017 16:45:27 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wm0-x230.google.com (mail-wm0-x230.google.com [IPv6:2a00:1450:400c:c09::230]) (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 6616A17F2; Mon, 13 Mar 2017 16:45:27 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: by mail-wm0-x230.google.com with SMTP id v186so45081280wmd.0; Mon, 13 Mar 2017 09:45:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=osH4URHcfN8dQvsjzyKqEfvyU5bAhUDPaic/j8yUXh4=; b=Dvn7tsFIdKlZxQRXuPzzBj7bqES4GbGuXi71FgFdx4wRDvH2pDZM9mUlKiP7+ZG3/g G9MIZ4Fj3bfD28MY6obTzaTKUKsZzNJJCvdCklm96aUtcfnoDn08CNbR6q7brkcFAjAt lf9/E+ZPGnyLm0O91iAcLaVpCedXhvlaJuJ8ldWyv3J3R8LWIc0scXtAWIZ2KJntasu3 4Tk6i+b83SlaxsgUTeqb1JpAdhYpj1lKHSjnySHmu1wfDAseld+MQnzp1JRYalYdS3dw Oq9k/QxvXWpxgDU5kfNfUVSIaQByLysS2NUS7aUJ+uqJMUKTlTlesBzgc0jtCV09ixbx ZOKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=osH4URHcfN8dQvsjzyKqEfvyU5bAhUDPaic/j8yUXh4=; b=WHI6bHRFUhFtFWkGYwY3jUcdk+cDXf0mkjEL/TugGKgKltfHLuGlA5+l5Fhl57ooNg lImTFU5jyMX1qTXwq/+rJ6QiWCxU6eaeUyuFIWL3Pg94Uj7wvCrIOH9dryVRXH82irC/ CNZNDHZtPwokE0r9Xer62IHHkU0jqidaXO9IhI45hAl0AUHYsruIp2OcYfVoM71dhz5F PfM8fOFj36l3QOnvfb/8OvCv53DnRP/bGb6WAnjWwssek9Tm60HM250KG8mray+bBiXn yDzwteXVoMvhZHi79jS8hZa+YykJDzPMMQjzFGUGC9fAJ3GLT2zAatnM30C3o/uESOtc MqGw== X-Gm-Message-State: AFeK/H196ijvakfLvNepqLQVPbCSwnBiKtdTMuwPyw7FEKNOzsDi7LSRsuAlPJ/TE8ql+ago4DMBifEd6GsuTQ== X-Received: by 10.28.72.193 with SMTP id v184mr11175744wma.105.1489423525736; Mon, 13 Mar 2017 09:45:25 -0700 (PDT) MIME-Version: 1.0 Received: by 10.28.128.133 with HTTP; Mon, 13 Mar 2017 09:45:25 -0700 (PDT) In-Reply-To: <20170313154059.ibzxffsw46uz73lk@ivaldir.net> References: <201703110501.v2B51UJQ045535@repo.freebsd.org> <758cfa1c-0985-f392-aa74-228f257a676c@freebsd.org> <20170313154059.ibzxffsw46uz73lk@ivaldir.net> From: Adrian Chadd Date: Mon, 13 Mar 2017 09:45:25 -0700 Message-ID: Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests To: Baptiste Daroussin Cc: Michal Meloun , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 16:45:27 -0000 size. think 32/64mb RAM, 8mb flash storage. -adrian On 13 March 2017 at 08:40, Baptiste Daroussin wrote: > On Mon, Mar 13, 2017 at 09:55:52AM +0100, Michal Meloun wrote: >> >> >> On 11.03.2017 6:01, Baptiste Daroussin wrote: >> > Author: bapt >> > Date: Sat Mar 11 05:01:29 2017 >> > New Revision: 315051 >> > URL: https://svnweb.freebsd.org/changeset/base/315051 >> > >> > Log: >> > Import diff from OpenBSD and remove GNU diff >> > >> > Some of the modifications from the previous summer of code has been integrated >> > Modification for compatibility with GNU diff output has been added >> > >> > Main difference with OpenBSD: >> > Implement multiple GNU diff options: >> > * --ignore-file-name-case >> > * --no-ignore-file-name-case >> > * --normal >> > * --tabsize >> > * --strip-trailing-cr >> > Make diff -p compatible with GNU diff >> > Implement diff -l >> > Make diff -r compatible with GNU diff >> > >> > Capsicumize diffing 2 regular files >> > Add a simple test suite >> > >> > Approved by: AsiaBSDcon devsummit >> > Obtained from: OpenBSD, GSoC >> > Relnotes: yes >> > >> >> It seems that this commit breaks mergemaster (but I'm not sure): >> >> ----- >> diff: unable to limit rights on: /etc/casper/system.dns: Function not >> implemented >> --- >> >> Michal > > Yes you were right I forgot a test against systems without capsicum, but that > makes me wonder why you do build your system without capsicum? > > Best regards, > Bapt From owner-svn-src-all@freebsd.org Mon Mar 13 17:05:51 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 05914D0AB90; Mon, 13 Mar 2017 17:05:51 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C96001444; Mon, 13 Mar 2017 17:05:50 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DH5nEq050142; Mon, 13 Mar 2017 17:05:49 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DH5nLH050141; Mon, 13 Mar 2017 17:05:49 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703131705.v2DH5nLH050141@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 17:05:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315199 - head/sbin/dhclient X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:05:51 -0000 Author: ngie Date: Mon Mar 13 17:05:49 2017 New Revision: 315199 URL: https://svnweb.freebsd.org/changeset/base/315199 Log: sbin/dhclient: fix a memory leak in parse_client_lease_statement(..) The memory stored by `lease` would have previously been leaked if an unterminated lease declaration was found in an early-return code path. MFC after: 1 week Reported by: clang static analyzer, Coverity CID: 1007114 Submitted by: Tom Rix Sponsored by: Dell EMC Isilon; Juniper, Inc Differential Revision: D9992 Modified: head/sbin/dhclient/clparse.c Modified: head/sbin/dhclient/clparse.c ============================================================================== --- head/sbin/dhclient/clparse.c Mon Mar 13 16:44:06 2017 (r315198) +++ head/sbin/dhclient/clparse.c Mon Mar 13 17:05:49 2017 (r315199) @@ -512,6 +512,7 @@ parse_client_lease_statement(FILE *cfile token = peek_token(&val, cfile); if (token == EOF) { parse_warn("unterminated lease declaration."); + free_client_lease(lease); return; } if (token == RBRACE) From owner-svn-src-all@freebsd.org Mon Mar 13 17:15:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CE5C4D0AEED; Mon, 13 Mar 2017 17:15:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9E0161D2A; Mon, 13 Mar 2017 17:15:46 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHFjZT054215; Mon, 13 Mar 2017 17:15:45 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHFja9054214; Mon, 13 Mar 2017 17:15:45 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703131715.v2DHFja9054214@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 17:15:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315200 - head/sbin/dhclient/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:15:46 -0000 Author: ngie Date: Mon Mar 13 17:15:45 2017 New Revision: 315200 URL: https://svnweb.freebsd.org/changeset/base/315200 Log: Fix -Wunused-but-set-warning with `ret` While here, resolve Coverity warnings by demonstrating that vfprintf's return value is being explicitly ignored. MFC after: 1 week Reported by: gcc 6.3.0 Tested with: clang, gcc 4.2.1, gcc 6.3.0 Sponsored by: Dell EMC Isilon Modified: head/sbin/dhclient/tests/fake.c Modified: head/sbin/dhclient/tests/fake.c ============================================================================== --- head/sbin/dhclient/tests/fake.c Mon Mar 13 17:05:49 2017 (r315199) +++ head/sbin/dhclient/tests/fake.c Mon Mar 13 17:15:45 2017 (r315200) @@ -14,7 +14,7 @@ error(char *fmt, ...) va_list ap; va_start(ap, fmt); - vfprintf(stderr, fmt, ap); + (void)vfprintf(stderr, fmt, ap); va_end(ap); fprintf(stderr, "\n"); @@ -24,11 +24,10 @@ error(char *fmt, ...) int warning(char *fmt, ...) { - int ret; va_list ap; va_start(ap, fmt); - ret = vfprintf(stderr, fmt, ap); + (void)vfprintf(stderr, fmt, ap); va_end(ap); fprintf(stderr, "\n"); From owner-svn-src-all@freebsd.org Mon Mar 13 17:16:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9A549D0AF58; Mon, 13 Mar 2017 17:16:30 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 678C31E81; Mon, 13 Mar 2017 17:16:30 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHGTO0054294; Mon, 13 Mar 2017 17:16:29 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHGTcS054293; Mon, 13 Mar 2017 17:16:29 GMT (envelope-from np@FreeBSD.org) Message-Id: <201703131716.v2DHGTcS054293@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Mon, 13 Mar 2017 17:16:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315201 - head/sys/dev/cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:16:30 -0000 Author: np Date: Mon Mar 13 17:16:29 2017 New Revision: 315201 URL: https://svnweb.freebsd.org/changeset/base/315201 Log: cxgbe(4): Fix an always-true assertion (reported by PVS-Studio). sys/dev/cxgbe/t4_main.c: PVS-Studio: Expression is Always True (CWE-571) (3) PR: 217746 Submitted by: Svyatoslav (razmyslov at viva64 com) MFC after: 1 week Modified: head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/t4_main.c ============================================================================== --- head/sys/dev/cxgbe/t4_main.c Mon Mar 13 17:15:45 2017 (r315200) +++ head/sys/dev/cxgbe/t4_main.c Mon Mar 13 17:16:29 2017 (r315201) @@ -7999,9 +7999,9 @@ sysctl_tp_timer(SYSCTL_HANDLER_ARGS) u_int cclk_ps = 1000000000 / sc->params.vpd.cclk; MPASS(reg == A_TP_RXT_MIN || reg == A_TP_RXT_MAX || - reg == A_TP_PERS_MIN || reg == A_TP_PERS_MAX || - reg == A_TP_KEEP_IDLE || A_TP_KEEP_INTVL || reg == A_TP_INIT_SRTT || - reg == A_TP_FINWAIT2_TIMER); + reg == A_TP_PERS_MIN || reg == A_TP_PERS_MAX || + reg == A_TP_KEEP_IDLE || reg == A_TP_KEEP_INTVL || + reg == A_TP_INIT_SRTT || reg == A_TP_FINWAIT2_TIMER); tre = G_TIMERRESOLUTION(t4_read_reg(sc, A_TP_TIMER_RESOLUTION)); tp_tick_us = (cclk_ps << tre) / 1000000; From owner-svn-src-all@freebsd.org Mon Mar 13 17:35:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B08A0D0A9AC; Mon, 13 Mar 2017 17:35:56 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7185F11C0; Mon, 13 Mar 2017 17:35:56 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHZtwF062413; Mon, 13 Mar 2017 17:35:55 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHZtCN062412; Mon, 13 Mar 2017 17:35:55 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703131735.v2DHZtCN062412@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 17:35:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315202 - head/lib/libcam X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:35:56 -0000 Author: ngie Date: Mon Mar 13 17:35:55 2017 New Revision: 315202 URL: https://svnweb.freebsd.org/changeset/base/315202 Log: lib/libcam/cam_cdbparse.3: fix manpage warnings - Add comma before and after 'e.g.'; remove surrounding parentheses that were unnecessary after this change [1]. - Add .Mt when referencing ken and Peter Dufault's email addresses [2]. - Sprinkle around .An use where proper [2]. Bump .Dd for the change MFC after: 1 week Reported by: igor [1], manlint [2] Reviewed by: imp Sponsored by: Dell EMC Isilon Differential Revision: D9968 Modified: head/lib/libcam/cam_cdbparse.3 Modified: head/lib/libcam/cam_cdbparse.3 ============================================================================== --- head/lib/libcam/cam_cdbparse.3 Mon Mar 13 17:16:29 2017 (r315201) +++ head/lib/libcam/cam_cdbparse.3 Mon Mar 13 17:35:55 2017 (r315202) @@ -61,7 +61,7 @@ .\" SUCH DAMAGE. .\" .\" -.Dd October 13, 1998 +.Dd March 13, 2017 .Dt CAM_CDBPARSE 3 .Os .Sh NAME @@ -170,12 +170,11 @@ layer. These functions may be used in new applications, but users may find it easier to use the various SCSI CCB building functions included with the .Xr cam 3 -library. -(e.g.\& +library, e.g., \& .Fn cam_fill_csio , .Fn scsi_start_stop , and -.Fn scsi_read_write ) +.Fn scsi_read_write . .Pp .Fn csio_build builds up a @@ -522,17 +521,18 @@ implemented for the old layer. The encoding/decoding functions in the old .Tn SCSI -code were written by Peter Dufault. +code were written by +.An Peter Dufault Aq Mt dufault@hda.com . .Pp Many systems have comparable interfaces to permit a user to construct a SCSI command in user space. .Pp The old .Va scsireq -data structure was almost identical to the SGI /dev/scsi data -structure. -If anyone knows the name of the authors it should -go here; Peter Dufault first read about it in a 1989 Sun Expert magazine. +data structure was almost identical to the SGI /dev/scsi data structure. +If anyone knows the name of the authors it should go here; +Peter Dufault +first read about it in a 1989 Sun Expert magazine. .Pp The new CCB data structures are derived from the CAM-2 and CAM-3 specifications. @@ -545,11 +545,14 @@ led to the original .Fx .Tn SCSI library and the related kernel ioctl. -If anyone needs that for compatibility contact dufault@hda.com. +If anyone needs that for compatibility, contact +.Mt dufault@hda.com . .Sh AUTHORS -Kenneth Merry implemented the CAM versions of these encoding and decoding -functions. -This current work is based upon earlier work by Peter Dufault. +.An -nosplit +.An Kenneth Merry Aq Mt ken@FreeBSD.org +implemented the CAM versions of these encoding and decoding functions. +This current work is based upon earlier work by +.An Peter Dufault Aq Mt dufault@hda.com . .Sh BUGS There should probably be a function that encodes both the CDB and the data buffer portions of a From owner-svn-src-all@freebsd.org Mon Mar 13 17:45:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 83C7DD0A143; Mon, 13 Mar 2017 17:45:01 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 509191C2F; Mon, 13 Mar 2017 17:45:01 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHj0F9067128; Mon, 13 Mar 2017 17:45:00 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHj0VX067127; Mon, 13 Mar 2017 17:45:00 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703131745.v2DHj0VX067127@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 17:45:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315203 - head/sbin/dhclient X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:45:01 -0000 Author: ngie Date: Mon Mar 13 17:45:00 2017 New Revision: 315203 URL: https://svnweb.freebsd.org/changeset/base/315203 Log: sbin/dhclient: fix `vendor` storage leak in parse_option_decl(..) This ensures the storage isn't leaked when non-NULL and the function returns early, prior to the `free(vendor)` later on in the function. MFC after: 1 week Reported by: Coverity CID: 1007111-1007113 Reviewed by: cem Sponsored by: Dell EMC Isilon Differential Revision: D9993 Modified: head/sbin/dhclient/clparse.c Modified: head/sbin/dhclient/clparse.c ============================================================================== --- head/sbin/dhclient/clparse.c Mon Mar 13 17:35:55 2017 (r315202) +++ head/sbin/dhclient/clparse.c Mon Mar 13 17:45:00 2017 (r315203) @@ -714,6 +714,7 @@ parse_option_decl(FILE *cfile, struct op parse_warn("expecting identifier after '.'"); if (token != SEMI) skip_to_semi(cfile); + free(vendor); return (NULL); } @@ -726,6 +727,7 @@ parse_option_decl(FILE *cfile, struct op if (!universe) { parse_warn("no vendor named %s.", vendor); skip_to_semi(cfile); + free(vendor); return (NULL); } } else { @@ -747,6 +749,7 @@ parse_option_decl(FILE *cfile, struct op parse_warn("no option named %s for vendor %s", val, vendor); skip_to_semi(cfile); + free(vendor); return (NULL); } From owner-svn-src-all@freebsd.org Mon Mar 13 17:53:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6608DD0A603; Mon, 13 Mar 2017 17:53:47 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 35C7B17B2; Mon, 13 Mar 2017 17:53:47 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHrk44071517; Mon, 13 Mar 2017 17:53:46 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHrkab071516; Mon, 13 Mar 2017 17:53:46 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201703131753.v2DHrkab071516@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: Conrad Meyer Date: Mon, 13 Mar 2017 17:53:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315204 - head/sys/netpfil/ipfw/nat64 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:53:47 -0000 Author: cem Date: Mon Mar 13 17:53:46 2017 New Revision: 315204 URL: https://svnweb.freebsd.org/changeset/base/315204 Log: nat64lsn: Use memset() with structure, not pointer, size PR: 217738 Submitted by: Svyatoslav Sponsored by: Viva64 (PVS-Studio) Modified: head/sys/netpfil/ipfw/nat64/nat64lsn.c Modified: head/sys/netpfil/ipfw/nat64/nat64lsn.c ============================================================================== --- head/sys/netpfil/ipfw/nat64/nat64lsn.c Mon Mar 13 17:45:00 2017 (r315203) +++ head/sys/netpfil/ipfw/nat64/nat64lsn.c Mon Mar 13 17:53:46 2017 (r315204) @@ -215,7 +215,7 @@ nat64lsn_log(struct pfloghdr *plog, stru uint32_t n, uint32_t sn) { - memset(plog, 0, sizeof(plog)); + memset(plog, 0, sizeof(*plog)); plog->length = PFLOG_REAL_HDRLEN; plog->af = family; plog->action = PF_NAT; From owner-svn-src-all@freebsd.org Mon Mar 13 17:58:09 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 827E5D0A945; Mon, 13 Mar 2017 17:58:09 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4FADC1CF6; Mon, 13 Mar 2017 17:58:09 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DHw8j8071841; Mon, 13 Mar 2017 17:58:08 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DHw8NC071840; Mon, 13 Mar 2017 17:58:08 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201703131758.v2DHw8NC071840@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: Conrad Meyer Date: Mon, 13 Mar 2017 17:58:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315205 - head/sys/dev/isci/scil X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 17:58:09 -0000 Author: cem Date: Mon Mar 13 17:58:08 2017 New Revision: 315205 URL: https://svnweb.freebsd.org/changeset/base/315205 Log: scif_sas_controller: Fix inverted logic range check PR: 217742 Submitted by: Svyatoslav Sponsored by: Viva64 (PVS-Studio) Modified: head/sys/dev/isci/scil/scif_sas_controller.c Modified: head/sys/dev/isci/scil/scif_sas_controller.c ============================================================================== --- head/sys/dev/isci/scil/scif_sas_controller.c Mon Mar 13 17:53:46 2017 (r315204) +++ head/sys/dev/isci/scil/scif_sas_controller.c Mon Mar 13 17:58:08 2017 (r315205) @@ -528,7 +528,7 @@ SCI_STATUS scif_user_parameters_set( if (scif_parms->sas.is_sata_ncq_enabled != 1 && scif_parms->sas.is_sata_ncq_enabled != 0) return SCI_FAILURE_INVALID_PARAMETER_VALUE; - if (scif_parms->sas.max_ncq_depth < 1 && scif_parms->sas.max_ncq_depth > 32) + if (scif_parms->sas.max_ncq_depth < 1 || scif_parms->sas.max_ncq_depth > 32) return SCI_FAILURE_INVALID_PARAMETER_VALUE; if (scif_parms->sas.is_sata_standby_timer_enabled != 1 From owner-svn-src-all@freebsd.org Mon Mar 13 18:01:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 18051D0AA9D; Mon, 13 Mar 2017 18:01:03 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DBED310A8; Mon, 13 Mar 2017 18:01:02 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DI112q072032; Mon, 13 Mar 2017 18:01:01 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DI11ue072031; Mon, 13 Mar 2017 18:01:01 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703131801.v2DI11ue072031@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Mon, 13 Mar 2017 18:01:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315206 - head/contrib/bsnmp/snmpd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 18:01:03 -0000 Author: ngie Date: Mon Mar 13 18:01:01 2017 New Revision: 315206 URL: https://svnweb.freebsd.org/changeset/base/315206 Log: bsnmpd: fix segfault when trans_insert_port(..) is called with multiple out of order addresses Move `port->transport` initialization before the TAILQ_FOREACH(..) loop to ensure that the value is properly initialized before it's inserted into the TAILQ. MFC after: 1 week PR: 217760 Submitted by: eugen Sponsored by: Dell EMC Isilon Modified: head/contrib/bsnmp/snmpd/main.c Modified: head/contrib/bsnmp/snmpd/main.c ============================================================================== --- head/contrib/bsnmp/snmpd/main.c Mon Mar 13 17:58:08 2017 (r315205) +++ head/contrib/bsnmp/snmpd/main.c Mon Mar 13 18:01:01 2017 (r315206) @@ -765,13 +765,13 @@ trans_insert_port(struct transport *t, s { struct tport *p; + port->transport = t; TAILQ_FOREACH(p, &t->table, link) { if (asn_compare_oid(&p->index, &port->index) > 0) { TAILQ_INSERT_BEFORE(p, port, link); return; } } - port->transport = t; TAILQ_INSERT_TAIL(&t->table, port, link); } From owner-svn-src-all@freebsd.org Mon Mar 13 18:05:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1D706D0AC25; Mon, 13 Mar 2017 18:05:33 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D3F1B1376; Mon, 13 Mar 2017 18:05:32 +0000 (UTC) (envelope-from cem@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DI5VsU075702; Mon, 13 Mar 2017 18:05:31 GMT (envelope-from cem@FreeBSD.org) Received: (from cem@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DI5V69075701; Mon, 13 Mar 2017 18:05:31 GMT (envelope-from cem@FreeBSD.org) Message-Id: <201703131805.v2DI5V69075701@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cem set sender to cem@FreeBSD.org using -f From: Conrad Meyer Date: Mon, 13 Mar 2017 18:05:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315207 - head/sys/netinet/libalias X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 18:05:33 -0000 Author: cem Date: Mon Mar 13 18:05:31 2017 New Revision: 315207 URL: https://svnweb.freebsd.org/changeset/base/315207 Log: alias_proxy.c: Fix accidental error quashing This was introduced on accident in r165243, when return sites were unified to add a lock around LibAliasProxyRule(). PR: 217749 Submitted by: Svyatoslav Sponsored by: Viva64 (PVS-Studio) Modified: head/sys/netinet/libalias/alias_proxy.c Modified: head/sys/netinet/libalias/alias_proxy.c ============================================================================== --- head/sys/netinet/libalias/alias_proxy.c Mon Mar 13 18:01:01 2017 (r315206) +++ head/sys/netinet/libalias/alias_proxy.c Mon Mar 13 18:05:31 2017 (r315207) @@ -720,7 +720,8 @@ LibAliasProxyRule(struct libalias *la, c err = RuleNumberDelete(la, rule_to_delete); if (err) ret = -1; - ret = 0; + else + ret = 0; goto getout; } From owner-svn-src-all@freebsd.org Mon Mar 13 18:43:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CDEA0D0A99F; Mon, 13 Mar 2017 18:43: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 954D41E1D; Mon, 13 Mar 2017 18:43: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 v2DIh01v091964; Mon, 13 Mar 2017 18:43:00 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DIh0Pv091963; Mon, 13 Mar 2017 18:43:00 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201703131843.v2DIh0Pv091963@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Mon, 13 Mar 2017 18:43:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315208 - head/sys/cddl/dev/dtrace X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 18:43:01 -0000 Author: markj Date: Mon Mar 13 18:43:00 2017 New Revision: 315208 URL: https://svnweb.freebsd.org/changeset/base/315208 Log: Fix a backwards comparison in the code to dump a DTrace debug buffer. PR: 217739 MFC after: 1 week Modified: head/sys/cddl/dev/dtrace/dtrace_debug.c Modified: head/sys/cddl/dev/dtrace/dtrace_debug.c ============================================================================== --- head/sys/cddl/dev/dtrace/dtrace_debug.c Mon Mar 13 18:05:31 2017 (r315207) +++ head/sys/cddl/dev/dtrace/dtrace_debug.c Mon Mar 13 18:43:00 2017 (r315208) @@ -106,7 +106,7 @@ dtrace_debug_output(void) for (p = d->first; p < d->next; p++) *p1++ = *p; - } else if (d->next > d->first) { + } else if (d->first > d->next) { char *p1 = dtrace_debug_bufr; count = (uintptr_t) d->last - (uintptr_t) d->first; From owner-svn-src-all@freebsd.org Mon Mar 13 18:45:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 764CAD0AB13; Mon, 13 Mar 2017 18:45:26 +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 3C6971025; Mon, 13 Mar 2017 18:45:26 +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 v2DIjPJE092193; Mon, 13 Mar 2017 18:45:25 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DIjP7u092192; Mon, 13 Mar 2017 18:45:25 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201703131845.v2DIjP7u092192@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Mon, 13 Mar 2017 18:45:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315209 - head/sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 18:45:26 -0000 Author: markj Date: Mon Mar 13 18:45:25 2017 New Revision: 315209 URL: https://svnweb.freebsd.org/changeset/base/315209 Log: Update a comment to reflect reality. MFC after: 1 week Modified: head/sys/vm/uma.h Modified: head/sys/vm/uma.h ============================================================================== --- head/sys/vm/uma.h Mon Mar 13 18:43:00 2017 (r315208) +++ head/sys/vm/uma.h Mon Mar 13 18:45:25 2017 (r315209) @@ -242,7 +242,7 @@ uma_zone_t uma_zcache_create(char *name, * Definitions for uma_zcreate flags * * These flags share space with UMA_ZFLAGs in uma_int.h. Be careful not to - * overlap when adding new features. 0xf0000000 is in use by uma_int.h. + * overlap when adding new features. 0xff000000 is in use by uma_int.h. */ #define UMA_ZONE_PAGEABLE 0x0001 /* Return items not fully backed by physical memory XXX Not yet */ From owner-svn-src-all@freebsd.org Mon Mar 13 19:12:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C4ED0D0A6F3; Mon, 13 Mar 2017 19:12:19 +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 9426A1297; Mon, 13 Mar 2017 19:12:19 +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 v2DJCI7e005176; Mon, 13 Mar 2017 19:12:18 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DJCIKH005175; Mon, 13 Mar 2017 19:12:18 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201703131912.v2DJCIKH005175@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Mon, 13 Mar 2017 19:12:18 +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: r315210 - stable/11/sbin/kldstat X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 19:12:19 -0000 Author: markj Date: Mon Mar 13 19:12:18 2017 New Revision: 315210 URL: https://svnweb.freebsd.org/changeset/base/315210 Log: MFC r315018: Typo. Modified: stable/11/sbin/kldstat/kldstat.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sbin/kldstat/kldstat.c ============================================================================== --- stable/11/sbin/kldstat/kldstat.c Mon Mar 13 18:45:25 2017 (r315209) +++ stable/11/sbin/kldstat/kldstat.c Mon Mar 13 19:12:18 2017 (r315210) @@ -97,7 +97,7 @@ printfile(int fileid, int verbose, int h static void usage(void) { - fprintf(stderr, "usage: kldstata[-d] [-h] [-q] [-v] [-i id] [-n filename]\n"); + fprintf(stderr, "usage: kldstat [-d] [-h] [-q] [-v] [-i id] [-n filename]\n"); fprintf(stderr, " kldstat [-d] [-q] [-m modname]\n"); exit(1); } From owner-svn-src-all@freebsd.org Mon Mar 13 19:54:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E14CDD0A7D7; Mon, 13 Mar 2017 19:54:21 +0000 (UTC) (envelope-from bdrewery@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 B09791EAB; Mon, 13 Mar 2017 19:54:21 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DJsKgj021475; Mon, 13 Mar 2017 19:54:20 GMT (envelope-from bdrewery@FreeBSD.org) Received: (from bdrewery@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DJsKb6021474; Mon, 13 Mar 2017 19:54:20 GMT (envelope-from bdrewery@FreeBSD.org) Message-Id: <201703131954.v2DJsKb6021474@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bdrewery set sender to bdrewery@FreeBSD.org using -f From: Bryan Drewery Date: Mon, 13 Mar 2017 19:54:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315211 - head/share/man/man7 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 19:54:22 -0000 Author: bdrewery Date: Mon Mar 13 19:54:20 2017 New Revision: 315211 URL: https://svnweb.freebsd.org/changeset/base/315211 Log: hier(7): Fix entry location for /usr/share/vt. MFC after: 2 weeks Modified: head/share/man/man7/hier.7 Modified: head/share/man/man7/hier.7 ============================================================================== --- head/share/man/man7/hier.7 Mon Mar 13 19:12:18 2017 (r315210) +++ head/share/man/man7/hier.7 Mon Mar 13 19:54:20 2017 (r315211) @@ -28,7 +28,7 @@ .\" @(#)hier.7 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd March 8, 2017 +.Dd March 13, 2017 .Dt HIER 7 .Os .Sh NAME @@ -644,11 +644,6 @@ and .It Pa vi/ localization support and utilities for .Xr vi 1 -.It Pa zoneinfo/ -timezone configuration information; -see -.Xr tzfile 5 -.El .It Pa vt/ files used by vt; see @@ -669,6 +664,11 @@ and .\" .It Pa scrnmaps/ .\" console screen maps .El +.It Pa zoneinfo/ +timezone configuration information; +see +.Xr tzfile 5 +.El .It Pa src/ .Bx , third-party, and/or local source files From owner-svn-src-all@freebsd.org Mon Mar 13 20:14:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DE09DD0A116; Mon, 13 Mar 2017 20:14:08 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ADB4D1DB4; Mon, 13 Mar 2017 20:14:08 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DKE7Oh029777; Mon, 13 Mar 2017 20:14:07 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DKE76m029776; Mon, 13 Mar 2017 20:14:07 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703132014.v2DKE76m029776@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 13 Mar 2017 20:14:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315212 - head/usr.bin/mkimg X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 20:14:09 -0000 Author: pfg Date: Mon Mar 13 20:14:07 2017 New Revision: 315212 URL: https://svnweb.freebsd.org/changeset/base/315212 Log: mkimg(1): let calloc(3) do the multiplication. Reviewed by: marcel MFC after: 1 week Modified: head/usr.bin/mkimg/qcow.c Modified: head/usr.bin/mkimg/qcow.c ============================================================================== --- head/usr.bin/mkimg/qcow.c Mon Mar 13 19:54:20 2017 (r315211) +++ head/usr.bin/mkimg/qcow.c Mon Mar 13 20:14:07 2017 (r315212) @@ -216,7 +216,7 @@ qcow_write(int fd, u_int version) ofs = clstrsz * l2clno; nclstrs = 1 + clstr_l1tblsz + clstr_rctblsz; - l1tbl = calloc(1, clstrsz * clstr_l1tblsz); + l1tbl = calloc(clstr_l1tblsz, clstrsz); if (l1tbl == NULL) { error = ENOMEM; goto out; @@ -247,7 +247,7 @@ qcow_write(int fd, u_int version) } while (n < clstr_rcblks); if (rcclno > 0) { - rctbl = calloc(1, clstrsz * clstr_rctblsz); + rctbl = calloc(clstr_rctblsz, clstrsz); if (rctbl == NULL) { error = ENOMEM; goto out; @@ -297,7 +297,7 @@ qcow_write(int fd, u_int version) l1tbl = NULL; if (rcclno > 0) { - rcblk = calloc(1, clstrsz * clstr_rcblks); + rcblk = calloc(clstr_rcblks, clstrsz); if (rcblk == NULL) { error = ENOMEM; goto out; From owner-svn-src-all@freebsd.org Mon Mar 13 20:34:55 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 147FAD0A5FE; Mon, 13 Mar 2017 20:34:55 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E092B16E1; Mon, 13 Mar 2017 20:34:54 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DKYrpT037515; Mon, 13 Mar 2017 20:34:53 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DKYru2037511; Mon, 13 Mar 2017 20:34:53 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703132034.v2DKYru2037511@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 13 Mar 2017 20:34:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315213 - head/usr.sbin/nscd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 20:34:55 -0000 Author: pfg Date: Mon Mar 13 20:34:53 2017 New Revision: 315213 URL: https://svnweb.freebsd.org/changeset/base/315213 Log: nscd(8): let calloc(3) do the multiplying. MFC after: 1 week Modified: head/usr.sbin/nscd/cachelib.c head/usr.sbin/nscd/config.c head/usr.sbin/nscd/hashtable.h head/usr.sbin/nscd/nscd.c Modified: head/usr.sbin/nscd/cachelib.c ============================================================================== --- head/usr.sbin/nscd/cachelib.c Mon Mar 13 20:14:07 2017 (r315212) +++ head/usr.sbin/nscd/cachelib.c Mon Mar 13 20:34:53 2017 (r315213) @@ -487,8 +487,8 @@ init_cache(struct cache_params const *pa assert(params != NULL); memcpy(&retval->params, params, sizeof(struct cache_params)); - retval->entries = calloc(1, - sizeof(*retval->entries) * INITIAL_ENTRIES_CAPACITY); + retval->entries = calloc(INITIAL_ENTRIES_CAPACITY, + sizeof(*retval->entries)); assert(retval->entries != NULL); retval->entries_capacity = INITIAL_ENTRIES_CAPACITY; @@ -540,8 +540,8 @@ register_cache_entry(struct cache_ *the_ new_capacity = the_cache->entries_capacity + ENTRIES_CAPACITY_STEP; - new_entries = calloc(1, - sizeof(*new_entries) * new_capacity); + new_entries = calloc(new_capacity, + sizeof(*new_entries)); assert(new_entries != NULL); memcpy(new_entries, the_cache->entries, @@ -582,8 +582,8 @@ register_cache_entry(struct cache_ *the_ else policies_size = 2; - new_common_entry->policies = calloc(1, - sizeof(*new_common_entry->policies) * policies_size); + new_common_entry->policies = calloc(policies_size, + sizeof(*new_common_entry->policies)); assert(new_common_entry->policies != NULL); new_common_entry->policies_size = policies_size; Modified: head/usr.sbin/nscd/config.c ============================================================================== --- head/usr.sbin/nscd/config.c Mon Mar 13 20:14:07 2017 (r315212) +++ head/usr.sbin/nscd/config.c Mon Mar 13 20:34:53 2017 (r315213) @@ -274,9 +274,8 @@ add_configuration_entry(struct configura struct configuration_entry **new_entries; config->entries_capacity *= 2; - new_entries = calloc(1, - sizeof(*new_entries) * - config->entries_capacity); + new_entries = calloc(config->entries_capacity, + sizeof(*new_entries)); assert(new_entries != NULL); memcpy(new_entries, config->entries, sizeof(struct configuration_entry *) * @@ -522,9 +521,8 @@ init_configuration(void) assert(retval != NULL); retval->entries_capacity = INITIAL_ENTRIES_CAPACITY; - retval->entries = calloc(1, - sizeof(*retval->entries) * - retval->entries_capacity); + retval->entries = calloc(retval->entries_capacity, + sizeof(*retval->entries)); assert(retval->entries != NULL); pthread_rwlock_init(&retval->rwlock, NULL); Modified: head/usr.sbin/nscd/hashtable.h ============================================================================== --- head/usr.sbin/nscd/hashtable.h Mon Mar 13 20:14:07 2017 (r315212) +++ head/usr.sbin/nscd/hashtable.h Mon Mar 13 20:34:53 2017 (r315213) @@ -75,8 +75,8 @@ typedef unsigned int hashtable_index_t; #define HASHTABLE_INIT(table, type, field, _entries_size) \ do { \ hashtable_index_t var; \ - (table)->entries = calloc(1, \ - sizeof(*(table)->entries) * (_entries_size)); \ + (table)->entries = calloc(_entries_size, \ + sizeof(*(table)->entries)); \ (table)->entries_size = (_entries_size); \ for (var = 0; var < HASHTABLE_ENTRIES_COUNT(table); ++var) {\ (table)->entries[var].field.capacity = \ Modified: head/usr.sbin/nscd/nscd.c ============================================================================== --- head/usr.sbin/nscd/nscd.c Mon Mar 13 20:14:07 2017 (r315212) +++ head/usr.sbin/nscd/nscd.c Mon Mar 13 20:34:53 2017 (r315213) @@ -828,8 +828,8 @@ main(int argc, char *argv[]) } if (s_configuration->threads_num > 1) { - threads = calloc(1, sizeof(*threads) * - s_configuration->threads_num); + threads = calloc(s_configuration->threads_num, + sizeof(*threads)); for (i = 0; i < s_configuration->threads_num; ++i) { thread_args = malloc( sizeof(*thread_args)); From owner-svn-src-all@freebsd.org Mon Mar 13 20:49:32 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A9C52D0A85F; Mon, 13 Mar 2017 20:49:32 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 76EE01D31; Mon, 13 Mar 2017 20:49:32 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DKnVxo042065; Mon, 13 Mar 2017 20:49:31 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DKnVvm042064; Mon, 13 Mar 2017 20:49:31 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703132049.v2DKnVvm042064@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 13 Mar 2017 20:49:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315214 - head/usr.sbin/mpsutil X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 20:49:32 -0000 Author: pfg Date: Mon Mar 13 20:49:31 2017 New Revision: 315214 URL: https://svnweb.freebsd.org/changeset/base/315214 Log: mpsutil(8): let calloc(3) do the multiplying. Modified: head/usr.sbin/mpsutil/mps_cmd.c Modified: head/usr.sbin/mpsutil/mps_cmd.c ============================================================================== --- head/usr.sbin/mpsutil/mps_cmd.c Mon Mar 13 20:34:53 2017 (r315213) +++ head/usr.sbin/mpsutil/mps_cmd.c Mon Mar 13 20:49:31 2017 (r315214) @@ -486,7 +486,7 @@ mps_firmware_get(int fd, unsigned char * } size = reply.ActualImageSize; - *firmware = calloc(1, sizeof(unsigned char) * size); + *firmware = calloc(size, sizeof(unsigned char)); if (*firmware == NULL) { warn("calloc"); return (-1); From owner-svn-src-all@freebsd.org Mon Mar 13 20:51:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 66FBCD0AB2C; Mon, 13 Mar 2017 20:51:01 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3467810E2; Mon, 13 Mar 2017 20:51:01 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DKp0G9043062; Mon, 13 Mar 2017 20:51:00 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DKp0lf043061; Mon, 13 Mar 2017 20:51:00 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703132051.v2DKp0lf043061@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Mon, 13 Mar 2017 20:51:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315215 - head/usr.sbin/ypbind X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 20:51:01 -0000 Author: pfg Date: Mon Mar 13 20:51:00 2017 New Revision: 315215 URL: https://svnweb.freebsd.org/changeset/base/315215 Log: ypbind(8): let calloc(3) do the multiplying. Modified: head/usr.sbin/ypbind/yp_ping.c Modified: head/usr.sbin/ypbind/yp_ping.c ============================================================================== --- head/usr.sbin/ypbind/yp_ping.c Mon Mar 13 20:49:31 2017 (r315214) +++ head/usr.sbin/ypbind/yp_ping.c Mon Mar 13 20:51:00 2017 (r315215) @@ -226,7 +226,7 @@ __yp_ping(struct in_addr *restricted_add int validsrvs = 0; /* Set up handles. */ - reqs = calloc(1, sizeof(struct ping_req *) * cnt); + reqs = calloc(cnt, sizeof(struct ping_req *)); xid_seed = time(NULL) ^ getpid(); for (i = 0; i < cnt; i++) { From owner-svn-src-all@freebsd.org Mon Mar 13 20:55:39 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7E78ED0ABD5; Mon, 13 Mar 2017 20:55:39 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-qt0-x22a.google.com (mail-qt0-x22a.google.com [IPv6:2607:f8b0:400d:c0d::22a]) (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 35D3D15A8; Mon, 13 Mar 2017 20:55:39 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-qt0-x22a.google.com with SMTP id n21so41931565qta.1; Mon, 13 Mar 2017 13:55:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=getT5rmN9lS7gwAdJhhZQFB+/sHm6bU3Y+TWcfbD9Ng=; b=U9k2TKVBLappCkBLb5Lng3eSXsIdjyMxGcBvpD+f7/ikDEGCyQA6PW+RqQOKV3KCjS rfbW+BMivdqXqi6C+iprhPt7PLP1FRc/GQP0o1ooksB9clfBqHWeWo1Bm008RbGQmWb6 LRCTV9EgF4aR5JeZ6Vug/OgEDB+73W5QVeXUllghikEUOMg3XuVcV+0kYOe+jjKvqcb+ E9C0hPcHbGkBA25GIj4obOOHWr0z4ihAerOXUTfPNCo2Q/tGDr+iN06/egXJEoMNDMBS DqvJSSF92mSc+v17FJXK0PSByKga4umlR5Ugo9x5gQky4toU1a+HQVtgKBTV6/2qGTpu T+og== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=getT5rmN9lS7gwAdJhhZQFB+/sHm6bU3Y+TWcfbD9Ng=; b=SXtaSKgzWbISJq4KTUzYE5fyZv/i/wGAGj14Z67zo3Il964pMJ6dc/K8lz0lCzZw5m F4AsmSVhzfKx4HupghzVDWoAj2I/xlvn0Vfok87qlf6X4KKs8djrbweUnx+lAvTAZ4e9 yl83YWe4fiF6mIDvSWDV02ZN9RB1hsmX0xDtEA5vYBaf3pYJ0EHbMRIZj2zHQOC042oE ffNgRP3Ty8IvCsEU7D4ssqyXThNXHKZnp7BrsqLW77CxEsXzmEOWmxjN5MvZRXzC8Udo mXSdewziDrQVF4qPWuB9e26lg+Dk1kAKG/XLVmfcs7WwMGpZ7ANn9iSdksl5lxCz+F2w vcYg== X-Gm-Message-State: AMke39mz8YX9MMcQ29xSR4p4P++ddgCpBsSxhtutSi1CGRsqHpzYTQQRdLtZQhnvdDwvnKjAJjJ8cSr1qcrHiw== X-Received: by 10.237.33.240 with SMTP id m45mr36392620qtc.246.1489438538152; Mon, 13 Mar 2017 13:55:38 -0700 (PDT) MIME-Version: 1.0 Received: by 10.140.104.200 with HTTP; Mon, 13 Mar 2017 13:55:37 -0700 (PDT) In-Reply-To: <201703132049.v2DKnVvm042064@repo.freebsd.org> References: <201703132049.v2DKnVvm042064@repo.freebsd.org> From: Ngie Cooper Date: Mon, 13 Mar 2017 13:55:37 -0700 Message-ID: Subject: Re: svn commit: r315214 - head/usr.sbin/mpsutil To: "Pedro F. Giffuni" Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 20:55:39 -0000 On Mon, Mar 13, 2017 at 1:49 PM, Pedro F. Giffuni wrote: > Author: pfg > Date: Mon Mar 13 20:49:31 2017 > New Revision: 315214 > URL: https://svnweb.freebsd.org/changeset/base/315214 > > Log: > mpsutil(8): let calloc(3) do the multiplying. Should this change and the next one (ypbind) be MFCed? Thanks! -Ngie From owner-svn-src-all@freebsd.org Mon Mar 13 21:20:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 877D0D0A931 for ; Mon, 13 Mar 2017 21:20:19 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from nm2-vm5.bullet.mail.ne1.yahoo.com (nm2-vm5.bullet.mail.ne1.yahoo.com [98.138.91.224]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 526981322 for ; Mon, 13 Mar 2017 21:20:18 +0000 (UTC) (envelope-from pfg@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1489440012; bh=l63FPBqGMlaVHeg/LTHY4ad0wc5TWfCluEJOsyzapXo=; h=Subject:To:References:Cc:From:Date:In-Reply-To:From:Subject; b=cuJOjD0BdNTVXNRodTtmL0uHMrVpAcxPXEdTqp7Rgi5m2beK01+fKIDJOC3g1GiO0orj1Dh9n39ovMwi2MDW0ljeAQWuB3t3k20WeI5pDFm0bzR7ikkhBbUz5TelHlohyUPAuBQIz2OF3vQ6TMIsZexqcViIp88A+8LSTiM/uLIrVRM9LmOTsrERX9uiDccXSZLufOZYxkS077Li0fOo+9iMZZFNW1lSH+i1K7J2v/CwSCJYCNFHgH1a7T/JWr0LbAG6W16J0zCpG/1pCMER2oLRcYd+N6fu7uz8Qeq3XHtBBCecWNIsGsAd82y3fFrlt8NXxSp2BSh1su0L+XaApg== Received: from [98.138.101.128] by nm2.bullet.mail.ne1.yahoo.com with NNFMP; 13 Mar 2017 21:20:12 -0000 Received: from [98.138.226.61] by tm16.bullet.mail.ne1.yahoo.com with NNFMP; 13 Mar 2017 21:20:12 -0000 Received: from [127.0.0.1] by smtp212.mail.ne1.yahoo.com with NNFMP; 13 Mar 2017 21:20:12 -0000 X-Yahoo-Newman-Id: 826596.98204.bm@smtp212.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: zKE1SoYVM1lbTEl6c7LCxxNoRNVhUSwUwHZu8HPN6MtbnaK NaQd9vqLnCjfY0.wmXediqRQl7Rk8pYZ9GxLOlmhQfZih602NrdMHo5iEIYH 2FRv5XMT_W01asc6JhFu4KZdjB66rjm5_JkrmEqpToR3muyfhteO7FvR8Vdp .J3urtVVkaBUOzT6I4qsJLpMZC9azQiByhD09pgUq5h0x6HBYuqRQXcq.K7F qnqWVypykPVYHjyLLcBS2SeKKbxCUVvzJmRR4abdTxkNV.43armHJF9L88_y L7lyh9YG5TdZsM9iEWCouVjsd5J60VFAy1ieLJMkJ2nAu6srM0PLTrlUt0l4 dwfIOsDDFRgIOeNMr6ze24grl82.Ev8yZD4FmX.0b0uxXT5u9DPJljfD5TZ1 43Ru7Mz0B2.UFXpQoTfIzX9fjMC3ZmeHMsHXdzHmzhkNacJntZBExIYCjJR3 v74sWcdP1xHip3qbh1SqbfQTlU5BuB9Q7cTFz7Tr8gexAPTRIVl9liSZCNY5 DlPQaokNPgzsR.8NN9IJKCeN8QDocJsItGTiIim.ZDLJ0 X-Yahoo-SMTP: xcjD0guswBAZaPPIbxpWwLcp9Unf Subject: Re: svn commit: r315214 - head/usr.sbin/mpsutil To: Ngie Cooper References: <201703132049.v2DKnVvm042064@repo.freebsd.org> Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" From: Pedro Giffuni Message-ID: Date: Mon, 13 Mar 2017 16:23:20 -0500 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 21:20:19 -0000 On 3/13/2017 3:55 PM, Ngie Cooper wrote: > On Mon, Mar 13, 2017 at 1:49 PM, Pedro F. Giffuni wrote: >> Author: pfg >> Date: Mon Mar 13 20:49:31 2017 >> New Revision: 315214 >> URL: https://svnweb.freebsd.org/changeset/base/315214 >> >> Log: >> mpsutil(8): let calloc(3) do the multiplying. > Should this change and the next one (ypbind) be MFCed? They are really minor and they hit my lazyness threshold. I don't think I want to be reminded, at least not for now :-P. Pedro. From owner-svn-src-all@freebsd.org Mon Mar 13 22:45:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 058B0D0A1DE; Mon, 13 Mar 2017 22:45:53 +0000 (UTC) (envelope-from jlh@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ADFA11634; Mon, 13 Mar 2017 22:45:52 +0000 (UTC) (envelope-from jlh@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DMjpQ1090183; Mon, 13 Mar 2017 22:45:51 GMT (envelope-from jlh@FreeBSD.org) Received: (from jlh@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DMjprg090182; Mon, 13 Mar 2017 22:45:51 GMT (envelope-from jlh@FreeBSD.org) Message-Id: <201703132245.v2DMjprg090182@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jlh set sender to jlh@FreeBSD.org using -f From: Jeremie Le Hen Date: Mon, 13 Mar 2017 22:45:51 +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: r315216 - stable/11/share/man/man7 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 22:45:53 -0000 Author: jlh Date: Mon Mar 13 22:45:51 2017 New Revision: 315216 URL: https://svnweb.freebsd.org/changeset/base/315216 Log: MFC r314995: Add a very natural, binary version of the ASCII table. Reviewed by: bcr, eadler Obtained from: https://garbagecollected.org/2017/01/31/four-column-ascii/ Differential Revision: https://reviews.freebsd.org/D9902 Modified: stable/11/share/man/man7/ascii.7 Modified: stable/11/share/man/man7/ascii.7 ============================================================================== --- stable/11/share/man/man7/ascii.7 Mon Mar 13 20:51:00 2017 (r315215) +++ stable/11/share/man/man7/ascii.7 Mon Mar 13 22:45:51 2017 (r315216) @@ -28,12 +28,12 @@ .\" @(#)ascii.7 8.1 (Berkeley) 6/5/93 .\" $FreeBSD$ .\" -.Dd January 6, 2016 +.Dd March 10, 2017 .Dt ASCII 7 .Os .Sh NAME .Nm ascii -.Nd octal, hexadecimal and decimal +.Nd octal, hexadecimal, decimal and binary .Tn ASCII character sets .Sh DESCRIPTION @@ -102,6 +102,46 @@ set: 112 p 113 q 114 r 115 s 116 t 117 u 118 v 119 w 120 x 121 y 122 z 123 { 124 | 125 } 126 ~ 127 DEL .Ed +.Pp +The +.Nm binary +set: +.Bd -literal -offset left + 00 01 10 11 + +NUL SP @ ` 00000 +SOH ! A a 00001 +STX " B b 00010 +ETX # C c 00011 +EOT $ D d 00100 +ENQ % E e 00101 +ACK & F f 00110 +BEL ' G g 00111 + BS ( H h 01000 + HT ) I i 01001 + LF * J j 01010 + VT + K k 01011 + FF , L l 01100 + CR - M m 01101 + SO . N n 01110 + SI / O o 01111 +DLE 0 P p 10000 +DC1 1 Q q 10001 +DC2 2 R r 10010 +DC3 3 S s 10011 +DC4 4 T t 10100 +NAK 5 U u 10101 +SYN 6 V v 10110 +ETB 7 W w 10111 +CAN 8 X x 11000 + EM 9 Y y 11001 +SUB : Z z 11010 +ESC ; [ { 11011 + FS < \ | 11100 + GS = ] } 11101 + RS > ^ - 11110 + US ? _ DEL 11111 +.Ed .Sh FILES .Bl -tag -width /usr/share/misc/ascii -compact .It Pa /usr/share/misc/ascii From owner-svn-src-all@freebsd.org Mon Mar 13 22:53:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 59363D0A417; Mon, 13 Mar 2017 22:53:08 +0000 (UTC) (envelope-from sbruno@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 219691AF3; Mon, 13 Mar 2017 22:53:08 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2DMr7dJ094180; Mon, 13 Mar 2017 22:53:07 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2DMr7Qq094175; Mon, 13 Mar 2017 22:53:07 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201703132253.v2DMr7Qq094175@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Mon, 13 Mar 2017 22:53:06 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315217 - in head/sys: dev/bnxt dev/e1000 net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Mar 2017 22:53:08 -0000 Author: sbruno Date: Mon Mar 13 22:53:06 2017 New Revision: 315217 URL: https://svnweb.freebsd.org/changeset/base/315217 Log: IFLIB updates - unconditionally enable BUS_DMA on non-x86 architectures - speed up rxd zeroing via customized function - support out of order updates to rxd's - add prefetching to hardware descriptor rings - only prefetch on 10G or faster hardware - add seperate tx queue intr function - preliminary rework of NETMAP interfaces, WIP Submitted by: Matt Macy Sponsored by: Limelight Networks Modified: head/sys/dev/bnxt/bnxt_txrx.c head/sys/dev/bnxt/if_bnxt.c head/sys/dev/e1000/em_txrx.c head/sys/dev/e1000/if_em.c head/sys/dev/e1000/if_em.h head/sys/dev/e1000/igb_txrx.c head/sys/net/ifdi_if.m head/sys/net/iflib.c head/sys/net/iflib.h Modified: head/sys/dev/bnxt/bnxt_txrx.c ============================================================================== --- head/sys/dev/bnxt/bnxt_txrx.c Mon Mar 13 22:45:51 2017 (r315216) +++ head/sys/dev/bnxt/bnxt_txrx.c Mon Mar 13 22:53:06 2017 (r315217) @@ -48,17 +48,19 @@ __FBSDID("$FreeBSD$"); */ static int bnxt_isc_txd_encap(void *sc, if_pkt_info_t pi); -static void bnxt_isc_txd_flush(void *sc, uint16_t txqid, uint32_t pidx); -static int bnxt_isc_txd_credits_update(void *sc, uint16_t txqid, uint32_t cidx, - bool clear); +static void bnxt_isc_txd_flush(void *sc, uint16_t txqid, qidx_t pidx); +static int bnxt_isc_txd_credits_update(void *sc, uint16_t txqid, bool clear); -static void bnxt_isc_rxd_refill(void *sc, uint16_t rxqid, uint8_t flid, +static void bnxt_isc_rxd_refill(void *sc, if_rxd_update_t iru); + +/* uint16_t rxqid, uint8_t flid, uint32_t pidx, uint64_t *paddrs, caddr_t *vaddrs, uint16_t count, uint16_t buf_size); +*/ static void bnxt_isc_rxd_flush(void *sc, uint16_t rxqid, uint8_t flid, - uint32_t pidx); -static int bnxt_isc_rxd_available(void *sc, uint16_t rxqid, uint32_t idx, - int budget); + qidx_t pidx); +static int bnxt_isc_rxd_available(void *sc, uint16_t rxqid, qidx_t idx, + qidx_t budget); static int bnxt_isc_rxd_pkt_get(void *sc, if_rxd_info_t ri); static int bnxt_intr(void *sc); @@ -172,7 +174,7 @@ bnxt_isc_txd_encap(void *sc, if_pkt_info } static void -bnxt_isc_txd_flush(void *sc, uint16_t txqid, uint32_t pidx) +bnxt_isc_txd_flush(void *sc, uint16_t txqid, qidx_t pidx) { struct bnxt_softc *softc = (struct bnxt_softc *)sc; struct bnxt_ring *tx_ring = &softc->tx_rings[txqid]; @@ -185,7 +187,7 @@ bnxt_isc_txd_flush(void *sc, uint16_t tx } static int -bnxt_isc_txd_credits_update(void *sc, uint16_t txqid, uint32_t idx, bool clear) +bnxt_isc_txd_credits_update(void *sc, uint16_t txqid, bool clear) { struct bnxt_softc *softc = (struct bnxt_softc *)sc; struct bnxt_cp_ring *cpr = &softc->tx_cp_rings[txqid]; @@ -249,15 +251,27 @@ done: } static void -bnxt_isc_rxd_refill(void *sc, uint16_t rxqid, uint8_t flid, - uint32_t pidx, uint64_t *paddrs, - caddr_t *vaddrs, uint16_t count, uint16_t len) +bnxt_isc_rxd_refill(void *sc, if_rxd_update_t iru) { struct bnxt_softc *softc = (struct bnxt_softc *)sc; struct bnxt_ring *rx_ring; struct rx_prod_pkt_bd *rxbd; uint16_t type; uint16_t i; + uint16_t rxqid; + uint16_t count, len; + uint32_t pidx; + uint8_t flid; + uint64_t *paddrs; + caddr_t *vaddrs; + + rxqid = iru->iru_qsidx; + count = iru->iru_count; + len = iru->iru_buf_size; + pidx = iru->iru_pidx; + flid = iru->iru_flidx; + vaddrs = iru->iru_vaddrs; + paddrs = iru->iru_paddrs; if (flid == 0) { rx_ring = &softc->rx_rings[rxqid]; @@ -284,7 +298,7 @@ bnxt_isc_rxd_refill(void *sc, uint16_t r static void bnxt_isc_rxd_flush(void *sc, uint16_t rxqid, uint8_t flid, - uint32_t pidx) + qidx_t pidx) { struct bnxt_softc *softc = (struct bnxt_softc *)sc; struct bnxt_ring *rx_ring; @@ -310,7 +324,7 @@ bnxt_isc_rxd_flush(void *sc, uint16_t rx } static int -bnxt_isc_rxd_available(void *sc, uint16_t rxqid, uint32_t idx, int budget) +bnxt_isc_rxd_available(void *sc, uint16_t rxqid, qidx_t idx, qidx_t budget) { struct bnxt_softc *softc = (struct bnxt_softc *)sc; struct bnxt_cp_ring *cpr = &softc->rx_cp_rings[rxqid]; @@ -412,37 +426,6 @@ cmpl_invalid: return avail; } -static void -bnxt_set_rsstype(if_rxd_info_t ri, uint8_t rss_hash_type) -{ - uint8_t rss_profile_id; - - rss_profile_id = BNXT_GET_RSS_PROFILE_ID(rss_hash_type); - switch (rss_profile_id) { - case BNXT_RSS_HASH_TYPE_TCPV4: - ri->iri_rsstype = M_HASHTYPE_RSS_TCP_IPV4; - break; - case BNXT_RSS_HASH_TYPE_UDPV4: - ri->iri_rsstype = M_HASHTYPE_RSS_UDP_IPV4; - break; - case BNXT_RSS_HASH_TYPE_IPV4: - ri->iri_rsstype = M_HASHTYPE_RSS_IPV4; - break; - case BNXT_RSS_HASH_TYPE_TCPV6: - ri->iri_rsstype = M_HASHTYPE_RSS_TCP_IPV6; - break; - case BNXT_RSS_HASH_TYPE_UDPV6: - ri->iri_rsstype = M_HASHTYPE_RSS_UDP_IPV6; - break; - case BNXT_RSS_HASH_TYPE_IPV6: - ri->iri_rsstype = M_HASHTYPE_RSS_IPV6; - break; - default: - ri->iri_rsstype = M_HASHTYPE_OPAQUE; - break; - } -} - static int bnxt_pkt_get_l2(struct bnxt_softc *softc, if_rxd_info_t ri, struct bnxt_cp_ring *cpr, uint16_t flags_type) @@ -460,7 +443,13 @@ bnxt_pkt_get_l2(struct bnxt_softc *softc /* Extract from the first 16-byte BD */ if (flags_type & RX_PKT_CMPL_FLAGS_RSS_VALID) { ri->iri_flowid = le32toh(rcp->rss_hash); - bnxt_set_rsstype(ri, rcp->rss_hash_type); + /* + * TODO: Extract something useful from rcp->rss_hash_type + * (undocumented) + * May be documented in the "LSI ES" + * also check the firmware code. + */ + ri->iri_rsstype = M_HASHTYPE_OPAQUE; } else { ri->iri_rsstype = M_HASHTYPE_NONE; @@ -540,7 +529,13 @@ bnxt_pkt_get_tpa(struct bnxt_softc *soft /* Extract from the first 16-byte BD */ if (le16toh(tpas->low.flags_type) & RX_TPA_START_CMPL_FLAGS_RSS_VALID) { ri->iri_flowid = le32toh(tpas->low.rss_hash); - bnxt_set_rsstype(ri, tpas->low.rss_hash_type); + /* + * TODO: Extract something useful from tpas->low.rss_hash_type + * (undocumented) + * May be documented in the "LSI ES" + * also check the firmware code. + */ + ri->iri_rsstype = M_HASHTYPE_OPAQUE; } else { ri->iri_rsstype = M_HASHTYPE_NONE; Modified: head/sys/dev/bnxt/if_bnxt.c ============================================================================== --- head/sys/dev/bnxt/if_bnxt.c Mon Mar 13 22:45:51 2017 (r315216) +++ head/sys/dev/bnxt/if_bnxt.c Mon Mar 13 22:53:06 2017 (r315217) @@ -253,7 +253,8 @@ static device_method_t bnxt_iflib_method DEVMETHOD(ifdi_update_admin_status, bnxt_update_admin_status), DEVMETHOD(ifdi_intr_enable, bnxt_intr_enable), - DEVMETHOD(ifdi_queue_intr_enable, bnxt_queue_intr_enable), + DEVMETHOD(ifdi_tx_queue_intr_enable, bnxt_queue_intr_enable), + DEVMETHOD(ifdi_rx_queue_intr_enable, bnxt_queue_intr_enable), DEVMETHOD(ifdi_intr_disable, bnxt_disable_intr), DEVMETHOD(ifdi_msix_intr_assign, bnxt_msix_intr_assign), @@ -711,6 +712,8 @@ bnxt_attach_pre(if_ctx_t ctx) scctx->isc_tx_tso_size_max = BNXT_TSO_SIZE; scctx->isc_tx_tso_segsize_max = BNXT_TSO_SIZE; scctx->isc_vectors = softc->func.max_cp_rings; + scctx->isc_txrx = &bnxt_txrx; + if (scctx->isc_nrxd[0] < ((scctx->isc_nrxd[1] * 4) + scctx->isc_nrxd[2])) device_printf(softc->dev, @@ -1479,7 +1482,7 @@ bnxt_msix_intr_assign(if_ctx_t ctx, int for (i=0; iscctx->isc_nrxqsets; i++) { rc = iflib_irq_alloc_generic(ctx, &softc->rx_cp_rings[i].irq, - softc->rx_cp_rings[i].ring.id + 1, IFLIB_INTR_RX, + softc->rx_cp_rings[i].ring.id + 1, IFLIB_INTR_RXTX, bnxt_handle_rx_cp, &softc->rx_cp_rings[i], i, "rx_cp"); if (rc) { device_printf(iflib_get_dev(ctx), Modified: head/sys/dev/e1000/em_txrx.c ============================================================================== --- head/sys/dev/e1000/em_txrx.c Mon Mar 13 22:45:51 2017 (r315216) +++ head/sys/dev/e1000/em_txrx.c Mon Mar 13 22:53:06 2017 (r315217) @@ -1,5 +1,5 @@ /*- - * Copyright (c) 2016 Matt Macy + * Copyright (c) 2016-2017 Matt Macy * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -27,7 +27,7 @@ /* $FreeBSD$ */ #include "if_em.h" -#ifdef RSS +#ifdef RSS #include #include #endif @@ -41,23 +41,24 @@ /********************************************************************* * Local Function prototypes *********************************************************************/ -static int em_tso_setup(struct adapter *adapter, if_pkt_info_t pi, u32 *txd_upper, u32 *txd_lower); -static int em_transmit_checksum_setup(struct adapter *adapter, if_pkt_info_t pi, u32 *txd_upper, u32 *txd_lower); +static int em_tso_setup(struct adapter *adapter, if_pkt_info_t pi, u32 *txd_upper, + u32 *txd_lower); +static int em_transmit_checksum_setup(struct adapter *adapter, if_pkt_info_t pi, + u32 *txd_upper, u32 *txd_lower); static int em_isc_txd_encap(void *arg, if_pkt_info_t pi); -static void em_isc_txd_flush(void *arg, uint16_t txqid, uint32_t pidx); -static int em_isc_txd_credits_update(void *arg, uint16_t txqid, uint32_t cidx_init, bool clear); -static void em_isc_rxd_refill(void *arg, uint16_t rxqid, uint8_t flid __unused, - uint32_t pidx, uint64_t *paddrs, caddr_t *vaddrs __unused, uint16_t count, uint16_t buflen __unused); -static void em_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, uint32_t pidx); -static int em_isc_rxd_available(void *arg, uint16_t rxqid, uint32_t idx, - int budget); +static void em_isc_txd_flush(void *arg, uint16_t txqid, qidx_t pidx); +static int em_isc_txd_credits_update(void *arg, uint16_t txqid, bool clear); +static void em_isc_rxd_refill(void *arg, if_rxd_update_t iru); +static void em_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, + qidx_t pidx); +static int em_isc_rxd_available(void *arg, uint16_t rxqid, qidx_t idx, + qidx_t budget); static int em_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri); -static void lem_isc_rxd_refill(void *arg, uint16_t rxqid, uint8_t flid __unused, - uint32_t pidx, uint64_t *paddrs, caddr_t *vaddrs __unused, uint16_t count, uint16_t buflen __unused); +static void lem_isc_rxd_refill(void *arg, if_rxd_update_t iru); -static int lem_isc_rxd_available(void *arg, uint16_t rxqid, uint32_t idx, - int budget); +static int lem_isc_rxd_available(void *arg, uint16_t rxqid, qidx_t idx, + qidx_t budget); static int lem_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri); static void lem_receive_checksum(int status, int errors, if_rxd_info_t ri); @@ -65,7 +66,7 @@ static void em_receive_checksum(uint32_t static int em_determine_rsstype(u32 pkt_info); extern int em_intr(void *arg); -struct if_txrx em_txrx = { +struct if_txrx em_txrx = { em_isc_txd_encap, em_isc_txd_flush, em_isc_txd_credits_update, @@ -76,7 +77,7 @@ struct if_txrx em_txrx = { em_intr }; -struct if_txrx lem_txrx = { +struct if_txrx lem_txrx = { em_isc_txd_encap, em_isc_txd_flush, em_isc_txd_credits_update, @@ -87,7 +88,42 @@ struct if_txrx lem_txrx = { em_intr }; -extern if_shared_ctx_t em_sctx; +extern if_shared_ctx_t em_sctx; + +void +em_dump_rs(struct adapter *adapter) +{ + if_softc_ctx_t scctx = adapter->shared; + struct em_tx_queue *que; + struct tx_ring *txr; + qidx_t i, ntxd, qid, cur; + int16_t rs_cidx; + uint8_t status; + + printf("\n"); + ntxd = scctx->isc_ntxd[0]; + for (qid = 0; qid < adapter->tx_num_queues; qid++) { + que = &adapter->tx_queues[qid]; + txr = &que->txr; + rs_cidx = txr->tx_rs_cidx; + if (rs_cidx != txr->tx_rs_pidx) { + cur = txr->tx_rsq[rs_cidx]; + status = txr->tx_base[cur].upper.fields.status; + if (!(status & E1000_TXD_STAT_DD)) + printf("qid[%d]->tx_rsq[%d]: %d clear ", qid, rs_cidx, cur); + } else { + rs_cidx = (rs_cidx-1)&(ntxd-1); + cur = txr->tx_rsq[rs_cidx]; + printf("qid[%d]->tx_rsq[rs_cidx-1=%d]: %d ", qid, rs_cidx, cur); + } + printf("cidx_prev=%d rs_pidx=%d ",txr->tx_cidx_processed, txr->tx_rs_pidx); + for (i = 0; i < ntxd; i++) { + if (txr->tx_base[i].upper.fields.status & E1000_TXD_STAT_DD) + printf("%d set ", i); + } + printf("\n"); + } +} /********************************************************************** * @@ -99,14 +135,13 @@ static int em_tso_setup(struct adapter *adapter, if_pkt_info_t pi, u32 *txd_upper, u32 *txd_lower) { if_softc_ctx_t scctx = adapter->shared; - struct em_tx_queue *que = &adapter->tx_queues[pi->ipi_qsidx]; - struct tx_ring *txr = &que->txr; + struct em_tx_queue *que = &adapter->tx_queues[pi->ipi_qsidx]; + struct tx_ring *txr = &que->txr; struct e1000_context_desc *TXD; - struct em_txbuffer *tx_buffer; - int cur, hdr_len; + int cur, hdr_len; hdr_len = pi->ipi_ehdrlen + pi->ipi_ip_hlen + pi->ipi_tcp_hlen; - *txd_lower = (E1000_TXD_CMD_DEXT | /* Extended descr type */ + *txd_lower = (E1000_TXD_CMD_DEXT | /* Extended descr type */ E1000_TXD_DTYP_D | /* Data descr type */ E1000_TXD_CMD_TSE); /* Do TSE on this packet */ @@ -114,10 +149,9 @@ em_tso_setup(struct adapter *adapter, if *txd_upper = (E1000_TXD_POPTS_IXSM | E1000_TXD_POPTS_TXSM) << 8; cur = pi->ipi_pidx; - TXD = (struct e1000_context_desc *)&txr->tx_base[cur]; - tx_buffer = &txr->tx_buffers[cur]; - - /* + TXD = (struct e1000_context_desc *)&txr->tx_base[cur]; + + /* * Start offset for header checksum calculation. * End offset for header checksum calculation. * Offset of place put the checksum. @@ -127,7 +161,7 @@ em_tso_setup(struct adapter *adapter, if htole16(pi->ipi_ehdrlen + pi->ipi_ip_hlen - 1); TXD->lower_setup.ip_fields.ipcso = pi->ipi_ehdrlen + offsetof(struct ip, ip_sum); - /* + /* * Start offset for payload checksum calculation. * End offset for payload checksum calculation. * Offset of place to put the checksum. @@ -136,8 +170,8 @@ em_tso_setup(struct adapter *adapter, if TXD->upper_setup.tcp_fields.tucse = 0; TXD->upper_setup.tcp_fields.tucso = pi->ipi_ehdrlen + pi->ipi_ip_hlen + offsetof(struct tcphdr, th_sum); - - /* + + /* * Payload size per packet w/o any headers. * Length of all headers up to payload. */ @@ -150,7 +184,6 @@ em_tso_setup(struct adapter *adapter, if E1000_TXD_CMD_IP | /* Do IP csum */ E1000_TXD_CMD_TCP | /* Do TCP checksum */ (pi->ipi_len - hdr_len)); /* Total len */ - tx_buffer->eop = -1; txr->tx_tso = TRUE; if (++cur == scctx->isc_ntxd[0]) { @@ -178,21 +211,20 @@ em_tso_setup(struct adapter *adapter, if * until the previous request completes. This means setting up * a new context effectively disables pipelined Tx data DMA which * in turn greatly slow down performance to send small sized - * frames. + * frames. **********************************************************************/ static int em_transmit_checksum_setup(struct adapter *adapter, if_pkt_info_t pi, u32 *txd_upper, u32 *txd_lower) { - struct e1000_context_desc *TXD = NULL; - if_softc_ctx_t scctx = adapter->shared; - struct em_tx_queue *que = &adapter->tx_queues[pi->ipi_qsidx]; - struct tx_ring *txr = &que->txr; - struct em_txbuffer *tx_buffer; - int csum_flags = pi->ipi_csum_flags; - int cur, hdr_len; - u32 cmd; - + struct e1000_context_desc *TXD = NULL; + if_softc_ctx_t scctx = adapter->shared; + struct em_tx_queue *que = &adapter->tx_queues[pi->ipi_qsidx]; + struct tx_ring *txr = &que->txr; + int csum_flags = pi->ipi_csum_flags; + int cur, hdr_len; + u32 cmd; + cur = pi->ipi_pidx; hdr_len = pi->ipi_ehdrlen + pi->ipi_ip_hlen; cmd = adapter->txd_cmd; @@ -220,7 +252,7 @@ em_transmit_checksum_setup(struct adapte TXD = (struct e1000_context_desc *)&txr->tx_base[cur]; if (csum_flags & CSUM_IP) { - *txd_upper |= E1000_TXD_POPTS_IXSM << 8; + *txd_upper |= E1000_TXD_POPTS_IXSM << 8; /* * Start offset for header checksum calculation. * End offset for header checksum calculation. @@ -235,7 +267,7 @@ em_transmit_checksum_setup(struct adapte if (csum_flags & (CSUM_TCP|CSUM_UDP)) { uint8_t tucso; - *txd_upper |= E1000_TXD_POPTS_TXSM << 8; + *txd_upper |= E1000_TXD_POPTS_TXSM << 8; *txd_lower = E1000_TXD_CMD_DEXT | E1000_TXD_DTYP_D; if (csum_flags & CSUM_TCP) { @@ -243,9 +275,9 @@ em_transmit_checksum_setup(struct adapte cmd |= E1000_TXD_CMD_TCP; } else tucso = hdr_len + offsetof(struct udphdr, uh_sum); - TXD->upper_setup.tcp_fields.tucss = hdr_len; - TXD->upper_setup.tcp_fields.tucse = htole16(0); - TXD->upper_setup.tcp_fields.tucso = tucso; + TXD->upper_setup.tcp_fields.tucss = hdr_len; + TXD->upper_setup.tcp_fields.tucse = htole16(0); + TXD->upper_setup.tcp_fields.tucso = tucso; } txr->csum_lhlen = pi->ipi_ehdrlen; @@ -258,9 +290,6 @@ em_transmit_checksum_setup(struct adapte TXD->cmd_and_length = htole32(E1000_TXD_CMD_IFCS | E1000_TXD_CMD_DEXT | cmd); - tx_buffer = &txr->tx_buffers[cur]; - tx_buffer->eop = -1; - if (++cur == scctx->isc_ntxd[0]) { cur = 0; } @@ -272,24 +301,26 @@ em_transmit_checksum_setup(struct adapte static int em_isc_txd_encap(void *arg, if_pkt_info_t pi) { - struct adapter *sc = arg; - if_softc_ctx_t scctx = sc->shared; - struct em_tx_queue *que = &sc->tx_queues[pi->ipi_qsidx]; - struct tx_ring *txr = &que->txr; - bus_dma_segment_t *segs = pi->ipi_segs; - int nsegs = pi->ipi_nsegs; - int csum_flags = pi->ipi_csum_flags; - int i, j, first, pidx_last; - u32 txd_upper = 0, txd_lower = 0; - - struct em_txbuffer *tx_buffer; + struct adapter *sc = arg; + if_softc_ctx_t scctx = sc->shared; + struct em_tx_queue *que = &sc->tx_queues[pi->ipi_qsidx]; + struct tx_ring *txr = &que->txr; + bus_dma_segment_t *segs = pi->ipi_segs; + int nsegs = pi->ipi_nsegs; + int csum_flags = pi->ipi_csum_flags; + int i, j, first, pidx_last; + u32 txd_flags, txd_upper = 0, txd_lower = 0; + struct e1000_tx_desc *ctxd = NULL; - bool do_tso, tso_desc; - - i = first = pi->ipi_pidx; + bool do_tso, tso_desc; + qidx_t ntxd; + + txd_flags = pi->ipi_flags & IPI_TX_INTR ? E1000_TXD_CMD_RS : 0; + i = first = pi->ipi_pidx; do_tso = (csum_flags & CSUM_TSO); tso_desc = FALSE; - /* + ntxd = scctx->isc_ntxd[0]; + /* * TSO Hardware workaround, if this packet is not * TSO, and is only a single descriptor long, and * it follows a TSO burst, then we need to add a @@ -310,10 +341,10 @@ em_isc_txd_encap(void *arg, if_pkt_info_ } if (pi->ipi_mflags & M_VLANTAG) { - /* Set the vlan id. */ + /* Set the vlan id. */ txd_upper |= htole16(pi->ipi_vtag) << 16; - /* Tell hardware to add tag */ - txd_lower |= htole32(E1000_TXD_CMD_VLE); + /* Tell hardware to add tag */ + txd_lower |= htole32(E1000_TXD_CMD_VLE); } DPRINTF(iflib_get_dev(sc->ctx), "encap: set up tx: nsegs=%d first=%d i=%d\n", nsegs, first, i); @@ -326,28 +357,26 @@ em_isc_txd_encap(void *arg, if_pkt_info_ uint32_t cmd; ctxd = &txr->tx_base[i]; - tx_buffer = &txr->tx_buffers[i]; seg_addr = segs[j].ds_addr; seg_len = segs[j].ds_len; cmd = E1000_TXD_CMD_IFCS | sc->txd_cmd; /* - ** TSO Workaround: - ** If this is the last descriptor, we want to - ** split it so we have a small final sentinel - */ + * TSO Workaround: + * If this is the last descriptor, we want to + * split it so we have a small final sentinel + */ if (tso_desc && (j == (nsegs - 1)) && (seg_len > 8)) { seg_len -= TSO_WORKAROUND; ctxd->buffer_addr = htole64(seg_addr); ctxd->lower.data = htole32(cmd | txd_lower | seg_len); ctxd->upper.data = htole32(txd_upper); - if (++i == scctx->isc_ntxd[0]) + if (++i == scctx->isc_ntxd[0]) i = 0; /* Now make the sentinel */ ctxd = &txr->tx_base[i]; - tx_buffer = &txr->tx_buffers[i]; ctxd->buffer_addr = htole64(seg_addr + seg_len); ctxd->lower.data = htole32(cmd | txd_lower | TSO_WORKAROUND); ctxd->upper.data = htole32(txd_upper); @@ -364,27 +393,28 @@ em_isc_txd_encap(void *arg, if_pkt_info_ i = 0; DPRINTF(iflib_get_dev(sc->ctx), "pidx_last=%d i=%d ntxd[0]=%d\n", pidx_last, i, scctx->isc_ntxd[0]); } - tx_buffer->eop = -1; } /* - * Last Descriptor of Packet + * Last Descriptor of Packet * needs End Of Packet (EOP) * and Report Status (RS) - */ - ctxd->lower.data |= - htole32(E1000_TXD_CMD_EOP | E1000_TXD_CMD_RS); - - tx_buffer = &txr->tx_buffers[first]; - tx_buffer->eop = pidx_last; + */ + if (txd_flags) { + txr->tx_rsq[txr->tx_rs_pidx] = pidx_last; + DPRINTF(iflib_get_dev(sc->ctx), "setting to RS on %d rs_pidx %d first: %d\n", pidx_last, txr->tx_rs_pidx, first); + txr->tx_rs_pidx = (txr->tx_rs_pidx+1) & (ntxd-1); + MPASS(txr->tx_rs_pidx != txr->tx_rs_cidx); + } + ctxd->lower.data |= htole32(E1000_TXD_CMD_EOP | txd_flags); DPRINTF(iflib_get_dev(sc->ctx), "tx_buffers[%d]->eop = %d ipi_new_pidx=%d\n", first, pidx_last, i); pi->ipi_new_pidx = i; - return (0); + return (0); } static void -em_isc_txd_flush(void *arg, uint16_t txqid, uint32_t pidx) +em_isc_txd_flush(void *arg, uint16_t txqid, qidx_t pidx) { struct adapter *adapter = arg; struct em_tx_queue *que = &adapter->tx_queues[txqid]; @@ -394,86 +424,72 @@ em_isc_txd_flush(void *arg, uint16_t txq } static int -em_isc_txd_credits_update(void *arg, uint16_t txqid, uint32_t cidx_init, bool clear) +em_isc_txd_credits_update(void *arg, uint16_t txqid, bool clear) { struct adapter *adapter = arg; if_softc_ctx_t scctx = adapter->shared; struct em_tx_queue *que = &adapter->tx_queues[txqid]; struct tx_ring *txr = &que->txr; - u32 cidx, processed = 0; - int last, done; - struct em_txbuffer *buf; - struct e1000_tx_desc *tx_desc, *eop_desc; - - cidx = cidx_init; - buf = &txr->tx_buffers[cidx]; - tx_desc = &txr->tx_base[cidx]; - last = buf->eop; - if (last == -1) - return (processed); - eop_desc = &txr->tx_base[last]; - - DPRINTF(iflib_get_dev(adapter->ctx), - "credits_update: cidx_init=%d clear=%d last=%d\n", - cidx_init, clear, last); - /* - * What this does is get the index of the - * first descriptor AFTER the EOP of the - * first packet, that way we can do the - * simple comparison on the inner while loop. - */ - if (++last == scctx->isc_ntxd[0]) - last = 0; - done = last; - - - while (eop_desc->upper.fields.status & E1000_TXD_STAT_DD) { - /* We clean the range of the packet */ - while (cidx != done) { - if (clear) { - tx_desc->upper.data = 0; - tx_desc->lower.data = 0; - tx_desc->buffer_addr = 0; - buf->eop = -1; - } - tx_desc++; - buf++; - processed++; - - /* wrap the ring ? */ - if (++cidx == scctx->isc_ntxd[0]) { - cidx = 0; - } - buf = &txr->tx_buffers[cidx]; - tx_desc = &txr->tx_base[cidx]; - } - /* See if we can continue to the next packet */ - last = buf->eop; - if (last == -1) + qidx_t processed = 0; + int updated; + qidx_t cur, prev, ntxd, rs_cidx; + int32_t delta; + uint8_t status; + + rs_cidx = txr->tx_rs_cidx; + if (rs_cidx == txr->tx_rs_pidx) + return (0); + cur = txr->tx_rsq[rs_cidx]; + MPASS(cur != QIDX_INVALID); + status = txr->tx_base[cur].upper.fields.status; + updated = !!(status & E1000_TXD_STAT_DD); + + if (clear == false || updated == 0) + return (updated); + + prev = txr->tx_cidx_processed; + ntxd = scctx->isc_ntxd[0]; + do { + delta = (int32_t)cur - (int32_t)prev; + MPASS(prev == 0 || delta != 0); + if (delta < 0) + delta += ntxd; + DPRINTF(iflib_get_dev(adapter->ctx), + "%s: cidx_processed=%u cur=%u clear=%d delta=%d\n", + __FUNCTION__, prev, cur, clear, delta); + + processed += delta; + prev = cur; + rs_cidx = (rs_cidx + 1) & (ntxd-1); + if (rs_cidx == txr->tx_rs_pidx) break; - eop_desc = &txr->tx_base[last]; - /* Get new done point */ - if (++last == scctx->isc_ntxd[0]) - last = 0; - done = last; - } + cur = txr->tx_rsq[rs_cidx]; + MPASS(cur != QIDX_INVALID); + status = txr->tx_base[cur].upper.fields.status; + } while ((status & E1000_TXD_STAT_DD)); - DPRINTF(iflib_get_dev(adapter->ctx), "Processed %d credits update\n", processed); + txr->tx_rs_cidx = rs_cidx; + txr->tx_cidx_processed = prev; return(processed); } static void -lem_isc_rxd_refill(void *arg, uint16_t rxqid, uint8_t flid __unused, - uint32_t pidx, uint64_t *paddrs, caddr_t *vaddrs __unused, uint16_t count, uint16_t buflen __unused) +lem_isc_rxd_refill(void *arg, if_rxd_update_t iru) { struct adapter *sc = arg; if_softc_ctx_t scctx = sc->shared; - struct em_rx_queue *que = &sc->rx_queues[rxqid]; + struct em_rx_queue *que = &sc->rx_queues[iru->iru_qsidx]; struct rx_ring *rxr = &que->rxr; struct e1000_rx_desc *rxd; + uint64_t *paddrs; + uint32_t next_pidx, pidx; + uint16_t count; int i; - uint32_t next_pidx; + + paddrs = iru->iru_paddrs; + pidx = iru->iru_pidx; + count = iru->iru_count; for (i = 0, next_pidx = pidx; i < count; i++) { rxd = (struct e1000_rx_desc *)&rxr->rx_base[next_pidx]; @@ -487,48 +503,60 @@ lem_isc_rxd_refill(void *arg, uint16_t r } static void -em_isc_rxd_refill(void *arg, uint16_t rxqid, uint8_t flid __unused, - uint32_t pidx, uint64_t *paddrs, caddr_t *vaddrs __unused, uint16_t count, uint16_t buflen __unused) +em_isc_rxd_refill(void *arg, if_rxd_update_t iru) { struct adapter *sc = arg; if_softc_ctx_t scctx = sc->shared; + uint16_t rxqid = iru->iru_qsidx; struct em_rx_queue *que = &sc->rx_queues[rxqid]; struct rx_ring *rxr = &que->rxr; union e1000_rx_desc_extended *rxd; + uint64_t *paddrs; + uint32_t next_pidx, pidx; + uint16_t count; int i; - uint32_t next_pidx; + + paddrs = iru->iru_paddrs; + pidx = iru->iru_pidx; + count = iru->iru_count; for (i = 0, next_pidx = pidx; i < count; i++) { rxd = &rxr->rx_base[next_pidx]; rxd->read.buffer_addr = htole64(paddrs[i]); /* DD bits must be cleared */ - rxd->wb.upper.status_error = 0; - + rxd->wb.upper.status_error = 0; + if (++next_pidx == scctx->isc_nrxd[0]) next_pidx = 0; } } static void -em_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, uint32_t pidx) +em_isc_rxd_flush(void *arg, uint16_t rxqid, uint8_t flid __unused, qidx_t pidx) { - struct adapter *sc = arg; - struct em_rx_queue *que = &sc->rx_queues[rxqid]; - struct rx_ring *rxr = &que->rxr; + struct adapter *sc = arg; + struct em_rx_queue *que = &sc->rx_queues[rxqid]; + struct rx_ring *rxr = &que->rxr; - E1000_WRITE_REG(&sc->hw, E1000_RDT(rxr->me), pidx); + E1000_WRITE_REG(&sc->hw, E1000_RDT(rxr->me), pidx); } static int -lem_isc_rxd_available(void *arg, uint16_t rxqid, uint32_t idx, int budget) +lem_isc_rxd_available(void *arg, uint16_t rxqid, qidx_t idx, qidx_t budget) { - struct adapter *sc = arg; + struct adapter *sc = arg; if_softc_ctx_t scctx = sc->shared; - struct em_rx_queue *que = &sc->rx_queues[rxqid]; - struct rx_ring *rxr = &que->rxr; + struct em_rx_queue *que = &sc->rx_queues[rxqid]; + struct rx_ring *rxr = &que->rxr; struct e1000_rx_desc *rxd; - u32 staterr = 0; - int cnt, i; + u32 staterr = 0; + int cnt, i; + + if (budget == 1) { + rxd = (struct e1000_rx_desc *)&rxr->rx_base[idx]; + staterr = rxd->status; + return (staterr & E1000_RXD_STAT_DD); + } for (cnt = 0, i = idx; cnt < scctx->isc_nrxd[0] && cnt <= budget;) { rxd = (struct e1000_rx_desc *)&rxr->rx_base[i]; @@ -547,15 +575,21 @@ lem_isc_rxd_available(void *arg, uint16_ } static int -em_isc_rxd_available(void *arg, uint16_t rxqid, uint32_t idx, int budget) +em_isc_rxd_available(void *arg, uint16_t rxqid, qidx_t idx, qidx_t budget) { - struct adapter *sc = arg; + struct adapter *sc = arg; if_softc_ctx_t scctx = sc->shared; - struct em_rx_queue *que = &sc->rx_queues[rxqid]; - struct rx_ring *rxr = &que->rxr; + struct em_rx_queue *que = &sc->rx_queues[rxqid]; + struct rx_ring *rxr = &que->rxr; union e1000_rx_desc_extended *rxd; - u32 staterr = 0; - int cnt, i; + u32 staterr = 0; + int cnt, i; + + if (budget == 1) { + rxd = &rxr->rx_base[idx]; + staterr = le32toh(rxd->wb.upper.status_error); + return (staterr & E1000_RXD_STAT_DD); + } for (cnt = 0, i = idx; cnt < scctx->isc_nrxd[0] && cnt <= budget;) { rxd = &rxr->rx_base[i]; @@ -578,15 +612,15 @@ em_isc_rxd_available(void *arg, uint16_t static int lem_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri) { - struct adapter *adapter = arg; - if_softc_ctx_t scctx = adapter->shared; - struct em_rx_queue *que = &adapter->rx_queues[ri->iri_qsidx]; - struct rx_ring *rxr = &que->rxr; + struct adapter *adapter = arg; + if_softc_ctx_t scctx = adapter->shared; + struct em_rx_queue *que = &adapter->rx_queues[ri->iri_qsidx]; + struct rx_ring *rxr = &que->rxr; struct e1000_rx_desc *rxd; - u16 len; - u32 status, errors; - bool eop; - int i, cidx; + u16 len; + u32 status, errors; + bool eop; + int i, cidx; status = errors = i = 0; cidx = ri->iri_cidx; @@ -639,31 +673,31 @@ lem_isc_rxd_pkt_get(void *arg, if_rxd_in static int em_isc_rxd_pkt_get(void *arg, if_rxd_info_t ri) { - struct adapter *adapter = arg; - if_softc_ctx_t scctx = adapter->shared; - struct em_rx_queue *que = &adapter->rx_queues[ri->iri_qsidx]; - struct rx_ring *rxr = &que->rxr; + struct adapter *adapter = arg; + if_softc_ctx_t scctx = adapter->shared; + struct em_rx_queue *que = &adapter->rx_queues[ri->iri_qsidx]; + struct rx_ring *rxr = &que->rxr; union e1000_rx_desc_extended *rxd; - u16 len; - u32 pkt_info; - u32 staterr = 0; - bool eop; - int i, cidx, vtag; + u16 len; + u32 pkt_info; + u32 staterr = 0; + bool eop; + int i, cidx, vtag; i = vtag = 0; cidx = ri->iri_cidx; do { rxd = &rxr->rx_base[cidx]; - staterr = le32toh(rxd->wb.upper.status_error); + staterr = le32toh(rxd->wb.upper.status_error); pkt_info = le32toh(rxd->wb.lower.mrq); - + /* Error Checking then decrement count */ MPASS ((staterr & E1000_RXD_STAT_DD) != 0); len = le16toh(rxd->wb.upper.length); - ri->iri_len += len; + ri->iri_len += len; eop = (staterr & E1000_RXD_STAT_EOP) != 0; @@ -690,15 +724,14 @@ em_isc_rxd_pkt_get(void *arg, if_rxd_inf if (staterr & E1000_RXD_STAT_VP) { vtag = le16toh(rxd->wb.upper.vlan); - } - + } + ri->iri_vtag = vtag; if (vtag) ri->iri_flags |= M_VLANTAG; - - ri->iri_flowid = - le32toh(rxd->wb.lower.hi_dword.rss); - ri->iri_rsstype = em_determine_rsstype(pkt_info); + + ri->iri_flowid = le32toh(rxd->wb.lower.hi_dword.rss); + ri->iri_rsstype = em_determine_rsstype(pkt_info); ri->iri_nfrags = i; return (0); @@ -736,23 +769,24 @@ lem_receive_checksum(int status, int err static int em_determine_rsstype(u32 pkt_info) { - switch (pkt_info & E1000_RXDADV_RSSTYPE_MASK) { - case E1000_RXDADV_RSSTYPE_IPV4_TCP: - return M_HASHTYPE_RSS_TCP_IPV4; - case E1000_RXDADV_RSSTYPE_IPV4: - return M_HASHTYPE_RSS_IPV4; - case E1000_RXDADV_RSSTYPE_IPV6_TCP: - return M_HASHTYPE_RSS_TCP_IPV6; - case E1000_RXDADV_RSSTYPE_IPV6_EX: - return M_HASHTYPE_RSS_IPV6_EX; - case E1000_RXDADV_RSSTYPE_IPV6: - return M_HASHTYPE_RSS_IPV6; - case E1000_RXDADV_RSSTYPE_IPV6_TCP_EX: - return M_HASHTYPE_RSS_TCP_IPV6_EX; - default: - return M_HASHTYPE_OPAQUE; - } + switch (pkt_info & E1000_RXDADV_RSSTYPE_MASK) { + case E1000_RXDADV_RSSTYPE_IPV4_TCP: + return M_HASHTYPE_RSS_TCP_IPV4; + case E1000_RXDADV_RSSTYPE_IPV4: + return M_HASHTYPE_RSS_IPV4; + case E1000_RXDADV_RSSTYPE_IPV6_TCP: + return M_HASHTYPE_RSS_TCP_IPV6; + case E1000_RXDADV_RSSTYPE_IPV6_EX: + return M_HASHTYPE_RSS_IPV6_EX; + case E1000_RXDADV_RSSTYPE_IPV6: + return M_HASHTYPE_RSS_IPV6; + case E1000_RXDADV_RSSTYPE_IPV6_TCP_EX: + return M_HASHTYPE_RSS_TCP_IPV6_EX; + default: + return M_HASHTYPE_OPAQUE; + } } + static void em_receive_checksum(uint32_t status, if_rxd_info_t ri) { @@ -764,7 +798,7 @@ em_receive_checksum(uint32_t status, if_ /* If the IP checksum exists and there is no IP Checksum error */ if ((status & (E1000_RXD_STAT_IPCS | E1000_RXDEXT_STATERR_IPE)) == - E1000_RXD_STAT_IPCS) { + E1000_RXD_STAT_IPCS) { ri->iri_csum_flags = (CSUM_IP_CHECKED | CSUM_IP_VALID); } Modified: head/sys/dev/e1000/if_em.c ============================================================================== --- head/sys/dev/e1000/if_em.c Mon Mar 13 22:45:51 2017 (r315216) +++ head/sys/dev/e1000/if_em.c Mon Mar 13 22:53:06 2017 (r315217) @@ -50,113 +50,113 @@ char em_driver_version[] = "7.6.1-k"; static pci_vendor_info_t em_vendor_info_array[] = { /* Intel(R) PRO/1000 Network Connection - Legacy em*/ - PVID(0x8086, E1000_DEV_ID_82540EM, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82540EM_LOM, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82540EP, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82540EP_LOM, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82540EP_LP, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82541EI, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541ER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541ER_LOM, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541EI_MOBILE, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541GI, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541GI_LF, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82541GI_MOBILE, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82542, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82543GC_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82543GC_COPPER, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82544EI_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82544EI_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82544GC_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82544GC_LOM, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82545EM_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82545EM_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82545GM_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82545GM_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82545GM_SERDES, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82546EB_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546EB_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546EB_QUAD_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_FIBER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_SERDES, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_PCIE, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_QUAD_COPPER, "Intel(R) PRO/1000 Network Connection"), - PVID(0x8086, E1000_DEV_ID_82546GB_QUAD_COPPER_KSP3, "Intel(R) PRO/1000 Network Connection"), - - PVID(0x8086, E1000_DEV_ID_82547EI, "Intel(R) PRO/1000 Network Connection"), *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Tue Mar 14 00:41:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A6CCD09493; Tue, 14 Mar 2017 00:41:56 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp002.me.com (mr11p00im-asmtp002.me.com [17.110.69.253]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EA1AD15CB; Tue, 14 Mar 2017 00:41:55 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp002.me.com by mr11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OMS00K0049R2800@mr11p00im-asmtp002.me.com>; Tue, 14 Mar 2017 00:41:49 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1489452109; bh=MfmcmhoHiX6nBVl2fAx02HVn9NR6nyRBRKRBbWlE8Rg=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=CsS8GRCNZiW+g3lEJ9pnC/gXKImITD86i4FqF9EXQCJPe3iDOz4TDMDffw5UOZPY+ wjvK8psUDfC22ioCvje1XnNv6DGebx9dOlQv+3UrsetLlmP84MNbz673TxwsccbAzM h1xqSKSRr3o8vQEE65WKoeSg2in3wyaXXLJBPS6qpXdjxYNEZAA+KsGhR74XAN6TXL 9BnQRFZGZ69TuBZJb2WcbB30U8xHbB8hPdg40dGvV5Zfy7kTVqNrSPTdXz+BNalMMQ oyOTTZaEESHuJEbPKEYI48Mfln3N27NUiwp7WSf2ggW0wqmM+AxdeqOpfmfhEQ9IUw rOEL5Miea5HEQ== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OMS00DKF4LLV610@mr11p00im-asmtp002.me.com>; Tue, 14 Mar 2017 00:41:46 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-03-13_18:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1703140005 User-Agent: Microsoft-MacOutlook/f.1f.0.170216 Date: Mon, 13 Mar 2017 17:41:43 -0700 Subject: Re: svn commit: r315155 - in head/sys: kern sys From: Ravi Pokala Sender: "Pokala, Ravi" To: Konstantin Belousov , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-id: <9F3E9E31-579D-460E-B1CA-389C1FE476E0@panasas.com> Thread-topic: svn commit: r315155 - in head/sys: kern sys References: <201703121348.v2CDmOpp070774@repo.freebsd.org> In-reply-to: <201703121348.v2CDmOpp070774@repo.freebsd.org> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 00:41:56 -0000 Hi Konstantin, This appears to break mips kernels: _.mips.ADM5120:cc1: warnings being treated as errors _.mips.ADM5120-/usr/home/rpokala/freebsd/clean/base/head/sys/kern/kern_event.c:892: warning: 'kev_iovlen' defined but not used _.mips.ALCHEMY:cc1: warnings being treated as errors _.mips.ALCHEMY-/usr/home/rpokala/freebsd/clean/base/head/sys/kern/kern_event.c:892: warning: 'kev_iovlen' defined but not used _.mips.AR71XX_BASE:cc1: warnings being treated as errors _.mips.AR71XX_BASE-/usr/home/rpokala/freebsd/clean/base/head/sys/kern/kern_event.c:892: warning: 'kev_iovlen' defined but not used _.mips.AR724X_BASE:cc1: warnings being treated as errors _.mips.AR724X_BASE-/usr/home/rpokala/freebsd/clean/base/head/sys/kern/kern_event.c:892: warning: 'kev_iovlen' defined but not used etc. Thanks, Ravi (rpokala@) -----Original Message----- From: on behalf of Konstantin Belousov Date: 2017-03-12, Sunday at 06:48 To: , , Subject: svn commit: r315155 - in head/sys: kern sys Author: kib Date: Sun Mar 12 13:48:24 2017 New Revision: 315155 URL: https://svnweb.freebsd.org/changeset/base/315155 Log: Ktracing kevent(2) calls with unusual arguments might leads to an overly large allocation requests. When ktrace-ing io, sys_kevent() allocates memory to copy the requested changes and reported events. Allocations are sized by the incoming syscall lengths arguments, which are user-controlled, and might cause overflow in calculations or too large allocations. Since io trace chunks are limited by ktr_geniosize, there is no sense it even trying to satisfy unbounded allocations. Export ktr_geniosize and clamp the buffers sizes in advance. PR: 217435 Reported by: Tim Newsham Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/kern/kern_event.c head/sys/kern/kern_ktrace.c head/sys/sys/ktrace.h Modified: head/sys/kern/kern_event.c ============================================================================== --- head/sys/kern/kern_event.c Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/kern/kern_event.c Sun Mar 12 13:48:24 2017 (r315155) @@ -887,6 +887,15 @@ kern_kqueue(struct thread *td, int flags return (0); } +static size_t +kev_iovlen(int n, u_int kgio) +{ + + if (n < 0 || n >= kgio / sizeof(struct kevent)) + return (kgio); + return (n * sizeof(struct kevent)); +} + #ifndef _SYS_SYSPROTO_H_ struct kevent_args { int fd; @@ -910,6 +919,7 @@ sys_kevent(struct thread *td, struct kev struct iovec ktriov; struct uio *ktruioin = NULL; struct uio *ktruioout = NULL; + u_int kgio; #endif if (uap->timeout != NULL) { @@ -922,13 +932,15 @@ sys_kevent(struct thread *td, struct kev #ifdef KTRACE if (KTRPOINT(td, KTR_GENIO)) { + kgio = ktr_geniosize; ktriov.iov_base = uap->changelist; - ktriov.iov_len = uap->nchanges * sizeof(struct kevent); + ktriov.iov_len = kev_iovlen(uap->nchanges, kgio); ktruio = (struct uio){ .uio_iov = &ktriov, .uio_iovcnt = 1, .uio_segflg = UIO_USERSPACE, .uio_rw = UIO_READ, .uio_td = td }; ktruioin = cloneuio(&ktruio); ktriov.iov_base = uap->eventlist; + ktriov.iov_len = kev_iovlen(uap->nevents, kgio); ktriov.iov_len = uap->nevents * sizeof(struct kevent); ktruioout = cloneuio(&ktruio); } @@ -939,9 +951,9 @@ sys_kevent(struct thread *td, struct kev #ifdef KTRACE if (ktruioin != NULL) { - ktruioin->uio_resid = uap->nchanges * sizeof(struct kevent); + ktruioin->uio_resid = kev_iovlen(uap->nchanges, kgio); ktrgenio(uap->fd, UIO_WRITE, ktruioin, 0); - ktruioout->uio_resid = td->td_retval[0] * sizeof(struct kevent); + ktruioout->uio_resid = kev_iovlen(td->td_retval[0], kgio); ktrgenio(uap->fd, UIO_READ, ktruioout, error); } #endif Modified: head/sys/kern/kern_ktrace.c ============================================================================== --- head/sys/kern/kern_ktrace.c Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/kern/kern_ktrace.c Sun Mar 12 13:48:24 2017 (r315155) @@ -132,7 +132,7 @@ static SYSCTL_NODE(_kern, OID_AUTO, ktra static u_int ktr_requestpool = KTRACE_REQUEST_POOL; TUNABLE_INT("kern.ktrace.request_pool", &ktr_requestpool); -static u_int ktr_geniosize = PAGE_SIZE; +u_int ktr_geniosize = PAGE_SIZE; SYSCTL_UINT(_kern_ktrace, OID_AUTO, genio_size, CTLFLAG_RWTUN, &ktr_geniosize, 0, "Maximum size of genio event payload"); Modified: head/sys/sys/ktrace.h ============================================================================== --- head/sys/sys/ktrace.h Sun Mar 12 13:42:40 2017 (r315154) +++ head/sys/sys/ktrace.h Sun Mar 12 13:48:24 2017 (r315155) @@ -276,7 +276,7 @@ void ktrcapfail(enum ktr_cap_fail_type, ktrstruct("sockaddr", (s), ((struct sockaddr *)(s))->sa_len) #define ktrstat(s) \ ktrstruct("stat", (s), sizeof(struct stat)) - +extern u_int ktr_geniosize; #else #include From owner-svn-src-all@freebsd.org Tue Mar 14 00:43:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48161D096AD; Tue, 14 Mar 2017 00:43:45 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp003.me.com (mr11p00im-asmtp003.me.com [17.110.69.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2D86E18EB; Tue, 14 Mar 2017 00:43:45 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp003.me.com by mr11p00im-asmtp003.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OMS00J0049FNQ00@mr11p00im-asmtp003.me.com>; Tue, 14 Mar 2017 00:43:38 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1489452218; bh=gHVcsWsUMAFLed5DSQhjqVEK9jFWDCoaV7I5xi3Uo6o=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=gvu8hqY9ltMqaBDK8csQFAMgxjq5YHSWhU4V+aoeRW+8ypfS7i0Mj57k0nFv+NWUY o9BtMrMChSI9luLBid73it8Nhz1qPj+rHZElEC5BTcVpSYsBs9DzMhlwXqm0VNtBUZ smKTifPJY99XrKOYsckt8YqzzYOuO+gS+yRxucTNupV523GWwVA1sc3erBcvXiJoy1 AGXOFlyN57oELqh5vUoygJxxdsSP/46afkER1kNfvBgOgHft+ragMsWg9us3VhEEVv EG2cCC4S8q/2HLVEzFdgGbOgOHNnjZ+6amgGjkKW9W3efO9klASBE89F3RaUTE1eBv T7R/V3E930Lmw== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp003.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OMS00HM44ONZX10@mr11p00im-asmtp003.me.com>; Tue, 14 Mar 2017 00:43:36 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-03-13_18:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1703140005 User-Agent: Microsoft-MacOutlook/f.1f.0.170216 Date: Mon, 13 Mar 2017 17:43:35 -0700 Subject: Re: svn commit: r315163 - head/sys/dev/isp From: Ravi Pokala Sender: "Pokala, Ravi" To: Alexander Motin , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-id: <5AE94770-B65A-4B09-A770-6EC55B29D121@panasas.com> Thread-topic: svn commit: r315163 - head/sys/dev/isp References: <201703121655.v2CGtIjX049531@repo.freebsd.org> In-reply-to: <201703121655.v2CGtIjX049531@repo.freebsd.org> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 00:43:45 -0000 Hi Alexander, This appears to break powerpc and sparc64 kernels: _.powerpc.GENERIC:cc1: warnings being treated as errors _.powerpc.GENERIC-/usr/home/rpokala/freebsd/clean/base/head/sys/dev/isp/isp_freebsd.c:55: warning: 'isp_intr_enable' declared 'static' but never defined -- _.powerpc.GENERIC:cc1: warnings being treated as errors _.powerpc.GENERIC-/usr/home/rpokala/freebsd/clean/base/head/sys/dev/isp/isp_freebsd.c:55: warning: 'isp_intr_enable' declared 'static' but never defined ... _.sparc64.GENERIC:cc1: warnings being treated as errors _.sparc64.GENERIC-/usr/home/rpokala/freebsd/clean/base/head/sys/dev/isp/isp_freebsd.c:55: warning: 'isp_intr_enable' declared 'static' but never defined _.sparc64.GENERIC-NODEBUG:cc1: warnings being treated as errors _.sparc64.GENERIC-NODEBUG-/usr/home/rpokala/freebsd/clean/base/head/sys/dev/isp/isp_freebsd.c:55: warning: 'isp_intr_enable' declared 'static' but never defined etc. Thanks, Ravi (rpokala@) -----Original Message----- From: on behalf of Alexander Motin Date: 2017-03-12, Sunday at 09:55 To: , , Subject: svn commit: r315163 - head/sys/dev/isp Author: mav Date: Sun Mar 12 16:55:18 2017 New Revision: 315163 URL: https://svnweb.freebsd.org/changeset/base/315163 Log: Remove strange config_intrhook_establish() magic. Interrupts are enabled as part of chip reset just during driver attach. Later "enabling" of already enabled interrupts is useless. MFC after: 2 weeks Modified: head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Sun Mar 12 16:03:34 2017 (r315162) +++ head/sys/dev/isp/isp_freebsd.c Sun Mar 12 16:55:18 2017 (r315163) @@ -278,25 +278,11 @@ isp_attach(ispsoftc_t *isp) int du = device_get_unit(isp->isp_dev); int chan; - isp->isp_osinfo.ehook.ich_func = isp_intr_enable; - isp->isp_osinfo.ehook.ich_arg = isp; - /* - * Haha. Set this first, because if we're loaded as a module isp_intr_enable - * will be called right awawy, which will clear isp_osinfo.ehook_active, - * which would be unwise to then set again later. - */ - isp->isp_osinfo.ehook_active = 1; - if (config_intrhook_establish(&isp->isp_osinfo.ehook) != 0) { - isp_prt(isp, ISP_LOGERR, "could not establish interrupt enable hook"); - return (-EIO); - } - /* * Create the device queue for our SIM(s). */ isp->isp_osinfo.devq = cam_simq_alloc(isp->isp_maxcmds); if (isp->isp_osinfo.devq == NULL) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); return (EIO); } @@ -330,10 +316,6 @@ unwind: ISP_UNLOCK(isp); cam_sim_free(sim, FALSE); } - if (isp->isp_osinfo.ehook_active) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); - isp->isp_osinfo.ehook_active = 0; - } if (isp->isp_osinfo.cdev) { destroy_dev(isp->isp_osinfo.cdev); isp->isp_osinfo.cdev = NULL; @@ -371,10 +353,6 @@ isp_detach(ispsoftc_t *isp) destroy_dev(isp->isp_osinfo.cdev); isp->isp_osinfo.cdev = NULL; } - if (isp->isp_osinfo.ehook_active) { - config_intrhook_disestablish(&isp->isp_osinfo.ehook); - isp->isp_osinfo.ehook_active = 0; - } if (isp->isp_osinfo.devq != NULL) { cam_simq_free(isp->isp_osinfo.devq); isp->isp_osinfo.devq = NULL; @@ -786,28 +764,6 @@ ispioctl(struct cdev *dev, u_long c, cad return (retval); } -static void -isp_intr_enable(void *arg) -{ - int chan; - ispsoftc_t *isp = arg; - ISP_LOCK(isp); - if (IS_FC(isp)) { - for (chan = 0; chan < isp->isp_nchan; chan++) { - if (FCPARAM(isp, chan)->role != ISP_ROLE_NONE) { - ISP_ENABLE_INTS(isp); - break; - } - } - } else { - ISP_ENABLE_INTS(isp); - } - isp->isp_osinfo.ehook_active = 0; - ISP_UNLOCK(isp); - /* Release our hook so that the boot can continue. */ - config_intrhook_disestablish(&isp->isp_osinfo.ehook); -} - /* * Local Inlines */ Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Sun Mar 12 16:03:34 2017 (r315162) +++ head/sys/dev/isp/isp_freebsd.h Sun Mar 12 16:55:18 2017 (r315163) @@ -270,7 +270,6 @@ struct isposinfo { struct mtx lock; device_t dev; struct cdev * cdev; - struct intr_config_hook ehook; struct cam_devq * devq; /* @@ -310,7 +309,6 @@ struct isposinfo { sixtyfourbit : 1, /* sixtyfour bit platform */ timer_active : 1, autoconf : 1, - ehook_active : 1, mbox_sleeping : 1, mbox_sleep_ok : 1, mboxcmd_done : 1, From owner-svn-src-all@freebsd.org Tue Mar 14 01:00:10 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7C9A3D09B91; Tue, 14 Mar 2017 01:00:10 +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 49F6611E6; Tue, 14 Mar 2017 01:00:10 +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 v2E109jX042880; Tue, 14 Mar 2017 01:00:09 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E109jA042879; Tue, 14 Mar 2017 01:00:09 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201703140100.v2E109jA042879@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 14 Mar 2017 01:00:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315218 - head/sbin/ipf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 01:00:10 -0000 Author: cy Date: Tue Mar 14 01:00:09 2017 New Revision: 315218 URL: https://svnweb.freebsd.org/changeset/base/315218 Log: Disconnect ipftest and ipresend from the build until it can be verified that they still work. These utilities have become out of sync with the code in the kernel and need work to bring them back into shape. Most people test on real systems or VMs on real networks. Sugested by: glebius Modified: head/sbin/ipf/Makefile Modified: head/sbin/ipf/Makefile ============================================================================== --- head/sbin/ipf/Makefile Mon Mar 13 22:53:06 2017 (r315217) +++ head/sbin/ipf/Makefile Tue Mar 14 01:00:09 2017 (r315218) @@ -1,7 +1,9 @@ # $FreeBSD$ SUBDIR= libipf .WAIT -SUBDIR+= ipf ipfs ipfstat ipftest ipmon ipnat ippool ipresend +SUBDIR+= ipf ipfs ipftest ipmon ipnat ippool +# XXX: Disconnected for now. +# XXX: SUBDIR+= ipftest ipresend SUBDIR_PARALLEL= .include From owner-svn-src-all@freebsd.org Tue Mar 14 01:15:15 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53520D0A6CE; Tue, 14 Mar 2017 01:15:15 +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 2352A1DB8; Tue, 14 Mar 2017 01:15:15 +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 v2E1FEtd050756; Tue, 14 Mar 2017 01:15:14 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E1FEQA050755; Tue, 14 Mar 2017 01:15:14 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201703140115.v2E1FEQA050755@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 14 Mar 2017 01:15:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315219 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 01:15:15 -0000 Author: cy Date: Tue Mar 14 01:15:14 2017 New Revision: 315219 URL: https://svnweb.freebsd.org/changeset/base/315219 Log: Temporarily remove sbin/ipftest and sbin/ipresend until it can be verified that they still work. See r315218 for the reason why. In support of: r315218 Modified: head/ObsoleteFiles.inc Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Tue Mar 14 01:00:09 2017 (r315218) +++ head/ObsoleteFiles.inc Tue Mar 14 01:15:14 2017 (r315219) @@ -38,6 +38,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20170313: sbin/ipftest and ipresend temporarily disconnected (r315218). +OLD_FILES+=sbin/ipftest +OLD_FILES+=sbin/ipresend # 20170311: Remove WITHOUT_MANDOCDB option OLD_FILES+=usr/share/man/man1/makewhatis.1.gz # 20170311: remove GNU diff From owner-svn-src-all@freebsd.org Tue Mar 14 02:04:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7257BD0B606; Tue, 14 Mar 2017 02:04:45 +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 424D31A12; Tue, 14 Mar 2017 02:04:45 +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 v2E24iJ1070772; Tue, 14 Mar 2017 02:04:44 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E24i8q070771; Tue, 14 Mar 2017 02:04:44 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201703140204.v2E24i8q070771@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 14 Mar 2017 02:04:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315220 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 02:04:45 -0000 Author: cy Date: Tue Mar 14 02:04:44 2017 New Revision: 315220 URL: https://svnweb.freebsd.org/changeset/base/315220 Log: Revert r315219 so that it may be committed together with r315218. Modified: head/ObsoleteFiles.inc Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Tue Mar 14 01:15:14 2017 (r315219) +++ head/ObsoleteFiles.inc Tue Mar 14 02:04:44 2017 (r315220) @@ -38,9 +38,6 @@ # xargs -n1 | sort | uniq -d; # done -# 20170313: sbin/ipftest and ipresend temporarily disconnected (r315218). -OLD_FILES+=sbin/ipftest -OLD_FILES+=sbin/ipresend # 20170311: Remove WITHOUT_MANDOCDB option OLD_FILES+=usr/share/man/man1/makewhatis.1.gz # 20170311: remove GNU diff From owner-svn-src-all@freebsd.org Tue Mar 14 02:06:11 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6D74FD0B6A8; Tue, 14 Mar 2017 02:06:11 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1E9BB1BC6; Tue, 14 Mar 2017 02:06:11 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E26A79070931; Tue, 14 Mar 2017 02:06:10 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E264XL070870; Tue, 14 Mar 2017 02:06:04 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703140206.v2E264XL070870@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Tue, 14 Mar 2017 02:06: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: r315221 - in stable/11/sys: amd64/amd64 boot/common boot/efi/libefi boot/fdt boot/ficl boot/kshim boot/ofw/libofw boot/sparc64/loader boot/userboot/userboot boot/zfs dev/agp dev/an dev/... X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 02:06:11 -0000 Author: pfg Date: Tue Mar 14 02:06:03 2017 New Revision: 315221 URL: https://svnweb.freebsd.org/changeset/base/315221 Log: MFC r313982, r314068: sys: Replace zero with NULL for pointers. Found with: devel/coccinelle Modified: stable/11/sys/amd64/amd64/db_disasm.c stable/11/sys/amd64/amd64/pmap.c stable/11/sys/boot/common/md.c stable/11/sys/boot/efi/libefi/efinet.c stable/11/sys/boot/fdt/fdt_overlay.c stable/11/sys/boot/ficl/ficl.c stable/11/sys/boot/kshim/bsd_kernel.c stable/11/sys/boot/ofw/libofw/ofw_memory.c stable/11/sys/boot/sparc64/loader/main.c stable/11/sys/boot/userboot/userboot/userboot_disk.c stable/11/sys/boot/zfs/zfs.c stable/11/sys/boot/zfs/zfsimpl.c stable/11/sys/dev/agp/agp.c stable/11/sys/dev/an/if_an.c stable/11/sys/dev/arcmsr/arcmsr.c stable/11/sys/dev/bce/if_bce.c stable/11/sys/dev/beri/virtio/virtio_block.c stable/11/sys/dev/buslogic/bt_pci.c stable/11/sys/dev/ce/if_ce.c stable/11/sys/dev/cm/smc90cx6.c stable/11/sys/dev/cp/if_cp.c stable/11/sys/dev/ctau/ctddk.c stable/11/sys/dev/ctau/if_ct.c stable/11/sys/dev/cx/cxddk.c stable/11/sys/dev/cx/if_cx.c stable/11/sys/dev/de/if_de.c stable/11/sys/dev/ed/if_ed.c stable/11/sys/dev/fatm/if_fatm.c stable/11/sys/dev/fe/if_fe.c stable/11/sys/dev/firewire/if_fwip.c stable/11/sys/dev/hptiop/hptiop.c stable/11/sys/dev/hptmv/entry.c stable/11/sys/dev/hptmv/gui_lib.c stable/11/sys/dev/hptmv/hptproc.c stable/11/sys/dev/hptmv/ioctl.c stable/11/sys/dev/iicbus/if_ic.c stable/11/sys/dev/isp/isp_pci.c stable/11/sys/dev/le/am7990.c stable/11/sys/dev/le/am79900.c stable/11/sys/dev/le/lance.c stable/11/sys/dev/md/md.c stable/11/sys/dev/ncr/ncr.c stable/11/sys/dev/ofw/ofw_bus_subr.c stable/11/sys/dev/patm/if_patm_tx.c stable/11/sys/dev/pccard/pccard.c stable/11/sys/dev/pms/RefTisa/sallsdk/spc/sainit.c stable/11/sys/dev/pms/RefTisa/tisa/sassata/common/tdioctl.c stable/11/sys/dev/pms/freebsd/driver/ini/src/agtiapi.c stable/11/sys/dev/ppbus/if_plip.c stable/11/sys/dev/ppbus/ppbconf.c stable/11/sys/dev/ppc/ppc.c stable/11/sys/dev/sbni/if_sbni_isa.c stable/11/sys/dev/sn/if_sn.c stable/11/sys/dev/sym/sym_hipd.c stable/11/sys/dev/vx/if_vx.c stable/11/sys/libkern/iconv_xlat16.c stable/11/sys/net/if_fddisubr.c stable/11/sys/net/if_iso88025subr.c stable/11/sys/net/iflib.c stable/11/sys/netpfil/ipfw/ip_fw_sockopt.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/amd64/amd64/db_disasm.c ============================================================================== --- stable/11/sys/amd64/amd64/db_disasm.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/amd64/amd64/db_disasm.c Tue Mar 14 02:06:03 2017 (r315221) @@ -1044,7 +1044,7 @@ db_read_address(loc, short_addr, rex, re return (loc); } addrp->is_reg = FALSE; - addrp->index = 0; + addrp->index = NULL; if (short_addr) size = LONG; @@ -1067,7 +1067,7 @@ db_read_address(loc, short_addr, rex, re if (rm == 5) { get_value_inc(addrp->disp, loc, 4, FALSE); if (have_sib) - addrp->base = 0; + addrp->base = NULL; else if (short_addr) addrp->base = "%eip"; else @@ -1109,9 +1109,9 @@ db_print_address(seg, size, rex, addrp) db_printf("%s:", seg); } - if (addrp->disp != 0 || (addrp->base == 0 && addrp->index == 0)) + if (addrp->disp != 0 || (addrp->base == NULL && addrp->index == NULL)) db_printsym((db_addr_t)addrp->disp, DB_STGY_ANY); - if (addrp->base != 0 || addrp->index != 0) { + if (addrp->base != NULL || addrp->index != NULL) { db_printf("("); if (addrp->base) db_printf("%s", addrp->base); @@ -1248,7 +1248,7 @@ db_disasm(db_addr_t loc, bool altfmt) get_value_inc(inst, loc, 1, FALSE); short_addr = FALSE; size = LONG; - seg = 0; + seg = NULL; /* * Get prefixes @@ -1313,7 +1313,7 @@ db_disasm(db_addr_t loc, bool altfmt) while (ip->i_size == ESC) { get_value_inc(inst, loc, 1, FALSE); ip = ((const struct inst * const *)ip->i_extra)[inst>>4]; - if (ip == 0) { + if (ip == NULL) { ip = &db_bad_inst; } else { Modified: stable/11/sys/amd64/amd64/pmap.c ============================================================================== --- stable/11/sys/amd64/amd64/pmap.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/amd64/amd64/pmap.c Tue Mar 14 02:06:03 2017 (r315221) @@ -391,7 +391,7 @@ static struct md_page pv_dummy; /* * All those kernel PT submaps that BSD is so fond of */ -pt_entry_t *CMAP1 = 0; +pt_entry_t *CMAP1 = NULL; caddr_t CADDR1 = 0; static vm_offset_t qframe = 0; static struct mtx qframe_mtx; Modified: stable/11/sys/boot/common/md.c ============================================================================== --- stable/11/sys/boot/common/md.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/common/md.c Tue Mar 14 02:06:03 2017 (r315221) @@ -103,7 +103,7 @@ md_strategy(void *devdata, int rw, daddr if ((ofs + size) > MD_IMAGE_SIZE) size = MD_IMAGE_SIZE - ofs; - if (rsize != 0) + if (rsize != NULL) *rsize = size; switch (rw) { Modified: stable/11/sys/boot/efi/libefi/efinet.c ============================================================================== --- stable/11/sys/boot/efi/libefi/efinet.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/efi/libefi/efinet.c Tue Mar 14 02:06:03 2017 (r315221) @@ -131,13 +131,13 @@ efinet_put(struct iodesc *desc, void *pk /* Wait for the buffer to be transmitted */ do { - buf = 0; /* XXX Is this needed? */ + buf = NULL; /* XXX Is this needed? */ status = net->GetStatus(net, 0, &buf); /* * XXX EFI1.1 and the E1000 card returns a different * address than we gave. Sigh. */ - } while (status == EFI_SUCCESS && buf == 0); + } while (status == EFI_SUCCESS && buf == NULL); /* XXX How do we deal with status != EFI_SUCCESS now? */ return ((status == EFI_SUCCESS) ? len : -1); Modified: stable/11/sys/boot/fdt/fdt_overlay.c ============================================================================== --- stable/11/sys/boot/fdt/fdt_overlay.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/fdt/fdt_overlay.c Tue Mar 14 02:06:03 2017 (r315221) @@ -64,7 +64,7 @@ fdt_get_fixup_location(void *fdtp, const int prop_offset, o, proplen; void *result; - result = 0; + result = NULL; path = strdup(fixup); prop = strchr(path, ':'); Modified: stable/11/sys/boot/ficl/ficl.c ============================================================================== --- stable/11/sys/boot/ficl/ficl.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/ficl/ficl.c Tue Mar 14 02:06:03 2017 (r315221) @@ -276,7 +276,7 @@ void ficlFreeVM(FICL_VM *pVM) FICL_SYSTEM *pSys = pVM->pSys; FICL_VM *pList = pSys->vmList; - assert(pVM != 0); + assert(pVM != NULL); if (pSys->vmList == pVM) { Modified: stable/11/sys/boot/kshim/bsd_kernel.c ============================================================================== --- stable/11/sys/boot/kshim/bsd_kernel.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/kshim/bsd_kernel.c Tue Mar 14 02:06:03 2017 (r315221) @@ -75,7 +75,7 @@ bus_dmamem_alloc(bus_dma_tag_t dmat, voi void *addr; addr = malloc(dmat->maxsize + dmat->alignment, XXX, XXX); - if (addr == 0) + if (addr == NULL) return (ENOMEM); *mapp = addr; Modified: stable/11/sys/boot/ofw/libofw/ofw_memory.c ============================================================================== --- stable/11/sys/boot/ofw/libofw/ofw_memory.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/ofw/libofw/ofw_memory.c Tue Mar 14 02:06:03 2017 (r315221) @@ -35,7 +35,7 @@ __FBSDID("$FreeBSD$"); #include "libofw.h" #include "openfirm.h" -static void *heap_base = 0; +static void *heap_base = NULL; static unsigned int heap_size = 0; struct ofw_mapping { Modified: stable/11/sys/boot/sparc64/loader/main.c ============================================================================== --- stable/11/sys/boot/sparc64/loader/main.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/sparc64/loader/main.c Tue Mar 14 02:06:03 2017 (r315221) @@ -859,7 +859,7 @@ main(int (*openfirm)(void *)) /* * Initialize devices. */ - for (dp = devsw; *dp != 0; dp++) + for (dp = devsw; *dp != NULL; dp++) if ((*dp)->dv_init != 0) (*dp)->dv_init(); Modified: stable/11/sys/boot/userboot/userboot/userboot_disk.c ============================================================================== --- stable/11/sys/boot/userboot/userboot/userboot_disk.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/userboot/userboot/userboot_disk.c Tue Mar 14 02:06:03 2017 (r315221) @@ -91,8 +91,8 @@ userdisk_init(void) return (ENOMEM); for (i = 0; i < userdisk_maxunit; i++) { if (CALLBACK(diskioctl, i, DIOCGSECTORSIZE, - §orsize) != 0 || CALLBACK(diskioctl, i, - DIOCGMEDIASIZE, &mediasize) != 0) + §orsize) != NULL || CALLBACK(diskioctl, i, + DIOCGMEDIASIZE, &mediasize) != NULL) return (ENXIO); ud_info[i].mediasize = mediasize; ud_info[i].sectorsize = sectorsize; Modified: stable/11/sys/boot/zfs/zfs.c ============================================================================== --- stable/11/sys/boot/zfs/zfs.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/zfs/zfs.c Tue Mar 14 02:06:03 2017 (r315221) @@ -126,7 +126,7 @@ zfs_close(struct open_file *f) { struct file *fp = (struct file *)f->f_fsdata; - dnode_cache_obj = 0; + dnode_cache_obj = NULL; f->f_fsdata = (void *)0; if (fp == (struct file *)0) return (0); Modified: stable/11/sys/boot/zfs/zfsimpl.c ============================================================================== --- stable/11/sys/boot/zfs/zfsimpl.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/boot/zfs/zfsimpl.c Tue Mar 14 02:06:03 2017 (r315221) @@ -67,7 +67,7 @@ static const char *features_for_read[] = static spa_list_t zfs_pools; static uint64_t zfs_crc64_table[256]; -static const dnode_phys_t *dnode_cache_obj = 0; +static const dnode_phys_t *dnode_cache_obj = NULL; static uint64_t dnode_cache_bn; static char *dnode_cache_buf; static char *zap_scratch; @@ -1430,7 +1430,7 @@ fzap_lookup(const spa_t *spa, const dnod zc = &ZAP_LEAF_CHUNK(&zl, h); while (zc->l_entry.le_hash != hash) { if (zc->l_entry.le_next == 0xffff) { - zc = 0; + zc = NULL; break; } zc = &ZAP_LEAF_CHUNK(&zl, zc->l_entry.le_next); @@ -2127,7 +2127,7 @@ zfs_lookup(const struct zfsmount *mount, p = q; } else { strcpy(element, p); - p = 0; + p = NULL; } rc = zfs_dnode_stat(spa, &dn, &sb); Modified: stable/11/sys/dev/agp/agp.c ============================================================================== --- stable/11/sys/dev/agp/agp.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/agp/agp.c Tue Mar 14 02:06:03 2017 (r315221) @@ -820,7 +820,7 @@ agp_close(struct cdev *kdev, int fflag, /* * Clear the GATT and force release on last close */ - while ((mem = TAILQ_FIRST(&sc->as_memory)) != 0) { + while ((mem = TAILQ_FIRST(&sc->as_memory)) != NULL) { if (mem->am_is_bound) AGP_UNBIND_MEMORY(dev, mem); AGP_FREE_MEMORY(dev, mem); Modified: stable/11/sys/dev/an/if_an.c ============================================================================== --- stable/11/sys/dev/an/if_an.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/an/if_an.c Tue Mar 14 02:06:03 2017 (r315221) @@ -3057,7 +3057,7 @@ static void an_cache_store(struct an_softc *sc, struct ether_header *eh, struct mbuf *m, u_int8_t rx_rssi, u_int8_t rx_quality) { - struct ip *ip = 0; + struct ip *ip = NULL; int i; static int cache_slot = 0; /* use this cache entry */ static int wrapindex = 0; /* next "free" cache entry */ Modified: stable/11/sys/dev/arcmsr/arcmsr.c ============================================================================== --- stable/11/sys/dev/arcmsr/arcmsr.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/arcmsr/arcmsr.c Tue Mar 14 02:06:03 2017 (r315221) @@ -1398,8 +1398,8 @@ static u_int32_t arcmsr_Read_iop_rqbuffe struct QBUFFER *prbuffer) { u_int8_t *pQbuffer; - u_int8_t *buf1 = 0; - u_int32_t *iop_data, *buf2 = 0; + u_int8_t *buf1 = NULL; + u_int32_t *iop_data, *buf2 = NULL; u_int32_t iop_len, data_len; iop_data = (u_int32_t *)prbuffer->data; @@ -1494,8 +1494,8 @@ static void arcmsr_Write_data_2iop_wqbuf { u_int8_t *pQbuffer; struct QBUFFER *pwbuffer; - u_int8_t *buf1 = 0; - u_int32_t *iop_data, *buf2 = 0; + u_int8_t *buf1 = NULL; + u_int32_t *iop_data, *buf2 = NULL; u_int32_t allxfer_len = 0, data_len; if(acb->acb_flags & ACB_F_MESSAGE_WQBUFFER_READ) { Modified: stable/11/sys/dev/bce/if_bce.c ============================================================================== --- stable/11/sys/dev/bce/if_bce.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/bce/if_bce.c Tue Mar 14 02:06:03 2017 (r315221) @@ -2800,7 +2800,7 @@ bce_nvram_write(struct bce_softc *sc, u3 if (align_start || align_end) { buf = malloc(len32, M_DEVBUF, M_NOWAIT); - if (buf == 0) { + if (buf == NULL) { rc = ENOMEM; goto bce_nvram_write_exit; } Modified: stable/11/sys/dev/beri/virtio/virtio_block.c ============================================================================== --- stable/11/sys/dev/beri/virtio/virtio_block.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/beri/virtio/virtio_block.c Tue Mar 14 02:06:03 2017 (r315221) @@ -457,7 +457,7 @@ beri_ioctl(struct cdev *dev, u_long cmd, sc->opened = 1; break; case MDIOCDETACH: - if (sc->vnode == 0) { + if (sc->vnode == NULL) { /* File not opened */ return (1); } Modified: stable/11/sys/dev/buslogic/bt_pci.c ============================================================================== --- stable/11/sys/dev/buslogic/bt_pci.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/buslogic/bt_pci.c Tue Mar 14 02:06:03 2017 (r315221) @@ -58,8 +58,8 @@ static int bt_pci_alloc_resources(device_t dev) { int type = 0, rid, zero; - struct resource *regs = 0; - struct resource *irq = 0; + struct resource *regs = NULL; + struct resource *irq = NULL; #if 0 /* XXX Memory Mapped I/O seems to cause problems */ Modified: stable/11/sys/dev/ce/if_ce.c ============================================================================== --- stable/11/sys/dev/ce/if_ce.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ce/if_ce.c Tue Mar 14 02:06:03 2017 (r315221) @@ -840,11 +840,11 @@ static int ce_detach (device_t dev) if (! d || ! d->chan) continue; callout_drain (&d->timeout_handle); - channel [b->num * NCHAN + c->num] = 0; + channel [b->num * NCHAN + c->num] = NULL; /* Deallocate buffers. */ ce_bus_dma_mem_free (&d->dmamem); } - adapter [b->num] = 0; + adapter [b->num] = NULL; ce_bus_dma_mem_free (&bd->dmamem); free (b, M_DEVBUF); #if __FreeBSD_version >= 504000 Modified: stable/11/sys/dev/cm/smc90cx6.c ============================================================================== --- stable/11/sys/dev/cm/smc90cx6.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/cm/smc90cx6.c Tue Mar 14 02:06:03 2017 (r315221) @@ -373,7 +373,7 @@ cm_start_locked(ifp) m = arc_frag_next(ifp); buffer = sc->sc_tx_act ^ 1; - if (m == 0) + if (m == NULL) return; #ifdef CM_DEBUG @@ -388,7 +388,7 @@ cm_start_locked(ifp) #endif cm_ram_ptr = buffer * 512; - if (m == 0) + if (m == NULL) return; /* write the addresses to RAM and throw them away */ @@ -505,7 +505,7 @@ cm_srint_locked(vsc) /* Allocate header mbuf */ MGETHDR(m, M_NOWAIT, MT_DATA); - if (m == 0) { + if (m == NULL) { /* * in case s.th. goes wrong with mem, drop it * to make sure the receiver can be started again @@ -546,7 +546,7 @@ cm_srint_locked(vsc) } } - if (m == 0) { + if (m == NULL) { if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); goto cleanup; } Modified: stable/11/sys/dev/cp/if_cp.c ============================================================================== --- stable/11/sys/dev/cp/if_cp.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/cp/if_cp.c Tue Mar 14 02:06:03 2017 (r315221) @@ -628,11 +628,11 @@ static int cp_detach (device_t dev) if (! d || ! d->chan->type) continue; callout_drain (&d->timeout_handle); - channel [b->num*NCHAN + c->num] = 0; + channel [b->num*NCHAN + c->num] = NULL; /* Deallocate buffers. */ cp_bus_dma_mem_free (&d->dmamem); } - adapter [b->num] = 0; + adapter [b->num] = NULL; cp_bus_dma_mem_free (&bd->dmamem); free (b, M_DEVBUF); mtx_destroy (&bd->cp_mtx); Modified: stable/11/sys/dev/ctau/ctddk.c ============================================================================== --- stable/11/sys/dev/ctau/ctddk.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ctau/ctddk.c Tue Mar 14 02:06:03 2017 (r315221) @@ -104,7 +104,7 @@ int ct_open_board (ct_board_t *b, int nu case B_TAU2_E1D: fw = ctau2_fw_data; flen = 0; - ft = 0; + ft = NULL; break; #ifndef CT_DDK_NO_G703 case B_TAU_G703: Modified: stable/11/sys/dev/ctau/if_ct.c ============================================================================== --- stable/11/sys/dev/ctau/if_ct.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ctau/if_ct.c Tue Mar 14 02:06:03 2017 (r315221) @@ -839,8 +839,8 @@ static int ct_detach (device_t dev) /* Deallocate buffers. */ ct_bus_dma_mem_free (&d->dmamem); } - bd->board = 0; - adapter [b->num] = 0; + bd->board = NULL; + adapter [b->num] = NULL; free (b, M_DEVBUF); mtx_destroy (&bd->ct_mtx); Modified: stable/11/sys/dev/cx/cxddk.c ============================================================================== --- stable/11/sys/dev/cx/cxddk.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/cx/cxddk.c Tue Mar 14 02:06:03 2017 (r315221) @@ -440,7 +440,7 @@ static int cx_receive_interrupt (cx_chan if (c->mode == M_ASYNC && (risr & RISA_TIMEOUT)) { unsigned long rcbadr = (unsigned short) inw (RCBADRL(c->port)) | (long) inw (RCBADRU(c->port)) << 16; - unsigned char *buf = 0; + unsigned char *buf = NULL; port_t cnt_port = 0, sts_port = 0; if (rcbadr >= c->brphys && rcbadr < c->brphys+DMABUFSZ) { Modified: stable/11/sys/dev/cx/if_cx.c ============================================================================== --- stable/11/sys/dev/cx/if_cx.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/cx/if_cx.c Tue Mar 14 02:06:03 2017 (r315221) @@ -991,8 +991,8 @@ static int cx_detach (device_t dev) /* Deallocate buffers. */ cx_bus_dma_mem_free (&d->dmamem); } - bd->board = 0; - adapter [b->num] = 0; + bd->board = NULL; + adapter [b->num] = NULL; free (b, M_DEVBUF); splx (s); Modified: stable/11/sys/dev/de/if_de.c ============================================================================== --- stable/11/sys/dev/de/if_de.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/de/if_de.c Tue Mar 14 02:06:03 2017 (r315221) @@ -4887,8 +4887,8 @@ tulip_pci_attach(device_t dev) rid = 0; res = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid, RF_SHAREABLE | RF_ACTIVE); - if (res == 0 || bus_setup_intr(dev, res, INTR_TYPE_NET | - INTR_MPSAFE, NULL, intr_rtn, sc, &ih)) { + if (res == NULL || bus_setup_intr(dev, res, INTR_TYPE_NET | + INTR_MPSAFE, NULL, intr_rtn, sc, &ih)) { device_printf(dev, "couldn't map interrupt\n"); tulip_busdma_cleanup(sc); ether_ifdetach(sc->tulip_ifp); Modified: stable/11/sys/dev/ed/if_ed.c ============================================================================== --- stable/11/sys/dev/ed/if_ed.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ed/if_ed.c Tue Mar 14 02:06:03 2017 (r315221) @@ -751,7 +751,7 @@ outloop: return; } IFQ_DRV_DEQUEUE(&ifp->if_snd, m); - if (m == 0) { + if (m == NULL) { /* * We are using the !OACTIVE flag to indicate to the outside Modified: stable/11/sys/dev/fatm/if_fatm.c ============================================================================== --- stable/11/sys/dev/fatm/if_fatm.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/fatm/if_fatm.c Tue Mar 14 02:06:03 2017 (r315221) @@ -1501,7 +1501,7 @@ fatm_intr_drain_rx(struct fatm_softc *sc rpd->nseg = le32toh(rpd->nseg); mlen = 0; - m0 = last = 0; + m0 = last = NULL; for (i = 0; i < rpd->nseg; i++) { rb = sc->rbufs + rpd->segment[i].handle; if (m0 == NULL) { Modified: stable/11/sys/dev/fe/if_fe.c ============================================================================== --- stable/11/sys/dev/fe/if_fe.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/fe/if_fe.c Tue Mar 14 02:06:03 2017 (r315221) @@ -2011,7 +2011,7 @@ fe_write_mbufs (struct fe_softc *sc, str if ((sc->proto_dlcr6 & FE_D6_SBW) == FE_D6_SBW_BYTE) { /* 8-bit cards are easy. */ - for (mp = m; mp != 0; mp = mp->m_next) { + for (mp = m; mp != NULL; mp = mp->m_next) { if (mp->m_len) fe_outsb(sc, FE_BMPR8, mtod(mp, caddr_t), mp->m_len); @@ -2021,7 +2021,7 @@ fe_write_mbufs (struct fe_softc *sc, str { /* 16-bit cards are a pain. */ savebyte = NO_PENDING_BYTE; - for (mp = m; mp != 0; mp = mp->m_next) { + for (mp = m; mp != NULL; mp = mp->m_next) { /* Ignore empty mbuf. */ len = mp->m_len; Modified: stable/11/sys/dev/firewire/if_fwip.c ============================================================================== --- stable/11/sys/dev/firewire/if_fwip.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/firewire/if_fwip.c Tue Mar 14 02:06:03 2017 (r315221) @@ -575,7 +575,7 @@ fwip_async_output(struct fwip_softc *fwi */ mtag = m_tag_locate(m, MTAG_FIREWIRE, MTAG_FIREWIRE_HWADDR, 0); if (mtag == NULL) - destfw = 0; + destfw = NULL; else destfw = (struct fw_hwaddr *) (mtag + 1); Modified: stable/11/sys/dev/hptiop/hptiop.c ============================================================================== --- stable/11/sys/dev/hptiop/hptiop.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/hptiop/hptiop.c Tue Mar 14 02:06:03 2017 (r315221) @@ -330,7 +330,7 @@ static void hptiop_request_callback_itl( u_int32_t index) { struct hpt_iop_srb *srb; - struct hpt_iop_request_scsi_command *req=0; + struct hpt_iop_request_scsi_command *req=NULL; union ccb *ccb; u_int8_t *cdb; u_int32_t result, temp, dxfer; Modified: stable/11/sys/dev/hptmv/entry.c ============================================================================== --- stable/11/sys/dev/hptmv/entry.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/hptmv/entry.c Tue Mar 14 02:06:03 2017 (r315221) @@ -138,8 +138,8 @@ static MV_BOOLEAN hptmv_event_notify(MV_ static struct sx hptmv_list_lock; SX_SYSINIT(hptmv_list_lock, &hptmv_list_lock, "hptmv list"); -IAL_ADAPTER_T *gIal_Adapter = 0; -IAL_ADAPTER_T *pCurAdapter = 0; +IAL_ADAPTER_T *gIal_Adapter = NULL; +IAL_ADAPTER_T *pCurAdapter = NULL; static MV_SATA_CHANNEL gMvSataChannels[MAX_VBUS][MV_SATA_CHANNELS_NUM]; typedef struct st_HPT_DPC { @@ -1262,7 +1262,7 @@ init_adapter(IAL_ADAPTER_T *pAdapter) sx_xlock(&hptmv_list_lock); pAdapter->next = 0; - if(gIal_Adapter == 0){ + if(gIal_Adapter == NULL){ gIal_Adapter = pAdapter; pCurAdapter = gIal_Adapter; } @@ -2427,7 +2427,7 @@ static void hpt_worker_thread(void) sx_slock(&hptmv_list_lock); pAdapter = gIal_Adapter; - while(pAdapter != 0){ + while(pAdapter != NULL){ mtx_lock(&pAdapter->lock); _vbus_p = &pAdapter->VBus; Modified: stable/11/sys/dev/hptmv/gui_lib.c ============================================================================== --- stable/11/sys/dev/hptmv/gui_lib.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/hptmv/gui_lib.c Tue Mar 14 02:06:03 2017 (r315221) @@ -74,7 +74,7 @@ check_VDevice_valid(PVDevice p) PVBus _vbus_p; IAL_ADAPTER_T *pAdapter = gIal_Adapter; - while(pAdapter != 0) + while(pAdapter != NULL) { for (i = 0; i < MV_SATA_CHANNELS_NUM; i++) if(&(pAdapter->VDevices[i]) == p) return 0; @@ -83,7 +83,7 @@ check_VDevice_valid(PVDevice p) #ifdef SUPPORT_ARRAY pAdapter = gIal_Adapter; - while(pAdapter != 0) + while(pAdapter != NULL) { _vbus_p = &pAdapter->VBus; for (i=0;inext; @@ -448,7 +448,7 @@ int hpt_get_channel_info(int id, int bus IAL_ADAPTER_T *pAdapTemp = gIal_Adapter; int i,iControllerCount = 0; - while(pAdapTemp != 0) + while(pAdapTemp != NULL) { if (iControllerCount++==id) goto found; Modified: stable/11/sys/dev/hptmv/hptproc.c ============================================================================== --- stable/11/sys/dev/hptmv/hptproc.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/hptmv/hptproc.c Tue Mar 14 02:06:03 2017 (r315221) @@ -427,7 +427,7 @@ static void hpt_copy_array_info(HPT_GET_INFO *pinfo, int nld, PVDevice pArray) { int i; - char *sType=0, *sStatus=0; + char *sType = NULL, *sStatus = NULL; char buf[32]; PVDevice pTmpArray; Modified: stable/11/sys/dev/hptmv/ioctl.c ============================================================================== --- stable/11/sys/dev/hptmv/ioctl.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/hptmv/ioctl.c Tue Mar 14 02:06:03 2017 (r315221) @@ -691,7 +691,7 @@ hpt_rebuild_data_block(IAL_ADAPTER_T *pA PCommand pCmd; UINT result; int needsync=0, retry=0, needdelete=0; - void *buffer = 0; + void *buffer = NULL; _VBUS_INST(&pAdapter->VBus) Modified: stable/11/sys/dev/iicbus/if_ic.c ============================================================================== --- stable/11/sys/dev/iicbus/if_ic.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/iicbus/if_ic.c Tue Mar 14 02:06:03 2017 (r315221) @@ -251,7 +251,7 @@ icioctl(struct ifnet *ifp, u_long cmd, c case SIOCADDMULTI: case SIOCDELMULTI: - if (ifr == 0) + if (ifr == NULL) return (EAFNOSUPPORT); /* XXX */ switch (ifr->ifr_addr.sa_family) { case AF_INET: Modified: stable/11/sys/dev/isp/isp_pci.c ============================================================================== --- stable/11/sys/dev/isp/isp_pci.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/isp/isp_pci.c Tue Mar 14 02:06:03 2017 (r315221) @@ -583,10 +583,10 @@ isp_get_specific_options(device_t dev, i name, &tval) == 0 && tval != 0) { isp->isp_confopts |= ISP_CFG_FULL_DUPLEX; } - sptr = 0; + sptr = NULL; snprintf(name, sizeof(name), "%stopology", prefix); if (resource_string_value(device_get_name(dev), device_get_unit(dev), - name, (const char **) &sptr) == 0 && sptr != 0) { + name, (const char **) &sptr) == 0 && sptr != NULL) { if (strcmp(sptr, "lport") == 0) { isp->isp_confopts |= ISP_CFG_LPORT; } else if (strcmp(sptr, "nport") == 0) { @@ -631,12 +631,12 @@ isp_get_specific_options(device_t dev, i * hint replacement to specify WWN strings with a leading * 'w' (e..g w50000000aaaa0001). Sigh. */ - sptr = 0; + sptr = NULL; snprintf(name, sizeof(name), "%sportwwn", prefix); tval = resource_string_value(device_get_name(dev), device_get_unit(dev), name, (const char **) &sptr); - if (tval == 0 && sptr != 0 && *sptr++ == 'w') { - char *eptr = 0; + if (tval == 0 && sptr != NULL && *sptr++ == 'w') { + char *eptr = NULL; ISP_FC_PC(isp, chan)->def_wwpn = strtouq(sptr, &eptr, 16); if (eptr < sptr + 16 || ISP_FC_PC(isp, chan)->def_wwpn == -1) { device_printf(dev, "mangled portwwn hint '%s'\n", sptr); @@ -644,12 +644,12 @@ isp_get_specific_options(device_t dev, i } } - sptr = 0; + sptr = NULL; snprintf(name, sizeof(name), "%snodewwn", prefix); tval = resource_string_value(device_get_name(dev), device_get_unit(dev), name, (const char **) &sptr); - if (tval == 0 && sptr != 0 && *sptr++ == 'w') { - char *eptr = 0; + if (tval == 0 && sptr != NULL && *sptr++ == 'w') { + char *eptr = NULL; ISP_FC_PC(isp, chan)->def_wwnn = strtouq(sptr, &eptr, 16); if (eptr < sptr + 16 || ISP_FC_PC(isp, chan)->def_wwnn == 0) { device_printf(dev, "mangled nodewwn hint '%s'\n", sptr); Modified: stable/11/sys/dev/le/am7990.c ============================================================================== --- stable/11/sys/dev/le/am7990.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/le/am7990.c Tue Mar 14 02:06:03 2017 (r315221) @@ -519,7 +519,7 @@ am7990_start_locked(struct lance_softc * } IFQ_DRV_DEQUEUE(&ifp->if_snd, m); - if (m == 0) + if (m == NULL) break; /* Modified: stable/11/sys/dev/le/am79900.c ============================================================================== --- stable/11/sys/dev/le/am79900.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/le/am79900.c Tue Mar 14 02:06:03 2017 (r315221) @@ -557,7 +557,7 @@ am79900_start_locked(struct lance_softc } IFQ_DRV_DEQUEUE(&ifp->if_snd, m); - if (m == 0) + if (m == NULL) break; /* Modified: stable/11/sys/dev/le/lance.c ============================================================================== --- stable/11/sys/dev/le/lance.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/le/lance.c Tue Mar 14 02:06:03 2017 (r315221) @@ -418,7 +418,7 @@ lance_get(struct lance_softc *sc, int bo totlen -= len; if (totlen > 0) { MGET(newm, M_NOWAIT, MT_DATA); - if (newm == 0) + if (newm == NULL) goto bad; len = MLEN; m = m->m_next = newm; Modified: stable/11/sys/dev/md/md.c ============================================================================== --- stable/11/sys/dev/md/md.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/md/md.c Tue Mar 14 02:06:03 2017 (r315221) @@ -153,7 +153,7 @@ static g_access_t g_md_access; static void g_md_dumpconf(struct sbuf *sb, const char *indent, struct g_geom *gp, struct g_consumer *cp __unused, struct g_provider *pp); -static struct cdev *status_dev = 0; +static struct cdev *status_dev = NULL; static struct sx md_sx; static struct unrhdr *md_uh; Modified: stable/11/sys/dev/ncr/ncr.c ============================================================================== --- stable/11/sys/dev/ncr/ncr.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ncr/ncr.c Tue Mar 14 02:06:03 2017 (r315221) @@ -5206,7 +5206,7 @@ static void ncr_log_hard_error(ncb_p np, } else { script_ofs = dsp; script_size = 0; - script_base = 0; + script_base = NULL; script_name = "mem"; } @@ -5809,7 +5809,7 @@ static void ncr_int_sir (ncb_p np) u_char scntl3; u_char chg, ofs, per, fak, wide; u_char num = INB (nc_dsps); - nccb_p cp=0; + nccb_p cp = NULL; u_long dsa; u_int target = INB (nc_sdid) & 0x0f; tcb_p tp = &np->target[target]; Modified: stable/11/sys/dev/ofw/ofw_bus_subr.c ============================================================================== --- stable/11/sys/dev/ofw/ofw_bus_subr.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ofw/ofw_bus_subr.c Tue Mar 14 02:06:03 2017 (r315221) @@ -944,7 +944,7 @@ ofw_bus_string_list_to_array(phandle_t n i += len; tptr += len; } - array[cnt] = 0; + array[cnt] = NULL; *out_array = array; return (cnt); Modified: stable/11/sys/dev/patm/if_patm_tx.c ============================================================================== --- stable/11/sys/dev/patm/if_patm_tx.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/patm/if_patm_tx.c Tue Mar 14 02:06:03 2017 (r315221) @@ -440,7 +440,7 @@ patm_tx_pad(struct patm_softc *sc, struc } } MGET(m, M_NOWAIT, MT_DATA); - if (m == 0) { + if (m == NULL) { m_freem(m0); if_inc_counter(sc->ifp, IFCOUNTER_OERRORS, 1); return (NULL); Modified: stable/11/sys/dev/pccard/pccard.c ============================================================================== --- stable/11/sys/dev/pccard/pccard.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/pccard/pccard.c Tue Mar 14 02:06:03 2017 (r315221) @@ -470,7 +470,7 @@ pccard_function_init(struct pccard_funct struct pccard_ivar *devi = PCCARD_IVAR(pf->dev); struct resource_list *rl = &devi->resources; struct resource_list_entry *rle; - struct resource *r = 0; + struct resource *r = NULL; struct pccard_ce_iospace *ios; struct pccard_ce_memspace *mems; device_t bus; @@ -1115,7 +1115,7 @@ pccard_alloc_resource(device_t dev, devi rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) { struct pccard_ivar *dinfo; - struct resource_list_entry *rle = 0; + struct resource_list_entry *rle = NULL; int passthrough = (device_get_parent(child) != dev); int isdefault = (RMAN_IS_DEFAULT_RANGE(start, end) && count == 1); struct resource *r = NULL; @@ -1165,7 +1165,7 @@ pccard_release_resource(device_t dev, de { struct pccard_ivar *dinfo; int passthrough = (device_get_parent(child) != dev); - struct resource_list_entry *rle = 0; + struct resource_list_entry *rle = NULL; if (passthrough) return BUS_RELEASE_RESOURCE(device_get_parent(dev), child, Modified: stable/11/sys/dev/pms/RefTisa/sallsdk/spc/sainit.c ============================================================================== --- stable/11/sys/dev/pms/RefTisa/sallsdk/spc/sainit.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/pms/RefTisa/sallsdk/spc/sainit.c Tue Mar 14 02:06:03 2017 (r315221) @@ -48,7 +48,7 @@ bit32 gLLSoftResetCounter = 0; bit32 gPollForMissingInt; #ifdef FW_EVT_LOG_TST -void *eventLogAddress = 0; +void *eventLogAddress = NULL; #endif extern bit32 gWait_3; Modified: stable/11/sys/dev/pms/RefTisa/tisa/sassata/common/tdioctl.c ============================================================================== --- stable/11/sys/dev/pms/RefTisa/tisa/sassata/common/tdioctl.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/pms/RefTisa/tisa/sassata/common/tdioctl.c Tue Mar 14 02:06:03 2017 (r315221) @@ -379,7 +379,7 @@ tiCOMMgntIOCTL( bit32 Offset = 0; bit32 RequestLength = 0; /* user request on how much data to pass to application */ agsaContext_t *agContext = NULL; - bit8 *loc = 0; + bit8 *loc = NULL; TI_DBG3(("tiCOMMgntIOCTL: start\n")); Modified: stable/11/sys/dev/pms/freebsd/driver/ini/src/agtiapi.c ============================================================================== --- stable/11/sys/dev/pms/freebsd/driver/ini/src/agtiapi.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/pms/freebsd/driver/ini/src/agtiapi.c Tue Mar 14 02:06:03 2017 (r315221) @@ -5032,7 +5032,7 @@ STATIC void agtiapi_PrepCCBs( struct agt int i; U32 hdr_sz, ccb_sz; - ccb_t *pccb = 0; + ccb_t *pccb = NULL; int offset = 0; int nsegs = 0; int sgl_sz = 0; @@ -5159,7 +5159,7 @@ STATIC U32 agtiapi_InitCCBs(struct agtia U32 max_ccb, size, ccb_sz, hdr_sz; int no_allocs = 0, i; - ccb_hdr_t *hdr = 0; + ccb_hdr_t *hdr = NULL; AGTIAPI_PRINTK("agtiapi_InitCCBs: start\n"); AGTIAPI_PRINTK("agtiapi_InitCCBs: tgtCount %d tid %d\n", tgtCount, tid); @@ -5395,7 +5395,7 @@ STATIC U32 agtiapi_GetDevHandle( struct for ( devIdx = 0; devIdx < pCard->devDiscover; devIdx++ ) { - if ( agDev[devIdx] != 0 ) + if ( agDev[devIdx] != NULL ) { // AGTIAPI_PRINTK( "agtiapi_GetDevHandle: agDev %d not NULL %p\n", // devIdx, agDev[devIdx] ); @@ -5820,7 +5820,7 @@ STATIC void agtiapi_ReleaseCCBs( struct ccb_hdr_t *hdr; U32 hdr_sz; - ccb_t *pccb = 0; + ccb_t *pccb = NULL; AGTIAPI_PRINTK( "agtiapi_ReleaseCCBs: start\n" ); Modified: stable/11/sys/dev/ppbus/if_plip.c ============================================================================== --- stable/11/sys/dev/ppbus/if_plip.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ppbus/if_plip.c Tue Mar 14 02:06:03 2017 (r315221) @@ -245,7 +245,7 @@ lp_attach(device_t dev) */ lp->res_irq = bus_alloc_resource_any(dev, SYS_RES_IRQ, &rid, RF_SHAREABLE); - if (lp->res_irq == 0) { + if (lp->res_irq == NULL) { device_printf(dev, "cannot reserve interrupt, failed.\n"); return (ENXIO); } @@ -453,7 +453,7 @@ lpioctl(struct ifnet *ifp, u_long cmd, c case SIOCADDMULTI: case SIOCDELMULTI: - if (ifr == 0) { + if (ifr == NULL) { return (EAFNOSUPPORT); /* XXX */ } switch (ifr->ifr_addr.sa_family) { Modified: stable/11/sys/dev/ppbus/ppbconf.c ============================================================================== --- stable/11/sys/dev/ppbus/ppbconf.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ppbus/ppbconf.c Tue Mar 14 02:06:03 2017 (r315221) @@ -206,7 +206,7 @@ search_token(char *str, int slen, char * static int ppb_pnp_detect(device_t bus) { - char *token, *class = 0; + char *token, *class = NULL; int i, len, error; int class_id = -1; char str[PPB_PnP_STRING_SIZE+1]; Modified: stable/11/sys/dev/ppc/ppc.c ============================================================================== --- stable/11/sys/dev/ppc/ppc.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/ppc/ppc.c Tue Mar 14 02:06:03 2017 (r315221) @@ -1329,9 +1329,9 @@ ppc_exec_microseq(device_t dev, struct p register int reg; register char mask; register int accum = 0; - register char *ptr = 0; + register char *ptr = NULL; - struct ppb_microseq *stack = 0; + struct ppb_microseq *stack = NULL; /* microsequence registers are equivalent to PC-like port registers */ @@ -1501,7 +1501,7 @@ ppc_exec_microseq(device_t dev, struct p mi = stack; /* reset the stack */ - stack = 0; + stack = NULL; /* XXX return code */ Modified: stable/11/sys/dev/sbni/if_sbni_isa.c ============================================================================== --- stable/11/sys/dev/sbni/if_sbni_isa.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/sbni/if_sbni_isa.c Tue Mar 14 02:06:03 2017 (r315221) @@ -132,7 +132,7 @@ sbni_attach_isa(device_t dev) } else { struct sbni_softc *master; - if ((master = connect_to_master(sc)) == 0) { + if ((master = connect_to_master(sc)) == NULL) { device_printf(dev, "failed to alloc irq\n"); sbni_release_resources(sc); return (ENXIO); Modified: stable/11/sys/dev/sn/if_sn.c ============================================================================== --- stable/11/sys/dev/sn/if_sn.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/sn/if_sn.c Tue Mar 14 02:06:03 2017 (r315221) @@ -393,7 +393,7 @@ startagain: * Sneak a peek at the next packet */ m = ifp->if_snd.ifq_head; - if (m == 0) + if (m == NULL) return; /* * Compute the frame length and set pad to give an overall even @@ -509,7 +509,7 @@ startagain: /* * Push out the data to the card. */ - for (top = m; m != 0; m = m->m_next) { + for (top = m; m != NULL; m = m->m_next) { /* * Push out words. @@ -607,7 +607,7 @@ snresume(struct ifnet *ifp) * Sneak a peek at the next packet */ m = ifp->if_snd.ifq_head; - if (m == 0) { + if (m == NULL) { if_printf(ifp, "snresume() with nothing to send\n"); return; } @@ -708,7 +708,7 @@ snresume(struct ifnet *ifp) /* * Push out the data to the card. */ - for (top = m; m != 0; m = m->m_next) { + for (top = m; m != NULL; m = m->m_next) { /* * Push out words. Modified: stable/11/sys/dev/sym/sym_hipd.c ============================================================================== --- stable/11/sys/dev/sym/sym_hipd.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/sym/sym_hipd.c Tue Mar 14 02:06:03 2017 (r315221) @@ -3710,7 +3710,7 @@ static void sym_log_hard_error(hcb_p np, } else { script_ofs = dsp; script_size = 0; - script_base = 0; + script_base = NULL; script_name = "mem"; } @@ -4296,7 +4296,7 @@ static void sym_int_ma (hcb_p np) * try to find the interrupted script command, * and the address at which to continue. */ - vdsp = 0; + vdsp = NULL; nxtdsp = 0; if (dsp > np->scripta_ba && dsp <= np->scripta_ba + np->scripta_sz) { @@ -6673,7 +6673,7 @@ static void sym_alloc_lcb_tags (hcb_p np lp->cb_tags = sym_calloc(SYM_CONF_MAX_TASK, "CB_TAGS"); if (!lp->cb_tags) { sym_mfree_dma(lp->itlq_tbl, SYM_CONF_MAX_TASK*4, "ITLQ_TBL"); - lp->itlq_tbl = 0; + lp->itlq_tbl = NULL; return; } Modified: stable/11/sys/dev/vx/if_vx.c ============================================================================== --- stable/11/sys/dev/vx/if_vx.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/dev/vx/if_vx.c Tue Mar 14 02:06:03 2017 (r315221) @@ -350,7 +350,7 @@ vx_setlink(struct vx_softc *sc) */ i = sc->vx_connector; /* default in EEPROM */ reason = "default"; - warning = 0; + warning = NULL; if (ifp->if_flags & IFF_LINK0) { if (sc->vx_connectors & conn_tab[CONNECTOR_AUI].bit) { @@ -729,7 +729,7 @@ again: /* Pull packet off interface. */ m = vx_get(sc, len); - if (m == 0) { + if (m == NULL) { if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); goto abort; } Modified: stable/11/sys/libkern/iconv_xlat16.c ============================================================================== --- stable/11/sys/libkern/iconv_xlat16.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/libkern/iconv_xlat16.c Tue Mar 14 02:06:03 2017 (r315221) @@ -268,7 +268,7 @@ iconv_xlat16_conv(void *d2p, const char * there is a case that inbuf char is a single * byte char while inlen == 2 */ - if ((u_char)*(src+1) == 0 && !nullin ) { + if ((u_char)*(src+1) == '\0' && !nullin ) { src++; ir--; } else { Modified: stable/11/sys/net/if_fddisubr.c ============================================================================== --- stable/11/sys/net/if_fddisubr.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/net/if_fddisubr.c Tue Mar 14 02:06:03 2017 (r315221) @@ -400,7 +400,7 @@ fddi_input(ifp, m) m_adj(m, FDDI_HDR_LEN); m = m_pullup(m, LLC_SNAPFRAMELEN); - if (m == 0) { + if (m == NULL) { if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); goto dropanyway; } Modified: stable/11/sys/net/if_iso88025subr.c ============================================================================== --- stable/11/sys/net/if_iso88025subr.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/net/if_iso88025subr.c Tue Mar 14 02:06:03 2017 (r315221) @@ -487,7 +487,7 @@ iso88025_input(ifp, m) m_adj(m, mac_hdr_len); m = m_pullup(m, LLC_SNAPFRAMELEN); - if (m == 0) { + if (m == NULL) { if_inc_counter(ifp, IFCOUNTER_IERRORS, 1); goto dropanyway; } Modified: stable/11/sys/net/iflib.c ============================================================================== --- stable/11/sys/net/iflib.c Tue Mar 14 02:04:44 2017 (r315220) +++ stable/11/sys/net/iflib.c Tue Mar 14 02:06:03 2017 (r315221) @@ -989,7 +989,7 @@ iflib_netmap_txq_init(if_ctx_t ctx, ifli struct netmap_slot *slot; slot = netmap_reset(na, NR_TX, txq->ift_id, 0); - if (slot == 0) + if (slot == NULL) return; for (int i = 0; i < ctx->ifc_softc_ctx.isc_ntxd[0]; i++) { @@ -1014,7 +1014,7 @@ iflib_netmap_rxq_init(if_ctx_t ctx, ifli int nrxd; slot = netmap_reset(na, NR_RX, rxq->ifr_id, 0); - if (slot == 0) + if (slot == NULL) *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Tue Mar 14 02:06:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 08F54D0B6B3; Tue, 14 Mar 2017 02:06:14 +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 CA9301BCC; Tue, 14 Mar 2017 02:06:13 +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 v2E26Cok070975; Tue, 14 Mar 2017 02:06:12 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E26Cxb070974; Tue, 14 Mar 2017 02:06:12 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201703140206.v2E26Cxb070974@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 14 Mar 2017 02:06:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315222 - head/sbin/ipf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 02:06:14 -0000 Author: cy Date: Tue Mar 14 02:06:12 2017 New Revision: 315222 URL: https://svnweb.freebsd.org/changeset/base/315222 Log: Revert r315218 so that it may be committed together with r315219. Modified: head/sbin/ipf/Makefile Modified: head/sbin/ipf/Makefile ============================================================================== --- head/sbin/ipf/Makefile Tue Mar 14 02:06:03 2017 (r315221) +++ head/sbin/ipf/Makefile Tue Mar 14 02:06:12 2017 (r315222) @@ -1,9 +1,7 @@ # $FreeBSD$ SUBDIR= libipf .WAIT -SUBDIR+= ipf ipfs ipftest ipmon ipnat ippool -# XXX: Disconnected for now. -# XXX: SUBDIR+= ipftest ipresend +SUBDIR+= ipf ipfs ipfstat ipftest ipmon ipnat ippool ipresend SUBDIR_PARALLEL= .include From owner-svn-src-all@freebsd.org Tue Mar 14 02:10:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5B0ED0B942; Tue, 14 Mar 2017 02:10:38 +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 B58081F70; Tue, 14 Mar 2017 02:10:38 +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 v2E2Abrb071183; Tue, 14 Mar 2017 02:10:37 GMT (envelope-from cy@FreeBSD.org) Received: (from cy@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E2Ab5b071181; Tue, 14 Mar 2017 02:10:37 GMT (envelope-from cy@FreeBSD.org) Message-Id: <201703140210.v2E2Ab5b071181@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: cy set sender to cy@FreeBSD.org using -f From: Cy Schubert Date: Tue, 14 Mar 2017 02:10:37 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315223 - in head: . sbin/ipf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 02:10:39 -0000 Author: cy Date: Tue Mar 14 02:10:37 2017 New Revision: 315223 URL: https://svnweb.freebsd.org/changeset/base/315223 Log: Disconnect ipftest and ipresend from the build until it can be verified that they still work. These utilities have become out of sync with the code in the kernel and need work to bring them back into shape. Most people test on real systems or VMs on real networks. Suggested by: glebius Modified: head/ObsoleteFiles.inc head/sbin/ipf/Makefile Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Tue Mar 14 02:06:12 2017 (r315222) +++ head/ObsoleteFiles.inc Tue Mar 14 02:10:37 2017 (r315223) @@ -38,6 +38,9 @@ # xargs -n1 | sort | uniq -d; # done +# 20170313: sbin/ipftest and ipresend temporarily disconnected. +OLD_FILES+=sbin/ipftest +OLD_FILES+=sbin/ipresend # 20170311: Remove WITHOUT_MANDOCDB option OLD_FILES+=usr/share/man/man1/makewhatis.1.gz # 20170311: remove GNU diff Modified: head/sbin/ipf/Makefile ============================================================================== --- head/sbin/ipf/Makefile Tue Mar 14 02:06:12 2017 (r315222) +++ head/sbin/ipf/Makefile Tue Mar 14 02:10:37 2017 (r315223) @@ -1,7 +1,9 @@ # $FreeBSD$ SUBDIR= libipf .WAIT -SUBDIR+= ipf ipfs ipfstat ipftest ipmon ipnat ippool ipresend +SUBDIR+= ipf ipfs ipfstat ipmon ipnat ippool +# XXX Temporarily disconnected. +# SUBDIR+= ipftest ipresend SUBDIR_PARALLEL= .include From owner-svn-src-all@freebsd.org Tue Mar 14 02:14:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 063DCD0BD15; Tue, 14 Mar 2017 02:14:01 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C973815B1; Tue, 14 Mar 2017 02:14:00 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E2DxQD074843; Tue, 14 Mar 2017 02:13:59 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E2DxmV074842; Tue, 14 Mar 2017 02:13:59 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703140213.v2E2DxmV074842@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Tue, 14 Mar 2017 02:13:59 +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: r315224 - stable/11/usr.bin/localedef X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 02:14:01 -0000 Author: pfg Date: Tue Mar 14 02:13:59 2017 New Revision: 315224 URL: https://svnweb.freebsd.org/changeset/base/315224 Log: MFC r314974, r315006: localedef(1): Fix small coverity issues. - Operands don't affect result (CONSTANT_EXPRESSION_RESULT) - Buffer not null terminated (BUFFER_SIZE_WARNING) CID: 1338557, 1338565 Obtained from: illumos Modified: stable/11/usr.bin/localedef/ctype.c Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.bin/localedef/ctype.c ============================================================================== --- stable/11/usr.bin/localedef/ctype.c Tue Mar 14 02:10:37 2017 (r315223) +++ stable/11/usr.bin/localedef/ctype.c Tue Mar 14 02:13:59 2017 (r315224) @@ -306,7 +306,7 @@ dump_ctype(void) return; (void) memcpy(rl.magic, _FILE_RUNE_MAGIC_1, 8); - (void) strncpy(rl.encoding, get_wide_encoding(), sizeof (rl.encoding)); + (void) strlcpy(rl.encoding, get_wide_encoding(), sizeof (rl.encoding)); /* * Initialize the identity map. @@ -379,12 +379,12 @@ dump_ctype(void) if ((ctn->ctype & _ISALPHA) && (ctn->ctype & (_ISPUNCT|_ISDIGIT))) conflict++; - if ((ctn->ctype & _ISPUNCT) & + if ((ctn->ctype & _ISPUNCT) && (ctn->ctype & (_ISDIGIT|_ISALPHA|_ISXDIGIT))) conflict++; if ((ctn->ctype & _ISSPACE) && (ctn->ctype & _ISGRAPH)) conflict++; - if ((ctn->ctype & _ISCNTRL) & _ISPRINT) + if ((ctn->ctype & _ISCNTRL) && (ctn->ctype & _ISPRINT)) conflict++; if ((wc == ' ') && (ctn->ctype & (_ISPUNCT|_ISGRAPH))) conflict++; From owner-svn-src-all@freebsd.org Tue Mar 14 06:00:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0FD1ED0A9FF; Tue, 14 Mar 2017 06:00:46 +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 D36A61EBB; Tue, 14 Mar 2017 06:00:45 +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 v2E60iei067345; Tue, 14 Mar 2017 06:00:44 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E60iq5067343; Tue, 14 Mar 2017 06:00:44 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201703140600.v2E60iq5067343@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Tue, 14 Mar 2017 06:00:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315225 - in head: lib/libc/gen sys/libkern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 06:00:46 -0000 Author: delphij Date: Tue Mar 14 06:00:44 2017 New Revision: 315225 URL: https://svnweb.freebsd.org/changeset/base/315225 Log: Discard first 3072 bytes of RC4 keystream, this is a bandaid that allows us to work on switching to a more modern PRNG. Submitted by: Steven Chamberlain Approved by: so Modified: head/lib/libc/gen/arc4random.c head/sys/libkern/arc4random.c Modified: head/lib/libc/gen/arc4random.c ============================================================================== --- head/lib/libc/gen/arc4random.c Tue Mar 14 02:13:59 2017 (r315224) +++ head/lib/libc/gen/arc4random.c Tue Mar 14 06:00:44 2017 (r315225) @@ -160,7 +160,7 @@ arc4_stir(void) * Discard early keystream, as per recommendations in: * "(Not So) Random Shuffles of RC4" by Ilya Mironov. */ - for (i = 0; i < 1024; i++) + for (i = 0; i < 3072; i++) (void)arc4_getbyte(); arc4_count = 1600000; } Modified: head/sys/libkern/arc4random.c ============================================================================== --- head/sys/libkern/arc4random.c Tue Mar 14 02:13:59 2017 (r315224) +++ head/sys/libkern/arc4random.c Tue Mar 14 06:00:44 2017 (r315225) @@ -84,11 +84,11 @@ arc4_randomstir(struct arc4_s* arc4) /* * Throw away the first N words of output, as suggested in the * paper "Weaknesses in the Key Scheduling Algorithm of RC4" - * by Fluher, Mantin, and Shamir. (N = 256 in our case.) + * by Fluher, Mantin, and Shamir. (N = 768 in our case.) * * http://dl.acm.org/citation.cfm?id=646557.694759 */ - for (n = 0; n < 256*4; n++) + for (n = 0; n < 768*4; n++) arc4_randbyte(arc4); mtx_unlock(&arc4->mtx); From owner-svn-src-all@freebsd.org Tue Mar 14 06:10:42 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 665E2D0AD2C; Tue, 14 Mar 2017 06:10: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 32D1313BB; Tue, 14 Mar 2017 06:10: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 v2E6Af6r071537; Tue, 14 Mar 2017 06:10:41 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E6Af2N071535; Tue, 14 Mar 2017 06:10:41 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201703140610.v2E6Af2N071535@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Tue, 14 Mar 2017 06:10: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: r315226 - in stable/11: lib/libc/gen sys/libkern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 06:10:42 -0000 Author: delphij Date: Tue Mar 14 06:10:40 2017 New Revision: 315226 URL: https://svnweb.freebsd.org/changeset/base/315226 Log: MFC r315225: Discard first 3072 bytes of RC4 keystream, this is a bandaid that allows us to work on switching to a more modern PRNG. Submitted by: Steven Chamberlain Approved by: so Modified: stable/11/lib/libc/gen/arc4random.c stable/11/sys/libkern/arc4random.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/libc/gen/arc4random.c ============================================================================== --- stable/11/lib/libc/gen/arc4random.c Tue Mar 14 06:00:44 2017 (r315225) +++ stable/11/lib/libc/gen/arc4random.c Tue Mar 14 06:10:40 2017 (r315226) @@ -171,7 +171,7 @@ arc4_stir(void) * Discard early keystream, as per recommendations in: * "(Not So) Random Shuffles of RC4" by Ilya Mironov. */ - for (i = 0; i < 1024; i++) + for (i = 0; i < 3072; i++) (void)arc4_getbyte(); arc4_count = 1600000; } Modified: stable/11/sys/libkern/arc4random.c ============================================================================== --- stable/11/sys/libkern/arc4random.c Tue Mar 14 06:00:44 2017 (r315225) +++ stable/11/sys/libkern/arc4random.c Tue Mar 14 06:10:40 2017 (r315226) @@ -72,11 +72,11 @@ arc4_randomstir(void) /* * Throw away the first N words of output, as suggested in the * paper "Weaknesses in the Key Scheduling Algorithm of RC4" - * by Fluher, Mantin, and Shamir. (N = 256 in our case.) + * by Fluher, Mantin, and Shamir. (N = 768 in our case.) * * http://dl.acm.org/citation.cfm?id=646557.694759 */ - for (n = 0; n < 256*4; n++) + for (n = 0; n < 768*4; n++) arc4_randbyte(); mtx_unlock(&arc4_mtx); } From owner-svn-src-all@freebsd.org Tue Mar 14 06:12:52 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA7E3D0AF49; Tue, 14 Mar 2017 06:12:52 +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 A6C8C181D; Tue, 14 Mar 2017 06:12:52 +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 v2E6CpEO075278; Tue, 14 Mar 2017 06:12:51 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E6CpMo075276; Tue, 14 Mar 2017 06:12:51 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201703140612.v2E6CpMo075276@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Tue, 14 Mar 2017 06:12:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315227 - in stable/10: lib/libc/gen sys/libkern X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 06:12:53 -0000 Author: delphij Date: Tue Mar 14 06:12:51 2017 New Revision: 315227 URL: https://svnweb.freebsd.org/changeset/base/315227 Log: MFC r315225: Discard first 3072 bytes of RC4 keystream, this is a bandaid that allows us to work on switching to a more modern PRNG. Submitted by: Steven Chamberlain Approved by: so Modified: stable/10/lib/libc/gen/arc4random.c stable/10/sys/libkern/arc4random.c Directory Properties: stable/10/ (props changed) Modified: stable/10/lib/libc/gen/arc4random.c ============================================================================== --- stable/10/lib/libc/gen/arc4random.c Tue Mar 14 06:10:40 2017 (r315226) +++ stable/10/lib/libc/gen/arc4random.c Tue Mar 14 06:12:51 2017 (r315227) @@ -172,7 +172,7 @@ arc4_stir(void) * Discard early keystream, as per recommendations in: * "(Not So) Random Shuffles of RC4" by Ilya Mironov. */ - for (i = 0; i < 1024; i++) + for (i = 0; i < 3072; i++) (void)arc4_getbyte(); arc4_count = 1600000; } Modified: stable/10/sys/libkern/arc4random.c ============================================================================== --- stable/10/sys/libkern/arc4random.c Tue Mar 14 06:10:40 2017 (r315226) +++ stable/10/sys/libkern/arc4random.c Tue Mar 14 06:12:51 2017 (r315227) @@ -80,9 +80,9 @@ arc4_randomstir (void) /* * Throw away the first N words of output, as suggested in the * paper "Weaknesses in the Key Scheduling Algorithm of RC4" - * by Fluher, Mantin, and Shamir. (N = 256 in our case.) + * by Fluher, Mantin, and Shamir. (N = 768 in our case.) */ - for (n = 0; n < 256*4; n++) + for (n = 0; n < 768*4; n++) arc4_randbyte(); mtx_unlock(&arc4_mtx); } From owner-svn-src-all@freebsd.org Tue Mar 14 06:52:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 052A7D0BE33; Tue, 14 Mar 2017 06:52:56 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C5E8A1D94; Tue, 14 Mar 2017 06:52:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E6qsYf091460; Tue, 14 Mar 2017 06:52:54 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E6qssX091459; Tue, 14 Mar 2017 06:52:54 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703140652.v2E6qssX091459@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 14 Mar 2017 06:52:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315228 - head/tools/build/mk X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 06:52:56 -0000 Author: ngie Date: Tue Mar 14 06:52:54 2017 New Revision: 315228 URL: https://svnweb.freebsd.org/changeset/base/315228 Log: Redirect standard error from find /rescue to /dev/null This mutes noise from find when /rescue doesn't exist. MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/tools/build/mk/OptionalObsoleteFiles.inc Modified: head/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- head/tools/build/mk/OptionalObsoleteFiles.inc Tue Mar 14 06:12:51 2017 (r315227) +++ head/tools/build/mk/OptionalObsoleteFiles.inc Tue Mar 14 06:52:54 2017 (r315228) @@ -7484,9 +7484,9 @@ OLD_FILES+=usr/share/man/man8/rwhod.8.gz .if ${MK_RESCUE} == no . if exists(${DESTDIR}${TESTSBASE}) -RESCUE_DIRS!=find ${DESTDIR}/rescue -type d | sed -e 's,^${DESTDIR}/,,'; echo +RESCUE_DIRS!=find ${DESTDIR}/rescue -type d 2>/dev/null | sed -e 's,^${DESTDIR}/,,'; echo OLD_DIRS+=${RESCUE_DIRS} -RESCUE_FILES!=find ${DESTDIR}/rescue \! -type d | sed -e 's,^${DESTDIR}/,,'; echo +RESCUE_FILES!=find ${DESTDIR}/rescue \! -type d 2>/dev/null | sed -e 's,^${DESTDIR}/,,'; echo OLD_FILES+=${RESCUE_FILES} . endif .endif From owner-svn-src-all@freebsd.org Tue Mar 14 06:57:57 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3401BD0B057; Tue, 14 Mar 2017 06:57:57 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EF7F510B0; Tue, 14 Mar 2017 06:57:56 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E6vu6W091733; Tue, 14 Mar 2017 06:57:56 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E6vuG0091732; Tue, 14 Mar 2017 06:57:56 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703140657.v2E6vuG0091732@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 06:57:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315229 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 06:57:57 -0000 Author: mav Date: Tue Mar 14 06:57:55 2017 New Revision: 315229 URL: https://svnweb.freebsd.org/changeset/base/315229 Log: Remove remnant of r315163. MFC after: 13 days Modified: head/sys/dev/isp/isp_freebsd.c Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Tue Mar 14 06:52:54 2017 (r315228) +++ head/sys/dev/isp/isp_freebsd.c Tue Mar 14 06:57:55 2017 (r315229) @@ -52,7 +52,6 @@ static const char prom3[] = "Chan %d [%u static void isp_freeze_loopdown(ispsoftc_t *, int); static void isp_loop_changed(ispsoftc_t *isp, int chan); static d_ioctl_t ispioctl; -static void isp_intr_enable(void *); static void isp_cam_async(void *, uint32_t, struct cam_path *, void *); static void isp_poll(struct cam_sim *); static timeout_t isp_watchdog; From owner-svn-src-all@freebsd.org Tue Mar 14 07:00:25 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 63267D0B12E; Tue, 14 Mar 2017 07:00:25 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 203891243; Tue, 14 Mar 2017 07:00:24 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E70NIg091925; Tue, 14 Mar 2017 07:00:23 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E70MXc091919; Tue, 14 Mar 2017 07:00:22 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703140700.v2E70MXc091919@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 14 Mar 2017 07:00:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315230 - in head: etc/mtree tests/sys/geom tests/sys/geom/class/eli tests/sys/geom/eli X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 07:00:25 -0000 Author: ngie Date: Tue Mar 14 07:00:22 2017 New Revision: 315230 URL: https://svnweb.freebsd.org/changeset/base/315230 Log: Move .../sys/geom/eli/pbkdf2... to .../sys/geom/class/eli/... This change moves the tests added in r313962 to an existing directory structure used by the geli TAP tests. It also, renames the test from pbkdf2 to pbkdf2_test . The changes to ObsoleteFiles.inc are being committed separately as they aren't needed for the MFC to ^/stable/11, etc, if the MFC for the tests is done all in one commit. MFC after: 2 weeks X-MFC with: r313962, r313972-r313973 Reviewed by: allanjude Sponsored by: Dell EMC Isilon Differential Revision: D9985 Added: - copied unchanged from r315229, head/tests/sys/geom/eli/pbkdf2/gentestvect.py - copied unchanged from r315229, head/tests/sys/geom/eli/pbkdf2/hmactest.c - copied unchanged from r315229, head/tests/sys/geom/eli/pbkdf2/testvect.h Directory Properties: head/tests/sys/geom/class/eli/gentestvect.py (props changed) head/tests/sys/geom/class/eli/hmac_test.c (props changed) head/tests/sys/geom/class/eli/testvect.h (props changed) Deleted: head/tests/sys/geom/eli/ Modified: head/etc/mtree/BSD.tests.dist head/tests/sys/geom/Makefile head/tests/sys/geom/class/eli/Makefile Modified: head/etc/mtree/BSD.tests.dist ============================================================================== --- head/etc/mtree/BSD.tests.dist Tue Mar 14 06:57:55 2017 (r315229) +++ head/etc/mtree/BSD.tests.dist Tue Mar 14 07:00:22 2017 (r315230) @@ -425,10 +425,6 @@ .. .. .. - eli - pbkdf2 - .. - .. .. kern acct Modified: head/tests/sys/geom/Makefile ============================================================================== --- head/tests/sys/geom/Makefile Tue Mar 14 06:57:55 2017 (r315229) +++ head/tests/sys/geom/Makefile Tue Mar 14 07:00:22 2017 (r315230) @@ -3,6 +3,5 @@ TESTSDIR= ${TESTSBASE}/sys/geom TESTS_SUBDIRS+= class -TESTS_SUBDIRS+= eli .include Modified: head/tests/sys/geom/class/eli/Makefile ============================================================================== --- head/tests/sys/geom/class/eli/Makefile Tue Mar 14 06:57:55 2017 (r315229) +++ head/tests/sys/geom/class/eli/Makefile Tue Mar 14 07:00:22 2017 (r315230) @@ -1,9 +1,13 @@ # $FreeBSD$ +.PATH: ${SRCTOP}/sys/geom/eli ${SRCTOP}/sys/crypto/sha2 + PACKAGE= tests TESTSDIR= ${TESTSBASE}/sys/geom/class/${.CURDIR:T} +ATF_TESTS_C= pbkdf2_test + TAP_TESTS_SH+= attach_d_test TAP_TESTS_SH+= configure_b_B_test TAP_TESTS_SH+= delkey_test @@ -40,4 +44,19 @@ ${PACKAGE}FILES+= conf.sh TEST_METADATA.$t+= required_user="root" .endfor +CFLAGS.pbkdf2_test= -I${SYSDIR}/sys + +SRCS.pbkdf2_test= \ + hmac_test.c \ + g_eli_crypto.c \ + g_eli_hmac.c \ + pkcs5v2.c \ + sha512c.c \ + sha256c.c + +LIBADD.pbkdf2_test= crypto + +testvect.h: + python gentestvect.py > ${.TARGET} + .include Copied: head/tests/sys/geom/class/eli/gentestvect.py (from r315229, head/tests/sys/geom/eli/pbkdf2/gentestvect.py) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tests/sys/geom/class/eli/gentestvect.py Tue Mar 14 07:00:22 2017 (r315230, copy of r315229, head/tests/sys/geom/eli/pbkdf2/gentestvect.py) @@ -0,0 +1,63 @@ +#!/usr/bin/env python +# $FreeBSD$ + +from hashlib import pbkdf2_hmac +import hashlib +import itertools +import string + +#From: https://stackoverflow.com/questions/14945095/how-to-escape-string-for-generated-c +def cstring(s, encoding='ascii'): + if isinstance(s, unicode): + s = s.encode(encoding) + + result = '' + for c in s: + if not (32 <= ord(c) < 127) or c in ('\\', '"'): + result += '\\%03o' % ord(c) + else: + result += c + + return '"' + result + '"' + +intarr = lambda y: ', '.join(map(lambda x: str(ord(x)), y)) + +_randfd = open('/dev/urandom', 'rb') +_maketrans = string.maketrans('', '') +def randgen(l, delchrs=None): + if delchrs is None: + return _randfd.read(l) + + s = '' + while len(s) < l: + s += string.translate(_randfd.read(l - len(s)), _maketrans, + delchrs) + return s + +def printhmacres(salt, passwd, itr, hmacout): + print '\t{ %s, %d, %s, %d, %s, %d },' % (cstring(salt), len(salt), + cstring(passwd), itr, cstring(hmacout), len(hmacout)) + +if __name__ == '__main__': + import sys + + if len(sys.argv) == 1: + hashfun = 'sha512' + else: + hashfun = sys.argv[1] + + if hashfun not in hashlib.algorithms: + print 'Invalid hash function: %s' % `hashfun` + sys.exit(1) + + print '/* Test Vectors for PBKDF2-%s */' % hashfun.upper() + print '\t/* salt, saltlen, passwd, itr, hmacout, hmacoutlen */' + for saltl in xrange(8, 64, 8): + for itr in itertools.chain(xrange(100, 1000, 100), xrange(1000, + 10000, 1000)): + for passlen in xrange(8, 80, 8): + salt = randgen(saltl) + passwd = randgen(passlen, '\x00') + hmacout = pbkdf2_hmac(hashfun, passwd, salt, + itr) + printhmacres(salt, passwd, itr, hmacout) Copied: head/tests/sys/geom/class/eli/hmac_test.c (from r315229, head/tests/sys/geom/eli/pbkdf2/hmactest.c) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tests/sys/geom/class/eli/hmac_test.c Tue Mar 14 07:00:22 2017 (r315230, copy of r315229, head/tests/sys/geom/eli/pbkdf2/hmactest.c) @@ -0,0 +1,41 @@ +/* + * $FreeBSD$ + */ + +#include +#include + +#include + +const struct { + char *salt; + size_t saltlen; + char *passwd; + int iterations; + char *hmacout; + size_t hmaclen; +} testdata[] = { +#include "testvect.h" +}; + +ATF_TC_WITHOUT_HEAD(hmactest); +ATF_TC_BODY(hmactest, tc) +{ + size_t i; + uint8_t hmacout[64]; + + for (i = 0; i < nitems(testdata); i++) { + pkcs5v2_genkey(hmacout, testdata[i].hmaclen, + (uint8_t *)testdata[i].salt, testdata[i].saltlen, + testdata[i].passwd, testdata[i].iterations); + ATF_REQUIRE(bcmp(hmacout, testdata[i].hmacout, + testdata[i].hmaclen) == 0); + } +} + +ATF_TP_ADD_TCS(tp) +{ + ATF_TP_ADD_TC(tp, hmactest); + + return (atf_no_error()); +} Copied: head/tests/sys/geom/class/eli/testvect.h (from r315229, head/tests/sys/geom/eli/pbkdf2/testvect.h) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tests/sys/geom/class/eli/testvect.h Tue Mar 14 07:00:22 2017 (r315230, copy of r315229, head/tests/sys/geom/eli/pbkdf2/testvect.h) @@ -0,0 +1,1137 @@ +/* $FreeBSD$ */ +/* Test Vectors for PBKDF2-SHA512 */ + /* salt, saltlen, passwd, itr, hmacout, hmacoutlen */ + { "\331}\035\215\000\272\350\261", 8, "\323\303\210\231\260\225\217\035", 100, "J\257\275\352n\371\300!tp\367\257\347c'\000\243F\246\376\274H\263\312m\336\304\3515P\222Cb\037-\313W\0067\232\024%\235\252\322\035\225k\025\2248\251r\312]v\316\021j\231\224\2556\350", 64 }, + { "\321\213\277\330\210E\207x", 8, "(C\371\344\354\356\232\212\346\014\335M(\234g\226", 100, "\035MoB\245\001\000\315\332\235\356?alD\231I[%A\372\367\027\267,\303\022\324\004\302a\302t\257\306S\251\250;-pa\246Z\200\003*+\026\305_\250\214n\321\340.\032a3\371\346\025\042", 64 }, + { "\344\353\215\257\020\315\245\367", 8, "/pj@N\344\271\243^\352\236gu\352\344os\366FR\362\001\347\301", 100, "\223eS:\015\311\023\317\230O\012\347\014\32070\321\337p\353\305\361\223\323\333&\011'\360?\022\374P\336\337\031\266,~@!\037\000\320v\360!\225\221@C\266|k\370@\305\202\235+\314\247\305&", 64 }, + { "\364\275\222\376\0064\240g", 8, "_\2000 A\233#\372\351\332\247\010\313\274\334\255\362J\356\333\302\345\317\305*\357 \366Aj\344\346", 100, "\223\015X\340\024\244\2767\027\253\261\232\360(?\350H7\326K\322\246\341\222\202:@\254\3218\016T\275\212^\005\344\202\230\220s\311\201\025\233~K6\241*b\244\203\273\355\270\277\242\300V3\037\224\311", 64 }, + { "\272\207\326\030\010\374\263f", 8, "\323\230\233\317\337\001\241]G\312\347\320K\3374\247\016\343\246\353\300\373\267\335\314h\216\245$\373\210\214\014b\340\377\256\0202E", 100, "a\274S.\032\246\330\321\322\207\004\241n\303\363\361\361\215\367Xi\250\275\246\037\355\255\342\004\253\250\243&\032\357\250\204\207K\2612\0318\3353\253\335Z\351\337\253v\345\322r\030\0066\230jp\345\373\203", 64 }, + { "j\276\230\215\031$\326v", 8, "gy\264\354\363\322(w\262\272\203\306{\356\031\376\277+\276L\337\270G\345!>29\010\204m\240!\326\255\326\321\272(\325T\033B\262[\267]\272", 100, "\2563\024\201\310\372\017\373\270\232\277\265:j\231\365\032zS\3723\012\341i\302V\233l\247\030:\355\262]\337\361JUe:\350|#D\262\335)\260\333\273\221\252\005\226\322'\371+a\270a\302\276p", 64 }, + { ",;\270P\012\035\262\235", 8, "\375 \232J\304\271_\272\033\027\363\021\227\260\323\310\304k\004.\327\354\217,\357\353]I0\332We\245\257\371,\260\360\325\224\026q[VuS\217\004\262\376T\353\262\321\241\024", 100, "\313\246&~\374Zq(0\000\002\332\356\355M\353Z?\310~\234\327\011\242\370\032GK\250\020\203sJ\234I,\271\012\230\204g\323\345\343\343\350\231\227\015\350b\256\012\367Q\255v\365\210\247\2614\210\365", 64 }, + { "\021\325\267u\203$\352\274", 8, "\232\032\225'\021*'a\042\023{\250\361r\262\365\370\032\347\336\363Re28\033J\3763^\311I\322:\036\204\320\033\245\200\262\225\341\377\334\241p\314\334\005O,\374\225\234\014\266\365\030i6\210a\205", 100, "\220\006\216\2420-8m\2766\353(6\212\306\261C@\252\2104\005\205\274\204\365\226\373\016\345\332\207\361A\244\023W\3051:\277\2705Z\253\262\371M\024L\215\224\340p\336\355\250\030*8\300\017\254f", 64 }, + { "[\353e\224\2423\270m", 8, "\1776\374\302o0\007\307w\032\307\266\376\320\042/\266\352\233\224\316\3616\314!`\015d\316\370L{\201B\245\317\366@V\036\227\273I\205\251\306GW\200*\340P\267\202#\354\330\266O\347\254(\203\270\366w\274\375\272\016\240\313", 100, "?j\005\340=\022\012NM\024\231\220_u\023@\042\214\014b\375\251\023\244y3m\330\377\341\271~V0\263\223\274\325Rmug\026Dt!\347%\270\244\371@\177\350\250N\320\246\034\320\013|\276\027", 64 }, + { "\262\304(\244\326\272\262\311", 8, "\210C(\273\376\013/\034", 200, "6+\233\201\350\374\2053\013\377SA\007\037\303\027RyrC\361\303\321\031\225d\215\314\213\210\006\031\217\035L)\377'\016\263\310\206\326\372\362\230\226.F\134\277\367\35357(\214\262\036\310@\363#\020", 64 }, + { "\246<\216\226^F\004\036", 8, "\344].\210\212\236\252f\256n\006\250\2615\325\371", 200, "\213J\234\270\227$St\265\035\323\001&\025\027T>\015F\205\325\361_\003l\245|\213S\232@\254o\227\235l$\355\037\214\220\032\213\320\265lM\334\320\313+\205.\355\310\201K\370^\025\134\346[K", 64 }, + { "9s72\020\270\251\350", 8, "\323\370:k\323o\271Y\335\306\375#\333\222\246?C\313\023\202>\005\025\216", 200, "\371\373\341\202(\231\010\325_\335\205\253\216\371\227\354\352Os2\356e\033L\236znr;\337a'\025\335n\032f\304\177u\001n{\236`\261\346N\2748R\017\243\226[\256@<\021m\202r\363g", 64 }, + { "\032\216\254\215\022l\001H", 8, "\027J\232\302\240lTSU\215y\262\360\017\346\3253\276r\276\211\306>\3740\263\264\002\333J;\262", 200, "\3206K,\267r<\302r\207y\373\3625]2Y\3710\343\272\211\202\3465g\340jG\001`\341\352\313\203\250x\221K\254iV\350w\2220\257Yc\360Z\263\237\255\042\325\341\307\330\232s@?\210", 64 }, + { "D\302g\023\316\224l\271", 8, "\262t\301{\366\345Bv\271!\213\303\244O8\314\336\363\325|\206x\034d$#\001x9\012\241\256W\241\334\307\240\207F", 64 }, + { "\037\346\010\241]\004x\204", 8, "T\334\371\316I\33656Q\027\277\203\033\303\240\371\231\352\214\3701@\002\015?2\264\002\257R\205\250\264}\021\012\326\366wF\311\267\271\0042C:/\341\031\242\337\237.\021V\034\263`W\306Y\3533", 200, "V\370Nt\341W\226|\367\226\200\033|\006Kii\263\304\307\347\301#L\371\335l|O\304\300v\361d\255h^\322\026\332U\224\270\255\227\022\226G\326\363\303\244\234\235\016/<\331\247\307\242\355\226\307", 64 }, + { "\364\303X\325\327\256\342f", 8, "\227E\237\320\214GB\332\005\0333\250=\020c(\345\007?\032)\2643\243\202\371\200\030\002\225\011/\030\030\003Q\354\344\361B\214\333.\015\336`\376.\360\243$\017\367K\207\212\347L\356S\230\346\034*\307\207\203\233a\310\370\255", 200, "L(\217#(\300jA\343\037\251rR\312G\024\016dj:\212|\024\373\275\134\375\374\247\266FpF\275:\373_\314\134\244\016\373\203k\265\225\243\212t\240\310\347\226\262%\233\213\332w\042WL\302\331", 64 }, + { "c\027\266\220\010\031\241\313", 8, "F#\323\2367\260\323\273", 300, "@\200\033\254\020\246\206L$\203\026.T\223\205\364\362@\204*\316\232u\033\321\212;l\202\313s\205\333<1~\211\267\213\336Z\276\233W\322\366!\3629l\343@O\216+[!\262I\350\262\312\022\357", 64 }, + { "\001\277`\003x\301n\313", 8, "\257'\372i.M$\356\230\032\252yq\302\004c", 300, "?\037\327=m\335R\367?\242q\002\023V\203\017q8\252\325?6\213\241\274\275\356\344*\312/p~.<\305\346]\377\242\361\025\311\375\303\247\305\345@U\230\364F\275\211n\250Ay\352\026+\253V", 64 }, + { "\203\020{)\016R\324\350", 8, "\261\200\031:\346l\242u\352\300\014_\320\221y\213e\214\352\042c\371\257\361", 300, "\001\2111R\305R'b.L\007$\042\267\346\304(|+2\240\260\021\042\243J\344\237\006\236\203A\032\363\356\251\015.\321\336\03431X\002\355\221\313]\264\310\315o\316aw\246|\312bT:\325\300", 64 }, + { "\002X\311\253\033h\036'", 8, "P\206\257!\305E\377\275\310\005\364Bn\005\342>!w\017@}\245\350\177\305\312\323\361,\301y\022", 300, "\360\301\033\007\367,\374\242\177\3153D\251*_>{\005\272NQ\021\024:0\036\357\333c\254/\001\035\202\341\330\005\0245\265b}\261\232\273\0318\225\227\252\210\361\300\016\357\323\204\202\246\376\277@\225w", 64 }, + { ">+\207\003k\311\225\276", 8, "((\260Eak\253\305\3243Q\332*N\276\323\325_48\317\264&\340\005\323N\224p\003\331Fl\215\317 w\034u?", 300, "\276\317.\310Gj \217\3502.za\021\230\322C6\255\301\354-\263\247\002\352\377\267]\243\201n\245\213D\240\010D|\324\336\251\326\342e\231\350*\300\315\007\234\236\002}\372\013\364\257\232\262:\207e", 64 }, + { "\265G\357\330S\302?8", 8, "7S-\203\036\340\015\356\027\253\302\376\222\037\2276\0141|p\255\313\325\211\206\265\230\333\027\343\231\007\335\366\356\011 $ \312`\333y\267K4\317\277", 300, "\004\264\241\262\204\361YL%#v\373\013@E/\335\353 l\365\242u\215\301p\360O\030{\0236\033\206$\340\263\202bC\032\014\252\365\323\325\350u\210\234\020\037\015\275\000{h\363a\244\024\177\356\236", 64 }, + { "I\257\321\376\365\317\267I", 8, "\200!XxW\233B\374,\362\027,\343\022\204\220\373\231=\376\343\362\246\224 \001\233\015\0338\337\224#%\320\037\342\276\314X{h\036\210w\377\011@=\021\034\3429!\211\350", 300, "`\277s c\215t\251,\306:L\267`u%D\244\021\340\036C\304\032\014u\042\134Mzo\313\225\3641\017\037\271q*\321\023\227\253\215\330\351\373\202\220\274`P\267\277\373\007\366\370\031\350\015\214\245", 64 }, + { "\324\366\347;\363R\300!", 8, "y\262~C\031\252 \004\215a\033\355l9\024C\237b/\032Kk\316q\257K\017\017\036\316\003\246\005\225(\0168\264\032pT\030\250\334\341\020\012X K\325\002\254mh\265\134N*?\233\007Zn", 300, "\202\252\261h$8%\335rv\260\0005\313Lj\244\262\342\202\352\277\005 \2418\2740Y\333\036\014[\015\030'O\351\377|D\0114O\344\203\177\360\337\3610\315\323\2528\247\307\3535R\366)\033\236", 64 }, + { "\301\357\263\261\347O\344,", 8, "\216\376\312\271K}\224Pt\022\2572\230lR\177\340m\224\271\305\237Z\374\252\204\313M\307&\330]^W[\001\317\207\264\305\017\224\331\245\361\301Z\371r\264\223\202\201\353\252k\223Bk\361\323c\307\255(\010:x%\257\3352", 300, "\312\240!.\3606\236]\235\315\2409\042?\027\015\271\030\352l>\272s\345\340\231\317\263\306W6[\342\360\307\305 !\357\003|g][\275j=ptx\344\265\271~\036_\361\004\246\261\313\241D)", 64 }, + { "\257\000;+\233Q\214b", 8, "eoq{\270\246ua", 400, "\251B\370\245m\000>\134\007\256\373\001\251\262,\310\367\376\323\334{K\202\177\235\376x\365D(+\367\361\373\031\376\254H\243\305/N\267\205\2108\301*\025@\030\311\012.\261\237\377\015\205h\261\042\372\034", 64 }, + { "hU\325\246:obb", 8, "?/\352\332\327c\027\331\305N'\321\355\337\316\241", 400, "\177\312\2275\203 \026aNXF\010\377\336=\240\025\312\252r\01363\234\351\2754[y7E\334CQ\371\243F\010l\2545\253\214\341\323\300u\202\225\236\250\356\007Q\000Q\302\207M@g\350m:", 64 }, + { "p(\256-\313\020{\300", 8, "\334\310\227\225J\356\360\307!\353\023\332|\214\306\036\026\253|-\267\341\321\223", 400, "\267\250\271J-\265\303\247\337ib\237l>\352\344\302\3321\3006\240\233\232N\2661\236\022s+\300\1342\375%\251Yl\032kK}\227T`\364\233v0|/\217\026\032\261\020\225\335k@`\021\227", 64 }, + { ",\032\034\337\304,\340\334", 8, "\011F\350\213N\0058\212}N\267\007\007E\276\203C\315\332\013\030`\372\030\370\001\240\030\354@9\327", 400, "\206A\034\355\042\030\025\220\000\251\025`\356\372Fr\313\246L\307\255@;\366\354\346\362\206h\023>A\271\273r\036\224\325Q\246\2527 ^\014!\240:|\335G\322\333\032\005ok~\371\372\255oD\257", 64 }, + { "H\322\305\000\020\341\365\243", 8, "\330\313R\037\276\004\355\327\363QH\327\364r\305}\014\370\007B\252xS\345\003\346\202\366\250\375\237\315 \205\355\214Rj\037\365", 400, "u\346\0049k\347\134\211\023\330\015\360o`\217\266\234\012\007\003\270\025A}\373^\366d:n\344\000PqM\314\200\213<\204:N\0279\323z\337\271\031\337x\0007\352\220\032b \303\346`\201\2729", 64 }, + { "\236\271\202\214\310\003r\323", 8, "\020>\356\364\222*\307l\337\312\351\343R\273pxL6|\305\324\362\273>\332\245t\3267\212\276\231\310\343\243\034X\360,\224il\313\374\217\2407\134", 400, "\224?^QsO\227|\332iTx\204=g\360\033\352\240`\330L\212\276(\201Dx\017\216\016\231\307^\204K%^\327\360\257\236\005j\010\233\371H\203n`zx\230cH\320,M\315\344%\215\024", 64 }, + { "\353h~\2307\320gN", 8, "\235H\252\037+\014\003\265\235*v\020I\376\207\331\222\266\274\0270tb\341\276.\306w^\331\270\263k\341%\270\200\232\321b/\244\310\016\361\316\362:\375/\371\255B\307./", 400, "\221Y)\236*\214\226e\360\324\257\367\230R\014_\314\214\236\027O\004\305\370\317w\257\260\001w\245\003P\371\335Y\240\227\365\243bh\254\372\247\375\301)k\255\245&\262\036\374_\026\224\326D\220\336\246\351", 64 }, + { "\362\023\013 \331\240-M", 8, "\353~\003\260'd@\026_<\301\360]EU\332i\336\177g\347\313\232\337\3562\010\250\345c\235\265\236\343;\322\302~\317\371\002~\027\012\332\301r\014#\322\004\353\261\275g\263\017(W>{`\322P", 400, "SA\003b\271\034\227\224gN\023\203\207 mW\365\257Nz\267wn\016\221\017g%(n\256/\330\311\377+\335\261\343CA\015A\272\352-\345`\245\370W6\020Y\215\2212\000\272\001\022$*\376", 64 }, + { "\250c`\236vN\302\210", 8, "\257(\256\0171z\243\023\042\134\363\223\252}GzB\307\261\220\301\270\027\327\326\353\253>\313\276\006UAd\355}\276\320)\375`E\353*-\370\226\370\021\004\203\374e\016e\275\202\313\227AP/?5\260\225\217\243\276Ag\377", 400, "\203\022\352c\27522Z\265mo\224\016G\376/C\026\000{\0201\015(\224\005!fV\262\204N\265\206\202\336\255\362\036\015\330\241!5\247\035rVG\346v\301W\306\204\335HS\371Tlq\207\334", 64 }, + { "\327\002\265\344\005\337@O", 8, "\233\317\326\221:\2409Y", 500, "\134\021\253\352\370\313yg<\015\200\022b\317Vq\262\220\257fL\315\302\201\266\036lxQ\371\021 J\337)(2\346\017V2\310\217\030\274I\357\215\2115\277p\351\236\012\272\346V:\317\003\326\2062", 64 }, + { "\320u\027+-\245\0217", 8, "\216\257\376\3147\035d\300\366\365\315\320w\304\236$", 500, "\001_\134H\237\352\244\340\034\274\366\034H\321\311\216\255R_U\263\221\206J\301\2641\304J~\274oH\007\340\246a\313\204>\216\330\311x*<\334T\216\251S\322at\360\234\243w3\033\2061PL", 64 }, + { "#@\256\000\333y\350\327", 8, "Rb\213R\263\262W\317\333\354\261\340\246\26119H\334\277U\253\266C\247", 500, "\343\224\023a\337\367\347\276\245\310-(\363\021\271\221_\360\245\233\356S\236\363\027\212\0046*\244\376\3032\352\007\023Fs-\332\203#+\355\244\33654\205a\200\302w\314\335\0157\212S\227\271l\202*", 64 }, + { "\350e\303Y\257\366M\223", 8, "d\311\323\036\030%\266j\372\006\016\024;\344\350\256\234\026\341el\325\270\236\226\020\312b[\212\353\343", 500, "F\026H&\347}\264@\307\246ap\356W\272P\023\254\204/-\006\337u\230K\221\204\312h\337Q\021\037p9\222U\032\262k~\013e\017X\134/\243\264>j\251=DBu_*\350Z\260\010z", 64 }, + { "\277\212\2413\001K\016_", 8, "\005<#\022(`\277\021/J4~\363\354x\207\271\211Ft\233\026\252\326:\236", 500, "\220\344\307\355\203\332\013\207\2504\364\207\303\026\316\251\026X\367\373sN\225\2540\243\006\233/l\224\370\310\346\352\227}K\267\223E,\010G{e\270>})\274\312\001\3350\311\261\367?7\251|i\243", 64 }, + { "\271\035\035\334\321\366u\304", 8, "\325L\272\252\211;\134\014}^\270\007<\316[68S\361\3264lA\240}\025l\032\265\036\247\227!\035x\354C\262[\177\320\324\305%\333{\317*V\220\027\367\322_\234\017\253]\024\347dDB#>\373\003\216\347\333r\220Z\334\301\346\356']\323 \375t7cQh\010\004v\2253", 64 }, + { "\275\303\226\316\005\315-\300", 8, "\223\241?\356\014`\255l\337ad\241k\345\355\226\334\266@\217C\221\237\005", 600, "\312\375\227\367e\311\261\367\012\304\303\372K:\226\326\010E\235\355A\225\331j\026n\3264\303\301\324\214YnM\261\310\020\002bi\324\311\247\011\237{;\013\216C<> \017-xk\370\265\303\333\311\014", 64 }, + { "J\242\213\023\026l\3506", 8, "\303\020\346\376\230\303\347=_\355#\0015\363\345+\233\216\203l\347rSa\272Q9\336>\034\257\233", 600, "\3331\377\232\361\326D\362V#\2124l\237\327\215\231\375%|)aM\037\201\030\027\341OxFU<\306\302\355fO\326\325\242\177A\254\316H\247V\227\342\032\377\002\256VY\220\303\363\206[j\222\226", 64 }, + { "\222\360%qi`\034\316", 8, "\370Hx\232\025]yH\337ys\310\032f\317g\371\315-zT\225c4\033Uy\021\314\013\337\260\247G_4s%\261\004", 600, "\336lk\337\003M\223\020y\344p\356\250\000\301z\337\263.WN),\335!\375\227\210\367d\263Z\214Y\330\333\264\030\004\326\011W\005\323\3448\354(^T'\200\255\301\320\012\355F\240\271\203\012\353\313", 64 }, + { "0\015\376\022\354\343\255/", 8, "\304\347\345\335\327g\331\204\343\025\246\030\247y\365-\266\264\361\212\366\211\035\216\276+\235<\371\321\226[\250\336\346tn<}\247\2076%\231\373\227o\351", 600, "\201\306eLu\262\032\355\246H`2\246\247-\007\217H;\017\370\277\237)\275='\001HG$\134\223N\000\335n\304y\272\205N\2265\310\305o\250# \235r\312\236\217W\324\360\323\007\351\215\232+", 64 }, + { "\030\253\370\026\377\013s\252", 8, "\337\202p\313\334&[ql\346\042\350\016\272+\322|\004S5d\223]9}\250\253EW\357+\215\315\255\246\023\352>\274\001\027\231x\225#\261:n\342\012l\253\005\036\134\327", 600, "\223\241\274\227M\2322t\205\027\016\377\267\015\350\012Y \321\217\000\305\305Y\322\301\260\316\230\200\003rQ\235\245\177\003\305\342\022Iu\375\323>1W\002\013\321k\264\334?\225:!\377\014\331\206\270\371'", 64 }, + { "a\033o\014\314\261\004\243", 8, "y\340j\235ZH+4\023}\372=4\262\303\213\134|\220\252\255\0014\021\262\355\224\212\312\341\277 l^\021t\261S^j\007\313N\005\277\340\224\345\320\346\226eH\042\313q\271i\317\023U]B\331", 600, "\355=1\261\000\236>\260t@\241\370\305\323\2139\016\316vb\352\2533\336L\015\371\321\265\211_\273\177c\311UAa8P\263\017\272\037\217<\201\327\205\002IV\227\034\273\002\002\3312#\243\225\327b", 64 }, + { "[$\035\042a\220:c", 8, "j\312\316\373\207\241\335\304\0327\033\263\274[\305\234\371\224\253\012\266x\340\224V\230\335\374l3\320L\252\306qA\344\3069C&H\265\211\306X\347\311:\376\223It,\251\300!h\24791\371V\007\375\233J\032\330.\236U", 600, "`l\213nT\353\237\304\251I\256 >C\231\000X\377\332\206\204K\262Z\353\327\022\265}\245y\232\3368WI\332/\213\316\042\371\200\033\0378\322U4J\363\360\357\350\361*\367.>\363\377\334\0232", 64 }, + { "\354\304\015\017\355\240\021\276", 8, "\247\274\225<\353\357\376c", 700, "\374\221\245\277Y\007w\274\375\266'l\316\243\333\312\223\257\301\270\303K\337q_\331\354\347\376\012\223\275\344\001t\373F`\235\302\3108W\332\205Q\223d\004\207\223aki\277\307\313}\326\254\234v\042\341", 64 }, + { "IZ\367\257\273\377\332k", 8, "i\027\226\010\004~\257w\273?\222\224\212\274 C", 700, "\253\034\346./iA\3661T32Zw\312\266.\357\034\032\202\213\332\320\356\356\327\275\217\251\326\356\042\377^\270\362\346W\367\353\237\331B[\021\034\310& Me]|\355\274\207\325\372=\373iR\177", 64 }, + { "G\334S\242\304\334Y<", 8, "\330x<\264\323\016\237-\300\231\260\364\210B\314bW\255/\235\014\277\3450", 700, ";U\042\252\241\200\357\247\366\020?gb\0358\231W\354\331\377MS\273 F\3361\313\377\344\361\004edjn\276\261[\0221\225\017\3731\203`\350a\301a\005\036wwQ\034m\323\226", 64 }, + { "T\236\334\030&\300sl", 8, "\006\377L|^\220T\213\307-f\214\024\215\251\366\224\240\250L\364\346=\224\001m\206D\335\375i\371.\261\3026\364\270\225\320", 700, "|i\376\031T\307y\012)\250\211\242c\200\244\370\232\212\206\316$-\031~\274\264\302IJ\243\356\367\232C\314c\013U\037\236\305\313\264\207\322}\273VHX\300\321\002Yi\237\261\345e\031\005{L|", 64 }, + { "A\313\345\257\373[@]", 8, ")\227\310\042\306\361\235\256\363y\337\341\265\3144\344\012\342\3540\260>\343\246\214id\013\254c:\203>\020\365\267x\243\013B7w4\235\267\015\330,", 700, "\0428\377Wc\042\366\266\227\254\030_w\263g\202\376\326\267\253\336\265\353\026\200t\017\354l\227\352\314[;\364\263\361\203\215\220\374.\272\042:.@m\033\250\274}\3646\000\330b^\363\364\327(A\015", 64 }, + { "\210\332a\312\367\024()", 8, "]\215\337\017p\215\251/\2747[\206\312\314Zk\267'\324\223c4\265Z%\315\210&\014\021&\262\270U\274@\374\221\0262\2720\3360?\274\214\330\302\373\240G\205RwQ", 700, "0\3646)\364\337\3250\333!\010\356\306D\241]wn\353\303\265:\374\315~6C%\250\346\234\231\367\330\367\220\221\324\255\221\375\344mc\271+R\324\374z\027\237H?k\343\211\022\014\375\134J\256\014", 64 }, + { "\305\354v] \232v\253", 8, "9\230\361c\001XS\355\303\361*\366\267z\363\226\237\331E\336\222#\305\037\326\005v\336\375_+=\277\212_\0269!A=\235\007h\254\370Z7K\346\277\246\360*\015Kb6\303\022\224\322\026M\313", 700, "\253\232\256))\226\212\353\237S+\307u<>$\3440\367\363v\222\250\321k:\323^\234P\351\236f\205?\003F\326\016\355\311\244\023\346\321\243|\256!\273\2243y\226P\026\323m\250\306\360Q\267p", 64 }, + { "\001\363\342\257~\177S\275", 8, "B\012\033\376\003<9&\264 \214\003\212\001j\004;/\321@\231r\267\024\302\270\344c\0306\262\215\205@\263_\360\033j\3177Z\220\042E#\206\231X_}j\012\340\365\325\336\376D[\273g\366O\377\300\265\373\256\203\2779", 700, "\013\331\003N\240.\215\336\022\230\317\271\042\376lv\311\036\305[f4\351\314\237f\323e2u2\272g\225\261b1\027\246>\251\235\261\326$\243\201\342\250CG\224MY\3737\225\312o\355TU\032\275", 64 }, + { "\017\327\331x\230\001\363\353", 8, ".\331\317\373;\330h_", 800, "\265udMk\214\004v\236Q\366c\336\020\010/\243\236\262\020\320\004\016\241\371\242\232i |)\240\305=\266\316\201\350UAY$J\243\230\267P\377\011\000o\033+\211\236\020r\356|\261\317\033\355u", 64 }, + { "\032\276\352\212\347\313\231;", 8, "\311\365\134;\311+\024N\037\134\0020\362\354\324x", 800, "\276\004-\013\036\334\372\350\311\270\306T3\014\230\351\015\230^@\330\342\304\324\034F\264e\367\013\273\355\251\260\271O4\257\020x\362*\354il)\363\201\017\232\032\344:\312\037\005\341\325\3720\326\366\002b", 64 }, + { "]]Yk\304T\222f", 8, "H\031\273\324T\210$\267\222\324\027\270_\2514\214\347\317o\177C\272\313\012", 800, "\325\007\134%\256\3015\242\203%;\261\350\324!\262\367\002H\177\355\247Mk\042m\373\263\306#\301\3472\354\344\353\031\346\246\017\202\342\306V\005D\266giX\205\012\016H3\231\344bn:;v\225,", 64 }, + { "\346\320\306\0348\265\356\000", 8, "\376S\210\356d\366\033O0\352\265\314ZV\263\3701p\023\262f\227\356\025\361\002EV\204\337\304\206", 800, "Z\2104\306`\244\211\342\010\204%\343\240\207VL\375_T\342\360\031\017\257_\207\345\327\014\347Fn?\331QY\310\375\334b\244\337\241\003\370\202\0356!\305\326z\330@\201\0241\244\332:v\371/\264", 64 }, + { "r\206Tl\304\226\231\356", 8, "g_B@\2277\267\027l\314\247W\306\346\221\226\223\201\013\263R\245A<\024\177\007\230\222|\216\331~\233{\350n\244\341\362", 800, "f8ma\263y|\237\2600q\021'\276I\3642\276\344\255\345\032\270\273\032\262\365\026\004\364j\211x:\330_\207\250\336\311\016g\376\261\366\307\345\223\204k\362\355\252l!\357X\211\003\035L`]\341", 64 }, + { "\016\320!\037;\311\210\213", 8, "\347\042\302\3575\315\031\013\267\340\377)\031DY\177`G\316D\251\025\327o\311\233We3\236\022L\017\354\314\342d\207\343\017\345\235\010H\210\225E\345", 800, "4V\003\007\215ht\377\262zSoW\277\3314\316L\376oAw\367\015\224\304\201\2176\277\375}9r\042\304hZU\374\306\202\205\354\2167M!(\371]\313\357]\233\005\345\256N\252]\177Q#", 64 }, + { "\347\274e\2157\327\016 ", 8, "\272xp\134\303\305\032\372\217\330\225\227\354\372?D\027\354\212\376\311\236\260?H\362\257\006\261\003\350|p\266\331R\363\036{\332\335t\021\327\213.\253\202Ss \335\252#*%", 800, "\1346\322\026\247m\011\012,\203\263\2449,\344\250\235\360|t>\225\277.Z\215\037\226)5\356\345JV\334\234\211\357c\024=\2534\257\026\225\005\023\221\330\275\010\246\011^\374\034A\246Pd\212\234\317", 64 }, + { "Z\207\036\243J\207\322D", 8, "\323\326\355\204\245}\341\034\322\331\364\234\240\241\260\2203,X\355\362\335O9^V\212\373;\214\342\334\020\316\234\214\324H\317wH_\313S\257\335\240e\007n\372\036](\317\024\331\231`\031\023\002\243\033", 800, "\224\343\262\023\213\042XE\317\300\260\327\316\217{{\322\307\234yqc\011BMd\312\373\375M\323]@X\3400\012\2175k\235_X\307a\134\023\376\035\323Z\312\011\376?\346\006C\356x \332\323\227", 64 }, + { "4\324\256]z\277\006\304", 8, "Os\324\324\223\211\353X\217\245\344\317\334w C\265\024\371e5\007\235\230\364CH*\036\243\251\222,|/\270+\31386ywY\202.ByB J\245p\237(\315\024l\362\240SC\352\261D\24176\026\024D\023u", 800, "\014\217}\334\346\012\202\320\323x\317\341\363\307y\261\134\355\0259|\237\224\200Q\002q#\232t\336\215\303\355\020\263\221\0257\205)\374-\316\271sj(\000\332h\303&\003\323%\3052x\035\230\3673\267", 64 }, + { "\2311\362\360(*\314c", 8, "\226\205\332a\235\200\177\002", 900, "\266N>\311\351\345\223>\327\365/\202\006\211\317\345\265z\001\276\340'\355\303QyH\367\311\042\032\350\331\012\034\261\327po\323\275E\317\000D\234\355\032\241\242\332]e\276Pk\264\000\211ia0q5", 64 }, + { "\020\277\212\360H>\226S", 8, "\333\342rh\323\302\366\223vK\376\004\340\213\316;", 900, "\344\254\354@\367\243\012\310\303\042\263\330\230\230\307\266-\011\134\024\221[\371\320\324\244\375^S\314u\303\335:", 8, "\035)\304;g\254m\313n\232Rn\276\022\264\317.\210WB\272\026M~", 900, "[i{\304\237n\213\314\375\2223w\134T\257\027\265\307\015\264\016\022\245~\250\031\257\342w\211Q\242{\012\370&\003P\016\311\032+\235,F\260\362\327&2wxw\030\277D#\365'c\216\303A\356", 64 }, + { "\324\210\245\303\375jc\134", 8, "\003\042\006\004.8\256\321\013\216'\227\210\353\226.\364\037\300\351e\206\357JY\201\254x\015\352\023\212", 900, "\2727$\177\202\237\0142`&\034\321\224P\3620\013\367pg\371h\315 \134\227\306\241\257\3333uS\025\206\030\2704n\013\354^\032\034\266]\024\254\000\256\356\2356\331nz\263\310Q\2178\201\310\320", 64 }, + { "\322;F\214L\230wH", 8, "\330%\316\307\264\310\375q;+\256*\315h\300\274\215yZ\320\360\203)\353|\310!\016u\260\350\222\323\177\303\226\212o\3255", 900, "m\267\007?\353\220\220$\231\316;f\201\253X\312\320\006{\307\014\334s\3257\277[^\0055\2567\134\270yr9A\342\273N\217i\374\314\364\301\312\335G\036\014R\341|w\323ei\226\014I\034C", 64 }, + { "\345\342>\335\2457/,", 8, "\355\262\340\201\134\012o\2011F\234^\321\211\216w\207\022[\361\310\004\236\256`x`j^\263v*\2250\336=*\340\017\317R|\00164\353<\244", 900, "\004\240\005\275jv\352M\360\350\036U\306l\237[\031C\224\205C0iT\370\242\011K\042\030\333\375\302^\255B\301\354\310\240*\323\257\310\222\240\354\233\221\346h\311;\214\321\240\341]\363\326\335\022\216\224", 64 }, + { ".\245\313\031\277\374\042l", 8, "-]\026q\347=q\004<\002@^\242\277\355\212\334\337M\304B\351\015:p\323!lA\357\204\206\364*N\317\363\016\016\230D6\227\337\347*t\243\177\021]Y|\240\035\006", 900, "p\006\336\010\351\337\304\260\372\210\267\013\231 t\265\231\274{%DScF\3726\320\205\275 \011h'\251B\363\323L\014V\260\362#z'\233\322H_\306t\273\027\353\272\021f0Q\222\244\0316\225", 64 }, + { "\014Y>\242\331\270\367G", 8, "\222\344 \364|\347CP.9\372Tu\341n\014\333\321\034\204k4y\312\314\363\323(\221\365\023\032\342Y!\010n\273\213ot\346\310h\304\220y./\235\342Pg\214\037\217\352\316\374\276\3740\256e", 900, "\211\042{m\201\233_\3020\350\237<\315\272\256\200\010\323)\210\210*\042\200~\266\343\177ic\212\300\363L\215\271\022\2609_\361eWbF8\203\271\363\214t\272\275X5\011\355<\2233[T]P", 64 }, + { "\334\023\304\233\305\200\206\272", 8, "\314\332|aD\003\341\033_\3733\374\263\042L&9\014g\336\253\355Ir`\004\014\377\306\2031\212nX)uG\236I\021\031\337\336u0m;\3126u\332\025Q\370u\303$2*YH\211\343Z\3628\237\274\2061sw", 900, "\005Zx\257\262D\357n\005b\014(\012\277O<\313\361M\331\373mB8\031\215\035/\247\005B\343\346\305\337o\024\275\357|Y\235@\221}\202M1\0325\306\325A\253\250\241JY\326\255\032\272\314c", 64 }, + { "Z\270\301ED\237U|", 8, "\0272-\237\010\275\377\042", 1000, "\360\355\220\212\252\371b9P\343K\301,\024$\227|\305\346\327$>\215R\243\214Vs\273W{\306\234x\347Jlb\211\355\321\310\015\002\267\352[\210\335Zl\341\023\236u{\225\264\027\370Wc\343&", 64 }, + { "\262\3435,q\037^\014", 8, "G\330\246\256\356\260\201)P|\336R\254\301\265m", 1000, "\314\320h\267\227\350\034\216p\334\250\372\230\300\273\220s\352K\341\347\253\317\321\362\042R\311fN\177S[\376b\354@R\320\010\251W\374\256]\243\262NO\000\206\347\005\306`\215u4/!\365\025T\026", 64 }, + { "\033\341\202Z\263\274s\025", 8, "\317\320\367\371\200\035\361Z\240oE~t\347\300\227\330V]g\337r\316@", 1000, "\234\313t+9d;3\226!\325\256\242\211`\323\030\352\336\377\306\215rZ\263#{\306\037{7\307\203\325M\032\031Q^\260[8$a\272\215\337?p\022A\335n%u\214\232\303^\352\241\251~\247", 64 }, + { "uc\214\232\3031l\300", 8, "\013(7Vl\341\013JA\276\222u\345\271\363\015\134\317\340R\214\335\312\245\264z\324\326\366L\344\250", 1000, "'\352\216\246\314\215\365\333%\334\202\342\334\352\347\211%\312\215(R\312k\246\330\207\223\004LhVFw\374\322\331\275\265\334k7\343\013\312\010_\264\362b[\254\366\226\224hvgG\307\200\347\216\033\036", 64 }, + { "cD\020\266.C`u", 8, "\247&^M\360@\266Y\365\322'\367\262l\376\250\042KU\360\237nOl\207\346\2520\203\0428\003\332o\344\0046`\226a", 1000, "\241u\001\027W\202YT\341\275\204.Y\242_U\016t\003\025\001\340\304\213\364L\264)\023\346\031(d\234\256\313\204\260\262x\220N\017\274\340\315\000\276q\017\001;x\375v\004\025\300\276U9\336\260\375", 64 }, + { "a\0162\201\011\221d\017", 8, "\256aW\215\327\374\235\334;\303\032\021\037wg\306K@\001d\213L\244>\343Z\234u\336\313\024b\344`\233\271\234\333\365\305Z\306\0218\310UK\306", 1000, "\304\023e\243|\032k\320ni\270\002\252\306\036tZ\015j\373\340\331\207\245\347\032\261L\354kh\012\356\363e7\015\334\352\206\036;\320~\331\260\330\003\257\310\244\364\244\370\305\233:J\363\367\324\362\025[", 64 }, + { "\324\304\265\306\270\217\276\015", 8, "\276\027jRk0X\215\227lG\236\240RpJ\220N\005\250b\345tQ\221h\321\354P\371\035\244$\256l\023HZ[\031\255- O\236\222:\267t\254d\313's\317\024", 1000, "\250\316\327\215\271\374\206\207\220\351D\263\306Q\362\366c|\273VQ\241\016\377\004n\314f\215\253\305\321\350\236.ZjX\037|!\314m\331\3775\011\034n_\263x\267\345\241\322j\230l^G\334\256L", 64 }, + { "\030\302&\234\200)\230\305", 8, "+L\221:5T\274h\237\256q\323\353m\333fh\201}Q\351*\351\240\267\276\327\007\254\316\214J\342\350\351\367\367\266\301\010\3775\015\014\351\337\3264\355K\027\355\327m\300\241@?#\232\225\263\037\007", 1000, "\201\355F\216\035\037@\350_\232\325Mx5\353\004*\372\250\370%X\247)\315\324\314\256\315\242}?\373L3\346a\331\302\134\334=\237n\275 \330_OZ]VW\007q\312\254\244\276\024\034K,C", 64 }, + { "?\362\015\253q\331|\250", 8, "}\020\020\337\215V\263\334p\346\003G\363\301A\333\134\177\222w\271\262\306>m\2774\343\006#P\260\306mS#Gs\250\363u\230\227\377\015\361\235\336\273V\230\316\214\276l\201\272\241}\361\260\357Aw\015\263\246/\366\026\375\037", 1000, "u'\305L\233\270\032\326\225\2422\323\347\335g\374\270\023\352E\305\332\240\231\244\035\343\226\322z\264\346\354M\036\211ye:A1\257K\236\215\333B#BV!\333\245\336|\217\317P\257>\257\265\252\003", 64 }, + { "(\134\324\014\245*\260?", 8, "\263nO\374\320BL\042", 2000, "\354`\262\357X\301\351\240\333\374\3536\307\367A\273gVR\366B\1775\217_]\214\016\2641j$kE\201g\270,\276$\213\205\250\237\005\211D$\351\241\334\222\337\326\360\372\277P\002k\224\235\2137", 64 }, + { "VC\260\247\227+K\325", 8, "\214y\202\334\330\323;\206\274k\026\333#X\247H", 2000, "\005\366 t\203\277\030z|\241z+\222\344\134C\306XV\367\042\032Y\2074j\211\034g~\013\263Z}\354d\342\246\005\011\250\230\244\222\336(\224\320\320\221\237lj\227\003\345c\311P\023t\000\243<", 64 }, + { "\226\264\332\250Q\332\033?", 8, "6\177z\010St\034J\240\224\003\367\252I\322/\034ZS\243\322\307\374\311", 2000, "\225\325\364`R\004\354\021\306\2123\337\341M\273\023xsu\030\210\267U\375\011\223{\002!3a\031\254\247\200\302\265\016\277\301\235\024\014Vj\363\022\367H\224\372\205\337\302G\035\351\257~\316\371\252D\342", 64 }, + { "\347\016\225\220\026\324\301Y", 8, "\351\314\237M\230\305o\321\374\374\253H\236(*=1\364\203\007\210\344\001\245\2736\022\340C\314\265\224", 2000, "kN3z\003R\340\020D\033\221{\234\352\211\201\315\356\017\234\370\270\214\035J\335KM\255\200I\010=:\3512\030\260(+\257\276\275\001\361\263j\030\002\224\352\372\031$q_\023\330\333\021\233\240\222x", 64 }, + { "\340r\267}u]\377\350", 8, "\242\360\243\361\363\020jX_g\376\016X\352dF\022;'+\306\213\375\036\224\214A\242L\022\334\025\231\015\267\305\001:\032\270", 2000, "\230D8\251\010\031,p\016\330\310\233\241O\031#\310[\324u\261\207\2042\361u\310;\366\342[9\201\005\037\20261\316\351;&\273\325\263\305\325@\251\027\343Ak\225\270\014K\342\037\015\305\247e\231", 64 }, + { "\013n\007\254\357\255\217\340", 8, "\334\015\217\312\237\315sW\026\357{W\321,\031\034\374\023\2720y\251\235q\030\2170\357\251\366\370\364\312E\205.w\273r\242`\246\005}>,\231\250", 2000, "w\210\363\2605\020\134\374\231\024\327\314\205\310\325\247\033%\322T\226\271@\302\004\266q\304\345\326\275\347\260\322\361\2435\344\010\356\300%g\307\217K\0423!`R,\005\327\201\0037U\266\2705\275\343r", 64 }, + { "\202\361W\024^\252\307\235", 8, "\356\247\020\315\037(p\361\006\223 \261\035\332b\222m\236\027\367n\020dw\323\247\3017:8\034\256\302\363\263|\273\134TF\260M_D\3418h\237\365\260\262\257\007\344\231\351", 2000, "\327G\376I\211\335s\3060\367\277\200\015\270\327\351\023\3539\245\203\356\244\367Y\244\340\277\207\235\360\027\347\352\343.\301\3570\347\330\324\352\353S\242>\324w\213\271\262\013\211\250\035\261a\011\271\370\034\3633", 64 }, + { "\207-J\204\243\334\335\016", 8, "\261\134\241\340\024\3441\306'\32061\256\202\267\232\370\2327\257\357\342R\202\326\345\300\362Cp\315!;\320\305\240\013Zm\234\343\217\373f)#\223\343s7\320R\342d\224\027\212,+\304\262k\243l", 2000, "\271\317r\177#\201M\306\320\314\317e\236\042k\031\032\242W\364\321\255\026YkJ\371zp`\337\264\212\253x\034Ef\2003\214-\370o\277\305\3671\355\013\320C\247d\214nA\273!C\375\025\2218", 64 }, + { "\300H\213\371\272>\337\241", 8, "\001qO\241\310Gs\274\036\375\272\362\033\014\256\327v^\037\321\246\277e\224\300\235\231U\367\316'\014\327\232\265Z\033*s\302\252}xo\374(a\231\355\301\0350\021\231\024F\177\276\341\221N\316\025f\320\324\134\247\376\335\274c", 2000, "\301\360\262PJf1\243rl\320\364\320\017\312@~\240\031\206\211\261\330\035?\314\356\253\263>\016\252wt\341\213\001!\014.N\264\350\377]\243\234\245\354\325Au\353\227\236;L\333\332k\340\343\352z", 64 }, + { "z\015\256n_HF\264", 8, "IO\305\325\253\232\001\022", 3000, "\021\032\252P\005v\354\234q:\204\326\203U\2162\246\371\343\340b\327+\037\330\360\241_\215\134H\214c\373Ix\364j>\036L\016\355i\226\034Q\370\320'\320'\014i\336A\210Z|D\200\006\006\202", 64 }, + { "\027\035\353\321\372\222%>", 8, "\375\3772\334\316\222?\333\300\325\265\005\360\361\347F", 3000, "\231\0011>Jk\031l\324q\271\2308\316\025B\362/JA\010\370\021\377C[3\016G\260/l~\042\350_8\252%\373Q\275-\263}>\356\330\337&\005\265L\353\377\021\324~\255\371\346\316R\204", 64 }, + { "'\331\374\255\355\315\206^", 8, "~Wx\355\211\365/\372@\022c3\337\311\233\253\007\215j\356\264\254\321\032", 3000, "}\344w\013/\000n\371<7", 3000, "f8\205}\321\371=\330\3410\034\030\354\323\033\270\333\227\320vUS\336\305\010\332`\306q8\351\027\034n\372\356\363$u\376@\017\244\3467Ft6H{\264\345\275k\302G \334\202\275\257\375\242r", 64 }, + { "\241\364\000\231\250^_\277", 8, "R4\332\217\332\374?\341\030\277\345\025~Q\364#l\307\273\331\357\0352\361\373\246\320M\220\250\265EP\225\221(\236\026\332\272", 3000, "\177\243\277\322\005\134\016\015E\251\300\205\250\352\366e_~\377\251+\223\011\021\326\042\033\277\267\206\037\224\231g\260\031_V\341.\300{\243-x\025Q>\177u8\223\177\032\201T3\360\033\336\201\255\234\024", 64 }, + { "\020\011\277\006(\215\353j", 8, "\215\341\262\207s/M\323\274\341\223\322q\215t\177\225\246\367?\326\245Y\330\026\221:\370`u1\305\377\261\215p\311[D\0229\200(\205\216\341\247\230", 3000, "\236\022O\372{|'\313\011\216[d\364\210\030\36249\2122\266\221\022xD\266\363\207'z\215t\2448\007Be{\272\244\207\251\352\365_\353t\333u\355\317\327\327\205\222\250\003\330\201B\023\004#5", 64 }, + { "C\251\361u\026\34102", 8, "5\343\200wqFK\2739\260#\224\301\256\323$\247\033\272\322\346_\227k\274\250Wzt\3062\134VI\202\234\325fv\013*m\003\355=R\366\214\233\305O\333|\200\376b", 3000, "\030\177WT\007\014.\134XcB\245\202\004\363\021\313E\344M\216\332<\330W\360N\314\134\341\255\030%\031\323\024\035\312O\370\213\017\263\034*\261\344\031\356\237\271Oi\213.\276\315\314\367\222\212\027\024W", 64 }, + { "\311\254\331ZS\226@L", 8, "\013\320= \345\032S\317t\255\2550\245\3062\232\316\241\002\235\333\015$Lx\376\026\334K\010\360=\237*;\007\134\3506O\352,\037\322\342\013", 3000, "\344\202\347\365^\026e&\200\260\214A\324\264\022\313\225\351\033\254\254o\357\255(\215^z\034\200\220\312K\301\240\227MO\030\231\366\020\031=\203\012\224=\024\004>\316W2:\363D\365\231hy\366\365j", 64 }, + { "\134#\216 D[\241\223", 8, "\017P\274\200^(R\220\266g;\211Z\265\036\345\337\360\2310y\031\330\206rF\253\254\375\271dr\321\367iT\304\2003fV\367\333\264\247\2370S:\377&\216\360yfs\202h>\327\347C\261\345\274\357q\037\331^\305\134", 3000, "\177\373nj\013\324\202\021\035]!)\370\370%\005\353\016~W\330\265\217\362\337\301Z\275\321V\000g71\335\377v\013R\335K\315\241\225\216qE\312\272@.\020\315b\247l\3359:\242\265\000)\310", 64 }, + { "\304\326\303\344\272\260A?", 8, "`f\262P\027'\211\217", 4000, "\012^\363\365\134\265*$\014\270]F\274|\375>p\341\003dT\242\337u{\314\205\307\260\360\322\025\214\007E\307y\365\352\310\240\372\134Fji\370\241\017\305\336\262\351\332\002{\026\270\376\363\266\134\274;", 64 }, + { "1\2004\011\006-\032R", 8, "\353\371\330A\261\263)\213u\007\233-\354\230!\202", 4000, "{o\014.\322\016\323\244\021\037&W4*\362\300)mGv\014\016\306\307\237/6G[\267\033\213u\313\266J'\276GtN!\000\216\363^7Y\037\370\021\014\333\250\374\332\274\235l\230\263\220\347\222", 64 }, + { "\354n\227\202\363\306j8", 8, "T\334\212\366\246\020\042\264\342r\271\317a\0047\322\317\354O\031\202\342\370o", 4000, "\312~\260\260\027\266G\247\236\312`n\335\342\262Ec\247\272x\001\003\252y=\002\362\362\004\326\350\007\0252!\263\312\360H\344\246\016\207vEO\022\205\212\306\276\251O\325;Gz\307O\266}\020\322\376", 64 }, + { "\360\263\275l\234\244zO", 8, "\335\375\273\001\261%\233,\007\350\255\247\342\235\310-\032\035\314\246\252\027+a\233f\204\274M5W\262", 4000, "\317\365.\214hyP\313\205\356(4Y\251\224W\367\263\361\027\262\324\277\255M\010z\263\314?0\025\003\367\332\236.\004\331\302\232\011R\332D8;]Dz`v\000\246\242a\247b\033M\031\270\011?", 64 }, + { "v\327\346&\035C\320\322", 8, "\260 ^\376\355\375\2567_\272\252\255Wb\376v\0057M\226\346\031\272a#Up\264#\015\311\342+\2128`(\224\224V", 4000, "`s7\365\307p\250\356x\310^7\320f\2442mm\242\0207\023\360\300\264\336\252.\266\244\202\134\042\311\023F\374\206\225'\371|\327R\371\277\357\307\304\250\352E\016\253\010N@-/9\257'\0235", 64 }, + { "\252\317\025\232\012l\372\275", 8, "\216\020\363\015\245F\277y5\254}\016'\272\204Rf\226\340\341E\230L\024\352\205\312\306\340\042\241\017\263\375\337\355\013\020KJ\273\342\3572^\313\312U", 4000, "\222\010Cw\275\317./j@\012\032LH^\222s\205\240\335\011\026\310\275i\246\264\347\305\302\365\302\336\221}R\016]\231\006#G\321\222\255\215E\262\272\013\202\260%~\027\350U\031\220(U\210\221\314", 64 }, + { "\035dQ9@Z\267$", 8, "\204]\013SSO\332\324\322\327\216\362D\203\253\241/\262\21093\374Z\213\001t\376>\207\024e\273\371.\037|\036\334p\005}\353\277'/\346\014#NP\362\2504w6/", 4000, "\252BW%6\265\317\000\271\024C\010C\202nYZ\027\006@\334\321\365g\371z\017\3469J\374\262\366\242G\200\017\363\313\223=\251s\213`\343\362\007\000~_CV\336\207\240\352F*\313#x\212P", 64 }, + { "\344\263\246\321\357 \003\347", 8, "aT\363\245-\012\023\032\333\253\3049D\372\033\332I\370\005o\267\177\340\226\211&\356T(\210\017\355\372\003\207\277F\012\010\221\213\274s\314\200xLST\260\375\217\013\331wG\240\343\344\347\347\301\324\302", 4000, "\324\336\003\003\337\337\215\354\327z\217\0319E\000\020\353\011\366\347\001\035x\3660D\332\014\276\374\2363\3635\026\227\031f0G#=\015\213\275\210\237\032\207\342s\002\263\2438h'\301)M\351\213\200\274", 64 }, + { "fJ\325L\311M\364\333", 8, "\2640\311\202\3471\2310\011\271\345\002\265\225\257>\220\277\205\311f_I3\247|l\351\222\341\353j\240|2G\035(\353\203\250\031Jl]\317\226\223\343\205]Z\324\356\245,\264v\030\333~t\035\220*f\027k\207\364Yr", 4000, "42\335%\022\372\310&W\2374\335bp\217\247m#\210\006\207\021\371\134N\306\335a]S\274\350y\247oZ\024\272j%\326\213;\324\273\347w\300E]\347%'Z\261\206w\2350(\265\205\301\302", 64 }, + { "\363\237$\002\006\023\357\001", 8, "f\327\370v\0061\026\200", 5000, "\331\303\025\301\344\370\222\004z\275\364\374h\253Y9i\027md\032\020<\042\017\250\261\317%#ne\303Z\324!\354\300\006\235\374[Y\341\036`\373a0\357\357\015\246\3464\352*'\241\272-\317\325M", 64 }, + { "\332|{6Q\346v\313", 8, "\134!gL\026\024\376\2430~\306\2743\232c\206", 5000, "3\325\201\34598\202\330\263Y\005\244\321}}w+\245:\274\177\255\365\265\000e7\375\312gc\261'OG\266hPp\365\250\364\042\333\373\323|\205m\005\2572\021\027\271]\233\360\216-;\210\371\274", 64 }, + { "\333\220G-\240N\205\232\303\177 \012\324\374rl\034", 5000, "U\342\2200*K\262\010\177\273\024\2455|\367\336\2311\225\366/\005b\305\345{\233\301k\030\023?e\250Cf\007\134\036:\377\213\027)\353%\323R\322:b\255Rqr\007!\020r6\305a)F", 64 }, + { "\234\004/\345\032\000v\220", 8, "ar\031\272\305\245\232*\007\247\025HL\274\010\336E+\311\336\2557\266\300\263%\3031\337F\227<", 5000, "\320\254\3477Do\003\227NL\334\355\217)\317\302\221\344\300\320\356\204\266\350\305\223\275\273&r\327\014\261\352\324@\356\032\325\221\330C\346\202\233\013\007\304\031#h\202\244L\207\236p\351\371\335\213O\341^", 64 }, + { "k\317u\332\217\324\322\216", 8, "\177Te\253\271\260\255\276\353o\223D\324\001s\317L\033V\242\247,\2566\233\206\313\315\014\332b\317\312\134\322\216\314d\344\344", 5000, "\316\021\033\027\375R\207\327\021\341\340\253Y\230\016\257\355\024\027B\226\322\346\025\017\2429.\336\2262\352\324\375\225\356\367\353\235\012X\011\361$Q,s\240\033\372\254p\202>\343\034^\303<\211\242\273AA", 64 }, + { "`\226\222T\332\377\223\015", 8, "\351\350a \311\352J/ \015\270I~3\360\2378\265kP\302\371q\202\3006\000", 64 }, + { "\303\327\253eb|\362\227", 8, "\30630\364^\006>\227\224\315o\217]aL\236*\256DZ\270<^N.\326\014y!!Ng\375\325P-v\220\341\206\315'>\314X\315\364\276\014L\324\212\374\354e\230", 5000, "\267\272\262\235\213^\042E\255\330\372\010&\012p\354nBG\344\246\266#t\300\237a\271)\275\010x\356b\274a7^\327\303S9s\343\203\236!=\332n06\241\312\254s\335\265\334\356\324\367\177\375", 64 }, + { "Z\3378}!\257\020\301", 8, "\301.\2642Q\250\277$\271\334M\307\250jz\364\354\361+K\322\275\343\242\322\021Z\2747\333\213\241\224\011\0320j\267\011\337O\023~{7/y\350\012_\202\331\216L\206\003\006\026iQ^\310\036\360", 5000, "\216\202S\222}\336pr\331?\232X\323M!\202<\372\263%\353\264\334\035\370_\323\363\217\322\014\301\177", 8, "\344\303W\177\317\032+u\032B\353\375\317,\225r", 6000, "\212\205\266\373(\344\246\213'\247\262\257\030vZ\355L)\242\375\353p\227\3250h\022Xg\356\310\350=\353\247=/k%\021\364\030\223\013\272-\177\277iX\005?\000\200\325\310\245\0137\247\365\034\234\007", 64 }, + { "\235z\200\0425D\206\326", 8, "ZC\014\243\032t3g\336&\0058\016`U\317\210K$\205\236\264\274\224", 6000, "\233__\371\276\213\263L\005\211\250jO\042\364m,B\020S9\014\332\263~`R\334\236\020\224d\374\037\201\311\327\262:l\221\315&\277\351A\251\262\000\012\200R\203\360\011\371.\373\323b\000\316\277\275", 64 }, + { "\013\216\203\231;\177\030\022", 8, ";\250\2605\215\314[\2478\314\343\342gM\352\211\020:\336\3271E\260\042\3444\274\305\234:\226\221", 6000, "k\255\012\344\344\350\306;fm\253<\277T\017\020?\234\215\216A\373\303\3375l\325\333\027P\301\006\214\221\202\375\342\240\213\012\307g3`\377@*F\3518\000?\010\002\021\005\023\227+E\177\363\022\236", 64 }, + { "\211\354\257\301\023\201\377\374", 8, "t\235\202\224\274\013\350\134Cnm77\352w\200B>\250\213\211l\275\357\234/\004\342\311\216)\260a\016B\216o\253&\317", 6000, "\304\225\214\273\016\374\375V\215\207G\264?/\273*\276\257\343\012\234/\025&/\017\331\211\355\016\351+\301bS\004x\017\326\252\032&\205\030\222\347\272\002\036\231\261\033\200\276\330\367\007\252\376\005#\217~\212", 64 }, + { "{\355d\364\020MGs", 8, "\324\301)\225SI\220\322\320\333\263[\375\2154\006X\303\014\275x\300a\313O:E]\011\236\134\203\344\220wj\231\320\300\015\222\321\324\177\341\320\237\372", 6000, "]\005'\026\210\036\250\037{}hs7\254d\327\243$Ch\000.\011E|\213_\347\3579d\342\321E\212\334\251~\231\221o9\006\323\317\013L9L\312\206\357\372\007Hv\234Q\311'+\001\276\034", 64 }, + { "DR\0073?q\272\374", 8, "\250l\002\017#4\320=p\032\202\257s\207\352\347I\373\244z\377jD\227\214IG\364\206\004\322\261-\217\305\301\214.\314\206\373p\341 TSu\323\377L\373Bu{\032\247\370\270Q\260\307PZ\337\203\304\235\004\254\354\322\363\260\001\004", 64 }, + { "PB\323`z9_2", 8, "\373\317\015\021\275\311\335\315\323\231\212}\307j\336::\201\343Y\210\042P+M\263Gh\031d1\034jz&\134\366\363\012\374\274\212\244\315j|\207\331 \345\312\027x\026\261f\016\311\035Mt\370x\243\323\3550A\014R\033h", 6000, "\134L\334\310\334X\035\356S\015v\243\242|\002\037\305\022\375\372qK]\020\300\226\001\334\310P\357\376s\203\225 \037\305\373o\261\020\303\264\370\256\262\337\237\251\273>:E\335e\260\316\246U`c}\016", 64 }, + { "\027\223!\256N\260<\200", 8, "\020\374\203\034\005b\230\201", 7000, "\302I|/\305\025\001\003\233\244@\332R<&1\333\030B<\010\3315\267\213\317\231U\225\303\336S\217\037\337\212C\202\022p\270\207o\205D\177!}j\221\215\027)\306~s\004h\323\342\336Z\252\377", 64 }, + { "\201\016\210\273m\345&W", 8, "\253\363\011\215\2646\222:gr\001:h{\012Y", 7000, "\244*>\204\042@\302A*b\010\024j\270\220P!\2114\327\031\237\304\231Lb\303\336J\325\321K\263d0\200\327\005l\320\344\336\353\323\012y}N\251!h\275\363\376\320\225\341f\246RE\310\2418", 64 }, + { "\276\257\256+\244\247\211\226", 8, "?\235\347\030\024\362ng\234\254\017@\033\321\331TO_\255\277!\042\233t", 7000, "\216I\365\206\200\134\002\353\213I$\327$U\275\240(\351\352\2738{\313H\202\275F/\322\013h(8\263\205\326\303\042\2621\032\204M\264hT\221\205\310\263\214\273\262\313\221\267\206m|)G\324\241\025", 64 }, + { "\2020\274j\042\224\231\221", 8, "\334\260p\216\333[3\014\301-\223\026&\315G|\231\207\205{\310\336@H\246\3257M\020\031\362-", 7000, "x\213\321\215\223\332\313\016\323\012\310\330?o\300\277\177j\312\220\255H\247&\366\232BX\232\352\362N0\225=\373\010\260\027'\271v\376\220\324\263\225~\354\035\277r\222f\221\260R\253\215m\203|$\334", 64 }, + { "\372+1\367\246\333\271w", 8, "`\220^\277$Y\341q?\315!\014J\221\210\242\232ySd'\354\361z\306\301\016\252\274\342\267sso_TZ\200fe", 7000, "d\224\227\252\306\204\012g\201\237\314i~\216\214QV(1C\271\320\233K\341\351\313\005\342\343>\361\341\377\030\204b7N\340\356\274Ma\023\212\314\222\240\211\033\013\211-\356\264\267\027\262\005\313\270[\204", 64 }, + { "e/\227\361\021\350\237E", 8, "-NQ\342\360?\267#\011s\303\241\227\353\232\227\010f\003f\012;[\022\217iu\317\024g,caX\370.\214\321\273\035|\337EB\014\2636\235", 7000, "\247_\330\233!\237~,D\351\274\202\265Z\026G\224a}\277q1\250?\023!\276\011j\254e\233\255\374\246b\024\275ss\200\031\036\312\322\257i\357\367\371\022\324\213W\014\246<}_\003G\317\204\247", 64 }, + { "\230\373\305\254hVc5", 8, "\362\306\303B\214\210\020QR\316\205\356\241\373>W\307q\237\261\227\355\251R\334\332j\303\231\202Y\356~\213C$l\353f\017\031US\334\324\016\034D:\374\345\252\235D\303\214", 7000, "\331[#\367\002\331}\306\266\3258\246n\226\357M\204u\226\320\306\323n\015$\320\247\305;\265~\2478\025V\364\222\366s\240f\270\314\034\250\277\347d\275\351\326\310]\213\244d\264v\303\317\371p\235\263", 64 }, + { "j\332\311\021\016q~\273", 8, "G\026\002J\024d]\255~\231\271\322d\335T1\203\371(\350\331b\013\302n\244\004pi\231\210\205\332\327oE\205\345\011\300\216df>F@\323\020\240I)\026\335\362\345ndx\321b|a\304U", 7000, "\371?q\263\265\2344%\200;\333\251G\020E\316\333\331RD`\275\260\006\261\356\332b\027Tv\251\243\001S(p\361\313\011(g\327^\241\0030\376\365\3425\376\363\307\216\234\316\216\377b{\310\347\003", 64 }, + { "oS\366\311V \247u", 8, "\217\350\316\355\003>f\334\306W\026\213\307? \304a\245\370\333\364[\236\0256\267\320g\360xn{\037\015\356H\271\010\255\360\265\3136\025\266\342\324\246\204\211\311k\244\322\342\231\307\204o\2376\361cy3w\314\347/\246@\022", 7000, "\211\314\257hDW;\257\3702\271\243\322\314\3131\352\250e\313\006\364/\001\207\327J\350\214\350\232U\353\216\024\344\177(\325\366K\031Rt\220\201L\265\263{\366\305\305\215]\373x\177\373\020K\224\346\350", 64 }, + { "\2713\267\214\012\302\311g", 8, "bo\2109\255\305P\036", 8000, "\236bG>\215\363\021\012\242\265P8\373\332\017,\367o\217}\210\320\035\320\255\316}1\005\021m'\205\214B\236y\232\377\300\262&\240pJRXQ9\226\011\212\316\346E3\302\252!l\266\304\134\017", 64 }, + { "l\364\370\012\341\025\344z", 8, "\201\004\012\261\355\255N]*\324i\346\002z\300O", 8000, "\024\220\237\352h\017\263\237Vk7\015\250\007\000\253\203\305\255\220\337|\306\233\240\023\361\226d\304\315g!GGY\363g\331\005\376\354\243\371\207Q\212\246Ez\030|\341\315;h?Pe\351\256\004\364\373", 64 }, + { "\302\241:W\337\336\036\342", 8, "\273\233\362\231\357\212^\310 $n\370\314\324a\225\235\004L|\322\015\357\256", 8000, "\357\333\324\221\253\207\002\244\006\352S#\326\352Y\201\034\307\301e\22120\252\036\333\2151\010\134*~\235T\322\007\200\020x\221phGw4p\221d\251\262\355\013=\236I_Vm\241\003CN\245]", 64 }, + { "\250\275\025\013\365\363\227\210", 8, "\030\02582\351Z8\344\017\0252\203\305sTM6\322\336\214\037\303\223!H\306\276R3\235\323D", 8000, "\337/\303\204\376H\020/\366\036\3336O\234\237b\012Q,=9z*4VZ<\320\214\270\341\277\262gjEu,I\224\242\316c\217h\042\211\005\300+\033&\336\024\254&\227&\301\324\004\362\377r", 64 }, + { "\366\345\301\371\301\220\3759", 8, "\315\012\003\227M\042[2[ \036\264dB\022a\326\372\203%\223\005\330&\007\304\012\300n\347\233\012\263o\330)\177DC\323", 8000, "\023\006\222\026\010\342gH\220\370\372\277Z\327/?\240P\244\244-\326\333e\234g8p\323\263OG2K_\272S=\276\012\011\314\217G\027{\215\246\360 \024\224\244\352\363\003\307\371o\305\212\341\3706", 64 }, + { "\272\010\025[\365PR<", 8, "\270\205:\014\2338\264k\246~\025\245z3\345\001?\005Nk\006\202\357\220:|\251\2522\276Z\243\232<~8\341i\326IQq\265\355\013$c\241", 8000, "\031\240\307X\344 m0\221(p%\247>\215B\244\325\211#\036\355\215\356\231\247\263=B\232G\264E\260\222\214`\006v\315L\011\355\025F\235\352\347\365Pm\230\211\273\255N\0023\021\202\362\370\004\340", 64 }, + { "\031\322*2\357\375S\022", 8, "\366\252\324S\223=\016\205>\011\374\2703\234\226\316\004\327\231\1774K\236\030T\232_\315AS'\374H\326\226E\037\225\263.s\004g\332\360\372\0147\200\364Z\003\262\225GJ", 8000, "Y$ \014\261L\304\307\264F\212M\362\364\272\375f5\223\016\275&3z|\227\021]mvP-\024\225!+\361\371\250\335\375\377\310\035\017=\233\347\225\235\042\335\241\300\264\260E*\327\034\220E\204\325", 64 }, + { "\031\220H$e\221aZ", 8, "\366\331\016o\241W!J\177\212U\230\316F\042\345xO@\324\314cQfu\315\261\312j\252\005{\001\035\362/`i|\361\237\367GmJ\303\356\035\366sV<\031\346\2736\266t\302\024x\001\360t", 8000, "IB\042P\213'\260\225\275a\244\255\225\361\346a%\321tT\251t?gbp\344@x\016\002A\025\242\264\177\224\256'~;\256\216\277\301Nc\302a\216\325\220~\213\240\245\252\260E2\371\216w\134", 64 }, + { "\004\341juF>\010\303", 8, "\012\374\210H\310\034\235\215\205\261\207r\3443\224\300\027\275\304\271\366\021\300\034\024b\256\337\0164\007w\335\243$T\300m\010O\202]%\306h\205\311\260B\206c\236\011\233m\305\305V\042\020\274\001[zM", 8000, "e\327,[\030\205\3270?\251o\320\177\305\134\272`\256\332~\363\017\200(\035s=\343\300\244A\231\243\267\247\032\353\325\275\256k\221\364\230\301\301\2658\260D\035\244\207>\211\354\035\220\202$:\012\345\177", 64 }, + { "\244\276\254\240~1|k", 8, "\251>\326\357\223\360I\224", 9000, "\202\327C\273\265\315pa&\261\02517B\232V\007\200q\302i\240\265\250\302FH\230\002]\357\216\204\245\351\221\223\335\250[\0274\265\307\214\362\347_\213\003]\244\360\344\014\011\003t\226\031\016\354\034L", 64 }, + { "v\015\177M_\312\0052", 8, "\366;\234/9\024b`\042Np7\3674\335\254", 9000, "\363{J[\233\031\001=k\307d\011w?\300 `\320\005\253\303\373\134\004Q\212\334\344} \355v\221\370\315a\314\205\236\343\363H=\357/\026\2531\024\316ZC\200D\345\212\3025\011\333!`:q", 64 }, + { "\272\021\314kDz,\250", 8, "\1774.\331\031\134\003wT\204\366\216@\2057N\223\237m<\341\307Z\307", 9000, "\323`\024\332+\270\220\374#eZ\314\217\274\015\275\234>X\342\363\240l\202\321\3030\245n44\267\007\377\042\334\225\323>t\310\316\301\333\213\215\205N\330\274+\214\323(\342\012\336\255\233\233T\220\345\352", 64 }, + { "\346G\354\015KEg9", 8, "\320i\372\224\255\204t\310p\216(.\260j\241\215\217\245\350o\362=\024d\323\350\364\212\010\300\351\265", 9000, "\237\006\200\214I\354\024/O\134\026\322\201i\203\031vjkO\024\234\311\351M\020\202\350\016vO\331}^\333\223\247\006\366\251\260\3661()\027\322\361\350v\310F\005n\337\277'\361\327\220\330\031\374\037", 64 }, + { "\350V\321\365\262\311q\250", 8, "\343m\037\250\273\367\033\260\306+\343\236\021\337\216;&\366\361\237\301\244\224\035\017m\033\241T\206\011\006\030\220\240\222(\226=%", 9000, "\215,\364\267-?M\243\134l\345\312s\270\224lu\363@\337\360Gz\357 =0\374\320\027E~\206t\347\031\222\371\211H\333\242\210p\371H\023E\262u\004\042@\250\341.\316IYA%\364\010o", 64 }, + { "\134\012\274\273\331\3564\247", 8, "o\2669\261\335\134\307M'\373{\361\367\325\253\331\243qy\316^\031\315\223>\024\007\177\375L\216\001\272Y\235\246\340\341$rG\352<\203s\255%#", 9000, "-\017\003\263@\273\011\274\3138Fx\036\312\320/3y\26458\035V\222\376\004\312\330]\263\317*\265q\324\340a%\016\214\241\255v\033U4j\006\002n\346\014\326\011\211\201\237I4\330\034\0002\335", 64 }, + { "\276Z\205\372\215/E^", 8, "\260X\264\010\316\224\021_\014\005\246\0046\005I\377j\356N\365\013\253}\007\250BlGu\224\027\37541\352\316\3704\305\024\343%\037\342\265\236YA\200\005j\352\203\254\315\237", 9000, "\266t\3301\355\364\233_\353*\333\220Z\007\360\343t\343&\260\036\334\201\254\335R\373&b\237\027\221\343]U\304\212+\0367\307\375w\250\227\233\042U\227\215\324\017`_\254\3125.E\002D\321\200;", 64 }, + { "\226\005\201\252\315+\266a", 8, "\377\315Y\201\220\361\037\222\262r \237\226*r\005\236\225\036\323\313(n\257b\011\330\357H:# \321\271\344\202,\231Q\016\013\034\222\003\364\205|m\335\232\0172V\355\275*vH\262\177\205\307\210D", 9000, "\234GS\240:\220\213\346l\004u\204\234\243\351I\370\260\375\010\201\035\223_E\354\271v\036\250\266h\227[\243=\337\315?\220\3253\300\366\346\024[\307w\325\313y&l\027\010-", 9000, "\307\367\342\016j\337\217Jr\210\226)\242A\315v6U\313S\042\025`\335\346\002\240'U\312\342\210]=|DZU\253\237\320\235\264\311p\200\221EP\311z*\207\267\305J\273P\033Utu\254\300", 64 }, + { "\347H\205\004\340w\177\321\313\337\042G\204\274\033\334", 16, "h}o\344Iv:b", 100, "\037 \023\347\332\024\007\042\036e\253\276\016\270RM\224\223w\012i\223\305\2474]_=\257\303.\331\025EqB}\214\204s\253sD\037\317b\034\000\376e\012\340V\220\224\00532+\024f\206\032a", 64 }, + { "S>\007\330\027\271yp\211\357\017\246\200q\302\376", 16, "\266\042\300\276\377Z\362X\241\271\005\257\355l\232\235", 100, "\320\302\134\002$F\034\315\343\211\010\256\264\222\021\363\177\003T\030\225\027\333\376\213\256\357\202\324\272\350\201\3161\233\277\327\04293 \332>?\327A\377\361\265b\274\202\246\3123\236\366\001g\211u\223\354\354", 64 }, + { "B\031~Q\003^\310\367\210K\014\256\245\202\316j", 16, "\015-L\002\032\352\005\215\322f\024\344\3559\360\273\222\336\347\221\356_c\320", 100, "\177\207_s#\007\301m\206\013\2300!\365\000\2125o\261\376\343\365x\220\313\356\264p\304\013\033\306\354\246}\304\004Z\311l]\002b\362yd\013\234c\007\340\262Bh\001\013\314\364\021l=T\344~", 64 }, + { "\245\360\247\005\370r{\215\303#0\353\344>\002d", 16, "_k\016jF9i\254\253\026,\251e\003\315\3136\016\023\213\337/\331q\343\356n_\355\242\200\231", 100, "\303\207[\317\226\277\341}\225.\324<\006jL\035\372\247\245\332j\334V\015\266\012\366\273\213;\213\275\021\020\341\271\325W\277\303oy\260\215\021U1\333\205D-`-[<\335E$V\253\014\213mg\267\355k\262\211(7(\016\003\036\231$\257", 64 }, + { "\3746\000\2150\247\037#\313\331\351l\012\333\247A", 16, "\234y\004\241[\363vH\207.\227X3\234\366G", 200, "\314z=\265I\243\201;\010\234\015.\042\377\265`\220\223M \006\234\276\035\036\2571\322\237+~C\241qv\223\006\223I\034\225qT'Q\232q7\3102\336\371\271\237~F(~\350\317W\236D\000", 64 }, + { "\305\363\361\241\301\257\317\177\3327\134\252\316f \307", 16, "\324)\212\012\226\034\330\315\313\323n\361&s(,\205\322\034\211a\236\335\375", 200, "&\3403J!17\345\026 \211\235C\025R\212\177\374\273\343\027\3772\026}\232\347\016\362U\352\025|-\373V\300Q\221\003\317,\037x\334Dq\230j\277\206(iW\037.\336vJ\230W=\013\376", 64 }, + { "\342\015\026\337\254d\021\237\010\216O\314\271\015\202>", 16, "\272\010\351vz\243\205y\234\345\354\262[\353^z\346G\324\177@\217\357\252z\254\354\240\241Yb0", 200, "_\235S\033v\365x\3567c\255\216L\267\200\307\204\006\365\271\276>H#\260\015\335\025d\000\230H4\255\365\264\370& \204[\345w\035ne\301\254\312\246$\213\345\362\261\256s;,\321\304\371o\333", 64 }, + { "P\220Zg>x\313,\234\260\240\262\260\351\177{", 16, "\3762s\2309\276B\215}-\215&\363Z\374\305\233\325\203\254\367\212\250\266H\222\002\256\362~m\374mr\354\305\317\330\215\214", 200, "B\2700\007hU\301p|\227\275\342e\005%\374\023D\242x\311l\0344\211\256k(\264%\011\362\266:a\305\330\252\320\303\365uh6\240\0033\271\236c\220M:}\365|\210\010\305g\000\364\027\347", 64 }, + { "\032\222\254\003\000n\311\010x\225ny~\226p\016", 16, "\303\3346\310>\2656\271\251L\272\243\007\315\221OZ\300\212q\335\367\246t\234`\213\214\347\332U\340\352\275\265\134\354\203\333( ?\256\304\035D\012?", 200, "t\301\031U\330\0141Jw\010\027\212\334q,\306\307\313\354\177L^h\376&\033\310-\231\220\273=\277?n\201>~\0263\216\012M\341\224\037\034\244\036:\325\017\2024\230\342\006i=$\3546*\243", 64 }, + { "z\012!\011\346\202\316+8\217e\255\023>\350\221", 16, "\177\015\264RK\134=\005j\210\255\202\373z\327\304\377\027\267g\254\3139\333\354\215\273\177\0112\237\327\343D\205>\213\231j#\235\355\363,\237\315t\021\335Q\300t.\346v\210", 200, "\233c\377\253\202\010\203\256\372\357<\200\231\334\3074\207\371\232\243\206\023\212zj\272\273\216\217\210f\200`\031\202Z\337/\2467?\177\226\321\215\300\216\260\222t\320i\361\012oT\017\302\340\353=\302\240z", 64 }, + { "8\346\2320\027\300\302e_\224V5\347!\037<", 16, "\247b\235u\341\201tX7\372$\260M\312R\344\275\241i\233\255\253\030\206\256u!\334\201\275\202\042\036_\237\335=\031,\015\230\372\303\224\312\334\220V\035\323\226\340;\177\250v\375{k\344\331\255\214$", 200, "\216\323\264\300\362\373?\027\346\000\323\275\267q\001\222 y\303D\366{@f\034\226O\234\341\216\230/\226\324\034{\001\264\042\326\357\015\360\037\362\2602\306\277.s\244\001t\346V\333\016\3111\015r0\316\005b\330s\204\317uxc", 64 }, + { "`\204\233i\237g%EA\265\241\220\240\311\271\277", 16, "\007{\3171vCb\215", 300, "\231\365\3613x\302\240\021\024\331\3726O\333\340E\304 OVy^\0121\360\353\237\210PM\261P\011\325\311\307{ -\307\016\204R\300+\003\324M\312h\003\304+\251\214\005\205&\002\252\022\240\3702", 64 }, + { "t\271\276\220\376\026\002Q\320(\350\3108\032\234\227", 16, "\275'o.\375\363f\266\245\373IN`\331\016]", 300, "\234\203\367\265\303\221\335\243F\363!\225\007..\177v\266\321oe\227\013_/3\032\330\225d3\233*\252\042A\323gR\303}A\374\300A\353s*~\205LdO\305\002[\201\204\033>\244\207\330\030", 64 }, + { "\200|\315\327\367T6\016E/+~\016\267\042\366", 16, "hR\302J\352\242*>\306R\202R\354\214^\317\216\270\277\014\316\322P*", 300, "\215.\042\007PDE\315\3073\355\007^\2619\323ET\250\004\334|\364lQ8\020/f|\206\344Q\010p')\013\220\277\231\362\272\00462\344r\211%i\273U\012y\346\322<\005s\204\017\200\274", 64 }, + { "\302\354a`\2242\277\372\213\134P\021lU\200u", 16, "\320\311\272#\313\335\306\264\251J\255lR}\002\273G\3006\371\205h\235Ah-X\001\312\3341\027", 300, "\022\220u_\275S\011\301u+\222\351\307~q\226\007\233d\231\276\026e\251x\3123(\243B\227\021\215\277\031\315\226\315Y<\360\213$h\203\017\266\335\024\247cSC\350<\340\303\343\237\241*\200}\265", 64 }, + { "/\342EJ\341\2354E\202N)\376\311\231S\231", 16, "\266\012\010\366\027c\3434\364\272\373\260 \263\207\262\344\237\350\271Y\245+\011 \341\344\277", 16, "\326&\352]\243\333[\211\035t!\366\204\204.\351\005\036:\260F<\210?\343m\226\035_\134\255@\016\260\017\347\033\256\377\361Cd,\343@\007\264e\177L\275f\216\346rP", 400, "\300\042\035WU\336\316\023i\201\215\215KSU\215aH=\010\332C\207\276\207\254}\373\331\325\312\013)%<)WM\330r+ \014\214\217\012c\266\023\364\330\356t\264\042(\031\312\271\312\351\3356J", 64 }, + { "\260\354\027\023%\230\372\345'\315\035rq\356<\327", 16, "\300#\263\231\336\337J9\346\354\007\273\351\244z\013\247C\342\337\042cF\221\022\221\203z\200\244\323H\015\366p\364*1\2271\134\326\377>\002{\260:\242\224\323\035\211\002\277\347\246\227\237\223\315\315\361=", 400, "/\015\317\021n>l.\252\256A\340'/\327vM\233\262C*\241\361\036\353\203sjK\003\007\331\361][\204\3643\237$\234\353\205_\206\226\337\275\375\025\255\314\263\250\311\244.\362P\336w8_\344", 64 }, + { "\366\317\345\225\251\365g\205\211\324*\313\001E\314R", 16, "{-\027(\230\231a\371\302\271rc\302\204\32402\204\312\005f\227\336R@f+%\250\372%\023\340\002!\203\037\237!\1346\012\355\345\246\020\346\263\204\204\222\356\221\2334=\3333\364)bs\242\314w\001g\214\212\020Gq", 400, "\212K\270\302:\017\317\343\266*H-\373\241\321\200\021\204y\276\272\252\347#\333V\025sI&\325@\337\015t\312JR\312\222\243le-\204\354WAi\364d\353\364+\023\376\363\210}\261\236\242\262\222", 64 }, + { "'\225\026", 500, "\341\213,\254\202dg\312T3&z\363\354#\350\301\204b\302\357\253~\315a\342\235Z\206J\002\341\042\004\342h+\274Z\305\350.8^\377C\241c'\231+UI\216`a\002\203>>H\276q\330", 64 }, + { "\355\2508\036\235/\211\331\356\0223S\2121`\224", 16, "Zk\3217\020B\320\302u\222N\357UBC\364\221M<\344\210Rq\254\327[v\266\347\251Y\022\367E\376m\303\332\134\270\020\332\333\026\224\204\367\254\362U\011 \324\276m\330 \032\222^W\2304\345F\005fw\364\277\322VXJ\345\0167KM\213\022fv'~\032k", 64 }, + { "\134\244y5\2355\245\326E\016:R\206\032\334\202", 16, "\233\364\201H8\215y\376\014\277\016\334\013\337Jm", 600, "8\337\036\337\322h\016\272\377\261\302jZ\271\312!F\372\364\327>XPTg\232\226F\021\362\024%~\371@\314\226;\026\244\2356\312\134\134\236K\217\243\341\0052J\304\014\354n\205\321\365\256\214t\337", 64 }, + { "Q\361\217DR\030\023l0f\316\321\317\370\000\270", 16, "\210\323\252\322\0060{\223\006\022On0fm\202\011\315\357a\031\373*\317", 600, "\300\241\266\226\264\202\202\216m\0166|\321<:^\367\256B\327\211\036d\030\002i\207\311\322RSC\252\303G*xD\203\213\003\343\252=D\261b6\033?\351\257Y\251\261)\254j6I\203e<\333", 64 }, + { "W\240\211i \373\342$O\315\042y\243\371o\203", 16, "m\225\254MJ\265\037\231)\021\336\371\254\253\256\317.\204\210N\300\226\320w\354\021G>\014\256\310\034", 600, "\373\356\000o\004\330\262\234\262\250\346f\212ap\337e\220,\007f\333\202\270\253_ms\351\013\373\234\251j\204\360\033\257e\344\360\200A\324S\320\251\235)\015\013m\202\206$eE\370\243\001\014\221\300\275", 64 }, + { "\305\337\271 *\214\274\272\356\013\307u\215/<'", 16, "\323>\273\2563S\220)\265\367\346\246\002l),\025\177\027f\332\223\014\004\260}A%R0 #Z\357h\340e\261\025>", 600, "\333\224\212N\256t\331\335\002\315\266\324W\214\017\016\273\250\303\021\326\340\016fC\015&\305\213\266Pi\261\344D\325A\367z\251\326n\321\305\2120L\324v\006\262r\320\211[\023\253\301\330\376\017\245w\000", 64 }, + { "\227\317\337v\243\316\223\362\003=\022\307\243\250o\216", 16, "\247\270\205\312\252b\325\344\227\372q6\3660\004\035i&r\212 \253\177\211\365\034\207`\213\310&\005\307zo\332\363\344R`\217\267\270l<\275\321\317", 600, "\312\021O\242AA,?\251\335\207\244\357\274\2753\020\006\321\240\362\262\304\253\210\370\231>\323v}\335C\000r\362|f\273\246\225\314\354\244\272\260\330o\221e\233\005ea'7\336\232\232:\221S\031\334r`\316\2015\257\377\203:j\221\264d@\342", 64 }, + { "\255\377\250\342\216\0156\217\331\352\220r\302\236\376w", 16, "\377I\023\011\206\313\214=\006\344\0217\037\034\312Q\013\303;#v\275,\276b\036\023\375r\332\302G\335\307\333B\325\374\347\271", 700, "0\2629)\037Z\226\272\312\021\215\345\266_\036\373\277\012\023\364\271%\271\272\366\353\205\322\243\220\1342<\233\372\311M\232\027,\215<\334Z\357N6F\207O#\031n\215\235<\256\333\304k\223\323\240]", 64 }, + { "\243<+\014\304\027\016\025\023\373@\377rt@\336", 16, "\316\023W\361\200\325\241\255_\347\247V\0324U\031.\377u1F=\234\206\365\342\256\210\243\346\217\317m\3334\267\242\263|.\015H9\212\313\360\331,", 700, "B\322\302\014Tt\014A\243K\347\353K\031\364_)\340Q\356\216\006\367\275\355\246\035\362k)\322$\242jn\3077\255@\036d#\266\267\274\267\343ti\211\376\032\200x\313[\306\267\247n\222\222\347\021", 64 }, + { "\371)r\237\3421+4\356s\277\234\343\330\212\313", 16, "\262\017\333\260\372\305\253\325SWj\350\233\231\222\372s\277\032\272[p;5\204T\014\243\017A\345\314\217\210\323&9\222!y\247U\3673'\351\266W\216N\215\265\0331\331\373", 700, "r\016\300\215\261\246E\350\234\360\035\340\025\033\206C`\206b.\326\223\367sV\320\232\006\374\227\234N\027\222\376\273\264\356\206\340\317\337>\237\266r\207\206\224zp\343\335b\333\237k\240\306\204I9qF", 64 }, + { "\351\236t\270\232A\203a}#a\340\217\314\235\246", 16, "\345a\00716#31\263\314\220\255\005<\306\277\3574;\025\004\341\323\215\023\210l\373|\226\234\251O\242\2334\311\336g\260\033<\261\236\237\271\357\230\035\273\016c\212\200\3406\361g\022\263\030\311E\277", 700, "\300\270 \346\234{<\357^\225\303\255u\351\042\254\267A6\032?\023\251\226\320\361AToOc\201\220\335\241\276\363.\277\227G\042i\300x^`\230\253\247S\205\231\2700\370]\304\343y-\134\262\274", 64 }, + { "\326\315\030\330\327m\324g`\357\314\374,m\313\027", 16, "\222\231=\273\242\212\226\031\325\251e5\213\256\244i\036\370\247\361\2530\377\372E\244\265\367\346\251\312\300<\304\221\035\201\277\342\304\015@", 64 }, + { "o}J\242\212Q\201\317\222\006\331dI:\362T", 16, "\227\363\374\030\2151\324W\373\366>QP\367\032\315", 900, "\374\010\253\244u\317\244|\366\2348h\341\373\322\350\234,{x>V\036\006\266m\042\374\335,\351Vl\376\341\026\000\233\302\021\013u\274\246\363#F\321\234\226A[J\323\253\371\201\344\306\312\222\300\232!", 64 }, + { "fW`\315\042.\323\234/\024e/\235.\367{", 16, "\377\001Rk\017\237\367\371WR4q\271\242\200\034\374\224\224\026\371\3056\305", 900, "\314e3\234\224\216\231\334\257\005\354\223\241\322\363t\134 T\343l\246q\237[\300n.\014F\207I6 Hp21\271l\244b\023\352\214\356\331+\331\006'\321\215\301}\223!\3318Mp7\005\330", 64 }, + { "\365\016\371I\230s\357\307\245\037\373\023N\2579\236", 16, "+\214\007\212\252%\034\006\337Z\013\267\134l\211\030\302\271\267\376W\014!\370 \354\272k\013 \265\035", 900, "\026\345\251\321>\361;\226\251\251\277\3261$\233\224tk\373\011h\030\256N\030\314e\352M\2200\273\341\351\350\302\257\03796Lc\3615\215\033J\326q\347\364T\0232B<\015\202\251b\021\352\271\224", 64 }, + { "\357\305\300\016h4\217\213\205|\365\275\2402M\212", 16, "\232{\261\235\227\366}\037?xZ\217{\271\352\3539\3628\370T\207\370\222\334\221PJ6\237`\235\343\020n\323\370}+\025", 900, "\006An\011@\267Z\023\026aW\274\002\263\316S\006\374\372\362%\003\357C\355\307\202\023\266YN\245\361\324:\311\201/Pa\342e4\2122\203\255\312T\201\243l\357\337}\361\302\347\034}\315l\007\301", 64 }, + { "\254\373N\035\251\017\360\304\005\333`\256\301\240\351\020", 16, "\257\231q%\353\262\257\37167\260\364e\222*\0135\242\214-\263;\011\232e\237\221\202\026\352\334\034=\326\346\246\016\353\375hH\020\2666;\276\254\254", 900, "{1\200C\304@\350\255\323d\266\042|\2019\262\264\177/T\362\020\346V=\032\360\226WC\234\260u\244X/6\326\202\363\025[\327Y1\240\243\030\373m$Yp8\220\272v\321]\361\343\305?\226", 64 }, + { "\200\323\244\005\342\327}\330\0329D\266v\037\332\234", 16, "\305sYC\035z\357\246\025\315'\376\305Do\345\022\320\016L\321\236rW)\0128>;\042\215\2640\244\370\245\271\312\220\222\211j\247\323\252\324\252\316G\014\307\303\220\026>\241", 900, ":\015\356\340\031MC[\210\244\201QVg/u5\331\215\134Q\277J\322E\306\222\372\346X0\210N^\207'\300I\345\011\020\366R\014\177\213\037\3425&\252>\264H\316\335\235W\264\265\256\3774\002", 64 }, + { "\033t\350)6\260R\333\031\346'3\021x\014)", 16, "\317\036\207|'\372vD9\324\306m\004B96\3643\007/\337\212\015\042\015\317\022\375\3434\3669\266\243\234+\336\261\234!@P\204\377\220d\236\370\254\370vx\312\134\017\204\3509\225+\034\351\024\267aH}p\364fW\006+;=", 900, "\023\234\016G\310\260[R\353\236BW\207\317\016H\245'\203'\3209L\0148\230(x\027\337\025\256\355&O\2170\024\177\312\200\005\320\365Z\353c\365\207\333\134\264?\321j\0170\312\263\366\350\2733\030", 64 }, + { "}\026\215\320q$\364\307\271\035\234s\210bw\265", 16, "\260d\255\307\300\313\321\370", 1000, "ko~\027fI:q\276\226\305\216\270\317\010\340)d\020\353l\010\274H\013-\306\331\014\277\252\254}\007~\371\327{\352\216\255\211<\366\221\201\311\001\340\267JV\227+\347\253.\222\200U\317F_\276", 64 }, + { "\302\316l\266\270\312\0316W\200lJD\344\263\264", 16, "\353L\235\037:<\341\377\357z\035R\322\221b\010", 1000, "\357\261'\225|\274\201H\253\332.\240:\2151\3776\250\032Sa\351\3659\223\366\240H\200\2439\007\223\240\300k?,\004\203$\200\220M\236\202\314\032\321/\231;\210\312\013\214=U\0129\246\247\347\324", 64 }, + { "\351%\241\263p\261\200\362S\377%\206e\350\237p", 16, "\347x\025h\232\331\240\015\006\035\273\353\233\001@\004\177>\254We\361\353\215", 1000, "\302\000\266c\330\375\3350W\022\272\3446\345EY+\311~\244\0162\006=\353N\212\343\257/-B\271\270\343!\030Q\210\242F\307r\276342\261F[\342\337\277\321\217\360v\015\215\301\005\367\232C", 64 }, + { "\224U\367\245\357\276\004zv\004\017`\350\315\220^", 16, "\230G\361u\016\305\221\367\253\334\344Dg&x0\314\301/j\042\211~\320\207\207y\217r\237p\354", 1000, "{8\226FL\023\270\334N,\247>\033\032B\032\354k\010\001\373\222;t\023X\304\371\276\244\203\316Vw\352\214\310yI\010x\025\215\250}\301\027\205 .\042P`\306Xrx\322\257\235\340J;\277", 64 }, + { "\225t\353\356\367\376\013\326RX\246\016\134D\243\336", 16, "D\006}S\362\262u\220p\364\313\365&{\346n\277\322Jv\2202xdk\230g\327\341C1\220\374\322>;C\263\254W", 1000, "\026.X\262\251\361\032\206=\326\251\214\2721.!5n:\266-\267\015\213\216\313\335vP\013\305\034*\301\177\226\010\345\030\322\213C\313\233\251n\245p*\207tO\021\022\221\020)\006\212\237\014\223\020\256", 64 }, + { ")\035\350\023\325\370\321\370\243\005\263dm\3147\252", 16, "\015m$\343M\220\3573\304\200,C\032m\237}\256\366=A@\200\223\177z|~\263a\321\320\344=z\0229\244\200\222\253\013\224\021\265\224\023Hf", 1000, "x\351\246kB\345\355\201\134K M\003\321V\307\024\257\246\251\031\224>\244\021e]\014\262\272\004\206>\251\270D\372\226\206\352\225\273\010\036!\364_\327\244\001\353\012\250\232\227W(\034\231p\301\031\203\325", 64 }, + { "\246\337^`\273\277pp\204\370\235\023\256\026&Z", 16, "\327 h\205i7+eN\362\265T\320\321\237\214s\036,\326\021\357:7S\302\212\253\016e+\251\253\334z]\022\256]c\007\310`\223\364\022\206\245\217O\036\251\366\214\242\370", 1000, "\346\364s\202y\026\347\275\220gk\304\232\326\234\025\257Rg\254\233\216\344a\306\225\366N\216?\276\367\032pn\364-\322\331\367y\002*\276\322x\340Q\016\354:\341\216\320b\216w:\267_\227>\274\235", 64 }, + { ";\355],\232J\026\265\200\333\220Di\271\362\325", 16, "\217p\015\025\3636\334\234\011:\304\3378\203T\247\207\350qA\370\365\307\021\230\250\312:\214l\311~\274\220\303\225S\250\230\343hc\261\374\343gI\374JO\013\325N\271\255A\264\032\215\013>>\262\021", 1000, "Tm\271\346\333\031\034\261o\233\342G\006\277\264\2759\015$\351\352\331\214\200BL\375\356\322\376\340\337)f\356%\346Tm@\277F\027\012\315>\327\276\001\302\2576\313\244\315\276H3\346A\266\226\312T", 64 }, + { "1\317C\247\340O\362+\332\245\006\261\2069\252\342", 16, "l\31548\373\321n\375\007\337\320\277WV\334\205Q\230:\021\010*g?\3702\004\005\306\305\324\025\256 \203\351^\276\347H\306\345=k\310\247G}\326\020\347\363\350\016\215{\023\374\357\335\2669\315\353\336\250\224\303W\370\246\221", 1000, "E66r;h\253\215\200\205\375d\261\331\275\264\330\3146o\011W\210\217NI\343w\256;\226\351\351\000h\346\340wi\221\275\302C}l{\336\272\030\177\273o[6zV3j6\007)L\244T\025\256\353\2726\023\241\3501\221Qz\342\001S*^\327x", 64 }, + { "^u\024=)!f\324L\251Z\200\377#\134\362", 16, "\224v\363\204\345\353\263&e\242g\310\227\323\231\370\320\350u(3>\346\013?\3316\360n\316\2560\032\264n\003\177\352b\360", 2000, "u64\012\241KEM\001(>Z\237\042\027\240\361|\252\216\357\214\017-\302\002\365\224\355\277\351\033\011\030\324\363\034\320q\340&F4uCc\235{\347\013l\2671zB\025\236\3174\215k\361IJ", 64 }, + { "\256\002\200\356\321\334\300\0423Y\021fv\323iD", 16, "\224\307\134\316\002\320\273^[g\332G\320U\0139\004\022\220\010\372\200'iw\376\236\012\034\304\017\035\334a%/\322\277\3206o\262*8\014<\004\202", 2000, "4\274\031mr\012\340\305s\042/\217\205y3\374`\224\223\311\377\222\301\202\214\351\337\010\015\315m\213\263\334g\314oT\372\330\246(\333\306X\321\376X2\206\026\230\333\361\325z=\277n98\334\377@", 64 }, + { "\250\346\251\243\207\200\303\011\307\231z\220\332\004\367\021", 16, "F\251%7\247?A\003\200\015@A\260\042\247\310\356\004/`#\222\244\201\317\375>\134B\023\024\007\032\251z\330\371\3456\006Be\207\343\354CR<\261O\352\362J\361\377\367", 2000, "\276\207\365,\306\033P\0200\231\2013c\351-\301\032\207\212#\301\3233D\374b\027\206\357\335\341\321\205TO<\316\225\011\271\013Ca\235\315>\214\325\222R$\003a\224\005v\253\226\243s$\375\345\240", 64 }, + { "\222\324\307\304'\000\210\255 [),\322\357l\332", 16, "\007\345\242+\012\357t\231\202\266\324\250iv\277\257n\315\354r\025\004\356\233\317n\256\042\202\372\251\223\230\226c\203=\334\331\230\237\034\2129\215\365\317\006\250\010\361\335\226\261\367u[zT63|\365!", 2000, "\371\270dr\215\025\035\212\004\012q>\263\267*L\201\373g<\333+\215@\334\260E\253,\302\261>\222\201)Y\006\316,{?\303H\240\253\326\362b\134\374\177\013c\351\237h\025\2350\313\3422\313\272", 64 }, + { "\325\351\200@r/\240=\323\331\372\023\244H\013\236", 16, "\326\307\360\340u/\260\312d\314E\240r\134\025h\272\202\230\177\364\346\134-L\345\362\260Y$\207\027fv\257(\336a\307\215\341!X{\024\0317\345\257\240\263q\332\032Y\230k\026\254\037-t\031\244'\353\324\344\3014pD", 2000, "sf\252}\216![5`hs\210\324T5H\346\037v\314\344\346\330c\240\373\021\023-s\350\356kj\224M~i\206\325\246\325b\347\335\252\303+\277n\003\307lgw\217\245\025R\205\301\257gb", 64 }, + { "\244 \262P\000\300\360\311\042\251hn\226\023A\270", 16, "R{\337\244\226\014\276w", 3000, "b\254\205l3\271@=Y`\251\226<\316\334\013$\321\357[\357\324P\201\246!\355W;\362{\367h\2072\270\247\353 \271\357\233_\330C\322\231\341\251\315\010xm\270\350\260\352\304\035\304\204K$m", 64 }, + { "\015}\205\262\251\331\300M\312\216\024H;\313O\030", 16, "@\225\032!\031\231W`\325%\332\334+\345L\257", 3000, "S\042\245F\263\330\001\203\365\020Q(Q\032O\302\236\311jA[Yq$\000\210\266\026BIFj\255\263\362L\357^\304I\266\222\223\001~\321N2\202\206\301Ml?.R\321\215h\327*\347\317\324", 64 }, + { "\270\257g\226\273\231t\256;\025\270\267mL\177y", 16, "\224\2678\3320\274\306\365\254a\260\307\276\377\012Y\231\372-\3652\026\225\026", 3000, "5\3706\342[/{PT\265sHl\345\275\215\273W\300\354\341\342 \334\011\013T\003l\225Q\333\277B\240s\211\231s\360\353\301A4yj&`\024\005_\307\216\325E3\235R\032>\213\034[4", 64 }, + { "\312\207\223Gfp\250\306\342\002|\233\1349U\004", 16, "4\321\374\364\375ycx\020g\345\224\352\0424\313\011c*p\267\376\232_\370|\240\010.\3227\033", 3000, "\341.\134\262?0\256n\334\263\356\273\3141m*\352\344\237\302\300\364>\347Kq,mu<\327\010\267.lg\002\232\226\350\354\010\263\215+\032\014\230\262\375R\264\032\204\334\351/\314q\361w\246D\274", 64 }, + { "\2645\264\241X\321\351\352\342\015\253\257\241\354xn", 16, "\214Ihf0\343\371\323=X6\244\327\237l%\340\300\021\006\271Q\340\002\267\331\234\0100\231#j\005\342[\367\012\042J\237", 3000, "A?@\303a\325\243\015\200\206\256\025m\2471\254|\252\203j$Y(\013'\346\336\011\217\355I\346m.\001\337\033V\022\342\2177\216\264\211\000\253\330\007\315\323s\365o\371\330t\361\235:\0231\266#", 64 }, + { "\250b\326\230\271\352\346\357\305\245\303:\3236\036\300", 16, "Fe\247\220E?\206\201p\303G\006\357\027\204xD\264\237\247t\042\357N\335\351\351B6\177Q\301\307\334\012H>\2572\275.'tu#\014\371\260", 3000, "\3270\222r\024-Gf*\352\204\271\305\315l\234\370\364\313\304\250N\267\321i_=5\370R-\302Oi\251\305\236\244\376\005\033\270\265\031\007\242\234\301\02166q\243\042\035\326j\224w\035\232J#m", 64 }, + { "\226 \316\360\363n\302\012\207I\3022\252\232\271\221", 16, "\213\316\027t\212l\242\354\014\304\376\344\377\352o\207\330\376\037?t/\214\316\017\027\363Y\010\017\027N\326\007\003\263\274\042\177\230z\264x\340\017\204\005\203\200}w8R\304|g", 3000, "x\330\300Nq\0371t=\326=O'i\0176\314k\351\301\335\134\372s\200\331\010\322\226e3N\016\341\251\3670QT\322\200\346\217\300\202w\010\253\242\342\272\024&|i\307\270[H\357\306Vu\004", 64 }, + { "ng,\206\357\313\353!`\263a\237\375\256\224s", 16, "\334\370\260\331\016\0355\342]/\207\227K\2323\256\003\004\314\256\020\020Wc\241\367!s\366\223\025\254\245\227`\335\226-<\375\367\010_p\2151*\204\2501\263\242r\324y\231>Ej\324\374\265\247+", 3000, "\233\241\316\316\335\307~\260\336\332\273\337\263yqH^\202\037\265\375\032\353\364\277\241\241\2456\325\3558\364\360ft\316\031F\350\300\026\026\264;\345{Ru\002~\027\340U\316\313\231\205\205p\3167\256*", 64 }, + { "]\340\304\315\250W\316\336J\263\231\002\216\251\364\242", 16, "\201\376\003\177\021\346\237\211\320\262\334k\320Hu\220r\357\237%\222\357\013\350\330\042{\210t\227\376\372\016\3707\340\230f\200\360\300u\312\034\220\376]ct\225\311\275\005z1\243l\373-\234\2154\317zZ\0306\312\2435\032C", 3000, "V\373\262\256p\232H\0424\034\215\015\273)\217\366\237\253\323R\226\256A\257\334\355\035\376\331=\251.T)OVJd0\005q#\356\346\012\223,\017\015S\227\007\034\010\026\370\271\233\267\030\010\357*\244", 64 }, + { "\021\225f`U!\334\331P\355\312\351-\032E)", 16, "+d'\210\235<\262\204", 4000, "'\276\227\331e\015\206\231\234\323\2578\306/\0338\007U8\354}%\310\265\335%O%\255\377\376Lo\303\350n0\353Zi\355\277\315l\010\252\366'G\272\263f\341\310N2V\346\334\257\214\333\002G", 64 }, + { "^\314\361\023\376q\261\003\245N\240\353\031\300\031I", 16, "\355^\377\321#:\253X@7\201\251\215\257&\310", 4000, "\266=p\000\366\231n\365r\310\011\266\315\357\242\011\333\237o\030k\364\341T\042E\332\313\255\227\246\251.^\372\012\317\222\355\244\2066\034\336\000\250\277x\000\315\002\373\263]\037b\350S\036\303\341X\002\335", 64 }, + { "\300&m\242\343a\326$\210e\200x\012\335\036Z", 16, "SG\363E\013\273\017VO\360a#J\220,\263\375\322\202\227\242;Pr", 4000, "\242\351.\17783>g\001<\034\004\030\002\312\345\270\021k\342\375\243/\342-\346\240\017\260bj\342e\206\225\134\367x\330\020/\363v\214\241\025\205lg\347$\275\300\315\205\021u-1\246SH\205$", 64 }, + { "\235QV\311\015\001\301Sd\204*\270o\026\177A", 16, "w\020\211E\315W\014\015\342\344j\251X\341\2528\354\371\336\214\260B\367)\264r\345r~\221k\255", 4000, "\3260\375\203\347\030\375\023\351t]\015=\301\267\303\035\204\2345cJ\2565\243\266G\211\333\024\311\320\2556\031\302\310\257\273{\340\274A\011\305\206\272\232\264\336\217\012)\375\036~q]\241\267\220[\203\330", 64 }, + { "\303g\3655f\271\332\250\306${\317S'\270U", 16, "\300RV\321<\333\2779\031\216\346/\305Dv\021\333a\374\344\303\355\370\0367\201\315\346]\242\375)\323=e\023\013\201\306 ", 4000, "@\253ur\230\326\344l!\004\026\352D\222,\021l\0316S\205-,\035\374#E\023q\034\312\0003?\234\000bs\334\011\011\204w\2558\356v\343\255y\260\023\320\305T\314\300K\232\000\013\352\305:", 64 }, + { "\366\307\305\200i\370k\246sc\035zh#`\035", 16, "\341@\032\010\373\0114'\275\204P\256\314\324>\030\266\343 \034jB\372\0124\255^\234\207\274\322\227\357\244VJ\273wq\326\224\373x\360\327k\3508", 4000, "\323u\002\267\022\271\274t\002\305B\017\015\366y`\256\201{w\017\240/\225p\356\036yj\277\277\242\243)$\244\333\272j\367\024\223>\021o\370Aq\343nV\237\031\234\350z\226\201\300\024\256\006Gh", 64 }, + { "\365\236\311\322\134\327\033F\230F\370_\217\221H\315", 16, "\214\207u\217\253\234Y\236\377\343qB\374\035\231b\267\266\314\226V\207T\367\352V\001jY<\337~q\203\345\265\230zB\2110\346U0\231\205\246\254\013\213\011\134\236\351YO", 4000, "\315\360d\246\273\364\265\217\210\306dnuA\004\347\022w\200\375\267\341\336\340\226jlc\354\205\310\316\251G\373\347\237Cee]O\351\237UN\236`\305\244W6al;#\336\377n\335(\337qO", 64 }, + { "\341\325\003\214aV\254\361\365\314\333y}\005\036p", 16, "\274\271\3200UV\327\273\263H\022\362@\322\300\362)SMQ\335'6}\017\255\332e\341=\377v}\024\012\316\233\324xJ\367\011\016\260[\260N\322\257\011\005h\273\237L\010C\263\3300\321C\365H", 4000, "\336=?\327\210\002\245G\275:Q\371\271\233\300\273v\274@\002\363\340A\305\372\272%\355\365\343\012\000a\204\276\243$|\237\223\221\240*\351\311\262\327\367U\000\316$G\224q\036\033\327\224\247\371rzY", 64 }, + { "E\352\312,\222$\365\267\303\016\331\276\345f\305\134", 16, "\01152\236\032\242H}L\263\334qk-9\013\006\356\357\251\372\026Tb\304\256\226#Ad\216\3024\333\264\240S\217:S\257\024\347\030\321\026\223\024f\301\261]\301\002\272\350\023M<\254\255A\270]Yh\251g\2235\206*", 4000, "\352\317\323\300\357w\365m\200D*\277\024\330\246H\207\347\257\211^\240\362\005\001D\237\310\332@T\243pB\247\025\236\204V\377\346u\242\203q\324\307\320\314\207\372\376\222\206m\134\037\365[\307,\240\377c", 64 }, + { "ho\014\234\352\310\134-\224\021\301\134\015d\356\351", 16, "'\256\217k~\376y\335", 5000, "_\341\264f\012\003\275\012It\363\322\301\032\342\337\331j$'\006\014!3\3029\313\200n\266\003\254@\236[\011\214XK\372\020\210\335\031\134\303\011\042-\004\365\003sn5\235NK\375\013`\022\336\025", 64 }, + { "4\020\304\323y$t\014\202P\251H\371\235|\035", 16, "\303\370Y \366f\325\317\352\030^\245\234\366\010u", 5000, "#W\033\270\241m\245%\357\270\243\340\211\271\263y*\341-\002\277I\332\227\042\271x\321\344\246\030x\252\233\326-s\302\334\327G:(!\315\220c\346\240\375\012@F8@\205\271Vx\321\202\024!}", 64 }, + { "\034.{\0068\255D\335\340\303m\273\356\223x\204", 16, "\247z\325\244A\337\245'5\373\351\336X\330\003\2576\243H\020s\226\266p", 5000, "\353\206?\351#+\346\206\330\225;ua\020\263\312p\024\2229\213h\015\336q\254\216P\256 \004}\001\355\230\214emU\323E\371g--\237\303\022'\016\033\355\274\267\271\351T\0327\300\306\253\031v", 64 }, + { "\015\363\324\364\323\220\323f\177rR&v\375\027U", 16, "C\020\362\262F\351H\240l\271\245_G\134\034mC}\277\354\017\377_Ab,l\322_6[v", 5000, "\370\357\015*{\001\221\310\244\235\134\214k\335\310%\274\226\3203o6\223\361\243\356\200\000\340\240\330~\225\266\004\224\254\211\276\270\202^\251P4\237\350^\036\3671MV\317\214\227\022\211\344\022\321\001\257}", 64 }, + { "\312\272\240\233x{\372:;\253\370\330\334#\267A", 16, "\323&\213|\016\3346>\224\345\032;R\233\0056\316:\037\315V?\221!h\0308\231\333\207\221k\035\222\252\014I\2215K", 5000, "\004\012\245\017y\316\355)\320\007\331\236c\324+\3771\247\257|\336C\332\331\317\037\007KG\321\334\235\237\265\301\360\315Im\212\260\012d\033DIb\042\260\025\304\311I6\2158\3527n[\032\347x\371", 64 }, + { "\215R\005M\032\350\240=\023x\0165\246\231$.", 16, "\021\272d\364Y\217\317\346\026\0161\327\214\001\357\335D\030\364OE\264\266\012\270\350c\276\340\327\254(\2638\361O\253\254!Lb\021\014S\234Z8Y", 5000, "_\3748\356H\220\264;\253\233\323\376\2548\235\004\357)\002\277#Gz\253\363j\026\015^\335\024#\211\002\354\207\373E\364\2513\344(f`\214\227\3319\031SIh\260\234\202\301\375\204\315 \002\347\376", 64 }, + { "\245\313\007\234\303h\224\215\356\243\352O\206,e\266", 16, "\031\033p\375\350W\006\004\213\313]3\214\257v\333\0357\016\375\364\021\344\305\323,;_\330E\224\351&N\244\026\275J\354\024\340\310'/(\012V\217\253P\361\236\273PMl", 5000, "v\276{&\342:\355Rm1\362\320E\344J?\015\023\323l\315\331\252\031\245\206\231\014\303\340\022\231\241\332qe\036\226qF\213\254\037^\220\042\324L\204\011q\277\233T\303\350o\217k[\327x2\346", 64 }, + { "\273E~\201\327n\340\231\001G\001\367l\206\021\030", 16, "<0=\371\010\317Aa\375\340\261\234F\275\251\236\024\310d\003\265^\345|\372-\223\305\235\272\344\350\271\3669-Q\264\312S\323 \236\343\352x\304)\341\334\355>j\024\251\377\252-\356\241.QW\256", 5000, "\307\241^1\271\302UOY$\250\372pd\343l\031\205\353\272s\004\311\002R\276\006\232I?\327\020\237[\363\012\2656-\361Z\177\025\210V\204ZF\351w|\206RqU\042T\205+\222Op\235\376", 64 }, + { "[\034\223\310a\210w\351\020J\351\263\240z\034\261", 16, "<\217A\265\347 \264\242\024\324:\011\370b\263\345R\012'\271.\005\350d\027\314\017\034\361W\316Tj\225n\1778Y\356'\012ie\307\342cF\266?M\300. \271\247`\042\344\272\371\013\273s\316\357X\207\304\357\013\322\315", 5000, "\241\224\024\317\303\227\241\317\332\351\301\3567j\326\320w)\275\223\234m\241{B\356\274P\274,\012|\235\367.E\345c ^Z\321\031\352I\042\005\365\264\360\245\357K;\306\202h\350\206fV1\000\325", 64 }, + { "5\265\376M\262\3518<\353of\232AA \374", 16, "WSKsW#\354W", 6000, "o\027\243%Q.\3759\331k\011R\363\367jK\234\357o\363\317\220|'\245\233l\250\001N\203\322\002Q\026\027H\267\253v.\351\242\220\257e=}\010/v!9\346\352\3749\2014q-\340N\376", 64 }, + { "\350\203\337\210]\367\213\335\270\213\232\026\221|,\370", 16, "\346\327\263\312\213\345\005\011'~\221\027\355\241J\231", 6000, "*\022\205kO\256\322\231(\361\367\342\277\266\220\000nj\330xh\340\215O\356d\210\225\303\2373\340\2130;\005\254S\3115R\257g\344\233\023\347\205\237\274M\307\367\327\364-W\246W\203\275\373\237\272", 64 }, + { "m\326\335]k)2U\200G\347\000\311\010\311\302", 16, "\340\250^(]nb\003\212\354b\177\344\011y\300P\016cl/0\016\213", 6000, "\273\333\252\306\015\232\306\321\251_]Y\006\042\345\350r\222\010\372\026\205Mg\373\347\267\014\234\032\016d\210i@n*aP\316s\366\206\200\004\015\017\034\325g\334OS\177\214\374\230\211eP\213rNp", 64 }, + { "f\323\354%,\247\330/\027\373\267@~\345\352\256", 16, "=\354\324\017\336\012\214\370\014Pd\217\317f\364\301a\207\032+\227\2247\201\317\215\333\020\276B&0", 6000, "\245+\223Y\302\363Wl\312\0344J\245)\347\217\027l\027\321\0121\341\365/\263\374t\330\262\210\220\250\354\240q\020^\033M\274\261\350Sp\325\254_\262\304\357U\031*\262$\363\371\030\036ay\200\242", 64 }, + { "|\035\377\326\376\2752^\335\207\230\271\341\326z*", 16, "P\271\315\034\230[z$j\377\266\015\205\3064h_\316\254\271\353\342\301*\366\366\350iV\004\351f}\260wr\257\236\025\241", 6000, "\301\354S\253]c\332 \277\205!Y\356v%\225\367c`gB\006\024\247t\314\300Q\323\225\020d\036\024A\353d\335\007\025\014\245?\252\246W\222w'\301\263\003M\014\300.\014\2420\011\355\342XA", 64 }, + { "\364;\377\002H\026A\016P\352\331g\2407[\261", 16, "p\271\243\3110\372w{O\317\315Q\035\371\221\016\236\215\002\222\317Z{\372\375X\316 8\226\270\024\344\373^>\235\274\320\337\313\366\223\246\336\250\134K", 6000, "\340Lv+w\360\311\322\355_\036@Hd\246\275\324\033\235\274\013RJr&zD\230\345\033\216\234\213\255\237[\217U\367\300\356\331\372\237\021)x\362\216\306/\351\374\314\210\2341h\227|\230,\336D", 64 }, + { "\134.\271\033\351\232P\020\356k\321X\351q\331\004", 16, "\277\207!\216\312\324\347\223\234\202\360\220}m\3773\210\232pe\020\254\371\334\266(\227\254?\305\017T5\020\210\223\006O\223\375\357!+\363\003\245.\325\255vF\350\3565s\221", 6000, "\352*\003U\323P\225\256\254\374\001\337\312\377[\134>\2306\270\001\217V\033\006<\243\265\012\355+\024&\374\313\031\254|\302\006\216\216\250wD\352\320\3128zf\000\205[P\323\013E{\025\353\276\316\034", 64 }, + { "\015\372\205\371:m\005T\000n\3255\366\220\2653", 16, "\266\234\036\134e\020:],5\005\201\331`S\305\224\017kW=@.\025\376\017\353\022\210\007#|M6\354\210\3121N\356\331\033\223\230\344\305sR\241\232p*t\217\366\243\352E\255\332\004\270\365\361", 6000, "qq\245\012\237#\004\316%\345a6\322\340\353\0344\265\013LH`\237A\232\337\357]\363\023[\353\2631\000\277\013\317\336\371\3125\312y\305`\236*]]\204\236\302\344e#L\270F\232\372\267\232\250", 64 }, + { "F\256\277\366N\234\235\316\042\230\263\256\025Q\320'", 16, "\200\254Yq.\205\373\373\0056\331\214\376C\235\277\323\350\261Rc<\177.<\326\237B\353\373\360\313\257\333^\212\303\023>\223\004\327Q\333\271\011I\303\230N\325N\0172vT\011\214\330a\260\216n\017\207xd\264\327\272f\276", 6000, "9\343\311g\224\222\221\275\256Mb\206nD\361\232L\327s\222P\005;\255\027\240\261R-M\231\347\315\3164\264\314F\347\245\372\247\247\303Q\341\241\271\003\035\207\303\304\335,\012\360?Y\320Y\227\376q", 64 }, + { "#\256)c\376QG\273\245\222Y\010\357x\221;", 16, "\315Ysi\036\266I\332", 7000, "Z\213\027\2367\231\205\005\224\300'\224>u*\372\031\003U\205\242e\223\274Q6F\362;?\022\327_\343!\214\276\262\247L\260MLX\247N*Y+\331\361\215\220l\331\213\361\335c\314\203.\330~", 64 }, + { "\360\343\200\367\344\250O\260\215`\247Z\341\274\346\270", 16, "\310\2524/j\334(\344\303\017Bs-\201\264\312", 7000, "\037$}\362F\213\254\306\345R\345i\326Z&\262Q\017\304\210\026\216\336#\220:A]\210[W\246\272\005\011z\337\036g\366\206)\245\201\214K\335#\212\205\350B\376h\034!\235\006M\272\256\225\257\220", 64 }, + { "<\230\261\363\334\357\217\022\276\000R\306\240\210Dg", 16, "FQ\263I\223\375\335\2135\006\374-1/\227\207S\341\202!\372\206\253\236", 7000, "\266|\263\374\266\265}\000\261eB\307;\233\241V\253C\014\224\230\012\326q\276\242>M\214[wt \361\361\205\303\311\320\355dV\245\242A\237MAt\237\340\242K\3133\355\357\034\303\200\0277\267U", 64 }, + { "\213.\310\205\014W\307\364sd\223u\363\035M\260", 16, "\331\007K\015\367D\224\016Q@\243a\264\342\346\216t\2161\030p\345{\227\245]\245\274\235{\322\245", 7000, "nX\013K/^l\377\237\3044\010\277\367\134.\222\215/\3471\023&:]!^\261\177g\272\011\177\374#2\177\326v\251\003\005\374\232z\030\274@\311\321n\323\227*\024H\225PA\241y(\276\361", 64 }, + { "`k\271x\304Cf\230\313;O\277\236\2448\207", 16, "r(\245\265\003\237kT\204@\321\252\202j\242\352\365\366FZZ:\366\272#\323\017\2666U\240v\252\236S\332\011\001\361p", 7000, "W\200\361\034j\376\022\254\325\205\257|\232\255w/0\373\267n~\355u_\331\007\242jXi\034E\254\032S\205\034/\023i\356\310\250\226\3517\201\311\360\237\201\221O\267w\355`\366\217\257\006z\357\321", 64 }, + { "bg\316Zg(\330\371\016:\011^\202\000\235f", 16, "_\177\346\022\375\256%\310\347m\336p`_J\333\334\003\312k\254X,Z\361\372\303#\305q;\343&XT\316`\006\036\215\306\207\327\311\255(\203/", 7000, "\313\000\3670T+\346TF\365[6\223rBb\241\267_\035\321y\315o\255\321\035\361\230\371\230\015\264\347y\364'\376-\240yL\036\260\265\234\265n.\217\312\261a\234\032\227\257\207a\331\354\010\263X", 64 }, + { "\350\026px{\014~\0317\015\314\231h\336\237\217", 16, "\347A\307^u\267Qc\027\235j\323\012\315\311\031\234\2003R'\015\221\370\030\227\003)h\214\236\012Qok\210`\320\227\307\354\303\305\317\314~|\014Z\012WA\036M\322I", 7000, "\227|\356\271\333\257\235G", 16, "\311\372\032x.?\3452L\331*\235\356\356\261sY\313\266\260\014\202\333\016\006\322j\3516\007U\377\215p\177s\267&\010\352\010A\361\315\357\0103k\220\311\042\250\267\022\312\030\034>\343\250\320\300\002\0123i\361\025~V\037\273\277\322\272sI\375m\375\337(\345*\220\362w\231\373\315y\230\273l3\017\226\260`", 64 }, + { ",<\361\027\343\375\355\265O\264\234[w5\261\340", 16, "dS:\242\350\2612,\314\224}\367\361kW\335+Gj\357Q\355\251i@\326r\024K\346\034B\340\360\242\356\016\272\216m\232u\220\300\236\333\312\363\036\241(\322&\244\211=\275\376\006.\377\013\034\220\020\306\353\274\374\042[\300", 7000, "\277\364m'[]\305CMd`\345G\237\352\371\225\215\373j>V\362\241!\364l\033<\236\364O\023\276?n\231\207\3735\201r\270\305\337\177'b\031\014\251\213\217mZ\320\266O\211\364&\0304x", 64 }, + { "\225\306\272{\341v\275 [\231\230\317\371\363Je", 16, "\343\036pA\252Q\264\242", 8000, "sJ\331\240\3206G\226\015\2441\370e\317\012u\356\372V>}\251l\1340\033U\177\215\316\317\037v\226\016\272O\275Z\341\307\370\317q\311\010\332\304\012a\375\343y\336ZT\377-2\361\203 \042\336", 64 }, + { "\320\231-\337g\034\212\004\342\037QU:X\277\316", 16, "\216k\037\361.T\244\366\003\010E\323U\233v\240", 8000, "\021\375\214G\326\017\316\350\013*\236-\013\026S\223\310,d\036L\311\032CM\006\0352\241\232\000\342\224\025x:\215S\2146wvh\205\306-[p2\003\322M\224\353\237\263/\216\134`Z8\273_", 64 }, + { "*/E\206\367\224\243\334\243\262r\326\360\231*H", 16, "\345\315t\032\021\207@\026\330=HF\320\204\304\330!\232Om\322\246\0260", 8000, "\200\306R\350\230V\334N\020\001Ol\242\024yN:\350\241\332\214\262\016\2629V\264(\2059\220\326b\340\303\020h\232gb\202ZCiR\275z\347+\326\267\027+A\246!\345\206k6\344\255\264*", 64 }, + { "S\345P\373\311\016\352\202\352`)Ecl\336\361", 16, "\376\007\354p2\333q\006\237q%\037\220/,\007\264\366\006-\335\273\235\377\036\345\035:\351\042k<", 8000, "\204\256G\244\332\302{GC\274\335x\200\216\001\232\211>\263\211\360\032\031\267\236\317\257\211\273\031u?.M\022\014\220!\202\225\310_VC)L\001\323\362\014\231\341\244\350\222\022\243\361t\364\357\316G\257", 64 }, + { "F\042a\201rU \373\374e\273\351=\364w\222", 16, "\212\030=]!}o\373VP\036\303\376/\373\322\025\222n\234\300Rl\264\010\2311(Y\275\232\3137\013i>\327\233)\207", 8000, "\233\276*\331\257\377\012\270|\212\272\2466cAh\225\024\334\2332\026\177\330'\006\210\210V\277\323\251\211\230\212\363W\2258y\224\236=9\337(]\010\3171N\342\016.Cjm\322Y\356\26574\207\332\355^\351f\0258\343\267w\361B", 64 }, + { "\305?\017\233\177\271m4\354\221@\216j\376%_", 16, "_,H\223\264<\314\342", 9000, "\236\314\367\273Z6(]M\214\215U\254\264\325Gb\24793\042l66\014g\317\342a\236\317\251\254CaS\326![\210\303\323\202\032f\014M\247\034w\225a\220\303\332\024L\317M\324\022\023\206\316", 64 }, + { "?0`\205\22034\220\217B\361\242\217+'\022", 16, "\177\315\237t\250\213S\313\337\265\337\371]l8\026", 9000, "\377n\327S\215\306\365\346\375Gj\247\245e\2004\343\202\221^_\275}\323\2345\302\007\333\337p\353\265\222\350t\227g\356\032\272G't\242r3V\276\362Lf\222\016\244Ez\200\315\247\370B|\372", 64 }, + { "\306$\211\276,\353}W.\355\274\330\215Ay\346", 16, "\330\362\015\255\012+e\264\241.\036#\377\327\001\011\205\254i;[P\223\363", 9000, "\204\003\342\235\365\213\361\303\3248_\324\346\330RpT4\235J\0106j\263\032\2113bjHj\233\332\365oA\222\247s;\250\247\017\377U\354-f\005\277p\377\345\345&ILO05\232R\325\311", 64 }, + { "\257\364\250\253\267\304/\330\357ch\230xu]1", 16, "\247\336\344\240\322\251G\223\222\225P\370\322\311/\204f}\253\222\252\363y\214\346\016x\262&N_\002", 9000, "\262\003\321\0362H\220\310\344\306\265\020\373\300T3\2652+\252g\275\225\224\036\357\2050B?\375E\273\232\344\024\310\344Zh\004(%@e)\264\202\2022iAZ\030\210\033r\346\211\332x\363\023\032", 64 }, + { "\340\000\323\220e,\371U\242\254f\245\272\337\001\357", 16, "\215\306\001}9&\307\2221d\253\212q\236\3316G\005|\015\042\012\361+\005w\270\367\211\332N\026\331\037\250\014\212d\330\246", 9000, "\260\342\217\247s\321\350A\016\221\371\222W\304&<`\312c#\366\002\225\241fJ\033\211F\252\300\251Z\313\225q\202\036w\253\264\277+\361\256\235\354\300\203g\334qz\310[\022\326\212\223\314H\247Wg", 64 }, + { "\025[\275\212\134\0013L[|\034k\356Q\321\267", 16, "#YZ\033(t\272\257\363\262\134\225y\206zF\234rB\266\221\254\367\310\042\264\270\236\026\372#v\354\213\265\372\221\304-i\020\042\0107\344\253\3678", 9000, "E\267\177\372_&\305\201\215\351\335\007irx\302U\037\252\012q4\201U\356%\366m\245\202\373bqh\244;\271z\372l\2516u\267\004\013\246z\274F\021\312E\177\2159|\037\033C\340\351\332\353", 64 }, + { "\312\016\206\247\361E\252\245\001\033\031\234\227\246L\332", 16, "^S8\353\353\0307\031}\012\247}o\352@\027\217\200s\220\206c\320`D\270\232\275#\361\223\210ur\361%\003\034\3607\255E\016\271p\336\274\260Q\027\0136r\246\025\263", 9000, "\202d\317\362\315$\311J\377+\037\244V\342.\336\363Mx^\347\202\206Vm:\363[\3353\324\316\3403\012\357\351\364\221TN\340\275ALC\033mC\224\225\274\000{n>i\327\006\221p\360:\020", 64 }, + { "I-\350\031\2302\352\226OO\234*?me\030", 16, "\004'\254\034\206\216\214\277\213/\235\237\007\312K\347\034\361?\376\327C64w\313\300\004Z\226\207\303\363\0066\377\375=\341\371\207Aq\247V\237\024T\246\200X\342]\005\356\337\273\023tq\226\032\021\202", 9000, "\367\317\013/\030\210_\377\013k\366C\234s\237\011\212\330!.\016\263@\353\017\007\034\345B\212s\204\371q\336;\334\032\313E\324>\326e\344\304v\205\004\342\000\343v\025\346ZO\2243Y\264\366Z{", 64 }, + { "\237\234O\246\003\264m\356\326\201\266\313\345\227j\324", 16, "\027\016\205\250\331\027\275\260Q\032'\204\373j<\233N\251v\234\346T\250\270n\017\244\225\275\340\354\346LJ\376\2779\2311\311\312P\335\036\323\202h\255\254\376\261\350kO\3324\277\266\223\207Q\263\373\351&\0030\247\330lL9", 9000, "r\036\301q\371B\034\017/H\010>\242\326\247F\353\014\333:)9\353\261c\003\177\223\3277\250Sm\263\306\316\261\341\321\321\134\232b\312\235\014@\336l\330\3356\001nw>\363\015\210O!*{Z", 64 }, + { "\227\346\344\330,\020\250\376\033v\253F\236\207\374\245C\230\255&\277\300\310M", 24, "\333\256\034\031\307s\315'", 100, "\267@0\237\025s\217\307\3646\231O\246za\000\340\233Q\254$\277/=)M\250\213i\245\275t\333\322U\256S\025\030<\200fFkO\2528Y\272\243:\033\315\304\313\237\017\356\255\274\357m\323\215", 64 }, + { "\3410\3103\201\025\037\366'2\340N\277\256q\345Gc\020\036kH\373w", 24, "\302\330?\225\200d\3510\335\346\211\317\324\365\366*", 100, "FN\014\374\031a\240\212\202H\314\016\371|{\025\267\243\353r\257\365{35\134q\252\205\357]\317,Y\350G\206\365Tuf9\356\267\365S\371\332+\245f\332\213\371\320\215\215\300\242\243\216F\361-", 64 }, + { "\265\001\263W\336\011\274\204=\356p6\210\000\216k\216k\203\365>W\275k", 24, "\270\342\331\242\013|j\306\324$X\035R\365\326\242\307\036Z\321\303\357hi", 100, "\005\301\361qhJ\263\253\2069O\003\242E\333Z\014\003\274\336f\322De(\376\024T\336\250\2111T\270\320>\366\266\311P\177\234\264(\015Vd\260+ De[\0301}gzZ/\263\263ma", 64 }, + { "C\347\306\033\005#\201X+OL\177\310\360:\207'L\316B\325\264\324\264", 24, "\021\357\353jzG\377\235V\012u\262'\256\354:\007\343A-'{Z\204\204\226\321GbTP\270", 100, "\200GB\211ui\244\352\343Sj\207|\250\213\035\010[\335\312\345k)&a\035\363\213\371\217\212\317\364\031{]\355\315E\222@n\026\375k\357\004\3505\025\226w<\134\226\324\326\254\345$\322l\302\247", 64 }, + { "\236\030\042\231=f\332wq\260\342\364o\372S\374t^\343\027\374\006\002\024", 24, "\344\273\215\371\325wt\273n\225\221\020\263\214~\226\266\237\226\323w\026\313\327\377\201\022\226\356.7`C\362jR\217,\362.", 100, "\235\361\025\375f\302\004\271\274\003\354w\027\001f\034\246\323HME~<%\303I\037 \266\042\335PY\306\134<]\364\377\026\254d^a\327\275\012\134\223\027\265\277\177\035W\3347,d\362\250`\006\342", 64 }, + { "\035x\237%7I1\271N\370\236\340\214p\331\367@\355o\134\256\032\355\243", 24, "3w\231\014p'd\220\317\366[Kz\241\271\010\200u\225.E\277\313q\262\341\313\031\271\205\016\024\3616\021\345\030\254\367\314\312] \026\211\273fs", 100, "-\300\221\205rc1\013\374\370_xC\315\013Y\21477\320\202m(\345(%:\260\232\304\004\263\303\275\304\317D\376\245\331K\310\027\343\322\221q\200.Kp\206\311\231\306!a\240\203\324^)%\026", 64 }, + { "\023\366\263t\006\015l\264\316Gq\271\3468j\220\271\232\361\223tW\224\020", 24, "\365\367`yT7jO\360\247/;-K\241\031\227\034\211\251[\236S\015\035P\304\256\342E!q\205WJ\207\373\016\006\355`\235\367[~\300\264'\232\200u\241\234\210io", 100, "\271\034\330\262\216K\312\224\375\206\243\341{\372}\232\210R2H\032n\264\377J\021*\263\022\240\277i\242\356GS\302\243b\230@\034<\261\276\025\016\340EIt$;\347\221\024W\311\275R\254\272A\037", 64 }, + { "\373Oc{\307\313=\3414>\340\016\245\217jar]\035\307\252\010\031\025", 24, "kk\262\256\340\255Z\310\235\020\320_\032\345\260\243\352\202\321\301\246s\300)\3314FJ\267\361b\237\034*BrjY=z\336\300\344\370\371\035\227\334[5*\325\3152\233Z\022\302\3733Wr\012\005", 100, "\246\372\3420\204\346\034\314$wZT/\240\376d\252\354?\331y\225\037\252\374Ah.\304\3737\242\013K\351\035tH(\255\353\240\214\304\350\245s\273\326\265\340\300\253,\022/\311\223\024\3369\002{V", 64 }, + { "\201\012\000\332_\206`\206GD\336\346Gm\227j>\301Y\333\2658\354\001", 24, "\361\321\374qZ\346\016\307Xm(a\256\301\002\245\352\216\244/ca\247,\315V\017+H\004\355wmR\225Upz\373\217\333\206\337>\257\313\275\307\260\342PS\013\260\356\377\322\267e\027\250\030\262B\012\346Q\260\025C\311\317", 100, "\254\012\230\016\257A\017\210\264Z&\234\320\375BRb?\266\012\2509\222\355UgM\322Y^\321b\225\243\353\374\374\224\2545$q\030\030\370\332M\302\350\014F\023p\033\201\316\004\000\270b\016!)$", 64 }, + { "n( \210$O\004\366\207T\3158\361!\212\3606\317<\330G\250\260\272", 24, "\204+\330\321\244\030h\275", 200, "\353Ko\207&\357t\224\036\266ob\222)Cz\360#p\020E\357k\320\370\007R\375\311'\347\007\364p\340\341\275\220\341\260\032\316]-Rthu\206\202\255QY\251.\214\245\330\007\312\354@\375\204", 64 }, + { "'\273`n\012l\345{r4\347\264\223\376LW\311\363P_h\302\001C", 24, "\324\200pH\263\220\2615\305\341\371Gp:\323\322", 200, "\205-\343\243<\333\375na\337\314\271J\354S\300D7\011J\364\023?\2222\360\267\221\010Fr\256\366{\366\235\255\331K 1\370\307V\373\020o\363\367\036\226\004\246G\331o\321%\314\220\254\234\317\033", 64 }, + { "\345/\334G\221\360\212(\211i\247\012\215\223h(P\366\215\371\300w\336\274", 24, "o\341\236\363w\371x\217Y)\013\331\006\034\222\007\221oA\022\037\332\252-", 200, "os\235_H\326N\300\244\310\361o0\202j4\334YO \345#:/\227\042=$@\363h\212\365\376\277\34220\301\371\373\250\327\201\374\012!)_\001\346Y\2061\220\302e\323\004E\364\025\334Q", 64 }, + { "|fm*#\220r\246\343f\364\364\241\370P\313\315}\216x\303,\335w", 24, "\342\177\034\326\226\223Oo\035\214\227\361\305\316\314\307\323\223\353\271\303_\213^\337\017\204C\316\037t\345", 200, "\2571!\373\364\361]\225\332K\267\042\317\314\030\2360.\257\037H\215E\276I,\356\033\13411\267\335>;\226\254g\2532\024\323t\024\237\275\014\021\267\251\004\004\331o\305\036\256\221\234\242\210[\273\271", 64 }, + { "\315\3742x\230\331D\375G\256R\363g\316 \024Q\034\317C\271X\240K", 24, "<3~d\026V9\2178\224\202\324U\335\006%\270=\225^\001l\212\212UC\277\270\233r\211lR\300\275\223\275\300\346J", 200, "`[\366\233Zk==\042\033\211\322-r\354e6D\210\302\275\247\274\374\0266\203d\234\315\331\244\2671\226\014\336\243\350\216^\206\255\242\023ueK\017%CN\002t\300N\244\272?/s\243\200\327", 64 }, + { "v\313\001I\364\011(l\005=7\330\0012\000C@w\317\206\230\306\363\000", 24, " \300\300\271\3443iMC\254\301*%S\325\211\212Rw\350\3027N\233\237\334\3134\204\332\031HS\374\3749\214 \3503FN\367\002\030\312\351D", 200, "S\007a\011\031\231\366\371g\003@\3407\024\016\376yl\373M ksH\327=6\210Y\225Q\325(\2348\334\362E/w#\375\354qY5\324\356F\212\232:\033\231\306\235\302\321\330y\226\005\260X", 64 }, + { "\335\002\277\030F@\273\340E\000\300\304\372\322n\230\262\354\032\250/*\351\230", 24, "\270\207\0010\377\337\347\375\213\331q\315\033\371\253\012n\275\262D\267\226G\367\371P\213*xA!\364!J\342\2113\242\321:\205\203hF\015\315D\026\313\353[`\213`\374j", 200, "3\301\365]\214s%u\230\234\215e\331<.\347<\320T/\254\351\243huF\003dA\341\342\372\206\243\005\277\257\033\364\042[\200Y\326\017@\015\271R\225\035\330z\37523*\313\3347\027\226\325\355", 64 }, + { "C\325RQ/\246$:h\177\362\331\223\261\312\006\237%\326zY\375\033\341", 24, "\002d\2740-\177h\221\356\310\211B\036K/H\335\336X\326\324\3304\251D\365\377\234\220\375\325,`\003O?\340\276=1\246+\231\336\233\211\272\265\257K\036\316\333\204\223g\035\336s\347h\230\270f", 200, "[\037\344w\257\272\235\230\032\270\263xh\361\014\273\350:\273\201Z[\314W\254\224\222\364;z\303\372D:\022a\366\266\364U\3467\314\337\357\246su\014FO\240\030:\325\362ZA\363`\362\005q!", 64 }, + { "=e\0029fU\375,?\262\327\273+f\013\263\201\021\027N\026y\341\340", 24, "\312\204\344\332=f\0336\341\017\264#j\216\206\236k\022Z`B\242\355'Y\016\267h?F\270\213B0\245;\367f\363\246J\012\200\330y\230\200}\347$\243\343\216\032\037\006\271\214\322X\255\256\032\276\021%\263aM\264\252G", 200, "H)\352\343\007'}5\333\013:e\354\225zG\271\032\340~\262\351\261\177\004\227~\333I\363\301u\210S\252\231\340+R\271\336\317\027\354\351\364<\276\220\042a\373\320en\370\001\301\305\356\344\244\236,", 64 }, + { "\376\374`\300n\003\362\372\017\2253-\307\232\264a\351F\247\002\011\270\336\311", 24, "\023\265B\220\374\244\304\323", 300, "{\346'N\227\254\343\334b\323\220\316&\335\375\227\013\314K\214~E\374$n.Mi\337\223\326L\361\342\237\242\257D\207'#\237\373.\2729\363\005\003O\216\011\005$\261O\214\343\275(X\336]\317", 64 }, + { "\177\337\370\037J\313\252R\367\027-\303\274\322?(]\370\017_?\010\360a", 24, "~hCg\251\003\302}\372\2644,v\264q\251", 300, "\003\253\302X\215\255\034\206\337\272\327Z}\206\000\333\311\026\377T\336\347\315\341>\210gsS*\276@3(T\340\263#\325\327\335\027~\310\201;C\2723?\042\341R\346\247\273\355\344\002\300\341\314\245\345", 64 }, + { "mD\363\333\332\276\206\023\340y\331\010\326\322\331vHX\265:\277\042\350_", 24, "w\011\263\376{\016R3\025\013<\033\261\320\024\017\356)\371\235c\021\353\262", 300, "\304\010\302K\273#u\237\227\3135^\134\2743z\326F\265=}0#m\240@\303\020\356\373\042Xl\223^)\242\031\374\215\031T\316\020\203\255\273$\024\034h1\370\270;\276\277P\250k\252\352\232\371", 64 }, + { "Z\2556U\206\026\34258E\247BT\276%L\367\0119r\032\233L\272", 24, "8@\034\305j[D\015A\317!\227jgy\313D\315ZIu\367\266{@]\335\311}\351dC", 300, "\022\23418\340\022\235\005\024\016\010m\217\370\271\262\307z\325\003\237:a\216\255w\023y=#fx\323k\346\215\331\275\206YGw_\261\353\007", 64 }, + { "\247\005\202\025\315\206zP\360\241\134\036C<-\006\327\363\201q\251\002`\267", 24, "\271]\336\352\244%\215\020\330\3458\377\225\350\302\237\253\033\202\367\265\373\331\261o\250\031Q\374q\217\254\233o\230\375\236\327\333f", 300, " ~\303\251\370\211U\337,\237Ln}E\320.k\245\246i\234\202r\314\324MU\365\377v\3177\266nXT\002%\346<;\350\3354\262\330\275\303W\242\014\024UN\274Hd\210 W\244\222Fv", 64 }, + { "%\312/\275\212\305\002\376\340\362\311b\224\3203\012\317R\370]\336\204\260>", 24, "\343';\334\363\247E\332\354\203kj\3654>+_E\310\353~xO\202n\234\217\227\360\371\261\343\314E\331-\210\203\032]\177;)$~\333\367\313", 300, "\2553\037\301\022E\356\010\274\241\216\332\333\037!9X\374z\314\306T\345\274'Z\256\375\036\355HL\337Dw\276\235D\225\213\304\214\350\250\031\316\200B\317\320:\0253\233\233\025n\264\016Y\271\242\035\316", 64 }, + { "\273o\033\015`\0168\005\343\233[\262$q\314\315\246\011\036(\233\203\211'", 24, "Qsa\3029\213*\321F\261}\270\357\330\030\200\335\375'\261cT$\2101\303\035\253\024\267\240\246\377&\316\357\331\221\361nl\0327B\015[\332h\333\376\351\0258\232\203\321", 300, "\260<4h\346\217Q\237=\376N\213\261R\257\374@!&\300\311\027\263\346'\230\377\224\134\225\237\002vQu\006\033y\036D\357T\362\316\311.\321\271\207r8\304\035T\226\233\326\345,\327\361W\217\364", 64 }, + { "-\207,\240\261txU\001\360Q\213R3\332\236\037_7\016H\261d,", 24, ",U^\351\036\003\300?0&+'`\363\252j\202\270V\375\007\355DR^\032\011\237}B\304\031\267.[\266J\273]\325y\335\327\2555\201m\233\254\352A\315\214\337\022Q\270\330\367?\363A\021f", 300, "\220\326\330u\2268\305\223\255\2359\332\203\273F\203I~\012\232g\001\355jb\224\212\226\032\277\036z\326\0361\265\025[N\226\261$f\216\311\236X:.\366\036_\020:\247\004d\276_\276\237`\323=", 64 }, + { "\276\035\274eI\033\356\262M3\021I\315\006j\241T\025\216\342\246\223\035}", 24, "1\316\345\252\312\377\027_\302v+.\276[\002j\006\266\233\037\265UR\023\255\244o\263\333\276+\264s\336\304f'\250\377\003\300\006\320\006B\375\205\300\332\341p\241\223\254\024j\274\231\024:\003\276\233\232\006\011\201\220\356\257\257\361", 300, "\271\353O+ C\226\325Qu\362\201Cb\304)\014\367\001\376\243\027\360U\273\356Y\235\234\357\243\002a\210\324\017`\304F\317;\022\014\021Y\375?\356\343\253\306\371\006\330fdD\333O6\042\203\214\354", 64 }, + { "\342$\336\336[\306\001\033/\216\277\201\367\014\257\362\331\320\374\036\034\361\371N", 24, "\220F\317Y\0232\2022", 400, "\351\321\325*\035\023\026\377\273d.\016s\225\276\321.\330u\014V+\331Z\223\365\034\371\377\236^\203\213\240\375\220/\313P\024WS\331\034\251\347\220ux\231[$\334:x\014|\344\010\233U)\276\344", 64 }, + { "D\255;\367\374\305_\373\372\020$\201\275\3735p`S\330\333\246\271\316)", 24, "\300M\273:\024\362\017\002\247j\376#8\321\260\346", 400, "rW\235\326[\326(\001\223\221\340\316\006z Z$\217\321\372\3722\277\024\334\025I\252\374\134\232\342!\2111\351\323}^\324\217L\032\350n1\372>\311\001\323\3239\321\345i\262\323\013\014\262j \336", 64 }, + { "\200q\243(\134z\361\042cG\335'v\231\025X:\016\316\0170\342hH", 24, "!8\347\001?\220\313\251\3042\306\201\004l\012\356.\177\367~e\305\3269", 400, "\371\230\253b7m\177\266\325\344\350\375>!D\246b", 24, "\314\354\361@\255\027O\232\037\322w\032\316\356i\023\333\331\342n-\301Q\002\244\2328z\026\304$\372\366\260cc\310_S\236\241\237\304\212[\022'\365\226e\016_X\303\323\005'\374\010}O\336\242\321", 400, "\273\265\023\023\343\261\201\026t\300\270#E\336\012I8\300\271\011\016`\234\326\2417\015\311t\012\322\341\355T\335\254\217L\243\253\211\364\234d\222-\344\203\027o\342y1\305\266\261$\316\376\364\220\317I\267", 64 }, + { "\275\272\371\314\250`\370\331\324d(\227\364e\203!\014\322m\254kH\012\354", 24, "\2617\007\347\243\255u9\320\226\035d\341\311\344L\272\352\023\256\361\332\364\2700\014\247\331s]\234\223\223\210/\273V\364\335\015\032\267\357_\001q\310\367\260E\374!E\335\200\337\316sQ\205\023\240M\355\267\250\020{\207\254\231i", 400, "R\300\302\270\242\312\331\300\376P\201\353\0128\370\241o\233\316\260\030\222\303\322)\376\017>\007\011\005\222JPb\361\233\340)\036\352\242\035*>\373R\020\203\355\340\000\0212K8\311\240\266\134\347\351\216\326", 64 }, + { "\330\2011\262\366s\232\025\317~\260\312\237+J\202\020t?\134l\207\310\304", 24, "cE\245\266X\315\3545", 500, "\315\247\030\277\337=T\214\254\331&\364\374\030\246\000]\220\345\274\373k\243O\0234\006\210\2606\031\360y\205\226\221\212I\341\006\216M\206K\211\342\314s\343\327\316\353A]}z@b\0053\202\212R[", 64 }, + { "\250+>b\307\310\001\233\331\261o\360>\206\2733Dp\340y\017\372V\023", 24, "E\241\134\345\365\327\016\336D,\217\032\022E\233\262", 500, "O5\263\352\317g89k\247\351\020/\037\3033\370T7\304\256o\216\337\227\321\225\254hH\211G\316\224j^c\271?\340\036\003\177\001\205Y\303a3\376f \021\211\344q\362\255Q\341\264\244u\321", 64 }, + { "\2153$\257\243\042\257\230\3443\276Y\275\000\354^\363\317\342#\343\272~?", 24, ")\246LD\006}w(\243\307w\260\336\241\024w{O\237/\236\004\230\016", 500, "\304\373j\036\0062\302._\327q\002\302 \023~\367\007.TC,\206\177DX\275Y]\224\366\232\212\001U\207z\305\233\317\320\203\3543\353s\374\012\272q`]\333W\305\250E\336VG\223\343I\257", 64 }, + { "\224\302\305\230\315\313\231\243pxO_\014\374\342\256\237\231\356\330\215:\260S", 24, "\310D\2217\341\363\362\243&@$\221\340\320\266\213\236`LOy:'\300\244\314\212\302^Q\373\376", 500, "i\311\241\337\357s\333\356P+\023'\330\310\273\205D\354\233\343\310\306;\037\213N6\230\006\273\261H\272X\243\367\341t\234\035\263\2034{\203p\034\371gY\265^_\010\267\321~\272\34364\227\322\027", 64 }, + { "m#\277k\323P\307\256\351\316\020\370d\202\377\023P~l\024\201p\033\015", 24, "\366g\225\335\215\223\322\241\007\333\007Y\275\343\330\267\346\003\006\306q\332\317\355\355\377\373}\303i\3322\262\322\221\226\217\305\027\354", 500, "\351\011\202M\306\035&\257KE\357\361\3644\243^\272\346\024\375\267gK4\010y\013\021\361o\253\025\2719\267yk\374\261 [\010\036\360yP\311\351v\0252\236\270i\217\356\022\006\214\224k@L\343", 64 }, + { "\264\276S\014\276;\012]s|\330\273\223+\222\230\004j-\035u\260\336\364", 24, "\177\010jO\370\237\274\370J\333u\240\013\255\374\3621\342\013\240H\374l\372\225\016\266Vy\315\371\030*\024\231\302pLl\234\336\255\271T\001V\254\263", 500, "\225$\317\031\226?\314Cy\201\035-@<\030\252\205\014\245\231\277\271\013\317\375\260", 64 }, + { ".\373qW\226\272\303\354\235\374\302\320h\345\357\034\014\250\344\266\244\325\244\270", 24, "\240/%\223\314\333\316\363\361\034q\245\312\134]\254\263\267\255f\225\217\313\313!ax\035\273\264\272_\027\037\323c\253\271\372\246\013\361\305\364\014\016@-\310\361\233Tc(\015\014", 500, "\010\250\337\244J\255\022/\001\035M\334\2426i\327\255\012i\333\217Y4\250uG\007D\225:\276\344|\027(\311\302\307\321!!A\003\343y\202\247\267\253R\032\312Y\243\134\007\252\321\236\251\364\307\342\366", 64 }, + { "3\244\330\322\257\350\201\244$\032V\270\032\236T:YU\211U\265\327\262\355", 24, "\227o]\354 ;iq\224\345\203Z\231L9+\374\316\265\226\226{\375\377\204\007\223\274\273RH\244\134\243\224A\337W-k\362\372\317'\207\023\272\361\347\015\3371\344\334\226\277\215\277\237\351O\307\362}", 500, "I^J\373\327{\005\200L\373\304\022M\022\250J\253Iu`\345;/\023\325\362\001\032\367{B\017\366_\034a\257x\000\025}tA\347\332]#_\260\023\211{\301\310/@.&\272-\005\323\262\355", 64 }, + { "\343~<_Kd\253{\262\357W95\256\337n\325\336\357\257\260-\227\011", 24, "\251\014\025\254\015\257!\326\256@1\225Ay\027\311\313\204'#\230\306\254\036\324p\221e>\230{\373ZP\236\025\025\3610\001\313\002\275\315\204\263\332\315\342\003-\326\356\216[+\270g\255p%\224O\306\365\241H\262\001q\231\346", 500, "\307\204\357\347\320l\0328\015\373G\336\271\322h\326\034\245\301,G\215Jf\031\177\355fhtW\034g\266\316V\034\222\042\346U\253Ac\036\304g$1\004\244\245VP=41\313\200\272FJe\374", 64 }, + { ".\246\322\250\363\276\370\266\342\207\226\210p\366P\025FM\371\232\203*\036\303", 24, "m\221\370\307\016\020\374\317", 600, "\252D\266\320\035\2649\007=\003\326\355p\332;\021\277\360\200\255\033\313w\366}\201a\325\377A\033\365\321\320S\357G\241e\344\375)\0303E;\256\017 \031'\223\204\2630\027\253\225\354\305T\366\360\005", 64 }, + { "\277\010D\025\241\325\032%\235\032y2A;H\020\214\333\306\356j$", 64 }, + { "\002\261>m$`\016\02494\263\307\353\263\252r\006\356x\223\215\321\236\037", 24, ".\222M\266\201\371\370\375\214\134\223)\242\011\371\225\365Y\203*\365\275\252\037\262\315\024;\032\256SuK\275hn\231\233HN", 600, "q\223\223]O\3412\371D\304\246Z\277P\267\307\247\327\213\036$\223\234Q\021e\332u\004\240\254\316_\012\036!\230\213\233~=\233Ay/\313\010\204\207\220\312j*\016\324\347\042=\017\217Qn4\302", 64 }, + { "\216i\036Z\247\365\202\373\255\243\035o\301\221\013\3434*r\347\214\002\342T", 24, "F-\311\364o3?M\260\205\340:)\302.>#\203O\340\245@6\375\356\313X\267\302c0\014\325\261{\013\267\253\277\027W\254\004a\353\350\255b", 600, "Uq\242\257\354/\372\365\027\376\020\267#S\277\237\300\314t\021\234\370\034\320\206-\357T\272\370\204r\002ZAsX\356j}\012\2259\247\231\211<6-\372\027V8ZM]\200\2344\227\276q\033\322", 64 }, + { "g,R\261\255\355\242\315\344\302\207\312\216\326$&\246\352\351\004\230\372\357\342", 24, "\011\237\227\033\026b\224\320Z\340\2019r\220\367\304m\256%&&\3424zt!CY F\014\347\345v\255\230Se\372\021\242\203YH\277\262\213\301\327\267\314\036\205\0020$", 600, "\020*\217~@\030\030z\241\300Cf\230\362\037\343r\203\344A\304Z\223\2310\331X\377\365k\237\245'l\223\024\012`\345*\324?\310L\344!\270\340>\001 aL\220\001\221KD\235n9\333\362\227", 64 }, + { "-^[\305D\215\276\210\007\255\365\315\023\340\343\011\212_\340?\215(\221|", 24, "'(\221\177\261K\003\247;*\201=\251?\240\345\026U\225\252\355lg\342\310\021-\006\004\270-\256\340&\007e\304\042;]K\306b ;h\222d\353\277\030\332}\355\030\001\347o\375a:#\207\232", 600, "\213{K\321\232\301\253\312\037\324\340\2454\262\376J\335\210J\235\252\220\370-\004\042\134C\316\025\275Te\250\333\212\227\324\035\006\244c\273\004Mq2\276\373\005w'\212f\266u\010\320(\361\332\217W\000", 64 }, + { "E\223\025>\255\312\337\310X\234\377\032\243\275\366\347~QmZ\027\013\257l", 24, "\202\021:\372K\001\252\250\363`\260Lk\255\042^|m\312\370\200,Gv'\255\024\022<\357\346\002\016b\252\315,\303\374\247\326\324\352\254\322\250L\306;\315\311\374\264\042z\354\256\304\021BD\231%\236s\321n\236\251\022\006\262", 600, "T\024\252$\261\307\0362\033@Y92dA\366\341\204\33236\265\357\205\232\266\027oI\245J\272\233O\215\317\302\246\374Ko\204\270z\356\236\042\315\360\312l\231{\274\026\225\221\345\377\343MG\321\320", 64 }, + { "ew\357\210D\321\347\2421\315\323\264_\036\253\332^\253\325\271I\211\212\250", 24, "h5\202`\361F\354\312", 700, "o\325\241\254!\217\211\331~e\346{\211Z5\371+\353\334\134\034\207\213\243\270I\334\317S\312X\344\326y\217f\261\021\243\223\251\015h\022C\303\026\036\222E,\203\366G\362Sy`\3241\3205\262\265", 64 }, + { "\275\247\376Y\223o+\2440\255\024e\351\324_\203\206\326t\333\134\332J7", 24, "trXoC\241\333\350\3415x\210\356\307]\243", 700, "gyBJl\234\206\356:\023K\310gd\312\200\346\320\2479V\272\340\000\024J\316\362PI\271\263\202\022Yhs\302L1\234\037\267\200\312\3641\0171\265\217\215\205S6\243\222\300d5x9\306\275", 64 }, + { "\001\024\003\337\276\355UDd\202\271\302\262m\021\205b\021\234\3108\220\226\343", 24, "<\015&\212c@\264\015n4z\261\252>\355\025\231\363C\224\311n\313-", 700, "g\2301\253WQM\014\240kG#\037t\014gaF\007\234\317:\261|C=\344+\252)~*Pr_\037\376\013y,\377\376\344\2419\266J\227\260\2123\225s\344s\224(\204\024\344@\001c\255", 64 }, + { ">\030*\353\341\240\203\312r\031t\260\265\012\345\331\354\016\014}\306SI\351", 24, "Z\020\013K\254\006\0164\347J\264)O0^a\025T_(\243\025p\261\210j\203\260\233\026\263\360", 700, "\223\3078V\010{G\373\301\030Ea\340\335\315\251\237\257W&B@\022+yHu\2165Y\377p2\344\003\340\341\326f\134\262\267\253\037\300d\312\030t\030\324\211\032Y\255\257T\237K\332\220\310\307P", 64 }, + { "\374\310\024\302\321W\213\250C\252\275\336\024\341i''\022\373xg\007\247x", 24, "\3404>\007'\303\215\331\2719\357\362\010\2146Nf,\272\304Hd\226%\251\2659\252\336\224@\355\357W\024\322\265\341\355\226", 700, "\273\207\247\374n\350\247\030\2469m\313-'\204\200h\022\356\320\341\302\001%ON\343\244\316\227W\212\3252\317\234\366\275,\033\261}\325\350\341\207\203\306y\010\034{%z]r\350\206\201{\017\330|\031", 64 }, + { "\240+\274h}\2040K(f\267\320\015\265CC\337\226\200\335\032E2[", 24, "\240\266\274n\2077\260C\005\223\036\004\011]\322q^*3\276\235\226\320\027=\344$M^\227N\370\022\234\313\007Wk\366.\205\016\365\350\200\020\217E", 700, "\212\232\234:U\323\302L(\362\221\016[\270\266\001v3\253\225\340t{\016\226|EC2Jx\377\264hn6\331\266\014W\245\233\277m\020\353\245\023\221\016H\000|c\307\362P\027)5\323\0230\344", 64 }, + { "\030\307\267{\345\270MM\201\325\330:O\224f\313\005\311\325\310\210tJa\022\002\010\374\335S/\247\253\270\010-\205f\257?\330\234\032", 24, "\335I!\203\271D\364\336OF\220\225]! \362\013%Bsp\326\341\343\360K\267\267\367L\354\370@\371\035\227\225\360Z\205mx\276\371F\247P\344.\223\264\221x}\322\225!\346\350\256\2742\253\265C\367\377\022\036;\017P", 700, "(\036gv\030n\0139/\250P\272\313\230\351\226\211\363\237\312Y\037\272\311\265=\351\343\305\374_\246\235A\264YD\304\334\202K>\037\274\336)\301%\366\242\246D\324\134A\303\2414\276*\031Y\376\357", 64 }, + { "#\0427\244K\257\006l\005*\256m~8+\317\373\325x`\224.\320\221", 24, "\261f\203\226F\362\245\334", 800, "\267c\357A}cz\243\206\233+\230\256=\203\034H\007[\32169\375\366\322J=hG\336o60\336{\244\037\2775\326\243\213\320)\337\003\370\323Q\232\242A\306ZRT\016\242\242\350\372\015\220\260", 64 }, + { "\347\377\324\375\314\303n\375%,\010\336{\375\3320\227\344\2662\0024\325\365", 24, "\361\311\366\227\314\275\335}\213\1773o\371\231\357K", 800, "\273\267\010\210e`\307P\264k\012\345K\247\362\367\033\310=\000\225\035V\220\312\213X\314\341\273|9\325\275\304\241m\012EI\271\302\2747\331A~\177\032#\233\376\353]N\301\365^Mh\272.+\260", 64 }, + { "\357\2528\231\262a\032ZJm\3157\260\331<[\232\27441\372\310\267\036", 24, "l\001\255\324\355\0220\246E\206G-~-\333\004\331Y\026\363\303R\010\324", 800, "\246\354\213\206<\223h\204\367\333W\021!2G\376\014:\373\013\327m\225\227\336\250\342\221\310\321\363\253z\354\022uk\342\177\302\213F\3758\021\341mgESmN\257\356\014\276\344ju\372\332\361\014\011", 64 }, + { "u\267\0421[S\023km]\353\002\364\331~J\3503\376Ay\335L\012", 24, "\352\204\321\301fO\005\370g\003m\307\304\344\354:\030\244\216\215\026\331\262\2267\223\3655qX\252x", 800, "\011\254b\343o*\216\240Dp\215\015A!.E0", 800, "\375\240\241\236\314\214\274}\266\250\225p\024zo\012\354\220\377#_\210\001\301\343KG2\362\312B\335\331\304L\224\205\267o\320E\305\233G\021\031\2726iE\267\257E\217\310\313\247\312\232\200p`\266\375", 64 }, + { "\255\032\237A_\223m\000!7E\226\354wSZ \375\207\316\2177d\031", 24, "\324\234\005\333;6(\316k9\134\271r_\035p%\350Rm6\2418\025\204vv\212b$\321\027\314\250_\3478\233y\303\301\370\016\200\301IZ\316", 800, "\316\312\267%f\212!y0\237 \243\207\371\274\321\134\274!\327\362\004\014\210D\250\232\307PbslaL:\252\262\201#\315<\220\232\275\273\246G\311\333/\032p;D\253\235\2401b\016\224\215\134\341", 64 }, + { "z\006\205PE\271u\361w$g\362u'\134\013\240U\303\0055\305!U", 24, "\0279\275\233\304 \031Fb\231\224\204\276\203\021\011kM@\341\223\236+ \262q\337\212\376\222\3471\243\3615\333\247\340`7\004\3137'\263\231\302\327\3253\353\326VP[\263", 800, "\011\253 \313\264\371\333\363\017o3(F\001\234\207\243\263\376G)Y>x\271\332`\270!\250I\375V\300$\000C\206}v\345{\247\257\314\276\017*\365%\332\374\242\242\343\271\243\210D\200{+\254;", 64 }, + { "\367\212\237\347\371`\021\024\317\363m\366\226P\240\271~\353l\015\204[\350\306", 24, "B\343\221\021\345\275\004\353ZB\274\223t7\313:\233\255\233\363\361\351\014\315\314\325\343^\370\301S\012\212\317>%\022\023\210\352<2(\224\311\312\027\232\327:\227\214\230\363\023\037\337.\024\010\372\317h\023", 800, "\327\304K\020\214\277B\366\002\330C:n\353t\334fXe\351P\033\032\311M+`\320/r\265!\301B\231\350`\001\013\311c?\220\333\326\202\216\243\365\245^\245j\377\372\210\307\272\303\342\216\370\210\355", 64 }, + { "\212\264Q\307\376[/\236\013n\346\243\030\322\026\321\205\216\324\214\360=\370}", 24, "\202e\341xV\033\272\236\340\342\216:\016\2516y2G\267D\211\375!\247I\342\021\277b\031P*\207\035P\205\244\235\311\310_2\346\023\354T\004\304\327.\332TR\312\346\034\212\302\251\134\005\310\016\004\200\257L|\205c\303\205", 800, "\220\242\272\200\024,\341E\312\361`\270\304\345\016\037\273\273\341\301\134\224\316\032\003\324$(\316\234o<\250\263?6\351\024\312\042d\373\366\320\036Pa\015'nX\213\033:\313N{i\134/s$=@", 64 }, + { "\274\322\370Z\025\306%\003\310\201(b\362P\000g\264\011\212\340{3\244\236", 24, "\256e\007,5\002=\262", 900, "\005\001w|\222\320\330\021\015P\305/k\244+(\002\366\277\207\243a\302\350\301\227;Mdc\250\024\370\006\311\007\226\302\037o\367Wg\377q?k\005\223u\021\036\375U\321@\363\232\317\363\225\177\3303", 64 }, + { "f\247\021,n\027\321:\311Y\243M\345.\204Qe\302\206\301(\205\031\235", 24, "\037^\213\344\352\177&\134\004\203\203{%&\027i", 900, "\253m\201\326M\344} \345K\2152,\245a\255\306'\265\353\216\011\217\004\207Y\271b\234\222\230m\016mu\340\231\035\235\215\3413:\004\332\015\310yR\260\023b\206\000\230\007\314\214\370 8\011\210\313", 64 }, + { "U\257m1\225~y\202\247\245\346\262\261&\252\253\261\375\022\303\247e\351\342\321\260\237\275L\220^)\3519\017\261\013\364\243\037\030\277\375MkIo\275y\004_j\241", 64 }, + { "\367B\325\214\226\364F9!\304<\320{\342kg\315I\315\023\316\372A\336", 24, "\240a\265\361\241\204\221O\347\345\026K2\336a\357\304\037F\311\341\276\216\343\360A\334\014E\317\265\203Ik\346]\317\031\272~\365\267ft\241\015\350GX\235\021\037;\024\033\354\2124J\337\377\304\203\250", 900, "\202\242\3013\2208U:\340\237\377\261,\312\016\251^\260\271l\324\213\034\311j4\011\236\254\360\251\341\347\310{H\017\320 }\232\274Jg{\217\324\257\363o\357\344\026\026G\277\310\004\242\235\263\357-\222", 64 }, + { "\016\270E&%\327f4\252\212>4r\344d\252\234\271'\254S\324\352\350", 24, "\375\306\361\014e1\036\264\033W\024j\367\214\265\027*\201\337\333\233\275y?\027\270~F\274\346dC\364w\211`L@\364PCo\257)#\346\343?)m(_k\252K\375\275\003\3456\376\2240\036\360\222\373C\265\217\322\251", 900, "\302\205\312\343Gl\252\336J7\013\234\355z\377E\3711U\311\204\213\332X07Z\222\333\017s\351k3\333\370\273\352\361nvB,w\315\202\214\327\367\351W\3560\350\377\016\2111\323\315Rd\360\241", 64 }, + { "X\241g:\042LD\026\033\305\2103\347%\313\222M%IxT\3311[", 24, "\354*\024\334zTk&", 1000, "TW\205I\026\261\327\304\271\241.\340\134\260\241U\257\312\000L\177\012\002\020c\266\333W\352q\331P\336\027\357\363j\356P\3036y\357\306.\361C\232\134\245[\366\203\213\307}r\255\350\324~\330J@", 64 }, + { "P\273\256\313\320\002{\007\246Q\235\261\314\225\325f+\265c\221f3\037|", 24, "\3772#\270\014I\036\251\274\343\270*\254r\244S", 64 }, + { "~\021+\245uZ\362\213\366\200\022\206\215\334\351NYt\355\377{\353m\027", 24, "\2447u\244\364\217\330\177\207zVy\210\026|h\302\255\343\012l\034W\235\214w\263\270\256\236\255\312\134j\272Z\350\134v\357", 1000, "\323\021P\223\322\235O\310\243\376\254\014W\021\250#\357\307'\305\362)z\177Y\177\354w\265\015qzf\333>\020G}\011\355\350O]\253<\221\251A\013\315:\023\201\267\010\210\372\277B6\241\244*\314", 64 }, + { "`\216\220\304\345\323\032\361\230\006\373k\0015w\247j2xL\303\242\021\301", 24, "\354\314=\001]\034\307\013\035\250P\231Pi&\031\205\203\027Y?\360\215nEQ\021\336\373\215\332O}h\264\207\253Ah\377\376a\264u\251\002z\252", 1000, "\321=R\262\037DS\377\205\222t\316\371\353\206\267\315\313\246\364\3673\010%\224\351\307z2\230\360\273\220\311aGp\2636\015l9\300\345\003\326r\356m\203Q\235\232O\227 \352\341\021{\267M;E", 64 }, + { "\354\004\006\232\301c\330+\321\346{\032\251+\226\274\273r\2126K\000\000\320", 24, "\244\371\011l\010r\042\231\366N\007\354\251\304\237\021\200\314\321d\330P\027Jgm\022NQ\015u\354\016\023s\363\0059\003x\243\366\361'\375s\330\266\310\334]\350\201\037\330\177", 1000, "\262\340\313\343-\0366\257\034\321\223hwX\317D\305h_\036\012\323\303\360(\016\014\351\244\256|;\031\316\355\317&\244\221\374Do\370\351\372\233\344\027\237x\225\212\032\026\321>\203\335{\263\343h\254\245", 64 }, + { "\306\321\026\304\337ii\326\313\346\326Vw\314&B=\233:\237?\221\201\353", 24, ")\344\304\012\2374O\241\033;\035\3024u\021\243\347\201\314\277u\304\210h\252\022\241\237y\031In&\3374\356\315b\214\004\277\370;\330~\237\335\262\275[\373\3121t\005',\211\201=I\321\216\334", 1000, "\376L\243\307O\223 ;d\203\232\017\217\324\246\260*=>\377\373z8\226\237\255\341\320\342Z\301\015m\363\005\201X\026\202\221\017\351\301\003M\366J\031\263\035\001{:\307R\026\356\367Ww\226\2106N", 64 }, + { "a\201~E\177k^\377\225\372\322\254\303%\007\300\327\315\250\025\257VA0", 24, "\270SB\012l\322\243\037q\035\317;\324\307\324\351\347\030]\245\265\366X\2650e\322e=P\205R4\344\245\227\221F\272\356\034&\323&\022m`z2\275\303\266:\207\212\213U:,\035\227I\275\347\257\023\211\206\211\324\377\364", 1000, "\224F\035\020\272\0235\366!5\234\200\355y^\042+\321\275nk\247\366\034#b\235o\214\277\020\375\344q\374\035\261\263\222\246TI\221 \240u\232[\214\346HB\221\322\003\377r\371wG\025\035y\345", 64 }, + { "(A\2328\302\034m\303m\265$2&\227\250\016Q\3779\275,\313\013h", 24, "\250\337%\227r\334&S", 2000, "\241}n\035\312\202l\273\322\352\272\252\212)\335\230\226\325\012\362eE\004\315\357\177\245'\022\0052\244\024\014\225\227\007\243As\277\251\351-\262\246u4\312Z\214\274\202O\376\324\262m\035\201\360*\343\006", 64 }, + { "\224\227\346\024\316\015\012\374\275#\026\307#\012\262Nr\313\353+ \216\372\032", 24, "t[\215\345V\325<\254\367\361\255\343\245\023\017C", 2000, "u-\242\357\275\260\2226\270\312\037\230\275\372rS\327\216l9\316Q\356\210\323\210E5@\217\347\036\032C\202)\033\230f<\227\023\256'o\233\247\006c\320j\244\341\020\134\177\313\177A\214\336\215\230\322", 64 }, + { "b\247o\224K\245\234t/\302\265\264>\310\225\024\015#\255\227>\225\022@", 24, "\211e\230C\273\3177\2211j\365\030\320\203H\255\017^\256\324S\212\266\372", 2000, "\302\004\0071\000\034\042\360R\205>\020.\016\334\042W\230c\250\222zs\337-\377\373r\333c\001\371\272z\363\0003'\362\202raS\244V\354\377\344\336$\201\336\322\372Uqy`>{B\021\234\030", 64 }, + { "\002,v\342\377\027yk\360b6]\032eS\242\353\011\353\204T\307\207\022", 24, "\236\177\303M\345\365\027T\017\323:\360\225z\271\361\220\265\017\300\273\030\223\2531U\316T\020)\225\375", 2000, "\340\214P\252yt\0126\301i\3054U\217\267\024\364\035\306\003\376!/\345\374?9\250\207,S\031K\276\223\257\364\346\367\241 &\256\271\314-:\272+n\367\023\272\311Y\346\004\225\315\016\236\205\306\350", 64 }, + { "\004\000\227\245\266\231UzT\033sW\240t\234\004\356\320xazQZ\033", 24, "\257\341\327r\023?z\022Y\205t\302{\252\341\027\341\333\260_d\030\206\354\367\026\302*M2\225\347\336N\253\251&Ad\276", 2000, "\353\364R\036\042\354w$=(^!\317\207\266\342\212\215\263\250+\307H#P\011\3448'\212'\030m\037V\021\212\375\3601\311B\233\361!9\036\2135\034\337\264T\331\346-k\222z6I;\303\360", 64 }, + { "\015\213l\014\376\305F\340\317\356[<8l\000\235L\361\327\3623\251,\032", 24, "\356~\011\332\242\011\203:\271\222\204xV\274#\0064\016\237\364[\377\231|j\031\336\272Q\007\331\371$\010\361\231\346\205\337\340U%\230\241\221\202f\267", 2000, "*\230O\020\204]\354H\245&VSOk\247\352Jd>\243\322\351(kX\302c\177UhS]\001hq\245K\320oB\201;\335 %\3164\256\024`\233\273\256\304\324\247\321\345|\023$?cJ", 64 }, + { "\203\371\026\261\020\021\004\370\246\244o\321\365\355j\004\200\367V\304>)\355\300", 24, "\260\347Jg9\373\303\270u\270\253\343C\300\336\010\307?\016bu\366<\334!\312\337v\240w\177[j\227\224AU'\037{\032\245\347n\343\011\370\342o)\214\354\265\236\234B", 2000, "G\345\0377\201\012\226\231\207F\224\006\035\236p9\303\365\3250\223\226>,\313\330d\317\237\312\3238BN.\257\0155h\377\034\236\331\223\037\307\3416\317]\203\302\252\356\234\230^\027\220\375|\0341\006", 64 }, + { "!\323\234\201\027.\265K1\243\334w\375W\367s\264\232]^\011\243'k", 24, "`C\241\225\020\3131\226V\311\257\355\361\313\326\304\003K\206\266\311L:\327'\370@\317U\300\027\207\012[\246h\247\004d Re\027\247\222\323\212\225\324\020v\252_\252\255\361\367\303\020(b\015\346\336", 2000, "\332\363\361a\364\375z\356\215\366N\256\330L\022H\2644\134I\362\373\310\212\213\262\326%\366\351`)\315\014\356a\266\037\352\262\236\365\326z)uU\374\364cq\307=\331\013\316\243\335\033{\273\244'c", 64 }, + { "\263\266\230s\247\032\243\235\271\203y\245\243\012\276\015\230C\230\262\213T\346", 24, "4GO\256\202.5\272\256\313\017\307\220\252\234E", 3000, "\223\021;\244\350D\254W\275\346\222\261N:\235\364\316N`V\307\134\004\037\005m\332\222J\324H\020^\325=\233\356\350'!\035^\245\025\263\022.\272\004\254\342\243?\010\011k\224\331\331\2322\336R\242", 64 }, + { "\237V\216}VW3\357\037qC\305\317\207\302\220\351\331\037\375L:\022 ", 24, "\336\277\323o\333\220q\304\274\313h\237|a\327\323\230\261(\371~\020\327d", 3000, "\211\017E*\360`\315\036-Q\374A^B\343\020\200y\034\177U7\340\260\371?U\221\323}\321\212\261\255\3411L\246\315\334\004%K\01749\207\341\027\313X\230v\300\032=\304\340\307\240\005cu\036", 64 }, + { "\277^\326\265S(\042\033\000\346Y\234M\000\310\025\344\3171\343\230\017s:", 24, "j\301\025\325\364\345h6p,\377h\322\372[\215\262\261\235{\355\352ae3:\042\337o^\270\226", 3000, "\367\314\334~\313\305\216R\375\313\317( W\2524\237\367t\006V\356l\270\305\025b\351\372\016\205\274\032yn\321\366B,Z\300\245\310\364\202\374\336y\325\015\221\342\343\223\254)\340GH\354\021\235u\354", 64 }, + { "oP\0024\027P6\376C\272\232\025\207\225\3616\361\26629\313\004\375$", 24, "\031r\357\216B\274\223?U\2367\002<&\2615Lj\012\276\303\327~\373\314\373\3762\010N\177\231\324\036n\334`\317\013\200", 3000, "&\322\212\306\227\365|H\226f\313\2425.p\030V\261j\350|\352\205:|L\316[\023\305\222`W\264\246-\232DO*+\343:\241\251\320\233\354\377\203\246\235S\027\341\250\316\327C<\226~\346o", 64 }, + { "O7\204\017\015\252\361\327R\030\367$\314\307\217\207\252\323\333\270\213\207]0", 24, "'\234\271/\326l\237\264-\337%\332\012n\372\276H\262\134\263\336\213\337\021M\234\321Q\227\333r\266\304XS\343\211\256T\322\303\234\211\260\241[\037\271", 3000, "_\203,Z\033\317!\350W\356\335\2426T\015IE\012s\331~\301D\012\374\306\235V\321p\340$\353\263\331\237(76I+\000P\342/\001N\345\313\241\214\377\333\377\360Z9}\3544\236\201\370\351", 64 }, + { "\244\350\3759f9f\300\002\015\214P\344\022\200\351[\134RvR\363\225~", 24, "\204\253i\244\217\223s=\217_\313\242\024<\252\241\3530\215,\212^\335S\257j\331\003DNLn\2414\035\017,p{\364\360\342U\032\254\007\021\036\256\345t\253\316M\021\254", 3000, "F\264\340\263\355%\367\007CHC\304!5o\030K^=\305\204P\305gIJ\274\177s\232?\341\000\364\014>\214n\236\004\363\250\323\324\211g\025\371\004Y\357c\351\033(O%\312\267\214\313\001\003\274", 64 }, + { " \373\314\232\000\2625\230_\303\350zD\210\252*\034\305\005\017\355\356\227\270", 24, "R)\032\244p\363 !9\274-\205\343'\231)X\346\025E\323r\032\357\024\020Fr@\013K\221M\376a\336$\024q1\310zU\031\271\274\325(\352\265\017\042\210\016\276\271]\330\252#\244X\261O", 3000, "\241\362\014\177\002\312\211G\001\312\001z5_3\207\232\300\227\245\201J\255\376n/\177(\371x<\303f$\353\210\014\232\232[\244\277h\353\341\022\320\325\002TF\352\037\264Tf\2676\370\271\321\363!\307", 64 }, + { "\333\025O\227@h\274\2608\237\300\004\377\223\022\320\341\312e\202`xN\263", 24, "a\042V\324\255~rU\355\206\366\202\005\354\002}w\033\215\266\010` \215\226-@\231\246\376\340\010\023\015\216)z\221\365\327\372\262\203\035j=5\265\243\242E\035n\036\014\0177\367\205\237\363\031\346\264!K\357Y\350d\375\373", 3000, "\003\242\243\204\364\011Z\213&\276\020\270\364\204\275&v\013\015?/d\352XM\302\306\371\242l\360\033/\247=\277c\331:\021OUK\262^l\270]qh\242\257b\213TJ4L1\364\366\253\201r", 64 }, + { "(n\026\312\205\343\005\033\363+;\013\305ww\340`ET\312*\2063\371", 24, "\327\336n\263\257uk\336", 4000, "Fj?_\352\260\304u^\354\210\205e\025_K\026\277\346Vrq(\224n\204\371\024\221\021dc\360\030z\270eu*\203\365\336p\32321\305w\347\245\265\337\212}S\302\247LR\377{\002\203\235", 64 }, + { "\275\277G\270\316\265\317Y\033\321\261\3341^\036)\235\253\253\274\014\227\327\374", 24, ":\311\227\357\355\353V\261iP\265L\354xr\262", 4000, "\021\332D\300\265\336P\356\226\215\014[=\000\234\027\224eX\022\260P\220\207\315\274~\030(e'\314\134\256KX\015\022\361`\315N7\021$\005\213\027\327\230\300\212\246\267\010UF\322}\260\276\006[\273", 64 }, + { "e\3241\366\225:\037\220p\032\242\346\364\341\237s\332\235+\033`\007\333\260$\241\007p\013j\007", 24, "q\326\233\230 \340\376\340\330\241\255\270}Qb\037\331L\363\243\021Fe\012\204\210\220 \246'e\323", 4000, "\233A\343!1\343\230\230\201Xu\272V\314L\330\204\217\301\265\376Ph\035s\321\253_\303\224\201\262M\350\365\375\302\325\217&D\234\314\320D\210S\370L\3674\217B\311\251\313\237\243\202)\030\022\307\336", 64 }, + { "\266\015\355@-\222\245\034\2232\353\327a\326[\223H>\212BBP\212\221", 24, "\207Q\350>\367*\313\020LH\353Ap\025/e\240\033\230\221=\367\325\243\326Bp\037KHzi\302\017\247\254\306\375@\346", 4000, "Ii\225\355?a\327\357\035d\007@`A\307M\214\027\304\205\376\343\2641.\325^\336\030g\275u\351\333_\205@Q2v\255\263\353O\243\006Q\243\303\031\252\252\036_\020\3739\202\307\177C\314{\271", 64 }, + { "\362\272&\200\012\014\365\001\341\023T\232,j\201\202\324\0042\256h\377L\250", 24, "=\013\254\322\351\270\307\341\322\310Y\262\211%\357\356\273\233\346'\265\277\350\313\342\263\244\017\361\005?\033\352\374+\305\244e\270\232$bB\375/k\355\316", 4000, "\222a\254\336Z1\3035)c\302\226\031v\216\345qr\234\247\211\134\004O\010\033\205\221YR\313\365\034`\244\276m8\204\255\217}\333\013p\017\307,\245\270\344~\037.\027@\243\3008\226\346\364\004^", 64 }, + { "g\027\243\247\030\210\246\017\355\022\306\212\347\226pup\007v\374H\261\006b", 24, "s\006v\241m\353\271\320{X]\346V\027\345\331\360\017\302\210\010\213\243\134\361`\235\306\265\036U\025\264\373T\373\324n\033\226\037\252\031\340s_xtA\310\335a|A\252\274", 4000, "l\247\361\333NE h\255\336\021\374\356\327}\347\314\347lZ\336\335\377\341\354\342\206\317\310\036\302G\2039-\374\005\027\204\313\304\340\334\032\032z{S\273\330\1772Q\220a\201\260\264\312\222\003\317\034U", 64 }, + { ":\243\340\307\302'\256\134\326\301W\356]\307\3327", 5000, "\205\254\255LW\275\210\264\205a\214\001\323\312\254\251\233%O\222!0\037\177\274:\212\357\354`\005\335W\254\265[\275>S\243s\225\032\341\313\214\321D\177*\246\001\366\005S\234\230\010\300\301\024\337\3777", 64 }, + { "i\347u\243(?];\2174p\027|w\252\232\374\252\031\360\013<\244\313", 24, "U\204\031A\265u\316;\325\340\215C\340\026\245\366\027V#\3607\320\223\315\352\364\316\240\020\276\034\342", 5000, "p\216\236P/^Q\034\303A/:C\012-V\363\242J\370\310\265\333b4\2267\177!pX:e\306\242(c\325\033\306\315\312B{\311\026\250k\026\257\207\217E\306\013\246>:@%\203\272\001A", 64 }, + { "#E2\2447&#\202\264\042-e\346\315\327\212S`\354\357T\373\374\356", 24, "}+\227\036\352<\035B\325jB\225\343w\237\034\206\255\235\260\233\336\204Sx\216\317\202\001\261\242wb\035\352\304\235D\221\267", 5000, "\242\246\366\007v\255\267\332>O\332\005\024)K>f\350\031\325)\224\236\277/j9\373w\375\224\207\327B\321\354\265!f\373\013\375\024o\3768\345c\351\202\305~\366\221\301\237\3504}\215\313\306aK", 64 }, + { "n\342f\266\256\206\242}}3\011Iw\350\264de\356\210\365.A\357I", 24, "\313\366\372-\305\017\251\134\366\265\2732\304\203\300\275\224\300\314ZKR\016\260\363\273\014\255\344\304kW\217\275\021\357\334*\342\022\243\312\303\265\016OM1", 5000, "9H\012\364@\023gk\224\324\007\340\017\215U\013\247(\006\007\305\335\006xAp\372\343\267\322\355\250\344#385;D\342\310Q\030\214\271b\275\265S\246A\020\247\030%\233,$C\267\334\036I\020", 64 }, + { "p\224\002t\321\207- x\331MZn\352\042*\220Cv\230\303\244u\233", 24, "DE.\236\2209#`\026\303\274.\352\300\310\230\216\032\216\214\307\254\024\253\317U\033b\327\3532\033\231\370\344<\376\013-\330\0032\260\264L\012\305\020\254\356N\375c\333\010\236", 5000, "\324\235\2268\20247\200[\222\042\315\006\244\002\207\367h\31422p\371\205\206Y\202\331\307V\227\210\024@\002q\226\225\345\305`iwI\274\334\373\310\345\330\271\226N\331\242\371g{\231\266\035F\330\263", 64 }, + { "I\2423\320\015(\222H\242\017\252\211\353\375Ja8\033\340\3765\314\322u", 24, "\346M\375k'| \307\351{\221\376\304T\026\0058)!\025\306\022\271\227\032G\254\200+\201\033\021e\032\334\002\301\317\201V\3658$\042\266\362\216i\217\266\021Y\312\017r-\354j9R\022\037\321)", 5000, "\224I\371i\265\005\262\257\262\253\373zV\250\240<\311\201\257\362\222UH\340\367\200Q\212\017\335\251J\020\002\341PB\202\030\022\017\277\032fT\256\013\266\355\227=\224!D\371\225\240J\215w\002\255>\300", 64 }, + { "\205\027X\235\021\3344\2458U\361\222k\375\353\370\226z\3140\321v\353\026", 24, "\254\365t\304\343\317\275\254\0273g\241\003\320C\326\264\034Ep\360\267\273\2332\210B'\222\210\303W\202\021\364\246\302\320\236\256#\3074\324\313\216V\231\242c*\003\2345l\0365\353n\347\276c^\366>\257\215\227\215-R\207", 5000, "\337F\336\013{\253\267\314\001wC\321\201G\344", 6000, "\226\341q(.\361\024R\272\037\201Z\202\300\271\002\216AM[g\263=\0039\034m\250pb\235_\205\3468A\007\213\276\366oK\273]\277k\010\011#\255\264V.)m\032_|\372x\230mnv", 64 }, + { ";\346\354\013\230\227\031F\357Nz\350\262\002\025\305\013\337\377\332\350\256\014\030", 24, "\222G\375\327\177$\353\274\353\357@\007\026\356\266\303\240\370\271\241h\241\003f\233\0061=U\264\177\320\311\312\334\036\031\025\275'\324\341QQ`\277A\347J|\012\3315\243\230\217", 6000, "\332\363q\304\333D\240\347\241\032i\333P\231b\271\344\317\024\355\314\301\267\316\021\237\321`\013\215\202l\365\330\311g\235\247\232\361\336\257\206,\321\317\330\006\253\233\302$T\357\324\035\241\0316\030\036(\204\251\331\376M^\2559.\225@\0110[j\201\350", 64 }, + { "7Y\231\310\325x\221\333\3057~t\254\265\325\335\247\326\227\363:\134\355\201", 24, "\340\341y\031.\267\217\264\012\020M\250\347\274l\311_\255\361o\232\260I\342", 7000, "\202\267\254}\0042\357\253\273\261\022\024H\020\203\013\032to}\347m\337\376\371$\250\255\321r\016\006\274\367\311\323\243^wsG\237Vw\004p]\325\261\365\027\356b\230\205\322L]\021\203\371\2709d", 64 }, + { "\177\335\200\3270AM\247Y\322\010*\234\035A\261C\366n\036>r`l", 24, "\214\014\337\257?\303=\024\240\307\343\00255#\326\0235\267\327K>\354\375\211\321b\021[i6>", 7000, "K\000\352K\222\245\260\275\361\361o\365\326\364\036\2770\207\331 \312LL\350c\006\226\247\014\217\217\261/;AP2N\327\343\013\246d@f\250-\364\304\013\002\314T\032\025\247\017\217c\366\003\305\037\362", 64 }, + { "\200s3/\021\217F\036\305x\321\206\215\004mk\314<\000\300\226(*\244", 24, "\247\250\3112z~\236L\327\215\003\367\022\244\217\201\373f\010$HE\221\026%w\326>\033\017\226\020\207G\367\352iL\322/", 7000, "\311\374\230\374$\026\042\360\254\307\307\252\207ZP\232\364", 24, "\207tG[%\035\246\377\337\325\331N\022~\365\236/\304\201\374\021@U\372] \226\375\037E8\007\254\354\370}5vZ\031\206`\366!\322\366\342^", 7000, "\245\210\355\305?\007\012\026-\377\272\025\2700\270\375T\332iM?\216$tT\216.}\356\005ExPe\005\262?\223\226,O'\365\000k\246E\202\021\213\324\035qRg'c\024'\200X\026\240o", 64 }, + { "\021\300\216*\364\017\360\1340\321\362\221`G\234W\363\333h\324\216b\217\307", 24, "+E\251\013\223\005\246S3R\255\016G`\212\214\246\352\012t\353\324\237\230\242\241c\227\021\374\316#\260\351\317\0252\243\007\002\346\026\237\023\216\3117\344S}.9\274\203h\371", 7000, "\362\315\306z\261\307\255\373\276u6\243\021\347\234C\370\206\306Bv\257\211\347\242", 7000, "\033\256\213\370\341\215jM\215\216\262\324d\007\316\365\227\371\2034\134\272\012\206h8\212\253Z\027\314\305\017z\371\010\216s\343\313\277{A\262>\312k\376`*d\300\360\2516\241:%aj\215\242\275\375", 64 }, + { "2\214\342\377V\332?\2433\233\177\347:\352\242\364\337\340\331X\237\257}6", 24, "\320\326\244\261\006:\026\037p\252$B\205\265\036`\362\327%w\241\271\317\367\004\026\215\364\260\023F\3245\220\276\367\347\260G&g$,\2219\015\177a\224\211\313\016\346\027+ \011\354\017`\026#>a\327\022\372\177|_\023\231", 7000, "\332\3414\351\013\042V\243\371\033\321o\023\023m7T^\220X\343\300H\010\306a\307+9\326\315\323\226\032\205\030\024b\371\365j\220n\014\312\024\003p\345X\017\341=\321\304\205\340Q\300\362`\307\314\365", 64 }, + { "55v.A\333M\011\253\244\245\331H\317t\353\235\243\306\200\307\241\330d", 24, "\301\032\244\327Z\351#\344", 8000, ">\334a\343\370\316\221c\363\253\306\042\325\007\310UU\351g\340|&\203l\034Q*\36754\206\134\264<\341q\342\332bg\014\000\301}yR:pI\342\301\343\250x\232p.\373\211\033o\016\015\300", 64 }, + { "u\034\247\2249\312\031?K\134\367\227\373\015w\005\303v\375\311\227Y\264P", 24, "\347\374w\031d0O\321\342+\036q\026\015+L", 8000, "\000\307\323\245\336\306|\361i\245\221\003\013Mn\233\211\227\230=\272\211Ybv.\007\256\244u\364\350\201k\274RA\022\327\212\325\234Or\0137gx\340$\365`\355\255\3310r\205CF\246\3554\003", 64 }, + { ">\372\324z\264\3456\210u\275\205\315\302%$\323\023\204.\245\305O\266\215", 24, "\210\036\242\335\310\002\367\363\365\034\003\030\207\017\007\022m\0369Z\322\032\272\213", 8000, "wO\311(\236\027@\354\006YJ\353\207~\360\237`Y\316\242\247\307uz)\307\023\267\262\340\007\307u\2256\0220\347\1774\274\042\271M\335\026D\342`\356\004\255\2702\21587\0270\346\310\231\303\215", 64 }, + { "\205\015pw\204\330\315l\327UI\003\134\005\033j!\202\007M9\030\017\257", 24, "\243\006_`Ge\333\270\232\361\256\305\266\204\351\231\232\310k\230}\035\225oh,F \177\213\3508", 8000, "|\206d\356K\204\337\023\357\324\325\377U\314\343\001\177Q{m\277Y\3232\347Z\264\343\032b\367\337\204\347\237\340\220\000\005\240\015\256\207\240\266\020{#p\216Kd\031\245\266\237\366\327\003\352\20096\270", 64 }, + { "\234\317\267X\261\316p\305\317\270\037\223\364s`)\266\360\255\372Cx\034\344", 24, "\037*ZQG\262z\310\302\331\247\036\355\331S\227\271\245\240=K\342\360}\015o\376\275\353\370v\326\011\352\366\011\035\346t\315", 8000, "X\246h\312\331\270l\217;7\371z\357\213}\021\200`\035\335\277S\211#\024\257\253\367\270$\306\334\346\236e\030r\031\356Z\314\340_\237\242\025\134\314z\360\216\020\337\205\272z\314\036L\216Y\217G>", 64 }, + { "\216\336\334\260\010\376\034\330\025Ilx\217\376+\341?A\303\320\212)\242[", 24, "\002\257\245\0163\344\244v\375\344\023\272\244;\353\242\371|\010H\337(\200ut\252\252W\260\256\355\251\244|\013H\257\350P\003\210\330Ji\026\361\230\313", 8000, "H\320\325\372\034/\365\265\000Z\356\250\353{\205\202\247\006\313|I\032\013+F\373\270\134S\015\036\3443\240\376\334\3018\3343h^\344\200\243\312Nk\264,\302K\365\267\315\346y\030!\020\313\373\241\272", 64 }, + { "\364[\025a\015\244\351\226\361\277\362RnY\016Vg\011\004\032\0243V\334", 24, "\303\035t\266\010\251('\331\304\035\276E2\030\216\305\330\026\3153\271\227szf\361\307Jg\217\003\200.\031\034ga{\247\042\021VG\262\216\264t\015\006\014\232\236\300\335\360", 8000, "\373Ng\266cw\232\023\340\345\134(\241\223\330\251P*.\251p\023I\216\222\016s\274\2610\2719-QX\017s'\364\367\203[z;\321\275\367N]\016\205\216\032\246\351\013\014\230u:a!\340\344", 64 }, + { "\036-\324\033\321\251\200\377\035C\2173\352\252);\211\025\316\215\375\214w\215", 24, "\300\007\353\005\230\026\313\261\017\376~\245\312\375R\275\336UpX\223\261R\321\012\257\305\361\354\305y\016[P\026\302\367\203\210\222\320\267\341A\374\323Lk\237\360\277\303\226v\214\362\372\303\363\2325\032Y\216", 8000, "G\277\034+\204mQ\037Jh\3735M\226yb\271T\333\216\320\233+\3414.\010\243\335\030vR\223r*\272O\263\222\310\204\366\266)\037\012o\344\333#\027\260\037\300F\010f\336\236\236\367\203\213\222", 64 }, + { "\266c\307\213\340;\202\254\364tO\370\023\221\332\006w3Q\352d\224\000a", 24, "p\035\261\247\274*,[\341\236\263\237,\272\361\301\232\301w\203\023\024}\265]\313E\203g\364\247o\005\134Az_\007G\007\010\220;\326RR\216\262\025\200\255\262>\330\321\276\316\331\356\310\334(\241e\345D\263\330Gx\324\325", 8000, "\253h\230\377\267\373 \214\322-\273\273~\336\356\177\024\205\277\240\277[\227\023\332\316\315\374\000\272\351\357Z\011\021\300\377\371\376o\223\336\235\312\021U\330\257mz\250N\206\210jB\134m%\276/o\357\354", 64 }, + { "\245\221f\320]\012k\303\031\336Wr\336'kl%\250\3559=\266P\274", 24, "\243 \351Hp\230\003\351", 9000, "Z0\012\276\353\351\232\246\223\035\333\243S\367\365\272\376;\035\314\004HG\030\213\275yU\355\005'\341\134\002O\014\310\134\21217\020\011\317\311\032\031\317\355/=h\201N\305\243\232\300\354\342\005\206\216\200", 64 }, + { "K\213x;{\306\322N-=\201\352v\366\255\013\005\012\221\2142\336\014\300", 24, "\200>\242~\026\241\226\204\221\351\213\303\223\237*\345", 9000, "\273\325T\251\032q\370\2077\310\220FF9e\204\342\226\374\247BP\370_\273\024%\314r/Y\270\231\343\323\353A{r\334\013$\315\224-\226\272\276\244x\337\220d*H\021G\307\271\347\251\304\360a", 64 }, + { "X8\022-Z\303\263\357\3236\371-\322\352\212}\226xVF\200KH\271", 24, "\352\321\241\333\217\016\012\344\245\240\216\017-\367\340\324\260i/\320\377{$Z", 9000, "\363\313A;\203\243u\267\276\002\327\036\2234\323\217o(k\372\333\023\240\221\300\254\2677\234\2040\300\350uv\327\371\262\215\272x'\213\274\010\021\034|\352\3338\353\273\027\272\265\376n\134\210r\300\006\247", 64 }, + { "\335y\005\355Q\326\204\360\222$g\356s\374o\200W\011\220\001\247\025'u", 24, "\035*\242\310`G,\244Q\372\256\301\305p\034\271)t4bW\2076\225\177y\335\322\317\245\256&", 9000, "f\326\017\227\016\302R\363\324\314\010\271\320U\341Y\222\370\265\277z\370\313\303TA\334b\371\226\254\264pq\336^D\330\134Q/n\324\320,`ay8\203-\035\223\351\301%3\032\355\217<\233\256\236", 64 }, + { " \250t\357\202 ;\3730`p\201\373k+r]\354;\370\244\030p?", 24, "\363\217\315\313~\351\231+$\215\216\362W\26569\223\027\300<\252\336=?\320\015t\333\004\265\316$'Z\010\337\032\300\356o", 9000, "\013\263\374\335\225\200S$\237\251\312#@\227@iE\373\364tpE_\342\203\204\364q\350\333\215\237\345\262n\217X\023\020`\257\327\257\236a\273\007\271\020\213`9\363:\011\240\014\257u\013B\302\365Z", 64 }, + { "\037\211\342J\233OL\256\313,\272\317E\355__\006\211\354\343)a\326\366", 24, "\3069v\303-\210\007`\270\242\024-\010\203d\242\210\250\347g\031\343\265}\035\317WY\2600n\342\263\317\300\010\007A\023\313\311\320\361Y\266\206\326\256", 9000, "\037\232\322\324l|\277\265I9\377\203-F\026`\202\206;f\256-6\312\374b\0152\016@p\017\374*\250\213\255i|\274.\326\364y\336}@\252\012\377D\202:LL\274'\010\222\304\265\360\324V", 64 }, + { ";I\027SS_\355\250\257M\025\034\252\332C*}=A{S\012\267\020", 24, "h\324z\036\2161^\373N\027iO\210.\344\361\370\213\300\274\204!q6\277rja\216tk\243\371#\353\201\272t\312j\206+L\005*fh\033?B\323K\213\300u\310", 9000, "\323\004\241\010\242'?&\207\347n\2659\262c\327\356\373Af{\363k\244u\315\271\257\215\002&#\350\244\253\345\004\362\245\341!\370\367\235L\324t\325V\232i\261\177\3241\010~\310\347z:\263\177\211", 64 }, + { "\331\363[@JRZ\206\223\334\330\027\234\035\3774\273l\316\322]\310\212`", 24, "\250\0109m\246\376;\177\2612T<\274\327\2363\344\324U\343\343\340\206%;\347()\364\322}?\376\214?\246\361\005#\273\020r\200\260\3608\335\217\017\202\212F7\202\325\353\323\367\305\034M\033\303{", 9000, "\205\373\010\365Z\241;\3701a\253D\025\351\374\254eX\244\037?u\372f\346\231g-t\274\325h\030\365X\363\322N\011@\270#\027\212\271\307\221\302\275(\033{\221\270^\264ku\017H\367H\201\002", 64 }, + { ".\354\201\342\256\244\227\276\215j(\026Va\3359\206l\377\020\253\376vu", 24, "\014\346\240i\217\206\263\300Aq\336\242;,,\240\035-\253\3070\367B\352\325\042\366\351\013\200\134\372\245\227u\233B\212\016\244.\021\362!\214\221\016%\224A\231\004f/\346\343|\007\3014K\334\015\2660\302\332\243\330\331\277\225", 9000, "?\341\377#\006\027\300O\217\020\267]\3708K\301b\177Flug\301\212T{\304\255>\260\357\266\2368\336^\134\326\335\0268\357\214\230R&&\372\223\315\212\374\341\320\234\224\203\017\310f\254\017\365\371", 64 }, + { "\035Uw\245\207fy\341\213Cf\313\250\356\333#\365\330\025\214V\365V\315C\301\312A;\265\324\333", 32, "\237\306\371M\211\275\020}", 100, "\277\325\220\301\016\372\256@NS\004\207\201\3778`\215_\211w%.\337\374\353\367\220Z\272\373\326]\275\224,^\036\311a\206\211\260\005\317U\0154\001\237\273\305\316\033uu\251Q\213z\351x\036\243\265", 64 }, + { "I\333\366\014@\0225Jgoz\373\270\002\020\037(\012\177V$\232\250(\264;\320\371!\324p\235", 32, "p\340\214\234\324\205\224\324\020h\221\357Ej\330J", 100, "\317]\000c\226\304\271\261\023h\365\3636ZV\016\353\356\222y4 \340\013\223\223\301\356<\004\234+\300\201V\230\370\375z(\177m\364\306\351\231s\254\360\227T\351ebLA\316\207\011\273\353n\323c", 64 }, + { "\342\206\301N\363g\353|\226Wd\356\240\3630,z\343\225\024\031\252a\275Jg\337\361\000\224_\273", 32, "F\342{{\365w\331/Pi,}$\303\260\344\265,\032\134r\362s?", 100, "A_o\223\300\360\016\264Z\223&\300D\2500\310\316U\347\004/\226\364\336\353\034\217\011](\237r\356hd\245\205k\037\252\042/n\241'eZ\316\310K\233\017{\247\234\303/\205,J\373l\362.", 64 }, + { "k\007z\262\2607\030\372\326\240\273\317\332\2406\031\203\014\211KOT\330H\001\356@\360:6\310\336", 32, "\301\261#\301\224\212~\323\326\237\037\202\036N\342\034\323\034\332\245s\002&n\035\265)kU\314+\244", 100, ":\276\200\342\261\1345\243N\265\304\334\375\364\323\371\304\213KB\336\372i$5\205\344\313\012.X\273\021\306n\222\025\224\207\321\365\265\333\304\363\225C\256Yf$\235\340d\026\027\207\216\267\006\361\030\353@", 64 }, + { "\212nj\377V\332\013\370O\246\366+\370\264\321V\252\246\341\232\000\250t\341\241y\217\2764\213\234\203", 32, "\210\370\011\356\265\343X\235\3101\255m],h\253[\347{\134B\360x\215\222\324\275=\212}\363\247\326\004m\034\003C\241t", 100, "pc\205\224\356\344\247b\310\251\222\224\357\315\277]\000\272/\303T'\371\336\221u\370\355*\264\226~L\357\004\237\345\215\236\224\310n\032n\345\357\347\204\231\2543\020\234\032\042'\014\361,o\134\305\2233", 64 }, + { "\227\222\262P\202\346\315\316\216#\250\032\346\007U\375-\317j\020<\220F\344\215X\234\004\374uM#", 32, "\215\215\254\311\351\001\253\313\331\364\304\315\032\276r6(\261\325\224\346 d\357\257\013\240T%\314\305\270\200\350\204\343\276\371\021\011\206\221(\310!+\034)", 100, "1W\302\356\244\310\375,&oW\334\355\230ipU/\026\236\352\250X\010p\335c$\032V=\375\316\037T&ja1{\225\262\177\313M\360Q\313\220\177M\307/.6\206\333\256@<[\331x\212", 64 }, + { "\016j\376}|\201\341\346\214\014}\023\353||\360K`\336\205\261\336\015J\243MP\341-Z\016\224", 32, "\013\350b=%\356\202\247\222\201\3362\222gr\331Lf\201\340=\365\002?>\011h\246\306C\361\274\306mK\002\005Z\230\267\372\0364\342\254<\032'\215FR\231\210re\035", 100, "Fr\342\330}\351*D4\314\003G\366\270z\016\345\233\241\331\225j\262\324\362o\016\306\205\272\333J\255\350G\001\365\225\2548c\202\036\275\353\375-\031\032\023m\220u\337\236\265f\357\033O\341\332\235\246", 64 }, + { "\037h\035C\201\200\227\347\245\205a\334g\343\330F\330\267\276\254\350\234=\317$\220e_?7\014\020", 32, "\363\34664\0316\003!\264\262\016C\225\026-\230(\363\007(R\347\013\014\012\304\244S\032\367\203\336x\251^\365\200\004G\354Vv\236\277S_2\363\260MU+\240\263p[\274\357\343\227\264TN\244", 100, "=\304\257c\200^\221\207\253\275\301\300\245\370\303\326Lt\026\235\337\334K\026B/&\0273\352q\024Pf\377\305\326\015\353\217~:\223bxyC\036/\021\134@\324,\337@O\024\356\252\352\314\001w", 64 }, + { "\350B\315\204\370D;A\224\200\004{,\202\302Ba\310=\214\012U\002\007\265h\007\262ou\251f\372\337\227\012\310\357\277\346\321\351\236?\310\303.\263\377`", 64 }, + { "\372\252\370u<\365\355\222\214g\324\027\302\020\214\357\013;\334A\042\331\227\267c\3001\035\215^\245\316", 32, "8Kt_\242\015\235\007d\013\376\241ml\211Bf\225k\357\226\031\042m", 200, "\214\323$\343\001&.\301\226\220\260R\263\253\207\226\321.\276E\233\267\351BW\230\365sc\273\034\005\342\006\033\2051\227*1\017\216\221\024\276Db\222\212Y\032\017X\333\320\210\177\356U\366\321\256\002\216", 64 }, + { "\203\000$\374>\2270*\334\000*\254(8\020o\311\213!\000\253q\333`r<\201IS\020\217\246", 32, "d\315\226\314\202\321\343\360\351\203\033\343\312\315\245\024x\351\274&\032\034\364m\241}\376}T\253]d", 200, "}1)\202\266\331\2179l!M\277\251\265=\3449\310\220\346\310w\330\210\026\305\251\375*\207\233\276s\277\273\202o\326wes\224\023\3222\223\365\304\375\371K\274\344t+S\314M\217d\320\221I'", 64 }, + { "\2519\015GJ\241\362a*\252\307\253B+\226\204\226\320\276TlW]xHr\244L\354<1\363", 32, "1\207\307\303\232\276\322\277\037}b\023\256\211A\371\333\220\217\342\216\304\011`\3450\270\207\343\365\277\311\301\351p\002\223\011\372\362", 200, "\354\034\351Z\226\347\033\212*\253\011X\355\254\336s\363\365\257]/\202\256c\305\203X>\251\027A\233\357s5\337\022wW\240A2\351\271v'D\376\205[\246\313\361\375\301\251\307c\202\365tf\000\305", 64 }, + { "+we\241*9\342\353\272\365\313\366\241\031\272\231R=\310#\372'\322s\014\253y\372ym\314\260", 32, "\230\327\217\225\203D\015\036\364D'2\042,\001&W\310\326*\375n\255\2530*\323\210~\203\361\234m\375\215\2151\342`\360\353\224\224\2510cW\260", 200, "\017\317\2567\134\357G\343 f\3122\011\377\334R<\365j\230\021_N\230\235\006\245\035\274\037-P\012P\225D\024\021Zy\256o\223\242\030\032Y\024\213z\265\012\374c\325\342\2735\370+\274\360&\020", 64 }, + { "\234T\251\237\350\325\232\3613\253\322p\252\327Y\212\213,\374\326\203\235\037\274\203\2665kO\025\356\012", 32, "\263Bg\330\260$a\243\027$\303M\2553\2347Qm^8\2041\011`\216@\013\011}\302%\352\360\316\352\370\003\220?\321F,\236\360\362F\327\350R@\327\247d\325\272I", 200, "\244\015\341\362\031\363\032!/\221\207\204\325\303\254xl=\267\373\336\357-\322\304o#\314\027Q\015G~\012\211l\314\265\3305T\005\247\324\000\2406vp\372t\352\204u\374O\347\032\010h\277[8\257", 64 }, + { "\257\330\002\330n\015\300\364\026\251V\016\3308\231\221\207m\003\024CL\271\251\364\324r\036\313[u&", 32, "\240\032\225W\314\311S\204\0351\027\177\361\367eO\224\260\214\274\266Yj\275#V\265\32533\244\00139m\356\256\363\312\221\015u\334\036r\205q\300\024\264\002\311\277Z\271\333\006a\326\206M\357\253B", 200, "\270\367\357\237\004\177T\024\266\332\342 g\261\336\024 \035\243\255a\336\2006Uq\217-\362\372\037S\301\314\314\327+n\252\235c\004\042\020f\311\337\177\211S\266]\346\033\210\244\254\377\333\305\314\007\355\311", 64 }, + { "\224!/\213\360\357\220!5,h\322LnTY\025{\334XqV\236qY\026A'`\021\364/", 32, "\247\213\203\223K\362\366\255\020\217\2265\222%\030T\265\313:SW\237Y\346\256\324\012\2358\235\257J\276\034\031a`\337\202\317\352Z\017\323\303 \264\042\016\015\012\253\004\264$i:F+\003\301\266)\270Im\234@\271\014\026\312", 200, "\207\261\336J\2314\262\330\025I\012\316}\354|\357\033t\006\361\326\333\232\031\325y\003K\277\3518\334\301\357\365\234\301.w\230K\256\201\266\350@~\340\222\310\014\376\355Fk\257x\242D\374\037gxU", 64 }, + { "_\005\231\003\225\334q\370mQ\321\252X\031\265=I\224{\343u)\217\201\370J?\364\013\315D\177", 32, "Q,\356e\355p\312\232\311\270O\333\024g\301vY\364\032\351\352Nw\320\247!\241\367\003\006", 64 }, + { "92\200 \224\243\3026Vp\376\270X,\300V\315\265\270$H`\262\324\271\337\320\253\367P\2525", 32, "\360\371\017\302\303~\016~\334\013(|S\017\315\2465\264\227\3060\334\014w6\235C\256I\346\022Z\012O\023\221\262\252\355\237\346\323F\3111>L.", 300, "\274\0251\006\345\321\275[id\316<\370{\026\210\350KjB\324,lS:\345O\263\301\355J\364\346\271/\3262\223j\347\231\245\234\022\241\254h\002\265\234J\275\2521V\325Xg)\215\300VFN", 64 }, + { "\224-3\372E\373y\366q6\375r\201\250\276\235\212\276R\275\347\317\331I\2572\031{k\354Sm", 32, "\335\213\324\011\243y'\302X`\317 \300nj\240\002\355\177\322\003\350\004\250\3265\333L\210\134\354\260\327Qty\007\033\337\350\234\216\340)\230/\321!|\361\2669\246\335\266\360", 300, "\240\270\256\340\027\016\010W\030L\305\234~\362\011C\234\022\267g\207\301\246p\216`\234>\245`0n\231\326\303\032\2464.\215\310\347\236\237i\220 \336i/\275q\315\205\034$Y\307\2310\326\276\252\224", 64 }, + { "\347w?8\316\356\356u\030FA\011cQ0\032\301{\322z\364\007\344\244P\003\312t\271\370\022g", 32, "\270\003\340}\246\274jA\267\033\366Z\275\177\227\331\205%v\323\260-\012\340\015?t\2752'i\302z\212\300\332\317\231\234\220\015\241\035\3523g\025\263\244\042y\340\274\322a\252\005\251\336:\275B\020E", 300, "v7\377au\016Z%\270\215\300\011\237\324S\021\207\014\357<\335-p\306\034\224\362Dn\331cK@Ji\354\217\324p\324\212\310\313Ho.\224\340\031/H\373*\335\033\357\253\037\222\204\234\265\037-", 64 }, + { "\255\002vG\234h\247N\257\033\370\323\353\003Z\352.\361\373!\003\304Z\374R\012\265\255K\273\223\005", 32, "\335'+\321\275\250\200\315\216I\235\253\307\266\310\357G\004\372\301\311\031\352y\004\247\252\277\325$-,\340\352j3\331\042\360S:}>\276\313:%N*\226\273\311\264\363W\217yBLK\225?\343W\020\360\261\347?\267\344\203", 300, "\212\336y\264\270\212\272\345y\231nX\323\343t\236|\334\370\346<\347\322[\013Z\036\200\267\333t\014\3361\347O\210\357\206\031?\314Q!\275\310)%_\325T9\376\204\260\241\223\003\363\334{K\360f", 64 }, + { "\257\324S\205\231\324\023n\317*\321\373\341\307p\302\300A\251\304\014\325\276&p=\307#\341\220\274\000", 32, "\203%ft\036\202Iv", 400, "5\213\375C\213\233\346\347\003\243\243\304\255\035\213xV\007\275\042\013\265\015\231\267\322\021~rZ\271\227~\010 T\277rS^\326\211\305\032]4\023G\224K%x\005\312\3131No\177\230O#\0423", 64 }, + { "\234$\001\017m\223\035\315\265X\360u&\202D&\321\020\216\334\261\236QA\302\004D\367R\302\255\341", 32, "\247\334\314\177\366|5\235\231h\323\217\332\364O\016", 400, ";\015\000\340\014\206\252\307\206\376\314v$\224x/\033g\027S\003\262\270\273bT\036\020\001!\261\003h\314u\003T\014\030\037V\202\005\327\216\324\213\336\020\303Le\3237B\012\374B\310\035\322\320\006\324", 64 }, + { "!B\007Pw^\277\024m\232\342jH\2722\376\326+?\3568\217WT\037\273\037\311\352\240\007\273", 32, "\374Vhd\263\246\255W\226\015\276h\241\253.\274*\012o\003D1\360\021", 400, "\0119\322\250\350\027\226G\260\203 \316\245\027[lV\313\005d6K/\217}L\353\337\273*\250]J~\223\320\266\331\225\222p\262\027\007\227DV\223\340\332\305|\211\303~N\211~\353U\340\324\261\042", 64 }, + { "`m\302\221<\360\306\306)\220)\2751sl\022\216\363\233*\257\000\251^m\006\261\367k\007\355?", 32, "\300_\016\250\265\234\3131\241\030\033L\253F\003B|\272\250\021\242z\235\011c\013\231ty\277M\027", 400, "Rb\332\252\340\0128\177\311\030p\330\0265\337\206\212\217\213\322c\240\370\200\016\370hC\012\026HB\275W\255l\316\354}\225\354M\310A(\307\372_\254\260mY\277\032\375F[{\323P\030\273\321.", 64 }, + { "\020\301r\264\274\330C\264`DH\360>V\370\005\234\013\270\273\223\234\02137\345\275{\042\326\236X", 32, "\274(\277C\310%D\305\035zk\212\360\020\324\324\223\212\234+\312$Y\221\250\006\357\325F>9\212\313n\250\2323\314\343 ", 400, "\276\012\347\225\301\271\344\223V\3001\004\212\033y\001\351\313vU\331\021C\036\360\343!\324\321%\222sh\221\232\313lo\3063\2471\354\335s\256\237.\241\267\323\247\261\340=\272\370c\276\336\134\214>\204", 64 }, + { "H\325\277\243\331\206\273\317R\005\324\030^,\370t\276j\0003\230~\370i\346\363!\223\273\244d\333", 32, "\367\241s\025\264\023%I\355:^XHr\003\230\177\331\245\347\025\372\234i\325\350-_\177\375\323\370#\320\332\320\311\241nED;\134\370:\012\026=", 400, "5\325\243\265{\033-\344\370u\020\1342B\017r\301\277\134+4\016\001+_T\367\354\012\325\311\257\023\200s \262[7jy,@\205\254\364\350\033\212\223\275\236\332o\031\350\026c\366%\377\272\333,", 64 }, + { "\012rD\010t\322\202\251\355\253W<\201J\363\312\206\323\337dN\244V\025zG\324\375\361\207RK", 32, "\207\227\350\201v\263\376\206\215\360\221\3046\022\217\002+\022[0\216G\225bQ)s\204\321,\225\352\256`!\250\333\216\364\217\30602i\017\262\013\352\326\301\250\022\244iLf", 400, "\034\033\242g\257\230{\316\363{U\253\0049\000\257\265\264\030\264\011E\320J1<\274)\201[c\252\323\266\353\222\022Jy\366\301\024\252\024m\272\261\307=\2047\371Ril\222/\230eL\003\325c\276", 64 }, + { "\207xrV%\324mBu\004\356\222\302;`T\347\0040\302\356\324\012\335\015#\324\330\214\335\221\205", 32, "\346)|\356\355q\266\340?\377\220\364\361\022\004\274eTvh>@\231\205\003\3354\234\001\337\260\031\225\3546C0i-\377\3657\021\340\354\225\352@\314\313\336\035\313\014\347\327\320\250\314\276\247#\356`", 400, "\341\017\177\253\177\265\002.\322\235\224\177\244$k\307H\245&fLi\354|u\241^^\0231#\300\317<\316\230\254\0302\264\134\011\016\275\356)\307\374\365\313\324\311\267\246\236\371Sl\366\327\254\333c!", 64 }, + { "\024\201\3045\325ty\362\270\271\253!\260hE4\220W\255\240\277\377\326\320\202\206t\264I\324\215\204", 32, "_\271\352z\017\375Q\326\256`\372g=\274\261c\367\033#\275\356\0242\315<\220[#\023\371\2636\3131\360:\324\375\242 mC\227\315\220\302\006#\204\273\011\252\245\002\026\030&_\241:T\215(\002\372\213\252\331lX\017\370", 400, "\242\304\265c@\230\004N\354\001\252\263\211\037\201\276-]\015g\365\204\323\252\355\272\3165iB\364\357HS\345\253\303+\006\251g]\370\323\204\267\346\031[#`\225\343\272\201\253Rxn\347l-\3050", 64 }, + { "A\316\347I\012\032\011\224\206\310LF}\377\212\035q.\031\206\241Tt\346\252\220(o\223\272\325\257", 32, "\011\025\200\201\221V\177\373", 500, "C\275\213\366A\324\330s\323\322\231\342\353\355F\226Z\253T| f\331\134\377\337K\325 ^[#\275\012\231\325\032\362S\371\027\312\223*\356\222\364\226\042\311\006\260s\360\236\034\253\310\357\365\265h\374\236", 64 }, + { "663\230\3430\362\027D#\210\010\013P\017\224>\020\005\216\272m\006\035\225\355Zly\221\005\223", 32, "\335\374\334\026Y\254Z\211\272\353\306L\354)\251\002", 500, "\022e\035\371\012\311q\335%W\011\312B\377\263=\376\214'\275}K\254\221R\205\321\212'X\221\354\337_e\327\362\372\323\320\311\300b\263\253\273\020\305\302\251\002\266\005|F\245g_?<\361\314P\201", 64 }, + { "\031\236|\263)\012v8?A\033\332\003\363\2020sLS\230&\353B\031\242\010\245=\027\217\037p", 32, "\012]\202\012\2107`\233\373\265r\217\234\273\213|M|\315\357Yue\327", 500, "g,v\236\024\021\267gL{\262\341\213\346\356B\250a\361\354\276\267-\313\201d\211[\001bu\314`T\036\134\212\022\330o\366_\254\3731\354\024Z\300\272\250>%Y&Y\354v\271K<\316\246H", 64 }, + { "\301\031\014\272\325+ \361B\361\360\204\343A\230\220l\221\017\337\250\316\134T\351\211\037eO\305.x", 32, "J\244-\214\267\363s8\302\242\237\204\351\274q\204\3478\227z\263\311u\312~\336\317\250\241\341\206q", 500, "\316\205\233\374\320\350\232\001\355\277E\227\230:\372q\230\024\373y\356\264\306F3\2551\320\246\275\025\036\206{\323\264\272f\276\330\1778\262?\235\204\363\363\261w\030\251\242\347}\002\305\223|)\340{\264\257", 64 }, + { "\364wG\247F\300\250\203\364rB\337\311\272Td\221\207\034\251\303\265\217\014\273P\034\377\342\254\363\037", 32, "\361\134\360\257\305\010\030w\345\030Y\244\236\002ge\324\326\340\276\022\362\335\353\366\362\205\307\020A\232\274\034\240\366\274\310C\242v", 500, "\260\311x\272\213L,\223\333U\363\022\355\366?\231Fr\227\025\253\321\203\025\013M(\033\300\302\226\256\272\344\370\217\034\256o\376\325[\004\035\007\004M\220\005\334y\234O\367\334wp\2750'\032y\306T", 64 }, + { "t\246\251p\322\247`B\337\225i\007\362\317\201\023\010\263H]\373\344\226\005\304^@z\226\210>\250", 32, "\315\310T\325\200ys9\324G\3320\034J\376\024\366\365\310\351\350\221\362\251u\372\334xiUD\205Q\247\206\276\232\204\015\2034\264\347x\303\270\375[", 500, ">F\372\306+\2150\024\263\031\340\226\215d\350\373!\237\272\263\340\362aBZ\354\263N\377!r\351\307\223\257\215\224\322\305\253j\016\201W\303\3706\177%\262$\212\334P\015uwj#\267\037(\254\204", 64 }, + { "\351\275\340\351\264\341\017\033f|\233\331pOK\277)\013\354\312\356\211\344@(\320\321\322,\367Z\212", 32, "\360\340\021bp\367\336\246\352\231\244.\232\370M\257\204\033/v\236\226I\215\033\243}#e\362\030>g\361\242'\334\220\177\003t\353<\370\023f\034\354\177\017\267\013\335\315\350\355", 500, "\001\266i\240c\265i\314\204Y\252!\335\042\373\211\332U\303(\273\304m\261\020l!\360\300\006\376j8\2547E\037+\242yO8\002\377]\256\245Q\032}R\343\311\344H\353/\227\3566\270V\263D", 64 }, + { "\217\025\363\021\024\006\013\355\005N2/\250-+\3704\354M\001t\245\000\233\361j\324:\340\266D\036", 32, "\177\226\351\134a]/i\247`\370\346\243\006Q8\302\211r\021gQb\006\244s\350\273\303\202\220\236\341:\372\026\335_\247f\203\254\303\010\231\035gG\252e\375 \326H\3469\270\014d\215\273{yw", 500, "\270\334>\273H\035}\215\322\350,\353r\212\020\362Hd\033\214\021g}\366\352\346\2725K\022K\217\220z\221n;M5\024\012\310\225Uv\377.\203\260\026W\351\000\263\003\266\017\202\324x\313~/\302", 64 }, + { "\214k\277\217\215\031\022\204\207\011_E\321BRrkE\020\015\375\223\367\346\370\013f2\306R\217\356", 32, "\307\337r\321\366\245\307A\013\015t\352\362\006?\245 \333\334\264f\260N\250\225\341\030J\334`#\263j\275\231WU8\366\203K\223\365X,\266?n(_v\347\303\305|\316\207\013\042\251\233\232\011\324\3714g\010#C\241\336", 500, "\007YI\203\310+\236\336\020\221YU\351\376\232\266DF@Y\006\226\242\256\270r\303eO'\366?+\323\032\225\345\320\015\227rsge\317\260\342jp\231\372\306nG\350Mx/\337f\2757\0121", 64 }, + { "\134\355\220\225k\203\013\271o\037N\364\237\343\352c\336:\335n0\213\247\365K\204A\253\005\205\211=", 32, "u\267\316\322\344I\327a", 600, "\263OO\366\217\232\213i\216se\234\231\2740!\311#\256~2\267\134\025\367\310\020\3541-T\223\227\025\010\276\212c~\265Sf1\200\017MO\002\006\352\374\316}\313\032\317\221\007\322]S\224jl", 64 }, + { "\014\274\263\346f\231?\005\223\3336\036u\301z\361\324\277\351\013\320\244\247_\365\315n\222\345s\023\134", 32, "\336I\3260\310g\341\234\3012\376\205\002\301f\311", 600, "\362\246 u\364\216c\037\232*\037\253\031\335\347\022[\007\256j\303O\225\270\204/\031E\244\253FdC\272\305\233i\343\357\327b\273\241j\243\261\321\255\345\304\365\363\337\277\222(&hL\325\361\011J\266", 64 }, + { "YC\314\276\211\370\003\272\320\325\232?v\203\001\274\2738qt\256\330\365\276Ad)\256$5\353v", 32, "g\346W\016*\233\311\344_\267D\346\261\322>\031\274J\300A:\355\232\330", 600, "\304\2457j\205\3131Z\021oA\234FI\254(O\026\334N\017\324\206\033_C\375\231$\314\270\212\245aV\035+\220GC\264\035@\241\231\0124\235\014<\334j\257d9\355\301(\236\226\210$\235\230", 64 }, + { "\207j\363\010\013\313\273v\326\270\265e\260\033\313\3237\211*tQ\366\215\216J\212\235\324 W\035\033", 32, "\303\374\023\372y\363\307\320(w\236\200H]\371\262\010\006\020\361M\030\346\222\361\216S!bc\3612", 600, "Y\301\037?z\341Y\350_\374@\210\324\274\014f\377\317\023\303lOh\032\253\035\332\217|\375.m\203\031\361^\320v\323^ s\031\347\215Z\012Zj\335\206\363\024:F\310\035\211\255\216\301\203\251M", 64 }, + { "\216PY\256\343yt=H\205\303\011\353\232\340\2630^\021\365\266\004r\001\307wV\251a3k\370", 32, "I\256\322\255atb\305@\004Z\352H\032\205\212\254\215", 32, "vU\273'/j`\351", 700, "\360\255\227x\024|z\360JY\364\273B\240\037+\027\376\346\207?\030A`K\216Ba\366\241^A\030n\027\363\225\301z]Y_e\012\273*0\222\274\242\313Q\003\201\336\034\210T\361\2268E\243\303", 64 }, + { "\352J\265\255z\256\252C\363\273\332\3044\351\214\311\012\2516~\226\355\225/\347T\264\260A\330\377\355", 32, "dv\016\032\340<\207.\260\037\354\234Csm\337", 700, "\360|\337\257\240\016)LW\230]\035T\016\001\256\252Ew\222\016\003{yE\025^A\274\377\346\265\370W\361\336`\352\0118~\241\356BW\272\315\260P\240\273\273v\322.P\322\301\177\033`\317\244\346", 64 }, + { "Q\026o\230\010\276b\336kNrzjJ\021D\302\364'\353'1\202\345\207\203\207\201\034\203\000\257", 32, "lwS\255\204\030M\357jIx\363\301\271q\304!r\215s\356\322\340$", 700, "Fx\263\350\210|\223Thrl\326\215A\366u\2168z\225U\255\314_v\020\017\314\025U\304S\023}N\021\363a\314\267G\2444\205C\200\011^Q\253{\216}[zfQG<\232\242r\314\334", 64 }, + { "Y+b\271\212\342\325\025\343\277\012\223\0121\243d\004\240\342<\205\013f0k\307\254\335\014e\364\261", 32, "\343j4%\254\352o \0116ksr)-\341\366\366P)\021\362\305\305\003T\204\302\317\312\313f", 700, "\016r\343>\207\376\003\177dw\037AN\262\334\017Y\236\374L\253<,\226\027d\317;\250`\216\326\334d\251\355\300i3eV\241Iy\220\001\356\035\364[\303\220:\242|eN\313\354\3039\3309\272", 64 }, + { "\354\261t\321\217\227\3512\321}N\214E\257\251~\006\014\372\200R\017\261\007\021\220\371\370@@P\222", 32, "\277\301+;*+3M\352\373\365\246\304\356\250nf\320-\241\325\244\306\357kXYX\325R/u\326*\277\265<\200\360\270", 700, "\265%\225}\007\257W\255.\306\000\201U>\271\330F*\253DD\317\021aj\374\223`3\367f;\026\010\342f\0150o\232\303\015\377\017\205\357%\277]\277\216m&\236\344\366\313?\373P\214\223\000\324", 64 }, + { "\310F\324\335\367\301A4\252\337\342\331\016\000\241V\341>\237\034C\204\301\276\255e\276q\341\3778\301", 32, "\214\222\134\343\224:\336\012B\323z\310\262\021\205\225\216<\313|\227L\267\024^s\316\257\014\2259\261\371tB\242\373\366\232\374\353\336[\343\026k\307\256", 700, "u:_q\370\012\235@\315X|\367\377C\217\353(\3051a\251\001\003\226\205\342\227\212\306\337$\274\201\212P\315\017\221\347\006\021\230\354\266\200.v\213\361'\320\227\331Wi\034\374\346)\332\273O\372\225", 64 }, + { "o\210\323\375q@\013U\011)\020\252TE\206\233\306\2058\324\371\354P\374?\212\235e;r\207\261", 32, "U[{7\230\215\213\276\344\336\223\322,P\214\360\205\007\202\276e\005\025H\2048\212\247Vq\232q\303\272r\273\001=\201\261\265I\311\266\323\206\203\207J\212\323\200A\375!\276", 700, "\211B\011\227\272\0275k\016\015\266\202B\0301\223\226@\037\005\377H#\302~B\020|\002\226\015\242C\342\273T\306\245\376\307\320I\301f\021f\316[_Q\356\210M!\271m\011p\027\361x\316\353]", 64 }, + { "\033\310\253\302A\013u\205\252\020.\233;\372vs\243\275\351 \015G\220l);\265\245\362c0[", 32, "\306\233y\253,\303\222I\343\335\211\242\243\026\320\253\177\211x\215\033\234\177*\333\343~\215\364\333t\326\005\240\256\300\362\015\022\344\212+)\237\277k\354;FFL\323\373\2342\022\001\254S\353\265\253\323\363", 700, "(#\342K\312\320\243\035\234y\366\000\333\023\256\305\042\361u\035\026\201?\252}Y\015=\203\332\235;&\344\027\235f\353\252\235\257Z\042k\377:\346\365l\236\335\035\274X\237WL\342\237U.y\003H", 64 }, + { "\003!:\341;,\031hr\233W\265|O\015!eO\352\272\355\210\304\360\3318q\004pw)\364", 32, "\317\243\314\370\315\317\025\017\002\273\020\344\354\222^\007\217\245\336\362\002\307c\207\376\236[\373`\257\226\332\025\202\246\010\230>\311|#\273\134\322A\364y\354V\021*=\344\326jb_:Z\221\214\203\011\277h\042v\212\211\241\303r", 700, "\252'\212\362^\0326\2114\216J#\367z\024KZIf{~\375\345C\302\307\236\030\002\262\346\012\033\317\272\230\244\320\220\272\242*\021\327\240>k`\222\263DT\231\204';\301i\027.\302\223\320\236", 64 }, + { "\321\334^\2313\347D\003\200\003RyA\002\241\321b\264d\337k]\005\260\265\226\001\017\3361$\341", 32, "6\327\246\342\376\260\013\303", 800, "\304\350\334c\025Q\240R\263\243M\320\011D\351\230\375\257Q\134\346V\303\267i\362\221\277?\323\363\207?`Qx\023\356H*wm\032\343F\017\304\033\327\204\242\2064^\214\204n3\000oqF3\347", 64 }, + { "<\204\330om\325\200\322\261\262\343\010\364z\017\317\223\366\313\311'\263\344V\270\134\2008\005'\267K", 32, "\015<\014\200\270\270\134\036\277\352\025\350Gk,\301", 800, "\331[p+\273\317\247\205\026\353\262\311\226D0Q\273U\014\366Rc\371\346>\255\206Z\253\260\267\226\200\321\357\134\3309\002X\014\015\241Wu2Y2$\331\265M\267\377\262\255r\252-\021d\201\341\217", 64 }, + { "\206\362\247\200tY~\344\264,\2113{Myk\366\370\3025\310_\343g6 \261nK ~\310", 32, "\323\372Uv{\243\026\035\350\261\323(B\257.\334v\024K\016\334\227\034\266", 800, "]\275\033\351\007\357\036\375\264\375$\360\322{\213Jaxg\027\21729\251\357\274\246\222\267K\271\351\237\321o\2451\035\310\2423\267|\272~\254\222\030\356c\003\240\337\373\231\033\270\340\277\240\3505V`", 64 }, + { "y\207\206\361\236\374\200\304St\364l\263z\244\375\270!\355\334\370\205\372(\027#\320!xij\313\314", 64 }, + { "\200\364\370;\271\323\015f\203%k\217\262E?*\305\243\211S\370\010fV\255\271IA\312sL\303", 32, "P'\305'\353+.\324[\364\241]\231\231_\215\357\004\345\322\2315\250F\335I\3471u\026\325{\204\241l\235\365\233\357x", 800, "\226v\235\300y\206\023\337\027\266B+1\377\312\214/\027\343m~\036\361\222R\024}\337S$\003\001\330\317cW\200iKJ\362sy\227\307\2670S\341;\252dE\343\217\375\270\206\373,1\020\352\312", 64 }, + { "ZN\344\3253\000'\217\224\223\206\257\3662\321\235j\204K\236\264'\312\030\327\276*\363\001q\272\223", 32, "\246\017~\226\231#gE\374\224\224E\374d\367\301\027\336XL\242+-\247\227\020F\215e\354\020i\272\214\271F>v\030\230t\007n\263\301\275\231\214", 800, "\332\003m>\274\2375.p0[\0234\037\245\256\227\2617%2\374u/\201,\316\324\200\323\225a\242\023c\332\233\211\342\254\011\230\032AV\235`\246PC\222\301\222/\342\354\261\251;\3505\357ey", 64 }, + { "\371\374\236\365\2432\210\021\205\300A[\365\017\207\2611\252\236`\015\031\205\326E\324\010\253\037\312\267\304", 32, "e\316\2516%\025\333\014\300QA\220O\343\366\001J5\251\353\300\262\262A\2748-R\025\027\263\227z\231E}Z\207\017\250\365\030\001\344\231\376\002j!\375\317\206 \347\3046", 800, "S]:v\220\373\206M\244y$\240\260>\030q\335+\206\205\305\361\251\326\0039\332.\034X\250x\004O\016\221\022\027\001\022\221,r\377F\262M\307=\033\042\341\312\014/\024v\224\265\200R\363\223|\360\235\200qp\225$o\201\020\2500\375\024^\217d\347*\355\257\211L \007", 64 }, + { "\206\307\0424\261\034\255\242\033\233\205VS*\003W8\226n\302\042\263\366YL\343\033\256'R\007\331", 32, "\035\241\217\002\364\341\305\313Cu\347@)\020\376\336\372\375\257Y3\202\237\266\365)J\270\351\265\310\212v$\201\207_@u\013\301\177j94\202\304k\345W_\324\310z\215_\304\2554U\236\245\314\330\313r\271\001\335\0075\322", 800, "\237\225\217\301\200\264\242I\240Z}\303\365n\227ps\365\302\013U3\373\311\273`KQ\354\360\335\212p\227\245h\332\225\374\375\374\300\261#[\240\246y\212\013\332/\342\212ns\243'\243\036\023\375\002[", 64 }, + { "d\375\042\033\372\337\277O4\004\270\037G|\234oY\032\214\211|6\374\374\207\221\205\261Z\034h\362", 32, "\332jcz)%\345\206", 900, "\312\233\266M|)\265Y\277UY\323MYj\034\203\011\353\215\361\247:(/o\270\321\362\034&\302$\2402\277\260\262\371\231\030\204\373\230;\276\371\000\323\302\025\314\027\205\035\2404\257]Kyl\363\203", 64 }, + { "\272\211\350\227\343N9\013\232\254RC\003\362)-M\324)\211\002\343l\331\300\177`\255\373\017r[", 32, "O[\2002X\323wW\374\204vg\355\270\003t", 900, "\243FM\260\206\333G\331\341\347\337\336\001;rr\306\343\211\360\272'g\207>'\224\334\2664nLA\311\221\321\030\024\015\036\246[\224\364P\270\223q\221QN\254\272+]\246G\337z@\211FQ~", 64 }, + { "x\357\024\247\310&1j\252\035r\024\301\217\241\012\336\300[\342\201\312\335<\307y(\273\321Wp\323", 32, "u#j\303\340\326h\242\367\023&\377\334M\201\202Y\342F\205\241\357\220\036", 900, "1\343\316\341e\365\233Z\355\313\013\021\302@\027\274\223\342\331\367\343z\353R\276r [\273\344\332~\015\311\255\324\325\014i\266dH\357s\3040\304\002\355\257\274\022\212\346\27511\300\272\215\210m\042|", 64 }, + { "Y}\011\134e\265|\3432\274gZi\334\340\320\011E\360\353\033\374\373\004\023n\025Z\325j\036\003", 32, "~\034V#\3239\346\017\020m\212/\203\370\372'\341\005\021\246\304\341v\352\275\224\036M\313S\211\257", 900, "\377\374\030KE\325Clh$K|\350#Ns\267X\3442\031%\270\012\024\17744_P\317Y\244\316s[\240\312\347F\305Q\322\021\013D\350\022V\014\2677\017q\306\361\222\260\306\037\257\236\010\263", 64 }, + { "\301\271z:r\325\332&s\200|W\361\220\270V\327\337\376\266Q\343/Z\224\245\021\226f\012\227\321", 32, "\1342m}<\220\234r\367W?\235p\234k\216.Z\260Q\304\212u\006\323\317\3103\300&@\257\354\276\245\311_9\004\252", 900, "\351\010\311ad_\347\271\204\243\007\377\311\236C\027,\215e\200\030\024=:B\253fp,1C\221\311d\214l \317T\027\376\030\320\204o:\362\235h\270\366\353\001eJu\004\202\300`\215%\355\201", 64 }, + { "\241\371#\267\251}\342\250k\275/\364dhP\000\340rX\010\006f\241\371\377>>\032\370\265h\253", 32, "\333/\273\006\213P\330\305\304\357\357\324.A!\002\250\210brD\302{\026n\007\350}\327,\371\260\240\322\253Q\243\266\254\037\001fm\233\257Z\315-", 900, "\030{p\375!\357\134*\353\017C%\217C+\225m\005_\206+\004 J:N\370\367\2041o7\241\236\222\261 \313\222\177\340\134\376r;l\224cC\035v?\022\316\321D \372K\214\317\216A>", 64 }, + { "\014b\217 (,\360\311\026\343\360yQ\215\363?\030\3467f\352\251%4\361Pt\037\261\371\014b", 32, "\032\257\353]'\003&l`\315\012\274\356L\346\001\255\303\3150{?/K\270\305\346\2311$O\244C--\351\004\206n\327S\217[\134\274c\372P}\243\355A\354\266\207\006", 900, "\007t\223\367\034\352H\312\205\030\314|\272\240\360\362\006\002(@\261\224\004\225\204Q,{qhp\240\271S\340B\015C\376f/\370B&Gf\024\022\312M\262O\316\177 \325i>\274\377E&\220\220", 64 }, + { "=`\230\314\234r\206\304\134\367\363!\023\2774\301\323\026\011\366\265\265/(\343!\007\335\242\214P\012", 32, "e\024\351\002y\227a\260\331\026\213Y\267\251\310*\230\030W\214p\255\230u\001j\3704\315\375MSX\030c\336\306w\325\346\262\2640\255\2465\253\3334\337Nex\234\334\216\316\314|-\257\017\022(", 900, "t\221\347C\244\016:\216QD[$r\347\227\325\256\343P\203.\012\277\3216N\241\351!\037\211\322U\017h\021\042\352\030\221=\317r\306 \367G\372\270\214\004\000\207n1\3646\344\034\371R\215K\305", 64 }, + { "\355\361\227|\310\247\256\014p\026\017\037?\364\277\355\314\030\236\306\032\306\240\321%\262\256\265\244Y\216\252", 32, "\263\354<\350\215\312\311\366\242xX'\234\312}f$>Ez\327\023x\320\355\331'\372uF\231\257\251^\034\364d\230\022\304\245\322\261>\325,\273\357\303\311N\3374~\323Q\014\342b\342\025\226y\307\245\026\231Q\266dm\215", 900, "\325\361\300\010\312\311\037\017Mh\310]\254@NC\324\205+Y6\027\362'b`x\353\007\211\035\264b\005\225|&\321AH+W\007z\377#\361\274\265:\371=\257\225\361ec]\315\203Jv\203R", 64 }, + { "\242\341U\355j\004k\356\204\330\351ufb\327\337\357A\223\341\233\3668\220\352\134\247\202\373\006\310\323", 32, "]\331\327\016\205\272\246\206", 1000, "?\230\007\216(\272\307M\015J\344W\242_\233\230\2201\243iM\254\362+\254\333\3658I'\335\241\377\2061\013d\212T<\327\201\257*U=\014\226\321\251\227y\370y\016\216=C\363$j\272\241\365", 64 }, + { "\017\376\364^4\254p\016=\353\344\366\352\006\227)\030\357\004\263R\373\177#\211 \335V*[\344\257", 32, "\3722\017\275\232\262\323fcgiW\232\224\262f", 1000, "\373P\274\357\005\026n\3021wkI\355\325\026\376\021", 64 }, + { "\042t\014\315\227K\273\323\237\220!\270\0172O?\2645\030\265J\325F\343!\241\344\323\301\241\024\272", 32, "\316\027A>\233\225\212m0\037Z\277d-f\017\200\303z\334Y@\261\230\254XT\227P\301\260\014\242\266\244\262f\334\365\324", 1000, "q2\353W\236\364\266\204\340G2\337\224;\220\223/|\2132\202%\215+\362\023\340>\210\360]\217n\374'\353-\010\217\000\212U\335,\012*_\325\001\370\037\322\007uCu\037\331\242\212eb\343\035", 64 }, + { "|{v\001\223\245`d\005\263$\321\225f\344\340\010,\305\273\025$\370\275<\315\373j\304\226\350\233", 32, "\224\263<\367\330\351A*\260\300\235\337))y\221\367\306\373G\324\266\227\372\027g\013OH\321f\326\025\333\334|\013\002e\005\025\205\004j\212\206\244\216", 1000, "\341\371\031\340\344\313\002M\255\020I\333\324\265\242ra\371mhr\017\214\366\274\337\200l\336R\305\276F\024\264\035:'Hg\231\245\217\350\306\251\376\032\310\010\311\250\013\354Tr\017c\367\241\300\031h\211", 64 }, + { "\303\341\317.\250\305\257\235F\324\011OjZ2\312s\224st\2041KS\233H\022gm\354\276<", 32, "%\264\212\004p\266<\314:\376\324\250\341\3151\251 F~\223\267\032\252\245\370\001[\257~v\363\242\253\240g\042j\306\233\336\312\042\345\257:\266Rc?\011$\344\313\267t|", 1000, ">a>\272\354,h\337\205\232\204Z\212\230\257e\307D\322\263\2539,\264\271!\034Rg=\201\334~\201\252@etE\326\241Q3f\205\314cc\237\216\373\272>,\0112\010\273 \307\332z\223\274", 64 }, + { "\211\211\354\215f\332\255Z\340\337P\031\217G\266c\200J\323\042\361\250[\210\022\007R\341A\017xD", 32, "\256\303\241\352Ij\317\253XL\262\221\031\375S\343\275\225\301\033\356\264\332'\014\004\326\230\036\275\002\325\260\301-2\223\247\0041m\251\210a\356\251\274\324\204\361AP,\312\025\247^\363t[\350\223WY", 1000, "\311\035\334V-zy\017\370\244\203\300W_f\2177\002\237T;\301\261\221G[S.\037\2030`1\321\010\300(b~\371\217\034\301\276\250\023\2462\342\374\332`\372\204x\035\247\012\237ju\275\224\362", 64 }, + { " \313\304\230\206\234\222pk\244\005\2711u \340 \223\322\345\002w\275\020\324\316\224\325\036r\223;", 32, "\372\344\357\324a\333\254c\215i\177\320\300\242\020\025[\005\3252;b\277&@I\270\015}F.;\242\304!\177\343\012=U\253\253o[qR\371\201n\357\361\330\277\253\346\177^\332\042\322$\201\377\340.IOk\273\363\005w", 1000, "\310\012_\254\372k\220\263\272\361\134l,\345/\371\371\357\237\301>\205\237\237m\036\272~^L\355\0210X\221x\331\0256LD\264(1f\357\014#?w\034\023'\210&\355\261\235\361^\004\277\313\014", 64 }, + { "\373\253'\357\233\227]\260\212\305\037\273`\364\001\032H\177\203\342\012\022\225\2572o`\240\277|\275M", 32, "U7%\340\031!\012%", 2000, "\024\2525\230j}\315\267\244\345e6oY\226\027\347\017\336\134\316\355*\252F,\034\247\267\270'\017\245\201I\2735\205^\205!\205\312\221\352\216\270\274\222\276\011 |-E\301#\240ifGA\375\210", 64 }, + { "\207K/>\226\027\221N{?\037s\003\323&S\243\355$R\361\254Q\026R9\2540\231Zx\374", 32, "\314\260\226\231\312\037\245u\230\345]T&\037>\375", 2000, "\010\267\374\351\370\303s,\323\030N\244\353\252e\275\205\253\206TL\340\3205E\004\253\204f\220\362\330\231\037?\204'D\274+\367\363\316\340\340x:\230\254\313U\016\347\023|G?\363\017\037M\177l\321", 64 }, + { "\215\3425\215\223\0224\311Y\251\213\337\240nw\233\343\320\335\244U!\300\023\023\347\012w1\222\011\263", 32, "\010uJ\261\030JR\357vV\257Wd\012\004i\257\351\360\266\303\200/\256", 2000, "\211\243QK\231\376\321\212\322\350\321*\245~\311+6S\013E$\351\217\227\224\217B\006\230\212\251L\264\245.ZJ\350$!u\000Q]\021}`\022\370U\364\224\215\274%\353\333Ys\177*\265#\314", 64 }, + { "O\2649\000z2\177w\372mk@\345\277\270$\231\330\246\001\334\350\271-\264\343\307\342Nw\231\221", 32, "\201VZ\223\246\217\224\263\241AO\325\367\251\031\322\221\200g\354BM\2600\340x\276\307\246zIT", 2000, "\316\341$\022\261\303\322yZh\227\205\310(\347\233\326g\031\220>\011\226.\352J\242\311\274\247\211\010\355\336\220\214,\2440\214\311\241\253I\042^\257\361\336\241\360\177UB\356G^\325\203A\3040,\042", 64 }, + { "\177\016\252\362g\010?|\0168\364*!(\042\343\015]m\253>\012\012/\3471\205\015\321\014jh", 32, "%$\263U\023\275\273\230SxJ\363o\373\241JK\234\252<)\207\026\302\267\215\016C\357\014V(\021J\336pq%\360\214", 2000, "\301\365\314\263\264K\025\305[161\030\015\211\207\0358h\020\231\042\351\031\323\253wC\320\330\351\205Nm\216\024\033\201e\324\037\354\006Z\331\305O\335\272\333\233\243\262\271b\023/\342\320l\177\311L\000", 64 }, + { "L\027CQ\252\262\232\343\237\205\245\344C\014F4\134\210\345\213G\256.~;\240\252<\332\202(\032", 32, "\313\376\250X\267T\235\320\236T\242[\255'\0117\207\332 \2130\242kz\246}\336\321\022_\316\377\323}\340_H.\001\337\327\205\372q\022\355\013m", 2000, "\302\002\343\242\245\365L\016\366\205WD\242\015\330\375\300\357\357\020\206\344j\237\022\002\036\247\265>\350\036\212\027\242\325\2135a\320\312\344\330O\366\335=h\253\330b\216\221\017\031\026\027\233 \260\254\204\345#", 64 }, + { "\013\207\005\265\235\252\020\354d\367\342\006\341\2004\311\021l\000\256\246\241\342v\342\026B\225\333&\214L", 32, "xW\265\230\242\345\002d\230\216\315\347!\232\272\3751J7\3271\011;-\3309:\207\374\204\244\203\244\333\026\011\344\366\134\364j\324\004y4\347^\005\313\202)_\030\217\236\355", 2000, "F<\236\376\203\266\204\306\361\367/\001:\220\350a\366\035\326\374\332\244\304`\202\367oA\335\331\013\330\204\361\353$\347\206\345\231\005\231l\215\013L\351\302\267]\244\006\335\374G\342\311)\245q\301B_I", 64 }, + { "\241\021vc\346\211\270V\212A\302t8\233G\232&c\001_\263\211k\232~\241\001\305z;}\204\371F<\200\350\260%E\036\374\013Nu\200\242>\321\234\316Y\232\375\220\036\243C\250)N\375\341\3775\336\357@O\232\304\225gH\351\270\316\003V\364\003\206;\352.\320", 2000, "\360\350\222\354\320\364\042y\245\343W\2413\024\250\221\377\245\325GH\277ZAu\274\026\265\275\231\304\2722.\010np\217\302f#\346Z\347]@\216a\302\177F\233k?\326\337x\301}\230ek\300\332", 64 }, + { "\030\344U\2107\244N\237\230d\255\376\324\213\343l\224\201\325\027Xb\201sH\200\245\263\244\035\005\300", 32, "]\371\274\014\217\177([--\347Z{\021\350\330\301\134\255n/&@N/\177?\2006\2026\360\241'\3025\215\362\253\322\027\034\201mA\353>3\247\366d\327\007g\335Z\367|L\026\234\301\340\016\325\204\261\244i\036\016*", 2000, "\225q\223-\325\221\257:\351t\266\032n\250\357\002\350\003:\020\242\302\236\311\245zi(\333\010B.\311\256>\265Uue7B\030-\243((%\332\362\303D\325\242\314\243\321g\264\201\331\001@\207{", 64 }, + { ".\356\217\343\212\004\001a\027\213\207[,\042\231Xj\221\315\276HB\037F+\372B\251|\265t\026", 32, "\330R]2\031E\351U", 3000, "Z\271\372U\365\246\007\342\272\236\251\271%V\347\027Q\303\237\356\304\242\220\231\026GJ\011\031R>\252Y\223\014\017]\311\365\265>8\370\211\323\014\2027\225\304\030\273\000[Jj\204\015\025c\211\302\361\331", 64 }, + { "\333?\003\246\275\035\007?\027Y\354w\012\344f$\3309\030Rf\263\366\306\350]\332\002\221\346/t", 32, "\361A\234}\315\361C\366\227\177h\325\235'\001\205", 3000, "f\367\374\346\006B\013x%\010]\371I]\256F\042\264\334\233#'\013\271|\347\355I?#7\266\257\253\353\027\217\025\276/G\334\020'\271\004>A\033\233WM\237\377S)\347}\2357\252=\277\313", 64 }, + { "\334\276\227$\003\200y\2567l0kC1\3330\310*x>V\273\021\015\305\246=\250\353\361Y\221", 32, "\364\023\034&\371R\363\231\003\342\350\236\0131\333u\266\314\327\266-8\243\374", 3000, "(\004s\333p/\003\201\333\376F\024K\313\004\374\371\310W{\037\313\377J!\304[\303:\3329\340\200E\204\177\212p\235^\221pu~\270\361Jvl\267;W\225\034\311Lm\371Yl\301Q\032f", 64 }, + { "\221\326\310\317\321-OH\334\006\007P\374uz\213\300\226h\231G\2220E\237\235\323\030\235=\316\267", 32, "ZO\241\0178\261\034\025\311\353E=t\353\331\003\364\243}\005\343\364\006\340\024t\341w\310\303\235\035", 3000, "\363Nm\010\373\315G\216_\354\021\200I\242]\014y\026u\301\346?\273/\304\213z\264\231e\322\304\010\217\205\303\204\277.\234\371\22699L\242\342\313\027\210\316\026z\252\215\235\307\347\361\002\306\037D\302", 64 }, + { "\032\370|S\365\270uTK\326O\353r\255\271\034#\327\307\370\242\262\374\266\312\263#\277J\215\251\362", 32, "\301\225\303\340w\312\303}~\011+\261z\216\320\220c\237\250\037\011\253\300%\267\011q\224\266z\271\025m\266\361|\341\374\301\007", 3000, "\364\037VE\343\326\327v\222\042\300\250\272Mr\036\023\270~o\316\314?Z\321\232c\261\374Rq\020~\032\344\333\134\272\223)\035\005Di\205\345\012;\3076\227\205Y/Z\350\016\236\317J\253\323`=", 64 }, + { "\245\223u0\342\000R\223\240\033e\340**\244\254K\302\031\363\177`M\240$\247\361\317Y\220\227\344", 32, "\372U\371\002\134:\304\002\023\314\037x\372\231\375\241\210\360\224_}r\334\302+\372t\2741I6\035\232\226\036\336\012\211\316\260\205\220\3374\316\256m\343", 3000, "\273\361\376/\034`\322Sy\031\333*\033\134U~$b\362\363\236\361$\313H\022\243\203\306\352\314\375\204\347\223S\246\314\230jB,%\241\000\335\237\364I\000\215\266\300DR\211`\322\271\306\026.\215\341", 64 }, + { "\273G\256e\220\336\234\0325]\177\324\012\204\230\031\322\023<\020~;\347J\355\027\244\032\342\304\340t", 32, "A\350>\021x_\311\275\017\322!\315\376\357\177t\236\001~\355\315Tg\344_\012\002j\2454\002 \233\012&\212g\224\221m\242\315\353\250e\322o\004L\005<)\220 \177R", 3000, "S:z\324\320\361s\320>bW\326\0118\026b\316[\021\265\375\273\021\343\031\205u7-.\307+\360W\237\321\236 z_\347H\256q\255\022\242%\2746\032\251B\224\2446^\266\261\177|\272\010\246", 64 }, + { "\367>aQ\260\374\262\260\020\201%\260[M\244G3\337H\200\025g:\002\275@\373H\364Q\030x", 32, "\321~\273\020-L\224;2\342G\223\025\235i {\256\342 =\316e\376\014\215\221\034\252\235\25762\007\210\3158\257(\235\277i\350\272\011\016\231fb\007\243)\307\376\2409\234\011\034\207\262\307\026\230", 3000, "\307\312QT\215\034\320`\314\352\251]\210w&\203\004\2716\352\251\311\311\261\001\220\276\224\301Y\020\241\245\364L\305\335NP#$]\251\023}z\304\351\304?\214\000\354r\323\000\300\220\003\343@Q4\366", 64 }, + { "1\211\332\336\2713\223\3103\310\247]\376\015\275K\036\233\266\036\275\362\211\343\013\312\134b\306v\227\272", 32, "\134\253eO\347\267\226\220n\360+a\374\362a\314\202\304\221oy\275\020\367\201}:Eu\214\303\2002[\2270jFO\245\237<\241\323N\032\200>\314\330\261V\342\364\361S\243\215.H\012gTu\345\212M\026\024q\236\337", 3000, "m\324)\245\253\323\022\134HK\340v\314\270\315)~Y5y\270,T\3453\366\376\360 @\234\362\006\012\216\210\216.\360G\233.\326\363\253\006\031\277q\303&\215O\203\257\214\002\037\223\365\023\022\303\361", 64 }, + { "v\352_\013\314\201C\025V\042\015h\374\375\272=\361\320\337\302i<\264\275H\002\2622\321\3266\265", 32, "\361H\3748\322\242\2249", 4000, "\025\332a\365\371\230\207\270h\260\011d5`\307%\235\311\354\337r\012P\323\005\214\330\202aT\356\202\225(Z1'\237\246\177:I_]@\327\317\332\266E\241\233h$\312q\217\325\256\230L>\353k", 64 }, + { ")2\223N,\364T\011\236\322\2671\214\240\220\306m,Xt\322\025\241\013\276'/\027\022A}\367", 32, "Pv\327\262\275\253WCP\010\004\341,\227\242\263", 4000, "\206\345\207oIg\320\275\200\246~\243\233S\303\330a(\301\367;wh\212\016\243\335/\034\202\201yN\352\200A\261;\226\277\222\230\256\243\342\021\340#\006T7=\324=\013\231\376\255\216\025\251C\224!", 64 }, + { "A\375*|\023?\215\251\2717\204\366\2310\356\004%\206\331\326]\022-\234\372q\243\371\231\314\207W", 32, "\031\003f\276o\314\232\2038@\307#z\312\222\376\007\376\351\346[g\005i", 4000, "\252e\003QJl\010#\235*5+8\210)A\251\250\032<6\003\215\221\364k\211\233\312\225\356\026f\220\254\303H0k\201\2565Adv\236\247Dt\3735](\3508\2602\315\035V\240\247\013\266", 64 }, + { "_\026N\013=\247\000\330\377\233a0!\007H\0054\021\337\027\242\315\361\004\373\360t\216\203\240qa", 32, "<\252\210&-\264*1\312\334\235q\316\011\024-Cm2bX&\356\033\233\207\001&\277t\311\325", 4000, "\002R\002W\3036\276\213w8\007Y\362\377y~#\347\207+\216\225\2272\271Jh9\354*\016\361\2554\233\263\025\353\267\015\026K\016Y\340\340\377\304\015=iz\341-\275q\315Ed2n:~4", 64 }, + { "\217\243/\333S*\205\365\302\330HZ\235\347C\007\003m\364\015,\316\032$\036\274\225\317\010,\244\213", 32, ":\226\370{n\035?\032\006(\257\302\366\036\301\275HI\342\230\303 \230\301\230\226k_2Ur\210=O\3602\253\277s\205", 4000, "\266x72y\026W\037Yu\222\207\244(0K\340\305\233\310s\021\011\275\022\004\213|\210D\002\240S\276\207\000\207v'\206w\271\320\362\302{q\231\355ff\361\374B\022\363\272;\223\316|[\301\217", 64 }, + { "Yf\027I8L\371^\314Y\006*BK\36582A\221\252\030\322\352D_\266ux\377\035\367\023", 32, "\362d\335&o`\242r@\363\2426n}\234\004t\275\213\254\236\020\341\021\304.\042\321\361'o.\002\223[\266\224\233?%\004\337\240\340<\323\267\3039\220u\334\330\242\3239", 4000, "d\315\310\234\260\364\012\230\023\235\2756I\352\305\247_F\260\3602\350\324\2067\353\341-\232\020?\247\302\014\232\253\006S\016\241\320\251\000\022!DA\022\011P\356\372qL\277\263o\303\242\007\347\225\370\331", 64 }, + { "@>\004\006\352\316\314\230\032\255\237\021\276h\037i\032/=^<}}R\313\265\001\270n\267\274\340", 32, "3\245B\276\234\220I\261\336\323\014\353\325?6\360_O/I#\270S\362\331\270\200\360\242Mp\213\361\356;2\316\304\251\227\003\352\327\027\003\271\026\275\230\237\233'\316\003\332j\260\032\014\323\243SO\006", 4000, "_\347Q\374R\016[\274\365~\217(\266\016\364\253\306\365~W\335\223:`Q\301L>\033\344(\253\027\211\372\352.\355\251\233\005\036\225\134\220\034\357'<\031\227\223f\253\240[>\031\344\300+\025\243\365", 64 }, + { "\017\024\253{G\272\276x`\224}\324\216\324W\363\357o\266{Z\347\200\342*s;\3159\036\320]", 32, "/\203\306Y\243\30672\2236\257\335\233\352,W\351R2\004\237n\325y*\3525\371!^r\222\364A\217\311\370\301\3677A#9\212\030q\220r\042\321\031\303\036\003\235\274F\252\134\327XKI\344\370\215\266\316\013\3704\352", 4000, "\216o\275\201\220\001\2209\010\241\307\260\352\274\220\020\004\352`'\3552\372T\204{M\221\202oy\226\223lhIe%\260\325\303\314BX\347\331\316TN\311\332\177\251;W12\006X\376\307\235^\227", 64 }, + { "\375\367\261\310P\032\253\300s\271\362\034Q\000\267\231wh\274[\367N\031\272\313\333Lg\016\233\032\246", 32, "w4\376Oe\334\337(", 5000, "\265\320\254NT0=/r<\341)\226*\376\345\364\004\134\201\024m\020\375Z\216t\212l\313G-\232%\321\272\256\336W$\371\310]m\335\334\242\306\241\367\220\263}F0\216\267\364\341D^\212\251\341", 64 }, + { "\341\3615\215\010Wr\235\353\224\272`%vA\336\2122KT\237t\233\321(\213\316$\340\206\237\001", 32, "\337\362\246Z\225\307J\215c\244\007W\221/m\027", 5000, "z\033/\267\300\001z\320\334\020\034\255m\3321\364d\227\012\247\032\017\370C\031\340$\307TCn\004Y$\017\220\371\274/\350\306\303\002\012,]T\034\301\017\3459\365\252\032\321\316j\231\245\341\322%)", 64 }, + { "\355p\310\241\334\272\230LP\241\235\324\302\312\202\002bm#\375\324\314\266L\212\016\340x\0370\333\304", 32, "\031\3057\204`\205\372\200;\320i\264\027I\007\027\267*-\365K\134\243Y", 5000, "mB\302\302\253l\313x;_y\012{\273N\340\303ohA\210TQ\310\321[lK\015lWL/\252\134iB\224a\265\207+[\016\241\330\005DRam\250\335}\356wZ\006\015\256\226a\216h", 64 }, + { "\240\367\032Y\306a\312*U\314\322\335\022\016\377\213jMmr\244\042\274\257)\267\220\3307\221\033A", 32, "\027\277\033\343S\023\203\300\354nzy\226\254a\307\2146\215\033 p\256\342 \016B1\015C\027\266", 5000, "j=:\035`\342S/}\343\240\311\033N\227\377\327\270|\215\353\241\310\206\042\265\367\206\243\222\315\023a\303\274G\037\245\345\323H`\010\231\344\342\351X\001^r\353\314 &\234\024\002\242\317\021\254\340.", 64 }, + { "\250\277w^\361\217\026b\210\177\306\3461%\252=\266\234A\211\002q\264\357e\232\3257;\036-\362", 32, "\261\363r\305^\275\322\224\3328\261\352\242\275\201O\317\275{\020\263{YD\241%2;\340\352?\366t\300\272h\351W\303+", 5000, "d\364y\350\264o\356\017\320\011\2317\326\027\254\033V\326/\200\276\374\360d\321\265\015\212_x\017\246bE\003\256\337F\265\260X!N\354\031o\216\335O\3278\202\027\222\266\262\356\311]Ok5=m", 64 }, + { "\374;\134\361\232\355\314\370sC\252\275N\372\2732\335\213*\232*\310\352\0312\0047\3758\230\022\010", 32, "\332\205i\265\023\022\002\372\234S\253,W*\303^o\204\316\360\332\353\237[x\030\210\2003eBX\342u\224\363\232Q\262\220\212`$\026l\207\330\302", 5000, "d\021\307\254\221XR\257$\322]9\306}\306aqr\333\224\337M\266\245-\001\2148\203\346\002\032\031ax2\336\230\024W8p\346\310\300!\213\203\241\306|\222\206i.\272\251\026\022O\007\207\262?", 64 }, + { "\204K\335O\134`\227I\204P\241\370G\324\350\313\305\346X\221\312\313S:\371t\341\011\275\327\301W", 32, ";h\002\331bk\375\014\232b:\334\367\341\361h\261\005\266\265\316!$N/i\201\002\272\005\351\212\031<\332Y3A\243\036\303\254\255\317\317\0356\020LD\210\337aU\007\023", 5000, "\002\036\314;\347rW\266\310(9\304\223\015\220\367\334~\3175W\354\233(\372\177n\304)\270\221\352\233\256[\370\320\222\042\202!\265\201\251\262\214m\234N\352\371\314\2724\201\001\272\3643\347\265/d\205", 64 }, + { "I\304\026\242\014M\013\255)\257wq\205\273\337\252\256\2626\233faR\365\262\257\010\010\333@~\322", 32, "\377\235?i\251n\222\2608\250N\304r\353\331\313Byx\236u\212\340\322\243\376y=fv\367\244\303\232A\214\244*p\253\333\134\335\250X\223\320\325R\311\243G\2524\337\344\134I\340E=\253\300\301", 5000, "\335\011\020j[V\242\266q\257^\2139\027XpWl\367G+\224\210\371\320\002\2170\007\223\361s\271\033\374\134\301A\320\234N\357\252:\343\275\025'\012\035]\311/H\341\315\310\303\310}Q\021\375r", 64 }, + { "Dml\351(\305\351#\355\004||\231$h\227j\361\3136\210l\375T\213\315\375\234~dF.", 32, "n\353',\204G\017\242\020\255N\026Io\221\224v$\324I(\246\016\036\035\374[\343\260]\326\021\013ne\371\356\301D\350\030k+\357nGJ\270E\262\035\351R\303\010f\233\246>\326\355|:\2552\003\021\234>dr\313", 5000, "\220\243\001\307\364\032\262\304\372\017\266%r\204;\301!\374\042[+,Z\321\373\020S\014\243s\305\335r\331\350\370\216\277\267\224GT\035\301\030\261\237kge\006\017|z\220\224\274\033\215\201\301\026uJ", 64 }, + { "\270\0170\011\344\012A%\357\323\236(t.v\263l\231\00450?bA\325*?<\251j\256\230", 32, ";\354h\272\035\251\026\346", 6000, "<\220\344\337G\206\302WjF\342\302\323\276\371\3105d\240\376QF\003 VL\024\357\217%\237\331\360g\326\362\224p\322\032\204Y\254\230\227A\2048\201\023AaN\363\264h\347F\222'\232\352\356\042", 64 }, + { "+\2547\326e\016\371\243\360E\373\0228\222sO\203\374\322\204\247\240\320f\227\201\364\371\223\323\216-", 32, "\215L\237\227\342\276aw\036\025\374\246\201\030\010\352", 6000, "oT:^\276\374\027\266\300\375v`Yz\330\206\325[~/\134\364o*hW\371\213\375w&\275\006\011\361\037!j\370\317\337\301\346\234\341\354\225\321\264\305\346iz\313&\324|O\305\317\2629?\022", 64 }, + { "\354\332\023}\256\222\332\241 \362\302\351MG\3479\276\332\334\023\362\271\253\211u\275\200\334/\246\013\244", 32, "\266\243\134H\272\356\332/\011\305Q\357n\371\354\001\020\307\177\333\037\362\315\242", 6000, "\306\231\246\333A\300/\22328l\017\305+\010\037\256\341\202\313pq9'X\264(Z\246m\177\300.\352 \372\20368*\274p\305\033\2251ar\211.\2624,\326B\031\134\335o\033\310\037\2469", 64 }, + { "\327'\333\2626\365\015l\373\244\377\016\314T\205\023\255T\244\217\346\304s\275\370\134o\226\241\000\3653", 32, "\204\340\237\333\347B Zh\352@\2206\262\303\002|\312\203\327\333<\372o\200\035\276G\210S\134Z", 6000, "\334B\327\177g\003$\351\375\134F\266\375\211\212\241\366y\323\375\373_\267\215l[\203\305\370\216\202$p>\241\264\377\032\022\211I\257,:&\317f\245\242w\364*q\037.\347\276\277\275\244\205?\034\317", 64 }, + { "\234>s\026\201USYC\367\314\261\324w\355\264\037\377\236\274\021\3211\006\372\354\201\250o\20011", 32, "'&A<4\356\331\213\213y\222#=_(\361\346\226\350\3564\177\261\024\350\3528 \331\235g?\007\361rYB\003\220}", 6000, "\304\232K\203\301\022\0351\220\354\260\350\311\321\337\023\264\354\256\365\333\215\373\325\201\274\204\216\310=\252y\006I7\250Y\210\204\226N]\036h<\016@\231$\234\134\271\357\307\225\273\331\245\272\2650\357q\203", 64 }, + { "\351\000z&j\354\276\2739+7\300\022\264\327\244\275\345\003\365>\204;\276\217\307)`XP:\345", 32, "\234\365\001{\277}\042\367\222\230\030\327\264\201\016>\241\001\037\336\340z%>\324\032#\352\204\351\212eC\304\027i\205\362\215Sn\226i\215\313\374\210\354", 6000, "?A\017\245L]\214\344\373i?\212\306\252\013Lg\277\015\256\260\001\306C\375\354D\025L\134\337\263\363\025V\336\227\013\237\353>F]_\035\314D\240ES\253\357\210\344\014r\220!\222\220\010\374-\265", 64 }, + { "T\217D\316|\373{}\037\354\234\177S\327\270\016-\231\316RE2\376E\030\245't\005)<\200", 32, "2\316\204\337k\213\260o\273\020-\351q,\220\202]e+\376ci\312\367L'\331\237\035\024\025,|\323\220z\332\211B\314\226\261E:.\002\0238\376\315\320\274.&\233\036", 6000, "\312X.<\3273\237\320\2349\267Rg'\337\230\326~\223\323}\204\010\005\352\035\221\223\244\374\262D;O\2356i0\311\333\360W\203%\321m\037\3220\267\0162\254w\0161\342\320\031u\206\032\370\271", 64 }, + { "D\243\026\222\253]\312\252\020% ^w\024\024\377\312~Q\221\334t\215\377\365#\353\305\340\273\341\364", 32, "r\012Vc\246\013\020\364\221>\227\273DJc\233\2373F\235\001\307G\223\210\260\033\236\361\365J\037K$\372\245\270\370\2402x|\360\033,\002b\307#\305\026\345\2572\325\241\321Sk#\364\035\342\363", 6000, "\342\3053\272\022\221\021F\344AvW~\350\355\314\342|\303\324\315\002U\311\236\315#\2776)\3219\033.T?0\035\264\207\350d\247\247\042w\365\371\262\217\2051\001E}\201\301\034\025\177\016\314\246\312", 64 }, + { ";\370<_m\217w\363\0054hx\333\347:\247\033\337\364\363n\370\042\244\303\014\306G\322\027\323U", 32, "4\331\020,\014\345\314\367~DR7\345\013\2001P\261\273\333\257\306\373\300\033\361\257\256\271\362\302\134\342<\320\301\224\034\034g\033\206\022\005\220N\260\014\207\347\265|\206'Q\323\214\276\305\357\356O\355Gr>\237\204Z\371\354\375", 6000, "\027\304\207\017\213\207_\0117\262Yu\004\012J.\274\307xu\273\372V\004z\243P\007n\363n\222:A\311\351\031\212\2748f\352@\217\347;[@\177:\023nq\260\221n\244\014\246*\361\033\212\042", 64 }, + { "~_\236f\256=\004\026S\320\325Tz\237U\327d2#w\202)Ir\003%\220>$u4\215", 32, "\372v\342\354;>9\312", 7000, "\134\017I=\243`|\314\225\014\263\254K\014r\372l4R\015<\3138'3Pw\214\3051 J!^G\364l\334\037\314\177m\220\247\321\001\307P\317B;\316\037BC\246\310@\250\250\367V\031\223", 64 }, + { "\371\311\302+J{\330+%\236\312\021P\377\377I\235\356\2664\000[\270Q\042\022\357\235\374\307.=", 32, "r\244\035~\327Y\310\266#\364\324D\203hd\266", 7000, "\272\304O|Wj\3136{g_+\347\355j\265/\300!lR+\341\231\2032\322:\032\272\350\331J\347Q\203DQc'4\335@i\347\334}))a\004(\313\255\3220\206\000\346\014\206\206\365\012", 64 }, + { "4\203\215\242\377.\236%\324\260\315@\275i\310C\241U\350\363\3107\337\371\2607\223\036\015:tQ", 32, "y;\315-J\314\274\357\264\210\020\222\007\240\272N\015\331\370\037\334Y\267\016", 7000, "\351\334\341R\305\301\022\273C8\001\000\270i\226\343\304\016z\322d\370_Q\377\2671\215Zu\376nS\245\030Za\374\353\255\305H\024\202\024\0110\037i9\003\363\337\377\304\214\331\207\366\226W\012\307\376", 64 }, + { "l?\242\3334\336\353R\233b\216|C!\013\000\022\274^$xfn\231\237!\037\357k\351\345\374", 32, "\005\276\347\3550\023\213\226w\2313\312\351\253PuJ+\027\003!\255\322\340\006\334__\017\317!\341", 7000, "=\015\237\267?\333$u\274\201\353e\204.Zls}H\344O\020!W\036@\222\362Qp\013\212\225T\274\265\256\024\2221#v\245\254\203K\202\020\355\0118\262\001\333\346\364\332\240\347\017\3227>\245", 64 }, + { "\027\344\376D\230{\335\276\012\027xc\247h\300\221\253\2004\231N\337XVPH\350\177\202\324\336(", 32, "\014;\3008\375\017N\372G\354\331\201\031\263A\027a\351\315\256\344rE\326P\247G\375\2502\262\375\353\344NA\035\317i\212", 7000, "Y\222\200\251;I<\227Q]\356\335\317\263\351\231\042Q\322s\313n\006-P'RKDZ\330\237q\213\332\374c\266\022\352,y6\231\226\001\233\354\027\245k22\312\331^i\026\2764\244\353\306\251", 64 }, + { "\267\366\277\006\327\363\330(~,Wd\275\303A\203\315\016\230\333\327X=*\326yB\364\213v&%", 32, "\274M\257\261N\266.k\356\343p \331wdX\324>\366a\031\362\207\3732\323\302\255\013\212r\003\321:d\220\200PI\010\0029HA\011\003\326\220", 7000, "i\364Q(V\223\200\223\340\007\374\330&H\342E\032\215\2515\3556X\022\215O\365\363\264\247Vwu>\371\320\332j\305\354\267R\323\022\274\232\216\262\361\301\225\3124\004\215=\236\237\341\347\365z(/", 64 }, + { ";~ \241\225\021\325\357\016\232\310=\214\261\3451\270\316\233-\303g\361\216\033Nxz\377\361.\236", 32, "\272x^\233\036p\375\304\204\200\034\306\224\352\307g\361\310\003K\224\276\211%\202\336\346;c\207\240A\021\005\206\255\006%6\312\233G\017,3\230\310\301\202\226A% \0341\353", 7000, "\331\326\014\373X\343aJI\247Cn-?\201B\223\271R\230\015\346\204\350\350w\012Y\373\240\265\020\274\232\000\366\207s\263\360\323\0254S\226i\007\371]\354\314\015aV>\337\303\260f\030\275\214\233\372", 64 }, + { "zt\362W\316\317\032\273\343zzZ\207)ZLm\224\345=\350_\361:\033X\324`\305\306\202-", 32, "\010\306xU:i\204\2235\375\346w6Q?\036\010M\267\275\265\240\223[p\022\255\213K-iKnR\263oP\263\002\036\331\200J\363\365\314\214\036\026\343\304\316\352=a\211\274*I\340.\266\015\265", 7000, "\337\242\214[V\263\350\233\377\006\301\201\275G-\365;\260\241\030\035\355\010\242k\361,\271\344\377bB<\304\242h\357\015\225\313\203\266b\031\322\270\235\376\365\351h\212b\2250\317\2567\254\033\223PLq", 64 }, + { "\004\221\352\003\252\354\313\377UT\030\207\205\362+\004\033\015\2140\004\261Yr\001\340jA2\241\2625", 32, "\256\300\3735\301\013\223\035\221Hl\304mj\340\375\215\254\337\0332\3472\274\254g(.\323\322g\0122\177\347\377\343\353\271t\010R\024\215\331\033\0027e\237\305{U\034k\357\220S\240v ;R\266\177\344p|Tw,\230", 7000, "\335\227U\002aP\016>\270\376g\266\312\211+\305&\013\273\312\262\364\365*\002\227\256/tg\007\341\3777 \351\323\337\031\246\025\227\301!\330\221\032;tX\007\030\004\353\004oX\277j\250\257\323J\230", 64 }, + { "\347\324\310U\204\323j\341\215\317&\325zo\327\025D\024&\352'gZ+>w5\256x\3500\353", 32, "\311b;\237!Zc\350", 8000, "\032\210\262\273W\324\134P\216\315\300\312\325\270\346\032^\031\022\260\372u\313\336\234\315h\005\264\2010\373$4u/\271\311VX\226V\304\261\042B\241A\227}\265jR@O\3651\364!\012w\246\335\200", 64 }, + { "Dn\207\341\204X\030\206\355vO@\340B\275\354\000\023\311\265\225T\237m\013\364\034\247\353\217\316w", 32, "\372\366\303\033\331\272uy\262\371j\302\256\356\334\257", 8000, "\250KJ\204a\031\225\204\016\325x\310?\230\013\2070\322\302\263\231r\264\001\240VR\237\270F#\330\353!\337\330V\256\223\357\262\030\2421\205\037x\272\305L\350Z\031\245W|\360\325\305w\223\020oc", 64 }, + { "\355\015e\250>p\225X\225*\011\316{\311\244f\364g\372\300\336\351=\216-W\324\257\316\373i\376", 32, "\226l\330`I\331\035r\203A\354~\251\373^yQK\322\343.Z E", 8000, "70`<\225^\221|\350*\017|\244\004`\317\221\134\376\352}%\245\324\360\216IY\042\311l|\201\350\230\210{\346\034\271\264R,&#\001\337\261[I\357kBl\336\335\213T\352;\015\024\301\033", 64 }, + { "\317|uV\275\303X\214t\250w\274\335\0028z\376\025\223^2\326F\250i\006\024\006Jm\303\017", 32, "\012\375\360\206\245\022J<\212H\177\267\247\370gr\326\322\251\011\324\331\010B^_IC\317JP\327", 8000, "`n\314\361\221\2161\263%w}y\006-\323\010S\354\240\332\026l)\325\266\023\013\036.\273\000u\247'\273Y\316j,ap\345\206*\264\324inn\022\203tj\260pb\023\210c\306R\234-\320", 64 }, + { "\231\230\221\276\330\2648\017\330v\311\346E\364\272<\037\243'\355\356\252*\210f\006\036\206Z\346[I", 32, "/Ws\213\262\202\020\005n\351i\334\233\303\375~\374\341\251]\227\247aeU\246H\263\031\035\015[\250\316\205\031{\222\016\205", 8000, "T(\016UCC$\370\236\251|\013s\237\023\325G\014\327\376Q\013\306\244*\233E;\014\264sZ\2449\242!m\200\243\264\342M\257\0350\370\357\224\373\262\201K\023\204\334\320\340\016y\272P\311A\217", 64 }, + { "\372\310Z\030\0367\234\257\361J\306F\267\310\216\2069+\013\224\275T/S\257\3554e\177P\243\134", 32, "p\237\036hc\362\305I\350\222\316\022\310v\240\240rE\200\277\241\212\245\330\260\035y_i\374\332\240\304\031w-QX\357\022Q\025\343n\371\273D\201", 8000, "c&\346\353\305F\004P\307\212\3268\356\255\252\225vy\214\213%\340Zz\242\252\301\263R\344qUhOG\334\363\177\203\030\014m\241\306\313\366m<\322\241\254{\334A\007\371\035\0210\211\320\357\042\014", 64 }, + { "\274\023\233g\226\220\266b~\011M\215\240\304:\345\216)\2338O\031\205c2nj\364\332\245\252\275", 32, "\023x\251\256\246*\363\004nr\336\240\357\031\011\315J\210\243:\023f\263\202H\333u0s\323\345\2516i\212\012>d\344\004\231:\217\371%P3\004\333\225M\037\321\036'z", 8000, "\305\373\334\202\333DvE\007\302L\246\273O1\312\006\327\203m 1\227\322\262\275\262$}\343n\377\275\325\034\323c\242\337e\352\247\217\264\200\276l\203\207*MG\245wI`4\261\200\025w\277\374\273", 64 }, + { "\310M\231/BX\015\3022,D\221\343\336{AB\373\305\232\223~\332\001$p%\236\311?\307\255", 32, "\346\237C\3322L\307\240\003+\342@\244\356\210\3652@\231uyajh\3672)\3133k\015\247\011\221\360\256$}G\232\326\344sB9\266\326a\273\276\273t\134\330Q)\2555O\212\204\207K\251", 8000, "Fg\027\253\252e\334-\306!7\300\374\277\235\274\261\350\005D\327\262\302\037\025\016\306|p3+\031\230\216\224\362\370&34\314\240LA\326\010\307b\371\177Pw\310\2605\210\275\305q$YPw\024", 64 }, + { "\243%\302\344P\210:6\271\3316\330|\234\377\325x\317\255\356u\266\204_\264\232\306\221H\235\323\233", 32, "\203\355\374\337L8\346\314\340\310\310)iB\261\313\303`\254\263\356\011\360LVf[\240\372\033\263\031 \237\361\263\264\007\257\323\224\205\207\366)\344\220\270H\216\005K\310\200\256~\341w\352\365m\305\316\231\315!\354\232\270\030\327\027", 8000, "/p\266KV\336\250\270\214\3752\255>\253\011\261\353Lu\022y\313+\300v\201\005^\333\310\370\016\375x\023N\340v&\222\042\353W'\277\014\226ss\240\314T/\020\347\2303\225i\337\255\217\275\310", 64 }, + { "\020\352\211\2704\337\355MK\251\237\315\207w=\345M\253j\013Q\312A\323v\256\212\273\346\314\206Z", 32, "\356\327\312\324\304XV\042", 9000, "<\252\305rA1WHK\030\310K\220\312\214/\225\222#\211\020y5J.\373.\375\250\246\344=U\326_\322\205\303\357\316\212*2\252\1347yP)/y\330\030q(;\275\222\316B\345N/'", 64 }, + { "\246\200\343|\000\363\320\004c1/\252 \230\027f\221\010\300L8<\315\333\014\000~\013=\224m`", 32, "\344h\347\244\325\331\22483=Nft\360\302\261", 9000, "\330Y+Q\337\302\005\230&\257\271\201\020\266\346rXi\310\342\234l\365\374}\242\365&\377\214Fn\240\315\272\026\322\326\2318\332\325\001\362\007G\316\346T\001\225\273\377\042\345?\377\330\302\361:\354Q\270", 64 }, + { "\300^\277,{\327^\347;\023\366\331\344\214@\224\226/\231\304z\212\024\264\343\305u\353Y\301\305\031", 32, "e0H}\001o\0238|<\317\200\275\255I\300\2211SZ\350\024\010x", 9000, "\346\352\302\366Gt<\261;\010((\022\360\232w\323\024~\3107\323\001\003\331X\006\245\235\364V\302\000\233~9\370\225\340\312\2120\011\362\274W\036\272\270\3168\311d\366\361\270\254E\363Zg\001\326\227", 64 }, + { "\302\3170F\365\303\367\304\340\000\332\3223F|\363\231o\336\315\010\334\000\327\225,\300\205\214\301\272)", 32, "\017\015*/]\217\334\262S\312\317\235r\371m\225\273\013\215N\360\016\324\003 \257\222\315\371\014\326t", 9000, "Q\213LROW\365\360C\375\251\233\235\237\273f\370\333&Qv\035\231bj|\2621\134\365\213\254\264\221\377N\321\305\036\272\236I\331K\375 \276\212\177R(T\370\030\376\322\201!a\230\014g2\330", 64 }, + { "VW\226?\011\206\237\332\316^\201\211F\363\242#\2414\260\034f\253F\020\015\356\022\026\030wy\207", 32, "\134X>oO\341\2221p\023\236\217\357\355\213qc\222\237$q\311\271\224\317\005\354\243\010'\365\246Q\371)N_\226\353m", 9000, "\310Z1\202\257\017\276\0118bF\322\213U\222~\243\033\323[\324\371\365(\344R\363\347\313\342\255\033\320\316\374]\207\371\004\353e\311+\316`%p\236\327\326o\017\235yu\234=+\216\303\3420\246\333", 64 }, + { "\265\321\227\226\355\037\225\225f\000`\331\364x_h\261\236\302F\356\277\305\203\337n\324\242XlX\276", 32, "\353\325\230[\314*\371$\233U\335d\302\356+M+\217K\255:\305i\217\315U5dmm1r\034`^\033\200\311\366\323\244\254\134\354*.C\261", 9000, "\203\205\206;\334K\261)~\005a\365\232$.\246\250\333\351\036\237\227T\326\007\266\277\337\267\012i\252\277f/\367", 64 }, + { "g\342u\261\360\205W\253\3757\224>\2007\261$\321\326[A\030Nl>\300\255\270\310j\230\000\317", 32, "\205R\344\134\355S;_$R9\207\216\351\035\355\344\246\230\347\305\225y\365'\264\273\273\002\3004\3074\321%j\237\246\352\345Y(\224\334\371\274\012WL\232$z\246\331m\020", 9000, "\042\307\336\011n\273.\027\006Z\200\335\244N)\210\325\177M\000\270U\2167\007\331\217\002u\262\030\257\223\325]\371WI\207\226\211\331s\007.\224P\3330\023E\273\3256\324\2250|h\332\134\306M}", 64 }, + { "\205\222\255d0\015\236\365\024\002w\355:\025Q\206(\000\014\315*`6\343\233\217\377\036\227\231\001\310", 32, "\031\345\002\252\206*\014\226\235[\012\333\340K\207$\010\010\332s8*\346|\245\323h}^\202`\233\200\2460\304H9\031H\2321x\013\033\363\322=B\223\224\321\2335\204\262#%\245#N\236\205\360", 9000, "\376\304\247X\265W\252\204.\025\177:\360\227\0259$\005h\205\364\030o\324p\023\206\006\325\302B:\311\252\240\015\253\000\370\313\007\002\276:\037/\001\240-T\241\221\007\247`Z\012|M\027\316\2303\004", 64 }, + { "\262\332x\2240\1348{\351ow\377\220.\005\010\351\313\365w\310\006\042\312O\234\256\254I\225P\236", 32, "\003\262\327\213\033E\352\255k\031x_V1\330\217\232\333TCjCG\257\222\207\302aA_&\303\022\242T2V\301l\230U=\204\255\013?9\212W\217R\254\246\264J\310\243\340\215\276\324\264\211\371H~d\334V\0048\210", 9000, "\2428\360\032\336\004$\015\303\304\203\271/\302\252\361\204\366\314\201\231\324\323\340\031E\355\205\372\201?JX\264\256\177\242L\362\001oc\310\134{pO\232\234\200x03\270\364@\346\134\214\330\202\010\254\350", 64 }, + { "`\210\003\226\023\271\363\251\376u\032@4R\227A\233\177\204+\331D\302jJ\035I~\033Va\334\306\134\337\3708\3159\374", 40, "g:\354\200:\353\237\314", 100, "\247\204y~\264\003\374\263YbJ1\265\256\370b\020\377?\034\240{\014\275Z\011\347\213\206\356\037Q\010^\306\207Q9\021\374q\270\242DI\034-\232o=\212\202\134\037+\305pB\2152CI\275[", 64 }, + { "\330\3067\035\364 \2267\266\226]\315\242\015X{\270Vn9\260\277\277\375a\014\251k2P\003f{Z\037[t|o=", 40, "\375\276EL5\306\235A\371\032\272\364\014\340\014\374", 100, "8\255\030MN[\002\3162\250\340\323\262\011O\0374\012V'\303a\010\026\372\337\022p\002\321*\032\255\205\217\377`\264\015\255\217\005\300`\352\261\313\370`\217en.\252\205V_\331b\261\302g\333\273", 64 }, + { "\247\3113>'\341Z\226\015E\235\221\200}d\217\021\263\134r\205NX\241\366\014\257\243\261y\212r\263D\272\243\021\207\235\216", 40, "(\213\353B\221\216\0302\003R}\310}\331\006\343\001\333\326\236\017x3\005", 100, "\261\201\255\301\037\027-\004\242}\361\027\264\250\210r\231\274=d\010\371\2662\357\017\233d\224\230\0300\356\273\264\245\212A*%\333 \326(c#\273X\026\312\226\317\031X\257,\353\213\307\254\304\337C\326", 64 }, + { "\024B\327M\362\134\210]Iu3\223\322\277\361\3646\276H\263\030\2348XC\271\206d5\242\231\263*\334w\317\015\376\002\014", 40, "\321\357!\351~\005{\304\267\313\205\027\005\307\232a\367\212r\302\306\032\231\26567\246\356\227!R2", 100, "`\236%\333\327{\331~X\022m\274\337\203\257\326\012\247\021\326\270l\3271W\244A:T\261\250\252n\230\327\231\305v\024\245\371\377\346\007\305\204\360\215\252\267G\007\005_E\0221\223\340\3714\243\220\303", 64 }, + { "\002\325\230\270\245\022\320|\042<\274\236\243{IF\255\2123~1\324NX\343\212\002\230+,\321\253\320\334\246\273\264\265\215\350", 40, "M\361.*\033\362\022\226*k\333\225B\320\377\266\011\307\034w4s\274\316\217\034\221W\373\003\256\244\210e\260\242)\206\254\223", 100, "\371d\211g\2024\010\257M\023f\177\247\376\000e\036\353\372\375%l4\272\370\026\343\330\240\022L\214y\025\235\360\0213\014\375B\326\331\300G\336\212}\342*,\254~\001B\204\370\200d\254 \303E\367", 64 }, + { "\243\035i\361t\264\370\31688\017\261Ph\267\224\271\357Y4\035gZ\2631\021\253\236\364\311\031E\364K\240\313xi\253o", 40, "\313h\035\345a9\260^n\335\014\337v'\371\330D\215`\332|1\357\023\253\215\213X,\215h\306X\244C\232\236h\256\372\247\020N\275\020d\360\005", 100, "{\320\345i\277g\336.\253(|\256\347\302\022\260\330\315\247j3\217\257\236\260\302\024\204\000,+}I\202Ow\321\205\013\315\324\001\332\331\003\367E%C\205\354\345\366E\314\351\032\340\314\2568\233=#", 64 }, + { "R.\220Q\306\005\331\013_\274\263\364\305\363\253ut\215T\042\354}\011\014\256\254J\245c\353f/R3s\342$<\205\366", 40, "\042L;\375\240\241\376\322\232GY\375\004PV\261\331}\305#d=\210T\261\233\246\322\377\365\350\365\304\202\256\264\003WX\021=\273\247;\007\215\377Y\360\212\004\324\2525\260\223", 100, "]\370(3IL\232v\357\336\347\350j\3428=\337\205g\331\211=w\023\373\311q\321fM\372\134\037o\312\270\207E\232$\246\224\0069q\245;_U\256\207\246\224~\265lfX\217+\241\177\012\000", 64 }, + { "\005F\364\361\037\250}\236\013\315z\330\022B\011U\222\372\236Z\033ZH|G\313j\247\263\363\222\350\362\243~;8\203\276Y", 40, "'\006e\223)\331-D/\272>1\236\236\202\360\034\015\253\305\312\036\202;\306\254\036\313)\235\011\217\270y\235 9'\355cs5\311\300I\042\235ls}\202\364\002\303S\223L\3528\262\305\001\203\011", 100, "NY\261\274\311\225i^\034\326=\353\301\204\312\357y\263r\031\234\240O<%\253\221\022\321\264\015rH\311\327\302\201yi\304\360\3748z\036\022\205\236W\026\023\006\256B\227mJ\234\231\263\253\3368\202", 64 }, + { "\006\336\254*o{\322\024\361\337\007S\353\357\243\370\244\033\261\024`\3159\311\001\027:\342h\275)R#_S\030\217V\336\024", 40, "\001/Wmb8\260\026\246\270#\346W\360\277/\347\177\233\322t%|\226\334\261~\001tJE\326+\204X\304\324&\036\134\252\004\362\020Y\347V\245\015\023\332EQ\345U\002F\321\202T\012\356\313\235f\206h\356]+\314\324", 100, "I\177\227\177z\320\023\255\352\036\233\272\216\032\231\236\236\220\034\304\263\006x\212\004\340~\371a\034\375R\254T\321\237,\351>\367Be\335\020d\343\363\216\271\011!\344\345\271\325u\006Jdv\004\350\277\301g\007\211_\336", 64 }, + { "\011d*\215\352[\313\3051?\362\360c\277?7\1771\306\221\271\022\275\205Y1E\240M\214T\225R\363\010\3130!*y", 40, "\310l3\2262\346\215Z\223\005\236\302\241\025~\276'\334r<\030Ou\273", 200, "\022\251\266\330\274\244\022\001\042g?\014Q\334^\032\320\203\004\023\231VI\236\351\032\234\200\220\272}/\255\356\322C\342\315\340mR/\024\003WvC\362}0\204\274x\315u\216\014\203\337\353\0350\216\241", 64 }, + { "N{\366HE\323\251BA2\337\035lQ9y\377\206_\354\217\210\210\237\301\277Tm\234\001\033\237\200\261:\314$\007Ro", 40, "\226L\252\227\244 P\217\303\022\353\351\357u|\367X\206\134h\354]\006\257\247b\277ug\266\371\305", 200, "\331\343\322@\363\303\324CF\204on\225pD1\260\342\250h\337\376<\376oqrOrC\260,\014\330\234@ \363\236v\206\201;\335\020+\253#\232x\267-\035\035P\010G\277\322\200d\241d\337", 64 }, + { "RjMU\235u\300\005\020s\3026\244C \010T\277\204\025}6\221\260t\030\347\262y\246\004\004\022nP\003E\224B\275", 40, "\361|Oc\337\006\334\314}y\037}5'L\363\3776(W\331\015+\005y\211\036X\006\33121\012Y\017\011c\016\353\025", 200, "\037^\036", 300, "^b\177X\310\203*\016\340f\343R\233\025\025\222\017l|R\203\227F\217\311@\261\207\325\013\273\042\375\260\256b\333\036\221\220\026\377\223X\336\243\217\235h\006\3110\231R\314\247\3401q\365>dA\010", 64 }, + { "\350$\307\023\016\225\330\3677\315F]9\3447F\306\036?w\000w\266\266\214\244|w\354\204*9~\331y\262x4\237E", 40, "\023*\200k:\322 \321O\214W\374R\223>\232G\202\230\223u\231.\266", 300, "z\223\217\302\200\321_U\300\304W\241/a~\367X\24385\244\207\224M/\255,\232\252\366C\377>5\312\210\273k\001\377\353>g\204\032>\017\303\207#1\021\373\257\031(M*\014 h\334P\370", 64 }, + { "\341\320\235C\357(E\316\332\224\353$\002\330\352{m\215\310l%\255\247\035>fQN\270\217\001\211\355\265@\2036W\263\210", 40, "\232\001\020\307\220Q\244C\312\213%\0206bK~y\272Bh\302\323D8OE\205\323\356\003\235\300", 300, "\227\366^\335\033\330\023e+w\242!B*~t\226\326\322\201\020\251\025O\336 \302\354\355b=\3732,\304\311\025\005y\032\376\005y\347I\031\260\336\360puq/\340\235\325(\337\023\344y\225Hs", 64 }, + { "E,\342\3250\250\275N5\307?b\016f\215\200E7\3260\2062z\026X\243R\245A\210R\014\262\240r\305Z\303\211\042", 40, "\213n0gD'Y$\2742\031\330\027\247\253\343Y\345\263Y\335\354\270\0275\205`\015\227\002\3527\336\367\354\337\024\204v0", 300, "\305\042\312\304t\351\241\223H<~\212\257N\201\022\363\032~\231\241\373\300L\344\333\302F\272\233\306\037\231\260\236\243\326\035\370lOM[v6N\214\042\362D\224\001\372\316Z\372\220t\177\301>\020}2", 64 }, + { "&\3372)\301\232E\222\030&{\236\272\013\210\011\034%1\352s\310\341^\310\251\352\177\257l*\3071}\343\011\317\377\012\221", 40, "\332%\357\310,%\202/Ei\2600\0219\256\305\225}\344F\273*\231\272\317\004@G\334\242\311\270F\0232\240\264\003\234JL\304P\2627\271\234U", 300, "\017\356\256\272\201\031Kf\300\365Z\246\362Z\2765b\346\272c\011\222\241\033\337L\356\323h\034%\001\270\020\016u5\251\030\013u\343%\361%c\005d\242\340p\224L\255\261\370\025\216=9S\225\027X", 64 }, + { "\023\225\225\225a\205\3544\023J\002\345\037\024\217$\252P\240\347\025-\206\0266wn\353*Jx\327\323\213qo\322~JV", 40, "<\225(\247f\351\21182x\003\036Z\333I\376\347\211\037\340{\241\0017jPQ\037\206N(\365\354$$\001X\253\3713\253?\263.W?]\260\327')\347\200\240%\354", 300, "\362wD\306Q!\204\002\0347J\363\256\214\210\3030\266\007\3170\323\346\375\301n+\300\010\025\345\010\0316\363\344%*\377\360\260#\212Ut\324\347\334;\011\356(&A\207\0332\013\320\3060\367\271\333", 64 }, + { "\267\244\274\263\273\230jf&\202Y\220\226\354\216\363\010\031\206\326p\363ux\3536%.~<\213\324;vCi\0217\004\311", 40, "\230\250\225\200\265%,\326\017\035?\274\237{D\272\224\303\3037ea\205:\042\022B1\272\017\275G\263\317\344 \306\204\233\244\273\254\235m/1\317\223\344Uf \273\372.\305\306?\005\011[\217\302p", 300, "\360\214I\303\037J\034r\211\204\333\023u\217\274\134\373G\024\327Z\016\331\022\210aOM\014\212\226\240\257N\215nH\266\343\006e?X\244\370&-\313|\252%\353\351{\345\340\004\345\271\004Q\314^0", 64 }, + { "G.\325\033\317\202j\005\253z1\227\033\207\2061<0\003\311+\3337L9\264\004h&\027@:\030H\331\313/N\270/", 40, "\006\032\324w1\247)\271\337H\335\312\316\2467\214\042\207\245\373\361\250J\207\354c\253f\371\001\276o\343\300h\010A\300\366\331\301NI\255\322\270\350lf\246\020\257\263m\231\311H\3175{>\257\223\313\262Y\245\254hghv", 300, "d8\023\233e\020}\215\007\036\002\367H\003\367\336\010\260\364\255 \360\200\223\265\252\203y\315\322\013\252\376E-gi\000IY\325\367\353)\322\311g\023\301\245\245\134\223n\211\324\245\301coXc.\320", 64 }, + { "\302\347\272e\366\307\3749\015< ^\330\275\344*\370\033\274_\361\227=-\350d\340[V\025#\225\255\017\252g\325;H9", 40, "\272w\001\242\254\207\370\351", 400, "\304>v\275T\012F\025\366\200\362K'\263v\211\232\267oM$\337\134R~&\262\205IM\300\372\3549\014\177\267H{!\241$\234S=t\355T\247O|?\310\247U\263\326y\000\221\214\2404\266", 64 }, + { "8\217\216\363!u\361\212Kw?\134\251\346\316\012\000\0055\042g\230\010T\374\365y\312\213\333\307z\022\363\313\330d\354\226\325", 40, "\331\326\007\325[\226\374\225\250\021\225\214\012c\240\310", 400, "\016e\302\330?9\223s=\3620\302X\221\336==v\365\351iF\340\227\223;?b\005;\010\201)\327\262\006\247\0077\345\224\250=\026\341tP\303-+M\025\014[\367\007\022w\013k\374\032\234&", 64 }, + { "\027\271\230\271\345\254vz%`\006\201P\331\3222-\323\374\222[S!\003\011\323\231\262+\325\224\250=|\277 \201\254\201_", 40, "\010\214t\242\242\352\314\021\304\320\367\322I\3120\314Ry:\334u\354\272\370", 400, "\334\230\272\330r `\333\030E^\250m\023}\302\022\025th\024\364UC7b\001\301\023d\272\265\207.\037\377\371\011\362\344\270o\2101Bk@\340\332\351\253\257yp\361\377\331v\016\3105\020\363\317", 64 }, + { "B>\351\352\241\021\035\330U73\250J\266\243\374+\340\306\337\263\316\377{U\331\250\304\033jy\0032\216\021\211\345N)d", 40, "\250,\252\367X\257\022\264\331\373\042\223\226Z\021PQ`d\021\371\201\227w\374r\2028\033\3662\377", 400, "\315j\243\042p\000\266\016]BH\350\270\356\257\236\013\214'\347\347\001\010\341v\357\271\355avY\354\250\367\032\260:dRv\377\134?Abn\262\026\020\010\371\255#\227F\035\326,lx\251+D\372E.\263A", 40, "\350\3618b\270\207+:1\033\366\322`\321,\240\244/TDD\315\362\335\354\231\327\333hI\365~\270\271\244\374EU\237\270", 400, "jY\035\262\337\213\327\204\367\352u\230\024\020\021/\027\261\021\037D\2740\354\276G\035\222~\037\3065\201\002\350\042\371\276ye\020\253^B0\234\237v\363\252\267\221\305\373\336\016\034\351\236\243\215\375\236\305", 64 }, + { "\270\322\236\314\345\206Gv@\370=\210\267\316\245\215!F\264\211I7\032\231\225\360?\020\375\256\371\0020V\204&\134\273yk", 40, "\265\257\037\360V\302\357\200\373\024R1X\211!\362\327\027\275\134>X\371\334W9jt=1\331r\241\0138\265\344{hWe^?rZ\301\305\375", 400, "o\212\230=\031.r\255\037}3Q\3413\237%\320\323\362\260/\014\377w\312\370!\236\335\371\010\377\240hR\252\254\016\000\030\332\004\243\305G\371\024<\025r\243X\312\371\320p%n\340K\317\346\2710", 64 }, + { "v\203'\352\031\202O\037i\246\205\355\211^AW\331\251g\257\356vw5\003v\247\304\225\310\232\206\373kqS\360'\252\255", 40, "\252\275\277Tw\316\320$\304s>\372\236\264\330\354\341\314\275\315\034E\240f\001\330=ZK\001\026b\317\333\007\224\230\272\020\366\314\332\027\265\221\033\244\034fA\323\214\032\227\010\225", 400, "\327\262\021>\322}w \177&\302\357\351\356\350\345\217\300\004\24057\0254*\367\365a\200\263\353\000\134h!\226O\243\202\231I+\003\006\244JK\210\005\336\363\032\352\242\206\330\266JQL\013\356\356\307", 64 }, + { "@\257T\377\244\313W+}\242\241gP_\252\2466u\016U\335\230\344\210S\323\030\01608\237\351`\320\332a\3702t\327", 40, "lB;^\004{\301\301\2000\367\227\226\026\222cQl\322\225\374\221\351\277\134\301\023,\002_c[V\333\010z\271\200tQP\237;\277\213\265C6\3474\361=cs\267\200\247\012h\253\233\017k\025", 400, "b\016\304n\314l\007\256\316\042\300\033\006\033\356\305@\237H\356s\026u\276\013Z\016%g\340\344a\0330W\004\244 \241K\216\255V\345\360;\026+u\340\374\006$\201\371\004X\274\332\360D\233s\011", 64 }, + { "h\026\013#^#\3608\361\241y\335\311\364\257\251\0033\202s.0\032I\254\256\250\305[L\332x\032\035M\275\373#41", 40, "n\272\237\200{L\204\300\313\253c\332\220c\225\325\024\243\266$$\364s\344\271\327\270i\245\375\002yu\245`\250\042!\341\200\025\017\203w\253\002{9i~Y\337\316\215G\222\273\031\200\005\221)\370\004e\200\313\2531\335*)", 400, "]J\212\037\332v\225s\225A\361\336b\015`X\010\301\352C\225\020\333\215\226\354\264\205/\034\033\345Q\316\310\311\335\025@\323\376L\373\365N\014\207\333\377\373\030c?\263o \270y1\327'\011\275\300", 64 }, + { "\037$\023\200l\203\315\362\001r:\251Y\265N\006\033\223\177\266\276}\235\042.{\340@(\361\042u\250\364\374/\017\225\203?", 40, "o'P\035\276\332b\015", 500, "\027+\241\256=XP\216\265\203C\372\367\026_g\042W\277\042\017Q\200\260\363\021\031\370\017\354\214H#\247\233\012\244*\277\325fi\261\344\005\026\206\262v->\344\340\332\367C6RpF\273Y(c", 64 }, + { "i\356+\334\331\004\246\024\364t\321l&\254\240['=B^\351Y\222e\332\267\227++\320,\351\315$\025H4\036\307\305", 40, "\232%\344]\343?\304T\007\016\323\211\341\264\350\003", 500, "\376%\230\250'\221\371L\315\021\017^\256\034\273;\335\337\360p\305k\331\256\370\021\371\230kZk\234\353\026\227\340\313{\203\206r\032\034\034\374J\025\352\015\335 \373V\365\347\024\005\276*\363\021\331\3446", 64 }, + { "B\276J\227\335\347dq0\204\341\373\352\264v$\311g\306b\314,\252a\030^,\333\202\327\353(\245l\240\313\267B\243s", 40, "]r\312\3217\237OJfZR\274\021\261Q (\244\241\013bm\306\001", 500, "\020\307H\233\2222\307\276\233\134\220Sc\226&\230\273\353\315\265\004*\253\030\222\031\016\203\022`\242\360/}\301z\226\270\231L\203\346\034sh\201\216\030\201 \223j\341Y\337\350\366\256\347\301X\372V?", 64 }, + { "\367\373\350:\033`v#:q\264G\032\235Y\3419(\211bK\002\012\317\237\217\261\277|\367'F\225\346\322M\262oO\032", 40, "\017q*\266,_U\373\216\351\001\035\3237u\354\251^r\022'X\237\206\230]\331{@%\301\311", 500, "\211\366\134\340\227K~6!L>7(#\032\2176\230\000J\344\321\013\371A6\206#^\350/N\021\341\365V\211\230;\266v\013\327\000\221X\360\025ag]\344\011\002\322\357\363\254\270\324j\333e\232", 64 }, + { "`r\253B\0145\341=\303\240Yp%\023\256\003\232\354\212!F\246Q\232\207\224\337\347Z\216\261\235\244c\332\242w\206-\337", 40, "Z\216\370\311}==\002\367]w65\340\302\340\221\002\032@\302\210AP\273\215\335\322Q>\011I[\004\231\241\310\246\022\322", 500, "H:DD\322bY\205\003\134,\367\345\265\352\021\331\375\007\261\2251\334{g\336\022bso\015\203\277\312\264)\005\2372(\335RK\225^qM]\2626j\266\324\006\023n\371\321\340\260\354/\357\225", 64 }, + { "\036;{cq\252\200V\205y\367HY\042\373\323<\235\252F4\31601v\341\235\005%\204x&\177\316.\222\032\214\357>", 40, "\023\321:\305B\361\352\322\345J\042\202\333Q\214c\007-\026MN\352\252\231t\205\012Y\365\340=\212\374\245\275\021\177?g)\006c\0104%6A/", 500, "\250\303\354\237a\347#'\230\270\035^\357\275\231\254\000\001z\315{\312@u\365s\310x\326z=\007S\213\336\026`}/\324\220\275\217\232\323\321\273Z@\027\317|\223\011e,2\023P\021^\325\000b", 64 }, + { "*z\225F\206\0151/t\213\026\2309~\313\313\374\205\235*\342\026\003\267\347\223\333\034:N\2051\001O\3031\207\375H\265", 40, "/?\0267\245\223\272\370\225Ad\214,H\332\265\376'\377NE\035bP\342\311\030\202\031\311\014\340\276\266 bW]\373\255+W\316\020\211,\277S\035c\020%\365g\350\271", 500, "\031Q\035\3656\223\042s\342\21538\340\235\226v\014\357\260\013\363\201g\241\271\226\213\220\316Zj\000\306\000\220\021V\027\250\230\302\265'\255\235\334N\230\355\251\326&\207\307;4\2550p\377d\315\342\222", 64 }, + { "\247g\321K\211\224K\024H-}\217\260\373\332\325;L/e.\307e-,\013\263n\255\271\312\213\231\241\266\264\264\010\220\177", 40, "\026\227\357\264\367\222d\234F\311\363\371\316:,\366\007\007\240b\272\361\244\215\007U$PW\007\321jGm\033]M)@\326\234\341K~G\005$\024MU\266f\333\247\374\002_\34273\020\301\036D", 500, "\2177\022\2258\227\032v\042f\134\2542D\314\315\271\320\315\026M<\2708r|@c!\351E%\035@v~j\245m\276a\367\364\311\237\016\370Zy\352k\230\322\315\355a\3212\367\252'8\027\010", 64 }, + { "1\010\366:\322\246\037\312\007Jc|d\302)\233\366\134\224\351\272\237\3669\305\247T}\245*\3402m\241\214\035\365\341\274U", 40, "\260\042\205\205\337\006\014\3020%\243\020\221J\361\352\337\003\317\352-\006\303\032\353\333\030:y)aP\003\206\376K\313>\332,\340\202\245\331\333\034Hd\342q\315m\002\256M@4\340:99o6\013\3201\253\355\347R;\022", 500, "f_\215\220\321\254\317rr\306_[\007H\267\334\332\271P\270\220\360mbZ?\012\220\322\357\351e\330E\250N\251\256/?z\261J\276\013\226%\224.4\327\367\310.\320\324bk#x\250P\205`", 64 }, + { "\205\310\260\004\314\016\205\266\337>I\276\336XNQ\371\2057\001oj0|\033\022u\255\233\250\307R#\220_u\021\350\222\317", 40, "\321\234C\254C=\026\005", 600, "\230m\022Q\007v\331W\031'/0\0336\235\241\254g\231v\367\244\013[8\007\016\351\200\371\305b\203\231r\241\324\363/\246\256\222\234\001\223\325\231\267\245\005Pav\241\257\323\265\254\355\134\250\224\033\245", 64 }, + { "\032G5\256\134!\321-\371\005\331b3\321\321\351'%v\361\316\2378\213\356\032{o\042\220\355\006z\277\351\332\342\304\3146", 40, "\200h\016\361\347\034\302\327\3315\371\344:\203\331W", 600, "X\275\364\247\307\262\230\202f\255^X\225\330\225\254\223\203iL\037Gq\001M\304{&\330\342\354\002\322\252\001\301=\231\313[)\236v\012CT\2719\340S~\371\001=\312\234H\323\217\343\020\022m\237", 64 }, + { "18\333\277\367\221\366w\230\253K\012\351\2526\234^\270/\247JD\204,\034\361!Y\266\336\274\354\322\226R6\030\207\305\304", 40, "g\241\307h\373\326X\200\134\002s\362C\011\230-\012\277-\011\377\001\274`", 600, "\236\207\032|\264\025\321-\203\236Ug\306\360\366\262L\022\333\370s\207O]\344+\326\334U\266\340\310>=\360re\227\017Nz\026\216\331\204n$\007\365\323\257>\334;M\213\024\320\252_E\010$\042", 64 }, + { "|\017\325Z\222\240\336\245\247\207\000\326`\221e\2770\360\226\232$\274\375(B\024\264\336t`SwhX\354|D\327Z\236", 40, "\356^\021\042^\200\272j:Z\377\216\247KVH\334\241\263\307\220\223Gi\337r\001Q\246\261 \207", 600, "\323\247\260\306\013&\234n\235\213;{\234\276\241\016\270\012\006\340:6\337g+\234\0264cV\367\307\361\341Iqu\210\307\370\0056\002\343Oy\264w\230X\3239H\024\207\027\377\315\204\333\340\302\220\250", 64 }, + { "}\017\344\277/u\246\350\315\226\323\033\277\356o\024h\004\234\343\036\005\014s\265\375\023\001\363\206d\265a\266\374\036\344\200*\364", 40, ":\361\031\206\006\321\276\321\206^*\330\027\257:\204i\311\012\233\3404\236\0040Zk\326\007\013\015\310\022\367i\313)m\341\026", 600, "\236\317\231\200E\323\025aM\347\231R\345\020\324\364\254\367{\024F~]c\204\350G\364\364\204\355k'4k\343\221\034W}TL\311B\027T\246\353\311\333|\340\2266\231\017\323\307\254\337A\007\373\333", 64 }, + { "\247KD\327\323`\024v \344}H4C;\307#J*\323\314\021\362/\214\254ED\201\042:\341\204\313\231U;\351\362\336\362\024\223^\341L\0328\350\235\247\342\371\254'\257J\357\323\2046\362\363\247\260 V\025w\244\253\246\177&n\275\212.V", 700, "\310\245K\3722\340P\316g\224`\021\2139\225\207\324\277\251{;\036\376\001c\235\342[E\314\007\324\217J\316\331y\216\216\305O\210\374\277\3710\227\276/\033i\205\316\247/\215\256\330\037\271\273\251\310 ", 64 }, + { "\250\003\231s\236\374(\2562\314\007\365\037&\2730O\376=k\236#mm\035J\315\333\335\022\377\236\2177\304\266\177\037\352\201", 40, "\207\207\017\306y\205G\030\023\012\312-\215g\345\252\016\244Z\215\200b\021\201D\253\306\001|\024\227\363V\313~`\207o\003\263\207^\246\345\025\262\252\036~\262\304\350kvD\365|\377\301\346(\252}D", 700, "\002\345y\325*\313\214\003-7\371d\134\220\017\215j\246\304iH\271Sx)q\275n\016\361L\253\213\362\206\367\022\017\375\272Q\245\220\353.\264\011?\257\311\233\013\3441\005\370]Z\235@\200\010\231h", 64 }, + { "\266\361)\254\304\357\342\2513\207\262ND\246\022\210\234\262\013m\331tD\036\216\256W\221\337tW\201\245\254\035.\252j\037\246", 40, "\317\036!DOSD\017\215RzN\235\344\266R\320\275,R\030\356\3542\241\217\346\310\002\020\264\260\235A\022\016\037\247\027zb\236\023\323{\301\205\323B\342B[-2\312\363 \217~\216\332\347\317\355vnZ:T6/M", 700, "\254\355\201.s;\233PQ\344\304\255\230\272\016s\332\341\035\014\023C\254\352\2167\010R\037\253\025\325PV\305k\336\364\316\347\370\375\317\247\274\3319\015\375*\265U\222g\00126Y\265\220\331W\026\300", 64 }, + { "\236\003\332\3109\303\331\310\316\216\276\331\011\305\003\217\316R\343oW\036\362\015\321\205`\224:#cpm8v\202\200z.\316", 40, "\226\1340\320oh\347\016", 800, "N\251K\255\026\242\251J\361\374\033\356\007.\006\205\035\317\006\202\272[&<\255\244D&D\032\017m\307\345 \001\016\272k\024\134\252-$\346Y\330\031\035W\250\031~>,\346\260\242\352\001'Iw1\363\365\223\255\3738\276\344\202\325\042C\2714\252\254\273\215\244\250q;\375\344?\201\233a\334\332]", 64 }, + { "\272\210\031:*\250\216=\324\274\240L\340\220#\351\042s\203zR\2328\367\012\014\265&\372\225p\204S\310vFS\360\221\304", 40, "\244D\351Q\254>(\306\235&\226\314|\306\211\364\010\247\323\361\356\247\224\340", 800, "\360\245`M\036\222\270\011\207\000\377,LH\254\217\034\273\023[\367C^\366<\213\302\352u\035\355\367H", 800, "m\230\007Ou^\233\342\007\326MA\333J\010\256^\336\231mw\3463S\203\035~63\363\222U\201\375\311:\032\3244T\316Z\031\345\021;\356\222\010\245\262\214\204\316\273\320\266\036^\371W\005\372[", 64 }, + { "\025U\274\365\264D\325M\362\270\031\134\277y\240\201\017\367\011=\234B\206\216\275Z_:\310\022\034\226#\276\311z\356^\006m", 40, "\375\252kc`9\356\355\347\361wv4~\324\024\324\242", 64 }, + { "\2277\226\352\341\316T\3078\305\005\370\357\257\3065\270d\027\031\200I\245\016\243JC_\301\332\230p\323\345\274\252U\345\364\374", 40, "\321\257\023dE\264\202\246\274\342\024Y\307\377L~\244N\254\213\202\027\2641>\015\235\205\020\010/\333\275Z\350\030\305\006\3614\266\034\244\251\211X\241\217\212M\315\310K\252\374\351]f\267$X_\266\242", 800, "\303W\001v\301H\013*\303D\267\013\246\003\333Nr\213\363\214\023\231\300\334B\271\240\020A\214+\321\006\250\037\251p\230\373\020\262\333\255\210\251\031\013\206\366\000\246%\005\250\266\006I\274\257\337\031n\250D", 64 }, + { "v\036\315v\000\305_\303\343^\006?L$\025\304Xr\014\203'\257y\2462\274p\251\351\221,\211\001\313\024\234ua2S", 40, "\004\222\311 d\350\256\035pO'\302\255\260%5\210j\277T6a%\251F\017\013\300|]e\360\317\0245\037B\216\276mMZo\247\340\021\017~\305\326\242=OJu]shHr\212Y\254\304Gl\236\332\2600\042\216", 800, "\323\004MM>\322@<\321\23672O#\360\030\234\335~\352\345;\016\301^\237\304\260T\274\304\010\247\356iT\207kU\207\134\353\235\251 \377\270M\303#\300\274m\3151k\2259\240\327t\275\371d", 64 }, + { "\272\246\030\303\247i@\262\342\042sn\0006\222\247\366\013\002\205\034\363\246b\237\226\032\377\226\244r\243\377\362", 40, "1\324K\006\307I\330R", 900, "\215G|*\014\234\000^>$\313\363p\327\250QD\343\337\232D\042\256\331-\303LE\3602\0019\3137]\337\006\352\017\026 }Q\035\036\325\261\246\320\027+\357\007HP\200+\345\264\300\362\026\374\320", 64 }, + { "P\255'\277m\2654\026\225\362y\206\002\311\313\032J\213\315.R\201\375\025rP\236\254\333\357*\221,Nk\025\004\014\005\271", 40, "\322\002\261\273*\303\310\2203\375\240s\317\027\206\265", 900, "\311{\342#h\025\214A0\351T\253.\361\350w\200\336\367\331\241\023\006\201\375U\264\376,AL\276\373\360y\266\243\017\253\252'\232\346#\207\223\254\023\002Q);r\223\271\025\322\035\336\266\001*}\314", 64 }, + { "\375\021:w<-\363\227v\242\220s\343\37651\006\257x\331\004\213\363\336\266w9I\336\323QCN\216\354\215\306>[ ", 40, "Xm?\205\340\010\207\256\003#g\224\331\333XE\251\303\331Gr\025N\217", 900, "\316YO\221\237+`\004\0179 \317\322\220\374<\266rl\377\246\331T~3\235\304\014\023\335.'\273\034W\340\226\235\244 \033~J\222\021\240\014\327rD\007\235lR\022\321u\264~Yd\337\014\200", 64 }, + { "\035\264\036.]6\335\000\277zG\326\304\363\236\012\215\227\334\226 \375\220\325g\312D^jv\014\011\001>\263\364\330\260\271U", 40, "+\134<\316[s\224\272\360\201\201\031#\233n\261\317\205v\363\230\262^\215\213b\2162\244r\322Q", 900, "\373fya$\300>\001=\340\335\240\200T\321(\317\310\227xM\241q\237\305\351\335\253r\027/s\277vc\212\232w\332\026W\362:\361=\302\377\350\317\227\365+\223\033g\337\347p\344\273\012\366\317\345", 64 }, + { "\007Z\255E%IM\035\302\343\304d\276\354\312\042\211\015\266>|0Z\377\320m\303\254\334\231\206\266eFw\314\025\2734n", 40, "\354\272\341\373\202=\177\030\134A\224\256\246\217\336,\207\375\230\241D{\035\222q\275\220:o\240\321\375fP\303\375&Ak\205", 900, "7>\250Ar\323b\375\207\336\000\003\257\204\244\203\0137b\213\042\260\134<\372m\333*\3515\200\024\211\313\365y\345\276$\016\276\276\253\032Y\321\237x\367\000u\245\026s\015\014\326+\347\245j\251\221\236", 64 }, + { "\234\012J\305\000\361\2322b\357\3757\252\2230^Y=\310\353|\002>\013\257eF\230\200s\275V\214X\222\272|_j\215", 40, "\266\305(\042U\226dza\035\006h@\035t\335L\247#\360IqL\260\307\347\2761~_\316\032U7\206\255_\222\205\301\207\324\325<\222y\373\335", 900, "\373q\021\255\334\2365\216.\366\206i\034\217\256\227\210\3675\314\274\3716G\032\360\030$S\270\313Y\314k\022y\2272M\033C\277\003\221\334:h\001x\306\302yx\221\217\016\277;\012N\261%\211\240", 64 }, + { ">\346'MZ\252D.\350\326\241\240\2335cH\334\261f\371\224\236\032\375e\312b~\0165\324[\012\134\215=\277$", 900, "\027@\215A\225!\233*\003m\364\006\373+L\031^\007-l\010\242\377\242Y6aa\235\313\265\260\262b4\325\305T4\203\011\315\320\336_>\004\342\264\353O\351\266O\226;\313U\214\353\362RI\277", 64 }, + { "\223)\222Fg\257\022\2141\375\232Q\356\251\270A\021\237u\213C\010\371\243\250Z\233&\002\334-|\3267\340\026\354\276k\221", 40, "\243\370\024\263dz\312\234+\326\225\267g\254\317\205\346\350\303L\311\026\225\024\042\20679\266RG=\022\273\276\021\342\324\336\314\353\232M,M\334\025T\035\340\210\225\357\316)\374\265l\031\215\222\011\201K", 900, " \321\337\221\312.4*\351\042\242\026\134\221\002f#u\342\266\033\015\007\335\230\205\037E\016\324P\273\013q'\210\002\344AE6\206P\323N\221\260\362%\346\301t\246It\230RY\366\020\220\334K\017", 64 }, + { "V\215\330\206\025D\027\363\346\134\010\376\201\305\275_\366\034\344i\231\017\236\007\006\330s\351\033\336\011g\325\037\3173\023", 1000, "\211\272(\272\325\230{{\033k\220\260\341\026\225m\365\201|\276)\374\355\255\221\223\352;\235M\001\010\006\023tE<\340?o\001\246\226\232\012\343\306\234\001Iq\371\373r9\021\032\016:i\277\351C[", 64 }, + { "d\211\205{8\004\024\223f\011\313y\323\344\034\326\362\304X\320\241sG\235W\201\352\340u\215$\271\330\320\376\267\237 \324s", 40, "\310\034\021\375\023\330\206\027\323\1773D*N\003\317", 1000, "Pf\365\012\011i[?I\015%\343W\233\027\345\005\345\344\024\271\203\355\311fS\212\012\3022\021k\366\316\200[\250]\377.J\322u{\341\313`\323.i&*\037\327(\325\237\372\377\015)C\3507", 64 }, + { "\263\011\250\275\025\371Z\0101]\350mf\343\257p(\232p\375\013\350\2748J\327\024W\310-Xo\033.I\213\263\307T\350", 40, "/|\3329\253\374\350\017{\246Y\213\340\232J\226\261|A6\2306\220\267", 1000, "r>\177\026\256\271\343\015\236\212\217l\216R\0140pA\371\321\027:<\005\270,%\364\263#\221\274\344{8(;cR\346\302,<\035jG\247B\242\213\301\310\334\025\257\026B5[\023U\235\231\021", 64 }, + { "6P\203\023g\301\004\023\216)\306^h}\224-\020u\277\202\005\215\326q&\301\305-\001\313DU\343i8LJ\261%#", 40, "H\373x\252\220\007\246\251\353b\013S\223\314\364\017\305\326\341\347|\003\361\2411\215\363\2177\362}\333", 1000, "\035G\260X5\372\306\321\216\255\336\177\226.\2416j\302\315\220\270\2442\343(\236\017\376t\344\377\355!y\236L;\352\200\2603e\255$f\305\304\025\024\034\320+\000g>\371.)d&\201\225\211\001", 64 }, + { "\275\267\241\311\255\003A\347la\224=\205\012\312\320\315nNQ`B:8E9\257z\261\210\251#\003\321\007\360b\210\352t", 40, "\326\364~\371\340\012\011\247\221\223\373H\221g16\321\317\335\271\264\263:\217\201\373Cy6\344bG\315J\376?@\353\341?", 1000, "\334g[\011\227?\316|\030~\233Q\030\326\237 \244\376\016\026C~E\032_\022S\214\317\331L\270\3726\030\306\333\344ce\006\016\371\254\251\254m\254\225\305\277\301\000\257\035\363\340\321\350\211\332\000\023\304", 64 }, + { "\313\260\003\264?r\237\205$\220~n\016n\036\252\311\2724\241_\356}\362G\340K\373m\034\233\362\000\373\2329\204\253?q", 40, "\213\252\265?\016+v\221\020\234\261\012\254\305\200\326\027~a[\252^\024\350<\334\205\253%v\362\277Z\327\356\305/\253\215\010\261\221\276\224\306\355\237\033", 1000, "O\257}r\305\306\214\240p\023N\367u\336\275Q\340\011\005\377}\001\203\231}SE\221\303{\251\310\027\200\326\026\300\204p3\2726\212\224\355\237u\200\233\004\215dNd\243~\254\216\323\361\201\233\220\277", 64 }, + { "\217\252\036 M-\337\272Pzu\215\221?!\253\134\220\3331\320\352\2520,\232z\372\304\3133X\320\270ba\042\363\222\335", 40, "\331E\026\277\027J\200\301MA\345>\306@*L~\347-X\242\361\035\042\251\230\177\334Q\235\330\371c\322\300\242*c\322\364>|\250[\326\350\022\241\216\303\243\221\267\206\253\225", 1000, "\312G{\134\201\277o\201EE`\260E=~dQ& \212|O!\2507\177\336\274\220\0060G\354\316\006\243o\254lC\231\371\002v\004\013\234\251;\361wZ\210(JFj[\210\360t\263\363t", 64 }, + { "c\346\307Q\376\034zU\020%+\207\274\361.\222\231W\233\034\024\371\302\335\243\214\034\215\244\0076W\3629\367e\233\031Z\032", 40, "\042\006\220\030}-~\351a~\0349\354\270\336#c\301/\347X\014o\256\265>\357\004~\002\261q\215\012\042\025\370\260Q\236\324\262\356C\207\010\245\376*+\031P\320j\277.\234\231\377~+\003\022\356", 1000, "\233i\253\245\234\027Pe\201\215\321l\262\350\352\271\202\232\307\004\000Aaj\327W\265\372 \210\211 S;\037M\037/p\341\267\246\017\273R%\003\316\313\226\342\365\012\347\000\274\001\331\022z\313\2502\310", 64 }, + { "'\241\373B\206`\215\306\266\042\273F\242\205\356L\323\370\370N^\332\331\312=|\015B%o\004\337\361\346`\372\001\325\314J", 40, "\273\037G\277\315+\250\305\332`Q}ou\247\2227\357\012\336\255\366\303\027\330\247N\262\212n\277\213\241o\0010\231Z\210+\312\277\021\246\010m\211\377\001\376\325\234\303\033W\3723\222\240\351&\215\005\214\220K\257\3311%g%", 1000, "\276\005n\341E@}\262\034\244t\311O&\246;9s\034a\342\211H\004\275d){G\013\374\207|\271\023\316\303\365\337DdUY\337V\0375_\320\221\337c\202Evx\024\032\266\221\274\213\031\025", 64 }, + { "m\134\004\204\357\247%}5\327hN\356!\226\021\240\014\006\222\300\202\233H\366\245\235`\263Ua\000\220K\361\222\315\030\030V", 40, "Q\241\243\224|\243\305\211", 2000, "\320DN\260\222\254\336<\304\3538\324(\233\233\242\274S\372\224\216]\267\042\340\251\375S\213\335\217\243\3523\356c\325R\255\011\002\347\022\236fb4\242\363~n\301\226P\255\237P\030\362\324\252$\372\204", 64 }, + { "\342\007S\226t\2532\237\254u\361MMY\246\177\214i\256\343M\246\362\204\355'\335#\264\276\315[\321\236!!G\134\273\217", 40, "\246 y\253.\353\205\022se\355\015\273\352iI", 2000, "\201\303L9\227\266\301\245\372\243\036\235\016@,\027\370\223a;\331>\271^9\342P(\003\344\227\265=\032\033\022\224\0165\337\002\375>A\316\203<\222mp\016\0243\3068/\353\367\306\270\306%\177H", 64 }, + { "/\252\340\020\222?k\371?|p\371-\271\012O\002\255O\316\240&\303.\226U\204\347Zp\352\355!X\221\225\034\205\355\331", 40, "\241/\342\261\015ZAZM\217\316\374\357\212c\330+\203$\375\255\2075\341", 2000, "9\213W0\242u\022^\357\327Z[m\023\177\310\237\346J\340#(?4&\031y\310\005\34293\232o$?~\200\277O\255&=\360x\310\336\304\314Y5\214?2\313\034(\312\375\350\012=\334\263", 64 }, + { "\2058\365\033v\273$a\001\305%}QW\037\376\212\377!\005Z\347\366\375\010\253t\032\240\012P\247TC\267\330Y\335\206z", 40, "N\027>D\017\2778\324\346\012\264?\222w\276\202\207#\367:\206.\0313E\363\330\275.\265x7", 2000, "\254L\354\232\275\274\246|\323\213\236X=9'\332\233uX\333deG\013\217\262y\223\314\007\350\331S\244\356m75\016\015\314\331\334i\350za\010*\360\373\206;\272\003\336|\007\226!L_C\252", 64 }, + { "H\004\267\271\232\367\366y\362\342,\221$\037/82, \256\014`1\226\215\035\303%#p5\303\015\376\333\362\371\352\342\310", 40, "\022\3154\234\374[\232 \030HA~S\321\207\265\272\330z\236\356\212\360\236\323\215\373\231_\273Gk\220\256\331\264\005\230\267H", 2000, "<\360\033NOuN\014\207)\325@\302\0262\210\355!\367\033\302\253wN\372\370?|\217m\215\234\242e\243\004z\010:\330\032\315/y\326\213\267U1\362\242O5_=\264J\253\377\364\032\035W\375", 64 }, + { "R\225J\021F\232\376(\260\300\0304y\230%\327\352%\352\204\211\013\362\265\375Jc\0326A\206\0357\042\005G\025\354\253\006", 40, "\232\212\252\221\374`\030(\227%{\023\327~$BM\376\226?\177T\3368\353\214\321\216b\367\353S\366\042\177\330;\341\230\353\214\363\235\324\005s\234E", 2000, "O\021\336_6\247)\246\005CX\031\302\346\241\035\365CQ\310\037\274\265\377\247\235\257&\254J\315\250'\210\356hl>\027\246\013)\350p\004\267'=\025\236;\220\002x'\035Ij0\373\265\013\357\023", 64 }, + { "\374:\010\203(\0329\201D\346\246`\372\311\221\036C\256\030\024\335?\312\277\340l\344D\307\254\246\342+3;\312\301O\235\303", 40, "\237\233\317JL\336\027\026lj\264A\012)\005\225\210!b\267fn0\264e\2521Ko\235zd8]\031\213@\230T\3726\256\304\213K\211\231s\307\015\031!\237\020\233w", 2000, "S2\030\011\244\331Oq/{\000\330\177v-1X)\207\226}8\020\032H\310\000\215m\214;\011g\215\233\033\000\222\201\317c\237\2358T`:@\234\316\034\007A\337^\235\315lW\256A\214\237l", 64 }, + { "\270\224\207\301\240\001`\311\327\371\211\2550\254>\220%k\025d\306xg\250\276\322\245;\326N\237\311\276-\372\321l\214\321D", 40, "l+#\215\304\301\264\331\303\363\021\304\237\366gT\333\340\240\302{\200\370\207\221\205F\243\375t\357w\303<\371GM\237\006\352Q\344lg\266q\020\223X\274\023>\302\007\371CI\240e1U&u\223", 2000, "\017\360_\264\037\250\221\031\134\274\315\265\177\377m\355\205\246\202{\016|\214OI/\327\205\270\017\220G\3402n\014\233\236i\017Z{\036b\356\340O\033~\037\362\306\253j\324I'\265L\211wO\000\237", 64 }, + { "HU\270>(\233{\312\014\211\005\242\206\341\027\033\347\217KY\260\231\255\010\207\340\030s\037\340'\031\003\231\267W\031)\324\270", 40, "\304\232F#\277'\371\351GwI\343\233\374\2569\004Q\336\322z\305'\243n\270\023\377\330h\375\235\365F)\244yq\027\276\223'*\033\311\362h\221\322g\300\356+\241\300\365\301K_\231\363\005?[L\374\227\255j\216H\347", 2000, "\377)\253\322@\211\324\134CI\333\034>>m\374\270\207\375\025\372\367$2\235\337|\331t\251 \244\370\271F\012\341\250$\0221\210\276 \026\134\031\224\360k,8\034\262\013\360\225\260\352\031\240@\303\243", 64 }, + { "v\014\202\367\330\015\0016v\220\351\311\003u\263\236\205\251\334\260\257\203\020\300\204\332\245\257-\350\3476\303\325\377t#<[%", 40, "\346x\031\351=\212\362\002", 3000, "\236f'\326l\345\210x9\310\206\304Qb\247\335\351\246\310\255\200\007\373\301\272{Z\360h7W\005\355e{n\312\226\203/\357}\332o\314\2270\026'\357\342\012\331\376\000E\337U\374&\256\367\252`", 64 }, + { "tHN\335\351\026j\345\347\265\303js&\276\000\027`A\251\242\263\016 #\267\313\272\242\275\024\3430\333ah\276\342C.", 40, "\334\020y\342a\350!Y\332p\012a\247\217\223t", 3000, "\343ur\205\201\3444\263\011\373snRl\207\002\211\2332\260\302{\022\250t\210\250\030\177\277\304[\315}Fzi\333\210\303\234\010\337\244\216\360V\007*\305\243\327\371\007[\330J \027\257\1770:\001", 64 }, + { "\020((\271~1\371\354\134\256\025\362\323\332\010\200\010i]3Fw\003\324\237\250\301\247p\311\240\342G\335\255\006s\265\351\373", 40, "y\365\011\223\001\346\262\360#\245\027\313\026i\213Q\372\031\005\017sr\242\221", 3000, "\042?\357Y\375x\355a\024\200\003Y\245\356A0\267k^\203 \224\232I\260\304UQp\355D\233\253\326T\353\271\022l\377\247\300\307\351c\177\233v\002\266\336>\035\2711\307WM\321\377\000\371\007D", 64 }, + { "J\236\237\344\246\252\331\360~/\033\032kpw\321\235\036-}\233)\250Z\017\316W\3158\042\334(\216\227\373\324V\374QL", 40, "\216G\344\346]\013\356|g\005\363k\250\360\255E\225\263\327n\332\225\253\033\364\222.4#^-\355", 3000, "\324\224\245<*\230=\324Mf\352\224:\004\024\031\255qI\327\377'\327\223F\007\264v\037\367p7\301\366\253\225\266y\320\025=AZ\373\310\034\326n\311\272\270t%X\253\232\372\357X\270\205\201\376\036", 64 }, + { "\350\312\011|2E\205K3\036eK\177\355\265M\344\001\255\277(\231\376CG\301'\237\346pN]&\177\273\000R\015\336\353", 40, "Ui\256\334\260\242}$\372\237U*\265\020\023\264\027\247\367T\234\351MN>\0126lLv\360\016\223j\343\220\034\325\374\365", 3000, "#\012 \354\261\226\226=\251\271l{\001\013\301\260\012W\247\020\366\204*\341\352R\371\353\010\036V\375\037\345o\244*,\000\262\013Y\375\311,\033@R\3140\037\264L\031\360\020\354A\210\213\022\201\336M", 64 }, + { ",\347+3\364\305P\245\223\300<\323C=\213*S\373\0163>T\357\360\304[\202*P\004\004\224\33585\3249\332\032\253", 40, "Gs\271\225\331\274\026?XX\021\254\205\205Mrn\341s_\217\006\000\134\375:\301\334!\341\322\202\262\002\332\365\257O1B\305\376]\016\021l2\225\277\025I\012U\321\363\221\002\206,y\210\224\217g>\0258\254\261M\340\3714\274\013", 64 }, + { "\277\313O\320\373~\303\235\255\327\022\212&z\367\015r\270i\332A\222\320q\215\025\263\233\215\371Rc\337\012W\360t>\202\337", 40, "\005\271\372\326x{W\034\256\244\343\013\305\332\342\036R>\205'Im?z\350\014\006W\227\032\022\235S\352\025@O\036^\002\364\333G\373\242\201R\325\214\011W3\325$G\024", 3000, "\033\333ct\032Lr+\011C5\034>k5JL/l\003y$\225\022~3\347I\361fd\321\376\351\366\004'\365if\320\014\362\007\377\204\313\254\347\210]\033\331\025\005\243\255\271\037 \243\2633\254", 64 }, + { "\022 \253~\327\267\303s\016\037\331T\333zT=\330}-1\364\022\343\360D\307\377<\232\364Z\001\205\360\236\030\376\2163\243", 40, "I\222\331\177\265\220\372\015\351\001\220\213'{\334\362G\365\252s\201&#\263\357&\366D\302\023k\360#\2510bJ\342e\306\220\005T#\323\365`\013aQ%j\223\275\335|\363\200\304]m\212\251\304", 3000, "#U.\217\271\211\346\352y\3342\365DQ\035\374r\207\331\356u\346\211\246\255\347s\011\252/\374'\357\002\227zv{y\211Rz\300\206\254U\225>\207b\011\222f\313\005\374\202\010\272\313\032\242'i", 64 }, + { "\221\335\035[!\200\342\272\204\016\320H\250x\225\264Y\371rO]{\247I\316\020\314\376\256\267\331\302\311?\300[TGK\302", 40, "\214\217\316\227\270t6\374\010\211\320\217\213\220\023\004\305O\251m\306(\222\361\037\001r\3364\331\376u\203\344\273\342\266\224\201\215%\230=\235\341\331X\255\232\021\304\227\346V\340\331y\272\3321\216lKo\310\233\202\301\200Uk\355", 3000, "\222~6LF\263sIa\313\266\021\262\264 \250\012\2010\247\336\275\011zySN\270~\272\025N\025wT)%\206t\312@\253\352\033;Eby\270\231\025\207\362\363\356\3531\304\244*\364!\361s", 64 }, + { ";\244\030\035\035\032\256BP)X\202\277\214|]c\002\361r\214\220\367\037hU\347V\241\314\012\250\250\321p \032\254\335\031", 40, "\377\311\272\264\0173\245+", 4000, "\317\333,\233.\220\351\334\236B\341\200\252\021\306\254\001\355u\307\262\022\275_\236h\035\322|\370\346n\004\303\205)\037)\321\253\267\221\236\2446\252\226\250\334\225s\2761\334\244=\323\376\240\364\237\037\206~", 64 }, + { ".\362\232\346\221\3370e\363\2018S\366n\220\212CM\354K\015L\214\205\271\215\301J\003Q\240=f\001\240\036\027\363\245\210", 40, "\270$\3356\362\262.g\261\204\001\177tH\303\223", 4000, "\365S+K\204p\330\243\342\230\343\225\342\266\277\306\0113\001\027\214\326\2070r\334h\256\361$5O\033ze\336#\242\260W\321\311\211\020\262\342v~G-\223S\267\263\372J\305Kw\247\274\354\233Q", 64 }, + { "\221^\330\236-6\207\017\240\250:\317\255\035\234\362o_\344:w\334\236i'JH\304V\320`\255;\363\011H^\207J8", 40, "\305OM\233\221\204\0010\314d-}Z\376pSi\022\323\313\023\370\346\024", 4000, "\315\312\356\271\366\301\134=4\222\013qYj\206\352|\015J\312C\206\327t\305D\225X\324f\337v``\035u|\317\206\342\000\367E\233]M\372\351\134\304A\245\271\206~\301\362p#F`|+\206", 64 }, + { "RL\275F\026S\037q\0277\023\207\253\245s\301\363\002=m\307i\003\337\313\026\336x=\017A\212\343\206tGb\346,^", 40, "\262\215\200|\220`FH\353\321[\022\211\321\357\207\355\352\361LY\3416\032.pv$\202\200\311,", 4000, "\327\303\255\024\231\307\253\007\274%9\207\240SxB\223\037\367\203\246O\316\351\271\260<\312\223\305r\025\366(\214\276\334u\266\274\023}\343)Sr\332\206\224\333\375x\354\020D\243\013Z\374:\263d\355\230", 64 }, + { "zoK\020E\344\266\327\350\326\301\042ay\277/\027;k\036\210\343[\377\014W\307\277H#%\023d\323\255\373\3728\355\334", 40, "\224{J\344\244\356]\345\376\235\2521|D\210u\376\0337\367\245\343\360\035w\342y\351\340\030]Ys\320\3052H\036\253j", 4000, "kX\307\311\033v\211\230i\303S\020\231\313\334e\251p\010QnHK\261)\001W`\275\261:\347\345N\232\346m^\042\336oI\216\342JB\245\347W\227\234K\264\330\376\373\003\301\277Z\007k\311\003", 64 }, + { ";\346\033\200\372(h;\347\364\342\013\240\320J\254\311\313\326\332\207\020\012\276SlpS\221\206(\276*\012]2\264\357\353\333", 40, "#\233j\343\021\317\331\033\241\204O\326\207\375!\221\247<\271\237p\343R\253\017&\327\356\221[\255i\251.g\212Q\014\320\276~\244\005\3155k\251\010", 4000, "\276\001\247\265\317\006\331\235\337\310\301\212m\344\013v:K\337\134\360t\024\012\244\023\311u[C\303\324\033\351E\015]\234\363\351>}D7gL\324\364\244\306f\267\235\377\231z(I\214g\346\240\3447", 64 }, + { "}\251_'\352\042\262{u\213e\353\301&,\023\227\327\006\206\356\215\016\233\255B\015\033\211l\015\360\237\322\225\013zx|t", 40, "F'm\243\321/\261\3521 \366\342n\017\322k\333Q\026\010o\306\004x\254a,C\364\201\027\231\232\215\353\003ZS\227$Xk%\313\201tX\327\216|\275\242\313s\320d", 4000, "\217g3\243_\275\301\025G\345\354\363\253\220/\024lL/\351p\337\302&\263\011\300&\23191\345uu\345\301\230\337\362\042\360\352rZ>\312M:\355]`\360\273\205\223D \002\042\221\003\306tH", 64 }, + { "\245HR\177'\360\330\340\032[\203\254Z(,\272G\360\223\201\306\364\234'\010u\217\013\273\227\026\037\251\221\007\246 )[\235", 40, "\371\255\347\205\201U;\255\350_(\222q\235\261p\376\325\326&\203\042\224\3215Jy\352:\205\362\211f@l\221\015E\002P\207\252\200\233B\207\3329\202\042\256\001_\334h\023\001\003\374\216\237\353qJ", 4000, "\311\262\026\036\313\3243&UG\006\336\224\261\001\353\210\355\032\2372W\316Sw{\254\267\315\234\263\024\365\256\220\021\220A\231F\001A1\347\255q\224\305\220'[0\315Q\240a\221\236*\221\034\376i\313", 64 }, + { "j \331\356\021\266\302\373\305\037\234\305y\013\367\372i\222\236#\253E\221\215\222\022\223\007\203\134\207a\300\321\017\346\222?=v", 40, "\336\220\315rU\233\013\342D\314f\016\037\230\372\007'\003\361\037\234Q\221pf\356\017\203\010\264\321\370\211\360\251V\353\236\232l\220@\004\027\334b\366\265\006p\225JW\236\227\251fiN\232\233\200o\234|\274\015\265\317\001\200\012", 4000, "~M\276\371\346\345\324\242\202\212\337\025\277\227\024+\037\371P\263U\015\016\007\362\177T\370Y\346w\025h1I\307F\364\303<\023F\014\350\221\215H\276\353\206J\244kT\031r\330\246\016hj\250x/", 64 }, + { "\302E\227\301\254y7\247\337\332\015I\243\021\025-\320\361\315\262\377\327Q\277\367Y\203=\011\366u\362\006Ci\374\323\203B\236", 40, "\003V\223D\273\375{V", 5000, "\231\305\276)\251'^7\336\227\212\234\230\350\034\353\304=\215\033\230~\340,\261\351\317\246I.\212\023\217?_\225\012z\002\356\201v\215rA_6o\214/\264\347\006W:\006v\030\212=o\327\226+", 64 }, + { "4\314(\203E\260'\215c\345\331\341\017V\311\346\006;\013e\312\022\215\021D]Y\251D\227\027\366c_\276V\022\037\340\264", 40, "\2103\375Ru\276NAI\345\254\036/\252w2", 5000, "\214\345$\014\000\333\027\204>\326p\320-\020En\034\371+\207\023\327<\314\266\312\277\010\353H\2049\037J3\220\247\3302=\032'\205-}\005BB\372\355\371X\365\325}A\025&!.\311\252|\236", 64 }, + { "_[\347\031\345\200`\000t\302\207\327=\366\270/\322\350;\007\221\207A\027\256\250\364\313\355\370T\240\317Xb\224\363e\313b", 40, "\337\303I\267n\336+\240\134\243_\351\3100\317ZF\016\302m\263\220\302_", 5000, "\213\263Za\221\346\370\303+R\024\335\214C\222\372\332u\313\252#\347\353\006\332 \010\324\034\276\310\321\2165\2403\016\342\306\322\026Y\134~&g\367[\346\021t\221X\035\223\317t\270j\212\211\334\003Q", 64 }, + { "\361m\332Y\307\254=\374\376\312Km\012\013\312\012\206\210B\313j\227:\323&\233>\240\314\211\353\226%\322\035 +\346\305\302", 40, "\211\014jR\233\265\360\224\042\274\034\326y\311\310\200\016\376\356\301\216\205\353+6V\302q\276\247\253\240", 5000, "\201\205\336\014]\323\211\027\312]\276\307\034f\002g\035\310\214)\310d=\376\334\221\252\271L\014\307\202\373\357\226i\0365\210H\0201\260\227\277\2070\222\354\230\277\265\341\251\037\030?\270L\300I\342\030k", 64 }, + { "\302\265\353\372,\300O\312\032\035\205\376^\333?\330\362ZW\004\004\030\264\036J\255\341^b^\024\177\035_\0129\230\335\206o", 40, "\347/\326gV\324l\210\233\301\013\375\3151\314T%\271J\374\327\331\177!\035\312m:\376\247-\271k$JE\262\243}f", 5000, "\042bQM\317\245\256\010YW\336e_\023\354\372\206v=Y_\033!R\342\2103\331\374\204\034\016k\324H\374o\332\032*\012\014\031d\255k\324\300VI\351\244I\230\027\025\357G\206\300\000\222Mk", 64 }, + { "u\263\272CY\021`n\345\307\203\030\012\357T)\377\317\357f\025\361\015\337QM\253\215\367\022\217_\275a\244=/\205\360)", 40, "0M\352w 0\255\033\242penz\365\252O\327\002e\241\263_\015%xG\333g\344}\340\243v|\377\240e\011\354\203\316\352\377T\2143-\370", 5000, "49\310^\216\307t%\355\337\227\301\342\365\302\225MG\223\201-e\203\370Q\376\205w]\264\250)\010\002\367\213\303\256\363\265z\364)\201\276f\006\002\366\2458})4F\250\364\233m)\207 R9", 64 }, + { "6\353u\336\003\275APas\275*\356\210\325\270\274Z\303`N\022\261m\250\235\247\205\344\033\003\343\322o\000;\335R\023\273", 40, "N&{\2130%\355\335\335H\033\2166L\222\371o\374\246\012\033\256\301\235\271\314\345\206V\267?\013~\030\032)k(5\362\267\377#\276xRs\377\205\322\006!\225z\314~", 5000, "\256\213v\006\364ft\342-\254t#\024\244\020\015xM\036\337}\036\267\313C#*N\210\207d\351NG\037s\250\336\257v'\333F\253\244\242\207?\227\317h\337\025\344\2602.G\325:\214\337\373\202", 64 }, + { "\261q\320\011;tg\211\011\333\365\306pUw\272\271\276Tm4\370\373FXt\201\262\031\270\3704\177\0214J0\234\235\324", 40, "\316\264\004\246\371=\031\371*xZ\010\256\245*\355\022\012\260\231h\026z\214\363\277\372\250\302X>\016`\336\345\007\304/ >\234\217\330[\362Z]\343\275e\341\257t\316\232\235 \320\273\004f\261$5", 5000, "?*\034kY\205\002\241\226\003-\242e\003$\020?\345\005\311y\237>1\241\3324s\363\230\356:\206n\042\257\326\366\276n/\177\360\217\322z\335\016\203\353\356\037\213+iH\374\350\371\346y{\177\304", 64 }, + { "\027\252\311\265\024\350\347@\042Uh\245\021_\024;\241\265\2175\345hmj\365\325\300\362\000o\205u;x{cX\313\004\351", 40, "?\177\260\340\0031\020n\352t\261\032\361g\275\207`o\246\031\226\020\361$\352)oN\334\330,_S\2148\005E8\016\263\354i\243\322`\032\024w\307\225\011\275^i\312\032Y-,;\333c\375aX\002\214\327w\374\253\240", 5000, "\252\310U\245\245\134N\247\374z\317DEN;+\342h\231n\000h\015\032S;\333\245\244\201\340-\235\015\332\015\277\253\377\200\271\203\223p\204\252\341\264<\231\134\300\224c/\366u\253f9\337j\200\224", 64 }, + { "\001\257f\007F!\225t\202w\366\277\211\232 \202\246n\204\200pgdp7\365\033#\221\341\023\310\230\216\013\245#\201\365\274", 40, "\372\277\012\266\031\334\375\215", 6000, "\273HFL\315W\015\217\2275\377\356*\225\2074\351p\227\035\365\271\016\312=\373\220\251be\344\345\223\363\261\035e\330\2327\377z\226\355\015\242\314V\326\331Skm\311\323\252Y\3536?.\334\013(", 64 }, + { "\200\313\010\003\253\353HE\362\346\303J\205\346\232R\2477C\217\312&\023\244{\324A\310\2625\260\370\303o\353\360\262\267\236y", 40, "('z_\337\037M9\2131\036\204r[i1", 6000, "7\134(\341\220\2024\317Zm7\323Jg\267\274\376x7\377\253\016\254\366\213\363\24001\236\245'dr(\303\311#\015\335\223\273\342\323\353;\372\342\252\026\372\023tW\241\240\364\357\306!\3761\201\010", 64 }, + { "d\345L\034\356D\017-\277,\007n:5\226\014\227\210jN\000e\020\307C?K\267\323\010\011\257\347\277\350\032^\017\227]", 40, "\3435\273ab+KN\264O\201\211\242\325\251\233\311Hi\363\007=U\026", 6000, "\016u\265\242\011RP\313\341\316\345\370\303\365\327+\225\205\352\312\221g\001/\266\027\312\333!\247\361z\277\336\303\000A1\3715\341\262\374\224y{\223\013+'UB\242u\003R\217\311\316\042N\231\265\033", 64 }, + { "K\264\033\201\243)o'2\253\305C\007\355O\353r\310h\321\256zd>.\221\0330\244j\3349\015\240\225\317\347\344\260\220", 40, "/T!4a/\015v\243}\342\211f\274p\314q\267M\2352v\251\236r\015\327u\211\343\212w", 6000, "\037\211\024g\307|V\037\007O4\006\262\227\335\3174\306\011\015\230\277\022\207\374x\014\234\234_V\026.\352\232\231h,\236\205\035\333\271\227\335]\373\020\320\262\263\216\372\243_lA\244IEK\251}\272", 64 }, + { "\003\006I\015\227\203\320\264\024k\261\002\261k\375`\001\247\333\260\307\364\351\217\3228\377\342)\243\213\3446\351\266)\355\232\353\271", 40, "\245\033r\214\247\344II\366\256@\036\015\015{\260[\270\227\253\254\350\265\355\024\247&g~E\301\015\027\006D\346`\243\317=", 6000, "J\334\343\350\306\134w\367\333\377\220\004\201\025b\236\245J-\005\370\004\235[:\3718\222G8\027\036\215R\021\317\012\013\321MF+R_\341\004\206#\230\134\346\025\353=\026\200\216\256\203\342@\344\251\244", 64 }, + { "*\266\352zh\265\215\235\307~\357~&\262\354\232I\235\376\233;\3240\273r\243#^\003\354\0300\267\325\035bB\346\355\274", 40, "\270\274{\245'\246\304\0049\366\304\300\227^\302\024-\2140\261\236\323\273%:O\022\013\250I\354\275\223\372\037\270\177\301\304f4\2508\252\247\005pb", 6000, "\2323\251\356eT\177\244\020\004\264\251\320\327\0007:\037\322\227b\253Z\010z\305\204Z*\303(-v2W\266u\001\256\373\352~\017\215>\316\340&\333\331\206\030W\366\336D\3000\235Ma\270\031\003", 64 }, + { "\257\247u\250\333z\015\007\221\013\031nz\017\272\216C4I$\361h\310N\324\260D\223|\213\252\237l\007\300\361\2308\033\265", 40, "\300\351\273P\263c\222\222=\356r\337%\037a \226\002\355\330A\207\033\306z\214I\374qc\342\347\251Cp\237\204\322\253\214\010\221\361\324\351\314\030\0330\266\202\002=A\320D", 6000, "A\371[p\255$\364]A\313\177\322\346\354\270\250h\364\347m0 [*\376\213%\211\025L\263!\224\307ZR\263&\202\324n!\223\3475\374:s\2036\225'\347\356\025N\207\375\337r\011b\037\274", 64 }, + { "\251(R\225\234\026\3011t)IIC\345\235a\345\203\270\201\226\235\000y\024\356\240D\325f\210\200#\332\333\277\266p`\254", 40, "\375\010\333?yf\325\367e\202l70+\257\312\3228CX\2546\235q\203\245\134bk\316/\202O\0152\320D\002\3327\037\013\007>\222\247\351\334\2152\316\310H\304\251\200h\230\360\277Bh#D", 6000, "\030s0\2213\201\230\035\216*s\037\014}d\272{\006\372\177\237\036&\246Ylz\255\345\373s\042\333\034\005\244\235M%_[\026^\361\217\3119[\030\004\311e\205\316\003@\010\322I\017A%\246\370", 64 }, + { "\012'`d\013B\231\266\374\302\004\336\016\202\214\333\0120\246?\302\270a\242\003\334\343\022\341\241\352q/\273\323;z\012\355\306", 40, ")mKR[\252\253\024\321\034\236\033\306\243\360\320\331\300\261\346W\361_\263\226\310\013\346\010:\037\200\333\3300\313\255g\223l\177<\306S\216\325\346\335\027\244s ~#\256\224#\011\214\342G\350\015\021\315\307\335\214\027", 6000, "\023\220\224\005&\237LK\2207\363\221\020\037dL,\0230(\230\017x\375*\272\344\031\351\247\012|g\364\342\022\220\2566\221H\020\200\350\211\011I2\341\3277\3609\250\3164\332\377\370\241\227'\243\340", 64 }, + { "\262\362R(~\026\210J(H\232\034\237\314\321\227\376\272\252\242\226\0027uC\035\042\242R\377Pl\016\220T\242H\030i\320\215$\254`f\333>\024(\322\364H!\0008NK\000quQ>\027\363\013", 64 }, + { "\230,\310\226\255\024)\207\357`x\314\210l\252\361CC\240|\363t\322X'8Xbz\231\245d\000\003\025]\260;\350\245", 40, "\255\007Y\022Gk\265r\304]\207W\352\027TC", 7000, "\355\353\317\011\342\342f\336v\370\313[a\363\352\234?\371\234\254*\017%=\032}\257\375<\355\000\232q\305I%\327\017\300\032\253md\250\037\032\306\241\320t\211+\231\364\247\375\314[\204'j\322\272\022", 64 }, + { "B ko\350vU=\244~\353q\233\037@\022\215\273J\313\235\376\001\241\237\341\330\000\310\371J#)\335\262\245\000\207\325\023", 40, "\320\265\271\302]5\246-:J\0011Q\355#\373\271]\236;:l.\244", 7000, "HS\236-\206\233bC-0\327\311'=\206\014-\343gW\021\232P\246L\020:C\226\252(,\134M\240FIa[\260\277\225\015\275\376\000\273X\213\033p\241\371b\212\356\272\316\253\204LuK=", 64 }, + { "\210\323\042\001Y\3122\230\004\020\236g\001\016)\260\323.\204Xj2\360\320\343\357aW\214n1`:\277\352\264\376\356\367\227", 40, "X\014\020\274\005N\342\004\211j5=\2640\262B[?U9\334\020\277\341\255\234:mzGD\270", 7000, "\035$\354\365k%\310\367W\3049\001f(\207s\242\376\026\361v&\226\042\361\247\201x\322\212\233$\210\227\214\250I\346\236p\370lp\012a\215\351\217\304:\326(1\013\017\257\243\352!d\261j#'", 64 }, + { "~@<\225p\276\020\313]\245\331^8\017\204>\310\231E)\346\006_\362\236\331\253}x6\316O\237\271\216\000\253\304\371E", 40, "BD\027\320\345\300\267\013H\342\332\216.\227\247G \212\367\207\017i\365\257\212\317\333\351\217<\361b\010Xy|l\037\216^", 7000, ";t\042r\011\377\204\033\036\235%.\271~\235q\355F\264\215\236\250w\022#\255u1\252M\376\267z\337\004\236\346\203.sqh\223\025\002\033BE\204h\317\317x\026K\332;\372\357G\203\362\346\275", 64 }, + { "\027\231\333\257\306\3570\325\033\266\036\204\206#\030\006nT \255\356\277B\331\201\340A{\212ttQ\177y\374\353\254\025\274`", 40, "\321\005\246\023\042\306\027\177Hv\351W\025\0158\315s'\022KX\036~\367/4\247\223\377^z\324_Q\233\206\023\355H\265l0RkB^\241\207\250\366\240\320\340@\376\362\270;\267#\363\277q=%\365I\261\310\3268\201\324x\257\350c\250\256\311\355\2006\366", 7000, "\350\312+\222.\134\265\366+j\362t\042\317\014\307\2450\236\361/\207\324\362\222\360\262Q,I\254s\370\277w\346\203\261s\302\376\300\030\321\224\327\003\371U\016.$\274\256\362\004\016\312A\236O\242i\235", 64 }, + { "\035\376\031\3777\014\372b\372\316\207\314\334\245\242\374\022\233v\226\227A\303B\245\367\006U\032R\006\032\357\205\345\275Xe\344\001", 40, "v\277\337qw\301\203B\207\372N_\216\332\311p\0101\134\035O\232b\314\331\362z\036\005\327\205R\261\024&dSW\255\252\370\315UY\2716\335-DH\260\222\3627\371o\217\313\236\323\365H\310@\226\032\031\256\347lN\302", 7000, "iz\243\257\217P\205\341\3410t\250\341\244k\351\022\334\311\347I\221\216\244h\352\242y\355\253\374y\323\237g3\235J\232D}\333\310\217p\220\231\304U\026Kf\350\013\365\251\042\275\334\306e9\234e", 64 }, + { "so|\334\340\356\262\312\334\317@GX{l\234\03104Tw!'\332\237a\270\271\0246\333\31447M)3?\036\357", 40, "\357\2626\371\375L\006Q", 8000, "[\347\034s\255S\2004\012\233*\013c_\343\277\213p\314r\274@\373\230\252):;+\007\232D\276\3402\372\300\330\3713\307\227\303H`\376c<<\306\252\251\0241]u\256u\272U\332@l\330", 64 }, + { "\222y\345\357\037\366\020t\321\270\236H\262\273]\244@\253o\365\224\376,tN\245?^\216\034{\361\240`\022\001Q\354\362\357", 40, "\356\310w\353\307t\362\346'\204\202.\277\207\310\341", 8000, "\350\247\235\274\265\301\315\232Fj\366\3460\255\225*C\203G\033\320]\311j\273\264B\276\202\370\274&O\303\374\327$\373\023%7kX\0061\212\274\252\3371\332\213\232\313Cn\353\364U\326\215\352\347*", 64 }, + { "I\221@)\032\264\220^\211\253\025\222\202\236z\335\177\333\225\247\134\321\377\217\321\224\024Ve\304\364\302G3(3Y\266\221\020", 40, "%\242\270\266\326\262\215|\351\353\370B\336\312g\222\343\227\366z\341\036\207=", 8000, "\234D\201\323^\351\320\034\2358\026\360\032fU\357\030\234P\354\247/N\250J\355\011&;\277\134Z\024\343o\262\270\206m\253\254\366\375:\265$\034\321\200\011\261\347", 40, "x\373\357\225\035v\364\3700:\356eB\206\206\266\037L\356ip\301@eI\027\371\253X]]\326$\245D\357\322\007G\214\347\374\350~@h2o\021\001\251\247\224\030\250;}a8\256\247\005$\206\242.\212\261 ^\341\004", 8000, "pQ\266K\355\240CT\242N\326\002\026\241\300w\220\240\026NkK6\201\010N@\177\315\324\276\214\210\333\200\240:iX\216\206\252yy\322\333\330\317_+\235\273\317g\220\134 \203\302D\254$\360N", 64 }, + { "\207\356hc\332\311\262\221\017!\224L`\234\322g\242;\311\030t\240\371\247\304_\367\262\204xz=\306\351\367\007\3268\002\022", 40, "\024\231\371\007*\236k\272", 9000, "\232\035\200\0108\362\327\310\016\210h\244bi\365}v\342\243\034=\366\313\310Is\364\332\360\216\247\231g\352\322\364~R\360v\370\225\225{\034\007\325\305\231\025%\327O\231\272\3101\011\341\356\357\322\204\243", 64 }, + { "\347\232\037t\232\325\134\270\246\231:\000\216\341\364\327\243\233\336\374\233\254:f\234;\261\023T\211^\023\274e\277\331\224\254\361\022", 40, "\231\374k\017\264\022Z\310E\224\373\215G0\323l", 9000, "\242]\315\226Pn@\346\220\257~\134\340\031\325w\0057P\354Z\227\213\004w\255\215\244\305&\020\324\220`NY\262\227B\261\357\337\347\035\35701,jH\237\031\0423\262\321\344W\307\242\042\204\370?", 64 }, + { "\351\222\0071B\005V\022\340\224\323\035\331ry\303\333\214g\374WJ\346\310N\034\027\371H\021K\261b|\212\221k!\227\374", 40, "\235\3570\3671\254\004\034^:g3\274\230\042\314F\310\274\355\226\001\253\315", 9000, "#\335\027Q\374\272[\264x\366?\330\347\372N\366b\336\306[<5\314J\333%\223\321\016\266\333x\251\036W\266\336v\212\332\333\3400\006\302 \334\370{h\015n\374Q\276\026M\244P\026\253\352`\206", 64 }, + { "A9\335N\304O\264hp\360\036V\277c{\356\037$S\331\272\246\023#\254\341\345\252\372{\213q\005a\022\202 \336G\032", 40, "r\333\017\004\376\276\347\351F\362\241\221\026\211HC\374\032\022\004\0101dU\326(\343*y\2774\370", 9000, "cux \267k\007\254\005\211\304\235G\336\200\207\003tZ\010 WP<\360\3709\037\367\233\377\222\360\210\325Q\351\002/\325\134\234O\275~\363\355:_\267\006\316\362n\012\225\265\210i\2451\355\327Q", 64 }, + { "~\327n\210\367Y\1346o\001\235@\031\265\026\331\247;\262v\347,=\310\212}d\327A+V\372\246\011\034F\307r\021\236", 40, "=\232\244p\320Q\003B\224,\020}\340\267\270o\2408\321\256\261\360\332\211\346qM\345\276\004lS\270\010\336|\274\215\224\257", 9000, "\255\314\336\220vu\346\367\321\212W5\010+J\134\275\310\202\350\334\214\252,f\205t\2525\252\344\344\023\277G`<\353=1h\257\326U\025SY\027\352 x\340\026\272\363[\016{B\364T\347\337\025", 64 }, + { "&\007\346\021Eya_^(\217&\372\222\020X\246\367Q\015o,y\240\273\357\352\345\321\005\264p\031\034}e\244\274\003\247", 40, "\341E\304{\336\344\364w\231.Q)\334c\3024\305V\375jvam\004:\235\312\305t{T\205w\313\374\021\345\251\023l\264\036\325u\375\352\3710", 9000, "M\2779\257\330,\023S\354jg\345M\306tTW\036)\015%{\313\032\005\261_\377\370w\220\360N\266\366H\222U;\032`\031\261xzOS\356~\327\232\030\017\321!\334.\216\271\203\205\246\304]", 64 }, + { "\214e\042X\244P>-7\351\310\252\242\311\223\032PFX\215,\333\313\036N\0322\322\325\3340\366\242\226\366K\345y~\306", 40, "\134\307Ui \271\307\301p\225)\267\024\373\303\363v\214\002\017\270#\300\321\024e\025\371\025\305Y\252w;;\327\357\337\351\2130\244,\252\005\316D2\375\261\034^\367Ar\002", 9000, "_\227\217\237;:(\330\254\277(\202\301\303W>\346\372x\012#8\272\244G\371\134\214S\301\252\010\241\315\313\362\027\035\203\023zUV%\347\337\354,\225\375\345\275e]U\234.\007\023-\320o\272X", 64 }, + { "\254|F\033\270\264\331\247\266.9\233\013\212\036\3258H\203}\237\003\267O\325\317\336\375XC\220\362n\241d0\256\012E%", 40, "\340$\356g^;\224Y\340\2251\367\212\235\134\264\216\316\023\316;s\3010\272\340\242\313\244\206\310\354J\305\264\021\334\265\216g\331\304E\212r\010\341\224D\252d0\333F\246\212)\220\313\007W\2412\323", 9000, "\207w8\211 T\261\360\276u.\263)\252\303\233\270\317p\352\213G;\021-\025\2572C\250U\260\031\263\025?\343\216bs\042'\341[\007\242\337\342\022\374\207\237L\266\005\3305\305\366\335\231SDx", 64 }, + { "\212\341\3665{\373\267\340\360b/\234\313\327\235N\242%\334\246\274\216\024\350\304\134\271\321\0316P\013$\332\370\346\010r\351\326", 40, "\372\263P1\315\027\012\301u)\234\334\365\211\333\310g\303\203\240a\312_\276\2755\333\324r\275l\014\2311\356,\017\272\010t\033\354$\010\347`\321\235A\221\311\205\327\276\310\257\305h\262\245\315\204\366\334\013\313\363\027\303\216\202\015", 9000, "\257\316\015\202\024\245\365\303#%\303\351L\327\332L^\317j\370\250\261\337\177\277\276\321\302\246i\275\270\324\311\224\264\252\024\346\262Q9^\001\205\223l\250\343\007+\372\344w\270\350\372\350\326K\015v\346\014", 64 }, + { "\031tE\340P\214\336\351\311:\226@\254\206?MP\247\224d\271\251\266y_\036\371_\134\275\227\333\311\235Sb\307;\272\024\303\302\373\007M\3414\037", 48, "\021\201\255\007\253>\337z", 100, "\177?Y\235<\025\237c-q\203\035K\253_\276bE\236?L\220\016\237d\317W\376\337C}|\370d\000\004\304\331sJ\264\251\345\322\011\033\352k\341\272\323-\003\313ss\020F\201\021Yy\274\370", 64 }, + { "\361\225EV\034Lo\324\302\177\265\004\352\340\300\271K\372\263'b=\021\014<\244\035I\231\276\270\273o#\334P\227\317\364\026W\316\267\033\030L;\331", 48, "\347\276C\014\313y\201\013\217\230|\315\356=\256\213", 100, "\373\302\027\231[\013&'\375J2)\3601\356\260\356\226\377q?9\342\027\023\255\346\2219\302\301\256k\004\224\005\361\027\301d\255\322g\375\177\033\302\226V\232Iu\300\000W\364\010'd\033'\002\271\243", 64 }, + { "\232)\225y\274\233\203\256O[*\212\311\217Cr\005\332\031]I\212H\327\370e\203k;\340G\263>\321x\214s\350\262{\276\042f\370n-\325c", 48, "\317\277C\314B3!\207\217\214Y4m#\202\036\011\264\206\310L,}\225", 100, "U\263q5\313\207\331.v\021z\020I\204g\322\255+\326<\304@d\256d\020\203\205\342m\237!\337\005\261\353\302\216\215)\334\235-t\203\303\324P\3069d\314\253\301u\223\223\303\224yA\325\311\206", 64 }, + { "gk\0051\366\256\225\374T*:8\016\307\211\042\332\356\020\206?\014\353 UK\256\300)\371\274\356c\374\250\042\311\377\275\242\334\276\247\311\015\001\321g", 48, "K\346\020\021 \322\220\223\362\0178i\341\312b\223\200\241\310\011\027\020bR\343G\305\211\220\340\315\004", 100, "\3516\020\200.\042\206\302\212K\340\037\370\271@x\0013\251\301\012k\272\352wA\216\006y\270%.\343?\341\237\253A\236\232\377\217\240(\002W\345\311.Z\327\224K\304\015\251\200\252C\021\316]X\307", 64 }, + { "\241\243\332j\033\357\354S\364\247\334i\302\264[>8\351\326;A\030\003F\270\016S\320\014*\013\3555\320\270D\226\371`v\003\357\331\326\306\231\311&", 48, "\026|\301 \027`\301\032\2317\230\246\376\352>R D\250\263!\250^Q]H8\322\217\2377N@\341$\273\341\031\306\357", 100, "\377\025\011\030Ve\223\272K\275\230\002&=V\271\2043\243\013\004\270\016\201\377z1\335\241\005q\035\016\016-\314XR\177\3371N\252RR\206v\351\032q\370\207\321\033*\3410\277yjA\320\236X", 64 }, + { "\304\2053\034\271~\263W\025\300\311\253\321\265\201\303s\336s\262\230\212-\374\3737\336\331\0256\205\226o sp\264\274B\267\356\034\362\0130B\255R", 48, "\376\306\264\014\224\245\200\022\344\367\353\213s\376J\261U\200Q\371\330!\263\206\360\251\351_\0140\205\004\255\257\205\261\017\243[U\351\372~:\0350\211~", 100, "\272a\373KE\010KD\001\361\134\311\345Z\005\341H\036\035\324.r\233O\037;\217Z>\273\355\267\035=\204\215\017%\270,\256&p\212YI\356\246RL(\025Y\026Yd\237\264p\364\244\134\011\361", 64 }, + { "\246nj~QCr|u\223\234\331<-\226\320|\356\360\236j\273hr\021R4\254\034\345\032\025\262\037\042S\274\216\236%\375\361\224\006\243\357f\335", 48, "\200\025\363A\033\210\2445\333\263&\244\002R\026\227\221\024\177\236\201\2766^.\250\262\240W:\352\334F\233\210Hf\022\273\305-\273\312\246\274\256\257v\344\361\346\333\233\216\375\033", 100, "\336\007\257\321\234\327\323\354\251\223\244\266\331&\032\352\220\335ZJ\000\002\222y-\022\3648\256'\355\003\256\333\211\276\321fY'u\252\017\202U\353\0123G\012R\002\206\374\023\026\341@\356\202\330\243\357\017", 64 }, + { "\334^\236\035+\253\251\261\313#*C\273\226\221\266\223W:\322f\340F\234\241\277\031\002\263\340\347\271\017<\025\261\334G\313\035\343\042~\342\320\221\2420\042<2ZN\227Z}\221\231\216\134\334\263", 64 }, + { "\322<\332T\271\207f\242\337\256P\376\331\274\220E\351\251\331b\324{\261\315\353\237~\267\134O0P\244\205\334D@AR\020Q\305!\217}\204'\034", 48, "\134\277\013\215[R+\223V;yS\134\334~\311\351\017\321\246k\0349\207\300\221\332T1\227z7\256\003\371Wh\313]m\037G)4\257\177\031\373I\353\227\355\3219\365g4\010\362\243O\251\333\342\015\300\227\205M-\303\261", 100, "Z\032\013\325z\312$7B\024\241\035?$5\005\374h\300b\267\375Ah\251\311\210l\200\323M\333}\203XIf@\367\222\261\357T\301\256(\004'60\334\304\255\237h\300\361, \336\331(\364\335", 64 }, + { "\333'(\350\331\304A]*\271\315\031\002\372\361\011\035\211\317'\010\355\320.\376\265\262\343F\222A\006\312\037k\224_\327\003\312\256x\337>\304\205\2778", 48, "\215a\037X\3719K(", 200, "\203\363`'\026\233\226/+\260O%\306s\361\015\257\363w\326\042\212\250V\025\023\271\344\351/73\211\206G\2627\355Y8p\324\224\335\242\213\247DJ&\343\031]\362\343cQ\360D_\031\300A\005", 64 }, + { "y\042\366\351\206\036<\213\015Y\013Jb\245,\200bcRZ\253\013\034\346\276,\352\221\365{m\215\255(\251\274aA\231Qo\314\220\000\215[\025_", 48, "/\272\034\233d\274\376i\001\316s5,.qf", 200, "\301\322mH\217C4\207\042\375a\020[\315#$\336\264\012-\236\372\247A\323p\016\370e#6\221\224w\305\331l;A\233\374\311\231\030\236\244\022\002\336\313\202\300\333@)\316\325\042\017Wl\010\352\244", 64 }, + { "\243\034\205\371_\266\334W\037\345\300+@*7\033DN+\025\366\316\235\3720\177\267J\007\004\3030a\356\245!{/Ph8\223\037 %;\320~", 48, "\211\332\202T\321|k\027\207d!\223x\036*O\210U\005\032m\245\306\276", 200, "\214$\026\211\256*\222r|\334\364\000\232\005/I\277\030\015\264\336\344\000q7\235G\327\274AKx\221\257:\004\244:?\030\257^r:\251\312vj\036V\304\231K\317\325\215\015\202?\305\357\225\311\223", 64 }, + { "BS\204Y\226\027rk\273\322\022uFq2\343\324\373x~?\026\003\350$\370\276\242\314\374\177\325Z'\035uh\2213\204Z\314\340\243\221=g\037", 48, "<\225\331HzR\273\272\323c\203\312Z\302\344\226q\305\0241AE\042\251\336\274r<+_X\244", 200, "k\042\212\314OLc\3329\373a\353\256\316\2749>=\244P\260\134x,w\006\203\000L\004\230\223\025&)\241:\255\226\210\265K~)%\134a^\236\215I\023\3725\346Z\327\204\221\350\032\334\376\355", 64 }, + { "\025B\316\263\210\305R\004\013\362\2013\345)\237\023\006uR\305a\366\347\310\001\215\246\021|\014\006~\340\274\335\302\017~\350C\310\0151\204&\015_\332", 48, "\243j\023\234O\272\233|\212\264\2748\340\023\240\360j\314,\213H\367\344=\320\205\336\312\333O\314\344\002\230\316\362e\347\033x", 200, "\341u\033\206O\346\300\206_!\331>\002\203\273\352\351i\007\272\371 \2139:\353\231\255\015\223\262\035\355\375W\213\004\237>&f\042xi\242\266\365g,h\350\324\007\271dt\350\323\267\317\232\346G\247", 64 }, + { "3\303\365\236\271x\021y\227j\002\351\255\225&+{\221\326cUA\331\315\012\325X\035.\014\037\215ng$\370\345gG`\004\353\305\366\226\350\344t", 48, "\366@\247\226\256\020\017\215w\241/F-\033\315\347\204\250\252/\277\336\337\022\211\365\314\036\204z\261\226T\016o2\361}\321A\256\017\270>c\216\010\231", 200, "i\350\326-\342\324\032\205\034>U\346\2228q\207\207Z~\315\375\253\317\222>\373\035\212\021Kiq\316\352\036\3025\037\220\011g7!NHAO\332\257\220\304\206\202\236\246c*\3167\227\024\234U\207", 64 }, + { "\311\3651R\231\201cT@H_\210\352\224;\273)\3454n\213R\377\022Z\244[\222z!\234\004\3760\3162m\310\333}\022\353J\016Vb\367\245", 48, "\267G\341\021\361\231D\345\301\325\277\376g\305\256\2147\271\202Q\320\341\034M\333\251wz\247'\274\311\373\037\263\250\345\233\004\337\345l\325\321\266\370k\222\017M\030'n\033\210\363", 200, "zq/h\233Q\377\001\007i\020d\371\241\217\354\307\022$h\236\210\210\042\233\370=\246\323\236o\222\337;\316\213+\332\251\343\020\320\006\003g\013\025\230\250p\263\252\367\362+L\304\213\356\222P\317\024:", 64 }, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Tue Mar 14 07:06:07 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33231D0B5EF; Tue, 14 Mar 2017 07:06:07 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DDD501C84; Tue, 14 Mar 2017 07:06:06 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E766C7096003; Tue, 14 Mar 2017 07:06:06 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E765J7096002; Tue, 14 Mar 2017 07:06:05 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703140706.v2E765J7096002@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 07:06: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: r315231 - stable/11/sys/dev/firewire X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 07:06:07 -0000 Author: mav Date: Tue Mar 14 07:06:05 2017 New Revision: 315231 URL: https://svnweb.freebsd.org/changeset/base/315231 Log: MFC r314375: Remove some locking not needed for modern CAM. This driver is full of LORs. This change allows to reduce deadlock chance from 100% to level that allows some tests to be done. Modified: stable/11/sys/dev/firewire/sbp_targ.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/firewire/sbp_targ.c ============================================================================== --- stable/11/sys/dev/firewire/sbp_targ.c Tue Mar 14 07:00:22 2017 (r315230) +++ stable/11/sys/dev/firewire/sbp_targ.c Tue Mar 14 07:06:05 2017 (r315231) @@ -317,10 +317,8 @@ sbp_targ_post_busreset(void *arg) unit = &sc->unit; if ((sc->flags & F_FREEZED) == 0) { - SBP_LOCK(sc); sc->flags |= F_FREEZED; xpt_freeze_simq(sc->sim, /*count*/1); - SBP_UNLOCK(sc); } else { printf("%s: already freezed\n", __func__); } @@ -367,10 +365,8 @@ sbp_targ_post_explore(void *arg) struct sbp_targ_softc *sc; sc = (struct sbp_targ_softc *)arg; - SBP_LOCK(sc); sc->flags &= ~F_FREEZED; xpt_release_simq(sc->sim, /*run queue*/TRUE); - SBP_UNLOCK(sc); return; } @@ -869,18 +865,14 @@ sbp_targ_cam_done(struct fw_xfer *xfer) printf("%s: CAM_SEND_STATUS not set %0x\n", __func__, ccb->ccb_h.flags); ccb->ccb_h.status = CAM_REQ_CMP; } - SBP_LOCK(orbi->sc); xpt_done(ccb); - SBP_UNLOCK(orbi->sc); } else { orbi->status.len = 1; sbp_targ_status_FIFO(orbi, orbi->login->fifo_hi, orbi->login->fifo_lo, /*dequeue*/1); ccb->ccb_h.status = CAM_REQ_ABORTED; - SBP_LOCK(orbi->sc); xpt_done(ccb); - SBP_UNLOCK(orbi->sc); } } @@ -1456,9 +1448,7 @@ sbp_targ_cmd_handler(struct fw_xfer *xfe sbp_targ_remove_orb_info(orbi->login, orbi); free(orbi, M_SBP_TARG); atio->ccb_h.status = CAM_REQ_ABORTED; - SBP_LOCK(orbi->sc); xpt_done((union ccb*)atio); - SBP_UNLOCK(orbi->sc); goto done0; } orbi->state = ORBI_STATUS_ATIO; @@ -1530,9 +1520,7 @@ sbp_targ_cmd_handler(struct fw_xfer *xfe orbi->data_lo = orb[3]; orbi->orb4 = *orb4; - SBP_LOCK(orbi->sc); xpt_done((union ccb*)atio); - SBP_UNLOCK(orbi->sc); done0: fw_xfer_free(xfer); return; @@ -2023,8 +2011,8 @@ sbp_targ_detach(device_t dev) SBP_LOCK(sc); xpt_free_path(sc->path); xpt_bus_deregister(cam_sim_path(sc->sim)); - SBP_UNLOCK(sc); cam_sim_free(sc->sim, /*free_devq*/TRUE); + SBP_UNLOCK(sc); for (i = 0; i < MAX_LUN; i++) { lstate = sc->lstate[i]; From owner-svn-src-all@freebsd.org Tue Mar 14 07:09:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3C70CD0B78E; Tue, 14 Mar 2017 07:09:53 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 09D7B1E32; Tue, 14 Mar 2017 07:09:52 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E79q6o096198; Tue, 14 Mar 2017 07:09:52 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E79qth096197; Tue, 14 Mar 2017 07:09:52 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703140709.v2E79qth096197@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Tue, 14 Mar 2017 07:09:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315232 - head X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 07:09:53 -0000 Author: ngie Date: Tue Mar 14 07:09:51 2017 New Revision: 315232 URL: https://svnweb.freebsd.org/changeset/base/315232 Log: Remove /usr/tests/sys/geom/eli/... The path was elided with the existing geli tests under /usr/tests/sys/geom/class/eli/... in r315230. MFC after: 2 weeks (if r315230, etc isn't MFCed at once) Sponsored by: Dell EMC Isilon Modified: head/ObsoleteFiles.inc Modified: head/ObsoleteFiles.inc ============================================================================== --- head/ObsoleteFiles.inc Tue Mar 14 07:06:05 2017 (r315231) +++ head/ObsoleteFiles.inc Tue Mar 14 07:09:51 2017 (r315232) @@ -38,6 +38,12 @@ # xargs -n1 | sort | uniq -d; # done +# 20170313: move .../sys/geom/eli/... to .../sys/geom/class/eli/... +OLD_FILES+=usr/tests/sys/geom/eli/pbkdf2/pbkdf2 +OLD_FILES+=usr/tests/sys/geom/eli/pbkdf2/Kyuafile +OLD_FILES+=usr/tests/sys/geom/eli/Kyuafile +OLD_DIRS+=usr/tests/sys/geom/eli/pbkdf2 +OLD_DIRS+=usr/tests/sys/geom/eli # 20170313: sbin/ipftest and ipresend temporarily disconnected. OLD_FILES+=sbin/ipftest OLD_FILES+=sbin/ipresend From owner-svn-src-all@freebsd.org Tue Mar 14 07:57:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 75CF0D0B7AB; Tue, 14 Mar 2017 07:57:34 +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 4499B175A; Tue, 14 Mar 2017 07:57:34 +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 v2E7vXUF016649; Tue, 14 Mar 2017 07:57:33 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E7vXb7016648; Tue, 14 Mar 2017 07:57:33 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201703140757.v2E7vXb7016648@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Tue, 14 Mar 2017 07:57:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315233 - head/sys/netpfil/ipfw/nat64 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 07:57:34 -0000 Author: ae Date: Tue Mar 14 07:57:33 2017 New Revision: 315233 URL: https://svnweb.freebsd.org/changeset/base/315233 Log: Use memset with structure size. Modified: head/sys/netpfil/ipfw/nat64/nat64stl.c Modified: head/sys/netpfil/ipfw/nat64/nat64stl.c ============================================================================== --- head/sys/netpfil/ipfw/nat64/nat64stl.c Tue Mar 14 07:09:51 2017 (r315232) +++ head/sys/netpfil/ipfw/nat64/nat64stl.c Tue Mar 14 07:57:33 2017 (r315233) @@ -69,7 +69,7 @@ nat64stl_log(struct pfloghdr *plog, stru { static uint32_t pktid = 0; - memset(plog, 0, sizeof(plog)); + memset(plog, 0, sizeof(*plog)); plog->length = PFLOG_REAL_HDRLEN; plog->af = family; plog->action = PF_NAT; From owner-svn-src-all@freebsd.org Tue Mar 14 08:03:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A4EBD0BDF1; Tue, 14 Mar 2017 08:03:58 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D6FAA1F79; Tue, 14 Mar 2017 08:03:57 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E83v0n020446; Tue, 14 Mar 2017 08:03:57 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E83u75020439; Tue, 14 Mar 2017 08:03:56 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703140803.v2E83u75020439@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 08:03:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315234 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 08:03:58 -0000 Author: mav Date: Tue Mar 14 08:03:56 2017 New Revision: 315234 URL: https://svnweb.freebsd.org/changeset/base/315234 Log: Improvements around attach, reset and detach. This change fixes DMA resource leak on driver unload. Also it removes DMA resources allocation for hardcoded number of requests before fetching the real number from firmware. Also it prepares ground for more flexible IRQs allocation according to firmware capabilities. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h head/sys/dev/isp/isp_library.c head/sys/dev/isp/isp_library.h head/sys/dev/isp/isp_pci.c head/sys/dev/isp/isp_sbus.c head/sys/dev/isp/ispvar.h Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp.c Tue Mar 14 08:03:56 2017 (r315234) @@ -178,13 +178,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d const char *btype = "????"; static const char dcrc[] = "Downloaded RISC Code Checksum Failure"; - isp->isp_state = ISP_NILSTATE; - if (isp->isp_dead) { - isp_shutdown(isp); - ISP_DISABLE_INTS(isp); - return; - } - /* * Basic types (SCSI, FibreChannel and PCI or SBus) * have been set in the MD code. We figure out more @@ -195,56 +188,10 @@ isp_reset(ispsoftc_t *isp, int do_load_d * for SCSI adapters and do other settings for the 2100. */ + isp->isp_state = ISP_NILSTATE; ISP_DISABLE_INTS(isp); /* - * Pick an initial maxcmds value which will be used - * to allocate xflist pointer space. It may be changed - * later by the firmware. - */ - if (IS_24XX(isp)) { - isp->isp_maxcmds = 4096; - } else if (IS_2322(isp)) { - isp->isp_maxcmds = 2048; - } else if (IS_23XX(isp) || IS_2200(isp)) { - isp->isp_maxcmds = 1024; - } else { - isp->isp_maxcmds = 512; - } - - /* - * Set up DMA for the request and response queues. - * - * We do this now so we can use the request queue - * for dma to load firmware from. - */ - if (ISP_MBOXDMASETUP(isp) != 0) { - isp_prt(isp, ISP_LOGERR, "Cannot setup DMA"); - return; - } - - /* - * Set up default request/response queue in-pointer/out-pointer - * register indices. - */ - if (IS_24XX(isp)) { - isp->isp_rqstinrp = BIU2400_REQINP; - isp->isp_rqstoutrp = BIU2400_REQOUTP; - isp->isp_respinrp = BIU2400_RSPINP; - isp->isp_respoutrp = BIU2400_RSPOUTP; - } else if (IS_23XX(isp)) { - isp->isp_rqstinrp = BIU_REQINP; - isp->isp_rqstoutrp = BIU_REQOUTP; - isp->isp_respinrp = BIU_RSPINP; - isp->isp_respoutrp = BIU_RSPOUTP; - } else { - isp->isp_rqstinrp = INMAILBOX4; - isp->isp_rqstoutrp = OUTMAILBOX4; - isp->isp_respinrp = OUTMAILBOX5; - isp->isp_respoutrp = INMAILBOX5; - } - - /* * Put the board into PAUSE mode (so we can read the SXP registers * or write FPM/FBM registers). */ @@ -468,7 +415,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_clock = isp->isp_mdvec->dv_clock; } } - } /* @@ -477,11 +423,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_intcnt = isp->isp_intbogus = 0; /* - * Do MD specific pre initialization - */ - ISP_RESET0(isp); - - /* * Hit the chip over the head with hammer, * and give it a chance to recover. */ @@ -513,7 +454,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d } } if (val & BIU2400_DMA_ACTIVE) { - ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "DMA Failed to Stop on Reset"); return; } @@ -533,7 +473,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d } } if (val & BIU2400_SOFT_RESET) { - ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "Failed to come out of reset"); return; } @@ -572,7 +511,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_DELAY(100); if (--loops < 0) { ISP_DUMPREGS(isp, "chip reset timed out"); - ISP_RESET0(isp); return; } } @@ -613,7 +551,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d } } if (val != 0) { - ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "reset didn't clear"); return; } @@ -655,6 +592,26 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_WRITE(isp, HCCR, HCCR_CMD_RELEASE); } + /* + * Set up default request/response queue in-pointer/out-pointer + * register indices. + */ + if (IS_24XX(isp)) { + isp->isp_rqstinrp = BIU2400_REQINP; + isp->isp_rqstoutrp = BIU2400_REQOUTP; + isp->isp_respinrp = BIU2400_RSPINP; + isp->isp_respoutrp = BIU2400_RSPOUTP; + } else if (IS_23XX(isp)) { + isp->isp_rqstinrp = BIU_REQINP; + isp->isp_rqstoutrp = BIU_REQOUTP; + isp->isp_respinrp = BIU_RSPINP; + isp->isp_respoutrp = BIU_RSPOUTP; + } else { + isp->isp_rqstinrp = INMAILBOX4; + isp->isp_rqstoutrp = OUTMAILBOX4; + isp->isp_respinrp = OUTMAILBOX5; + isp->isp_respoutrp = INMAILBOX5; + } ISP_WRITE(isp, isp->isp_rqstinrp, 0); ISP_WRITE(isp, isp->isp_rqstoutrp, 0); ISP_WRITE(isp, isp->isp_respinrp, 0); @@ -668,10 +625,10 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_WRITE(isp, BIU2400_ATIO_RSPOUTP, 0); } - /* - * Do MD specific post initialization - */ - ISP_RESET1(isp); + if (!IS_24XX(isp) && isp->isp_bustype == ISP_BT_PCI) { + /* Make sure the BIOS is disabled */ + ISP_WRITE(isp, HCCR, PCI_HCCR_CMD_BIOS); + } /* * Wait for everything to finish firing up. @@ -686,7 +643,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d while (ISP_READ(isp, OUTMAILBOX0) == MBOX_BUSY) { ISP_DELAY(100); if (--loops < 0) { - ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "MBOX_BUSY never cleared on reset"); return; } @@ -707,14 +663,12 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "NOP command failed (%x)", mbs.param[0]); - ISP_RESET0(isp); return; } /* * Do some operational tests */ - if (IS_SCSI(isp) || IS_24XX(isp)) { static const uint16_t patterns[MAX_MAILBOX] = { 0x0000, 0xdead, 0xbeef, 0xffff, @@ -735,12 +689,10 @@ isp_reset(ispsoftc_t *isp, int do_load_d } isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - ISP_RESET0(isp); return; } for (i = 1; i < nmbox; i++) { if (mbs.param[i] != patterns[i]) { - ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "Register Test Failed at Register %d: should have 0x%04x but got 0x%04x", i, patterns[i], mbs.param[i]); return; } @@ -758,6 +710,17 @@ isp_reset(ispsoftc_t *isp, int do_load_d */ if ((isp->isp_mdvec->dv_ispfw == NULL) || (isp->isp_confopts & ISP_CFG_NORELOAD)) { dodnld = 0; + } else { + + /* + * Set up DMA for the request and response queues. + * We do this now so we can use the request queue + * for dma to load firmware from. + */ + if (ISP_MBOXDMASETUP(isp) != 0) { + isp_prt(isp, ISP_LOGERR, "Cannot setup DMA"); + return; + } } if (IS_24XX(isp)) { @@ -849,7 +812,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d goto again; } isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); - ISP_RESET0(isp); return; } la += nw; @@ -918,7 +880,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); - ISP_RESET0(isp); return; } la += nw; @@ -961,7 +922,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "F/W download failed at word %d", isp->isp_mbxwrk1 - code_org); - ISP_RESET0(isp); return; } } else if (IS_26XX(isp)) { @@ -971,7 +931,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "Flash F/W load failed"); - ISP_RESET0(isp); return; } } else { @@ -992,7 +951,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, dcrc); - ISP_RESET0(isp); return; } } @@ -1003,8 +961,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d * If we didn't actually download f/w, * we still need to (re)start it. */ - - MBSINIT(&mbs, MBOX_EXEC_FIRMWARE, MBLOGALL, 5000000); if (IS_24XX(isp)) { mbs.param[1] = code_org >> 16; @@ -1027,7 +983,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp_mboxcmd(isp, &mbs); if (IS_2322(isp) || IS_24XX(isp)) { if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - ISP_RESET0(isp); return; } } @@ -1051,7 +1006,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d MBSINIT(&mbs, MBOX_ABOUT_FIRMWARE, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - ISP_RESET0(isp); return; } @@ -1249,22 +1203,16 @@ isp_reset(ispsoftc_t *isp, int do_load_d MBSINIT(&mbs, MBOX_GET_RESOURCE_COUNT, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - ISP_RESET0(isp); return; } - if (isp->isp_maxcmds >= mbs.param[3]) { - isp->isp_maxcmds = mbs.param[3]; - } + isp->isp_maxcmds = mbs.param[3]; } else { MBSINIT(&mbs, MBOX_GET_FIRMWARE_STATUS, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - ISP_RESET0(isp); return; } - if (isp->isp_maxcmds >= mbs.param[2]) { - isp->isp_maxcmds = mbs.param[2]; - } + isp->isp_maxcmds = mbs.param[2]; } isp_prt(isp, ISP_LOGCONFIG, "%d max I/O command limit set", isp->isp_maxcmds); @@ -1284,15 +1232,28 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_nchan = 1; } } + + /* + * Final DMA setup after we got isp_maxcmds. + */ + if (ISP_MBOXDMASETUP(isp) != 0) { + isp_prt(isp, ISP_LOGERR, "Cannot setup DMA"); + return; + } + + /* + * Setup interrupts. + */ + if (ISP_IRQSETUP(isp) != 0) { + isp_prt(isp, ISP_LOGERR, "Cannot setup IRQ"); + return; + } + ISP_ENABLE_INTS(isp); + if (IS_FC(isp)) { for (i = 0; i < isp->isp_nchan; i++) isp_change_fw_state(isp, i, FW_CONFIG_WAIT); } - if (isp->isp_dead) { - isp_shutdown(isp); - ISP_DISABLE_INTS(isp); - return; - } isp->isp_state = ISP_RESETSTATE; @@ -1303,7 +1264,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d * of knowing how many luns we support. * * Expanded lun firmware gives you 32 luns for SCSI cards and - * 16384 luns for Fibre Channel cards. + * unlimited luns for Fibre Channel cards. * * It turns out that even for QLogic 2100s with ROM 1.10 and above * we do get a firmware attributes word returned in mailbox register 6. @@ -1351,7 +1312,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d * Clean firmware shutdown. */ static int -isp_deinit(ispsoftc_t *isp) +isp_stop(ispsoftc_t *isp) { mbreg_t mbs; @@ -1370,6 +1331,35 @@ isp_deinit(ispsoftc_t *isp) } /* + * Hardware shutdown. + */ +void +isp_shutdown(ispsoftc_t *isp) +{ + + if (isp->isp_state >= ISP_RESETSTATE) + isp_stop(isp); + ISP_DISABLE_INTS(isp); + if (IS_FC(isp)) { + if (IS_24XX(isp)) { + ISP_WRITE(isp, BIU2400_ICR, 0); + ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_PAUSE); + } else { + ISP_WRITE(isp, BIU_ICR, 0); + ISP_WRITE(isp, HCCR, HCCR_CMD_PAUSE); + ISP_WRITE(isp, BIU2100_CSR, BIU2100_FPM0_REGS); + ISP_WRITE(isp, FPM_DIAG_CONFIG, FPM_SOFT_RESET); + ISP_WRITE(isp, BIU2100_CSR, BIU2100_FB_REGS); + ISP_WRITE(isp, FBM_CMD, FBMCMD_FIFO_RESET_ALL); + ISP_WRITE(isp, BIU2100_CSR, BIU2100_RISC_REGS); + } + } else { + ISP_WRITE(isp, BIU_ICR, 0); + ISP_WRITE(isp, HCCR, HCCR_CMD_PAUSE); + } +} + +/* * Initialize Parameters of Hardware to a known state. * * Locks are held before coming here. @@ -5599,7 +5589,6 @@ isp_parse_async(ispsoftc_t *isp, uint16_ isp_async(isp, ISPASYNC_BUS_RESET, chan); break; case ASYNC_SYSTEM_ERROR: - isp->isp_dead = 1; isp->isp_state = ISP_CRASHED; /* * Were we waiting for a mailbox command to complete? @@ -5770,7 +5759,6 @@ isp_parse_async_fc(ispsoftc_t *isp, uint switch (mbox) { case ASYNC_SYSTEM_ERROR: - isp->isp_dead = 1; isp->isp_state = ISP_CRASHED; FCPARAM(isp, chan)->isp_loopstate = LOOP_NIL; isp_change_fw_state(isp, chan, FW_CONFIG_WAIT); @@ -6052,7 +6040,6 @@ isp_parse_async_fc(ispsoftc_t *isp, uint "Point-to-Point -> Loop mode (BAD LIP)"); break; case ISP_CONN_FATAL: - isp->isp_dead = 1; isp->isp_state = ISP_CRASHED; isp_prt(isp, ISP_LOGERR, "FATAL CONNECTION ERROR"); isp_async(isp, ISPASYNC_FW_CRASH); @@ -7895,14 +7882,13 @@ isp_reinit(ispsoftc_t *isp, int do_load_ { int i, res = 0; - if (isp->isp_state == ISP_RUNSTATE) - isp_deinit(isp); + if (isp->isp_state > ISP_RESETSTATE) + isp_stop(isp); if (isp->isp_state != ISP_RESETSTATE) isp_reset(isp, do_load_defaults); if (isp->isp_state != ISP_RESETSTATE) { res = EIO; isp_prt(isp, ISP_LOGERR, "%s: cannot reset card", __func__); - ISP_DISABLE_INTS(isp); goto cleanup; } Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp_freebsd.c Tue Mar 14 08:03:56 2017 (r315234) @@ -1529,7 +1529,7 @@ isp_target_start_ctio(ispsoftc_t *isp, u isp_prt(isp, ISP_LOGTDEBUG0, "%s: ests base %p vaddr %p ecmd_dma %jx addr %jx len %u", __func__, isp->isp_osinfo.ecmd_base, atp->ests, (uintmax_t) isp->isp_osinfo.ecmd_dma, (uintmax_t)addr, MIN_FCP_RESPONSE_SIZE + sense_length); cto->rsp.m2.ct_datalen = MIN_FCP_RESPONSE_SIZE + sense_length; - if (isp->isp_osinfo.sixtyfourbit) { + if (cto->ct_header.rqs_entry_type == RQSTYPE_CTIO3) { cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_base = DMA_LO32(addr); cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_basehi = DMA_HI32(addr); cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; @@ -4304,21 +4304,6 @@ changed: } } - -/* - * Locks are held before coming here. - */ -void -isp_uninit(ispsoftc_t *isp) -{ - if (IS_24XX(isp)) { - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_RESET); - } else { - ISP_WRITE(isp, HCCR, HCCR_CMD_RESET); - } - ISP_DISABLE_INTS(isp); -} - uint64_t isp_default_wwn(ispsoftc_t * isp, int chan, int isactive, int iswwnn) { Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp_freebsd.h Tue Mar 14 08:03:56 2017 (r315234) @@ -697,7 +697,6 @@ default: \ */ extern int isp_attach(ispsoftc_t *); extern int isp_detach(ispsoftc_t *); -extern void isp_uninit(ispsoftc_t *); extern uint64_t isp_default_wwn(ispsoftc_t *, int, int, int); /* Modified: head/sys/dev/isp/isp_library.c ============================================================================== --- head/sys/dev/isp/isp_library.c Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp_library.c Tue Mar 14 08:03:56 2017 (r315234) @@ -632,28 +632,6 @@ isp_clear_commands(ispsoftc_t *isp) #endif } -void -isp_shutdown(ispsoftc_t *isp) -{ - if (IS_FC(isp)) { - if (IS_24XX(isp)) { - ISP_WRITE(isp, BIU2400_ICR, 0); - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_PAUSE); - } else { - ISP_WRITE(isp, BIU_ICR, 0); - ISP_WRITE(isp, HCCR, HCCR_CMD_PAUSE); - ISP_WRITE(isp, BIU2100_CSR, BIU2100_FPM0_REGS); - ISP_WRITE(isp, FPM_DIAG_CONFIG, FPM_SOFT_RESET); - ISP_WRITE(isp, BIU2100_CSR, BIU2100_FB_REGS); - ISP_WRITE(isp, FBM_CMD, FBMCMD_FIFO_RESET_ALL); - ISP_WRITE(isp, BIU2100_CSR, BIU2100_RISC_REGS); - } - } else { - ISP_WRITE(isp, BIU_ICR, 0); - ISP_WRITE(isp, HCCR, HCCR_CMD_PAUSE); - } -} - /* * Functions to move stuff to a form that the QLogic RISC engine understands * and functions to move stuff back to a form the processor understands. Modified: head/sys/dev/isp/isp_library.h ============================================================================== --- head/sys/dev/isp/isp_library.h Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp_library.h Tue Mar 14 08:03:56 2017 (r315234) @@ -77,11 +77,6 @@ const char *isp_fc_toponame(fcparam *); void isp_clear_commands(ispsoftc_t *); /* - * Common chip shutdown function - */ -void isp_shutdown(ispsoftc_t *); - -/* * Put/Get routines to push from CPU view to device view * or to pull from device view to CPU view for various * data structures (IOCB) Modified: head/sys/dev/isp/isp_pci.c ============================================================================== --- head/sys/dev/isp/isp_pci.c Tue Mar 14 07:57:33 2017 (r315233) +++ head/sys/dev/isp/isp_pci.c Tue Mar 14 08:03:56 2017 (r315234) @@ -65,11 +65,9 @@ static int isp_pci_rd_isr(ispsoftc_t *, static int isp_pci_rd_isr_2300(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); static int isp_pci_rd_isr_2400(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); static int isp_pci_mbxdma(ispsoftc_t *); +static void isp_pci_mbxdmafree(ispsoftc_t *); static int isp_pci_dmasetup(ispsoftc_t *, XS_T *, void *); - - -static void isp_pci_reset0(ispsoftc_t *); -static void isp_pci_reset1(ispsoftc_t *); +static int isp_pci_irqsetup(ispsoftc_t *); static void isp_pci_dumpregs(ispsoftc_t *, const char *); static struct ispmdvec mdvec = { @@ -79,8 +77,7 @@ static struct ispmdvec mdvec = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs, NULL, BIU_BURST_ENABLE|BIU_PCI_CONF1_FIFO_64 @@ -93,8 +90,7 @@ static struct ispmdvec mdvec_1080 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs, NULL, BIU_BURST_ENABLE|BIU_PCI_CONF1_FIFO_64 @@ -107,8 +103,7 @@ static struct ispmdvec mdvec_12160 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs, NULL, BIU_BURST_ENABLE|BIU_PCI_CONF1_FIFO_64 @@ -121,8 +116,7 @@ static struct ispmdvec mdvec_2100 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs }; @@ -133,8 +127,7 @@ static struct ispmdvec mdvec_2200 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs }; @@ -145,8 +138,7 @@ static struct ispmdvec mdvec_2300 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, isp_pci_dumpregs }; @@ -157,8 +149,7 @@ static struct ispmdvec mdvec_2400 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, NULL }; @@ -169,8 +160,7 @@ static struct ispmdvec mdvec_2500 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, NULL }; @@ -181,8 +171,7 @@ static struct ispmdvec mdvec_2600 = { isp_pci_mbxdma, isp_pci_dmasetup, isp_common_dmateardown, - isp_pci_reset0, - isp_pci_reset1, + isp_pci_irqsetup, NULL }; @@ -681,26 +670,19 @@ isp_get_specific_options(device_t dev, i static int isp_pci_attach(device_t dev) { - int i, locksetup = 0; + struct isp_pcisoftc *pcs = device_get_softc(dev); + ispsoftc_t *isp = &pcs->pci_isp; + int i; uint32_t data, cmd, linesz, did; - struct isp_pcisoftc *pcs; - ispsoftc_t *isp; size_t psize, xsize; char fwname[32]; - pcs = device_get_softc(dev); - if (pcs == NULL) { - device_printf(dev, "cannot get softc\n"); - return (ENOMEM); - } - memset(pcs, 0, sizeof (*pcs)); - pcs->pci_dev = dev; - isp = &pcs->pci_isp; isp->isp_dev = dev; isp->isp_nchan = 1; if (sizeof (bus_addr_t) > 4) isp->isp_osinfo.sixtyfourbit = 1; + mtx_init(&isp->isp_osinfo.lock, "isp", NULL, MTX_DEF); /* * Get Generic Options @@ -980,10 +962,6 @@ isp_pci_attach(device_t dev) goto bad; } - /* Make sure the lock is set up. */ - mtx_init(&isp->isp_osinfo.lock, "isp", NULL, MTX_DEF); - locksetup++; - if (isp_setup_intr(dev, pcs->irq, ISP_IFLAGS, NULL, isp_platform_intr, isp, &pcs->ih)) { device_printf(dev, "could not setup interrupt\n"); goto bad; @@ -1007,7 +985,7 @@ isp_pci_attach(device_t dev) ISP_UNLOCK(isp); if (isp_attach(isp)) { ISP_LOCK(isp); - isp_uninit(isp); + isp_shutdown(isp); ISP_UNLOCK(isp); goto bad; } @@ -1017,9 +995,6 @@ bad: if (pcs->ih) { (void) bus_teardown_intr(dev, pcs->irq, pcs->ih); } - if (locksetup) { - mtx_destroy(&isp->isp_osinfo.lock); - } if (pcs->irq) { (void) bus_release_resource(dev, SYS_RES_IRQ, pcs->iqd, pcs->irq); } @@ -1040,43 +1015,34 @@ bad: free(pcs->pci_isp.isp_osinfo.pc.ptr, M_DEVBUF); pcs->pci_isp.isp_osinfo.pc.ptr = NULL; } + mtx_destroy(&isp->isp_osinfo.lock); return (ENXIO); } static int isp_pci_detach(device_t dev) { - struct isp_pcisoftc *pcs; - ispsoftc_t *isp; + struct isp_pcisoftc *pcs = device_get_softc(dev); + ispsoftc_t *isp = &pcs->pci_isp; int status; - pcs = device_get_softc(dev); - if (pcs == NULL) { - return (ENXIO); - } - isp = (ispsoftc_t *) pcs; status = isp_detach(isp); if (status) return (status); ISP_LOCK(isp); - isp_uninit(isp); - if (pcs->ih) { - (void) bus_teardown_intr(dev, pcs->irq, pcs->ih); - } + isp_shutdown(isp); ISP_UNLOCK(isp); - mtx_destroy(&isp->isp_osinfo.lock); + if (pcs->ih) + (void) bus_teardown_intr(dev, pcs->irq, pcs->ih); (void) bus_release_resource(dev, SYS_RES_IRQ, pcs->iqd, pcs->irq); - if (pcs->msicount) { + if (pcs->msicount) pci_release_msi(dev); - } (void) bus_release_resource(dev, pcs->rtp, pcs->rgd, pcs->regs); if (pcs->regs1) (void) bus_release_resource(dev, pcs->rtp1, pcs->rgd1, pcs->regs1); if (pcs->regs2) (void) bus_release_resource(dev, pcs->rtp2, pcs->rgd2, pcs->regs2); - /* - * XXX: THERE IS A LOT OF LEAKAGE HERE - */ + isp_pci_mbxdmafree(isp); if (pcs->pci_isp.isp_param) { free(pcs->pci_isp.isp_param, M_DEVBUF); pcs->pci_isp.isp_param = NULL; @@ -1085,6 +1051,7 @@ isp_pci_detach(device_t dev) free(pcs->pci_isp.isp_osinfo.pc.ptr, M_DEVBUF); pcs->pci_isp.isp_osinfo.pc.ptr = NULL; } + mtx_destroy(&isp->isp_osinfo.lock); return (0); } @@ -1571,56 +1538,39 @@ isp_pci_mbxdma(ispsoftc_t *isp) struct imush im; isp_ecmd_t *ecmd; - /* - * Already been here? If so, leave... - */ - if (isp->isp_rquest) { + /* Already been here? If so, leave... */ + if (isp->isp_xflist != NULL) + return (0); + if (isp->isp_rquest != NULL && isp->isp_maxcmds == 0) return (0); - } ISP_UNLOCK(isp); - - if (isp->isp_maxcmds == 0) { - isp_prt(isp, ISP_LOGERR, "maxcmds not set"); - ISP_LOCK(isp); - return (1); - } + if (isp->isp_rquest != NULL) + goto gotmaxcmds; hlim = BUS_SPACE_MAXADDR; if (IS_ULTRA2(isp) || IS_FC(isp) || IS_1240(isp)) { - if (sizeof (bus_size_t) > 4) { + if (sizeof (bus_size_t) > 4) slim = (bus_size_t) (1ULL << 32); - } else { + else slim = (bus_size_t) (1UL << 31); - } llim = BUS_SPACE_MAXADDR; } else { - llim = BUS_SPACE_MAXADDR_32BIT; slim = (1UL << 24); + llim = BUS_SPACE_MAXADDR_32BIT; } - - len = isp->isp_maxcmds * sizeof (struct isp_pcmd); - isp->isp_osinfo.pcmd_pool = (struct isp_pcmd *) malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); - - if (isp->isp_osinfo.sixtyfourbit) { + if (isp->isp_osinfo.sixtyfourbit) nsegs = ISP_NSEG64_MAX; - } else { + else nsegs = ISP_NSEG_MAX; - } - if (isp_dma_tag_create(BUS_DMA_ROOTARG(ISP_PCD(isp)), 1, slim, llim, hlim, NULL, NULL, BUS_SPACE_MAXSIZE, nsegs, slim, 0, &isp->isp_osinfo.dmat)) { - free(isp->isp_osinfo.pcmd_pool, M_DEVBUF); + if (isp_dma_tag_create(BUS_DMA_ROOTARG(ISP_PCD(isp)), 1, + slim, llim, hlim, NULL, NULL, BUS_SPACE_MAXSIZE, nsegs, slim, 0, + &isp->isp_osinfo.dmat)) { ISP_LOCK(isp); isp_prt(isp, ISP_LOGERR, "could not create master dma tag"); return (1); } - len = sizeof (isp_hdl_t) * isp->isp_maxcmds; - isp->isp_xflist = (isp_hdl_t *) malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); - for (len = 0; len < isp->isp_maxcmds - 1; len++) { - isp->isp_xflist[len].cmd = &isp->isp_xflist[len+1]; - } - isp->isp_xffree = isp->isp_xflist; - /* * Allocate and map the request queue and a region for external * DMA addressable command/status structures (22XX and later). @@ -1632,20 +1582,20 @@ isp_pci_mbxdma(ispsoftc_t *isp) BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL, NULL, len, 1, len, 0, &isp->isp_osinfo.reqdmat)) { isp_prt(isp, ISP_LOGERR, "cannot create request DMA tag"); - goto bad1; + goto bad; } if (bus_dmamem_alloc(isp->isp_osinfo.reqdmat, (void **)&base, BUS_DMA_COHERENT, &isp->isp_osinfo.reqmap) != 0) { isp_prt(isp, ISP_LOGERR, "cannot allocate request DMA memory"); bus_dma_tag_destroy(isp->isp_osinfo.reqdmat); - goto bad1; + goto bad; } isp->isp_rquest = base; im.error = 0; if (bus_dmamap_load(isp->isp_osinfo.reqdmat, isp->isp_osinfo.reqmap, base, len, imc, &im, 0) || im.error) { isp_prt(isp, ISP_LOGERR, "error loading request DMA map %d", im.error); - goto bad1; + goto bad; } isp_prt(isp, ISP_LOGDEBUG0, "request area @ 0x%jx/0x%jx", (uintmax_t)im.maddr, (uintmax_t)len); @@ -1673,20 +1623,20 @@ isp_pci_mbxdma(ispsoftc_t *isp) BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL, NULL, len, 1, len, 0, &isp->isp_osinfo.respdmat)) { isp_prt(isp, ISP_LOGERR, "cannot create response DMA tag"); - goto bad1; + goto bad; } if (bus_dmamem_alloc(isp->isp_osinfo.respdmat, (void **)&base, BUS_DMA_COHERENT, &isp->isp_osinfo.respmap) != 0) { isp_prt(isp, ISP_LOGERR, "cannot allocate response DMA memory"); bus_dma_tag_destroy(isp->isp_osinfo.respdmat); - goto bad1; + goto bad; } isp->isp_result = base; im.error = 0; if (bus_dmamap_load(isp->isp_osinfo.respdmat, isp->isp_osinfo.respmap, base, len, imc, &im, 0) || im.error) { isp_prt(isp, ISP_LOGERR, "error loading response DMA map %d", im.error); - goto bad1; + goto bad; } isp_prt(isp, ISP_LOGDEBUG0, "response area @ 0x%jx/0x%jx", (uintmax_t)im.maddr, (uintmax_t)len); @@ -1702,13 +1652,13 @@ isp_pci_mbxdma(ispsoftc_t *isp) BUS_SPACE_MAXADDR_32BIT, BUS_SPACE_MAXADDR, NULL, NULL, len, 1, len, 0, &isp->isp_osinfo.atiodmat)) { isp_prt(isp, ISP_LOGERR, "cannot create ATIO DMA tag"); - goto bad1; + goto bad; } if (bus_dmamem_alloc(isp->isp_osinfo.atiodmat, (void **)&base, BUS_DMA_COHERENT, &isp->isp_osinfo.atiomap) != 0) { isp_prt(isp, ISP_LOGERR, "cannot allocate ATIO DMA memory"); bus_dma_tag_destroy(isp->isp_osinfo.atiodmat); - goto bad1; + goto bad; } isp->isp_atioq = base; im.error = 0; @@ -1754,6 +1704,7 @@ isp_pci_mbxdma(ispsoftc_t *isp) base, ISP_FC_SCRLEN, imc, &im, 0) || im.error) { bus_dmamem_free(isp->isp_osinfo.scdmat, base, fc->scmap); + FCPARAM(isp, cmap)->isp_scratch = NULL; goto bad; } FCPARAM(isp, cmap)->isp_scdma = im.maddr; @@ -1775,83 +1726,134 @@ isp_pci_mbxdma(ispsoftc_t *isp) } } + if (isp->isp_maxcmds == 0) { + ISP_LOCK(isp); + return (0); + } + +gotmaxcmds: + len = isp->isp_maxcmds * sizeof (struct isp_pcmd); + isp->isp_osinfo.pcmd_pool = (struct isp_pcmd *) + malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); for (i = 0; i < isp->isp_maxcmds; i++) { struct isp_pcmd *pcmd = &isp->isp_osinfo.pcmd_pool[i]; error = bus_dmamap_create(isp->isp_osinfo.dmat, 0, &pcmd->dmap); if (error) { isp_prt(isp, ISP_LOGERR, "error %d creating per-cmd DMA maps", error); while (--i >= 0) { - bus_dmamap_destroy(isp->isp_osinfo.dmat, isp->isp_osinfo.pcmd_pool[i].dmap); + bus_dmamap_destroy(isp->isp_osinfo.dmat, + isp->isp_osinfo.pcmd_pool[i].dmap); } goto bad; } callout_init_mtx(&pcmd->wdog, &isp->isp_osinfo.lock, 0); - if (i == isp->isp_maxcmds-1) { + if (i == isp->isp_maxcmds-1) pcmd->next = NULL; - } else { + else pcmd->next = &isp->isp_osinfo.pcmd_pool[i+1]; - } } isp->isp_osinfo.pcmd_free = &isp->isp_osinfo.pcmd_pool[0]; + + len = sizeof (isp_hdl_t) * isp->isp_maxcmds; + isp->isp_xflist = (isp_hdl_t *) malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); + for (len = 0; len < isp->isp_maxcmds - 1; len++) + isp->isp_xflist[len].cmd = &isp->isp_xflist[len+1]; + isp->isp_xffree = isp->isp_xflist; + ISP_LOCK(isp); return (0); bad: + isp_pci_mbxdmafree(isp); + ISP_LOCK(isp); + return (1); +} + +static void +isp_pci_mbxdmafree(ispsoftc_t *isp) +{ + int i; + + if (isp->isp_xflist != NULL) { + free(isp->isp_xflist, M_DEVBUF); + isp->isp_xflist = NULL; + } + if (isp->isp_osinfo.pcmd_pool != NULL) { + for (i = 0; i < isp->isp_maxcmds; i++) { + bus_dmamap_destroy(isp->isp_osinfo.dmat, + isp->isp_osinfo.pcmd_pool[i].dmap); + } + free(isp->isp_osinfo.pcmd_pool, M_DEVBUF); + isp->isp_osinfo.pcmd_pool = NULL; + } if (IS_FC(isp)) { - while (--cmap >= 0) { - struct isp_fc *fc = ISP_FC_PC(isp, cmap); - bus_dmamap_unload(isp->isp_osinfo.scdmat, fc->scmap); - bus_dmamem_free(isp->isp_osinfo.scdmat, - FCPARAM(isp, cmap)->isp_scratch, fc->scmap); + for (i = 0; i < isp->isp_nchan; i++) { + struct isp_fc *fc = ISP_FC_PC(isp, i); + if (FCPARAM(isp, i)->isp_scdma != 0) { + bus_dmamap_unload(isp->isp_osinfo.scdmat, + fc->scmap); + FCPARAM(isp, i)->isp_scdma = 0; + } + if (FCPARAM(isp, i)->isp_scratch != NULL) { + bus_dmamem_free(isp->isp_osinfo.scdmat, + FCPARAM(isp, i)->isp_scratch, fc->scmap); + FCPARAM(isp, i)->isp_scratch = NULL; + } while (fc->nexus_free_list) { struct isp_nexus *n = fc->nexus_free_list; fc->nexus_free_list = n->next; free(n, M_DEVBUF); } } - bus_dma_tag_destroy(isp->isp_osinfo.scdmat); - bus_dmamap_unload(isp->isp_osinfo.iocbdmat, isp->isp_osinfo.iocbmap); - bus_dmamem_free(isp->isp_osinfo.iocbdmat, isp->isp_iocb, - isp->isp_osinfo.iocbmap); - bus_dma_tag_destroy(isp->isp_osinfo.iocbdmat); - } -bad1: - if (isp->isp_rquest_dma != 0) { - bus_dmamap_unload(isp->isp_osinfo.reqdmat, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Tue Mar 14 08:12:15 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5012ED0B2EA; Tue, 14 Mar 2017 08:12:15 +0000 (UTC) (envelope-from dexuan@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 1FBCF1715; Tue, 14 Mar 2017 08:12:15 +0000 (UTC) (envelope-from dexuan@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E8CEVk024652; Tue, 14 Mar 2017 08:12:14 GMT (envelope-from dexuan@FreeBSD.org) Received: (from dexuan@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E8CE6V024651; Tue, 14 Mar 2017 08:12:14 GMT (envelope-from dexuan@FreeBSD.org) Message-Id: <201703140812.v2E8CE6V024651@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dexuan set sender to dexuan@FreeBSD.org using -f From: Dexuan Cui Date: Tue, 14 Mar 2017 08:12:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315235 - head/sys/boot/efi/loader X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 08:12:15 -0000 Author: dexuan Date: Tue Mar 14 08:12:14 2017 New Revision: 315235 URL: https://svnweb.freebsd.org/changeset/base/315235 Log: loader.efi: use stricter check for Hyper-V Some other hypervisors like Xen can pretend to be Hyper-V but obviously they can't implement all Hyper-V features. Let's make sure we're genuine Hyper-V here. Also fix some minor coding style issues. PR: 211746 MFC after: 2 weeks Sponsored by: Microsoft Modified: head/sys/boot/efi/loader/copy.c Modified: head/sys/boot/efi/loader/copy.c ============================================================================== --- head/sys/boot/efi/loader/copy.c Tue Mar 14 08:03:56 2017 (r315234) +++ head/sys/boot/efi/loader/copy.c Tue Mar 14 08:12:14 2017 (r315235) @@ -52,8 +52,11 @@ __FBSDID("$FreeBSD$"); #define CPUID_LEAF_HV_FEATURES 0x40000003 #define CPUID_LEAF_HV_LIMITS 0x40000005 #define CPUID_HV_IFACE_HYPERV 0x31237648 /* HV#1 */ +#define CPUID_HV_MSR_TIME_REFCNT 0x0002 /* MSR_HV_TIME_REF_COUNT */ #define CPUID_HV_MSR_HYPERCALL 0x0020 -static int running_on_hyperv(void) + +static int +running_on_hyperv(void) { char hv_vendor[16]; uint32_t regs[4]; @@ -80,6 +83,8 @@ static int running_on_hyperv(void) do_cpuid(CPUID_LEAF_HV_FEATURES, regs); if ((regs[0] & CPUID_HV_MSR_HYPERCALL) == 0) return (0); + if ((regs[0] & CPUID_HV_MSR_TIME_REFCNT) == 0) + return (0); return (1); } @@ -157,7 +162,7 @@ efi_verify_staging_size(unsigned long *n out: free(map); } -#endif +#endif /* __i386__ || __amd64__ */ #ifndef EFI_STAGING_SIZE #define EFI_STAGING_SIZE 64 From owner-svn-src-all@freebsd.org Tue Mar 14 08:45:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D92A8D0A540; Tue, 14 Mar 2017 08:45:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A62511E03; Tue, 14 Mar 2017 08:45:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2E8jXp7037000; Tue, 14 Mar 2017 08:45:33 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E8jX4A036999; Tue, 14 Mar 2017 08:45:33 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703140845.v2E8jX4A036999@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 08:45:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315236 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 08:45:34 -0000 Author: mav Date: Tue Mar 14 08:45:33 2017 New Revision: 315236 URL: https://svnweb.freebsd.org/changeset/base/315236 Log: Remove dangerous and questionable isp_mboxcmd_qnw() call. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Tue Mar 14 08:12:14 2017 (r315235) +++ head/sys/dev/isp/isp.c Tue Mar 14 08:45:33 2017 (r315236) @@ -6503,20 +6503,8 @@ isp_parse_status(ispsoftc_t *isp, ispsta isp_prt(isp, ISP_LOGINFO, "port %s for target %d", reason, XS_TGT(xs)); - /* - * If we're on a local loop, force a LIP (which is overkill) - * to force a re-login of this unit. If we're on fabric, - * then we'll have to log in again as a matter of course. - */ - if (fcp->isp_topo == TOPO_NL_PORT || - fcp->isp_topo == TOPO_FL_PORT) { - mbreg_t mbs; - MBSINIT(&mbs, MBOX_INIT_LIP, MBLOGALL, 0); - if (ISP_CAP_2KLOGIN(isp)) { - mbs.ibits = (1 << 10); - } - isp_mboxcmd_qnw(isp, &mbs, 1); - } + /* XXX: Should we trigger rescan or FW announce change? */ + if (XS_NOERR(xs)) { lp = &fcp->portdb[XS_TGT(xs)]; if (lp->state == FC_PORTDB_STATE_ZOMBIE) { @@ -6664,9 +6652,8 @@ isp_parse_status_24xx(ispsoftc_t *isp, i isp_prt(isp, ISP_LOGINFO, "Chan %d port %s for target %d", chan, reason, XS_TGT(xs)); - /* - * There is no MBOX_INIT_LIP for the 24XX. - */ + /* XXX: Should we trigger rescan or FW announce change? */ + if (XS_NOERR(xs)) { lp = &fcp->portdb[XS_TGT(xs)]; if (lp->state == FC_PORTDB_STATE_ZOMBIE) { From owner-svn-src-all@freebsd.org Tue Mar 14 08:45:54 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 307F9D0A58E; Tue, 14 Mar 2017 08:45:54 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 003A31F53; Tue, 14 Mar 2017 08:45:53 +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 v2E8jrcI037058; Tue, 14 Mar 2017 08:45:53 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E8jrh5037057; Tue, 14 Mar 2017 08:45:53 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703140845.v2E8jrh5037057@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 08:45:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315237 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 08:45:54 -0000 Author: kib Date: Tue Mar 14 08:45:52 2017 New Revision: 315237 URL: https://svnweb.freebsd.org/changeset/base/315237 Log: Hide kev_iovlen() definition under #ifdef KTRACE, fixing build of kernel configs without KTRACE. Reported by: rpokala Sponsored by: The FreeBSD Foundation MFC after: 4 days Modified: head/sys/kern/kern_event.c Modified: head/sys/kern/kern_event.c ============================================================================== --- head/sys/kern/kern_event.c Tue Mar 14 08:45:33 2017 (r315236) +++ head/sys/kern/kern_event.c Tue Mar 14 08:45:52 2017 (r315237) @@ -887,6 +887,7 @@ kern_kqueue(struct thread *td, int flags return (0); } +#ifdef KTRACE static size_t kev_iovlen(int n, u_int kgio) { @@ -895,6 +896,7 @@ kev_iovlen(int n, u_int kgio) return (kgio); return (n * sizeof(struct kevent)); } +#endif #ifndef _SYS_SYSPROTO_H_ struct kevent_args { From owner-svn-src-all@freebsd.org Tue Mar 14 09:25:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5AA37D0B983; Tue, 14 Mar 2017 09:25:03 +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 1F49E1B26; Tue, 14 Mar 2017 09:25:03 +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 v2E9P2gp053876; Tue, 14 Mar 2017 09:25:02 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2E9P2Oh053874; Tue, 14 Mar 2017 09:25:02 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703140925.v2E9P2Oh053874@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 09:25:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315238 - in head/sys: compat/freebsd32 kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 09:25:03 -0000 Author: kib Date: Tue Mar 14 09:25:01 2017 New Revision: 315238 URL: https://svnweb.freebsd.org/changeset/base/315238 Log: Use designated initializers for kevent_copyops. Sponsored by: The FreeBSD Foundation MFC after: 1 week Modified: head/sys/compat/freebsd32/freebsd32_misc.c head/sys/kern/kern_event.c Modified: head/sys/compat/freebsd32/freebsd32_misc.c ============================================================================== --- head/sys/compat/freebsd32/freebsd32_misc.c Tue Mar 14 08:45:52 2017 (r315237) +++ head/sys/compat/freebsd32/freebsd32_misc.c Tue Mar 14 09:25:01 2017 (r315238) @@ -651,9 +651,11 @@ freebsd32_kevent(struct thread *td, stru { struct timespec32 ts32; struct timespec ts, *tsp; - struct kevent_copyops k_ops = { uap, - freebsd32_kevent_copyout, - freebsd32_kevent_copyin}; + struct kevent_copyops k_ops = { + .arg = uap, + .k_copyout = freebsd32_kevent_copyout, + .k_copyin = freebsd32_kevent_copyin, + }; int error; Modified: head/sys/kern/kern_event.c ============================================================================== --- head/sys/kern/kern_event.c Tue Mar 14 08:45:52 2017 (r315237) +++ head/sys/kern/kern_event.c Tue Mar 14 09:25:01 2017 (r315238) @@ -912,9 +912,11 @@ int sys_kevent(struct thread *td, struct kevent_args *uap) { struct timespec ts, *tsp; - struct kevent_copyops k_ops = { uap, - kevent_copyout, - kevent_copyin}; + struct kevent_copyops k_ops = { + .arg = uap, + .k_copyout = kevent_copyout, + .k_copyin = kevent_copyin, + }; int error; #ifdef KTRACE struct uio ktruio; From owner-svn-src-all@freebsd.org Tue Mar 14 10:06:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CB470D0CCD5; Tue, 14 Mar 2017 10:06:21 +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 9A87817F2; Tue, 14 Mar 2017 10:06:21 +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 v2EA6Klq070750; Tue, 14 Mar 2017 10:06:20 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EA6KxL070749; Tue, 14 Mar 2017 10:06:20 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703141006.v2EA6KxL070749@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 10:06: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: r315239 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 10:06:21 -0000 Author: kib Date: Tue Mar 14 10:06:20 2017 New Revision: 315239 URL: https://svnweb.freebsd.org/changeset/base/315239 Log: MFC r314849: Consistently use vm_ooffset_t type for the vm object offset in elf_load_section. Modified: stable/11/sys/kern/imgact_elf.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/imgact_elf.c ============================================================================== --- stable/11/sys/kern/imgact_elf.c Tue Mar 14 09:25:01 2017 (r315238) +++ stable/11/sys/kern/imgact_elf.c Tue Mar 14 10:06:20 2017 (r315239) @@ -89,7 +89,7 @@ static Elf_Brandinfo *__elfN(get_brandin const char *interp, int interp_name_len, int32_t *osrel); static int __elfN(load_file)(struct proc *p, const char *file, u_long *addr, u_long *entry, size_t pagesize); -static int __elfN(load_section)(struct image_params *imgp, vm_offset_t offset, +static int __elfN(load_section)(struct image_params *imgp, vm_ooffset_t offset, caddr_t vmaddr, size_t memsz, size_t filsz, vm_prot_t prot, size_t pagesize); static int __CONCAT(exec_, __elfN(imgact))(struct image_params *imgp); @@ -490,7 +490,7 @@ __elfN(map_insert)(struct image_params * } static int -__elfN(load_section)(struct image_params *imgp, vm_offset_t offset, +__elfN(load_section)(struct image_params *imgp, vm_ooffset_t offset, caddr_t vmaddr, size_t memsz, size_t filsz, vm_prot_t prot, size_t pagesize) { @@ -501,7 +501,7 @@ __elfN(load_section)(struct image_params vm_offset_t map_addr; int error, rv, cow; size_t copy_len; - vm_offset_t file_addr; + vm_ooffset_t file_addr; /* * It's necessary to fail if the filsz + offset taken from the From owner-svn-src-all@freebsd.org Tue Mar 14 10:08:13 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8C773D0CDF1; Tue, 14 Mar 2017 10:08:13 +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 5930A19DF; Tue, 14 Mar 2017 10:08:13 +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 v2EA8C9O070878; Tue, 14 Mar 2017 10:08:12 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EA8ChY070877; Tue, 14 Mar 2017 10:08:12 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703141008.v2EA8ChY070877@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 10:08:12 +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: r315240 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 10:08:13 -0000 Author: kib Date: Tue Mar 14 10:08:12 2017 New Revision: 315240 URL: https://svnweb.freebsd.org/changeset/base/315240 Log: MFC r314850: Require whole brand string matching for old Elf branding. Modified: stable/11/sys/kern/imgact_elf.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/imgact_elf.c ============================================================================== --- stable/11/sys/kern/imgact_elf.c Tue Mar 14 10:06:20 2017 (r315239) +++ stable/11/sys/kern/imgact_elf.c Tue Mar 14 10:08:12 2017 (r315240) @@ -309,8 +309,8 @@ __elfN(get_brandinfo)(struct image_param continue; if (hdr->e_machine == bi->machine && (hdr->e_ident[EI_OSABI] == bi->brand || - strncmp((const char *)&hdr->e_ident[OLD_EI_BRAND], - bi->compat_3_brand, strlen(bi->compat_3_brand)) == 0)) { + strcmp((const char *)&hdr->e_ident[OLD_EI_BRAND], + bi->compat_3_brand) == 0)) { /* Looks good, but give brand a chance to veto */ if (!bi->header_supported || bi->header_supported(imgp)) return (bi); From owner-svn-src-all@freebsd.org Tue Mar 14 10:09:52 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0C3BDD0CED4; Tue, 14 Mar 2017 10:09:52 +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 CD1531BF5; Tue, 14 Mar 2017 10:09:51 +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 v2EA9oVi070991; Tue, 14 Mar 2017 10:09:50 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EA9oM8070990; Tue, 14 Mar 2017 10:09:50 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703141009.v2EA9oM8070990@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 10:09:50 +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: r315241 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 10:09:52 -0000 Author: kib Date: Tue Mar 14 10:09:50 2017 New Revision: 315241 URL: https://svnweb.freebsd.org/changeset/base/315241 Log: MFC r314851: When selecting brand based on old Elf branding, prefer the brand which interpreter exactly matches the one requested by the activated image. Modified: stable/11/sys/kern/imgact_elf.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/imgact_elf.c ============================================================================== --- stable/11/sys/kern/imgact_elf.c Tue Mar 14 10:08:12 2017 (r315240) +++ stable/11/sys/kern/imgact_elf.c Tue Mar 14 10:09:50 2017 (r315241) @@ -312,10 +312,23 @@ __elfN(get_brandinfo)(struct image_param strcmp((const char *)&hdr->e_ident[OLD_EI_BRAND], bi->compat_3_brand) == 0)) { /* Looks good, but give brand a chance to veto */ - if (!bi->header_supported || bi->header_supported(imgp)) - return (bi); + if (!bi->header_supported || + bi->header_supported(imgp)) { + /* + * Again, prefer strictly matching + * interpreter path. + */ + if (strlen(bi->interp_path) + 1 == + interp_name_len && strncmp(interp, + bi->interp_path, interp_name_len) == 0) + return (bi); + if (bi_m == NULL) + bi_m = bi; + } } } + if (bi_m != NULL) + return (bi_m); /* No known brand, see if the header is recognized by any brand */ for (i = 0; i < MAX_BRANDS; i++) { From owner-svn-src-all@freebsd.org Tue Mar 14 12:39:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B1F3FD0A849; Tue, 14 Mar 2017 12:39:20 +0000 (UTC) (envelope-from amdmi3@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 76C531D6D; Tue, 14 Mar 2017 12:39:20 +0000 (UTC) (envelope-from amdmi3@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2ECdJxn033067; Tue, 14 Mar 2017 12:39:19 GMT (envelope-from amdmi3@FreeBSD.org) Received: (from amdmi3@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2ECdJQt033066; Tue, 14 Mar 2017 12:39:19 GMT (envelope-from amdmi3@FreeBSD.org) Message-Id: <201703141239.v2ECdJQt033066@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: amdmi3 set sender to amdmi3@FreeBSD.org using -f From: Dmitry Marakasov Date: Tue, 14 Mar 2017 12:39:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315242 - head/sbin/swapon X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 12:39:20 -0000 Author: amdmi3 (ports committer) Date: Tue Mar 14 12:39:19 2017 New Revision: 315242 URL: https://svnweb.freebsd.org/changeset/base/315242 Log: Fix late and noauto with geli swap With the following in /etc/fstab: /dev/gpt/swap.eli none swap sw,late 0 0 swap will not be enabled, with `swapon -aL' complaining: swapon: Invalid option: late This happens because swap_on_geli_args() which parses geli arguments out of all mount options does not expect late or noauto among them. Fix this by explicitly allowing these arguments. Reviewed by: jilles Approved by: jilles MFC after: 2 weeks Differential Revision: D9835 Modified: head/sbin/swapon/swapon.c Modified: head/sbin/swapon/swapon.c ============================================================================== --- head/sbin/swapon/swapon.c Tue Mar 14 10:09:50 2017 (r315241) +++ head/sbin/swapon/swapon.c Tue Mar 14 12:39:19 2017 (r315242) @@ -375,8 +375,12 @@ swap_on_geli_args(const char *mntops) free(ops); return (NULL); } - } else if ((p = strstr(token, "notrim")) == token) { + } else if (strcmp(token, "notrim") == 0) { Tflag = " -T "; + } else if (strcmp(token, "late") == 0) { + /* ignore known option */ + } else if (strcmp(token, "noauto") == 0) { + /* ignore known option */ } else if (strcmp(token, "sw") != 0) { warnx("Invalid option: %s", token); free(ops); From owner-svn-src-all@freebsd.org Tue Mar 14 13:54:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E2009D0C7D0; Tue, 14 Mar 2017 13:54:19 +0000 (UTC) (envelope-from sbruno@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 8AB811113; Tue, 14 Mar 2017 13:54:19 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EDsI9G066105; Tue, 14 Mar 2017 13:54:18 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EDsIFu066104; Tue, 14 Mar 2017 13:54:18 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201703141354.v2EDsIFu066104@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Tue, 14 Mar 2017 13:54:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315243 - head/sys/dev/bnxt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 13:54:20 -0000 Author: sbruno Date: Tue Mar 14 13:54:18 2017 New Revision: 315243 URL: https://svnweb.freebsd.org/changeset/base/315243 Log: Restore changes for RSS routing improvements made in 314369 that were reverted in the IFLIB update I made in 315217. Submitted by: Venkat Duvvuru Modified: head/sys/dev/bnxt/bnxt_txrx.c Modified: head/sys/dev/bnxt/bnxt_txrx.c ============================================================================== --- head/sys/dev/bnxt/bnxt_txrx.c Tue Mar 14 12:39:19 2017 (r315242) +++ head/sys/dev/bnxt/bnxt_txrx.c Tue Mar 14 13:54:18 2017 (r315243) @@ -426,6 +426,37 @@ cmpl_invalid: return avail; } +static void +bnxt_set_rsstype(if_rxd_info_t ri, uint8_t rss_hash_type) +{ + uint8_t rss_profile_id; + + rss_profile_id = BNXT_GET_RSS_PROFILE_ID(rss_hash_type); + switch (rss_profile_id) { + case BNXT_RSS_HASH_TYPE_TCPV4: + ri->iri_rsstype = M_HASHTYPE_RSS_TCP_IPV4; + break; + case BNXT_RSS_HASH_TYPE_UDPV4: + ri->iri_rsstype = M_HASHTYPE_RSS_UDP_IPV4; + break; + case BNXT_RSS_HASH_TYPE_IPV4: + ri->iri_rsstype = M_HASHTYPE_RSS_IPV4; + break; + case BNXT_RSS_HASH_TYPE_TCPV6: + ri->iri_rsstype = M_HASHTYPE_RSS_TCP_IPV6; + break; + case BNXT_RSS_HASH_TYPE_UDPV6: + ri->iri_rsstype = M_HASHTYPE_RSS_UDP_IPV6; + break; + case BNXT_RSS_HASH_TYPE_IPV6: + ri->iri_rsstype = M_HASHTYPE_RSS_IPV6; + break; + default: + ri->iri_rsstype = M_HASHTYPE_OPAQUE; + break; + } +} + static int bnxt_pkt_get_l2(struct bnxt_softc *softc, if_rxd_info_t ri, struct bnxt_cp_ring *cpr, uint16_t flags_type) @@ -443,13 +474,7 @@ bnxt_pkt_get_l2(struct bnxt_softc *softc /* Extract from the first 16-byte BD */ if (flags_type & RX_PKT_CMPL_FLAGS_RSS_VALID) { ri->iri_flowid = le32toh(rcp->rss_hash); - /* - * TODO: Extract something useful from rcp->rss_hash_type - * (undocumented) - * May be documented in the "LSI ES" - * also check the firmware code. - */ - ri->iri_rsstype = M_HASHTYPE_OPAQUE; + bnxt_set_rsstype(ri, rcp->rss_hash_type); } else { ri->iri_rsstype = M_HASHTYPE_NONE; @@ -529,13 +554,7 @@ bnxt_pkt_get_tpa(struct bnxt_softc *soft /* Extract from the first 16-byte BD */ if (le16toh(tpas->low.flags_type) & RX_TPA_START_CMPL_FLAGS_RSS_VALID) { ri->iri_flowid = le32toh(tpas->low.rss_hash); - /* - * TODO: Extract something useful from tpas->low.rss_hash_type - * (undocumented) - * May be documented in the "LSI ES" - * also check the firmware code. - */ - ri->iri_rsstype = M_HASHTYPE_OPAQUE; + bnxt_set_rsstype(ri, tpas->low.rss_hash_type); } else { ri->iri_rsstype = M_HASHTYPE_NONE; From owner-svn-src-all@freebsd.org Tue Mar 14 14:02:48 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C31E1D0C9D5; Tue, 14 Mar 2017 14:02:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9255D1632; Tue, 14 Mar 2017 14:02:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EE2lsw070154; Tue, 14 Mar 2017 14:02:47 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EE2lWV070153; Tue, 14 Mar 2017 14:02:47 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141402.v2EE2lWV070153@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 14:02:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315244 - head/sys/compat/linuxkpi/common/src X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 14:02:48 -0000 Author: hselasky Date: Tue Mar 14 14:02:47 2017 New Revision: 315244 URL: https://svnweb.freebsd.org/changeset/base/315244 Log: Set "current" pointer for LinuxKPI interrupts and timer callbacks. MFC after: 1 week Sponsored by: Mellanox Technologies Modified: head/sys/compat/linuxkpi/common/src/linux_compat.c Modified: head/sys/compat/linuxkpi/common/src/linux_compat.c ============================================================================== --- head/sys/compat/linuxkpi/common/src/linux_compat.c Tue Mar 14 13:54:18 2017 (r315243) +++ head/sys/compat/linuxkpi/common/src/linux_compat.c Tue Mar 14 14:02:47 2017 (r315244) @@ -999,6 +999,8 @@ linux_timer_callback_wrapper(void *conte { struct timer_list *timer; + linux_set_current(curthread); + timer = context; timer->function(timer->data); } @@ -1343,6 +1345,8 @@ linux_irq_handler(void *ent) { struct irq_ent *irqe; + linux_set_current(curthread); + irqe = ent; irqe->handler(irqe->irq, irqe->arg); } From owner-svn-src-all@freebsd.org Tue Mar 14 15:08:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48914D0BC1B; Tue, 14 Mar 2017 15:08:58 +0000 (UTC) (envelope-from sbruno@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 1833F1A9E; Tue, 14 Mar 2017 15:08:58 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EF8vaX095222; Tue, 14 Mar 2017 15:08:57 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EF8vLk095221; Tue, 14 Mar 2017 15:08:57 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201703141508.v2EF8vLk095221@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Tue, 14 Mar 2017 15:08:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315245 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:08:58 -0000 Author: sbruno Date: Tue Mar 14 15:08:56 2017 New Revision: 315245 URL: https://svnweb.freebsd.org/changeset/base/315245 Log: Fixup LINT by using uint64_t type as we do on all other calls to PNMB() Found with Jenkins. Reported by: lwshu Sponsored by: Limelight Networks Modified: head/sys/net/iflib.c Modified: head/sys/net/iflib.c ============================================================================== --- head/sys/net/iflib.c Tue Mar 14 14:02:47 2017 (r315244) +++ head/sys/net/iflib.c Tue Mar 14 15:08:56 2017 (r315245) @@ -860,7 +860,7 @@ iflib_netmap_txsync(struct netmap_kring for (n = 0; nm_i != head; n++) { struct netmap_slot *slot = &ring->slot[nm_i]; u_int len = slot->len; - vm_paddr_t paddr; + uint64_t paddr; void *addr = PNMB(na, slot, &paddr); int flags = (slot->flags & NS_REPORT || nic_i == 0 || nic_i == report_frequency) ? From owner-svn-src-all@freebsd.org Tue Mar 14 15:12:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AA365D0BEA1; Tue, 14 Mar 2017 15:12:59 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7DDED1F03; Tue, 14 Mar 2017 15:12:59 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFCwVE099122; Tue, 14 Mar 2017 15:12:58 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFCwAj099121; Tue, 14 Mar 2017 15:12:58 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141512.v2EFCwAj099121@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:12:58 +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: r315246 - stable/11/sys/dev/pci X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:12:59 -0000 Author: hselasky Date: Tue Mar 14 15:12:58 2017 New Revision: 315246 URL: https://svnweb.freebsd.org/changeset/base/315246 Log: MFC r310806: Add MSIX rewrite table quirk for use with VMs. This patch solves IRQ generation problems using the mlx5en(4) driver with xenserver v6.5.0 in SRIOV and PCI-passthrough modes. Until further the hw.pci.msix_rewrite_table quirk must be set manually in /boot/loader.conf . Reviewed by: jhb @ Sponsored by: Mellanox Technologies Modified: stable/11/sys/dev/pci/pci.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/pci/pci.c ============================================================================== --- stable/11/sys/dev/pci/pci.c Tue Mar 14 15:08:56 2017 (r315245) +++ stable/11/sys/dev/pci/pci.c Tue Mar 14 15:12:58 2017 (r315246) @@ -357,6 +357,11 @@ static int pci_do_msix = 1; SYSCTL_INT(_hw_pci, OID_AUTO, enable_msix, CTLFLAG_RWTUN, &pci_do_msix, 1, "Enable support for MSI-X interrupts"); +static int pci_msix_rewrite_table = 0; +SYSCTL_INT(_hw_pci, OID_AUTO, msix_rewrite_table, CTLFLAG_RWTUN, + &pci_msix_rewrite_table, 0, + "Rewrite entire MSI-X table when updating MSI-X entries"); + static int pci_honor_msi_blacklist = 1; SYSCTL_INT(_hw_pci, OID_AUTO, honor_msi_blacklist, CTLFLAG_RDTUN, &pci_honor_msi_blacklist, 1, "Honor chipset blacklist for MSI/MSI-X"); @@ -1483,11 +1488,10 @@ pci_find_extcap_method(device_t dev, dev /* * Support for MSI-X message interrupts. */ -void -pci_enable_msix_method(device_t dev, device_t child, u_int index, - uint64_t address, uint32_t data) +static void +pci_write_msix_entry(device_t dev, u_int index, uint64_t address, uint32_t data) { - struct pci_devinfo *dinfo = device_get_ivars(child); + struct pci_devinfo *dinfo = device_get_ivars(dev); struct pcicfg_msix *msix = &dinfo->cfg.msix; uint32_t offset; @@ -1496,6 +1500,31 @@ pci_enable_msix_method(device_t dev, dev bus_write_4(msix->msix_table_res, offset, address & 0xffffffff); bus_write_4(msix->msix_table_res, offset + 4, address >> 32); bus_write_4(msix->msix_table_res, offset + 8, data); +} + +void +pci_enable_msix_method(device_t dev, device_t child, u_int index, + uint64_t address, uint32_t data) +{ + + if (pci_msix_rewrite_table) { + struct pci_devinfo *dinfo = device_get_ivars(child); + struct pcicfg_msix *msix = &dinfo->cfg.msix; + + /* + * Some VM hosts require MSIX to be disabled in the + * control register before updating the MSIX table + * entries are allowed. It is not enough to only + * disable MSIX while updating a single entry. MSIX + * must be disabled while updating all entries in the + * table. + */ + pci_write_config(child, + msix->msix_location + PCIR_MSIX_CTRL, + msix->msix_ctrl & ~PCIM_MSIXCTRL_MSIX_ENABLE, 2); + pci_resume_msix(child); + } else + pci_write_msix_entry(child, index, address, data); /* Enable MSI -> HT mapping. */ pci_ht_map_msi(child, address); @@ -1571,7 +1600,8 @@ pci_resume_msix(device_t dev) if (mte->mte_vector == 0 || mte->mte_handlers == 0) continue; mv = &msix->msix_vectors[mte->mte_vector - 1]; - pci_enable_msix(dev, i, mv->mv_address, mv->mv_data); + pci_write_msix_entry(dev, i, mv->mv_address, + mv->mv_data); pci_unmask_msix(dev, i); } } @@ -4402,12 +4432,20 @@ pci_setup_intr(device_t dev, device_t ch mv->mv_address = addr; mv->mv_data = data; } - if (mte->mte_handlers == 0) { + + /* + * The MSIX table entry must be made valid by + * incrementing the mte_handlers before + * calling pci_enable_msix() and + * pci_resume_msix(). Else the MSIX rewrite + * table quirk will not work as expected. + */ + mte->mte_handlers++; + if (mte->mte_handlers == 1) { pci_enable_msix(child, rid - 1, mv->mv_address, mv->mv_data); pci_unmask_msix(child, rid - 1); } - mte->mte_handlers++; } /* From owner-svn-src-all@freebsd.org Tue Mar 14 15:15:39 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1A330D0BF55; Tue, 14 Mar 2017 15:15:39 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E901126C; Tue, 14 Mar 2017 15:15:38 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFFcZB099289; Tue, 14 Mar 2017 15:15:38 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFFcVl099288; Tue, 14 Mar 2017 15:15:38 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141515.v2EFFcVl099288@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:15:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315247 - stable/10/sys/dev/pci X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:15:39 -0000 Author: hselasky Date: Tue Mar 14 15:15:37 2017 New Revision: 315247 URL: https://svnweb.freebsd.org/changeset/base/315247 Log: MFC r310806: Add MSIX rewrite table quirk for use with VMs. This patch solves IRQ generation problems using the mlx5en(4) driver with xenserver v6.5.0 in SRIOV and PCI-passthrough modes. Until further the hw.pci.msix_rewrite_table quirk must be set manually in /boot/loader.conf . Reviewed by: jhb @ Sponsored by: Mellanox Technologies Modified: stable/10/sys/dev/pci/pci.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/pci/pci.c ============================================================================== --- stable/10/sys/dev/pci/pci.c Tue Mar 14 15:12:58 2017 (r315246) +++ stable/10/sys/dev/pci/pci.c Tue Mar 14 15:15:37 2017 (r315247) @@ -351,6 +351,11 @@ TUNABLE_INT("hw.pci.enable_msix", &pci_d SYSCTL_INT(_hw_pci, OID_AUTO, enable_msix, CTLFLAG_RW, &pci_do_msix, 1, "Enable support for MSI-X interrupts"); +static int pci_msix_rewrite_table = 0; +SYSCTL_INT(_hw_pci, OID_AUTO, msix_rewrite_table, CTLFLAG_RWTUN, + &pci_msix_rewrite_table, 0, + "Rewrite entire MSI-X table when updating MSI-X entries"); + static int pci_honor_msi_blacklist = 1; TUNABLE_INT("hw.pci.honor_msi_blacklist", &pci_honor_msi_blacklist); SYSCTL_INT(_hw_pci, OID_AUTO, honor_msi_blacklist, CTLFLAG_RD, @@ -1375,11 +1380,10 @@ pci_find_extcap_method(device_t dev, dev /* * Support for MSI-X message interrupts. */ -void -pci_enable_msix_method(device_t dev, device_t child, u_int index, - uint64_t address, uint32_t data) +static void +pci_write_msix_entry(device_t dev, u_int index, uint64_t address, uint32_t data) { - struct pci_devinfo *dinfo = device_get_ivars(child); + struct pci_devinfo *dinfo = device_get_ivars(dev); struct pcicfg_msix *msix = &dinfo->cfg.msix; uint32_t offset; @@ -1388,6 +1392,31 @@ pci_enable_msix_method(device_t dev, dev bus_write_4(msix->msix_table_res, offset, address & 0xffffffff); bus_write_4(msix->msix_table_res, offset + 4, address >> 32); bus_write_4(msix->msix_table_res, offset + 8, data); +} + +void +pci_enable_msix_method(device_t dev, device_t child, u_int index, + uint64_t address, uint32_t data) +{ + + if (pci_msix_rewrite_table) { + struct pci_devinfo *dinfo = device_get_ivars(child); + struct pcicfg_msix *msix = &dinfo->cfg.msix; + + /* + * Some VM hosts require MSIX to be disabled in the + * control register before updating the MSIX table + * entries are allowed. It is not enough to only + * disable MSIX while updating a single entry. MSIX + * must be disabled while updating all entries in the + * table. + */ + pci_write_config(child, + msix->msix_location + PCIR_MSIX_CTRL, + msix->msix_ctrl & ~PCIM_MSIXCTRL_MSIX_ENABLE, 2); + pci_resume_msix(child); + } else + pci_write_msix_entry(child, index, address, data); /* Enable MSI -> HT mapping. */ pci_ht_map_msi(child, address); @@ -1463,7 +1492,8 @@ pci_resume_msix(device_t dev) if (mte->mte_vector == 0 || mte->mte_handlers == 0) continue; mv = &msix->msix_vectors[mte->mte_vector - 1]; - pci_enable_msix(dev, i, mv->mv_address, mv->mv_data); + pci_write_msix_entry(dev, i, mv->mv_address, + mv->mv_data); pci_unmask_msix(dev, i); } } @@ -3980,12 +4010,20 @@ pci_setup_intr(device_t dev, device_t ch mv->mv_address = addr; mv->mv_data = data; } - if (mte->mte_handlers == 0) { + + /* + * The MSIX table entry must be made valid by + * incrementing the mte_handlers before + * calling pci_enable_msix() and + * pci_resume_msix(). Else the MSIX rewrite + * table quirk will not work as expected. + */ + mte->mte_handlers++; + if (mte->mte_handlers == 1) { pci_enable_msix(child, rid - 1, mv->mv_address, mv->mv_data); pci_unmask_msix(child, rid - 1); } - mte->mte_handlers++; } /* From owner-svn-src-all@freebsd.org Tue Mar 14 15:19:16 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 92C6CD0C03C; Tue, 14 Mar 2017 15:19:16 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6AD1D7FB; Tue, 14 Mar 2017 15:19:16 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFJFYU099666; Tue, 14 Mar 2017 15:19:15 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFJFrH099661; Tue, 14 Mar 2017 15:19:15 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141519.v2EFJFrH099661@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:19:15 +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: r315248 - in stable/11: share/man/man4 sys/dev/sound/usb sys/dev/usb sys/dev/usb/quirk X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:19:16 -0000 Author: hselasky Date: Tue Mar 14 15:19:14 2017 New Revision: 315248 URL: https://svnweb.freebsd.org/changeset/base/315248 Log: MFC r312338: Add USB audio support for S/PDIF output with C-Media CM6206 devices. Submitted by: Julien Nadeau PR: 216131 Modified: stable/11/share/man/man4/usb_quirk.4 stable/11/sys/dev/sound/usb/uaudio.c stable/11/sys/dev/usb/quirk/usb_quirk.c stable/11/sys/dev/usb/quirk/usb_quirk.h stable/11/sys/dev/usb/usbdevs Directory Properties: stable/11/ (props changed) Modified: stable/11/share/man/man4/usb_quirk.4 ============================================================================== --- stable/11/share/man/man4/usb_quirk.4 Tue Mar 14 15:15:37 2017 (r315247) +++ stable/11/share/man/man4/usb_quirk.4 Tue Mar 14 15:19:14 2017 (r315248) @@ -16,7 +16,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 4, 2016 +.Dd January 17, 2017 .Dt USB_QUIRK 4 .Os .Sh NAME @@ -52,6 +52,10 @@ input is async despite claim of adaptive do not adjust for fractional samples .It UQ_AU_NO_XU audio device has broken extension unit +.It UQ_AU_VENDOR_CLASS +audio device uses vendor class to identify itself +.It UQ_AU_SET_SPDIF_CM6206 +audio device needs special programming to enable S/PDIF audio output .It UQ_BAD_ADC bad audio spec version number .It UQ_BAD_AUDIO Modified: stable/11/sys/dev/sound/usb/uaudio.c ============================================================================== --- stable/11/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:15:37 2017 (r315247) +++ stable/11/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:19:14 2017 (r315248) @@ -337,6 +337,11 @@ struct uaudio_hid { uint8_t mute_id; }; +#define UAUDIO_SPDIF_OUT 0x01 /* Enable S/PDIF output */ +#define UAUDIO_SPDIF_OUT_48K 0x02 /* Out sample rate = 48K */ +#define UAUDIO_SPDIF_OUT_96K 0x04 /* Out sample rate = 96K */ +#define UAUDIO_SPDIF_IN_MIX 0x10 /* Input mix enable */ + struct uaudio_softc { struct sbuf sc_sndstat; struct sndcard_func sc_sndcard_func; @@ -354,6 +359,7 @@ struct uaudio_softc { struct usb_xfer *sc_mixer_xfer[1]; struct uaudio_mixer_node *sc_mixer_root; struct uaudio_mixer_node *sc_mixer_curr; + int (*sc_set_spdif_fn) (struct uaudio_softc *, int); uint32_t sc_mix_info; uint32_t sc_recsrc_info; @@ -885,6 +891,46 @@ uaudio_probe(device_t dev) return (ENXIO); } +/* + * Set Cmedia CM6206 S/PDIF settings + * Source: CM6206 Datasheet v2.3. + */ +static int +uaudio_set_spdif_cm6206(struct uaudio_softc *sc, int flags) +{ + uint8_t cmd[2][4] = { + {0x20, 0x20, 0x00, 0}, + {0x20, 0x30, 0x02, 1} + }; + int i; + + if (flags & UAUDIO_SPDIF_OUT) + cmd[1][1] = 0x00; + else + cmd[1][1] = 0x02; + + if (flags & UAUDIO_SPDIF_OUT_96K) + cmd[0][1] = 0x60; /* 96K: 3'b110 */ + + if (flags & UAUDIO_SPDIF_IN_MIX) + cmd[1][1] = 0x03; /* SPDIFMIX */ + + for (i = 0; i < 2; i++) { + if (usbd_req_set_report(sc->sc_udev, NULL, + cmd[i], sizeof(cmd[0]), + sc->sc_mixer_iface_index, UHID_OUTPUT_REPORT, 0) != 0) { + return (ENXIO); + } + } + return (0); +} + +static int +uaudio_set_spdif_dummy(struct uaudio_softc *sc, int flags) +{ + return (0); +} + static int uaudio_attach(device_t dev) { @@ -919,6 +965,12 @@ uaudio_attach(device_t dev) if (usb_test_quirk(uaa, UQ_AU_VENDOR_CLASS)) sc->sc_uq_au_vendor_class = 1; + /* set S/PDIF function */ + if (usb_test_quirk(uaa, UQ_AU_SET_SPDIF_CM6206)) + sc->sc_set_spdif_fn = uaudio_set_spdif_cm6206; + else + sc->sc_set_spdif_fn = uaudio_set_spdif_dummy; + umidi_init(dev); device_set_usb_desc(dev); @@ -1055,6 +1107,11 @@ uaudio_attach(device_t dev) /* reload all mixer settings */ uaudio_mixer_reload_all(sc); + /* enable S/PDIF output, if any */ + if (sc->sc_set_spdif_fn(sc, + UAUDIO_SPDIF_OUT | UAUDIO_SPDIF_OUT_48K) != 0) { + device_printf(dev, "Failed to enable S/PDIF at 48K\n"); + } return (0); /* success */ detach: @@ -1139,6 +1196,9 @@ uaudio_detach_sub(device_t dev) struct uaudio_softc *sc = device_get_softc(device_get_parent(dev)); int error = 0; + /* disable S/PDIF output, if any */ + (void) sc->sc_set_spdif_fn(sc, 0); + repeat: if (sc->sc_pcm_registered) { error = pcm_unregister(dev); Modified: stable/11/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/11/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:15:37 2017 (r315247) +++ stable/11/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:19:14 2017 (r315248) @@ -519,6 +519,7 @@ static struct usb_quirk_entry usb_quirks /* Non-standard USB AUDIO devices */ USB_QUIRK(MAUDIO, FASTTRACKULTRA, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MAUDIO, FASTTRACKULTRA8R, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), + USB_QUIRK(CMEDIA, CM6206, 0x0000, 0xffff, UQ_AU_SET_SPDIF_CM6206), /* * Quirks for manufacturers which USB devices does not respond @@ -605,6 +606,7 @@ static const char *usb_quirk_str[USB_QUI [UQ_AU_VENDOR_CLASS] = "UQ_AU_VENDOR_CLASS", [UQ_SINGLE_CMD_MIDI] = "UQ_SINGLE_CMD_MIDI", [UQ_MSC_DYMO_EJECT] = "UQ_MSC_DYMO_EJECT", + [UQ_AU_SET_SPDIF_CM6206] = "UQ_AU_SET_SPDIF_CM6206", }; /*------------------------------------------------------------------------* Modified: stable/11/sys/dev/usb/quirk/usb_quirk.h ============================================================================== --- stable/11/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:15:37 2017 (r315247) +++ stable/11/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:19:14 2017 (r315248) @@ -109,6 +109,7 @@ enum { UQ_AU_VENDOR_CLASS, /* audio device uses vendor and not audio class */ UQ_SINGLE_CMD_MIDI, /* at most one command per USB packet */ UQ_MSC_DYMO_EJECT, /* ejects Dymo MSC device */ + UQ_AU_SET_SPDIF_CM6206, /* enable S/PDIF audio output */ USB_QUIRK_MAX }; Modified: stable/11/sys/dev/usb/usbdevs ============================================================================== --- stable/11/sys/dev/usb/usbdevs Tue Mar 14 15:15:37 2017 (r315247) +++ stable/11/sys/dev/usb/usbdevs Tue Mar 14 15:19:14 2017 (r315248) @@ -1439,6 +1439,9 @@ product CLIPSAL 5000CT2 0x0304 5000CT2 product CLIPSAL C5000CT2 0x0305 C5000CT2 C-Bus Touch Screen product CLIPSAL L51xx 0x0401 L51xx C-Bus Dimmer +/* C-Media products */ +product CMEDIA CM6206 0x0102 CM106 compatible sound device + /* CMOTECH products */ product CMOTECH CNU510 0x5141 CDMA Technologies USB modem product CMOTECH CNU550 0x5543 CDMA 2000 1xRTT/1xEVDO USB modem From owner-svn-src-all@freebsd.org Tue Mar 14 15:21:42 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D8C70D0C276; Tue, 14 Mar 2017 15:21:42 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B0ADEC54; Tue, 14 Mar 2017 15:21:42 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFLfai000797; Tue, 14 Mar 2017 15:21:41 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFLfZK000791; Tue, 14 Mar 2017 15:21:41 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141521.v2EFLfZK000791@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:21:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315249 - in stable/10: share/man/man4 sys/dev/sound/usb sys/dev/usb sys/dev/usb/quirk X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:21:43 -0000 Author: hselasky Date: Tue Mar 14 15:21:41 2017 New Revision: 315249 URL: https://svnweb.freebsd.org/changeset/base/315249 Log: MFC r312338: Add USB audio support for S/PDIF output with C-Media CM6206 devices. Submitted by: Julien Nadeau PR: 216131 Modified: stable/10/share/man/man4/usb_quirk.4 stable/10/sys/dev/sound/usb/uaudio.c stable/10/sys/dev/usb/quirk/usb_quirk.c stable/10/sys/dev/usb/quirk/usb_quirk.h stable/10/sys/dev/usb/usbdevs Directory Properties: stable/10/ (props changed) Modified: stable/10/share/man/man4/usb_quirk.4 ============================================================================== --- stable/10/share/man/man4/usb_quirk.4 Tue Mar 14 15:19:14 2017 (r315248) +++ stable/10/share/man/man4/usb_quirk.4 Tue Mar 14 15:21:41 2017 (r315249) @@ -16,7 +16,7 @@ .\" .\" $FreeBSD$ .\" -.Dd April 4, 2016 +.Dd January 17, 2017 .Dt USB_QUIRK 4 .Os .Sh NAME @@ -52,6 +52,10 @@ input is async despite claim of adaptive do not adjust for fractional samples .It UQ_AU_NO_XU audio device has broken extension unit +.It UQ_AU_VENDOR_CLASS +audio device uses vendor class to identify itself +.It UQ_AU_SET_SPDIF_CM6206 +audio device needs special programming to enable S/PDIF audio output .It UQ_BAD_ADC bad audio spec version number .It UQ_BAD_AUDIO Modified: stable/10/sys/dev/sound/usb/uaudio.c ============================================================================== --- stable/10/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:19:14 2017 (r315248) +++ stable/10/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:21:41 2017 (r315249) @@ -343,6 +343,11 @@ struct uaudio_hid { uint8_t mute_id; }; +#define UAUDIO_SPDIF_OUT 0x01 /* Enable S/PDIF output */ +#define UAUDIO_SPDIF_OUT_48K 0x02 /* Out sample rate = 48K */ +#define UAUDIO_SPDIF_OUT_96K 0x04 /* Out sample rate = 96K */ +#define UAUDIO_SPDIF_IN_MIX 0x10 /* Input mix enable */ + struct uaudio_softc { struct sbuf sc_sndstat; struct sndcard_func sc_sndcard_func; @@ -360,6 +365,7 @@ struct uaudio_softc { struct usb_xfer *sc_mixer_xfer[1]; struct uaudio_mixer_node *sc_mixer_root; struct uaudio_mixer_node *sc_mixer_curr; + int (*sc_set_spdif_fn) (struct uaudio_softc *, int); uint32_t sc_mix_info; uint32_t sc_recsrc_info; @@ -891,6 +897,46 @@ uaudio_probe(device_t dev) return (ENXIO); } +/* + * Set Cmedia CM6206 S/PDIF settings + * Source: CM6206 Datasheet v2.3. + */ +static int +uaudio_set_spdif_cm6206(struct uaudio_softc *sc, int flags) +{ + uint8_t cmd[2][4] = { + {0x20, 0x20, 0x00, 0}, + {0x20, 0x30, 0x02, 1} + }; + int i; + + if (flags & UAUDIO_SPDIF_OUT) + cmd[1][1] = 0x00; + else + cmd[1][1] = 0x02; + + if (flags & UAUDIO_SPDIF_OUT_96K) + cmd[0][1] = 0x60; /* 96K: 3'b110 */ + + if (flags & UAUDIO_SPDIF_IN_MIX) + cmd[1][1] = 0x03; /* SPDIFMIX */ + + for (i = 0; i < 2; i++) { + if (usbd_req_set_report(sc->sc_udev, NULL, + cmd[i], sizeof(cmd[0]), + sc->sc_mixer_iface_index, UHID_OUTPUT_REPORT, 0) != 0) { + return (ENXIO); + } + } + return (0); +} + +static int +uaudio_set_spdif_dummy(struct uaudio_softc *sc, int flags) +{ + return (0); +} + static int uaudio_attach(device_t dev) { @@ -925,6 +971,12 @@ uaudio_attach(device_t dev) if (usb_test_quirk(uaa, UQ_AU_VENDOR_CLASS)) sc->sc_uq_au_vendor_class = 1; + /* set S/PDIF function */ + if (usb_test_quirk(uaa, UQ_AU_SET_SPDIF_CM6206)) + sc->sc_set_spdif_fn = uaudio_set_spdif_cm6206; + else + sc->sc_set_spdif_fn = uaudio_set_spdif_dummy; + umidi_init(dev); device_set_usb_desc(dev); @@ -1061,6 +1113,11 @@ uaudio_attach(device_t dev) /* reload all mixer settings */ uaudio_mixer_reload_all(sc); + /* enable S/PDIF output, if any */ + if (sc->sc_set_spdif_fn(sc, + UAUDIO_SPDIF_OUT | UAUDIO_SPDIF_OUT_48K) != 0) { + device_printf(dev, "Failed to enable S/PDIF at 48K\n"); + } return (0); /* success */ detach: @@ -1145,6 +1202,9 @@ uaudio_detach_sub(device_t dev) struct uaudio_softc *sc = device_get_softc(device_get_parent(dev)); int error = 0; + /* disable S/PDIF output, if any */ + (void) sc->sc_set_spdif_fn(sc, 0); + repeat: if (sc->sc_pcm_registered) { error = pcm_unregister(dev); Modified: stable/10/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/10/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:19:14 2017 (r315248) +++ stable/10/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:21:41 2017 (r315249) @@ -518,6 +518,7 @@ static struct usb_quirk_entry usb_quirks /* Non-standard USB AUDIO devices */ USB_QUIRK(MAUDIO, FASTTRACKULTRA, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MAUDIO, FASTTRACKULTRA8R, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), + USB_QUIRK(CMEDIA, CM6206, 0x0000, 0xffff, UQ_AU_SET_SPDIF_CM6206), /* * Quirks for manufacturers which USB devices does not respond @@ -604,6 +605,7 @@ static const char *usb_quirk_str[USB_QUI [UQ_AU_VENDOR_CLASS] = "UQ_AU_VENDOR_CLASS", [UQ_SINGLE_CMD_MIDI] = "UQ_SINGLE_CMD_MIDI", [UQ_MSC_DYMO_EJECT] = "UQ_MSC_DYMO_EJECT", + [UQ_AU_SET_SPDIF_CM6206] = "UQ_AU_SET_SPDIF_CM6206", }; /*------------------------------------------------------------------------* Modified: stable/10/sys/dev/usb/quirk/usb_quirk.h ============================================================================== --- stable/10/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:19:14 2017 (r315248) +++ stable/10/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:21:41 2017 (r315249) @@ -109,6 +109,7 @@ enum { UQ_AU_VENDOR_CLASS, /* audio device uses vendor and not audio class */ UQ_SINGLE_CMD_MIDI, /* at most one command per USB packet */ UQ_MSC_DYMO_EJECT, /* ejects Dymo MSC device */ + UQ_AU_SET_SPDIF_CM6206, /* enable S/PDIF audio output */ USB_QUIRK_MAX }; Modified: stable/10/sys/dev/usb/usbdevs ============================================================================== --- stable/10/sys/dev/usb/usbdevs Tue Mar 14 15:19:14 2017 (r315248) +++ stable/10/sys/dev/usb/usbdevs Tue Mar 14 15:21:41 2017 (r315249) @@ -1438,6 +1438,9 @@ product CLIPSAL 5000CT2 0x0304 5000CT2 product CLIPSAL C5000CT2 0x0305 C5000CT2 C-Bus Touch Screen product CLIPSAL L51xx 0x0401 L51xx C-Bus Dimmer +/* C-Media products */ +product CMEDIA CM6206 0x0102 CM106 compatible sound device + /* CMOTECH products */ product CMOTECH CNU510 0x5141 CDMA Technologies USB modem product CMOTECH CNU550 0x5543 CDMA 2000 1xRTT/1xEVDO USB modem From owner-svn-src-all@freebsd.org Tue Mar 14 15:25:51 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A6776D0C3A4; Tue, 14 Mar 2017 15:25:51 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7E4141132; Tue, 14 Mar 2017 15:25:51 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFPor8003798; Tue, 14 Mar 2017 15:25:50 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFPoiI003793; Tue, 14 Mar 2017 15:25:50 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141525.v2EFPoiI003793@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:25:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315250 - in stable/9: share/man/man4 sys/dev/sound/usb sys/dev/usb sys/dev/usb/quirk X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:25:51 -0000 Author: hselasky Date: Tue Mar 14 15:25:49 2017 New Revision: 315250 URL: https://svnweb.freebsd.org/changeset/base/315250 Log: MFC r312338: Add USB audio support for S/PDIF output with C-Media CM6206 devices. Submitted by: Julien Nadeau PR: 216131 Modified: stable/9/share/man/man4/usb_quirk.4 stable/9/sys/dev/sound/usb/uaudio.c stable/9/sys/dev/usb/quirk/usb_quirk.c stable/9/sys/dev/usb/quirk/usb_quirk.h stable/9/sys/dev/usb/usbdevs Directory Properties: stable/9/share/ (props changed) stable/9/share/man/ (props changed) stable/9/share/man/man4/ (props changed) stable/9/sys/ (props changed) Modified: stable/9/share/man/man4/usb_quirk.4 ============================================================================== --- stable/9/share/man/man4/usb_quirk.4 Tue Mar 14 15:21:41 2017 (r315249) +++ stable/9/share/man/man4/usb_quirk.4 Tue Mar 14 15:25:49 2017 (r315250) @@ -16,7 +16,7 @@ .\" .\" $FreeBSD$ .\" -.Dd September 26, 2015 +.Dd January 17, 2017 .Dt USB_QUIRK 4 .Os .Sh NAME @@ -52,6 +52,10 @@ input is async despite claim of adaptive do not adjust for fractional samples .It UQ_AU_NO_XU audio device has broken extension unit +.It UQ_AU_VENDOR_CLASS +audio device uses vendor class to identify itself +.It UQ_AU_SET_SPDIF_CM6206 +audio device needs special programming to enable S/PDIF audio output .It UQ_BAD_ADC bad audio spec version number .It UQ_BAD_AUDIO Modified: stable/9/sys/dev/sound/usb/uaudio.c ============================================================================== --- stable/9/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:21:41 2017 (r315249) +++ stable/9/sys/dev/sound/usb/uaudio.c Tue Mar 14 15:25:49 2017 (r315250) @@ -317,6 +317,11 @@ struct uaudio_hid { uint8_t mute_id; }; +#define UAUDIO_SPDIF_OUT 0x01 /* Enable S/PDIF output */ +#define UAUDIO_SPDIF_OUT_48K 0x02 /* Out sample rate = 48K */ +#define UAUDIO_SPDIF_OUT_96K 0x04 /* Out sample rate = 96K */ +#define UAUDIO_SPDIF_IN_MIX 0x10 /* Input mix enable */ + struct uaudio_softc { struct sbuf sc_sndstat; struct sndcard_func sc_sndcard_func; @@ -334,6 +339,7 @@ struct uaudio_softc { struct usb_xfer *sc_mixer_xfer[1]; struct uaudio_mixer_node *sc_mixer_root; struct uaudio_mixer_node *sc_mixer_curr; + int (*sc_set_spdif_fn) (struct uaudio_softc *, int); uint32_t sc_mix_info; uint32_t sc_recsrc_info; @@ -864,6 +870,46 @@ uaudio_probe(device_t dev) return (ENXIO); } +/* + * Set Cmedia CM6206 S/PDIF settings + * Source: CM6206 Datasheet v2.3. + */ +static int +uaudio_set_spdif_cm6206(struct uaudio_softc *sc, int flags) +{ + uint8_t cmd[2][4] = { + {0x20, 0x20, 0x00, 0}, + {0x20, 0x30, 0x02, 1} + }; + int i; + + if (flags & UAUDIO_SPDIF_OUT) + cmd[1][1] = 0x00; + else + cmd[1][1] = 0x02; + + if (flags & UAUDIO_SPDIF_OUT_96K) + cmd[0][1] = 0x60; /* 96K: 3'b110 */ + + if (flags & UAUDIO_SPDIF_IN_MIX) + cmd[1][1] = 0x03; /* SPDIFMIX */ + + for (i = 0; i < 2; i++) { + if (usbd_req_set_report(sc->sc_udev, NULL, + cmd[i], sizeof(cmd[0]), + sc->sc_mixer_iface_index, UHID_OUTPUT_REPORT, 0) != 0) { + return (ENXIO); + } + } + return (0); +} + +static int +uaudio_set_spdif_dummy(struct uaudio_softc *sc, int flags) +{ + return (0); +} + static int uaudio_attach(device_t dev) { @@ -898,6 +944,12 @@ uaudio_attach(device_t dev) if (usb_test_quirk(uaa, UQ_AU_VENDOR_CLASS)) sc->sc_uq_au_vendor_class = 1; + /* set S/PDIF function */ + if (usb_test_quirk(uaa, UQ_AU_SET_SPDIF_CM6206)) + sc->sc_set_spdif_fn = uaudio_set_spdif_cm6206; + else + sc->sc_set_spdif_fn = uaudio_set_spdif_dummy; + umidi_init(dev); device_set_usb_desc(dev); @@ -1034,6 +1086,11 @@ uaudio_attach(device_t dev) /* reload all mixer settings */ uaudio_mixer_reload_all(sc); + /* enable S/PDIF output, if any */ + if (sc->sc_set_spdif_fn(sc, + UAUDIO_SPDIF_OUT | UAUDIO_SPDIF_OUT_48K) != 0) { + device_printf(dev, "Failed to enable S/PDIF at 48K\n"); + } return (0); /* success */ detach: @@ -1114,6 +1171,9 @@ uaudio_detach_sub(device_t dev) struct uaudio_softc *sc = device_get_softc(device_get_parent(dev)); int error = 0; + /* disable S/PDIF output, if any */ + (void) sc->sc_set_spdif_fn(sc, 0); + repeat: if (sc->sc_pcm_registered) { error = pcm_unregister(dev); Modified: stable/9/sys/dev/usb/quirk/usb_quirk.c ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:21:41 2017 (r315249) +++ stable/9/sys/dev/usb/quirk/usb_quirk.c Tue Mar 14 15:25:49 2017 (r315250) @@ -517,6 +517,7 @@ static struct usb_quirk_entry usb_quirks /* Non-standard USB AUDIO devices */ USB_QUIRK(MAUDIO, FASTTRACKULTRA, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), USB_QUIRK(MAUDIO, FASTTRACKULTRA8R, 0x0000, 0xffff, UQ_AU_VENDOR_CLASS), + USB_QUIRK(CMEDIA, CM6206, 0x0000, 0xffff, UQ_AU_SET_SPDIF_CM6206), /* * Quirks for manufacturers which USB devices does not respond @@ -604,6 +605,7 @@ static const char *usb_quirk_str[USB_QUI [UQ_AU_VENDOR_CLASS] = "UQ_AU_VENDOR_CLASS", [UQ_SINGLE_CMD_MIDI] = "UQ_SINGLE_CMD_MIDI", [UQ_MSC_DYMO_EJECT] = "UQ_MSC_DYMO_EJECT", + [UQ_AU_SET_SPDIF_CM6206] = "UQ_AU_SET_SPDIF_CM6206", }; /*------------------------------------------------------------------------* Modified: stable/9/sys/dev/usb/quirk/usb_quirk.h ============================================================================== --- stable/9/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:21:41 2017 (r315249) +++ stable/9/sys/dev/usb/quirk/usb_quirk.h Tue Mar 14 15:25:49 2017 (r315250) @@ -110,6 +110,7 @@ enum { UQ_AU_VENDOR_CLASS, /* audio device uses vendor and not audio class */ UQ_SINGLE_CMD_MIDI, /* at most one command per USB packet */ UQ_MSC_DYMO_EJECT, /* ejects Dymo MSC device */ + UQ_AU_SET_SPDIF_CM6206, /* enable S/PDIF audio output */ USB_QUIRK_MAX }; Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Tue Mar 14 15:21:41 2017 (r315249) +++ stable/9/sys/dev/usb/usbdevs Tue Mar 14 15:25:49 2017 (r315250) @@ -1438,6 +1438,9 @@ product CLIPSAL 5000CT2 0x0304 5000CT2 product CLIPSAL C5000CT2 0x0305 C5000CT2 C-Bus Touch Screen product CLIPSAL L51xx 0x0401 L51xx C-Bus Dimmer +/* C-Media products */ +product CMEDIA CM6206 0x0102 CM106 compatible sound device + /* CMOTECH products */ product CMOTECH CNU510 0x5141 CDMA Technologies USB modem product CMOTECH CNU550 0x5543 CDMA 2000 1xRTT/1xEVDO USB modem From owner-svn-src-all@freebsd.org Tue Mar 14 15:27:40 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2E4B4D0C466; Tue, 14 Mar 2017 15:27:40 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0662512EC; Tue, 14 Mar 2017 15:27:39 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFRdqO003935; Tue, 14 Mar 2017 15:27:39 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFRcD7003932; Tue, 14 Mar 2017 15:27:38 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141527.v2EFRcD7003932@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:27: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: r315251 - stable/11/sys/dev/usb/controller X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:27:40 -0000 Author: hselasky Date: Tue Mar 14 15:27:38 2017 New Revision: 315251 URL: https://svnweb.freebsd.org/changeset/base/315251 Log: MFC r312424: Fix problem with suspend and resume when using Skylake chipsets. Make sure the XHCI controller is reset after halting it. The problem is clearly a BIOS bug as the suspend and resume is failing without loading the XHCI driver. The same happens when using Linux and the XHCI driver is not loaded. Submitted by: Yanko Yankulov PR: 216261 Modified: stable/11/sys/dev/usb/controller/xhci.c stable/11/sys/dev/usb/controller/xhci.h stable/11/sys/dev/usb/controller/xhci_pci.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/usb/controller/xhci.c ============================================================================== --- stable/11/sys/dev/usb/controller/xhci.c Tue Mar 14 15:25:49 2017 (r315250) +++ stable/11/sys/dev/usb/controller/xhci.c Tue Mar 14 15:27:38 2017 (r315251) @@ -347,6 +347,7 @@ xhci_start_controller(struct xhci_softc struct usb_page_search buf_res; struct xhci_hw_root *phwr; struct xhci_dev_ctx_addr *pdctxa; + usb_error_t err; uint64_t addr; uint32_t temp; uint16_t i; @@ -358,22 +359,9 @@ xhci_start_controller(struct xhci_softc sc->sc_command_ccs = 1; sc->sc_command_idx = 0; - /* Reset controller */ - XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); - - for (i = 0; i != 100; i++) { - usb_pause_mtx(NULL, hz / 100); - temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | - (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); - if (!temp) - break; - } - - if (temp) { - device_printf(sc->sc_bus.parent, "Controller " - "reset timeout.\n"); - return (USB_ERR_IOERROR); - } + err = xhci_reset_controller(sc); + if (err) + return (err); /* set up number of device slots */ DPRINTF("CONFIG=0x%08x -> 0x%08x\n", @@ -521,6 +509,33 @@ xhci_halt_controller(struct xhci_softc * } usb_error_t +xhci_reset_controller(struct xhci_softc *sc) +{ + uint32_t temp = 0; + uint16_t i; + + DPRINTF("\n"); + + /* Reset controller */ + XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); + + for (i = 0; i != 100; i++) { + usb_pause_mtx(NULL, hz / 100); + temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | + (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); + if (!temp) + break; + } + + if (temp) { + device_printf(sc->sc_bus.parent, "Controller " + "reset timeout.\n"); + return (USB_ERR_IOERROR); + } + return (0); +} + +usb_error_t xhci_init(struct xhci_softc *sc, device_t self, uint8_t dma32) { uint32_t temp; @@ -671,10 +686,12 @@ xhci_set_hw_power_sleep(struct usb_bus * case USB_HW_POWER_SUSPEND: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_SHUTDOWN: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_RESUME: DPRINTF("Starting the XHCI\n"); Modified: stable/11/sys/dev/usb/controller/xhci.h ============================================================================== --- stable/11/sys/dev/usb/controller/xhci.h Tue Mar 14 15:25:49 2017 (r315250) +++ stable/11/sys/dev/usb/controller/xhci.h Tue Mar 14 15:27:38 2017 (r315251) @@ -525,6 +525,7 @@ struct xhci_softc { uint8_t xhci_use_polling(void); usb_error_t xhci_halt_controller(struct xhci_softc *); +usb_error_t xhci_reset_controller(struct xhci_softc *); usb_error_t xhci_init(struct xhci_softc *, device_t, uint8_t); usb_error_t xhci_start_controller(struct xhci_softc *); void xhci_interrupt(struct xhci_softc *); Modified: stable/11/sys/dev/usb/controller/xhci_pci.c ============================================================================== --- stable/11/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:25:49 2017 (r315250) +++ stable/11/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:27:38 2017 (r315251) @@ -348,6 +348,7 @@ xhci_pci_detach(device_t self) usb_callout_drain(&sc->sc_callout); xhci_halt_controller(sc); + xhci_reset_controller(sc); pci_disable_busmaster(self); From owner-svn-src-all@freebsd.org Tue Mar 14 15:29:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 49343D0C56F; Tue, 14 Mar 2017 15:29:01 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2349B14EB; Tue, 14 Mar 2017 15:29:01 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFT0EU004060; Tue, 14 Mar 2017 15:29:00 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFT0Px004054; Tue, 14 Mar 2017 15:29:00 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141529.v2EFT0Px004054@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:29:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315252 - stable/10/sys/dev/usb/controller X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:29:01 -0000 Author: hselasky Date: Tue Mar 14 15:28:59 2017 New Revision: 315252 URL: https://svnweb.freebsd.org/changeset/base/315252 Log: MFC r312424: Fix problem with suspend and resume when using Skylake chipsets. Make sure the XHCI controller is reset after halting it. The problem is clearly a BIOS bug as the suspend and resume is failing without loading the XHCI driver. The same happens when using Linux and the XHCI driver is not loaded. Submitted by: Yanko Yankulov PR: 216261 Modified: stable/10/sys/dev/usb/controller/xhci.c stable/10/sys/dev/usb/controller/xhci.h stable/10/sys/dev/usb/controller/xhci_pci.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/usb/controller/xhci.c ============================================================================== --- stable/10/sys/dev/usb/controller/xhci.c Tue Mar 14 15:27:38 2017 (r315251) +++ stable/10/sys/dev/usb/controller/xhci.c Tue Mar 14 15:28:59 2017 (r315252) @@ -352,6 +352,7 @@ xhci_start_controller(struct xhci_softc struct usb_page_search buf_res; struct xhci_hw_root *phwr; struct xhci_dev_ctx_addr *pdctxa; + usb_error_t err; uint64_t addr; uint32_t temp; uint16_t i; @@ -363,22 +364,9 @@ xhci_start_controller(struct xhci_softc sc->sc_command_ccs = 1; sc->sc_command_idx = 0; - /* Reset controller */ - XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); - - for (i = 0; i != 100; i++) { - usb_pause_mtx(NULL, hz / 100); - temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | - (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); - if (!temp) - break; - } - - if (temp) { - device_printf(sc->sc_bus.parent, "Controller " - "reset timeout.\n"); - return (USB_ERR_IOERROR); - } + err = xhci_reset_controller(sc); + if (err) + return (err); /* set up number of device slots */ DPRINTF("CONFIG=0x%08x -> 0x%08x\n", @@ -526,6 +514,33 @@ xhci_halt_controller(struct xhci_softc * } usb_error_t +xhci_reset_controller(struct xhci_softc *sc) +{ + uint32_t temp = 0; + uint16_t i; + + DPRINTF("\n"); + + /* Reset controller */ + XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); + + for (i = 0; i != 100; i++) { + usb_pause_mtx(NULL, hz / 100); + temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | + (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); + if (!temp) + break; + } + + if (temp) { + device_printf(sc->sc_bus.parent, "Controller " + "reset timeout.\n"); + return (USB_ERR_IOERROR); + } + return (0); +} + +usb_error_t xhci_init(struct xhci_softc *sc, device_t self, uint8_t dma32) { uint32_t temp; @@ -676,10 +691,12 @@ xhci_set_hw_power_sleep(struct usb_bus * case USB_HW_POWER_SUSPEND: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_SHUTDOWN: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_RESUME: DPRINTF("Starting the XHCI\n"); Modified: stable/10/sys/dev/usb/controller/xhci.h ============================================================================== --- stable/10/sys/dev/usb/controller/xhci.h Tue Mar 14 15:27:38 2017 (r315251) +++ stable/10/sys/dev/usb/controller/xhci.h Tue Mar 14 15:28:59 2017 (r315252) @@ -524,6 +524,7 @@ struct xhci_softc { uint8_t xhci_use_polling(void); usb_error_t xhci_halt_controller(struct xhci_softc *); +usb_error_t xhci_reset_controller(struct xhci_softc *); usb_error_t xhci_init(struct xhci_softc *, device_t, uint8_t); usb_error_t xhci_start_controller(struct xhci_softc *); void xhci_interrupt(struct xhci_softc *); Modified: stable/10/sys/dev/usb/controller/xhci_pci.c ============================================================================== --- stable/10/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:27:38 2017 (r315251) +++ stable/10/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:28:59 2017 (r315252) @@ -326,6 +326,7 @@ xhci_pci_detach(device_t self) usb_callout_drain(&sc->sc_callout); xhci_halt_controller(sc); + xhci_reset_controller(sc); pci_disable_busmaster(self); From owner-svn-src-all@freebsd.org Tue Mar 14 15:30:48 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3D0EED0C66F; Tue, 14 Mar 2017 15:30:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 17B7917E0; Tue, 14 Mar 2017 15:30:48 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFUlpw004214; Tue, 14 Mar 2017 15:30:47 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFUkKD004210; Tue, 14 Mar 2017 15:30:46 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141530.v2EFUkKD004210@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:30:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315253 - stable/9/sys/dev/usb/controller X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:30:48 -0000 Author: hselasky Date: Tue Mar 14 15:30:46 2017 New Revision: 315253 URL: https://svnweb.freebsd.org/changeset/base/315253 Log: MFC r312424: Fix problem with suspend and resume when using Skylake chipsets. Make sure the XHCI controller is reset after halting it. The problem is clearly a BIOS bug as the suspend and resume is failing without loading the XHCI driver. The same happens when using Linux and the XHCI driver is not loaded. Submitted by: Yanko Yankulov PR: 216261 Modified: stable/9/sys/dev/usb/controller/xhci.c stable/9/sys/dev/usb/controller/xhci.h stable/9/sys/dev/usb/controller/xhci_pci.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/dev/usb/controller/xhci.c ============================================================================== --- stable/9/sys/dev/usb/controller/xhci.c Tue Mar 14 15:28:59 2017 (r315252) +++ stable/9/sys/dev/usb/controller/xhci.c Tue Mar 14 15:30:46 2017 (r315253) @@ -341,6 +341,7 @@ xhci_start_controller(struct xhci_softc struct usb_page_search buf_res; struct xhci_hw_root *phwr; struct xhci_dev_ctx_addr *pdctxa; + usb_error_t err; uint64_t addr; uint32_t temp; uint16_t i; @@ -352,22 +353,9 @@ xhci_start_controller(struct xhci_softc sc->sc_command_ccs = 1; sc->sc_command_idx = 0; - /* Reset controller */ - XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); - - for (i = 0; i != 100; i++) { - usb_pause_mtx(NULL, hz / 100); - temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | - (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); - if (!temp) - break; - } - - if (temp) { - device_printf(sc->sc_bus.parent, "Controller " - "reset timeout.\n"); - return (USB_ERR_IOERROR); - } + err = xhci_reset_controller(sc); + if (err) + return (err); /* set up number of device slots */ DPRINTF("CONFIG=0x%08x -> 0x%08x\n", @@ -515,6 +503,33 @@ xhci_halt_controller(struct xhci_softc * } usb_error_t +xhci_reset_controller(struct xhci_softc *sc) +{ + uint32_t temp = 0; + uint16_t i; + + DPRINTF("\n"); + + /* Reset controller */ + XWRITE4(sc, oper, XHCI_USBCMD, XHCI_CMD_HCRST); + + for (i = 0; i != 100; i++) { + usb_pause_mtx(NULL, hz / 100); + temp = (XREAD4(sc, oper, XHCI_USBCMD) & XHCI_CMD_HCRST) | + (XREAD4(sc, oper, XHCI_USBSTS) & XHCI_STS_CNR); + if (!temp) + break; + } + + if (temp) { + device_printf(sc->sc_bus.parent, "Controller " + "reset timeout.\n"); + return (USB_ERR_IOERROR); + } + return (0); +} + +usb_error_t xhci_init(struct xhci_softc *sc, device_t self, uint8_t dma32) { uint32_t temp; @@ -666,10 +681,12 @@ xhci_set_hw_power_sleep(struct usb_bus * case USB_HW_POWER_SUSPEND: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_SHUTDOWN: DPRINTF("Stopping the XHCI\n"); xhci_halt_controller(sc); + xhci_reset_controller(sc); break; case USB_HW_POWER_RESUME: DPRINTF("Starting the XHCI\n"); Modified: stable/9/sys/dev/usb/controller/xhci.h ============================================================================== --- stable/9/sys/dev/usb/controller/xhci.h Tue Mar 14 15:28:59 2017 (r315252) +++ stable/9/sys/dev/usb/controller/xhci.h Tue Mar 14 15:30:46 2017 (r315253) @@ -515,6 +515,7 @@ struct xhci_softc { uint8_t xhci_use_polling(void); usb_error_t xhci_halt_controller(struct xhci_softc *); +usb_error_t xhci_reset_controller(struct xhci_softc *); usb_error_t xhci_init(struct xhci_softc *, device_t, uint8_t); usb_error_t xhci_start_controller(struct xhci_softc *); void xhci_interrupt(struct xhci_softc *); Modified: stable/9/sys/dev/usb/controller/xhci_pci.c ============================================================================== --- stable/9/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:28:59 2017 (r315252) +++ stable/9/sys/dev/usb/controller/xhci_pci.c Tue Mar 14 15:30:46 2017 (r315253) @@ -317,6 +317,7 @@ xhci_pci_detach(device_t self) usb_callout_drain(&sc->sc_callout); xhci_halt_controller(sc); + xhci_reset_controller(sc); pci_disable_busmaster(self); From owner-svn-src-all@freebsd.org Tue Mar 14 15:35:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 570D0D0C922; Tue, 14 Mar 2017 15:35:41 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2A60E1E06; Tue, 14 Mar 2017 15:35:41 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFZerh008400; Tue, 14 Mar 2017 15:35:40 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFZeut008399; Tue, 14 Mar 2017 15:35:40 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141535.v2EFZeut008399@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:35:40 +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: r315254 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:35:41 -0000 Author: hselasky Date: Tue Mar 14 15:35:40 2017 New Revision: 315254 URL: https://svnweb.freebsd.org/changeset/base/315254 Log: MFC r312551: Fix for race leading to endless timer interrupts related to configtimer(). During normal operation "state->nextcallopt" will always be less than or equal to "state->nextcall" and checking only "state->nextcallopt" before calling "callout_process()" is sufficient. However when "configtimer()" is called a race might happen requiring both of these binary times to be checked. Short description of race: 1) A configtimer() call will reset both "state->nextcall" and "state->nextcallopt" to the same binary time. 2) If a "callout_reset()" call happens between "configtimer()" and the next "callout_process()" call, "state->nextcallopt" will get updated and "state->nextcall" will remain at the current time. Refer to logic inside cpu_new_callout(). 3) getnextcpuevent() only respects "state->nextcall" and returns this value over and over again, even if it is in the past, until "now >= state->nextcallopt" becomes true. Then these two time variables are corrected by a "callout_process()" call and the situation goes back to normal. The problem manifests itself in different ways. The common factor is the timer process(es) consume all CPU on one or more CPU cores for a long time, blocking other kernel processes from getting execution time. This can be seen by very high interrupt counts as displayed by "vmstat -i | grep timer" right after boot. When EARLY_AP_STARTUP was enabled in r310177 the likelyhood of hitting this bug apparently increased. Example output from "vmstat -i" before patch: cpu0:timer 7591 69 cpu9:timer 39031773 358089 cpu4:timer 9359 85 cpu3:timer 9100 83 cpu2:timer 9620 88 Example output from "vmstat -i" after patch: cpu0:timer 4242 34 cpu6:timer 5531 44 cpu3:timer 6450 52 cpu1:timer 4545 36 cpu9:timer 7153 58 Before the patch cpu9 in the example above, was spinning in a loop in order to reach 39 million interrupts just a few seconds after bootup. After the patch the timer interrupt counts are more or less consistent. Discussed with: mav @ Reported by: several people Sponsored by: Mellanox Technologies Modified: stable/11/sys/kern/kern_clocksource.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_clocksource.c ============================================================================== --- stable/11/sys/kern/kern_clocksource.c Tue Mar 14 15:30:46 2017 (r315253) +++ stable/11/sys/kern/kern_clocksource.c Tue Mar 14 15:35:40 2017 (r315254) @@ -206,7 +206,7 @@ handleevents(sbintime_t now, int fake) } } else state->nextprof = state->nextstat; - if (now >= state->nextcallopt) { + if (now >= state->nextcallopt || now >= state->nextcall) { state->nextcall = state->nextcallopt = SBT_MAX; callout_process(now); } From owner-svn-src-all@freebsd.org Tue Mar 14 15:37:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BBF3BD0C998; Tue, 14 Mar 2017 15:37:30 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 940B31FCE; Tue, 14 Mar 2017 15:37:30 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFbTDc008523; Tue, 14 Mar 2017 15:37:29 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFbTTJ008522; Tue, 14 Mar 2017 15:37:29 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141537.v2EFbTTJ008522@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:37:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315255 - stable/10/sys/kern X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:37:30 -0000 Author: hselasky Date: Tue Mar 14 15:37:29 2017 New Revision: 315255 URL: https://svnweb.freebsd.org/changeset/base/315255 Log: MFC r312551: Fix for race leading to endless timer interrupts related to configtimer(). During normal operation "state->nextcallopt" will always be less than or equal to "state->nextcall" and checking only "state->nextcallopt" before calling "callout_process()" is sufficient. However when "configtimer()" is called a race might happen requiring both of these binary times to be checked. Short description of race: 1) A configtimer() call will reset both "state->nextcall" and "state->nextcallopt" to the same binary time. 2) If a "callout_reset()" call happens between "configtimer()" and the next "callout_process()" call, "state->nextcallopt" will get updated and "state->nextcall" will remain at the current time. Refer to logic inside cpu_new_callout(). 3) getnextcpuevent() only respects "state->nextcall" and returns this value over and over again, even if it is in the past, until "now >= state->nextcallopt" becomes true. Then these two time variables are corrected by a "callout_process()" call and the situation goes back to normal. The problem manifests itself in different ways. The common factor is the timer process(es) consume all CPU on one or more CPU cores for a long time, blocking other kernel processes from getting execution time. This can be seen by very high interrupt counts as displayed by "vmstat -i | grep timer" right after boot. When EARLY_AP_STARTUP was enabled in r310177 the likelyhood of hitting this bug apparently increased. Example output from "vmstat -i" before patch: cpu0:timer 7591 69 cpu9:timer 39031773 358089 cpu4:timer 9359 85 cpu3:timer 9100 83 cpu2:timer 9620 88 Example output from "vmstat -i" after patch: cpu0:timer 4242 34 cpu6:timer 5531 44 cpu3:timer 6450 52 cpu1:timer 4545 36 cpu9:timer 7153 58 Before the patch cpu9 in the example above, was spinning in a loop in order to reach 39 million interrupts just a few seconds after bootup. After the patch the timer interrupt counts are more or less consistent. Discussed with: mav @ Reported by: several people Sponsored by: Mellanox Technologies Modified: stable/10/sys/kern/kern_clocksource.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/kern/kern_clocksource.c ============================================================================== --- stable/10/sys/kern/kern_clocksource.c Tue Mar 14 15:35:40 2017 (r315254) +++ stable/10/sys/kern/kern_clocksource.c Tue Mar 14 15:37:29 2017 (r315255) @@ -210,7 +210,7 @@ handleevents(sbintime_t now, int fake) } } else state->nextprof = state->nextstat; - if (now >= state->nextcallopt) { + if (now >= state->nextcallopt || now >= state->nextcall) { state->nextcall = state->nextcallopt = SBT_MAX; callout_process(now); } From owner-svn-src-all@freebsd.org Tue Mar 14 15:42:28 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 61639D0CCA3; Tue, 14 Mar 2017 15:42:28 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3031993D; Tue, 14 Mar 2017 15:42:28 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFgR1h012467; Tue, 14 Mar 2017 15:42:27 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFgRLx012466; Tue, 14 Mar 2017 15:42:27 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141542.v2EFgRLx012466@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:42:27 +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: r315256 - stable/11/sys/ofed/drivers/infiniband/hw/mlx4 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:42:28 -0000 Author: hselasky Date: Tue Mar 14 15:42:27 2017 New Revision: 315256 URL: https://svnweb.freebsd.org/changeset/base/315256 Log: MFC r313778: Improve code readability and fix compilation error when using clang 4.x. Found by: emaste @ Sponsored by: Mellanox Technologies Modified: stable/11/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/ofed/drivers/infiniband/hw/mlx4/mad.c ============================================================================== --- stable/11/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:37:29 2017 (r315255) +++ stable/11/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:42:27 2017 (r315256) @@ -614,7 +614,7 @@ static int mlx4_ib_demux_mad(struct ib_d is_eth = 1; if (is_eth) { - if (!wc->wc_flags & IB_WC_GRH) { + if (!(wc->wc_flags & IB_WC_GRH)) { mlx4_ib_warn(ibdev, "RoCE grh not present.\n"); return -EINVAL; } From owner-svn-src-all@freebsd.org Tue Mar 14 15:44:40 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AE0B5D0CE02; Tue, 14 Mar 2017 15:44:40 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7CE9FBAF; Tue, 14 Mar 2017 15:44:40 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFidd2012625; Tue, 14 Mar 2017 15:44:39 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFid4I012624; Tue, 14 Mar 2017 15:44:39 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141544.v2EFid4I012624@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:44:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315257 - stable/10/sys/ofed/drivers/infiniband/hw/mlx4 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:44:40 -0000 Author: hselasky Date: Tue Mar 14 15:44:39 2017 New Revision: 315257 URL: https://svnweb.freebsd.org/changeset/base/315257 Log: MFC r313778: Improve code readability and fix compilation error when using clang 4.x. Found by: emaste @ Sponsored by: Mellanox Technologies Modified: stable/10/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/ofed/drivers/infiniband/hw/mlx4/mad.c ============================================================================== --- stable/10/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:42:27 2017 (r315256) +++ stable/10/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:44:39 2017 (r315257) @@ -593,7 +593,7 @@ static int mlx4_ib_demux_mad(struct ib_d is_eth = 1; if (is_eth) { - if (!wc->wc_flags & IB_WC_GRH) { + if (!(wc->wc_flags & IB_WC_GRH)) { mlx4_ib_warn(ibdev, "RoCE grh not present.\n"); return -EINVAL; } From owner-svn-src-all@freebsd.org Tue Mar 14 15:47:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EEC6ED0CEFE; Tue, 14 Mar 2017 15:47:18 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BD7FFD42; Tue, 14 Mar 2017 15:47:18 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFlHBG012788; Tue, 14 Mar 2017 15:47:17 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFlHFB012787; Tue, 14 Mar 2017 15:47:17 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141547.v2EFlHFB012787@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:47:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315258 - stable/9/sys/ofed/drivers/infiniband/hw/mlx4 X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:47:19 -0000 Author: hselasky Date: Tue Mar 14 15:47:17 2017 New Revision: 315258 URL: https://svnweb.freebsd.org/changeset/base/315258 Log: MFC r313778: Improve code readability and fix compilation error when using clang 4.x. Found by: emaste @ Sponsored by: Mellanox Technologies Modified: stable/9/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/ofed/drivers/infiniband/hw/mlx4/mad.c ============================================================================== --- stable/9/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:44:39 2017 (r315257) +++ stable/9/sys/ofed/drivers/infiniband/hw/mlx4/mad.c Tue Mar 14 15:47:17 2017 (r315258) @@ -593,7 +593,7 @@ static int mlx4_ib_demux_mad(struct ib_d is_eth = 1; if (is_eth) { - if (!wc->wc_flags & IB_WC_GRH) { + if (!(wc->wc_flags & IB_WC_GRH)) { mlx4_ib_warn(ibdev, "RoCE grh not present.\n"); return -EINVAL; } From owner-svn-src-all@freebsd.org Tue Mar 14 15:49:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 22E5ED0CFC8; Tue, 14 Mar 2017 15:49:30 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CB24CF85; Tue, 14 Mar 2017 15:49:29 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFnSmF012912; Tue, 14 Mar 2017 15:49:28 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFnS6w012911; Tue, 14 Mar 2017 15:49:28 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141549.v2EFnS6w012911@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:49:28 +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: r315259 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:49:30 -0000 Author: hselasky Date: Tue Mar 14 15:49:28 2017 New Revision: 315259 URL: https://svnweb.freebsd.org/changeset/base/315259 Log: MFC r313941: Make sure the thread constructor and destructor eventhandlers are called for all threads belonging to a procedure. Currently the first thread in a procedure is kept around as an optimisation step and is never freed. Because the first thread in a procedure is never freed nor allocated, its destructor and constructor callbacks are never called which means per thread structures allocated by dtrace and the Linux emulation layers for example, might be present for threads which don't need these structures. This patch adds a thread construction and destruction call for the first thread in a procedure. Tested: dtrace, linux emulation Reviewed by: kib @ Sponsored by: Mellanox Technologies Modified: stable/11/sys/kern/kern_proc.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_proc.c ============================================================================== --- stable/11/sys/kern/kern_proc.c Tue Mar 14 15:47:17 2017 (r315258) +++ stable/11/sys/kern/kern_proc.c Tue Mar 14 15:49:28 2017 (r315259) @@ -191,11 +191,17 @@ static int proc_ctor(void *mem, int size, void *arg, int flags) { struct proc *p; + struct thread *td; p = (struct proc *)mem; SDT_PROBE4(proc, , ctor , entry, p, size, arg, flags); EVENTHANDLER_INVOKE(process_ctor, p); SDT_PROBE4(proc, , ctor , return, p, size, arg, flags); + td = FIRST_THREAD_IN_PROC(p); + if (td != NULL) { + /* Make sure all thread constructors are executed */ + EVENTHANDLER_INVOKE(thread_ctor, td); + } return (0); } @@ -220,6 +226,9 @@ proc_dtor(void *mem, int size, void *arg #endif /* Free all OSD associated to this thread. */ osd_thread_exit(td); + + /* Make sure all thread destructors are executed */ + EVENTHANDLER_INVOKE(thread_dtor, td); } EVENTHANDLER_INVOKE(process_dtor, p); if (p->p_ksi != NULL) From owner-svn-src-all@freebsd.org Tue Mar 14 15:50:37 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9A332D0C044; Tue, 14 Mar 2017 15:50:37 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 49B981160; Tue, 14 Mar 2017 15:50:37 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFoaJb015117; Tue, 14 Mar 2017 15:50:36 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFoada015116; Tue, 14 Mar 2017 15:50:36 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141550.v2EFoada015116@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:50:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315260 - stable/10/sys/kern X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:50:37 -0000 Author: hselasky Date: Tue Mar 14 15:50:36 2017 New Revision: 315260 URL: https://svnweb.freebsd.org/changeset/base/315260 Log: MFC r313941: Make sure the thread constructor and destructor eventhandlers are called for all threads belonging to a procedure. Currently the first thread in a procedure is kept around as an optimisation step and is never freed. Because the first thread in a procedure is never freed nor allocated, its destructor and constructor callbacks are never called which means per thread structures allocated by dtrace and the Linux emulation layers for example, might be present for threads which don't need these structures. This patch adds a thread construction and destruction call for the first thread in a procedure. Tested: dtrace, linux emulation Reviewed by: kib @ Sponsored by: Mellanox Technologies Modified: stable/10/sys/kern/kern_proc.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/kern/kern_proc.c ============================================================================== --- stable/10/sys/kern/kern_proc.c Tue Mar 14 15:49:28 2017 (r315259) +++ stable/10/sys/kern/kern_proc.c Tue Mar 14 15:50:36 2017 (r315260) @@ -191,11 +191,17 @@ static int proc_ctor(void *mem, int size, void *arg, int flags) { struct proc *p; + struct thread *td; p = (struct proc *)mem; SDT_PROBE4(proc, , ctor , entry, p, size, arg, flags); EVENTHANDLER_INVOKE(process_ctor, p); SDT_PROBE4(proc, , ctor , return, p, size, arg, flags); + td = FIRST_THREAD_IN_PROC(p); + if (td != NULL) { + /* Make sure all thread constructors are executed */ + EVENTHANDLER_INVOKE(thread_ctor, td); + } return (0); } @@ -220,6 +226,9 @@ proc_dtor(void *mem, int size, void *arg #endif /* Free all OSD associated to this thread. */ osd_thread_exit(td); + + /* Make sure all thread destructors are executed */ + EVENTHANDLER_INVOKE(thread_dtor, td); } EVENTHANDLER_INVOKE(process_dtor, p); if (p->p_ksi != NULL) From owner-svn-src-all@freebsd.org Tue Mar 14 15:52:02 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 83DD6D0C4CB; Tue, 14 Mar 2017 15:52:02 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 245F41768; Tue, 14 Mar 2017 15:52:02 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFq1Rm016775; Tue, 14 Mar 2017 15:52:01 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFq1QL016774; Tue, 14 Mar 2017 15:52:01 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141552.v2EFq1QL016774@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:52:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315261 - stable/9/sys/kern X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:52:02 -0000 Author: hselasky Date: Tue Mar 14 15:52:01 2017 New Revision: 315261 URL: https://svnweb.freebsd.org/changeset/base/315261 Log: MFC r313941: Make sure the thread constructor and destructor eventhandlers are called for all threads belonging to a procedure. Currently the first thread in a procedure is kept around as an optimisation step and is never freed. Because the first thread in a procedure is never freed nor allocated, its destructor and constructor callbacks are never called which means per thread structures allocated by dtrace and the Linux emulation layers for example, might be present for threads which don't need these structures. This patch adds a thread construction and destruction call for the first thread in a procedure. Tested: dtrace, linux emulation Reviewed by: kib @ Sponsored by: Mellanox Technologies Modified: stable/9/sys/kern/kern_proc.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/kern/kern_proc.c ============================================================================== --- stable/9/sys/kern/kern_proc.c Tue Mar 14 15:50:36 2017 (r315260) +++ stable/9/sys/kern/kern_proc.c Tue Mar 14 15:52:01 2017 (r315261) @@ -178,11 +178,17 @@ static int proc_ctor(void *mem, int size, void *arg, int flags) { struct proc *p; + struct thread *td; p = (struct proc *)mem; SDT_PROBE4(proc, kernel, ctor , entry, p, size, arg, flags); EVENTHANDLER_INVOKE(process_ctor, p); SDT_PROBE4(proc, kernel, ctor , return, p, size, arg, flags); + td = FIRST_THREAD_IN_PROC(p); + if (td != NULL) { + /* Make sure all thread constructors are executed */ + EVENTHANDLER_INVOKE(thread_ctor, td); + } return (0); } @@ -207,6 +213,9 @@ proc_dtor(void *mem, int size, void *arg #endif /* Free all OSD associated to this thread. */ osd_thread_exit(td); + + /* Make sure all thread destructors are executed */ + EVENTHANDLER_INVOKE(thread_dtor, td); } EVENTHANDLER_INVOKE(process_dtor, p); if (p->p_ksi != NULL) From owner-svn-src-all@freebsd.org Tue Mar 14 15:53:25 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C6B70D0C618; Tue, 14 Mar 2017 15:53:25 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 760661993; Tue, 14 Mar 2017 15:53:25 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFrOrw017005; Tue, 14 Mar 2017 15:53:24 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFrOWw017004; Tue, 14 Mar 2017 15:53:24 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141553.v2EFrOWw017004@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:53:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r315262 - stable/8/sys/kern X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:53:25 -0000 Author: hselasky Date: Tue Mar 14 15:53:24 2017 New Revision: 315262 URL: https://svnweb.freebsd.org/changeset/base/315262 Log: MFC r313941: Make sure the thread constructor and destructor eventhandlers are called for all threads belonging to a procedure. Currently the first thread in a procedure is kept around as an optimisation step and is never freed. Because the first thread in a procedure is never freed nor allocated, its destructor and constructor callbacks are never called which means per thread structures allocated by dtrace and the Linux emulation layers for example, might be present for threads which don't need these structures. This patch adds a thread construction and destruction call for the first thread in a procedure. Tested: dtrace, linux emulation Reviewed by: kib @ Sponsored by: Mellanox Technologies Modified: stable/8/sys/kern/kern_proc.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/kern/ (props changed) Modified: stable/8/sys/kern/kern_proc.c ============================================================================== --- stable/8/sys/kern/kern_proc.c Tue Mar 14 15:52:01 2017 (r315261) +++ stable/8/sys/kern/kern_proc.c Tue Mar 14 15:53:24 2017 (r315262) @@ -181,11 +181,17 @@ static int proc_ctor(void *mem, int size, void *arg, int flags) { struct proc *p; + struct thread *td; p = (struct proc *)mem; SDT_PROBE(proc, kernel, ctor , entry, p, size, arg, flags, 0); EVENTHANDLER_INVOKE(process_ctor, p); SDT_PROBE(proc, kernel, ctor , return, p, size, arg, flags, 0); + td = FIRST_THREAD_IN_PROC(p); + if (td != NULL) { + /* Make sure all thread constructors are executed */ + EVENTHANDLER_INVOKE(thread_ctor, td); + } return (0); } @@ -210,6 +216,9 @@ proc_dtor(void *mem, int size, void *arg #endif /* Free all OSD associated to this thread. */ osd_thread_exit(td); + + /* Make sure all thread destructors are executed */ + EVENTHANDLER_INVOKE(thread_dtor, td); } EVENTHANDLER_INVOKE(process_dtor, p); if (p->p_ksi != NULL) From owner-svn-src-all@freebsd.org Tue Mar 14 15:55:18 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 992B4D0C6C2; Tue, 14 Mar 2017 15:55:18 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5A1131BAE; Tue, 14 Mar 2017 15:55:18 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFtHSn017335; Tue, 14 Mar 2017 15:55:17 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFtHcF017334; Tue, 14 Mar 2017 15:55:17 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141555.v2EFtHcF017334@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:55:17 +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: r315263 - stable/11/sys/dev/acpica X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:55:18 -0000 Author: hselasky Date: Tue Mar 14 15:55:17 2017 New Revision: 315263 URL: https://svnweb.freebsd.org/changeset/base/315263 Log: MFC r314328: Fix startup race initialising ACPI CM battery structures on MacBookPro. During acpi_cmbat_attach() the acpi_cmbat_init_battery() notification handler is registered. It has been observed this notification handler can be called instantly, before the attach routine has returned. In the notification handler there is a call to device_is_attached() which returns false. Because the softc is set we know an attach is in progress and the fix is simply to wait and try again in this case. Reviewed by: avg @ Modified: stable/11/sys/dev/acpica/acpi_cmbat.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/dev/acpica/acpi_cmbat.c ============================================================================== --- stable/11/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:53:24 2017 (r315262) +++ stable/11/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:55:17 2017 (r315263) @@ -164,6 +164,16 @@ acpi_cmbat_detach(device_t dev) handle = acpi_get_handle(dev); AcpiRemoveNotifyHandler(handle, ACPI_ALL_NOTIFY, acpi_cmbat_notify_handler); acpi_battery_remove(dev); + + /* + * Force any pending notification handler calls to complete by + * requesting cmbat serialisation while freeing and clearing the + * softc pointer: + */ + ACPI_SERIAL_BEGIN(cmbat); + device_set_softc(dev, NULL); + ACPI_SERIAL_END(cmbat); + return (0); } @@ -436,7 +446,6 @@ acpi_cmbat_init_battery(void *arg) device_t dev; dev = (device_t)arg; - sc = device_get_softc(dev); ACPI_VPRINT(dev, acpi_device_get_parent_softc(dev), "battery initialization start\n"); @@ -446,18 +455,33 @@ acpi_cmbat_init_battery(void *arg) * to wait a while. */ for (retry = 0; retry < ACPI_CMBAT_RETRY_MAX; retry++, AcpiOsSleep(10000)) { - /* batteries on DOCK can be ejected w/ DOCK during retrying */ - if (!device_is_attached(dev)) + /* + * Batteries on DOCK can be ejected w/ DOCK during retrying. + * + * If there is a valid softc pointer the device may be in + * attaching, attached or detaching state. If the state is + * different from attached retry getting the device state + * until it becomes stable. This solves a race if the ACPI + * notification handler is called during attach, because + * device_is_attached() doesn't return non-zero until after + * the attach code has been executed. + */ + ACPI_SERIAL_BEGIN(cmbat); + sc = device_get_softc(dev); + if (sc == NULL) { + ACPI_SERIAL_END(cmbat); return; + } - if (!acpi_BatteryIsPresent(dev)) + if (!acpi_BatteryIsPresent(dev) || !device_is_attached(dev)) { + ACPI_SERIAL_END(cmbat); continue; + } /* * Only query the battery if this is the first try or the specific * type of info is still invalid. */ - ACPI_SERIAL_BEGIN(cmbat); if (retry == 0 || !acpi_battery_bst_valid(&sc->bst)) { timespecclear(&sc->bst_lastupdated); acpi_cmbat_get_bst(dev); From owner-svn-src-all@freebsd.org Tue Mar 14 15:56:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 627E9D0C72B; Tue, 14 Mar 2017 15:56:20 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 236321D07; Tue, 14 Mar 2017 15:56:20 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFuJ4b017508; Tue, 14 Mar 2017 15:56:19 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFuJLS017507; Tue, 14 Mar 2017 15:56:19 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141556.v2EFuJLS017507@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:56:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315264 - stable/10/sys/dev/acpica X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:56:20 -0000 Author: hselasky Date: Tue Mar 14 15:56:19 2017 New Revision: 315264 URL: https://svnweb.freebsd.org/changeset/base/315264 Log: MFC r314328: Fix startup race initialising ACPI CM battery structures on MacBookPro. During acpi_cmbat_attach() the acpi_cmbat_init_battery() notification handler is registered. It has been observed this notification handler can be called instantly, before the attach routine has returned. In the notification handler there is a call to device_is_attached() which returns false. Because the softc is set we know an attach is in progress and the fix is simply to wait and try again in this case. Reviewed by: avg @ Modified: stable/10/sys/dev/acpica/acpi_cmbat.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/acpica/acpi_cmbat.c ============================================================================== --- stable/10/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:55:17 2017 (r315263) +++ stable/10/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:56:19 2017 (r315264) @@ -164,6 +164,16 @@ acpi_cmbat_detach(device_t dev) handle = acpi_get_handle(dev); AcpiRemoveNotifyHandler(handle, ACPI_ALL_NOTIFY, acpi_cmbat_notify_handler); acpi_battery_remove(dev); + + /* + * Force any pending notification handler calls to complete by + * requesting cmbat serialisation while freeing and clearing the + * softc pointer: + */ + ACPI_SERIAL_BEGIN(cmbat); + device_set_softc(dev, NULL); + ACPI_SERIAL_END(cmbat); + return (0); } @@ -436,7 +446,6 @@ acpi_cmbat_init_battery(void *arg) device_t dev; dev = (device_t)arg; - sc = device_get_softc(dev); ACPI_VPRINT(dev, acpi_device_get_parent_softc(dev), "battery initialization start\n"); @@ -446,18 +455,33 @@ acpi_cmbat_init_battery(void *arg) * to wait a while. */ for (retry = 0; retry < ACPI_CMBAT_RETRY_MAX; retry++, AcpiOsSleep(10000)) { - /* batteries on DOCK can be ejected w/ DOCK during retrying */ - if (!device_is_attached(dev)) + /* + * Batteries on DOCK can be ejected w/ DOCK during retrying. + * + * If there is a valid softc pointer the device may be in + * attaching, attached or detaching state. If the state is + * different from attached retry getting the device state + * until it becomes stable. This solves a race if the ACPI + * notification handler is called during attach, because + * device_is_attached() doesn't return non-zero until after + * the attach code has been executed. + */ + ACPI_SERIAL_BEGIN(cmbat); + sc = device_get_softc(dev); + if (sc == NULL) { + ACPI_SERIAL_END(cmbat); return; + } - if (!acpi_BatteryIsPresent(dev)) + if (!acpi_BatteryIsPresent(dev) || !device_is_attached(dev)) { + ACPI_SERIAL_END(cmbat); continue; + } /* * Only query the battery if this is the first try or the specific * type of info is still invalid. */ - ACPI_SERIAL_BEGIN(cmbat); if (retry == 0 || !acpi_battery_bst_valid(&sc->bst)) { timespecclear(&sc->bst_lastupdated); acpi_cmbat_get_bst(dev); From owner-svn-src-all@freebsd.org Tue Mar 14 15:57:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 32A34D0C7CB; Tue, 14 Mar 2017 15:57:23 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E801114D; Tue, 14 Mar 2017 15:57:22 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFvMbT017711; Tue, 14 Mar 2017 15:57:22 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFvMeR017710; Tue, 14 Mar 2017 15:57:22 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141557.v2EFvMeR017710@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:57:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315265 - stable/9/sys/dev/acpica X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:57:23 -0000 Author: hselasky Date: Tue Mar 14 15:57:21 2017 New Revision: 315265 URL: https://svnweb.freebsd.org/changeset/base/315265 Log: MFC r314328: Fix startup race initialising ACPI CM battery structures on MacBookPro. During acpi_cmbat_attach() the acpi_cmbat_init_battery() notification handler is registered. It has been observed this notification handler can be called instantly, before the attach routine has returned. In the notification handler there is a call to device_is_attached() which returns false. Because the softc is set we know an attach is in progress and the fix is simply to wait and try again in this case. Reviewed by: avg @ Modified: stable/9/sys/dev/acpica/acpi_cmbat.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/dev/acpica/acpi_cmbat.c ============================================================================== --- stable/9/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:56:19 2017 (r315264) +++ stable/9/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:57:21 2017 (r315265) @@ -164,6 +164,16 @@ acpi_cmbat_detach(device_t dev) handle = acpi_get_handle(dev); AcpiRemoveNotifyHandler(handle, ACPI_ALL_NOTIFY, acpi_cmbat_notify_handler); acpi_battery_remove(dev); + + /* + * Force any pending notification handler calls to complete by + * requesting cmbat serialisation while freeing and clearing the + * softc pointer: + */ + ACPI_SERIAL_BEGIN(cmbat); + device_set_softc(dev, NULL); + ACPI_SERIAL_END(cmbat); + return (0); } @@ -436,7 +446,6 @@ acpi_cmbat_init_battery(void *arg) device_t dev; dev = (device_t)arg; - sc = device_get_softc(dev); ACPI_VPRINT(dev, acpi_device_get_parent_softc(dev), "battery initialization start\n"); @@ -446,18 +455,33 @@ acpi_cmbat_init_battery(void *arg) * to wait a while. */ for (retry = 0; retry < ACPI_CMBAT_RETRY_MAX; retry++, AcpiOsSleep(10000)) { - /* batteries on DOCK can be ejected w/ DOCK during retrying */ - if (!device_is_attached(dev)) + /* + * Batteries on DOCK can be ejected w/ DOCK during retrying. + * + * If there is a valid softc pointer the device may be in + * attaching, attached or detaching state. If the state is + * different from attached retry getting the device state + * until it becomes stable. This solves a race if the ACPI + * notification handler is called during attach, because + * device_is_attached() doesn't return non-zero until after + * the attach code has been executed. + */ + ACPI_SERIAL_BEGIN(cmbat); + sc = device_get_softc(dev); + if (sc == NULL) { + ACPI_SERIAL_END(cmbat); return; + } - if (!acpi_BatteryIsPresent(dev)) + if (!acpi_BatteryIsPresent(dev) || !device_is_attached(dev)) { + ACPI_SERIAL_END(cmbat); continue; + } /* * Only query the battery if this is the first try or the specific * type of info is still invalid. */ - ACPI_SERIAL_BEGIN(cmbat); if (retry == 0 || !acpi_battery_bst_valid(&sc->bst)) { timespecclear(&sc->bst_lastupdated); acpi_cmbat_get_bst(dev); From owner-svn-src-all@freebsd.org Tue Mar 14 15:58:02 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8AE62D0C8AD; Tue, 14 Mar 2017 15:58:02 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4A2BA3AF; Tue, 14 Mar 2017 15:58:02 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFw1p5017892; Tue, 14 Mar 2017 15:58:01 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFw1Wn017891; Tue, 14 Mar 2017 15:58:01 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141558.v2EFw1Wn017891@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:58:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r315266 - stable/8/sys/dev/acpica X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:58:02 -0000 Author: hselasky Date: Tue Mar 14 15:58:01 2017 New Revision: 315266 URL: https://svnweb.freebsd.org/changeset/base/315266 Log: MFC r314328: Fix startup race initialising ACPI CM battery structures on MacBookPro. During acpi_cmbat_attach() the acpi_cmbat_init_battery() notification handler is registered. It has been observed this notification handler can be called instantly, before the attach routine has returned. In the notification handler there is a call to device_is_attached() which returns false. Because the softc is set we know an attach is in progress and the fix is simply to wait and try again in this case. Reviewed by: avg @ Modified: stable/8/sys/dev/acpica/acpi_cmbat.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/acpica/ (props changed) Modified: stable/8/sys/dev/acpica/acpi_cmbat.c ============================================================================== --- stable/8/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:57:21 2017 (r315265) +++ stable/8/sys/dev/acpica/acpi_cmbat.c Tue Mar 14 15:58:01 2017 (r315266) @@ -163,6 +163,16 @@ acpi_cmbat_detach(device_t dev) handle = acpi_get_handle(dev); AcpiRemoveNotifyHandler(handle, ACPI_ALL_NOTIFY, acpi_cmbat_notify_handler); acpi_battery_remove(dev); + + /* + * Force any pending notification handler calls to complete by + * requesting cmbat serialisation while freeing and clearing the + * softc pointer: + */ + ACPI_SERIAL_BEGIN(cmbat); + device_set_softc(dev, NULL); + ACPI_SERIAL_END(cmbat); + return (0); } @@ -435,7 +445,6 @@ acpi_cmbat_init_battery(void *arg) device_t dev; dev = (device_t)arg; - sc = device_get_softc(dev); ACPI_VPRINT(dev, acpi_device_get_parent_softc(dev), "battery initialization start\n"); @@ -445,18 +454,33 @@ acpi_cmbat_init_battery(void *arg) * to wait a while. */ for (retry = 0; retry < ACPI_CMBAT_RETRY_MAX; retry++, AcpiOsSleep(10000)) { - /* batteries on DOCK can be ejected w/ DOCK during retrying */ - if (!device_is_attached(dev)) + /* + * Batteries on DOCK can be ejected w/ DOCK during retrying. + * + * If there is a valid softc pointer the device may be in + * attaching, attached or detaching state. If the state is + * different from attached retry getting the device state + * until it becomes stable. This solves a race if the ACPI + * notification handler is called during attach, because + * device_is_attached() doesn't return non-zero until after + * the attach code has been executed. + */ + ACPI_SERIAL_BEGIN(cmbat); + sc = device_get_softc(dev); + if (sc == NULL) { + ACPI_SERIAL_END(cmbat); return; + } - if (!acpi_BatteryIsPresent(dev)) + if (!acpi_BatteryIsPresent(dev) || !device_is_attached(dev)) { + ACPI_SERIAL_END(cmbat); continue; + } /* * Only query the battery if this is the first try or the specific * type of info is still invalid. */ - ACPI_SERIAL_BEGIN(cmbat); if (retry == 0 || !acpi_battery_bst_valid(&sc->bst)) { timespecclear(&sc->bst_lastupdated); acpi_cmbat_get_bst(dev); From owner-svn-src-all@freebsd.org Tue Mar 14 15:59:52 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id ED5F7D0C940; Tue, 14 Mar 2017 15:59:52 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A0BCF7CC; Tue, 14 Mar 2017 15:59:52 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EFxp1C018133; Tue, 14 Mar 2017 15:59:51 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EFxp2G018127; Tue, 14 Mar 2017 15:59:51 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141559.v2EFxp2G018127@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 15:59:51 +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: r315267 - in stable/11/sys: kern sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 15:59:53 -0000 Author: hselasky Date: Tue Mar 14 15:59:51 2017 New Revision: 315267 URL: https://svnweb.freebsd.org/changeset/base/315267 Log: MFC r314553: Implement taskqueue_poll_is_busy() for use by the LinuxKPI. Refer to comment above function for a detailed description. Discussed with: kib @ Sponsored by: Mellanox Technologies Modified: stable/11/sys/kern/subr_taskqueue.c stable/11/sys/sys/taskqueue.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/subr_taskqueue.c ============================================================================== --- stable/11/sys/kern/subr_taskqueue.c Tue Mar 14 15:58:01 2017 (r315266) +++ stable/11/sys/kern/subr_taskqueue.c Tue Mar 14 15:59:51 2017 (r315267) @@ -487,6 +487,23 @@ task_is_running(struct taskqueue *queue, return (0); } +/* + * Only use this function in single threaded contexts. It returns + * non-zero if the given task is either pending or running. Else the + * task is idle and can be queued again or freed. + */ +int +taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task) +{ + int retval; + + TQ_LOCK(queue); + retval = task->ta_pending > 0 || task_is_running(queue, task); + TQ_UNLOCK(queue); + + return (retval); +} + static int taskqueue_cancel_locked(struct taskqueue *queue, struct task *task, u_int *pendp) Modified: stable/11/sys/sys/taskqueue.h ============================================================================== --- stable/11/sys/sys/taskqueue.h Tue Mar 14 15:58:01 2017 (r315266) +++ stable/11/sys/sys/taskqueue.h Tue Mar 14 15:59:51 2017 (r315267) @@ -79,6 +79,7 @@ int taskqueue_start_threads_cpuset(struc int taskqueue_enqueue(struct taskqueue *queue, struct task *task); int taskqueue_enqueue_timeout(struct taskqueue *queue, struct timeout_task *timeout_task, int ticks); +int taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task); int taskqueue_cancel(struct taskqueue *queue, struct task *task, u_int *pendp); int taskqueue_cancel_timeout(struct taskqueue *queue, From owner-svn-src-all@freebsd.org Tue Mar 14 16:00:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EF9FFD0C9B8; Tue, 14 Mar 2017 16:00:34 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A10DC913; Tue, 14 Mar 2017 16:00:34 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EG0Xhr018311; Tue, 14 Mar 2017 16:00:33 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EG0XBl018309; Tue, 14 Mar 2017 16:00:33 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141600.v2EG0XBl018309@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 16:00:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315268 - in stable/10/sys: kern sys X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:00:35 -0000 Author: hselasky Date: Tue Mar 14 16:00:33 2017 New Revision: 315268 URL: https://svnweb.freebsd.org/changeset/base/315268 Log: MFC r314553: Implement taskqueue_poll_is_busy() for use by the LinuxKPI. Refer to comment above function for a detailed description. Discussed with: kib @ Sponsored by: Mellanox Technologies Modified: stable/10/sys/kern/subr_taskqueue.c stable/10/sys/sys/taskqueue.h Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/kern/subr_taskqueue.c ============================================================================== --- stable/10/sys/kern/subr_taskqueue.c Tue Mar 14 15:59:51 2017 (r315267) +++ stable/10/sys/kern/subr_taskqueue.c Tue Mar 14 16:00:33 2017 (r315268) @@ -390,6 +390,23 @@ task_is_running(struct taskqueue *queue, return (0); } +/* + * Only use this function in single threaded contexts. It returns + * non-zero if the given task is either pending or running. Else the + * task is idle and can be queued again or freed. + */ +int +taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task) +{ + int retval; + + TQ_LOCK(queue); + retval = task->ta_pending > 0 || task_is_running(queue, task); + TQ_UNLOCK(queue); + + return (retval); +} + static int taskqueue_cancel_locked(struct taskqueue *queue, struct task *task, u_int *pendp) Modified: stable/10/sys/sys/taskqueue.h ============================================================================== --- stable/10/sys/sys/taskqueue.h Tue Mar 14 15:59:51 2017 (r315267) +++ stable/10/sys/sys/taskqueue.h Tue Mar 14 16:00:33 2017 (r315268) @@ -74,6 +74,7 @@ int taskqueue_start_threads(struct taskq int taskqueue_enqueue(struct taskqueue *queue, struct task *task); int taskqueue_enqueue_timeout(struct taskqueue *queue, struct timeout_task *timeout_task, int ticks); +int taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task); int taskqueue_cancel(struct taskqueue *queue, struct task *task, u_int *pendp); int taskqueue_cancel_timeout(struct taskqueue *queue, From owner-svn-src-all@freebsd.org Tue Mar 14 16:01:38 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 07D32D0CB90; Tue, 14 Mar 2017 16:01:38 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B03CCCB8; Tue, 14 Mar 2017 16:01:37 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EG1ac3021944; Tue, 14 Mar 2017 16:01:36 GMT (envelope-from hselasky@FreeBSD.org) Received: (from hselasky@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EG1ape021942; Tue, 14 Mar 2017 16:01:36 GMT (envelope-from hselasky@FreeBSD.org) Message-Id: <201703141601.v2EG1ape021942@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: hselasky set sender to hselasky@FreeBSD.org using -f From: Hans Petter Selasky Date: Tue, 14 Mar 2017 16:01:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r315269 - in stable/9/sys: kern sys X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:01:38 -0000 Author: hselasky Date: Tue Mar 14 16:01:36 2017 New Revision: 315269 URL: https://svnweb.freebsd.org/changeset/base/315269 Log: MFC r314553: Implement taskqueue_poll_is_busy() for use by the LinuxKPI. Refer to comment above function for a detailed description. Discussed with: kib @ Sponsored by: Mellanox Technologies Modified: stable/9/sys/kern/subr_taskqueue.c stable/9/sys/sys/taskqueue.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/sys/ (props changed) Modified: stable/9/sys/kern/subr_taskqueue.c ============================================================================== --- stable/9/sys/kern/subr_taskqueue.c Tue Mar 14 16:00:33 2017 (r315268) +++ stable/9/sys/kern/subr_taskqueue.c Tue Mar 14 16:01:36 2017 (r315269) @@ -356,6 +356,23 @@ task_is_running(struct taskqueue *queue, return (0); } +/* + * Only use this function in single threaded contexts. It returns + * non-zero if the given task is either pending or running. Else the + * task is idle and can be queued again or freed. + */ +int +taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task) +{ + int retval; + + TQ_LOCK(queue); + retval = task->ta_pending > 0 || task_is_running(queue, task); + TQ_UNLOCK(queue); + + return (retval); +} + static int taskqueue_cancel_locked(struct taskqueue *queue, struct task *task, u_int *pendp) Modified: stable/9/sys/sys/taskqueue.h ============================================================================== --- stable/9/sys/sys/taskqueue.h Tue Mar 14 16:00:33 2017 (r315268) +++ stable/9/sys/sys/taskqueue.h Tue Mar 14 16:01:36 2017 (r315269) @@ -64,6 +64,7 @@ int taskqueue_start_threads(struct taskq int taskqueue_enqueue(struct taskqueue *queue, struct task *task); int taskqueue_enqueue_timeout(struct taskqueue *queue, struct timeout_task *timeout_task, int ticks); +int taskqueue_poll_is_busy(struct taskqueue *queue, struct task *task); int taskqueue_cancel(struct taskqueue *queue, struct task *task, u_int *pendp); int taskqueue_cancel_timeout(struct taskqueue *queue, From owner-svn-src-all@freebsd.org Tue Mar 14 16:06:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CA0E4D0CC77; Tue, 14 Mar 2017 16:06:58 +0000 (UTC) (envelope-from fabient@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 8ABA6F9C; Tue, 14 Mar 2017 16:06:58 +0000 (UTC) (envelope-from fabient@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EG6vaH022436; Tue, 14 Mar 2017 16:06:57 GMT (envelope-from fabient@FreeBSD.org) Received: (from fabient@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EG6vDf022435; Tue, 14 Mar 2017 16:06:57 GMT (envelope-from fabient@FreeBSD.org) Message-Id: <201703141606.v2EG6vDf022435@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: fabient set sender to fabient@FreeBSD.org using -f From: Fabien Thomas Date: Tue, 14 Mar 2017 16:06:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315270 - in head/sys: arm/include dev/hwpmc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:06:58 -0000 Author: fabient Date: Tue Mar 14 16:06:57 2017 New Revision: 315270 URL: https://svnweb.freebsd.org/changeset/base/315270 Log: Fix arm stack frame walking support: - Adjust stack offset for Clang - Correctly fill registers for fake stack frame (soft PMC) MFC after: 1 week Sponsored by: Stormshield Differential Revision: https://reviews.freebsd.org/D7396 Modified: head/sys/arm/include/pmc_mdep.h head/sys/dev/hwpmc/hwpmc_arm.c Modified: head/sys/arm/include/pmc_mdep.h ============================================================================== --- head/sys/arm/include/pmc_mdep.h Tue Mar 14 16:01:36 2017 (r315269) +++ head/sys/arm/include/pmc_mdep.h Tue Mar 14 16:06:57 2017 (r315270) @@ -70,7 +70,9 @@ union pmc_md_pmc { /* Build a fake kernel trapframe from current instruction pointer. */ #define PMC_FAKE_TRAPFRAME(TF) \ do { \ + (TF)->tf_spsr = PSR_SVC32_MODE; \ __asm __volatile("mov %0, pc" : "=r" ((TF)->tf_pc)); \ + __asm __volatile("mov %0, r11" : "=r" ((TF)->tf_r11)); \ } while (0) /* Modified: head/sys/dev/hwpmc/hwpmc_arm.c ============================================================================== --- head/sys/dev/hwpmc/hwpmc_arm.c Tue Mar 14 16:01:36 2017 (r315269) +++ head/sys/dev/hwpmc/hwpmc_arm.c Tue Mar 14 16:06:57 2017 (r315270) @@ -42,6 +42,17 @@ __FBSDID("$FreeBSD$"); #include #include +/* XXX: Userland code compiled with gcc will need an heuristic + * to be correctly detected. + */ +#ifdef __clang__ +#define PC_OFF 1 +#define FP_OFF 0 +#else +#define PC_OFF -1 +#define FP_OFF -3 +#endif + struct pmc_mdep * pmc_md_initialize() { @@ -100,7 +111,7 @@ pmc_save_kernel_callchain(uintptr_t *cc, for (count = 1; count < maxsamples; count++) { /* Use saved lr as pc. */ - r = fp - sizeof(uintptr_t); + r = fp + PC_OFF * sizeof(uintptr_t); if (!PMC_IN_KERNEL_STACK(r, stackstart, stackend)) break; pc = *(uintptr_t *)r; @@ -110,7 +121,7 @@ pmc_save_kernel_callchain(uintptr_t *cc, *cc++ = pc; /* Switch to next frame up */ - r = fp - 3 * sizeof(uintptr_t); + r = fp + FP_OFF * sizeof(uintptr_t); if (!PMC_IN_KERNEL_STACK(r, stackstart, stackend)) break; fp = *(uintptr_t *)r; @@ -147,7 +158,7 @@ pmc_save_user_callchain(uintptr_t *cc, i for (count = 1; count < maxsamples; count++) { /* Use saved lr as pc. */ - r = fp - sizeof(uintptr_t); + r = fp + PC_OFF * sizeof(uintptr_t); if (copyin((void *)r, &pc, sizeof(pc)) != 0) break; if (!PMC_IN_USERSPACE(pc)) @@ -157,7 +168,7 @@ pmc_save_user_callchain(uintptr_t *cc, i /* Switch to next frame up */ oldfp = fp; - r = fp - 3 * sizeof(uintptr_t); + r = fp + FP_OFF * sizeof(uintptr_t); if (copyin((void *)r, &fp, sizeof(fp)) != 0) break; if (fp < oldfp || !PMC_IN_USERSPACE(fp)) From owner-svn-src-all@freebsd.org Tue Mar 14 16:25:51 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B1861D0C25C; Tue, 14 Mar 2017 16:25:51 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp004.me.com (mr11p00im-asmtp004.me.com [17.110.69.135]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9784C1C95; Tue, 14 Mar 2017 16:25:51 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp004.me.com by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OMT00C00BEF1J00@mr11p00im-asmtp004.me.com>; Tue, 14 Mar 2017 16:25:35 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1489508735; bh=4Ve47TK45GGt15559BFHgzh5qWVfw59ttbLmdV4yEqg=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=DU2cWfC1OI6wbzbZBLi5HsLjijgLrXWHI/o9w+T7M7m+EDvi79HbrdgA5azmNU3LJ Nu0Xg/jUsx0OcTH0QCrwHN6fLHJz61C5tFjI2o0AxGpp+mNGp1hTqxLnIRhR1LLvIS IJJT4uzxDKDJCVmblpt16zeOUO1psh0TDlxF+vXgDaz9E2a2/V/y8vnYOF++VobCQG E8ZleMsDUIDt/Xeu0X7NDhR5y411PP7z3zQBT2Vof0WschN7OzL3+WMMeb/J5NjsM0 AHAgkostlsuUOagxUmyhJxtHS5148sZ7MuyO9JgEUSQxUjY2lmyBLs7KiX1kxMfay2 hNqyjcCk9jQ6g== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp004.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OMT00JYQCALGA30@mr11p00im-asmtp004.me.com>; Tue, 14 Mar 2017 16:25:34 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-03-14_08:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1703140127 User-Agent: Microsoft-MacOutlook/f.1f.0.170216 Date: Tue, 14 Mar 2017 09:25:32 -0700 Subject: Re: svn commit: r315245 - head/sys/net From: Ravi Pokala Sender: "Pokala, Ravi" To: Sean Bruno , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-id: <48897A80-CB0A-425E-8AA7-C1DD7FCFB566@panasas.com> Thread-topic: svn commit: r315245 - head/sys/net References: <201703141508.v2EF8vLk095221@repo.freebsd.org> In-reply-to: <201703141508.v2EF8vLk095221@repo.freebsd.org> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:25:51 -0000 Hi Sean, A few MIPS (XLPN32, XLRN32), and PowerPC (MPC85XX, MPC85XXSPE) configs are still broken: --- iflib.o --- cc1: warnings being treated as errors /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c: In function 'calc_next_rxd': /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2280: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2280: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c: In function 'calc_next_txd': /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2990: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2990: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] *** [iflib.o] Error code 1 Thanks, Ravi (rpokala@) -----Original Message----- From: on behalf of Sean Bruno Date: 2017-03-14, Tuesday at 08:08 To: , , Subject: svn commit: r315245 - head/sys/net Author: sbruno Date: Tue Mar 14 15:08:56 2017 New Revision: 315245 URL: https://svnweb.freebsd.org/changeset/base/315245 Log: Fixup LINT by using uint64_t type as we do on all other calls to PNMB() Found with Jenkins. Reported by: lwshu Sponsored by: Limelight Networks Modified: head/sys/net/iflib.c Modified: head/sys/net/iflib.c ============================================================================== --- head/sys/net/iflib.c Tue Mar 14 14:02:47 2017 (r315244) +++ head/sys/net/iflib.c Tue Mar 14 15:08:56 2017 (r315245) @@ -860,7 +860,7 @@ iflib_netmap_txsync(struct netmap_kring for (n = 0; nm_i != head; n++) { struct netmap_slot *slot = &ring->slot[nm_i]; u_int len = slot->len; - vm_paddr_t paddr; + uint64_t paddr; void *addr = PNMB(na, slot, &paddr); int flags = (slot->flags & NS_REPORT || nic_i == 0 || nic_i == report_frequency) ? From owner-svn-src-all@freebsd.org Tue Mar 14 16:40:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E2AF1D0C5ED; Tue, 14 Mar 2017 16:40:19 +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 AFA12645; Tue, 14 Mar 2017 16:40:19 +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 v2EGeIAY035216; Tue, 14 Mar 2017 16:40:18 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EGeIG6035215; Tue, 14 Mar 2017 16:40:18 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703141640.v2EGeIG6035215@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Tue, 14 Mar 2017 16:40:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315271 - head/usr.sbin/makefs/ffs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:40:20 -0000 Author: emaste Date: Tue Mar 14 16:40:18 2017 New Revision: 315271 URL: https://svnweb.freebsd.org/changeset/base/315271 Log: makefs: remove unused variable NetBSD revisions: mkfs.c 1.32 Obtained from: NetBSD Modified: head/usr.sbin/makefs/ffs/mkfs.c Modified: head/usr.sbin/makefs/ffs/mkfs.c ============================================================================== --- head/usr.sbin/makefs/ffs/mkfs.c Tue Mar 14 16:06:57 2017 (r315270) +++ head/usr.sbin/makefs/ffs/mkfs.c Tue Mar 14 16:40:18 2017 (r315271) @@ -119,7 +119,7 @@ ffs_mkfs(const char *fsys, const fsinfo_ int32_t cylno, i, csfrags; long long sizepb; void *space; - int size, blks; + int size; int nprintcols, printcolwidth; ffs_opt_t *ffs_opts = fsopts->fs_specific; @@ -400,7 +400,6 @@ ffs_mkfs(const char *fsys, const fsinfo_ * Cribbed from ffs_mountfs(). */ size = sblock.fs_cssize; - blks = howmany(size, sblock.fs_fsize); if (sblock.fs_contigsumsize > 0) size += sblock.fs_ncg * sizeof(int32_t); if ((space = (char *)calloc(1, size)) == NULL) From owner-svn-src-all@freebsd.org Tue Mar 14 16:43:29 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1B3C8D0C7F6; Tue, 14 Mar 2017 16:43:29 +0000 (UTC) (envelope-from sbruno@freebsd.org) Received: from mail.ignoranthack.me (ignoranthack.me [199.102.79.106]) (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 E06BFCC1; Tue, 14 Mar 2017 16:43:28 +0000 (UTC) (envelope-from sbruno@freebsd.org) Received: from [192.168.0.6] (75-173-99-247.albq.qwest.net [75.173.99.247]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: sbruno@ignoranthack.me) by mail.ignoranthack.me (Postfix) with ESMTPSA id 5F5521928BA; Tue, 14 Mar 2017 16:43:25 +0000 (UTC) Subject: Re: svn commit: r315245 - head/sys/net To: Ravi Pokala , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201703141508.v2EF8vLk095221@repo.freebsd.org> <48897A80-CB0A-425E-8AA7-C1DD7FCFB566@panasas.com> From: Sean Bruno Message-ID: Date: Tue, 14 Mar 2017 10:43:22 -0600 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <48897A80-CB0A-425E-8AA7-C1DD7FCFB566@panasas.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="cWXfFKsTwERS3Wo7msHNa1gM9kc0r3PTn" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 16:43:29 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --cWXfFKsTwERS3Wo7msHNa1gM9kc0r3PTn Content-Type: multipart/mixed; boundary="tcCqRDAvUUOluaWctRrppcQD8mHnUUhCR"; protected-headers="v1" From: Sean Bruno To: Ravi Pokala , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-ID: Subject: Re: svn commit: r315245 - head/sys/net References: <201703141508.v2EF8vLk095221@repo.freebsd.org> <48897A80-CB0A-425E-8AA7-C1DD7FCFB566@panasas.com> In-Reply-To: <48897A80-CB0A-425E-8AA7-C1DD7FCFB566@panasas.com> --tcCqRDAvUUOluaWctRrppcQD8mHnUUhCR Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 03/14/17 10:25, Ravi Pokala wrote: > Hi Sean, >=20 > A few MIPS (XLPN32, XLRN32), and PowerPC (MPC85XX, MPC85XXSPE) configs = are still broken: >=20 > --- iflib.o --- > cc1: warnings being treated as errors > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c: In funct= ion 'calc_next_rxd': > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2280: war= ning: cast from pointer to integer of different size [-Wpointer-to-int-ca= st] > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2280: war= ning: cast to pointer from integer of different size [-Wint-to-pointer-ca= st] > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c: In funct= ion 'calc_next_txd': > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2990: war= ning: cast from pointer to integer of different size [-Wpointer-to-int-ca= st] > /usr/home/rpokala/freebsd/clean/base/head/sys/net/iflib.c:2990: war= ning: cast to pointer from integer of different size [-Wint-to-pointer-ca= st] > *** [iflib.o] Error code 1 >=20 > Thanks, >=20 > Ravi (rpokala@) >=20 Hrm. Ok. Will fixup directly. sean > -----Original Message----- > From: on behalf of Sean Bruno > Date: 2017-03-14, Tuesday at 08:08 > To: , , > Subject: svn commit: r315245 - head/sys/net >=20 > Author: sbruno > Date: Tue Mar 14 15:08:56 2017 > New Revision: 315245 > URL: https://svnweb.freebsd.org/changeset/base/315245 >=20 > Log: > Fixup LINT by using uint64_t type as we do on all other calls to PNMB= () > =20 > Found with Jenkins. > =20 > Reported by: lwshu > Sponsored by: Limelight Networks >=20 > Modified: > head/sys/net/iflib.c >=20 > Modified: head/sys/net/iflib.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/net/iflib.c Tue Mar 14 14:02:47 2017 (r315244) > +++ head/sys/net/iflib.c Tue Mar 14 15:08:56 2017 (r315245) > @@ -860,7 +860,7 @@ iflib_netmap_txsync(struct netmap_kring=20 > for (n =3D 0; nm_i !=3D head; n++) { > struct netmap_slot *slot =3D &ring->slot[nm_i]; > u_int len =3D slot->len; > - vm_paddr_t paddr; > + uint64_t paddr; > void *addr =3D PNMB(na, slot, &paddr); > int flags =3D (slot->flags & NS_REPORT || > nic_i =3D=3D 0 || nic_i =3D=3D report_frequency) ? >=20 >=20 >=20 >=20 >=20 --tcCqRDAvUUOluaWctRrppcQD8mHnUUhCR-- --cWXfFKsTwERS3Wo7msHNa1gM9kc0r3PTn Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQGTBAEBCgB9FiEEuq1GMucSHejSCZfdEgHvyh5yfmQFAljIHa1fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEJB QUQ0NjMyRTcxMjFERThEMjA5OTdERDEyMDFFRkNBMUU3MjdFNjQACgkQEgHvyh5y fmSSLwgAvmII3FbzPzdr2SGVHrvEO3oMpZz8T6j4pY8r2dlIvxWFofdZz8fAikVF TOK1RoeLiPUlCx+olcjlwi6zsE47eLEqmKB2J35/2g2dhmLgsCaUEGqN/vzXBUBx 7m44T58VNZlYyLtQkDz3f7v8Gu+BC9wYkGJmYE+WGMivSHqd/9Zk/dlVoU6soHna f6e1VSribVgCxuD8h2QpoIEnl1yeyxgU2Fh0fSTFy1sZYG8Qvzht5kWnw+UobhAe BoEi/Rj/F024ORxceGThcLACJ6OwGibKug8eZAS42XuS0vBDVZEoIowDCRq3lvTJ FK46546n898fLDTbgCQe/7xJ6SofEA== =Op/1 -----END PGP SIGNATURE----- --cWXfFKsTwERS3Wo7msHNa1gM9kc0r3PTn-- From owner-svn-src-all@freebsd.org Tue Mar 14 17:10:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 26AD9D0C1C2; Tue, 14 Mar 2017 17:10:44 +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 F2ECC1BB4; Tue, 14 Mar 2017 17:10:43 +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 v2EHAhF4047603; Tue, 14 Mar 2017 17:10:43 GMT (envelope-from delphij@FreeBSD.org) Received: (from delphij@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EHAgxB047599; Tue, 14 Mar 2017 17:10:42 GMT (envelope-from delphij@FreeBSD.org) Message-Id: <201703141710.v2EHAgxB047599@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: delphij set sender to delphij@FreeBSD.org using -f From: Xin LI Date: Tue, 14 Mar 2017 17:10:42 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315272 - in head: lib/libc/sys sys/sys sys/vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 17:10:44 -0000 Author: delphij Date: Tue Mar 14 17:10:42 2017 New Revision: 315272 URL: https://svnweb.freebsd.org/changeset/base/315272 Log: Implement INHERIT_ZERO for minherit(2). INHERIT_ZERO is an OpenBSD feature. When a page is marked as such, it would be zeroed upon fork(). This would be used in new arc4random(3) functions. PR: 182610 Reviewed by: kib (earlier version) MFC after: 1 month Differential Revision: https://reviews.freebsd.org/D427 Modified: head/lib/libc/sys/minherit.2 head/sys/sys/mman.h head/sys/vm/vm.h head/sys/vm/vm_map.c Modified: head/lib/libc/sys/minherit.2 ============================================================================== --- head/lib/libc/sys/minherit.2 Tue Mar 14 16:40:18 2017 (r315271) +++ head/lib/libc/sys/minherit.2 Tue Mar 14 17:10:42 2017 (r315272) @@ -29,7 +29,7 @@ .\" .\" @(#)minherit.2 8.1 (Berkeley) 6/9/93 .\" -.Dd October 30, 2007 +.Dd March 15, 2017 .Dt MINHERIT 2 .Os .Sh NAME @@ -91,6 +91,11 @@ it will no longer be shared in the paren after the parent forks and there is no way to get the previous shared-backing-store mapping without unmapping and remapping the address space in the parent. +.It Dv INHERIT_ZERO +This option causes the address space in question to be mapped as new +anonymous pages, +which would be initialized to all zero bytes, +in the child process. .El .Sh RETURN VALUES .Rv -std minherit @@ -130,6 +135,13 @@ system call first appeared in .Ox and then in .Fx 2.2 . +.Pp +The +.Dv INHERIT_ZERO +support first appeared in +.Ox 5.6 +and then in +.Fx 12.0 . .Sh BUGS Once you set inheritance to .Dv MAP_PRIVATE Modified: head/sys/sys/mman.h ============================================================================== --- head/sys/sys/mman.h Tue Mar 14 16:40:18 2017 (r315271) +++ head/sys/sys/mman.h Tue Mar 14 17:10:42 2017 (r315272) @@ -43,6 +43,7 @@ #define INHERIT_SHARE 0 #define INHERIT_COPY 1 #define INHERIT_NONE 2 +#define INHERIT_ZERO 3 #endif /* Modified: head/sys/vm/vm.h ============================================================================== --- head/sys/vm/vm.h Tue Mar 14 16:40:18 2017 (r315271) +++ head/sys/vm/vm.h Tue Mar 14 17:10:42 2017 (r315272) @@ -68,6 +68,7 @@ typedef char vm_inherit_t; /* inheritanc #define VM_INHERIT_SHARE ((vm_inherit_t) 0) #define VM_INHERIT_COPY ((vm_inherit_t) 1) #define VM_INHERIT_NONE ((vm_inherit_t) 2) +#define VM_INHERIT_ZERO ((vm_inherit_t) 3) #define VM_INHERIT_DEFAULT VM_INHERIT_COPY typedef u_char vm_prot_t; /* protection codes */ Modified: head/sys/vm/vm_map.c ============================================================================== --- head/sys/vm/vm_map.c Tue Mar 14 16:40:18 2017 (r315271) +++ head/sys/vm/vm_map.c Tue Mar 14 17:10:42 2017 (r315272) @@ -2285,6 +2285,7 @@ vm_map_inherit(vm_map_t map, vm_offset_t case VM_INHERIT_NONE: case VM_INHERIT_COPY: case VM_INHERIT_SHARE: + case VM_INHERIT_ZERO: break; default: return (KERN_INVALID_ARGUMENT); @@ -3443,6 +3444,36 @@ vmspace_fork(struct vmspace *vm1, vm_oof vm_map_copy_entry(old_map, new_map, old_entry, new_entry, fork_charge); break; + + case VM_INHERIT_ZERO: + /* + * Create a new anonymous mapping entry modelled from + * the old one. + */ + new_entry = vm_map_entry_create(new_map); + memset(new_entry, 0, sizeof(*new_entry)); + + new_entry->start = old_entry->start; + new_entry->end = old_entry->end; + new_entry->avail_ssize = old_entry->avail_ssize; + new_entry->adj_free = old_entry->adj_free; + new_entry->max_free = old_entry->max_free; + new_entry->eflags = old_entry->eflags & + ~(MAP_ENTRY_USER_WIRED | MAP_ENTRY_IN_TRANSITION | + MAP_ENTRY_VN_WRITECNT); + new_entry->protection = old_entry->protection; + new_entry->max_protection = old_entry->max_protection; + new_entry->inheritance = VM_INHERIT_ZERO; + + vm_map_entry_link(new_map, new_map->header.prev, + new_entry); + vmspace_map_entry_forked(vm1, vm2, new_entry); + + new_entry->cred = curthread->td_ucred; + crhold(new_entry->cred); + *fork_charge += (new_entry->end - new_entry->start); + + break; } old_entry = old_entry->next; } From owner-svn-src-all@freebsd.org Tue Mar 14 17:34:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4D6B8D0C754; Tue, 14 Mar 2017 17:34:46 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0E649CE8; Tue, 14 Mar 2017 17:34:45 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EHYjCx059794; Tue, 14 Mar 2017 17:34:45 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EHYir0059790; Tue, 14 Mar 2017 17:34:44 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703141734.v2EHYir0059790@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 17:34:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315273 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 17:34:46 -0000 Author: mav Date: Tue Mar 14 17:34:44 2017 New Revision: 315273 URL: https://svnweb.freebsd.org/changeset/base/315273 Log: Remove tangled isp_mbox_continue() mechanism. It was implemented to reduce context switches when uploading firmware to card's RAM. But this mechanism is not used last 10 years since all mbox operations are now polled, and it was never used for cards produced in last 15 years. Newer cards can use DMA to upload firmware. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h head/sys/dev/isp/ispvar.h Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Tue Mar 14 17:10:42 2017 (r315272) +++ head/sys/dev/isp/isp.c Tue Mar 14 17:34:44 2017 (r315273) @@ -101,7 +101,6 @@ static int isp_handle_other_response(isp static void isp_parse_status(ispsoftc_t *, ispstatusreq_t *, XS_T *, long *); static void isp_parse_status_24xx(ispsoftc_t *, isp24xx_statusreq_t *, XS_T *, long *); static void isp_fastpost_complete(ispsoftc_t *, uint32_t); -static int isp_mbox_continue(ispsoftc_t *); static void isp_scsi_init(ispsoftc_t *); static void isp_scsi_channel_init(ispsoftc_t *, int); static void isp_fibre_init(ispsoftc_t *); @@ -130,7 +129,6 @@ static int isp_register_port_name_24xx(i static int isp_register_node_name_24xx(ispsoftc_t *, int); static uint16_t isp_next_handle(ispsoftc_t *, uint16_t *); static int isp_fw_state(ispsoftc_t *, int); -static void isp_mboxcmd_qnw(ispsoftc_t *, mbreg_t *, int); static void isp_mboxcmd(ispsoftc_t *, mbreg_t *); static void isp_spi_update(ispsoftc_t *, int); @@ -734,87 +732,47 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_loaded_fw = 0; if (dodnld && IS_24XX(isp)) { const uint32_t *ptr = isp->isp_mdvec->dv_ispfw; - int wordload; + uint32_t la, wi, wl; /* * Keep loading until we run out of f/w. */ code_org = ptr[2]; /* 1st load address is our start addr */ - wordload = 0; for (;;) { - uint32_t la, wi, wl; isp_prt(isp, ISP_LOGDEBUG0, "load 0x%x words of code at load address 0x%x", ptr[3], ptr[2]); wi = 0; la = ptr[2]; wl = ptr[3]; - while (wi < ptr[3]) { uint32_t *cp; uint32_t nw; - nw = ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)) >> 2; - if (nw > wl) { - nw = wl; - } + nw = min(wl, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)) / 4); cp = isp->isp_rquest; - for (i = 0; i < nw; i++) { - ISP_IOXPUT_32(isp, ptr[wi++], &cp[i]); - wl--; - } + for (i = 0; i < nw; i++) + ISP_IOXPUT_32(isp, ptr[wi + i], &cp[i]); MEMORYBARRIER(isp, SYNC_REQUEST, 0, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)), -1); - again: - MBSINIT(&mbs, 0, MBLOGALL, 0); - if (la < 0x10000 && nw < 0x10000) { - mbs.param[0] = MBOX_LOAD_RISC_RAM_2100; - mbs.param[1] = la; - mbs.param[2] = DMA_WD1(isp->isp_rquest_dma); - mbs.param[3] = DMA_WD0(isp->isp_rquest_dma); - mbs.param[4] = nw; - mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); - mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); - isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM 2100 %u words at load address 0x%x", nw, la); - } else if (wordload) { - union { - const uint32_t *cp; - uint32_t *np; - } ucd; - ucd.cp = (const uint32_t *)cp; - mbs.param[0] = MBOX_WRITE_RAM_WORD_EXTENDED; - mbs.param[1] = la; - mbs.param[2] = (*ucd.np); - mbs.param[3] = (*ucd.np) >> 16; - mbs.param[8] = la >> 16; - isp->isp_mbxwrk0 = nw - 1; - isp->isp_mbxworkp = ucd.np+1; - isp->isp_mbxwrk1 = (la + 1); - isp->isp_mbxwrk8 = (la + 1) >> 16; - isp_prt(isp, ISP_LOGDEBUG0, "WRITE RAM WORD EXTENDED %u words at load address 0x%x", nw, la); - } else { - mbs.param[0] = MBOX_LOAD_RISC_RAM; - mbs.param[1] = la; - mbs.param[2] = DMA_WD1(isp->isp_rquest_dma); - mbs.param[3] = DMA_WD0(isp->isp_rquest_dma); - mbs.param[4] = nw >> 16; - mbs.param[5] = nw; - mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); - mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); - mbs.param[8] = la >> 16; - isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM %u words at load address 0x%x", nw, la); - } + MBSINIT(&mbs, MBOX_LOAD_RISC_RAM, MBLOGALL, 0); + mbs.param[1] = la; + mbs.param[2] = DMA_WD1(isp->isp_rquest_dma); + mbs.param[3] = DMA_WD0(isp->isp_rquest_dma); + mbs.param[4] = nw >> 16; + mbs.param[5] = nw; + mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); + mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); + mbs.param[8] = la >> 16; + isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM %u words at load address 0x%x", nw, la); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - if (mbs.param[0] == MBOX_HOST_INTERFACE_ERROR) { - isp_prt(isp, ISP_LOGERR, "switching to word load"); - wordload = 1; - goto again; - } - isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); + isp_prt(isp, ISP_LOGERR, "F/W download failed"); return; } la += nw; + wi += nw; + wl -= nw; } if (ptr[1] == 0) { @@ -843,18 +801,10 @@ isp_reset(ispsoftc_t *isp, int do_load_d uint16_t *cp; uint16_t nw; - nw = ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)) >> 1; - if (nw > wl) { - nw = wl; - } - if (nw > (1 << 15)) { - nw = 1 << 15; - } + nw = min(wl, min((1 << 15), ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)) / 2)); cp = isp->isp_rquest; - for (i = 0; i < nw; i++) { - ISP_IOXPUT_16(isp, ptr[wi++], &cp[i]); - wl--; - } + for (i = 0; i < nw; i++) + ISP_IOXPUT_16(isp, ptr[wi + i], &cp[i]); MEMORYBARRIER(isp, SYNC_REQUEST, 0, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)), -1); MBSINIT(&mbs, 0, MBLOGALL, 0); if (la < 0x10000) { @@ -879,10 +829,12 @@ isp_reset(ispsoftc_t *isp, int do_load_d } isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); + isp_prt(isp, ISP_LOGERR, "F/W download failed"); return; } la += nw; + wi += nw; + wl -= nw; } if (!IS_2322(isp)) { @@ -907,22 +859,22 @@ isp_reset(ispsoftc_t *isp, int do_load_d } isp->isp_loaded_fw = 1; } else if (dodnld) { - union { - const uint16_t *cp; - uint16_t *np; - } ucd; - ucd.cp = isp->isp_mdvec->dv_ispfw; - isp->isp_mbxworkp = &ucd.np[1]; - isp->isp_mbxwrk0 = ucd.np[3] - 1; - isp->isp_mbxwrk1 = code_org + 1; - MBSINIT(&mbs, MBOX_WRITE_RAM_WORD, MBLOGNONE, 0); - mbs.param[1] = code_org; - mbs.param[2] = ucd.np[0]; - isp_prt(isp, ISP_LOGDEBUG1, "WRITE RAM %u words at load address 0x%x", ucd.np[3], code_org); - isp_mboxcmd(isp, &mbs); - if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - isp_prt(isp, ISP_LOGERR, "F/W download failed at word %d", isp->isp_mbxwrk1 - code_org); - return; + const uint16_t *ptr = isp->isp_mdvec->dv_ispfw; + u_int i, wl; + + wl = ptr[3]; + isp_prt(isp, ISP_LOGDEBUG1, + "WRITE RAM %u words at load address 0x%x", wl, code_org); + for (i = 0; i < wl; i++) { + MBSINIT(&mbs, MBOX_WRITE_RAM_WORD, MBLOGNONE, 0); + mbs.param[1] = code_org + i; + mbs.param[2] = ptr[i]; + isp_mboxcmd(isp, &mbs); + if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { + isp_prt(isp, ISP_LOGERR, + "F/W download failed at word %d", i); + return; + } } } else if (IS_26XX(isp)) { MBSINIT(&mbs, MBOX_LOAD_FLASH_FIRMWARE, MBLOGALL, 5000000); @@ -4993,11 +4945,6 @@ again: } isp->isp_mboxtmp[i] = ISP_READ(isp, MBOX_OFF(i)); } - if (isp->isp_mbxwrk0) { - if (isp_mbox_continue(isp) == 0) { - return; - } - } MBOX_NOTIFY_COMPLETE(isp); } else { isp_prt(isp, ISP_LOGWARN, "mailbox cmd (0x%x) with no waiters", info); @@ -6730,96 +6677,6 @@ isp_fastpost_complete(ispsoftc_t *isp, u isp_done(xs); } -static int -isp_mbox_continue(ispsoftc_t *isp) -{ - mbreg_t mbs; - uint16_t *ptr; - uint32_t offset; - - switch (isp->isp_lastmbxcmd) { - case MBOX_WRITE_RAM_WORD: - case MBOX_READ_RAM_WORD: - case MBOX_WRITE_RAM_WORD_EXTENDED: - case MBOX_READ_RAM_WORD_EXTENDED: - break; - default: - return (1); - } - if (isp->isp_mboxtmp[0] != MBOX_COMMAND_COMPLETE) { - isp->isp_mbxwrk0 = 0; - return (-1); - } - - /* - * Clear the previous interrupt. - */ - if (IS_24XX(isp)) { - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_CLEAR_RISC_INT); - } else { - ISP_WRITE(isp, HCCR, HCCR_CMD_CLEAR_RISC_INT); - ISP_WRITE(isp, BIU_SEMA, 0); - } - - /* - * Continue with next word. - */ - ISP_MEMZERO(&mbs, sizeof (mbs)); - ptr = isp->isp_mbxworkp; - switch (isp->isp_lastmbxcmd) { - case MBOX_WRITE_RAM_WORD: - mbs.param[1] = isp->isp_mbxwrk1++; - mbs.param[2] = *ptr++; - break; - case MBOX_READ_RAM_WORD: - *ptr++ = isp->isp_mboxtmp[2]; - mbs.param[1] = isp->isp_mbxwrk1++; - break; - case MBOX_WRITE_RAM_WORD_EXTENDED: - if (IS_24XX(isp)) { - uint32_t *lptr = (uint32_t *)ptr; - mbs.param[2] = lptr[0]; - mbs.param[3] = lptr[0] >> 16; - lptr++; - ptr = (uint16_t *)lptr; - } else { - mbs.param[2] = *ptr++; - } - offset = isp->isp_mbxwrk1; - offset |= isp->isp_mbxwrk8 << 16; - mbs.param[1] = offset; - mbs.param[8] = offset >> 16; - offset++; - isp->isp_mbxwrk1 = offset; - isp->isp_mbxwrk8 = offset >> 16; - break; - case MBOX_READ_RAM_WORD_EXTENDED: - if (IS_24XX(isp)) { - uint32_t *lptr = (uint32_t *)ptr; - uint32_t val = isp->isp_mboxtmp[2]; - val |= (isp->isp_mboxtmp[3]) << 16; - *lptr++ = val; - ptr = (uint16_t *)lptr; - } else { - *ptr++ = isp->isp_mboxtmp[2]; - } - offset = isp->isp_mbxwrk1; - offset |= isp->isp_mbxwrk8 << 16; - mbs.param[1] = offset; - mbs.param[8] = offset >> 16; - offset++; - isp->isp_mbxwrk1 = offset; - isp->isp_mbxwrk8 = offset >> 16; - break; - } - isp->isp_mbxworkp = ptr; - isp->isp_mbxwrk0--; - mbs.param[0] = isp->isp_lastmbxcmd; - mbs.logval = MBLOGALL; - isp_mboxcmd_qnw(isp, &mbs, 0); - return (0); -} - #define ISP_SCSI_IBITS(op) (mbpscsi[((op)<<1)]) #define ISP_SCSI_OBITS(op) (mbpscsi[((op)<<1) + 1]) #define ISP_SCSI_OPMAP(in, out) in, out @@ -7294,49 +7151,6 @@ static const char *fc_mbcmd_names[] = { }; static void -isp_mboxcmd_qnw(ispsoftc_t *isp, mbreg_t *mbp, int nodelay) -{ - unsigned int ibits, obits, box, opcode; - - opcode = mbp->param[0]; - if (IS_FC(isp)) { - ibits = ISP_FC_IBITS(opcode); - obits = ISP_FC_OBITS(opcode); - } else { - ibits = ISP_SCSI_IBITS(opcode); - obits = ISP_SCSI_OBITS(opcode); - } - ibits |= mbp->ibits; - obits |= mbp->obits; - for (box = 0; box < ISP_NMBOX(isp); box++) { - if (ibits & (1 << box)) { - ISP_WRITE(isp, MBOX_OFF(box), mbp->param[box]); - } - if (nodelay == 0) { - isp->isp_mboxtmp[box] = mbp->param[box] = 0; - } - } - if (nodelay == 0) { - isp->isp_lastmbxcmd = opcode; - isp->isp_obits = obits; - isp->isp_mboxbsy = 1; - } - if (IS_24XX(isp)) { - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_SET_HOST_INT); - } else { - ISP_WRITE(isp, HCCR, HCCR_CMD_SET_HOST_INT); - } - /* - * Oddly enough, if we're not delaying for an answer, - * delay a bit to give the f/w a chance to pick up the - * command. - */ - if (nodelay) { - ISP_DELAY(1000); - } -} - -static void isp_mboxcmd(ispsoftc_t *isp, mbreg_t *mbp) { const char *cname, *xname, *sname; Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Tue Mar 14 17:10:42 2017 (r315272) +++ head/sys/dev/isp/isp_freebsd.c Tue Mar 14 17:34:44 2017 (r315273) @@ -4413,50 +4413,33 @@ isp_mbox_acquire(ispsoftc_t *isp) void isp_mbox_wait_complete(ispsoftc_t *isp, mbreg_t *mbp) { - unsigned int usecs = mbp->timeout; - unsigned int max, olim, ilim; - - if (usecs == 0) { - usecs = MBCMD_DEFAULT_TIMEOUT; - } - max = isp->isp_mbxwrk0 + 1; + u_int t, to; + to = (mbp->timeout == 0) ? MBCMD_DEFAULT_TIMEOUT : mbp->timeout; if (isp->isp_osinfo.mbox_sleep_ok) { - unsigned int ms = (usecs + 999) / 1000; - isp->isp_osinfo.mbox_sleep_ok = 0; isp->isp_osinfo.mbox_sleeping = 1; - for (olim = 0; olim < max; olim++) { - msleep(&isp->isp_mbxworkp, &isp->isp_osinfo.lock, PRIBIO, "ispmbx_sleep", isp_mstohz(ms)); - if (isp->isp_osinfo.mboxcmd_done) { - break; - } - } + msleep_sbt(&isp->isp_osinfo.mboxcmd_done, &isp->isp_osinfo.lock, + PRIBIO, "ispmbx_sleep", to * SBT_1US, 0, 0); isp->isp_osinfo.mbox_sleep_ok = 1; isp->isp_osinfo.mbox_sleeping = 0; } else { - for (olim = 0; olim < max; olim++) { - for (ilim = 0; ilim < usecs; ilim += 100) { - uint16_t isr, sema, info; - if (isp->isp_osinfo.mboxcmd_done) { - break; - } - if (ISP_READ_ISR(isp, &isr, &sema, &info)) { - isp_intr(isp, isr, sema, info); - if (isp->isp_osinfo.mboxcmd_done) { - break; - } - } - ISP_DELAY(100); - } - if (isp->isp_osinfo.mboxcmd_done) { + for (t = 0; t < to; t += 100) { + uint16_t isr, sema, info; + if (isp->isp_osinfo.mboxcmd_done) break; + if (ISP_READ_ISR(isp, &isr, &sema, &info)) { + isp_intr(isp, isr, sema, info); + if (isp->isp_osinfo.mboxcmd_done) + break; } + ISP_DELAY(100); } } if (isp->isp_osinfo.mboxcmd_done == 0) { - isp_prt(isp, ISP_LOGWARN, "%s Mailbox Command (0x%x) Timeout (%uus) (started @ %s:%d)", - isp->isp_osinfo.mbox_sleep_ok? "Interrupting" : "Polled", isp->isp_lastmbxcmd, usecs, mbp->func, mbp->lineno); + isp_prt(isp, ISP_LOGWARN, "%s Mailbox Command (0x%x) Timeout (%uus) (%s:%d)", + isp->isp_osinfo.mbox_sleep_ok? "Interrupting" : "Polled", + isp->isp_lastmbxcmd, to, mbp->func, mbp->lineno); mbp->param[0] = MBOX_TIMEOUT; isp->isp_osinfo.mboxcmd_done = 1; } @@ -4465,10 +4448,9 @@ isp_mbox_wait_complete(ispsoftc_t *isp, void isp_mbox_notify_done(ispsoftc_t *isp) { - if (isp->isp_osinfo.mbox_sleeping) { - wakeup(&isp->isp_mbxworkp); - } isp->isp_osinfo.mboxcmd_done = 1; + if (isp->isp_osinfo.mbox_sleeping) + wakeup(&isp->isp_osinfo.mboxcmd_done); } void Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Tue Mar 14 17:10:42 2017 (r315272) +++ head/sys/dev/isp/isp_freebsd.h Tue Mar 14 17:34:44 2017 (r315273) @@ -308,11 +308,11 @@ struct isposinfo { #endif sixtyfourbit : 1, /* sixtyfour bit platform */ timer_active : 1, - autoconf : 1, - mbox_sleeping : 1, - mbox_sleep_ok : 1, - mboxcmd_done : 1, - mboxbsy : 1; + autoconf : 1; + int mbox_sleeping; + int mbox_sleep_ok; + int mboxbsy; + int mboxcmd_done; struct callout tmo; /* general timer */ Modified: head/sys/dev/isp/ispvar.h ============================================================================== --- head/sys/dev/isp/ispvar.h Tue Mar 14 17:10:42 2017 (r315272) +++ head/sys/dev/isp/ispvar.h Tue Mar 14 17:34:44 2017 (r315273) @@ -575,12 +575,7 @@ struct ispsoftc { volatile uint32_t isp_serno; /* rolling serial number */ volatile uint16_t isp_mboxtmp[MAX_MAILBOX]; volatile uint16_t isp_lastmbxcmd; /* last mbox command sent */ - volatile uint16_t isp_mbxwrk0; - volatile uint16_t isp_mbxwrk1; - volatile uint16_t isp_mbxwrk2; - volatile uint16_t isp_mbxwrk8; volatile uint16_t isp_seqno; /* running sequence number */ - void * isp_mbxworkp; /* * Active commands are stored here, indexed by handle functions. From owner-svn-src-all@freebsd.org Tue Mar 14 17:34:55 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5B318D0C77E; Tue, 14 Mar 2017 17:34:55 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp002.me.com (mr11p00im-asmtp002.me.com [17.110.69.253]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3EC09D4D; Tue, 14 Mar 2017 17:34:55 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp002.me.com by mr11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OMT00A00E1YP300@mr11p00im-asmtp002.me.com>; Tue, 14 Mar 2017 17:34:46 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1489512886; bh=nqfvHEGq/J+5Q844XP8gCTV553bRbNggR3EkdXo886c=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=h9b3D8vYb62bqeXh5z117CJhe919tJ6co2haqeja67hym7ZBBqk9lVDZFz4AZgckp 7r45v82ECc73oq5hrKYp3P9TcmFkwYyrKY026SPVFhYvqHZ/AZAp98twJ+b6r3852S cUYttevldzvdsZDPB6s6ArVJYhIThW/K/vucjT+WmwWd+He4GjoQxYLiOjPDzpq8V4 Rg0hHoY3EFLPNFnm+YXvhr8qccB5PL+aAnUw2L1TEOY/LGM4/cI3Lzc8FuQyK7lIzw O8KAy+UOYgAXQsko23NpoTnNSPgXn37OBOO4u+ROmBO+mnHgpq7LvknJEakgXUuGOh C+x+lm0m4/lqw== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OMT00CU4FHVUD30@mr11p00im-asmtp002.me.com>; Tue, 14 Mar 2017 17:34:44 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-03-14_09:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1703140136 User-Agent: Microsoft-MacOutlook/f.1f.0.170216 Date: Tue, 14 Mar 2017 10:34:42 -0700 Subject: Re: svn commit: r314591 - in stable/11/sys: amd64/amd64 conf i386/i386 modules/mem x86/x86 From: Ravi Pokala Sender: "Pokala, Ravi" To: Konstantin Belousov , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Message-id: <1FC1B5E1-D37F-4719-B282-DE2CFF84CD36@panasas.com> Thread-topic: svn commit: r314591 - in stable/11/sys: amd64/amd64 conf i386/i386 modules/mem x86/x86 References: <201703031030.v23AUVvs015379@repo.freebsd.org> In-reply-to: <201703031030.v23AUVvs015379@repo.freebsd.org> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 17:34:55 -0000 Hi Konstantin, It looks like this broke pc98 in stable/11 (where it is still supported): make[5]: make[5]: don't know how to make /usr/home/rpokala/freebsd/clean/base/stable/11/sys/i386/i386/i686_mem.c. Stop Thanks, Ravi (rpokala@) -----Original Message----- From: on behalf of Konstantin Belousov Date: 2017-03-03, Friday at 02:30 To: , , , Subject: svn commit: r314591 - in stable/11/sys: amd64/amd64 conf i386/i386 modules/mem x86/x86 Author: kib Date: Fri Mar 3 10:30:30 2017 New Revision: 314591 URL: https://svnweb.freebsd.org/changeset/base/314591 Log: MFC r313898, r313902, r313903, r313934, r314087, r314252: Merge i386 and amd64 mtrr drivers. Added: stable/11/sys/x86/x86/x86_mem.c - copied, changed from r313898, head/sys/x86/x86/x86_mem.c Deleted: stable/11/sys/amd64/amd64/amd64_mem.c stable/11/sys/i386/i386/i686_mem.c Modified: stable/11/sys/conf/files.amd64 stable/11/sys/conf/files.i386 stable/11/sys/modules/mem/Makefile Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/conf/files.amd64 ============================================================================== --- stable/11/sys/conf/files.amd64 Fri Mar 3 10:17:16 2017 (r314590) +++ stable/11/sys/conf/files.amd64 Fri Mar 3 10:30:30 2017 (r314591) @@ -125,7 +125,6 @@ acpi_wakedata.h optional acpi \ no-obj no-implicit-rule before-depend \ clean "acpi_wakedata.h" # -amd64/amd64/amd64_mem.c optional mem #amd64/amd64/apic_vector.S standard amd64/amd64/atomic.c standard amd64/amd64/bios.c standard @@ -651,6 +650,7 @@ x86/x86/io_apic.c standard x86/x86/legacy.c standard x86/x86/local_apic.c standard x86/x86/mca.c standard +x86/x86/x86_mem.c optional mem x86/x86/mptable.c optional mptable x86/x86/mptable_pci.c optional mptable pci x86/x86/mp_x86.c optional smp Modified: stable/11/sys/conf/files.i386 ============================================================================== --- stable/11/sys/conf/files.i386 Fri Mar 3 10:17:16 2017 (r314590) +++ stable/11/sys/conf/files.i386 Fri Mar 3 10:30:30 2017 (r314591) @@ -486,7 +486,6 @@ i386/i386/elf_machdep.c standard i386/i386/exception.s standard i386/i386/gdb_machdep.c optional gdb i386/i386/geode.c optional cpu_geode -i386/i386/i686_mem.c optional mem i386/i386/in_cksum.c optional inet | inet6 i386/i386/initcpu.c standard i386/i386/io.c optional io @@ -625,6 +624,7 @@ x86/x86/io_apic.c optional apic x86/x86/legacy.c standard x86/x86/local_apic.c optional apic x86/x86/mca.c standard +x86/x86/x86_mem.c optional mem x86/x86/mptable.c optional apic x86/x86/mptable_pci.c optional apic pci x86/x86/mp_x86.c optional smp Modified: stable/11/sys/modules/mem/Makefile ============================================================================== --- stable/11/sys/modules/mem/Makefile Fri Mar 3 10:17:16 2017 (r314590) +++ stable/11/sys/modules/mem/Makefile Fri Mar 3 10:30:30 2017 (r314591) @@ -3,14 +3,17 @@ .PATH: ${.CURDIR}/../../dev/mem .PATH: ${.CURDIR}/../../${MACHINE}/${MACHINE} .PATH: ${.CURDIR}/../../${MACHINE_CPUARCH}/${MACHINE_CPUARCH} +.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" +.PATH: ${.CURDIR}/../../x86/x86 +.endif KMOD= mem SRCS= mem.c memdev.c memutil.c .if ${MACHINE_CPUARCH} == "i386" -SRCS+= i686_mem.c k6_mem.c +SRCS+= x86_mem.c k6_mem.c .endif .if ${MACHINE_CPUARCH} == "amd64" -SRCS+= amd64_mem.c +SRCS+= x86_mem.c .endif SRCS+= bus_if.h device_if.h Copied and modified: stable/11/sys/x86/x86/x86_mem.c (from r313898, head/sys/x86/x86/x86_mem.c) ============================================================================== --- head/sys/x86/x86/x86_mem.c Fri Feb 17 21:08:32 2017 (r313898, copy source) +++ stable/11/sys/x86/x86/x86_mem.c Fri Mar 3 10:30:30 2017 (r314591) @@ -260,7 +260,7 @@ x86_mrfetch(struct mem_range_softc *sc) /* Compute the range from the mask. Ick. */ mrd->mr_len = (~(msrv & mtrr_physmask) & - (mtrr_physmask | 0xfffL)) + 1; + (mtrr_physmask | 0xfff)) + 1; if (!mrvalid(mrd->mr_base, mrd->mr_len)) mrd->mr_flags |= MDF_BOGUS; @@ -303,19 +303,13 @@ x86_mrt2mtrr(int flags, int oldval) * Update running CPU(s) MTRRs to match the ranges in the descriptor * list. * - * XXX Must be called with interrupts enabled. + * Must be called with interrupts enabled. */ static void x86_mrstore(struct mem_range_softc *sc) { -#ifdef SMP smp_rendezvous(NULL, x86_mrstoreone, NULL, sc); -#else - disable_intr(); /* disable interrupts */ - x86_mrstoreone(sc); - enable_intr(); -#endif } /* @@ -644,7 +638,8 @@ x86_mrinit(struct mem_range_softc *sc) * Determine the size of the PhysMask and PhysBase fields in * the variable range MTRRs. */ - mtrr_physmask = ((1UL << cpu_maxphyaddr) - 1) & ~0xfffUL; + mtrr_physmask = (((uint64_t)1 << cpu_maxphyaddr) - 1) & + ~(uint64_t)0xfff; /* If fixed MTRRs supported and enabled. */ if ((mtrrcap & MTRR_CAP_FIXED) && (mtrrdef & MTRR_DEF_FIXED_ENABLE)) { @@ -710,19 +705,13 @@ x86_mrAPinit(struct mem_range_softc *sc) * Re-initialise running CPU(s) MTRRs to match the ranges in the descriptor * list. * - * XXX Must be called with interrupts enabled. + * Must be called with interrupts enabled. */ static void x86_mrreinit(struct mem_range_softc *sc) { -#ifdef SMP - smp_rendezvous(NULL, (void *)x86_mrAPinit, NULL, sc); -#else - disable_intr(); /* disable interrupts */ - x86_mrAPinit(sc); - enable_intr(); -#endif + smp_rendezvous(NULL, (void (*)(void *))x86_mrAPinit, NULL, sc); } static void @@ -733,16 +722,6 @@ x86_mem_drvinit(void *unused) return; if (!(cpu_feature & CPUID_MTRR)) return; - if ((cpu_id & 0xf00) != 0x600 && (cpu_id & 0xf00) != 0xf00) - return; - switch (cpu_vendor_id) { - case CPU_VENDOR_INTEL: - case CPU_VENDOR_AMD: - case CPU_VENDOR_CENTAUR: - break; - default: - return; - } mem_range_softc.mr_op = &x86_mrops; x86_mrinit(&mem_range_softc); } From owner-svn-src-all@freebsd.org Tue Mar 14 17:52:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9381AD0CB9A; Tue, 14 Mar 2017 17:52:45 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 57D4617E3; Tue, 14 Mar 2017 17:52:45 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EHqiYM068048; Tue, 14 Mar 2017 17:52:44 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EHqhQ6068037; Tue, 14 Mar 2017 17:52:43 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201703141752.v2EHqhQ6068037@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 14 Mar 2017 17:52:43 +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: r315274 - in stable/11: contrib/netbsd-tests/lib/librt include lib/libc/gen lib/libc/include share/man/man3 sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 17:52:45 -0000 Author: vangyzen Date: Tue Mar 14 17:52:43 2017 New Revision: 315274 URL: https://svnweb.freebsd.org/changeset/base/315274 Log: MFC r314179 r314206 r314424 Add sem_clockwait_np() This function allows the caller to specify the reference clock and choose between absolute and relative mode. In relative mode, the remaining time can be returned. The API is similar to clock_nanosleep(3). Thanks to Ed Schouten for that suggestion. While I'm here, reduce the sleep time in the semaphore "child" test to greatly reduce its runtime. Also add a reasonable timeout. Relnotes: yes Sponsored by: Dell EMC Modified: stable/11/contrib/netbsd-tests/lib/librt/t_sem.c stable/11/include/semaphore.h stable/11/lib/libc/gen/Makefile.inc stable/11/lib/libc/gen/Symbol.map stable/11/lib/libc/gen/sem_new.c stable/11/lib/libc/gen/sem_timedwait.3 stable/11/lib/libc/include/namespace.h stable/11/lib/libc/include/un-namespace.h stable/11/share/man/man3/pthread_testcancel.3 stable/11/sys/kern/kern_umtx.c Directory Properties: stable/11/ (props changed) Modified: stable/11/contrib/netbsd-tests/lib/librt/t_sem.c ============================================================================== --- stable/11/contrib/netbsd-tests/lib/librt/t_sem.c Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/contrib/netbsd-tests/lib/librt/t_sem.c Tue Mar 14 17:52:43 2017 (r315274) @@ -60,18 +60,24 @@ __COPYRIGHT("@(#) Copyright (c) 2008, 20 The NetBSD Foundation, inc. All rights reserved."); __RCSID("$NetBSD: t_sem.c,v 1.3 2017/01/14 20:58:20 christos Exp $"); +#include #include #include #include #include +#include #include +#include #include #include #define NCHILDREN 10 +#define SEM_REQUIRE(x) \ + ATF_REQUIRE_EQ_MSG(x, 0, "%s", strerror(errno)) + ATF_TC_WITH_CLEANUP(basic); ATF_TC_HEAD(basic, tc) { @@ -118,6 +124,7 @@ ATF_TC_HEAD(child, tc) { atf_tc_set_md_var(tc, "descr", "Checks using semaphores to synchronize " "parent with multiple child processes"); + atf_tc_set_md_var(tc, "timeout", "5"); } ATF_TC_BODY(child, tc) { @@ -153,7 +160,7 @@ ATF_TC_BODY(child, tc) } for (i = 0; i < NCHILDREN; i++) { - sleep(1); + usleep(100000); printf("main loop %d: posting...\n", j); ATF_REQUIRE_EQ(sem_post(sem_a), 0); } @@ -173,11 +180,151 @@ ATF_TC_CLEANUP(child, tc) (void)sem_unlink("/sem_a"); } +static inline void +timespec_add_ms(struct timespec *ts, int ms) +{ + ts->tv_nsec += ms * 1000*1000; + if (ts->tv_nsec > 1000*1000*1000) { + ts->tv_sec++; + ts->tv_nsec -= 1000*1000*1000; + } +} + +volatile sig_atomic_t got_sigalrm = 0; + +static void +sigalrm_handler(int sig __unused) +{ + got_sigalrm = 1; +} + +ATF_TC(timedwait); +ATF_TC_HEAD(timedwait, tc) +{ + atf_tc_set_md_var(tc, "descr", "Tests sem_timedwait(3)" +#ifdef __FreeBSD__ + " and sem_clockwait_np(3)" +#endif + ); + atf_tc_set_md_var(tc, "timeout", "20"); +} +ATF_TC_BODY(timedwait, tc) +{ + struct timespec ts; + sem_t sem; + int result; + + SEM_REQUIRE(sem_init(&sem, 0, 0)); + SEM_REQUIRE(sem_post(&sem)); + ATF_REQUIRE_MSG(clock_gettime(CLOCK_REALTIME, &ts) == 0, + "%s", strerror(errno)); + timespec_add_ms(&ts, 100); + SEM_REQUIRE(sem_timedwait(&sem, &ts)); + ATF_REQUIRE_ERRNO(ETIMEDOUT, sem_timedwait(&sem, &ts)); + ts.tv_sec--; + ATF_REQUIRE_ERRNO(ETIMEDOUT, sem_timedwait(&sem, &ts)); + SEM_REQUIRE(sem_post(&sem)); + SEM_REQUIRE(sem_timedwait(&sem, &ts)); + + /* timespec validation, in the past */ + ts.tv_nsec += 1000*1000*1000; + ATF_REQUIRE_ERRNO(EINVAL, sem_timedwait(&sem, &ts)); + ts.tv_nsec = -1; + ATF_REQUIRE_ERRNO(EINVAL, sem_timedwait(&sem, &ts)); + /* timespec validation, in the future */ + ATF_REQUIRE_MSG(clock_gettime(CLOCK_REALTIME, &ts) == 0, + "%s", strerror(errno)); + ts.tv_sec++; + ts.tv_nsec = 1000*1000*1000; + ATF_REQUIRE_ERRNO(EINVAL, sem_timedwait(&sem, &ts)); + ts.tv_nsec = -1; + ATF_REQUIRE_ERRNO(EINVAL, sem_timedwait(&sem, &ts)); + + /* EINTR */ + struct sigaction act = { + .sa_handler = sigalrm_handler, + .sa_flags = 0 /* not SA_RESTART */ + }; + ATF_REQUIRE_MSG(sigemptyset(&act.sa_mask) == 0, + "%s", strerror(errno)); + ATF_REQUIRE_MSG(sigaction(SIGALRM, &act, NULL) == 0, + "%s", strerror(errno)); + struct itimerval it = { + .it_value.tv_usec = 50*1000 + }; + ATF_REQUIRE_MSG(setitimer(ITIMER_REAL, &it, NULL) == 0, + "%s", strerror(errno)); + ATF_REQUIRE_MSG(clock_gettime(CLOCK_REALTIME, &ts) == 0, + "%s", strerror(errno)); + timespec_add_ms(&ts, 100); + ATF_REQUIRE_ERRNO(EINTR, sem_timedwait(&sem, &ts)); + ATF_REQUIRE_MSG(got_sigalrm, "did not get SIGALRM"); + +#ifdef __FreeBSD__ + /* CLOCK_MONOTONIC, absolute */ + SEM_REQUIRE(sem_post(&sem)); + ATF_REQUIRE_MSG(clock_gettime(CLOCK_MONOTONIC, &ts) == 0, + "%s", strerror(errno)); + timespec_add_ms(&ts, 100); + SEM_REQUIRE(sem_clockwait_np(&sem, CLOCK_MONOTONIC, TIMER_ABSTIME, + &ts, NULL)); + ATF_REQUIRE_ERRNO(ETIMEDOUT, + sem_clockwait_np(&sem, CLOCK_MONOTONIC, TIMER_ABSTIME, &ts, NULL)); + + /* CLOCK_MONOTONIC, relative */ + SEM_REQUIRE(sem_post(&sem)); + ts.tv_sec = 0; + ts.tv_nsec = 100*1000*1000; + SEM_REQUIRE(sem_clockwait_np(&sem, CLOCK_MONOTONIC, 0, + &ts, NULL)); + ATF_REQUIRE_ERRNO(ETIMEDOUT, + sem_clockwait_np(&sem, CLOCK_MONOTONIC, 0, &ts, NULL)); + + /* absolute does not update remaining time on EINTR */ + struct timespec remain = {42, 1000*1000*1000}; + got_sigalrm = 0; + it.it_value.tv_usec = 50*1000; + ATF_REQUIRE_MSG(setitimer(ITIMER_REAL, &it, NULL) == 0, + "%s", strerror(errno)); + ATF_REQUIRE_MSG(clock_gettime(CLOCK_MONOTONIC, &ts) == 0, + "%s", strerror(errno)); + timespec_add_ms(&ts, 100); + ATF_REQUIRE_ERRNO(EINTR, sem_clockwait_np(&sem, CLOCK_MONOTONIC, + TIMER_ABSTIME, &ts, &remain)); + ATF_REQUIRE_MSG(got_sigalrm, "did not get SIGALRM"); + ATF_REQUIRE_MSG(remain.tv_sec == 42 && remain.tv_nsec == 1000*1000*1000, + "an absolute clockwait modified the remaining time on EINTR"); + + /* relative updates remaining time on EINTR */ + remain.tv_sec = 42; + remain.tv_nsec = 1000*1000*1000; + got_sigalrm = 0; + it.it_value.tv_usec = 50*1000; + ATF_REQUIRE_MSG(setitimer(ITIMER_REAL, &it, NULL) == 0, + "%s", strerror(errno)); + ts.tv_sec = 0; + ts.tv_nsec = 100*1000*1000; + ATF_REQUIRE_ERRNO(EINTR, sem_clockwait_np(&sem, CLOCK_MONOTONIC, 0, &ts, + &remain)); + ATF_REQUIRE_MSG(got_sigalrm, "did not get SIGALRM"); + /* + * If this nsec comparison turns out to be unreliable due to timing, + * it could simply check that nsec < 100 ms. + */ + ATF_REQUIRE_MSG(remain.tv_sec == 0 && + remain.tv_nsec >= 25*1000*1000 && + remain.tv_nsec <= 75*1000*1000, + "the remaining time was not as expected when a relative clockwait" + " got EINTR" ); +#endif +} + ATF_TP_ADD_TCS(tp) { ATF_TP_ADD_TC(tp, basic); ATF_TP_ADD_TC(tp, child); + ATF_TP_ADD_TC(tp, timedwait); return atf_no_error(); } Modified: stable/11/include/semaphore.h ============================================================================== --- stable/11/include/semaphore.h Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/include/semaphore.h Tue Mar 14 17:52:43 2017 (r315274) @@ -52,6 +52,10 @@ typedef struct _sem sem_t; struct timespec; __BEGIN_DECLS +#if __BSD_VISIBLE +int sem_clockwait_np(sem_t * __restrict, __clockid_t, int, + const struct timespec *, struct timespec *); +#endif int sem_close(sem_t *); int sem_destroy(sem_t *); int sem_getvalue(sem_t * __restrict, int * __restrict); Modified: stable/11/lib/libc/gen/Makefile.inc ============================================================================== --- stable/11/lib/libc/gen/Makefile.inc Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/gen/Makefile.inc Tue Mar 14 17:52:43 2017 (r315274) @@ -461,6 +461,7 @@ MLINKS+=scandir.3 alphasort.3 MLINKS+=sem_open.3 sem_close.3 \ sem_open.3 sem_unlink.3 MLINKS+=sem_wait.3 sem_trywait.3 +MLINKS+=sem_timedwait.3 sem_clockwait_np.3 MLINKS+=send.2 sendmmsg.2 MLINKS+=setjmp.3 _longjmp.3 \ setjmp.3 _setjmp.3 \ Modified: stable/11/lib/libc/gen/Symbol.map ============================================================================== --- stable/11/lib/libc/gen/Symbol.map Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/gen/Symbol.map Tue Mar 14 17:52:43 2017 (r315274) @@ -418,6 +418,10 @@ FBSD_1.4 { stravis; }; +FBSD_1.5 { + sem_clockwait_np; +}; + FBSDprivate_1.0 { /* needed by thread libraries */ __thr_jtable; Modified: stable/11/lib/libc/gen/sem_new.c ============================================================================== --- stable/11/lib/libc/gen/sem_new.c Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/gen/sem_new.c Tue Mar 14 17:52:43 2017 (r315274) @@ -56,6 +56,7 @@ __weak_reference(_sem_init, sem_init); __weak_reference(_sem_open, sem_open); __weak_reference(_sem_post, sem_post); __weak_reference(_sem_timedwait, sem_timedwait); +__weak_reference(_sem_clockwait_np, sem_clockwait_np); __weak_reference(_sem_trywait, sem_trywait); __weak_reference(_sem_unlink, sem_unlink); __weak_reference(_sem_wait, sem_wait); @@ -345,23 +346,34 @@ usem_wake(struct _usem2 *sem) } static __inline int -usem_wait(struct _usem2 *sem, const struct timespec *abstime) +usem_wait(struct _usem2 *sem, clockid_t clock_id, int flags, + const struct timespec *rqtp, struct timespec *rmtp) { - struct _umtx_time *tm_p, timeout; + struct { + struct _umtx_time timeout; + struct timespec remain; + } tms; + void *tm_p; size_t tm_size; + int retval; - if (abstime == NULL) { + if (rqtp == NULL) { tm_p = NULL; tm_size = 0; } else { - timeout._clockid = CLOCK_REALTIME; - timeout._flags = UMTX_ABSTIME; - timeout._timeout = *abstime; - tm_p = &timeout; - tm_size = sizeof(timeout); + tms.timeout._clockid = clock_id; + tms.timeout._flags = (flags & TIMER_ABSTIME) ? UMTX_ABSTIME : 0; + tms.timeout._timeout = *rqtp; + tm_p = &tms; + tm_size = sizeof(tms); + } + retval = _umtx_op(sem, UMTX_OP_SEM2_WAIT, 0, (void *)tm_size, tm_p); + if (retval == -1 && errno == EINTR && (flags & TIMER_ABSTIME) == 0 && + rqtp != NULL && rmtp != NULL) { + *rmtp = tms.remain; } - return _umtx_op(sem, UMTX_OP_SEM2_WAIT, 0, - (void *)tm_size, __DECONST(void*, tm_p)); + + return (retval); } int @@ -381,8 +393,8 @@ _sem_trywait(sem_t *sem) } int -_sem_timedwait(sem_t * __restrict sem, - const struct timespec * __restrict abstime) +_sem_clockwait_np(sem_t * __restrict sem, clockid_t clock_id, int flags, + const struct timespec *rqtp, struct timespec *rmtp) { int val, retval; @@ -393,7 +405,8 @@ _sem_timedwait(sem_t * __restrict sem, _pthread_testcancel(); for (;;) { while (USEM_COUNT(val = sem->_kern._count) > 0) { - if (atomic_cmpset_acq_int(&sem->_kern._count, val, val - 1)) + if (atomic_cmpset_acq_int(&sem->_kern._count, val, + val - 1)) return (0); } @@ -406,20 +419,28 @@ _sem_timedwait(sem_t * __restrict sem, * The timeout argument is only supposed to * be checked if the thread would have blocked. */ - if (abstime != NULL) { - if (abstime->tv_nsec >= 1000000000 || abstime->tv_nsec < 0) { + if (rqtp != NULL) { + if (rqtp->tv_nsec >= 1000000000 || rqtp->tv_nsec < 0) { errno = EINVAL; return (-1); } } _pthread_cancel_enter(1); - retval = usem_wait(&sem->_kern, abstime); + retval = usem_wait(&sem->_kern, clock_id, flags, rqtp, rmtp); _pthread_cancel_leave(0); } return (retval); } int +_sem_timedwait(sem_t * __restrict sem, + const struct timespec * __restrict abstime) +{ + return (_sem_clockwait_np(sem, CLOCK_REALTIME, TIMER_ABSTIME, abstime, + NULL)); +}; + +int _sem_wait(sem_t *sem) { return _sem_timedwait(sem, NULL); Modified: stable/11/lib/libc/gen/sem_timedwait.3 ============================================================================== --- stable/11/lib/libc/gen/sem_timedwait.3 Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/gen/sem_timedwait.3 Tue Mar 14 17:52:43 2017 (r315274) @@ -34,18 +34,22 @@ .\" .\" $FreeBSD$ .\" -.Dd March 3, 2008 +.Dd March 10, 2017 .Dt SEM_TIMEDWAIT 3 .Os .Sh NAME -.Nm sem_timedwait +.Nm sem_timedwait , +.Nm sem_clockwait_np .Nd "lock a semaphore" .Sh LIBRARY .Lb libpthread .Sh SYNOPSIS .In semaphore.h +.In time.h .Ft int .Fn sem_timedwait "sem_t *sem" "const struct timespec *abs_timeout" +.Ft int +.Fn sem_clockwait_np "sem_t * restrict sem" "clockid_t clock_id" "int flags" "const struct timespec * rqtp" "struct timespec * rmtp" .Sh DESCRIPTION The .Fn sem_timedwait @@ -77,10 +81,40 @@ clock. The validity of the .Fa abs_timeout is not checked if the semaphore can be locked immediately. -.Sh RETURN VALUES +.Pp The -.Fn sem_timedwait -function returns zero if the calling process successfully performed the +.Fn sem_clockwait_np +function is a more flexible variant of +.Fn sem_timedwait . +The +.Fa clock_id +parameter specifies the reference clock. +If the +.Fa flags +parameter contains +.Dv TIMER_ABSTIME , +then the requested timeout +.Pq Fa rqtp +is an absolute timeout; otherwise, +the timeout is relative. +If this function fails with +.Er EINTR +and the timeout is relative, +a non-NULL +.Fa rmtp +will be updated to contain the amount of time remaining in the interval +.Po +the requested time minus the time actually slept +.Pc . +An absolute timeout has no effect on +.Fa rmtp . +A single structure can be used for both +.Fa rqtp +and +.Fa rmtp . +.Sh RETURN VALUES +These +functions return zero if the calling process successfully performed the semaphore lock operation on the semaphore designated by .Fa sem . If the call was unsuccessful, the state of the semaphore is unchanged, @@ -88,9 +122,7 @@ and the function returns a value of \-1 .Va errno to indicate the error. .Sh ERRORS -The -.Fn sem_timedwait -function will fail if: +These functions will fail if: .Bl -tag -width Er .It Bq Er EINVAL The @@ -114,6 +146,18 @@ The .Fn sem_timedwait function conforms to .St -p1003.1-2004 . +The +.Fn sem_clockwait_np +function is not specified by any standard; +it exists only on +.Fx +at the time of this writing. .Sh HISTORY -The function first appeared in +The +.Fn sem_timedwait +function first appeared in .Fx 5.0 . +The +.Fn sem_clockwait_np +function first appeared in +.Fx 12.0 . Modified: stable/11/lib/libc/include/namespace.h ============================================================================== --- stable/11/lib/libc/include/namespace.h Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/include/namespace.h Tue Mar 14 17:52:43 2017 (r315274) @@ -217,6 +217,7 @@ #define sem_open _sem_open #define sem_post _sem_post #define sem_timedwait _sem_timedwait +#define sem_clockwait_np _sem_clockwait_np #define sem_trywait _sem_trywait #define sem_unlink _sem_unlink #define sem_wait _sem_wait Modified: stable/11/lib/libc/include/un-namespace.h ============================================================================== --- stable/11/lib/libc/include/un-namespace.h Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/lib/libc/include/un-namespace.h Tue Mar 14 17:52:43 2017 (r315274) @@ -198,6 +198,7 @@ #undef sem_open #undef sem_post #undef sem_timedwait +#undef sem_clockwait_np #undef sem_trywait #undef sem_unlink #undef sem_wait Modified: stable/11/share/man/man3/pthread_testcancel.3 ============================================================================== --- stable/11/share/man/man3/pthread_testcancel.3 Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/share/man/man3/pthread_testcancel.3 Tue Mar 14 17:52:43 2017 (r315274) @@ -1,5 +1,5 @@ .\" $FreeBSD$ -.Dd August 16, 2016 +.Dd February 17, 2017 .Dt PTHREAD_TESTCANCEL 3 .Os .Sh NAME @@ -120,9 +120,9 @@ is The .Fn kevent function is a cancellation point if it is potentially blocking, -i.e. when the +such as when the .Fa nevents -argument is non-zero. +argument is non-zero. .It Fn mq_receive .It Fn mq_send .It Fn mq_timedreceive @@ -146,6 +146,7 @@ argument is non-zero. .It Fn recvmsg .It Fn select .It Fn sem_timedwait +.It Fn sem_clockwait_np .It Fn sem_wait .It Fn send .It Fn sendmsg Modified: stable/11/sys/kern/kern_umtx.c ============================================================================== --- stable/11/sys/kern/kern_umtx.c Tue Mar 14 17:34:44 2017 (r315273) +++ stable/11/sys/kern/kern_umtx.c Tue Mar 14 17:52:43 2017 (r315274) @@ -3217,10 +3217,16 @@ do_sem2_wait(struct thread *td, struct _ error = 0; else { umtxq_remove(uq); - /* A relative timeout cannot be restarted. */ - if (error == ERESTART && timeout != NULL && - (timeout->_flags & UMTX_ABSTIME) == 0) - error = EINTR; + if (timeout != NULL && (timeout->_flags & UMTX_ABSTIME) == 0) { + /* A relative timeout cannot be restarted. */ + if (error == ERESTART) + error = EINTR; + if (error == EINTR) { + abs_timeout_update(&timo); + timeout->_timeout = timo.end; + timespecsub(&timeout->_timeout, &timo.cur); + } + } } umtxq_unlock(&uq->uq_key); umtx_key_release(&uq->uq_key); @@ -3583,19 +3589,33 @@ static int __umtx_op_sem2_wait(struct thread *td, struct _umtx_op_args *uap) { struct _umtx_time *tm_p, timeout; + size_t uasize; int error; /* Allow a null timespec (wait forever). */ - if (uap->uaddr2 == NULL) + if (uap->uaddr2 == NULL) { + uasize = 0; tm_p = NULL; - else { - error = umtx_copyin_umtx_time( - uap->uaddr2, (size_t)uap->uaddr1, &timeout); + } else { + uasize = (size_t)uap->uaddr1; + error = umtx_copyin_umtx_time(uap->uaddr2, uasize, &timeout); if (error != 0) return (error); tm_p = &timeout; } - return (do_sem2_wait(td, uap->obj, tm_p)); + error = do_sem2_wait(td, uap->obj, tm_p); + if (error == EINTR && uap->uaddr2 != NULL && + (timeout._flags & UMTX_ABSTIME) == 0 && + uasize >= sizeof(struct _umtx_time) + sizeof(struct timespec)) { + error = copyout(&timeout._timeout, + (struct _umtx_time *)uap->uaddr2 + 1, + sizeof(struct timespec)); + if (error == 0) { + error = EINTR; + } + } + + return (error); } static int @@ -4192,19 +4212,37 @@ static int __umtx_op_sem2_wait_compat32(struct thread *td, struct _umtx_op_args *uap) { struct _umtx_time *tm_p, timeout; + size_t uasize; int error; /* Allow a null timespec (wait forever). */ - if (uap->uaddr2 == NULL) + if (uap->uaddr2 == NULL) { + uasize = 0; tm_p = NULL; - else { - error = umtx_copyin_umtx_time32(uap->uaddr2, - (size_t)uap->uaddr1, &timeout); + } else { + uasize = (size_t)uap->uaddr1; + error = umtx_copyin_umtx_time32(uap->uaddr2, uasize, &timeout); if (error != 0) return (error); tm_p = &timeout; } - return (do_sem2_wait(td, uap->obj, tm_p)); + error = do_sem2_wait(td, uap->obj, tm_p); + if (error == EINTR && uap->uaddr2 != NULL && + (timeout._flags & UMTX_ABSTIME) == 0 && + uasize >= sizeof(struct umtx_time32) + sizeof(struct timespec32)) { + struct timespec32 remain32 = { + .tv_sec = timeout._timeout.tv_sec, + .tv_nsec = timeout._timeout.tv_nsec + }; + error = copyout(&remain32, + (struct umtx_time32 *)uap->uaddr2 + 1, + sizeof(struct timespec32)); + if (error == 0) { + error = EINTR; + } + } + + return (error); } static int From owner-svn-src-all@freebsd.org Tue Mar 14 17:56:37 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F07FD0CE2B; Tue, 14 Mar 2017 17:56:37 +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 2E3F41AF7; Tue, 14 Mar 2017 17:56:37 +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 v2EHuaKG068264; Tue, 14 Mar 2017 17:56:36 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EHua8o068263; Tue, 14 Mar 2017 17:56:36 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703141756.v2EHua8o068263@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 17:56:36 +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: r315275 - stable/11/sys/conf X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 17:56:37 -0000 Author: kib Date: Tue Mar 14 17:56:36 2017 New Revision: 315275 URL: https://svnweb.freebsd.org/changeset/base/315275 Log: Direct commit to stable/11, a followup to fix r314591 on pc98. Reported by: rpokala Sponsored by: The FreeBSD Foundation Modified: stable/11/sys/conf/files.pc98 Modified: stable/11/sys/conf/files.pc98 ============================================================================== --- stable/11/sys/conf/files.pc98 Tue Mar 14 17:52:43 2017 (r315274) +++ stable/11/sys/conf/files.pc98 Tue Mar 14 17:56:36 2017 (r315275) @@ -157,7 +157,6 @@ i386/i386/db_trace.c optional ddb i386/i386/elf_machdep.c standard i386/i386/exception.s standard i386/i386/gdb_machdep.c optional gdb -i386/i386/i686_mem.c optional mem i386/i386/in_cksum.c optional inet | inet6 i386/i386/initcpu.c standard i386/i386/io.c optional io @@ -268,6 +267,7 @@ x86/x86/io_apic.c optional apic x86/x86/legacy.c standard x86/x86/local_apic.c optional apic x86/x86/mca.c standard +x86/x86/x86_mem.c optional mem x86/x86/mptable.c optional apic x86/x86/mptable_pci.c optional apic pci x86/x86/mp_x86.c optional smp From owner-svn-src-all@freebsd.org Tue Mar 14 18:08:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 586E0D0C304; Tue, 14 Mar 2017 18:08:34 +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 2578F681; Tue, 14 Mar 2017 18:08:34 +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 v2EI8XBJ072387; Tue, 14 Mar 2017 18:08:33 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EI8X6c072386; Tue, 14 Mar 2017 18:08:33 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703141808.v2EI8X6c072386@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Tue, 14 Mar 2017 18:08:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315276 - head/usr.sbin/makefs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 18:08:34 -0000 Author: emaste Date: Tue Mar 14 18:08:32 2017 New Revision: 315276 URL: https://svnweb.freebsd.org/changeset/base/315276 Log: makefs: sync -T timestamp with NetBSD NetBSD revision: makefs.c 1.51 Obtained from: NetBSD Modified: head/usr.sbin/makefs/makefs.c Modified: head/usr.sbin/makefs/makefs.c ============================================================================== --- head/usr.sbin/makefs/makefs.c Tue Mar 14 17:56:36 2017 (r315275) +++ head/usr.sbin/makefs/makefs.c Tue Mar 14 18:08:32 2017 (r315276) @@ -112,10 +112,13 @@ main(int argc, char *argv[]) fstype->prepare_options(&fsoptions); specfile = NULL; +#ifdef CLOCK_REALTIME + ch = clock_gettime(CLOCK_REALTIME, &start_time); +#else ch = gettimeofday(&start, NULL); start_time.tv_sec = start.tv_sec; start_time.tv_nsec = start.tv_usec * 1000; - +#endif if (ch == -1) err(1, "Unable to get system time"); From owner-svn-src-all@freebsd.org Tue Mar 14 18:27:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9E8F1D0CE98; Tue, 14 Mar 2017 18:27:49 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6C085147B; Tue, 14 Mar 2017 18:27:49 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EIRmLq080311; Tue, 14 Mar 2017 18:27:48 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EIRmLv080307; Tue, 14 Mar 2017 18:27:48 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201703141827.v2EIRmLv080307@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 14 Mar 2017 18:27:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315277 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 18:27:49 -0000 Author: vangyzen Date: Tue Mar 14 18:27:48 2017 New Revision: 315277 URL: https://svnweb.freebsd.org/changeset/base/315277 Log: KTR: log IPv4 addresses in hex rather than dotted-quad When I made the changes in r313821, I fell victim to one of the classic blunders, the most famous of which is: never get involved in a land war in Asia. But only slightly less well known is this: Keep your brain turned on and engaged when making a tedious, sweeping, mechanical change. KTR can correctly log the immediate integral values passed to it, as well as constant strings, but not non-constant strings, since they might change by the time ktrdump retrieves them. Reported by: glebius MFC after: 3 days Sponsored by: Dell EMC Modified: head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c head/sys/netinet/igmp.c head/sys/netinet/in_mcast.c head/sys/netinet/ip_mroute.c Modified: head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c ============================================================================== --- head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 18:08:32 2017 (r315276) +++ head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 18:27:48 2017 (r315277) @@ -1461,9 +1461,6 @@ static void process_data(struct iwch_ep *ep) { struct sockaddr_in *local, *remote; -#ifdef KTR - char local_str[INET_ADDRSTRLEN], remote_str[INET_ADDRSTRLEN]; -#endif CTR4(KTR_IW_CXGB, "%s ep %p so %p state %s", __FUNCTION__, ep, ep->com.so, states[ep->com.state]); @@ -1481,9 +1478,8 @@ process_data(struct iwch_ep *ep) */ in_getsockaddr(ep->com.so, (struct sockaddr **)&local); in_getpeeraddr(ep->com.so, (struct sockaddr **)&remote); - CTR3(KTR_IW_CXGB, "%s local %s remote %s", __FUNCTION__, - inet_ntoa_r(local->sin_addr, local_str), - inet_ntoa_r(remote->sin_addr, remote_str)); + CTR3(KTR_IW_CXGB, "%s local 0x%08x remote 0x%08x", __FUNCTION__, + local->sin_addr.s_addr, remote->sin_addr.s_addr); ep->com.local_addr = *local; ep->com.remote_addr = *remote; free(local, M_SONAME); @@ -1522,9 +1518,6 @@ process_newconn(struct iw_cm_id *parent_ struct sockaddr_in *local; struct sockaddr_in *remote; struct iwch_ep *parent_ep = parent_cm_id->provider_data; -#ifdef KTR - char buf[INET_ADDRSTRLEN]; -#endif CTR3(KTR_IW_CXGB, "%s parent ep %p so %p", __FUNCTION__, parent_ep, parent_ep->com.so); if (!child_so) { @@ -1544,8 +1537,8 @@ process_newconn(struct iw_cm_id *parent_ in_getsockaddr(child_so, (struct sockaddr **)&local); in_getpeeraddr(child_so, (struct sockaddr **)&remote); - CTR3(KTR_IW_CXGB, "%s remote addr %s port %d", __FUNCTION__, - inet_ntoa_r(remote->sin_addr, buf), ntohs(remote->sin_port)); + CTR3(KTR_IW_CXGB, "%s remote addr 0x%08x port %d", __FUNCTION__, + remote->sin_addr.s_addr, ntohs(remote->sin_port)); child_ep->com.tdev = parent_ep->com.tdev; child_ep->com.local_addr.sin_family = parent_ep->com.local_addr.sin_family; child_ep->com.local_addr.sin_port = parent_ep->com.local_addr.sin_port; Modified: head/sys/netinet/igmp.c ============================================================================== --- head/sys/netinet/igmp.c Tue Mar 14 18:08:32 2017 (r315276) +++ head/sys/netinet/igmp.c Tue Mar 14 18:27:48 2017 (r315277) @@ -312,17 +312,6 @@ igmp_scrub_context(struct mbuf *m) m->m_pkthdr.flowid = 0; } -#ifdef KTR -static __inline char * -inet_ntoa_haddr(in_addr_t haddr, char *addrbuf) -{ - struct in_addr ia; - - ia.s_addr = htonl(haddr); - return (inet_ntoa_r(ia, addrbuf)); -} -#endif - /* * Restore context from a queued IGMP output chain. * Return saved ifindex. @@ -804,9 +793,6 @@ igmp_input_v2_query(struct ifnet *ifp, c struct in_multi *inm; int is_general_query; uint16_t timer; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif is_general_query = 0; @@ -875,9 +861,9 @@ igmp_input_v2_query(struct ifnet *ifp, c */ inm = inm_lookup(ifp, igmp->igmp_group); if (inm != NULL) { - CTR3(KTR_IGMPV3, "process v2 query %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, - ifp->if_xname); + CTR3(KTR_IGMPV3, + "process v2 query 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); igmp_v2_update_group(inm, timer); } } @@ -907,12 +893,9 @@ out_locked: static void igmp_v2_update_group(struct in_multi *inm, const int timer) { -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif - CTR4(KTR_IGMPV3, "%s: %s/%s timer=%d", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), inm->inm_ifp->if_xname, timer); + CTR4(KTR_IGMPV3, "0x%08x: %s/%s timer=%d", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname, timer); IN_MULTI_LOCK_ASSERT(); @@ -963,9 +946,6 @@ igmp_input_v3_query(struct ifnet *ifp, c uint32_t maxresp, nsrc, qqi; uint16_t timer; uint8_t qrv; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif is_general_query = 0; @@ -1095,9 +1075,8 @@ igmp_input_v3_query(struct ifnet *ifp, c goto out_locked; } } - CTR3(KTR_IGMPV3, "process v3 %s query on ifp %p(%s)", - inet_ntoa_r(igmpv3->igmp_group, addrbuf), ifp, - ifp->if_xname); + CTR3(KTR_IGMPV3, "process v3 0x%08x query on ifp %p(%s)", + igmpv3->igmp_group.s_addr, ifp, ifp->if_xname); /* * If there is a pending General Query response * scheduled sooner than the selected delay, no @@ -1230,9 +1209,6 @@ igmp_input_v1_report(struct ifnet *ifp, struct rm_priotracker in_ifa_tracker; struct in_ifaddr *ia; struct in_multi *inm; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif IGMPSTAT_INC(igps_rcv_reports); @@ -1260,8 +1236,8 @@ igmp_input_v1_report(struct ifnet *ifp, } } - CTR3(KTR_IGMPV3, "process v1 report %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, ifp->if_xname); + CTR3(KTR_IGMPV3, "process v1 report 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); /* * IGMPv1 report suppression. @@ -1303,16 +1279,16 @@ igmp_input_v1_report(struct ifnet *ifp, case IGMP_LAZY_MEMBER: case IGMP_AWAKENING_MEMBER: CTR3(KTR_IGMPV3, - "report suppressed for %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, + "report suppressed for 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); case IGMP_SLEEPING_MEMBER: inm->inm_state = IGMP_SLEEPING_MEMBER; break; case IGMP_REPORTING_MEMBER: CTR3(KTR_IGMPV3, - "report suppressed for %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, + "report suppressed for 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); if (igi->igi_version == IGMP_VERSION_1) inm->inm_state = IGMP_LAZY_MEMBER; @@ -1344,9 +1320,6 @@ igmp_input_v2_report(struct ifnet *ifp, struct rm_priotracker in_ifa_tracker; struct in_ifaddr *ia; struct in_multi *inm; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif /* * Make sure we don't hear our own membership report. Fast @@ -1389,8 +1362,8 @@ igmp_input_v2_report(struct ifnet *ifp, if (ia != NULL) ifa_free(&ia->ia_ifa); - CTR3(KTR_IGMPV3, "process v2 report %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, ifp->if_xname); + CTR3(KTR_IGMPV3, "process v2 report 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); /* * IGMPv2 report suppression. @@ -1430,9 +1403,8 @@ igmp_input_v2_report(struct ifnet *ifp, case IGMP_IDLE_MEMBER: case IGMP_AWAKENING_MEMBER: CTR3(KTR_IGMPV3, - "report suppressed for %s on ifp %p(%s)", - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, - ifp->if_xname); + "report suppressed for 0x%08x on ifp %p(%s)", + igmp->igmp_group.s_addr, ifp, ifp->if_xname); case IGMP_LAZY_MEMBER: inm->inm_state = IGMP_LAZY_MEMBER; break; @@ -1834,9 +1806,6 @@ igmp_v3_process_group_timers(struct igmp { int query_response_timer_expired; int state_change_retransmit_timer_expired; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif IN_MULTI_LOCK_ASSERT(); IGMP_LOCK_ASSERT(); @@ -1922,9 +1891,8 @@ igmp_v3_process_group_timers(struct igmp (void)igmp_v3_merge_state_changes(inm, scq); inm_commit(inm); - CTR3(KTR_IGMPV3, "%s: T1 -> T0 for %s/%s", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname); /* * If we are leaving the group for good, make sure @@ -2370,13 +2338,9 @@ igmp_initial_join(struct in_multi *inm, struct ifnet *ifp; struct mbufq *mq; int error, retval, syncstates; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif - CTR4(KTR_IGMPV3, "%s: initial join %s on ifp %p(%s)", - __func__, inet_ntoa_r(inm->inm_addr, addrbuf), inm->inm_ifp, - inm->inm_ifp->if_xname); + CTR4(KTR_IGMPV3, "%s: initial join 0x%08x on ifp %p(%s)", __func__, + inm->inm_addr.s_addr, inm->inm_ifp, inm->inm_ifp->if_xname); error = 0; syncstates = 1; @@ -2485,9 +2449,8 @@ igmp_initial_join(struct in_multi *inm, */ if (syncstates) { inm_commit(inm); - CTR3(KTR_IGMPV3, "%s: T1 -> T0 for %s/%s", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname); } return (error); @@ -2501,13 +2464,9 @@ igmp_handle_state_change(struct in_multi { struct ifnet *ifp; int retval; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif - CTR4(KTR_IGMPV3, "%s: state change for %s on ifp %p(%s)", - __func__, inet_ntoa_r(inm->inm_addr, addrbuf), inm->inm_ifp, - inm->inm_ifp->if_xname); + CTR4(KTR_IGMPV3, "%s: state change for 0x%08x on ifp %p(%s)", __func__, + inm->inm_addr.s_addr, inm->inm_ifp, inm->inm_ifp->if_xname); ifp = inm->inm_ifp; @@ -2526,9 +2485,8 @@ igmp_handle_state_change(struct in_multi } CTR1(KTR_IGMPV3, "%s: nothing to do", __func__); inm_commit(inm); - CTR3(KTR_IGMPV3, "%s: T1 -> T0 for %s/%s", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname); return (0); } @@ -2563,14 +2521,11 @@ static void igmp_final_leave(struct in_multi *inm, struct igmp_ifsoftc *igi) { int syncstates; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif syncstates = 1; - CTR4(KTR_IGMPV3, "%s: final leave %s on ifp %p(%s)", - __func__, inet_ntoa_r(inm->inm_addr, addrbuf), inm->inm_ifp, + CTR4(KTR_IGMPV3, "%s: final leave 0x%08x on ifp %p(%s)", + __func__, inm->inm_addr.s_addr, inm->inm_ifp, inm->inm_ifp->if_xname); IN_MULTI_LOCK_ASSERT(); @@ -2611,9 +2566,9 @@ igmp_final_leave(struct in_multi *inm, s } else { inm->inm_scrv = igi->igi_rv; } - CTR4(KTR_IGMPV3, "%s: Leaving %s/%s with %d " + CTR4(KTR_IGMPV3, "%s: Leaving 0x%08x/%s with %d " "pending retransmissions.", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), + inm->inm_addr.s_addr, inm->inm_ifp->if_xname, inm->inm_scrv); if (inm->inm_scrv == 0) { inm->inm_state = IGMP_NOT_MEMBER; @@ -2646,13 +2601,11 @@ igmp_final_leave(struct in_multi *inm, s if (syncstates) { inm_commit(inm); - CTR3(KTR_IGMPV3, "%s: T1 -> T0 for %s/%s", __func__, - inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname); inm->inm_st[1].iss_fmode = MCAST_UNDEFINED; - CTR3(KTR_IGMPV3, "%s: T1 now MCAST_UNDEFINED for %s/%s", - __func__, inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: T1 now MCAST_UNDEFINED for 0x%08x/%s", + __func__, inm->inm_addr.s_addr, inm->inm_ifp->if_xname); } } @@ -2700,9 +2653,6 @@ igmp_v3_enqueue_group_record(struct mbuf int type; in_addr_t naddr; uint8_t mode; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif IN_MULTI_LOCK_ASSERT(); @@ -2780,9 +2730,8 @@ igmp_v3_enqueue_group_record(struct mbuf return (igmp_v3_enqueue_filter_change(mq, inm)); if (type == IGMP_DO_NOTHING) { - CTR3(KTR_IGMPV3, "%s: nothing to do for %s/%s", - __func__, inet_ntoa_r(inm->inm_addr, addrbuf), - inm->inm_ifp->if_xname); + CTR3(KTR_IGMPV3, "%s: nothing to do for 0x%08x/%s", __func__, + inm->inm_addr.s_addr, inm->inm_ifp->if_xname); return (0); } @@ -2795,8 +2744,8 @@ igmp_v3_enqueue_group_record(struct mbuf if (record_has_sources) minrec0len += sizeof(in_addr_t); - CTR4(KTR_IGMPV3, "%s: queueing %s for %s/%s", __func__, - igmp_rec_type_to_str(type), inet_ntoa_r(inm->inm_addr, addrbuf), + CTR4(KTR_IGMPV3, "%s: queueing %s for 0x%08x/%s", __func__, + igmp_rec_type_to_str(type), inm->inm_addr.s_addr, inm->inm_ifp->if_xname); /* @@ -2884,8 +2833,8 @@ igmp_v3_enqueue_group_record(struct mbuf } msrcs = 0; RB_FOREACH_SAFE(ims, ip_msource_tree, &inm->inm_srcs, nims) { - CTR2(KTR_IGMPV3, "%s: visit node %s", __func__, - inet_ntoa_haddr(ims->ims_haddr, addrbuf)); + CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, + htonl(ims->ims_haddr)); now = ims_get_mode(inm, ims, 1); CTR2(KTR_IGMPV3, "%s: node is %d", __func__, now); if ((now != mode) || @@ -2980,8 +2929,8 @@ igmp_v3_enqueue_group_record(struct mbuf msrcs = 0; RB_FOREACH_FROM(ims, ip_msource_tree, nims) { - CTR2(KTR_IGMPV3, "%s: visit node %s", __func__, - inet_ntoa_haddr(ims->ims_haddr, addrbuf)); + CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, + htonl(ims->ims_haddr)); now = ims_get_mode(inm, ims, 1); if ((now != mode) || (now == mode && mode == MCAST_UNDEFINED)) { @@ -3064,9 +3013,6 @@ igmp_v3_enqueue_filter_change(struct mbu int nallow, nblock; uint8_t mode, now, then; rectype_t crt, drt, nrt; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif IN_MULTI_LOCK_ASSERT(); @@ -3175,9 +3121,8 @@ igmp_v3_enqueue_filter_change(struct mbu if (nims == NULL) nims = RB_MIN(ip_msource_tree, &inm->inm_srcs); RB_FOREACH_FROM(ims, ip_msource_tree, nims) { - CTR2(KTR_IGMPV3, "%s: visit node %s", - __func__, - inet_ntoa_haddr(ims->ims_haddr, addrbuf)); + CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", + __func__, htonl(ims->ims_haddr)); now = ims_get_mode(inm, ims, 1); then = ims_get_mode(inm, ims, 0); CTR3(KTR_IGMPV3, "%s: mode: t0 %d, t1 %d", Modified: head/sys/netinet/in_mcast.c ============================================================================== --- head/sys/netinet/in_mcast.c Tue Mar 14 18:08:32 2017 (r315276) +++ head/sys/netinet/in_mcast.c Tue Mar 14 18:27:48 2017 (r315277) @@ -877,10 +877,6 @@ inm_get_source(struct in_multi *inm, con { struct ip_msource find; struct ip_msource *ims, *nims; -#ifdef KTR - struct in_addr ia; - char addrbuf[INET_ADDRSTRLEN]; -#endif find.ims_haddr = haddr; ims = RB_FIND(ip_msource_tree, &inm->inm_srcs, &find); @@ -896,9 +892,8 @@ inm_get_source(struct in_multi *inm, con ++inm->inm_nsrc; ims = nims; #ifdef KTR - ia.s_addr = htonl(haddr); - CTR3(KTR_IGMPV3, "%s: allocated %s as %p", __func__, - inet_ntoa_r(ia, addrbuf), ims); + CTR3(KTR_IGMPV3, "%s: allocated 0x%08x as %p", __func__, + htonl(haddr), ims); #endif } @@ -916,29 +911,28 @@ ims_merge(struct ip_msource *ims, const { int n = rollback ? -1 : 1; #ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; - struct in_addr ia; + uint32_t addr; - ia.s_addr = htonl(ims->ims_haddr); + addr = htonl(ims->ims_haddr); #endif if (lims->imsl_st[0] == MCAST_EXCLUDE) { - CTR3(KTR_IGMPV3, "%s: t1 ex -= %d on %s", - __func__, n, inet_ntoa_r(ia, addrbuf)); + CTR3(KTR_IGMPV3, "%s: t1 ex -= %d on 0x%08x", + __func__, n, addr); ims->ims_st[1].ex -= n; } else if (lims->imsl_st[0] == MCAST_INCLUDE) { - CTR3(KTR_IGMPV3, "%s: t1 in -= %d on %s", - __func__, n, inet_ntoa_r(ia, addrbuf)); + CTR3(KTR_IGMPV3, "%s: t1 in -= %d on 0x%08x", + __func__, n, addr); ims->ims_st[1].in -= n; } if (lims->imsl_st[1] == MCAST_EXCLUDE) { - CTR3(KTR_IGMPV3, "%s: t1 ex += %d on %s", - __func__, n, inet_ntoa_r(ia, addrbuf)); + CTR3(KTR_IGMPV3, "%s: t1 ex += %d on 0x%08x", + __func__, n, addr); ims->ims_st[1].ex += n; } else if (lims->imsl_st[1] == MCAST_INCLUDE) { - CTR3(KTR_IGMPV3, "%s: t1 in += %d on %s", - __func__, n, inet_ntoa_r(ia, addrbuf)); + CTR3(KTR_IGMPV3, "%s: t1 in += %d on 0x%08x", + __func__, n, addr); ims->ims_st[1].in += n; } } @@ -1171,14 +1165,11 @@ in_joingroup_locked(struct ifnet *ifp, c struct in_mfilter timf; struct in_multi *inm; int error; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif IN_MULTI_LOCK_ASSERT(); - CTR4(KTR_IGMPV3, "%s: join %s on %p(%s))", __func__, - inet_ntoa_r(*gina, addrbuf), ifp, ifp->if_xname); + CTR4(KTR_IGMPV3, "%s: join 0x%08x on %p(%s))", __func__, + gina->s_addr, ifp, ifp->if_xname); error = 0; inm = NULL; @@ -1256,16 +1247,13 @@ in_leavegroup_locked(struct in_multi *in { struct in_mfilter timf; int error; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif error = 0; IN_MULTI_LOCK_ASSERT(); - CTR5(KTR_IGMPV3, "%s: leave inm %p, %s/%s, imf %p", __func__, - inm, inet_ntoa_r(inm->inm_addr, addrbuf), + CTR5(KTR_IGMPV3, "%s: leave inm %p, 0x%08x/%s, imf %p", __func__, + inm, inm->inm_addr.s_addr, (inm_is_ifp_detached(inm) ? "null" : inm->inm_ifp->if_xname), imf); @@ -1364,9 +1352,6 @@ inp_block_unblock_source(struct inpcb *i size_t idx; uint16_t fmode; int error, doblock; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif ifp = NULL; error = 0; @@ -1401,8 +1386,8 @@ inp_block_unblock_source(struct inpcb *i if (sopt->sopt_name == IP_BLOCK_SOURCE) doblock = 1; - CTR3(KTR_IGMPV3, "%s: imr_interface = %s, ifp = %p", - __func__, inet_ntoa_r(mreqs.imr_interface, addrbuf), ifp); + CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", + __func__, mreqs.imr_interface.s_addr, ifp); break; } @@ -1474,9 +1459,8 @@ inp_block_unblock_source(struct inpcb *i */ ims = imo_match_source(imo, idx, &ssa->sa); if ((ims != NULL && doblock) || (ims == NULL && !doblock)) { - CTR3(KTR_IGMPV3, "%s: source %s %spresent", __func__, - inet_ntoa_r(ssa->sin.sin_addr, addrbuf), - doblock ? "" : "not "); + CTR3(KTR_IGMPV3, "%s: source 0x%08x %spresent", __func__, + ssa->sin.sin_addr.s_addr, doblock ? "" : "not "); error = EADDRNOTAVAIL; goto out_inp_locked; } @@ -1953,9 +1937,6 @@ inp_join_group(struct inpcb *inp, struct struct in_msource *lims; size_t idx; int error, is_new; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif ifp = NULL; imf = NULL; @@ -2007,8 +1988,8 @@ inp_join_group(struct inpcb *inp, struct ifp = inp_lookup_mcast_ifp(inp, &gsa->sin, mreqs.imr_interface); - CTR3(KTR_IGMPV3, "%s: imr_interface = %s, ifp = %p", - __func__, inet_ntoa_r(mreqs.imr_interface, addrbuf), ifp); + CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", + __func__, mreqs.imr_interface.s_addr, ifp); break; } @@ -2255,9 +2236,6 @@ inp_leave_group(struct inpcb *inp, struc struct in_multi *inm; size_t idx; int error, is_final; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif ifp = NULL; error = 0; @@ -2311,8 +2289,8 @@ inp_leave_group(struct inpcb *inp, struc if (!in_nullhost(mreqs.imr_interface)) INADDR_TO_IFP(mreqs.imr_interface, ifp); - CTR3(KTR_IGMPV3, "%s: imr_interface = %s, ifp = %p", - __func__, inet_ntoa_r(mreqs.imr_interface, addrbuf), ifp); + CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", + __func__, mreqs.imr_interface.s_addr, ifp); break; @@ -2392,8 +2370,8 @@ inp_leave_group(struct inpcb *inp, struc } ims = imo_match_source(imo, idx, &ssa->sa); if (ims == NULL) { - CTR3(KTR_IGMPV3, "%s: source %s %spresent", __func__, - inet_ntoa_r(ssa->sin.sin_addr, addrbuf), "not "); + CTR3(KTR_IGMPV3, "%s: source 0x%08x %spresent", + __func__, ssa->sin.sin_addr.s_addr, "not "); error = EADDRNOTAVAIL; goto out_inp_locked; } @@ -2475,9 +2453,6 @@ inp_set_multicast_if(struct inpcb *inp, struct ifnet *ifp; struct ip_moptions *imo; int error; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif if (sopt->sopt_valsize == sizeof(struct ip_mreqn)) { /* @@ -2515,8 +2490,8 @@ inp_set_multicast_if(struct inpcb *inp, if (ifp == NULL) return (EADDRNOTAVAIL); } - CTR3(KTR_IGMPV3, "%s: ifp = %p, addr = %s", __func__, ifp, - inet_ntoa_r(addr, addrbuf)); + CTR3(KTR_IGMPV3, "%s: ifp = %p, addr = 0x%08x", __func__, ifp, + addr.s_addr); } /* Reject interfaces which do not support multicast. */ @@ -2874,9 +2849,6 @@ sysctl_ip_mcast_filters(SYSCTL_HANDLER_A int retval; u_int namelen; uint32_t fmode, ifindex; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif name = (int *)arg1; namelen = arg2; @@ -2896,8 +2868,8 @@ sysctl_ip_mcast_filters(SYSCTL_HANDLER_A group.s_addr = name[1]; if (!IN_MULTICAST(ntohl(group.s_addr))) { - CTR2(KTR_IGMPV3, "%s: group %s is not multicast", - __func__, inet_ntoa_r(group, addrbuf)); + CTR2(KTR_IGMPV3, "%s: group 0x%08x is not multicast", + __func__, group.s_addr); return (EINVAL); } @@ -2928,12 +2900,8 @@ sysctl_ip_mcast_filters(SYSCTL_HANDLER_A if (retval != 0) break; RB_FOREACH(ims, ip_msource_tree, &inm->inm_srcs) { -#ifdef KTR - struct in_addr ina; - ina.s_addr = htonl(ims->ims_haddr); - CTR2(KTR_IGMPV3, "%s: visit node %s", __func__, - inet_ntoa_r(ina, addrbuf)); -#endif + CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, + htonl(ims->ims_haddr)); /* * Only copy-out sources which are in-mode. */ Modified: head/sys/netinet/ip_mroute.c ============================================================================== --- head/sys/netinet/ip_mroute.c Tue Mar 14 18:08:32 2017 (r315276) +++ head/sys/netinet/ip_mroute.c Tue Mar 14 18:27:48 2017 (r315277) @@ -845,9 +845,6 @@ add_vif(struct vifctl *vifcp) struct ifaddr *ifa; struct ifnet *ifp; int error; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif VIF_LOCK(); if (vifcp->vifc_vifi >= MAXVIFS) { @@ -931,8 +928,8 @@ add_vif(struct vifctl *vifcp) VIF_UNLOCK(); - CTR4(KTR_IPMF, "%s: add vif %d laddr %s thresh %x", __func__, - (int)vifcp->vifc_vifi, inet_ntoa_r(vifcp->vifc_lcl_addr, addrbuf), + CTR4(KTR_IPMF, "%s: add vif %d laddr 0x%08x thresh %x", __func__, + (int)vifcp->vifc_vifi, vifcp->vifc_lcl_addr.s_addr, (int)vifcp->vifc_threshold); return 0; @@ -1055,9 +1052,6 @@ add_mfc(struct mfcctl2 *mfccp) struct rtdetq *rte, *nrte; u_long hash = 0; u_short nstl; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif VIF_LOCK(); MFC_LOCK(); @@ -1066,8 +1060,8 @@ add_mfc(struct mfcctl2 *mfccp) /* If an entry already exists, just update the fields */ if (rt) { - CTR4(KTR_IPMF, "%s: update mfc orig %s group %lx parent %x", - __func__, inet_ntoa_r(mfccp->mfcc_origin, addrbuf), + CTR4(KTR_IPMF, "%s: update mfc orig 0x%08x group %lx parent %x", + __func__, mfccp->mfcc_origin.s_addr, (u_long)ntohl(mfccp->mfcc_mcastgrp.s_addr), mfccp->mfcc_parent); update_mfc_params(rt, mfccp); @@ -1086,8 +1080,8 @@ add_mfc(struct mfcctl2 *mfccp) in_hosteq(rt->mfc_mcastgrp, mfccp->mfcc_mcastgrp) && !TAILQ_EMPTY(&rt->mfc_stall)) { CTR5(KTR_IPMF, - "%s: add mfc orig %s group %lx parent %x qh %p", - __func__, inet_ntoa_r(mfccp->mfcc_origin, addrbuf), + "%s: add mfc orig 0x%08x group %lx parent %x qh %p", + __func__, mfccp->mfcc_origin.s_addr, (u_long)ntohl(mfccp->mfcc_mcastgrp.s_addr), mfccp->mfcc_parent, TAILQ_FIRST(&rt->mfc_stall)); @@ -1161,15 +1155,12 @@ del_mfc(struct mfcctl2 *mfccp) struct in_addr origin; struct in_addr mcastgrp; struct mfc *rt; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif origin = mfccp->mfcc_origin; mcastgrp = mfccp->mfcc_mcastgrp; - CTR3(KTR_IPMF, "%s: delete mfc orig %s group %lx", __func__, - inet_ntoa_r(origin, addrbuf), (u_long)ntohl(mcastgrp.s_addr)); + CTR3(KTR_IPMF, "%s: delete mfc orig 0x%08x group %lx", __func__, + origin.s_addr, (u_long)ntohl(mcastgrp.s_addr)); MFC_LOCK(); @@ -1232,13 +1223,9 @@ X_ip_mforward(struct ip *ip, struct ifne struct mfc *rt; int error; vifi_t vifi; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif - CTR3(KTR_IPMF, "ip_mforward: delete mfc orig %s group %lx ifp %p", - inet_ntoa_r(ip->ip_src, addrbuf), (u_long)ntohl(ip->ip_dst.s_addr), - ifp); + CTR3(KTR_IPMF, "ip_mforward: delete mfc orig 0x%08x group %lx ifp %p", + ntohl(ip->ip_src.s_addr), (u_long)ntohl(ip->ip_dst.s_addr), ifp); if (ip->ip_hl < (sizeof(struct ip) + TUNNEL_LEN) >> 2 || ((u_char *)(ip + 1))[1] != IPOPT_LSRR ) { @@ -1300,8 +1287,8 @@ X_ip_mforward(struct ip *ip, struct ifne MRTSTAT_INC(mrts_mfc_misses); MRTSTAT_INC(mrts_no_route); - CTR2(KTR_IPMF, "ip_mforward: no mfc for (%s,%lx)", - inet_ntoa_r(ip->ip_src, addrbuf), (u_long)ntohl(ip->ip_dst.s_addr)); + CTR2(KTR_IPMF, "ip_mforward: no mfc for (0x%08x,%lx)", + ntohl(ip->ip_src.s_addr), (u_long)ntohl(ip->ip_dst.s_addr)); /* * Allocate mbufs early so that we don't do extra work if we are @@ -2583,9 +2570,6 @@ pim_input(struct mbuf **mp, int *offp, i int minlen; int datalen = ntohs(ip->ip_len) - iphlen; int ip_tos; -#ifdef KTR - char addrbuf[INET_ADDRSTRLEN]; -#endif *mp = NULL; @@ -2598,8 +2582,8 @@ pim_input(struct mbuf **mp, int *offp, i */ if (datalen < PIM_MINLEN) { PIMSTAT_INC(pims_rcv_tooshort); - CTR3(KTR_IPMF, "%s: short packet (%d) from %s", - __func__, datalen, inet_ntoa_r(ip->ip_src, addrbuf)); + CTR3(KTR_IPMF, "%s: short packet (%d) from 0x%08x", + __func__, datalen, ntohl(ip->ip_src.s_addr)); m_freem(m); return (IPPROTO_DONE); } @@ -2698,8 +2682,8 @@ pim_input(struct mbuf **mp, int *offp, i reghdr = (u_int32_t *)(pim + 1); encap_ip = (struct ip *)(reghdr + 1); - CTR3(KTR_IPMF, "%s: register: encap ip src %s len %d", - __func__, inet_ntoa_r(encap_ip->ip_src, addrbuf), + CTR3(KTR_IPMF, "%s: register: encap ip src 0x%08x len %d", + __func__, ntohl(encap_ip->ip_src.s_addr), ntohs(encap_ip->ip_len)); /* verify the version number of the inner packet */ @@ -2713,8 +2697,8 @@ pim_input(struct mbuf **mp, int *offp, i /* verify the inner packet is destined to a mcast group */ if (!IN_MULTICAST(ntohl(encap_ip->ip_dst.s_addr))) { PIMSTAT_INC(pims_rcv_badregisters); - CTR2(KTR_IPMF, "%s: bad encap ip dest %s", __func__, - inet_ntoa_r(encap_ip->ip_dst, addrbuf)); + CTR2(KTR_IPMF, "%s: bad encap ip dest 0x%08x", __func__, + ntohl(encap_ip->ip_dst.s_addr)); m_freem(m); return (IPPROTO_DONE); } From owner-svn-src-all@freebsd.org Tue Mar 14 18:29:24 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D6A47D0B118; Tue, 14 Mar 2017 18:29:24 +0000 (UTC) (envelope-from dchagin@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 A39F5178D; Tue, 14 Mar 2017 18:29:24 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EITNgg080408; Tue, 14 Mar 2017 18:29:23 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EITNSY080407; Tue, 14 Mar 2017 18:29:23 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703141829.v2EITNSY080407@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Tue, 14 Mar 2017 18:29:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315278 - head/sys/compat/linux X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 18:29:24 -0000 Author: dchagin Date: Tue Mar 14 18:29:23 2017 New Revision: 315278 URL: https://svnweb.freebsd.org/changeset/base/315278 Log: Fix usage of the same 'i' variable in the external and nested loops. Submitted by: Svyatoslav Sponsored by: PVS-Studio MFC after: 1 week Modified: head/sys/compat/linux/linux_vdso.c Modified: head/sys/compat/linux/linux_vdso.c ============================================================================== --- head/sys/compat/linux/linux_vdso.c Tue Mar 14 18:27:48 2017 (r315277) +++ head/sys/compat/linux/linux_vdso.c Tue Mar 14 18:29:23 2017 (r315278) @@ -147,7 +147,7 @@ __elfN(linux_vdso_reloc)(struct sysentve Elf_Shdr *shdr; Elf_Dyn *dyn; Elf_Sym *sym; - int i, symcnt; + int i, j, symcnt; ehdr = (Elf_Ehdr *) sv->sv_sigcode; @@ -205,7 +205,7 @@ __elfN(linux_vdso_reloc)(struct sysentve sym = (Elf_Sym *)((caddr_t)ehdr + shdr[i].sh_offset); symcnt = shdr[i].sh_size / sizeof(*sym); - for(i = 0; i < symcnt; i++, sym++) { + for(j = 0; j < symcnt; j++, sym++) { if (sym->st_shndx == SHN_UNDEF || sym->st_shndx == SHN_ABS) continue; From owner-svn-src-all@freebsd.org Tue Mar 14 18:42:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E0721D0B653; Tue, 14 Mar 2017 18:42:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9AAD59A; Tue, 14 Mar 2017 18:42:34 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EIgXZw088484; Tue, 14 Mar 2017 18:42:33 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EIgXj8088480; Tue, 14 Mar 2017 18:42:33 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703141842.v2EIgXj8088480@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Tue, 14 Mar 2017 18:42:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315279 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 18:42:35 -0000 Author: mav Date: Tue Mar 14 18:42:33 2017 New Revision: 315279 URL: https://svnweb.freebsd.org/changeset/base/315279 Log: Remove some dead/broken code paths around async handling MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_target.c head/sys/dev/isp/ispvar.h Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Tue Mar 14 18:29:23 2017 (r315278) +++ head/sys/dev/isp/isp.c Tue Mar 14 18:42:33 2017 (r315279) @@ -95,11 +95,11 @@ static const uint8_t alpa_map[] = { /* * Local function prototypes. */ -static int isp_parse_async(ispsoftc_t *, uint16_t); -static int isp_parse_async_fc(ispsoftc_t *, uint16_t); +static void isp_parse_async(ispsoftc_t *, uint16_t); +static void isp_parse_async_fc(ispsoftc_t *, uint16_t); static int isp_handle_other_response(ispsoftc_t *, int, isphdr_t *, uint32_t *); -static void isp_parse_status(ispsoftc_t *, ispstatusreq_t *, XS_T *, long *); static void -isp_parse_status_24xx(ispsoftc_t *, isp24xx_statusreq_t *, XS_T *, long *); +static void isp_parse_status(ispsoftc_t *, ispstatusreq_t *, XS_T *, long *); +static void isp_parse_status_24xx(ispsoftc_t *, isp24xx_statusreq_t *, XS_T *, long *); static void isp_fastpost_complete(ispsoftc_t *, uint32_t); static void isp_scsi_init(ispsoftc_t *); static void isp_scsi_channel_init(ispsoftc_t *, int); @@ -4950,10 +4950,10 @@ again: isp_prt(isp, ISP_LOGWARN, "mailbox cmd (0x%x) with no waiters", info); } } else { - i = IS_FC(isp)? isp_parse_async_fc(isp, info) : isp_parse_async(isp, info); - if (i < 0) { - return; - } + if (IS_FC(isp)) + isp_parse_async_fc(isp, info); + else + isp_parse_async(isp, info); } if ((IS_FC(isp) && info != ASYNC_RIOZIO_STALL) || isp->isp_state != ISP_RUNSTATE) { goto out; @@ -5504,13 +5504,10 @@ isp_prt_endcmd(ispsoftc_t *isp, XS_T *xs /* * Parse an ASYNC mailbox complete - * - * Return non-zero if the event has been acknowledged. */ -static int +static void isp_parse_async(ispsoftc_t *isp, uint16_t mbox) { - int acked = 0; uint32_t h1 = 0, h2 = 0; uint16_t chan = 0; @@ -5529,9 +5526,7 @@ isp_parse_async(ispsoftc_t *isp, uint16_ case ASYNC_BUS_RESET: ISP_SET_SENDMARKER(isp, chan, 1); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif isp_async(isp, ISPASYNC_BUS_RESET, chan); break; @@ -5551,7 +5546,6 @@ isp_parse_async(ispsoftc_t *isp, uint16_ * restart the firmware */ isp_async(isp, ISPASYNC_FW_CRASH); - acked = 1; break; case ASYNC_RQS_XFER_ERR: @@ -5575,9 +5569,7 @@ isp_parse_async(ispsoftc_t *isp, uint16_ isp_prt(isp, ISP_LOGWARN, "timeout initiated SCSI bus reset of chan %d", chan); ISP_SET_SENDMARKER(isp, chan, 1); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif break; @@ -5585,9 +5577,7 @@ isp_parse_async(ispsoftc_t *isp, uint16_ isp_prt(isp, ISP_LOGINFO, "device reset on chan %d", chan); ISP_SET_SENDMARKER(isp, chan, 1); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif break; @@ -5687,14 +5677,12 @@ isp_parse_async(ispsoftc_t *isp, uint16_ } else { isp->isp_intoasync++; } - return (acked); } -static int +static void isp_parse_async_fc(ispsoftc_t *isp, uint16_t mbox) { fcparam *fcp; - int acked = 0; uint16_t chan; if (IS_DUALBUS(isp)) { @@ -5723,7 +5711,6 @@ isp_parse_async_fc(ispsoftc_t *isp, uint * restart the firmware */ isp_async(isp, ISPASYNC_FW_CRASH); - acked = 1; break; case ASYNC_RQS_XFER_ERR: @@ -5756,11 +5743,9 @@ isp_parse_async_fc(ispsoftc_t *isp, uint case ASYNC_CTIO_DONE: #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, (ISP_READ(isp, OUTMAILBOX2) << 16) | ISP_READ(isp, OUTMAILBOX1), mbox)) { - acked = 1; - } else { - isp->isp_fphccmplt++; - } + isp_target_async(isp, (ISP_READ(isp, OUTMAILBOX2) << 16) | + ISP_READ(isp, OUTMAILBOX1), mbox); + isp->isp_fphccmplt++; #else isp_prt(isp, ISP_LOGWARN, "unexpected ASYNC CTIO done"); #endif @@ -5785,9 +5770,7 @@ isp_parse_async_fc(ispsoftc_t *isp, uint ISP_SET_SENDMARKER(isp, chan, 1); isp_async(isp, ISPASYNC_LIP, chan); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif /* * We've had problems with data corruption occurring on @@ -5841,9 +5824,7 @@ isp_parse_async_fc(ispsoftc_t *isp, uint ISP_SET_SENDMARKER(isp, chan, 1); isp_async(isp, ISPASYNC_LOOP_UP, chan); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif } break; @@ -5862,9 +5843,7 @@ isp_parse_async_fc(ispsoftc_t *isp, uint fcp->isp_loopstate = LOOP_NIL; isp_async(isp, ISPASYNC_LOOP_DOWN, chan); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif } break; @@ -5884,9 +5863,7 @@ isp_parse_async_fc(ispsoftc_t *isp, uint fcp->isp_loopstate = LOOP_HAVE_LINK; isp_async(isp, ISPASYNC_LOOP_RESET, chan); #ifdef ISP_TARGET_MODE - if (isp_target_async(isp, chan, mbox)) { - acked = 1; - } + isp_target_async(isp, chan, mbox); #endif } break; @@ -5990,7 +5967,7 @@ isp_parse_async_fc(ispsoftc_t *isp, uint isp->isp_state = ISP_CRASHED; isp_prt(isp, ISP_LOGERR, "FATAL CONNECTION ERROR"); isp_async(isp, ISPASYNC_FW_CRASH); - return (-1); + return; case ISP_CONN_LOOPBACK: isp_prt(isp, ISP_LOGWARN, "Looped Back in Point-to-Point mode"); @@ -6043,7 +6020,6 @@ isp_parse_async_fc(ispsoftc_t *isp, uint if (mbox != ASYNC_CTIO_DONE && mbox != ASYNC_CMD_CMPLT) { isp->isp_intoasync++; } - return (acked); } /* Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Tue Mar 14 18:29:23 2017 (r315278) +++ head/sys/dev/isp/isp_freebsd.c Tue Mar 14 18:42:33 2017 (r315279) @@ -4291,11 +4291,13 @@ changed: mbox6 = 0; } isp_prt(isp, ISP_LOGERR, "Internal Firmware Error on bus %d @ RISC Address 0x%x", mbox6, mbox1); +#if 0 mbox1 = isp->isp_osinfo.mbox_sleep_ok; isp->isp_osinfo.mbox_sleep_ok = 0; isp_reinit(isp, 1); isp->isp_osinfo.mbox_sleep_ok = mbox1; isp_async(isp, ISPASYNC_FW_RESTARTED, NULL); +#endif break; } default: Modified: head/sys/dev/isp/isp_target.c ============================================================================== --- head/sys/dev/isp/isp_target.c Tue Mar 14 18:29:23 2017 (r315278) +++ head/sys/dev/isp/isp_target.c Tue Mar 14 18:42:33 2017 (r315279) @@ -617,7 +617,7 @@ isp_endcmd(ispsoftc_t *isp, ...) * These are either broadcast events or specifically CTIO fast completion */ -int +void isp_target_async(ispsoftc_t *isp, int bus, int event) { isp_notify_t notify; @@ -694,7 +694,6 @@ isp_target_async(ispsoftc_t *isp, int bu } break; } - return (0); } /* Modified: head/sys/dev/isp/ispvar.h ============================================================================== --- head/sys/dev/isp/ispvar.h Tue Mar 14 18:29:23 2017 (r315278) +++ head/sys/dev/isp/ispvar.h Tue Mar 14 18:42:33 2017 (r315279) @@ -1141,9 +1141,7 @@ int isp_endcmd(ispsoftc_t *, ...); /* * Handle an asynchronous event - * - * Return nonzero if the interrupt that generated this event has been dismissed. */ -int isp_target_async(ispsoftc_t *, int, int); +void isp_target_async(ispsoftc_t *, int, int); #endif #endif /* _ISPVAR_H */ From owner-svn-src-all@freebsd.org Tue Mar 14 19:02:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9C3ADD0BBE7 for ; Tue, 14 Mar 2017 19:02:36 +0000 (UTC) (envelope-from ian@freebsd.org) Received: from outbound1a.eu.mailhop.org (outbound1a.eu.mailhop.org [52.58.109.202]) (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 38909C80 for ; Tue, 14 Mar 2017 19:02:35 +0000 (UTC) (envelope-from ian@freebsd.org) X-MHO-User: c6e3f79d-08e8-11e7-95b5-6dfd7dbb0ee5 X-Report-Abuse-To: https://support.duocircle.com/support/solutions/articles/5000540958-duocircle-standard-smtp-abuse-information X-Originating-IP: 73.78.92.27 X-Mail-Handler: DuoCircle Outbound SMTP Received: from ilsoft.org (unknown [73.78.92.27]) by outbound1.eu.mailhop.org (Halon) with ESMTPSA id c6e3f79d-08e8-11e7-95b5-6dfd7dbb0ee5; Tue, 14 Mar 2017 19:02:33 +0000 (UTC) Received: from rev (rev [172.22.42.240]) by ilsoft.org (8.15.2/8.15.2) with ESMTP id v2EJ2LTW001759; Tue, 14 Mar 2017 13:02:21 -0600 (MDT) (envelope-from ian@freebsd.org) Message-ID: <1489518141.40576.119.camel@freebsd.org> Subject: Re: svn commit: r315277 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet From: Ian Lepore To: Eric van Gyzen , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Date: Tue, 14 Mar 2017 13:02:21 -0600 In-Reply-To: <201703141827.v2EIRmLv080307@repo.freebsd.org> References: <201703141827.v2EIRmLv080307@repo.freebsd.org> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.1 FreeBSD GNOME Team Port Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 19:02:36 -0000 On Tue, 2017-03-14 at 18:27 +0000, Eric van Gyzen wrote: > Author: vangyzen > Date: Tue Mar 14 18:27:48 2017 > New Revision: 315277 > URL: https://svnweb.freebsd.org/changeset/base/315277 > > Log: >   KTR: log IPv4 addresses in hex rather than dotted-quad >    Don't all those s_addr fields now need some ntohl() love to print properly as an integer value? -- ian From owner-svn-src-all@freebsd.org Tue Mar 14 19:06:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 914FCD0BD67; Tue, 14 Mar 2017 19:06:46 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6051BF23; Tue, 14 Mar 2017 19:06:46 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EJ6jSb096683; Tue, 14 Mar 2017 19:06:45 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EJ6i0x096677; Tue, 14 Mar 2017 19:06:44 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201703141906.v2EJ6i0x096677@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 14 Mar 2017 19:06:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315280 - in head/sys: kern sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 19:06:46 -0000 Author: vangyzen Date: Tue Mar 14 19:06:44 2017 New Revision: 315280 URL: https://svnweb.freebsd.org/changeset/base/315280 Log: When the RTC is adjusted, reevaluate absolute sleep times based on the RTC POSIX 2008 says this about clock_settime(2): If the value of the CLOCK_REALTIME clock is set via clock_settime(), the new value of the clock shall be used to determine the time of expiration for absolute time services based upon the CLOCK_REALTIME clock. This applies to the time at which armed absolute timers expire. If the absolute time requested at the invocation of such a time service is before the new value of the clock, the time service shall expire immediately as if the clock had reached the requested time normally. Setting the value of the CLOCK_REALTIME clock via clock_settime() shall have no effect on threads that are blocked waiting for a relative time service based upon this clock, including the nanosleep() function; nor on the expiration of relative timers based upon this clock. Consequently, these time services shall expire when the requested relative interval elapses, independently of the new or old value of the clock. When the real-time clock is adjusted, such as by clock_settime(3), wake any threads sleeping until an absolute real-clock time. Such a sleep is indicated by a non-zero td_rtcgen. The sleep functions will set that field to zero and return zero to tell the caller to reevaluate its sleep duration based on the new value of the clock. At present, this affects the following functions: pthread_cond_timedwait(3) pthread_mutex_timedlock(3) pthread_rwlock_timedrdlock(3) pthread_rwlock_timedwrlock(3) sem_timedwait(3) sem_clockwait_np(3) I'm working on adding clock_nanosleep(2), which will also be affected. Reported by: Sebastian Huber Reviewed by: jhb, kib MFC after: 2 weeks Relnotes: yes Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D9791 Modified: head/sys/kern/kern_tc.c head/sys/kern/kern_umtx.c head/sys/kern/subr_sleepqueue.c head/sys/sys/proc.h head/sys/sys/sleepqueue.h head/sys/sys/time.h Modified: head/sys/kern/kern_tc.c ============================================================================== --- head/sys/kern/kern_tc.c Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/kern/kern_tc.c Tue Mar 14 19:06:44 2017 (r315280) @@ -28,7 +28,9 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include +#include #include #include #include @@ -126,6 +128,8 @@ SYSCTL_PROC(_kern_timecounter, OID_AUTO, sysctl_kern_timecounter_adjprecision, "I", "Allowed time interval deviation in percents"); +volatile int rtc_generation = 1; + static int tc_chosen; /* Non-zero if a specific tc was chosen via sysctl. */ static void tc_windup(struct bintime *new_boottimebin); @@ -1261,6 +1265,17 @@ tc_getfrequency(void) return (timehands->th_counter->tc_frequency); } +static bool +sleeping_on_old_rtc(struct thread *td) +{ + + if (td->td_rtcgen != 0 && td->td_rtcgen != rtc_generation) { + td->td_rtcgen = 0; + return (true); + } + return (false); +} + static struct mtx tc_setclock_mtx; MTX_SYSINIT(tc_setclock_init, &tc_setclock_mtx, "tcsetc", MTX_SPIN); @@ -1284,6 +1299,9 @@ tc_setclock(struct timespec *ts) /* XXX fiddle all the little crinkly bits around the fiords... */ tc_windup(&bt); mtx_unlock_spin(&tc_setclock_mtx); + /* Avoid rtc_generation == 0, since td_rtcgen == 0 is special. */ + atomic_add_rel_int(&rtc_generation, 2); + sleepq_chains_remove_matching(sleeping_on_old_rtc); if (timestepwarnings) { nanotime(&taft); log(LOG_INFO, Modified: head/sys/kern/kern_umtx.c ============================================================================== --- head/sys/kern/kern_umtx.c Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/kern/kern_umtx.c Tue Mar 14 19:06:44 2017 (r315280) @@ -59,6 +59,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include @@ -70,6 +71,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #ifdef COMPAT_FREEBSD32 @@ -210,6 +212,7 @@ struct umtxq_chain { struct abs_timeout { int clockid; + bool is_abs_real; /* TIMER_ABSTIME && CLOCK_REALTIME* */ struct timespec cur; struct timespec end; }; @@ -257,6 +260,8 @@ SYSCTL_LONG(_debug_umtx, OID_AUTO, max_l static SYSCTL_NODE(_debug_umtx, OID_AUTO, chains, CTLFLAG_RD, 0, "umtx chain stats"); #endif +static void abs_timeout_update(struct abs_timeout *timo); + static void umtx_shm_init(void); static void umtxq_sysinit(void *); static void umtxq_hash(struct umtx_key *key); @@ -772,12 +777,22 @@ abs_timeout_init(struct abs_timeout *tim timo->clockid = clockid; if (!absolute) { - kern_clock_gettime(curthread, clockid, &timo->end); - timo->cur = timo->end; + timo->is_abs_real = false; + abs_timeout_update(timo); + timo->end = timo->cur; timespecadd(&timo->end, timeout); } else { timo->end = *timeout; - kern_clock_gettime(curthread, clockid, &timo->cur); + timo->is_abs_real = clockid == CLOCK_REALTIME || + clockid == CLOCK_REALTIME_FAST || + clockid == CLOCK_REALTIME_PRECISE; + /* + * If is_abs_real, umtxq_sleep will read the clock + * after setting td_rtcgen; otherwise, read it here. + */ + if (!timo->is_abs_real) { + abs_timeout_update(timo); + } } } @@ -831,26 +846,41 @@ umtxq_sleep(struct umtx_q *uq, const cha struct umtxq_chain *uc; int error, timo; + if (abstime != NULL && abstime->is_abs_real) { + curthread->td_rtcgen = atomic_load_acq_int(&rtc_generation); + abs_timeout_update(abstime); + } + uc = umtxq_getchain(&uq->uq_key); UMTXQ_LOCKED_ASSERT(uc); for (;;) { - if (!(uq->uq_flags & UQF_UMTXQ)) - return (0); + if (!(uq->uq_flags & UQF_UMTXQ)) { + error = 0; + break; + } if (abstime != NULL) { timo = abs_timeout_gethz(abstime); - if (timo < 0) - return (ETIMEDOUT); + if (timo < 0) { + error = ETIMEDOUT; + break; + } } else timo = 0; error = msleep(uq, &uc->uc_lock, PCATCH | PDROP, wmesg, timo); - if (error != EWOULDBLOCK) { + if (error == EINTR || error == ERESTART) { umtxq_lock(&uq->uq_key); break; } - if (abstime != NULL) + if (abstime != NULL) { + if (abstime->is_abs_real) + curthread->td_rtcgen = + atomic_load_acq_int(&rtc_generation); abs_timeout_update(abstime); + } umtxq_lock(&uq->uq_key); } + + curthread->td_rtcgen = 0; return (error); } Modified: head/sys/kern/subr_sleepqueue.c ============================================================================== --- head/sys/kern/subr_sleepqueue.c Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/kern/subr_sleepqueue.c Tue Mar 14 19:06:44 2017 (r315280) @@ -78,6 +78,9 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include + +#include #include @@ -539,6 +542,7 @@ sleepq_switch(void *wchan, int pri) struct sleepqueue_chain *sc; struct sleepqueue *sq; struct thread *td; + bool rtc_changed; td = curthread; sc = SC_LOOKUP(wchan); @@ -557,9 +561,15 @@ sleepq_switch(void *wchan, int pri) /* * If TDF_TIMEOUT is set, then our sleep has been timed out * already but we are still on the sleep queue, so dequeue the - * thread and return. + * thread and return. Do the same if the real-time clock has + * been adjusted since this thread calculated its timeout + * based on that clock. */ - if (td->td_flags & TDF_TIMEOUT) { + rtc_changed = td->td_rtcgen != 0 && td->td_rtcgen != rtc_generation; + if ((td->td_flags & TDF_TIMEOUT) || rtc_changed) { + if (rtc_changed) { + td->td_rtcgen = 0; + } MPASS(TD_ON_SLEEPQ(td)); sq = sleepq_lookup(wchan); if (sleepq_resume_thread(sq, td, 0)) { @@ -886,6 +896,12 @@ sleepq_signal(void *wchan, int flags, in return (wakeup_swapper); } +static bool +match_any(struct thread *td __unused) +{ + return (true); +} + /* * Resume all threads sleeping on a specified wait channel. */ @@ -893,8 +909,6 @@ int sleepq_broadcast(void *wchan, int flags, int pri, int queue) { struct sleepqueue *sq; - struct thread *td, *tdn; - int wakeup_swapper; CTR2(KTR_PROC, "sleepq_broadcast(%p, %d)", wchan, flags); KASSERT(wchan != NULL, ("%s: invalid NULL wait channel", __func__)); @@ -905,18 +919,33 @@ sleepq_broadcast(void *wchan, int flags, KASSERT(sq->sq_type == (flags & SLEEPQ_TYPE), ("%s: mismatch between sleep/wakeup and cv_*", __func__)); + return (sleepq_remove_matching(sq, queue, match_any, pri)); +} + +/* + * Resume threads on the sleep queue that match the given predicate. + */ +int +sleepq_remove_matching(struct sleepqueue *sq, int queue, + bool (*matches)(struct thread *), int pri) +{ + struct thread *td, *tdn; + int wakeup_swapper; + /* - * Resume all blocked threads on the sleep queue. The last thread will - * be given ownership of sq and may re-enqueue itself before - * sleepq_resume_thread() returns, so we must cache the "next" queue - * item at the beginning of the final iteration. + * The last thread will be given ownership of sq and may + * re-enqueue itself before sleepq_resume_thread() returns, + * so we must cache the "next" queue item at the beginning + * of the final iteration. */ wakeup_swapper = 0; TAILQ_FOREACH_SAFE(td, &sq->sq_blocked[queue], td_slpq, tdn) { thread_lock(td); - wakeup_swapper |= sleepq_resume_thread(sq, td, pri); + if (matches(td)) + wakeup_swapper |= sleepq_resume_thread(sq, td, pri); thread_unlock(td); } + return (wakeup_swapper); } @@ -1052,6 +1081,32 @@ sleepq_abort(struct thread *td, int intr return (sleepq_resume_thread(sq, td, 0)); } +void +sleepq_chains_remove_matching(bool (*matches)(struct thread *)) +{ + struct sleepqueue_chain *sc; + struct sleepqueue *sq; + int i, wakeup_swapper; + + wakeup_swapper = 0; + for (sc = &sleepq_chains[0]; sc < sleepq_chains + SC_TABLESIZE; ++sc) { + if (LIST_EMPTY(&sc->sc_queues)) { + continue; + } + mtx_lock_spin(&sc->sc_lock); + LIST_FOREACH(sq, &sc->sc_queues, sq_hash) { + for (i = 0; i < NR_SLEEPQS; ++i) { + wakeup_swapper |= sleepq_remove_matching(sq, i, + matches, 0); + } + } + mtx_unlock_spin(&sc->sc_lock); + } + if (wakeup_swapper) { + kick_proc0(); + } +} + /* * Prints the stacks of all threads presently sleeping on wchan/queue to * the sbuf sb. Sets count_stacks_printed to the number of stacks actually Modified: head/sys/sys/proc.h ============================================================================== --- head/sys/sys/proc.h Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/sys/proc.h Tue Mar 14 19:06:44 2017 (r315280) @@ -148,6 +148,7 @@ struct pargs { * o - ktrace lock * q - td_contested lock * r - p_peers lock + * s - by curthread, or by others when curthread is on sleepqueue * t - thread lock * u - process stat lock * w - process timer lock @@ -283,6 +284,7 @@ struct thread { int td_dom_rr_idx; /* (k) RR Numa domain selection. */ void *td_su; /* (k) FFS SU private */ sbintime_t td_sleeptimo; /* (t) Sleep timeout. */ + int td_rtcgen; /* (s) rtc_generation of abs. sleep */ #define td_endzero td_sigmask /* Copied during fork1() or create_thread(). */ Modified: head/sys/sys/sleepqueue.h ============================================================================== --- head/sys/sys/sleepqueue.h Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/sys/sleepqueue.h Tue Mar 14 19:06:44 2017 (r315280) @@ -90,11 +90,14 @@ void sleepq_add(void *wchan, struct lock int flags, int queue); struct sleepqueue *sleepq_alloc(void); int sleepq_broadcast(void *wchan, int flags, int pri, int queue); +void sleepq_chains_remove_matching(bool (*matches)(struct thread *)); void sleepq_free(struct sleepqueue *sq); void sleepq_lock(void *wchan); struct sleepqueue *sleepq_lookup(void *wchan); void sleepq_release(void *wchan); void sleepq_remove(struct thread *td, void *wchan); +int sleepq_remove_matching(struct sleepqueue *sq, int queue, + bool (*matches)(struct thread *), int pri); int sleepq_signal(void *wchan, int flags, int pri, int queue); void sleepq_set_timeout_sbt(void *wchan, sbintime_t sbt, sbintime_t pr, int flags); Modified: head/sys/sys/time.h ============================================================================== --- head/sys/sys/time.h Tue Mar 14 18:42:33 2017 (r315279) +++ head/sys/sys/time.h Tue Mar 14 19:06:44 2017 (r315280) @@ -383,6 +383,8 @@ extern struct bintime bt_tickthreshold; extern sbintime_t sbt_timethreshold; extern sbintime_t sbt_tickthreshold; +extern volatile int rtc_generation; + /* * Functions for looking at our clock: [get]{bin,nano,micro}[up]time() * From owner-svn-src-all@freebsd.org Tue Mar 14 19:39:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 78135D0CBDD; Tue, 14 Mar 2017 19:39:19 +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 4FF152DE; Tue, 14 Mar 2017 19:39:19 +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 v2EJdIRB009449; Tue, 14 Mar 2017 19:39:18 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EJdHFV009438; Tue, 14 Mar 2017 19:39:17 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703141939.v2EJdHFV009438@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Tue, 14 Mar 2017 19:39:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315281 - in head/sys: dev/drm dev/drm2 kern vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 19:39:19 -0000 Author: kib Date: Tue Mar 14 19:39:17 2017 New Revision: 315281 URL: https://svnweb.freebsd.org/changeset/base/315281 Log: Use atop() instead of OFF_TO_IDX() for convertion of addresses or addresses offsets, as intended. Suggested and reviewed by: alc Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Modified: head/sys/dev/drm/drm_scatter.c head/sys/dev/drm2/drm_scatter.c head/sys/kern/kern_proc.c head/sys/kern/vfs_bio.c head/sys/vm/vm_fault.c head/sys/vm/vm_kern.c head/sys/vm/vm_map.c head/sys/vm/vm_mmap.c head/sys/vm/vm_object.c Modified: head/sys/dev/drm/drm_scatter.c ============================================================================== --- head/sys/dev/drm/drm_scatter.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/dev/drm/drm_scatter.c Tue Mar 14 19:39:17 2017 (r315281) @@ -48,7 +48,7 @@ drm_sg_alloc(struct drm_device *dev, str entry = malloc(sizeof(*entry), DRM_MEM_DRIVER, M_WAITOK | M_ZERO); size = round_page(request->size); - entry->pages = OFF_TO_IDX(size); + entry->pages = atop(size); entry->busaddr = malloc(entry->pages * sizeof(*entry->busaddr), DRM_MEM_SGLISTS, M_WAITOK | M_ZERO); Modified: head/sys/dev/drm2/drm_scatter.c ============================================================================== --- head/sys/dev/drm2/drm_scatter.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/dev/drm2/drm_scatter.c Tue Mar 14 19:39:17 2017 (r315281) @@ -74,7 +74,7 @@ int drm_sg_alloc(struct drm_device *dev, DRM_DEBUG("request size=%ld\n", request->size); size = round_page(request->size); - entry->pages = OFF_TO_IDX(size); + entry->pages = atop(size); entry->busaddr = malloc(entry->pages * sizeof(*entry->busaddr), DRM_MEM_SGLISTS, M_NOWAIT | M_ZERO); if (!entry->busaddr) { Modified: head/sys/kern/kern_proc.c ============================================================================== --- head/sys/kern/kern_proc.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/kern/kern_proc.c Tue Mar 14 19:39:17 2017 (r315281) @@ -2258,7 +2258,7 @@ kern_proc_vmmap_resident(vm_map_t map, v if (m_adv != NULL) { m = m_adv; } else { - pi_adv = OFF_TO_IDX(entry->end - addr); + pi_adv = atop(entry->end - addr); pindex = pi; for (tobj = obj;; tobj = tobj->backing_object) { m = vm_page_find_least(tobj, pindex); @@ -2282,7 +2282,7 @@ kern_proc_vmmap_resident(vm_map_t map, v (pmap_mincore(map->pmap, addr, &locked_pa) & MINCORE_SUPER) != 0) { kve->kve_flags |= KVME_FLAG_SUPER; - pi_adv = OFF_TO_IDX(pagesizes[1]); + pi_adv = atop(pagesizes[1]); } else { /* * We do not test the found page on validity. Modified: head/sys/kern/vfs_bio.c ============================================================================== --- head/sys/kern/vfs_bio.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/kern/vfs_bio.c Tue Mar 14 19:39:17 2017 (r315281) @@ -3894,7 +3894,7 @@ biodone(struct bio *bp) start = trunc_page((vm_offset_t)bp->bio_data); end = round_page((vm_offset_t)bp->bio_data + bp->bio_length); bp->bio_data = unmapped_buf; - pmap_qremove(start, OFF_TO_IDX(end - start)); + pmap_qremove(start, atop(end - start)); vmem_free(transient_arena, start, end - start); atomic_add_int(&inflight_transient_maps, -1); } Modified: head/sys/vm/vm_fault.c ============================================================================== --- head/sys/vm/vm_fault.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/vm/vm_fault.c Tue Mar 14 19:39:17 2017 (r315281) @@ -1544,7 +1544,7 @@ vm_fault_copy_entry(vm_map_t dst_map, vm * actually shadow anything - we copy the pages directly.) */ dst_object = vm_object_allocate(OBJT_DEFAULT, - OFF_TO_IDX(dst_entry->end - dst_entry->start)); + atop(dst_entry->end - dst_entry->start)); #if VM_NRESERVLEVEL > 0 dst_object->flags |= OBJ_COLORED; dst_object->pg_color = atop(dst_entry->start); Modified: head/sys/vm/vm_kern.c ============================================================================== --- head/sys/vm/vm_kern.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/vm/vm_kern.c Tue Mar 14 19:39:17 2017 (r315281) @@ -165,8 +165,7 @@ kmem_alloc_attr(vmem_t *vmem, vm_size_t vm_paddr_t high, vm_memattr_t memattr) { vm_object_t object = vmem == kmem_arena ? kmem_object : kernel_object; - vm_offset_t addr, i; - vm_ooffset_t offset; + vm_offset_t addr, i, offset; vm_page_t m; int pflags, tries; @@ -179,7 +178,7 @@ kmem_alloc_attr(vmem_t *vmem, vm_size_t for (i = 0; i < size; i += PAGE_SIZE) { tries = 0; retry: - m = vm_page_alloc_contig(object, OFF_TO_IDX(offset + i), + m = vm_page_alloc_contig(object, atop(offset + i), pflags, 1, low, high, PAGE_SIZE, 0, memattr); if (m == NULL) { VM_OBJECT_WUNLOCK(object); @@ -220,8 +219,7 @@ kmem_alloc_contig(struct vmem *vmem, vm_ vm_memattr_t memattr) { vm_object_t object = vmem == kmem_arena ? kmem_object : kernel_object; - vm_offset_t addr, tmp; - vm_ooffset_t offset; + vm_offset_t addr, offset, tmp; vm_page_t end_m, m; u_long npages; int pflags, tries; @@ -235,7 +233,7 @@ kmem_alloc_contig(struct vmem *vmem, vm_ VM_OBJECT_WLOCK(object); tries = 0; retry: - m = vm_page_alloc_contig(object, OFF_TO_IDX(offset), pflags, + m = vm_page_alloc_contig(object, atop(offset), pflags, npages, low, high, alignment, boundary, memattr); if (m == NULL) { VM_OBJECT_WUNLOCK(object); @@ -346,7 +344,7 @@ kmem_back(vm_object_t object, vm_offset_ VM_OBJECT_WLOCK(object); for (i = 0; i < size; i += PAGE_SIZE) { retry: - m = vm_page_alloc(object, OFF_TO_IDX(offset + i), pflags); + m = vm_page_alloc(object, atop(offset + i), pflags); /* * Ran out of space, free everything up and return. Don't need @@ -398,7 +396,7 @@ kmem_unback(vm_object_t object, vm_offse offset = addr - VM_MIN_KERNEL_ADDRESS; VM_OBJECT_WLOCK(object); for (i = 0; i < size; i += PAGE_SIZE) { - m = vm_page_lookup(object, OFF_TO_IDX(offset + i)); + m = vm_page_lookup(object, atop(offset + i)); vm_page_unwire(m, PQ_NONE); vm_page_free(m); } Modified: head/sys/vm/vm_map.c ============================================================================== --- head/sys/vm/vm_map.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/vm/vm_map.c Tue Mar 14 19:39:17 2017 (r315281) @@ -2903,7 +2903,7 @@ vm_map_entry_delete(vm_map_t map, vm_map { vm_object_t object; vm_pindex_t offidxstart, offidxend, count, size1; - vm_ooffset_t size; + vm_size_t size; vm_map_entry_unlink(map, entry); object = entry->object.vm_object; @@ -2920,7 +2920,7 @@ vm_map_entry_delete(vm_map_t map, vm_map KASSERT(entry->cred == NULL || object->cred == NULL || (entry->eflags & MAP_ENTRY_NEEDS_COPY), ("OVERCOMMIT vm_map_entry_delete: both cred %p", entry)); - count = OFF_TO_IDX(size); + count = atop(size); offidxstart = OFF_TO_IDX(entry->offset); offidxend = offidxstart + count; VM_OBJECT_WLOCK(object); Modified: head/sys/vm/vm_mmap.c ============================================================================== --- head/sys/vm/vm_mmap.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/vm/vm_mmap.c Tue Mar 14 19:39:17 2017 (r315281) @@ -885,7 +885,7 @@ RestartScan: /* * calculate index into user supplied byte vector */ - vecindex = OFF_TO_IDX(addr - first_addr); + vecindex = atop(addr - first_addr); /* * If we have skipped map entries, we need to make sure that @@ -931,7 +931,7 @@ RestartScan: /* * Zero the last entries in the byte vector. */ - vecindex = OFF_TO_IDX(end - first_addr); + vecindex = atop(end - first_addr); while ((lastvecindex + 1) < vecindex) { ++lastvecindex; error = subyte(vec + lastvecindex, 0); Modified: head/sys/vm/vm_object.c ============================================================================== --- head/sys/vm/vm_object.c Tue Mar 14 19:06:44 2017 (r315280) +++ head/sys/vm/vm_object.c Tue Mar 14 19:39:17 2017 (r315281) @@ -273,16 +273,16 @@ vm_object_init(void) mtx_init(&vm_object_list_mtx, "vm object_list", NULL, MTX_DEF); rw_init(&kernel_object->lock, "kernel vm object"); - _vm_object_allocate(OBJT_PHYS, OFF_TO_IDX(VM_MAX_KERNEL_ADDRESS - VM_MIN_KERNEL_ADDRESS), - kernel_object); + _vm_object_allocate(OBJT_PHYS, atop(VM_MAX_KERNEL_ADDRESS - + VM_MIN_KERNEL_ADDRESS), kernel_object); #if VM_NRESERVLEVEL > 0 kernel_object->flags |= OBJ_COLORED; kernel_object->pg_color = (u_short)atop(VM_MIN_KERNEL_ADDRESS); #endif rw_init(&kmem_object->lock, "kmem vm object"); - _vm_object_allocate(OBJT_PHYS, OFF_TO_IDX(VM_MAX_KERNEL_ADDRESS - VM_MIN_KERNEL_ADDRESS), - kmem_object); + _vm_object_allocate(OBJT_PHYS, atop(VM_MAX_KERNEL_ADDRESS - + VM_MIN_KERNEL_ADDRESS), kmem_object); #if VM_NRESERVLEVEL > 0 kmem_object->flags |= OBJ_COLORED; kmem_object->pg_color = (u_short)atop(VM_MIN_KERNEL_ADDRESS); @@ -1028,7 +1028,7 @@ vm_object_sync(vm_object_t object, vm_oo (void) vn_start_write(vp, &mp, V_WAIT); vn_lock(vp, LK_EXCLUSIVE | LK_RETRY); if (syncio && !invalidate && offset == 0 && - OFF_TO_IDX(size) == object->size) { + atop(size) == object->size) { /* * If syncing the whole mapping of the file, * it is faster to schedule all the writes in From owner-svn-src-all@freebsd.org Tue Mar 14 20:14:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5AB93D0C7E9; Tue, 14 Mar 2017 20:14:59 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2324C1A2E; Tue, 14 Mar 2017 20:14:59 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EKEw1H026170; Tue, 14 Mar 2017 20:14:58 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EKEvsY026163; Tue, 14 Mar 2017 20:14:57 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703142014.v2EKEvsY026163@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Tue, 14 Mar 2017 20:14:57 +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: r315282 - in stable/11: include lib/libthr/thread sys/sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 20:14:59 -0000 Author: pfg Date: Tue Mar 14 20:14:57 2017 New Revision: 315282 URL: https://svnweb.freebsd.org/changeset/base/315282 Log: MFC r312934: Make use of clang nullability attributes in C headers. Replace uses of the GCC __nonnull__ attribute with the clang nullability qualifiers. These are starting to get use in clang's static analyzer. Replacement should be transparent for developers using clang. GCC ports from older FreeBSD versions may need updating if the compiler was built before r312860 (Jan-27-2017). Hinted by: Apple's Libc-1158.20.4, Bionic libc Relnotes: yes Modified: stable/11/include/err.h stable/11/include/pthread.h stable/11/include/signal.h stable/11/include/stdio.h stable/11/include/stdlib.h stable/11/lib/libthr/thread/thr_private.h stable/11/sys/sys/systm.h Directory Properties: stable/11/ (props changed) Modified: stable/11/include/err.h ============================================================================== --- stable/11/include/err.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/include/err.h Tue Mar 14 20:14:57 2017 (r315282) @@ -43,6 +43,8 @@ #include #include +__NULLABILITY_PRAGMA_PUSH + __BEGIN_DECLS void err(int, const char *, ...) __dead2 __printf0like(2, 3); void verr(int, const char *, __va_list) __dead2 __printf0like(2, 0); @@ -58,7 +60,8 @@ void vwarnc(int, const char *, __va_list void warnx(const char *, ...) __printflike(1, 2); void vwarnx(const char *, __va_list) __printflike(1, 0); void err_set_file(void *); -void err_set_exit(void (*)(int)); +void err_set_exit(void (* _Nullable)(int)); __END_DECLS +__NULLABILITY_PRAGMA_POP #endif /* !_ERR_H_ */ Modified: stable/11/include/pthread.h ============================================================================== --- stable/11/include/pthread.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/include/pthread.h Tue Mar 14 20:14:57 2017 (r315282) @@ -46,6 +46,8 @@ #include #include +__NULLABILITY_PRAGMA_PUSH + /* * Run-time invariant values: */ @@ -147,28 +149,35 @@ struct _pthread_cleanup_info { */ __BEGIN_DECLS int pthread_atfork(void (*)(void), void (*)(void), void (*)(void)); -int pthread_attr_destroy(pthread_attr_t *); -int pthread_attr_getstack(const pthread_attr_t * __restrict, - void ** __restrict, size_t * __restrict); -int pthread_attr_getstacksize(const pthread_attr_t *, size_t *); -int pthread_attr_getguardsize(const pthread_attr_t *, size_t *); +int pthread_attr_destroy(pthread_attr_t * _Nonnull); +int pthread_attr_getstack( + const pthread_attr_t * _Nonnull __restrict, + void ** _Nonnull __restrict, + size_t * _Nonnull __restrict); +int pthread_attr_getstacksize(const pthread_attr_t * _Nonnull, + size_t * _Nonnull); +int pthread_attr_getguardsize(const pthread_attr_t * _Nonnull, + size_t * _Nonnull); int pthread_attr_getstackaddr(const pthread_attr_t *, void **); -int pthread_attr_getdetachstate(const pthread_attr_t *, int *); -int pthread_attr_init(pthread_attr_t *); -int pthread_attr_setstacksize(pthread_attr_t *, size_t); -int pthread_attr_setguardsize(pthread_attr_t *, size_t); -int pthread_attr_setstack(pthread_attr_t *, void *, size_t); +int pthread_attr_getdetachstate(const pthread_attr_t * _Nonnull, + int * _Nonnull); +int pthread_attr_init(pthread_attr_t * _Nonnull); +int pthread_attr_setstacksize(pthread_attr_t * _Nonnull, size_t); +int pthread_attr_setguardsize(pthread_attr_t * _Nonnull, size_t); +int pthread_attr_setstack(pthread_attr_t * _Nonnull, void *, + size_t); int pthread_attr_setstackaddr(pthread_attr_t *, void *); -int pthread_attr_setdetachstate(pthread_attr_t *, int); -int pthread_barrier_destroy(pthread_barrier_t *); -int pthread_barrier_init(pthread_barrier_t *, +int pthread_attr_setdetachstate(pthread_attr_t * _Nonnull, int); +int pthread_barrier_destroy(pthread_barrier_t * _Nonnull); +int pthread_barrier_init(pthread_barrier_t * _Nonnull, const pthread_barrierattr_t *, unsigned); -int pthread_barrier_wait(pthread_barrier_t *); -int pthread_barrierattr_destroy(pthread_barrierattr_t *); -int pthread_barrierattr_getpshared(const pthread_barrierattr_t *, - int *); -int pthread_barrierattr_init(pthread_barrierattr_t *); -int pthread_barrierattr_setpshared(pthread_barrierattr_t *, int); +int pthread_barrier_wait(pthread_barrier_t * _Nonnull); +int pthread_barrierattr_destroy(pthread_barrierattr_t * _Nonnull); +int pthread_barrierattr_getpshared( + const pthread_barrierattr_t * _Nonnull, int * _Nonnull); +int pthread_barrierattr_init(pthread_barrierattr_t * _Nonnull); +int pthread_barrierattr_setpshared(pthread_barrierattr_t * _Nonnull, + int); #define pthread_cleanup_push(cleanup_routine, cleanup_arg) \ { \ @@ -183,100 +192,109 @@ int pthread_barrierattr_setpshared(pthr __pthread_cleanup_pop_imp(execute); \ } -int pthread_condattr_destroy(pthread_condattr_t *); -int pthread_condattr_getclock(const pthread_condattr_t *, - clockid_t *); -int pthread_condattr_getpshared(const pthread_condattr_t *, int *); -int pthread_condattr_init(pthread_condattr_t *); -int pthread_condattr_setclock(pthread_condattr_t *, clockid_t); -int pthread_condattr_setpshared(pthread_condattr_t *, int); -int pthread_cond_broadcast(pthread_cond_t *); -int pthread_cond_destroy(pthread_cond_t *); -int pthread_cond_init(pthread_cond_t *, +int pthread_condattr_destroy(pthread_condattr_t * _Nonnull); +int pthread_condattr_getclock(const pthread_condattr_t * _Nonnull, + clockid_t * _Nonnull); +int pthread_condattr_getpshared(const pthread_condattr_t * _Nonnull, + int * _Nonnull); +int pthread_condattr_init(pthread_condattr_t * _Nonnull); +int pthread_condattr_setclock(pthread_condattr_t * _Nonnull, + clockid_t); +int pthread_condattr_setpshared(pthread_condattr_t * _Nonnull, int); +int pthread_cond_broadcast(pthread_cond_t * _Nonnull); +int pthread_cond_destroy(pthread_cond_t * _Nonnull); +int pthread_cond_init(pthread_cond_t * _Nonnull, const pthread_condattr_t *); -int pthread_cond_signal(pthread_cond_t *); -int pthread_cond_timedwait(pthread_cond_t *, - pthread_mutex_t *__mutex, const struct timespec *) +int pthread_cond_signal(pthread_cond_t * _Nonnull); +int pthread_cond_timedwait(pthread_cond_t * _Nonnull, + pthread_mutex_t * _Nonnull __mutex, + const struct timespec * _Nonnull) __requires_exclusive(*__mutex); -int pthread_cond_wait(pthread_cond_t *, pthread_mutex_t *__mutex) +int pthread_cond_wait(pthread_cond_t * _Nonnull, + pthread_mutex_t * _Nonnull __mutex) __requires_exclusive(*__mutex); -int pthread_create(pthread_t *, const pthread_attr_t *, - void *(*) (void *), void *); +int pthread_create(pthread_t * _Nonnull, const pthread_attr_t *, + void *(* _Nonnull) (void *), void *); int pthread_detach(pthread_t); int pthread_equal(pthread_t, pthread_t); void pthread_exit(void *) __dead2; void *pthread_getspecific(pthread_key_t); -int pthread_getcpuclockid(pthread_t, clockid_t *); +int pthread_getcpuclockid(pthread_t, clockid_t * _Nonnull); int pthread_join(pthread_t, void **); -int pthread_key_create(pthread_key_t *, - void (*) (void *)); +int pthread_key_create(pthread_key_t * _Nonnull, + void (*) (void *)); int pthread_key_delete(pthread_key_t); -int pthread_mutexattr_init(pthread_mutexattr_t *); -int pthread_mutexattr_destroy(pthread_mutexattr_t *); -int pthread_mutexattr_getpshared(const pthread_mutexattr_t *, - int *); -int pthread_mutexattr_gettype(pthread_mutexattr_t *, int *); -int pthread_mutexattr_settype(pthread_mutexattr_t *, int); -int pthread_mutexattr_setpshared(pthread_mutexattr_t *, int); -int pthread_mutex_consistent(pthread_mutex_t *__mutex) - __nonnull(1) __requires_exclusive(*__mutex); -int pthread_mutex_destroy(pthread_mutex_t *__mutex) +int pthread_mutexattr_init(pthread_mutexattr_t * _Nonnull); +int pthread_mutexattr_destroy(pthread_mutexattr_t * _Nonnull); +int pthread_mutexattr_getpshared( + const pthread_mutexattr_t * _Nonnull, int * _Nonnull); +int pthread_mutexattr_gettype(pthread_mutexattr_t * _Nonnull, + int * _Nonnull); +int pthread_mutexattr_settype(pthread_mutexattr_t * _Nonnull, int); +int pthread_mutexattr_setpshared(pthread_mutexattr_t * _Nonnull, + int); +int pthread_mutex_consistent(pthread_mutex_t * _Nonnull __mutex) + __requires_exclusive(*__mutex); +int pthread_mutex_destroy(pthread_mutex_t * _Nonnull __mutex) __requires_unlocked(*__mutex); -int pthread_mutex_init(pthread_mutex_t *__mutex, - const pthread_mutexattr_t *) +int pthread_mutex_init(pthread_mutex_t * _Nonnull __mutex, + const pthread_mutexattr_t *) __requires_unlocked(*__mutex); -int pthread_mutex_lock(pthread_mutex_t *__mutex) - __locks_exclusive(*__mutex); -int pthread_mutex_trylock(pthread_mutex_t *__mutex) - __trylocks_exclusive(0, *__mutex); -int pthread_mutex_timedlock(pthread_mutex_t *__mutex, - const struct timespec *) - __trylocks_exclusive(0, *__mutex); -int pthread_mutex_unlock(pthread_mutex_t *__mutex) +int pthread_mutex_lock(pthread_mutex_t * _Nonnull __mutex) + __locks_exclusive(*__mutex); +int pthread_mutex_trylock(pthread_mutex_t * _Nonnull __mutex) + __trylocks_exclusive(0, *__mutex); +int pthread_mutex_timedlock(pthread_mutex_t * _Nonnull __mutex, + const struct timespec * _Nonnull) + __trylocks_exclusive(0, *__mutex); +int pthread_mutex_unlock(pthread_mutex_t * _Nonnull __mutex) __unlocks(*__mutex); -int pthread_once(pthread_once_t *, void (*) (void)); -int pthread_rwlock_destroy(pthread_rwlock_t *__rwlock) +int pthread_once(pthread_once_t * _Nonnull, + void (* _Nonnull) (void)); +int pthread_rwlock_destroy(pthread_rwlock_t * _Nonnull __rwlock) __requires_unlocked(*__rwlock); -int pthread_rwlock_init(pthread_rwlock_t *__rwlock, - const pthread_rwlockattr_t *) +int pthread_rwlock_init(pthread_rwlock_t * _Nonnull __rwlock, + const pthread_rwlockattr_t *) __requires_unlocked(*__rwlock); -int pthread_rwlock_rdlock(pthread_rwlock_t *__rwlock) - __locks_shared(*__rwlock); -int pthread_rwlock_timedrdlock(pthread_rwlock_t *__rwlock, - const struct timespec *) - __trylocks_shared(0, *__rwlock); -int pthread_rwlock_timedwrlock(pthread_rwlock_t *__rwlock, - const struct timespec *) - __trylocks_exclusive(0, *__rwlock); -int pthread_rwlock_tryrdlock(pthread_rwlock_t *__rwlock) - __trylocks_shared(0, *__rwlock); -int pthread_rwlock_trywrlock(pthread_rwlock_t *__rwlock) - __trylocks_exclusive(0, *__rwlock); -int pthread_rwlock_unlock(pthread_rwlock_t *__rwlock) +int pthread_rwlock_rdlock(pthread_rwlock_t * _Nonnull __rwlock) + __locks_shared(*__rwlock); +int pthread_rwlock_timedrdlock(pthread_rwlock_t * _Nonnull __rwlock, + const struct timespec * _Nonnull) + __trylocks_shared(0, *__rwlock); +int pthread_rwlock_timedwrlock(pthread_rwlock_t * _Nonnull __rwlock, + const struct timespec * _Nonnull) + __trylocks_exclusive(0, *__rwlock); +int pthread_rwlock_tryrdlock(pthread_rwlock_t * _Nonnull __rwlock) + __trylocks_shared(0, *__rwlock); +int pthread_rwlock_trywrlock(pthread_rwlock_t * _Nonnull __rwlock) + __trylocks_exclusive(0, *__rwlock); +int pthread_rwlock_unlock(pthread_rwlock_t * _Nonnull __rwlock) __unlocks(*__rwlock); -int pthread_rwlock_wrlock(pthread_rwlock_t *__rwlock) - __locks_exclusive(*__rwlock); -int pthread_rwlockattr_destroy(pthread_rwlockattr_t *); -int pthread_rwlockattr_getkind_np(const pthread_rwlockattr_t *, - int *); -int pthread_rwlockattr_getpshared(const pthread_rwlockattr_t *, - int *); -int pthread_rwlockattr_init(pthread_rwlockattr_t *); -int pthread_rwlockattr_setkind_np(pthread_rwlockattr_t *, int); -int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *, int); +int pthread_rwlock_wrlock(pthread_rwlock_t * _Nonnull __rwlock) + __locks_exclusive(*__rwlock); +int pthread_rwlockattr_destroy(pthread_rwlockattr_t * _Nonnull); +int pthread_rwlockattr_getkind_np( + const pthread_rwlockattr_t * _Nonnull, int *); +int pthread_rwlockattr_getpshared( + const pthread_rwlockattr_t * _Nonnull, int * _Nonnull); +int pthread_rwlockattr_init(pthread_rwlockattr_t * _Nonnull); +int pthread_rwlockattr_setkind_np(pthread_rwlockattr_t * _Nonnull, + int); +int pthread_rwlockattr_setpshared(pthread_rwlockattr_t * _Nonnull, + int); pthread_t pthread_self(void); int pthread_setspecific(pthread_key_t, const void *); -int pthread_spin_init(pthread_spinlock_t *__spin, int) +int pthread_spin_init(pthread_spinlock_t * _Nonnull __spin, int) __requires_unlocked(*__spin); -int pthread_spin_destroy(pthread_spinlock_t *__spin) +int pthread_spin_destroy(pthread_spinlock_t * _Nonnull __spin) __requires_unlocked(*__spin); -int pthread_spin_lock(pthread_spinlock_t *__spin) - __locks_exclusive(*__spin); -int pthread_spin_trylock(pthread_spinlock_t *__spin) - __trylocks_exclusive(0, *__spin); -int pthread_spin_unlock(pthread_spinlock_t *__spin) - __unlocks(*__spin); +int pthread_spin_lock(pthread_spinlock_t * _Nonnull __spin) + __locks_exclusive(*__spin); +int pthread_spin_trylock(pthread_spinlock_t * _Nonnull __spin) + __trylocks_exclusive(0, *__spin); +int pthread_spin_unlock(pthread_spinlock_t * _Nonnull __spin) + __unlocks(*__spin); int pthread_cancel(pthread_t); int pthread_setcancelstate(int, int *); int pthread_setcanceltype(int, int *); @@ -288,35 +306,36 @@ int pthread_setprio(pthread_t, int); void pthread_yield(void); #endif -int pthread_mutexattr_getprioceiling(pthread_mutexattr_t *, - int *); -int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *, - int); +int pthread_mutexattr_getprioceiling(pthread_mutexattr_t *, int *); +int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *, int); int pthread_mutex_getprioceiling(pthread_mutex_t *, int *); int pthread_mutex_setprioceiling(pthread_mutex_t *, int, int *); int pthread_mutexattr_getprotocol(pthread_mutexattr_t *, int *); int pthread_mutexattr_setprotocol(pthread_mutexattr_t *, int); -int pthread_mutexattr_getrobust(pthread_mutexattr_t *__restrict, - int *__restrict) __nonnull_all; -int pthread_mutexattr_setrobust(pthread_mutexattr_t *, int) - __nonnull(1); +int pthread_mutexattr_getrobust( + pthread_mutexattr_t * _Nonnull __restrict, + int * _Nonnull __restrict); +int pthread_mutexattr_setrobust(pthread_mutexattr_t * _Nonnull, + int); int pthread_attr_getinheritsched(const pthread_attr_t *, int *); -int pthread_attr_getschedparam(const pthread_attr_t *, - struct sched_param *); -int pthread_attr_getschedpolicy(const pthread_attr_t *, int *); -int pthread_attr_getscope(const pthread_attr_t *, int *); +int pthread_attr_getschedparam(const pthread_attr_t * _Nonnull, + struct sched_param * _Nonnull); +int pthread_attr_getschedpolicy(const pthread_attr_t * _Nonnull, + int * _Nonnull); +int pthread_attr_getscope(const pthread_attr_t * _Nonnull, + int * _Nonnull); int pthread_attr_setinheritsched(pthread_attr_t *, int); -int pthread_attr_setschedparam(pthread_attr_t *, - const struct sched_param *); -int pthread_attr_setschedpolicy(pthread_attr_t *, int); -int pthread_attr_setscope(pthread_attr_t *, int); -int pthread_getschedparam(pthread_t pthread, int *, - struct sched_param *); +int pthread_attr_setschedparam(pthread_attr_t * _Nonnull, + const struct sched_param * _Nonnull); +int pthread_attr_setschedpolicy(pthread_attr_t * _Nonnull, int); +int pthread_attr_setscope(pthread_attr_t * _Nonnull, int); +int pthread_getschedparam(pthread_t pthread, int * _Nonnull, + struct sched_param * _Nonnull); int pthread_setschedparam(pthread_t, int, - const struct sched_param *); + const struct sched_param * _Nonnull); #if __XSI_VISIBLE int pthread_getconcurrency(void); int pthread_setconcurrency(int); @@ -326,5 +345,6 @@ void __pthread_cleanup_push_imp(void (* struct _pthread_cleanup_info *); void __pthread_cleanup_pop_imp(int); __END_DECLS +__NULLABILITY_PRAGMA_POP -#endif +#endif /* _PTHREAD_H_ */ Modified: stable/11/include/signal.h ============================================================================== --- stable/11/include/signal.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/include/signal.h Tue Mar 14 20:14:57 2017 (r315282) @@ -41,6 +41,8 @@ #include #endif +__NULLABILITY_PRAGMA_PUSH + #if __BSD_VISIBLE /* * XXX should enlarge these, if only to give empty names instead of bounds @@ -82,10 +84,11 @@ int sigdelset(sigset_t *, int); int sigemptyset(sigset_t *); int sigfillset(sigset_t *); int sigismember(const sigset_t *, int); -int sigpending(sigset_t *); +int sigpending(sigset_t * _Nonnull); int sigprocmask(int, const sigset_t * __restrict, sigset_t * __restrict); -int sigsuspend(const sigset_t *); -int sigwait(const sigset_t * __restrict, int * __restrict); +int sigsuspend(const sigset_t * _Nonnull); +int sigwait(const sigset_t * _Nonnull __restrict, + int * _Nonnull __restrict); #endif #if __POSIX_VISIBLE >= 199506 || __XSI_VISIBLE >= 600 @@ -104,7 +107,7 @@ int sighold(int); int sigignore(int); int sigpause(int); int sigrelse(int); -void (*sigset(int, void (*)(int)))(int); +void (* _Nullable sigset(int, void (* _Nullable)(int)))(int); int xsi_sigpause(int); #endif @@ -124,5 +127,6 @@ int sigstack(const struct sigstack *, st int sigvec(int, struct sigvec *, struct sigvec *); #endif __END_DECLS +__NULLABILITY_PRAGMA_POP #endif /* !_SIGNAL_H_ */ Modified: stable/11/include/stdio.h ============================================================================== --- stable/11/include/stdio.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/include/stdio.h Tue Mar 14 20:14:57 2017 (r315282) @@ -40,6 +40,8 @@ #include #include +__NULLABILITY_PRAGMA_PUSH + typedef __off_t fpos_t; #ifndef _SIZE_T_DECLARED @@ -123,10 +125,10 @@ struct __sFILE { /* operations */ void *_cookie; /* (*) cookie passed to io functions */ - int (*_close)(void *); - int (*_read)(void *, char *, int); - fpos_t (*_seek)(void *, fpos_t, int); - int (*_write)(void *, const char *, int); + int (* _Nullable _close)(void *); + int (* _Nullable _read)(void *, char *, int); + fpos_t (* _Nullable _seek)(void *, fpos_t, int); + int (* _Nullable _write)(void *, const char *, int); /* separate buffer for long sequences of ungetc() */ struct __sbuf _ub; /* ungetc buffer */ @@ -425,10 +427,10 @@ extern const char * const sys_errlist[]; * Stdio function-access interface. */ FILE *funopen(const void *, - int (*)(void *, char *, int), - int (*)(void *, const char *, int), - fpos_t (*)(void *, fpos_t, int), - int (*)(void *)); + int (* _Nullable)(void *, char *, int), + int (* _Nullable)(void *, const char *, int), + fpos_t (* _Nullable)(void *, fpos_t, int), + int (* _Nullable)(void *)); #define fropen(cookie, fn) funopen(cookie, fn, 0, 0, 0) #define fwopen(cookie, fn) funopen(cookie, 0, fn, 0, 0) @@ -541,4 +543,6 @@ extern int __isthreaded; #endif /* __cplusplus */ __END_DECLS +__NULLABILITY_PRAGMA_POP + #endif /* !_STDIO_H_ */ Modified: stable/11/include/stdlib.h ============================================================================== --- stable/11/include/stdlib.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/include/stdlib.h Tue Mar 14 20:14:57 2017 (r315282) @@ -37,6 +37,8 @@ #include #include +__NULLABILITY_PRAGMA_PUSH + #if __BSD_VISIBLE #ifndef _RUNE_T_DECLARED typedef __rune_t rune_t; @@ -81,12 +83,12 @@ extern int ___mb_cur_max(void); _Noreturn void abort(void); int abs(int) __pure2; -int atexit(void (*)(void)); +int atexit(void (* _Nonnull)(void)); double atof(const char *); int atoi(const char *); long atol(const char *); void *bsearch(const void *, const void *, size_t, - size_t, int (*)(const void *, const void *)); + size_t, int (*)(const void * _Nonnull, const void *)); void *calloc(size_t, size_t) __malloc_like __result_use_check __alloc_size(1) __alloc_size(2); div_t div(int, int) __pure2; @@ -100,7 +102,7 @@ int mblen(const char *, size_t); size_t mbstowcs(wchar_t * __restrict , const char * __restrict, size_t); int mbtowc(wchar_t * __restrict, const char * __restrict, size_t); void qsort(void *, size_t, size_t, - int (*)(const void *, const void *)); + int (* _Nonnull)(const void *, const void *)); int rand(void); void *realloc(void *, size_t) __result_use_check __alloc_size(2); void srand(unsigned); @@ -260,9 +262,9 @@ void arc4random_stir(void); __uint32_t arc4random_uniform(__uint32_t); #ifdef __BLOCKS__ -int atexit_b(void (^)(void)); +int atexit_b(void (^ _Nonnull)(void)); void *bsearch_b(const void *, const void *, size_t, - size_t, int (^)(const void *, const void *)); + size_t, int (^ _Nonnull)(const void *, const void *)); #endif char *getbsize(int *, long *); /* getcap(3) functions */ @@ -286,11 +288,13 @@ int getloadavg(double [], int); const char * getprogname(void); -int heapsort(void *, size_t, size_t, int (*)(const void *, const void *)); +int heapsort(void *, size_t, size_t, + int (* _Nonnull)(const void *, const void *)); #ifdef __BLOCKS__ -int heapsort_b(void *, size_t, size_t, int (^)(const void *, const void *)); +int heapsort_b(void *, size_t, size_t, + int (^ _Nonnull)(const void *, const void *)); void qsort_b(void *, size_t, size_t, - int (^)(const void *, const void *)); + int (^ _Nonnull)(const void *, const void *)); #endif int l64a_r(long, char *, int); int mergesort(void *, size_t, size_t, int (*)(const void *, const void *)); @@ -324,5 +328,6 @@ __uint64_t extern char *suboptarg; /* getsubopt(3) external variable */ #endif /* __BSD_VISIBLE */ __END_DECLS +__NULLABILITY_PRAGMA_POP #endif /* !_STDLIB_H_ */ Modified: stable/11/lib/libthr/thread/thr_private.h ============================================================================== --- stable/11/lib/libthr/thread/thr_private.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/lib/libthr/thread/thr_private.h Tue Mar 14 20:14:57 2017 (r315282) @@ -53,6 +53,8 @@ #include #include +__NULLABILITY_PRAGMA_PUSH + #define SYM_FB10(sym) __CONCAT(sym, _fb10) #define SYM_FBP10(sym) __CONCAT(sym, _fbp10) #define WEAK_REF(sym, alias) __weak_reference(sym, alias) @@ -835,11 +837,10 @@ void _pthread_cleanup_pop(int); void _pthread_exit_mask(void *status, sigset_t *mask) __dead2 __hidden; void _pthread_cancel_enter(int maycancel); void _pthread_cancel_leave(int maycancel); -int _pthread_mutex_consistent(pthread_mutex_t *) __nonnull(1); -int _pthread_mutexattr_getrobust(pthread_mutexattr_t *__restrict, - int *__restrict) __nonnull_all; -int _pthread_mutexattr_setrobust(pthread_mutexattr_t *, int) - __nonnull(1); +int _pthread_mutex_consistent(pthread_mutex_t * _Nonnull); +int _pthread_mutexattr_getrobust(pthread_mutexattr_t * _Nonnull __restrict, + int * _Nonnull __restrict); +int _pthread_mutexattr_setrobust(pthread_mutexattr_t * _Nonnull, int); /* #include */ #ifdef _SYS_FCNTL_H_ @@ -984,5 +985,6 @@ void __thr_pshared_atfork_pre(void) __hi void __thr_pshared_atfork_post(void) __hidden; __END_DECLS +__NULLABILITY_PRAGMA_POP #endif /* !_THR_PRIVATE_H */ Modified: stable/11/sys/sys/systm.h ============================================================================== --- stable/11/sys/sys/systm.h Tue Mar 14 19:39:17 2017 (r315281) +++ stable/11/sys/sys/systm.h Tue Mar 14 20:14:57 2017 (r315282) @@ -45,6 +45,8 @@ #include #include /* for people using printf mainly */ +__NULLABILITY_PRAGMA_PUSH + extern int cold; /* nonzero if we are doing a cold boot */ extern int suspend_blocked; /* block suspend due to pending shutdown */ extern int rebooting; /* kern_reboot() has been called. */ @@ -227,12 +229,12 @@ int vsnprintf(char *, size_t, const char int vsnrprintf(char *, size_t, int, const char *, __va_list) __printflike(4, 0); int vsprintf(char *buf, const char *, __va_list) __printflike(2, 0); int ttyprintf(struct tty *, const char *, ...) __printflike(2, 3); -int sscanf(const char *, char const *, ...) __nonnull(1) __nonnull(2); -int vsscanf(const char *, char const *, __va_list) __nonnull(1) __nonnull(2); -long strtol(const char *, char **, int) __nonnull(1); -u_long strtoul(const char *, char **, int) __nonnull(1); -quad_t strtoq(const char *, char **, int) __nonnull(1); -u_quad_t strtouq(const char *, char **, int) __nonnull(1); +int sscanf(const char *, char const * _Nonnull, ...) __scanflike(2, 3); +int vsscanf(const char * _Nonnull, char const * _Nonnull, __va_list) __scanflike(2, 0); +long strtol(const char *, char **, int); +u_long strtoul(const char *, char **, int); +quad_t strtoq(const char *, char **, int); +u_quad_t strtouq(const char *, char **, int); void tprintf(struct proc *p, int pri, const char *, ...) __printflike(3, 4); void vtprintf(struct proc *, int, const char *, __va_list) __printflike(3, 0); void hexdump(const void *ptr, int length, const char *hdr, int flags); @@ -243,27 +245,27 @@ void hexdump(const void *ptr, int length #define HD_OMIT_CHARS (1 << 18) #define ovbcopy(f, t, l) bcopy((f), (t), (l)) -void bcopy(const void *from, void *to, size_t len) __nonnull(1) __nonnull(2); -void bzero(void *buf, size_t len) __nonnull(1); -void explicit_bzero(void *, size_t) __nonnull(1); - -void *memcpy(void *to, const void *from, size_t len) __nonnull(1) __nonnull(2); -void *memmove(void *dest, const void *src, size_t n) __nonnull(1) __nonnull(2); - -int copystr(const void * __restrict kfaddr, void * __restrict kdaddr, - size_t len, size_t * __restrict lencopied) - __nonnull(1) __nonnull(2); -int copyinstr(const void * __restrict udaddr, void * __restrict kaddr, - size_t len, size_t * __restrict lencopied) - __nonnull(1) __nonnull(2); -int copyin(const void * __restrict udaddr, void * __restrict kaddr, - size_t len) __nonnull(1) __nonnull(2); -int copyin_nofault(const void * __restrict udaddr, void * __restrict kaddr, - size_t len) __nonnull(1) __nonnull(2); -int copyout(const void * __restrict kaddr, void * __restrict udaddr, - size_t len) __nonnull(1) __nonnull(2); -int copyout_nofault(const void * __restrict kaddr, void * __restrict udaddr, - size_t len) __nonnull(1) __nonnull(2); +void bcopy(const void * _Nonnull from, void * _Nonnull to, size_t len); +void bzero(void * _Nonnull buf, size_t len); +void explicit_bzero(void * _Nonnull, size_t); + +void *memcpy(void * _Nonnull to, const void * _Nonnull from, size_t len); +void *memmove(void * _Nonnull dest, const void * _Nonnull src, size_t n); + +int copystr(const void * _Nonnull __restrict kfaddr, + void * _Nonnull __restrict kdaddr, size_t len, + size_t * __restrict lencopied); +int copyinstr(const void * __restrict udaddr, + void * _Nonnull __restrict kaddr, size_t len, + size_t * __restrict lencopied); +int copyin(const void * _Nonnull __restrict udaddr, + void * _Nonnull __restrict kaddr, size_t len); +int copyin_nofault(const void * _Nonnull __restrict udaddr, + void * _Nonnull __restrict kaddr, size_t len); +int copyout(const void * _Nonnull __restrict kaddr, + void * _Nonnull __restrict udaddr, size_t len); +int copyout_nofault(const void * _Nonnull __restrict kaddr, + void * _Nonnull __restrict udaddr, size_t len); int fubyte(volatile const void *base); long fuword(volatile const void *base); @@ -377,16 +379,16 @@ static __inline void splx(intrmask_t ip * Common `proc' functions are declared here so that proc.h can be included * less often. */ -int _sleep(void *chan, struct lock_object *lock, int pri, const char *wmesg, - sbintime_t sbt, sbintime_t pr, int flags) __nonnull(1); +int _sleep(void * _Nonnull chan, struct lock_object *lock, int pri, + const char *wmesg, sbintime_t sbt, sbintime_t pr, int flags); #define msleep(chan, mtx, pri, wmesg, timo) \ _sleep((chan), &(mtx)->lock_object, (pri), (wmesg), \ tick_sbt * (timo), 0, C_HARDCLOCK) #define msleep_sbt(chan, mtx, pri, wmesg, bt, pr, flags) \ _sleep((chan), &(mtx)->lock_object, (pri), (wmesg), (bt), (pr), \ (flags)) -int msleep_spin_sbt(void *chan, struct mtx *mtx, const char *wmesg, - sbintime_t sbt, sbintime_t pr, int flags) __nonnull(1); +int msleep_spin_sbt(void * _Nonnull chan, struct mtx *mtx, + const char *wmesg, sbintime_t sbt, sbintime_t pr, int flags); #define msleep_spin(chan, mtx, wmesg, timo) \ msleep_spin_sbt((chan), (mtx), (wmesg), tick_sbt * (timo), \ 0, C_HARDCLOCK) @@ -399,8 +401,8 @@ int pause_sbt(const char *wmesg, sbintim 0, C_HARDCLOCK) #define tsleep_sbt(chan, pri, wmesg, bt, pr, flags) \ _sleep((chan), NULL, (pri), (wmesg), (bt), (pr), (flags)) -void wakeup(void *chan) __nonnull(1); -void wakeup_one(void *chan) __nonnull(1); +void wakeup(void * chan); +void wakeup_one(void * chan); /* * Common `struct cdev *' stuff are declared here to avoid #include poisoning @@ -446,4 +448,6 @@ void intr_prof_stack_use(struct thread * void counted_warning(unsigned *counter, const char *msg); +__NULLABILITY_PRAGMA_POP + #endif /* !_SYS_SYSTM_H_ */ From owner-svn-src-all@freebsd.org Tue Mar 14 20:31:11 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 742A9D0CB42; Tue, 14 Mar 2017 20:31:11 +0000 (UTC) (envelope-from tobik@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 43D442C5; Tue, 14 Mar 2017 20:31:11 +0000 (UTC) (envelope-from tobik@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EKVAcN031236; Tue, 14 Mar 2017 20:31:10 GMT (envelope-from tobik@FreeBSD.org) Received: (from tobik@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EKVAXt031235; Tue, 14 Mar 2017 20:31:10 GMT (envelope-from tobik@FreeBSD.org) Message-Id: <201703142031.v2EKVAXt031235@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tobik set sender to tobik@FreeBSD.org using -f From: Tobias Kortkamp Date: Tue, 14 Mar 2017 20:31:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315283 - head/lib/libsysdecode X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 20:31:11 -0000 Author: tobik (ports committer) Date: Tue Mar 14 20:31:10 2017 New Revision: 315283 URL: https://svnweb.freebsd.org/changeset/base/315283 Log: Fix sysdecode_cap_rights which currently prints bogus capability rights PR: 217787 Reviewed by: jhb, emaste Approved by: jhb Modified: head/lib/libsysdecode/flags.c Modified: head/lib/libsysdecode/flags.c ============================================================================== --- head/lib/libsysdecode/flags.c Tue Mar 14 20:14:57 2017 (r315282) +++ head/lib/libsysdecode/flags.c Tue Mar 14 20:31:10 2017 (r315283) @@ -962,23 +962,15 @@ sysdecode_umtx_rwlock_flags(FILE *fp, u_ return (print_mask_0ul(fp, umtxrwlockflags, flags, rem)); } -/* XXX: This should be in */ -#define CAPMASK(right) ((right) & (((uint64_t)1 << 57) - 1)) - void sysdecode_cap_rights(FILE *fp, cap_rights_t *rightsp) { struct name_table *t; - int idx; bool comma; comma = false; for (t = caprights; t->str != NULL; t++) { - idx = ffs(CAPIDXBIT(t->val)) - 1; - if (CAPARSIZE(rightsp) < idx) - continue; - if ((rightsp->cr_rights[CAPIDXBIT(t->val)] & CAPMASK(t->val)) == - CAPMASK(t->val)) { + if (cap_rights_is_set(rightsp, t->val)) { fprintf(fp, "%s%s", comma ? "," : "", t->str); comma = true; } From owner-svn-src-all@freebsd.org Tue Mar 14 20:39:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6DD5AD0D0A3; Tue, 14 Mar 2017 20:39:08 +0000 (UTC) (envelope-from mjg@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 3A270948; Tue, 14 Mar 2017 20:39:08 +0000 (UTC) (envelope-from mjg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EKd7sE034522; Tue, 14 Mar 2017 20:39:07 GMT (envelope-from mjg@FreeBSD.org) Received: (from mjg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EKd7Qk034518; Tue, 14 Mar 2017 20:39:07 GMT (envelope-from mjg@FreeBSD.org) Message-Id: <201703142039.v2EKd7Qk034518@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mjg set sender to mjg@FreeBSD.org using -f From: Mateusz Guzik Date: Tue, 14 Mar 2017 20:39: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: r315284 - in stable/11/sys: compat/linuxkpi/common/include/linux conf dev/drm2 sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 20:39:08 -0000 Author: mjg Date: Tue Mar 14 20:39:06 2017 New Revision: 315284 URL: https://svnweb.freebsd.org/changeset/base/315284 Log: MFC r312888: Introduce __read_mostly and __exclusive_cache_line macros. The intended use is to annotate frequently used globals which either rarely change (and thus can be grouped in the same cacheline) or are an atomic counter (which means it may benefit from being the only variable in the cacheline). Linker script support is provided only for amd64. Architectures without it risk having other variables put in, i.e. as if they were not annotated. This is harmless from correctness point of view. Modified: stable/11/sys/compat/linuxkpi/common/include/linux/compiler.h stable/11/sys/conf/ldscript.amd64 stable/11/sys/dev/drm2/drm_os_freebsd.h stable/11/sys/sys/systm.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/linuxkpi/common/include/linux/compiler.h ============================================================================== --- stable/11/sys/compat/linuxkpi/common/include/linux/compiler.h Tue Mar 14 20:31:10 2017 (r315283) +++ stable/11/sys/compat/linuxkpi/common/include/linux/compiler.h Tue Mar 14 20:39:06 2017 (r315284) @@ -67,7 +67,6 @@ #define typeof(x) __typeof(x) #define uninitialized_var(x) x = x -#define __read_mostly __attribute__((__section__(".data.read_mostly"))) #define __always_unused __unused #define __must_check __result_use_check Modified: stable/11/sys/conf/ldscript.amd64 ============================================================================== --- stable/11/sys/conf/ldscript.amd64 Tue Mar 14 20:31:10 2017 (r315283) +++ stable/11/sys/conf/ldscript.amd64 Tue Mar 14 20:39:06 2017 (r315284) @@ -145,6 +145,17 @@ SECTIONS .got : { *(.got) } . = DATA_SEGMENT_RELRO_END (24, .); .got.plt : { *(.got.plt) } + . = ALIGN(64); + .data.read_mostly : + { + *(.data.read_mostly) + } + . = ALIGN(64); + .data.exclusive_cache_line : + { + *(.data.exclusive_cache_line) + } + . = ALIGN(64); .data : { *(.data .data.* .gnu.linkonce.d.*) Modified: stable/11/sys/dev/drm2/drm_os_freebsd.h ============================================================================== --- stable/11/sys/dev/drm2/drm_os_freebsd.h Tue Mar 14 20:31:10 2017 (r315283) +++ stable/11/sys/dev/drm2/drm_os_freebsd.h Tue Mar 14 20:39:06 2017 (r315284) @@ -80,7 +80,6 @@ typedef void irqreturn_t; #define __init #define __exit -#define __read_mostly #define BUILD_BUG_ON(x) CTASSERT(!(x)) #define BUILD_BUG_ON_NOT_POWER_OF_2(x) Modified: stable/11/sys/sys/systm.h ============================================================================== --- stable/11/sys/sys/systm.h Tue Mar 14 20:31:10 2017 (r315283) +++ stable/11/sys/sys/systm.h Tue Mar 14 20:39:06 2017 (r315284) @@ -131,6 +131,12 @@ void kassert_panic(const char *fmt, ...) #define SCHEDULER_STOPPED() __predict_false(curthread->td_stopsched) /* + * Align variables. + */ +#define __read_mostly __section(".data.read_mostly") +#define __exclusive_cache_line __aligned(CACHE_LINE_SIZE) \ + __section(".data.exclusive_cache_line") +/* * XXX the hints declarations are even more misplaced than most declarations * in this file, since they are needed in one file (per arch) and only used * in two files. From owner-svn-src-all@freebsd.org Tue Mar 14 20:43:06 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 19C63D0D2C8; Tue, 14 Mar 2017 20:43:06 +0000 (UTC) (envelope-from mjg@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 D0167F58; Tue, 14 Mar 2017 20:43:05 +0000 (UTC) (envelope-from mjg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EKh4jx038785; Tue, 14 Mar 2017 20:43:04 GMT (envelope-from mjg@FreeBSD.org) Received: (from mjg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EKh4Wh038781; Tue, 14 Mar 2017 20:43:04 GMT (envelope-from mjg@FreeBSD.org) Message-Id: <201703142043.v2EKh4Wh038781@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mjg set sender to mjg@FreeBSD.org using -f From: Mateusz Guzik Date: Tue, 14 Mar 2017 20:43: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: r315285 - in stable/11/sys: kern sys vm X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 20:43:06 -0000 Author: mjg Date: Tue Mar 14 20:43:04 2017 New Revision: 315285 URL: https://svnweb.freebsd.org/changeset/base/315285 Log: MFC r312724,r312901,r312902: hwpmc: partially depessimize munmap handling if the module is not loaded HWPMC_HOOKS is enabled in GENERIC and triggers some work avoidable in the common (module not loaded) case. In particular this avoids permission checks + lock downgrade singlethreaded and in cases were an executable mapping is found the pmc sx lock is no longer bounced. Note this is a band aid. == hwpmc: partially depessimize mmap handling if the module is not loaded In particular this means the pmc sx lock is no longer taken when an executable mapping succeeds. == hwpmc: annotate pmc_hook and pmc_intr as __read_mostly Modified: stable/11/sys/kern/kern_pmc.c stable/11/sys/kern/vfs_vnops.c stable/11/sys/sys/pmckern.h stable/11/sys/vm/vm_mmap.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_pmc.c ============================================================================== --- stable/11/sys/kern/kern_pmc.c Tue Mar 14 20:39:06 2017 (r315284) +++ stable/11/sys/kern/kern_pmc.c Tue Mar 14 20:43:04 2017 (r315285) @@ -59,10 +59,10 @@ MALLOC_DEFINE(M_PMCHOOKS, "pmchooks", "M const int pmc_kernel_version = PMC_KERNEL_VERSION; /* Hook variable. */ -int (*pmc_hook)(struct thread *td, int function, void *arg) = NULL; +int __read_mostly (*pmc_hook)(struct thread *td, int function, void *arg) = NULL; /* Interrupt handler */ -int (*pmc_intr)(int cpu, struct trapframe *tf) = NULL; +int __read_mostly (*pmc_intr)(int cpu, struct trapframe *tf) = NULL; /* Bitmask of CPUs requiring servicing at hardclock time */ volatile cpuset_t pmc_cpumask; Modified: stable/11/sys/kern/vfs_vnops.c ============================================================================== --- stable/11/sys/kern/vfs_vnops.c Tue Mar 14 20:39:06 2017 (r315284) +++ stable/11/sys/kern/vfs_vnops.c Tue Mar 14 20:43:04 2017 (r315285) @@ -2479,10 +2479,12 @@ vn_mmap(struct file *fp, vm_map_t map, v } #ifdef HWPMC_HOOKS /* Inform hwpmc(4) if an executable is being mapped. */ - if (error == 0 && (prot & VM_PROT_EXECUTE) != 0) { - pkm.pm_file = vp; - pkm.pm_address = (uintptr_t) *addr; - PMC_CALL_HOOK(td, PMC_FN_MMAP, (void *) &pkm); + if (PMC_HOOK_INSTALLED(PMC_FN_MMAP)) { + if ((prot & VM_PROT_EXECUTE) != 0 && error == 0) { + pkm.pm_file = vp; + pkm.pm_address = (uintptr_t) *addr; + PMC_CALL_HOOK(td, PMC_FN_MMAP, (void *) &pkm); + } } #endif return (error); Modified: stable/11/sys/sys/pmckern.h ============================================================================== --- stable/11/sys/sys/pmckern.h Tue Mar 14 20:39:06 2017 (r315284) +++ stable/11/sys/sys/pmckern.h Tue Mar 14 20:43:04 2017 (r315285) @@ -174,6 +174,9 @@ extern const int pmc_kernel_version; /* PMC soft per cpu trapframe */ extern struct trapframe pmc_tf[MAXCPU]; +/* Quick check if preparatory work is necessary */ +#define PMC_HOOK_INSTALLED(cmd) __predict_false(pmc_hook != NULL) + /* Hook invocation; for use within the kernel */ #define PMC_CALL_HOOK(t, cmd, arg) \ do { \ Modified: stable/11/sys/vm/vm_mmap.c ============================================================================== --- stable/11/sys/vm/vm_mmap.c Tue Mar 14 20:39:06 2017 (r315284) +++ stable/11/sys/vm/vm_mmap.c Tue Mar 14 20:43:04 2017 (r315285) @@ -500,6 +500,7 @@ kern_munmap(struct thread *td, uintptr_t #ifdef HWPMC_HOOKS struct pmckern_map_out pkm; vm_map_entry_t entry; + bool pmc_handled; #endif vm_offset_t addr; vm_size_t pageoff; @@ -524,20 +525,24 @@ kern_munmap(struct thread *td, uintptr_t return (EINVAL); vm_map_lock(map); #ifdef HWPMC_HOOKS - /* - * Inform hwpmc if the address range being unmapped contains - * an executable region. - */ - pkm.pm_address = (uintptr_t) NULL; - if (vm_map_lookup_entry(map, addr, &entry)) { - for (; - entry != &map->header && entry->start < addr + size; - entry = entry->next) { - if (vm_map_check_protection(map, entry->start, - entry->end, VM_PROT_EXECUTE) == TRUE) { - pkm.pm_address = (uintptr_t) addr; - pkm.pm_size = (size_t) size; - break; + pmc_handled = false; + if (PMC_HOOK_INSTALLED(PMC_FN_MUNMAP)) { + pmc_handled = true; + /* + * Inform hwpmc if the address range being unmapped contains + * an executable region. + */ + pkm.pm_address = (uintptr_t) NULL; + if (vm_map_lookup_entry(map, addr, &entry)) { + for (; + entry != &map->header && entry->start < addr + size; + entry = entry->next) { + if (vm_map_check_protection(map, entry->start, + entry->end, VM_PROT_EXECUTE) == TRUE) { + pkm.pm_address = (uintptr_t) addr; + pkm.pm_size = (size_t) size; + break; + } } } } @@ -545,14 +550,16 @@ kern_munmap(struct thread *td, uintptr_t vm_map_delete(map, addr, addr + size); #ifdef HWPMC_HOOKS - /* downgrade the lock to prevent a LOR with the pmc-sx lock */ - vm_map_lock_downgrade(map); - if (pkm.pm_address != (uintptr_t) NULL) - PMC_CALL_HOOK(td, PMC_FN_MUNMAP, (void *) &pkm); - vm_map_unlock_read(map); -#else - vm_map_unlock(map); + if (__predict_false(pmc_handled)) { + /* downgrade the lock to prevent a LOR with the pmc-sx lock */ + vm_map_lock_downgrade(map); + if (pkm.pm_address != (uintptr_t) NULL) + PMC_CALL_HOOK(td, PMC_FN_MUNMAP, (void *) &pkm); + vm_map_unlock_read(map); + } else #endif + vm_map_unlock(map); + /* vm_map_delete returns nothing but KERN_SUCCESS anyway */ return (0); } From owner-svn-src-all@freebsd.org Tue Mar 14 20:57:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4697AD0D77A; Tue, 14 Mar 2017 20:57:56 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 080CD188B; Tue, 14 Mar 2017 20:57:55 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EKvtSf043038; Tue, 14 Mar 2017 20:57:55 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EKvssk043033; Tue, 14 Mar 2017 20:57:54 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201703142057.v2EKvssk043033@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 14 Mar 2017 20:57:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315286 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 20:57:56 -0000 Author: vangyzen Date: Tue Mar 14 20:57:54 2017 New Revision: 315286 URL: https://svnweb.freebsd.org/changeset/base/315286 Log: Add some ntohl() love to r315277 inet_ntoa() and inet_ntoa_r() take the address in network byte-order. When I removed those calls, I should have replaced them with ntohl() to make the hex addresses slightly less unreadable. Here they are. See r315277 regarding classic blunders. vangyzen: you're deep in "no good deed" territory, it seems --badger Reported by: ian MFC after: 3 days MFC when: I finally get it right Sponsored by: Dell EMC Modified: head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c head/sys/netinet/igmp.c head/sys/netinet/in_mcast.c head/sys/netinet/ip_mroute.c Modified: head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c ============================================================================== --- head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 20:43:04 2017 (r315285) +++ head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 20:57:54 2017 (r315286) @@ -1479,7 +1479,8 @@ process_data(struct iwch_ep *ep) in_getsockaddr(ep->com.so, (struct sockaddr **)&local); in_getpeeraddr(ep->com.so, (struct sockaddr **)&remote); CTR3(KTR_IW_CXGB, "%s local 0x%08x remote 0x%08x", __FUNCTION__, - local->sin_addr.s_addr, remote->sin_addr.s_addr); + ntohl(local->sin_addr.s_addr), + ntohl(remote->sin_addr.s_addr)); ep->com.local_addr = *local; ep->com.remote_addr = *remote; free(local, M_SONAME); @@ -1538,7 +1539,7 @@ process_newconn(struct iw_cm_id *parent_ in_getpeeraddr(child_so, (struct sockaddr **)&remote); CTR3(KTR_IW_CXGB, "%s remote addr 0x%08x port %d", __FUNCTION__, - remote->sin_addr.s_addr, ntohs(remote->sin_port)); + ntohl(remote->sin_addr.s_addr), ntohs(remote->sin_port)); child_ep->com.tdev = parent_ep->com.tdev; child_ep->com.local_addr.sin_family = parent_ep->com.local_addr.sin_family; child_ep->com.local_addr.sin_port = parent_ep->com.local_addr.sin_port; Modified: head/sys/netinet/igmp.c ============================================================================== --- head/sys/netinet/igmp.c Tue Mar 14 20:43:04 2017 (r315285) +++ head/sys/netinet/igmp.c Tue Mar 14 20:57:54 2017 (r315286) @@ -863,7 +863,7 @@ igmp_input_v2_query(struct ifnet *ifp, c if (inm != NULL) { CTR3(KTR_IGMPV3, "process v2 query 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, ifp->if_xname); + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); igmp_v2_update_group(inm, timer); } } @@ -895,7 +895,7 @@ igmp_v2_update_group(struct in_multi *in { CTR4(KTR_IGMPV3, "0x%08x: %s/%s timer=%d", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname, timer); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname, timer); IN_MULTI_LOCK_ASSERT(); @@ -1076,7 +1076,7 @@ igmp_input_v3_query(struct ifnet *ifp, c } } CTR3(KTR_IGMPV3, "process v3 0x%08x query on ifp %p(%s)", - igmpv3->igmp_group.s_addr, ifp, ifp->if_xname); + ntohl(igmpv3->igmp_group.s_addr), ifp, ifp->if_xname); /* * If there is a pending General Query response * scheduled sooner than the selected delay, no @@ -1237,7 +1237,7 @@ igmp_input_v1_report(struct ifnet *ifp, } CTR3(KTR_IGMPV3, "process v1 report 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, ifp->if_xname); + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); /* * IGMPv1 report suppression. @@ -1280,7 +1280,7 @@ igmp_input_v1_report(struct ifnet *ifp, case IGMP_AWAKENING_MEMBER: CTR3(KTR_IGMPV3, "report suppressed for 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); case IGMP_SLEEPING_MEMBER: inm->inm_state = IGMP_SLEEPING_MEMBER; @@ -1288,7 +1288,7 @@ igmp_input_v1_report(struct ifnet *ifp, case IGMP_REPORTING_MEMBER: CTR3(KTR_IGMPV3, "report suppressed for 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); if (igi->igi_version == IGMP_VERSION_1) inm->inm_state = IGMP_LAZY_MEMBER; @@ -1363,7 +1363,7 @@ igmp_input_v2_report(struct ifnet *ifp, ifa_free(&ia->ia_ifa); CTR3(KTR_IGMPV3, "process v2 report 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, ifp->if_xname); + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); /* * IGMPv2 report suppression. @@ -1404,7 +1404,7 @@ igmp_input_v2_report(struct ifnet *ifp, case IGMP_AWAKENING_MEMBER: CTR3(KTR_IGMPV3, "report suppressed for 0x%08x on ifp %p(%s)", - igmp->igmp_group.s_addr, ifp, ifp->if_xname); + ntohl(igmp->igmp_group.s_addr), ifp, ifp->if_xname); case IGMP_LAZY_MEMBER: inm->inm_state = IGMP_LAZY_MEMBER; break; @@ -1892,7 +1892,8 @@ igmp_v3_process_group_timers(struct igmp inm_commit(inm); CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), + inm->inm_ifp->if_xname); /* * If we are leaving the group for good, make sure @@ -2340,7 +2341,7 @@ igmp_initial_join(struct in_multi *inm, int error, retval, syncstates; CTR4(KTR_IGMPV3, "%s: initial join 0x%08x on ifp %p(%s)", __func__, - inm->inm_addr.s_addr, inm->inm_ifp, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp, inm->inm_ifp->if_xname); error = 0; syncstates = 1; @@ -2450,7 +2451,7 @@ igmp_initial_join(struct in_multi *inm, if (syncstates) { inm_commit(inm); CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname); } return (error); @@ -2466,7 +2467,7 @@ igmp_handle_state_change(struct in_multi int retval; CTR4(KTR_IGMPV3, "%s: state change for 0x%08x on ifp %p(%s)", __func__, - inm->inm_addr.s_addr, inm->inm_ifp, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp, inm->inm_ifp->if_xname); ifp = inm->inm_ifp; @@ -2486,7 +2487,7 @@ igmp_handle_state_change(struct in_multi CTR1(KTR_IGMPV3, "%s: nothing to do", __func__); inm_commit(inm); CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname); return (0); } @@ -2525,7 +2526,7 @@ igmp_final_leave(struct in_multi *inm, s syncstates = 1; CTR4(KTR_IGMPV3, "%s: final leave 0x%08x on ifp %p(%s)", - __func__, inm->inm_addr.s_addr, inm->inm_ifp, + __func__, ntohl(inm->inm_addr.s_addr), inm->inm_ifp, inm->inm_ifp->if_xname); IN_MULTI_LOCK_ASSERT(); @@ -2568,7 +2569,7 @@ igmp_final_leave(struct in_multi *inm, s } CTR4(KTR_IGMPV3, "%s: Leaving 0x%08x/%s with %d " "pending retransmissions.", __func__, - inm->inm_addr.s_addr, + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname, inm->inm_scrv); if (inm->inm_scrv == 0) { inm->inm_state = IGMP_NOT_MEMBER; @@ -2602,10 +2603,11 @@ igmp_final_leave(struct in_multi *inm, s if (syncstates) { inm_commit(inm); CTR3(KTR_IGMPV3, "%s: T1 -> T0 for 0x%08x/%s", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname); inm->inm_st[1].iss_fmode = MCAST_UNDEFINED; CTR3(KTR_IGMPV3, "%s: T1 now MCAST_UNDEFINED for 0x%08x/%s", - __func__, inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + __func__, ntohl(inm->inm_addr.s_addr), + inm->inm_ifp->if_xname); } } @@ -2731,7 +2733,7 @@ igmp_v3_enqueue_group_record(struct mbuf if (type == IGMP_DO_NOTHING) { CTR3(KTR_IGMPV3, "%s: nothing to do for 0x%08x/%s", __func__, - inm->inm_addr.s_addr, inm->inm_ifp->if_xname); + ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname); return (0); } @@ -2745,7 +2747,7 @@ igmp_v3_enqueue_group_record(struct mbuf minrec0len += sizeof(in_addr_t); CTR4(KTR_IGMPV3, "%s: queueing %s for 0x%08x/%s", __func__, - igmp_rec_type_to_str(type), inm->inm_addr.s_addr, + igmp_rec_type_to_str(type), ntohl(inm->inm_addr.s_addr), inm->inm_ifp->if_xname); /* @@ -2834,7 +2836,7 @@ igmp_v3_enqueue_group_record(struct mbuf msrcs = 0; RB_FOREACH_SAFE(ims, ip_msource_tree, &inm->inm_srcs, nims) { CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, - htonl(ims->ims_haddr)); + ims->ims_haddr); now = ims_get_mode(inm, ims, 1); CTR2(KTR_IGMPV3, "%s: node is %d", __func__, now); if ((now != mode) || @@ -2930,7 +2932,7 @@ igmp_v3_enqueue_group_record(struct mbuf msrcs = 0; RB_FOREACH_FROM(ims, ip_msource_tree, nims) { CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, - htonl(ims->ims_haddr)); + ims->ims_haddr); now = ims_get_mode(inm, ims, 1); if ((now != mode) || (now == mode && mode == MCAST_UNDEFINED)) { @@ -3122,7 +3124,7 @@ igmp_v3_enqueue_filter_change(struct mbu nims = RB_MIN(ip_msource_tree, &inm->inm_srcs); RB_FOREACH_FROM(ims, ip_msource_tree, nims) { CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", - __func__, htonl(ims->ims_haddr)); + __func__, ims->ims_haddr); now = ims_get_mode(inm, ims, 1); then = ims_get_mode(inm, ims, 0); CTR3(KTR_IGMPV3, "%s: mode: t0 %d, t1 %d", Modified: head/sys/netinet/in_mcast.c ============================================================================== --- head/sys/netinet/in_mcast.c Tue Mar 14 20:43:04 2017 (r315285) +++ head/sys/netinet/in_mcast.c Tue Mar 14 20:57:54 2017 (r315286) @@ -893,7 +893,7 @@ inm_get_source(struct in_multi *inm, con ims = nims; #ifdef KTR CTR3(KTR_IGMPV3, "%s: allocated 0x%08x as %p", __func__, - htonl(haddr), ims); + haddr, ims); #endif } @@ -910,29 +910,24 @@ ims_merge(struct ip_msource *ims, const const int rollback) { int n = rollback ? -1 : 1; -#ifdef KTR - uint32_t addr; - - addr = htonl(ims->ims_haddr); -#endif if (lims->imsl_st[0] == MCAST_EXCLUDE) { CTR3(KTR_IGMPV3, "%s: t1 ex -= %d on 0x%08x", - __func__, n, addr); + __func__, n, ims->ims_haddr); ims->ims_st[1].ex -= n; } else if (lims->imsl_st[0] == MCAST_INCLUDE) { CTR3(KTR_IGMPV3, "%s: t1 in -= %d on 0x%08x", - __func__, n, addr); + __func__, n, ims->ims_haddr); ims->ims_st[1].in -= n; } if (lims->imsl_st[1] == MCAST_EXCLUDE) { CTR3(KTR_IGMPV3, "%s: t1 ex += %d on 0x%08x", - __func__, n, addr); + __func__, n, ims->ims_haddr); ims->ims_st[1].ex += n; } else if (lims->imsl_st[1] == MCAST_INCLUDE) { CTR3(KTR_IGMPV3, "%s: t1 in += %d on 0x%08x", - __func__, n, addr); + __func__, n, ims->ims_haddr); ims->ims_st[1].in += n; } } @@ -1169,7 +1164,7 @@ in_joingroup_locked(struct ifnet *ifp, c IN_MULTI_LOCK_ASSERT(); CTR4(KTR_IGMPV3, "%s: join 0x%08x on %p(%s))", __func__, - gina->s_addr, ifp, ifp->if_xname); + ntohl(gina->s_addr), ifp, ifp->if_xname); error = 0; inm = NULL; @@ -1253,7 +1248,7 @@ in_leavegroup_locked(struct in_multi *in IN_MULTI_LOCK_ASSERT(); CTR5(KTR_IGMPV3, "%s: leave inm %p, 0x%08x/%s, imf %p", __func__, - inm, inm->inm_addr.s_addr, + inm, ntohl(inm->inm_addr.s_addr), (inm_is_ifp_detached(inm) ? "null" : inm->inm_ifp->if_xname), imf); @@ -1387,7 +1382,7 @@ inp_block_unblock_source(struct inpcb *i doblock = 1; CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", - __func__, mreqs.imr_interface.s_addr, ifp); + __func__, ntohl(mreqs.imr_interface.s_addr), ifp); break; } @@ -1460,7 +1455,7 @@ inp_block_unblock_source(struct inpcb *i ims = imo_match_source(imo, idx, &ssa->sa); if ((ims != NULL && doblock) || (ims == NULL && !doblock)) { CTR3(KTR_IGMPV3, "%s: source 0x%08x %spresent", __func__, - ssa->sin.sin_addr.s_addr, doblock ? "" : "not "); + ntohl(ssa->sin.sin_addr.s_addr), doblock ? "" : "not "); error = EADDRNOTAVAIL; goto out_inp_locked; } @@ -1989,7 +1984,7 @@ inp_join_group(struct inpcb *inp, struct ifp = inp_lookup_mcast_ifp(inp, &gsa->sin, mreqs.imr_interface); CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", - __func__, mreqs.imr_interface.s_addr, ifp); + __func__, ntohl(mreqs.imr_interface.s_addr), ifp); break; } @@ -2290,7 +2285,7 @@ inp_leave_group(struct inpcb *inp, struc INADDR_TO_IFP(mreqs.imr_interface, ifp); CTR3(KTR_IGMPV3, "%s: imr_interface = 0x%08x, ifp = %p", - __func__, mreqs.imr_interface.s_addr, ifp); + __func__, ntohl(mreqs.imr_interface.s_addr), ifp); break; @@ -2371,7 +2366,7 @@ inp_leave_group(struct inpcb *inp, struc ims = imo_match_source(imo, idx, &ssa->sa); if (ims == NULL) { CTR3(KTR_IGMPV3, "%s: source 0x%08x %spresent", - __func__, ssa->sin.sin_addr.s_addr, "not "); + __func__, ntohl(ssa->sin.sin_addr.s_addr), "not "); error = EADDRNOTAVAIL; goto out_inp_locked; } @@ -2491,7 +2486,7 @@ inp_set_multicast_if(struct inpcb *inp, return (EADDRNOTAVAIL); } CTR3(KTR_IGMPV3, "%s: ifp = %p, addr = 0x%08x", __func__, ifp, - addr.s_addr); + ntohl(addr.s_addr)); } /* Reject interfaces which do not support multicast. */ @@ -2869,7 +2864,7 @@ sysctl_ip_mcast_filters(SYSCTL_HANDLER_A group.s_addr = name[1]; if (!IN_MULTICAST(ntohl(group.s_addr))) { CTR2(KTR_IGMPV3, "%s: group 0x%08x is not multicast", - __func__, group.s_addr); + __func__, ntohl(group.s_addr)); return (EINVAL); } @@ -2901,7 +2896,7 @@ sysctl_ip_mcast_filters(SYSCTL_HANDLER_A break; RB_FOREACH(ims, ip_msource_tree, &inm->inm_srcs) { CTR2(KTR_IGMPV3, "%s: visit node 0x%08x", __func__, - htonl(ims->ims_haddr)); + ims->ims_haddr); /* * Only copy-out sources which are in-mode. */ Modified: head/sys/netinet/ip_mroute.c ============================================================================== --- head/sys/netinet/ip_mroute.c Tue Mar 14 20:43:04 2017 (r315285) +++ head/sys/netinet/ip_mroute.c Tue Mar 14 20:57:54 2017 (r315286) @@ -929,7 +929,7 @@ add_vif(struct vifctl *vifcp) VIF_UNLOCK(); CTR4(KTR_IPMF, "%s: add vif %d laddr 0x%08x thresh %x", __func__, - (int)vifcp->vifc_vifi, vifcp->vifc_lcl_addr.s_addr, + (int)vifcp->vifc_vifi, ntohl(vifcp->vifc_lcl_addr.s_addr), (int)vifcp->vifc_threshold); return 0; @@ -1061,7 +1061,7 @@ add_mfc(struct mfcctl2 *mfccp) /* If an entry already exists, just update the fields */ if (rt) { CTR4(KTR_IPMF, "%s: update mfc orig 0x%08x group %lx parent %x", - __func__, mfccp->mfcc_origin.s_addr, + __func__, ntohl(mfccp->mfcc_origin.s_addr), (u_long)ntohl(mfccp->mfcc_mcastgrp.s_addr), mfccp->mfcc_parent); update_mfc_params(rt, mfccp); @@ -1081,7 +1081,7 @@ add_mfc(struct mfcctl2 *mfccp) !TAILQ_EMPTY(&rt->mfc_stall)) { CTR5(KTR_IPMF, "%s: add mfc orig 0x%08x group %lx parent %x qh %p", - __func__, mfccp->mfcc_origin.s_addr, + __func__, ntohl(mfccp->mfcc_origin.s_addr), (u_long)ntohl(mfccp->mfcc_mcastgrp.s_addr), mfccp->mfcc_parent, TAILQ_FIRST(&rt->mfc_stall)); @@ -1160,7 +1160,7 @@ del_mfc(struct mfcctl2 *mfccp) mcastgrp = mfccp->mfcc_mcastgrp; CTR3(KTR_IPMF, "%s: delete mfc orig 0x%08x group %lx", __func__, - origin.s_addr, (u_long)ntohl(mcastgrp.s_addr)); + ntohl(origin.s_addr), (u_long)ntohl(mcastgrp.s_addr)); MFC_LOCK(); From owner-svn-src-all@freebsd.org Tue Mar 14 21:03:54 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BCCA5D0DAC2; Tue, 14 Mar 2017 21:03:54 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id A79AB1F53; Tue, 14 Mar 2017 21:03:54 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from sweettea.beer.town (unknown [76.164.8.130]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 25F4856575; Tue, 14 Mar 2017 16:03:48 -0500 (CDT) Subject: Re: svn commit: r315277 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet To: Ian Lepore , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201703141827.v2EIRmLv080307@repo.freebsd.org> <1489518141.40576.119.camel@freebsd.org> From: Eric van Gyzen Message-ID: Date: Tue, 14 Mar 2017 16:03:47 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: <1489518141.40576.119.camel@freebsd.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 21:03:54 -0000 On 03/14/2017 14:02, Ian Lepore wrote: > On Tue, 2017-03-14 at 18:27 +0000, Eric van Gyzen wrote: >> Author: vangyzen >> Date: Tue Mar 14 18:27:48 2017 >> New Revision: 315277 >> URL: https://svnweb.freebsd.org/changeset/base/315277 >> >> Log: >> KTR: log IPv4 addresses in hex rather than dotted-quad >> > > Don't all those s_addr fields now need some ntohl() love to print > properly as an integer value? *sigh* Yes, of course. Fixed in r315286. Thanks, Ian. How did I get it right in several places in ip_mroute.c, but wrong in all the other places? That was rhetorical. Please, for my sake, don't share your postulations about my malfunctioning brain. Eric From owner-svn-src-all@freebsd.org Tue Mar 14 21:57:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A402ED0CF86; Tue, 14 Mar 2017 21:57:08 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (glebi.us [96.95.210.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cell.glebi.us", Issuer "cell.glebi.us" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 6DD1E1087; Tue, 14 Mar 2017 21:57:07 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (localhost [127.0.0.1]) by cell.glebi.us (8.15.2/8.15.2) with ESMTPS id v2ELv6HX001718 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 14 Mar 2017 14:57:07 -0700 (PDT) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebi.us (8.15.2/8.15.2/Submit) id v2ELv6SI001717; Tue, 14 Mar 2017 14:57:06 -0700 (PDT) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebi.us: glebius set sender to glebius@FreeBSD.org using -f Date: Tue, 14 Mar 2017 14:57:06 -0700 From: Gleb Smirnoff To: Kristof Provost Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315136 - head/sys/netpfil/pf Message-ID: <20170314215706.GB1072@FreeBSD.org> References: <201703120542.v2C5gvM4075391@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201703120542.v2C5gvM4075391@repo.freebsd.org> User-Agent: Mutt/1.7.2 (2016-11-26) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 21:57:08 -0000 Kristof, On Sun, Mar 12, 2017 at 05:42:57AM +0000, Kristof Provost wrote: K> Log: K> pf: Fix incorrect rw_sleep() in pf_unload() K> K> When we unload we don't hold the pf_rules_lock, so we cannot call rw_sleep() K> with it, because it would release a lock we do not hold. There's no need for the K> lock either, so we can just tsleep(). K> K> While here also make the same change in pf_purge_thread(), because it explicitly K> takes the lock before rw_sleep() and then immediately releases it afterwards. The correct change would to be grab lock in pf_unload(), exactly as pf_purge_thread() does. With your change you introduces a possible infinite sleep due to race, since there is no timeout and no lock. No... Actually both cases should PF_RULES_WLOCK(), and read/write the pf_end_threads variable under this lock. And use rw_sleep. K> Modified: K> head/sys/netpfil/pf/pf.c K> head/sys/netpfil/pf/pf_ioctl.c K> K> Modified: head/sys/netpfil/pf/pf.c K> ============================================================================== K> --- head/sys/netpfil/pf/pf.c Sun Mar 12 05:36:31 2017 (r315135) K> +++ head/sys/netpfil/pf/pf.c Sun Mar 12 05:42:57 2017 (r315136) K> @@ -1429,9 +1429,7 @@ pf_purge_thread(void *unused __unused) K> u_int idx = 0; K> K> for (;;) { K> - PF_RULES_RLOCK(); K> - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftm", hz / 10); K> - PF_RULES_RUNLOCK(); K> + tsleep(pf_purge_thread, 0, "pftm", hz / 10); K> K> VNET_LIST_RLOCK(); K> VNET_FOREACH(vnet_iter) { K> K> Modified: head/sys/netpfil/pf/pf_ioctl.c K> ============================================================================== K> --- head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:36:31 2017 (r315135) K> +++ head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:42:57 2017 (r315136) K> @@ -3791,7 +3791,7 @@ pf_unload(void) K> pf_end_threads = 1; K> while (pf_end_threads < 2) { K> wakeup_one(pf_purge_thread); K> - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftmo", 0); K> + tsleep(pf_purge_thread, 0, "pftmo", 0); K> } K> K> if (pf_dev != NULL) K> _______________________________________________ K> svn-src-all@freebsd.org mailing list K> https://lists.freebsd.org/mailman/listinfo/svn-src-all K> To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" -- Totus tuus, Glebius. From owner-svn-src-all@freebsd.org Tue Mar 14 22:02:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6BA6CD0D197; Tue, 14 Mar 2017 22:02:04 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 252F21527; Tue, 14 Mar 2017 22:02:04 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EM23n2072478; Tue, 14 Mar 2017 22:02:03 GMT (envelope-from vangyzen@FreeBSD.org) Received: (from vangyzen@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EM22O9072474; Tue, 14 Mar 2017 22:02:02 GMT (envelope-from vangyzen@FreeBSD.org) Message-Id: <201703142202.v2EM22O9072474@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: vangyzen set sender to vangyzen@FreeBSD.org using -f From: Eric van Gyzen Date: Tue, 14 Mar 2017 22:02:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315287 - in head: share/man/man9 sys/kern sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 22:02:04 -0000 Author: vangyzen Date: Tue Mar 14 22:02:02 2017 New Revision: 315287 URL: https://svnweb.freebsd.org/changeset/base/315287 Log: Add missing pieces of r315280 I moved this branch from github to a private server, and pulled from the wrong one when committing r315280, so I failed to include two recent commits. Thankfully, they were only cosmetic and were included in the review. Specifically: Add documentation, polish comments, and improve style(9). Tested by: pho (r315280) MFC after: 2 weeks Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D9791 Modified: head/share/man/man9/sleep.9 head/sys/kern/kern_tc.c head/sys/kern/subr_sleepqueue.c head/sys/sys/proc.h Modified: head/share/man/man9/sleep.9 ============================================================================== --- head/share/man/man9/sleep.9 Tue Mar 14 20:57:54 2017 (r315286) +++ head/share/man/man9/sleep.9 Tue Mar 14 22:02:02 2017 (r315287) @@ -280,6 +280,21 @@ to pay particular attention to ensure that no other threads wait on the same .Fa chan . +.Pp +If the timeout given by +.Fa timo +or +.Fa sbt +is based on an absolute real-time clock value, +then the thread should copy the global +.Va rtc_generation +into its +.Va td_rtcgen +member before reading the RTC. +If the real-time clock is adjusted, these functions will set +.Va td_rtcgen +to zero and return zero. +The caller should reconsider its orientation with the new RTC value. .Sh RETURN VALUES When awakened by a call to .Fn wakeup @@ -298,6 +313,9 @@ the .Fn msleep_spin , .Fn tsleep , and locking primitive sleep functions return 0. +Zero can also be returned when the real-time clock is adjusted; +see above regarding +.Va td_rtcgen . Otherwise, a non-zero error code is returned. .Sh ERRORS .Fn msleep , Modified: head/sys/kern/kern_tc.c ============================================================================== --- head/sys/kern/kern_tc.c Tue Mar 14 20:57:54 2017 (r315286) +++ head/sys/kern/kern_tc.c Tue Mar 14 22:02:02 2017 (r315287) @@ -1269,6 +1269,15 @@ static bool sleeping_on_old_rtc(struct thread *td) { + /* + * td_rtcgen is modified by curthread when it is running, + * and by other threads in this function. By finding the thread + * on a sleepqueue and holding the lock on the sleepqueue + * chain, we guarantee that the thread is not running and that + * modifying td_rtcgen is safe. Setting td_rtcgen to zero informs + * the thread that it was woken due to a real-time clock adjustment. + * (The declaration of td_rtcgen refers to this comment.) + */ if (td->td_rtcgen != 0 && td->td_rtcgen != rtc_generation) { td->td_rtcgen = 0; return (true); @@ -1299,6 +1308,7 @@ tc_setclock(struct timespec *ts) /* XXX fiddle all the little crinkly bits around the fiords... */ tc_windup(&bt); mtx_unlock_spin(&tc_setclock_mtx); + /* Avoid rtc_generation == 0, since td_rtcgen == 0 is special. */ atomic_add_rel_int(&rtc_generation, 2); sleepq_chains_remove_matching(sleeping_on_old_rtc); Modified: head/sys/kern/subr_sleepqueue.c ============================================================================== --- head/sys/kern/subr_sleepqueue.c Tue Mar 14 20:57:54 2017 (r315286) +++ head/sys/kern/subr_sleepqueue.c Tue Mar 14 22:02:02 2017 (r315287) @@ -561,9 +561,21 @@ sleepq_switch(void *wchan, int pri) /* * If TDF_TIMEOUT is set, then our sleep has been timed out * already but we are still on the sleep queue, so dequeue the - * thread and return. Do the same if the real-time clock has - * been adjusted since this thread calculated its timeout - * based on that clock. + * thread and return. + * + * Do the same if the real-time clock has been adjusted since this + * thread calculated its timeout based on that clock. This handles + * the following race: + * - The Ts thread needs to sleep until an absolute real-clock time. + * It copies the global rtc_generation into curthread->td_rtcgen, + * reads the RTC, and calculates a sleep duration based on that time. + * See umtxq_sleep() for an example. + * - The Tc thread adjusts the RTC, bumps rtc_generation, and wakes + * threads that are sleeping until an absolute real-clock time. + * See tc_setclock() and the POSIX specification of clock_settime(). + * - Ts reaches the code below. It holds the sleepqueue chain lock, + * so Tc has finished waking, so this thread must test td_rtcgen. + * (The declaration of td_rtcgen refers to this comment.) */ rtc_changed = td->td_rtcgen != 0 && td->td_rtcgen != rtc_generation; if ((td->td_flags & TDF_TIMEOUT) || rtc_changed) { @@ -899,6 +911,7 @@ sleepq_signal(void *wchan, int flags, in static bool match_any(struct thread *td __unused) { + return (true); } Modified: head/sys/sys/proc.h ============================================================================== --- head/sys/sys/proc.h Tue Mar 14 20:57:54 2017 (r315286) +++ head/sys/sys/proc.h Tue Mar 14 22:02:02 2017 (r315287) @@ -148,7 +148,7 @@ struct pargs { * o - ktrace lock * q - td_contested lock * r - p_peers lock - * s - by curthread, or by others when curthread is on sleepqueue + * s - see sleepq_switch(), sleeping_on_old_rtc(), and sleep(9) * t - thread lock * u - process stat lock * w - process timer lock From owner-svn-src-all@freebsd.org Tue Mar 14 22:09:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2C920D0D2EF; Tue, 14 Mar 2017 22:09:19 +0000 (UTC) (envelope-from ermal.luci@gmail.com) Received: from mail-it0-x22b.google.com (mail-it0-x22b.google.com [IPv6:2607:f8b0:4001:c0b::22b]) (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 E8B9C1873; Tue, 14 Mar 2017 22:09:18 +0000 (UTC) (envelope-from ermal.luci@gmail.com) Received: by mail-it0-x22b.google.com with SMTP id m27so55969166iti.0; Tue, 14 Mar 2017 15:09:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=6Lbn79Gu5klDLCppl2HDpVWECdh3uhHeVoAAEeQyy5Q=; b=L/j31fUtz6ntguvU2mLeawzFrACHv70E0HqwEK9ySvV8XFEfbEe6NRplYFFHRjEvy1 E+yDJ6aTecFfeCz/bInKuct5hXDChmDjISq+PBkjGAswL1mdKq09j4qgbH+2xzQNEtEP aI+FSFGM+l4TvOurDvFwQNQseFJHP14gKUMlnZKP/itV5edY3ATCCWt6a5XrivQHpvOq QNjYXbrCx3sDfHitPts4v72mzogizLfPTpIKvLql0N0uvDNUEdXYMOEa+6XelcmoLQCs tg6+f5ynTO0PaBaxVw7vexLEkuZ3oE7Keu5Z2IR0ZnFqWKEpzn9es1XGMg1EWGUDjrqI /8Hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=6Lbn79Gu5klDLCppl2HDpVWECdh3uhHeVoAAEeQyy5Q=; b=aA2MP66sU3ybin7f4kUGMGIYT75M8MbbwQefKd88V29X3kw8xaVbtyPIzguMs3lN3P +rSrgxJYxDHhP+zgbulCdphaTastOTCH0Y9AWUaflnq6x3PZAJkB/Ku6gQyJgDSULjJY I6td2pxhcX6nhU2+zQ1ux5XyuGwRKWmLm4JPfivsnTC/svh7owkDPXfrOVCCGrk9pzHE 60RCz3uJxeALnerRReynJjQ6k1Y2BJ+znjlfmfK3CKts+rBr2xFARrveeo6wJrYKveV1 8Ai3vfehzd4mi8Z2cJr8SKYOpsCRVWZMDWa704ln9v/21I1rFji9z0XaEx553miuG9jq xfOw== X-Gm-Message-State: AFeK/H3MzUpq9RLZhhaDLHxzoGjn2xTTgEobHR0q6UYpxOdo/CXjKVb7ZNsJF7FWk9MAPuRk/oAawfqfvrUMVQ== X-Received: by 10.36.153.197 with SMTP id a188mr18757487ite.5.1489529358143; Tue, 14 Mar 2017 15:09:18 -0700 (PDT) MIME-Version: 1.0 Sender: ermal.luci@gmail.com Received: by 10.107.149.135 with HTTP; Tue, 14 Mar 2017 15:09:17 -0700 (PDT) In-Reply-To: <20170314215706.GB1072@FreeBSD.org> References: <201703120542.v2C5gvM4075391@repo.freebsd.org> <20170314215706.GB1072@FreeBSD.org> From: =?UTF-8?Q?Ermal_Lu=C3=A7i?= Date: Tue, 14 Mar 2017 15:09:17 -0700 X-Google-Sender-Auth: lGZM-2-wlZymMIpbxHPnNA4lSO4 Message-ID: Subject: Re: svn commit: r315136 - head/sys/netpfil/pf To: Gleb Smirnoff Cc: Kristof Provost , src-committers , svn-src-all , svn-src-head Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 22:09:19 -0000 On Tue, Mar 14, 2017 at 2:57 PM, Gleb Smirnoff wrote: > Kristof, > > On Sun, Mar 12, 2017 at 05:42:57AM +0000, Kristof Provost wrote: > K> Log: > K> pf: Fix incorrect rw_sleep() in pf_unload() > K> > K> When we unload we don't hold the pf_rules_lock, so we cannot call > rw_sleep() > K> with it, because it would release a lock we do not hold. There's no > need for the > K> lock either, so we can just tsleep(). > K> > K> While here also make the same change in pf_purge_thread(), because it > explicitly > K> takes the lock before rw_sleep() and then immediately releases it > afterwards. > > The correct change would to be grab lock in pf_unload(), exactly as > pf_purge_thread() > does. With your change you introduces a possible infinite sleep due to > race, since > there is no timeout and no lock. > > No... Actually both cases should PF_RULES_WLOCK(), and read/write the > pf_end_threads > variable under this lock. And use rw_sleep. > I already provided the same concerns privately and solutions to it. > > K> Modified: > K> head/sys/netpfil/pf/pf.c > K> head/sys/netpfil/pf/pf_ioctl.c > K> > K> Modified: head/sys/netpfil/pf/pf.c > K> ============================================================ > ================== > K> --- head/sys/netpfil/pf/pf.c Sun Mar 12 05:36:31 2017 (r315135) > K> +++ head/sys/netpfil/pf/pf.c Sun Mar 12 05:42:57 2017 (r315136) > K> @@ -1429,9 +1429,7 @@ pf_purge_thread(void *unused __unused) > K> u_int idx = 0; > K> > K> for (;;) { > K> - PF_RULES_RLOCK(); > K> - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftm", hz / > 10); > K> - PF_RULES_RUNLOCK(); > K> + tsleep(pf_purge_thread, 0, "pftm", hz / 10); > K> > K> VNET_LIST_RLOCK(); > K> VNET_FOREACH(vnet_iter) { > K> > K> Modified: head/sys/netpfil/pf/pf_ioctl.c > K> ============================================================ > ================== > K> --- head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:36:31 2017 > (r315135) > K> +++ head/sys/netpfil/pf/pf_ioctl.c Sun Mar 12 05:42:57 2017 > (r315136) > K> @@ -3791,7 +3791,7 @@ pf_unload(void) > K> pf_end_threads = 1; > K> while (pf_end_threads < 2) { > K> wakeup_one(pf_purge_thread); > K> - rw_sleep(pf_purge_thread, &pf_rules_lock, 0, "pftmo", 0); > K> + tsleep(pf_purge_thread, 0, "pftmo", 0); > K> } > K> > K> if (pf_dev != NULL) > K> _______________________________________________ > K> svn-src-all@freebsd.org mailing list > K> https://lists.freebsd.org/mailman/listinfo/svn-src-all > K> To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" > > -- > Totus tuus, Glebius. > > -- > Ermal > From owner-svn-src-all@freebsd.org Tue Mar 14 22:16:13 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4F19BD0D4A9; Tue, 14 Mar 2017 22:16:13 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-qk0-x234.google.com (mail-qk0-x234.google.com [IPv6:2607:f8b0:400d:c09::234]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id F28F21DB7; Tue, 14 Mar 2017 22:16:12 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-qk0-x234.google.com with SMTP id v127so3443690qkb.2; Tue, 14 Mar 2017 15:16:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=tATd1UjWt7xbeI6kcZsBObh5JYPSOk1VT9LFSz2o51g=; b=FFNTVUtZcrs5DT1b4d5qFkFSFfigT6dOMcw5hwy4AN7WWvEuFJtGIvEA9sxFdkcwhE r0CKfU81/a/qxmqorPKc8C3tf4NRi5NAdgnfObW9z2XZ9X8qLQjkQUHJwnbztvQX/xKI d5tBjbKOuWzgwiGwC1tJl2IQ7FPKADmiQMIAWaAvZNuJeraniRbfR/XX/p4WqX5ghegT bI+kgGtMU4nKv9HAO4MbU40fm+1GwN/4sc2sAeSN3ug5PBOwNen+S1m6h/ADRVNnHIAw ZrvdACyJRCooTvto8sq1xpmVYUoT3ytJ4iizJr8T5fzfv7RndxsvKBKDQPOs7yoFCCE8 Sb9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=tATd1UjWt7xbeI6kcZsBObh5JYPSOk1VT9LFSz2o51g=; b=ulcR3oy1/Az1dwVtOKQgJxXBxbps8Q5VYpHEFN18TzF6ncfx4bCEgVt+tReVg80V9B 1fr7ulHVq88zMvqgv8yrNmtblMWavdrRIu8R8eoeGitY2y9Fdn4E636QA+rhTqogNd24 RxFPPRrACAFeJU+rj9rXMs656hANBexhkNpWCyBpYdE68oFF+7A+4tysdC+t1Po+UrAI ka+iYvHB7flUzAhNCoe5XokC0G1CF73iNFLKWe5p0m76f6jd1gYGu915Ah8es0cAlRMZ zdpKsa3FtXxf7Xfo0DVaoPwaF4z1KuwrrkJYO+F4p4pnlibZTgvRIaYfC8M6+cFaJOV9 lbKw== X-Gm-Message-State: AFeK/H3oF2ZXrhaHR/rWd4Q+k8QCXxyRUH5fxyiLgYdhH2KlzOUjoQe5IALADCtIE+S9PCyre9evKmGgMBrREA== X-Received: by 10.55.58.193 with SMTP id h184mr1341qka.40.1489529771950; Tue, 14 Mar 2017 15:16:11 -0700 (PDT) MIME-Version: 1.0 Received: by 10.140.104.200 with HTTP; Tue, 14 Mar 2017 15:16:11 -0700 (PDT) In-Reply-To: <201703141906.v2EJ6i0x096677@repo.freebsd.org> References: <201703141906.v2EJ6i0x096677@repo.freebsd.org> From: Ngie Cooper Date: Tue, 14 Mar 2017 15:16:11 -0700 Message-ID: Subject: Re: svn commit: r315280 - in head/sys: kern sys To: Eric van Gyzen Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 22:16:13 -0000 On Tue, Mar 14, 2017 at 12:06 PM, Eric van Gyzen wrote: > Author: vangyzen > Date: Tue Mar 14 19:06:44 2017 > New Revision: 315280 > URL: https://svnweb.freebsd.org/changeset/base/315280 > > Log: > When the RTC is adjusted, reevaluate absolute sleep times based on the RTC > > POSIX 2008 says this about clock_settime(2): > > If the value of the CLOCK_REALTIME clock is set via clock_settime(), > the new value of the clock shall be used to determine the time > of expiration for absolute time services based upon the > CLOCK_REALTIME clock. This applies to the time at which armed > absolute timers expire. If the absolute time requested at the > invocation of such a time service is before the new value of > the clock, the time service shall expire immediately as if the > clock had reached the requested time normally. > > Setting the value of the CLOCK_REALTIME clock via clock_settime() > shall have no effect on threads that are blocked waiting for > a relative time service based upon this clock, including the > nanosleep() function; nor on the expiration of relative timers > based upon this clock. Consequently, these time services shall > expire when the requested relative interval elapses, independently > of the new or old value of the clock. > > When the real-time clock is adjusted, such as by clock_settime(3), > wake any threads sleeping until an absolute real-clock time. > Such a sleep is indicated by a non-zero td_rtcgen. The sleep functions > will set that field to zero and return zero to tell the caller > to reevaluate its sleep duration based on the new value of the clock. > > At present, this affects the following functions: > > pthread_cond_timedwait(3) > pthread_mutex_timedlock(3) > pthread_rwlock_timedrdlock(3) > pthread_rwlock_timedwrlock(3) > sem_timedwait(3) > sem_clockwait_np(3) > > I'm working on adding clock_nanosleep(2), which will also be affected. > > Reported by: Sebastian Huber > Reviewed by: jhb, kib > MFC after: 2 weeks > Relnotes: yes > Sponsored by: Dell EMC > Differential Revision: https://reviews.freebsd.org/D9791 Thanks for this! I'll take a look at running "open_posix_testsuite" from LTP and (when time/appropriate), I'll help out with integrating in the clock_nanosleep tests from NetBSD (contrib/netbsd-tests/lib/libc/sys/t_clock_nanosleep.c, ). Cheers! -Ngie From owner-svn-src-all@freebsd.org Tue Mar 14 22:25:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E4567D0D6EB; Tue, 14 Mar 2017 22:25:08 +0000 (UTC) (envelope-from sbruno@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 A91321294; Tue, 14 Mar 2017 22:25:08 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2EMP7LV082619; Tue, 14 Mar 2017 22:25:07 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2EMP70D082618; Tue, 14 Mar 2017 22:25:07 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201703142225.v2EMP70D082618@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Tue, 14 Mar 2017 22:25:07 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315288 - head/sys/net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 22:25:09 -0000 Author: sbruno Date: Tue Mar 14 22:25:07 2017 New Revision: 315288 URL: https://svnweb.freebsd.org/changeset/base/315288 Log: Change casting to a uintptr_t to be compatible with non-x86 architectures. Submitted by: Matt Macy Reported by: rpokala Sponsored by: Limelight Networks Modified: head/sys/net/iflib.c Modified: head/sys/net/iflib.c ============================================================================== --- head/sys/net/iflib.c Tue Mar 14 22:02:02 2017 (r315287) +++ head/sys/net/iflib.c Tue Mar 14 22:25:07 2017 (r315288) @@ -257,7 +257,7 @@ iflib_get_sctx(if_ctx_t ctx) #define IP_ALIGNED(m) ((((uintptr_t)(m)->m_data) & 0x3) == 0x2) #define CACHE_PTR_INCREMENT (CACHE_LINE_SIZE/sizeof(void*)) -#define CACHE_PTR_NEXT(ptr) ((void *)(((vm_paddr_t)(ptr)+CACHE_LINE_SIZE-1) & (CACHE_LINE_SIZE-1))) +#define CACHE_PTR_NEXT(ptr) ((void *)(((uintptr_t)(ptr)+CACHE_LINE_SIZE-1) & (CACHE_LINE_SIZE-1))) #define LINK_ACTIVE(ctx) ((ctx)->ifc_link_state == LINK_STATE_UP) #define CTX_IS_VF(ctx) ((ctx)->ifc_sctx->isc_flags & IFLIB_IS_VF) From owner-svn-src-all@freebsd.org Tue Mar 14 22:28:35 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B062ED0D79E; Tue, 14 Mar 2017 22:28:35 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-qk0-x230.google.com (mail-qk0-x230.google.com [IPv6:2607:f8b0:400d:c09::230]) (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 6D1041462; Tue, 14 Mar 2017 22:28:35 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-qk0-x230.google.com with SMTP id v127so73589qkb.2; Tue, 14 Mar 2017 15:28:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=G8A1aqI6MBm2ti4S6EcmtBdr9RLyYWH6B8vYa9YIPX0=; b=l4jTUP6dA8T/d4aXAzisoDeHG54fm71fRzTQ6RHkY0L1jDp5H+PON0HkOWloK+cbCw ftls7w8ErFs2oiPAfT49MYMBn1+q3mo4OJlzc4ge6xJyJgA9pWmIw3TvlS5DqmuSxpPW gn9K0BdI2NWPPqLNLbPeTTF4pEkNrHMrNpHbM+UvDZOf0h90McIkEs+wVOfOjgmmY4m3 IMlbfyIRboNQV0+hSt5XdMpDahmsLIb4C6m0r4+aWvaAwlCvgomyNF8i4ebYaO+Jhcy2 bCict40uURXoa/fx2ZaQ5hPrgz32hC82UIb8haO2X/xXbAG/Cl6qaeOKwjK28ITjNHU+ eqqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=G8A1aqI6MBm2ti4S6EcmtBdr9RLyYWH6B8vYa9YIPX0=; b=j8lODSx8vmKR8L6BwtZLK7RyfS3Oj4WSZUVCnE+pL+uc+O1HRsrTMfi5sB9bwG7Ik5 z4BRszaaftm+sckvjETddENhwVPQ7GDNk2bWQO4cF1RHUp8SBCEDcYUPUr06KO5hsbzM 69z8FKRCNgzFc1viE+UEDAhgwqAJpQaBAH/KFbY5cCNSrAB8pxQyUwjhXrLE/vbitEzg 0oUGwfV9icGqqaWnfMKo2dFubVaOXDtjjzuINJSSNPt6L7ii4QyFHt0limMem0p/Dock Og/LNBR3sttg0hPdQm4JlTIGAgssbniyWr2YXYZAmMrmuk/J5sTxO8uP0TcMmANcy+Dk UgSw== X-Gm-Message-State: AFeK/H2bQCOqYmTHk7yHe+7nSwq02xmG8iWC6y9qImmUOiSJFZ9cH8NppqLm7GkJeeSAL1MLYjmrEQDFhV6WBw== X-Received: by 10.55.67.135 with SMTP id q129mr39625qka.98.1489530514530; Tue, 14 Mar 2017 15:28:34 -0700 (PDT) MIME-Version: 1.0 Received: by 10.140.104.200 with HTTP; Tue, 14 Mar 2017 15:28:34 -0700 (PDT) In-Reply-To: <201703141827.v2EIRmLv080307@repo.freebsd.org> References: <201703141827.v2EIRmLv080307@repo.freebsd.org> From: Ngie Cooper Date: Tue, 14 Mar 2017 15:28:34 -0700 Message-ID: Subject: Re: svn commit: r315277 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet To: Eric van Gyzen Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 22:28:35 -0000 On Tue, Mar 14, 2017 at 11:27 AM, Eric van Gyzen wrote: > Author: vangyzen > Date: Tue Mar 14 18:27:48 2017 > New Revision: 315277 > URL: https://svnweb.freebsd.org/changeset/base/315277 > > Log: > KTR: log IPv4 addresses in hex rather than dotted-quad > > When I made the changes in r313821, I fell victim to one of the > classic blunders, the most famous of which is: never get involved > in a land war in Asia. But only slightly less well known is this: > Keep your brain turned on and engaged when making a tedious, sweeping, > mechanical change. KTR can correctly log the immediate integral values > passed to it, as well as constant strings, but not non-constant strings, > since they might change by the time ktrdump retrieves them. Love the Princess Bride reference :). Some might say, bugs like this are, "Inconceivable!" Take care! -Ngie From owner-svn-src-all@freebsd.org Tue Mar 14 23:33:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 535ECD0D930; Tue, 14 Mar 2017 23:33:49 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from mr11p00im-asmtp001.me.com (mr11p00im-asmtp001.me.com [17.110.69.252]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 335CD16BF; Tue, 14 Mar 2017 23:33:49 +0000 (UTC) (envelope-from rpokala@mac.com) Received: from process-dkim-sign-daemon.mr11p00im-asmtp001.me.com by mr11p00im-asmtp001.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OMT00900UF8VJ00@mr11p00im-asmtp001.me.com>; Tue, 14 Mar 2017 23:33:23 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=4d515a; t=1489534403; bh=TzjCq8HOnKTE5ZDR55VDTGfPC1mwqhJmHvwXc08kM7U=; h=Date:Subject:From:To:Message-id:MIME-version:Content-type; b=SIBu8rIzYoAqw9rVcpyRegVqf2pIKrM4qR/WO5I1Uv3Yjar1feyngtFOlgZF5c/jj 7i4TUdNhl4701VXTcXQjTMaZ9Z5GV5JXQ5kUWzU9pQkkE8RNNXkb8T+HjZkCNSszz9 ahlbn0EhNIYndOCQPkGC7R9tRwkHH2gmPT5ugFUu87u99deGJ49eFf1EsqBR0zcMQ3 1tOuY/6b4+aNtT1WCXxgT0NL6RgQ23flAb6s8wOnGHOW8VQhJcUsjsIU00X3bSDsWh uelUQCx2o01Ow2Qcp+J2lkTRM+tfYSZC2AHlK/h4vXZV4QZtdZD3pYJ915ZAeB5nOJ PfENwrjop101Q== Received: from icloud.com ([127.0.0.1]) by mr11p00im-asmtp001.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OMT00468W3K8M00@mr11p00im-asmtp001.me.com>; Tue, 14 Mar 2017 23:33:20 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-03-14_12:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1703140182 User-Agent: Microsoft-MacOutlook/f.1f.0.170216 Date: Tue, 14 Mar 2017 16:33:19 -0700 Subject: Re: svn commit: r314646 - head/sys/dev/syscons From: Ravi Pokala Sender: "Pokala, Ravi" To: Bruce Evans , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-id: Thread-topic: svn commit: r314646 - head/sys/dev/syscons References: <201703040847.v248lVZS064744@repo.freebsd.org> In-reply-to: <201703040847.v248lVZS064744@repo.freebsd.org> MIME-version: 1.0 Content-type: text/plain; charset=UTF-8 Content-transfer-encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Mar 2017 23:33:49 -0000 Hi Bruce, This breaks all sparc64 kernconfs. (And no, this is *not* fixed by r314997.) --- syscons.o --- cc1: warnings being treated as errors /usr/home/rpokala/freebsd/clean/base/head/sys/dev/syscons/syscons.c:261: warning: 'ec_scroffset' defined but not used /usr/home/rpokala/freebsd/clean/base/head/sys/dev/syscons/syscons.c:269: warning: 'fake_main_console' defined but not used *** [syscons.o] Error code 1 Thanks, Ravi (rpokala@) -----Original Message----- From: on behalf of Bruce Evans Date: 2017-03-04, Saturday at 00:47 To: , , Subject: svn commit: r314646 - head/sys/dev/syscons Author: bde Date: Sat Mar 4 08:47:31 2017 New Revision: 314646 URL: https://svnweb.freebsd.org/changeset/base/314646 Log: Implement ec_putc() (emergency kernel [syscons] console putc()) and use it in emergency in sc_cnputc(). Locking fixes in sc_cnputc() previously turned off normal output in near-deadlock conditions and added deferred output which might never be completed. Emergency output goes to the frame buffer using sufficiently atomic non-blocking writes if the console is in text mode (in graphics mode, nothing is done, modulo races setting the graphics mode bit). Screen updates overwrite the emergency output if the emergency condition clears enough to reach them. ec_putc() also works for "early" console output in normal x86 text mode as soon as this mode is initialized (if ever). This uses a hard-coded x86 frame buffer address before cninit() and a hopefully MI address after cninit(). But non-x86 is more likely to not support text mode, when ec_putc() will be null. ec_putc() has no dependencies of syscons before cninit(), and only has them later to track syscons' mode changes. This commit doesn't attach ec_putc() for early use. To test emergency use, put a breakpoint in central syscons output code like sc_puts() and do some user output. The system used to race or deadlock in ddb output soon after entry to ddb. The locking fixes deferred the output until after leaving ddb, so ddb was unusable and you had to try typing c[ontinue] blindly until it exited, or better use a serial console in parallel. Now the output goes to a window in the middle 2/3 of the screen. Scrolling is circular and there is no cursor, but otherwise ec_putc() provides full dumb terminal functionality and very fast output that hides artificates from dumb overwrites. Modified: head/sys/dev/syscons/syscons.c Modified: head/sys/dev/syscons/syscons.c ============================================================================== --- head/sys/dev/syscons/syscons.c Sat Mar 4 08:46:57 2017 (r314645) +++ head/sys/dev/syscons/syscons.c Sat Mar 4 08:47:31 2017 (r314646) @@ -266,6 +266,65 @@ static struct cdevsw consolectl_devsw = .d_name = "consolectl", }; +/* ec -- emergency console. */ + +static u_int ec_scroffset; + +/* + * Fake enough of main_console for ec_putc() to work very early on x86 if + * the kernel starts in normal color text mode. On non-x86, scribbling + * to the x86 normal color text frame buffer's addresses is unsafe, so + * set (likely non-fake) graphics mode to get a null initial ec_putc(). + */ +static scr_stat fake_main_console = { + .scr.vtb_buffer = 0xb8000, + .xsize = 80, + .ysize = 25, +#if !defined(__amd64__) && !defined(__i386__) + .status = GRAPHICS_MODE, +#endif +}; + +#define main_console (sc_console == NULL ? fake_main_console : main_console) + +static void +ec_putc(int c) +{ + u_short *scrptr; + u_int ind; + int attr, column, mysize, width, xsize, yborder, ysize; + + if (main_console.status & GRAPHICS_MODE || + c < 0 || c > 0xff || c == '\a') + return; + xsize = main_console.xsize; + ysize = main_console.ysize; + yborder = ysize / 5; + scrptr = (u_short *)main_console.scr.vtb_buffer + xsize * yborder; + mysize = xsize * (ysize - 2 * yborder); + do { + ind = ec_scroffset; + column = ind % xsize; + width = (c == '\b' ? -1 : c == '\t' ? (column + 8) & ~7 : + c == '\r' ? -column : c == '\n' ? xsize - column : 1); + if (width == 0 || (width < 0 && ind < -width)) + return; + } while (atomic_cmpset_rel_int(&ec_scroffset, ind, ind + width) == 0); + if (c == '\b' || c == '\r') + return; + if (c == '\n') + ind += xsize; /* XXX clearing from new pos is not atomic */ + + attr = sc_kattr(); + if (c == '\t' || c == '\n') + c = ' '; + do + scrptr[ind++ % mysize] = (attr << 8) | c; + while (--width != 0); +} + +#undef main_console + int sc_probe_unit(int unit, int flags) { @@ -1861,10 +1920,13 @@ sc_cnputc(struct consdev *cd, int c) sc_cnputc_log[head % sizeof(sc_cnputc_log)] = c; /* - * If we couldn't open, return to defer output. + * If we couldn't open, do special reentrant output and return to defer + * normal output. */ - if (!st.scr_opened) + if (!st.scr_opened) { + ec_putc(c); return; + } #ifndef SC_NO_HISTORY if (scp == scp->sc->cur_scp && scp->status & SLKED) { From owner-svn-src-all@freebsd.org Wed Mar 15 00:29:29 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 489FED0D790; Wed, 15 Mar 2017 00:29:29 +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 03EFF1E4A; Wed, 15 Mar 2017 00:29:28 +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 v2F0TS0a031685; Wed, 15 Mar 2017 00:29:28 GMT (envelope-from markj@FreeBSD.org) Received: (from markj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F0TSSE031684; Wed, 15 Mar 2017 00:29:28 GMT (envelope-from markj@FreeBSD.org) Message-Id: <201703150029.v2F0TSSE031684@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: markj set sender to markj@FreeBSD.org using -f From: Mark Johnston Date: Wed, 15 Mar 2017 00:29:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315289 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 00:29:29 -0000 Author: markj Date: Wed Mar 15 00:29:27 2017 New Revision: 315289 URL: https://svnweb.freebsd.org/changeset/base/315289 Log: When draining a callout, don't clear CALLOUT_ACTIVE while it is running. The callout may reschedule itself and execute again before callout_drain() returns, but we should not clear CALLOUT_ACTIVE until the callout is stopped. Tested by: pho MFC after: 2 weeks Sponsored by: Dell EMC Isilon Modified: head/sys/kern/kern_timeout.c Modified: head/sys/kern/kern_timeout.c ============================================================================== --- head/sys/kern/kern_timeout.c Tue Mar 14 22:25:07 2017 (r315288) +++ head/sys/kern/kern_timeout.c Wed Mar 15 00:29:27 2017 (r315289) @@ -1254,9 +1254,12 @@ again: if (cc_exec_curr(cc, direct) == c) { /* * Succeed we to stop it or not, we must clear the - * active flag - this is what API users expect. + * active flag - this is what API users expect. If we're + * draining and the callout is currently executing, first wait + * until it finishes. */ - c->c_flags &= ~CALLOUT_ACTIVE; + if ((flags & CS_DRAIN) == 0) + c->c_flags &= ~CALLOUT_ACTIVE; if ((flags & CS_DRAIN) != 0) { /* @@ -1315,6 +1318,7 @@ again: PICKUP_GIANT(); CC_LOCK(cc); } + c->c_flags &= ~CALLOUT_ACTIVE; } else if (use_lock && !cc_exec_cancel(cc, direct) && (drain == NULL)) { From owner-svn-src-all@freebsd.org Wed Mar 15 01:26:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4476BD0A709; Wed, 15 Mar 2017 01:26:49 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: from venus.codepro.be (venus.codepro.be [IPv6:2a01:4f8:162:1127::2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.codepro.be", Issuer "Gandi Standard SSL CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 10BD01878; Wed, 15 Mar 2017 01:26:49 +0000 (UTC) (envelope-from kp@FreeBSD.org) Received: from [192.168.8.218] (203.141.139.231.static.zoot.jp [203.141.139.231]) (Authenticated sender: kp) by venus.codepro.be (Postfix) with ESMTPSA id 2ECF61E97C; Wed, 15 Mar 2017 02:26:42 +0100 (CET) From: "Kristof Provost" To: "Gleb Smirnoff" Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315136 - head/sys/netpfil/pf Date: Wed, 15 Mar 2017 10:26:39 +0900 Message-ID: <7B1C8879-E636-4315-99A2-A258AB9AE500@FreeBSD.org> In-Reply-To: <20170314215706.GB1072@FreeBSD.org> References: <201703120542.v2C5gvM4075391@repo.freebsd.org> <20170314215706.GB1072@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Mailer: MailMate (2.0BETAr6080) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 01:26:49 -0000 On 15 Mar 2017, at 6:57, Gleb Smirnoff wrote: > On Sun, Mar 12, 2017 at 05:42:57AM +0000, Kristof Provost wrote: > K> Log: > K> pf: Fix incorrect rw_sleep() in pf_unload() > K> > K> When we unload we don't hold the pf_rules_lock, so we cannot call > rw_sleep() > K> with it, because it would release a lock we do not hold. There's > no need for the > K> lock either, so we can just tsleep(). > K> > K> While here also make the same change in pf_purge_thread(), > because it explicitly > K> takes the lock before rw_sleep() and then immediately releases it > afterwards. > > The correct change would to be grab lock in pf_unload(), exactly as > pf_purge_thread() > does. With your change you introduces a possible infinite sleep due to > race, since > there is no timeout and no lock. > I must be missing something, because I don’t see the race, and don’t see how we could end up with an infinite sleep. Even if pf_purge_thread() somehow misses that pf_end_threads is non-zero (say it was not sleeping but executing the last vnet cleanup after the pf_end_threads check) while pf_unload() calls the wakeup_one(pf_purge_thread) it would still terminate the next time the tsleep() timed out. The only way around that would be to hold the PF_RULES_LOCK() during all of pf_purge_thread() that’s not actually sleeping. That’s non-trivial because pf_purge_unlinked_rules() also takes the PF_RULES_LOCK and there are lock ordering constraints with some of the other locks taken in the other cleanup code. Given that unloading pf is a non-supported development use case (see MOD_QUIESCE in pf_modevent()), I think I’d rather accept the occasional 10 second delay in unloading. There is another issue with unloading (vnet_pf_uninit() gets called after pf_unload(), which means we try to take a destroyed lock), for which I’ll have a patch soon. Regards, Kristof From owner-svn-src-all@freebsd.org Wed Mar 15 01:53:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D8554D0ACF3; Wed, 15 Mar 2017 01:53:30 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail110.syd.optusnet.com.au (mail110.syd.optusnet.com.au [211.29.132.97]) by mx1.freebsd.org (Postfix) with ESMTP id 7BB64135E; Wed, 15 Mar 2017 01:53:30 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c122-106-153-191.carlnfd1.nsw.optusnet.com.au [122.106.153.191]) by mail110.syd.optusnet.com.au (Postfix) with ESMTPS id 6E720105F1F; Wed, 15 Mar 2017 12:53:21 +1100 (AEDT) Date: Wed, 15 Mar 2017 12:53:20 +1100 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Eric van Gyzen cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315277 - in head/sys: dev/cxgb/ulp/iw_cxgb netinet In-Reply-To: <201703141827.v2EIRmLv080307@repo.freebsd.org> Message-ID: <20170315110727.M964@besplex.bde.org> References: <201703141827.v2EIRmLv080307@repo.freebsd.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=KeqiiUQD c=1 sm=1 tr=0 a=Tj3pCpwHnMupdyZSltBt7Q==:117 a=Tj3pCpwHnMupdyZSltBt7Q==:17 a=kj9zAlcOel0A:10 a=wRcB3c5BtoXeLLscNvUA:9 a=Pq97Be7vu5kELnKR:21 a=ugwPLQF33PDyiZ65:21 a=CjuIK1q_8ugA:10 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 01:53:31 -0000 On Tue, 14 Mar 2017, Eric van Gyzen wrote: > Log: > KTR: log IPv4 addresses in hex rather than dotted-quad > > When I made the changes in r313821, I fell victim to one of the > classic blunders, the most famous of which is: never get involved > in a land war in Asia. But only slightly less well known is this: > Keep your brain turned on and engaged when making a tedious, sweeping, > mechanical change. KTR can correctly log the immediate integral values > passed to it, as well as constant strings, but not non-constant strings, > since they might change by the time ktrdump retrieves them. > > Reported by: glebius > MFC after: 3 days > Sponsored by: Dell EMC The new format is too raw. Hex is just as easy to read as dotted-quad, but inet_ntoa() also does the equivalent of htonl(). Due to not using it, addresses are now printed reversed in most but not all cases on little-endian arches. They should be converted to host byte order using ntohl() except when they are already in host byte order. Old code already prints some addresses using the bad format %lx or worse (this should be 0x%08x like new code) and still does this conversion. This conversion is still correct, except it doesn't do the reversal on little-endian arches, so users would have to guess which cases are reversed. Addresses are sometimes in host byte order to begin with. Old code might print these in hex without conversion, but when it called inet_ntoa() it first converted to network byte order using htonl(). This now gives consistent reversals on little-endian arches. This commit also fixes the style bug of messes from using the badly-designed API inet_ntoa_r(), but not nearby style bugs. > Modified: head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c > ============================================================================== > --- head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 18:08:32 2017 (r315276) > +++ head/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cm.c Tue Mar 14 18:27:48 2017 (r315277) > @@ -1481,9 +1478,8 @@ process_data(struct iwch_ep *ep) > */ > in_getsockaddr(ep->com.so, (struct sockaddr **)&local); > in_getpeeraddr(ep->com.so, (struct sockaddr **)&remote); > - CTR3(KTR_IW_CXGB, "%s local %s remote %s", __FUNCTION__, > - inet_ntoa_r(local->sin_addr, local_str), > - inet_ntoa_r(remote->sin_addr, remote_str)); > + CTR3(KTR_IW_CXGB, "%s local 0x%08x remote 0x%08x", __FUNCTION__, > + local->sin_addr.s_addr, remote->sin_addr.s_addr); > ep->com.local_addr = *local; > ep->com.remote_addr = *remote; > free(local, M_SONAME); Still has 3 style bugs: - continuation indent of 8 instead of KNF 4 - obfuscates the function name by not using a string literal - doesn't even spell the obfuscation using its C99 name __func__. CTR*() uses obfuscated macros which prevent checking for printf() format errors. The macros convert all args to u_long, so all formats except %lx are technically broken. Using htonl() would also convert to a consistent type that is technically correct. htonl() used to return long, but it now returns uint32_t, and the type hacks for CTR*() depend on much the same magic as long sort of being the same as uint32_t for the purposes of htonl(). But changing the type of htonl() broke lots of printf() formats, expecially in code that was careful enough to use the right format to print longs. [... another instances of the above style bugs, and more __FUNCTION__'s visible in unchanged code. > Modified: head/sys/netinet/igmp.c > ============================================================================== > --- head/sys/netinet/igmp.c Tue Mar 14 18:08:32 2017 (r315276) > +++ head/sys/netinet/igmp.c Tue Mar 14 18:27:48 2017 (r315277) > @@ -312,17 +312,6 @@ igmp_scrub_context(struct mbuf *m) > m->m_pkthdr.flowid = 0; > } > > -#ifdef KTR > -static __inline char * > -inet_ntoa_haddr(in_addr_t haddr, char *addrbuf) > -{ > - struct in_addr ia; > - > - ia.s_addr = htonl(haddr); > - return (inet_ntoa_r(ia, addrbuf)); > -} > -#endif This did a double reversal on little-endian arches. The first reversal is now done directly. So the order is even more confusing but less MD than I first thought. I think the address now ends up looking consistently backwards on little-endian arches (provided all callers remember to do the above conversion iff their address starts in host byte order). > @@ -875,9 +861,9 @@ igmp_input_v2_query(struct ifnet *ifp, c > */ > inm = inm_lookup(ifp, igmp->igmp_group); > if (inm != NULL) { > - CTR3(KTR_IGMPV3, "process v2 query %s on ifp %p(%s)", > - inet_ntoa_r(igmp->igmp_group, addrbuf), ifp, > - ifp->if_xname); > + CTR3(KTR_IGMPV3, > + "process v2 query 0x%08x on ifp %p(%s)", > + igmp->igmp_group.s_addr, ifp, ifp->if_xname); > igmp_v2_update_group(inm, timer); > } > } This doesn't have the obfuscations to print the function's name, since it doesn't print the name. Like for KASSERT(), the function name probably shouldn't supplied explicitly or omitted explicity fby the caller, but should be supplied automatically like for assert(3), but not as badly implemented as for assert(3). It can be recovered from the program counter in a way that shouldn't pessimize for space or time. For KTR, it seems to be necessary to pessimize in the generated record (if the user wants function names). The program counter would have to be recorded. Always recording it would be shorter than usually recording pointers to the function's name or literal strings. > @@ -907,12 +893,9 @@ out_locked: > static void > igmp_v2_update_group(struct in_multi *inm, const int timer) > { > -#ifdef KTR > - char addrbuf[INET_ADDRSTRLEN]; > -#endif > > - CTR4(KTR_IGMPV3, "%s: %s/%s timer=%d", __func__, > - inet_ntoa_r(inm->inm_addr, addrbuf), inm->inm_ifp->if_xname, timer); > + CTR4(KTR_IGMPV3, "0x%08x: %s/%s timer=%d", __func__, > + inm->inm_addr.s_addr, inm->inm_ifp->if_xname, timer); This uses the usual obfuscation of the function's name. > ... Most calls print the function name using the __func__ obfuscation, and don't have indentation errors, and are prefectly backwards for htonl()/ ntohl(). > ... > Modified: head/sys/netinet/ip_mroute.c > ============================================================================== > --- head/sys/netinet/ip_mroute.c Tue Mar 14 18:08:32 2017 (r315276) > +++ head/sys/netinet/ip_mroute.c Tue Mar 14 18:27:48 2017 (r315277) > @@ -1066,8 +1060,8 @@ add_mfc(struct mfcctl2 *mfccp) > > /* If an entry already exists, just update the fields */ > if (rt) { > - CTR4(KTR_IPMF, "%s: update mfc orig %s group %lx parent %x", > - __func__, inet_ntoa_r(mfccp->mfcc_origin, addrbuf), > + CTR4(KTR_IPMF, "%s: update mfc orig 0x%08x group %lx parent %x", > + __func__, mfccp->mfcc_origin.s_addr, > (u_long)ntohl(mfccp->mfcc_mcastgrp.s_addr), > mfccp->mfcc_parent); > update_mfc_params(rt, mfccp); This one already printed 1 address in confusing hex format with a not-so bogus cast and a confusing host/network conversion for the printing, and and another confusing hex format. The old hex formats are missing 0x prefixes, so are more confusing that before now that there is a hex format not missing the prefix on the same line. ntohl() no longer returns long, but is cast to u_long for portability. This might be best for printf(), but CTR*() does the same cast. The 'l' in %lx is also technically needed and it is not having 'l' for %x in all CTR*() is technically wrong, (ktrdump copies the args to an array of u_long's and then applies the format string to this, and %x's instead of %lx's in it usually work magically) but it is best to consistently omit casts and consistently use wrong %x formats. Finally, the ntohl() is confusing. I think it is actually correct, and is what this commit should have added where inet_ntoa() was used with no htonl() before it. Apparently the variable is in network byte order, and we need to fudge it into host byte order because printf() will convert from host byte order to network byte order. printf() actually converts host integers in host byte order to big-endian order for printing, but since network byte order is big endian this is like htonl() to reverse the ntohl() in the above. Bruce From owner-svn-src-all@freebsd.org Wed Mar 15 04:16:09 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D1BD6D0D3ED; Wed, 15 Mar 2017 04:16:09 +0000 (UTC) (envelope-from jpaetzel@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 AC70511A0; Wed, 15 Mar 2017 04:16:09 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2F4G8Fi025017; Wed, 15 Mar 2017 04:16:08 GMT (envelope-from jpaetzel@FreeBSD.org) Received: (from jpaetzel@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F4G8xo025013; Wed, 15 Mar 2017 04:16:08 GMT (envelope-from jpaetzel@FreeBSD.org) Message-Id: <201703150416.v2F4G8xo025013@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jpaetzel set sender to jpaetzel@FreeBSD.org using -f From: Josh Paetzel Date: Wed, 15 Mar 2017 04:16:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r315290 - in vendor/illumos/dist: cmd/zdb cmd/ztest lib/libzpool/common lib/libzpool/common/sys X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 04:16:09 -0000 Author: jpaetzel Date: Wed Mar 15 04:16:08 2017 New Revision: 315290 URL: https://svnweb.freebsd.org/changeset/base/315290 Log: 7303 dynamic metaslab selection illumos/illumos-gate@8363e80ae72609660f6090766ca8c2c18aa53f0c https://github.com/illumos/illumos-gate/commit/8363e80ae72609660f6090766ca8c2c18aa53f0 https://www.illumos.org/issues/7303 This change introduces a new weighting algorithm to improve metaslab selection. The new weighting algorithm relies on the SPACEMAP_HISTOGRAM feature. As a result, the metaslab weight now encodes the type of weighting algorithm used (size-based vs segment-based). This also introduce a new allocation tracing facility and two new dcmds to help debug allocation problems. Each zio now contains a zio_alloc_list_t structure that is populated as the zio goes through the allocations stage. Here's an example of how to use the tracing facility: > c5ec000::print zio_t io_alloc_list | ::walk list | ::metaslab_trace MSID DVA ASIZE WEIGHT RESULT VDEV - 0 400 0 NOT_ALLOCATABLE ztest.0a - 0 400 0 NOT_ALLOCATABLE ztest.0a - 0 400 0 ENOSPC ztest.0a - 0 200 0 NOT_ALLOCATABLE ztest.0a - 0 200 0 NOT_ALLOCATABLE ztest.0a - 0 200 0 ENOSPC ztest.0a 1 0 400 1 x 8M 17b1a00 ztest.0a > 1ff2400::print zio_t io_alloc_list | ::walk list | ::metaslab_trace MSID DVA ASIZE WEIGHT RESULT VDEV - 0 200 0 NOT_ALLOCATABLE mirror-2 - 0 200 0 NOT_ALLOCATABLE mirror-0 1 0 200 1 x 4M 112ae00 mirror-1 - 1 200 0 NOT_ALLOCATABLE mirror-2 - 1 200 0 NOT_ALLOCATABLE mirror-0 1 1 200 1 x 4M 112b000 mirror-1 - 2 200 0 NOT_ALLOCATABLE mirror-2 If the metaslab is using segment-based weighting then the WEIGHT column will display the number of segments available in the bucket where the allocation attempt was made. Author: George Wilson Reviewed by: Alex Reece Reviewed by: Chris Siden Reviewed by: Dan Kimmel Reviewed by: Matthew Ahrens Reviewed by: Paul Dagnelie Reviewed by: Pavel Zakharov Reviewed by: Prakash Surya Reviewed by: Don Brady Approved by: Richard Lowe Modified: vendor/illumos/dist/cmd/zdb/zdb.c vendor/illumos/dist/cmd/ztest/ztest.c vendor/illumos/dist/lib/libzpool/common/kernel.c vendor/illumos/dist/lib/libzpool/common/sys/zfs_context.h Modified: vendor/illumos/dist/cmd/zdb/zdb.c ============================================================================== --- vendor/illumos/dist/cmd/zdb/zdb.c Wed Mar 15 00:29:27 2017 (r315289) +++ vendor/illumos/dist/cmd/zdb/zdb.c Wed Mar 15 04:16:08 2017 (r315290) @@ -2562,10 +2562,21 @@ zdb_leak_init(spa_t *spa, zdb_cb_t *zcb) if (!dump_opt['L']) { vdev_t *rvd = spa->spa_root_vdev; + + /* + * We are going to be changing the meaning of the metaslab's + * ms_tree. Ensure that the allocator doesn't try to + * use the tree. + */ + spa->spa_normal_class->mc_ops = &zdb_metaslab_ops; + spa->spa_log_class->mc_ops = &zdb_metaslab_ops; + for (uint64_t c = 0; c < rvd->vdev_children; c++) { vdev_t *vd = rvd->vdev_child[c]; + metaslab_group_t *mg = vd->vdev_mg; for (uint64_t m = 0; m < vd->vdev_ms_count; m++) { metaslab_t *msp = vd->vdev_ms[m]; + ASSERT3P(msp->ms_group, ==, mg); mutex_enter(&msp->ms_lock); metaslab_unload(msp); @@ -2586,8 +2597,6 @@ zdb_leak_init(spa_t *spa, zdb_cb_t *zcb) (longlong_t)m, (longlong_t)vd->vdev_ms_count); - msp->ms_ops = &zdb_metaslab_ops; - /* * We don't want to spend the CPU * manipulating the size-ordered @@ -2597,7 +2606,10 @@ zdb_leak_init(spa_t *spa, zdb_cb_t *zcb) msp->ms_tree->rt_ops = NULL; VERIFY0(space_map_load(msp->ms_sm, msp->ms_tree, SM_ALLOC)); - msp->ms_loaded = B_TRUE; + + if (!msp->ms_loaded) { + msp->ms_loaded = B_TRUE; + } } mutex_exit(&msp->ms_lock); } @@ -2619,8 +2631,10 @@ zdb_leak_fini(spa_t *spa) vdev_t *rvd = spa->spa_root_vdev; for (int c = 0; c < rvd->vdev_children; c++) { vdev_t *vd = rvd->vdev_child[c]; + metaslab_group_t *mg = vd->vdev_mg; for (int m = 0; m < vd->vdev_ms_count; m++) { metaslab_t *msp = vd->vdev_ms[m]; + ASSERT3P(mg, ==, msp->ms_group); mutex_enter(&msp->ms_lock); /* @@ -2634,7 +2648,10 @@ zdb_leak_fini(spa_t *spa) * from the ms_tree. */ range_tree_vacate(msp->ms_tree, zdb_leak, vd); - msp->ms_loaded = B_FALSE; + + if (msp->ms_loaded) { + msp->ms_loaded = B_FALSE; + } mutex_exit(&msp->ms_lock); } Modified: vendor/illumos/dist/cmd/ztest/ztest.c ============================================================================== --- vendor/illumos/dist/cmd/ztest/ztest.c Wed Mar 15 00:29:27 2017 (r315289) +++ vendor/illumos/dist/cmd/ztest/ztest.c Wed Mar 15 04:16:08 2017 (r315290) @@ -171,7 +171,7 @@ static const ztest_shared_opts_t ztest_o .zo_mirrors = 2, .zo_raidz = 4, .zo_raidz_parity = 1, - .zo_vdev_size = SPA_MINDEVSIZE * 2, + .zo_vdev_size = SPA_MINDEVSIZE * 4, /* 256m default size */ .zo_datasets = 7, .zo_threads = 23, .zo_passtime = 60, /* 60 seconds */ Modified: vendor/illumos/dist/lib/libzpool/common/kernel.c ============================================================================== --- vendor/illumos/dist/lib/libzpool/common/kernel.c Wed Mar 15 00:29:27 2017 (r315289) +++ vendor/illumos/dist/lib/libzpool/common/kernel.c Wed Mar 15 04:16:08 2017 (r315290) @@ -94,6 +94,11 @@ kstat_create(const char *module, int ins /*ARGSUSED*/ void +kstat_named_init(kstat_named_t *knp, const char *name, uchar_t type) +{} + +/*ARGSUSED*/ +void kstat_install(kstat_t *ksp) {} Modified: vendor/illumos/dist/lib/libzpool/common/sys/zfs_context.h ============================================================================== --- vendor/illumos/dist/lib/libzpool/common/sys/zfs_context.h Wed Mar 15 00:29:27 2017 (r315289) +++ vendor/illumos/dist/lib/libzpool/common/sys/zfs_context.h Wed Mar 15 04:16:08 2017 (r315290) @@ -301,6 +301,7 @@ extern void cv_broadcast(kcondvar_t *cv) */ extern kstat_t *kstat_create(const char *, int, const char *, const char *, uchar_t, ulong_t, uchar_t); +extern void kstat_named_init(kstat_named_t *, const char *, uchar_t); extern void kstat_install(kstat_t *); extern void kstat_delete(kstat_t *); extern void kstat_waitq_enter(kstat_io_t *); From owner-svn-src-all@freebsd.org Wed Mar 15 04:18:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DC931D0D4D6; Wed, 15 Mar 2017 04:18:41 +0000 (UTC) (envelope-from jpaetzel@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 9D5D813A0; Wed, 15 Mar 2017 04:18:41 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2F4IeJU025192; Wed, 15 Mar 2017 04:18:40 GMT (envelope-from jpaetzel@FreeBSD.org) Received: (from jpaetzel@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F4Iesf025190; Wed, 15 Mar 2017 04:18:40 GMT (envelope-from jpaetzel@FreeBSD.org) Message-Id: <201703150418.v2F4Iesf025190@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jpaetzel set sender to jpaetzel@FreeBSD.org using -f From: Josh Paetzel Date: Wed, 15 Mar 2017 04:18:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r315291 - in vendor-sys/illumos/dist/uts/common/fs/zfs: . sys X-SVN-Group: vendor-sys MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 04:18:42 -0000 Author: jpaetzel Date: Wed Mar 15 04:18:40 2017 New Revision: 315291 URL: https://svnweb.freebsd.org/changeset/base/315291 Log: 7303 dynamic metaslab selection illumos/illumos-gate@8363e80ae72609660f6090766ca8c2c18aa53f0c https://github.com/illumos/illumos-gate/commit/8363e80ae72609660f6090766ca8c2c18aa53f0 https://www.illumos.org/issues/7303 This change introduces a new weighting algorithm to improve metaslab selection. The new weighting algorithm relies on the SPACEMAP_HISTOGRAM feature. As a result, the metaslab weight now encodes the type of weighting algorithm used (size-based vs segment-based). This also introduce a new allocation tracing facility and two new dcmds to help debug allocation problems. Each zio now contains a zio_alloc_list_t structure that is populated as the zio goes through the allocations stage. Here's an example of how to use the tracing facility: > c5ec000::print zio_t io_alloc_list | ::walk list | ::metaslab_trace MSID DVA ASIZE WEIGHT RESULT VDEV - 0 400 0 NOT_ALLOCATABLE ztest.0a - 0 400 0 NOT_ALLOCATABLE ztest.0a - 0 400 0 ENOSPC ztest.0a - 0 200 0 NOT_ALLOCATABLE ztest.0a - 0 200 0 NOT_ALLOCATABLE ztest.0a - 0 200 0 ENOSPC ztest.0a 1 0 400 1 x 8M 17b1a00 ztest.0a > 1ff2400::print zio_t io_alloc_list | ::walk list | ::metaslab_trace MSID DVA ASIZE WEIGHT RESULT VDEV - 0 200 0 NOT_ALLOCATABLE mirror-2 - 0 200 0 NOT_ALLOCATABLE mirror-0 1 0 200 1 x 4M 112ae00 mirror-1 - 1 200 0 NOT_ALLOCATABLE mirror-2 - 1 200 0 NOT_ALLOCATABLE mirror-0 1 1 200 1 x 4M 112b000 mirror-1 - 2 200 0 NOT_ALLOCATABLE mirror-2 If the metaslab is using segment-based weighting then the WEIGHT column will display the number of segments available in the bucket where the allocation attempt was made. Author: George Wilson Reviewed by: Alex Reece Reviewed by: Chris Siden Reviewed by: Dan Kimmel Reviewed by: Matthew Ahrens Reviewed by: Paul Dagnelie Reviewed by: Pavel Zakharov Reviewed by: Prakash Surya Reviewed by: Don Brady Approved by: Richard Lowe Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/metaslab.c vendor-sys/illumos/dist/uts/common/fs/zfs/spa.c vendor-sys/illumos/dist/uts/common/fs/zfs/spa_misc.c vendor-sys/illumos/dist/uts/common/fs/zfs/space_map.c vendor-sys/illumos/dist/uts/common/fs/zfs/sys/metaslab.h vendor-sys/illumos/dist/uts/common/fs/zfs/sys/metaslab_impl.h vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zfs_debug.h vendor-sys/illumos/dist/uts/common/fs/zfs/sys/zio.h vendor-sys/illumos/dist/uts/common/fs/zfs/zio.c Modified: vendor-sys/illumos/dist/uts/common/fs/zfs/metaslab.c ============================================================================== --- vendor-sys/illumos/dist/uts/common/fs/zfs/metaslab.c Wed Mar 15 04:16:08 2017 (r315290) +++ vendor-sys/illumos/dist/uts/common/fs/zfs/metaslab.c Wed Mar 15 04:18:40 2017 (r315291) @@ -38,18 +38,13 @@ #define GANG_ALLOCATION(flags) \ ((flags) & (METASLAB_GANG_CHILD | METASLAB_GANG_HEADER)) -#define METASLAB_WEIGHT_PRIMARY (1ULL << 63) -#define METASLAB_WEIGHT_SECONDARY (1ULL << 62) -#define METASLAB_ACTIVE_MASK \ - (METASLAB_WEIGHT_PRIMARY | METASLAB_WEIGHT_SECONDARY) - uint64_t metaslab_aliquot = 512ULL << 10; uint64_t metaslab_gang_bang = SPA_MAXBLOCKSIZE + 1; /* force gang blocks */ /* * The in-core space map representation is more compact than its on-disk form. * The zfs_condense_pct determines how much more compact the in-core - * space_map representation must be before we compact it on-disk. + * space map representation must be before we compact it on-disk. * Values should be greater than or equal to 100. */ int zfs_condense_pct = 200; @@ -122,7 +117,7 @@ uint64_t metaslab_df_alloc_threshold = S /* * The minimum free space, in percent, which must be available * in a space map to continue allocations in a first-fit fashion. - * Once the space_map's free space drops below this level we dynamically + * Once the space map's free space drops below this level we dynamically * switch to using best-fit allocations. */ int metaslab_df_free_pct = 4; @@ -170,7 +165,38 @@ boolean_t metaslab_lba_weighting_enabled */ boolean_t metaslab_bias_enabled = B_TRUE; -static uint64_t metaslab_fragmentation(metaslab_t *); +/* + * Enable/disable segment-based metaslab selection. + */ +boolean_t zfs_metaslab_segment_weight_enabled = B_TRUE; + +/* + * When using segment-based metaslab selection, we will continue + * allocating from the active metaslab until we have exhausted + * zfs_metaslab_switch_threshold of its buckets. + */ +int zfs_metaslab_switch_threshold = 2; + +/* + * Internal switch to enable/disable the metaslab allocation tracing + * facility. + */ +boolean_t metaslab_trace_enabled = B_TRUE; + +/* + * Maximum entries that the metaslab allocation tracing facility will keep + * in a given list when running in non-debug mode. We limit the number + * of entries in non-debug mode to prevent us from using up too much memory. + * The limit should be sufficiently large that we don't expect any allocation + * to every exceed this value. In debug mode, the system will panic if this + * limit is ever reached allowing for further investigation. + */ +uint64_t metaslab_trace_max_entries = 5000; + +static uint64_t metaslab_weight(metaslab_t *); +static void metaslab_set_fragmentation(metaslab_t *); + +kmem_cache_t *metaslab_alloc_trace_cache; /* * ========================================================================== @@ -388,11 +414,6 @@ metaslab_class_expandable_space(metaslab return (space); } -/* - * ========================================================================== - * Metaslab groups - * ========================================================================== - */ static int metaslab_compare(const void *x1, const void *x2) { @@ -418,6 +439,57 @@ metaslab_compare(const void *x1, const v } /* + * Verify that the space accounting on disk matches the in-core range_trees. + */ +void +metaslab_verify_space(metaslab_t *msp, uint64_t txg) +{ + spa_t *spa = msp->ms_group->mg_vd->vdev_spa; + uint64_t allocated = 0; + uint64_t freed = 0; + uint64_t sm_free_space, msp_free_space; + + ASSERT(MUTEX_HELD(&msp->ms_lock)); + + if ((zfs_flags & ZFS_DEBUG_METASLAB_VERIFY) == 0) + return; + + /* + * We can only verify the metaslab space when we're called + * from syncing context with a loaded metaslab that has an allocated + * space map. Calling this in non-syncing context does not + * provide a consistent view of the metaslab since we're performing + * allocations in the future. + */ + if (txg != spa_syncing_txg(spa) || msp->ms_sm == NULL || + !msp->ms_loaded) + return; + + sm_free_space = msp->ms_size - space_map_allocated(msp->ms_sm) - + space_map_alloc_delta(msp->ms_sm); + + /* + * Account for future allocations since we would have already + * deducted that space from the ms_freetree. + */ + for (int t = 0; t < TXG_CONCURRENT_STATES; t++) { + allocated += + range_tree_space(msp->ms_alloctree[(txg + t) & TXG_MASK]); + } + freed = range_tree_space(msp->ms_freetree[TXG_CLEAN(txg) & TXG_MASK]); + + msp_free_space = range_tree_space(msp->ms_tree) + allocated + + msp->ms_deferspace + freed; + + VERIFY3U(sm_free_space, ==, msp_free_space); +} + +/* + * ========================================================================== + * Metaslab groups + * ========================================================================== + */ +/* * Update the allocatable flag and the metaslab group's capacity. * The allocatable flag is set to true if the capacity is below * the zfs_mg_noalloc_threshold or has a fragmentation value that is @@ -989,7 +1061,7 @@ static range_tree_ops_t metaslab_rt_ops /* * ========================================================================== - * Metaslab block operations + * Common allocator routines * ========================================================================== */ @@ -1008,31 +1080,22 @@ metaslab_block_maxsize(metaslab_t *msp) return (rs->rs_end - rs->rs_start); } -uint64_t -metaslab_block_alloc(metaslab_t *msp, uint64_t size) +static range_seg_t * +metaslab_block_find(avl_tree_t *t, uint64_t start, uint64_t size) { - uint64_t start; - range_tree_t *rt = msp->ms_tree; - - VERIFY(!msp->ms_condensing); + range_seg_t *rs, rsearch; + avl_index_t where; - start = msp->ms_ops->msop_alloc(msp, size); - if (start != -1ULL) { - vdev_t *vd = msp->ms_group->mg_vd; + rsearch.rs_start = start; + rsearch.rs_end = start + size; - VERIFY0(P2PHASE(start, 1ULL << vd->vdev_ashift)); - VERIFY0(P2PHASE(size, 1ULL << vd->vdev_ashift)); - VERIFY3U(range_tree_space(rt) - size, <=, msp->ms_size); - range_tree_remove(rt, start, size); + rs = avl_find(t, &rsearch, &where); + if (rs == NULL) { + rs = avl_nearest(t, where, AVL_AFTER); } - return (start); -} -/* - * ========================================================================== - * Common allocator routines - * ========================================================================== - */ + return (rs); +} /* * This is a helper function that can be used by the allocator to find @@ -1043,15 +1106,7 @@ static uint64_t metaslab_block_picker(avl_tree_t *t, uint64_t *cursor, uint64_t size, uint64_t align) { - range_seg_t *rs, rsearch; - avl_index_t where; - - rsearch.rs_start = *cursor; - rsearch.rs_end = *cursor + size; - - rs = avl_find(t, &rsearch, &where); - if (rs == NULL) - rs = avl_nearest(t, where, AVL_AFTER); + range_seg_t *rs = metaslab_block_find(t, *cursor, size); while (rs != NULL) { uint64_t offset = P2ROUNDUP(rs->rs_start, align); @@ -1276,6 +1331,7 @@ int metaslab_load(metaslab_t *msp) { int error = 0; + boolean_t success = B_FALSE; ASSERT(MUTEX_HELD(&msp->ms_lock)); ASSERT(!msp->ms_loaded); @@ -1293,14 +1349,18 @@ metaslab_load(metaslab_t *msp) else range_tree_add(msp->ms_tree, msp->ms_start, msp->ms_size); - msp->ms_loaded = (error == 0); + success = (error == 0); msp->ms_loading = B_FALSE; - if (msp->ms_loaded) { + if (success) { + ASSERT3P(msp->ms_group, !=, NULL); + msp->ms_loaded = B_TRUE; + for (int t = 0; t < TXG_DEFER_SIZE; t++) { range_tree_walk(msp->ms_defertree[t], range_tree_remove, msp->ms_tree); } + msp->ms_max_size = metaslab_block_maxsize(msp); } cv_broadcast(&msp->ms_load_cv); return (error); @@ -1313,6 +1373,7 @@ metaslab_unload(metaslab_t *msp) range_tree_vacate(msp->ms_tree, NULL, NULL); msp->ms_loaded = B_FALSE; msp->ms_weight &= ~METASLAB_ACTIVE_MASK; + msp->ms_max_size = 0; } int @@ -1357,21 +1418,23 @@ metaslab_init(metaslab_group_t *mg, uint ms->ms_tree = range_tree_create(&metaslab_rt_ops, ms, &ms->ms_lock); metaslab_group_add(mg, ms); - ms->ms_fragmentation = metaslab_fragmentation(ms); - ms->ms_ops = mg->mg_class->mc_ops; + metaslab_set_fragmentation(ms); /* * If we're opening an existing pool (txg == 0) or creating * a new one (txg == TXG_INITIAL), all space is available now. * If we're adding space to an existing pool, the new space * does not become available until after this txg has synced. + * The metaslab's weight will also be initialized when we sync + * out this txg. This ensures that we don't attempt to allocate + * from it before we have initialized it completely. */ if (txg <= TXG_INITIAL) metaslab_sync_done(ms, 0); /* * If metaslab_debug_load is set and we're initializing a metaslab - * that has an allocated space_map object then load the its space + * that has an allocated space map object then load the its space * map so that can verify frees. */ if (metaslab_debug_load && ms->ms_sm != NULL) { @@ -1398,7 +1461,6 @@ metaslab_fini(metaslab_t *msp) metaslab_group_remove(mg, msp); mutex_enter(&msp->ms_lock); - VERIFY(msp->ms_group == NULL); vdev_space_update(mg->mg_vd, -space_map_allocated(msp->ms_sm), 0, -msp->ms_size); @@ -1471,8 +1533,8 @@ int zfs_frag_table[FRAGMENTATION_TABLE_S * not support this metric. Otherwise, the return value should be in the * range [0, 100]. */ -static uint64_t -metaslab_fragmentation(metaslab_t *msp) +static void +metaslab_set_fragmentation(metaslab_t *msp) { spa_t *spa = msp->ms_group->mg_vd->vdev_spa; uint64_t fragmentation = 0; @@ -1480,18 +1542,22 @@ metaslab_fragmentation(metaslab_t *msp) boolean_t feature_enabled = spa_feature_is_enabled(spa, SPA_FEATURE_SPACEMAP_HISTOGRAM); - if (!feature_enabled) - return (ZFS_FRAG_INVALID); + if (!feature_enabled) { + msp->ms_fragmentation = ZFS_FRAG_INVALID; + return; + } /* * A null space map means that the entire metaslab is free * and thus is not fragmented. */ - if (msp->ms_sm == NULL) - return (0); + if (msp->ms_sm == NULL) { + msp->ms_fragmentation = 0; + return; + } /* - * If this metaslab's space_map has not been upgraded, flag it + * If this metaslab's space map has not been upgraded, flag it * so that we upgrade next time we encounter it. */ if (msp->ms_sm->sm_dbuf->db_size != sizeof (space_map_phys_t)) { @@ -1504,12 +1570,14 @@ metaslab_fragmentation(metaslab_t *msp) spa_dbgmsg(spa, "txg %llu, requesting force condense: " "msp %p, vd %p", txg, msp, vd); } - return (ZFS_FRAG_INVALID); + msp->ms_fragmentation = ZFS_FRAG_INVALID; + return; } for (int i = 0; i < SPACE_MAP_HISTOGRAM_SIZE; i++) { uint64_t space = 0; uint8_t shift = msp->ms_sm->sm_shift; + int idx = MIN(shift - SPA_MINBLOCKSHIFT + i, FRAGMENTATION_TABLE_SIZE - 1); @@ -1526,7 +1594,8 @@ metaslab_fragmentation(metaslab_t *msp) if (total > 0) fragmentation /= total; ASSERT3U(fragmentation, <=, 100); - return (fragmentation); + + msp->ms_fragmentation = fragmentation; } /* @@ -1535,30 +1604,20 @@ metaslab_fragmentation(metaslab_t *msp) * the LBA range, and whether the metaslab is loaded. */ static uint64_t -metaslab_weight(metaslab_t *msp) +metaslab_space_weight(metaslab_t *msp) { metaslab_group_t *mg = msp->ms_group; vdev_t *vd = mg->mg_vd; uint64_t weight, space; ASSERT(MUTEX_HELD(&msp->ms_lock)); - - /* - * This vdev is in the process of being removed so there is nothing - * for us to do here. - */ - if (vd->vdev_removing) { - ASSERT0(space_map_allocated(msp->ms_sm)); - ASSERT0(vd->vdev_ms_shift); - return (0); - } + ASSERT(!vd->vdev_removing); /* * The baseline weight is the metaslab's free space. */ space = msp->ms_size - space_map_allocated(msp->ms_sm); - msp->ms_fragmentation = metaslab_fragmentation(msp); if (metaslab_fragmentation_factor_enabled && msp->ms_fragmentation != ZFS_FRAG_INVALID) { /* @@ -1607,6 +1666,210 @@ metaslab_weight(metaslab_t *msp) weight |= (msp->ms_weight & METASLAB_ACTIVE_MASK); } + WEIGHT_SET_SPACEBASED(weight); + return (weight); +} + +/* + * Return the weight of the specified metaslab, according to the segment-based + * weighting algorithm. The metaslab must be loaded. This function can + * be called within a sync pass since it relies only on the metaslab's + * range tree which is always accurate when the metaslab is loaded. + */ +static uint64_t +metaslab_weight_from_range_tree(metaslab_t *msp) +{ + uint64_t weight = 0; + uint32_t segments = 0; + + ASSERT(msp->ms_loaded); + + for (int i = RANGE_TREE_HISTOGRAM_SIZE - 1; i >= SPA_MINBLOCKSHIFT; + i--) { + uint8_t shift = msp->ms_group->mg_vd->vdev_ashift; + int max_idx = SPACE_MAP_HISTOGRAM_SIZE + shift - 1; + + segments <<= 1; + segments += msp->ms_tree->rt_histogram[i]; + + /* + * The range tree provides more precision than the space map + * and must be downgraded so that all values fit within the + * space map's histogram. This allows us to compare loaded + * vs. unloaded metaslabs to determine which metaslab is + * considered "best". + */ + if (i > max_idx) + continue; + + if (segments != 0) { + WEIGHT_SET_COUNT(weight, segments); + WEIGHT_SET_INDEX(weight, i); + WEIGHT_SET_ACTIVE(weight, 0); + break; + } + } + return (weight); +} + +/* + * Calculate the weight based on the on-disk histogram. This should only + * be called after a sync pass has completely finished since the on-disk + * information is updated in metaslab_sync(). + */ +static uint64_t +metaslab_weight_from_spacemap(metaslab_t *msp) +{ + uint64_t weight = 0; + + for (int i = SPACE_MAP_HISTOGRAM_SIZE - 1; i >= 0; i--) { + if (msp->ms_sm->sm_phys->smp_histogram[i] != 0) { + WEIGHT_SET_COUNT(weight, + msp->ms_sm->sm_phys->smp_histogram[i]); + WEIGHT_SET_INDEX(weight, i + + msp->ms_sm->sm_shift); + WEIGHT_SET_ACTIVE(weight, 0); + break; + } + } + return (weight); +} + +/* + * Compute a segment-based weight for the specified metaslab. The weight + * is determined by highest bucket in the histogram. The information + * for the highest bucket is encoded into the weight value. + */ +static uint64_t +metaslab_segment_weight(metaslab_t *msp) +{ + metaslab_group_t *mg = msp->ms_group; + uint64_t weight = 0; + uint8_t shift = mg->mg_vd->vdev_ashift; + + ASSERT(MUTEX_HELD(&msp->ms_lock)); + + /* + * The metaslab is completely free. + */ + if (space_map_allocated(msp->ms_sm) == 0) { + int idx = highbit64(msp->ms_size) - 1; + int max_idx = SPACE_MAP_HISTOGRAM_SIZE + shift - 1; + + if (idx < max_idx) { + WEIGHT_SET_COUNT(weight, 1ULL); + WEIGHT_SET_INDEX(weight, idx); + } else { + WEIGHT_SET_COUNT(weight, 1ULL << (idx - max_idx)); + WEIGHT_SET_INDEX(weight, max_idx); + } + WEIGHT_SET_ACTIVE(weight, 0); + ASSERT(!WEIGHT_IS_SPACEBASED(weight)); + + return (weight); + } + + ASSERT3U(msp->ms_sm->sm_dbuf->db_size, ==, sizeof (space_map_phys_t)); + + /* + * If the metaslab is fully allocated then just make the weight 0. + */ + if (space_map_allocated(msp->ms_sm) == msp->ms_size) + return (0); + /* + * If the metaslab is already loaded, then use the range tree to + * determine the weight. Otherwise, we rely on the space map information + * to generate the weight. + */ + if (msp->ms_loaded) { + weight = metaslab_weight_from_range_tree(msp); + } else { + weight = metaslab_weight_from_spacemap(msp); + } + + /* + * If the metaslab was active the last time we calculated its weight + * then keep it active. We want to consume the entire region that + * is associated with this weight. + */ + if (msp->ms_activation_weight != 0 && weight != 0) + WEIGHT_SET_ACTIVE(weight, WEIGHT_GET_ACTIVE(msp->ms_weight)); + return (weight); +} + +/* + * Determine if we should attempt to allocate from this metaslab. If the + * metaslab has a maximum size then we can quickly determine if the desired + * allocation size can be satisfied. Otherwise, if we're using segment-based + * weighting then we can determine the maximum allocation that this metaslab + * can accommodate based on the index encoded in the weight. If we're using + * space-based weights then rely on the entire weight (excluding the weight + * type bit). + */ +boolean_t +metaslab_should_allocate(metaslab_t *msp, uint64_t asize) +{ + boolean_t should_allocate; + + if (msp->ms_max_size != 0) + return (msp->ms_max_size >= asize); + + if (!WEIGHT_IS_SPACEBASED(msp->ms_weight)) { + /* + * The metaslab segment weight indicates segments in the + * range [2^i, 2^(i+1)), where i is the index in the weight. + * Since the asize might be in the middle of the range, we + * should attempt the allocation if asize < 2^(i+1). + */ + should_allocate = (asize < + 1ULL << (WEIGHT_GET_INDEX(msp->ms_weight) + 1)); + } else { + should_allocate = (asize <= + (msp->ms_weight & ~METASLAB_WEIGHT_TYPE)); + } + return (should_allocate); +} + +static uint64_t +metaslab_weight(metaslab_t *msp) +{ + vdev_t *vd = msp->ms_group->mg_vd; + spa_t *spa = vd->vdev_spa; + uint64_t weight; + + ASSERT(MUTEX_HELD(&msp->ms_lock)); + + /* + * This vdev is in the process of being removed so there is nothing + * for us to do here. + */ + if (vd->vdev_removing) { + ASSERT0(space_map_allocated(msp->ms_sm)); + ASSERT0(vd->vdev_ms_shift); + return (0); + } + + metaslab_set_fragmentation(msp); + + /* + * Update the maximum size if the metaslab is loaded. This will + * ensure that we get an accurate maximum size if newly freed space + * has been added back into the free tree. + */ + if (msp->ms_loaded) + msp->ms_max_size = metaslab_block_maxsize(msp); + + /* + * Segment-based weighting requires space map histogram support. + */ + if (zfs_metaslab_segment_weight_enabled && + spa_feature_is_enabled(spa, SPA_FEATURE_SPACEMAP_HISTOGRAM) && + (msp->ms_sm == NULL || msp->ms_sm->sm_dbuf->db_size == + sizeof (space_map_phys_t))) { + weight = metaslab_segment_weight(msp); + } else { + weight = metaslab_space_weight(msp); + } return (weight); } @@ -1625,6 +1888,7 @@ metaslab_activate(metaslab_t *msp, uint6 } } + msp->ms_activation_weight = msp->ms_weight; metaslab_group_sort(msp->ms_group, msp, msp->ms_weight | activation_weight); } @@ -1635,18 +1899,56 @@ metaslab_activate(metaslab_t *msp, uint6 } static void -metaslab_passivate(metaslab_t *msp, uint64_t size) +metaslab_passivate(metaslab_t *msp, uint64_t weight) { + uint64_t size = weight & ~METASLAB_WEIGHT_TYPE; + /* * If size < SPA_MINBLOCKSIZE, then we will not allocate from * this metaslab again. In that case, it had better be empty, * or we would be leaving space on the table. */ - ASSERT(size >= SPA_MINBLOCKSIZE || range_tree_space(msp->ms_tree) == 0); - metaslab_group_sort(msp->ms_group, msp, MIN(msp->ms_weight, size)); + ASSERT(size >= SPA_MINBLOCKSIZE || + range_tree_space(msp->ms_tree) == 0); + ASSERT0(weight & METASLAB_ACTIVE_MASK); + + msp->ms_activation_weight = 0; + metaslab_group_sort(msp->ms_group, msp, weight); ASSERT((msp->ms_weight & METASLAB_ACTIVE_MASK) == 0); } +/* + * Segment-based metaslabs are activated once and remain active until + * we either fail an allocation attempt (similar to space-based metaslabs) + * or have exhausted the free space in zfs_metaslab_switch_threshold + * buckets since the metaslab was activated. This function checks to see + * if we've exhaused the zfs_metaslab_switch_threshold buckets in the + * metaslab and passivates it proactively. This will allow us to select a + * metaslabs with larger contiguous region if any remaining within this + * metaslab group. If we're in sync pass > 1, then we continue using this + * metaslab so that we don't dirty more block and cause more sync passes. + */ +void +metaslab_segment_may_passivate(metaslab_t *msp) +{ + spa_t *spa = msp->ms_group->mg_vd->vdev_spa; + + if (WEIGHT_IS_SPACEBASED(msp->ms_weight) || spa_sync_pass(spa) > 1) + return; + + /* + * Since we are in the middle of a sync pass, the most accurate + * information that is accessible to us is the in-core range tree + * histogram; calculate the new weight based on that information. + */ + uint64_t weight = metaslab_weight_from_range_tree(msp); + int activation_idx = WEIGHT_GET_INDEX(msp->ms_activation_weight); + int current_idx = WEIGHT_GET_INDEX(weight); + + if (current_idx <= activation_idx - zfs_metaslab_switch_threshold) + metaslab_passivate(msp, weight); +} + static void metaslab_preload(void *arg) { @@ -1659,11 +1961,7 @@ metaslab_preload(void *arg) metaslab_load_wait(msp); if (!msp->ms_loaded) (void) metaslab_load(msp); - - /* - * Set the ms_access_txg value so that we don't unload it right away. - */ - msp->ms_access_txg = spa_syncing_txg(spa) + metaslab_unload_delay + 1; + msp->ms_selected_txg = spa_syncing_txg(spa); mutex_exit(&msp->ms_lock); } @@ -1684,10 +1982,7 @@ metaslab_group_preload(metaslab_group_t /* * Load the next potential metaslabs */ - msp = avl_first(t); - while (msp != NULL) { - metaslab_t *msp_next = AVL_NEXT(t, msp); - + for (msp = avl_first(t); msp != NULL; msp = AVL_NEXT(t, msp)) { /* * We preload only the maximum number of metaslabs specified * by metaslab_preload_limit. If a metaslab is being forced @@ -1695,27 +1990,11 @@ metaslab_group_preload(metaslab_group_t * that force condensing happens in the next txg. */ if (++m > metaslab_preload_limit && !msp->ms_condense_wanted) { - msp = msp_next; continue; } - /* - * We must drop the metaslab group lock here to preserve - * lock ordering with the ms_lock (when grabbing both - * the mg_lock and the ms_lock, the ms_lock must be taken - * first). As a result, it is possible that the ordering - * of the metaslabs within the avl tree may change before - * we reacquire the lock. The metaslab cannot be removed from - * the tree while we're in syncing context so it is safe to - * drop the mg_lock here. If the metaslabs are reordered - * nothing will break -- we just may end up loading a - * less than optimal one. - */ - mutex_exit(&mg->mg_lock); VERIFY(taskq_dispatch(mg->mg_taskq, metaslab_preload, msp, TQ_SLEEP) != NULL); - mutex_enter(&mg->mg_lock); - msp = msp_next; } mutex_exit(&mg->mg_lock); } @@ -1864,7 +2143,7 @@ metaslab_condense(metaslab_t *msp, uint6 mutex_enter(&msp->ms_lock); /* - * While we would ideally like to create a space_map representation + * While we would ideally like to create a space map representation * that consists only of allocation records, doing so can be * prohibitively expensive because the in-core free tree can be * large, and therefore computationally expensive to subtract @@ -1927,7 +2206,7 @@ metaslab_sync(metaslab_t *msp, uint64_t * metaslab_sync() is the metaslab's ms_tree. No other thread can * be modifying this txg's alloctree, freetree, freed_tree, or * space_map_phys_t. Therefore, we only hold ms_lock to satify - * space_map ASSERTs. We drop it whenever we call into the DMU, + * space map ASSERTs. We drop it whenever we call into the DMU, * because the DMU can call down to us (e.g. via zio_free()) at * any time. */ @@ -1949,7 +2228,7 @@ metaslab_sync(metaslab_t *msp, uint64_t mutex_enter(&msp->ms_lock); /* - * Note: metaslab_condense() clears the space_map's histogram. + * Note: metaslab_condense() clears the space map's histogram. * Therefore we must verify and remove this histogram before * condensing. */ @@ -1974,16 +2253,38 @@ metaslab_sync(metaslab_t *msp, uint64_t */ space_map_histogram_clear(msp->ms_sm); space_map_histogram_add(msp->ms_sm, msp->ms_tree, tx); - } else { + + /* + * Since we've cleared the histogram we need to add back + * any free space that has already been processed, plus + * any deferred space. This allows the on-disk histogram + * to accurately reflect all free space even if some space + * is not yet available for allocation (i.e. deferred). + */ + space_map_histogram_add(msp->ms_sm, *freed_tree, tx); + /* - * Since the space map is not loaded we simply update the - * exisiting histogram with what was freed in this txg. This - * means that the on-disk histogram may not have an accurate - * view of the free space but it's close enough to allow - * us to make allocation decisions. + * Add back any deferred free space that has not been + * added back into the in-core free tree yet. This will + * ensure that we don't end up with a space map histogram + * that is completely empty unless the metaslab is fully + * allocated. */ - space_map_histogram_add(msp->ms_sm, *freetree, tx); + for (int t = 0; t < TXG_DEFER_SIZE; t++) { + space_map_histogram_add(msp->ms_sm, + msp->ms_defertree[t], tx); + } } + + /* + * Always add the free space from this sync pass to the space + * map histogram. We want to make sure that the on-disk histogram + * accounts for all free space. If the space map is not loaded, + * then we will lose some accuracy but will correct it the next + * time we load the space map. + */ + space_map_histogram_add(msp->ms_sm, *freetree, tx); + metaslab_group_histogram_add(mg, msp); metaslab_group_histogram_verify(mg); metaslab_class_histogram_verify(mg->mg_class); @@ -2002,6 +2303,7 @@ metaslab_sync(metaslab_t *msp, uint64_t range_tree_vacate(alloctree, NULL, NULL); ASSERT0(range_tree_space(msp->ms_alloctree[txg & TXG_MASK])); + ASSERT0(range_tree_space(msp->ms_alloctree[TXG_CLEAN(txg) & TXG_MASK])); ASSERT0(range_tree_space(msp->ms_freetree[txg & TXG_MASK])); mutex_exit(&msp->ms_lock); @@ -2023,9 +2325,11 @@ metaslab_sync_done(metaslab_t *msp, uint { metaslab_group_t *mg = msp->ms_group; vdev_t *vd = mg->mg_vd; + spa_t *spa = vd->vdev_spa; range_tree_t **freed_tree; range_tree_t **defer_tree; int64_t alloc_delta, defer_delta; + boolean_t defer_allowed = B_TRUE; ASSERT(!vd->vdev_ishole); @@ -2060,9 +2364,20 @@ metaslab_sync_done(metaslab_t *msp, uint freed_tree = &msp->ms_freetree[TXG_CLEAN(txg) & TXG_MASK]; defer_tree = &msp->ms_defertree[txg % TXG_DEFER_SIZE]; + uint64_t free_space = metaslab_class_get_space(spa_normal_class(spa)) - + metaslab_class_get_alloc(spa_normal_class(spa)); + if (free_space <= spa_get_slop_space(spa)) { + defer_allowed = B_FALSE; + } + + defer_delta = 0; alloc_delta = space_map_alloc_delta(msp->ms_sm); - defer_delta = range_tree_space(*freed_tree) - - range_tree_space(*defer_tree); + if (defer_allowed) { + defer_delta = range_tree_space(*freed_tree) - + range_tree_space(*defer_tree); + } else { + defer_delta -= range_tree_space(*defer_tree); + } vdev_space_update(vd, alloc_delta + defer_delta, defer_delta, 0); @@ -2083,7 +2398,12 @@ metaslab_sync_done(metaslab_t *msp, uint */ range_tree_vacate(*defer_tree, msp->ms_loaded ? range_tree_add : NULL, msp->ms_tree); - range_tree_swap(freed_tree, defer_tree); + if (defer_allowed) { + range_tree_swap(freed_tree, defer_tree); + } else { + range_tree_vacate(*freed_tree, + msp->ms_loaded ? range_tree_add : NULL, msp->ms_tree); + } space_map_update(msp->ms_sm); @@ -2098,7 +2418,18 @@ metaslab_sync_done(metaslab_t *msp, uint vdev_dirty(vd, VDD_METASLAB, msp, txg + 1); } - if (msp->ms_loaded && msp->ms_access_txg < txg) { + /* + * Calculate the new weights before unloading any metaslabs. + * This will give us the most accurate weighting. + */ + metaslab_group_sort(mg, msp, metaslab_weight(msp)); + + /* + * If the metaslab is loaded and we've not tried to load or allocate + * from it in 'metaslab_unload_delay' txgs, then unload it. + */ + if (msp->ms_loaded && + msp->ms_selected_txg + metaslab_unload_delay < txg) { for (int t = 1; t < TXG_CONCURRENT_STATES; t++) { VERIFY0(range_tree_space( msp->ms_alloctree[(txg + t) & TXG_MASK])); @@ -2108,7 +2439,6 @@ metaslab_sync_done(metaslab_t *msp, uint metaslab_unload(msp); } - metaslab_group_sort(mg, msp, metaslab_weight(msp)); mutex_exit(&msp->ms_lock); } @@ -2143,6 +2473,113 @@ metaslab_distance(metaslab_t *msp, dva_t /* * ========================================================================== + * Metaslab allocation tracing facility + * ========================================================================== + */ +kstat_t *metaslab_trace_ksp; +kstat_named_t metaslab_trace_over_limit; + +void +metaslab_alloc_trace_init(void) +{ + ASSERT(metaslab_alloc_trace_cache == NULL); + metaslab_alloc_trace_cache = kmem_cache_create( + "metaslab_alloc_trace_cache", sizeof (metaslab_alloc_trace_t), + 0, NULL, NULL, NULL, NULL, NULL, 0); + metaslab_trace_ksp = kstat_create("zfs", 0, "metaslab_trace_stats", + "misc", KSTAT_TYPE_NAMED, 1, KSTAT_FLAG_VIRTUAL); + if (metaslab_trace_ksp != NULL) { + metaslab_trace_ksp->ks_data = &metaslab_trace_over_limit; + kstat_named_init(&metaslab_trace_over_limit, + "metaslab_trace_over_limit", KSTAT_DATA_UINT64); + kstat_install(metaslab_trace_ksp); + } +} + +void +metaslab_alloc_trace_fini(void) +{ + if (metaslab_trace_ksp != NULL) { + kstat_delete(metaslab_trace_ksp); + metaslab_trace_ksp = NULL; + } + kmem_cache_destroy(metaslab_alloc_trace_cache); + metaslab_alloc_trace_cache = NULL; +} + +/* + * Add an allocation trace element to the allocation tracing list. + */ +static void +metaslab_trace_add(zio_alloc_list_t *zal, metaslab_group_t *mg, + metaslab_t *msp, uint64_t psize, uint32_t dva_id, uint64_t offset) +{ + if (!metaslab_trace_enabled) + return; + + /* + * When the tracing list reaches its maximum we remove + * the second element in the list before adding a new one. + * By removing the second element we preserve the original + * entry as a clue to what allocations steps have already been + * performed. + */ + if (zal->zal_size == metaslab_trace_max_entries) { + metaslab_alloc_trace_t *mat_next; +#ifdef DEBUG + panic("too many entries in allocation list"); +#endif + atomic_inc_64(&metaslab_trace_over_limit.value.ui64); + zal->zal_size--; + mat_next = list_next(&zal->zal_list, list_head(&zal->zal_list)); + list_remove(&zal->zal_list, mat_next); + kmem_cache_free(metaslab_alloc_trace_cache, mat_next); + } + + metaslab_alloc_trace_t *mat = + kmem_cache_alloc(metaslab_alloc_trace_cache, KM_SLEEP); + list_link_init(&mat->mat_list_node); + mat->mat_mg = mg; + mat->mat_msp = msp; + mat->mat_size = psize; + mat->mat_dva_id = dva_id; + mat->mat_offset = offset; + mat->mat_weight = 0; + + if (msp != NULL) + mat->mat_weight = msp->ms_weight; + + /* + * The list is part of the zio so locking is not required. Only + * a single thread will perform allocations for a given zio. + */ + list_insert_tail(&zal->zal_list, mat); + zal->zal_size++; + + ASSERT3U(zal->zal_size, <=, metaslab_trace_max_entries); +} + +void +metaslab_trace_init(zio_alloc_list_t *zal) +{ + list_create(&zal->zal_list, sizeof (metaslab_alloc_trace_t), + offsetof(metaslab_alloc_trace_t, mat_list_node)); + zal->zal_size = 0; +} + +void +metaslab_trace_fini(zio_alloc_list_t *zal) +{ + metaslab_alloc_trace_t *mat; + + while ((mat = list_remove_head(&zal->zal_list)) != NULL) + kmem_cache_free(metaslab_alloc_trace_cache, mat); + list_destroy(&zal->zal_list); + zal->zal_size = 0; +} + +/* + * ========================================================================== * Metaslab block operations * ========================================================================== */ @@ -2191,13 +2628,48 @@ metaslab_group_alloc_verify(spa_t *spa, } static uint64_t -metaslab_group_alloc(metaslab_group_t *mg, uint64_t asize, - uint64_t txg, uint64_t min_distance, dva_t *dva, int d) +metaslab_block_alloc(metaslab_t *msp, uint64_t size, uint64_t txg) +{ + uint64_t start; + range_tree_t *rt = msp->ms_tree; + metaslab_class_t *mc = msp->ms_group->mg_class; + + VERIFY(!msp->ms_condensing); + + start = mc->mc_ops->msop_alloc(msp, size); + if (start != -1ULL) { *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Wed Mar 15 05:22:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B248FD0A549; Wed, 15 Mar 2017 05:22:41 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (glebi.us [96.95.210.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cell.glebi.us", Issuer "cell.glebi.us" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 99D901309; Wed, 15 Mar 2017 05:22:41 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (localhost [127.0.0.1]) by cell.glebi.us (8.15.2/8.15.2) with ESMTPS id v2F5MdeV004158 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 14 Mar 2017 22:22:40 -0700 (PDT) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebi.us (8.15.2/8.15.2/Submit) id v2F5Mdgc004157; Tue, 14 Mar 2017 22:22:39 -0700 (PDT) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebi.us: glebius set sender to glebius@FreeBSD.org using -f Date: Tue, 14 Mar 2017 22:22:39 -0700 From: Gleb Smirnoff To: Ngie Cooper Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315230 - in head: etc/mtree tests/sys/geom tests/sys/geom/class/eli tests/sys/geom/eli Message-ID: <20170315052239.GC1072@FreeBSD.org> References: <201703140700.v2E70MXc091919@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201703140700.v2E70MXc091919@repo.freebsd.org> User-Agent: Mutt/1.7.2 (2016-11-26) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 05:22:41 -0000 On Tue, Mar 14, 2017 at 07:00:22AM +0000, Ngie Cooper wrote: N> Author: ngie N> Date: Tue Mar 14 07:00:22 2017 N> New Revision: 315230 N> URL: https://svnweb.freebsd.org/changeset/base/315230 N> N> Log: N> Move .../sys/geom/eli/pbkdf2... to .../sys/geom/class/eli/... N> N> This change moves the tests added in r313962 to an existing directory N> structure used by the geli TAP tests. It also, renames the test from N> pbkdf2 to pbkdf2_test . N> N> The changes to ObsoleteFiles.inc are being committed separately as they N> aren't needed for the MFC to ^/stable/11, etc, if the MFC for the tests N> is done all in one commit. N> N> MFC after: 2 weeks N> X-MFC with: r313962, r313972-r313973 N> Reviewed by: allanjude N> Sponsored by: Dell EMC Isilon N> Differential Revision: D9985 This breaks buildworld for a system that doesn't have SYSDIR defined in src.conf, and also doesn't have /usr/src/sys. What happens is that include path is /sys. On some systems this is meaningful, on others not. glebius@morannon:/usr/src/head/tests/sys/geom/class/eli:|>make (cd /usr/src/head/tests/sys/geom/class/eli && DEPENDFILE=.depend.pbkdf2_test NO_SUBDIR=1 make -f /usr/src/head/tests/sys/geom/class/eli/Makefile _RECURSING_PROGS=t PROG=pbkdf2_test ) cc -O2 -pipe -I/sys -g -MD -MF.depend.pbkdf2_test.g_eli_crypto.o -MTg_eli_crypto.o -std=gnu99 -fstack-protector-strong -Qunused-arguments -c /usr/src/head/sys/geom/eli/g_eli_crypto.c -o g_eli_crypto.o In file included from /usr/src/head/sys/geom/eli/g_eli_crypto.c:44: /usr/include/geom/eli/g_eli.h:35:10: fatal error: 'crypto/sha2/sha256.h' file not found #include This also breaks buildworld. -- Totus tuus, Glebius. From owner-svn-src-all@freebsd.org Wed Mar 15 05:31:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3BEDCD0A6FB; Wed, 15 Mar 2017 05:31:04 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 02EA015CA; Wed, 15 Mar 2017 05:31:03 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2F5V34E054562; Wed, 15 Mar 2017 05:31:03 GMT (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F5V3aS054561; Wed, 15 Mar 2017 05:31:03 GMT (envelope-from glebius@FreeBSD.org) Message-Id: <201703150531.v2F5V3aS054561@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: glebius set sender to glebius@FreeBSD.org using -f From: Gleb Smirnoff Date: Wed, 15 Mar 2017 05:31:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315292 - head/tests/sys/geom/class/eli X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 05:31:04 -0000 Author: glebius Date: Wed Mar 15 05:31:02 2017 New Revision: 315292 URL: https://svnweb.freebsd.org/changeset/base/315292 Log: Fix buildworld broken in r315230 when /sys doesn't point into a right source tree. Usage of SYSDIR is apparently wrong here. Discussed with: allanjude Modified: head/tests/sys/geom/class/eli/Makefile Modified: head/tests/sys/geom/class/eli/Makefile ============================================================================== --- head/tests/sys/geom/class/eli/Makefile Wed Mar 15 04:18:40 2017 (r315291) +++ head/tests/sys/geom/class/eli/Makefile Wed Mar 15 05:31:02 2017 (r315292) @@ -44,7 +44,7 @@ ${PACKAGE}FILES+= conf.sh TEST_METADATA.$t+= required_user="root" .endfor -CFLAGS.pbkdf2_test= -I${SYSDIR}/sys +CFLAGS.pbkdf2_test= -I${SRCTOP}/sys SRCS.pbkdf2_test= \ hmac_test.c \ From owner-svn-src-all@freebsd.org Wed Mar 15 05:45:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C986BD0ACDB; Wed, 15 Mar 2017 05:45:20 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x233.google.com (mail-pf0-x233.google.com [IPv6:2607:f8b0:400e:c00::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 9709E1D5F; Wed, 15 Mar 2017 05:45:20 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x233.google.com with SMTP id w189so4167873pfb.0; Tue, 14 Mar 2017 22:45:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=dNZ6hdLr38OwW6r7OPzT1auQahaDr7rA5EgsAgozz7k=; b=Sv/9CMO+u9zzt7Z4dEXH+x0GUHuTu1sn4seBdkzrozElEylbbGrZpizz6NEA3sc0PL wA0idnk0YemOTJ3DaFj+o78vs7SawJiZWWNiKBgKSrYyA1QW6OnaR9OR1+cLQKRuQoP0 D5qdg+RFjHm7Vruiexc6PHNWR+JUcQ6RqEntJst73kC07sBTogurdSK7ai05ueAqcbCE xmWp5mo7g1ba3oo8YGEoWdoF+j6pHyF83hOKPyrCE+OVgwJlG/Ld6AnKY7kuVMAFjZ9o WvC1PeWjWWKRxJAtxdt0MSfpOsCT2pKftrJMqMaV06ApdNvMheotD2W1CyJVt2/qrGH0 y9sQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=dNZ6hdLr38OwW6r7OPzT1auQahaDr7rA5EgsAgozz7k=; b=XVyHvKRlORbxhBYTB+RCvBpLSXGnzzSgpODQ0KYYJwhTpgbQHF5Qyzzeciam1eGNyi Ypi8sh3ShMyNsx3vzkc0VY9WECRVZKD5kTsnyHyhQjbR1pE3006wXm4bqC0cVyhjbFEy nV5SndzGNzkAZ31Eh0BeY/wg3FNdKSRHZnp6v+PRQDof5B7qqwUSSRuqmfPySXSen7sO gKQ0sDVN30WEz1BNuY4xbTprK3kq890AwKEKhlEkV0xisGYE4W6q0BAzvEyM85oZAtBW /4YQyWtFW19uJV6acJUDUV/PplEAYDPg/jasilFCFlVvAUvdmQzlEambczhAUvtqKau3 eTOQ== X-Gm-Message-State: AFeK/H3yuODetQeWzC34lI6biI1qCcto3UvBGYv2Eeqvia72JewS+oi8qpt2rtwYBdxt/A== X-Received: by 10.98.65.211 with SMTP id g80mr1647470pfd.187.1489556719989; Tue, 14 Mar 2017 22:45:19 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id y184sm1353808pfg.86.2017.03.14.22.45.19 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 14 Mar 2017 22:45:19 -0700 (PDT) Subject: Re: svn commit: r315292 - head/tests/sys/geom/class/eli Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_4026DE0B-6FFF-4D0C-A039-DCC4EEAFA2E4"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703150531.v2F5V3aS054561@repo.freebsd.org> Date: Tue, 14 Mar 2017 22:45:17 -0700 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <8F707A90-15BE-4AF0-932E-3A6BC5ED94B0@gmail.com> References: <201703150531.v2F5V3aS054561@repo.freebsd.org> To: Gleb Smirnoff X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 05:45:20 -0000 --Apple-Mail=_4026DE0B-6FFF-4D0C-A039-DCC4EEAFA2E4 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii > On Mar 14, 2017, at 22:31, Gleb Smirnoff wrote: > > Author: glebius > Date: Wed Mar 15 05:31:02 2017 > New Revision: 315292 > URL: https://svnweb.freebsd.org/changeset/base/315292 > > Log: > Fix buildworld broken in r315230 when /sys doesn't point into a right > source tree. Usage of SYSDIR is apparently wrong here. > > Discussed with: allanjude Apologies and thank you for fixing that obvious mistake. -Ngie --Apple-Mail=_4026DE0B-6FFF-4D0C-A039-DCC4EEAFA2E4 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyNTuAAoJEPWDqSZpMIYV3WYQAJyWsmzLF6mVWLWF8pY0Gp1a n+/BK1mG7Hv1rlJRomWdp88uhDqMwJcdyVSfPKE97CtC8DhzLMmxEJJDotxytiMA TSnLbTa3mmu1Z6m1JfGtjEIidtbMls6h93ZtepIY3vzS4LcUmnWho788fWM5ngh8 S7CaQ3LTi+yy+gKGbLUgHsJ5gmyNDVzlfv5NH0J577SGY5Dp3N4LJfBiPWwy8IHV MXNaeGRYgaZpDTwVKJdJFGrlSIGJwGSgFJNPGsvwAkksGcJX5NNCR+H02zLtXkvt fi8XypRcmhPxJ+cVtMICIzQt3RktX4r9D3sUFkwx9YRiL9JmwsJVOkvmD5mRBdjQ fkmMcKryE+TyzQP8lNVWlX/qysVaPoseP0ucq+4DmaPMA0tIGj9cg3kBxV4KlCVe oUa4x6hem/kezgmiI1h0LvSN1LSXc5kGV5xCdqEWGP35M2EmBZt306aFS6uxz6CI qejTI9iVlLtx23f7MnoenRF2HVzj5PdZ/vgjHfSQws7pitvapTjNCst97TdpkjuY V9IDQiJCi+WsrJn6KQl49g89gP5T6RapRK/JklgnMr3x9JtkopOdbGFmyQdenGr8 CqOxCSEt1GBqRE/IDfqoDjcxxfB/58GBA9FNJclYz1M8ZBkYS/U7rMpCSXyvzPwk 2U60mEIcb26+6GC/j/gU =FHu8 -----END PGP SIGNATURE----- --Apple-Mail=_4026DE0B-6FFF-4D0C-A039-DCC4EEAFA2E4-- From owner-svn-src-all@freebsd.org Wed Mar 15 06:02:15 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7BE3FD0B080; Wed, 15 Mar 2017 06:02:15 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4149E15B0; Wed, 15 Mar 2017 06:02:15 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x244.google.com with SMTP id o126so1056738pfb.1; Tue, 14 Mar 2017 23:02:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=3q+9UFcZwlWreIIv5hweJ7adRFNQvisrV6J4G4IVGQA=; b=jfbZHqz3iTiwXOvlLPjfBfkFxrj3gm9o8gOokCtX57Ic0d9WDtqrmeksKACGNITKgv 9sV11sDoFeCipz+iet11AJVyKhodDsQWc1BIUVG8walP31pLN/Jl5HWK4dsRzmbwpRzF Si/ur+OgpYFB/0CO4wH18Ik2+6yw74HkLBKQV8ReDKFce2oAYy6ObfUClzf0R9N9q5Y+ EvGKAurOtShBQ7yJTenTDBcxyJmUsg8AnuoLvISAIJxOiVFtDhY5r8cah6C7eX3wLEyT ZT5z/0AZj7H83maOiEED5luOzgkoq+mCkODjIdYkpkzYZTW5uliu2rG2EMvElB+CudcZ 9LbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=3q+9UFcZwlWreIIv5hweJ7adRFNQvisrV6J4G4IVGQA=; b=XiWPlCfmFBfDmQaaldEzcrZ07vNkuP0x5puk20zm2IK5cR5VQIwS184UMSgCLaWZvc RGAdFy80HPkvlspDYCe5nnCgQ9m4Ec4ljEqPgKjsCc2RnTQg6MoCsostPN8CoRjm0p75 L8NK7af5FQknn95HyA8HWSBLB8xtiMjhgeJbTkPolL5gxPWJ79LLOene11mr/HMXBq77 UoiSLIVJCQ7OFCsXiRmbyZzKmMkJiVxfPaeX3epvNdGzz3V/PdIYP2D1D467vhWDuuXH p5T/VEGmwYM+B+90qf2KC8Eo14hSZiD6OcA9lRkt9JPHFuJpHtEgk4wWZjyhOgOH795G n1gw== X-Gm-Message-State: AFeK/H0UAO6kr2GSMiz5l0DMiZLwSJwWix4EjWZutmZ+hxVo3GoFjS5LGpB4D8xLBh/bJA== X-Received: by 10.99.102.135 with SMTP id a129mr1691277pgc.220.1489557734350; Tue, 14 Mar 2017 23:02:14 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id j62sm1474791pgc.54.2017.03.14.23.02.13 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 14 Mar 2017 23:02:13 -0700 (PDT) Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_BACBD6CE-CA76-4C76-904B-1D81BF97B362"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703110501.v2B51UJQ045535@repo.freebsd.org> Date: Tue, 14 Mar 2017 23:02:12 -0700 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: <3A41B310-CDCE-4CA5-9155-3621E55AA8CF@gmail.com> References: <201703110501.v2B51UJQ045535@repo.freebsd.org> To: Baptiste Daroussin X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 06:02:15 -0000 --Apple-Mail=_BACBD6CE-CA76-4C76-904B-1D81BF97B362 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On Mar 10, 2017, at 21:01, Baptiste Daroussin = wrote: >=20 > Author: bapt > Date: Sat Mar 11 05:01:29 2017 > New Revision: 315051 > URL: https://svnweb.freebsd.org/changeset/base/315051 >=20 > Log: > Import diff from OpenBSD and remove GNU diff >=20 > Some of the modifications from the previous summer of code has been = integrated > Modification for compatibility with GNU diff output has been added >=20 > Main difference with OpenBSD: > Implement multiple GNU diff options: > * --ignore-file-name-case > * --no-ignore-file-name-case > * --normal > * --tabsize > * --strip-trailing-cr > Make diff -p compatible with GNU diff > Implement diff -l > Make diff -r compatible with GNU diff >=20 > Capsicumize diffing 2 regular files > Add a simple test suite >=20 > Approved by: AsiaBSDcon devsummit > Obtained from: OpenBSD, GSoC > Relnotes: yes etcupdate(8) is broken after this commit, along with commands = that implement --*group-format=3D: = https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D217795 . Cheers, -Ngie --Apple-Mail=_BACBD6CE-CA76-4C76-904B-1D81BF97B362 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyNjkAAoJEPWDqSZpMIYVIvsP/0S5whGKR8nFexrxIKyrQeS8 TNVuMPU0OGNbMx/Dky27mIfJBU7E73t4gH1GrDxgpDxOvt3lC9AzzKPTIrbZxf8m rqFaLWv3HQAHHc3t9PwQoLu8vWEfOCaU+okOfBg1iucU5Do7O8/+qSVRbfHgFdw9 16pI5V++E22//paY/0/FDdvGTzvcDQv8x0L0Jobp+9Q8WKyFddJYl+0EXuC76dAr 3EK3Y2oBryz8n9crU3OVu1nFwoiXO/HAFnQSYbaBIN4qkA0Sdwte0H/6Bj/EzpfP zOGXLp2l6CxARjDE0XkTiIwqAC3CAlzVAdU8YF+sBEjtIb1lauMbncVH7gGnq+cg sxB3w0vWx6pHTt8dvKT/JRYzraGwYTvpqofCJJNNYl/UrqkyEHmqC8WeB8nS4Uxo d4DHIZx8MDKvtuYGNG5zbqEaeYMJyW6NSBH+sV/0hIthts2AnjfXcjUOZme7d2Eh 2TgzqO4AIyfWr3eibEnFCZyYRTwWz31xZO8/JfIJo+SR5ZKchFshCqmNRUYmvBSP I0At0WHRsYCTLyeXgT6jn6FeeP3kzNz8w4v+G3Vt8od745H7YEWhKCRwjhECiZnQ EuRC8kgkzJ24kYYAV95u2ypYePlq7dx6ehZVpJvCuRvD/UBJ5GQyNYAzOqcdm50s aZeQ7jQO2oxy/9pZ3TVa =TFRz -----END PGP SIGNATURE----- --Apple-Mail=_BACBD6CE-CA76-4C76-904B-1D81BF97B362-- From owner-svn-src-all@freebsd.org Wed Mar 15 06:18:15 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3757D0B5CA; Wed, 15 Mar 2017 06:18:15 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9333B1D0E; Wed, 15 Mar 2017 06:18:15 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2F6IEck073724; Wed, 15 Mar 2017 06:18:14 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F6IExf073723; Wed, 15 Mar 2017 06:18:14 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703150618.v2F6IExf073723@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Wed, 15 Mar 2017 06:18:14 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315293 - head/usr.bin/diff/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 06:18:15 -0000 Author: ngie Date: Wed Mar 15 06:18:14 2017 New Revision: 315293 URL: https://svnweb.freebsd.org/changeset/base/315293 Log: Integrate contrib/netbsd-tests/usr.bin/diff/t_diff.sh in as .../usr.bin/diff/diff_test Some minor adjustment needed to be done for :same as it currently has the test script hardcoded into the test, instead of using an idiom like $(dirname $0) MFC after: 1 week Sponsored by: Dell EMC Isilon Modified: head/usr.bin/diff/tests/Makefile Modified: head/usr.bin/diff/tests/Makefile ============================================================================== --- head/usr.bin/diff/tests/Makefile Wed Mar 15 05:31:02 2017 (r315292) +++ head/usr.bin/diff/tests/Makefile Wed Mar 15 06:18:14 2017 (r315293) @@ -21,4 +21,14 @@ ${PACKAGE}FILES+= \ unified_c9999.out \ unified_9999.out +NETBSD_ATF_TESTS_SH+= diff_test + +${PACKAGE}FILES+= \ + d_mallocv1.in \ + d_mallocv2.in + +ATF_TESTS_SH_SED_diff_test+= -e 's,t_diff,diff_test,g' + +.include + .include From owner-svn-src-all@freebsd.org Wed Mar 15 06:26:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9F315D0B8AB; Wed, 15 Mar 2017 06:26:53 +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 7D08011FA; Wed, 15 Mar 2017 06:26:53 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: by freefall.freebsd.org (Postfix, from userid 1235) id C0B387FB1; Wed, 15 Mar 2017 06:26:52 +0000 (UTC) Date: Wed, 15 Mar 2017 07:26:52 +0100 From: Baptiste Daroussin To: "Ngie Cooper (yaneurabeya)" Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315051 - in head: . gnu/usr.bin gnu/usr.bin/diff usr.bin usr.bin/diff usr.bin/diff/tests Message-ID: <20170315062652.5qmvzu4jcqr3637n@ivaldir.net> References: <201703110501.v2B51UJQ045535@repo.freebsd.org> <3A41B310-CDCE-4CA5-9155-3621E55AA8CF@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="2rpogljjh4xumtgz" Content-Disposition: inline In-Reply-To: <3A41B310-CDCE-4CA5-9155-3621E55AA8CF@gmail.com> User-Agent: NeoMutt/20170225 (1.8.0) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 06:26:53 -0000 --2rpogljjh4xumtgz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Mar 14, 2017 at 11:02:12PM -0700, Ngie Cooper (yaneurabeya) wrote: >=20 > > On Mar 10, 2017, at 21:01, Baptiste Daroussin wrote: > >=20 > > Author: bapt > > Date: Sat Mar 11 05:01:29 2017 > > New Revision: 315051 > > URL: https://svnweb.freebsd.org/changeset/base/315051 > >=20 > > Log: > > Import diff from OpenBSD and remove GNU diff > >=20 > > Some of the modifications from the previous summer of code has been in= tegrated > > Modification for compatibility with GNU diff output has been added > >=20 > > Main difference with OpenBSD: > > Implement multiple GNU diff options: > > * --ignore-file-name-case > > * --no-ignore-file-name-case > > * --normal > > * --tabsize > > * --strip-trailing-cr > > Make diff -p compatible with GNU diff > > Implement diff -l > > Make diff -r compatible with GNU diff > >=20 > > Capsicumize diffing 2 regular files > > Add a simple test suite > >=20 > > Approved by: AsiaBSDcon devsummit > > Obtained from: OpenBSD, GSoC > > Relnotes: yes >=20 > etcupdate(8) is broken after this commit, along with commands that imple= ment --*group-format=3D: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id= =3D217795 . I ran the etcupdate testsuite to validate and it was ok I will have a look Best regards, Bapt --2rpogljjh4xumtgz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEgOTj3suS2urGXVU3Y4mL3PG3PloFAljI3qwACgkQY4mL3PG3 PlprNg//SJzPYSPi4sORA+nTK8JEauBTOba1kjEke3KwzAA/OW5hDKC/JvlXyBsZ 4HQrmMujewXR3phqf5sss6TJRIE6TXv/LwJTIpPQPdvnlbehGrAMZleoYoxCUzJs 4lqTC9S8KhrCQAow01f9hYQcRiqcybRMfXHcGPj9LhoAcqZRD+OUHWB7rtJmGlGT jni15rgyehb0+KAEngflIhCZHFqSeoNzNdlzdMwzog1gEkq9MfVU8yJMCoQoqGcv msUAwoTccJjTW/m6sWRA6eeqb6QMbhBQfT1iNrjQCPHgGKi+TGceJxMIcVT8FuTd 81+EXFAogPYNAmJwgNFgovdQ4fimMQgd5GMLfh7U+aSiJ/tgu8gF9rpS20ynNN1O tm6DR0D0NsQ8FiO2R97hXtLfH6WP7id1gBUi20vluJalwtl6Yi3A87BhS+oDpgV6 wykfu7FZDodztNa1D5LqPhMDk2sJGrd0FWf8w7ayKuFPaoORCB4kYqfJ0igYaoQT cLG1RONgFSMuTwOvZ1bs37F+yclizEuhHfARJaIhXyRlk9HfBH6nxkBeKy+FVZAh 0uYbWuKJHzBYXqNb/P8dCEAijXBGZmn9FbsM3+G/zZpCXuzJ3m+vN8K46h179i2F HeYEskrk26AbAPXKLJum5dWNO4vnrFEGDKM+sbcwbqksj+1dibo= =Qwj6 -----END PGP SIGNATURE----- --2rpogljjh4xumtgz-- From owner-svn-src-all@freebsd.org Wed Mar 15 09:31:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 572DED0D3DE; Wed, 15 Mar 2017 09:31:59 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1C1C01ED9; Wed, 15 Mar 2017 09:31:59 +0000 (UTC) (envelope-from kevlo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2F9VwN8055129; Wed, 15 Mar 2017 09:31:58 GMT (envelope-from kevlo@FreeBSD.org) Received: (from kevlo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2F9Vw1X055128; Wed, 15 Mar 2017 09:31:58 GMT (envelope-from kevlo@FreeBSD.org) Message-Id: <201703150931.v2F9Vw1X055128@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kevlo set sender to kevlo@FreeBSD.org using -f From: Kevin Lo Date: Wed, 15 Mar 2017 09:31:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315294 - head/sys/dev/wi X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 09:31:59 -0000 Author: kevlo Date: Wed Mar 15 09:31:58 2017 New Revision: 315294 URL: https://svnweb.freebsd.org/changeset/base/315294 Log: Fix unreachable code in wi_pci_resume(). PR: 217784 Submitted by: Svyatoslav Found by: PVS-Studio Modified: head/sys/dev/wi/if_wi_pci.c Modified: head/sys/dev/wi/if_wi_pci.c ============================================================================== --- head/sys/dev/wi/if_wi_pci.c Wed Mar 15 06:18:14 2017 (r315293) +++ head/sys/dev/wi/if_wi_pci.c Wed Mar 15 09:31:58 2017 (r315294) @@ -254,8 +254,8 @@ wi_pci_resume(device_t dev) WI_LOCK(sc); if (sc->wi_bus_type != WI_BUS_PCI_NATIVE) { - return (0); WI_UNLOCK(sc); + return (0); } if (ic->ic_nrunning > 0) wi_init(sc); From owner-svn-src-all@freebsd.org Wed Mar 15 10:33:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A1AD8D0D773; Wed, 15 Mar 2017 10:33:45 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6ED772AA; Wed, 15 Mar 2017 10:33:45 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FAXiVW079761; Wed, 15 Mar 2017 10:33:44 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FAXi1p079760; Wed, 15 Mar 2017 10:33:44 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703151033.v2FAXi1p079760@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Wed, 15 Mar 2017 10:33:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315298 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 10:33:45 -0000 Author: mav Date: Wed Mar 15 10:33:44 2017 New Revision: 315298 URL: https://svnweb.freebsd.org/changeset/base/315298 Log: Fix ancient bug from r84597, which broke 23xx after r315234. MFC after: 13 days Modified: head/sys/dev/isp/isp_pci.c Modified: head/sys/dev/isp/isp_pci.c ============================================================================== --- head/sys/dev/isp/isp_pci.c Wed Mar 15 10:31:32 2017 (r315297) +++ head/sys/dev/isp/isp_pci.c Wed Mar 15 10:33:44 2017 (r315298) @@ -1123,7 +1123,7 @@ isp_pci_rd_isr_2300(ispsoftc_t *isp, uin { uint32_t hccr, r2hisr; - if (!(BXR2(isp, IspVirt2Off(isp, BIU_ISR) & BIU2100_ISR_RISC_INT))) { + if ((BXR2(isp, IspVirt2Off(isp, BIU_ISR)) & BIU2100_ISR_RISC_INT) == 0) { *isrp = 0; return (0); } From owner-svn-src-all@freebsd.org Wed Mar 15 10:51:02 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 45688D0DC3E; Wed, 15 Mar 2017 10:51:02 +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 1488FF39; Wed, 15 Mar 2017 10:51:02 +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 v2FAp1NT087035; Wed, 15 Mar 2017 10:51:01 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FAp1he087034; Wed, 15 Mar 2017 10:51:01 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703151051.v2FAp1he087034@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 15 Mar 2017 10:51:01 +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: r315301 - stable/11/sys/compat/ia32 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 10:51:02 -0000 Author: kib Date: Wed Mar 15 10:51:00 2017 New Revision: 315301 URL: https://svnweb.freebsd.org/changeset/base/315301 Log: MFC r307688: With the removal of IA64, the only arch which uses ia32 compat is amd64. Modified: stable/11/sys/compat/ia32/ia32_sysvec.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/ia32/ia32_sysvec.c ============================================================================== --- stable/11/sys/compat/ia32/ia32_sysvec.c Wed Mar 15 10:40:36 2017 (r315300) +++ stable/11/sys/compat/ia32/ia32_sysvec.c Wed Mar 15 10:51:00 2017 (r315301) @@ -120,13 +120,11 @@ struct sysentvec ia32_freebsd_sysvec = { .sv_setregs = ia32_setregs, .sv_fixlimit = ia32_fixlimit, .sv_maxssiz = &ia32_maxssiz, - .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32 | + .sv_flags = #ifdef __amd64__ - SV_SHP | SV_TIMEKEEP -#else - 0 + SV_SHP | SV_TIMEKEEP | #endif - , + SV_ABI_FREEBSD | SV_IA32 | SV_ILP32, .sv_set_syscall_retval = ia32_set_syscall_retval, .sv_fetch_syscall_args = ia32_fetch_syscall_args, .sv_syscallnames = freebsd32_syscallnames, From owner-svn-src-all@freebsd.org Wed Mar 15 10:53:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 91A65D0DE29; Wed, 15 Mar 2017 10:53:41 +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 60E3712EC; Wed, 15 Mar 2017 10:53:41 +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 v2FAresi087907; Wed, 15 Mar 2017 10:53:40 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FArenD087906; Wed, 15 Mar 2017 10:53:40 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703151053.v2FArenD087906@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 15 Mar 2017 10:53:40 +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: r315302 - stable/11/sys/compat/ia32 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 10:53:41 -0000 Author: kib Date: Wed Mar 15 10:53:40 2017 New Revision: 315302 URL: https://svnweb.freebsd.org/changeset/base/315302 Log: MFC r314489: With the removal of IA64, the only arch which uses ia32 compat is amd64. Modified: stable/11/sys/compat/ia32/ia32_sysvec.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/ia32/ia32_sysvec.c ============================================================================== --- stable/11/sys/compat/ia32/ia32_sysvec.c Wed Mar 15 10:51:00 2017 (r315301) +++ stable/11/sys/compat/ia32/ia32_sysvec.c Wed Mar 15 10:53:40 2017 (r315302) @@ -120,11 +120,8 @@ struct sysentvec ia32_freebsd_sysvec = { .sv_setregs = ia32_setregs, .sv_fixlimit = ia32_fixlimit, .sv_maxssiz = &ia32_maxssiz, - .sv_flags = -#ifdef __amd64__ - SV_SHP | SV_TIMEKEEP | -#endif - SV_ABI_FREEBSD | SV_IA32 | SV_ILP32, + .sv_flags = SV_ABI_FREEBSD | SV_IA32 | SV_ILP32 | + SV_SHP | SV_TIMEKEEP, .sv_set_syscall_retval = ia32_set_syscall_retval, .sv_fetch_syscall_args = ia32_fetch_syscall_args, .sv_syscallnames = freebsd32_syscallnames, From owner-svn-src-all@freebsd.org Wed Mar 15 11:16:28 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5328FD0D60F; Wed, 15 Mar 2017 11:16:28 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 068831FA2; Wed, 15 Mar 2017 11:16:27 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FBGRqf096364; Wed, 15 Mar 2017 11:16:27 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FBGRKF096363; Wed, 15 Mar 2017 11:16:27 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703151116.v2FBGRKF096363@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Wed, 15 Mar 2017 11:16:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315303 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 11:16:28 -0000 Author: mav Date: Wed Mar 15 11:16:26 2017 New Revision: 315303 URL: https://svnweb.freebsd.org/changeset/base/315303 Log: Fix panic when SIM dereferenced before allocation. MFC after: 2 weeks Modified: head/sys/dev/isp/isp_freebsd.c Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Wed Mar 15 10:53:40 2017 (r315302) +++ head/sys/dev/isp/isp_freebsd.c Wed Mar 15 11:16:26 2017 (r315303) @@ -362,39 +362,40 @@ isp_detach(ispsoftc_t *isp) static void isp_freeze_loopdown(ispsoftc_t *isp, int chan) { - if (IS_FC(isp)) { - struct isp_fc *fc = ISP_FC_PC(isp, chan); - if (fc->simqfrozen == 0) { - isp_prt(isp, ISP_LOGDEBUG0, - "Chan %d Freeze simq (loopdown)", chan); - fc->simqfrozen = SIMQFRZ_LOOPDOWN; - xpt_hold_boot(); - xpt_freeze_simq(fc->sim, 1); - } else { - isp_prt(isp, ISP_LOGDEBUG0, - "Chan %d Mark simq frozen (loopdown)", chan); - fc->simqfrozen |= SIMQFRZ_LOOPDOWN; - } + struct isp_fc *fc = ISP_FC_PC(isp, chan); + + if (fc->sim == NULL) + return; + if (fc->simqfrozen == 0) { + isp_prt(isp, ISP_LOGDEBUG0, + "Chan %d Freeze simq (loopdown)", chan); + fc->simqfrozen = SIMQFRZ_LOOPDOWN; + xpt_hold_boot(); + xpt_freeze_simq(fc->sim, 1); + } else { + isp_prt(isp, ISP_LOGDEBUG0, + "Chan %d Mark simq frozen (loopdown)", chan); + fc->simqfrozen |= SIMQFRZ_LOOPDOWN; } } static void isp_unfreeze_loopdown(ispsoftc_t *isp, int chan) { - if (IS_FC(isp)) { - struct isp_fc *fc = ISP_FC_PC(isp, chan); - int wasfrozen = fc->simqfrozen & SIMQFRZ_LOOPDOWN; - fc->simqfrozen &= ~SIMQFRZ_LOOPDOWN; - if (wasfrozen && fc->simqfrozen == 0) { - isp_prt(isp, ISP_LOGDEBUG0, - "Chan %d Release simq", chan); - xpt_release_simq(fc->sim, 1); - xpt_release_boot(); - } + struct isp_fc *fc = ISP_FC_PC(isp, chan); + + if (fc->sim == NULL) + return; + int wasfrozen = fc->simqfrozen & SIMQFRZ_LOOPDOWN; + fc->simqfrozen &= ~SIMQFRZ_LOOPDOWN; + if (wasfrozen && fc->simqfrozen == 0) { + isp_prt(isp, ISP_LOGDEBUG0, + "Chan %d Release simq", chan); + xpt_release_simq(fc->sim, 1); + xpt_release_boot(); } } - static int ispioctl(struct cdev *dev, u_long c, caddr_t addr, int flags, struct thread *td) { From owner-svn-src-all@freebsd.org Wed Mar 15 12:52:32 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3D739D0C57B; Wed, 15 Mar 2017 12:52:32 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (turbocat.net [88.99.82.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 00E6611CE; Wed, 15 Mar 2017 12:52:31 +0000 (UTC) (envelope-from hps@selasky.org) Received: from hps2016.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 5AA7F1FE025; Wed, 15 Mar 2017 13:51:37 +0100 (CET) Subject: Re: svn commit: r310232 - head/sys/dev/mlx4/mlx4_ib To: Dimitry Andric , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, Meny Yossefi References: <201612181521.uBIFLcB3030383@repo.freebsd.org> From: Hans Petter Selasky Message-ID: <9290641f-00e0-4091-e641-448d2d0d24d6@selasky.org> Date: Wed, 15 Mar 2017 13:51:33 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <201612181521.uBIFLcB3030383@repo.freebsd.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 12:52:32 -0000 Hi, Can you MFC this patch to 11-stable and 10-stable. The directory layout is a bit different, so you'll need to manually apply the patch to sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c after merging the patch and resolving the non-existing path. --HPS On 12/18/16 16:21, Dimitry Andric wrote: > Author: dim > Date: Sun Dec 18 15:21:38 2016 > New Revision: 310232 > URL: https://svnweb.freebsd.org/changeset/base/310232 > > Log: > After r310171, the kernel version of sscanf() has format string checking > enabled. This results in a -Werror warning in mlx4ib: > > sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c:90:22: error: format specifies type 'unsigned long long *' but the argument has type 'u64 *' (aka 'unsigned long *') [-Werror,-Wformat] > sscanf(buf, "%llx", &sysadmin_ag_val); > ~~~~ ^~~~~~~~~~~~~~~~ > > Change sysadmin_ag_val to unsigned long long to avoid the warning. > > Reviewed by: hselasky > MFC after: 3 days > Differential Revision: https://reviews.freebsd.org/D8831 > > Modified: > head/sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c > > Modified: head/sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c > ============================================================================== > --- head/sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c Sun Dec 18 15:10:08 2016 (r310231) > +++ head/sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c Sun Dec 18 15:21:38 2016 (r310232) > @@ -79,7 +79,7 @@ static ssize_t store_admin_alias_guid(st > container_of(attr, struct mlx4_ib_iov_sysfs_attr, dentry); > struct mlx4_ib_iov_port *port = mlx4_ib_iov_dentry->ctx; > struct mlx4_ib_dev *mdev = port->dev; > - u64 sysadmin_ag_val; > + unsigned long long sysadmin_ag_val; > > record_num = mlx4_ib_iov_dentry->entry_num / 8; > guid_index_in_rec = mlx4_ib_iov_dentry->entry_num % 8; > > From owner-svn-src-all@freebsd.org Wed Mar 15 13:06:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B739ED0C962; Wed, 15 Mar 2017 13:06:47 +0000 (UTC) (envelope-from alc@rice.edu) Received: from pp2.rice.edu (proofpoint2.mail.rice.edu [128.42.201.101]) (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 966F41BE6; Wed, 15 Mar 2017 13:06:46 +0000 (UTC) (envelope-from alc@rice.edu) Received: from pps.filterd (pp2.rice.edu [127.0.0.1]) by pp2.rice.edu (8.16.0.17/8.16.0.17) with SMTP id v2FA1wlF032162; Wed, 15 Mar 2017 08:06:39 -0500 Received: from mh2.mail.rice.edu (mh2.mail.rice.edu [128.42.201.21]) by pp2.rice.edu with ESMTP id 296nkjgawa-1; Wed, 15 Mar 2017 08:06:39 -0500 X-Virus-Scanned: by amavis-2.7.0 at mh2.mail.rice.edu, auth channel Received: from 108-254-203-201.lightspeed.hstntx.sbcglobal.net (108-254-203-201.lightspeed.hstntx.sbcglobal.net [108.254.203.201]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) (Authenticated sender: alc) by mh2.mail.rice.edu (Postfix) with ESMTPSA id 2827C500093; Wed, 15 Mar 2017 08:06:39 -0500 (CDT) Subject: Re: svn commit: r315272 - in head: lib/libc/sys sys/sys sys/vm To: Xin LI , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201703141710.v2EHAgxB047599@repo.freebsd.org> From: Alan Cox Message-ID: <1a83c3e4-e46f-440f-12a4-9120406a3f74@rice.edu> Date: Wed, 15 Mar 2017 08:06:38 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: <201703141710.v2EHAgxB047599@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=10 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1611190142 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 13:06:47 -0000 On 03/14/2017 12:10, Xin LI wrote: > Author: delphij > Date: Tue Mar 14 17:10:42 2017 > New Revision: 315272 > URL: https://svnweb.freebsd.org/changeset/base/315272 > > Log: > Implement INHERIT_ZERO for minherit(2). > =20 > INHERIT_ZERO is an OpenBSD feature. > =20 > When a page is marked as such, it would be zeroed > upon fork(). > =20 > This would be used in new arc4random(3) functions. > =20 > PR: 182610 > Reviewed by: kib (earlier version) > MFC after: 1 month > Differential Revision: https://reviews.freebsd.org/D427 > > Modified: > head/lib/libc/sys/minherit.2 > head/sys/sys/mman.h > head/sys/vm/vm.h > head/sys/vm/vm_map.c > > Modified: head/lib/libc/sys/minherit.2 > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/lib/libc/sys/minherit.2 Tue Mar 14 16:40:18 2017 (r315271) > +++ head/lib/libc/sys/minherit.2 Tue Mar 14 17:10:42 2017 (r315272) > @@ -29,7 +29,7 @@ > .\" > .\" @(#)minherit.2 8.1 (Berkeley) 6/9/93 > .\" > -.Dd October 30, 2007 > +.Dd March 15, 2017 > .Dt MINHERIT 2 > .Os > .Sh NAME > @@ -91,6 +91,11 @@ it will no longer be shared in the paren > after the parent forks and there is no way to get the previous > shared-backing-store mapping without unmapping and remapping the addre= ss > space in the parent. > +.It Dv INHERIT_ZERO > +This option causes the address space in question to be mapped as new > +anonymous pages, > +which would be initialized to all zero bytes, > +in the child process. > .El > .Sh RETURN VALUES > .Rv -std minherit > @@ -130,6 +135,13 @@ system call first appeared in > .Ox > and then in > .Fx 2.2 . > +.Pp > +The > +.Dv INHERIT_ZERO > +support first appeared in > +.Ox 5.6 > +and then in > +.Fx 12.0 . > .Sh BUGS > Once you set inheritance to > .Dv MAP_PRIVATE > > Modified: head/sys/sys/mman.h > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/sys/mman.h Tue Mar 14 16:40:18 2017 (r315271) > +++ head/sys/sys/mman.h Tue Mar 14 17:10:42 2017 (r315272) > @@ -43,6 +43,7 @@ > #define INHERIT_SHARE 0 > #define INHERIT_COPY 1 > #define INHERIT_NONE 2 > +#define INHERIT_ZERO 3 > #endif > =20 > /* > > Modified: head/sys/vm/vm.h > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/vm/vm.h Tue Mar 14 16:40:18 2017 (r315271) > +++ head/sys/vm/vm.h Tue Mar 14 17:10:42 2017 (r315272) > @@ -68,6 +68,7 @@ typedef char vm_inherit_t; /* inheritanc > #define VM_INHERIT_SHARE ((vm_inherit_t) 0) > #define VM_INHERIT_COPY ((vm_inherit_t) 1) > #define VM_INHERIT_NONE ((vm_inherit_t) 2) > +#define VM_INHERIT_ZERO ((vm_inherit_t) 3) > #define VM_INHERIT_DEFAULT VM_INHERIT_COPY > =20 > typedef u_char vm_prot_t; /* protection codes */ > > Modified: head/sys/vm/vm_map.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/sys/vm/vm_map.c Tue Mar 14 16:40:18 2017 (r315271) > +++ head/sys/vm/vm_map.c Tue Mar 14 17:10:42 2017 (r315272) > @@ -2285,6 +2285,7 @@ vm_map_inherit(vm_map_t map, vm_offset_t > case VM_INHERIT_NONE: > case VM_INHERIT_COPY: > case VM_INHERIT_SHARE: > + case VM_INHERIT_ZERO: > break; > default: > return (KERN_INVALID_ARGUMENT); > @@ -3443,6 +3444,36 @@ vmspace_fork(struct vmspace *vm1, vm_oof > vm_map_copy_entry(old_map, new_map, old_entry, > new_entry, fork_charge); > break; > + > + case VM_INHERIT_ZERO: > + /* > + * Create a new anonymous mapping entry modelled from > + * the old one. > + */ > + new_entry =3D vm_map_entry_create(new_map); > + memset(new_entry, 0, sizeof(*new_entry)); > + > + new_entry->start =3D old_entry->start; > + new_entry->end =3D old_entry->end; > + new_entry->avail_ssize =3D old_entry->avail_ssize; > + new_entry->adj_free =3D old_entry->adj_free; > + new_entry->max_free =3D old_entry->max_free; The previous two fields should not be copied. The values from the old entry are not necessarily correct for the new entry. The correct values are calculated and assigned by the call to vm_map_entry_link() below.=20 So, these two assignments are harmless but also pointless. > + new_entry->eflags =3D old_entry->eflags & > + ~(MAP_ENTRY_USER_WIRED | MAP_ENTRY_IN_TRANSITION | > + MAP_ENTRY_VN_WRITECNT); > + new_entry->protection =3D old_entry->protection; > + new_entry->max_protection =3D old_entry->max_protection; > + new_entry->inheritance =3D VM_INHERIT_ZERO; > + > + vm_map_entry_link(new_map, new_map->header.prev, > + new_entry); > + vmspace_map_entry_forked(vm1, vm2, new_entry); > + > + new_entry->cred =3D curthread->td_ucred; > + crhold(new_entry->cred); > + *fork_charge +=3D (new_entry->end - new_entry->start); > + > + break; > } > old_entry =3D old_entry->next; > } > > From owner-svn-src-all@freebsd.org Wed Mar 15 13:34:53 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 82815D0D6B2; Wed, 15 Mar 2017 13:34:53 +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 4ADFE110E; Wed, 15 Mar 2017 13:34:53 +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 v2FDYqcw057253; Wed, 15 Mar 2017 13:34:52 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FDYqY8057248; Wed, 15 Mar 2017 13:34:52 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703151334.v2FDYqY8057248@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 15 Mar 2017 13:34:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315304 - head/usr.sbin/makefs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 13:34:53 -0000 Author: emaste Date: Wed Mar 15 13:34:51 2017 New Revision: 315304 URL: https://svnweb.freebsd.org/changeset/base/315304 Log: makefs: sync option parsing with NetBSD - add support for parsing different types; not just int - homogenize option parsing - fix single letter parsing - remove duplicated code NetBSD revisions: cd9660.c 1.36 1.37 1.38 1.41 1.42 1.43 ffs.c 1.50 1.51 1.52 1.53 1.56 1.57 makefs.c 1.36 1.37 1.38 1.39 1.40 1.42 1.43 1.44 1.46 makefs.h 1.28 1.29 1.31 1.32 Obtained from: NetBSD Sponsored by: The FreeBSD Foundation Modified: head/usr.sbin/makefs/cd9660.c head/usr.sbin/makefs/cd9660.h head/usr.sbin/makefs/ffs.c head/usr.sbin/makefs/makefs.c head/usr.sbin/makefs/makefs.h Modified: head/usr.sbin/makefs/cd9660.c ============================================================================== --- head/usr.sbin/makefs/cd9660.c Wed Mar 15 11:16:26 2017 (r315303) +++ head/usr.sbin/makefs/cd9660.c Wed Mar 15 13:34:51 2017 (r315304) @@ -256,7 +256,70 @@ cd9660_prep_opts(fsinfo_t *fsopts) if ((diskStructure = calloc(1, sizeof(*diskStructure))) == NULL) err(EXIT_FAILURE, "%s: calloc", __func__); +#define OPT_STR(letter, name, desc) \ + { letter, name, NULL, OPT_STRBUF, 0, 0, desc } + +#define OPT_NUM(letter, name, field, min, max, desc) \ + { letter, name, &diskStructure->field, \ + sizeof(diskStructure->field) == 8 ? OPT_INT64 : \ + (sizeof(diskStructure->field) == 4 ? OPT_INT32 : \ + (sizeof(diskStructure->field) == 2 ? OPT_INT16 : OPT_INT8)), \ + min, max, desc } + +#define OPT_BOOL(letter, name, field, desc) \ + OPT_NUM(letter, name, field, 0, 1, desc) + + const option_t cd9660_options[] = { + OPT_NUM('l', "isolevel", isoLevel, + 1, 2, "ISO Level"), + OPT_NUM('v', "verbose", verbose_level, + 0, 2, "Turns on verbose output"), + + OPT_BOOL('h', "help", displayHelp, + "Show help message"), + OPT_BOOL('S', "follow-symlinks", follow_sym_links, + "Resolve symlinks in pathnames"), + OPT_BOOL('R', "rockridge", rock_ridge_enabled, + "Enable Rock-Ridge extensions"), + OPT_BOOL('C', "chrp-boot", chrp_boot, + "Enable CHRP boot"), + OPT_BOOL('K', "keep-bad-images", keep_bad_images, + "Keep bad images"), + OPT_BOOL('D', "allow-deep-trees", allow_deep_trees, + "Allow trees more than 8 levels"), + OPT_BOOL('a', "allow-max-name", allow_max_name, + "Allow 37 char filenames (unimplemented)"), + OPT_BOOL('i', "allow-illegal-chars", allow_illegal_chars, + "Allow illegal characters in filenames"), + OPT_BOOL('d', "allow-multidot", allow_multidot, + "Allow multiple periods in filenames"), + OPT_BOOL('o', "omit-trailing-period", omit_trailing_period, + "Omit trailing periods in filenames"), + OPT_BOOL('\0', "allow-lowercase", allow_lowercase, + "Allow lowercase characters in filenames"), + OPT_BOOL('\0', "archimedes", archimedes_enabled, + "Enable Archimedes structure"), + OPT_BOOL('\0', "no-trailing-padding", include_padding_areas, + "Include padding areas"), + + OPT_STR('A', "applicationid", "Application Identifier"), + OPT_STR('P', "publisher", "Publisher Identifier"), + OPT_STR('p', "preparer", "Preparer Identifier"), + OPT_STR('L', "label", "Disk Label"), + OPT_STR('V', "volumeid", "Volume Set Identifier"), + OPT_STR('B', "bootimage", "Boot image parameter"), + OPT_STR('G', "generic-bootimage", "Generic boot image param"), + OPT_STR('\0', "bootimagedir", "Boot image directory"), + OPT_STR('\0', "no-emul-boot", "No boot emulation"), + OPT_STR('\0', "no-boot", "No boot support"), + OPT_STR('\0', "hard-disk-boot", "Boot from hard disk"), + OPT_STR('\0', "boot-load-segment", "Boot load segment"), + + { .name = NULL } + }; + fsopts->fs_specific = diskStructure; + fsopts->fs_options = copy_opts(cd9660_options); cd9660_set_defaults(diskStructure); } @@ -265,6 +328,7 @@ void cd9660_cleanup_opts(fsinfo_t *fsopts) { free(fsopts->fs_specific); + free(fsopts->fs_options); } static int @@ -301,144 +365,106 @@ cd9660_arguments_set_string(const char * int cd9660_parse_opts(const char *option, fsinfo_t *fsopts) { - char *var, *val; - int rv; + int rv, i; iso9660_disk *diskStructure = fsopts->fs_specific; - - /* Set up allowed options - integer options ONLY */ - option_t cd9660_options[] = { - { "l", &diskStructure->isoLevel, 1, 2, "ISO Level" }, - { "isolevel", &diskStructure->isoLevel, 1, 2, "ISO Level" }, - { "verbose", &diskStructure->verbose_level, 0, 2, - "Turns on verbose output" }, - { "v", &diskStructure->verbose_level, 0 , 2, - "Turns on verbose output"}, - { .name = NULL } - }; - - /* - * Todo : finish implementing this, and make a function that - * parses them - */ - /* - string_option_t cd9660_string_options[] = { - { "L", "Label", &diskStructure.primaryDescriptor.volume_id, 1, 32, "Disk Label", ISO_STRING_FILTER_DCHARS }, - { NULL } - } - */ + option_t *cd9660_options = fsopts->fs_options; + char buf[1024]; + const char *name, *desc; assert(option != NULL); if (debug & DEBUG_FS_PARSE_OPTS) printf("cd9660_parse_opts: got `%s'\n", option); - if ((var = strdup(option)) == NULL) - err(1, "allocating memory for copy of option string"); - rv = 1; - - val = strchr(var, '='); - if (val != NULL) - *val++ = '\0'; - - /* First handle options with no parameters */ - if (strcmp(var, "h") == 0) { - diskStructure->displayHelp = 1; - rv = 1; - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "S", "follow-symlinks")) { - /* this is not handled yet */ - diskStructure->follow_sym_links = 1; - rv = 1; - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "L", "label")) { - rv = cd9660_arguments_set_string(val, "Disk Label", 32, 'd', - diskStructure->primaryDescriptor.volume_id); - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "A", "applicationid")) { - rv = cd9660_arguments_set_string(val, "Application Identifier", 128, 'a', - diskStructure->primaryDescriptor.application_id); - } else if(CD9660_IS_COMMAND_ARG_DUAL(var, "P", "publisher")) { - rv = cd9660_arguments_set_string(val, "Publisher Identifier", - 128, 'a', diskStructure->primaryDescriptor.publisher_id); - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "p", "preparer")) { - rv = cd9660_arguments_set_string(val, "Preparer Identifier", - 128, 'a', diskStructure->primaryDescriptor.preparer_id); - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "V", "volumeid")) { - rv = cd9660_arguments_set_string(val, "Volume Set Identifier", - 128, 'a', diskStructure->primaryDescriptor.volume_set_id); - /* Boot options */ - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "B", "bootimage")) { - if (val == NULL) - warnx("error: The Boot Image parameter requires a valid boot information string"); - else - rv = cd9660_add_boot_disk(diskStructure, val); - } else if (CD9660_IS_COMMAND_ARG(var, "bootimagedir")) { - /* - * XXXfvdl this is unused. - */ - if (val == NULL) - errx(1, "error: The Boot Image Directory parameter" - " requires a directory name\n"); - else { - if ((diskStructure->boot_image_directory = - malloc(strlen(val) + 1)) == NULL) { - CD9660_MEM_ALLOC_ERROR("cd9660_parse_opts"); - exit(1); - } + i = set_option(cd9660_options, option, buf, sizeof(buf)); + if (i == -1) + return 0; - /* BIG TODO: Add the max length function here */ - cd9660_arguments_set_string(val, "Boot Image Directory", - 12 , 'd', diskStructure->boot_image_directory); - } - } else if (CD9660_IS_COMMAND_ARG_DUAL(var, "G", "generic-bootimage")) { - if (val == NULL) - warnx("error: The Boot Image parameter requires a valid boot information string"); - else - rv = cd9660_add_generic_bootimage(diskStructure, val); - } else if (CD9660_IS_COMMAND_ARG(var, "no-trailing-padding")) - diskStructure->include_padding_areas = 0; - /* RRIP */ - else if (CD9660_IS_COMMAND_ARG_DUAL(var, "R", "rockridge")) - diskStructure->rock_ridge_enabled = 1; - else if (CD9660_IS_COMMAND_ARG_DUAL(var, "A", "archimedes")) - diskStructure->archimedes_enabled = 1; - else if (CD9660_IS_COMMAND_ARG(var, "chrp-boot")) - diskStructure->chrp_boot = 1; - else if (CD9660_IS_COMMAND_ARG_DUAL(var, "K", "keep-bad-images")) - diskStructure->keep_bad_images = 1; - else if (CD9660_IS_COMMAND_ARG(var, "allow-deep-trees")) - diskStructure->allow_deep_trees = 1; - else if (CD9660_IS_COMMAND_ARG(var, "allow-max-name")) - diskStructure->allow_max_name = 1; - else if (CD9660_IS_COMMAND_ARG(var, "allow-illegal-chars")) - diskStructure->allow_illegal_chars = 1; - else if (CD9660_IS_COMMAND_ARG(var, "allow-lowercase")) - diskStructure->allow_lowercase = 1; - else if (CD9660_IS_COMMAND_ARG(var,"allow-multidot")) - diskStructure->allow_multidot = 1; - else if (CD9660_IS_COMMAND_ARG(var, "omit-trailing-period")) - diskStructure->omit_trailing_period = 1; - else if (CD9660_IS_COMMAND_ARG(var, "no-emul-boot") || - CD9660_IS_COMMAND_ARG(var, "no-boot") || - CD9660_IS_COMMAND_ARG(var, "hard-disk-boot")) { - cd9660_eltorito_add_boot_option(diskStructure, var, 0); - - /* End of flag variables */ - } else if (CD9660_IS_COMMAND_ARG(var, "boot-load-segment")) { - if (val == NULL) { - warnx("Option `%s' doesn't contain a value", var); + if (cd9660_options[i].name == NULL) + abort(); + + name = cd9660_options[i].name; + desc = cd9660_options[i].desc; + switch (cd9660_options[i].letter) { + case 'h': + case 'S': + rv = 0; /* this is not handled yet */ + break; + case 'L': + rv = cd9660_arguments_set_string(buf, desc, 32, 'd', + diskStructure->primaryDescriptor.volume_id); + break; + case 'A': + rv = cd9660_arguments_set_string(buf, desc, 128, 'a', + diskStructure->primaryDescriptor.application_id); + break; + case 'P': + rv = cd9660_arguments_set_string(buf, desc, 128, 'a', + diskStructure->primaryDescriptor.publisher_id); + break; + case 'p': + rv = cd9660_arguments_set_string(buf, desc, 128, 'a', + diskStructure->primaryDescriptor.preparer_id); + break; + case 'V': + rv = cd9660_arguments_set_string(buf, desc, 128, 'a', + diskStructure->primaryDescriptor.volume_set_id); + break; + /* Boot options */ + case 'B': + if (buf[0] == '\0') { + warnx("The Boot Image parameter requires a valid boot" + "information string"); rv = 0; - } else { - cd9660_eltorito_add_boot_option(diskStructure, var, - val); - } - } else { - if (val == NULL) { - warnx("Option `%s' doesn't contain a value", var); + } else + rv = cd9660_add_boot_disk(diskStructure, buf); + break; + case 'G': + if (buf[0] == '\0') { + warnx("The Generic Boot Image parameter requires a" + " valid boot information string"); rv = 0; } else - rv = set_option(cd9660_options, var, val); + rv = cd9660_add_generic_bootimage(diskStructure, buf); + break; + default: + if (strcmp(name, "bootimagedir") == 0) { + /* + * XXXfvdl this is unused. + */ + if (buf[0] == '\0') { + warnx("The Boot Image Directory parameter" + " requires a directory name\n"); + rv = 0; + } else { + diskStructure->boot_image_directory = + malloc(strlen(buf) + 1); + if (diskStructure->boot_image_directory == NULL) + err(1, "malloc"); + /* BIG TODO: Add the max length function here */ + rv = cd9660_arguments_set_string(buf, desc, 12, + 'd', diskStructure->boot_image_directory); + } + } else if (strcmp(name, "no-emul-boot") == 0 || + strcmp(name, "no-boot") == 0 || + strcmp(name, "hard-disk-boot") == 0) { + /* RRIP */ + cd9660_eltorito_add_boot_option(diskStructure, name, 0); + rv = 1; + } else if (strcmp(name, "boot-load-segment") == 0) { + if (buf[0] == '\0') { + warnx("Option `%s' doesn't contain a value", + name); + rv = 0; + } else { + cd9660_eltorito_add_boot_option(diskStructure, + name, buf); + rv = 1; + } + } else + rv = 1; } - - free(var); - return (rv); + return rv; } /* Modified: head/usr.sbin/makefs/cd9660.h ============================================================================== --- head/usr.sbin/makefs/cd9660.h Wed Mar 15 11:16:26 2017 (r315303) +++ head/usr.sbin/makefs/cd9660.h Wed Mar 15 13:34:51 2017 (r315304) @@ -120,12 +120,6 @@ typedef struct { #define CD9660_MEM_ALLOC_ERROR(_F) \ err(EXIT_FAILURE, "%s, %s l. %d", _F, __FILE__, __LINE__) -#define CD9660_IS_COMMAND_ARG_DUAL(var,short,long)\ - (strcmp((var),(short)) == 0) || (strcmp((var),(long))==0) - -#define CD9660_IS_COMMAND_ARG(var,arg)\ - (strcmp((var),(arg)) == 0) - #define CD9660_TYPE_FILE 0x01 #define CD9660_TYPE_DIR 0x02 #define CD9660_TYPE_DOT 0x04 Modified: head/usr.sbin/makefs/ffs.c ============================================================================== --- head/usr.sbin/makefs/ffs.c Wed Mar 15 11:16:26 2017 (r315303) +++ head/usr.sbin/makefs/ffs.c Wed Mar 15 13:34:51 2017 (r315304) @@ -144,7 +144,6 @@ static void *ffs_build_dinode2(struct u int sectorsize; /* XXX: for buf.c::getblk() */ - /* publicly visible functions */ void @@ -155,7 +154,33 @@ ffs_prep_opts(fsinfo_t *fsopts) if ((ffs_opts = calloc(1, sizeof(ffs_opt_t))) == NULL) err(1, "Allocating memory for ffs_options"); - fsopts->fs_specific = ffs_opts; + const option_t ffs_options[] = { + { 'b', "bsize", &ffs_opts->bsize, OPT_INT32, + 1, INT_MAX, "block size" }, + { 'f', "fsize", &ffs_opts->fsize, OPT_INT32, + 1, INT_MAX, "fragment size" }, + { 'd', "density", &ffs_opts->density, OPT_INT32, + 1, INT_MAX, "bytes per inode" }, + { 'm', "minfree", &ffs_opts->minfree, OPT_INT32, + 0, 99, "minfree" }, + { 'M', "maxbpg", &ffs_opts->maxbpg, OPT_INT32, + 1, INT_MAX, "max blocks per file in a cg" }, + { 'a', "avgfilesize", &ffs_opts->avgfilesize, OPT_INT32, + 1, INT_MAX, "expected average file size" }, + { 'n', "avgfpdir", &ffs_opts->avgfpdir, OPT_INT32, + 1, INT_MAX, "expected # of files per directory" }, + { 'x', "extent", &ffs_opts->maxbsize, OPT_INT32, + 1, INT_MAX, "maximum # extent size" }, + { 'g', "maxbpcg", &ffs_opts->maxblkspercg, OPT_INT32, + 1, INT_MAX, "max # of blocks per group" }, + { 'v', "version", &ffs_opts->version, OPT_INT32, + 1, 2, "UFS version" }, + { 'o', "optimization", NULL, OPT_STRBUF, + 0, 0, "Optimization (time|space)" }, + { 'l', "label", ffs_opts->label, OPT_STRARRAY, + 1, sizeof(ffs_opts->label), "UFS label" }, + { .name = NULL } + }; ffs_opts->bsize= -1; ffs_opts->fsize= -1; @@ -168,45 +193,25 @@ ffs_prep_opts(fsinfo_t *fsopts) ffs_opts->avgfilesize= -1; ffs_opts->avgfpdir= -1; ffs_opts->version = 1; + + fsopts->fs_specific = ffs_opts; + fsopts->fs_options = copy_opts(ffs_options); } void ffs_cleanup_opts(fsinfo_t *fsopts) { - if (fsopts->fs_specific) - free(fsopts->fs_specific); + free(fsopts->fs_specific); + free(fsopts->fs_options); } int ffs_parse_opts(const char *option, fsinfo_t *fsopts) { ffs_opt_t *ffs_opts = fsopts->fs_specific; + option_t *ffs_options = fsopts->fs_options; + char buf[1024]; - option_t ffs_options[] = { - { "bsize", &ffs_opts->bsize, 1, INT_MAX, - "block size" }, - { "fsize", &ffs_opts->fsize, 1, INT_MAX, - "fragment size" }, - { "density", &ffs_opts->density, 1, INT_MAX, - "bytes per inode" }, - { "minfree", &ffs_opts->minfree, 0, 99, - "minfree" }, - { "maxbpg", &ffs_opts->maxbpg, 1, INT_MAX, - "max blocks per file in a cg" }, - { "avgfilesize", &ffs_opts->avgfilesize,1, INT_MAX, - "expected average file size" }, - { "avgfpdir", &ffs_opts->avgfpdir, 1, INT_MAX, - "expected # of files per directory" }, - { "extent", &ffs_opts->maxbsize, 1, INT_MAX, - "maximum # extent size" }, - { "maxbpcg", &ffs_opts->maxblkspercg,1, INT_MAX, - "max # of blocks per group" }, - { "version", &ffs_opts->version, 1, 2, - "UFS version" }, - { .name = NULL } - }; - - char *var, *val; int rv; assert(option != NULL); @@ -216,36 +221,28 @@ ffs_parse_opts(const char *option, fsinf if (debug & DEBUG_FS_PARSE_OPTS) printf("ffs_parse_opts: got `%s'\n", option); - if ((var = strdup(option)) == NULL) - err(1, "Allocating memory for copy of option string"); - rv = 0; - - if ((val = strchr(var, '=')) == NULL) { - warnx("Option `%s' doesn't contain a value", var); - goto leave_ffs_parse_opts; - } - *val++ = '\0'; - - if (strcmp(var, "optimization") == 0) { - if (strcmp(val, "time") == 0) { + rv = set_option(ffs_options, option, buf, sizeof(buf)); + if (rv == -1) + return 0; + + if (ffs_options[rv].name == NULL) + abort(); + + switch (ffs_options[rv].letter) { + case 'o': + if (strcmp(buf, "time") == 0) { ffs_opts->optimization = FS_OPTTIME; - } else if (strcmp(val, "space") == 0) { + } else if (strcmp(buf, "space") == 0) { ffs_opts->optimization = FS_OPTSPACE; } else { - warnx("Invalid optimization `%s'", val); - goto leave_ffs_parse_opts; + warnx("Invalid optimization `%s'", buf); + return 0; } - rv = 1; - } else if (strcmp(var, "label") == 0) { - strlcpy(ffs_opts->label, val, sizeof(ffs_opts->label)); - rv = 1; - } else - rv = set_option(ffs_options, var, val); - - leave_ffs_parse_opts: - if (var) - free(var); - return (rv); + break; + default: + break; + } + return 1; } Modified: head/usr.sbin/makefs/makefs.c ============================================================================== --- head/usr.sbin/makefs/makefs.c Wed Mar 15 11:16:26 2017 (r315303) +++ head/usr.sbin/makefs/makefs.c Wed Mar 15 13:34:51 2017 (r315304) @@ -49,6 +49,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include "makefs.h" #include "mtree.h" @@ -82,7 +83,7 @@ struct stat stampst; static fstype_t *get_fstype(const char *); static int get_tstamp(const char *, struct stat *); -static void usage(void); +static void usage(fstype_t *, fsinfo_t *); int main(int, char *[]); int @@ -141,7 +142,7 @@ main(int argc, char *argv[]) #endif } else { warnx("Invalid endian `%s'.", optarg); - usage(); + usage(fstype, &fsoptions); } break; @@ -210,7 +211,7 @@ main(int argc, char *argv[]) if (*p == '\0') errx(1, "Empty option"); if (! fstype->parse_options(p, &fsoptions)) - usage(); + usage(fstype, &fsoptions); } break; } @@ -263,7 +264,7 @@ main(int argc, char *argv[]) case '?': default: - usage(); + usage(fstype, &fsoptions); /* NOTREACHED */ } @@ -278,7 +279,7 @@ main(int argc, char *argv[]) argv += optind; if (argc < 2) - usage(); + usage(fstype, &fsoptions); /* -x must be accompanied by -F */ if (fsoptions.onlyspec != 0 && specfile == NULL) @@ -344,21 +345,84 @@ main(int argc, char *argv[]) /* NOTREACHED */ } +int +set_option(const option_t *options, const char *option, char *buf, size_t len) +{ + char *var, *val; + int retval; + + assert(option != NULL); + + if ((var = strdup(option)) == NULL) { + err(EXIT_FAILURE, "Allocating memory for copy of option string"); + } + + for (val = var; *val; val++) + if (*val == '=') { + *val++ = '\0'; + break; + } + retval = set_option_var(options, var, val, buf, len); + free(var); + return retval; +} int -set_option(option_t *options, const char *var, const char *val) +set_option_var(const option_t *options, const char *var, const char *val, + char *buf, size_t len) { - int i; + char *s; + size_t i; + +#define NUM(type) \ + if (!*val) { \ + *(type *)options[i].value = 1; \ + break; \ + } \ + *(type *)options[i].value = (type)strsuftoll(options[i].desc, val, \ + options[i].minimum, options[i].maximum); break for (i = 0; options[i].name != NULL; i++) { - if (strcmp(options[i].name, var) != 0) + if (var[1] == '\0') { + if (options[i].letter != var[0]) + continue; + } else if (strcmp(options[i].name, var) != 0) continue; - *options[i].value = (int)strsuftoll(options[i].desc, val, - options[i].minimum, options[i].maximum); - return (1); + switch (options[i].type) { + case OPT_BOOL: + *(bool *)options[i].value = 1; + break; + case OPT_STRARRAY: + strlcpy((void *)options[i].value, val, (size_t) + options[i].maximum); + break; + case OPT_STRPTR: + if ((s = strdup(val)) == NULL) + err(1, NULL); + *(char **)options[i].value = s; + break; + case OPT_STRBUF: + if (buf == NULL) + abort(); + strlcpy(buf, val, len); + break; + case OPT_INT64: + NUM(uint64_t); + case OPT_INT32: + NUM(uint32_t); + case OPT_INT16: + NUM(uint16_t); + case OPT_INT8: + NUM(uint8_t); + default: + warnx("Unknown type %d in option %s", options[i].type, + val); + return 0; + } + return i; } warnx("Unknown option `%s'", var); - return (0); + return -1; } @@ -373,6 +437,20 @@ get_fstype(const char *type) return (NULL); } +option_t * +copy_opts(const option_t *o) +{ + size_t i; + void *rv; + + for (i = 0; o[i].name; i++) + continue; + i++; + if ((rv = calloc(i, sizeof(*o))) == NULL) + err(1, "calloc"); + return memcpy(rv, o, i * sizeof(*o)); +} + static int get_tstamp(const char *b, struct stat *st) { @@ -400,17 +478,29 @@ get_tstamp(const char *b, struct stat *s } static void -usage(void) +usage(fstype_t *fstype, fsinfo_t *fsoptions) { const char *prog; prog = getprogname(); fprintf(stderr, -"usage: %s [-xZ] [-B endian] [-b free-blocks] [-d debug-mask]\n" +"Usage: %s [-xZ] [-B endian] [-b free-blocks] [-d debug-mask]\n" "\t[-F mtree-specfile] [-f free-files] [-M minimum-size] [-m maximum-size]\n" "\t[-N userdb-dir] [-o fs-options] [-R roundup-size] [-S sector-size]\n" "\t[-s image-size] [-T ] [-t fs-type]\n" "\timage-file directory | manifest [extra-directory ...]\n", prog); + + if (fstype) { + size_t i; + option_t *o = fsoptions->fs_options; + + fprintf(stderr, "\n%s specific options:\n", fstype->type); + for (i = 0; o[i].name != NULL; i++) + fprintf(stderr, "\t%c%c%20.20s\t%s\n", + o[i].letter ? o[i].letter : ' ', + o[i].letter ? ',' : ' ', + o[i].name, o[i].desc); + } exit(1); } Modified: head/usr.sbin/makefs/makefs.h ============================================================================== --- head/usr.sbin/makefs/makefs.h Wed Mar 15 11:16:26 2017 (r315303) +++ head/usr.sbin/makefs/makefs.h Wed Mar 15 13:34:51 2017 (r315304) @@ -104,11 +104,37 @@ typedef struct _fsnode { #define FSNODE_F_OPTIONAL 0x02 /* fsnode is optional */ /* + * option_t - contains option name, description, pointer to location to store + * result, and range checks for the result. Used to simplify fs specific + * option setting + */ +typedef enum { + OPT_STRARRAY, + OPT_STRPTR, + OPT_STRBUF, + OPT_BOOL, + OPT_INT8, + OPT_INT16, + OPT_INT32, + OPT_INT64 +} opttype_t; + +typedef struct { + char letter; /* option letter NUL for none */ + const char *name; /* option name */ + void *value; /* where to stuff the value */ + opttype_t type; /* type of entry */ + long long minimum; /* minimum for value */ + long long maximum; /* maximum for value */ + const char *desc; /* option description */ +} option_t; + +/* * fsinfo_t - contains various settings and parameters pertaining to * the image, including current settings, global options, and fs * specific options */ -typedef struct { +typedef struct makefs_fsinfo { /* current settings */ off_t size; /* total size */ off_t inodes; /* number of inodes */ @@ -124,8 +150,8 @@ typedef struct { off_t minsize; /* minimum size image should be */ off_t maxsize; /* maximum size image can be */ off_t freefiles; /* free file entries to leave */ - int freefilepc; /* free file % */ off_t freeblocks; /* free blocks to leave */ + int freefilepc; /* free file % */ int freeblockpc; /* free block % */ int needswap; /* non-zero if byte swapping needed */ int sectorsize; /* sector size */ @@ -133,30 +159,20 @@ typedef struct { off_t roundup; /* round image size up to this value */ void *fs_specific; /* File system specific additions. */ + option_t *fs_options; /* File system specific options */ } fsinfo_t; -/* - * option_t - contains option name, description, pointer to location to store - * result, and range checks for the result. Used to simplify fs specific - * option setting - */ -typedef struct { - const char *name; /* option name */ - int *value; /* where to stuff the value */ - int minimum; /* minimum for value */ - int maximum; /* maximum for value */ - const char *desc; /* option description */ -} option_t; - - void apply_specfile(const char *, const char *, fsnode *, int); void dump_fsnodes(fsnode *); const char * inode_type(mode_t); fsnode * read_mtree(const char *, fsnode *); -int set_option(option_t *, const char *, const char *); +int set_option(const option_t *, const char *, char *, size_t); +int set_option_var(const option_t *, const char *, const char *, + char *, size_t); fsnode * walk_dir(const char *, const char *, fsnode *, fsnode *); void free_fsnodes(fsnode *); +option_t * copy_opts(const option_t *); #define DECLARE_FUN(fs) \ void fs ## _prep_opts(fsinfo_t *); \ From owner-svn-src-all@freebsd.org Wed Mar 15 13:36:36 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A68ACD0D8BB; Wed, 15 Mar 2017 13:36:36 +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 80F4F13B7; Wed, 15 Mar 2017 13:36:36 +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 v2FDaZCR057375; Wed, 15 Mar 2017 13:36:35 GMT (envelope-from ae@FreeBSD.org) Received: (from ae@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FDaZS7057372; Wed, 15 Mar 2017 13:36:35 GMT (envelope-from ae@FreeBSD.org) Message-Id: <201703151336.v2FDaZS7057372@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ae set sender to ae@FreeBSD.org using -f From: "Andrey V. Elsukov" Date: Wed, 15 Mar 2017 13:36:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315305 - in head: . sbin/ipfw X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 13:36:36 -0000 Author: ae Date: Wed Mar 15 13:36:35 2017 New Revision: 315305 URL: https://svnweb.freebsd.org/changeset/base/315305 Log: Change the syntax of ipfw's named states. Since the state name is an optional argument, it often can conflict with other options. To avoid ambiguity now the state name must be prefixed with a colon. Obtained from: Yandex LLC MFC after: 2 week Sponsored by: Yandex LLC Modified: head/UPDATING head/sbin/ipfw/ipfw.8 head/sbin/ipfw/ipfw2.c Modified: head/UPDATING ============================================================================== --- head/UPDATING Wed Mar 15 13:34:51 2017 (r315304) +++ head/UPDATING Wed Mar 15 13:36:35 2017 (r315305) @@ -51,6 +51,12 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12 ****************************** SPECIAL WARNING: ****************************** +20170315: + The syntax of ipfw(8) named states was changed to avoid ambiguity. + If you have used named states in the firewall rules, you need to modify + them after installworld and before rebooting. Now named states must + be prefixed with colon. + 20170311: The old drm (sys/dev/drm/) drivers for i915 and radeon have been removed as the userland we provide cannot use them. The KMS version Modified: head/sbin/ipfw/ipfw.8 ============================================================================== --- head/sbin/ipfw/ipfw.8 Wed Mar 15 13:34:51 2017 (r315304) +++ head/sbin/ipfw/ipfw.8 Wed Mar 15 13:36:35 2017 (r315305) @@ -1,7 +1,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 18, 2016 +.Dd March 15, 2017 .Dt IPFW 8 .Os .Sh NAME @@ -781,7 +781,7 @@ will be executed when the packet matches .It Cm allow | accept | pass | permit Allow packets that match rule. The search terminates. -.It Cm check-state Op Ar flowname | Cm any +.It Cm check-state Op Ar :flowname | Cm :any Checks the packet against the dynamic ruleset. If a match is found, execute the action associated with the rule which generated this dynamic rule, otherwise @@ -797,15 +797,15 @@ or .Cm limit rule. The -.Ar flowname +.Ar :flowname is symbolic name assigned to dynamic rule by .Cm keep-state opcode. The special flowname -.Cm any +.Cm :any can be used to ignore states flowname when matching. The -.Cm default +.Cm :default keyword is special name used for compatibility with old rulesets. .It Cm count Update counters for all packets that match rule. @@ -1662,7 +1662,7 @@ specified in the same way as .It Cm ipversion Ar ver Matches IP packets whose IP version field is .Ar ver . -.It Cm keep-state Op Ar flowname +.It Cm keep-state Op Ar :flowname Upon a match, the firewall will create a dynamic rule, whose default behaviour is to match bidirectional traffic between source and destination IP/port using the same protocol. @@ -1671,19 +1671,19 @@ The rule has a limited lifetime (control variables), and the lifetime is refreshed every time a matching packet is found. The -.Ar flowname +.Ar :flowname is used to assign additional to addresses, ports and protocol parameter to dynamic rule. It can be used for more accurate matching by .Cm check-state rule. The -.Cm default +.Cm :default keyword is special name used for compatibility with old rulesets. .It Cm layer2 Matches only layer2 packets, i.e., those passed to .Nm from ether_demux() and ether_output_frame(). -.It Cm limit Bro Cm src-addr | src-port | dst-addr | dst-port Brc Ar N Op Ar flowname +.It Cm limit Bro Cm src-addr | src-port | dst-addr | dst-port Brc Ar N Op Ar :flowname The firewall will only allow .Ar N connections with the same @@ -2286,7 +2286,7 @@ are completely equivalent afterwards). Rules created by .Cm keep-state option also have a -.Ar flowname +.Ar :flowname taken from it. This name is used in matching together with addresses, ports and protocol. Dynamic rules will be checked at the first @@ -2297,23 +2297,23 @@ occurrence, and the action performed upo as in the parent rule. .Pp Note that no additional attributes other than protocol and IP addresses -and ports and flowname are checked on dynamic rules. +and ports and :flowname are checked on dynamic rules. .Pp The typical use of dynamic rules is to keep a closed firewall configuration, but let the first TCP SYN packet from the inside network install a dynamic rule for the flow so that packets belonging to that session will be allowed through the firewall: .Pp -.Dl "ipfw add check-state OUTBOUND" -.Dl "ipfw add allow tcp from my-subnet to any setup keep-state OUTBOUND" +.Dl "ipfw add check-state :OUTBOUND" +.Dl "ipfw add allow tcp from my-subnet to any setup keep-state :OUTBOUND" .Dl "ipfw add deny tcp from any to any" .Pp A similar approach can be used for UDP, where an UDP packet coming from the inside will install a dynamic rule to let the response through the firewall: .Pp -.Dl "ipfw add check-state OUTBOUND" -.Dl "ipfw add allow udp from my-subnet to any keep-state OUTBOUND" +.Dl "ipfw add check-state :OUTBOUND" +.Dl "ipfw add allow udp from my-subnet to any keep-state :OUTBOUND" .Dl "ipfw add deny udp from any to any" .Pp Dynamic rules expire after some time, which depends on the status Modified: head/sbin/ipfw/ipfw2.c ============================================================================== --- head/sbin/ipfw/ipfw2.c Wed Mar 15 13:34:51 2017 (r315304) +++ head/sbin/ipfw/ipfw2.c Wed Mar 15 13:36:35 2017 (r315305) @@ -1483,7 +1483,7 @@ show_static_rule(struct cmdline_opts *co cmd->arg1, IPFW_TLV_STATE_NAME); else ename = NULL; - bprintf(bp, " %s", ename ? ename: "any"); + bprintf(bp, " :%s", ename ? ename: "any"); /* avoid printing anything else */ flags = HAVE_PROTO | HAVE_SRCIP | HAVE_DSTIP | HAVE_IP; @@ -2076,7 +2076,7 @@ show_static_rule(struct cmdline_opts *co case O_KEEP_STATE: bprintf(bp, " keep-state"); - bprintf(bp, " %s", + bprintf(bp, " :%s", object_search_ctlv(fo->tstate, cmd->arg1, IPFW_TLV_STATE_NAME)); break; @@ -2095,7 +2095,7 @@ show_static_rule(struct cmdline_opts *co comma = ","; } bprint_uint_arg(bp, " ", c->conn_limit); - bprintf(bp, " %s", + bprintf(bp, " :%s", object_search_ctlv(fo->tstate, cmd->arg1, IPFW_TLV_STATE_NAME)); break; @@ -2198,7 +2198,7 @@ show_dyn_state(struct cmdline_opts *co, } else bprintf(bp, " UNKNOWN <-> UNKNOWN"); if (d->kidx != 0) - bprintf(bp, " %s", object_search_ctlv(fo->tstate, + bprintf(bp, " :%s", object_search_ctlv(fo->tstate, d->kidx, IPFW_TLV_STATE_NAME)); } @@ -3714,27 +3714,25 @@ compile_rule(char *av[], uint32_t *rbuf, case TOK_CHECKSTATE: have_state = action; action->opcode = O_CHECK_STATE; - if (*av == NULL) { + if (*av == NULL || + match_token(rule_options, *av) == TOK_COMMENT) { action->arg1 = pack_object(tstate, default_state_name, IPFW_TLV_STATE_NAME); break; } - if (strcmp(*av, "any") == 0) - action->arg1 = 0; - else if ((i = match_token(rule_options, *av)) != -1) { - action->arg1 = pack_object(tstate, - default_state_name, IPFW_TLV_STATE_NAME); - if (i != TOK_COMMENT) - warn("Ambiguous state name '%s', '%s'" - " used instead.\n", *av, - default_state_name); - break; - } else if (state_check_name(*av) == 0) - action->arg1 = pack_object(tstate, *av, - IPFW_TLV_STATE_NAME); - else - errx(EX_DATAERR, "Invalid state name %s", *av); - av++; + if (*av[0] == ':') { + if (strcmp(*av + 1, "any") == 0) + action->arg1 = 0; + else if (state_check_name(*av + 1) == 0) + action->arg1 = pack_object(tstate, *av + 1, + IPFW_TLV_STATE_NAME); + else + errx(EX_DATAERR, "Invalid state name %s", + *av); + av++; + break; + } + errx(EX_DATAERR, "Invalid state name %s", *av); break; case TOK_ACCEPT: @@ -4577,22 +4575,16 @@ read_options: if (have_state) errx(EX_USAGE, "only one of keep-state " "and limit is allowed"); - if (*av == NULL || - (i = match_token(rule_options, *av)) != -1) { - if (*av != NULL && i != TOK_COMMENT) - warn("Ambiguous state name '%s'," - " '%s' used instead.\n", *av, - default_state_name); - uidx = pack_object(tstate, default_state_name, - IPFW_TLV_STATE_NAME); - } else { - if (state_check_name(*av) != 0) + if (*av != NULL && *av[0] == ':') { + if (state_check_name(*av + 1) != 0) errx(EX_DATAERR, "Invalid state name %s", *av); - uidx = pack_object(tstate, *av, + uidx = pack_object(tstate, *av + 1, IPFW_TLV_STATE_NAME); av++; - } + } else + uidx = pack_object(tstate, default_state_name, + IPFW_TLV_STATE_NAME); have_state = cmd; fill_cmd(cmd, O_KEEP_STATE, 0, uidx); break; @@ -4629,22 +4621,16 @@ read_options: TOK_LIMIT, rule_options); av++; - if (*av == NULL || - (i = match_token(rule_options, *av)) != -1) { - if (*av != NULL && i != TOK_COMMENT) - warn("Ambiguous state name '%s'," - " '%s' used instead.\n", *av, - default_state_name); - cmd->arg1 = pack_object(tstate, - default_state_name, IPFW_TLV_STATE_NAME); - } else { - if (state_check_name(*av) != 0) + if (*av != NULL && *av[0] == ':') { + if (state_check_name(*av + 1) != 0) errx(EX_DATAERR, "Invalid state name %s", *av); - cmd->arg1 = pack_object(tstate, *av, + cmd->arg1 = pack_object(tstate, *av + 1, IPFW_TLV_STATE_NAME); av++; - } + } else + cmd->arg1 = pack_object(tstate, + default_state_name, IPFW_TLV_STATE_NAME); break; } From owner-svn-src-all@freebsd.org Wed Mar 15 14:31:02 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 037DCD0E1D6; Wed, 15 Mar 2017 14:31:02 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (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 B9152774; Wed, 15 Mar 2017 14:31:01 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.86 (FreeBSD)) (envelope-from ) id 1co9wz-000IuW-7K; Wed, 15 Mar 2017 17:30:53 +0300 Date: Wed, 15 Mar 2017 17:30:53 +0300 From: Slawa Olhovchenkov To: John Baldwin 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: r313450 - in stable/11: lib/libc/gen lib/libc/sys sys/compat/freebsd32 sys/kern sys/sys Message-ID: <20170315143053.GW15630@zxy.spb.ru> References: <201702081832.v18IWZlC001828@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201702081832.v18IWZlC001828@repo.freebsd.org> User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 14:31:02 -0000 On Wed, Feb 08, 2017 at 06:32:35PM +0000, John Baldwin wrote: > Author: jhb > Date: Wed Feb 8 18:32:35 2017 > New Revision: 313450 > URL: https://svnweb.freebsd.org/changeset/base/313450 > > Log: > MFC 310638: > Rename the 'flags' argument to getfsstat() to 'mode' and validate it. > > This argument is not a bitmask of flags, but only accepts a single value. > Fail with EINVAL if an invalid value is passed to 'flag'. Rename the > 'flags' argument to getmntinfo(3) to 'mode' as well to match. > > This is a followup to r308088. > kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize, > - size_t *countp, enum uio_seg bufseg, int flags) > + size_t *countp, enum uio_seg bufseg, int mode) > { > struct mount *mp, *nmp; > struct statfs *sfsp, *sp, *sptmp, *tofree; > size_t count, maxcount; > int error; > > + switch (mode) { > + case MNT_WAIT: > + case MNT_NOWAIT: > + break; > + default: > + return (EINVAL); > + } > restart: This is break net-snmp UCD-SNMP-MIB::dskTable oid: 82434 snmpd CALL getfsstat(0,0,) 82434 snmpd RET getfsstat -1 errno 22 Invalid argument 82434 snmpd CALL getfsstat(0,0xfffffffffffffe28,MNT_NOWAIT) 82434 snmpd RET getfsstat -1 errno 22 Invalid argument 82434 snmpd CALL write(0x9,0x800f162ea,0x1) From owner-svn-src-all@freebsd.org Wed Mar 15 14:45:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 17910D0E892; Wed, 15 Mar 2017 14:45:01 +0000 (UTC) (envelope-from sbruno@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 D8D95131A; Wed, 15 Mar 2017 14:45:00 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FEix2a086034; Wed, 15 Mar 2017 14:44:59 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FEixfZ086033; Wed, 15 Mar 2017 14:44:59 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201703151444.v2FEixfZ086033@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Wed, 15 Mar 2017 14:44:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315306 - head/sys/dev/e1000 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 14:45:01 -0000 Author: sbruno Date: Wed Mar 15 14:44:59 2017 New Revision: 315306 URL: https://svnweb.freebsd.org/changeset/base/315306 Log: Actually set the MTU to the requested value and fixup handling of jumbo frames. Submitted by: Matt Macy Reported by: pho Sponsored by: Limelight Networks Modified: head/sys/dev/e1000/if_em.c Modified: head/sys/dev/e1000/if_em.c ============================================================================== --- head/sys/dev/e1000/if_em.c Wed Mar 15 13:36:35 2017 (r315305) +++ head/sys/dev/e1000/if_em.c Wed Mar 15 14:44:59 2017 (r315306) @@ -1116,7 +1116,6 @@ em_if_mtu_set(if_ctx_t ctx, uint32_t mtu { int max_frame_size; struct adapter *adapter = iflib_get_softc(ctx); - struct ifnet *ifp = iflib_get_ifp(ctx); if_softc_ctx_t scctx = iflib_get_softc_ctx(ctx); IOCTL_DEBUGOUT("ioctl rcv'd: SIOCSIFMTU (Set Interface MTU)"); @@ -1154,7 +1153,7 @@ em_if_mtu_set(if_ctx_t ctx, uint32_t mtu } scctx->isc_max_frame_size = adapter->hw.mac.max_frame_size = - if_getmtu(ifp) + ETHER_HDR_LEN + ETHER_CRC_LEN; + mtu + ETHER_HDR_LEN + ETHER_CRC_LEN; return (0); } From owner-svn-src-all@freebsd.org Wed Mar 15 14:53:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C3AF4D0EAA7; Wed, 15 Mar 2017 14:53:14 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io0-x22d.google.com (mail-io0-x22d.google.com [IPv6:2607:f8b0:4001:c06::22d]) (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 8D3521A59; Wed, 15 Mar 2017 14:53:14 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io0-x22d.google.com with SMTP id z13so21705922iof.2; Wed, 15 Mar 2017 07:53:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=PBO5MKYkSGXK6Beg1WTLWVvURT7jl+aXOEcyZcfOjxs=; b=uDEkhBcrtxoCtag9b75/GsQMULfA4NxqA6tYToj0Bi/nbXolLpk9B4EIuCIulb1PzC e/PyUDWuu94Hgbb3teeISj+WB/j9h6lDO3ImLxEhXN8YDvrvAIb761UZP4eia/TLz7ZD GVpePOmQXlCQc6koAUhmZUJyZ+1qqjoqxx3qBZPVwBsHFD02mOKykrey6WkwQkEOmb2E s1R4oh/cg5Bhi2f9Krp8z+mp7L3LWhXJmmyTn1o0r9sWryOHuGyyvU/VnQeedSeukq5x ORhu6j349YllXKxc+BOdrphbe6RjsI6t0bMyrj97QoMKbXMHdxo63cxjRsvol1RmOLEw Z5Nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=PBO5MKYkSGXK6Beg1WTLWVvURT7jl+aXOEcyZcfOjxs=; b=eJHqVP6trunqZNOnjqLklehHwpKKwv5F6NCsRNK7/QD6NDUpe6zGLhlN6eBSJ3Kq2y YcXzOPQ0cbNBf1vAW3NbVWoa10YDv9rOFFsT8DYGxDc/760dpcjXSiR6sSgZR0UpIJ+N mNqtPjVuTRYCMlpcImDFK+svJ/n8KHfC8xLbOdiOx2I7D2bj7voGdq4no9FYWwUaf+LO 6MjSZ+2FDM15+v7iLqHyTmAgX8y+UdIjRTuof9AOjDYiKRL5fu/PPdbiGwMxPDeyqmiI 2/TOkE98FtUQqtMrQEY78x0mEzsJHZjKDdtvV713nOZzfwUClh+CBFOyB8Xbdhmotj1l +f+w== X-Gm-Message-State: AFeK/H308uXzUZoSXOUsvKU1cvl5g0szL6n3zbC2bAnO6PWPg0kYB/xaN/o+QzN2tAnVoFojHG9pEJ3vc/iRfw== X-Received: by 10.107.47.102 with SMTP id j99mr5443321ioo.52.1489589592734; Wed, 15 Mar 2017 07:53:12 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.30.209 with HTTP; Wed, 15 Mar 2017 07:52:52 -0700 (PDT) In-Reply-To: <201703102245.v2AMj7h1088240@repo.freebsd.org> References: <201703102245.v2AMj7h1088240@repo.freebsd.org> From: Ed Maste Date: Wed, 15 Mar 2017 10:52:52 -0400 X-Google-Sender-Auth: bfGsL4mXlIZq8KXgg5KXO74BCYY Message-ID: Subject: Re: svn commit: r315031 - head/sys/tools/fdt To: Oleksandr Tymoshenko Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 14:53:14 -0000 On 10 March 2017 at 17:45, Oleksandr Tymoshenko wrote: > Author: gonzo > Date: Fri Mar 10 22:45:07 2017 > New Revision: 315031 > URL: https://svnweb.freebsd.org/changeset/base/315031 > > Log: > [fdt] Make DTBs generated by make_dtb.sh overlay-ready This breaks WITHOUT_GPL_DTC builds as the BSD dtc does not yet support -@. I've opened a GitHub issue at https://github.com/davidchisnall/dtc/issues/15 to track it. From owner-svn-src-all@freebsd.org Wed Mar 15 14:58:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9FF3FD0EC24; Wed, 15 Mar 2017 14:58:31 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6C0451D7F; Wed, 15 Mar 2017 14:58:31 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FEwUUV096834; Wed, 15 Mar 2017 14:58:30 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FEwU9b096829; Wed, 15 Mar 2017 14:58:30 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703151458.v2FEwU9b096829@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Wed, 15 Mar 2017 14:58:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315307 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 14:58:31 -0000 Author: mav Date: Wed Mar 15 14:58:29 2017 New Revision: 315307 URL: https://svnweb.freebsd.org/changeset/base/315307 Log: Refactor interrupt handling. Instead of single isp_intr() function doing all possible magic, introduce four different functions to handle mailbox operation completions, async events, response and ATIO queues. The goal is to isolate different code paths to make code more readable, and to make easier support for multiple interrupt vectors. Even oldest hardware in many cases can identify what code path it should run on interrupt. Contemporary hardware can assign them to different interrupt vectors. MFC after: 2 weeks Modified: head/sys/dev/isp/isp.c head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_pci.c head/sys/dev/isp/isp_sbus.c head/sys/dev/isp/ispvar.h Modified: head/sys/dev/isp/isp.c ============================================================================== --- head/sys/dev/isp/isp.c Wed Mar 15 14:44:59 2017 (r315306) +++ head/sys/dev/isp/isp.c Wed Mar 15 14:58:29 2017 (r315307) @@ -416,11 +416,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d } /* - * Clear instrumentation - */ - isp->isp_intcnt = isp->isp_intbogus = 0; - - /* * Hit the chip over the head with hammer, * and give it a chance to recover. */ @@ -4404,7 +4399,7 @@ isp_start(XS_T *xs) ((ispreqt7_t *)reqp)->req_task_attribute = ttype; } else if (IS_FC(isp)) { /* - * See comment in isp_intr + * See comment in isp_intr_respq */ /* XS_SET_RESID(xs, 0); */ @@ -4911,6 +4906,70 @@ isp_control(ispsoftc_t *isp, ispctl_t ct * and the locking will be held throughout this function. */ +#ifdef ISP_TARGET_MODE +void +isp_intr_atioq(ispsoftc_t *isp) +{ + uint8_t qe[QENTRY_LEN]; + isphdr_t *hp; + void *addr; + uint32_t iptr, optr, oop; + + iptr = ISP_READ(isp, BIU2400_ATIO_RSPINP); + optr = isp->isp_atioodx; + while (optr != iptr) { + oop = optr; + MEMORYBARRIER(isp, SYNC_ATIOQ, oop, QENTRY_LEN, -1); + addr = ISP_QUEUE_ENTRY(isp->isp_atioq, oop); + isp_get_hdr(isp, addr, (isphdr_t *)qe); + hp = (isphdr_t *)qe; + switch (hp->rqs_entry_type) { + case RQSTYPE_NOTIFY: + case RQSTYPE_ATIO: + (void) isp_target_notify(isp, addr, &oop); + break; + default: + isp_print_qentry(isp, "?ATIOQ entry?", oop, addr); + break; + } + optr = ISP_NXT_QENTRY(oop, RESULT_QUEUE_LEN(isp)); + } + if (isp->isp_atioodx != optr) { + ISP_WRITE(isp, BIU2400_ATIO_RSPOUTP, optr); + isp->isp_atioodx = optr; + } +} +#endif + +void +isp_intr_async(ispsoftc_t *isp, uint16_t event) +{ + + if (IS_FC(isp)) + isp_parse_async_fc(isp, event); + else + isp_parse_async(isp, event); +} + +void +isp_intr_mbox(ispsoftc_t *isp, uint16_t mbox0) +{ + int i, obits; + + if (!isp->isp_mboxbsy) { + isp_prt(isp, ISP_LOGWARN, "mailbox 0x%x with no waiters", mbox0); + return; + } + obits = isp->isp_obits; + isp->isp_mboxtmp[0] = mbox0; + for (i = 1; i < ISP_NMBOX(isp); i++) { + if ((obits & (1 << i)) == 0) + continue; + isp->isp_mboxtmp[i] = ISP_READ(isp, MBOX_OFF(i)); + } + MBOX_NOTIFY_COMPLETE(isp); +} + /* * Limit our stack depth by sticking with the max likely number * of completions on a request queue at any one time. @@ -4920,165 +4979,32 @@ isp_control(ispsoftc_t *isp, ispctl_t ct #endif void -isp_intr(ispsoftc_t *isp, uint16_t isr, uint16_t sema, uint16_t info) +isp_intr_respq(ispsoftc_t *isp) { XS_T *complist[MAX_REQUESTQ_COMPLETIONS], *xs; uint32_t iptr, optr, junk; int i, nlooked = 0, ndone = 0, continuations_expected = 0; int etype, last_etype = 0; -again: - /* - * Is this a mailbox related interrupt? - * The mailbox semaphore will be nonzero if so. - */ - if (sema) { - fmbox: - if (info & MBOX_COMMAND_COMPLETE) { - isp->isp_intmboxc++; - if (isp->isp_mboxbsy) { - int obits = isp->isp_obits; - isp->isp_mboxtmp[0] = info; - for (i = 1; i < ISP_NMBOX(isp); i++) { - if ((obits & (1 << i)) == 0) { - continue; - } - isp->isp_mboxtmp[i] = ISP_READ(isp, MBOX_OFF(i)); - } - MBOX_NOTIFY_COMPLETE(isp); - } else { - isp_prt(isp, ISP_LOGWARN, "mailbox cmd (0x%x) with no waiters", info); - } - } else { - if (IS_FC(isp)) - isp_parse_async_fc(isp, info); - else - isp_parse_async(isp, info); - } - if ((IS_FC(isp) && info != ASYNC_RIOZIO_STALL) || isp->isp_state != ISP_RUNSTATE) { - goto out; - } - } - /* * We can't be getting this now. */ if (isp->isp_state != ISP_RUNSTATE) { - /* - * This seems to happen to 23XX and 24XX cards- don't know why. - */ - if (isp->isp_mboxbsy && isp->isp_lastmbxcmd == MBOX_ABOUT_FIRMWARE) { - goto fmbox; - } - isp_prt(isp, ISP_LOGINFO, "interrupt (ISR=%x SEMA=%x INFO=%x) " - "when not ready", isr, sema, info); - /* - * Thank you very much! *Burrrp*! - */ - isp->isp_residx = ISP_READ(isp, isp->isp_respinrp); - isp->isp_resodx = isp->isp_residx; - ISP_WRITE(isp, isp->isp_respoutrp, isp->isp_resodx); - if (IS_24XX(isp)) { - ISP_DISABLE_INTS(isp); - } - goto out; - } - -#ifdef ISP_TARGET_MODE - /* - * Check for ATIO Queue entries. - */ - if (IS_24XX(isp) && - (isr == ISPR2HST_ATIO_UPDATE || isr == ISPR2HST_ATIO_RSPQ_UPDATE || - isr == ISPR2HST_ATIO_UPDATE2)) { - iptr = ISP_READ(isp, BIU2400_ATIO_RSPINP); - optr = isp->isp_atioodx; - - while (optr != iptr) { - uint8_t qe[QENTRY_LEN]; - isphdr_t *hp; - uint32_t oop; - void *addr; - - oop = optr; - MEMORYBARRIER(isp, SYNC_ATIOQ, oop, QENTRY_LEN, -1); - addr = ISP_QUEUE_ENTRY(isp->isp_atioq, oop); - isp_get_hdr(isp, addr, (isphdr_t *)qe); - hp = (isphdr_t *)qe; - switch (hp->rqs_entry_type) { - case RQSTYPE_NOTIFY: - case RQSTYPE_ATIO: - (void) isp_target_notify(isp, addr, &oop); - break; - default: - isp_print_qentry(isp, "?ATIOQ entry?", oop, addr); - break; - } - optr = ISP_NXT_QENTRY(oop, RESULT_QUEUE_LEN(isp)); - } - if (isp->isp_atioodx != optr) { - ISP_WRITE(isp, BIU2400_ATIO_RSPOUTP, optr); - isp->isp_atioodx = optr; - } + isp_prt(isp, ISP_LOGINFO, "respq interrupt when not ready"); + return; } -#endif - /* - * You *must* read the Response Queue In Pointer - * prior to clearing the RISC interrupt. - * - * Debounce the 2300 if revision less than 2. - */ + iptr = ISP_READ(isp, isp->isp_respinrp); + /* Debounce the 2300 if revision less than 2. */ if (IS_2100(isp) || (IS_2300(isp) && isp->isp_revision < 2)) { - i = 0; do { + junk = iptr; iptr = ISP_READ(isp, isp->isp_respinrp); - junk = ISP_READ(isp, isp->isp_respinrp); - } while (junk != iptr && ++i < 1000); - - if (iptr != junk) { - isp_prt(isp, ISP_LOGWARN, "Response Queue Out Pointer Unstable (%x, %x)", iptr, junk); - goto out; - } - } else { - iptr = ISP_READ(isp, isp->isp_respinrp); - } - - optr = isp->isp_resodx; - if (optr == iptr && sema == 0) { - /* - * There are a lot of these- reasons unknown- mostly on - * faster Alpha machines. - * - * I tried delaying after writing HCCR_CMD_CLEAR_RISC_INT to - * make sure the old interrupt went away (to avoid 'ringing' - * effects), but that didn't stop this from occurring. - */ - if (IS_24XX(isp)) { - junk = 0; - } else if (IS_23XX(isp)) { - ISP_DELAY(100); - iptr = ISP_READ(isp, isp->isp_respinrp); - junk = ISP_READ(isp, BIU_R2HSTSLO); - } else { - junk = ISP_READ(isp, BIU_ISR); - } - if (optr == iptr) { - if (IS_23XX(isp) || IS_24XX(isp)) { - ; - } else { - sema = ISP_READ(isp, BIU_SEMA); - info = ISP_READ(isp, OUTMAILBOX0); - if ((sema & 0x3) && (info & 0x8000)) { - goto again; - } - } - isp->isp_intbogus++; - isp_prt(isp, ISP_LOGDEBUG1, "bogus intr- isr %x (%x) iptr %x optr %x", isr, junk, iptr, optr); - } + } while (junk != iptr); } isp->isp_residx = iptr; + optr = isp->isp_resodx; while (optr != iptr) { uint8_t qe[QENTRY_LEN]; ispstatusreq_t *sp = (ispstatusreq_t *) qe; @@ -5130,9 +5056,6 @@ again: for (i = 0; i < rio->req_header.rqs_seqno; i++) { isp_fastpost_complete(isp, rio->req_handles[i]); } - if (isp->isp_fpcchiwater < rio->req_header.rqs_seqno) { - isp->isp_fpcchiwater = rio->req_header.rqs_seqno; - } ISP_MEMZERO(hp, QENTRY_LEN); /* PERF */ last_etype = etype; continue; @@ -5377,10 +5300,8 @@ again: if (ndone > (MAX_REQUESTQ_COMPLETIONS - continuations_expected - 1)) { /* we'll lose some stats, but that's a small price to pay */ for (i = 0; i < ndone; i++) { - if (complist[i]) { - isp->isp_rsltccmplt++; + if (complist[i]) isp_done(complist[i]); - } } ndone = 0; } @@ -5453,17 +5374,6 @@ again: if (nlooked) { ISP_WRITE(isp, isp->isp_respoutrp, optr); isp->isp_resodx = optr; - if (isp->isp_rscchiwater < ndone) - isp->isp_rscchiwater = ndone; - } - -out: - - if (IS_24XX(isp)) { - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_CLEAR_RISC_INT); - } else { - ISP_WRITE(isp, HCCR, HCCR_CMD_CLEAR_RISC_INT); - ISP_WRITE(isp, BIU_SEMA, 0); } for (i = 0; i < ndone; i++) { @@ -5473,7 +5383,6 @@ out: ((isp->isp_dblev & (ISP_LOGDEBUG0|ISP_LOG_CWARN) && ((!XS_NOERR(xs)) || (*XS_STSP(xs) != SCSI_GOOD))))) { isp_prt_endcmd(isp, xs); } - isp->isp_rsltccmplt++; isp_done(xs); } } @@ -5666,16 +5575,7 @@ isp_parse_async(ispsoftc_t *isp, uint16_ if (h2) { isp_prt(isp, ISP_LOGDEBUG3, "fast post/rio completion of 0x%08x", h2); isp_fastpost_complete(isp, h2); - if (isp->isp_fpcchiwater < 2) { - isp->isp_fpcchiwater = 2; - } - } else { - if (isp->isp_fpcchiwater < 1) { - isp->isp_fpcchiwater = 1; - } } - } else { - isp->isp_intoasync++; } } @@ -5733,19 +5633,16 @@ isp_parse_async_fc(ispsoftc_t *isp, uint case ASYNC_CMD_CMPLT: isp_fastpost_complete(isp, (ISP_READ(isp, OUTMAILBOX2) << 16) | ISP_READ(isp, OUTMAILBOX1)); - if (isp->isp_fpcchiwater < 1) { - isp->isp_fpcchiwater = 1; - } break; case ASYNC_RIOZIO_STALL: + isp_intr_respq(isp); break; case ASYNC_CTIO_DONE: #ifdef ISP_TARGET_MODE isp_target_async(isp, (ISP_READ(isp, OUTMAILBOX2) << 16) | ISP_READ(isp, OUTMAILBOX1), mbox); - isp->isp_fphccmplt++; #else isp_prt(isp, ISP_LOGWARN, "unexpected ASYNC CTIO done"); #endif @@ -6017,9 +5914,6 @@ isp_parse_async_fc(ispsoftc_t *isp, uint isp_prt(isp, ISP_LOGWARN, "Unknown Async Code 0x%x", mbox); break; } - if (mbox != ASYNC_CTIO_DONE && mbox != ASYNC_CMD_CMPLT) { - isp->isp_intoasync++; - } } /* @@ -6106,11 +6000,9 @@ isp_handle_other_response(ispsoftc_t *is case RQSTYPE_CTIO7: case RQSTYPE_ABTS_RCVD: case RQSTYPE_ABTS_RSP: - isp->isp_rsltccmplt++; /* count as a response completion */ #ifdef ISP_TARGET_MODE - if (isp_target_notify(isp, (ispstatusreq_t *) hp, optrp)) { + if (isp_target_notify(isp, (ispstatusreq_t *) hp, optrp)) return (1); - } #endif /* FALLTHROUGH */ case RQSTYPE_REQUEST: @@ -6649,7 +6541,6 @@ isp_fastpost_complete(ispsoftc_t *isp, u if (isp->isp_nactive) { isp->isp_nactive--; } - isp->isp_fphccmplt++; isp_done(xs); } Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Wed Mar 15 14:44:59 2017 (r315306) +++ head/sys/dev/isp/isp_freebsd.c Wed Mar 15 14:58:29 2017 (r315307) @@ -512,40 +512,6 @@ ispioctl(struct cdev *dev, u_long c, cad } break; } - case ISP_GET_STATS: - { - isp_stats_t *sp = (isp_stats_t *) addr; - - ISP_MEMZERO(sp, sizeof (*sp)); - sp->isp_stat_version = ISP_STATS_VERSION; - sp->isp_type = isp->isp_type; - sp->isp_revision = isp->isp_revision; - ISP_LOCK(isp); - sp->isp_stats[ISP_INTCNT] = isp->isp_intcnt; - sp->isp_stats[ISP_INTBOGUS] = isp->isp_intbogus; - sp->isp_stats[ISP_INTMBOXC] = isp->isp_intmboxc; - sp->isp_stats[ISP_INGOASYNC] = isp->isp_intoasync; - sp->isp_stats[ISP_RSLTCCMPLT] = isp->isp_rsltccmplt; - sp->isp_stats[ISP_FPHCCMCPLT] = isp->isp_fphccmplt; - sp->isp_stats[ISP_RSCCHIWAT] = isp->isp_rscchiwater; - sp->isp_stats[ISP_FPCCHIWAT] = isp->isp_fpcchiwater; - ISP_UNLOCK(isp); - retval = 0; - break; - } - case ISP_CLR_STATS: - ISP_LOCK(isp); - isp->isp_intcnt = 0; - isp->isp_intbogus = 0; - isp->isp_intmboxc = 0; - isp->isp_intoasync = 0; - isp->isp_rsltccmplt = 0; - isp->isp_fphccmplt = 0; - isp->isp_rscchiwater = 0; - isp->isp_fpcchiwater = 0; - ISP_UNLOCK(isp); - retval = 0; - break; case ISP_FC_GETHINFO: { struct isp_hba_device *hba = (struct isp_hba_device *) addr; @@ -2829,10 +2795,8 @@ static void isp_poll(struct cam_sim *sim) { ispsoftc_t *isp = cam_sim_softc(sim); - uint16_t isr, sema, info; - if (ISP_READ_ISR(isp, &isr, &sema, &info)) - isp_intr(isp, isr, sema, info); + ISP_RUN_ISR(isp); } @@ -2851,9 +2815,7 @@ isp_watchdog(void *arg) * Hand crank the interrupt code just to be sure the command isn't stuck somewhere. */ if (handle != ISP_HANDLE_FREE) { - uint16_t isr, sema, info; - if (ISP_READ_ISR(isp, &isr, &sema, &info) != 0) - isp_intr(isp, isr, sema, info); + ISP_RUN_ISR(isp); ohandle = handle; handle = isp_find_handle(isp, xs); } @@ -4428,14 +4390,11 @@ isp_mbox_wait_complete(ispsoftc_t *isp, isp->isp_osinfo.mbox_sleeping = 0; } else { for (t = 0; t < to; t += 100) { - uint16_t isr, sema, info; if (isp->isp_osinfo.mboxcmd_done) break; - if (ISP_READ_ISR(isp, &isr, &sema, &info)) { - isp_intr(isp, isr, sema, info); - if (isp->isp_osinfo.mboxcmd_done) - break; - } + ISP_RUN_ISR(isp); + if (isp->isp_osinfo.mboxcmd_done) + break; ISP_DELAY(100); } } @@ -4495,14 +4454,9 @@ void isp_platform_intr(void *arg) { ispsoftc_t *isp = arg; - uint16_t isr, sema, info; ISP_LOCK(isp); - isp->isp_intcnt++; - if (ISP_READ_ISR(isp, &isr, &sema, &info)) - isp_intr(isp, isr, sema, info); - else - isp->isp_intbogus++; + ISP_RUN_ISR(isp); ISP_UNLOCK(isp); } Modified: head/sys/dev/isp/isp_pci.c ============================================================================== --- head/sys/dev/isp/isp_pci.c Wed Mar 15 14:44:59 2017 (r315306) +++ head/sys/dev/isp/isp_pci.c Wed Mar 15 14:58:29 2017 (r315307) @@ -61,9 +61,9 @@ static uint32_t isp_pci_rd_reg_2400(isps static void isp_pci_wr_reg_2400(ispsoftc_t *, int, uint32_t); static uint32_t isp_pci_rd_reg_2600(ispsoftc_t *, int); static void isp_pci_wr_reg_2600(ispsoftc_t *, int, uint32_t); -static int isp_pci_rd_isr(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); -static int isp_pci_rd_isr_2300(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); -static int isp_pci_rd_isr_2400(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); +static void isp_pci_run_isr(ispsoftc_t *); +static void isp_pci_run_isr_2300(ispsoftc_t *); +static void isp_pci_run_isr_2400(ispsoftc_t *); static int isp_pci_mbxdma(ispsoftc_t *); static void isp_pci_mbxdmafree(ispsoftc_t *); static int isp_pci_dmasetup(ispsoftc_t *, XS_T *, void *); @@ -71,7 +71,7 @@ static int isp_pci_irqsetup(ispsoftc_t * static void isp_pci_dumpregs(ispsoftc_t *, const char *); static struct ispmdvec mdvec = { - isp_pci_rd_isr, + isp_pci_run_isr, isp_pci_rd_reg, isp_pci_wr_reg, isp_pci_mbxdma, @@ -84,7 +84,7 @@ static struct ispmdvec mdvec = { }; static struct ispmdvec mdvec_1080 = { - isp_pci_rd_isr, + isp_pci_run_isr, isp_pci_rd_reg_1080, isp_pci_wr_reg_1080, isp_pci_mbxdma, @@ -97,7 +97,7 @@ static struct ispmdvec mdvec_1080 = { }; static struct ispmdvec mdvec_12160 = { - isp_pci_rd_isr, + isp_pci_run_isr, isp_pci_rd_reg_1080, isp_pci_wr_reg_1080, isp_pci_mbxdma, @@ -110,7 +110,7 @@ static struct ispmdvec mdvec_12160 = { }; static struct ispmdvec mdvec_2100 = { - isp_pci_rd_isr, + isp_pci_run_isr, isp_pci_rd_reg, isp_pci_wr_reg, isp_pci_mbxdma, @@ -121,7 +121,7 @@ static struct ispmdvec mdvec_2100 = { }; static struct ispmdvec mdvec_2200 = { - isp_pci_rd_isr, + isp_pci_run_isr, isp_pci_rd_reg, isp_pci_wr_reg, isp_pci_mbxdma, @@ -132,7 +132,7 @@ static struct ispmdvec mdvec_2200 = { }; static struct ispmdvec mdvec_2300 = { - isp_pci_rd_isr_2300, + isp_pci_run_isr_2300, isp_pci_rd_reg, isp_pci_wr_reg, isp_pci_mbxdma, @@ -143,7 +143,7 @@ static struct ispmdvec mdvec_2300 = { }; static struct ispmdvec mdvec_2400 = { - isp_pci_rd_isr_2400, + isp_pci_run_isr_2400, isp_pci_rd_reg_2400, isp_pci_wr_reg_2400, isp_pci_mbxdma, @@ -154,7 +154,7 @@ static struct ispmdvec mdvec_2400 = { }; static struct ispmdvec mdvec_2500 = { - isp_pci_rd_isr_2400, + isp_pci_run_isr_2400, isp_pci_rd_reg_2400, isp_pci_wr_reg_2400, isp_pci_mbxdma, @@ -165,7 +165,7 @@ static struct ispmdvec mdvec_2500 = { }; static struct ispmdvec mdvec_2600 = { - isp_pci_rd_isr_2400, + isp_pci_run_isr_2400, isp_pci_rd_reg_2600, isp_pci_wr_reg_2600, isp_pci_mbxdma, @@ -1066,35 +1066,27 @@ isp_pci_detach(device_t dev) #define B2R4(isp, off) bus_read_4((isp)->isp_regs2, (off)) #define B2W4(isp, off, v) bus_write_4((isp)->isp_regs2, (off), (v)) -static ISP_INLINE int -isp_pci_rd_debounced(ispsoftc_t *isp, int off, uint16_t *rp) +static ISP_INLINE uint16_t +isp_pci_rd_debounced(ispsoftc_t *isp, int off) { - uint32_t val0, val1; - int i = 0; + uint16_t val, prev; + val = BXR2(isp, IspVirt2Off(isp, off)); do { - val0 = BXR2(isp, IspVirt2Off(isp, off)); - val1 = BXR2(isp, IspVirt2Off(isp, off)); - } while (val0 != val1 && ++i < 1000); - if (val0 != val1) { - return (1); - } - *rp = val0; - return (0); + prev = val; + val = BXR2(isp, IspVirt2Off(isp, off)); + } while (val != prev); + return (val); } -static int -isp_pci_rd_isr(ispsoftc_t *isp, uint16_t *isrp, uint16_t *semap, uint16_t *info) +static void +isp_pci_run_isr(ispsoftc_t *isp) { - uint16_t isr, sema; + uint16_t isr, sema, info; if (IS_2100(isp)) { - if (isp_pci_rd_debounced(isp, BIU_ISR, &isr)) { - return (0); - } - if (isp_pci_rd_debounced(isp, BIU_SEMA, &sema)) { - return (0); - } + isr = isp_pci_rd_debounced(isp, BIU_ISR); + sema = isp_pci_rd_debounced(isp, BIU_SEMA); } else { isr = BXR2(isp, IspVirt2Off(isp, BIU_ISR)); sema = BXR2(isp, IspVirt2Off(isp, BIU_SEMA)); @@ -1102,59 +1094,61 @@ isp_pci_rd_isr(ispsoftc_t *isp, uint16_t isp_prt(isp, ISP_LOGDEBUG3, "ISR 0x%x SEMA 0x%x", isr, sema); isr &= INT_PENDING_MASK(isp); sema &= BIU_SEMA_LOCK; - if (isr == 0 && sema == 0) { - return (0); - } - *isrp = isr; - if ((*semap = sema) != 0) { - if (IS_2100(isp)) { - if (isp_pci_rd_debounced(isp, OUTMAILBOX0, info)) { - return (0); - } - } else { - *info = BXR2(isp, IspVirt2Off(isp, OUTMAILBOX0)); - } - } - return (1); + if (isr == 0 && sema == 0) + return; + if (sema != 0) { + if (IS_2100(isp)) + info = isp_pci_rd_debounced(isp, OUTMAILBOX0); + else + info = BXR2(isp, IspVirt2Off(isp, OUTMAILBOX0)); + if (info & MBOX_COMMAND_COMPLETE) + isp_intr_mbox(isp, info); + else + isp_intr_async(isp, info); + if (!IS_FC(isp) && isp->isp_state == ISP_RUNSTATE) + isp_intr_respq(isp); + } else + isp_intr_respq(isp); + ISP_WRITE(isp, HCCR, HCCR_CMD_CLEAR_RISC_INT); + if (sema) + ISP_WRITE(isp, BIU_SEMA, 0); } -static int -isp_pci_rd_isr_2300(ispsoftc_t *isp, uint16_t *isrp, uint16_t *semap, uint16_t *info) +static void +isp_pci_run_isr_2300(ispsoftc_t *isp) { uint32_t hccr, r2hisr; + uint16_t isr, info; - if ((BXR2(isp, IspVirt2Off(isp, BIU_ISR)) & BIU2100_ISR_RISC_INT) == 0) { - *isrp = 0; - return (0); - } + if ((BXR2(isp, IspVirt2Off(isp, BIU_ISR)) & BIU2100_ISR_RISC_INT) == 0) + return; r2hisr = BXR4(isp, IspVirt2Off(isp, BIU_R2HSTSLO)); isp_prt(isp, ISP_LOGDEBUG3, "RISC2HOST ISR 0x%x", r2hisr); - if ((r2hisr & BIU_R2HST_INTR) == 0) { - *isrp = 0; - return (0); - } - switch ((*isrp = r2hisr & BIU_R2HST_ISTAT_MASK)) { + if ((r2hisr & BIU_R2HST_INTR) == 0) + return; + isr = r2hisr & BIU_R2HST_ISTAT_MASK; + info = r2hisr >> 16; + switch (isr) { case ISPR2HST_ROM_MBX_OK: case ISPR2HST_ROM_MBX_FAIL: case ISPR2HST_MBX_OK: case ISPR2HST_MBX_FAIL: + isp_intr_mbox(isp, info); + break; case ISPR2HST_ASYNC_EVENT: - *semap = 1; + isp_intr_async(isp, info); break; case ISPR2HST_RIO_16: - *info = ASYNC_RIO16_1; - *semap = 1; - return (1); + isp_intr_async(isp, ASYNC_RIO16_1); + break; case ISPR2HST_FPOST: - *info = ASYNC_CMD_CMPLT; - *semap = 1; - return (1); + isp_intr_async(isp, ASYNC_CMD_CMPLT); + break; case ISPR2HST_FPOST_CTIO: - *info = ASYNC_CTIO_DONE; - *semap = 1; - return (1); + isp_intr_async(isp, ASYNC_CTIO_DONE); + break; case ISPR2HST_RSPQ_UPDATE: - *semap = 0; + isp_intr_respq(isp); break; default: hccr = ISP_READ(isp, HCCR); @@ -1165,45 +1159,52 @@ isp_pci_rd_isr_2300(ispsoftc_t *isp, uin } else { isp_prt(isp, ISP_LOGERR, "unknown interrupt 0x%x\n", r2hisr); } - return (0); } - *info = (r2hisr >> 16); - return (1); + ISP_WRITE(isp, HCCR, HCCR_CMD_CLEAR_RISC_INT); + ISP_WRITE(isp, BIU_SEMA, 0); } -static int -isp_pci_rd_isr_2400(ispsoftc_t *isp, uint16_t *isrp, uint16_t *semap, uint16_t *info) +static void +isp_pci_run_isr_2400(ispsoftc_t *isp) { uint32_t r2hisr; + uint16_t isr, info; r2hisr = BXR4(isp, IspVirt2Off(isp, BIU2400_R2HSTSLO)); isp_prt(isp, ISP_LOGDEBUG3, "RISC2HOST ISR 0x%x", r2hisr); - if ((r2hisr & BIU_R2HST_INTR) == 0) { - *isrp = 0; - return (0); - } - switch ((*isrp = r2hisr & BIU_R2HST_ISTAT_MASK)) { + if ((r2hisr & BIU_R2HST_INTR) == 0) + return; + isr = r2hisr & BIU_R2HST_ISTAT_MASK; + info = (r2hisr >> 16); + switch (isr) { case ISPR2HST_ROM_MBX_OK: case ISPR2HST_ROM_MBX_FAIL: case ISPR2HST_MBX_OK: case ISPR2HST_MBX_FAIL: + isp_intr_mbox(isp, info); + break; case ISPR2HST_ASYNC_EVENT: - *semap = 1; + isp_intr_async(isp, info); break; case ISPR2HST_RSPQ_UPDATE: + isp_intr_respq(isp); + break; case ISPR2HST_RSPQ_UPDATE2: - case ISPR2HST_ATIO_UPDATE: +#ifdef ISP_TARGET_MODE case ISPR2HST_ATIO_RSPQ_UPDATE: +#endif + isp_intr_respq(isp); + /* FALLTHROUGH */ +#ifdef ISP_TARGET_MODE + case ISPR2HST_ATIO_UPDATE: case ISPR2HST_ATIO_UPDATE2: - *semap = 0; + isp_intr_atioq(isp); +#endif break; default: - ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_CLEAR_RISC_INT); isp_prt(isp, ISP_LOGERR, "unknown interrupt 0x%x\n", r2hisr); - return (0); } - *info = (r2hisr >> 16); - return (1); + ISP_WRITE(isp, BIU2400_HCCR, HCCR_2400_CMD_CLEAR_RISC_INT); } static uint32_t Modified: head/sys/dev/isp/isp_sbus.c ============================================================================== --- head/sys/dev/isp/isp_sbus.c Wed Mar 15 14:44:59 2017 (r315306) +++ head/sys/dev/isp/isp_sbus.c Wed Mar 15 14:58:29 2017 (r315307) @@ -53,14 +53,14 @@ __FBSDID("$FreeBSD$"); static uint32_t isp_sbus_rd_reg(ispsoftc_t *, int); static void isp_sbus_wr_reg(ispsoftc_t *, int, uint32_t); -static int isp_sbus_rd_isr(ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); +static void isp_sbus_run_isr(ispsoftc_t *); static int isp_sbus_mbxdma(ispsoftc_t *); static void isp_sbus_mbxdmafree(ispsoftc_t *); static int isp_sbus_dmasetup(ispsoftc_t *, XS_T *, void *); static void isp_sbus_dumpregs(ispsoftc_t *, const char *); static struct ispmdvec mdvec = { - isp_sbus_rd_isr, + isp_sbus_run_isr, isp_sbus_rd_reg, isp_sbus_wr_reg, isp_sbus_mbxdma, @@ -344,23 +344,31 @@ isp_sbus_detach(device_t dev) #define BXR2(isp, off) bus_read_2((isp)->isp_regs, (off)) -static int -isp_sbus_rd_isr(ispsoftc_t *isp, uint16_t *isrp, uint16_t *semap, uint16_t *info) +static void +isp_sbus_run_isr(ispsoftc_t *isp) { - uint16_t isr, sema; + uint16_t isr, sema, info; isr = BXR2(isp, IspVirt2Off(isp, BIU_ISR)); sema = BXR2(isp, IspVirt2Off(isp, BIU_SEMA)); isp_prt(isp, ISP_LOGDEBUG3, "ISR 0x%x SEMA 0x%x", isr, sema); isr &= INT_PENDING_MASK(isp); sema &= BIU_SEMA_LOCK; - if (isr == 0 && sema == 0) { - return (0); - } - *isrp = isr; - if ((*semap = sema) != 0) - *info = BXR2(isp, IspVirt2Off(isp, OUTMAILBOX0)); - return (1); + if (isr == 0 && sema == 0) + return; + if (sema != 0) { + info = BXR2(isp, IspVirt2Off(isp, OUTMAILBOX0)); + if (info & MBOX_COMMAND_COMPLETE) + isp_intr_mbox(isp, info); + else + isp_intr_async(isp, info); + if (isp->isp_state == ISP_RUNSTATE) + isp_intr_respq(isp); + } else + isp_intr_respq(isp); + ISP_WRITE(isp, HCCR, HCCR_CMD_CLEAR_RISC_INT); + if (sema) + ISP_WRITE(isp, BIU_SEMA, 0); } static uint32_t Modified: head/sys/dev/isp/ispvar.h ============================================================================== --- head/sys/dev/isp/ispvar.h Wed Mar 15 14:44:59 2017 (r315306) +++ head/sys/dev/isp/ispvar.h Wed Mar 15 14:58:29 2017 (r315307) @@ -58,7 +58,7 @@ */ typedef struct ispsoftc ispsoftc_t; struct ispmdvec { - int (*dv_rd_isr) (ispsoftc_t *, uint16_t *, uint16_t *, uint16_t *); + void (*dv_run_isr) (ispsoftc_t *); uint32_t (*dv_rd_reg) (ispsoftc_t *, int); void (*dv_wr_reg) (ispsoftc_t *, int, uint32_t); int (*dv_mbxdma) (ispsoftc_t *); @@ -85,8 +85,8 @@ struct ispmdvec { * Macros to access ISP registers through bus specific layers- * mostly wrappers to vector through the mdvec structure. */ -#define ISP_READ_ISR(isp, isrp, semap, info) \ - (*(isp)->isp_mdvec->dv_rd_isr)(isp, isrp, semap, info) +#define ISP_RUN_ISR(isp) \ + (*(isp)->isp_mdvec->dv_run_isr)(isp) #define ISP_READ(isp, reg) \ (*(isp)->isp_mdvec->dv_rd_reg)((isp), (reg)) @@ -544,18 +544,6 @@ struct ispsoftc { uint32_t isp_rqstoutrp; /* register for REQOUTP */ uint32_t isp_respinrp; /* register for RESINP */ uint32_t isp_respoutrp; /* register for RESOUTP */ - - /* - * Instrumentation - */ - uint64_t isp_intcnt; /* total int count */ - uint64_t isp_intbogus; /* spurious int count */ - uint64_t isp_intmboxc; /* mbox completions */ - uint64_t isp_intoasync; /* other async */ - uint64_t isp_rsltccmplt; /* CMDs on result q */ - uint64_t isp_fphccmplt; /* CMDs via fastpost */ - uint16_t isp_rscchiwater; - uint16_t isp_fpcchiwater; NANOTIME_T isp_init_time; /* time were last initialized */ /* @@ -813,12 +801,13 @@ void isp_shutdown(ispsoftc_t *); /* * Internal Interrupt Service Routine - * - * The outer layers do the spade work to get the appropriate status register, - * semaphore register and first mailbox register (if appropriate). This also - * means that most spurious/bogus interrupts not for us can be filtered first. */ -void isp_intr(ispsoftc_t *, uint16_t, uint16_t, uint16_t); +#ifdef ISP_TARGET_MODE +void isp_intr_atioq(ispsoftc_t *); +#endif +void isp_intr_async(ispsoftc_t *, uint16_t event); +void isp_intr_mbox(ispsoftc_t *, uint16_t mbox0); +void isp_intr_respq(ispsoftc_t *); /* From owner-svn-src-all@freebsd.org Wed Mar 15 15:29:14 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8C71BD0964B; Wed, 15 Mar 2017 15:29:14 +0000 (UTC) (envelope-from rionda@gmail.com) Received: from mail-qt0-x22d.google.com (mail-qt0-x22d.google.com [IPv6:2607:f8b0:400d:c0d::22d]) (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 453E2EE5; Wed, 15 Mar 2017 15:29:14 +0000 (UTC) (envelope-from rionda@gmail.com) Received: by mail-qt0-x22d.google.com with SMTP id n21so15071276qta.1; Wed, 15 Mar 2017 08:29:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=NuoqWoyUT8NKRa1N65iW2jn+y9mEre9vErC6oHqFS/U=; b=U9KnxLxKBCeRr12swS1lF8RUPDfaOz8D3a0dyb9zd2oRIneyy+cRHbT2pzEcZbdk8e QM/SPRjmQfbNZMj1SHioI93yZ/ZO6ZnzVz3FTgw/tuT9gEI4QnqV9rhvXjWjwi9kXGBY YYKIBXesqw+i3cL+Z0lsP4sPE1SDapuTsPQnSIC1CENAbFOATJS6JTiwqRYMwLIVsqyC 3zkE5+tTB6bu9L21KNLc8uq6g/ikgmaKOKZ4ZzQD1pnAaPn3nejAXwFXnNjTQB3dmZq+ XzAtI7QmRccXqITAba6y2i3irfEAJNezWSsWoo4pv1EXfTwHrFFFiVv5w+6BcjaJXgOz l7qQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=NuoqWoyUT8NKRa1N65iW2jn+y9mEre9vErC6oHqFS/U=; b=sovwmS7J2U+XQV43LeFTKMViZBXGP29H8+RIn/BKSCmxJLzJTstMcUtFwiSyqZvBPp 2RrZGraknoCkcCE+qHcoUJWNyF3ZfEd9PJ/zf7CkMghke30X0RKpAm1u3tIBLOln2p/I 9BJ66eWNDti220zx30hSSTH0kIJ9rnsh4+lhekf6p0Rt5btBCSXvnq9Rp4AZetD6+ciH l7epm0/blmAfpVK190xpE2UfBNjIBZnwd+L9LXxPN5/pQNf1961Lhwi5l8I0YoyTGqqE g9CfWtQYwho2BEyZOmc4QyMaT83mg2s0zl3oJ/HchMtz3fCEGw1YmwlxFUmLJ5hagWMo RUpQ== X-Gm-Message-State: AFeK/H1tcEM2ogAA+vwQuVGDWQ9xHfjH2y74xNmVxDJ2NpbhBDSZ9HH3mUtdtAvpRGmoPg== X-Received: by 10.200.49.230 with SMTP id i35mr3835485qte.254.1489591752047; Wed, 15 Mar 2017 08:29:12 -0700 (PDT) Received: from [172.31.30.181] (gzac12-mdf2-1.aoa.twosigma.com. [208.77.215.155]) by smtp.gmail.com with ESMTPSA id v39sm1479984qtv.61.2017.03.15.08.29.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 15 Mar 2017 08:29:10 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 10.2 \(3259\)) Subject: Re: svn commit: r315305 - in head: . sbin/ipfw From: Matteo Riondato In-Reply-To: <201703151336.v2FDaZS7057372@repo.freebsd.org> Date: Wed, 15 Mar 2017 11:29:09 -0400 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Transfer-Encoding: 7bit Message-Id: References: <201703151336.v2FDaZS7057372@repo.freebsd.org> To: "Andrey V. Elsukov" X-Mailer: Apple Mail (2.3259) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 15:29:14 -0000 > On Mar 15, 2017, at 9:36 AM, Andrey V. Elsukov wrote: > > Author: ae > Date: Wed Mar 15 13:36:35 2017 > New Revision: 315305 > URL: https://svnweb.freebsd.org/changeset/base/315305 > > Log: > Change the syntax of ipfw's named states. > > Since the state name is an optional argument, it often can conflict > with other options. To avoid ambiguity now the state name must be > prefixed with a colon. > > Obtained from: Yandex LLC > MFC after: 2 week > Sponsored by: Yandex LLC Relnotes: yes probably? Matteo From owner-svn-src-all@freebsd.org Wed Mar 15 15:32:37 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AF292D09957; Wed, 15 Mar 2017 15:32:37 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward3p.cmail.yandex.net (forward3p.cmail.yandex.net [77.88.31.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "forwards.mail.yandex.net", Issuer "Yandex CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 30DAF13E5; Wed, 15 Mar 2017 15:32:36 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from smtp1j.mail.yandex.net (smtp1j.mail.yandex.net [95.108.130.59]) by forward3p.cmail.yandex.net (Yandex) with ESMTP id 6319C210F8; Wed, 15 Mar 2017 18:32:27 +0300 (MSK) Received: from smtp1j.mail.yandex.net (localhost.localdomain [127.0.0.1]) by smtp1j.mail.yandex.net (Yandex) with ESMTP id 9A7AC3C811EA; Wed, 15 Mar 2017 18:32:25 +0300 (MSK) Received: by smtp1j.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id 4FznoTKe1Y-WOv4sXMd; Wed, 15 Mar 2017 18:32:24 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1489591944; bh=SMeWseCQCdlXg0eDCYTeIGb5wYgpM+HZkPvCVlc2xJQ=; h=Subject:To:References:Cc:From:Message-ID:Date:In-Reply-To; b=oBsN84rdKc7kK1pQlVovmQugLXAl7n5QbGUxH1entUqFoLF9m24A2+al3LiqUOT45 qtZP7/P+4QpUY0+ft7ARH0b+3SOTTOIkOBsyK9YWe/gMcvhcxgxM/xWxOs7jIWa+zl 8DQU6ImR1c6yTAJU/grOdDvpPfIFS1lSalPyC7cE= Authentication-Results: smtp1j.mail.yandex.net; dkim=pass header.i=@yandex.ru X-Yandex-Suid-Status: 1 0,1 0,1 0,1 0 Subject: Re: svn commit: r315305 - in head: . sbin/ipfw To: Matteo Riondato References: <201703151336.v2FDaZS7057372@repo.freebsd.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: "Andrey V. Elsukov" Openpgp: id=E6591E1B41DA1516F0C9BC0001C5EA0410C8A17A Message-ID: <1042672b-34a8-b1c8-8f13-41df69e4e785@yandex.ru> Date: Wed, 15 Mar 2017 18:30:47 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ESx8axnUSswliu3gL4CeaXkJIM0TPwmwF" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 15:32:37 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --ESx8axnUSswliu3gL4CeaXkJIM0TPwmwF Content-Type: multipart/mixed; boundary="JX6fxCjr3k1ITuLgMJdFSNfUdE13s9EL7"; protected-headers="v1" From: "Andrey V. Elsukov" To: Matteo Riondato Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-ID: <1042672b-34a8-b1c8-8f13-41df69e4e785@yandex.ru> Subject: Re: svn commit: r315305 - in head: . sbin/ipfw References: <201703151336.v2FDaZS7057372@repo.freebsd.org> In-Reply-To: --JX6fxCjr3k1ITuLgMJdFSNfUdE13s9EL7 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 15.03.2017 18:29, Matteo Riondato wrote: >=20 >> On Mar 15, 2017, at 9:36 AM, Andrey V. Elsukov wrote:= >> >> Author: ae >> Date: Wed Mar 15 13:36:35 2017 >> New Revision: 315305 >> URL: https://svnweb.freebsd.org/changeset/base/315305 >> >> Log: >> Change the syntax of ipfw's named states. >> >> Since the state name is an optional argument, it often can conflict >> with other options. To avoid ambiguity now the state name must be >> prefixed with a colon. >> >> Obtained from: Yandex LLC >> MFC after: 2 week >> Sponsored by: Yandex LLC >=20 > Relnotes: yes Named states was not merged into stable/11 yet, so I think the description from r303018 is still suitable for relnotes. --=20 WBR, Andrey V. Elsukov --JX6fxCjr3k1ITuLgMJdFSNfUdE13s9EL7-- --ESx8axnUSswliu3gL4CeaXkJIM0TPwmwF Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEzBAEBCAAdFiEE5lkeG0HaFRbwybwAAcXqBBDIoXoFAljJXicACgkQAcXqBBDI oXprqggAh+cqfLhyJrWYPD6B3ogKG4hTL1rxDfy6lfwhZi755Cub3vl5UNr236eg 8MzJcKTgiz2/pV6+qBednkyht4d/iWI6u3z5VB/SpjXh2i5I0dU/JQB4zRDMvKRN 7MJNH3JcIqLKBbwu5/9mxqKGCEnbVK2nXdPB5Ric9ALJHQrlAJFmiB8zir0NAy2A iFxNFl/VrYgMRL94dQB8Mpc7Xb/yzhPPNpD8XZ4gQyOuRa+gNEoYEZSOLk5eIoKH oLfkLp8aLdOVxMIP1mNuTSF4PfBCA2TDonRtmuwrXUuxn6V3EIDSFsdxfSkFreHL +uT9zMTBVkKGnzqj+xQtDRRxv3e9pw== =jo5y -----END PGP SIGNATURE----- --ESx8axnUSswliu3gL4CeaXkJIM0TPwmwF-- From owner-svn-src-all@freebsd.org Wed Mar 15 15:33:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E3900D099F1; Wed, 15 Mar 2017 15:33:33 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BB79B15ED; Wed, 15 Mar 2017 15:33:33 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FFXWC1013224; Wed, 15 Mar 2017 15:33:32 GMT (envelope-from pfg@FreeBSD.org) Received: (from pfg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FFXWIV013220; Wed, 15 Mar 2017 15:33:32 GMT (envelope-from pfg@FreeBSD.org) Message-Id: <201703151533.v2FFXWIV013220@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pfg set sender to pfg@FreeBSD.org using -f From: "Pedro F. Giffuni" Date: Wed, 15 Mar 2017 15:33:32 +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: r315308 - in stable/11/lib/libc: gen iconv stdlib X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 15:33:34 -0000 Author: pfg Date: Wed Mar 15 15:33:32 2017 New Revision: 315308 URL: https://svnweb.freebsd.org/changeset/base/315308 Log: MFC r315095, r315096, r315097, r315187: libc: small cleanups. Rename nitems to numitems: it shares the anme with an existing macro in sys/params.h. Also initialize the value later which avoids asigning the value if we exit early. Unsign setlen: it is local and will never be negative. Having one more bit for growth is beneficial and it avoids a cast when it's going to be used for allocation. Remove unused initialization: "num" is properly defined before use. Let calloc(3) do the multiplication. Modified: stable/11/lib/libc/gen/scandir.c stable/11/lib/libc/gen/setmode.c stable/11/lib/libc/iconv/citrus_esdb.c stable/11/lib/libc/stdlib/getenv.c Directory Properties: stable/11/ (props changed) Modified: stable/11/lib/libc/gen/scandir.c ============================================================================== --- stable/11/lib/libc/gen/scandir.c Wed Mar 15 14:58:29 2017 (r315307) +++ stable/11/lib/libc/gen/scandir.c Wed Mar 15 15:33:32 2017 (r315308) @@ -82,7 +82,7 @@ scandir(const char *dirname, struct dire #endif { struct dirent *d, *p, **names = NULL; - size_t nitems = 0; + size_t numitems; long arraysz; DIR *dirp; @@ -94,6 +94,7 @@ scandir(const char *dirname, struct dire if (names == NULL) goto fail; + numitems = 0; while ((d = readdir(dirp)) != NULL) { if (select != NULL && !SELECT(d)) continue; /* just selected names */ @@ -112,7 +113,7 @@ scandir(const char *dirname, struct dire * Check to make sure the array has space left and * realloc the maximum size. */ - if (nitems >= arraysz) { + if (numitems >= arraysz) { struct dirent **names2; names2 = (struct dirent **)realloc((char *)names, @@ -124,22 +125,22 @@ scandir(const char *dirname, struct dire names = names2; arraysz *= 2; } - names[nitems++] = p; + names[numitems++] = p; } closedir(dirp); - if (nitems && dcomp != NULL) + if (numitems && dcomp != NULL) #ifdef I_AM_SCANDIR_B - qsort_b(names, nitems, sizeof(struct dirent *), (void*)dcomp); + qsort_b(names, numitems, sizeof(struct dirent *), (void*)dcomp); #else - qsort_r(names, nitems, sizeof(struct dirent *), + qsort_r(names, numitems, sizeof(struct dirent *), &dcomp, alphasort_thunk); #endif *namelist = names; - return (nitems); + return (numitems); fail: - while (nitems > 0) - free(names[--nitems]); + while (numitems > 0) + free(names[--numitems]); free(names); closedir(dirp); return (-1); Modified: stable/11/lib/libc/gen/setmode.c ============================================================================== --- stable/11/lib/libc/gen/setmode.c Wed Mar 15 14:58:29 2017 (r315307) +++ stable/11/lib/libc/gen/setmode.c Wed Mar 15 15:33:32 2017 (r315308) @@ -175,7 +175,7 @@ setmode(const char *p) mode_t mask, perm, permXbits, who; long perml; int equalopdone; - int setlen; + u_int setlen; if (!*p) { errno = EINVAL; @@ -190,7 +190,7 @@ setmode(const char *p) setlen = SET_LEN + 2; - if ((set = malloc((u_int)(sizeof(BITCMD) * setlen))) == NULL) + if ((set = malloc(setlen * sizeof(BITCMD))) == NULL) return (NULL); saveset = set; endset = set + (setlen - 2); Modified: stable/11/lib/libc/iconv/citrus_esdb.c ============================================================================== --- stable/11/lib/libc/iconv/citrus_esdb.c Wed Mar 15 14:58:29 2017 (r315307) +++ stable/11/lib/libc/iconv/citrus_esdb.c Wed Mar 15 15:33:32 2017 (r315308) @@ -263,8 +263,6 @@ _citrus_esdb_get_list(char ***rlist, siz size_t num; int ret; - num = 0; - ret = _lookup_seq_open(&cla, _PATH_ESDB "/" ESDB_ALIAS, _LOOKUP_CASE_IGNORE); if (ret) Modified: stable/11/lib/libc/stdlib/getenv.c ============================================================================== --- stable/11/lib/libc/stdlib/getenv.c Wed Mar 15 14:58:29 2017 (r315307) +++ stable/11/lib/libc/stdlib/getenv.c Wed Mar 15 15:33:32 2017 (r315308) @@ -342,7 +342,7 @@ __build_env(void) envVarsSize = envVarsTotal * 2; /* Create new environment. */ - envVars = calloc(1, sizeof (*envVars) * envVarsSize); + envVars = calloc(envVarsSize, sizeof(*envVars)); if (envVars == NULL) goto Failure; From owner-svn-src-all@freebsd.org Wed Mar 15 15:57:13 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 38EECD0D456; Wed, 15 Mar 2017 15:57:13 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 05EAE14E3; Wed, 15 Mar 2017 15:57:12 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FFvCxe021386; Wed, 15 Mar 2017 15:57:12 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FFvCYS021385; Wed, 15 Mar 2017 15:57:12 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703151557.v2FFvCYS021385@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Wed, 15 Mar 2017 15:57:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315309 - head/usr.bin/lam X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 15:57:13 -0000 Author: bapt Date: Wed Mar 15 15:57:11 2017 New Revision: 315309 URL: https://svnweb.freebsd.org/changeset/base/315309 Log: Do not die on system built without CAPSICUM Modified: head/usr.bin/lam/lam.c Modified: head/usr.bin/lam/lam.c ============================================================================== --- head/usr.bin/lam/lam.c Wed Mar 15 15:33:32 2017 (r315308) +++ head/usr.bin/lam/lam.c Wed Mar 15 15:57:11 2017 (r315309) @@ -134,7 +134,8 @@ getargs(char *av[]) else if ((ip->fp = fopen(p, "r")) == NULL) { err(1, "%s", p); } - if (cap_rights_limit(fileno(ip->fp), &rights_ro) < 0) + if (cap_rights_limit(fileno(ip->fp), &rights_ro) < 0 + && errno != ENOSYS) err(1, "unable to limit rights on: %s", p); ip->pad = P; if (!ip->sepstring) From owner-svn-src-all@freebsd.org Wed Mar 15 16:13:54 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 194DED0DAAC; Wed, 15 Mar 2017 16:13:54 +0000 (UTC) (envelope-from maxim@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 DCE7F1FBB; Wed, 15 Mar 2017 16:13:53 +0000 (UTC) (envelope-from maxim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FGDrmq029609; Wed, 15 Mar 2017 16:13:53 GMT (envelope-from maxim@FreeBSD.org) Received: (from maxim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FGDqGW029608; Wed, 15 Mar 2017 16:13:52 GMT (envelope-from maxim@FreeBSD.org) Message-Id: <201703151613.v2FGDqGW029608@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: maxim set sender to maxim@FreeBSD.org using -f From: Maxim Konovalov Date: Wed, 15 Mar 2017 16:13:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315310 - head/lib/libsysdecode X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 16:13:54 -0000 Author: maxim Date: Wed Mar 15 16:13:52 2017 New Revision: 315310 URL: https://svnweb.freebsd.org/changeset/base/315310 Log: Spell "const" properly. PR: 217797 Submitted by: tobik Modified: head/lib/libsysdecode/sysdecode_ioctlname.3 Modified: head/lib/libsysdecode/sysdecode_ioctlname.3 ============================================================================== --- head/lib/libsysdecode/sysdecode_ioctlname.3 Wed Mar 15 15:57:11 2017 (r315309) +++ head/lib/libsysdecode/sysdecode_ioctlname.3 Wed Mar 15 16:13:52 2017 (r315310) @@ -37,7 +37,7 @@ .In sys/types.h .In stdbool.h .In sysdecode.h -.Ft conts char * +.Ft const char * .Fn sysdecode_ioctlname "unsigned long request" .Sh DESCRIPTION The From owner-svn-src-all@freebsd.org Wed Mar 15 16:16:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D7CBED0DC76; Wed, 15 Mar 2017 16:16:31 +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 A4DFC26B; Wed, 15 Mar 2017 16:16:31 +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 v2FGGUBR029775; Wed, 15 Mar 2017 16:16:30 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FGGU8N029774; Wed, 15 Mar 2017 16:16:30 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703151616.v2FGGU8N029774@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 15 Mar 2017 16:16:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315311 - head/usr.sbin/makefs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 16:16:31 -0000 Author: emaste Date: Wed Mar 15 16:16:30 2017 New Revision: 315311 URL: https://svnweb.freebsd.org/changeset/base/315311 Log: makefs: use 'm' for cd9660 allow-multidot, per NetBSD NetBSD revisions: cd9660.c 1.55 Obtained from: NetBSD Modified: head/usr.sbin/makefs/cd9660.c Modified: head/usr.sbin/makefs/cd9660.c ============================================================================== --- head/usr.sbin/makefs/cd9660.c Wed Mar 15 16:13:52 2017 (r315310) +++ head/usr.sbin/makefs/cd9660.c Wed Mar 15 16:16:30 2017 (r315311) @@ -291,7 +291,7 @@ cd9660_prep_opts(fsinfo_t *fsopts) "Allow 37 char filenames (unimplemented)"), OPT_BOOL('i', "allow-illegal-chars", allow_illegal_chars, "Allow illegal characters in filenames"), - OPT_BOOL('d', "allow-multidot", allow_multidot, + OPT_BOOL('m', "allow-multidot", allow_multidot, "Allow multiple periods in filenames"), OPT_BOOL('o', "omit-trailing-period", omit_trailing_period, "Omit trailing periods in filenames"), From owner-svn-src-all@freebsd.org Wed Mar 15 16:38:41 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F1DEBD0D857; Wed, 15 Mar 2017 16:38:41 +0000 (UTC) (envelope-from dchagin@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 B607E161C; Wed, 15 Mar 2017 16:38:41 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FGceq4038051; Wed, 15 Mar 2017 16:38:40 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FGcdOK038038; Wed, 15 Mar 2017 16:38:39 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703151638.v2FGcdOK038038@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Wed, 15 Mar 2017 16:38:39 +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: r315312 - in stable/11/sys: compat/cloudabi compat/linux dev/iscsi_initiator kern netinet sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 16:38:42 -0000 Author: dchagin Date: Wed Mar 15 16:38:39 2017 New Revision: 315312 URL: https://svnweb.freebsd.org/changeset/base/315312 Log: MFC r305093 (by mjg@): fd: add fdeget_locked and use in kern_descrip MFC r305756 (by oshogbo@): fd: add fget_cap and fget_cap_locked primitives. They can be used to obtain capabilities along with a referenced fp. MFC r306174 (by oshogbo@): capsicum: propagate rights on accept(2) Descriptor returned by accept(2) should inherits capabilities rights from the listening socket. PR: 201052 MFC r306184 (by oshogbo@): fd: simplify fgetvp_rights by using fget_cap_locked. MFC r306225 (by mjg@): fd: fix up fgetvp_rights after r306184 fget_cap_locked returns a referenced file, but the fgetvp_rights does not need it. Instead, due to the filedesc lock being held, it can ref the vnode after the file was looked up. Fix up fget_cap_locked to be consistent with other _locked helpers and not ref the file. This plugs a leak introduced in r306184. MFC r306232 (by oshogbo@): fd: fix up fget_cap If the kernel is not compiled with the CAPABILITIES kernel options fget_unlocked doesn't return the sequence number so fd_modify will always report modification, in that case we got infinity loop. MFC r311474 (by glebius@): Use getsock_cap() instead of fgetsock(). MFC r312079 (by glebius@): Use getsock_cap() instead of deprecated fgetsock(). MFC r312081 (by glebius@): Use getsock_cap() instead of deprecated fgetsock(). MFC r312087 (by glebius@): Remove deprecated fgetsock() and fputsock(). Bump __FreeBSD_version as getsock_cap changed and fgetsock/fputsock pair removed. Modified: stable/11/sys/compat/cloudabi/cloudabi_sock.c stable/11/sys/compat/linux/linux_socket.c stable/11/sys/dev/iscsi_initiator/isc_soc.c stable/11/sys/dev/iscsi_initiator/iscsi.c stable/11/sys/kern/kern_descrip.c stable/11/sys/kern/kern_sendfile.c stable/11/sys/kern/uipc_syscalls.c stable/11/sys/netinet/sctp_syscalls.c stable/11/sys/sys/file.h stable/11/sys/sys/filedesc.h stable/11/sys/sys/param.h stable/11/sys/sys/socketvar.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/cloudabi/cloudabi_sock.c ============================================================================== --- stable/11/sys/compat/cloudabi/cloudabi_sock.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/compat/cloudabi/cloudabi_sock.c Wed Mar 15 16:38:39 2017 (r315312) @@ -210,7 +210,7 @@ cloudabi_sys_sock_stat_get(struct thread int error; error = getsock_cap(td, uap->sock, cap_rights_init(&rights, - CAP_GETSOCKOPT, CAP_GETPEERNAME, CAP_GETSOCKNAME), &fp, NULL); + CAP_GETSOCKOPT, CAP_GETPEERNAME, CAP_GETSOCKNAME), &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; Modified: stable/11/sys/compat/linux/linux_socket.c ============================================================================== --- stable/11/sys/compat/linux/linux_socket.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/compat/linux/linux_socket.c Wed Mar 15 16:38:39 2017 (r315312) @@ -775,6 +775,7 @@ linux_connect(struct thread *td, struct cap_rights_t rights; struct socket *so; struct sockaddr *sa; + struct file *fp; u_int fflag; int error; @@ -792,24 +793,23 @@ linux_connect(struct thread *td, struct * Linux doesn't return EISCONN the first time it occurs, * when on a non-blocking socket. Instead it returns the * error getsockopt(SOL_SOCKET, SO_ERROR) would return on BSD. - * - * XXXRW: Instead of using fgetsock(), check that it is a - * socket and use the file descriptor reference instead of - * creating a new one. */ - error = fgetsock(td, args->s, cap_rights_init(&rights, CAP_CONNECT), - &so, &fflag); - if (error == 0) { - error = EISCONN; - if (fflag & FNONBLOCK) { - SOCK_LOCK(so); - if (so->so_emuldata == 0) - error = so->so_error; - so->so_emuldata = (void *)1; - SOCK_UNLOCK(so); - } - fputsock(so); + error = getsock_cap(td, args->s, cap_rights_init(&rights, CAP_CONNECT), + &fp, &fflag, NULL); + if (error != 0) + return (error); + + error = EISCONN; + so = fp->f_data; + if (fflag & FNONBLOCK) { + SOCK_LOCK(so); + if (so->so_emuldata == 0) + error = so->so_error; + so->so_emuldata = (void *)1; + SOCK_UNLOCK(so); } + fdrop(fp, td); + return (error); } @@ -855,7 +855,7 @@ linux_accept_common(struct thread *td, i if (error == EFAULT && namelen != sizeof(struct sockaddr_in)) return (EINVAL); if (error == EINVAL) { - error1 = getsock_cap(td, s, &rights, &fp, NULL); + error1 = getsock_cap(td, s, &rights, &fp, NULL, NULL); if (error1 != 0) return (error1); so = fp->f_data; Modified: stable/11/sys/dev/iscsi_initiator/isc_soc.c ============================================================================== --- stable/11/sys/dev/iscsi_initiator/isc_soc.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/dev/iscsi_initiator/isc_soc.c Wed Mar 15 16:38:39 2017 (r315312) @@ -680,7 +680,6 @@ isc_stop_receiver(isc_session_t *sp) if(sp->fp != NULL) fdrop(sp->fp, sp->td); - fputsock(sp->soc); sp->soc = NULL; sp->fp = NULL; Modified: stable/11/sys/dev/iscsi_initiator/iscsi.c ============================================================================== --- stable/11/sys/dev/iscsi_initiator/iscsi.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/dev/iscsi_initiator/iscsi.c Wed Mar 15 16:38:39 2017 (r315312) @@ -388,20 +388,14 @@ i_setsoc(isc_session_t *sp, int fd, stru if(sp->soc != NULL) isc_stop_receiver(sp); - error = fget(td, fd, cap_rights_init(&rights, CAP_SOCK_CLIENT), &sp->fp); + error = getsock_cap(td, fd, cap_rights_init(&rights, CAP_SOCK_CLIENT), + &sp->fp, NULL, NULL); if(error) return error; - error = fgetsock(td, fd, cap_rights_init(&rights, CAP_SOCK_CLIENT), - &sp->soc, 0); - if(error == 0) { - sp->td = td; - isc_start_receiver(sp); - } - else { - fdrop(sp->fp, td); - sp->fp = NULL; - } + sp->soc = sp->fp->f_data; + sp->td = td; + isc_start_receiver(sp); return error; } Modified: stable/11/sys/kern/kern_descrip.c ============================================================================== --- stable/11/sys/kern/kern_descrip.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/kern/kern_descrip.c Wed Mar 15 16:38:39 2017 (r315312) @@ -67,7 +67,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include #include @@ -517,28 +516,26 @@ kern_fcntl(struct thread *td, int fd, in break; case F_GETFD: + error = EBADF; FILEDESC_SLOCK(fdp); - if (fget_locked(fdp, fd) == NULL) { - FILEDESC_SUNLOCK(fdp); - error = EBADF; - break; + fde = fdeget_locked(fdp, fd); + if (fde != NULL) { + td->td_retval[0] = + (fde->fde_flags & UF_EXCLOSE) ? FD_CLOEXEC : 0; + error = 0; } - fde = &fdp->fd_ofiles[fd]; - td->td_retval[0] = - (fde->fde_flags & UF_EXCLOSE) ? FD_CLOEXEC : 0; FILEDESC_SUNLOCK(fdp); break; case F_SETFD: + error = EBADF; FILEDESC_XLOCK(fdp); - if (fget_locked(fdp, fd) == NULL) { - FILEDESC_XUNLOCK(fdp); - error = EBADF; - break; + fde = fdeget_locked(fdp, fd); + if (fde != NULL) { + fde->fde_flags = (fde->fde_flags & ~UF_EXCLOSE) | + (arg & FD_CLOEXEC ? UF_EXCLOSE : 0); + error = 0; } - fde = &fdp->fd_ofiles[fd]; - fde->fde_flags = (fde->fde_flags & ~UF_EXCLOSE) | - (arg & FD_CLOEXEC ? UF_EXCLOSE : 0); FILEDESC_XUNLOCK(fdp); break; @@ -2450,6 +2447,82 @@ finit(struct file *fp, u_int flag, short } int +fget_cap_locked(struct filedesc *fdp, int fd, cap_rights_t *needrightsp, + struct file **fpp, struct filecaps *havecapsp) +{ + struct filedescent *fde; + int error; + + FILEDESC_LOCK_ASSERT(fdp); + + fde = fdeget_locked(fdp, fd); + if (fde == NULL) { + error = EBADF; + goto out; + } + +#ifdef CAPABILITIES + error = cap_check(cap_rights_fde(fde), needrightsp); + if (error != 0) + goto out; +#endif + + if (havecapsp != NULL) + filecaps_copy(&fde->fde_caps, havecapsp, true); + + *fpp = fde->fde_file; + + error = 0; +out: + return (error); +} + +int +fget_cap(struct thread *td, int fd, cap_rights_t *needrightsp, + struct file **fpp, struct filecaps *havecapsp) +{ + struct filedesc *fdp = td->td_proc->p_fd; + int error; +#ifndef CAPABILITIES + error = fget_unlocked(fdp, fd, needrightsp, fpp, NULL); + if (error == 0 && havecapsp != NULL) + filecaps_fill(havecapsp); +#else + struct file *fp; + seq_t seq; + + for (;;) { + error = fget_unlocked(fdp, fd, needrightsp, &fp, &seq); + if (error != 0) + return (error); + + if (havecapsp != NULL) { + if (!filecaps_copy(&fdp->fd_ofiles[fd].fde_caps, + havecapsp, false)) { + fdrop(fp, td); + goto get_locked; + } + } + + if (!fd_modified(fdp, fd, seq)) + break; + fdrop(fp, td); + } + + *fpp = fp; + return (0); + +get_locked: + FILEDESC_SLOCK(fdp); + error = fget_cap_locked(fdp, fd, needrightsp, fpp, havecapsp); + if (error == 0) + fhold(*fpp); + FILEDESC_SUNLOCK(fdp); +#endif + return (error); +} + +int fget_unlocked(struct filedesc *fdp, int fd, cap_rights_t *needrightsp, struct file **fpp, seq_t *seqp) { @@ -2712,30 +2785,31 @@ fgetvp_rights(struct thread *td, int fd, struct filecaps *havecaps, struct vnode **vpp) { struct filedesc *fdp; + struct filecaps caps; struct file *fp; -#ifdef CAPABILITIES int error; -#endif fdp = td->td_proc->p_fd; - fp = fget_locked(fdp, fd); - if (fp == NULL || fp->f_ops == &badfileops) - return (EBADF); - -#ifdef CAPABILITIES - error = cap_check(cap_rights(fdp, fd), needrightsp); + error = fget_cap_locked(fdp, fd, needrightsp, &fp, &caps); if (error != 0) return (error); -#endif - - if (fp->f_vnode == NULL) - return (EINVAL); + if (fp->f_ops == &badfileops) { + error = EBADF; + goto out; + } + if (fp->f_vnode == NULL) { + error = EINVAL; + goto out; + } + *havecaps = caps; *vpp = fp->f_vnode; vrefact(*vpp); - filecaps_copy(&fdp->fd_ofiles[fd].fde_caps, havecaps, true); return (0); +out: + filecaps_free(&caps); + return (error); } int @@ -2763,61 +2837,6 @@ fgetvp_write(struct thread *td, int fd, #endif /* - * Like fget() but loads the underlying socket, or returns an error if the - * descriptor does not represent a socket. - * - * We bump the ref count on the returned socket. XXX Also obtain the SX lock - * in the future. - * - * Note: fgetsock() and fputsock() are deprecated, as consumers should rely - * on their file descriptor reference to prevent the socket from being free'd - * during use. - */ -int -fgetsock(struct thread *td, int fd, cap_rights_t *rightsp, struct socket **spp, - u_int *fflagp) -{ - struct file *fp; - int error; - - *spp = NULL; - if (fflagp != NULL) - *fflagp = 0; - if ((error = _fget(td, fd, &fp, 0, rightsp, NULL)) != 0) - return (error); - if (fp->f_type != DTYPE_SOCKET) { - error = ENOTSOCK; - } else { - *spp = fp->f_data; - if (fflagp) - *fflagp = fp->f_flag; - SOCK_LOCK(*spp); - soref(*spp); - SOCK_UNLOCK(*spp); - } - fdrop(fp, td); - - return (error); -} - -/* - * Drop the reference count on the socket and XXX release the SX lock in the - * future. The last reference closes the socket. - * - * Note: fputsock() is deprecated, see comment for fgetsock(). - */ -void -fputsock(struct socket *so) -{ - - ACCEPT_LOCK(); - SOCK_LOCK(so); - CURVNET_SET(so->so_vnet); - sorele(so); - CURVNET_RESTORE(); -} - -/* * Handle the last reference to a file being closed. */ int Modified: stable/11/sys/kern/kern_sendfile.c ============================================================================== --- stable/11/sys/kern/kern_sendfile.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/kern/kern_sendfile.c Wed Mar 15 16:38:39 2017 (r315312) @@ -502,7 +502,7 @@ sendfile_getsock(struct thread *td, int * The socket must be a stream socket and connected. */ error = getsock_cap(td, s, cap_rights_init(&rights, CAP_SEND), - sock_fp, NULL); + sock_fp, NULL, NULL); if (error != 0) return (error); *so = (*sock_fp)->f_data; Modified: stable/11/sys/kern/uipc_syscalls.c ============================================================================== --- stable/11/sys/kern/uipc_syscalls.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/kern/uipc_syscalls.c Wed Mar 15 16:38:39 2017 (r315312) @@ -89,20 +89,23 @@ static int sockargs(struct mbuf **, char /* * Convert a user file descriptor to a kernel file entry and check if required * capability rights are present. + * If required copy of current set of capability rights is returned. * A reference on the file entry is held upon returning. */ int getsock_cap(struct thread *td, int fd, cap_rights_t *rightsp, - struct file **fpp, u_int *fflagp) + struct file **fpp, u_int *fflagp, struct filecaps *havecapsp) { struct file *fp; int error; - error = fget_unlocked(td->td_proc->p_fd, fd, rightsp, &fp, NULL); + error = fget_cap(td, fd, rightsp, &fp, havecapsp); if (error != 0) return (error); if (fp->f_type != DTYPE_SOCKET) { fdrop(fp, td); + if (havecapsp != NULL) + filecaps_free(havecapsp); return (ENOTSOCK); } if (fflagp != NULL) @@ -201,7 +204,7 @@ kern_bindat(struct thread *td, int dirfd AUDIT_ARG_FD(fd); AUDIT_ARG_SOCKADDR(td, dirfd, sa); error = getsock_cap(td, fd, cap_rights_init(&rights, CAP_BIND), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; @@ -262,7 +265,7 @@ sys_listen(td, uap) AUDIT_ARG_FD(uap->s); error = getsock_cap(td, uap->s, cap_rights_init(&rights, CAP_LISTEN), - &fp, NULL); + &fp, NULL, NULL); if (error == 0) { so = fp->f_data; #ifdef MAC @@ -335,6 +338,7 @@ kern_accept4(struct thread *td, int s, s struct file *headfp, *nfp = NULL; struct sockaddr *sa = NULL; struct socket *head, *so; + struct filecaps fcaps; cap_rights_t rights; u_int fflag; pid_t pgid; @@ -345,7 +349,7 @@ kern_accept4(struct thread *td, int s, s AUDIT_ARG_FD(s); error = getsock_cap(td, s, cap_rights_init(&rights, CAP_ACCEPT), - &headfp, &fflag); + &headfp, &fflag, &fcaps); if (error != 0) return (error); head = headfp->f_data; @@ -358,7 +362,8 @@ kern_accept4(struct thread *td, int s, s if (error != 0) goto done; #endif - error = falloc(td, &nfp, &fd, (flags & SOCK_CLOEXEC) ? O_CLOEXEC : 0); + error = falloc_caps(td, &nfp, &fd, + (flags & SOCK_CLOEXEC) ? O_CLOEXEC : 0, &fcaps); if (error != 0) goto done; ACCEPT_LOCK(); @@ -467,6 +472,8 @@ noconnection: * a reference on nfp to the caller on success if they request it. */ done: + if (nfp == NULL) + filecaps_free(&fcaps); if (fp != NULL) { if (error == 0) { *fp = nfp; @@ -545,7 +552,7 @@ kern_connectat(struct thread *td, int di AUDIT_ARG_FD(fd); AUDIT_ARG_SOCKADDR(td, dirfd, sa); error = getsock_cap(td, fd, cap_rights_init(&rights, CAP_CONNECT), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; @@ -805,7 +812,7 @@ kern_sendit(td, s, mp, flags, control, s AUDIT_ARG_SOCKADDR(td, AT_FDCWD, mp->msg_name); cap_rights_set(&rights, CAP_CONNECT); } - error = getsock_cap(td, s, &rights, &fp, NULL); + error = getsock_cap(td, s, &rights, &fp, NULL, NULL); if (error != 0) { m_freem(control); return (error); @@ -1013,7 +1020,7 @@ kern_recvit(td, s, mp, fromseg, controlp AUDIT_ARG_FD(s); error = getsock_cap(td, s, cap_rights_init(&rights, CAP_RECV), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; @@ -1328,7 +1335,7 @@ sys_shutdown(td, uap) AUDIT_ARG_FD(uap->s); error = getsock_cap(td, uap->s, cap_rights_init(&rights, CAP_SHUTDOWN), - &fp, NULL); + &fp, NULL, NULL); if (error == 0) { so = fp->f_data; error = soshutdown(so, uap->how); @@ -1402,7 +1409,7 @@ kern_setsockopt(td, s, level, name, val, AUDIT_ARG_FD(s); error = getsock_cap(td, s, cap_rights_init(&rights, CAP_SETSOCKOPT), - &fp, NULL); + &fp, NULL, NULL); if (error == 0) { so = fp->f_data; error = sosetopt(so, &sopt); @@ -1483,7 +1490,7 @@ kern_getsockopt(td, s, level, name, val, AUDIT_ARG_FD(s); error = getsock_cap(td, s, cap_rights_init(&rights, CAP_GETSOCKOPT), - &fp, NULL); + &fp, NULL, NULL); if (error == 0) { so = fp->f_data; error = sogetopt(so, &sopt); @@ -1544,7 +1551,7 @@ kern_getsockname(struct thread *td, int AUDIT_ARG_FD(fd); error = getsock_cap(td, fd, cap_rights_init(&rights, CAP_GETSOCKNAME), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; @@ -1643,7 +1650,7 @@ kern_getpeername(struct thread *td, int AUDIT_ARG_FD(fd); error = getsock_cap(td, fd, cap_rights_init(&rights, CAP_GETPEERNAME), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); so = fp->f_data; Modified: stable/11/sys/netinet/sctp_syscalls.c ============================================================================== --- stable/11/sys/netinet/sctp_syscalls.c Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/netinet/sctp_syscalls.c Wed Mar 15 16:38:39 2017 (r315312) @@ -121,17 +121,18 @@ sys_sctp_peeloff(td, uap) } */ *uap; { #if (defined(INET) || defined(INET6)) && defined(SCTP) - struct file *nfp = NULL; + struct file *headfp, *nfp = NULL; struct socket *head, *so; cap_rights_t rights; u_int fflag; int error, fd; AUDIT_ARG_FD(uap->sd); - error = fgetsock(td, uap->sd, cap_rights_init(&rights, CAP_PEELOFF), - &head, &fflag); + error = getsock_cap(td, uap->sd, cap_rights_init(&rights, CAP_PEELOFF), + &headfp, &fflag, NULL); if (error != 0) goto done2; + head = headfp->f_data; if (head->so_proto->pr_protocol != IPPROTO_SCTP) { error = EOPNOTSUPP; goto done; @@ -196,7 +197,7 @@ noconnection: done: if (nfp != NULL) fdrop(nfp, td); - fputsock(head); + fdrop(headfp, td); done2: return (error); #else /* SCTP */ @@ -248,7 +249,7 @@ sys_sctp_generic_sendmsg (td, uap) } AUDIT_ARG_FD(uap->sd); - error = getsock_cap(td, uap->sd, &rights, &fp, NULL); + error = getsock_cap(td, uap->sd, &rights, &fp, NULL, NULL); if (error != 0) goto sctp_bad; #ifdef KTRACE @@ -361,7 +362,7 @@ sys_sctp_generic_sendmsg_iov(td, uap) } AUDIT_ARG_FD(uap->sd); - error = getsock_cap(td, uap->sd, &rights, &fp, NULL); + error = getsock_cap(td, uap->sd, &rights, &fp, NULL, NULL); if (error != 0) goto sctp_bad1; @@ -477,7 +478,7 @@ sys_sctp_generic_recvmsg(td, uap) AUDIT_ARG_FD(uap->sd); error = getsock_cap(td, uap->sd, cap_rights_init(&rights, CAP_RECV), - &fp, NULL); + &fp, NULL, NULL); if (error != 0) return (error); #ifdef COMPAT_FREEBSD32 Modified: stable/11/sys/sys/file.h ============================================================================== --- stable/11/sys/sys/file.h Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/sys/file.h Wed Mar 15 16:38:39 2017 (r315312) @@ -50,8 +50,6 @@ struct thread; struct uio; struct knote; struct vnode; -struct socket; - #endif /* _KERNEL */ @@ -268,10 +266,6 @@ int fgetvp_read(struct thread *td, int f int fgetvp_write(struct thread *td, int fd, cap_rights_t *rightsp, struct vnode **vpp); -int fgetsock(struct thread *td, int fd, cap_rights_t *rightsp, - struct socket **spp, u_int *fflagp); -void fputsock(struct socket *sp); - static __inline int _fnoop(void) { Modified: stable/11/sys/sys/filedesc.h ============================================================================== --- stable/11/sys/sys/filedesc.h Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/sys/filedesc.h Wed Mar 15 16:38:39 2017 (r315312) @@ -190,6 +190,11 @@ int getvnode(struct thread *td, int fd, struct file **fpp); void mountcheckdirs(struct vnode *olddp, struct vnode *newdp); +int fget_cap_locked(struct filedesc *fdp, int fd, cap_rights_t *needrightsp, + struct file **fpp, struct filecaps *havecapsp); +int fget_cap(struct thread *td, int fd, cap_rights_t *needrightsp, + struct file **fpp, struct filecaps *havecapsp); + /* Return a referenced file from an unlocked descriptor. */ int fget_unlocked(struct filedesc *fdp, int fd, cap_rights_t *needrightsp, struct file **fpp, seq_t *seqp); @@ -207,6 +212,18 @@ fget_locked(struct filedesc *fdp, int fd return (fdp->fd_ofiles[fd].fde_file); } +static __inline struct filedescent * +fdeget_locked(struct filedesc *fdp, int fd) +{ + + FILEDESC_LOCK_ASSERT(fdp); + + if ((u_int)fd > fdp->fd_lastfile) + return (NULL); + + return (&fdp->fd_ofiles[fd]); +} + static __inline bool fd_modified(struct filedesc *fdp, int fd, seq_t seq) { Modified: stable/11/sys/sys/param.h ============================================================================== --- stable/11/sys/sys/param.h Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/sys/param.h Wed Mar 15 16:38:39 2017 (r315312) @@ -58,7 +58,7 @@ * in the range 5 to 9. */ #undef __FreeBSD_version -#define __FreeBSD_version 1100509 /* Master, propagated to newvers */ +#define __FreeBSD_version 1100510 /* Master, propagated to newvers */ /* * __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD, Modified: stable/11/sys/sys/socketvar.h ============================================================================== --- stable/11/sys/sys/socketvar.h Wed Mar 15 16:16:30 2017 (r315311) +++ stable/11/sys/sys/socketvar.h Wed Mar 15 16:38:39 2017 (r315312) @@ -321,6 +321,7 @@ extern u_long sb_max; extern so_gen_t so_gencnt; struct file; +struct filecaps; struct filedesc; struct mbuf; struct sockaddr; @@ -340,7 +341,7 @@ struct uio; */ int getsockaddr(struct sockaddr **namp, caddr_t uaddr, size_t len); int getsock_cap(struct thread *td, int fd, cap_rights_t *rightsp, - struct file **fpp, u_int *fflagp); + struct file **fpp, u_int *fflagp, struct filecaps *havecaps); void soabort(struct socket *so); int soaccept(struct socket *so, struct sockaddr **nam); void soaio_enqueue(struct task *task); From owner-svn-src-all@freebsd.org Wed Mar 15 17:06:05 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB1D7D0E34C; Wed, 15 Mar 2017 17:06:05 +0000 (UTC) (envelope-from dchagin@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 9BC469E2; Wed, 15 Mar 2017 17:06:05 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FH64aT050316; Wed, 15 Mar 2017 17:06:04 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FH64Tp050315; Wed, 15 Mar 2017 17:06:04 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703151706.v2FH64Tp050315@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Wed, 15 Mar 2017 17:06: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: r315313 - stable/11/sys/compat/linux X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:06:06 -0000 Author: dchagin Date: Wed Mar 15 17:06:04 2017 New Revision: 315313 URL: https://svnweb.freebsd.org/changeset/base/315313 Log: MFC r313913: Initialize cap_rights before use. MFC r313914: Style(9), some XXX comments fix. No functional changes. Modified: stable/11/sys/compat/linux/linux_socket.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/linux/linux_socket.c ============================================================================== --- stable/11/sys/compat/linux/linux_socket.c Wed Mar 15 16:38:39 2017 (r315312) +++ stable/11/sys/compat/linux/linux_socket.c Wed Mar 15 17:06:04 2017 (r315313) @@ -505,7 +505,7 @@ linux_sa_put(struct osockaddr *osa) * not changed. */ error = copyin(osa, &sa, sizeof(sa.sa_family)); - if (error) + if (error != 0) return (error); bdom = bsd_to_linux_domain(sa.sa_family); @@ -613,7 +613,7 @@ linux_sendit(struct thread *td, int s, s if (mp->msg_name != NULL) { error = linux_getsockaddr(&to, mp->msg_name, mp->msg_namelen); - if (error) + if (error != 0) return (error); mp->msg_name = to; } else @@ -637,7 +637,7 @@ linux_check_hdrincl(struct thread *td, i size_val = sizeof(optval); error = kern_getsockopt(td, s, IPPROTO_IP, IP_HDRINCL, &optval, UIO_SYSSPACE, &size_val); - if (error) + if (error != 0) return (error); return (optval == 0); @@ -759,7 +759,7 @@ linux_bind(struct thread *td, struct lin error = linux_getsockaddr(&sa, PTRIN(args->name), args->namelen); - if (error) + if (error != 0) return (error); error = kern_bindat(td, AT_FDCWD, args->s, sa); @@ -781,7 +781,7 @@ linux_connect(struct thread *td, struct error = linux_getsockaddr(&sa, (struct osockaddr *)PTRIN(args->name), args->namelen); - if (error) + if (error != 0) return (error); error = kern_connectat(td, AT_FDCWD, args->s, sa); @@ -842,20 +842,20 @@ linux_accept_common(struct thread *td, i int error, error1; bsd_args.s = s; - /* XXX: */ bsd_args.name = (struct sockaddr * __restrict)PTRIN(addr); - bsd_args.anamelen = PTRIN(namelen);/* XXX */ + bsd_args.anamelen = PTRIN(namelen); bsd_args.flags = 0; error = linux_set_socket_flags(flags, &bsd_args.flags); if (error != 0) return (error); error = sys_accept4(td, &bsd_args); bsd_to_linux_sockaddr((struct sockaddr *)bsd_args.name); - if (error) { + if (error != 0) { if (error == EFAULT && namelen != sizeof(struct sockaddr_in)) return (EINVAL); if (error == EINVAL) { - error1 = getsock_cap(td, s, &rights, &fp, NULL, NULL); + error1 = getsock_cap(td, s, + cap_rights_init(&rights, CAP_ACCEPT), &fp, NULL, NULL); if (error1 != 0) return (error1); so = fp->f_data; @@ -869,7 +869,7 @@ linux_accept_common(struct thread *td, i } if (addr) error = linux_sa_put(PTRIN(addr)); - if (error) { + if (error != 0) { (void)kern_close(td, td->td_retval[0]); td->td_retval[0] = 0; } @@ -903,12 +903,11 @@ linux_getsockname(struct thread *td, str int error; bsd_args.fdes = args->s; - /* XXX: */ bsd_args.asa = (struct sockaddr * __restrict)PTRIN(args->addr); - bsd_args.alen = PTRIN(args->namelen); /* XXX */ + bsd_args.alen = PTRIN(args->namelen); error = sys_getsockname(td, &bsd_args); bsd_to_linux_sockaddr((struct sockaddr *)bsd_args.asa); - if (error) + if (error != 0) return (error); return (linux_sa_put(PTRIN(args->addr))); } @@ -928,7 +927,7 @@ linux_getpeername(struct thread *td, str bsd_args.alen = (socklen_t *)PTRIN(args->namelen); error = sys_getpeername(td, &bsd_args); bsd_to_linux_sockaddr((struct sockaddr *)bsd_args.asa); - if (error) + if (error != 0) return (error); return (linux_sa_put(PTRIN(args->addr))); } @@ -1425,12 +1424,12 @@ linux_recvmsg_common(struct thread *td, linux_cmsg->cmsg_len = LINUX_CMSG_LEN(datalen); error = copyout(linux_cmsg, outbuf, L_CMSG_HDRSZ); - if (error) + if (error != 0) goto bad; outbuf += L_CMSG_HDRSZ; error = copyout(data, outbuf, datalen); - if (error) + if (error != 0) goto bad; outbuf += LINUX_CMSG_ALIGN(datalen); @@ -1559,7 +1558,7 @@ linux_setsockopt(struct thread *td, stru case SO_SNDTIMEO: error = copyin(PTRIN(args->optval), &linux_tv, sizeof(linux_tv)); - if (error) + if (error != 0) return (error); tv.tv_sec = linux_tv.tv_sec; tv.tv_usec = linux_tv.tv_usec; @@ -1631,7 +1630,7 @@ linux_getsockopt(struct thread *td, stru tv_len = sizeof(tv); error = kern_getsockopt(td, args->s, bsd_args.level, name, &tv, UIO_SYSSPACE, &tv_len); - if (error) + if (error != 0) return (error); linux_tv.tv_sec = tv.tv_sec; linux_tv.tv_usec = tv.tv_usec; @@ -1645,7 +1644,7 @@ linux_getsockopt(struct thread *td, stru xulen = sizeof(xu); error = kern_getsockopt(td, args->s, bsd_args.level, name, &xu, UIO_SYSSPACE, &xulen); - if (error) + if (error != 0) return (error); /* * XXX Use 0 for pid as the FreeBSD does not cache peer pid. @@ -1660,7 +1659,7 @@ linux_getsockopt(struct thread *td, stru len = sizeof(newval); error = kern_getsockopt(td, args->s, bsd_args.level, name, &newval, UIO_SYSSPACE, &len); - if (error) + if (error != 0) return (error); newval = -SV_ABI_ERRNO(td->td_proc, newval); return (copyout(&newval, PTRIN(args->optval), len)); From owner-svn-src-all@freebsd.org Wed Mar 15 17:11:03 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 75D24D0E4F9; Wed, 15 Mar 2017 17:11:03 +0000 (UTC) (envelope-from dchagin@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 38451DC4; Wed, 15 Mar 2017 17:11:03 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHB2gF051351; Wed, 15 Mar 2017 17:11:02 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHB1mg051347; Wed, 15 Mar 2017 17:11:01 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703151711.v2FHB1mg051347@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Wed, 15 Mar 2017 17:11:01 +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: r315314 - in stable/11/sys: amd64/linux amd64/linux32 compat/linux i386/linux X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:11:03 -0000 Author: dchagin Date: Wed Mar 15 17:11:01 2017 New Revision: 315314 URL: https://svnweb.freebsd.org/changeset/base/315314 Log: MFC r313940: Implement rt_tgsigqueueinfo system call used by glibc for pthread_sigqueue(3). Modified: stable/11/sys/amd64/linux/linux_dummy.c stable/11/sys/amd64/linux32/linux32_dummy.c stable/11/sys/compat/linux/linux_signal.c stable/11/sys/i386/linux/linux_dummy.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/amd64/linux/linux_dummy.c ============================================================================== --- stable/11/sys/amd64/linux/linux_dummy.c Wed Mar 15 17:06:04 2017 (r315313) +++ stable/11/sys/amd64/linux/linux_dummy.c Wed Mar 15 17:11:01 2017 (r315314) @@ -112,7 +112,6 @@ DUMMY(timerfd_gettime); DUMMY(signalfd4); DUMMY(inotify_init1); /* linux 2.6.31: */ -DUMMY(rt_tgsigqueueinfo); DUMMY(perf_event_open); /* linux 2.6.38: */ DUMMY(fanotify_init); Modified: stable/11/sys/amd64/linux32/linux32_dummy.c ============================================================================== --- stable/11/sys/amd64/linux32/linux32_dummy.c Wed Mar 15 17:06:04 2017 (r315313) +++ stable/11/sys/amd64/linux32/linux32_dummy.c Wed Mar 15 17:11:01 2017 (r315314) @@ -111,7 +111,6 @@ DUMMY(timerfd_gettime); DUMMY(signalfd4); DUMMY(inotify_init1); /* linux 2.6.31: */ -DUMMY(rt_tgsigqueueinfo); DUMMY(perf_event_open); /* linux 2.6.33: */ DUMMY(fanotify_init); Modified: stable/11/sys/compat/linux/linux_signal.c ============================================================================== --- stable/11/sys/compat/linux/linux_signal.c Wed Mar 15 17:06:04 2017 (r315313) +++ stable/11/sys/compat/linux/linux_signal.c Wed Mar 15 17:11:01 2017 (r315314) @@ -764,3 +764,32 @@ linux_rt_sigqueueinfo(struct thread *td, return (error); } + +int +linux_rt_tgsigqueueinfo(struct thread *td, struct linux_rt_tgsigqueueinfo_args *args) +{ + l_siginfo_t linfo; + struct thread *tds; + ksiginfo_t ksi; + int error; + int sig; + + if (!LINUX_SIG_VALID(args->sig)) + return (EINVAL); + + error = copyin(args->uinfo, &linfo, sizeof(linfo)); + if (error != 0) + return (error); + + if (linfo.lsi_code >= 0) + return (EPERM); + + tds = linux_tdfind(td, args->tid, args->tgid); + if (tds == NULL) + return (ESRCH); + + sig = linux_to_bsd_signal(args->sig); + ksiginfo_init(&ksi); + lsiginfo_to_ksiginfo(&linfo, &ksi, sig); + return (linux_do_tkill(td, tds, &ksi)); +} Modified: stable/11/sys/i386/linux/linux_dummy.c ============================================================================== --- stable/11/sys/i386/linux/linux_dummy.c Wed Mar 15 17:06:04 2017 (r315313) +++ stable/11/sys/i386/linux/linux_dummy.c Wed Mar 15 17:11:01 2017 (r315314) @@ -107,7 +107,6 @@ DUMMY(timerfd_gettime); DUMMY(signalfd4); DUMMY(inotify_init1); /* linux 2.6.31: */ -DUMMY(rt_tgsigqueueinfo); DUMMY(perf_event_open); /* linux 2.6.33: */ DUMMY(fanotify_init); From owner-svn-src-all@freebsd.org Wed Mar 15 17:14:07 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3DBBAD0E6B0; Wed, 15 Mar 2017 17:14:07 +0000 (UTC) (envelope-from dchagin@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 0746011C9; Wed, 15 Mar 2017 17:14:06 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHE6Ju054529; Wed, 15 Mar 2017 17:14:06 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHE6hK054528; Wed, 15 Mar 2017 17:14:06 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703151714.v2FHE6hK054528@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Wed, 15 Mar 2017 17:14: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: r315315 - stable/11/sys/compat/linux X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:14:07 -0000 Author: dchagin Date: Wed Mar 15 17:14:05 2017 New Revision: 315315 URL: https://svnweb.freebsd.org/changeset/base/315315 Log: MFC r314132: Right clock defines specified in linux_timer.h. Get rid of spirious clock defines from linux_misc.h. Modified: stable/11/sys/compat/linux/linux_misc.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/linux/linux_misc.h ============================================================================== --- stable/11/sys/compat/linux/linux_misc.h Wed Mar 15 17:11:01 2017 (r315314) +++ stable/11/sys/compat/linux/linux_misc.h Wed Mar 15 17:14:05 2017 (r315315) @@ -114,13 +114,6 @@ struct l_new_utsname { char domainname[LINUX_MAX_UTSNAME]; }; -#define LINUX_CLOCK_REALTIME 0 -#define LINUX_CLOCK_MONOTONIC 1 -#define LINUX_CLOCK_PROCESS_CPUTIME_ID 2 -#define LINUX_CLOCK_THREAD_CPUTIME_ID 3 -#define LINUX_CLOCK_REALTIME_HR 4 -#define LINUX_CLOCK_MONOTONIC_HR 5 - #define LINUX_UTIME_NOW 0x3FFFFFFF #define LINUX_UTIME_OMIT 0x3FFFFFFE From owner-svn-src-all@freebsd.org Wed Mar 15 17:16:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5CBD0D0E72F; Wed, 15 Mar 2017 17:16:44 +0000 (UTC) (envelope-from dchagin@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 2BE361368; Wed, 15 Mar 2017 17:16:44 +0000 (UTC) (envelope-from dchagin@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHGhwc054688; Wed, 15 Mar 2017 17:16:43 GMT (envelope-from dchagin@FreeBSD.org) Received: (from dchagin@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHGhC7054687; Wed, 15 Mar 2017 17:16:43 GMT (envelope-from dchagin@FreeBSD.org) Message-Id: <201703151716.v2FHGhC7054687@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dchagin set sender to dchagin@FreeBSD.org using -f From: Dmitry Chagin Date: Wed, 15 Mar 2017 17:16:43 +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: r315316 - stable/11/sys/compat/linux X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:16:44 -0000 Author: dchagin Date: Wed Mar 15 17:16:43 2017 New Revision: 315316 URL: https://svnweb.freebsd.org/changeset/base/315316 Log: MFC r314643: Hide Linux socketcall constants under corresponding #ifdef since they are used only in i386 Linuxulator. Modified: stable/11/sys/compat/linux/linux_socket.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/compat/linux/linux_socket.h ============================================================================== --- stable/11/sys/compat/linux/linux_socket.h Wed Mar 15 17:14:05 2017 (r315315) +++ stable/11/sys/compat/linux/linux_socket.h Wed Mar 15 17:16:43 2017 (r315316) @@ -141,7 +141,6 @@ struct l_ucred { }; #if defined(__i386__) || (defined(__amd64__) && defined(COMPAT_LINUX32)) - struct linux_accept_args { register_t s; register_t addr; @@ -150,12 +149,7 @@ struct linux_accept_args { int linux_accept(struct thread *td, struct linux_accept_args *args); -#endif /* __i386__ || (__amd64__ && COMPAT_LINUX32) */ - - - /* Operations for socketcall */ - #define LINUX_SOCKET 1 #define LINUX_BIND 2 #define LINUX_CONNECT 3 @@ -176,6 +170,7 @@ int linux_accept(struct thread *td, stru #define LINUX_ACCEPT4 18 #define LINUX_RECVMMSG 19 #define LINUX_SENDMMSG 20 +#endif /* __i386__ || (__amd64__ && COMPAT_LINUX32) */ /* Socket options */ #define LINUX_IP_TOS 1 From owner-svn-src-all@freebsd.org Wed Mar 15 17:26:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EF538D0EB3A; Wed, 15 Mar 2017 17:26:20 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A273E1BF3; Wed, 15 Mar 2017 17:26:20 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHQJm1058963; Wed, 15 Mar 2017 17:26:19 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHQJs0058962; Wed, 15 Mar 2017 17:26:19 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703151726.v2FHQJs0058962@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 15 Mar 2017 17:26:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315317 - head/usr.sbin/makefs/ffs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:26:21 -0000 Author: emaste Date: Wed Mar 15 17:26:19 2017 New Revision: 315317 URL: https://svnweb.freebsd.org/changeset/base/315317 Log: makefs: don't print pointers in debugging messages NetBSD revisions: ffs/buf.c 1.14 Obtained from: NetBSD Modified: head/usr.sbin/makefs/ffs/buf.c Modified: head/usr.sbin/makefs/ffs/buf.c ============================================================================== --- head/usr.sbin/makefs/ffs/buf.c Wed Mar 15 17:16:43 2017 (r315316) +++ head/usr.sbin/makefs/ffs/buf.c Wed Mar 15 17:26:19 2017 (r315317) @@ -71,13 +71,12 @@ bread(struct vnode *vp, daddr_t blkno, i assert (bpp != NULL); if (debug & DEBUG_BUF_BREAD) - printf("bread: fs %p blkno %lld size %d\n", - fs, (long long)blkno, size); + printf("bread: blkno %lld size %d\n", (long long)blkno, size); *bpp = getblk(vp, blkno, size, 0, 0, 0); offset = (*bpp)->b_blkno * sectorsize; /* XXX */ if (debug & DEBUG_BUF_BREAD) - printf("bread: bp %p blkno %lld offset %lld bcount %ld\n", - (*bpp), (long long)(*bpp)->b_blkno, (long long) offset, + printf("bread: blkno %lld offset %lld bcount %ld\n", + (long long)(*bpp)->b_blkno, (long long) offset, (*bpp)->b_bcount); if (lseek((*bpp)->b_fd, offset, SEEK_SET) == -1) err(1, "bread: lseek %lld (%lld)", @@ -135,8 +134,8 @@ bwrite(struct buf *bp) assert (bp != NULL); offset = bp->b_blkno * sectorsize; /* XXX */ if (debug & DEBUG_BUF_BWRITE) - printf("bwrite: bp %p blkno %lld offset %lld bcount %ld\n", - bp, (long long)bp->b_blkno, (long long) offset, + printf("bwrite: blkno %lld offset %lld bcount %ld\n", + (long long)bp->b_blkno, (long long) offset, bp->b_bcount); if (lseek(bp->b_fd, offset, SEEK_SET) == -1) return (errno); @@ -188,8 +187,7 @@ getblk(struct vnode *vp, daddr_t blkno, blkno += vp->offset; assert (fs != NULL); if (debug & DEBUG_BUF_GETBLK) - printf("getblk: fs %p blkno %lld size %d\n", fs, - (long long)blkno, size); + printf("getblk: blkno %lld size %d\n", (long long)blkno, size); bp = NULL; if (!buftailinitted) { From owner-svn-src-all@freebsd.org Wed Mar 15 17:32:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 78E57D0ECD7; Wed, 15 Mar 2017 17:32:49 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x244.google.com (mail-pf0-x244.google.com [IPv6:2607:f8b0:400e:c00::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4682767; Wed, 15 Mar 2017 17:32:49 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x244.google.com with SMTP id v190so2844471pfb.0; Wed, 15 Mar 2017 10:32:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=Xr4bEeskWwhlLhg5kj2qYBdlAVscsrvBcENDZruWW1I=; b=REf61eeztv4Dmihea86LD+K9+alvaue6lYnGnfZsqsFF+ZHkMP99ybPfDczgcYeyHg iIF7AwcpHKijwesPukzvE60DuGh7BmPkKJHvxEyKmYnfH1KyZtudx4QkxR+8dnU2vFh4 eoGNLD5BrzdoJyKQLeZeK0s56li8D9cLdY1+G1DtTnM3XR3zLNuMa6UYkI59g8vdNoHd IM49/3W79A2rtedC+Ly/Ptg6GNA3Xmiyp3dvJsAyerPasAX94vUuv701IE4sp2ot95ap OhYEiQZetLM3J2uZoIH8F306ZUJKUg5HSmYN2VRay8U5Fyt1oKBS97VaBOeQTWhlonIp 7zbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=Xr4bEeskWwhlLhg5kj2qYBdlAVscsrvBcENDZruWW1I=; b=BlawZFqCdli7BIYPtXVD5aypiptOuMPeCc3NkSIsYuS4pZrfViKWkb+Fd/dFIsl6Kx AMLEVCnyOUSDkclnBupkFktwjkfmUQoFWH0zMocI/tNemaZFXmZBRHqXWRQf/HWDvXeo BNsJfmwxjGoI6/QkLeNufrLfjmNERoK2s+JfE39urkzCajf2ypUXH+eVRv/rgN3PzBX6 Egi3UXsUC3JxwQ0xhv2/6Nj+fxTkD0B0qm17Dgz++NX54iItEcNGtClpABQftqyYAO2R 64VNzL2BekRM57rveNRaAV64kMRM9A+khHmcqn6JtNOC/nuF0HO6vRyIybkePWsxDviI aQwg== X-Gm-Message-State: AFeK/H043Uy6kWNnerye87SdleaEiH/5g3OU4wo0H+ca7poJ3XSS9KS2qqrW0qttIutv9g== X-Received: by 10.98.9.29 with SMTP id e29mr4963965pfd.101.1489599168521; Wed, 15 Mar 2017 10:32:48 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id w123sm5534647pfb.44.2017.03.15.10.32.47 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 10:32:47 -0700 (PDT) Subject: Re: svn commit: r315311 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_E00E9696-BC1A-42F7-B3F0-02F8CE030954"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703151616.v2FGGU8N029774@repo.freebsd.org> Date: Wed, 15 Mar 2017 10:32:46 -0700 Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703151616.v2FGGU8N029774@repo.freebsd.org> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:32:49 -0000 --Apple-Mail=_E00E9696-BC1A-42F7-B3F0-02F8CE030954 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 09:16, Ed Maste wrote: >=20 > Author: emaste > Date: Wed Mar 15 16:16:30 2017 > New Revision: 315311 > URL: https://svnweb.freebsd.org/changeset/base/315311 >=20 > Log: > makefs: use 'm' for cd9660 allow-multidot, per NetBSD >=20 > NetBSD revisions: > cd9660.c 1.55 >=20 > Obtained from: NetBSD Hi Ed, I agree with the change, but doesn=E2=80=99t this break = backwards compatibility in FreeBSD? It also seems like it=E2=80=99s = missing a Relnotes: yes in the commit message (maybe with a bit more = full explanation of what it does). Thanks, -Ngie --Apple-Mail=_E00E9696-BC1A-42F7-B3F0-02F8CE030954 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyXq/AAoJEPWDqSZpMIYVa68QAJo7YzWIQBrWeNJZIkdb7/UY NGQjMx+vge8VWyT6DxJkadap71oOWSRAZMg4AIQ19z+8NxEGpds/rBDTbWn6FP6z NY/hwliOpE4OBnBOM/oFkerpv5l+w5OwsneQAmSNaHwD1u2rDAczo7wEJSDCZQ/4 vc5DAr3d72mNwlLMrWRzVOgYtTxXLaIdE7VLzOw/Wkoa72r3Gn55XXeIrtC/C+/N A3PxlmEGK+aRBzj2w+aF9HqSwx+q1bJZ+8CZ2vcaO2Uz++XutygsvbztcaDTZUQc 6tEDyc9Xy765io1zMV/meTunyldY1NFEiJZla0kgSx6xr9ufssG8/5sHPi1G1IRr 3lFEUoPu6wDQ65cLeaqGRJUFZrfPVyA+KgdmJ4Ir61/CFbJ4NSzXLyx4dfnG0Cwi ZKLGr2uC+w6WGr+IjRVlUrmKsjTxxVUAOng9OrKFvcSSU09ke2JnPdpGsT+hTlaD eL6g8fM2IfApv3qXKfOi8JJ+VOo63TVjw39gI85h3TyMjFyiqxP6O2BtVvY/vYtq 06+gM7ghMmuT4f5pxP8vV5HZcZkxPGEkzwx/aEV/CYA0Z1RKLuesfk9AK7BrqdC6 6HeMLRPPjyPLQeWAQFl7LFXG7JdMx9j3liakrBinyNkM0QaWq1nXu9JyA+E07Xru bARnTpouqZGAmGKKXrNX =XMyJ -----END PGP SIGNATURE----- --Apple-Mail=_E00E9696-BC1A-42F7-B3F0-02F8CE030954-- From owner-svn-src-all@freebsd.org Wed Mar 15 17:34:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CD558D0ED52; Wed, 15 Mar 2017 17:34:34 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x243.google.com (mail-pf0-x243.google.com [IPv6:2607:f8b0:400e:c00::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 9AE701C7; Wed, 15 Mar 2017 17:34:34 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x243.google.com with SMTP id o126so2846547pfb.1; Wed, 15 Mar 2017 10:34:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=vvZUo7Lg0WPsyBJkASxl8fCNvQKgeea7BndV4dX1sNk=; b=HWGc8Cz8CstiYn5KjrmJpAsRLqR5m12N+zZLoHHUN8GGkzHRRSmbDyfVprP4v5TQcG T0H9j2JyJhwQSoaXk8ej22AwblQQ8b/TpyQE9swzIpIKB1KQHzBjDAFG/RiXNp2FSBlY uBeIzYVsdYLq47wtlPjH+tDnm9Cyl5LCrIgn/VSrMekIfIAgokWwttoQEcOr1TyfUyBo /QJQSH/N6pjLOrY7s5PmAREXs1jHjJpyOu0OvxpnfBRgvrFpzH+/y6MXfQD4jo9U4Jdf ebjkJ7mSfEzA+tArO/NGi6h+W2WSChSOPztu7R/ErMhrPxiyOW1fVWo89+UwYFdJgsPU Kptg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=vvZUo7Lg0WPsyBJkASxl8fCNvQKgeea7BndV4dX1sNk=; b=dIoItwwCZvzgNr8yyOyADCUANkmLlhXkTtPzW6KSNTBXwpFLEQ0vpi9Js6qI8IozuD zgcCm2C3LFx68YCnkWPsJnCr/6l0y8ap0jtPsCUGCkGT8vpIEGl9M9aegyGG7OziNnQF HNeLWyI3Qw/J9tB1t4xY1zUC1eRphD9XJzrUD2W/iUG4NAVjYSktrHXG76rkk+yMSEHh CzQP86pOZqZF94Aa5tQdWek7MzpwHsBLbWaLE22OBZ/tqqE77P74dPeslQDDwziA/kLW l3LL5wtDmOJa1m7Thc/U5CUFz9Y99QUIcCv3KjyrfEckn8aB+5WLF2++vmFVn9z+DT9b d+CA== X-Gm-Message-State: AFeK/H22M1I/yQwTcH8Mz7lhA9eBMHENkhoORrhf1Dbem8y0kdu8xQ4gca+KLUo7eFijhA== X-Received: by 10.84.224.131 with SMTP id s3mr6241106plj.162.1489599273951; Wed, 15 Mar 2017 10:34:33 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id x10sm5531430pff.72.2017.03.15.10.34.32 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 10:34:33 -0700 (PDT) Subject: Re: svn commit: r315304 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_F883C7AA-8EA8-4FB6-9269-AC0100AB044C"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703151334.v2FDYqY8057248@repo.freebsd.org> Date: Wed, 15 Mar 2017 10:34:32 -0700 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703151334.v2FDYqY8057248@repo.freebsd.org> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:34:34 -0000 --Apple-Mail=_F883C7AA-8EA8-4FB6-9269-AC0100AB044C Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 06:34, Ed Maste wrote: >=20 > Author: emaste > Date: Wed Mar 15 13:34:51 2017 > New Revision: 315304 > URL: https://svnweb.freebsd.org/changeset/base/315304 >=20 > Log: > makefs: sync option parsing with NetBSD >=20 > - add support for parsing different types; not just int > - homogenize option parsing > - fix single letter parsing > - remove duplicated code >=20 > NetBSD revisions: > cd9660.c 1.36 1.37 1.38 1.41 1.42 1.43 > ffs.c 1.50 1.51 1.52 1.53 1.56 1.57 > makefs.c 1.36 1.37 1.38 1.39 1.40 1.42 1.43 1.44 1.46 > makefs.h 1.28 1.29 1.31 1.32 >=20 > Obtained from: NetBSD > Sponsored by: The FreeBSD Foundation Hi Ed! This probably deserves "Relnotes: yes", because it might change = options (and because =E2=80=94 heck, yes.. good features!). Also, does this need to be MFCed? Thanks, -Ngie --Apple-Mail=_F883C7AA-8EA8-4FB6-9269-AC0100AB044C Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyXsoAAoJEPWDqSZpMIYVcvEP/iBOadHb9+r/Dqb+CJiS9ftf PXMr6wYU10ehRpF7iY+0XTRKaGqgVZvsdr1z8HS9YtVrvJlqUKjA4jBMp1JAD0dv z/+NTe0IAKaVN3C/5h6UIKPlVlepKsBRV/Hu0KftTkZ8VBwpnYafo/Ub09mW6hxY UBx3WrhsJ4Fn0X3iIuWUmh2O7dbWJ2jvlRKj1WX33SlsKVO/si/IkdAkRpdxYZuj lpBRW+zw0pJ/6IJM8RC6qWrjk0St9QyIn4mGv2sw8rl31Z7wKk6SPG3ygA31ghpM uhXQjzDqX4ZaoCqXDiNzVDnMpJumRl88zpoBcGRvXPv2njdizeQo7HvXzv6ykCke HJYz1VVUjGIvzj7G+YHUBa8hoN9ZGFcQKUehprtoMIRxYuf2/FevzAuSsOyG5EtU jGclA9C25sH98+djb+eLq0mLNDHEd1sWp2yX+sTGLvwxu8SxoVDnRFani5FvIKlq KLWWP4h0XYA0fLfPqqB00iXtCDXjjcF+f6MCblRL+CZfi7XZdn6/aMLC2EgbpEZk 4YPq5BuCiNpVskL293WRCcXhYQBVb0UNHrr4CtjTAlYmERrYZ6DphfWWO3XLv+s9 FUJJIciOQiFzUDciwcfPEs1gWKZqW1lxItXV/ftZy6smwj82tEAWzQsi31P/mHLT OGB1nOknJ0aQQPxe/JSV =ZMT+ -----END PGP SIGNATURE----- --Apple-Mail=_F883C7AA-8EA8-4FB6-9269-AC0100AB044C-- From owner-svn-src-all@freebsd.org Wed Mar 15 17:34:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5FD05D0ED8E for ; Wed, 15 Mar 2017 17:34:47 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-it0-x22b.google.com (mail-it0-x22b.google.com [IPv6:2607:f8b0:4001:c0b::22b]) (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 24ACC285 for ; Wed, 15 Mar 2017 17:34:47 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-it0-x22b.google.com with SMTP id w124so53846510itb.1 for ; Wed, 15 Mar 2017 10:34:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=sFEi+OcyHlIjYPrpYTz8tLuCqUCAFj+cF4dWrkNwEME=; b=T3o8Wv7XzkLdNG08RkyYh5XC6FejmYtykph2ub3VYyu0pXn5a83695F19BA6hQ1HaM 7819eJkCbKd075lQR3uBxR+8nOtigNqf0zmudML0T0byp4aKdadAl3wcRCZxPq8bYOUP wLG+zKowOnl4Be4zIFyXIGVyeVebYq9a+glnjtH7FCHXiJ2xZDeP/e8CSyRbqgDzimDk QeFQa2HNpFLxBLvQmXoUmcyb1Xzb223gWxG0QE8iZyIyysYBc7bwN9RscVW/ufthUOPc OcwdS47xBQL0EVSg1NwGj4isUWL90HaTs66Lvq7CY42VhqUd6ByZtJDekZh6xzVe5F2S Htlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=sFEi+OcyHlIjYPrpYTz8tLuCqUCAFj+cF4dWrkNwEME=; b=QDEddqTu0hi10Jg32BAVz7NIOevIjI+ADG+EbHVcKcvmEh6AfM35p3QD5zqMoVxxJf Rh3Q65IAd/nBc009NgAUVjLPkG9GRw3NpJwEanFwRKqfSMOhEhtMiZ/ihCvYp+XIsy57 0ga+zqk5Sfb2ukxu70XiKSahi806jkkMjvnl5BR6jz0KOMotqQAiZJfnve4a0ECXbKCQ SfqC37COUOBZVvPZ3WufpYOru1asaJTSzIp1mjgfWpCHmlfxaR9KVneJaWxjIK6WA34C 6qsihX7PRnswfl6uot8G+VE0c/Ppx7fPGyCUp+IPICPESf8hnib0M2A/Gf14Dz8YpPeG VyQw== X-Gm-Message-State: AFeK/H3w7tNfxvXX/qkjhpSL5TjFX6yo+VYm4EseS++O3JNyIdjZsvZrpkWGghqY8vDQTElAJak8FQuaxj2bMA== X-Received: by 10.36.67.209 with SMTP id s200mr8980004itb.60.1489599286295; Wed, 15 Mar 2017 10:34:46 -0700 (PDT) MIME-Version: 1.0 Sender: wlosh@bsdimp.com Received: by 10.79.134.129 with HTTP; Wed, 15 Mar 2017 10:34:45 -0700 (PDT) X-Originating-IP: [50.253.99.174] In-Reply-To: References: <201703102245.v2AMj7h1088240@repo.freebsd.org> From: Warner Losh Date: Wed, 15 Mar 2017 11:34:45 -0600 X-Google-Sender-Auth: 6Hpcx_2t7iDajNw_G1jxJdiQRW4 Message-ID: Subject: Re: svn commit: r315031 - head/sys/tools/fdt To: Ed Maste Cc: Oleksandr Tymoshenko , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:34:47 -0000 On Wed, Mar 15, 2017 at 8:52 AM, Ed Maste wrote: > On 10 March 2017 at 17:45, Oleksandr Tymoshenko wrote: >> Author: gonzo >> Date: Fri Mar 10 22:45:07 2017 >> New Revision: 315031 >> URL: https://svnweb.freebsd.org/changeset/base/315031 >> >> Log: >> [fdt] Make DTBs generated by make_dtb.sh overlay-ready > > This breaks WITHOUT_GPL_DTC builds as the BSD dtc does not yet support > -@. I've opened a GitHub issue at > https://github.com/davidchisnall/dtc/issues/15 to track it. The BSD dtc also doesn't support overlays properly, which will we need to allow "shields" to work on the various embedded boards. Warner From owner-svn-src-all@freebsd.org Wed Mar 15 17:36:10 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A47D1D0EE47; Wed, 15 Mar 2017 17:36:10 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x244.google.com (mail-pg0-x244.google.com [IPv6:2607:f8b0:400e:c05::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 71F946CA; Wed, 15 Mar 2017 17:36:10 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x244.google.com with SMTP id y17so2985941pgh.0; Wed, 15 Mar 2017 10:36:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=nNguhS3wUy8L9aLkJzkJ+YwwAvybEV2585CMGW3nI34=; b=WIV+lqs2ybllG72yPl686F+cwGWAJG82NqubyNGsL4qsCCAZss+i3Az99VABVjkJRT Nuf8kcSeQH2uOoCba68b82h5me3Pq0tJRM8SfFnSgzj4M77Y5Sw9Mx3FgVnMAGZtQtnE iyTevTZZTE3Pyb9HL4yRl1JjBBY403ZYU7zs/VFTvWp9v0KBHFXSn1Lb8sc+Zk04nhHr jlNn1UXrHMCc6+GrZuwBB3P9MOZEo+StJ800ZEPCKA+ltMPohQdcSDtwd5axOwaKg8Ke Zicj9DahD91+D3p88aWGaAV3VxiFaO71BZIAHikCbU46EDHqgCSt4ijQqHvURxardGKY QK1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=nNguhS3wUy8L9aLkJzkJ+YwwAvybEV2585CMGW3nI34=; b=cOCs7TkSwdgSsHr6p0hG/ImEbvDDj57YEN4T3Yv7eM7Um9sd/fd+LDLP5YjcViHQZA pDkJQD+izQ9QBY7AIRfKFHNgbFqs/s/DTHzttfdje5b2SCDFrzzCVHli/ac99OItq9Aq v4I4LuEHBfHeeTErKTpOPBHRkD69HELHhkCD957lVE9L9ZGACOrIb3gthRKmZHCKywiu 3SxhirxcTv8CzsCKFJjVf7mcTlz49Pd5qsSPt3ShSI8mVf64C/Ux/cewsiu+Ntj9Kur/ YQoaUVEy2AQTXjBAvKjDw5RMogbsQosmh6G5t+5dbtSMDuzW8f+8YwITA3ueGi28eeX5 pk9w== X-Gm-Message-State: AFeK/H0fAO5mvaY9f723W9be5tXdg2q/lHhlUf/z4M62CUuSkOi3Unda6/HWRbg2XCIIRA== X-Received: by 10.99.167.9 with SMTP id d9mr4954485pgf.19.1489599369748; Wed, 15 Mar 2017 10:36:09 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id s20sm5556470pfg.11.2017.03.15.10.36.08 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 10:36:09 -0700 (PDT) Subject: Re: svn commit: r315298 - head/sys/dev/isp Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_6136B0C2-8C11-45D0-B0C1-F879A7130BC1"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <201703151033.v2FAXi1p079760@repo.freebsd.org> Date: Wed, 15 Mar 2017 10:36:08 -0700 Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Message-Id: References: <201703151033.v2FAXi1p079760@repo.freebsd.org> To: Alexander Motin X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:36:10 -0000 --Apple-Mail=_6136B0C2-8C11-45D0-B0C1-F879A7130BC1 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 03:33, Alexander Motin wrote: >=20 > Author: mav > Date: Wed Mar 15 10:33:44 2017 > New Revision: 315298 > URL: https://svnweb.freebsd.org/changeset/base/315298 >=20 > Log: > Fix ancient bug from r84597, which broke 23xx after r315234. To someone purely reading the commit messages, this doesn=E2=80=99= t describe what the bug was. Could you please expound on it? Thanks! -Ngie --Apple-Mail=_6136B0C2-8C11-45D0-B0C1-F879A7130BC1 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIbBAEBCgAGBQJYyXuIAAoJEPWDqSZpMIYVKNEP+KYViUdpSSkByaqzeCAEKl5o 9BNoIDvF4yMdl2sWkVksvGRlg2Yi+dinTrWao4/LnFtDcPAmjoUV3cMutyObEmzX lG/yxF7UJOzZuPyC/Ycab4pXcqHs0knt8jO2c2qJvMv4GHTTJaEmej7SrRWyK1p0 tn4dQVkgHK0GEsxKBG+rCyW2zrIIGPDUquCei54WNkNnHKNQGFnLAD/DE04CGDGx DLpWa6PKh0CSvoEjzp49Vnu5t355qNmQkgs9JsgpqDb9Mudl05U8Ad+E1dKsIQUV NTEiIzfHY2xCGMARNfldhRx7ZGOnqKdDviwgRz+gn7kWyjyuEaFfK5TQjTLCgBe6 cTjWs73RUTF2XsvbGpviiquJ0NMSP3qR1c24bn62ihixvjczfjASh2WSAPAe6ATn WXvqeKLppmL2y3HmYViglYziVy6koIx3ylHXgTAmW+GlntAr0JtEggtVIfNdo3lU RaeRDRnf35/0RKz6qh564ok5NgoSTms06nug/eFyHdnCKXbIw4jJCP6cuyDEb7Hp VuIy1UDmw+gvPu4/Iq03atC9XUWTxZ66NIZg26+8nKFTlji2qRL/FrOEmRdRCMGq dpHT9DWpMZDRAikxZaQ4CqBffcSF9VaYUfR194d4eX5UvkwzmoKVyzzAGzyMrLlh 2N2q/6iL7P0UZzwrhNw= =zbgU -----END PGP SIGNATURE----- --Apple-Mail=_6136B0C2-8C11-45D0-B0C1-F879A7130BC1-- From owner-svn-src-all@freebsd.org Wed Mar 15 17:39:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 97C01D0EEEF; Wed, 15 Mar 2017 17:39:49 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from mail-wr0-x243.google.com (mail-wr0-x243.google.com [IPv6:2a00:1450:400c:c0c::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3E06D8FB; Wed, 15 Mar 2017 17:39:49 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: by mail-wr0-x243.google.com with SMTP id u108so2914291wrb.2; Wed, 15 Mar 2017 10:39:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=qR3RRWxQfoL7Ibu+XE1PyjSW9pmEUOQb9kd1OdIMy+c=; b=G15pxUSf8+PToW/gssu4JotWK+YWs8QjhQjuY2ix0fA/tl/OSLiTnApiA0B33Cpz7i MggNwyzF/qSE3BCyPaX8BQmJBn7RI5aXCPN8c0n4AG9OZh0AWOt6v8UeiBNJWOPPmyeR 4Wdq5PgipMaSf4LneCfMFXf1pVEu5NloapOK1+xykBmDnuklYhZID7TybtDioCQPFfQG jk9D6Pxo2RJAYRkAmbBGvcC6/Vq1+JJaa2JsSMDgdej23ZCGxo0WzZVHkEQBp/s4YGlh javZCX+HnvhpKIVTIh6+q0Y+BVtFDhOSvRF7YvAlgCSXohXWuisizOgOhROqwZCadJyF Ce6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:references:cc:from:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=qR3RRWxQfoL7Ibu+XE1PyjSW9pmEUOQb9kd1OdIMy+c=; b=Ey34UPaQFYWZ35QRCYIksYDYD1nNJ6RW26EVv2xgH6Nm3/nukVH6JyafL6YVb58QfB wk2feQUkHEwbp+JVfYHHVoSMz0RCS58G5aGvzendxYbDbVNxuxzpO6RJM33qZR+Uaw4T gylVkmbFPTpHVp7wkm3BquxRKYBomFthAnCwiFVK3NmZPiAoPQagS9SS1NH0wLnmvUAI U39+tia2ljCEsid9QP5HNgzGza04TJP+H97QCovwnze1Bgez5DLN3l5b6P/wmkVA6kH3 9tt9s3st+ZC5R21gm9ZFAkP++01Iw9y85ASb8abgp9k866gzupfc44kpirlT1CTdJjrm VcAA== X-Gm-Message-State: AFeK/H26sJ+OojOLObv9bRs/bqxK6XpGJ8KZ1ykFmnNRThi7WQiKEMMDlHdZQOJqHDkCXA== X-Received: by 10.223.135.109 with SMTP id 42mr4536795wrz.141.1489599587361; Wed, 15 Mar 2017 10:39:47 -0700 (PDT) Received: from spectre.mavhome.dp.ua ([134.249.139.101]) by smtp.gmail.com with ESMTPSA id j80sm1276345wmd.14.2017.03.15.10.39.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 15 Mar 2017 10:39:46 -0700 (PDT) Sender: Alexander Motin Subject: Re: svn commit: r315298 - head/sys/dev/isp To: "Ngie Cooper (yaneurabeya)" References: <201703151033.v2FAXi1p079760@repo.freebsd.org> Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org From: Alexander Motin Message-ID: Date: Wed, 15 Mar 2017 19:39:45 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:39:49 -0000 On 15.03.2017 19:36, Ngie Cooper (yaneurabeya) wrote: >> On Mar 15, 2017, at 03:33, Alexander Motin wrote: >> Author: mav >> Date: Wed Mar 15 10:33:44 2017 >> New Revision: 315298 >> URL: https://svnweb.freebsd.org/changeset/base/315298 >> >> Log: >> Fix ancient bug from r84597, which broke 23xx after r315234. > > To someone purely reading the commit messages, this doesn’t describe what the bug was. Could you please expound on it? This trivial one line change. Braces in expression were put in wrong place, that caused wrong register to be read. -- Alexander Motin From owner-svn-src-all@freebsd.org Wed Mar 15 17:43:47 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 22668D0D0A2; Wed, 15 Mar 2017 17:43:47 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E36B9CF1; Wed, 15 Mar 2017 17:43:46 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHhjBW066659; Wed, 15 Mar 2017 17:43:45 GMT (envelope-from alc@FreeBSD.org) Received: (from alc@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHhjLn066656; Wed, 15 Mar 2017 17:43:45 GMT (envelope-from alc@FreeBSD.org) Message-Id: <201703151743.v2FHhjLn066656@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: alc set sender to alc@FreeBSD.org using -f From: Alan Cox Date: Wed, 15 Mar 2017 17:43:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315318 - in head/sys: kern vm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:43:47 -0000 Author: alc Date: Wed Mar 15 17:43:45 2017 New Revision: 315318 URL: https://svnweb.freebsd.org/changeset/base/315318 Log: Relax the locking requirements for vm_object_page_noreuse(). While reviewing all uses of OFF_TO_IDX(), I observed that vm_object_page_noreuse() is requiring an exclusive lock on the object when, in fact, a shared lock suffices. Reviewed by: kib, markj MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D10011 Modified: head/sys/kern/vfs_default.c head/sys/vm/vm_object.c Modified: head/sys/kern/vfs_default.c ============================================================================== --- head/sys/kern/vfs_default.c Wed Mar 15 17:26:19 2017 (r315317) +++ head/sys/kern/vfs_default.c Wed Mar 15 17:43:45 2017 (r315318) @@ -1100,10 +1100,10 @@ vop_stdadvise(struct vop_advise_args *ap if (vp->v_object != NULL) { start = trunc_page(ap->a_start); end = round_page(ap->a_end); - VM_OBJECT_WLOCK(vp->v_object); + VM_OBJECT_RLOCK(vp->v_object); vm_object_page_noreuse(vp->v_object, OFF_TO_IDX(start), OFF_TO_IDX(end)); - VM_OBJECT_WUNLOCK(vp->v_object); + VM_OBJECT_RUNLOCK(vp->v_object); } bo = &vp->v_bufobj; Modified: head/sys/vm/vm_object.c ============================================================================== --- head/sys/vm/vm_object.c Wed Mar 15 17:26:19 2017 (r315317) +++ head/sys/vm/vm_object.c Wed Mar 15 17:43:45 2017 (r315318) @@ -1978,7 +1978,7 @@ vm_object_page_noreuse(vm_object_t objec struct mtx *mtx, *new_mtx; vm_page_t p, next; - VM_OBJECT_ASSERT_WLOCKED(object); + VM_OBJECT_ASSERT_LOCKED(object); KASSERT((object->flags & (OBJ_FICTITIOUS | OBJ_UNMANAGED)) == 0, ("vm_object_page_noreuse: illegal object %p", object)); if (object->resident_page_count == 0) From owner-svn-src-all@freebsd.org Wed Mar 15 17:54:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 44E00D0D398; Wed, 15 Mar 2017 17:54:49 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 13E811320; Wed, 15 Mar 2017 17:54:49 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FHsmWX071299; Wed, 15 Mar 2017 17:54:48 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FHsm8j071298; Wed, 15 Mar 2017 17:54:48 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703151754.v2FHsm8j071298@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Wed, 15 Mar 2017 17:54:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315319 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:54:49 -0000 Author: ngie Date: Wed Mar 15 17:54:47 2017 New Revision: 315319 URL: https://svnweb.freebsd.org/changeset/base/315319 Log: diff(1): sort long options under -D example in SYNOPSYS Sponsored by: Dell EMC Isilon Modified: head/usr.bin/diff/diff.1 Modified: head/usr.bin/diff/diff.1 ============================================================================== --- head/usr.bin/diff/diff.1 Wed Mar 15 17:43:45 2017 (r315318) +++ head/usr.bin/diff/diff.1 Wed Mar 15 17:54:47 2017 (r315319) @@ -30,7 +30,7 @@ .\" @(#)diff.1 8.1 (Berkeley) 6/30/93 .\" $FreeBSD$ .\" -.Dd March 11, 2017 +.Dd March 15, 2017 .Dt DIFF 1 .Os .Sh NAME @@ -79,8 +79,8 @@ .Op Fl -ignore-case .Op Fl -no-ignore-case .Op Fl -normal -.Op Fl -tabsize .Op Fl -strip-trailing-cr +.Op Fl -tabsize .Fl U Ar number .Ar file1 file2 .Nm diff From owner-svn-src-all@freebsd.org Wed Mar 15 17:59:30 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 47CB6D0D46D; Wed, 15 Mar 2017 17:59:30 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: from mail-ot0-x233.google.com (mail-ot0-x233.google.com [IPv6:2607:f8b0:4003:c0f::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 15CEF1588; Wed, 15 Mar 2017 17:59:30 +0000 (UTC) (envelope-from bjkfbsd@gmail.com) Received: by mail-ot0-x233.google.com with SMTP id x37so27775310ota.2; Wed, 15 Mar 2017 10:59:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=JPen19aQ+S6AwjZ8vzodPaRUI17C8y8SPoTBYxhRwr0=; b=AeZWma2u5bY9SboLbGy1rw8XbSFCIF1spVqkqfoZQYriYkAYxDcrc7P3Xv+MsiwJy3 P/U+6DdZ4FRzYvqMpP/XKa69+e+Ea6yIQr3mHA2LjaHqtkgzw4x+3QWNdz7IYE90VTHg xaF0HZ9JZ4d3C/LWbludM0ptuybJh/f8wweby+Idf1iJArI5TcAJBUvBp9gVIaSGQMqk EHV5Sa3+Fq1TXG9NmecfrXMLe5zP5+lUCEhde9ixr6rUBQDShQC8Fdnocz+THL2LySu2 7F8aOo3IIUgj82865JlbJQ2eWWqkG3B69t/ONMNqa13CcxCK+BEMHB76XNopY4kKKUF4 i0Vg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=JPen19aQ+S6AwjZ8vzodPaRUI17C8y8SPoTBYxhRwr0=; b=NGXXS2yAoriP0SpfLpM8xdh5ovU+eChawbdNT6JM3rDBLd/DejogMwgKp++1Mtyg5h wY7+eoRb1JtHN370RQl/m5TlVpkfKJHxNobAUrLpo3bV1Ole+1ypjLv+14UNf6vspPoG IIuYzR6ipuaL2U6rZ4cx79yQKvOmfrziY6RWT0hbUJxqfygFtDbMww+2iFmbWT5GUMdM vBN3v53gi+BMcpTB9nbeRCNdrZ+khMMd2lAwYZNsSOELlpXtbimFQQBaRIhv4VisEIJ9 25BsO/CtI+C4D+/faENpWbKu0F6HJlHpOm3Txx0E8qWS49oavFlVOqskqMcLPmdQXmme uISA== X-Gm-Message-State: AFeK/H3ikQpuRUU/vQeG4Cy+ry/ws3kCQ7DdBSQ+Hnda9lj2fgY9vz5rKnZbUovGz9EKzv09s9Hu5qbS17C1IA== X-Received: by 10.202.216.8 with SMTP id p8mr2398857oig.109.1489600768900; Wed, 15 Mar 2017 10:59:28 -0700 (PDT) MIME-Version: 1.0 Received: by 10.182.88.138 with HTTP; Wed, 15 Mar 2017 10:59:28 -0700 (PDT) In-Reply-To: <201703151743.v2FHhjLn066656@repo.freebsd.org> References: <201703151743.v2FHhjLn066656@repo.freebsd.org> From: Benjamin Kaduk Date: Wed, 15 Mar 2017 12:59:28 -0500 Message-ID: Subject: Re: svn commit: r315318 - in head/sys: kern vm To: Alan Cox Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 17:59:30 -0000 Should __FreeBSD_version be bumped, e.g., for out-of-tree filesystems that have custom vop_advise? -Ben On Wed, Mar 15, 2017 at 12:43 PM, Alan Cox wrote: > Author: alc > Date: Wed Mar 15 17:43:45 2017 > New Revision: 315318 > URL: https://svnweb.freebsd.org/changeset/base/315318 > > Log: > Relax the locking requirements for vm_object_page_noreuse(). While > reviewing all uses of OFF_TO_IDX(), I observed that > vm_object_page_noreuse() is requiring an exclusive lock on the object > when, in fact, a shared lock suffices. > > Reviewed by: kib, markj > MFC after: 3 days > Differential Revision: https://reviews.freebsd.org/D10011 > > Modified: > head/sys/kern/vfs_default.c > head/sys/vm/vm_object.c > > Modified: head/sys/kern/vfs_default.c > ============================================================ > ================== > --- head/sys/kern/vfs_default.c Wed Mar 15 17:26:19 2017 (r315317) > +++ head/sys/kern/vfs_default.c Wed Mar 15 17:43:45 2017 (r315318) > @@ -1100,10 +1100,10 @@ vop_stdadvise(struct vop_advise_args *ap > if (vp->v_object != NULL) { > start = trunc_page(ap->a_start); > end = round_page(ap->a_end); > - VM_OBJECT_WLOCK(vp->v_object); > + VM_OBJECT_RLOCK(vp->v_object); > vm_object_page_noreuse(vp->v_object, > OFF_TO_IDX(start), > OFF_TO_IDX(end)); > - VM_OBJECT_WUNLOCK(vp->v_object); > + VM_OBJECT_RUNLOCK(vp->v_object); > } > > bo = &vp->v_bufobj; > > Modified: head/sys/vm/vm_object.c > ============================================================ > ================== > --- head/sys/vm/vm_object.c Wed Mar 15 17:26:19 2017 (r315317) > +++ head/sys/vm/vm_object.c Wed Mar 15 17:43:45 2017 (r315318) > @@ -1978,7 +1978,7 @@ vm_object_page_noreuse(vm_object_t objec > struct mtx *mtx, *new_mtx; > vm_page_t p, next; > > - VM_OBJECT_ASSERT_WLOCKED(object); > + VM_OBJECT_ASSERT_LOCKED(object); > KASSERT((object->flags & (OBJ_FICTITIOUS | OBJ_UNMANAGED)) == 0, > ("vm_object_page_noreuse: illegal object %p", object)); > if (object->resident_page_count == 0) > _______________________________________________ > svn-src-all@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" > From owner-svn-src-all@freebsd.org Wed Mar 15 18:00:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3FA5ED0D675; Wed, 15 Mar 2017 18:00:56 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EEBDD176A; Wed, 15 Mar 2017 18:00:55 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FI0tTm071631; Wed, 15 Mar 2017 18:00:55 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FI0s15071627; Wed, 15 Mar 2017 18:00:54 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703151800.v2FI0s15071627@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Wed, 15 Mar 2017 18:00:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315320 - in head: etc/mtree lib/libcam lib/libcam/tests X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:00:56 -0000 Author: ngie Date: Wed Mar 15 18:00:54 2017 New Revision: 315320 URL: https://svnweb.freebsd.org/changeset/base/315320 Log: Start adding basic tests for cam(3) This change contains several negative and positive tests for: - cam_open_device - cam_close_device - cam_getccb - cam_freeccb This also contains a test for the failure case noted in bug 217649, i.e., O_RDWR must be specified because pass(4) requires it. This test unfortunately cannot assume that cam-capable devices are present, so the user must explicitly provide a device via `test_suites.FreeBSD.cam_test_device`. In the future, a test kernel module might be shipped, or ctl(4) might be used, as a test device when testing out libcam, which will allow the tests to do away with having to specify an explicit test device. Reviewed by: asomers, ken (earlier diff) MFC after: 1 week Sponsored by: Dell EMC Isilon Differential Revision: D9928 Added: head/lib/libcam/tests/ head/lib/libcam/tests/Makefile (contents, props changed) head/lib/libcam/tests/libcam_test.c (contents, props changed) Modified: head/etc/mtree/BSD.tests.dist head/lib/libcam/Makefile Modified: head/etc/mtree/BSD.tests.dist ============================================================================== --- head/etc/mtree/BSD.tests.dist Wed Mar 15 17:54:47 2017 (r315319) +++ head/etc/mtree/BSD.tests.dist Wed Mar 15 18:00:54 2017 (r315320) @@ -310,6 +310,8 @@ ttyio .. .. + libcam + .. libcasper services cap_dns Modified: head/lib/libcam/Makefile ============================================================================== --- head/lib/libcam/Makefile Wed Mar 15 17:54:47 2017 (r315319) +++ head/lib/libcam/Makefile Wed Mar 15 18:00:54 2017 (r315320) @@ -43,4 +43,8 @@ CFLAGS+= -I${.CURDIR} -I${SRCTOP}/sys SHLIB_MAJOR= 7 +.include + +SUBDIR.${MK_TESTS}+= tests + .include Added: head/lib/libcam/tests/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libcam/tests/Makefile Wed Mar 15 18:00:54 2017 (r315320) @@ -0,0 +1,9 @@ +# $FreeBSD$ + +ATF_TESTS_C+= libcam_test + +LIBADD+= cam + +WARNS?= 6 + +.include Added: head/lib/libcam/tests/libcam_test.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/lib/libcam/tests/libcam_test.c Wed Mar 15 18:00:54 2017 (r315320) @@ -0,0 +1,217 @@ +/*- + * Copyright (c) 2017 Ngie Cooper + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#include +#include +#include +#include + +#include + +static const char * +get_cam_test_device(const atf_tc_t *tc) +{ + const char *cam_test_device; + + cam_test_device = atf_tc_get_config_var(tc, "cam_test_device"); + + return (cam_test_device); +} + +static void +cam_clear_error(void) +{ + + strcpy(cam_errbuf, ""); +} + +static bool +cam_has_error(void) +{ + + return (strlen(cam_errbuf) != 0); +} + +ATF_TC(cam_open_device_negative_test_O_RDONLY); +ATF_TC_HEAD(cam_open_device_negative_test_O_RDONLY, tc) +{ + + atf_tc_set_md_var(tc, "descr", + "test that cam_open_device(`cam_device`, O_RDONLY) fails to open " + "the underlying pass(4) device (bug 217649)"); + atf_tc_set_md_var(tc, "require.config", "cam_test_device"); + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_open_device_negative_test_O_RDONLY, tc) +{ + const char *cam_test_device; + + cam_test_device = get_cam_test_device(tc); + + cam_clear_error(); + ATF_CHECK(cam_open_device(cam_test_device, O_RDONLY) == NULL); + ATF_REQUIRE(cam_has_error()); +} + +ATF_TC(cam_open_device_negative_test_nonexistent); +ATF_TC_HEAD(cam_open_device_negative_test_nonexistent, tc) +{ + + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_open_device_negative_test_nonexistent, tc) +{ + + cam_clear_error(); + ATF_REQUIRE(cam_open_device("/nonexistent", O_RDWR) == NULL); + ATF_REQUIRE(cam_has_error()); +} + +ATF_TC(cam_open_device_negative_test_unprivileged); +ATF_TC_HEAD(cam_open_device_negative_test_unprivileged, tc) +{ + + atf_tc_set_md_var(tc, "require.config", "cam_test_device"); + atf_tc_set_md_var(tc, "require.user", "unprivileged"); +} + +ATF_TC_BODY(cam_open_device_negative_test_unprivileged, tc) +{ + const char *cam_test_device; + + cam_test_device = get_cam_test_device(tc); + + cam_clear_error(); + ATF_CHECK(cam_open_device(cam_test_device, O_RDONLY) == NULL); + ATF_REQUIRE(cam_has_error()); + + cam_clear_error(); + ATF_CHECK(cam_open_device(cam_test_device, O_RDWR) == NULL); + ATF_REQUIRE(cam_has_error()); +} + +ATF_TC(cam_open_device_positive_test); +ATF_TC_HEAD(cam_open_device_positive_test, tc) +{ + + atf_tc_set_md_var(tc, "require.config", "cam_test_device"); + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_open_device_positive_test, tc) +{ + struct cam_device *cam_dev; + const char *cam_test_device; + + cam_test_device = get_cam_test_device(tc); + + cam_clear_error(); + cam_dev = cam_open_device(cam_test_device, O_RDWR); + ATF_CHECK_MSG(cam_dev != NULL, "cam_open_device failed: %s", + cam_errbuf); + ATF_REQUIRE(!cam_has_error()); + cam_close_device(cam_dev); +} + +ATF_TC(cam_close_device_negative_test_NULL); +ATF_TC_HEAD(cam_close_device_negative_test_NULL, tc) +{ + + atf_tc_set_md_var(tc, "descr", + "test that cam_close_device(NULL) succeeds without error"); + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_close_device_negative_test_NULL, tc) +{ + + cam_clear_error(); + cam_close_device(NULL); + ATF_REQUIRE(!cam_has_error()); +} + +ATF_TC(cam_getccb_positive_test); +ATF_TC_HEAD(cam_getccb_positive_test, tc) +{ + + atf_tc_set_md_var(tc, "require.config", "cam_test_device"); + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_getccb_positive_test, tc) +{ + union ccb *cam_ccb; + struct cam_device *cam_dev; + const char *cam_test_device; + + cam_test_device = get_cam_test_device(tc); + + cam_clear_error(); + cam_dev = cam_open_device(cam_test_device, O_RDWR); + ATF_CHECK_MSG(cam_dev != NULL, "cam_open_device failed: %s", + cam_errbuf); + ATF_REQUIRE(!cam_has_error()); + cam_ccb = cam_getccb(cam_dev); + ATF_CHECK_MSG(cam_ccb != NULL, "get_camccb failed: %s", cam_errbuf); + ATF_REQUIRE(!cam_has_error()); + cam_freeccb(cam_ccb); + cam_close_device(cam_dev); +} + +ATF_TC(cam_freeccb_negative_test_NULL); +ATF_TC_HEAD(cam_freeccb_negative_test_NULL, tc) +{ + + atf_tc_set_md_var(tc, "descr", + "test that cam_freeccb(NULL) succeeds without error"); + atf_tc_set_md_var(tc, "require.user", "root"); +} + +ATF_TC_BODY(cam_freeccb_negative_test_NULL, tc) +{ + + cam_clear_error(); + cam_freeccb(NULL); + ATF_REQUIRE(!cam_has_error()); +} + +ATF_TP_ADD_TCS(tp) +{ + + ATF_TP_ADD_TC(tp, cam_open_device_negative_test_O_RDONLY); + ATF_TP_ADD_TC(tp, cam_open_device_negative_test_nonexistent); + ATF_TP_ADD_TC(tp, cam_open_device_negative_test_unprivileged); + ATF_TP_ADD_TC(tp, cam_open_device_positive_test); + ATF_TP_ADD_TC(tp, cam_close_device_negative_test_NULL); + ATF_TP_ADD_TC(tp, cam_getccb_positive_test); + ATF_TP_ADD_TC(tp, cam_freeccb_negative_test_NULL); + + return (atf_no_error()); +} From owner-svn-src-all@freebsd.org Wed Mar 15 18:06:34 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6CCD8D0D820; Wed, 15 Mar 2017 18:06:34 +0000 (UTC) (envelope-from alc@rice.edu) Received: from pp1.rice.edu (proofpoint1.mail.rice.edu [128.42.201.100]) (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 489591D1D; Wed, 15 Mar 2017 18:06:33 +0000 (UTC) (envelope-from alc@rice.edu) Received: from pps.filterd (pp1.rice.edu [127.0.0.1]) by pp1.rice.edu (8.16.0.17/8.16.0.17) with SMTP id v2FGPwuv018263; Wed, 15 Mar 2017 13:06:27 -0500 Received: from mh2.mail.rice.edu (mh2.mail.rice.edu [128.42.201.21]) by pp1.rice.edu with ESMTP id 29794h82gg-1; Wed, 15 Mar 2017 13:06:27 -0500 X-Virus-Scanned: by amavis-2.7.0 at mh2.mail.rice.edu, auth channel Received: from 108-254-203-201.lightspeed.hstntx.sbcglobal.net (108-254-203-201.lightspeed.hstntx.sbcglobal.net [108.254.203.201]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) (Authenticated sender: alc) by mh2.mail.rice.edu (Postfix) with ESMTPSA id EBAD350015F; Wed, 15 Mar 2017 13:06:26 -0500 (CDT) Subject: Re: svn commit: r315318 - in head/sys: kern vm To: Benjamin Kaduk , Alan Cox References: <201703151743.v2FHhjLn066656@repo.freebsd.org> Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" From: Alan Cox Message-ID: <4fd159d0-6509-98a9-7af0-6efada1def26@rice.edu> Date: Wed, 15 Mar 2017 13:06:26 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD i386; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=12 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1611190142 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:06:34 -0000 On 03/15/2017 12:59, Benjamin Kaduk wrote: > Should __FreeBSD_version be bumped, e.g., for out-of-tree filesystems > that have custom vop_advise? No, I don't think so. > On Wed, Mar 15, 2017 at 12:43 PM, Alan Cox > wrote: > > Author: alc > Date: Wed Mar 15 17:43:45 2017 > New Revision: 315318 > URL: https://svnweb.freebsd.org/changeset/base/315318 > > > Log: > Relax the locking requirements for vm_object_page_noreuse(). While > reviewing all uses of OFF_TO_IDX(), I observed that > vm_object_page_noreuse() is requiring an exclusive lock on the > object > when, in fact, a shared lock suffices. > > Reviewed by: kib, markj > MFC after: 3 days > Differential Revision: https://reviews.freebsd.org/D10011 > > > Modified: > head/sys/kern/vfs_default.c > head/sys/vm/vm_object.c > > Modified: head/sys/kern/vfs_default.c > ============================================================================== > --- head/sys/kern/vfs_default.c Wed Mar 15 17:26:19 2017 > (r315317) > +++ head/sys/kern/vfs_default.c Wed Mar 15 17:43:45 2017 > (r315318) > @@ -1100,10 +1100,10 @@ vop_stdadvise(struct vop_advise_args *ap > if (vp->v_object != NULL) { > start = trunc_page(ap->a_start); > end = round_page(ap->a_end); > - VM_OBJECT_WLOCK(vp->v_object); > + VM_OBJECT_RLOCK(vp->v_object); > vm_object_page_noreuse(vp->v_object, > OFF_TO_IDX(start), > OFF_TO_IDX(end)); > - VM_OBJECT_WUNLOCK(vp->v_object); > + VM_OBJECT_RUNLOCK(vp->v_object); > } > > bo = &vp->v_bufobj; > > Modified: head/sys/vm/vm_object.c > ============================================================================== > --- head/sys/vm/vm_object.c Wed Mar 15 17:26:19 2017 > (r315317) > +++ head/sys/vm/vm_object.c Wed Mar 15 17:43:45 2017 > (r315318) > @@ -1978,7 +1978,7 @@ vm_object_page_noreuse(vm_object_t objec > struct mtx *mtx, *new_mtx; > vm_page_t p, next; > > - VM_OBJECT_ASSERT_WLOCKED(object); > + VM_OBJECT_ASSERT_LOCKED(object); > KASSERT((object->flags & (OBJ_FICTITIOUS | OBJ_UNMANAGED)) > == 0, > ("vm_object_page_noreuse: illegal object %p", object)); > if (object->resident_page_count == 0) > _______________________________________________ > svn-src-all@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-all > > To unsubscribe, send any mail to > "svn-src-all-unsubscribe@freebsd.org > " > > From owner-svn-src-all@freebsd.org Wed Mar 15 18:14:56 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 79DB8D0DF3B; Wed, 15 Mar 2017 18:14:56 +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 31D1F80C; Wed, 15 Mar 2017 18:14:56 +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 v2FIEtsI079243; Wed, 15 Mar 2017 18:14:55 GMT (envelope-from emaste@FreeBSD.org) Received: (from emaste@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FIEst8079239; Wed, 15 Mar 2017 18:14:54 GMT (envelope-from emaste@FreeBSD.org) Message-Id: <201703151814.v2FIEst8079239@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: emaste set sender to emaste@FreeBSD.org using -f From: Ed Maste Date: Wed, 15 Mar 2017 18:14:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315321 - in head/usr.sbin/makefs: . ffs X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:14:56 -0000 Author: emaste Date: Wed Mar 15 18:14:54 2017 New Revision: 315321 URL: https://svnweb.freebsd.org/changeset/base/315321 Log: makefs: improve error messages - remove \n - use __func__ - err adds the error string itself NetBSD revs: cd9660.c 1.48 1.49 ffs/buf.c 1.21 ffs/mkfs.c 1.27 Obtained from: NetBSD Modified: head/usr.sbin/makefs/cd9660.c head/usr.sbin/makefs/ffs.c head/usr.sbin/makefs/ffs/buf.c head/usr.sbin/makefs/ffs/mkfs.c Modified: head/usr.sbin/makefs/cd9660.c ============================================================================== --- head/usr.sbin/makefs/cd9660.c Wed Mar 15 18:00:54 2017 (r315320) +++ head/usr.sbin/makefs/cd9660.c Wed Mar 15 18:14:54 2017 (r315321) @@ -374,7 +374,7 @@ cd9660_parse_opts(const char *option, fs assert(option != NULL); if (debug & DEBUG_FS_PARSE_OPTS) - printf("cd9660_parse_opts: got `%s'\n", option); + printf("%s: got `%s'\n", __func__, option); i = set_option(cd9660_options, option, buf, sizeof(buf)); if (i == -1) @@ -434,7 +434,7 @@ cd9660_parse_opts(const char *option, fs */ if (buf[0] == '\0') { warnx("The Boot Image Directory parameter" - " requires a directory name\n"); + " requires a directory name"); rv = 0; } else { diskStructure->boot_image_directory = @@ -489,11 +489,11 @@ cd9660_makefs(const char *image, const c iso9660_disk *diskStructure = fsopts->fs_specific; if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: ISO level is %i\n", + printf("%s: ISO level is %i\n", __func__, diskStructure->isoLevel); if (diskStructure->isoLevel < 2 && diskStructure->allow_multidot) - errx(1, "allow-multidot requires iso level of 2\n"); + errx(EXIT_FAILURE, "allow-multidot requires iso level of 2"); assert(image != NULL); assert(dir != NULL); @@ -508,7 +508,7 @@ cd9660_makefs(const char *image, const c } if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: image %s directory %s root %p\n", + printf("%s: image %s directory %s root %p\n", __func__, image, dir, root); /* Set up some constants. Later, these will be defined with options */ @@ -539,13 +539,13 @@ cd9660_makefs(const char *image, const c &numDirectories, &error); if (TAILQ_EMPTY(&real_root->cn_children)) { - errx(1, "cd9660_makefs: converted directory is empty. " - "Tree conversion failed\n"); + errx(EXIT_FAILURE, "%s: converted directory is empty. " + "Tree conversion failed", __func__); } else if (error != 0) { - errx(1, "cd9660_makefs: tree conversion failed\n"); + errx(EXIT_FAILURE, "%s: tree conversion failed", __func__); } else { if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: tree converted\n"); + printf("%s: tree converted\n", __func__); } /* Add the dot and dot dot records */ @@ -554,7 +554,7 @@ cd9660_makefs(const char *image, const c cd9660_setup_root_node(diskStructure); if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: done converting tree\n"); + printf("%s: done converting tree\n", __func__); /* non-SUSP extensions */ if (diskStructure->archimedes_enabled) @@ -578,7 +578,7 @@ cd9660_makefs(const char *image, const c firstAvailableSector = cd9660_setup_boot(diskStructure, firstAvailableSector); if (firstAvailableSector < 0) - errx(1, "setup_boot failed"); + errx(EXIT_FAILURE, "setup_boot failed"); } /* LE first, then BE */ diskStructure->primaryLittleEndianTableSector = firstAvailableSector; @@ -592,8 +592,9 @@ cd9660_makefs(const char *image, const c diskStructure->dataFirstSector = diskStructure->primaryBigEndianTableSector + pathTableSectors; if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: Path table conversion complete. " - "Each table is %i bytes, or %" PRIu64 " sectors.\n", + printf("%s: Path table conversion complete. " + "Each table is %i bytes, or %" PRIu64 " sectors.\n", + __func__, diskStructure->pathTableLength, pathTableSectors); startoffset = diskStructure->sectorSize*diskStructure->dataFirstSector; @@ -621,13 +622,14 @@ cd9660_makefs(const char *image, const c /* Debugging output */ if (diskStructure->verbose_level > 0) { - printf("cd9660_makefs: Sectors 0-15 reserved\n"); - printf("cd9660_makefs: Primary path tables starts in sector %" - PRId64 "\n", diskStructure->primaryLittleEndianTableSector); - printf("cd9660_makefs: File data starts in sector %" - PRId64 "\n", diskStructure->dataFirstSector); - printf("cd9660_makefs: Total sectors: %" - PRId64 "\n", diskStructure->totalSectors); + printf("%s: Sectors 0-15 reserved\n", __func__); + printf("%s: Primary path tables starts in sector %" + PRId64 "\n", __func__, + diskStructure->primaryLittleEndianTableSector); + printf("%s: File data starts in sector %" + PRId64 "\n", __func__, diskStructure->dataFirstSector); + printf("%s: Total sectors: %" + PRId64 "\n", __func__, diskStructure->totalSectors); } /* @@ -649,7 +651,7 @@ cd9660_makefs(const char *image, const c cd9660_free_structure(real_root); if (diskStructure->verbose_level > 0) - printf("cd9660_makefs: done\n"); + printf("%s: done\n", __func__); } /* Generic function pointer - implement later */ @@ -895,8 +897,7 @@ cd9660_translate_node(iso9660_disk *disk { if (node == NULL) { if (diskStructure->verbose_level > 0) - printf("cd9660_translate_node: NULL node passed, " - "returning\n"); + printf("%s: NULL node passed, returning\n", __func__); return 0; } if ((newnode->isoDirRecord = @@ -1270,7 +1271,7 @@ cd9660_count_collisions(cd9660node *copy } #if 0 if ((next = TAILQ_NEXT(iter, cn_next_child)) != NULL) { - printf("cd9660_recurse_on_collision: count is %i \n", count); + printf("%s: count is %i\n", __func__, count); compare = cd9660_compare_filename(iter->isoDirRecord->name, next->isoDirRecord->name); if (compare == 0) { @@ -1393,7 +1394,7 @@ cd9660_convert_structure(iso9660_disk *d * Newer, more efficient method, reduces recursion depth */ if (root == NULL) { - warnx("%s: root is null\n", __func__); + warnx("%s: root is null", __func__); return; } @@ -1629,7 +1630,7 @@ cd9660_compute_full_filename(cd9660node len = snprintf(buf, len, "%s/%s/%s", node->node->root, node->node->path, node->node->name); if (len > CD9660MAXPATH) - errx(1, "Pathname too long."); + errx(EXIT_FAILURE, "Pathname too long."); } /* NEW filename conversion method */ Modified: head/usr.sbin/makefs/ffs.c ============================================================================== --- head/usr.sbin/makefs/ffs.c Wed Mar 15 18:00:54 2017 (r315320) +++ head/usr.sbin/makefs/ffs.c Wed Mar 15 18:14:54 2017 (r315321) @@ -505,7 +505,7 @@ ffs_create_image(const char *image, fsin bufrem = fsopts->size; if (fsopts->sparse) { if (ftruncate(fsopts->fd, bufrem) == -1) { - warn("sparse option disabled.\n"); + warn("sparse option disabled."); fsopts->sparse = 0; } } Modified: head/usr.sbin/makefs/ffs/buf.c ============================================================================== --- head/usr.sbin/makefs/ffs/buf.c Wed Mar 15 18:00:54 2017 (r315320) +++ head/usr.sbin/makefs/ffs/buf.c Wed Mar 15 18:14:54 2017 (r315321) @@ -71,25 +71,26 @@ bread(struct vnode *vp, daddr_t blkno, i assert (bpp != NULL); if (debug & DEBUG_BUF_BREAD) - printf("bread: blkno %lld size %d\n", (long long)blkno, size); + printf("%s: blkno %lld size %d\n", __func__, (long long)blkno, + size); *bpp = getblk(vp, blkno, size, 0, 0, 0); offset = (*bpp)->b_blkno * sectorsize; /* XXX */ if (debug & DEBUG_BUF_BREAD) - printf("bread: blkno %lld offset %lld bcount %ld\n", + printf("%s: blkno %lld offset %lld bcount %ld\n", __func__, (long long)(*bpp)->b_blkno, (long long) offset, (*bpp)->b_bcount); if (lseek((*bpp)->b_fd, offset, SEEK_SET) == -1) - err(1, "bread: lseek %lld (%lld)", + err(1, "%s: lseek %lld (%lld)", __func__, (long long)(*bpp)->b_blkno, (long long)offset); rv = read((*bpp)->b_fd, (*bpp)->b_data, (*bpp)->b_bcount); if (debug & DEBUG_BUF_BREAD) - printf("bread: read %ld (%lld) returned %d\n", + printf("%s: read %ld (%lld) returned %d\n", __func__, (*bpp)->b_bcount, (long long)offset, (int)rv); if (rv == -1) /* read error */ - err(1, "bread: read %ld (%lld) returned %d", + err(1, "%s: read %ld (%lld) returned %d", __func__, (*bpp)->b_bcount, (long long)offset, (int)rv); else if (rv != (*bpp)->b_bcount) /* short read */ - err(1, "bread: read %ld (%lld) returned %d", + err(1, "%s: read %ld (%lld) returned %d", __func__, (*bpp)->b_bcount, (long long)offset, (int)rv); else return (0); Modified: head/usr.sbin/makefs/ffs/mkfs.c ============================================================================== --- head/usr.sbin/makefs/ffs/mkfs.c Wed Mar 15 18:00:54 2017 (r315320) +++ head/usr.sbin/makefs/ffs/mkfs.c Wed Mar 15 18:14:54 2017 (r315321) @@ -778,17 +778,17 @@ ffs_rdfs(daddr_t bno, int size, void *bf offset = bno; offset *= fsopts->sectorsize; if (lseek(fsopts->fd, offset, SEEK_SET) < 0) - err(1, "ffs_rdfs: seek error for sector %lld: %s\n", - (long long)bno, strerror(errno)); + err(1, "%s: seek error for sector %lld", __func__, + (long long)bno); n = read(fsopts->fd, bf, size); if (n == -1) { abort(); - err(1, "ffs_rdfs: read error bno %lld size %d", (long long)bno, - size); + err(1, "%s: read error bno %lld size %d", __func__, + (long long)bno, size); } else if (n != size) - errx(1, "ffs_rdfs: read error for sector %lld: %s\n", - (long long)bno, strerror(errno)); + errx(1, "%s: read error for sector %lld", __func__, + (long long)bno); } /* @@ -803,15 +803,15 @@ ffs_wtfs(daddr_t bno, int size, void *bf offset = bno; offset *= fsopts->sectorsize; if (lseek(fsopts->fd, offset, SEEK_SET) < 0) - err(1, "wtfs: seek error for sector %lld: %s\n", - (long long)bno, strerror(errno)); + err(1, "%s: seek error for sector %lld", __func__, + (long long)bno ); n = write(fsopts->fd, bf, size); if (n == -1) - err(1, "wtfs: write error for sector %lld: %s\n", - (long long)bno, strerror(errno)); + err(1, "%s: write error for sector %lld", __func__, + (long long)bno); else if (n != size) - errx(1, "wtfs: write error for sector %lld: %s\n", - (long long)bno, strerror(errno)); + errx(1, "%s: write error for sector %lld", __func__, + (long long)bno); } @@ -834,5 +834,5 @@ ilog2(int val) for (n = 0; n < sizeof(n) * CHAR_BIT; n++) if (1 << n == val) return (n); - errx(1, "ilog2: %d is not a power of 2\n", val); + errx(1, "%s: %d is not a power of 2", __func__, val); } From owner-svn-src-all@freebsd.org Wed Mar 15 18:15:32 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 3E326D0DFC7; Wed, 15 Mar 2017 18:15:32 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F22E1969; Wed, 15 Mar 2017 18:15:31 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FIFV9b079323; Wed, 15 Mar 2017 18:15:31 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FIFVnH079322; Wed, 15 Mar 2017 18:15:31 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703151815.v2FIFVnH079322@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Wed, 15 Mar 2017 18:15:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315322 - head/usr.sbin/syslogd X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:15:32 -0000 Author: ngie Date: Wed Mar 15 18:15:30 2017 New Revision: 315322 URL: https://svnweb.freebsd.org/changeset/base/315322 Log: syslogd: fix memory leaks in main(..) and allowaddr(..) - main(..): free memory assigned to fdsr before calling die(..). - allowaddr(..): free memory assigned to ap before returning from the function early. Add a `err` goto label to reduce freeaddrinfo/free(ap) logic duplication. MFC after: 1 week X-MFC notes: some of this is dependent on refactoring not MFCed Reported by: clang static analyzer, Coverity CID: 1367750 (ap leakage in allowaddr(..)) Submitted by: Tom Rix Reviewed by: ngie Sponsored by: Dell EMC Isilon, Juniper Differential Revision: D10004 Modified: head/usr.sbin/syslogd/syslogd.c Modified: head/usr.sbin/syslogd/syslogd.c ============================================================================== --- head/usr.sbin/syslogd/syslogd.c Wed Mar 15 18:14:54 2017 (r315321) +++ head/usr.sbin/syslogd/syslogd.c Wed Mar 15 18:15:30 2017 (r315322) @@ -685,8 +685,10 @@ main(int argc, char *argv[]) reapchild(WantReapchild); if (MarkSet) markit(); - if (WantDie) + if (WantDie) { + free(fdsr); die(WantDie); + } bzero(fdsr, howmany(fdsrmax+1, NFDBITS) * sizeof(fd_mask)); @@ -2438,7 +2440,7 @@ allowaddr(char *s) struct allowedpeer *ap; struct servent *se; int masklen = -1; - struct addrinfo hints, *res; + struct addrinfo hints, *res = NULL; #ifdef INET in_addr_t *addrp, *maskp; #endif @@ -2465,8 +2467,9 @@ allowaddr(char *s) ap->port = ntohs(se->s_port); } else { ap->port = strtol(cp1, &cp2, 0); + /* port not numeric */ if (*cp2 != '\0') - return (-1); /* port not numeric */ + goto err; } } else { if ((se = getservbyname("syslog", "udp"))) @@ -2480,7 +2483,7 @@ allowaddr(char *s) strspn(cp1 + 1, "0123456789") == strlen(cp1 + 1)) { *cp1 = '\0'; if ((masklen = atoi(cp1 + 1)) < 0) - return (-1); + goto err; } #ifdef INET6 if (*s == '[') { @@ -2526,8 +2529,7 @@ allowaddr(char *s) /* convert masklen to netmask */ *maskp = htonl(~((1 << (32 - masklen)) - 1)); } else { - freeaddrinfo(res); - return (-1); + goto err; } /* Lose any host bits in the network number. */ *addrp &= *maskp; @@ -2535,10 +2537,9 @@ allowaddr(char *s) #endif #ifdef INET6 case AF_INET6: - if (masklen > 128) { - freeaddrinfo(res); - return (-1); - } + if (masklen > 128) + goto err; + if (masklen < 0) masklen = 128; mask6p = (uint32_t *)&sstosin6(&ap->a_mask)->sin6_addr.s6_addr32[0]; @@ -2559,8 +2560,7 @@ allowaddr(char *s) break; #endif default: - freeaddrinfo(res); - return (-1); + goto err; } freeaddrinfo(res); } else { @@ -2596,7 +2596,13 @@ allowaddr(char *s) printf("port = %d\n", ap->port); } #endif + return (0); +err: + if (res != NULL) + freeaddrinfo(res); + free(ap); + return (-1); } /* From owner-svn-src-all@freebsd.org Wed Mar 15 18:23:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B771ED0E31E; Wed, 15 Mar 2017 18:23:33 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 83DA610B8; Wed, 15 Mar 2017 18:23:33 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FINW5k083380; Wed, 15 Mar 2017 18:23:32 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FINWN9083379; Wed, 15 Mar 2017 18:23:32 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201703151823.v2FINWN9083379@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 15 Mar 2017 18:23:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315323 - head/sys/kern X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:23:33 -0000 Author: jhb Date: Wed Mar 15 18:23:32 2017 New Revision: 315323 URL: https://svnweb.freebsd.org/changeset/base/315323 Log: Use UMA_ALIGN_PTR instead of sizeof(void *) for zone alignment. uma_zcreate()'s alignment argument is supposed to be sizeof(foo) - 1, and uma.h provides a set of helper macros for common types. Passing sizeof(void *) results in all of the members being misaligned triggering unaligned access faults on certain architectures (notably MIPS). Reported by: brooks Obtained from: CheriBSD MFC after: 3 days Sponsored by: DARPA / AFRL Modified: head/sys/kern/vfs_lookup.c Modified: head/sys/kern/vfs_lookup.c ============================================================================== --- head/sys/kern/vfs_lookup.c Wed Mar 15 18:15:30 2017 (r315322) +++ head/sys/kern/vfs_lookup.c Wed Mar 15 18:23:32 2017 (r315323) @@ -153,7 +153,7 @@ nameiinit(void *dummy __unused) namei_zone = uma_zcreate("NAMEI", MAXPATHLEN, NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, 0); nt_zone = uma_zcreate("rentr", sizeof(struct nameicap_tracker), - NULL, NULL, NULL, NULL, sizeof(void *), 0); + NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, 0); getnewvnode("crossmp", NULL, &crossmp_vnodeops, &vp_crossmp); } SYSINIT(vfs, SI_SUB_VFS, SI_ORDER_SECOND, nameiinit, NULL); From owner-svn-src-all@freebsd.org Wed Mar 15 18:33:48 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0BBDCD0E6EB; Wed, 15 Mar 2017 18:33:48 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-it0-x232.google.com (mail-it0-x232.google.com [IPv6:2607:f8b0:4001:c0b::232]) (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 C88961942; Wed, 15 Mar 2017 18:33:47 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-it0-x232.google.com with SMTP id m27so25206771iti.1; Wed, 15 Mar 2017 11:33:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=XwaeQiN6+NsSwLFMRmGA2afeGe+GOto3qD8ulrWwsr4=; b=nepqBHeblzt4yX+PJ/C5BoLN8pamrvPhWUSAQrdPz9lf1GuSTKPtNf/AzImlRIf9YC 7uAQHcY8P3mH0iZ+Z8S/UyUI+zwZixwvCGL/Ca9FdCvS4dRnAF/4Y9xKPkhUuw2Bm4mD ppMj2g6za38TOpA15IQiRaxJQfws67VHmiHJgvxw9EgEIaDIVEFMWTqWd4q7iCt9L8A2 8g7TdqIevcpZofHCVdz44mur781zJ3S3uCk501tL6mL+0Ux8wwhkzowTZQtOY5Eyk0hc joTdGM689+TCNX1b2ZReankyRMxxrhHfI+DOLCxUzcZ7zgiW2dPVKdVoOabCZd1Z+Ux/ 948A== 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=XwaeQiN6+NsSwLFMRmGA2afeGe+GOto3qD8ulrWwsr4=; b=nbJVf7l6m5NHn8z9OrIGLmxHfpk7MoqFTtSimPoJt6pjS5DRqY72PMzHK5MXlWq2aK unU+B8Z+EKuwcgdqoBkAFCcR38Wm3y1B1K48B7WL8w3u8ts5Mgg6MaCgPYCz0UALQa7R P33p+0HZKvysAA2YZqcJCoTgc5fSbqmZtWqA/AeAqlZNe1KPWQ4hm07tTUewb1yGoIGF Bsg10cUdKAo1mcKwtbbfgUxt8msayJnwZ91/la7auMvFPQ2vlHSs1Z51KpBCIdO81jH3 tenLcUx+VnvCtE0KuSy/OZJePzPSh8u7n/DV7ibfVAZhuPjvPFcEoA1RAWxdGd44iqML 7Rpg== X-Gm-Message-State: AFeK/H1M7ooE3bqDwul1tyiYX9jEOHNhrD6t3KfZSwFaQONr57tcEqehpgnpqWXCSpI+JLzP7XkTpap4dla0PQ== X-Received: by 10.36.213.196 with SMTP id a187mr21878731itg.4.1489602827198; Wed, 15 Mar 2017 11:33:47 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.30.209 with HTTP; Wed, 15 Mar 2017 11:33:26 -0700 (PDT) In-Reply-To: References: <201703151616.v2FGGU8N029774@repo.freebsd.org> From: Ed Maste Date: Wed, 15 Mar 2017 14:33:26 -0400 X-Google-Sender-Auth: RyUOzif0ItgyTt7qN46V1BgKbus Message-ID: Subject: Re: svn commit: r315311 - head/usr.sbin/makefs To: "Ngie Cooper (yaneurabeya)" Cc: src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:33:48 -0000 On 15 March 2017 at 13:32, Ngie Cooper (yaneurabeya) wrote: > > Hi Ed, > I agree with the change, but doesn=E2=80=99t this break backwards= compatibility in FreeBSD? Not really: the 'd' option only appeared as of r315304 earlier today. The options are documented in makefs(8), although the single-letter aliases are not. I'll try to work with NetBSD folks to rectify that. From owner-svn-src-all@freebsd.org Wed Mar 15 18:35:48 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33DD0D0E777 for ; Wed, 15 Mar 2017 18:35:48 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-io0-x22b.google.com (mail-io0-x22b.google.com [IPv6:2607:f8b0:4001:c06::22b]) (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 E7C361AED for ; Wed, 15 Mar 2017 18:35:47 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-io0-x22b.google.com with SMTP id f84so26407812ioj.0 for ; Wed, 15 Mar 2017 11:35:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=FpZPJJ+1WC561+aGKER2bfsa7gFzjYfZS+Yo5oBUa/k=; b=tN5WICbd2+gdTwL7sKKrSHmrKrJFB+vfR2iPPa9leQDUSACJ6VywBHCAwdq06BFm77 W1A7OsZfuWzeLPE8VCSEtu5u0T32VPD0P6IVbd9NPkww7QJPfJ59hCIfvMbn8RCtL7/L 1tbK9qgzZFd1M7vVmIYUPKNb8hV0djzvJQsCtCtBT6t2kHzIXcM2fqtMH80wKcjBL/S0 SMacu6RUQNqWULXbs5U+MtJ7+QJ7wehActmR5Iuw/CZUVuZwFzb0sH8NNfhKBWTV2nvS sOi3qMlTsIVq0o1dqx0qlLdunsVMpMdA6GT5sTywm3qW7m1/yBSKb1xx2sChuomYdwZe B7AA== 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=FpZPJJ+1WC561+aGKER2bfsa7gFzjYfZS+Yo5oBUa/k=; b=V60QOLY1EROugYU1IX31owRl6hlAy82xoj2o4Q/i63RJop8gZbXdv1Dtm+iUkk1bVb PI9WBhAPcvwwgannilUmus5rm/nyET0l5+r1KcPO2WDYWyizB8riEDTZ+o+HCC/Xo5ZG 1sBAtNbtZHSSedO7vMd5Unf7uEK179PmUmpFxrmVmNVnSav9Pk8rreozHR0hB7VDiCHn 8y86cln6PJTtPK1BUr0K6w649/vOtVm6CbCjaclyDvdxgW8iOpCdcO5Y6YycI0hSje7B u7ulXmq3FbPWq1m5jsYGwFpY5NPsJhKMeORZO0v6O2BbbfyW0p1/0eyBIj7PYT/Upu7o HHOw== X-Gm-Message-State: AFeK/H0+YjI8ApPbQuW+mQ9BlBuXDWgkDWmU/NQxc7LwW05WX061mifm4aHQmnhW4/I0Zhv12tHCrTM3/dYshQ== X-Received: by 10.107.174.220 with SMTP id n89mr7087707ioo.166.1489602947161; Wed, 15 Mar 2017 11:35:47 -0700 (PDT) MIME-Version: 1.0 Sender: wlosh@bsdimp.com Received: by 10.79.134.129 with HTTP; Wed, 15 Mar 2017 11:35:46 -0700 (PDT) X-Originating-IP: [50.253.99.174] In-Reply-To: References: <201703151616.v2FGGU8N029774@repo.freebsd.org> From: Warner Losh Date: Wed, 15 Mar 2017 12:35:46 -0600 X-Google-Sender-Auth: ZN2xaeYbjIpZ5aI0qZVjZpM0GsI Message-ID: Subject: Re: svn commit: r315311 - head/usr.sbin/makefs To: Ed Maste Cc: "Ngie Cooper (yaneurabeya)" , src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:35:48 -0000 On Wed, Mar 15, 2017 at 12:33 PM, Ed Maste wrote: > On 15 March 2017 at 13:32, Ngie Cooper (yaneurabeya) > wrote: >> >> Hi Ed, >> I agree with the change, but doesn=E2=80=99t this break backward= s compatibility in FreeBSD? > > Not really: the 'd' option only appeared as of r315304 earlier today. > > The options are documented in makefs(8), although the single-letter > aliases are not. I'll try to work with NetBSD folks to rectify that. But I put thousands of hours into my build system that depends on it since you committed it earlier today! Down with incompatibility. :P Warner From owner-svn-src-all@freebsd.org Wed Mar 15 18:36:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4E768D0E85A; Wed, 15 Mar 2017 18:36:58 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x242.google.com (mail-pf0-x242.google.com [IPv6:2607:f8b0:400e:c00::242]) (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 1931B1D3D; Wed, 15 Mar 2017 18:36:58 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x242.google.com with SMTP id x63so2884552pfx.2; Wed, 15 Mar 2017 11:36:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=2iZJdYko0LmrfRcplijceTWX4DO4meZd+DyYb4FCuCo=; b=qjAuHglAaIMRDmiH5iFj7q6XenwlY4HhCV1XQ0atkkLdcUgEJdHf0s5UQM5xvme/z4 G4cKWJK1IT9P4Q2b/SAW6PW5HvfNovw22lvc8fRuZCz+PrjITKwlr310kDPG/xEyhq6C b2kNvRDMx8MPGGVUqgDqXojs2OfA6MZro/7v+qLHQNJzOAXOp6Rdp7PivqTvf+Ofjy5Y t+vPRVFjtYKYDzKn9prYyyEMikIzgE5Z4gFge/1iMrla7eIfK688xrQtuq1ZNvQqX8xG 6DOW9rrQs7E9lH81R1vl5Ilf/0dmr4vuyHruHSWLULhyyhOyC/TSYMFFmEB4Num1+ZlE Z69Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=2iZJdYko0LmrfRcplijceTWX4DO4meZd+DyYb4FCuCo=; b=YTAYxFxjw7TUyQ1SP1ibDAaEFB6vD26os6rD8hsH4H/AXsJo31Ew6m282ct5PrDSMU /M53Zy6JwRN3JX2gFKAMBlav7ahVjs1eLPLx8nsrDFGBVoWez+zD1gAZS8Nzm85w73E+ DasSudSGva7p9MCsWAfuYfCM1hEjYw+kV5Jm71xBMyLJvwWwyn3cwXLSvtdvlGfjtA6j wj1KK8+oz02gqEzzznt1ffZLVHvcBGIsfeJvPdcz6sNkWfl7zBZYhzYPHaHxwqxdvUYW SLVCqfSBmZ4cxNGVnxlSzsriJO3xagjZ6UyVpEUAUlCgtleqwItVUK0gU6Uc3Bu1l2wc hxdA== X-Gm-Message-State: AFeK/H3TVhvOdv3hjKNEYUZbOJPP0+Dt3GxHbVTQzQVCB2nHhJaSudk1VhrrUu/xBBA99Q== X-Received: by 10.98.155.28 with SMTP id r28mr5176275pfd.212.1489603017659; Wed, 15 Mar 2017 11:36:57 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id b14sm5686934pfh.114.2017.03.15.11.36.56 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 11:36:57 -0700 (PDT) Subject: Re: svn commit: r315311 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_E7B1747D-EC0D-41D9-A2F7-49D2F6CC76F9"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Wed, 15 Mar 2017 11:36:56 -0700 Cc: Ed Maste , src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: <149A08DB-44D0-4534-81D6-77DA9F584931@gmail.com> References: <201703151616.v2FGGU8N029774@repo.freebsd.org> To: Warner Losh X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:36:58 -0000 --Apple-Mail=_E7B1747D-EC0D-41D9-A2F7-49D2F6CC76F9 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 11:35, Warner Losh wrote: >=20 > On Wed, Mar 15, 2017 at 12:33 PM, Ed Maste wrote: >> On 15 March 2017 at 13:32, Ngie Cooper (yaneurabeya) >> wrote: >>>=20 >>> Hi Ed, >>> I agree with the change, but doesn=E2=80=99t this break = backwards compatibility in FreeBSD? >>=20 >> Not really: the 'd' option only appeared as of r315304 earlier today. >>=20 >> The options are documented in makefs(8), although the single-letter >> aliases are not. I'll try to work with NetBSD folks to rectify that. >=20 > But I put thousands of hours into my build system that depends on it > since you committed it earlier today! Down with incompatibility. :P Buwahahaha=E2=80=A6 yeah, I totally missed that comment earlier :D. --Apple-Mail=_E7B1747D-EC0D-41D9-A2F7-49D2F6CC76F9 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyYnIAAoJEPWDqSZpMIYVIHwQANPEUIYZtPvjymVzNxecsc7f FQnkxbR2S965etiJIeWjYKxaLC/EYtYvKkPdlU64zCDzv4TWtPHso4Efzab9Egx/ T8d5i7LjCtugLsXMWcy6Ax35vMK3R+qCdlfgDsoI07NWor56KO4eEhwUJKgdf9iR rKJxWh/dXGVbQyPjeV6gND5/cpcHaa6n2SC4ZYuOkSL6Y12eycvz9zQRNnpYCeF4 j+GwY66U+lzIpaocAeNh4oXqBK2uirNImnChK3eN4BGMx1P7+6eW+XbheM4OxRzb Eh4Ib2Kb5Gh4MpmPLM0md4d9Xh9Ss4VnY368qYtQzcNHC0i1yLwL2r5s2a5itKtp 4MQdkkPPJ7xH2eGHh9gKQDTrTVCJbrMhHanPa5MU/OcFQSwknjff6bIMJBVcqZ0/ aYzpCo6kpptnXD2qqmEoy2xznAZ9lbKUQ7eovKg6sIwa/A6vhw9I3Y73NtCHf54o ndxFsXTaGrM48wdcn4Krux5n8lOHDx95PeXe0mhcUzo65nsMkT/d8mihsMCLRvT0 rv7yiFpXze4pDqLURvSbxcbe8nEBfhAjMmMuhSTYrCu/kP+hQmhgAoLzGKlVnCdP 99KGJ+vOJDMGVzRNGWV+2KCgF+zmeJwGxPfVfB3loBpd3zIMwcuhbbHBu6luD9wz uKIts424+NADF2+DrXFH =XHN8 -----END PGP SIGNATURE----- --Apple-Mail=_E7B1747D-EC0D-41D9-A2F7-49D2F6CC76F9-- From owner-svn-src-all@freebsd.org Wed Mar 15 18:38:07 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E1DB7D0E926; Wed, 15 Mar 2017 18:38:07 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io0-x22e.google.com (mail-io0-x22e.google.com [IPv6:2607:f8b0:4001:c06::22e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id AA74B1EC2; Wed, 15 Mar 2017 18:38:07 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io0-x22e.google.com with SMTP id b140so26549878iof.1; Wed, 15 Mar 2017 11:38:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=tptuJsbd22XZpbGs6IssyGzxqMO2rzQmD6GpZk+xOuI=; b=EmnlxqIDgsceOmVqXhodnFcF2juD+W9FpP/1mMLZKYn5k3cqj5J5tmIk9QK6BfufFO BngadAFO1vRp2jJWCUWxNvDNMNJxay4JlrriMiLf3dRnkUF9Ko7JTxeBvP1Sa67t1OMq nokdWnAYObNv3LgzqACTpk7ISCYqBsl/LDQUqpRMjhEjj6SucXUDkHGdNv3Lat3gF/v1 pVgE3827MbRYTpWfuv7LPLk7V++HyrHLn6Ks9JaXrVBa6jEROmPN2dKIYRmmQ/iPRYeb cLTvxc+cOYAXsh+i30zdnD59XJAAkEJ1yZbuVUSeQkZ5BGW7FpruxpraBfIZ6C/m39CR WS8Q== 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=tptuJsbd22XZpbGs6IssyGzxqMO2rzQmD6GpZk+xOuI=; b=gnmfN/I8DgTGTOaMbB0EsSzG0QqeAOFIMFngQPyi8nPd1oFvzn/KhhJEsLsgtEkMKt oK9BunYL8Gy6YBrvDNMOhSRwMwGvWlEufEMvf9oON7Y9t0hC4wjVYIfl4SMwmXjfJPQp NixZGJxPQyjNO16sjbW1kDm8cz8XZXqlNrrvY/NeTARJyMyHZj+55ydHbLNs4ayEpp/2 F/m4Ew0LVQNCYRWI6Q9mIZEnYNQlUfK/QsJXxgBMVVLWollS83CjX8VLfBMjKN6rxVXp EsvTvV+vd/KLJALUFLue06PDtQNNATPOq9ghqQ34HcF/lToYWwrtcvDpKYTBy5LvpxTV frxA== X-Gm-Message-State: AFeK/H2ae+NtxMpEM3+MXT5Kg1h7gOQDKcT2Xjejj97hMKBRUrlO70cLd5pVFsftlrzrP4mgqr9p8fBi5AZWPQ== X-Received: by 10.107.47.102 with SMTP id j99mr6546277ioo.52.1489603087097; Wed, 15 Mar 2017 11:38:07 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.30.209 with HTTP; Wed, 15 Mar 2017 11:37:46 -0700 (PDT) In-Reply-To: References: <201703151334.v2FDYqY8057248@repo.freebsd.org> From: Ed Maste Date: Wed, 15 Mar 2017 14:37:46 -0400 X-Google-Sender-Auth: E0czp3FEm66PlvNnrqfrL4OCmAw Message-ID: Subject: Re: svn commit: r315304 - head/usr.sbin/makefs To: "Ngie Cooper (yaneurabeya)" Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:38:08 -0000 On 15 March 2017 at 13:34, Ngie Cooper (yaneurabeya) wrote: > >> On Mar 15, 2017, at 06:34, Ed Maste wrote: >> >> Author: emaste >> Date: Wed Mar 15 13:34:51 2017 >> New Revision: 315304 >> URL: https://svnweb.freebsd.org/changeset/base/315304 >> >> Log: >> makefs: sync option parsing with NetBSD >> >> - add support for parsing different types; not just int >> - homogenize option parsing >> - fix single letter parsing >> - remove duplicated code >> >> NetBSD revisions: >> cd9660.c 1.36 1.37 1.38 1.41 1.42 1.43 >> ffs.c 1.50 1.51 1.52 1.53 1.56 1.57 >> makefs.c 1.36 1.37 1.38 1.39 1.40 1.42 1.43 1.44 1.46 >> makefs.h 1.28 1.29 1.31 1.32 >> >> Obtained from: NetBSD >> Sponsored by: The FreeBSD Foundation > > Hi Ed! > This probably deserves "Relnotes: yes", because it might change o= ptions (and because =E2=80=94 heck, yes.. good features!). This is largely an internal refactoring without user-facing changes. It mainly moves ad-hoc option parsing in individual filesystems into common code. The only visible effect should be that filesystem-specific options now have a single-letter alias as well. From owner-svn-src-all@freebsd.org Wed Mar 15 18:39:08 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7CE6ED0E9BA; Wed, 15 Mar 2017 18:39:08 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x22f.google.com (mail-pg0-x22f.google.com [IPv6:2607:f8b0:400e:c05::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 48EA88E; Wed, 15 Mar 2017 18:39:08 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x22f.google.com with SMTP id 141so12927468pgd.1; Wed, 15 Mar 2017 11:39:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=qZ+jGYVYDcR9REJpPDuvJm5nKtysmHwctXFdfB//7Eo=; b=iQC6mmuOfw3rTqZUSaOQaS+SR+TYbeHHtw8UU6zAtr6IhHhzw0F0PFi93Fdu8Z55uV MaxxH1d2PYgt6qlWGXRB3eZSZN6l3inRNuuL8f/7p45PhSN2rRW6xiH3WhX+9x8S2S9g 18eRRUJ9TkXpdsW8BXcuw/wgg86/7PSjj0iby7W0xQ8CFMA8a/sARqSHhSLFz6PxVxfK CLIzCc0zDGkfpnJdiKbv1XMsEnijTd87zULBBlAlIYc9CoLhbDmm1Ixxr95vmYQCrNJY 3gRnSqmv9+AXH3cU7OZm26iQswwX7al8Q3OMcZX9n2vv/iaRSnWi6o5344I/p90Md9Qp FJ0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=qZ+jGYVYDcR9REJpPDuvJm5nKtysmHwctXFdfB//7Eo=; b=Hg4vAaNLmPnhDYLT1Djcms04iVE8CtEvWz9xmqUTLH8e3yXxnvsJRM15tnhkQ53oF4 HJYQjbF9j1fK1Et6mu7DvWtJNVOb3yNWJry4uknEiUZIwdzsRAvRaQZRuq/lIHCNzUgG fi4QXK5LR3dOqV245wlfz3VnMqkjSNeyuxwKjvnnzTmvjwGNP69Hzx/kBn5ivTK47EmK qegvcAVyLtrimREW3HIPnxN2N8eSIAT/8PQdHZsL2fVBdsI8a28h/rOv6OG91lxE1jU1 Lpmd1aSyL1vQoVMOMH/5Jqy7Ze4yQ4PCQeCgJAuim6nRX7gbSJPGTNoJEjgVyvGEeqH1 eJRQ== X-Gm-Message-State: AFeK/H26NCbtWkRZptoSOw2o3GqvzFZLsX+WDHNcgFP+K/bN7Nttg3+n6mUPyh4M8yxABw== X-Received: by 10.84.134.164 with SMTP id 33mr6652470plh.116.1489603147561; Wed, 15 Mar 2017 11:39:07 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id h20sm5703982pfh.79.2017.03.15.11.39.06 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 11:39:06 -0700 (PDT) Subject: Re: svn commit: r315311 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_B0E910BB-F81D-4AB4-8338-889F5789671E"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Wed, 15 Mar 2017 11:39:06 -0700 Cc: src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: <9502A8F5-6198-407F-B836-9B6458AC5F3D@gmail.com> References: <201703151616.v2FGGU8N029774@repo.freebsd.org> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:39:08 -0000 --Apple-Mail=_B0E910BB-F81D-4AB4-8338-889F5789671E Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 11:33, Ed Maste wrote: >=20 > On 15 March 2017 at 13:32, Ngie Cooper (yaneurabeya) > wrote: >>=20 >> Hi Ed, >> I agree with the change, but doesn=E2=80=99t this break = backwards compatibility in FreeBSD? >=20 > Not really: the 'd' option only appeared as of r315304 earlier today. >=20 > The options are documented in makefs(8), although the single-letter > aliases are not. I'll try to work with NetBSD folks to rectify that. Lol. Whoops! Didn=E2=80=99t realize the feature just appeared today. Yeah=E2=80=A6 I think I filed a bug, somewhere for improving the = makefs(8) manpage (maybe NetBSD=E2=80=99s GNATS; maybe FreeBSD = bugzilla). mail.app isn=E2=80=99t finding the results I want for the = query I=E2=80=99m inputting (alternatively, I could have filed it so = long ago in the past that I deleted it when purging my email in the past = year)=E2=80=A6 Thanks! -Ngie --Apple-Mail=_B0E910BB-F81D-4AB4-8338-889F5789671E Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyYpKAAoJEPWDqSZpMIYVW+oP/jVuD3rV6UlA7sVRz+9737FA PBer31b6UM+edSnC3tuslt6M7FaWGgw20YaWetWuXRzvipk/Fwwqwnov7W3tAXBP jh98gcwylxm1YHC/yC7VjLwHeBrLUthNbqJHgapKF7kI95WdUyHppVwudBrsAB63 ke47I0/ubAGYbPhZaZu5xvf8+/3KjfJEinjaNv4ElHOFgBttqmmaQPAKOGJHacM2 glIGei1rHb0f957Kw/lhfa5MEDjZL0AsRkyj9DV0kERfZJXRxcvZHXmKm9tud1Hk 1WJ7Rai86T0G0WxxEN6fjpMaZ+zs/WBaoqL0aXOpk/cj3rNkp8iwfF/eSNO8jzi+ yUvIymruHwk14I1zi9tMJuUGROLzVg0CeDKXaPCfl0I+P3LG9ENOnAXSrk/OqF0f /pAG54jfJ5J3r24v+VYLLj9e24ythqAc9XWJTuI7UWZ7IyqryP/SGSDewA9yFxWG So7reJGIeK/V9M1inxwrVl+y7DnLa3oGZJI0FxTsWsAV82mVhCRaLiNeSU+NluqH 1Dq13u1hxBS74KfPXmIj2dl29pTh0y02qVDtOdqqIoL4b97+ZB5m3kkB4+Jn+GKw D2viKTrrMy60D5fwDDQWtp2D/xYjGMLCbEUYA0mVfZww7Abq0BjpvIcIs2zS6ug7 dIkG2SRfqzCrCtSR0tBC =DgcX -----END PGP SIGNATURE----- --Apple-Mail=_B0E910BB-F81D-4AB4-8338-889F5789671E-- From owner-svn-src-all@freebsd.org Wed Mar 15 18:44:33 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 74552D0EBFF; Wed, 15 Mar 2017 18:44:33 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io0-x244.google.com (mail-io0-x244.google.com [IPv6:2607:f8b0:4001:c06::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3BC22782; Wed, 15 Mar 2017 18:44:33 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io0-x244.google.com with SMTP id f84so3874334ioj.0; Wed, 15 Mar 2017 11:44:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-transfer-encoding; bh=mIukLWdHlKHMYcuBLPbCGvepJwRO1SeLHwL4yCWVdW8=; b=OxqTOGoYigPidJIXQdQywcGOvhthu4wa1RacwcGJBA0bQCaLsQhZwrYZatBLTDF+59 /ZsVsmlzUkOa2JWSnQ/KYjKPvhTWuNAck4H4HQ2cYto8Am8MF4KGPzYVeOSvyWLxsAPW YQ8tkUoT69aPTLK+kbzC0s3/jPRPZjuIRdZWHkLZ+VfZbvIlP89DdUSAJsVuXEp4ckbh +D8ibOAfzem+dW/O4JKhbULOLWlFOsqdK0rHhPVPgqoWkGEVFUItP4RJEBmf3TB+UiPa ULVfhAaU9Z6hiLOb46tOlFguXL0natnh1INAEOV9emU7rGBdwbiZc4+QBFaKKuE+aHPv mXGQ== 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=mIukLWdHlKHMYcuBLPbCGvepJwRO1SeLHwL4yCWVdW8=; b=h0j28Qdyo5F6ZSDeqfdcYZlXSVlkcHtZ/4EmqpBqTovVSvMt4MZuYv9LLaT/QOgLdf XihtDqShe48TaJ5PQmhjNwCjPLLFtrxz8Vjb+gGB2t3Vi6D8QrBWePmd4HwdKpU7/ptB oYlxcDu8K5x2lW6/w8nWVeOYrji1U3sheP4AglqMPW/blW0sUhKR5vb3CijGrVCT5+Kt Z6M0oSIDrdHLse8MB1UwhpDbHA113IAb8YbtkzIgIplbyxw47iAl/p3ZE6b6eTIXorGF RUIk5GPQ6hdY9C2pkxPPmH1RPhOUx+ucmYHN7PSvKZVp3j3DHLMVuZE9m8ij5+61kMbi a8Vw== X-Gm-Message-State: AFeK/H3qz2PYGuXUD1n//7H1nbQ6hkje2bYdqndnXtGu2icsWK8rucs7DJhNDWytSpvHQqmQhbNXmNt1EG8BEA== X-Received: by 10.107.47.102 with SMTP id j99mr6572442ioo.52.1489603472624; Wed, 15 Mar 2017 11:44:32 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.30.209 with HTTP; Wed, 15 Mar 2017 11:44:12 -0700 (PDT) In-Reply-To: <9502A8F5-6198-407F-B836-9B6458AC5F3D@gmail.com> References: <201703151616.v2FGGU8N029774@repo.freebsd.org> <9502A8F5-6198-407F-B836-9B6458AC5F3D@gmail.com> From: Ed Maste Date: Wed, 15 Mar 2017 14:44:12 -0400 X-Google-Sender-Auth: _7uywXFS293ATDE4ogGBwrj5kvw Message-ID: Subject: Re: svn commit: r315311 - head/usr.sbin/makefs To: "Ngie Cooper (yaneurabeya)" Cc: src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:44:33 -0000 On 15 March 2017 at 14:39, Ngie Cooper (yaneurabeya) wrote: > >> Yeah=E2=80=A6 I think I filed a bug, somewhere for improving the makefs(= 8) manpage (maybe NetBSD=E2=80=99s GNATS; maybe FreeBSD bugzilla). mail.app= isn=E2=80=99t finding the results I want for the query I=E2=80=99m inputti= ng (alternatively, I could have filed it so long ago in the past that I del= eted it when purging my email in the past year)=E2=80=A6 Ok, if you happen to find it again feel free to add me to CC. My goal here is to add msdos support from NetBSD's makefs. Dependencies include today's option parsing refactoring, and the newfs_msdos refactoring from some time ago. From owner-svn-src-all@freebsd.org Wed Mar 15 18:49:05 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6F158D0EE39; Wed, 15 Mar 2017 18:49:05 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pf0-x241.google.com (mail-pf0-x241.google.com [IPv6:2607:f8b0:400e:c00::241]) (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 39A94B8E; Wed, 15 Mar 2017 18:49:05 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pf0-x241.google.com with SMTP id o126so3027173pfb.1; Wed, 15 Mar 2017 11:49:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=gkxl6ZFvUkSk5vDB/2Cs/5050lXjfmogGU5Rm9i39Hw=; b=tSH/lac3PmFq0Jx/xNs+OHzjJuhaOg9x7wNOYQdR8ztSLKlDbKOnJZk4f7ocgbRFEe QF+Ho4v8ETcfKLMYW0ICR+zaZzdzeVqZY87ah5SBq+CeIPX4M5H2Az4DoGvrdxsNUt57 fXCXRPHrO8SWJ85HAEu4BHB5xSyBZyRbXMJS4xkw1367QFyJez0+FvIou+Jk7u6iOp2U 92jMJjxO2+Bb/z2xnM+UWMn+vvYu992V+vXIFPX9nWq2Axig1neGTKEAlU/U6SIc0N8Q cesMYge9jsdXq4JP4hSZJoG9Ki2hSVN219YuF7gV+W3R8wKLOriGNvY8nONYwX22kucN S/uQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=gkxl6ZFvUkSk5vDB/2Cs/5050lXjfmogGU5Rm9i39Hw=; b=Gs7IGX0tTSgduZRoDnLlHY+Di2nKcNLF4ZrjfdzhdWY9EdLrImZyvCXkwtGHuKFD2+ wxFDR84rItR3Ymst7RdCFF3eknm0R1HHX8Vt+/50ad5qklEDnYyhMAobIafJwueNoTYS wvTRiwdb9jsGWvVztwRo7GPRTrTxcAUYt2cWKaS9fC0QJ6y6/N78fl3WB5FJsBRlOhOF OTbuKU0lnMo9DC/GsUN8eAamVegd9O87MkbzhV80JTMZXc3eegJzIv9KvXP8Vnd4bBAO UGNJaRzVPqBSzQMTm7nX0UgqHniAwzUSlS5bBkX6ugS0+rlI+q3b1YAMzF8uRTPdxssa 36yg== X-Gm-Message-State: AFeK/H3e98ovqQhLL6+P+TP3XfCa2bTg2L8X39kBpUH+pyfvcfj8vFCmJFhNOsv80bzdIQ== X-Received: by 10.98.9.29 with SMTP id e29mr5320653pfd.101.1489603744663; Wed, 15 Mar 2017 11:49:04 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id b11sm5745714pfj.27.2017.03.15.11.49.03 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 11:49:03 -0700 (PDT) Subject: Re: svn commit: r315311 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_B2C376D6-131C-43C5-A63F-AA0A35B15FC3"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: Date: Wed, 15 Mar 2017 11:49:03 -0700 Cc: src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: <6C2922D2-F2E1-42A7-90BB-9218DF327C25@gmail.com> References: <201703151616.v2FGGU8N029774@repo.freebsd.org> <9502A8F5-6198-407F-B836-9B6458AC5F3D@gmail.com> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:49:05 -0000 --Apple-Mail=_B2C376D6-131C-43C5-A63F-AA0A35B15FC3 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 11:44, Ed Maste wrote: >=20 > On 15 March 2017 at 14:39, Ngie Cooper (yaneurabeya) > wrote: >>=20 >>> Yeah=E2=80=A6 I think I filed a bug, somewhere for improving the = makefs(8) manpage (maybe NetBSD=E2=80=99s GNATS; maybe FreeBSD = bugzilla). mail.app isn=E2=80=99t finding the results I want for the = query I=E2=80=99m inputting (alternatively, I could have filed it so = long ago in the past that I deleted it when purging my email in the past = year)=E2=80=A6 >=20 > Ok, if you happen to find it again feel free to add me to CC. >=20 > My goal here is to add msdos support from NetBSD's makefs. > Dependencies include today's option parsing refactoring, and the > newfs_msdos refactoring from some time ago. I didn=E2=80=99t find anything. I was probably thinking about it but = didn=E2=80=99t get around to it. Thanks! -Ngie --Apple-Mail=_B2C376D6-131C-43C5-A63F-AA0A35B15FC3 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyYyfAAoJEPWDqSZpMIYVvmoP/AwRp/a551iAmQCtjsqo78ny VXtH9Co3DQOz/PYp1ohiMr4PYpyvENenpOXJ6GPBeLW4I01Q9JOoel9ys6r62EuZ cQWhi50b8m5obd4a1PPqMYQMU7lk3GLUZZ+RNpA0t1tbAN3fihBF16fcAR4J8g2u tdXntdQk0+IoP1EyIHyt8LqoEcFfhPzvdA1bbn0xALco1zUgcSm2xzdah8ARhfg+ fM+iKNfLRp/qlJkTmxiz3Z3lwpgeawHACKF+FDtmxs2Ha5NtPIJZdj4cG0mTp+kh vdu8uLIloQMJVvx+ANxyg71KS3WXvtRjpKwDkTg1RSAk2ewv5FhZ994qQGSidbDB Q5tl1uAC49qNNyDZWzloDqTmkRWdCnfFTIX9Sxa8tQucQIEs1eEEqL2W3L3fF8CO X2dg2QqWgU8ajLyCccFrAGdA80k1sELXzZldrM229E9oou7CRRJ92Rq8WfXjO/f+ 8GbALTqgErlCLB/PhpB9W/xeCxlWaqx5NHLY1v0JJ/AR85ZSedzoV43jzNVrJ8Ok aoHlLV5dox1dN9upmfZh0gj88y3ckrznXS8l4HVhUwKl0GYqzOLB7SM72N71pchr knwtexCIO8qP/BG3wHfK7TD2Cud36YCbhr8HGBGXZXyrUG4HBtKW51eSQPonFBFn SOszMJNhmmy19Pdo/JXx =i6Hg -----END PGP SIGNATURE----- --Apple-Mail=_B2C376D6-131C-43C5-A63F-AA0A35B15FC3-- From owner-svn-src-all@freebsd.org Wed Mar 15 18:57:20 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 13504D0E32D; Wed, 15 Mar 2017 18:57:20 +0000 (UTC) (envelope-from mizhka@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 D6CFB13E6; Wed, 15 Mar 2017 18:57:19 +0000 (UTC) (envelope-from mizhka@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FIvIM6095591; Wed, 15 Mar 2017 18:57:18 GMT (envelope-from mizhka@FreeBSD.org) Received: (from mizhka@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FIvI7I095590; Wed, 15 Mar 2017 18:57:18 GMT (envelope-from mizhka@FreeBSD.org) Message-Id: <201703151857.v2FIvI7I095590@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mizhka set sender to mizhka@FreeBSD.org using -f From: Michael Zhilin Date: Wed, 15 Mar 2017 18:57:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315324 - head/sys/dev/bhnd/cores/pmu X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:57:20 -0000 Author: mizhka Date: Wed Mar 15 18:57:18 2017 New Revision: 315324 URL: https://svnweb.freebsd.org/changeset/base/315324 Log: [bhnd] fix mask for PMU control This patch fixes typo which results in extra bits of PMU control register. PR: 217782 Submitted by: Svyatoslav Found by: PVS-Studio Modified: head/sys/dev/bhnd/cores/pmu/bhnd_pmu_subr.c Modified: head/sys/dev/bhnd/cores/pmu/bhnd_pmu_subr.c ============================================================================== --- head/sys/dev/bhnd/cores/pmu/bhnd_pmu_subr.c Wed Mar 15 18:23:32 2017 (r315323) +++ head/sys/dev/bhnd/cores/pmu/bhnd_pmu_subr.c Wed Mar 15 18:57:18 2017 (r315324) @@ -2023,7 +2023,7 @@ bhnd_pmu1_pllinit0(struct bhnd_pmu_softc /* Write XtalFreq. Set the divisor also. */ pmuctrl = BHND_PMU_READ_4(sc, BHND_PMU_CTRL); - pmuctrl = ~(BHND_PMU_CTRL_ILP_DIV_MASK | BHND_PMU_CTRL_XTALFREQ_MASK); + pmuctrl &= ~(BHND_PMU_CTRL_ILP_DIV_MASK | BHND_PMU_CTRL_XTALFREQ_MASK); pmuctrl |= BHND_PMU_SET_BITS(((xt->fref + 127) / 128) - 1, BHND_PMU_CTRL_ILP_DIV); pmuctrl |= BHND_PMU_SET_BITS(xt->xf, BHND_PMU_CTRL_XTALFREQ); From owner-svn-src-all@freebsd.org Wed Mar 15 18:58:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EC409D0E411; Wed, 15 Mar 2017 18:58:44 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: from mail-pg0-x235.google.com (mail-pg0-x235.google.com [IPv6:2607:f8b0:400e:c05::235]) (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 B68B1168F; Wed, 15 Mar 2017 18:58:44 +0000 (UTC) (envelope-from yaneurabeya@gmail.com) Received: by mail-pg0-x235.google.com with SMTP id g2so13110809pge.3; Wed, 15 Mar 2017 11:58:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:mime-version:from:in-reply-to:date:cc:message-id:references :to; bh=bg+qAnOtnLjBWhg2va78N1/HUJfNvlwn5QxxtmP/X00=; b=bd/+I7Gq4ft0ejjXqO6bEjzxvFeWRnjtgZJrNwvNbW4088Yi5UMU9sqrdaeTfjnAip isAZyvdn8DeaNqinwjXLlMg+G6TWcLPJgGx4WrOAmIviVFy7Boe41ciGTKdsr1rAVV9G O/MuV/KLuxbtL6jcPQvcTMJN78bhF5NzQrFQGumDmNy+xo7GOO9ccXsRNu/uN93TCuAl gXctqht1psNOHx+gnWdyxcNWdjsbi6dJ1WLTWXmRmDzeJN8pmbDOMuztePtnwAHPlK9n pQoQpWoZJ/sOxtT/01ku8VXSNb+weP7oKnEG8+gO6KIKxpVzs5wdWl6q1r0uUoz6zZaD 1zKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:mime-version:from:in-reply-to:date:cc :message-id:references:to; bh=bg+qAnOtnLjBWhg2va78N1/HUJfNvlwn5QxxtmP/X00=; b=dxaq1xeZqV0ncnBCSlHwBOITlIY2vkX0Xo86PtXSgg7Ttm7GvFNkKMkvVL2rkJs1/p S7k038bQm+6L0aCsaGuzTnHftKPlXdlHJzLnufWjkTXklqVw5UQ5t31FJKuUhCKW5rWE +Q7d1CUq+zHHJ4gMi50AMjaA0HG2sPALAr7dI9XYhkgRUsQzyBUwNZEwP7h+opYsToGt TNdIa0OaFR2CSWHT7cIPZCjozmDcD+U88SsS3Z+d6erVEM/0ut601ZU5Eg+Q2mSUPXJA KEWAt8nXkKRpa6i+q3xSkJuNEP2NQ4js+WI++rURTWsbJUGU0jzOXZEx0miqTPlA00sb nWFg== X-Gm-Message-State: AFeK/H3oxVOFpOn7awV19xFZp8n0HHR8utBZB0h1//Yrehv6mDW1JyOPP/229nvAHm09aA== X-Received: by 10.98.93.90 with SMTP id r87mr5300453pfb.226.1489604324061; Wed, 15 Mar 2017 11:58:44 -0700 (PDT) Received: from pinklady.local (c-73-19-52-228.hsd1.wa.comcast.net. [73.19.52.228]) by smtp.gmail.com with ESMTPSA id z74sm5753398pfd.70.2017.03.15.11.58.43 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 15 Mar 2017 11:58:43 -0700 (PDT) Subject: Re: svn commit: r315311 - head/usr.sbin/makefs Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Content-Type: multipart/signed; boundary="Apple-Mail=_98CE3AAA-DA52-4058-9C4F-D316A34F5E94"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Pgp-Agent: GPGMail From: "Ngie Cooper (yaneurabeya)" In-Reply-To: <6C2922D2-F2E1-42A7-90BB-9218DF327C25@gmail.com> Date: Wed, 15 Mar 2017 11:58:42 -0700 Cc: src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Message-Id: References: <201703151616.v2FGGU8N029774@repo.freebsd.org> <9502A8F5-6198-407F-B836-9B6458AC5F3D@gmail.com> <6C2922D2-F2E1-42A7-90BB-9218DF327C25@gmail.com> To: Ed Maste X-Mailer: Apple Mail (2.3124) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 18:58:45 -0000 --Apple-Mail=_98CE3AAA-DA52-4058-9C4F-D316A34F5E94 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 > On Mar 15, 2017, at 11:49, Ngie Cooper (yaneurabeya) = wrote: >=20 >=20 >> On Mar 15, 2017, at 11:44, Ed Maste wrote: >>=20 >> On 15 March 2017 at 14:39, Ngie Cooper (yaneurabeya) >> wrote: >>>=20 >>>> Yeah=E2=80=A6 I think I filed a bug, somewhere for improving the = makefs(8) manpage (maybe NetBSD=E2=80=99s GNATS; maybe FreeBSD = bugzilla). mail.app isn=E2=80=99t finding the results I want for the = query I=E2=80=99m inputting (alternatively, I could have filed it so = long ago in the past that I deleted it when purging my email in the past = year)=E2=80=A6 >>=20 >> Ok, if you happen to find it again feel free to add me to CC. >>=20 >> My goal here is to add msdos support from NetBSD's makefs. >> Dependencies include today's option parsing refactoring, and the >> newfs_msdos refactoring from some time ago. >=20 > I didn=E2=80=99t find anything. I was probably thinking about it but = didn=E2=80=99t get around to it. Sidenote: if you open a CR in FreeBSD, I=E2=80=99ll be more than = happy to review the manpage in Phabricator, then we can work on = upstreaming it. Thanks! -Ngie --Apple-Mail=_98CE3AAA-DA52-4058-9C4F-D316A34F5E94 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJYyY7iAAoJEPWDqSZpMIYVBB4QAKefivmQVEaKqIWPtcyC5iO5 cRuYBoKhs6NVpIUlH3+n29OaNiwdjYfCW2LEXhjhr0JvMLcO3rShQknckR2lxO3D 3HWgkkhj2M9Gswvm/Mz+mYx1UuIR8DnrWJdwo/RZgXj4t4lUkEO8CNeXk6kDm3QO GROI8nrVK0ANS3oRa6HH94fJbJFmd9EoCzfYkNX8JpYwa9FTEoXkJNR3mS4Nov7R s/RNLwFszhqgiFiuw1c8Oo70cpNQYecXPcGDs6D8Io85NljS3N06uas3uZ+NUKBS sEYtt3s8BMsDBzLC2NP3hh4eIZvHFkb+XW8llGyVpuz7wN4cBDRHdd6NHrETDAr8 U4u/VGh+aKED4NdSCaxKOcZE3d6X6uaDGIveWft4s3Hd+4/+ZPN5oaEURL5B5C+L j/NB6MsunK3QSJq5EwCNXFCJLIPZN34hvOPgJYgtJKdI9i7NudHxiFKWdDh0pIAw jVuv2kHW3vwQHfRGAxHX7Ohel02jDNncNVnV54WUZzbv6fuTuH/lc/m+Kou1KqvG Ao7w5CQVjccc2QCmDLPq2NchDiMW+fFjGPVwE7AA2EoizNZAHJyL6s41PXOuWZKA lm/OxfgdYBfU7HWAH0Rh76hYSXOxz1PhHpdGb7qVMbE1v2SqAtsjPFfGOeWI9VxI 9hFuCZkMoiNTB+fUFzJc =hrdE -----END PGP SIGNATURE----- --Apple-Mail=_98CE3AAA-DA52-4058-9C4F-D316A34F5E94-- From owner-svn-src-all@freebsd.org Wed Mar 15 19:10:05 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5344D0E621; Wed, 15 Mar 2017 19:10:05 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B21C91BF5; Wed, 15 Mar 2017 19:10:05 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FJA4Si000166; Wed, 15 Mar 2017 19:10:04 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FJA4LZ000165; Wed, 15 Mar 2017 19:10:04 GMT (envelope-from np@FreeBSD.org) Message-Id: <201703151910.v2FJA4LZ000165@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Wed, 15 Mar 2017 19:10:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315325 - head/sys/dev/cxgbe/iw_cxgbe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:10:06 -0000 Author: np Date: Wed Mar 15 19:10:04 2017 New Revision: 315325 URL: https://svnweb.freebsd.org/changeset/base/315325 Log: cxgbe/iw_cxgbe: Use the socket and not the toepcb to reach for the inpcb. t4_tom detaches the inpcb from the toepcb as soon as the hardware is done with the connection (in final_cpl_received) but the socket is around as long as the cm_id and the rest of iWARP state is. This fixes an intermittent NULL dereference during abort. Submitted by: KrishnamRaju ErapaRaju @ Chelsio MFC after: 3 days Sponsored by: Chelsio Communications Modified: head/sys/dev/cxgbe/iw_cxgbe/qp.c Modified: head/sys/dev/cxgbe/iw_cxgbe/qp.c ============================================================================== --- head/sys/dev/cxgbe/iw_cxgbe/qp.c Wed Mar 15 18:57:18 2017 (r315324) +++ head/sys/dev/cxgbe/iw_cxgbe/qp.c Wed Mar 15 19:10:04 2017 (r315325) @@ -64,7 +64,7 @@ struct cpl_set_tcb_rpl; #include "iw_cxgbe.h" #include "user.h" -static void creds(struct toepcb *toep, size_t wrsize); +static int creds(struct toepcb *toep, struct inpcb *inp, size_t wrsize); static void set_state(struct c4iw_qp *qhp, enum c4iw_qp_state state) @@ -961,6 +961,7 @@ static inline void build_term_codes(stru static void post_terminate(struct c4iw_qp *qhp, struct t4_cqe *err_cqe, gfp_t gfp) { + int ret; struct fw_ri_wr *wqe; struct terminate_message *term; struct wrqe *wr; @@ -991,7 +992,11 @@ static void post_terminate(struct c4iw_q term->ecode = qhp->attr.ecode; } else build_term_codes(err_cqe, &term->layer_etype, &term->ecode); - creds(toep, sizeof(*wqe)); + ret = creds(toep, inp, sizeof(*wqe)); + if (ret) { + free_wrqe(wr); + return; + } t4_wrq_tx(qhp->rhp->rdev.adap, wr); } @@ -1094,7 +1099,11 @@ rdma_fini(struct c4iw_dev *rhp, struct c c4iw_init_wr_wait(&ep->com.wr_wait); - creds(toep, sizeof(*wqe)); + ret = creds(toep, inp, sizeof(*wqe)); + if (ret) { + free_wrqe(wr); + return ret; + } t4_wrq_tx(sc, wr); ret = c4iw_wait_for_reply(rdev, &ep->com.wr_wait, ep->hwtid, @@ -1127,13 +1136,17 @@ static void build_rtr_msg(u8 p2p_type, s } } -static void -creds(struct toepcb *toep, size_t wrsize) +static int +creds(struct toepcb *toep, struct inpcb *inp, size_t wrsize) { struct ofld_tx_sdesc *txsd; CTR3(KTR_IW_CXGBE, "%s:creB %p %u", __func__, toep , wrsize); - INP_WLOCK(toep->inp); + INP_WLOCK(inp); + if ((inp->inp_flags & (INP_DROPPED | INP_TIMEWAIT)) != 0) { + INP_WUNLOCK(inp); + return (EINVAL); + } txsd = &toep->txsd[toep->txsd_pidx]; txsd->tx_credits = howmany(wrsize, 16); txsd->plen = 0; @@ -1143,9 +1156,10 @@ creds(struct toepcb *toep, size_t wrsize if (__predict_false(++toep->txsd_pidx == toep->txsd_total)) toep->txsd_pidx = 0; toep->txsd_avail--; - INP_WUNLOCK(toep->inp); + INP_WUNLOCK(inp); CTR5(KTR_IW_CXGBE, "%s:creE %p %u %u %u", __func__, toep , txsd->tx_credits, toep->tx_credits, toep->txsd_pidx); + return (0); } static int rdma_init(struct c4iw_dev *rhp, struct c4iw_qp *qhp) @@ -1216,7 +1230,11 @@ static int rdma_init(struct c4iw_dev *rh c4iw_init_wr_wait(&ep->com.wr_wait); - creds(toep, sizeof(*wqe)); + ret = creds(toep, inp, sizeof(*wqe)); + if (ret) { + free_wrqe(wr); + return ret; + } t4_wrq_tx(sc, wr); ret = c4iw_wait_for_reply(rdev, &ep->com.wr_wait, ep->hwtid, From owner-svn-src-all@freebsd.org Wed Mar 15 19:18:44 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 405F6D0E87F; Wed, 15 Mar 2017 19:18:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from mail.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1F2CD21E; Wed, 15 Mar 2017 19:18:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by mail.baldwin.cx (Postfix) with ESMTPSA id 3755810A814; Wed, 15 Mar 2017 15:18:42 -0400 (EDT) From: John Baldwin To: Kristof Provost Cc: Gleb Smirnoff , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315136 - head/sys/netpfil/pf Date: Tue, 14 Mar 2017 23:45:57 -0700 Message-ID: <1803226.Igex2bR0P8@ralph.baldwin.cx> User-Agent: KMail/4.14.10 (FreeBSD/11.0-STABLE; KDE/4.14.10; amd64; ; ) In-Reply-To: <7B1C8879-E636-4315-99A2-A258AB9AE500@FreeBSD.org> References: <201703120542.v2C5gvM4075391@repo.freebsd.org> <20170314215706.GB1072@FreeBSD.org> <7B1C8879-E636-4315-99A2-A258AB9AE500@FreeBSD.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.4.3 (mail.baldwin.cx); Wed, 15 Mar 2017 15:18:42 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.99.2 at mail.baldwin.cx X-Virus-Status: Clean X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:18:44 -0000 On Wednesday, March 15, 2017 10:26:39 AM Kristof Provost wrote: > On 15 Mar 2017, at 6:57, Gleb Smirnoff wrote: > > On Sun, Mar 12, 2017 at 05:42:57AM +0000, Kristof Provost wrote: > > K> Log: > > K> pf: Fix incorrect rw_sleep() in pf_unload() > > K> > > K> When we unload we don't hold the pf_rules_lock, so we cannot c= all=20 > > rw_sleep() > > K> with it, because it would release a lock we do not hold. There= 's=20 > > no need for the > > K> lock either, so we can just tsleep(). > > K> > > K> While here also make the same change in pf_purge_thread(),=20 > > because it explicitly > > K> takes the lock before rw_sleep() and then immediately releases= it=20 > > afterwards. > > > > The correct change would to be grab lock in pf_unload(), exactly as= =20 > > pf_purge_thread() > > does. With your change you introduces a possible infinite sleep due= to=20 > > race, since > > there is no timeout and no lock. > > > I must be missing something, because I don=E2=80=99t see the race, an= d don=E2=80=99t=20 > see how we > could end up with an infinite sleep. You are ignoring interrupts and preemption. Suppose you get an interru= pt after 'wakeup_one(pf_purge_thread)' and before 'tsleep(..., 0)' in pf_unload(). If the interrupt preempts and results in the purge thread= running and issuing its wakeup before the thread executing pf_unload() resumes, then eventually when pf_unload() resumes it will do a tsleep()= with no timeout that will never be awoken. You obviously didn't test this in a debug kernel since there is a KASSE= RT explicitly to catch obvious tsleep races in _sleep(): KASSERT(sbt !=3D 0 || mtx_owned(&Giant) || lock !=3D NULL, ("sleeping without a lock")); You should fix this in the way that Gleb suggested. Also, all kthreads/kprocs do a wakeup() inside of exit1() or kthread_ex= it() to allow you to wait for a kthread to exit when unloading a module. Th= e general structure should be something like: struct thread *my_thread; void thread_main(void *arg) { LOCK(&mylock); while (!thread_quit) { UNLOCK(&mylock); /* do work */ LOCK(&mylock); if (!thread_quit && no_work_to_do) lock_sleep(&some_wchan, &mylock, ...); } UNLOCK(&mylock); kthread_exit(); } void unload_handler(...) { ... LOCK(&mylock); thread_quit =3D true; wakeup(&some_wchan); lock_sleep(my_thread, &mylock, ...); UNLOCK(&mylock); } void load_handler(...) { ... kthread_add(thread_main, arg, NULL, &my_thread, ...); } If you want to create a proc then you can use 'struct proc *my_proc' and sleep on 'my_proc' instead (along with using kproc_exit(), though kthread_exit() from the last thread in a kproc should call kproc_exit()= for you). --=20 John Baldwin From owner-svn-src-all@freebsd.org Wed Mar 15 19:21:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CDCD4D0EB61; Wed, 15 Mar 2017 19:21:58 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from mail.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AEF108B7; Wed, 15 Mar 2017 19:21:58 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from ralph.baldwin.cx (c-73-231-226-104.hsd1.ca.comcast.net [73.231.226.104]) by mail.baldwin.cx (Postfix) with ESMTPSA id B881810A7B9; Wed, 15 Mar 2017 15:21:57 -0400 (EDT) From: John Baldwin To: src-committers@freebsd.org Cc: svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315323 - head/sys/kern Date: Wed, 15 Mar 2017 12:21 -0700 Message-ID: <3167768.s4jIG6eyGp@ralph.baldwin.cx> User-Agent: KMail/4.14.10 (FreeBSD/11.0-STABLE; KDE/4.14.10; amd64; ; ) In-Reply-To: <201703151823.v2FINWN9083379@repo.freebsd.org> References: <201703151823.v2FINWN9083379@repo.freebsd.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.4.3 (mail.baldwin.cx); Wed, 15 Mar 2017 15:21:57 -0400 (EDT) X-Virus-Scanned: clamav-milter 0.99.2 at mail.baldwin.cx X-Virus-Status: Clean X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:21:58 -0000 On Wednesday, March 15, 2017 06:23:32 PM John Baldwin wrote: > Author: jhb > Date: Wed Mar 15 18:23:32 2017 > New Revision: 315323 > URL: https://svnweb.freebsd.org/changeset/base/315323 > > Log: > Use UMA_ALIGN_PTR instead of sizeof(void *) for zone alignment. > > uma_zcreate()'s alignment argument is supposed to be sizeof(foo) - 1, > and uma.h provides a set of helper macros for common types. Passing > sizeof(void *) results in all of the members being misaligned triggering > unaligned access faults on certain architectures (notably MIPS). > > Reported by: brooks > Obtained from: CheriBSD > MFC after: 3 days > Sponsored by: DARPA / AFRL > > Modified: > head/sys/kern/vfs_lookup.c We should perhaps add a KASSERT() to uma_zcreate to catch this sort of thing. Something like KASSERT(powerof2(align + 1)) (assuming there isn't a real use case for having non-power-of-2 alignments)? -- John Baldwin From owner-svn-src-all@freebsd.org Wed Mar 15 19:48:23 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85798D0E179; Wed, 15 Mar 2017 19:48:23 +0000 (UTC) (envelope-from tsoome@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 46482135F; Wed, 15 Mar 2017 19:48:23 +0000 (UTC) (envelope-from tsoome@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FJmMxx016153; Wed, 15 Mar 2017 19:48:22 GMT (envelope-from tsoome@FreeBSD.org) Received: (from tsoome@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FJmMG7016152; Wed, 15 Mar 2017 19:48:22 GMT (envelope-from tsoome@FreeBSD.org) Message-Id: <201703151948.v2FJmMG7016152@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: tsoome set sender to tsoome@FreeBSD.org using -f From: Toomas Soome Date: Wed, 15 Mar 2017 19:48:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315326 - head/sys/boot/efi/boot1 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:48:23 -0000 Author: tsoome Date: Wed Mar 15 19:48:22 2017 New Revision: 315326 URL: https://svnweb.freebsd.org/changeset/base/315326 Log: boot1.efi: can't boot from ZFS on 4kn HDD The boot1.efi immediate issue from PR216964 is that we are reading into too small buffer, from UEFI spec 2.6: The size of the Buffer in bytes. This must be a multiple of the intrinsic block size of the device. The secondary issue is that LBA calculation does not check reminder from division. This fix does check the provided buffer size and if we read less than media sector size or the read offset is not aligned to sector boundary, we allocate bounce buffer and perform the read by single sector. PR: 216964 Reported by: Sergey Kozlov Reviewed by: allanjude, Sergey Kozlov Approved by: allanjude (mentor) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D9870 Modified: head/sys/boot/efi/boot1/zfs_module.c Modified: head/sys/boot/efi/boot1/zfs_module.c ============================================================================== --- head/sys/boot/efi/boot1/zfs_module.c Wed Mar 15 19:10:04 2017 (r315325) +++ head/sys/boot/efi/boot1/zfs_module.c Wed Mar 15 19:48:22 2017 (r315326) @@ -44,23 +44,61 @@ static int vdev_read(vdev_t *vdev, void *priv, off_t off, void *buf, size_t bytes) { dev_info_t *devinfo; - off_t lba; + uint64_t lba; + size_t size, remainder, rb_size, blksz; + char *bouncebuf = NULL, *rb_buf; EFI_STATUS status; devinfo = (dev_info_t *)priv; lba = off / devinfo->dev->Media->BlockSize; + remainder = off % devinfo->dev->Media->BlockSize; - status = devinfo->dev->ReadBlocks(devinfo->dev, - devinfo->dev->Media->MediaId, lba, bytes, buf); - if (status != EFI_SUCCESS) { - DPRINTF("vdev_read: failed dev: %p, id: %u, lba: %jd, size: %zu," - " status: %lu\n", devinfo->dev, - devinfo->dev->Media->MediaId, (intmax_t)lba, bytes, - EFI_ERROR_CODE(status)); - return (-1); + rb_buf = buf; + rb_size = bytes; + + /* + * If we have remainder from off, we need to add remainder part. + * Since buffer must be multiple of the BlockSize, round it all up. + */ + size = roundup2(bytes + remainder, devinfo->dev->Media->BlockSize); + blksz = size; + if (remainder != 0 || size != bytes) { + rb_size = devinfo->dev->Media->BlockSize; + bouncebuf = malloc(rb_size); + if (bouncebuf == NULL) { + printf("vdev_read: out of memory\n"); + return (-1); + } + rb_buf = bouncebuf; + blksz = rb_size - remainder; } + while (bytes > 0) { + status = devinfo->dev->ReadBlocks(devinfo->dev, + devinfo->dev->Media->MediaId, lba, rb_size, rb_buf); + if (EFI_ERROR(status)) + goto error; + if (bytes < blksz) + blksz = bytes; + if (bouncebuf != NULL) + memcpy(buf, rb_buf + remainder, blksz); + buf = (void *)((uintptr_t)buf + blksz); + bytes -= blksz; + lba++; + remainder = 0; + blksz = rb_size; + } + + free(bouncebuf); return (0); + +error: + free(bouncebuf); + DPRINTF("vdev_read: failed dev: %p, id: %u, lba: %ju, size: %zu," + " rb_size: %zu, status: %lu\n", devinfo->dev, + devinfo->dev->Media->MediaId, (uintmax_t)lba, bytes, rb_size, + EFI_ERROR_CODE(status)); + return (-1); } static EFI_STATUS From owner-svn-src-all@freebsd.org Wed Mar 15 19:49:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B6AA4D0E268; Wed, 15 Mar 2017 19:49:46 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9146F15F3; Wed, 15 Mar 2017 19:49:46 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FJnjex016262; Wed, 15 Mar 2017 19:49:45 GMT (envelope-from mav@FreeBSD.org) Received: (from mav@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FJnjFe016260; Wed, 15 Mar 2017 19:49:45 GMT (envelope-from mav@FreeBSD.org) Message-Id: <201703151949.v2FJnjFe016260@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mav set sender to mav@FreeBSD.org using -f From: Alexander Motin Date: Wed, 15 Mar 2017 19:49:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315327 - head/sys/dev/isp X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:49:46 -0000 Author: mav Date: Wed Mar 15 19:49:45 2017 New Revision: 315327 URL: https://svnweb.freebsd.org/changeset/base/315327 Log: Remove not very useful ATIO/INOT stats. While there polish respective debug logging. MFC after: 2 weeks Modified: head/sys/dev/isp/isp_freebsd.c head/sys/dev/isp/isp_freebsd.h Modified: head/sys/dev/isp/isp_freebsd.c ============================================================================== --- head/sys/dev/isp/isp_freebsd.c Wed Mar 15 19:48:22 2017 (r315326) +++ head/sys/dev/isp/isp_freebsd.c Wed Mar 15 19:49:45 2017 (r315327) @@ -1742,8 +1742,7 @@ isp_handle_platform_atio2(ispsoftc_t *is atp->state = ATPD_STATE_ATIO; SLIST_REMOVE_HEAD(&tptr->atios, sim_links.sle); - tptr->atio_count--; - isp_prt(isp, ISP_LOGTDEBUG2, "Take FREE ATIO count now %d", tptr->atio_count); + ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, atiop->ccb_h.path, "Take FREE ATIO\n"); atiop->ccb_h.target_id = fcp->isp_loopid; atiop->ccb_h.target_lun = lun; @@ -1955,8 +1954,7 @@ isp_handle_platform_atio7(ispsoftc_t *is atp->word3 = lp->prli_word3; atp->state = ATPD_STATE_ATIO; SLIST_REMOVE_HEAD(&tptr->atios, sim_links.sle); - tptr->atio_count--; - ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, atiop->ccb_h.path, "Take FREE ATIO count now %d\n", tptr->atio_count); + ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, atiop->ccb_h.path, "Take FREE ATIO\n"); atiop->init_id = FC_PORTDB_TGT(isp, chan, lp); atiop->ccb_h.target_id = FCPARAM(isp, chan)->isp_loopid; atiop->ccb_h.target_lun = lun; @@ -2697,9 +2695,8 @@ isp_handle_platform_target_tmf(ispsoftc_ ntp->seq_id = notify->nt_tagval; ntp->tag_id = notify->nt_tagval >> 32; - tptr->inot_count--; SLIST_REMOVE_HEAD(&tptr->inots, sim_links.sle); - ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, inot->ccb_h.path, "%s: Take FREE INOT count now %d\n", __func__, tptr->inot_count); + ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, inot->ccb_h.path, "Take FREE INOT\n"); inot->ccb_h.status = CAM_MESSAGE_RECV; xpt_done((union ccb *)inot); return; @@ -3155,7 +3152,8 @@ isp_abort_atio(ispsoftc_t *isp, union cc if (sccb != &accb->ccb_h) continue; SLIST_REMOVE(&tptr->atios, sccb, ccb_hdr, sim_links.sle); - tptr->atio_count--; + ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, sccb->path, + "Abort FREE ATIO\n"); accb->ccb_h.status = CAM_REQ_ABORTED; xpt_done(accb); ccb->ccb_h.status = CAM_REQ_CMP; @@ -3205,7 +3203,8 @@ isp_abort_inot(ispsoftc_t *isp, union cc if (sccb != &accb->ccb_h) continue; SLIST_REMOVE(&tptr->inots, sccb, ccb_hdr, sim_links.sle); - tptr->inot_count--; + ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, sccb->path, + "Abort FREE INOT\n"); accb->ccb_h.status = CAM_REQ_ABORTED; xpt_done(accb); ccb->ccb_h.status = CAM_REQ_CMP; @@ -3349,16 +3348,14 @@ isp_action(struct cam_sim *sim, union cc if (ccb->ccb_h.func_code == XPT_ACCEPT_TARGET_IO) { ccb->atio.tag_id = 0; - tptr->atio_count++; SLIST_INSERT_HEAD(&tptr->atios, &ccb->ccb_h, sim_links.sle); ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, ccb->ccb_h.path, - "Put FREE ATIO, count now %d\n", tptr->atio_count); + "Put FREE ATIO\n"); } else if (ccb->ccb_h.func_code == XPT_IMMEDIATE_NOTIFY) { ccb->cin1.seq_id = ccb->cin1.tag_id = 0; - tptr->inot_count++; SLIST_INSERT_HEAD(&tptr->inots, &ccb->ccb_h, sim_links.sle); ISP_PATH_PRT(isp, ISP_LOGTDEBUG2, ccb->ccb_h.path, - "Put FREE INOT, count now %d\n", tptr->inot_count); + "Put FREE INOT\n"); } ccb->ccb_h.status = CAM_REQ_INPROG; break; Modified: head/sys/dev/isp/isp_freebsd.h ============================================================================== --- head/sys/dev/isp/isp_freebsd.h Wed Mar 15 19:48:22 2017 (r315326) +++ head/sys/dev/isp/isp_freebsd.h Wed Mar 15 19:49:45 2017 (r315327) @@ -160,8 +160,6 @@ typedef struct tstate { struct ccb_hdr_slist atios; struct ccb_hdr_slist inots; struct ntpdlist restart_queue; - uint16_t atio_count; - uint16_t inot_count; } tstate_t; #define LUN_HASH_SIZE 32 From owner-svn-src-all@freebsd.org Wed Mar 15 19:50:59 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DB491D0E326; Wed, 15 Mar 2017 19:50:59 +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 A0FCF1880; Wed, 15 Mar 2017 19:50:59 +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 v2FJowGQ017196; Wed, 15 Mar 2017 19:50:58 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FJow6j017195; Wed, 15 Mar 2017 19:50:58 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201703151950.v2FJow6j017195@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Wed, 15 Mar 2017 19:50:58 +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: r315328 - in stable: 10/sys/ofed/drivers/infiniband/hw/mlx4 11/sys/ofed/drivers/infiniband/hw/mlx4 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:51:00 -0000 Author: dim Date: Wed Mar 15 19:50:58 2017 New Revision: 315328 URL: https://svnweb.freebsd.org/changeset/base/315328 Log: MFC r310232: After r310171, the kernel version of sscanf() has format string checking enabled. This results in a -Werror warning in mlx4ib: sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c:90:22: error: format specifies type 'unsigned long long *' but the argument has type 'u64 *' (aka 'unsigned long *') [-Werror,-Wformat] sscanf(buf, "%llx", &sysadmin_ag_val); ~~~~ ^~~~~~~~~~~~~~~~ Change sysadmin_ag_val to unsigned long long to avoid the warning. Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D8831 Modified: stable/11/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/10/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Directory Properties: stable/10/ (props changed) Modified: stable/11/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c ============================================================================== --- stable/11/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Wed Mar 15 19:49:45 2017 (r315327) +++ stable/11/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Wed Mar 15 19:50:58 2017 (r315328) @@ -79,7 +79,7 @@ static ssize_t store_admin_alias_guid(st container_of(attr, struct mlx4_ib_iov_sysfs_attr, dentry); struct mlx4_ib_iov_port *port = mlx4_ib_iov_dentry->ctx; struct mlx4_ib_dev *mdev = port->dev; - u64 sysadmin_ag_val; + unsigned long long sysadmin_ag_val; record_num = mlx4_ib_iov_dentry->entry_num / 8; guid_index_in_rec = mlx4_ib_iov_dentry->entry_num % 8; From owner-svn-src-all@freebsd.org Wed Mar 15 19:51:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2584FD0E32B; Wed, 15 Mar 2017 19:51:00 +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 E5CBC1881; Wed, 15 Mar 2017 19:50:59 +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 v2FJowEq017202; Wed, 15 Mar 2017 19:50:58 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FJowv8017201; Wed, 15 Mar 2017 19:50:58 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201703151950.v2FJowv8017201@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Wed, 15 Mar 2017 19:50:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315328 - in stable: 10/sys/ofed/drivers/infiniband/hw/mlx4 11/sys/ofed/drivers/infiniband/hw/mlx4 X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 19:51:00 -0000 Author: dim Date: Wed Mar 15 19:50:58 2017 New Revision: 315328 URL: https://svnweb.freebsd.org/changeset/base/315328 Log: MFC r310232: After r310171, the kernel version of sscanf() has format string checking enabled. This results in a -Werror warning in mlx4ib: sys/dev/mlx4/mlx4_ib/mlx4_ib_sysfs.c:90:22: error: format specifies type 'unsigned long long *' but the argument has type 'u64 *' (aka 'unsigned long *') [-Werror,-Wformat] sscanf(buf, "%llx", &sysadmin_ag_val); ~~~~ ^~~~~~~~~~~~~~~~ Change sysadmin_ag_val to unsigned long long to avoid the warning. Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D8831 Modified: stable/10/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Directory Properties: stable/10/ (props changed) Changes in other areas also in this revision: Modified: stable/11/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Directory Properties: stable/11/ (props changed) Modified: stable/10/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c ============================================================================== --- stable/10/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Wed Mar 15 19:49:45 2017 (r315327) +++ stable/10/sys/ofed/drivers/infiniband/hw/mlx4/sysfs.c Wed Mar 15 19:50:58 2017 (r315328) @@ -79,7 +79,7 @@ static ssize_t store_admin_alias_guid(st container_of(attr, struct mlx4_ib_iov_sysfs_attr, dentry); struct mlx4_ib_iov_port *port = mlx4_ib_iov_dentry->ctx; struct mlx4_ib_dev *mdev = port->dev; - u64 sysadmin_ag_val; + unsigned long long sysadmin_ag_val; record_num = mlx4_ib_iov_dentry->entry_num / 8; guid_index_in_rec = mlx4_ib_iov_dentry->entry_num % 8; From owner-svn-src-all@freebsd.org Wed Mar 15 21:01:04 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E5CF6D0D6A2; Wed, 15 Mar 2017 21:01:04 +0000 (UTC) (envelope-from mizhka@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 98827FB6; Wed, 15 Mar 2017 21:01:04 +0000 (UTC) (envelope-from mizhka@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FL13Vi045016; Wed, 15 Mar 2017 21:01:03 GMT (envelope-from mizhka@FreeBSD.org) Received: (from mizhka@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FL13QS045014; Wed, 15 Mar 2017 21:01:03 GMT (envelope-from mizhka@FreeBSD.org) Message-Id: <201703152101.v2FL13QS045014@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mizhka set sender to mizhka@FreeBSD.org using -f From: Michael Zhilin Date: Wed, 15 Mar 2017 21:01:03 +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: r315329 - in stable/11/sys/dev: gpio spibus X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:01:05 -0000 Author: mizhka Date: Wed Mar 15 21:01:03 2017 New Revision: 315329 URL: https://svnweb.freebsd.org/changeset/base/315329 Log: MFC r310017-r310018 r310017: [spi] reformat message and ar5315_spi minor fix This commit corrects print of nomatch (newline was too early) and fix unit number for new child in ar5315_spi (was 0, now is -1 to calculate it according to actual system state) Submitted by: Hiroki Mori Reviewed by: ray, loos, mizhka MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D8749 r310018: [gpiospi] add clock delay to avoid smashing of bits Submitted by: Hiroki Mori Reviewed by: loos, ray, mizhka MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D8749 Modified: stable/11/sys/dev/gpio/gpiospi.c stable/11/sys/dev/spibus/spibus.c Modified: stable/11/sys/dev/gpio/gpiospi.c ============================================================================== --- stable/11/sys/dev/gpio/gpiospi.c Wed Mar 15 19:50:58 2017 (r315328) +++ stable/11/sys/dev/gpio/gpiospi.c Wed Mar 15 21:01:03 2017 (r315329) @@ -293,6 +293,7 @@ gpio_spi_txrx(struct gpio_spi_softc *sc, gpio_delay(sc); GPIOBUS_PIN_SET(sc->sc_busdev, sc->sc_dev, sc->sc_sclk, 1); + gpio_delay(sc); } else { /* If mode 0 or 3 */ @@ -312,6 +313,7 @@ gpio_spi_txrx(struct gpio_spi_softc *sc, gpio_delay(sc); GPIOBUS_PIN_SET(sc->sc_busdev, sc->sc_dev, sc->sc_sclk, 0); + gpio_delay(sc); } } Modified: stable/11/sys/dev/spibus/spibus.c ============================================================================== --- stable/11/sys/dev/spibus/spibus.c Wed Mar 15 19:50:58 2017 (r315328) +++ stable/11/sys/dev/spibus/spibus.c Wed Mar 15 21:01:03 2017 (r315329) @@ -116,9 +116,8 @@ spibus_probe_nomatch(device_t bus, devic { struct spibus_ivar *devi = SPIBUS_IVAR(child); - device_printf(bus, ""); - printf(" at cs %d\n", devi->cs); - printf(" mode %d", devi->mode); + device_printf(bus, " at cs %d mode %d\n", devi->cs, + devi->mode); return; } From owner-svn-src-all@freebsd.org Wed Mar 15 21:03:52 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B6E66D0D8A4; Wed, 15 Mar 2017 21:03:52 +0000 (UTC) (envelope-from mizhka@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 75B39132F; Wed, 15 Mar 2017 21:03:52 +0000 (UTC) (envelope-from mizhka@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FL3pwf048743; Wed, 15 Mar 2017 21:03:51 GMT (envelope-from mizhka@FreeBSD.org) Received: (from mizhka@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FL3p8j048739; Wed, 15 Mar 2017 21:03:51 GMT (envelope-from mizhka@FreeBSD.org) Message-Id: <201703152103.v2FL3p8j048739@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mizhka set sender to mizhka@FreeBSD.org using -f From: Michael Zhilin Date: Wed, 15 Mar 2017 21:03:51 +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: r315330 - in stable/11/sys: conf dev/etherswitch/rtl8366 X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:03:52 -0000 Author: mizhka Date: Wed Mar 15 21:03:51 2017 New Revision: 315330 URL: https://svnweb.freebsd.org/changeset/base/315330 Log: MFC r308700: [etherswitch] add RTL8366SR support Add RTL8366SR support at etherswitch driver. Tested on RTL8366RB and RTL8366SR. Submitted by: Hiroki Mori Reviewed by: adrian, mizhka Approved by: adrian(mentor) Differential Revision: https://reviews.freebsd.org/D6796 Modified: stable/11/sys/conf/options stable/11/sys/dev/etherswitch/rtl8366/rtl8366rb.c stable/11/sys/dev/etherswitch/rtl8366/rtl8366rbvar.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/conf/options ============================================================================== --- stable/11/sys/conf/options Wed Mar 15 21:01:03 2017 (r315329) +++ stable/11/sys/conf/options Wed Mar 15 21:03:51 2017 (r315330) @@ -987,6 +987,9 @@ BHND_LOGLEVEL opt_global.h # GPIO and child devices GPIO_SPI_DEBUG opt_gpio.h +# etherswitch(4) driver +RTL8366_SOFT_RESET opt_etherswitch.h + # evdev protocol support EVDEV_SUPPORT opt_evdev.h EVDEV_DEBUG opt_evdev.h Modified: stable/11/sys/dev/etherswitch/rtl8366/rtl8366rb.c ============================================================================== --- stable/11/sys/dev/etherswitch/rtl8366/rtl8366rb.c Wed Mar 15 21:01:03 2017 (r315329) +++ stable/11/sys/dev/etherswitch/rtl8366/rtl8366rb.c Wed Mar 15 21:03:51 2017 (r315330) @@ -1,4 +1,5 @@ /*- + * Copyright (c) 2015-2016 Hiroki Mori. * Copyright (c) 2011-2012 Stefan Bethke. * All rights reserved. * @@ -26,6 +27,8 @@ * $FreeBSD$ */ +#include "opt_etherswitch.h" + #include #include #include @@ -65,18 +68,13 @@ struct rtl8366rb_softc { int smi_acquired; /* serialize access to SMI/I2C bus */ struct mtx callout_mtx; /* serialize callout */ device_t dev; - int vid[RTL8366RB_NUM_VLANS]; - char *ifname[RTL8366RB_NUM_PHYS]; - device_t miibus[RTL8366RB_NUM_PHYS]; - struct ifnet *ifp[RTL8366RB_NUM_PHYS]; + int vid[RTL8366_NUM_VLANS]; + char *ifname[RTL8366_NUM_PHYS]; + device_t miibus[RTL8366_NUM_PHYS]; + struct ifnet *ifp[RTL8366_NUM_PHYS]; struct callout callout_tick; -}; - -static etherswitch_info_t etherswitch_info = { - .es_nports = RTL8366RB_NUM_PORTS, - .es_nvlangroups = RTL8366RB_NUM_VLANS, - .es_name = "Realtek RTL8366RB", - .es_vlan_caps = ETHERSWITCH_VLAN_DOT1Q, + etherswitch_info_t info; + int chip_type; /* 0 = RTL8366RB, 1 = RTL8366SR */ }; #define RTL_LOCK(_sc) mtx_lock(&(_sc)->sc_mtx) @@ -133,77 +131,101 @@ rtl8366rb_identify(driver_t *driver, dev if (device_find_child(parent, "rtl8366rb", -1) == NULL) { child = BUS_ADD_CHILD(parent, 0, "rtl8366rb", -1); devi = IICBUS_IVAR(child); - devi->addr = RTL8366RB_IIC_ADDR; + devi->addr = RTL8366_IIC_ADDR; } } static int rtl8366rb_probe(device_t dev) { + struct rtl8366rb_softc *sc; + + sc = device_get_softc(dev); + + bzero(sc, sizeof(*sc)); if (smi_probe(dev) != 0) return (ENXIO); - device_set_desc(dev, "RTL8366RB Ethernet Switch Controller"); + if(sc->chip_type == 0) + device_set_desc(dev, "RTL8366RB Ethernet Switch Controller"); + else + device_set_desc(dev, "RTL8366SR Ethernet Switch Controller"); return (BUS_PROBE_DEFAULT); } static void rtl8366rb_init(device_t dev) { - int i; struct rtl8366rb_softc *sc; + int i; + + sc = device_get_softc(dev); /* Initialisation for TL-WR1043ND */ - smi_rmw(dev, RTL8366RB_RCR, - RTL8366RB_RCR_HARD_RESET, - RTL8366RB_RCR_HARD_RESET, RTL_WAITOK); +#ifdef RTL8366_SOFT_RESET + smi_rmw(dev, RTL8366_RCR, + RTL8366_RCR_SOFT_RESET, + RTL8366_RCR_SOFT_RESET, RTL_WAITOK); +#else + smi_rmw(dev, RTL8366_RCR, + RTL8366_RCR_HARD_RESET, + RTL8366_RCR_HARD_RESET, RTL_WAITOK); +#endif + /* hard reset not return ack */ DELAY(100000); /* Enable 16 VLAN mode */ - smi_rmw(dev, RTL8366RB_SGCR, - RTL8366RB_SGCR_EN_VLAN | RTL8366RB_SGCR_EN_VLAN_4KTB, - RTL8366RB_SGCR_EN_VLAN, RTL_WAITOK); + smi_rmw(dev, RTL8366_SGCR, + RTL8366_SGCR_EN_VLAN | RTL8366_SGCR_EN_VLAN_4KTB, + RTL8366_SGCR_EN_VLAN, RTL_WAITOK); /* Initialize our vlan table. */ - sc = device_get_softc(dev); for (i = 0; i <= 1; i++) sc->vid[i] = (i + 1) | ETHERSWITCH_VID_VALID; /* Remove port 0 from VLAN 1. */ - smi_rmw(dev, RTL8366RB_VMCR(RTL8366RB_VMCR_MU_REG, 0), + smi_rmw(dev, RTL8366_VMCR(RTL8366_VMCR_MU_REG, 0), (1 << 0), 0, RTL_WAITOK); /* Add port 0 untagged and port 5 tagged to VLAN 2. */ - smi_rmw(dev, RTL8366RB_VMCR(RTL8366RB_VMCR_MU_REG, 1), - ((1 << 5 | 1 << 0) << RTL8366RB_VMCR_MU_MEMBER_SHIFT) - | ((1 << 5 | 1 << 0) << RTL8366RB_VMCR_MU_UNTAG_SHIFT), - ((1 << 5 | 1 << 0) << RTL8366RB_VMCR_MU_MEMBER_SHIFT - | ((1 << 0) << RTL8366RB_VMCR_MU_UNTAG_SHIFT)), + smi_rmw(dev, RTL8366_VMCR(RTL8366_VMCR_MU_REG, 1), + ((1 << 5 | 1 << 0) << RTL8366_VMCR_MU_MEMBER_SHIFT) + | ((1 << 5 | 1 << 0) << RTL8366_VMCR_MU_UNTAG_SHIFT), + ((1 << 5 | 1 << 0) << RTL8366_VMCR_MU_MEMBER_SHIFT + | ((1 << 0) << RTL8366_VMCR_MU_UNTAG_SHIFT)), RTL_WAITOK); /* Set PVID 2 for port 0. */ - smi_rmw(dev, RTL8366RB_PVCR_REG(0), - RTL8366RB_PVCR_VAL(0, RTL8366RB_PVCR_PORT_MASK), - RTL8366RB_PVCR_VAL(0, 1), RTL_WAITOK); + smi_rmw(dev, RTL8366_PVCR_REG(0), + RTL8366_PVCR_VAL(0, RTL8366_PVCR_PORT_MASK), + RTL8366_PVCR_VAL(0, 1), RTL_WAITOK); } static int rtl8366rb_attach(device_t dev) { - uint16_t rev = 0; struct rtl8366rb_softc *sc; + uint16_t rev = 0; char name[IFNAMSIZ]; int err = 0; int i; sc = device_get_softc(dev); - bzero(sc, sizeof(*sc)); + sc->dev = dev; mtx_init(&sc->sc_mtx, "rtl8366rb", NULL, MTX_DEF); sc->smi_acquired = 0; mtx_init(&sc->callout_mtx, "rtl8366rbcallout", NULL, MTX_DEF); rtl8366rb_init(dev); - smi_read(dev, RTL8366RB_CVCR, &rev, RTL_WAITOK); + smi_read(dev, RTL8366_CVCR, &rev, RTL_WAITOK); device_printf(dev, "rev. %d\n", rev & 0x000f); + sc->info.es_nports = RTL8366_NUM_PORTS; + sc->info.es_nvlangroups = RTL8366_NUM_VLANS; + sc->info.es_vlan_caps = ETHERSWITCH_VLAN_DOT1Q; + if(sc->chip_type == 0) + sprintf(sc->info.es_name, "Realtek RTL8366RB"); + else + sprintf(sc->info.es_name, "Realtek RTL8366SR"); + /* attach miibus and phys */ /* PHYs need an interface, so we generate a dummy one */ - for (i = 0; i < RTL8366RB_NUM_PHYS; i++) { + for (i = 0; i < RTL8366_NUM_PHYS; i++) { sc->ifp[i] = if_alloc(IFT_ETHER); sc->ifp[i]->if_softc = sc; sc->ifp[i]->if_flags |= IFF_UP | IFF_BROADCAST | IFF_DRV_RUNNING @@ -236,10 +258,12 @@ rtl8366rb_attach(device_t dev) static int rtl8366rb_detach(device_t dev) { - struct rtl8366rb_softc *sc = device_get_softc(dev); + struct rtl8366rb_softc *sc; int i; - for (i=0; i < RTL8366RB_NUM_PHYS; i++) { + sc = device_get_softc(dev); + + for (i=0; i < RTL8366_NUM_PHYS; i++) { if (sc->miibus[i]) device_delete_child(dev, sc->miibus[i]); if (sc->ifp[i] != NULL) @@ -259,30 +283,30 @@ rtl8366rb_update_ifmedia(int portstatus, { *media_active = IFM_ETHER; *media_status = IFM_AVALID; - if ((portstatus & RTL8366RB_PLSR_LINK) != 0) + if ((portstatus & RTL8366_PLSR_LINK) != 0) *media_status |= IFM_ACTIVE; else { *media_active |= IFM_NONE; return; } - switch (portstatus & RTL8366RB_PLSR_SPEED_MASK) { - case RTL8366RB_PLSR_SPEED_10: + switch (portstatus & RTL8366_PLSR_SPEED_MASK) { + case RTL8366_PLSR_SPEED_10: *media_active |= IFM_10_T; break; - case RTL8366RB_PLSR_SPEED_100: + case RTL8366_PLSR_SPEED_100: *media_active |= IFM_100_TX; break; - case RTL8366RB_PLSR_SPEED_1000: + case RTL8366_PLSR_SPEED_1000: *media_active |= IFM_1000_T; break; } - if ((portstatus & RTL8366RB_PLSR_FULLDUPLEX) != 0) + if ((portstatus & RTL8366_PLSR_FULLDUPLEX) != 0) *media_active |= IFM_FDX; else *media_active |= IFM_HDX; - if ((portstatus & RTL8366RB_PLSR_TXPAUSE) != 0) + if ((portstatus & RTL8366_PLSR_TXPAUSE) != 0) *media_active |= IFM_ETH_TXPAUSE; - if ((portstatus & RTL8366RB_PLSR_RXPAUSE) != 0) + if ((portstatus & RTL8366_PLSR_RXPAUSE) != 0) *media_active |= IFM_ETH_RXPAUSE; } @@ -295,10 +319,10 @@ rtl833rb_miipollstat(struct rtl8366rb_so uint16_t value; int portstatus; - for (i = 0; i < RTL8366RB_NUM_PHYS; i++) { + for (i = 0; i < RTL8366_NUM_PHYS; i++) { mii = device_get_softc(sc->miibus[i]); if ((i % 2) == 0) { - if (smi_read(sc->dev, RTL8366RB_PLSR_BASE + i/2, &value, RTL_NOWAIT) != 0) { + if (smi_read(sc->dev, RTL8366_PLSR_BASE + i/2, &value, RTL_NOWAIT) != 0) { DEBUG_INCRVAR(callout_blocked); return; } @@ -318,7 +342,9 @@ rtl833rb_miipollstat(struct rtl8366rb_so static void rtl8366rb_tick(void *arg) { - struct rtl8366rb_softc *sc = arg; + struct rtl8366rb_softc *sc; + + sc = arg; rtl833rb_miipollstat(sc); callout_reset(&sc->callout_tick, hz, rtl8366rb_tick, sc); @@ -327,39 +353,65 @@ rtl8366rb_tick(void *arg) static int smi_probe(device_t dev) { + struct rtl8366rb_softc *sc; device_t iicbus, iicha; - int err, i; + int err, i, j; uint16_t chipid; char bytes[2]; int xferd; - bytes[0] = RTL8366RB_CIR & 0xff; - bytes[1] = (RTL8366RB_CIR >> 8) & 0xff; + sc = device_get_softc(dev); + iicbus = device_get_parent(dev); iicha = device_get_parent(iicbus); - iicbus_reset(iicbus, IIC_FASTEST, RTL8366RB_IIC_ADDR, NULL); - for (i=3; i--; ) { - IICBUS_STOP(iicha); - /* - * we go directly to the host adapter because iicbus.c - * only issues a stop on a bus that was successfully started. - */ + + for(i = 0; i < 2; ++i) { + iicbus_reset(iicbus, IIC_FASTEST, RTL8366_IIC_ADDR, NULL); + for (j=3; j--; ) { + IICBUS_STOP(iicha); + /* + * we go directly to the host adapter because iicbus.c + * only issues a stop on a bus that was successfully started. + */ + } + err = iicbus_request_bus(iicbus, dev, IIC_WAIT); + if (err != 0) + goto out; + err = iicbus_start(iicbus, RTL8366_IIC_ADDR | RTL_IICBUS_READ, RTL_IICBUS_TIMEOUT); + if (err != 0) + goto out; + if(i == 0) { + bytes[0] = RTL8366RB_CIR & 0xff; + bytes[1] = (RTL8366RB_CIR >> 8) & 0xff; + } else { + bytes[0] = RTL8366SR_CIR & 0xff; + bytes[1] = (RTL8366SR_CIR >> 8) & 0xff; + } + err = iicbus_write(iicbus, bytes, 2, &xferd, RTL_IICBUS_TIMEOUT); + if (err != 0) + goto out; + err = iicbus_read(iicbus, bytes, 2, &xferd, IIC_LAST_READ, 0); + if (err != 0) + goto out; + chipid = ((bytes[1] & 0xff) << 8) | (bytes[0] & 0xff); + if (i == 0 && chipid == RTL8366RB_CIR_ID8366RB) { + DPRINTF(dev, "chip id 0x%04x\n", chipid); + sc->chip_type = 0; + err = 0; + break; + } + if (i == 1 && chipid == RTL8366SR_CIR_ID8366SR) { + DPRINTF(dev, "chip id 0x%04x\n", chipid); + sc->chip_type = 1; + err = 0; + break; + } + if(i == 0) { + iicbus_stop(iicbus); + iicbus_release_bus(iicbus, dev); + } } - err = iicbus_request_bus(iicbus, dev, IIC_WAIT); - if (err != 0) - goto out; - err = iicbus_start(iicbus, RTL8366RB_IIC_ADDR | RTL_IICBUS_READ, RTL_IICBUS_TIMEOUT); - if (err != 0) - goto out; - err = iicbus_write(iicbus, bytes, 2, &xferd, RTL_IICBUS_TIMEOUT); - if (err != 0) - goto out; - err = iicbus_read(iicbus, bytes, 2, &xferd, IIC_LAST_READ, 0); - if (err != 0) - goto out; - chipid = ((bytes[1] & 0xff) << 8) | (bytes[0] & 0xff); - DPRINTF(dev, "chip id 0x%04x\n", chipid); - if (chipid != RTL8366RB_CIR_ID8366RB) + if(i == 2) err = ENXIO; out: iicbus_stop(iicbus); @@ -406,12 +458,25 @@ smi_release(struct rtl8366rb_softc *sc, static int smi_select(device_t dev, int op, int sleep) { + struct rtl8366rb_softc *sc; int err, i; - device_t iicbus = device_get_parent(dev); - struct iicbus_ivar *devi = IICBUS_IVAR(dev); - int slave = devi->addr; + device_t iicbus; + struct iicbus_ivar *devi; + int slave; + + sc = device_get_softc(dev); + + iicbus = device_get_parent(dev); + devi = IICBUS_IVAR(dev); + slave = devi->addr; RTL_SMI_ACQUIRED_ASSERT((struct rtl8366rb_softc *)device_get_softc(dev)); + + if(sc->chip_type == 1) { // RTL8366SR work around + // this is same work around at probe + for (int i=3; i--; ) + IICBUS_STOP(device_get_parent(device_get_parent(dev))); + } /* * The chip does not use clock stretching when it is busy, * instead ignoring the command. Retry a few times. @@ -433,10 +498,12 @@ static int smi_read_locked(struct rtl8366rb_softc *sc, uint16_t addr, uint16_t *data, int sleep) { int err; - device_t iicbus = device_get_parent(sc->dev); + device_t iicbus; char bytes[2]; int xferd; + iicbus = device_get_parent(sc->dev); + RTL_SMI_ACQUIRED_ASSERT(sc); bytes[0] = addr & 0xff; bytes[1] = (addr >> 8) & 0xff; @@ -460,10 +527,12 @@ static int smi_write_locked(struct rtl8366rb_softc *sc, uint16_t addr, uint16_t data, int sleep) { int err; - device_t iicbus = device_get_parent(sc->dev); + device_t iicbus; char bytes[4]; int xferd; + iicbus = device_get_parent(sc->dev); + RTL_SMI_ACQUIRED_ASSERT(sc); bytes[0] = addr & 0xff; bytes[1] = (addr >> 8) & 0xff; @@ -481,9 +550,11 @@ smi_write_locked(struct rtl8366rb_softc static int smi_read(device_t dev, uint16_t addr, uint16_t *data, int sleep) { - struct rtl8366rb_softc *sc = device_get_softc(dev); + struct rtl8366rb_softc *sc; int err; + sc = device_get_softc(dev); + err = smi_acquire(sc, sleep); if (err != 0) return (EBUSY); @@ -496,9 +567,11 @@ smi_read(device_t dev, uint16_t addr, ui static int smi_write(device_t dev, uint16_t addr, uint16_t data, int sleep) { - struct rtl8366rb_softc *sc = device_get_softc(dev); + struct rtl8366rb_softc *sc; int err; + sc = device_get_softc(dev); + err = smi_acquire(sc, sleep); if (err != 0) return (EBUSY); @@ -511,10 +584,12 @@ smi_write(device_t dev, uint16_t addr, u static int smi_rmw(device_t dev, uint16_t addr, uint16_t mask, uint16_t data, int sleep) { - struct rtl8366rb_softc *sc = device_get_softc(dev); + struct rtl8366rb_softc *sc; int err; uint16_t oldv, newv; + sc = device_get_softc(dev); + err = smi_acquire(sc, sleep); if (err != 0) return (EBUSY); @@ -535,13 +610,19 @@ smi_rmw(device_t dev, uint16_t addr, uin static etherswitch_info_t * rtl_getinfo(device_t dev) { - return (ðerswitch_info); + struct rtl8366rb_softc *sc; + + sc = device_get_softc(dev); + + return (&sc->info); } static int rtl_readreg(device_t dev, int reg) { - uint16_t data = 0; + uint16_t data; + + data = 0; smi_read(dev, reg, &data, RTL_WAITOK); return (data); @@ -559,18 +640,21 @@ rtl_getport(device_t dev, etherswitch_po struct rtl8366rb_softc *sc; struct ifmedia *ifm; struct mii_data *mii; - struct ifmediareq *ifmr = &p->es_ifmr; + struct ifmediareq *ifmr; uint16_t v; int err, vlangroup; - if (p->es_port < 0 || p->es_port >= RTL8366RB_NUM_PORTS) - return (ENXIO); sc = device_get_softc(dev); - vlangroup = RTL8366RB_PVCR_GET(p->es_port, - rtl_readreg(dev, RTL8366RB_PVCR_REG(p->es_port))); + + ifmr = &p->es_ifmr; + + if (p->es_port < 0 || p->es_port >= RTL8366_NUM_PORTS) + return (ENXIO); + vlangroup = RTL8366_PVCR_GET(p->es_port, + rtl_readreg(dev, RTL8366_PVCR_REG(p->es_port))); p->es_pvid = sc->vid[vlangroup] & ETHERSWITCH_VID_MASK; - if (p->es_port < RTL8366RB_NUM_PHYS) { + if (p->es_port < RTL8366_NUM_PHYS) { mii = device_get_softc(sc->miibus[p->es_port]); ifm = &mii->mii_media; err = ifmedia_ioctl(sc->ifp[p->es_port], &p->es_ifr, ifm, SIOCGIFMEDIA); @@ -579,8 +663,8 @@ rtl_getport(device_t dev, etherswitch_po } else { /* fill in fixed values for CPU port */ p->es_flags |= ETHERSWITCH_PORT_CPU; - smi_read(dev, RTL8366RB_PLSR_BASE + (RTL8366RB_NUM_PHYS)/2, &v, RTL_WAITOK); - v = v >> (8 * ((RTL8366RB_NUM_PHYS) % 2)); + smi_read(dev, RTL8366_PLSR_BASE + (RTL8366_NUM_PHYS)/2, &v, RTL_WAITOK); + v = v >> (8 * ((RTL8366_NUM_PHYS) % 2)); rtl8366rb_update_ifmedia(v, &ifmr->ifm_status, &ifmr->ifm_active); ifmr->ifm_current = ifmr->ifm_active; ifmr->ifm_mask = 0; @@ -599,16 +683,17 @@ rtl_getport(device_t dev, etherswitch_po static int rtl_setport(device_t dev, etherswitch_port_t *p) { - int i, err, vlangroup; struct rtl8366rb_softc *sc; + int i, err, vlangroup; struct ifmedia *ifm; struct mii_data *mii; - if (p->es_port < 0 || p->es_port >= RTL8366RB_NUM_PORTS) - return (ENXIO); sc = device_get_softc(dev); + + if (p->es_port < 0 || p->es_port >= RTL8366_NUM_PORTS) + return (ENXIO); vlangroup = -1; - for (i = 0; i < RTL8366RB_NUM_VLANS; i++) { + for (i = 0; i < RTL8366_NUM_VLANS; i++) { if ((sc->vid[i] & ETHERSWITCH_VID_MASK) == p->es_pvid) { vlangroup = i; break; @@ -616,12 +701,12 @@ rtl_setport(device_t dev, etherswitch_po } if (vlangroup == -1) return (ENXIO); - err = smi_rmw(dev, RTL8366RB_PVCR_REG(p->es_port), - RTL8366RB_PVCR_VAL(p->es_port, RTL8366RB_PVCR_PORT_MASK), - RTL8366RB_PVCR_VAL(p->es_port, vlangroup), RTL_WAITOK); + err = smi_rmw(dev, RTL8366_PVCR_REG(p->es_port), + RTL8366_PVCR_VAL(p->es_port, RTL8366_PVCR_PORT_MASK), + RTL8366_PVCR_VAL(p->es_port, vlangroup), RTL_WAITOK); if (err) return (err); - if (p->es_port == RTL8366RB_CPU_PORT) + if (p->es_port == RTL8366_CPU_PORT) return (0); mii = device_get_softc(sc->miibus[p->es_port]); ifm = &mii->mii_media; @@ -636,14 +721,15 @@ rtl_getvgroup(device_t dev, etherswitch_ uint16_t vmcr[3]; int i; - for (i=0; i<3; i++) - vmcr[i] = rtl_readreg(dev, RTL8366RB_VMCR(i, vg->es_vlangroup)); - sc = device_get_softc(dev); + + for (i=0; ies_vlangroup)); + vg->es_vid = sc->vid[vg->es_vlangroup]; - vg->es_member_ports = RTL8366RB_VMCR_MEMBER(vmcr); - vg->es_untagged_ports = RTL8366RB_VMCR_UNTAG(vmcr); - vg->es_fid = RTL8366RB_VMCR_FID(vmcr); + vg->es_member_ports = RTL8366_VMCR_MEMBER(vmcr); + vg->es_untagged_ports = RTL8366_VMCR_UNTAG(vmcr); + vg->es_fid = RTL8366_VMCR_FID(vmcr); return (0); } @@ -651,21 +737,31 @@ static int rtl_setvgroup(device_t dev, etherswitch_vlangroup_t *vg) { struct rtl8366rb_softc *sc; - int g = vg->es_vlangroup; + int g; sc = device_get_softc(dev); + + g = vg->es_vlangroup; + sc->vid[g] = vg->es_vid; /* VLAN group disabled ? */ if (vg->es_member_ports == 0 && vg->es_untagged_ports == 0 && vg->es_vid == 0) return (0); sc->vid[g] |= ETHERSWITCH_VID_VALID; - rtl_writereg(dev, RTL8366RB_VMCR(RTL8366RB_VMCR_DOT1Q_REG, g), - (vg->es_vid << RTL8366RB_VMCR_DOT1Q_VID_SHIFT) & RTL8366RB_VMCR_DOT1Q_VID_MASK); - rtl_writereg(dev, RTL8366RB_VMCR(RTL8366RB_VMCR_MU_REG, g), - ((vg->es_member_ports << RTL8366RB_VMCR_MU_MEMBER_SHIFT) & RTL8366RB_VMCR_MU_MEMBER_MASK) | - ((vg->es_untagged_ports << RTL8366RB_VMCR_MU_UNTAG_SHIFT) & RTL8366RB_VMCR_MU_UNTAG_MASK)); - rtl_writereg(dev, RTL8366RB_VMCR(RTL8366RB_VMCR_FID_REG, g), - vg->es_fid); + rtl_writereg(dev, RTL8366_VMCR(RTL8366_VMCR_DOT1Q_REG, g), + (vg->es_vid << RTL8366_VMCR_DOT1Q_VID_SHIFT) & RTL8366_VMCR_DOT1Q_VID_MASK); + if(sc->chip_type == 0) { + rtl_writereg(dev, RTL8366_VMCR(RTL8366_VMCR_MU_REG, g), + ((vg->es_member_ports << RTL8366_VMCR_MU_MEMBER_SHIFT) & RTL8366_VMCR_MU_MEMBER_MASK) | + ((vg->es_untagged_ports << RTL8366_VMCR_MU_UNTAG_SHIFT) & RTL8366_VMCR_MU_UNTAG_MASK)); + rtl_writereg(dev, RTL8366_VMCR(RTL8366_VMCR_FID_REG, g), + vg->es_fid); + } else { + rtl_writereg(dev, RTL8366_VMCR(RTL8366_VMCR_MU_REG, g), + ((vg->es_member_ports << RTL8366_VMCR_MU_MEMBER_SHIFT) & RTL8366_VMCR_MU_MEMBER_MASK) | + ((vg->es_untagged_ports << RTL8366_VMCR_MU_UNTAG_SHIFT) & RTL8366_VMCR_MU_UNTAG_MASK) | + ((vg->es_fid << RTL8366_VMCR_FID_FID_SHIFT) & RTL8366_VMCR_FID_FID_MASK)); + } return (0); } @@ -683,24 +779,28 @@ rtl_getconf(device_t dev, etherswitch_co static int rtl_readphy(device_t dev, int phy, int reg) { - struct rtl8366rb_softc *sc = device_get_softc(dev); - uint16_t data = 0; + struct rtl8366rb_softc *sc; + uint16_t data; int err, i, sleep; - if (phy < 0 || phy >= RTL8366RB_NUM_PHYS) + sc = device_get_softc(dev); + + data = 0; + + if (phy < 0 || phy >= RTL8366_NUM_PHYS) return (ENXIO); - if (reg < 0 || reg >= RTL8366RB_NUM_PHY_REG) + if (reg < 0 || reg >= RTL8366_NUM_PHY_REG) return (ENXIO); sleep = RTL_WAITOK; err = smi_acquire(sc, sleep); if (err != 0) return (EBUSY); for (i = RTL_IICBUS_RETRIES; i--; ) { - err = smi_write_locked(sc, RTL8366RB_PACR, RTL8366RB_PACR_READ, sleep); + err = smi_write_locked(sc, RTL8366_PACR, RTL8366_PACR_READ, sleep); if (err == 0) - err = smi_write_locked(sc, RTL8366RB_PHYREG(phy, 0, reg), 0, sleep); + err = smi_write_locked(sc, RTL8366_PHYREG(phy, 0, reg), 0, sleep); if (err == 0) { - err = smi_read_locked(sc, RTL8366RB_PADR, &data, sleep); + err = smi_read_locked(sc, RTL8366_PADR, &data, sleep); break; } DEBUG_INCRVAR(phy_access_retries); @@ -715,21 +815,23 @@ rtl_readphy(device_t dev, int phy, int r static int rtl_writephy(device_t dev, int phy, int reg, int data) { - struct rtl8366rb_softc *sc = device_get_softc(dev); + struct rtl8366rb_softc *sc; int err, i, sleep; - if (phy < 0 || phy >= RTL8366RB_NUM_PHYS) + sc = device_get_softc(dev); + + if (phy < 0 || phy >= RTL8366_NUM_PHYS) return (ENXIO); - if (reg < 0 || reg >= RTL8366RB_NUM_PHY_REG) + if (reg < 0 || reg >= RTL8366_NUM_PHY_REG) return (ENXIO); sleep = RTL_WAITOK; err = smi_acquire(sc, sleep); if (err != 0) return (EBUSY); for (i = RTL_IICBUS_RETRIES; i--; ) { - err = smi_write_locked(sc, RTL8366RB_PACR, RTL8366RB_PACR_WRITE, sleep); + err = smi_write_locked(sc, RTL8366_PACR, RTL8366_PACR_WRITE, sleep); if (err == 0) - err = smi_write_locked(sc, RTL8366RB_PHYREG(phy, 0, reg), data, sleep); + err = smi_write_locked(sc, RTL8366_PHYREG(phy, 0, reg), data, sleep); if (err == 0) { break; } @@ -745,8 +847,11 @@ rtl_writephy(device_t dev, int phy, int static int rtl8366rb_ifmedia_upd(struct ifnet *ifp) { - struct rtl8366rb_softc *sc = ifp->if_softc; - struct mii_data *mii = device_get_softc(sc->miibus[ifp->if_dunit]); + struct rtl8366rb_softc *sc; + struct mii_data *mii; + + sc = ifp->if_softc; + mii = device_get_softc(sc->miibus[ifp->if_dunit]); mii_mediachg(mii); return (0); @@ -755,8 +860,11 @@ rtl8366rb_ifmedia_upd(struct ifnet *ifp) static void rtl8366rb_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr) { - struct rtl8366rb_softc *sc = ifp->if_softc; - struct mii_data *mii = device_get_softc(sc->miibus[ifp->if_dunit]); + struct rtl8366rb_softc *sc; + struct mii_data *mii; + + sc = ifp->if_softc; + mii = device_get_softc(sc->miibus[ifp->if_dunit]); mii_pollstat(mii); ifmr->ifm_active = mii->mii_media_active; Modified: stable/11/sys/dev/etherswitch/rtl8366/rtl8366rbvar.h ============================================================================== --- stable/11/sys/dev/etherswitch/rtl8366/rtl8366rbvar.h Wed Mar 15 21:01:03 2017 (r315329) +++ stable/11/sys/dev/etherswitch/rtl8366/rtl8366rbvar.h Wed Mar 15 21:03:51 2017 (r315330) @@ -1,4 +1,5 @@ /*- + * Copyright (c) 2015-2016 Hiroki Mori. * Copyright (c) 2011-2012 Stefan Bethke. * All rights reserved. * @@ -29,7 +30,7 @@ #ifndef _DEV_ETHERSWITCH_RTL8366RBVAR_H_ #define _DEV_ETHERSWITCH_RTL8366RBVAR_H_ -#define RTL8366RB_IIC_ADDR 0xa8 +#define RTL8366_IIC_ADDR 0xa8 #define RTL_IICBUS_TIMEOUT 100 /* us */ #define RTL_IICBUS_READ 1 #define RTL_IICBUS_WRITE 0 @@ -40,138 +41,142 @@ /* Register definitions */ /* Switch Global Configuration */ -#define RTL8366RB_SGCR 0x0000 -#define RTL8366RB_SGCR_EN_BC_STORM_CTRL 0x0001 -#define RTL8366RB_SGCR_MAX_LENGTH_MASK 0x0030 -#define RTL8366RB_SGCR_MAX_LENGTH_1522 0x0000 -#define RTL8366RB_SGCR_MAX_LENGTH_1536 0x0010 -#define RTL8366RB_SGCR_MAX_LENGTH_1552 0x0020 -#define RTL8366RB_SGCR_MAX_LENGTH_9216 0x0030 -#define RTL8366RB_SGCR_EN_VLAN 0x2000 -#define RTL8366RB_SGCR_EN_VLAN_4KTB 0x4000 -#define RTL8366RB_SGCR_EN_QOS 0x8000 +#define RTL8366_SGCR 0x0000 +#define RTL8366_SGCR_EN_BC_STORM_CTRL 0x0001 +#define RTL8366_SGCR_MAX_LENGTH_MASK 0x0030 +#define RTL8366_SGCR_MAX_LENGTH_1522 0x0000 +#define RTL8366_SGCR_MAX_LENGTH_1536 0x0010 +#define RTL8366_SGCR_MAX_LENGTH_1552 0x0020 +#define RTL8366_SGCR_MAX_LENGTH_9216 0x0030 +#define RTL8366_SGCR_EN_VLAN 0x2000 +#define RTL8366_SGCR_EN_VLAN_4KTB 0x4000 +#define RTL8366_SGCR_EN_QOS 0x8000 /* Port Enable Control: DISABLE_PORT[5:0] */ -#define RTL8366RB_PECR 0x0001 +#define RTL8366_PECR 0x0001 /* Switch Security Control 0: DIS_LEARN[5:0] */ -#define RTL8366RB_SSCR0 0x0002 +#define RTL8366_SSCR0 0x0002 /* Switch Security Control 1: DIS_AGE[5:0] */ -#define RTL8366RB_SSCR1 0x0003 +#define RTL8366_SSCR1 0x0003 /* Switch Security Control 2 */ -#define RTL8366RB_SSCR2 0x0004 -#define RTL8366RB_SSCR2_DROP_UNKNOWN_DA 0x0001 +#define RTL8366_SSCR2 0x0004 +#define RTL8366_SSCR2_DROP_UNKNOWN_DA 0x0001 /* Port Link Status: two ports per register */ -#define RTL8366RB_PLSR_BASE 0x0014 -#define RTL8366RB_PLSR_SPEED_MASK 0x03 -#define RTL8366RB_PLSR_SPEED_10 0x00 -#define RTL8366RB_PLSR_SPEED_100 0x01 -#define RTL8366RB_PLSR_SPEED_1000 0x02 -#define RTL8366RB_PLSR_FULLDUPLEX 0x04 -#define RTL8366RB_PLSR_LINK 0x10 -#define RTL8366RB_PLSR_TXPAUSE 0x20 -#define RTL8366RB_PLSR_RXPAUSE 0x40 -#define RTL8366RB_PLSR_NO_AUTO 0x80 - -/* VLAN Member Configuration, 3 registers per VLAN */ -#define RTL8366RB_VMCR_BASE 0x0020 -#define RTL8366RB_VMCR_MULT 3 -#define RTL8366RB_VMCR_DOT1Q_REG 0 -#define RTL8366RB_VMCR_DOT1Q_VID_SHIFT 0 -#define RTL8366RB_VMCR_DOT1Q_VID_MASK 0x0fff -#define RTL8366RB_VMCR_DOT1Q_PCP_SHIFT 12 -#define RTL8366RB_VMCR_DOT1Q_PCP_MASK 0x7000 -#define RTL8366RB_VMCR_MU_REG 1 -#define RTL8366RB_VMCR_MU_MEMBER_SHIFT 0 -#define RTL8366RB_VMCR_MU_MEMBER_MASK 0x00ff -#define RTL8366RB_VMCR_MU_UNTAG_SHIFT 8 -#define RTL8366RB_VMCR_MU_UNTAG_MASK 0xff00 -#define RTL8366RB_VMCR_FID_REG 2 -#define RTL8366RB_VMCR_FID_FID_SHIFT 0 -#define RTL8366RB_VMCR_FID_FID_MASK 0x0007 -#define RTL8366RB_VMCR(_reg, _vlan) \ - (RTL8366RB_VMCR_BASE + _reg + _vlan * RTL8366RB_VMCR_MULT) +#define RTL8366_PLSR_BASE (sc->chip_type == 0 ? 0x0014 : 0x0060) +#define RTL8366_PLSR_SPEED_MASK 0x03 +#define RTL8366_PLSR_SPEED_10 0x00 +#define RTL8366_PLSR_SPEED_100 0x01 +#define RTL8366_PLSR_SPEED_1000 0x02 +#define RTL8366_PLSR_FULLDUPLEX 0x04 +#define RTL8366_PLSR_LINK 0x10 +#define RTL8366_PLSR_TXPAUSE 0x20 +#define RTL8366_PLSR_RXPAUSE 0x40 +#define RTL8366_PLSR_NO_AUTO 0x80 + +/* VLAN Member Configuration, 3 or 2 registers per VLAN */ +#define RTL8366_VMCR_BASE (sc->chip_type == 0 ? 0x0020 : 0x0016) +#define RTL8366_VMCR_MULT (sc->chip_type == 0 ? 3 : 2) +#define RTL8366_VMCR_DOT1Q_REG 0 +#define RTL8366_VMCR_DOT1Q_VID_SHIFT 0 +#define RTL8366_VMCR_DOT1Q_VID_MASK 0x0fff +#define RTL8366_VMCR_DOT1Q_PCP_SHIFT 12 +#define RTL8366_VMCR_DOT1Q_PCP_MASK 0x7000 +#define RTL8366_VMCR_MU_REG 1 +#define RTL8366_VMCR_MU_MEMBER_SHIFT 0 +#define RTL8366_VMCR_MU_MEMBER_MASK (sc->chip_type == 0 ? 0x00ff : 0x003f) +#define RTL8366_VMCR_MU_UNTAG_SHIFT (sc->chip_type == 0 ? 8 : 6) +#define RTL8366_VMCR_MU_UNTAG_MASK (sc->chip_type == 0 ? 0xff00 : 0x0fc0) +#define RTL8366_VMCR_FID_REG (sc->chip_type == 0 ? 2 : 1) +#define RTL8366_VMCR_FID_FID_SHIFT (sc->chip_type == 0 ? 0 : 12) +#define RTL8366_VMCR_FID_FID_MASK (sc->chip_type == 0 ? 0x0007 : 0x7000) +#define RTL8366_VMCR(_reg, _vlan) \ + (RTL8366_VMCR_BASE + _reg + _vlan * RTL8366_VMCR_MULT) /* VLAN Identifier */ -#define RTL8366RB_VMCR_VID(_r) \ - (_r[RTL8366RB_VMCR_DOT1Q_REG] & RTL8366RB_VMCR_DOT1Q_VID_MASK) +#define RTL8366_VMCR_VID(_r) \ + (_r[RTL8366_VMCR_DOT1Q_REG] & RTL8366_VMCR_DOT1Q_VID_MASK) /* Priority Code Point */ -#define RTL8366RB_VMCR_PCP(_r) \ - ((_r[RTL8366RB_VMCR_DOT1Q_REG] & RTL8366RB_VMCR_DOT1Q_PCP_MASK) \ - >> RTL8366RB_VMCR_DOT1Q_PCP_SHIFT) +#define RTL8366_VMCR_PCP(_r) \ + ((_r[RTL8366_VMCR_DOT1Q_REG] & RTL8366_VMCR_DOT1Q_PCP_MASK) \ + >> RTL8366_VMCR_DOT1Q_PCP_SHIFT) /* Member ports */ -#define RTL8366RB_VMCR_MEMBER(_r) \ - (_r[RTL8366RB_VMCR_MU_REG] & RTL8366RB_VMCR_MU_MEMBER_MASK) +#define RTL8366_VMCR_MEMBER(_r) \ + (_r[RTL8366_VMCR_MU_REG] & RTL8366_VMCR_MU_MEMBER_MASK) /* Untagged ports */ -#define RTL8366RB_VMCR_UNTAG(_r) \ - ((_r[RTL8366RB_VMCR_MU_REG] & RTL8366RB_VMCR_MU_UNTAG_MASK) \ - >> RTL8366RB_VMCR_MU_UNTAG_SHIFT) +#define RTL8366_VMCR_UNTAG(_r) \ + ((_r[RTL8366_VMCR_MU_REG] & RTL8366_VMCR_MU_UNTAG_MASK) \ + >> RTL8366_VMCR_MU_UNTAG_SHIFT) /* Forwarding ID */ -#define RTL8366RB_VMCR_FID(_r) \ - (_r[RTL8366RB_VMCR_FID_REG] & RTL8366RB_VMCR_FID_FID_MASK) +#define RTL8366_VMCR_FID(_r) \ + (sc->chip_type == 0 ? (_r[RTL8366_VMCR_FID_REG] & RTL8366_VMCR_FID_FID_MASK) : \ + ((_r[RTL8366_VMCR_FID_REG] & RTL8366_VMCR_FID_FID_MASK) \ + >> RTL8366_VMCR_FID_FID_SHIFT)) /* * Port VLAN Control, 4 ports per register * Determines the VID for untagged ingress frames through * index into VMC. */ -#define RTL8366RB_PVCR_BASE 0x0063 -#define RTL8366RB_PVCR_PORT_SHIFT 4 -#define RTL8366RB_PVCR_PORT_PERREG (16 / RTL8366RB_PVCR_PORT_SHIFT) -#define RTL8366RB_PVCR_PORT_MASK 0x000f -#define RTL8366RB_PVCR_REG(_port) \ - (RTL8366RB_PVCR_BASE + _port / (RTL8366RB_PVCR_PORT_PERREG)) -#define RTL8366RB_PVCR_VAL(_port, _pvlan) \ - ((_pvlan & RTL8366RB_PVCR_PORT_MASK) << \ - ((_port % RTL8366RB_PVCR_PORT_PERREG) * RTL8366RB_PVCR_PORT_SHIFT)) -#define RTL8366RB_PVCR_GET(_port, _val) \ - (((_val) >> ((_port % RTL8366RB_PVCR_PORT_PERREG) * RTL8366RB_PVCR_PORT_SHIFT)) & RTL8366RB_PVCR_PORT_MASK) +#define RTL8366_PVCR_BASE (sc->chip_type == 0 ? 0x0063 : 0x0058) +#define RTL8366_PVCR_PORT_SHIFT 4 +#define RTL8366_PVCR_PORT_PERREG (16 / RTL8366_PVCR_PORT_SHIFT) +#define RTL8366_PVCR_PORT_MASK 0x000f +#define RTL8366_PVCR_REG(_port) \ + (RTL8366_PVCR_BASE + _port / (RTL8366_PVCR_PORT_PERREG)) +#define RTL8366_PVCR_VAL(_port, _pvlan) \ + ((_pvlan & RTL8366_PVCR_PORT_MASK) << \ + ((_port % RTL8366_PVCR_PORT_PERREG) * RTL8366_PVCR_PORT_SHIFT)) +#define RTL8366_PVCR_GET(_port, _val) \ + (((_val) >> ((_port % RTL8366_PVCR_PORT_PERREG) * RTL8366_PVCR_PORT_SHIFT)) & RTL8366_PVCR_PORT_MASK) /* Reset Control */ -#define RTL8366RB_RCR 0x0100 -#define RTL8366RB_RCR_HARD_RESET 0x0001 -#define RTL8366RB_RCR_SOFT_RESET 0x0002 +#define RTL8366_RCR 0x0100 +#define RTL8366_RCR_HARD_RESET 0x0001 +#define RTL8366_RCR_SOFT_RESET 0x0002 /* Chip Version Control: CHIP_VER[3:0] */ -#define RTL8366RB_CVCR 0x050A +#define RTL8366_CVCR (sc->chip_type == 0 ? 0x050A : 0x0104) /* Chip Identifier */ #define RTL8366RB_CIR 0x0509 #define RTL8366RB_CIR_ID8366RB 0x5937 +#define RTL8366SR_CIR 0x0105 +#define RTL8366SR_CIR_ID8366SR 0x8366 /* VLAN Ingress Control 2: [5:0] */ -#define RTL8366RB_VIC2R 0x037f +#define RTL8366_VIC2R 0x037f /* MIB registers */ -#define RTL8366RB_MCNT_BASE 0x1000 -#define RTL8366RB_MCTLR 0x13f0 -#define RTL8366RB_MCTLR_BUSY 0x0001 -#define RTL8366RB_MCTLR_RESET 0x0002 -#define RTL8366RB_MCTLR_RESET_PORT_MASK 0x00fc -#define RTL8366RB_MCTLR_RESET_ALL 0x0800 - -#define RTL8366RB_MCNT(_port, _r) \ - (RTL8366RB_MCNT_BASE + 0x50 * (_port) + (_r)) -#define RTL8366RB_MCTLR_RESET_PORT(_p) \ +#define RTL8366_MCNT_BASE 0x1000 +#define RTL8366_MCTLR (sc->chip_type == 0 ? 0x13f0 : 0x11F0) +#define RTL8366_MCTLR_BUSY 0x0001 +#define RTL8366_MCTLR_RESET 0x0002 +#define RTL8366_MCTLR_RESET_PORT_MASK 0x00fc +#define RTL8366_MCTLR_RESET_ALL 0x0800 + +#define RTL8366_MCNT(_port, _r) \ + (RTL8366_MCNT_BASE + 0x50 * (_port) + (_r)) +#define RTL8366_MCTLR_RESET_PORT(_p) \ (1 << ((_p) + 2)) /* PHY Access Control */ -#define RTL8366RB_PACR 0x8000 -#define RTL8366RB_PACR_WRITE 0x0000 -#define RTL8366RB_PACR_READ 0x0001 +#define RTL8366_PACR (sc->chip_type == 0 ? 0x8000 : 0x8028) +#define RTL8366_PACR_WRITE 0x0000 +#define RTL8366_PACR_READ 0x0001 /* PHY Access Data */ -#define RTL8366RB_PADR 0x8002 +#define RTL8366_PADR (sc->chip_type == 0 ? 0x8002 : 0x8029) -#define RTL8366RB_PHYREG(phy, page, reg) \ - (RTL8366RB_PACR | (1 << (((phy) & 0x1f) + 9)) | (((page) & 0xf) << 5) | ((reg) & 0x1f)) +#define RTL8366_PHYREG(phy, page, reg) \ + (0x8000 | (1 << (((phy) & 0x1f) + 9)) | (((page) & (sc->chip_type == 0 ? 0xf : 0x7)) << 5) | ((reg) & 0x1f)) /* general characteristics of the chip */ -#define RTL8366RB_CPU_PORT 5 -#define RTL8366RB_NUM_PORTS 6 -#define RTL8366RB_NUM_PHYS (RTL8366RB_NUM_PORTS-1) -#define RTL8366RB_NUM_VLANS 16 -#define RTL8366RB_NUM_PHY_REG 32 +#define RTL8366_CPU_PORT 5 +#define RTL8366_NUM_PORTS 6 +#define RTL8366_NUM_PHYS (RTL8366_NUM_PORTS-1) +#define RTL8366_NUM_VLANS 16 +#define RTL8366_NUM_PHY_REG 32 #endif From owner-svn-src-all@freebsd.org Wed Mar 15 21:12:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 429A0D0DCAD; Wed, 15 Mar 2017 21:12:01 +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 02D97184A; Wed, 15 Mar 2017 21:12:00 +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 v2FLC0Sq051950; Wed, 15 Mar 2017 21:12:00 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FLBwrD051923; Wed, 15 Mar 2017 21:11:58 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703152111.v2FLBwrD051923@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 15 Mar 2017 21:11:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315331 - in head/libexec/rtld-elf: . aarch64 amd64 arm i386 mips powerpc powerpc64 riscv sparc64 X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:12:01 -0000 Author: kib Date: Wed Mar 15 21:11:57 2017 New Revision: 315331 URL: https://svnweb.freebsd.org/changeset/base/315331 Log: Implement LD_BIND_NOT knob for rtld. From the manpage: When set to a nonempty string, prevents modifications of the PLT slots when doing bindings. As result, each call of the PLT-resolved function is resolved. In combination with debug output, this provides complete account of all bind actions at runtime. Same feature exists on Linux and Solaris. Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Modified: head/libexec/rtld-elf/aarch64/reloc.c head/libexec/rtld-elf/aarch64/rtld_machdep.h head/libexec/rtld-elf/amd64/reloc.c head/libexec/rtld-elf/amd64/rtld_machdep.h head/libexec/rtld-elf/arm/reloc.c head/libexec/rtld-elf/arm/rtld_machdep.h head/libexec/rtld-elf/i386/reloc.c head/libexec/rtld-elf/i386/rtld_machdep.h head/libexec/rtld-elf/mips/reloc.c head/libexec/rtld-elf/mips/rtld_machdep.h head/libexec/rtld-elf/powerpc/reloc.c head/libexec/rtld-elf/powerpc/rtld_machdep.h head/libexec/rtld-elf/powerpc64/reloc.c head/libexec/rtld-elf/powerpc64/rtld_machdep.h head/libexec/rtld-elf/riscv/reloc.c head/libexec/rtld-elf/riscv/rtld_machdep.h head/libexec/rtld-elf/rtld.1 head/libexec/rtld-elf/rtld.c head/libexec/rtld-elf/rtld.h head/libexec/rtld-elf/sparc64/reloc.c head/libexec/rtld-elf/sparc64/rtld_machdep.h Modified: head/libexec/rtld-elf/aarch64/reloc.c ============================================================================== --- head/libexec/rtld-elf/aarch64/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/aarch64/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -298,10 +298,9 @@ reloc_jmpslot(Elf_Addr *where, Elf_Addr assert(ELF_R_TYPE(rel->r_info) == R_AARCH64_JUMP_SLOT); - if (*where != target) + if (*where != target && !ld_bind_not) *where = target; - - return target; + return (target); } void Modified: head/libexec/rtld-elf/aarch64/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/aarch64/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/aarch64/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -47,9 +47,8 @@ struct Struct_Obj_Entry; }) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/amd64/reloc.c ============================================================================== --- head/libexec/rtld-elf/amd64/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/amd64/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -387,6 +387,20 @@ reloc_jmpslots(Obj_Entry *obj, int flags return 0; } +/* Fixup the jump slot at "where" to transfer control to "target". */ +Elf_Addr +reloc_jmpslot(Elf_Addr *where, Elf_Addr target, + const struct Struct_Obj_Entry *obj, const struct Struct_Obj_Entry *refobj, + const Elf_Rel *rel) +{ +#ifdef dbg + dbg("reloc_jmpslot: *%p = %p", where, (void *)target); +#endif + if (!ld_bind_not) + *where = target; + return (target); +} + int reloc_iresolve(Obj_Entry *obj, RtldLockState *lockstate) { Modified: head/libexec/rtld-elf/amd64/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/amd64/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/amd64/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -38,21 +38,11 @@ struct Struct_Obj_Entry; Elf_Dyn *rtld_dynamic_addr(void); #define rtld_dynamic(obj) rtld_dynamic_addr() -/* Fixup the jump slot at "where" to transfer control to "target". */ -static inline Elf_Addr -reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *obj, - const struct Struct_Obj_Entry *refobj, const Elf_Rel *rel) -{ -#ifdef dbg - dbg("reloc_jmpslot: *%p = %p", (void *)(where), - (void *)(target)); -#endif - (*(Elf_Addr *)(where) = (Elf_Addr)(target)); - return target; -} +Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, + const struct Struct_Obj_Entry *obj, const struct Struct_Obj_Entry *refobj, + const Elf_Rel *rel); -#define make_function_pointer(def, defobj) \ +#define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) #define call_initfini_pointer(obj, target) \ Modified: head/libexec/rtld-elf/arm/reloc.c ============================================================================== --- head/libexec/rtld-elf/arm/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/arm/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -468,15 +468,14 @@ reloc_gnu_ifunc(Obj_Entry *obj, int flag Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, const Obj_Entry *defobj, - const Obj_Entry *obj, const Elf_Rel *rel) + const Obj_Entry *obj, const Elf_Rel *rel) { assert(ELF_R_TYPE(rel->r_info) == R_ARM_JUMP_SLOT); - if (*where != target) + if (*where != target && !ld_bind_not) *where = target; - - return target; + return (target); } void Modified: head/libexec/rtld-elf/arm/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/arm/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/arm/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -38,9 +38,8 @@ struct Struct_Obj_Entry; #define rtld_dynamic(obj) (&_DYNAMIC) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/i386/reloc.c ============================================================================== --- head/libexec/rtld-elf/i386/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/i386/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -344,6 +344,20 @@ reloc_jmpslots(Obj_Entry *obj, int flags return 0; } +/* Fixup the jump slot at "where" to transfer control to "target". */ +Elf_Addr +reloc_jmpslot(Elf_Addr *where, Elf_Addr target, + const struct Struct_Obj_Entry *obj, const struct Struct_Obj_Entry *refobj, + const Elf_Rel *rel) +{ +#ifdef dbg + dbg("reloc_jmpslot: *%p = %p", where, (void *)target); +#endif + if (!ld_bind_not) + *where = target; + return (target); +} + int reloc_iresolve(Obj_Entry *obj, RtldLockState *lockstate) { Modified: head/libexec/rtld-elf/i386/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/i386/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/i386/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -38,21 +38,11 @@ struct Struct_Obj_Entry; #define rtld_dynamic(obj) \ ((const Elf_Dyn *)((obj)->relocbase + (Elf_Addr)&_DYNAMIC)) -/* Fixup the jump slot at "where" to transfer control to "target". */ -static inline Elf_Addr -reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *obj, - const struct Struct_Obj_Entry *refobj, const Elf_Rel *rel) -{ -#ifdef dbg - dbg("reloc_jmpslot: *%p = %p", (void *)(where), - (void *)(target)); -#endif - (*(Elf_Addr *)(where) = (Elf_Addr)(target)); - return target; -} +Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, + const struct Struct_Obj_Entry *obj, const struct Struct_Obj_Entry *refobj, + const Elf_Rel *rel); -#define make_function_pointer(def, defobj) \ +#define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) #define call_initfini_pointer(obj, target) \ Modified: head/libexec/rtld-elf/mips/reloc.c ============================================================================== --- head/libexec/rtld-elf/mips/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/mips/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -274,7 +274,8 @@ _mips_rtld_bind(Obj_Entry *obj, Elf_Size obj->path, (intmax_t)reloff, defobj->strtab + def->st_name, (void *)*where, (void *)target); - *where = target; + if (!ld_bind_not) + *where = target; lock_release(rtld_bind_lock, &lockstate); return (Elf_Addr)target; } Modified: head/libexec/rtld-elf/mips/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/mips/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/mips/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -39,9 +39,8 @@ struct Struct_Obj_Entry; #define rtld_dynamic(obj) (&_DYNAMIC) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/powerpc/reloc.c ============================================================================== --- head/libexec/rtld-elf/powerpc/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/powerpc/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -468,7 +468,7 @@ reloc_jmpslots(Obj_Entry *obj, int flags */ Elf_Addr reloc_jmpslot(Elf_Addr *wherep, Elf_Addr target, const Obj_Entry *defobj, - const Obj_Entry *obj, const Elf_Rel *rel) + const Obj_Entry *obj, const Elf_Rel *rel) { Elf_Addr offset; const Elf_Rela *rela = (const Elf_Rela *) rel; @@ -476,6 +476,9 @@ reloc_jmpslot(Elf_Addr *wherep, Elf_Addr dbg(" reloc_jmpslot: where=%p, target=%p", (void *)wherep, (void *)target); + if (ld_bind_not) + goto out; + /* * At the PLT entry pointed at by `wherep', construct * a direct transfer to the now fully resolved function @@ -519,6 +522,7 @@ reloc_jmpslot(Elf_Addr *wherep, Elf_Addr } } +out: return (target); } Modified: head/libexec/rtld-elf/powerpc/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/powerpc/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/powerpc/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -38,9 +38,8 @@ struct Struct_Obj_Entry; #define rtld_dynamic(obj) (&_DYNAMIC) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/powerpc64/reloc.c ============================================================================== --- head/libexec/rtld-elf/powerpc64/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/powerpc64/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -433,7 +433,7 @@ reloc_jmpslots(Obj_Entry *obj, int flags */ Elf_Addr reloc_jmpslot(Elf_Addr *wherep, Elf_Addr target, const Obj_Entry *defobj, - const Obj_Entry *obj, const Elf_Rel *rel) + const Obj_Entry *obj, const Elf_Rel *rel) { /* @@ -447,6 +447,9 @@ reloc_jmpslot(Elf_Addr *wherep, Elf_Addr (void *)wherep, (void *)target, *(Elf_Addr *)target, (Elf_Addr)defobj->relocbase); + if (ld_bind_not) + goto out; + /* * For the trampoline, the second two elements of the function * descriptor are unused, so we are fine replacing those at any time @@ -476,11 +479,13 @@ reloc_jmpslot(Elf_Addr *wherep, Elf_Addr ((struct funcdesc *)(wherep))->toc += (Elf_Addr)defobj->relocbase; } +out: #else dbg(" reloc_jmpslot: where=%p, target=%p", (void *)wherep, (void *)target); - *wherep = target; + if (!ld_bind_not) + *wherep = target; #endif return (target); Modified: head/libexec/rtld-elf/powerpc64/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/powerpc64/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/powerpc64/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -38,9 +38,8 @@ struct Struct_Obj_Entry; #define rtld_dynamic(obj) (&_DYNAMIC) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/riscv/reloc.c ============================================================================== --- head/libexec/rtld-elf/riscv/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/riscv/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -226,10 +226,9 @@ reloc_jmpslot(Elf_Addr *where, Elf_Addr assert(ELF_R_TYPE(rel->r_info) == R_RISCV_JUMP_SLOT); - if (*where != target) + if (*where != target && !ld_bind_not) *where = target; - - return target; + return (target); } /* Modified: head/libexec/rtld-elf/riscv/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/riscv/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/riscv/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -54,9 +54,8 @@ uint64_t set_gp(struct Struct_Obj_Entry }) Elf_Addr reloc_jmpslot(Elf_Addr *where, Elf_Addr target, - const struct Struct_Obj_Entry *defobj, - const struct Struct_Obj_Entry *obj, - const Elf_Rel *rel); + const struct Struct_Obj_Entry *defobj, const struct Struct_Obj_Entry *obj, + const Elf_Rel *rel); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) Modified: head/libexec/rtld-elf/rtld.1 ============================================================================== --- head/libexec/rtld-elf/rtld.1 Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/rtld.1 Wed Mar 15 21:11:57 2017 (r315331) @@ -28,7 +28,7 @@ .\" .\" $FreeBSD$ .\" -.Dd June 20, 2014 +.Dd March 16, 2017 .Dt RTLD 1 .Os .Sh NAME @@ -199,6 +199,12 @@ This is intended for use within sandboxes, when global namespaces such as the filesystem are unavailable. It is consulted just after LD_LIBRARY_PATH. This variable is unset for set-user-ID and set-group-ID programs. +.It Ev LD_BIND_NOT +When set to a nonempty string, prevents modifications of the PLT slots when +doing bindings. +As result, each call of the PLT-resolved function is resolved. +In combination with debug output, this provides complete account of +all bind actions at runtime. .It Ev LD_BIND_NOW When set to a nonempty string, causes .Nm Modified: head/libexec/rtld-elf/rtld.c ============================================================================== --- head/libexec/rtld-elf/rtld.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/rtld.c Wed Mar 15 21:11:57 2017 (r315331) @@ -178,6 +178,7 @@ static char *libmap_override; /* Maps to static bool trust; /* False for setuid and setgid programs */ static bool dangerous_ld_env; /* True if environment variables have been used to affect the libraries loaded */ +bool ld_bind_not; /* Disable PLT update */ static char *ld_bind_now; /* Environment variable for immediate binding */ static char *ld_debug; /* Environment variable for debugging */ static char *ld_library_path; /* Environment variable for search path */ @@ -416,6 +417,9 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ md_abi_variant_hook(aux_info); ld_bind_now = getenv(_LD("BIND_NOW")); + if (ld_bind_now == NULL) + ld_bind_not = getenv(_LD("BIND_NOT")) != NULL; + /* * If the process is tainted, then we un-set the dangerous environment * variables. The process will be marked as tainted until setuid(2) Modified: head/libexec/rtld-elf/rtld.h ============================================================================== --- head/libexec/rtld-elf/rtld.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/rtld.h Wed Mar 15 21:11:57 2017 (r315331) @@ -358,6 +358,7 @@ void *malloc_aligned(size_t size, size_t void free_aligned(void *ptr); extern Elf_Addr _GLOBAL_OFFSET_TABLE_[]; extern Elf_Sym sym_zero; /* For resolving undefined weak refs. */ +extern bool ld_bind_not; void dump_relocations(Obj_Entry *); void dump_obj_relocations(Obj_Entry *); Modified: head/libexec/rtld-elf/sparc64/reloc.c ============================================================================== --- head/libexec/rtld-elf/sparc64/reloc.c Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/sparc64/reloc.c Wed Mar 15 21:11:57 2017 (r315331) @@ -581,7 +581,9 @@ reloc_jmpslot(Elf_Addr *wherep, Elf_Addr Elf_Addr offset; Elf_Word *where; - if (rela - refobj->pltrela < 32764) { + if (ld_bind_not) { + /* Skip any PLT modifications */ + } else if (rela - refobj->pltrela < 32764) { /* * At the PLT entry pointed at by `where', we now construct * a direct transfer to the now fully resolved function Modified: head/libexec/rtld-elf/sparc64/rtld_machdep.h ============================================================================== --- head/libexec/rtld-elf/sparc64/rtld_machdep.h Wed Mar 15 21:03:51 2017 (r315330) +++ head/libexec/rtld-elf/sparc64/rtld_machdep.h Wed Mar 15 21:11:57 2017 (r315331) @@ -39,9 +39,8 @@ Elf_Dyn *rtld_dynamic_addr(void); #define rtld_dynamic(obj) rtld_dynamic_addr() Elf_Addr reloc_jmpslot(Elf_Addr *, Elf_Addr, - const struct Struct_Obj_Entry *, - const struct Struct_Obj_Entry *, - const Elf_Rel *); + const struct Struct_Obj_Entry *, const struct Struct_Obj_Entry *, + const Elf_Rel *); #define make_function_pointer(def, defobj) \ ((defobj)->relocbase + (def)->st_value) From owner-svn-src-all@freebsd.org Wed Mar 15 21:17:46 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EB55AD0DD97; Wed, 15 Mar 2017 21:17:46 +0000 (UTC) (envelope-from bdrewery@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 B2F2F1BDE; Wed, 15 Mar 2017 21:17:46 +0000 (UTC) (envelope-from bdrewery@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FLHjgp052846; Wed, 15 Mar 2017 21:17:45 GMT (envelope-from bdrewery@FreeBSD.org) Received: (from bdrewery@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FLHj7w052845; Wed, 15 Mar 2017 21:17:45 GMT (envelope-from bdrewery@FreeBSD.org) Message-Id: <201703152117.v2FLHj7w052845@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bdrewery set sender to bdrewery@FreeBSD.org using -f From: Bryan Drewery Date: Wed, 15 Mar 2017 21:17:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315332 - head/gnu/usr.bin X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:17:47 -0000 Author: bdrewery Date: Wed Mar 15 21:17:45 2017 New Revision: 315332 URL: https://svnweb.freebsd.org/changeset/base/315332 Log: Fix SUBDIR_DEPEND for gdb on binutils after r307659. Sponsored by: Dell EMC Isilon Modified: head/gnu/usr.bin/Makefile Modified: head/gnu/usr.bin/Makefile ============================================================================== --- head/gnu/usr.bin/Makefile Wed Mar 15 21:11:57 2017 (r315331) +++ head/gnu/usr.bin/Makefile Wed Mar 15 21:17:45 2017 (r315332) @@ -2,7 +2,6 @@ .include -SUBDIR_DEPEND_gdb= ${_binutils} .if ${MK_CXX} != "no" SUBDIR.${MK_GCC}+= gperf @@ -14,6 +13,7 @@ SUBDIR.${MK_DIALOG}+= dialog .if ${MK_BINUTILS} != "no" SUBDIR.${MK_GDB}+= gdb +SUBDIR_DEPEND_gdb= binutils .endif SUBDIR.${MK_GCC}+= cc From owner-svn-src-all@freebsd.org Wed Mar 15 21:19:57 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EFA9DD0DF2A for ; Wed, 15 Mar 2017 21:19:57 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Received: from mail-qk0-x22b.google.com (mail-qk0-x22b.google.com [IPv6:2607:f8b0:400d:c09::22b]) (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 A57791EA4 for ; Wed, 15 Mar 2017 21:19:57 +0000 (UTC) (envelope-from shawn.webb@hardenedbsd.org) Received: by mail-qk0-x22b.google.com with SMTP id 1so24370616qkl.3 for ; Wed, 15 Mar 2017 14:19:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardenedbsd-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=btQ2aQOpJBYiXf/NtjbQkNM4ILDr0EnNrbjo5NqNxiQ=; b=Fua+E2DelrKNEZ+SOVyDZxs+TKOpxLpN5ZGH9LZBPJJrMnrDhzDhqcaapuectNG0WJ 7O5ZgOk5YNFKIvC1t4vEiYDpvh6IeFkhKensDEdW8RFZqBBj8iuBX9OMcCYsNekcpiK0 qC4WA2LokJbpai9e0hRRyjzmlSm0rn7yKqkjoSCDoV3GtncXpCaS+qhagcr+zcufT5Nh 2WSQfYGj/pBcO0g3GM2p3YolLB+W0SPYYv8ITAagS3YDJtHuYrftXVvuNADVBJlIP15F TvR+57hC39EqKg7VVgvlTbdKo+5O1rFYikcbuSP4RXIATD17epDa4coNUjMujar/8oHQ 3Adw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=btQ2aQOpJBYiXf/NtjbQkNM4ILDr0EnNrbjo5NqNxiQ=; b=eEYNUm8Pqx27JJ9gLGRrz+gcZ9Mzh2Efm19Ihmro1vgd36vmwI7h/PHKkP0WMkcp1o sECO+lOwzaOsfHV4yLapByXAaRfCwYfLCfE2PKRqfY6vDqYaRTVOZvuanKZWzWw455tf SLBWeoPSN+fYXKt4/HlCoXPgCpKejObvFda9Js0pbeUL8M6u0AZWz//FntUla1GPNm1D QsNo3Nr2L9GMBv/ZEvOcQ86j4xgcB0SRwiB5RWqtuYY55VqCdAOa93xIf5kXXS3M06mN lUD1074X/udlEmn61+Xv3EUfP3EjMVhuadmrUnra+oHONay8E+irUQOfrQInU66XZgm/ 8YKA== X-Gm-Message-State: AFeK/H2N5m0IYuFazfqWFK8n6Wa9/P3MS3W54zcStCsl6mIY6HEH64POEAuC4YPadqR/7POV X-Received: by 10.55.135.66 with SMTP id j63mr1752419qkd.310.1489612796755; Wed, 15 Mar 2017 14:19:56 -0700 (PDT) Received: from mutt-hbsd ([63.88.83.66]) by smtp.gmail.com with ESMTPSA id h184sm2143206qkf.68.2017.03.15.14.19.55 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 15 Mar 2017 14:19:55 -0700 (PDT) Date: Wed, 15 Mar 2017 17:19:54 -0400 From: Shawn Webb To: Konstantin Belousov Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315331 - in head/libexec/rtld-elf: . aarch64 amd64 arm i386 mips powerpc powerpc64 riscv sparc64 Message-ID: <20170315211954.cspzjr7xltemzfv2@mutt-hbsd> References: <201703152111.v2FLBwrD051923@repo.freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="4jmumflztpb3vfoj" Content-Disposition: inline In-Reply-To: <201703152111.v2FLBwrD051923@repo.freebsd.org> X-Operating-System: FreeBSD mutt-hbsd 12.0-CURRENT-HBSD FreeBSD 12.0-CURRENT-HBSD X-PGP-Key: http://pgp.mit.edu/pks/lookup?op=vindex&search=0x6A84658F52456EEE User-Agent: NeoMutt/20170206 (1.7.2) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:19:58 -0000 --4jmumflztpb3vfoj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Mar 15, 2017 at 09:11:58PM +0000, Konstantin Belousov wrote: > Author: kib > Date: Wed Mar 15 21:11:57 2017 > New Revision: 315331 > URL: https://svnweb.freebsd.org/changeset/base/315331 >=20 > Log: > Implement LD_BIND_NOT knob for rtld. > =20 > From the manpage: > When set to a nonempty string, prevents modifications of the PLT slots > when doing bindings. As result, each call of the PLT-resolved > function is resolved. In combination with debug output, this provides > complete account of all bind actions at runtime. > =20 > Same feature exists on Linux and Solaris. > =20 > Sponsored by: The FreeBSD Foundation > MFC after: 2 weeks Hey Kostik, I'm curious what the use case is for this. When would someone use LD_BIND_NOT? Thanks, --=20 Shawn Webb Cofounder and Security Engineer HardenedBSD GPG Key ID: 0x6A84658F52456EEE GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89 3D9E 6A84 658F 5245 6EEE --4jmumflztpb3vfoj Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEKrq2ve9q9Ia+iT2eaoRlj1JFbu4FAljJr/cACgkQaoRlj1JF bu6JNRAAgxdSHHDaR1eUyqu8nANAJi0pEqlm6H2eQOiDWJf/97bV+yoxpc/1PUMO 8dJyqzDlEqKS+Y29qv/I5o2+SCp9IG/YyePlK+sD2alTGzH07FzNXVJmINCRlSa+ jqgobaKkXMUgkdQOLFOuPPptcAazbg1UJ0jGNt9Kh4RRM0WG4ivLzz4/JS5JZZjO DSWBY9f4T+uJXWaVdeASN+AHyKva4g/fIdGhJ0s9ZXdS4n2jsZfkteroCg4Uu412 lkK0QTxdrAyHAFzpOLkMTFGg3hKoTQHzbOiChn1FJN8Uq/ZA4CirZXGOeKZDb4MU w8qM2MAk3Th6DkH5gZS0TooXcPSVnruEZNj/vq2BojMv5xYzTQIbRpbZwuAmVrid Wu+BVCNKkGcMI3O9elKoq6McYamPZMGQ1VLyA6pNDmxX9I3Asr3NQfM3DWp9zpey 9wX6MpWA4RSVmp5kUzSNILqizlCkQjWaMDX0hfkyDawgJMcxuv2rQPvtX1j1QisN gOO4b3a33ybZr0EoI4VUHTex+KaJQCG8FACNOJ/nhDLmRfrPpik3Oagdqi8yEnpn uAzDytmtVMpGh0W1vSHvOlw5QNAxPMr0r8dDRfuHF1NVKd0gwdZU6xTx/p/w7B8E sF1Uo9sS7/dL4J+rvnNCIOjW8EP3q/TooetAwQMcfoKK7yWb1OQ= =cY8V -----END PGP SIGNATURE----- --4jmumflztpb3vfoj-- From owner-svn-src-all@freebsd.org Wed Mar 15 21:20:19 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 58269D0DFBA; Wed, 15 Mar 2017 21:20:19 +0000 (UTC) (envelope-from erj@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 E38FB1008; Wed, 15 Mar 2017 21:20:18 +0000 (UTC) (envelope-from erj@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FLKIiC053003; Wed, 15 Mar 2017 21:20:18 GMT (envelope-from erj@FreeBSD.org) Received: (from erj@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FLKHUs052999; Wed, 15 Mar 2017 21:20:17 GMT (envelope-from erj@FreeBSD.org) Message-Id: <201703152120.v2FLKHUs052999@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: erj set sender to erj@FreeBSD.org using -f From: Eric Joyner Date: Wed, 15 Mar 2017 21:20:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r315333 - in stable/10/sys: conf dev/ixgbe modules/ix modules/ixv X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 21:20:19 -0000 Author: erj Date: Wed Mar 15 21:20:17 2017 New Revision: 315333 URL: https://svnweb.freebsd.org/changeset/base/315333 Log: ixgbe(4): Update to 3.2.11-k Includes: 1. Support for X553 (Denverton) Ethernet devices. 2. Initialization code refactoring. 3. ixgbe-specific netmap code moved to ixgbe folder (but not removed from dev/netmap/). 4. VF driver full split. Some cleanup can be had due to redundant code, but this split goes inline with the refactoring. NOTE: This is a direct commit to stable/10. Newer branches will receive an iflib-converted version of ixgbe, with these updates included, instead. Differential Revision: https://reviews.freebsd.org/D9310 Submitted by: Jeb Cramer (jeb.j.cramer@intel.com) Tested by: Jeffrey Pieper (jeffrey.e.pieper@intel.com) Sponsored by: Intel Corporation Added: stable/10/sys/dev/ixgbe/if_bypass.c (contents, props changed) stable/10/sys/dev/ixgbe/if_fdir.c (contents, props changed) stable/10/sys/dev/ixgbe/if_sriov.c (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_bypass.h (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_fdir.h (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_features.h (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_netmap.c (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_netmap.h (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_rss.h (contents, props changed) stable/10/sys/dev/ixgbe/ixgbe_sriov.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_bypass.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_fdir.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_features.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_mbx.c (contents, props changed) stable/10/sys/dev/ixgbe/ixv_mbx.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_netmap.c (contents, props changed) stable/10/sys/dev/ixgbe/ixv_netmap.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_osdep.c (contents, props changed) stable/10/sys/dev/ixgbe/ixv_osdep.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_rss.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_sriov.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_txrx.c (contents, props changed) stable/10/sys/dev/ixgbe/ixv_type.h (contents, props changed) stable/10/sys/dev/ixgbe/ixv_vf.c (contents, props changed) stable/10/sys/dev/ixgbe/ixv_vf.h (contents, props changed) Deleted: stable/10/sys/dev/ixgbe/ixgbe_vf.c stable/10/sys/dev/ixgbe/ixgbe_vf.h Modified: stable/10/sys/conf/files stable/10/sys/dev/ixgbe/if_ix.c stable/10/sys/dev/ixgbe/if_ixv.c stable/10/sys/dev/ixgbe/ix_txrx.c stable/10/sys/dev/ixgbe/ixgbe.h stable/10/sys/dev/ixgbe/ixgbe_82598.c stable/10/sys/dev/ixgbe/ixgbe_82598.h stable/10/sys/dev/ixgbe/ixgbe_82599.c stable/10/sys/dev/ixgbe/ixgbe_82599.h stable/10/sys/dev/ixgbe/ixgbe_api.c stable/10/sys/dev/ixgbe/ixgbe_api.h stable/10/sys/dev/ixgbe/ixgbe_common.c stable/10/sys/dev/ixgbe/ixgbe_common.h stable/10/sys/dev/ixgbe/ixgbe_dcb.c stable/10/sys/dev/ixgbe/ixgbe_dcb.h stable/10/sys/dev/ixgbe/ixgbe_dcb_82598.c stable/10/sys/dev/ixgbe/ixgbe_dcb_82598.h stable/10/sys/dev/ixgbe/ixgbe_dcb_82599.c stable/10/sys/dev/ixgbe/ixgbe_dcb_82599.h stable/10/sys/dev/ixgbe/ixgbe_mbx.c stable/10/sys/dev/ixgbe/ixgbe_mbx.h stable/10/sys/dev/ixgbe/ixgbe_osdep.c stable/10/sys/dev/ixgbe/ixgbe_osdep.h stable/10/sys/dev/ixgbe/ixgbe_phy.c stable/10/sys/dev/ixgbe/ixgbe_phy.h stable/10/sys/dev/ixgbe/ixgbe_type.h stable/10/sys/dev/ixgbe/ixgbe_x540.c stable/10/sys/dev/ixgbe/ixgbe_x540.h stable/10/sys/dev/ixgbe/ixgbe_x550.c stable/10/sys/dev/ixgbe/ixgbe_x550.h stable/10/sys/modules/ix/Makefile stable/10/sys/modules/ixv/Makefile Modified: stable/10/sys/conf/files ============================================================================== --- stable/10/sys/conf/files Wed Mar 15 21:17:45 2017 (r315332) +++ stable/10/sys/conf/files Wed Mar 15 21:20:17 2017 (r315333) @@ -1765,6 +1765,14 @@ dev/ixgbe/if_ixv.c optional ixv inet | compile-with "${NORMAL_C} -I$S/dev/ixgbe -DSMP" dev/ixgbe/ix_txrx.c optional ix inet | ixv inet | ixgbe inet \ compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/if_bypass.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/if_fdir.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/if_sriov.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixgbe_netmap.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_phy.c optional ix inet | ixv inet | ixgbe inet \ compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_osdep.c optional ix inet | ixv inet | ixgbe inet \ @@ -1775,8 +1783,6 @@ dev/ixgbe/ixgbe_common.c optional ix ine compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_mbx.c optional ix inet | ixv inet | ixgbe inet \ compile-with "${NORMAL_C} -I$S/dev/ixgbe" -dev/ixgbe/ixgbe_vf.c optional ix inet | ixv inet | ixgbe inet \ - compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_82598.c optional ix inet | ixv inet | ixgbe inet \ compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_82599.c optional ix inet | ixv inet | ixgbe inet \ @@ -1791,6 +1797,16 @@ dev/ixgbe/ixgbe_dcb_82598.c optional ix compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixgbe/ixgbe_dcb_82599.c optional ix inet | ixv inet | ixgbe inet \ compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixv_mbx.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixv_netmap.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixv_osdep.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixv_txrx.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" +dev/ixgbe/ixv_vf.c optional ix inet | ixv inet | ixgbe inet \ + compile-with "${NORMAL_C} -I$S/dev/ixgbe" dev/ixl/if_ixl.c optional ixl inet \ compile-with "${NORMAL_C} -I$S/dev/ixl" dev/ixl/if_ixlv.c optional ixlv inet \ Added: stable/10/sys/dev/ixgbe/if_bypass.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/sys/dev/ixgbe/if_bypass.c Wed Mar 15 21:20:17 2017 (r315333) @@ -0,0 +1,808 @@ +/****************************************************************************** + + Copyright (c) 2001-2017, Intel Corporation + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + 3. Neither the name of the Intel Corporation nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + +******************************************************************************/ +/*$FreeBSD$*/ + + +#include "ixgbe.h" + +/************************************************************************ + * ixgbe_bypass_mutex_enter + * + * Mutex support for the bypass feature. Using a dual lock + * to facilitate a privileged access to the watchdog update + * over other threads. + ************************************************************************/ +static void +ixgbe_bypass_mutex_enter(struct adapter *adapter) +{ + while (atomic_cmpset_int(&adapter->bypass.low, 0, 1) == 0) + usec_delay(3000); + while (atomic_cmpset_int(&adapter->bypass.high, 0, 1) == 0) + usec_delay(3000); + return; +} /* ixgbe_bypass_mutex_enter */ + +/************************************************************************ + * ixgbe_bypass_mutex_clear + ************************************************************************/ +static void +ixgbe_bypass_mutex_clear(struct adapter *adapter) +{ + while (atomic_cmpset_int(&adapter->bypass.high, 1, 0) == 0) + usec_delay(6000); + while (atomic_cmpset_int(&adapter->bypass.low, 1, 0) == 0) + usec_delay(6000); + return; +} /* ixgbe_bypass_mutex_clear */ + +/************************************************************************ + * ixgbe_bypass_wd_mutex_enter + * + * Watchdog entry is allowed to simply grab the high priority + ************************************************************************/ +static void +ixgbe_bypass_wd_mutex_enter(struct adapter *adapter) +{ + while (atomic_cmpset_int(&adapter->bypass.high, 0, 1) == 0) + usec_delay(3000); + return; +} /* ixgbe_bypass_wd_mutex_enter */ + +/************************************************************************ + * ixgbe_bypass_wd_mutex_clear + ************************************************************************/ +static void +ixgbe_bypass_wd_mutex_clear(struct adapter *adapter) +{ + while (atomic_cmpset_int(&adapter->bypass.high, 1, 0) == 0) + usec_delay(6000); + return; +} /* ixgbe_bypass_wd_mutex_clear */ + +/************************************************************************ + * ixgbe_get_bypass_time + ************************************************************************/ +static void +ixgbe_get_bypass_time(u32 *year, u32 *sec) +{ + struct timespec current; + + *year = 1970; /* time starts at 01/01/1970 */ + nanotime(¤t); + *sec = current.tv_sec; + + while(*sec > SEC_THIS_YEAR(*year)) { + *sec -= SEC_THIS_YEAR(*year); + (*year)++; + } +} /* ixgbe_get_bypass_time */ + +/************************************************************************ + * ixgbe_bp_version + * + * Display the feature version + ************************************************************************/ +static int +ixgbe_bp_version(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int version = 0; + u32 cmd; + + ixgbe_bypass_mutex_enter(adapter); + cmd = BYPASS_PAGE_CTL2 | BYPASS_WE; + cmd |= (BYPASS_EEPROM_VER_ADD << BYPASS_CTL2_OFFSET_SHIFT) & + BYPASS_CTL2_OFFSET_M; + if ((error = hw->mac.ops.bypass_rw(hw, cmd, &version) != 0)) + goto err; + msec_delay(100); + cmd &= ~BYPASS_WE; + if ((error = hw->mac.ops.bypass_rw(hw, cmd, &version) != 0)) + goto err; + ixgbe_bypass_mutex_clear(adapter); + version &= BYPASS_CTL2_DATA_M; + error = sysctl_handle_int(oidp, &version, 0, req); + return (error); +err: + ixgbe_bypass_mutex_clear(adapter); + return (error); + +} /* ixgbe_bp_version */ + +/************************************************************************ + * ixgbe_bp_set_state + * + * Show/Set the Bypass State: + * 1 = NORMAL + * 2 = BYPASS + * 3 = ISOLATE + * + * With no argument the state is displayed, + * passing a value will set it. + ************************************************************************/ +static int +ixgbe_bp_set_state(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int state = 0; + + /* Get the current state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, + BYPASS_PAGE_CTL0, &state); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + state = (state >> BYPASS_STATUS_OFF_SHIFT) & 0x3; + + error = sysctl_handle_int(oidp, &state, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check new state */ + switch (state) { + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + ixgbe_bypass_mutex_enter(adapter); + if ((error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_MODE_OFF_M, state) != 0)) + goto out; + /* Set AUTO back on so FW can receive events */ + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_MODE_OFF_M, BYPASS_AUTO); +out: + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_set_state */ + +/************************************************************************ + * The following routines control the operational + * "rules" of the feature, what behavior will occur + * when particular events occur. + * Values are: + * 0 - no change for the event (NOP) + * 1 - go to Normal operation + * 2 - go to Bypass operation + * 3 - go to Isolate operation + * Calling the entry with no argument just displays + * the current rule setting. + ************************************************************************/ + +/************************************************************************ + * ixgbe_bp_timeout + * + * This is to set the Rule for the watchdog, + * not the actual watchdog timeout value. + ************************************************************************/ +static int +ixgbe_bp_timeout(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int timeout = 0; + + /* Get the current value */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &timeout); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + timeout = (timeout >> BYPASS_WDTIMEOUT_SHIFT) & 0x3; + + error = sysctl_handle_int(oidp, &timeout, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check on the setting */ + switch (timeout) { + case BYPASS_NOP: + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + + /* Set the new state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_WDTIMEOUT_M, timeout << BYPASS_WDTIMEOUT_SHIFT); + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_timeout */ + +/************************************************************************ + * ixgbe_bp_main_on + ************************************************************************/ +static int +ixgbe_bp_main_on(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int main_on = 0; + + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &main_on); + main_on = (main_on >> BYPASS_MAIN_ON_SHIFT) & 0x3; + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + + error = sysctl_handle_int(oidp, &main_on, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check on the setting */ + switch (main_on) { + case BYPASS_NOP: + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + + /* Set the new state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_MAIN_ON_M, main_on << BYPASS_MAIN_ON_SHIFT); + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_main_on */ + +/************************************************************************ + * ixgbe_bp_main_off + ************************************************************************/ +static int +ixgbe_bp_main_off(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int main_off = 0; + + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &main_off); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + main_off = (main_off >> BYPASS_MAIN_OFF_SHIFT) & 0x3; + + error = sysctl_handle_int(oidp, &main_off, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check on the setting */ + switch (main_off) { + case BYPASS_NOP: + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + + /* Set the new state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_MAIN_OFF_M, main_off << BYPASS_MAIN_OFF_SHIFT); + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_main_off */ + +/************************************************************************ + * ixgbe_bp_aux_on + ************************************************************************/ +static int +ixgbe_bp_aux_on(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int aux_on = 0; + + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &aux_on); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + aux_on = (aux_on >> BYPASS_AUX_ON_SHIFT) & 0x3; + + error = sysctl_handle_int(oidp, &aux_on, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check on the setting */ + switch (aux_on) { + case BYPASS_NOP: + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + + /* Set the new state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_AUX_ON_M, aux_on << BYPASS_AUX_ON_SHIFT); + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_aux_on */ + +/************************************************************************ + * ixgbe_bp_aux_off + ************************************************************************/ +static int +ixgbe_bp_aux_off(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error = 0; + static int aux_off = 0; + + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &aux_off); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + aux_off = (aux_off >> BYPASS_AUX_OFF_SHIFT) & 0x3; + + error = sysctl_handle_int(oidp, &aux_off, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Sanity check on the setting */ + switch (aux_off) { + case BYPASS_NOP: + case BYPASS_NORM: + case BYPASS_BYPASS: + case BYPASS_ISOLATE: + break; + default: + return (EINVAL); + } + + /* Set the new state */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, + BYPASS_AUX_OFF_M, aux_off << BYPASS_AUX_OFF_SHIFT); + ixgbe_bypass_mutex_clear(adapter); + usec_delay(6000); + return (error); +} /* ixgbe_bp_aux_off */ + +/************************************************************************ + * ixgbe_bp_wd_set - Set the Watchdog timer value + * + * Valid settings are: + * - 0 will disable the watchdog + * - 1, 2, 3, 4, 8, 16, 32 + * - anything else is invalid and will be ignored + ************************************************************************/ +static int +ixgbe_bp_wd_set(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + int error, tmp; + static int timeout = 0; + u32 mask, arg = BYPASS_PAGE_CTL0; + + /* Get the current hardware value */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL0, &tmp); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (error); + /* + * If armed keep the displayed value, + * else change the display to zero. + */ + if ((tmp & (0x1 << BYPASS_WDT_ENABLE_SHIFT)) == 0) + timeout = 0; + + error = sysctl_handle_int(oidp, &timeout, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + mask = BYPASS_WDT_ENABLE_M; + switch (timeout) { + case 0: /* disables the timer */ + break; + case 1: + arg = BYPASS_WDT_1_5 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 2: + arg = BYPASS_WDT_2 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 3: + arg = BYPASS_WDT_3 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 4: + arg = BYPASS_WDT_4 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 8: + arg = BYPASS_WDT_8 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 16: + arg = BYPASS_WDT_16 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + case 32: + arg = BYPASS_WDT_32 << BYPASS_WDT_TIME_SHIFT; + arg |= 0x1 << BYPASS_WDT_ENABLE_SHIFT; + mask |= BYPASS_WDT_VALUE_M; + break; + default: + return (EINVAL); + } + /* Set the new watchdog */ + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL0, mask, arg); + ixgbe_bypass_mutex_clear(adapter); + + return (error); +} /* ixgbe_bp_wd_set */ + +/************************************************************************ + * ixgbe_bp_wd_reset - Reset the Watchdog timer + * + * To activate this it must be called with any argument. + ************************************************************************/ +static int +ixgbe_bp_wd_reset(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + u32 sec, year; + int cmd, count = 0, error = 0; + int reset_wd = 0; + + error = sysctl_handle_int(oidp, &reset_wd, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + cmd = BYPASS_PAGE_CTL1 | BYPASS_WE | BYPASS_CTL1_WDT_PET; + + /* Resync the FW time while writing to CTL1 anyway */ + ixgbe_get_bypass_time(&year, &sec); + + cmd |= (sec & BYPASS_CTL1_TIME_M) | BYPASS_CTL1_VALID; + cmd |= BYPASS_CTL1_OFFTRST; + + ixgbe_bypass_wd_mutex_enter(adapter); + error = hw->mac.ops.bypass_rw(hw, cmd, &reset_wd); + + /* Read until it matches what we wrote, or we time out */ + do { + if (count++ > 10) { + error = IXGBE_BYPASS_FW_WRITE_FAILURE; + break; + } + if (hw->mac.ops.bypass_rw(hw, BYPASS_PAGE_CTL1, &reset_wd)) { + error = IXGBE_ERR_INVALID_ARGUMENT; + break; + } + } while (!hw->mac.ops.bypass_valid_rd(cmd, reset_wd)); + + reset_wd = 0; + ixgbe_bypass_wd_mutex_clear(adapter); + return (error); +} /* ixgbe_bp_wd_reset */ + +/************************************************************************ + * ixgbe_bp_log - Display the bypass log + * + * You must pass a non-zero arg to sysctl + ************************************************************************/ +static int +ixgbe_bp_log(SYSCTL_HANDLER_ARGS) +{ + struct adapter *adapter = (struct adapter *) arg1; + struct ixgbe_hw *hw = &adapter->hw; + u32 cmd, base, head; + u32 log_off, count = 0; + static int status = 0; + u8 data; + struct ixgbe_bypass_eeprom eeprom[BYPASS_MAX_LOGS]; + int i, error = 0; + + error = sysctl_handle_int(oidp, &status, 0, req); + if ((error) || (req->newptr == NULL)) + return (error); + + /* Keep the log display single-threaded */ + while (atomic_cmpset_int(&adapter->bypass.log, 0, 1) == 0) + usec_delay(3000); + + ixgbe_bypass_mutex_enter(adapter); + + /* Find Current head of the log eeprom offset */ + cmd = BYPASS_PAGE_CTL2 | BYPASS_WE; + cmd |= (0x1 << BYPASS_CTL2_OFFSET_SHIFT) & BYPASS_CTL2_OFFSET_M; + error = hw->mac.ops.bypass_rw(hw, cmd, &status); + if (error) + goto unlock_err; + + /* wait for the write to stick */ + msec_delay(100); + + /* Now read the results */ + cmd &= ~BYPASS_WE; + error = hw->mac.ops.bypass_rw(hw, cmd, &status); + if (error) + goto unlock_err; + + ixgbe_bypass_mutex_clear(adapter); + + base = status & BYPASS_CTL2_DATA_M; + head = (status & BYPASS_CTL2_HEAD_M) >> BYPASS_CTL2_HEAD_SHIFT; + + /* address of the first log */ + log_off = base + (head * 5); + + /* extract all the log entries */ + while (count < BYPASS_MAX_LOGS) { + eeprom[count].logs = 0; + eeprom[count].actions = 0; + + /* Log 5 bytes store in on u32 and a u8 */ + for (i = 0; i < 4; i++) { + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rd_eep(hw, log_off + i, + &data); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (-EINVAL); + eeprom[count].logs += data << (8 * i); + } + + ixgbe_bypass_mutex_enter(adapter); + error = hw->mac.ops.bypass_rd_eep(hw, + log_off + i, &eeprom[count].actions); + ixgbe_bypass_mutex_clear(adapter); + if (error) + return (-EINVAL); + + /* Quit if not a unread log */ + if (!(eeprom[count].logs & BYPASS_LOG_CLEAR_M)) + break; + /* + * Log looks good so store the address where it's + * Unread Log bit is so we can clear it after safely + * pulling out all of the log data. + */ + eeprom[count].clear_off = log_off; + + count++; + head = head ? head - 1 : BYPASS_MAX_LOGS; + log_off = base + (head * 5); + } + + /* reverse order (oldest first) for output */ + while (count--) { + int year; + u32 mon, days, hours, min, sec; + u32 time = eeprom[count].logs & BYPASS_LOG_TIME_M; + u32 event = (eeprom[count].logs & BYPASS_LOG_EVENT_M) >> + BYPASS_LOG_EVENT_SHIFT; + u8 action = eeprom[count].actions & BYPASS_LOG_ACTION_M; + u16 day_mon[2][13] = { + {0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365}, + {0, 31, 59, 91, 121, 152, 182, 213, 244, 274, 305, 335, 366} + }; + char *event_str[] = {"unknown", "main on", "aux on", + "main off", "aux off", "WDT", "user" }; + char *action_str[] = {"ignore", "normal", "bypass", "isolate",}; + + /* verify vaild data 1 - 6 */ + if (event < BYPASS_EVENT_MAIN_ON || event > BYPASS_EVENT_USR) + event = 0; + + /* + * time is in sec's this year, so convert to something + * printable. + */ + ixgbe_get_bypass_time(&year, &sec); + days = time / SEC_PER_DAY; + for (i = 11; days < day_mon[LEAP_YR(year)][i]; i--) + continue; + mon = i + 1; /* display month as 1-12 */ + time -= (day_mon[LEAP_YR(year)][i] * SEC_PER_DAY); + days = (time / SEC_PER_DAY) + 1; /* first day is 1 */ + time %= SEC_PER_DAY; + hours = time / (60 * 60); + time %= (60 * 60); + min = time / 60; + sec = time % 60; + device_printf(adapter->dev, + "UT %02d/%02d %02d:%02d:%02d %8.8s -> %7.7s\n", + mon, days, hours, min, sec, event_str[event], + action_str[action]); + cmd = BYPASS_PAGE_CTL2 | BYPASS_WE | BYPASS_CTL2_RW; + cmd |= ((eeprom[count].clear_off + 3) + << BYPASS_CTL2_OFFSET_SHIFT) & BYPASS_CTL2_OFFSET_M; + cmd |= ((eeprom[count].logs & ~BYPASS_LOG_CLEAR_M) >> 24); + + ixgbe_bypass_mutex_enter(adapter); + + error = hw->mac.ops.bypass_rw(hw, cmd, &status); + + /* wait for the write to stick */ + msec_delay(100); + + ixgbe_bypass_mutex_clear(adapter); + + if (error) + return (-EINVAL); + } + + status = 0; /* reset */ + /* Another log command can now run */ + while (atomic_cmpset_int(&adapter->bypass.log, 1, 0) == 0) + usec_delay(3000); + return(error); + +unlock_err: + ixgbe_bypass_mutex_clear(adapter); + status = 0; /* reset */ + while (atomic_cmpset_int(&adapter->bypass.log, 1, 0) == 0) + usec_delay(3000); + return (-EINVAL); +} /* ixgbe_bp_log */ + +/************************************************************************ + * ixgbe_bypass_init - Set up infrastructure for the bypass feature + * + * Do time and sysctl initialization here. This feature is + * only enabled for the first port of a bypass adapter. + ************************************************************************/ +void +ixgbe_bypass_init(struct adapter *adapter) +{ + struct ixgbe_hw *hw = &adapter->hw; + device_t dev = adapter->dev; + struct sysctl_oid *bp_node; + struct sysctl_oid_list *bp_list; + u32 mask, value, sec, year; + + if (!(adapter->feat_cap & IXGBE_FEATURE_BYPASS)) + return; + + /* First set up time for the hardware */ + ixgbe_get_bypass_time(&year, &sec); + + mask = BYPASS_CTL1_TIME_M + | BYPASS_CTL1_VALID_M + | BYPASS_CTL1_OFFTRST_M; + + value = (sec & BYPASS_CTL1_TIME_M) + | BYPASS_CTL1_VALID + | BYPASS_CTL1_OFFTRST; + + ixgbe_bypass_mutex_enter(adapter); + hw->mac.ops.bypass_set(hw, BYPASS_PAGE_CTL1, mask, value); + ixgbe_bypass_mutex_clear(adapter); + + /* Now set up the SYSCTL infrastructure */ + + /* + * The log routine is kept separate from the other + * children so a general display command like: + * `sysctl dev.ix.0.bypass` will not show the log. + */ + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), + SYSCTL_CHILDREN(device_get_sysctl_tree(dev)), + OID_AUTO, "bypass_log", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_log, "I", "Bypass Log"); + + /* All other setting are hung from the 'bypass' node */ + bp_node = SYSCTL_ADD_NODE(device_get_sysctl_ctx(dev), + SYSCTL_CHILDREN(device_get_sysctl_tree(dev)), + OID_AUTO, "bypass", CTLFLAG_RD, NULL, "Bypass"); + + bp_list = SYSCTL_CHILDREN(bp_node); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "version", CTLTYPE_INT | CTLFLAG_RD, + adapter, 0, ixgbe_bp_version, "I", "Bypass Version"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "state", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_set_state, "I", "Bypass State"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "timeout", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_timeout, "I", "Bypass Timeout"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "main_on", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_main_on, "I", "Bypass Main On"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "main_off", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_main_off, "I", "Bypass Main Off"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "aux_on", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_aux_on, "I", "Bypass Aux On"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "aux_off", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_aux_off, "I", "Bypass Aux Off"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "wd_set", CTLTYPE_INT | CTLFLAG_RW, + adapter, 0, ixgbe_bp_wd_set, "I", "Set BP Watchdog"); + + SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev), bp_list, + OID_AUTO, "wd_reset", CTLTYPE_INT | CTLFLAG_WR, + adapter, 0, ixgbe_bp_wd_reset, "S", "Bypass WD Reset"); + + adapter->feat_en |= IXGBE_FEATURE_BYPASS; + + return; +} /* ixgbe_bypass_init */ + Added: stable/10/sys/dev/ixgbe/if_fdir.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ stable/10/sys/dev/ixgbe/if_fdir.c Wed Mar 15 21:20:17 2017 (r315333) @@ -0,0 +1,154 @@ +/****************************************************************************** + + Copyright (c) 2001-2017, Intel Corporation + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + 3. Neither the name of the Intel Corporation nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + +******************************************************************************/ +/*$FreeBSD$*/ + +#include "ixgbe.h" + +#ifdef IXGBE_FDIR + +void +ixgbe_init_fdir(struct adapter *adapter) +{ + u32 hdrm = 32 << fdir_pballoc; + + if (!(adapter->feat_en & IXGBE_FEATURE_FDIR)) + return; + + adapter->hw.mac.ops.setup_rxpba(&adapter->hw, 0, hdrm, + PBA_STRATEGY_EQUAL); + ixgbe_init_fdir_signature_82599(&adapter->hw, fdir_pballoc); +} /* ixgbe_init_fdir */ + +void +ixgbe_reinit_fdir(void *context, int pending) +{ + struct adapter *adapter = context; + struct ifnet *ifp = adapter->ifp; + + if (!(adapter->feat_en & IXGBE_FEATURE_FDIR)) + return; + if (adapter->fdir_reinit != 1) /* Shouldn't happen */ + return; + ixgbe_reinit_fdir_tables_82599(&adapter->hw); + adapter->fdir_reinit = 0; + /* re-enable flow director interrupts */ + IXGBE_WRITE_REG(&adapter->hw, IXGBE_EIMS, IXGBE_EIMS_FLOW_DIR); + /* Restart the interface */ + ifp->if_drv_flags |= IFF_DRV_RUNNING; +} /* ixgbe_reinit_fdir */ + +/************************************************************************ + * ixgbe_atr + * + * Parse packet headers so that Flow Director can make + * a hashed filter table entry allowing traffic flows + * to be identified and kept on the same cpu. This + * would be a performance hit, but we only do it at + * IXGBE_FDIR_RATE of packets. + ************************************************************************/ +void +ixgbe_atr(struct tx_ring *txr, struct mbuf *mp) +{ + struct adapter *adapter = txr->adapter; + struct ix_queue *que; + struct ip *ip; + struct tcphdr *th; + struct udphdr *uh; + struct ether_vlan_header *eh; + union ixgbe_atr_hash_dword input = {.dword = 0}; + union ixgbe_atr_hash_dword common = {.dword = 0}; + int ehdrlen, ip_hlen; + u16 etype; + + eh = mtod(mp, struct ether_vlan_header *); + if (eh->evl_encap_proto == htons(ETHERTYPE_VLAN)) { + ehdrlen = ETHER_HDR_LEN + ETHER_VLAN_ENCAP_LEN; + etype = eh->evl_proto; + } else { + ehdrlen = ETHER_HDR_LEN; + etype = eh->evl_encap_proto; + } + + /* Only handling IPv4 */ + if (etype != htons(ETHERTYPE_IP)) + return; + + ip = (struct ip *)(mp->m_data + ehdrlen); + ip_hlen = ip->ip_hl << 2; + + /* check if we're UDP or TCP */ + switch (ip->ip_p) { + case IPPROTO_TCP: + th = (struct tcphdr *)((caddr_t)ip + ip_hlen); + /* src and dst are inverted */ + common.port.dst ^= th->th_sport; + common.port.src ^= th->th_dport; + input.formatted.flow_type ^= IXGBE_ATR_FLOW_TYPE_TCPV4; + break; + case IPPROTO_UDP: + uh = (struct udphdr *)((caddr_t)ip + ip_hlen); + /* src and dst are inverted */ + common.port.dst ^= uh->uh_sport; + common.port.src ^= uh->uh_dport; + input.formatted.flow_type ^= IXGBE_ATR_FLOW_TYPE_UDPV4; + break; + default: + return; + } + + input.formatted.vlan_id = htobe16(mp->m_pkthdr.ether_vtag); + if (mp->m_pkthdr.ether_vtag) + common.flex_bytes ^= htons(ETHERTYPE_VLAN); + else + common.flex_bytes ^= etype; + common.ip ^= ip->ip_src.s_addr ^ ip->ip_dst.s_addr; + + que = &adapter->queues[txr->me]; + /* + * This assumes the Rx queue and Tx + * queue are bound to the same CPU + */ + ixgbe_fdir_add_signature_filter_82599(&adapter->hw, + input, common, que->msix); +} /* ixgbe_atr */ *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-all@freebsd.org Wed Mar 15 22:36:27 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id B9B5DD0E53D; Wed, 15 Mar 2017 22:36:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7C2B617D1; Wed, 15 Mar 2017 22:36:27 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FMaQXP085331; Wed, 15 Mar 2017 22:36:26 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FMaQMJ085330; Wed, 15 Mar 2017 22:36:26 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201703152236.v2FMaQMJ085330@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 15 Mar 2017 22:36:26 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315334 - head/usr.bin/kdump X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 22:36:27 -0000 Author: jhb Date: Wed Mar 15 22:36:26 2017 New Revision: 315334 URL: https://svnweb.freebsd.org/changeset/base/315334 Log: Decode arguments to chflagsat(). Modified: head/usr.bin/kdump/kdump.c Modified: head/usr.bin/kdump/kdump.c ============================================================================== --- head/usr.bin/kdump/kdump.c Wed Mar 15 21:20:17 2017 (r315333) +++ head/usr.bin/kdump/kdump.c Wed Mar 15 22:36:26 2017 (r315334) @@ -840,6 +840,7 @@ ktrsyscall(struct ktr_syscall *ktr, u_in quad_slots = 1; switch (ktr->ktr_code) { case SYS_bindat: + case SYS_chflagsat: case SYS_connectat: case SYS_faccessat: case SYS_fchmodat: @@ -982,6 +983,7 @@ ktrsyscall(struct ktr_syscall *ktr, u_in narg--; break; case SYS_chflags: + case SYS_chflagsat: case SYS_fchflags: case SYS_lchflags: print_number(ip, narg, c); From owner-svn-src-all@freebsd.org Wed Mar 15 22:39:17 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 364A4D0E5CA; Wed, 15 Mar 2017 22:39:17 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0382419A0; Wed, 15 Mar 2017 22:39:16 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FMdGpn085469; Wed, 15 Mar 2017 22:39:16 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FMdGbL085468; Wed, 15 Mar 2017 22:39:16 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201703152239.v2FMdGbL085468@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 15 Mar 2017 22:39:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315335 - head/usr.bin/truss X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 22:39:17 -0000 Author: jhb Date: Wed Mar 15 22:39:15 2017 New Revision: 315335 URL: https://svnweb.freebsd.org/changeset/base/315335 Log: Remove duplicate argument from linux_stat64() decoding. Modified: head/usr.bin/truss/syscalls.c Modified: head/usr.bin/truss/syscalls.c ============================================================================== --- head/usr.bin/truss/syscalls.c Wed Mar 15 22:36:26 2017 (r315334) +++ head/usr.bin/truss/syscalls.c Wed Mar 15 22:39:15 2017 (r315335) @@ -377,8 +377,8 @@ static struct syscall decoded_syscalls[] .args = { { Name, 0 }, { Name | OUT, 1 }, { Int, 2 } } }, { .name = "linux_socketcall", .ret_type = 1, .nargs = 2, .args = { { Int, 0 }, { LinuxSockArgs, 1 } } }, - { .name = "linux_stat64", .ret_type = 1, .nargs = 3, - .args = { { Name | IN, 0 }, { Ptr | OUT, 1 }, { Ptr | IN, 1 } } }, + { .name = "linux_stat64", .ret_type = 1, .nargs = 2, + .args = { { Name | IN, 0 }, { Ptr | OUT, 1 } } }, /* CloudABI system calls. */ { .name = "cloudabi_sys_clock_res_get", .ret_type = 1, .nargs = 1, From owner-svn-src-all@freebsd.org Wed Mar 15 22:42:45 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DDD7DD0E883; Wed, 15 Mar 2017 22:42:45 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [199.48.133.146]) by mx1.freebsd.org (Postfix) with ESMTP id C7B451F67; Wed, 15 Mar 2017 22:42:45 +0000 (UTC) (envelope-from vangyzen@FreeBSD.org) Received: from ford.home.vangyzen.net (unknown [76.164.15.242]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 63857564F6; Wed, 15 Mar 2017 17:42:44 -0500 (CDT) Subject: Re: svn commit: r315280 - in head/sys: kern sys To: Ngie Cooper References: <201703141906.v2EJ6i0x096677@repo.freebsd.org> Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" From: Eric van Gyzen Message-ID: <1c228422-638c-63fe-fdfa-ba92ae196781@FreeBSD.org> Date: Wed, 15 Mar 2017 17:42:37 -0500 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 22:42:46 -0000 On 03/14/2017 17:16, Ngie Cooper wrote: > I'll take a look at running "open_posix_testsuite" from LTP and (when > time/appropriate), I'll help out with integrating in the > clock_nanosleep tests from NetBSD > (contrib/netbsd-tests/lib/libc/sys/t_clock_nanosleep.c, ). I hadn't heard of open_posix_testsuite. That sounds perfect. I'm very interested in your results. There isn't a lot of automated testing of {clock_,}nanosleep in our tree, as far as I can see. By the way, clock_nanosleep() is up for review. I took the liberty of making you a subscriber. https://reviews.freebsd.org/D10020 Eric From owner-svn-src-all@freebsd.org Wed Mar 15 22:50:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4261ED0EA33; Wed, 15 Mar 2017 22:50:21 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B343112B3; Wed, 15 Mar 2017 22:50:20 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v2FMoFkX068702 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 16 Mar 2017 00:50:15 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v2FMoFkX068702 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v2FMoEIu068701; Thu, 16 Mar 2017 00:50:14 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 16 Mar 2017 00:50:14 +0200 From: Konstantin Belousov To: Shawn Webb Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315331 - in head/libexec/rtld-elf: . aarch64 amd64 arm i386 mips powerpc powerpc64 riscv sparc64 Message-ID: <20170315225014.GL16105@kib.kiev.ua> References: <201703152111.v2FLBwrD051923@repo.freebsd.org> <20170315211954.cspzjr7xltemzfv2@mutt-hbsd> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170315211954.cspzjr7xltemzfv2@mutt-hbsd> User-Agent: Mutt/1.8.0 (2017-02-23) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 22:50:21 -0000 On Wed, Mar 15, 2017 at 05:19:54PM -0400, Shawn Webb wrote: > On Wed, Mar 15, 2017 at 09:11:58PM +0000, Konstantin Belousov wrote: > > Author: kib > > Date: Wed Mar 15 21:11:57 2017 > > New Revision: 315331 > > URL: https://svnweb.freebsd.org/changeset/base/315331 > > > > Log: > > Implement LD_BIND_NOT knob for rtld. > > > > From the manpage: > > When set to a nonempty string, prevents modifications of the PLT slots > > when doing bindings. As result, each call of the PLT-resolved > > function is resolved. In combination with debug output, this provides > > complete account of all bind actions at runtime. > > > > Same feature exists on Linux and Solaris. > > > > Sponsored by: The FreeBSD Foundation > > MFC after: 2 weeks > > Hey Kostik, > > I'm curious what the use case is for this. When would someone use > LD_BIND_NOT? The commit message explicitely describes the supposed use case, which also triggered my implementation of the feature. From owner-svn-src-all@freebsd.org Wed Mar 15 22:58:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9DB37D0EF10; Wed, 15 Mar 2017 22:58:00 +0000 (UTC) (envelope-from jilles@stack.nl) Received: from mailout.stack.nl (mailout05.stack.nl [IPv6:2001:610:1108:5010::202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mailout.stack.nl", Issuer "CA Cert Signing Authority" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 6BD211A42; Wed, 15 Mar 2017 22:58:00 +0000 (UTC) (envelope-from jilles@stack.nl) Received: from snail.stack.nl (snail.stack.nl [IPv6:2001:610:1108:5010::131]) by mailout.stack.nl (Postfix) with ESMTP id 8C69A55; Wed, 15 Mar 2017 23:57:49 +0100 (CET) Received: by snail.stack.nl (Postfix, from userid 1677) id 7B6FC28497; Wed, 15 Mar 2017 23:57:49 +0100 (CET) Date: Wed, 15 Mar 2017 23:57:49 +0100 From: Jilles Tjoelker To: Konstantin Belousov Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315331 - in head/libexec/rtld-elf: . aarch64 amd64 arm i386 mips powerpc powerpc64 riscv sparc64 Message-ID: <20170315225749.GB8141@stack.nl> References: <201703152111.v2FLBwrD051923@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201703152111.v2FLBwrD051923@repo.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 22:58:00 -0000 On Wed, Mar 15, 2017 at 09:11:58PM +0000, Konstantin Belousov wrote: > Author: kib > Date: Wed Mar 15 21:11:57 2017 > New Revision: 315331 > URL: https://svnweb.freebsd.org/changeset/base/315331 > Log: > Implement LD_BIND_NOT knob for rtld. > From the manpage: > When set to a nonempty string, prevents modifications of the PLT slots > when doing bindings. As result, each call of the PLT-resolved > function is resolved. In combination with debug output, this provides > complete account of all bind actions at runtime. > Same feature exists on Linux and Solaris. Since this feature heavily affects timing (possibly making race conditions easier to exploit) and may prevent making parts of the GOT read-only, it seems a good idea to treat this environment variable as dangerous for setuid and setgid processes. -- Jilles Tjoelker From owner-svn-src-all@freebsd.org Wed Mar 15 23:08:12 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 70124D0E270; Wed, 15 Mar 2017 23:08:12 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2DF9310CB; Wed, 15 Mar 2017 23:08:12 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2FN8BJa097483; Wed, 15 Mar 2017 23:08:11 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FN8B7r097482; Wed, 15 Mar 2017 23:08:11 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201703152308.v2FN8B7r097482@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Wed, 15 Mar 2017 23:08:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315336 - head/usr.bin/truss X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 23:08:12 -0000 Author: jhb Date: Wed Mar 15 23:08:11 2017 New Revision: 315336 URL: https://svnweb.freebsd.org/changeset/base/315336 Log: Automate the handling of QUAD_ALIGN and QUAD_SLOTS. Previously, the offset in a system call description specified the array index of the start of a system call argument. For most system call arguments this was the same as the index of the argument in the function signature. 64-bit arguments (off_t and id_t values) passed on 32-bit platforms use two slots in the array however. This was handled by adding (QUAD_SLOTS - 1) to the slot indicies of any subsequent arguments after a 64-bit argument (though written as ("{ Quad, 1 }, { Int, 1 + QUAD_SLOTS }" rather than "{ Quad, 1 }, { Int, 2 + QUAD_SLOTS - 1 }"). If a system call contained multiple 64-bit arguments (such as posix_fadvise()), then additional arguments would need to use 'QUAD_SLOTS * 2' but remember to subtract 2 from the initial number, etc. In addition, 32-bit powerpc requires 64-bit arguments to be 64-bit aligned, so if the effective index in the array of a 64-bit argument is odd, it needs QUAD_ALIGN added to the current and any subsequent slots. However, if the effective index in the array of a 64-bit argument was even, QUAD_ALIGN was omitted. This approach was messy and error prone. This commit replaces it with automated pre-processing of the system call table to do fixups for 64-bit argument offsets. The offset in a system call description now indicates the index of an argument in the associated function call's signature. A fixup function is run against each decoded system call description during startup on 32-bit platforms. The fixup function maintains an 'offset' value which holds an offset to be added to each remaining system call argument's index. Initially offset is 0. When a 64-bit system call argument is encountered, the offset is first aligned to a 64-bit boundary (only on powerpc) and then incremented to account for the second argument slot used by the argument. This modified 'offset' is then applied to any remaining arguments. This approach does require a few things that were not previously required: 1) Each system call description must now list arguments in ascending order (existing ones all do) without using duplicate slots in the register array. A new assert() should catch any future descriptions which violate this rule. 2) A system call description is still permitted to omit arguments (though none currently do), but if the call accepts 64-bit arguments those cannot be omitted or incorrect results will be displated on 32-bit systems. Tested on: amd64 and i386 Modified: head/usr.bin/truss/syscalls.c Modified: head/usr.bin/truss/syscalls.c ============================================================================== --- head/usr.bin/truss/syscalls.c Wed Mar 15 22:39:15 2017 (r315335) +++ head/usr.bin/truss/syscalls.c Wed Mar 15 23:08:11 2017 (r315336) @@ -71,20 +71,6 @@ __FBSDID("$FreeBSD$"); #include "extern.h" #include "syscall.h" -/* 64-bit alignment on 32-bit platforms. */ -#if !defined(__LP64__) && defined(__powerpc__) -#define QUAD_ALIGN 1 -#else -#define QUAD_ALIGN 0 -#endif - -/* Number of slots needed for a 64-bit argument. */ -#ifdef __LP64__ -#define QUAD_SLOTS 1 -#else -#define QUAD_SLOTS 2 -#endif - /* * This should probably be in its own file, sorted alphabetically. */ @@ -154,7 +140,7 @@ static struct syscall decoded_syscalls[] { .name = "fstatfs", .ret_type = 1, .nargs = 2, .args = { { Int, 0 }, { StatFs | OUT, 1 } } }, { .name = "ftruncate", .ret_type = 1, .nargs = 2, - .args = { { Int | IN, 0 }, { QuadHex | IN, 1 + QUAD_ALIGN } } }, + .args = { { Int | IN, 0 }, { QuadHex | IN, 1 } } }, { .name = "futimens", .ret_type = 1, .nargs = 2, .args = { { Int, 0 }, { Timespec2 | IN, 1 } } }, { .name = "futimes", .ret_type = 1, .nargs = 2, @@ -210,8 +196,7 @@ static struct syscall decoded_syscalls[] .args = { { Atfd, 0 }, { Name, 1 }, { Atfd, 2 }, { Name, 3 }, { Atflags, 4 } } }, { .name = "lseek", .ret_type = 2, .nargs = 3, - .args = { { Int, 0 }, { QuadHex, 1 + QUAD_ALIGN }, - { Whence, 1 + QUAD_SLOTS + QUAD_ALIGN } } }, + .args = { { Int, 0 }, { QuadHex, 1 }, { Whence, 2 } } }, { .name = "lstat", .ret_type = 1, .nargs = 2, .args = { { Name | IN, 0 }, { Stat | OUT, 1 } } }, { .name = "lutimes", .ret_type = 1, .nargs = 2, @@ -230,7 +215,7 @@ static struct syscall decoded_syscalls[] .args = { { Atfd, 0 }, { Name, 1 }, { Octal, 2 }, { Int, 3 } } }, { .name = "mmap", .ret_type = 1, .nargs = 6, .args = { { Ptr, 0 }, { Int, 1 }, { Mprot, 2 }, { Mmapflags, 3 }, - { Int, 4 }, { QuadHex, 5 + QUAD_ALIGN } } }, + { Int, 4 }, { QuadHex, 5 } } }, { .name = "modfind", .ret_type = 1, .nargs = 1, .args = { { Name | IN, 0 } } }, { .name = "mount", .ret_type = 1, .nargs = 4, @@ -257,9 +242,7 @@ static struct syscall decoded_syscalls[] { .name = "posix_openpt", .ret_type = 1, .nargs = 1, .args = { { Open, 0 } } }, { .name = "procctl", .ret_type = 1, .nargs = 4, - .args = { { Idtype, 0 }, { Quad, 1 + QUAD_ALIGN }, - { Procctl, 1 + QUAD_ALIGN + QUAD_SLOTS }, - { Ptr, 2 + QUAD_ALIGN + QUAD_SLOTS } } }, + .args = { { Idtype, 0 }, { Quad, 1 }, { Procctl, 2 }, { Ptr, 3 } } }, { .name = "read", .ret_type = 1, .nargs = 3, .args = { { Int, 0 }, { BinString | OUT, 1 }, { Int, 2 } } }, { .name = "readlink", .ret_type = 1, .nargs = 3, @@ -326,7 +309,7 @@ static struct syscall decoded_syscalls[] { .name = "thr_self", .ret_type = 1, .nargs = 1, .args = { { Ptr, 0 } } }, { .name = "truncate", .ret_type = 1, .nargs = 2, - .args = { { Name | IN, 0 }, { QuadHex | IN, 1 + QUAD_ALIGN } } }, + .args = { { Name | IN, 0 }, { QuadHex | IN, 1 } } }, #if 0 /* Does not exist */ { .name = "umount", .ret_type = 1, .nargs = 2, @@ -349,11 +332,8 @@ static struct syscall decoded_syscalls[] .args = { { Int, 0 }, { ExitStatus | OUT, 1 }, { Waitoptions, 2 }, { Rusage | OUT, 3 } } }, { .name = "wait6", .ret_type = 1, .nargs = 6, - .args = { { Idtype, 0 }, { Quad, 1 + QUAD_ALIGN }, - { ExitStatus | OUT, 1 + QUAD_ALIGN + QUAD_SLOTS }, - { Waitoptions, 2 + QUAD_ALIGN + QUAD_SLOTS }, - { Rusage | OUT, 3 + QUAD_ALIGN + QUAD_SLOTS }, - { Ptr, 4 + QUAD_ALIGN + QUAD_SLOTS } } }, + .args = { { Idtype, 0 }, { Quad, 1 }, { ExitStatus | OUT, 2 }, + { Waitoptions, 3 }, { Rusage | OUT, 4 }, { Ptr, 5 } } }, { .name = "write", .ret_type = 1, .nargs = 3, .args = { { Int, 0 }, { BinString | IN, 1 }, { Int, 2 } } }, @@ -811,14 +791,65 @@ print_mask_arg(bool (*decoder)(FILE *, i fprintf(fp, "|0x%x", rem); } +#ifndef __LP64__ +/* + * Add argument padding to subsequent system calls afater a Quad + * syscall arguments as needed. This used to be done by hand in the + * decoded_syscalls table which was ugly and error prone. It is + * simpler to do the fixup of offsets at initalization time than when + * decoding arguments. + */ +static void +quad_fixup(struct syscall *sc) +{ + int offset, prev; + u_int i; + + offset = 0; + prev = -1; + for (i = 0; i < sc->nargs; i++) { + /* This arg type is a dummy that doesn't use offset. */ + if ((sc->args[i].type & ARG_MASK) == PipeFds) + continue; + + assert(prev < sc->args[i].offset); + prev = sc->args[i].offset; + sc->args[i].offset += offset; + switch (sc->args[i].type & ARG_MASK) { + case Quad: + case QuadHex: +#ifdef __powerpc__ + /* + * 64-bit arguments on 32-bit powerpc must be + * 64-bit aligned. If the current offset is + * not aligned, the calling convention inserts + * a 32-bit pad argument that should be skipped. + */ + if (sc->args[i].offset % 2 == 1) { + sc->args[i].offset++; + offset++; + } +#endif + offset++; + default: + break; + } + } +} +#endif + void init_syscalls(void) { struct syscall *sc; STAILQ_INIT(&syscalls); - for (sc = decoded_syscalls; sc->name != NULL; sc++) + for (sc = decoded_syscalls; sc->name != NULL; sc++) { +#ifndef __LP64__ + quad_fixup(sc); +#endif STAILQ_INSERT_HEAD(&syscalls, sc, entries); + } } static struct syscall * From owner-svn-src-all@freebsd.org Wed Mar 15 23:47:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1FA69D0EDC0; Wed, 15 Mar 2017 23:47:21 +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 E36DE14C9; Wed, 15 Mar 2017 23:47:20 +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 v2FNlK1P013825; Wed, 15 Mar 2017 23:47:20 GMT (envelope-from kib@FreeBSD.org) Received: (from kib@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2FNlKws013824; Wed, 15 Mar 2017 23:47:20 GMT (envelope-from kib@FreeBSD.org) Message-Id: <201703152347.v2FNlKws013824@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kib set sender to kib@FreeBSD.org using -f From: Konstantin Belousov Date: Wed, 15 Mar 2017 23:47:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315337 - head/libexec/rtld-elf X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 23:47:21 -0000 Author: kib Date: Wed Mar 15 23:47:19 2017 New Revision: 315337 URL: https://svnweb.freebsd.org/changeset/base/315337 Log: Disable LD_BIND_NOT for setugid processes. Requested by: jilles Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Modified: head/libexec/rtld-elf/rtld.c Modified: head/libexec/rtld-elf/rtld.c ============================================================================== --- head/libexec/rtld-elf/rtld.c Wed Mar 15 23:08:11 2017 (r315336) +++ head/libexec/rtld-elf/rtld.c Wed Mar 15 23:47:19 2017 (r315337) @@ -417,8 +417,6 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ md_abi_variant_hook(aux_info); ld_bind_now = getenv(_LD("BIND_NOW")); - if (ld_bind_now == NULL) - ld_bind_not = getenv(_LD("BIND_NOT")) != NULL; /* * If the process is tainted, then we un-set the dangerous environment @@ -429,7 +427,7 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ if (!trust) { if (unsetenv(_LD("PRELOAD")) || unsetenv(_LD("LIBMAP")) || unsetenv(_LD("LIBRARY_PATH")) || unsetenv(_LD("LIBRARY_PATH_FDS")) || - unsetenv(_LD("LIBMAP_DISABLE")) || + unsetenv(_LD("LIBMAP_DISABLE")) || unsetenv(_LD("BIND_NOT")) || unsetenv(_LD("DEBUG")) || unsetenv(_LD("ELF_HINTS_PATH")) || unsetenv(_LD("LOADFLTR")) || unsetenv(_LD("LIBRARY_PATH_RPATH"))) { _rtld_error("environment corrupt; aborting"); @@ -437,6 +435,8 @@ _rtld(Elf_Addr *sp, func_ptr_type *exit_ } } ld_debug = getenv(_LD("DEBUG")); + if (ld_bind_now == NULL) + ld_bind_not = getenv(_LD("BIND_NOT")) != NULL; libmap_disable = getenv(_LD("LIBMAP_DISABLE")) != NULL; libmap_override = getenv(_LD("LIBMAP")); ld_library_path = getenv(_LD("LIBRARY_PATH")); From owner-svn-src-all@freebsd.org Wed Mar 15 23:52:01 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D1B5BD0EFA2; Wed, 15 Mar 2017 23:52:01 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4F89C17AB; Wed, 15 Mar 2017 23:52:01 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id v2FNpuZN082624 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 16 Mar 2017 01:51:56 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua v2FNpuZN082624 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id v2FNpu0x082623; Thu, 16 Mar 2017 01:51:56 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 16 Mar 2017 01:51:56 +0200 From: Konstantin Belousov To: John Baldwin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r315323 - head/sys/kern Message-ID: <20170315235156.GM16105@kib.kiev.ua> References: <201703151823.v2FINWN9083379@repo.freebsd.org> <3167768.s4jIG6eyGp@ralph.baldwin.cx> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3167768.s4jIG6eyGp@ralph.baldwin.cx> User-Agent: Mutt/1.8.0 (2017-02-23) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Mar 2017 23:52:01 -0000 On Wed, Mar 15, 2017 at 12:21:00PM -0700, John Baldwin wrote: > On Wednesday, March 15, 2017 06:23:32 PM John Baldwin wrote: > > Author: jhb > > Date: Wed Mar 15 18:23:32 2017 > > New Revision: 315323 > > URL: https://svnweb.freebsd.org/changeset/base/315323 > > > > Log: > > Use UMA_ALIGN_PTR instead of sizeof(void *) for zone alignment. > > > > uma_zcreate()'s alignment argument is supposed to be sizeof(foo) - 1, > > and uma.h provides a set of helper macros for common types. Passing > > sizeof(void *) results in all of the members being misaligned triggering > > unaligned access faults on certain architectures (notably MIPS). > > > > Reported by: brooks > > Obtained from: CheriBSD > > MFC after: 3 days > > Sponsored by: DARPA / AFRL > > > > Modified: > > head/sys/kern/vfs_lookup.c > > We should perhaps add a KASSERT() to uma_zcreate to catch this sort of > thing. Something like KASSERT(powerof2(align + 1)) (assuming there isn't > a real use case for having non-power-of-2 alignments)? > Will you do it ? From owner-svn-src-all@freebsd.org Thu Mar 16 00:50:00 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C9DA9D0C613; Thu, 16 Mar 2017 00:50:00 +0000 (UTC) (envelope-from kan@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 A44BA1921; Thu, 16 Mar 2017 00:50:00 +0000 (UTC) (envelope-from kan@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2G0nxGS038057; Thu, 16 Mar 2017 00:49:59 GMT (envelope-from kan@FreeBSD.org) Received: (from kan@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2G0nxM6038056; Thu, 16 Mar 2017 00:49:59 GMT (envelope-from kan@FreeBSD.org) Message-Id: <201703160049.v2G0nxM6038056@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kan set sender to kan@FreeBSD.org using -f From: Alexander Kabaev Date: Thu, 16 Mar 2017 00:49:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315338 - head/sys/mips/cavium X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Mar 2017 00:50:00 -0000 Author: kan Date: Thu Mar 16 00:49:59 2017 New Revision: 315338 URL: https://svnweb.freebsd.org/changeset/base/315338 Log: Add cavium octeon 'bootoctlinux' boot argument support While there, parse u-boot provided command line arguments for supported switches and update boothowto appropriately. Also support setting kenv variables from the kernel comman line. PR: 216831 (modified) Modified: head/sys/mips/cavium/octeon_machdep.c Modified: head/sys/mips/cavium/octeon_machdep.c ============================================================================== --- head/sys/mips/cavium/octeon_machdep.c Wed Mar 15 23:47:19 2017 (r315337) +++ head/sys/mips/cavium/octeon_machdep.c Thu Mar 16 00:49:59 2017 (r315338) @@ -95,6 +95,7 @@ struct octeon_feature_description { extern int *end; extern char cpu_model[]; extern char cpu_board[]; +static char octeon_kenv[0x2000]; static const struct octeon_feature_description octeon_feature_descriptions[] = { { OCTEON_FEATURE_SAAD, "SAAD" }, @@ -130,6 +131,7 @@ static uint64_t octeon_get_ticks(void); static unsigned octeon_get_timecount(struct timecounter *tc); static void octeon_boot_params_init(register_t ptr); +static void octeon_init_kenv(register_t ptr); static struct timecounter octeon_timecounter = { octeon_get_timecount, /* get_timecount */ @@ -341,12 +343,11 @@ platform_start(__register_t a0, __regist octeon_ciu_reset(); /* - * XXX - * We can certainly parse command line arguments or U-Boot environment - * to determine whether to bootverbose / single user / ... I think - * stass has patches to add support for loader things to U-Boot even. + * Convert U-Boot 'bootoctlinux' loader command line arguments into + * boot flags and kernel environment variables. */ bootverbose = 1; + octeon_init_kenv(a3); /* * For some reason on the cn38xx simulator ebase register is set to @@ -660,3 +661,59 @@ octeon_boot_params_init(register_t ptr) __cvmx_helper_cfg_init(); } /* impEND: This stuff should move back into the Cavium SDK */ + +static void +boothowto_parse(const char *v) +{ + if ((v == NULL) || (*v != '-')) + return; + + while (*v != '\0') { + v++; + switch (*v) { + case 'a': boothowto |= RB_ASKNAME; break; + case 'C': boothowto |= RB_CDROM; break; + case 'd': boothowto |= RB_KDB; break; + case 'D': boothowto |= RB_MULTIPLE; break; + case 'm': boothowto |= RB_MUTE; break; + case 'g': boothowto |= RB_GDB; break; + case 'h': boothowto |= RB_SERIAL; break; + case 'p': boothowto |= RB_PAUSE; break; + case 'r': boothowto |= RB_DFLTROOT; break; + case 's': boothowto |= RB_SINGLE; break; + case 'v': boothowto |= RB_VERBOSE; break; + } + } +} + +/* + * The boot loader command line may specify kernel environment variables or + * applicable boot flags of boot(8). + */ +static void +octeon_init_kenv(register_t ptr) +{ + int i; + char *n; + char *v; + octeon_boot_descriptor_t *app_desc_ptr; + + app_desc_ptr = (octeon_boot_descriptor_t *)(intptr_t)ptr; + memset(octeon_kenv, 0, sizeof(octeon_kenv)); + init_static_kenv(octeon_kenv, sizeof(octeon_kenv)); + + for (i = 0; i < app_desc_ptr->argc; i++) { + v = cvmx_phys_to_ptr(app_desc_ptr->argv[i]); + if (v == NULL) + continue; + if (*v == '-') { + boothowto_parse(v); + continue; + } + n = strsep(&v, "="); + if (v == NULL) + kern_setenv(n, "1"); + else + kern_setenv(n, v); + } +} From owner-svn-src-all@freebsd.org Thu Mar 16 00:51:26 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2C888D0C8A4; Thu, 16 Mar 2017 00:51:26 +0000 (UTC) (envelope-from mjg@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 048501D4B; Thu, 16 Mar 2017 00:51:25 +0000 (UTC) (envelope-from mjg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2G0pPHr039058; Thu, 16 Mar 2017 00:51:25 GMT (envelope-from mjg@FreeBSD.org) Received: (from mjg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2G0pOJ3039050; Thu, 16 Mar 2017 00:51:24 GMT (envelope-from mjg@FreeBSD.org) Message-Id: <201703160051.v2G0pOJ3039050@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mjg set sender to mjg@FreeBSD.org using -f From: Mateusz Guzik Date: Thu, 16 Mar 2017 00:51: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: r315339 - in stable/11/sys: kern sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Mar 2017 00:51:26 -0000 Author: mjg Date: Thu Mar 16 00:51:24 2017 New Revision: 315339 URL: https://svnweb.freebsd.org/changeset/base/315339 Log: MFC r312890,r313386,r313390: Sprinkle __read_mostly on backoff and lock profiling code. == locks: change backoff to exponential Previous implementation would use a random factor to spread readers and reduce chances of starvation. This visibly reduces effectiveness of the mechanism. Switch to the more traditional exponential variant. Try to limit starvation by imposing an upper limit of spins after which spinning is half of what other threads get. Note the mechanism is turned off by default. == locks: follow up r313386 Unfinished diff was committed by accident. The loop in lock_delay was changed to decrement, but the loop iterator was still incrementing. Modified: stable/11/sys/kern/kern_lockstat.c stable/11/sys/kern/kern_mutex.c stable/11/sys/kern/kern_rwlock.c stable/11/sys/kern/kern_sx.c stable/11/sys/kern/subr_lock.c stable/11/sys/sys/lock.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_lockstat.c ============================================================================== --- stable/11/sys/kern/kern_lockstat.c Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/kern/kern_lockstat.c Thu Mar 16 00:51:24 2017 (r315339) @@ -27,6 +27,7 @@ __FBSDID("$FreeBSD$"); #include +#include #include #include #include @@ -61,7 +62,7 @@ SDT_PROBE_DEFINE1(lockstat, , , sx__down SDT_PROBE_DEFINE2(lockstat, , , thread__spin, "struct mtx *", "uint64_t"); -int lockstat_enabled = 0; +int __read_mostly lockstat_enabled; uint64_t lockstat_nsecs(struct lock_object *lo) Modified: stable/11/sys/kern/kern_mutex.c ============================================================================== --- stable/11/sys/kern/kern_mutex.c Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/kern/kern_mutex.c Thu Mar 16 00:51:24 2017 (r315339) @@ -142,32 +142,14 @@ struct lock_class lock_class_mtx_spin = #ifdef ADAPTIVE_MUTEXES static SYSCTL_NODE(_debug, OID_AUTO, mtx, CTLFLAG_RD, NULL, "mtx debugging"); -static struct lock_delay_config mtx_delay = { - .initial = 1000, - .step = 500, - .min = 100, - .max = 5000, -}; +static struct lock_delay_config __read_mostly mtx_delay; -SYSCTL_INT(_debug_mtx, OID_AUTO, delay_initial, CTLFLAG_RW, &mtx_delay.initial, - 0, ""); -SYSCTL_INT(_debug_mtx, OID_AUTO, delay_step, CTLFLAG_RW, &mtx_delay.step, - 0, ""); -SYSCTL_INT(_debug_mtx, OID_AUTO, delay_min, CTLFLAG_RW, &mtx_delay.min, +SYSCTL_INT(_debug_mtx, OID_AUTO, delay_base, CTLFLAG_RW, &mtx_delay.base, 0, ""); SYSCTL_INT(_debug_mtx, OID_AUTO, delay_max, CTLFLAG_RW, &mtx_delay.max, 0, ""); -static void -mtx_delay_sysinit(void *dummy) -{ - - mtx_delay.initial = mp_ncpus * 25; - mtx_delay.step = (mp_ncpus * 25) / 2; - mtx_delay.min = mp_ncpus * 5; - mtx_delay.max = mp_ncpus * 25 * 10; -} -LOCK_DELAY_SYSINIT(mtx_delay_sysinit); +LOCK_DELAY_SYSINIT_DEFAULT(mtx_delay); #endif /* Modified: stable/11/sys/kern/kern_rwlock.c ============================================================================== --- stable/11/sys/kern/kern_rwlock.c Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/kern/kern_rwlock.c Thu Mar 16 00:51:24 2017 (r315339) @@ -100,32 +100,14 @@ static SYSCTL_NODE(_debug, OID_AUTO, rwl SYSCTL_INT(_debug_rwlock, OID_AUTO, retry, CTLFLAG_RW, &rowner_retries, 0, ""); SYSCTL_INT(_debug_rwlock, OID_AUTO, loops, CTLFLAG_RW, &rowner_loops, 0, ""); -static struct lock_delay_config rw_delay = { - .initial = 1000, - .step = 500, - .min = 100, - .max = 5000, -}; +static struct lock_delay_config __read_mostly rw_delay; -SYSCTL_INT(_debug_rwlock, OID_AUTO, delay_initial, CTLFLAG_RW, &rw_delay.initial, - 0, ""); -SYSCTL_INT(_debug_rwlock, OID_AUTO, delay_step, CTLFLAG_RW, &rw_delay.step, - 0, ""); -SYSCTL_INT(_debug_rwlock, OID_AUTO, delay_min, CTLFLAG_RW, &rw_delay.min, +SYSCTL_INT(_debug_rwlock, OID_AUTO, delay_base, CTLFLAG_RW, &rw_delay.base, 0, ""); SYSCTL_INT(_debug_rwlock, OID_AUTO, delay_max, CTLFLAG_RW, &rw_delay.max, 0, ""); -static void -rw_delay_sysinit(void *dummy) -{ - - rw_delay.initial = mp_ncpus * 25; - rw_delay.step = (mp_ncpus * 25) / 2; - rw_delay.min = mp_ncpus * 5; - rw_delay.max = mp_ncpus * 25 * 10; -} -LOCK_DELAY_SYSINIT(rw_delay_sysinit); +LOCK_DELAY_SYSINIT_DEFAULT(rw_delay); #endif /* Modified: stable/11/sys/kern/kern_sx.c ============================================================================== --- stable/11/sys/kern/kern_sx.c Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/kern/kern_sx.c Thu Mar 16 00:51:24 2017 (r315339) @@ -148,32 +148,14 @@ static SYSCTL_NODE(_debug, OID_AUTO, sx, SYSCTL_UINT(_debug_sx, OID_AUTO, retries, CTLFLAG_RW, &asx_retries, 0, ""); SYSCTL_UINT(_debug_sx, OID_AUTO, loops, CTLFLAG_RW, &asx_loops, 0, ""); -static struct lock_delay_config sx_delay = { - .initial = 1000, - .step = 500, - .min = 100, - .max = 5000, -}; +static struct lock_delay_config __read_mostly sx_delay; -SYSCTL_INT(_debug_sx, OID_AUTO, delay_initial, CTLFLAG_RW, &sx_delay.initial, - 0, ""); -SYSCTL_INT(_debug_sx, OID_AUTO, delay_step, CTLFLAG_RW, &sx_delay.step, - 0, ""); -SYSCTL_INT(_debug_sx, OID_AUTO, delay_min, CTLFLAG_RW, &sx_delay.min, +SYSCTL_INT(_debug_sx, OID_AUTO, delay_base, CTLFLAG_RW, &sx_delay.base, 0, ""); SYSCTL_INT(_debug_sx, OID_AUTO, delay_max, CTLFLAG_RW, &sx_delay.max, 0, ""); -static void -sx_delay_sysinit(void *dummy) -{ - - sx_delay.initial = mp_ncpus * 25; - sx_delay.step = (mp_ncpus * 25) / 2; - sx_delay.min = mp_ncpus * 5; - sx_delay.max = mp_ncpus * 25 * 10; -} -LOCK_DELAY_SYSINIT(sx_delay_sysinit); +LOCK_DELAY_SYSINIT_DEFAULT(sx_delay); #endif void Modified: stable/11/sys/kern/subr_lock.c ============================================================================== --- stable/11/sys/kern/subr_lock.c Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/kern/subr_lock.c Thu Mar 16 00:51:24 2017 (r315339) @@ -56,6 +56,9 @@ __FBSDID("$FreeBSD$"); #include +SDT_PROVIDER_DEFINE(lock); +SDT_PROBE_DEFINE1(lock, , , starvation, "u_int"); + CTASSERT(LOCK_CLASS_MAX == 15); struct lock_class *lock_classes[LOCK_CLASS_MAX + 1] = { @@ -103,32 +106,56 @@ lock_destroy(struct lock_object *lock) lock->lo_flags &= ~LO_INITIALIZED; } +static SYSCTL_NODE(_debug, OID_AUTO, lock, CTLFLAG_RD, NULL, "lock debugging"); +static SYSCTL_NODE(_debug_lock, OID_AUTO, delay, CTLFLAG_RD, NULL, + "lock delay"); + +static u_int __read_mostly starvation_limit = 131072; +SYSCTL_INT(_debug_lock_delay, OID_AUTO, starvation_limit, CTLFLAG_RW, + &starvation_limit, 0, ""); + +static u_int __read_mostly restrict_starvation = 0; +SYSCTL_INT(_debug_lock_delay, OID_AUTO, restrict_starvation, CTLFLAG_RW, + &restrict_starvation, 0, ""); + void lock_delay(struct lock_delay_arg *la) { - u_int i, delay, backoff, min, max; struct lock_delay_config *lc = la->config; + u_int i; - delay = la->delay; + la->delay <<= 1; + if (__predict_false(la->delay > lc->max)) + la->delay = lc->max; - if (delay == 0) - delay = lc->initial; - else { - delay += lc->step; - max = lc->max; - if (delay > max) - delay = max; - } - - backoff = cpu_ticks() % delay; - min = lc->min; - if (backoff < min) - backoff = min; - for (i = 0; i < backoff; i++) + for (i = la->delay; i > 0; i--) cpu_spinwait(); - la->delay = delay; - la->spin_cnt += backoff; + la->spin_cnt += la->delay; + if (__predict_false(la->spin_cnt > starvation_limit)) { + SDT_PROBE1(lock, , , starvation, la->delay); + if (restrict_starvation) + la->delay = lc->base; + } +} + +static u_int +lock_roundup_2(u_int val) +{ + u_int res; + + for (res = 1; res <= val; res <<= 1) + continue; + + return (res); +} + +void +lock_delay_default_init(struct lock_delay_config *lc) +{ + + lc->base = lock_roundup_2(mp_ncpus) / 4; + lc->max = lc->base * 1024; } #ifdef DDB @@ -213,7 +240,7 @@ struct lock_prof_cpu { struct lock_prof_cpu *lp_cpu[MAXCPU]; -volatile int lock_prof_enable = 0; +volatile int __read_mostly lock_prof_enable; static volatile int lock_prof_resetting; #define LPROF_SBUF_SIZE 256 @@ -655,7 +682,6 @@ out: critical_exit(); } -static SYSCTL_NODE(_debug, OID_AUTO, lock, CTLFLAG_RD, NULL, "lock debugging"); static SYSCTL_NODE(_debug_lock, OID_AUTO, prof, CTLFLAG_RD, NULL, "lock profiling"); SYSCTL_INT(_debug_lock_prof, OID_AUTO, skipspin, CTLFLAG_RW, Modified: stable/11/sys/sys/lock.h ============================================================================== --- stable/11/sys/sys/lock.h Thu Mar 16 00:49:59 2017 (r315338) +++ stable/11/sys/sys/lock.h Thu Mar 16 00:51:24 2017 (r315339) @@ -202,9 +202,7 @@ extern struct lock_class lock_class_lock extern struct lock_class *lock_classes[]; struct lock_delay_config { - u_int initial; - u_int step; - u_int min; + u_int base; u_int max; }; @@ -215,19 +213,25 @@ struct lock_delay_arg { }; static inline void -lock_delay_arg_init(struct lock_delay_arg *la, struct lock_delay_config *lc) { +lock_delay_arg_init(struct lock_delay_arg *la, struct lock_delay_config *lc) +{ la->config = lc; - la->delay = 0; + la->delay = lc->base; la->spin_cnt = 0; } #define LOCK_DELAY_SYSINIT(func) \ SYSINIT(func##_ld, SI_SUB_LOCK, SI_ORDER_ANY, func, NULL) +#define LOCK_DELAY_SYSINIT_DEFAULT(lc) \ + SYSINIT(lock_delay_##lc##_ld, SI_SUB_LOCK, SI_ORDER_ANY, \ + lock_delay_default_init, &lc) + void lock_init(struct lock_object *, struct lock_class *, const char *, const char *, int); void lock_destroy(struct lock_object *); void lock_delay(struct lock_delay_arg *); +void lock_delay_default_init(struct lock_delay_config *); void spinlock_enter(void); void spinlock_exit(void); void witness_init(struct lock_object *, const char *); From owner-svn-src-all@freebsd.org Thu Mar 16 01:04:31 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C347CD0CDA8; Thu, 16 Mar 2017 01:04:31 +0000 (UTC) (envelope-from mjg@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 9DD321505; Thu, 16 Mar 2017 01:04:31 +0000 (UTC) (envelope-from mjg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2G14UMo046095; Thu, 16 Mar 2017 01:04:30 GMT (envelope-from mjg@FreeBSD.org) Received: (from mjg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2G14UJw046094; Thu, 16 Mar 2017 01:04:30 GMT (envelope-from mjg@FreeBSD.org) Message-Id: <201703160104.v2G14UJw046094@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mjg set sender to mjg@FreeBSD.org using -f From: Mateusz Guzik Date: Thu, 16 Mar 2017 01:04:30 +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: r315340 - stable/11/sys/kern X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Mar 2017 01:04:31 -0000 Author: mjg Date: Thu Mar 16 01:04:30 2017 New Revision: 315340 URL: https://svnweb.freebsd.org/changeset/base/315340 Log: MFC r305671: locks: add backoff for spin mutexes and thread lock Modified: stable/11/sys/kern/kern_mutex.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_mutex.c ============================================================================== --- stable/11/sys/kern/kern_mutex.c Thu Mar 16 00:51:24 2017 (r315339) +++ stable/11/sys/kern/kern_mutex.c Thu Mar 16 01:04:30 2017 (r315340) @@ -152,6 +152,18 @@ SYSCTL_INT(_debug_mtx, OID_AUTO, delay_m LOCK_DELAY_SYSINIT_DEFAULT(mtx_delay); #endif +static SYSCTL_NODE(_debug, OID_AUTO, mtx_spin, CTLFLAG_RD, NULL, + "mtx spin debugging"); + +static struct lock_delay_config __read_mostly mtx_spin_delay; + +SYSCTL_INT(_debug_mtx_spin, OID_AUTO, delay_base, CTLFLAG_RW, + &mtx_spin_delay.base, 0, ""); +SYSCTL_INT(_debug_mtx_spin, OID_AUTO, delay_max, CTLFLAG_RW, + &mtx_spin_delay.max, 0, ""); + +LOCK_DELAY_SYSINIT_DEFAULT(mtx_spin_delay); + /* * System-wide mutexes */ @@ -623,7 +635,7 @@ _mtx_lock_spin_cookie(volatile uintptr_t const char *file, int line) { struct mtx *m; - int i = 0; + struct lock_delay_arg lda; #ifdef LOCK_PROFILING int contested = 0; uint64_t waittime = 0; @@ -635,6 +647,7 @@ _mtx_lock_spin_cookie(volatile uintptr_t if (SCHEDULER_STOPPED()) return; + lock_delay_arg_init(&lda, &mtx_spin_delay); m = mtxlock2mtx(c); if (LOCK_LOG_TEST(&m->lock_object, opts)) @@ -655,11 +668,13 @@ _mtx_lock_spin_cookie(volatile uintptr_t /* Give interrupts a chance while we spin. */ spinlock_exit(); while (m->mtx_lock != MTX_UNOWNED) { - if (i++ < 10000000) { - cpu_spinwait(); + if (lda.spin_cnt < 10000000) { + lock_delay(&lda); continue; } - if (i < 60000000 || kdb_active || panicstr != NULL) + lda.spin_cnt++; + if (lda.spin_cnt < 60000000 || kdb_active || + panicstr != NULL) DELAY(1); else _mtx_lock_spin_failed(m); @@ -690,7 +705,7 @@ thread_lock_flags_(struct thread *td, in { struct mtx *m; uintptr_t tid; - int i; + struct lock_delay_arg lda; #ifdef LOCK_PROFILING int contested = 0; uint64_t waittime = 0; @@ -699,7 +714,6 @@ thread_lock_flags_(struct thread *td, in int64_t spin_time = 0; #endif - i = 0; tid = (uintptr_t)curthread; if (SCHEDULER_STOPPED()) { @@ -712,6 +726,8 @@ thread_lock_flags_(struct thread *td, in return; } + lock_delay_arg_init(&lda, &mtx_spin_delay); + #ifdef KDTRACE_HOOKS spin_time -= lockstat_nsecs(&td->td_lock->lock_object); #endif @@ -745,14 +761,17 @@ retry: /* Give interrupts a chance while we spin. */ spinlock_exit(); while (m->mtx_lock != MTX_UNOWNED) { - if (i++ < 10000000) + if (lda.spin_cnt < 10000000) { + lock_delay(&lda); + } else { + lda.spin_cnt++; + if (lda.spin_cnt < 60000000 || + kdb_active || panicstr != NULL) + DELAY(1); + else + _mtx_lock_spin_failed(m); cpu_spinwait(); - else if (i < 60000000 || - kdb_active || panicstr != NULL) - DELAY(1); - else - _mtx_lock_spin_failed(m); - cpu_spinwait(); + } if (m != td->td_lock) goto retry; } From owner-svn-src-all@freebsd.org Thu Mar 16 01:32:58 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9EDFED0DC95; Thu, 16 Mar 2017 01:32:58 +0000 (UTC) (envelope-from mjg@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 6D8B015C7; Thu, 16 Mar 2017 01:32:58 +0000 (UTC) (envelope-from mjg@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2G1WvRW058013; Thu, 16 Mar 2017 01:32:57 GMT (envelope-from mjg@FreeBSD.org) Received: (from mjg@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2G1Wvvi058007; Thu, 16 Mar 2017 01:32:57 GMT (envelope-from mjg@FreeBSD.org) Message-Id: <201703160132.v2G1Wvvi058007@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mjg set sender to mjg@FreeBSD.org using -f From: Mateusz Guzik Date: Thu, 16 Mar 2017 01:32:57 +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: r315341 - in stable/11/sys: kern sys X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Mar 2017 01:32:58 -0000 Author: mjg Date: Thu Mar 16 01:32:56 2017 New Revision: 315341 URL: https://svnweb.freebsd.org/changeset/base/315341 Log: MFC r311172,r311194,r311226,r312389,r312390: mtx: reduce lock accesses Instead of spuriously re-reading the lock value, read it once. This change also has a side effect of fixing a performance bug: on failed _mtx_obtain_lock, it was possible that re-read would find the lock is unowned, but in this case the primitive would make a trip through turnstile code. This is diff reduction to a variant which uses atomic_fcmpset. == Reduce lock accesses in thread lock similarly to r311172 == mtx: plug open-coded mtx_lock access missed in r311172 == rwlock: reduce lock accesses similarly to r311172 == sx: reduce lock accesses similarly to r311172 Modified: stable/11/sys/kern/kern_mutex.c stable/11/sys/kern/kern_rwlock.c stable/11/sys/kern/kern_sx.c stable/11/sys/sys/mutex.h stable/11/sys/sys/rwlock.h stable/11/sys/sys/sx.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/kern/kern_mutex.c ============================================================================== --- stable/11/sys/kern/kern_mutex.c Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/kern/kern_mutex.c Thu Mar 16 01:32:56 2017 (r315341) @@ -94,8 +94,6 @@ PMC_SOFT_DEFINE( , , lock, failed); #define mtx_destroyed(m) ((m)->mtx_lock == MTX_DESTROYED) -#define mtx_owner(m) ((struct thread *)((m)->mtx_lock & ~MTX_FLAGMASK)) - static void assert_mtx(const struct lock_object *lock, int what); #ifdef DDB static void db_show_mtx(const struct lock_object *lock); @@ -452,8 +450,9 @@ __mtx_lock_sleep(volatile uintptr_t *c, lock_delay_arg_init(&lda, NULL); #endif m = mtxlock2mtx(c); + v = MTX_READ_VALUE(m); - if (mtx_owned(m)) { + if (__predict_false(lv_mtx_owner(v) == (struct thread *)tid)) { KASSERT((m->lock_object.lo_flags & LO_RECURSABLE) != 0 || (opts & MTX_RECURSE) != 0, ("_mtx_lock_sleep: recursed on non-recursive mutex %s @ %s:%d\n", @@ -481,8 +480,12 @@ __mtx_lock_sleep(volatile uintptr_t *c, #endif for (;;) { - if (m->mtx_lock == MTX_UNOWNED && _mtx_obtain_lock(m, tid)) - break; + if (v == MTX_UNOWNED) { + if (_mtx_obtain_lock(m, tid)) + break; + v = MTX_READ_VALUE(m); + continue; + } #ifdef KDTRACE_HOOKS lda.spin_cnt++; #endif @@ -491,31 +494,30 @@ __mtx_lock_sleep(volatile uintptr_t *c, * If the owner is running on another CPU, spin until the * owner stops running or the state of the lock changes. */ - v = m->mtx_lock; - if (v != MTX_UNOWNED) { - owner = (struct thread *)(v & ~MTX_FLAGMASK); - if (TD_IS_RUNNING(owner)) { - if (LOCK_LOG_TEST(&m->lock_object, 0)) - CTR3(KTR_LOCK, - "%s: spinning on %p held by %p", - __func__, m, owner); - KTR_STATE1(KTR_SCHED, "thread", - sched_tdname((struct thread *)tid), - "spinning", "lockname:\"%s\"", - m->lock_object.lo_name); - while (mtx_owner(m) == owner && - TD_IS_RUNNING(owner)) - lock_delay(&lda); - KTR_STATE0(KTR_SCHED, "thread", - sched_tdname((struct thread *)tid), - "running"); - continue; - } + owner = lv_mtx_owner(v); + if (TD_IS_RUNNING(owner)) { + if (LOCK_LOG_TEST(&m->lock_object, 0)) + CTR3(KTR_LOCK, + "%s: spinning on %p held by %p", + __func__, m, owner); + KTR_STATE1(KTR_SCHED, "thread", + sched_tdname((struct thread *)tid), + "spinning", "lockname:\"%s\"", + m->lock_object.lo_name); + do { + lock_delay(&lda); + v = MTX_READ_VALUE(m); + owner = lv_mtx_owner(v); + } while (v != MTX_UNOWNED && TD_IS_RUNNING(owner)); + KTR_STATE0(KTR_SCHED, "thread", + sched_tdname((struct thread *)tid), + "running"); + continue; } #endif ts = turnstile_trywait(&m->lock_object); - v = m->mtx_lock; + v = MTX_READ_VALUE(m); /* * Check if the lock has been released while spinning for @@ -534,7 +536,7 @@ __mtx_lock_sleep(volatile uintptr_t *c, * chain lock. If so, drop the turnstile lock and try * again. */ - owner = (struct thread *)(v & ~MTX_FLAGMASK); + owner = lv_mtx_owner(v); if (TD_IS_RUNNING(owner)) { turnstile_cancel(ts); continue; @@ -549,6 +551,7 @@ __mtx_lock_sleep(volatile uintptr_t *c, if ((v & MTX_CONTESTED) == 0 && !atomic_cmpset_ptr(&m->mtx_lock, v, v | MTX_CONTESTED)) { turnstile_cancel(ts); + v = MTX_READ_VALUE(m); continue; } @@ -579,6 +582,7 @@ __mtx_lock_sleep(volatile uintptr_t *c, sleep_time += lockstat_nsecs(&m->lock_object); sleep_cnt++; #endif + v = MTX_READ_VALUE(m); } #ifdef KDTRACE_HOOKS all_time += lockstat_nsecs(&m->lock_object); @@ -636,6 +640,7 @@ _mtx_lock_spin_cookie(volatile uintptr_t { struct mtx *m; struct lock_delay_arg lda; + uintptr_t v; #ifdef LOCK_PROFILING int contested = 0; uint64_t waittime = 0; @@ -662,24 +667,30 @@ _mtx_lock_spin_cookie(volatile uintptr_t #ifdef KDTRACE_HOOKS spin_time -= lockstat_nsecs(&m->lock_object); #endif + v = MTX_READ_VALUE(m); for (;;) { - if (m->mtx_lock == MTX_UNOWNED && _mtx_obtain_lock(m, tid)) - break; + if (v == MTX_UNOWNED) { + if (_mtx_obtain_lock(m, tid)) + break; + v = MTX_READ_VALUE(m); + continue; + } /* Give interrupts a chance while we spin. */ spinlock_exit(); - while (m->mtx_lock != MTX_UNOWNED) { + do { if (lda.spin_cnt < 10000000) { lock_delay(&lda); - continue; + } else { + lda.spin_cnt++; + if (lda.spin_cnt < 60000000 || kdb_active || + panicstr != NULL) + DELAY(1); + else + _mtx_lock_spin_failed(m); + cpu_spinwait(); } - lda.spin_cnt++; - if (lda.spin_cnt < 60000000 || kdb_active || - panicstr != NULL) - DELAY(1); - else - _mtx_lock_spin_failed(m); - cpu_spinwait(); - } + v = MTX_READ_VALUE(m); + } while (v != MTX_UNOWNED); spinlock_enter(); } #ifdef KDTRACE_HOOKS @@ -704,7 +715,7 @@ void thread_lock_flags_(struct thread *td, int opts, const char *file, int line) { struct mtx *m; - uintptr_t tid; + uintptr_t tid, v; struct lock_delay_arg lda; #ifdef LOCK_PROFILING int contested = 0; @@ -746,10 +757,15 @@ retry: m->lock_object.lo_name, file, line)); WITNESS_CHECKORDER(&m->lock_object, opts | LOP_NEWORDER | LOP_EXCLUSIVE, file, line, NULL); + v = MTX_READ_VALUE(m); for (;;) { - if (m->mtx_lock == MTX_UNOWNED && _mtx_obtain_lock(m, tid)) - break; - if (m->mtx_lock == tid) { + if (v == MTX_UNOWNED) { + if (_mtx_obtain_lock(m, tid)) + break; + v = MTX_READ_VALUE(m); + continue; + } + if (v == tid) { m->mtx_recurse++; break; } @@ -760,7 +776,7 @@ retry: &contested, &waittime); /* Give interrupts a chance while we spin. */ spinlock_exit(); - while (m->mtx_lock != MTX_UNOWNED) { + do { if (lda.spin_cnt < 10000000) { lock_delay(&lda); } else { @@ -774,7 +790,8 @@ retry: } if (m != td->td_lock) goto retry; - } + v = MTX_READ_VALUE(m); + } while (v != MTX_UNOWNED); spinlock_enter(); } if (m == td->td_lock) Modified: stable/11/sys/kern/kern_rwlock.c ============================================================================== --- stable/11/sys/kern/kern_rwlock.c Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/kern/kern_rwlock.c Thu Mar 16 01:32:56 2017 (r315341) @@ -114,9 +114,12 @@ LOCK_DELAY_SYSINIT_DEFAULT(rw_delay); * Return a pointer to the owning thread if the lock is write-locked or * NULL if the lock is unlocked or read-locked. */ -#define rw_wowner(rw) \ - ((rw)->rw_lock & RW_LOCK_READ ? NULL : \ - (struct thread *)RW_OWNER((rw)->rw_lock)) + +#define lv_rw_wowner(v) \ + ((v) & RW_LOCK_READ ? NULL : \ + (struct thread *)RW_OWNER((v))) + +#define rw_wowner(rw) lv_rw_wowner(RW_READ_VALUE(rw)) /* * Returns if a write owner is recursed. Write ownership is not assured @@ -397,7 +400,10 @@ __rw_rlock(volatile uintptr_t *c, const #ifdef KDTRACE_HOOKS all_time -= lockstat_nsecs(&rw->lock_object); - state = rw->rw_lock; +#endif + v = RW_READ_VALUE(rw); +#ifdef KDTRACE_HOOKS + state = v; #endif for (;;) { /* @@ -410,7 +416,6 @@ __rw_rlock(volatile uintptr_t *c, const * completely unlocked rwlock since such a lock is encoded * as a read lock with no waiters. */ - v = rw->rw_lock; if (RW_CAN_READ(v)) { /* * The RW_LOCK_READ_WAITERS flag should only be set @@ -426,6 +431,7 @@ __rw_rlock(volatile uintptr_t *c, const (void *)(v + RW_ONE_READER)); break; } + v = RW_READ_VALUE(rw); continue; } #ifdef KDTRACE_HOOKS @@ -453,9 +459,11 @@ __rw_rlock(volatile uintptr_t *c, const KTR_STATE1(KTR_SCHED, "thread", sched_tdname(curthread), "spinning", "lockname:\"%s\"", rw->lock_object.lo_name); - while ((struct thread*)RW_OWNER(rw->rw_lock) == - owner && TD_IS_RUNNING(owner)) + do { lock_delay(&lda); + v = RW_READ_VALUE(rw); + owner = lv_rw_wowner(v); + } while (owner != NULL && TD_IS_RUNNING(owner)); KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); continue; @@ -466,11 +474,12 @@ __rw_rlock(volatile uintptr_t *c, const "spinning", "lockname:\"%s\"", rw->lock_object.lo_name); for (i = 0; i < rowner_loops; i++) { - v = rw->rw_lock; + v = RW_READ_VALUE(rw); if ((v & RW_LOCK_READ) == 0 || RW_CAN_READ(v)) break; cpu_spinwait(); } + v = RW_READ_VALUE(rw); #ifdef KDTRACE_HOOKS lda.spin_cnt += rowner_loops - i; #endif @@ -493,7 +502,7 @@ __rw_rlock(volatile uintptr_t *c, const * The lock might have been released while we spun, so * recheck its state and restart the loop if needed. */ - v = rw->rw_lock; + v = RW_READ_VALUE(rw); if (RW_CAN_READ(v)) { turnstile_cancel(ts); continue; @@ -531,6 +540,7 @@ __rw_rlock(volatile uintptr_t *c, const if (!atomic_cmpset_ptr(&rw->rw_lock, v, v | RW_LOCK_READ_WAITERS)) { turnstile_cancel(ts); + v = RW_READ_VALUE(rw); continue; } if (LOCK_LOG_TEST(&rw->lock_object, 0)) @@ -556,6 +566,7 @@ __rw_rlock(volatile uintptr_t *c, const if (LOCK_LOG_TEST(&rw->lock_object, 0)) CTR2(KTR_LOCK, "%s: %p resuming from turnstile", __func__, rw); + v = RW_READ_VALUE(rw); } #ifdef KDTRACE_HOOKS all_time += lockstat_nsecs(&rw->lock_object); @@ -639,13 +650,12 @@ _rw_runlock_cookie(volatile uintptr_t *c LOCK_LOG_LOCK("RUNLOCK", &rw->lock_object, 0, 0, file, line); /* TODO: drop "owner of record" here. */ - + x = RW_READ_VALUE(rw); for (;;) { /* * See if there is more than one read lock held. If so, * just drop one and return. */ - x = rw->rw_lock; if (RW_READERS(x) > 1) { if (atomic_cmpset_rel_ptr(&rw->rw_lock, x, x - RW_ONE_READER)) { @@ -656,6 +666,7 @@ _rw_runlock_cookie(volatile uintptr_t *c (void *)(x - RW_ONE_READER)); break; } + x = RW_READ_VALUE(rw); continue; } /* @@ -672,6 +683,7 @@ _rw_runlock_cookie(volatile uintptr_t *c __func__, rw); break; } + x = RW_READ_VALUE(rw); continue; } /* @@ -707,6 +719,7 @@ _rw_runlock_cookie(volatile uintptr_t *c if (!atomic_cmpset_rel_ptr(&rw->rw_lock, RW_READERS_LOCK(1) | v, x)) { turnstile_chain_unlock(&rw->lock_object); + x = RW_READ_VALUE(rw); continue; } if (LOCK_LOG_TEST(&rw->lock_object, 0)) @@ -772,8 +785,9 @@ __rw_wlock_hard(volatile uintptr_t *c, u lock_delay_arg_init(&lda, NULL); #endif rw = rwlock2rw(c); + v = RW_READ_VALUE(rw); - if (rw_wlocked(rw)) { + if (__predict_false(lv_rw_wowner(v) == (struct thread *)tid)) { KASSERT(rw->lock_object.lo_flags & LO_RECURSABLE, ("%s: recursing but non-recursive rw %s @ %s:%d\n", __func__, rw->lock_object.lo_name, file, line)); @@ -789,11 +803,15 @@ __rw_wlock_hard(volatile uintptr_t *c, u #ifdef KDTRACE_HOOKS all_time -= lockstat_nsecs(&rw->lock_object); - state = rw->rw_lock; + state = v; #endif for (;;) { - if (rw->rw_lock == RW_UNLOCKED && _rw_write_lock(rw, tid)) - break; + if (v == RW_UNLOCKED) { + if (_rw_write_lock(rw, tid)) + break; + v = RW_READ_VALUE(rw); + continue; + } #ifdef KDTRACE_HOOKS lda.spin_cnt++; #endif @@ -808,8 +826,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u * running on another CPU, spin until the owner stops * running or the state of the lock changes. */ - v = rw->rw_lock; - owner = (struct thread *)RW_OWNER(v); + owner = lv_rw_wowner(v); if (!(v & RW_LOCK_READ) && TD_IS_RUNNING(owner)) { if (LOCK_LOG_TEST(&rw->lock_object, 0)) CTR3(KTR_LOCK, "%s: spinning on %p held by %p", @@ -817,9 +834,11 @@ __rw_wlock_hard(volatile uintptr_t *c, u KTR_STATE1(KTR_SCHED, "thread", sched_tdname(curthread), "spinning", "lockname:\"%s\"", rw->lock_object.lo_name); - while ((struct thread*)RW_OWNER(rw->rw_lock) == owner && - TD_IS_RUNNING(owner)) + do { lock_delay(&lda); + v = RW_READ_VALUE(rw); + owner = lv_rw_wowner(v); + } while (owner != NULL && TD_IS_RUNNING(owner)); KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); continue; @@ -829,6 +848,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u if (!(v & RW_LOCK_WRITE_SPINNER)) { if (!atomic_cmpset_ptr(&rw->rw_lock, v, v | RW_LOCK_WRITE_SPINNER)) { + v = RW_READ_VALUE(rw); continue; } } @@ -843,6 +863,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u } KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); + v = RW_READ_VALUE(rw); #ifdef KDTRACE_HOOKS lda.spin_cnt += rowner_loops - i; #endif @@ -851,7 +872,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u } #endif ts = turnstile_trywait(&rw->lock_object); - v = rw->rw_lock; + v = RW_READ_VALUE(rw); #ifdef ADAPTIVE_RWLOCKS /* @@ -887,6 +908,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u break; } turnstile_cancel(ts); + v = RW_READ_VALUE(rw); continue; } /* @@ -898,6 +920,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u if (!atomic_cmpset_ptr(&rw->rw_lock, v, v | RW_LOCK_WRITE_WAITERS)) { turnstile_cancel(ts); + v = RW_READ_VALUE(rw); continue; } if (LOCK_LOG_TEST(&rw->lock_object, 0)) @@ -925,6 +948,7 @@ __rw_wlock_hard(volatile uintptr_t *c, u #ifdef ADAPTIVE_RWLOCKS spintries = 0; #endif + v = RW_READ_VALUE(rw); } #ifdef KDTRACE_HOOKS all_time += lockstat_nsecs(&rw->lock_object); Modified: stable/11/sys/kern/kern_sx.c ============================================================================== --- stable/11/sys/kern/kern_sx.c Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/kern/kern_sx.c Thu Mar 16 01:32:56 2017 (r315341) @@ -543,8 +543,10 @@ _sx_xlock_hard(struct sx *sx, uintptr_t lock_delay_arg_init(&lda, NULL); #endif + x = SX_READ_VALUE(sx); + /* If we already hold an exclusive lock, then recurse. */ - if (sx_xlocked(sx)) { + if (__predict_false(lv_sx_owner(x) == (struct thread *)tid)) { KASSERT((sx->lock_object.lo_flags & LO_RECURSABLE) != 0, ("_sx_xlock_hard: recursed on non-recursive sx %s @ %s:%d\n", sx->lock_object.lo_name, file, line)); @@ -561,12 +563,15 @@ _sx_xlock_hard(struct sx *sx, uintptr_t #ifdef KDTRACE_HOOKS all_time -= lockstat_nsecs(&sx->lock_object); - state = sx->sx_lock; + state = x; #endif for (;;) { - if (sx->sx_lock == SX_LOCK_UNLOCKED && - atomic_cmpset_acq_ptr(&sx->sx_lock, SX_LOCK_UNLOCKED, tid)) - break; + if (x == SX_LOCK_UNLOCKED) { + if (atomic_cmpset_acq_ptr(&sx->sx_lock, x, tid)) + break; + x = SX_READ_VALUE(sx); + continue; + } #ifdef KDTRACE_HOOKS lda.spin_cnt++; #endif @@ -581,11 +586,9 @@ _sx_xlock_hard(struct sx *sx, uintptr_t * running on another CPU, spin until the owner stops * running or the state of the lock changes. */ - x = sx->sx_lock; if ((sx->lock_object.lo_flags & SX_NOADAPTIVE) == 0) { if ((x & SX_LOCK_SHARED) == 0) { - x = SX_OWNER(x); - owner = (struct thread *)x; + owner = lv_sx_owner(x); if (TD_IS_RUNNING(owner)) { if (LOCK_LOG_TEST(&sx->lock_object, 0)) CTR3(KTR_LOCK, @@ -596,9 +599,12 @@ _sx_xlock_hard(struct sx *sx, uintptr_t "lockname:\"%s\"", sx->lock_object.lo_name); GIANT_SAVE(); - while (SX_OWNER(sx->sx_lock) == x && - TD_IS_RUNNING(owner)) + do { lock_delay(&lda); + x = SX_READ_VALUE(sx); + owner = lv_sx_owner(x); + } while (owner != NULL && + TD_IS_RUNNING(owner)); KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); continue; @@ -625,6 +631,7 @@ _sx_xlock_hard(struct sx *sx, uintptr_t } KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); + x = SX_READ_VALUE(sx); if (i != asx_loops) continue; } @@ -632,7 +639,7 @@ _sx_xlock_hard(struct sx *sx, uintptr_t #endif sleepq_lock(&sx->lock_object); - x = sx->sx_lock; + x = SX_READ_VALUE(sx); /* * If the lock was released while spinning on the @@ -681,6 +688,7 @@ _sx_xlock_hard(struct sx *sx, uintptr_t break; } sleepq_release(&sx->lock_object); + x = SX_READ_VALUE(sx); continue; } @@ -692,6 +700,7 @@ _sx_xlock_hard(struct sx *sx, uintptr_t if (!atomic_cmpset_ptr(&sx->sx_lock, x, x | SX_LOCK_EXCLUSIVE_WAITERS)) { sleepq_release(&sx->lock_object); + x = SX_READ_VALUE(sx); continue; } if (LOCK_LOG_TEST(&sx->lock_object, 0)) @@ -733,6 +742,7 @@ _sx_xlock_hard(struct sx *sx, uintptr_t if (LOCK_LOG_TEST(&sx->lock_object, 0)) CTR2(KTR_LOCK, "%s: %p resuming from sleep queue", __func__, sx); + x = SX_READ_VALUE(sx); } #ifdef KDTRACE_HOOKS all_time += lockstat_nsecs(&sx->lock_object); @@ -852,20 +862,18 @@ _sx_slock_hard(struct sx *sx, int opts, lock_delay_arg_init(&lda, NULL); #endif #ifdef KDTRACE_HOOKS - state = sx->sx_lock; all_time -= lockstat_nsecs(&sx->lock_object); #endif + x = SX_READ_VALUE(sx); +#ifdef KDTRACE_HOOKS + state = x; +#endif /* * As with rwlocks, we don't make any attempt to try to block * shared locks once there is an exclusive waiter. */ for (;;) { -#ifdef KDTRACE_HOOKS - lda.spin_cnt++; -#endif - x = sx->sx_lock; - /* * If no other thread has an exclusive lock then try to bump up * the count of sharers. Since we have to preserve the state @@ -883,8 +891,13 @@ _sx_slock_hard(struct sx *sx, int opts, (void *)(x + SX_ONE_SHARER)); break; } + x = SX_READ_VALUE(sx); continue; } +#ifdef KDTRACE_HOOKS + lda.spin_cnt++; +#endif + #ifdef HWPMC_HOOKS PMC_SOFT_CALL( , , lock, failed); #endif @@ -898,8 +911,7 @@ _sx_slock_hard(struct sx *sx, int opts, * changes. */ if ((sx->lock_object.lo_flags & SX_NOADAPTIVE) == 0) { - x = SX_OWNER(x); - owner = (struct thread *)x; + owner = lv_sx_owner(x); if (TD_IS_RUNNING(owner)) { if (LOCK_LOG_TEST(&sx->lock_object, 0)) CTR3(KTR_LOCK, @@ -909,9 +921,11 @@ _sx_slock_hard(struct sx *sx, int opts, sched_tdname(curthread), "spinning", "lockname:\"%s\"", sx->lock_object.lo_name); GIANT_SAVE(); - while (SX_OWNER(sx->sx_lock) == x && - TD_IS_RUNNING(owner)) + do { lock_delay(&lda); + x = SX_READ_VALUE(sx); + owner = lv_sx_owner(x); + } while (owner != NULL && TD_IS_RUNNING(owner)); KTR_STATE0(KTR_SCHED, "thread", sched_tdname(curthread), "running"); continue; @@ -924,7 +938,7 @@ _sx_slock_hard(struct sx *sx, int opts, * start the process of blocking. */ sleepq_lock(&sx->lock_object); - x = sx->sx_lock; + x = SX_READ_VALUE(sx); /* * The lock could have been released while we spun. @@ -946,6 +960,7 @@ _sx_slock_hard(struct sx *sx, int opts, owner = (struct thread *)SX_OWNER(x); if (TD_IS_RUNNING(owner)) { sleepq_release(&sx->lock_object); + x = SX_READ_VALUE(sx); continue; } } @@ -960,6 +975,7 @@ _sx_slock_hard(struct sx *sx, int opts, if (!atomic_cmpset_ptr(&sx->sx_lock, x, x | SX_LOCK_SHARED_WAITERS)) { sleepq_release(&sx->lock_object); + x = SX_READ_VALUE(sx); continue; } if (LOCK_LOG_TEST(&sx->lock_object, 0)) @@ -1000,6 +1016,7 @@ _sx_slock_hard(struct sx *sx, int opts, if (LOCK_LOG_TEST(&sx->lock_object, 0)) CTR2(KTR_LOCK, "%s: %p resuming from sleep queue", __func__, sx); + x = SX_READ_VALUE(sx); } #ifdef KDTRACE_HOOKS all_time += lockstat_nsecs(&sx->lock_object); @@ -1034,9 +1051,8 @@ _sx_sunlock_hard(struct sx *sx, const ch if (SCHEDULER_STOPPED()) return; + x = SX_READ_VALUE(sx); for (;;) { - x = sx->sx_lock; - /* * We should never have sharers while at least one thread * holds a shared lock. @@ -1058,6 +1074,8 @@ _sx_sunlock_hard(struct sx *sx, const ch (void *)(x - SX_ONE_SHARER)); break; } + + x = SX_READ_VALUE(sx); continue; } @@ -1074,6 +1092,7 @@ _sx_sunlock_hard(struct sx *sx, const ch __func__, sx); break; } + x = SX_READ_VALUE(sx); continue; } @@ -1095,6 +1114,7 @@ _sx_sunlock_hard(struct sx *sx, const ch SX_SHARERS_LOCK(1) | SX_LOCK_EXCLUSIVE_WAITERS, SX_LOCK_UNLOCKED)) { sleepq_release(&sx->lock_object); + x = SX_READ_VALUE(sx); continue; } if (LOCK_LOG_TEST(&sx->lock_object, 0)) Modified: stable/11/sys/sys/mutex.h ============================================================================== --- stable/11/sys/sys/mutex.h Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/sys/mutex.h Thu Mar 16 01:32:56 2017 (r315341) @@ -420,9 +420,15 @@ extern struct mtx_pool *mtxpool_sleep; _sleep((chan), &(mtx)->lock_object, (pri), (wmesg), \ tick_sbt * (timo), 0, C_HARDCLOCK) +#define MTX_READ_VALUE(m) ((m)->mtx_lock) + #define mtx_initialized(m) lock_initialized(&(m)->lock_object) -#define mtx_owned(m) (((m)->mtx_lock & ~MTX_FLAGMASK) == (uintptr_t)curthread) +#define lv_mtx_owner(v) ((struct thread *)((v) & ~MTX_FLAGMASK)) + +#define mtx_owner(m) lv_mtx_owner(MTX_READ_VALUE(m)) + +#define mtx_owned(m) (mtx_owner(m) == curthread) #define mtx_recursed(m) ((m)->mtx_recurse != 0) Modified: stable/11/sys/sys/rwlock.h ============================================================================== --- stable/11/sys/sys/rwlock.h Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/sys/rwlock.h Thu Mar 16 01:32:56 2017 (r315341) @@ -76,6 +76,8 @@ #define rw_recurse lock_object.lo_data +#define RW_READ_VALUE(x) ((x)->rw_lock) + /* Very simple operations on rw_lock. */ /* Try to obtain a write lock once. */ Modified: stable/11/sys/sys/sx.h ============================================================================== --- stable/11/sys/sys/sx.h Thu Mar 16 01:04:30 2017 (r315340) +++ stable/11/sys/sys/sx.h Thu Mar 16 01:32:56 2017 (r315341) @@ -88,6 +88,11 @@ #define sx_recurse lock_object.lo_data +#define SX_READ_VALUE(sx) ((sx)->sx_lock) + +#define lv_sx_owner(v) \ + ((v & SX_LOCK_SHARED) ? NULL : (struct thread *)SX_OWNER(v)) + /* * Function prototipes. Routines that start with an underscore are not part * of the public interface and are wrappered with a macro. From owner-svn-src-all@freebsd.org Thu Mar 16 01:36:10 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6F363D0DE7D; Thu, 16 Mar 2017 01:36:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 49BFC1752; Thu, 16 Mar 2017 01:36:10 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2G1a9Ww058247; Thu, 16 Mar 2017 01:36:09 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2G1a9JV058246; Thu, 16 Mar 2017 01:36:09 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201703160136.v2G1a9JV058246@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Thu, 16 Mar 2017 01:36:09 +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: r315342 - stable/11/share/mk X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Mar 2017 01:36:10 -0000 Author: ngie Date: Thu Mar 16 01:36:09 2017 New Revision: 315342 URL: https://svnweb.freebsd.org/changeset/base/315342 Log: MFC r314869,r314871,r314872: r314869: Alphabetically sort variables The only content change is minor rewording around CLEANDIRS/CLEANFILES to accomodate sorting order. r314871: Fix LINKS example in bsd.prog.mk LINKS appends DESTDIR -- don't suggest double-append in example. r314872: Add bsd.man.mk references for MAN under bsd.lib.mk and bsd.prog.mk The latter set of manpages directly consume bsd.man.mk, so the bsd.man.mk behavior should be the source of truth for underlying behavior, whereas the other manpage fragment descriptions should document how they tweak the variable behavior, if at all (bsd.prog.mk does tweak the default value, as noted in its description) Modified: stable/11/share/mk/bsd.README Directory Properties: stable/11/ (props changed) Modified: stable/11/share/mk/bsd.README ============================================================================== --- stable/11/share/mk/bsd.README Thu Mar 16 01:32:56 2017 (r315341) +++ stable/11/share/mk/bsd.README Thu Mar 16 01:36:09 2017 (r315342) @@ -180,19 +180,19 @@ It has three targets: It sets/uses the following variables: +MAN The manual pages to be installed (use a .1 - .9 suffix). + MANDIR Base path for manual installation. MANGRP Manual group. -MANOWN Manual owner. - MANMODE Manual mode. +MANOWN Manual owner. + MANSUBDIR Subdirectory under the manual page section, i.e. "/vax" or "/tahoe" for machine specific manual pages. -MAN The manual pages to be installed (use a .1 - .9 suffix). - MLINKS List of manual page links (using a .1 - .9 suffix). The linked-to file must come first, the linked file second, and there may be multiple pairs. The files are hard-linked. @@ -211,18 +211,18 @@ It sets/uses the following variables: BINGRP Binary group. -BINOWN Binary owner. - BINMODE Binary mode. +BINOWN Binary owner. + MANDIR Base path for manual installation. MANGRP Manual group. -MANOWN Manual owner. - MANMODE Manual mode. +MANOWN Manual owner. + This file is generally useful when building your own Makefiles so that they use the same default owners etc. as the rest of the tree. @@ -257,23 +257,43 @@ It has seven targets: It sets/uses the following variables: -AFLAGS Flags to the assembler when assembling .s files. - ACFLAGS Flags to the compiler when preprocessing and assembling .S files. -BINGRP Binary group. +AFLAGS Flags to the assembler when assembling .s files. -BINOWN Binary owner. +BINGRP Binary group. BINMODE Binary mode. -CLEANFILES Additional files to remove and -CLEANDIRS additional directories to remove during clean and cleandir - targets. "rm -f" and "rm -rf" used respectively. +BINOWN Binary owner. CFLAGS Flags to the compiler when creating C objects. +CLEANDIRS Additional files (CLEANFILES) and directories (CLEANDIRS) to +CLEANFILES remove during clean and cleandir targets. "rm -rf" and + "rm -f" are used, respectively. + +DPADD Additional dependencies for the program. Usually used for + libraries. For example, to depend on the compatibility and + utility libraries use: + + DPADD=${LIBCOMPAT} ${LIBUTIL} + + There is a predefined identifier for each (non-profiled, + non-shared) library and object. Library file names are + transformed to identifiers by removing the extension and + converting to upper case. + + There are no special identifiers for profiled or shared + libraries or objects. The identifiers for the standard + libraries are used in DPADD. This works correctly iff all + the libraries are built at the same time. Unfortunately, + it causes unnecessary relinks to shared libraries when + only the static libraries have changed. Dependencies on + shared libraries should be only on the library version + numbers. + FILES A list of non-executable files. The installation is controlled by the FILESNAME, FILESOWN, FILESGRP, FILESMODE, FILESDIR variables that can be @@ -285,27 +305,30 @@ LDADD Additional loader objects. Usual LDADD=-lutil -lcompat -LIBADD Additional libraries. This is for base system libraries - and is only valid inside of the /usr/src tree. - Rather than use LDADD=-lname use LIBADD=name. - LDFLAGS Additional loader flags. Passed to the loader via CC, since that's used to link programs as well, so loader specific flags need to be prefixed with -Wl, to work. +LIBADD Additional libraries. This is for base system libraries + and is only valid inside of the /usr/src tree. + Rather than use LDADD=-lname use LIBADD=name. + LINKS The list of binary links; should be full pathnames, the linked-to file coming first, followed by the linked file. The files are hard-linked. For example, to link /bin/test and /bin/[, use: - LINKS= ${DESTDIR}/bin/test ${DESTDIR}/bin/[ + LINKS= /bin/test /bin/[ -MAN Manual pages (should end in .1 - .9). If no MAN variable - is defined, "MAN=${PROG}.1" is assumed. +MAN Manual pages. If no MAN variable is defined, + "MAN=${PROG}.1" is assumed. See bsd.man.mk for more details. PROG The name of the program to build. If not supplied, nothing is built. +PROGNAME The name that the above program will be installed as, if + different from ${PROG}. + PROG_CXX If defined, the name of the program to build. Also causes to link the program with the standard C++ library. PROG_CXX overrides the value @@ -344,33 +367,15 @@ PROGS_CXX PROG and PROGS_CXX in one Make - STRIP - WARNS -PROGNAME The name that the above program will be installed as, if - different from ${PROG}. +SCRIPTS A list of interpreter scripts [file.{sh,csh,pl,awk,...}]. + The installation is controlled by the SCRIPTSNAME, SCRIPTSOWN, + SCRIPTSGRP, SCRIPTSMODE, SCRIPTSDIR variables that can be + further specialized by SCRIPTS_