From owner-freebsd-hackers Sun Jan 18 14:49:40 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA22194 for hackers-outgoing; Sun, 18 Jan 1998 14:49:40 -0800 (PST) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from gvr.gvr.org (root@gvr.gvr.org [194.151.74.97]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id OAA22122 for ; Sun, 18 Jan 1998 14:49:14 -0800 (PST) (envelope-from guido@gvr.org) Received: (from guido@localhost) by gvr.gvr.org (8.8.6/8.8.5) id XAA25043; Sun, 18 Jan 1998 23:49:05 +0100 (MET) From: Guido van Rooij Message-Id: <199801182249.XAA25043@gvr.gvr.org> Subject: Re: socket ops In-Reply-To: <199801182236.PAA05447@usr04.primenet.com> from Terry Lambert at "Jan 18, 98 10:36:29 pm" To: tlambert@primenet.com (Terry Lambert) Date: Sun, 18 Jan 1998 23:49:04 +0100 (MET) Cc: tlambert@primenet.com, FreeBSD-hackers@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL32 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk Terry Lambert wrote: > > > Look for "struct fileops" in /sys/kern/*.c, and all will be revealed. > > > > > > The mode is referenced via VOP_GETATTR/VOP_SETATTR off of a vnode > > > to get the FS specific method of getting/setting mode bits. If you > > > do not have a backing object, you do not have mode bits. > > > > ?? There *is* a backing object. I am talking about UNIX domain > > sockets here. > > That's a handle object, not a backing object. Go look for the > "struct fileops" stuff. I still don't see what fileops has to do with it. I am not talking about accessing (read or write) the unix domain socket. > > If there was a backing object, you'd reference the thing by vnode and > you'd be able to fchmod it. a unix domain socket has a vnode created by VOP_CREATE. I can reference it via the struct unpcb pointer hanging off the struct socket. > > Look at it this way; I call socketpair(). In which FS does the backing > object (inode that I can reference by vnode) exist? Nowhere. In this case the vnode pointer in the unpcb is zero. -Guido