From owner-freebsd-arch@FreeBSD.ORG Thu Jan 12 21:58:42 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2AF8D1065677 for ; Thu, 12 Jan 2012 21:58:42 +0000 (UTC) (envelope-from kris@pcbsd.org) Received: from mail.iXsystems.com (newknight.ixsystems.com [206.40.55.70]) by mx1.freebsd.org (Postfix) with ESMTP id 0575A8FC1F for ; Thu, 12 Jan 2012 21:58:41 +0000 (UTC) Received: from mail.ixsystems.com (localhost [127.0.0.1]) by mail.iXsystems.com (Postfix) with ESMTP id C28945E7 for ; Thu, 12 Jan 2012 13:43:09 -0800 (PST) Received: from mail.iXsystems.com ([127.0.0.1]) by mail.ixsystems.com (mail.ixsystems.com [127.0.0.1]) (amavisd-maia, port 10024) with ESMTP id 17949-05 for ; Thu, 12 Jan 2012 13:43:09 -0800 (PST) Received: from [192.168.0.186] (75-130-56-30.static.kgpt.tn.charter.com [75.130.56.30]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mail.iXsystems.com (Postfix) with ESMTPSA id 2ACBE5E2 for ; Thu, 12 Jan 2012 13:43:09 -0800 (PST) Message-ID: <4F0F53EC.1020608@pcbsd.org> Date: Thu, 12 Jan 2012 16:43:08 -0500 From: Kris Moore User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:9.0) Gecko/20111227 Thunderbird/9.0 MIME-Version: 1.0 To: freebsd-arch@freebsd.org References: <86sjjobzmn.fsf@kopusha.home.net> <86fwfnti5t.fsf@kopusha.home.net> In-Reply-To: X-Enigmail-Version: undefined Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: unix domain sockets on nullfs(5) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 Jan 2012 21:58:42 -0000 On 01/12/2012 16:39, Robert N. M. Watson wrote: > On 12 Jan 2012, at 21:17, Mikolaj Golub wrote: > >> If we agree to have only the new behavior then nullfs won't need modification >> at all, it will work as expected automatically. The patch could be (with updated >> locking for the connect case): >> >> http://people.freebsd.org/~trociny/VOP_UNP.1.patch > Greatly simplified. > >> --- sys/kern/uipc_usrreq.c (revision 229979) >> +++ sys/kern/uipc_usrreq.c (working copy) >> @@ -542,7 +542,7 @@ >> >> UNP_LINK_WLOCK(); >> UNP_PCB_LOCK(unp); >> - vp->v_socket = unp->unp_socket; >> + VOP_UNPBIND(vp, unp->unp_socket); >> unp->unp_vnode = vp; >> unp->unp_addr = soun; >> unp->unp_flags &= ~UNP_BINDING; > > I still find myself worried by the fact that unp->unp_vnode points at the nullfs vnode rather than the underlying vnode, but haven't yet managed to identify any actual bugs that would result. I'll continue pondering it over the weekend :-). > > Robert_______________________________________________ > freebsd-arch@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org" FYI - Not sure if this helps, but we've been using this patch to expose sockets in the lower layer for 2+ years now, haven't run into any issues as of yet. http://trac.pcbsd.org/browser/pcbsd/current/build-files/src-patches/nullfs-patch -- Kris Moore PC-BSD Software iXsystems