[lkml]   [2007]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [RFD 1/4] Pass no useless nameidata to the create, lookup, and permission IOPs
    On Tue, Jun 26, 2007 at 04:15:11PM -0700, wrote:
    > The create, lookup, and permission inode operations are all passed a
    > full nameidata. This is unfortunate because in nfsd and the mqueue
    > filesystem, we must instantiate a struct nameidata but cannot provide
    > all of the same information that a regular lookup would provide. The
    > unused fields take up space on the stack, but more importantly, it is
    > not obvious which fields have meaningful values and which don't, and so
    > things might easily break.
    > This patch introduces struct nameidata2 with only the fields that make
    > sense independent of an actual lookup, and uses that struct in those
    > places where a full nameidat is not needed.

    We need something like this, but I don't quite like the way you've done
    it. First the name is wrong, it's not a nameidata anymore but a lookup
    intent, so it should be named that way, struct lookup_intent. Second
    the macro hackery is more than ugly, please keep the structures separate.
    With modern gcc it might be possible to embed the lookup_intent into
    the nameidata anonymously. Also please either remove the dentry from
    struct lookup_entry or from the direct argument list of the functions
    and methods - there is no need to pass this one twice.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2007-06-30 11:15    [W:0.020 / U:147.664 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site