From owner-svn-src-head@freebsd.org Fri Sep 30 17:55:45 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 53F7DC0362A; Fri, 30 Sep 2016 17:55:45 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-wm0-x22b.google.com (mail-wm0-x22b.google.com [IPv6:2a00:1450:400c: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 E0AB466B; Fri, 30 Sep 2016 17:55:44 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: by mail-wm0-x22b.google.com with SMTP id k125so39446135wma.1; Fri, 30 Sep 2016 10:55:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=vWK13XDppviuhYv7qV+qfPpy3+J/FIe3D/LnlQRzSec=; b=RJdqm9c784AaVG2IzIg82xTSq6TUthT22NDxt08sun3B7JskZCit0MLI0cHnISAJ7W llc8XqWjU2nvHd6QgdQAbcodcAK0IZJ0MRpaHa7UWXC+zEbSDSgs3+YEwd5LiiWG2lQ6 vxF53VFEUZUPvRVJlwTbeIUEXTa+9/CKzwiIpOldjMuplmPjRKn6Cr62wdFxgaxlX3+4 qQVePj+dlehMRRkrtD0Ai8b0beI+5M/KoI4stTNCuu/PavXzmaH8r0k5Kyr31HT9flcm QwPpT5rDkU6OTyzh6JzBNMekOkhsfGXAvv7HxmVLksMqSY9eAOFcURqKxLI4ryN9+Yhw QvZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=vWK13XDppviuhYv7qV+qfPpy3+J/FIe3D/LnlQRzSec=; b=makHkS/Slsd3Rj+tVfNasa2HSSjsPO6p7DE0t+UCLerh5nQ2jPL5TROOK05GSfal3l qhYiTsXEc2d+reNRtgYNmN8Xb2Xh+WTU5lNYA06CApZXyk424213G3ajtezjdnOZK7Rq w5IU3mQRVxC9l9wTavyBqD9lAW607qiuw+T3kqlgdQPdf4U0C/wNTDcdSX/OlxhjeLUN IpPQUMENGzI34s5DdpT9n5PidoUINN1J6Vh1bX7JdReyhsYlcCASUgRvUHGrcYlKkqQd yskkDdidt3WaF3gq5bkXrE5B+8047ot0WJYxbSXZ+4ThZF1Un+h7DmBoykABW5I5Uvhu 8SIw== X-Gm-Message-State: AA6/9Rn86zqtlPZISrqbu3BxwNldiX80Tg/y3Ir0eUSwMvH7BJsqyYCM4GAJv5yhS6JV9A== X-Received: by 10.194.84.134 with SMTP id z6mr7314716wjy.204.1475258143402; Fri, 30 Sep 2016 10:55:43 -0700 (PDT) Received: from dft-labs.eu (n1x0n-1-pt.tunnel.tserv5.lon1.ipv6.he.net. [2001:470:1f08:1f7::2]) by smtp.gmail.com with ESMTPSA id uw3sm20775042wjb.21.2016.09.30.10.55.42 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Fri, 30 Sep 2016 10:55:42 -0700 (PDT) Date: Fri, 30 Sep 2016 19:55:40 +0200 From: Mateusz Guzik To: Larry Rosenman Cc: Shawn Webb , svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Mateusz Guzik , owner-svn-src-all@freebsd.org Subject: Re: svn commit: r306509 - in head/sys: fs/nandfs kern sys ufs/ffs Message-ID: <20160930175540.GD3714@dft-labs.eu> References: <201609301711.u8UHB35d046389@repo.freebsd.org> <20160930171845.GA62393@mutt-hardenedbsd> <20160930172845.GC3714@dft-labs.eu> <9eddf030ed57a527c2d23e32289df7cf@thebighonker.lerctr.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <9eddf030ed57a527c2d23e32289df7cf@thebighonker.lerctr.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Sep 2016 17:55:45 -0000 On Fri, Sep 30, 2016 at 01:36:26PM -0400, Larry Rosenman wrote: > On 2016-09-30 13:28, Mateusz Guzik wrote: > >On Fri, Sep 30, 2016 at 01:18:45PM -0400, Shawn Webb wrote: > >>On Fri, Sep 30, 2016 at 05:11:03PM +0000, Mateusz Guzik wrote: > >>> Author: mjg > >>> Date: Fri Sep 30 17:11:03 2016 > >>> New Revision: 306509 > >>> URL: https://svnweb.freebsd.org/changeset/base/306509 > >>> > >>> Log: > >>> vfs: remove the __bo_vnode field from struct vnode > >>> > >>> The pointer can be obtained using __containerof instead. > >>> > >>> Reviewed by: kib > >> > >>Should __FreeBSD_Version be bumped? > >> > > > >Unlikely. It can be in an odd case it turns out there is a module which > >is using the field. > > Can someone do me a favor and make sure sysutils/lsof still > compiles/works? > > I'm OOT at the moment, and have a test IPv6 patch on my 12 system. I just ran lsof and it worked fine at least for the basic case. Apparently it indeed still goes through kernel memory. Did anyone ask the author what kind of interfaces would they want to NOT have to do this? Also, it looks like it constains some kind of a loop to imitate closefrom. On truss I see over 3.7 milion (yes, MILION) calls to close. Like this: close(3773297) ERR#9 'Bad file descriptor' close(3773298) ERR#9 'Bad file descriptor' close(3773299) ERR#9 'Bad file descriptor' close(3773300) ERR#9 'Bad file descriptor' close(3773301) ERR#9 'Bad file descriptor' close(3773302) ERR#9 'Bad file descriptor' close(3773303) ERR#9 'Bad file descriptor' [snip] At least for freebsd this can be patched with the use of closefrom() on all supported releases. Arguably this may be a side effect of limits set too high, perhaps linux sets them sigifnicanly lower and the problem is not that terrible. -- Mateusz Guzik