From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Howells Subject: Re: [PATCH] Update the exportfs documentation and comments and fix some exportfs issues Date: Wed, 03 Dec 2008 10:54:50 +0000 Message-ID: <29007.1228301690@redhat.com> References: <49364304.7000501@lougher.demon.co.uk> <20081202210233.19035.48005.stgit@warthog.procyon.org.uk> Cc: dhowells@redhat.com, hch@infradead.org, viro@ZenIV.linux.org.uk, linux-fsdevel@vger.kernel.org To: Phillip Lougher Return-path: Received: from mx2.redhat.com ([66.187.237.31]:53587 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751428AbYLCKzQ (ORCPT ); Wed, 3 Dec 2008 05:55:16 -0500 In-Reply-To: <49364304.7000501@lougher.demon.co.uk> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Phillip Lougher wrote: > You define these in the filesystem c files themselves as #defines. UDF and > BTRFS place theirs in the enum fid_type definition itself (in > linux/exportfs.h). Is there any reason why you didn't do this? I don't know that we want to stick loads of filesystem-specific stuff into a general header file. I believe we used to do that for struct inode (IIRC there used to be a large union with filesystem-specific members). > > int type = FILEID_INO32_GEN; > > ^^^^ > > this should be changed to enum fid_type I missed that. Updated. > > +#define FUSE_FILEID ((enum fid_type) 0x81) > > +#define FUSE_FILEID_PARENT ((enum fid_type) 0x82) > > Move to enum fid_type in linux/exportfs.h? As mentioned above, do we really want to do that? > > +#define ISOFS_FILEID ((enum fid_type) 1) > > +#define ISOFS_FILEID_PARENT ((enum fid_type) 2) > > + > > Move to enum fid_type in linux/exportfs.h? > > Type 1 and 2 are also used by the generic fid_types FILEID_INO32_GEN and > FILEID_INO32_GEN_PARENT, but (obviously) their formats are different. I know. As far as I know, there's no restriction on them reusing types 1 and 2, just an advisory note where these collide with other export types. Perhaps Al or Christoph would care to comment on this. Also, I don't know that changing these types would necessarily be a good idea. wireshark, for example, could multiplex the types by the length as the standard types are lengths 2 and 4, and ISOFS types are 3 and 5. David