Messages in this thread | | | From | Paul Menage <> | Subject | Re: [RFC][PATCH 2.4.17] Your suggestions for fast path walk | Date | Thu, 14 Feb 2002 12:06:40 -0800 |
| |
>I have also combined path_init and path_walk in places where >they are always called together.
This is nice from a code simplification point of view, and is mostly orthogonal to the fast path walking.
I'd be inclined to call this combined function something like path_lookup(), rather than path_init_walk() - the callers don't need to know that it's an init followed by a walk, they just need to know that it does a lookup.
Also, to avoid code duplication, is there any reason why path_lookup() can't be implemented (possibly inlined) just as:
static int path_lookup(const char *name, struct nameidata *nd, int flags) {
if(!path_init(name, flags, nd)) return 0;
return path_walk(name, nd);
}
Paul - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |