Date: Sun, 11 Nov 2012 08:31:02 +0100
From: manu%netbsd.org@localhost (Emmanuel Dreyfus)
Taylor R Campbell <campbell+netbsd-tech-kern%mumble.net@localhost> wrote:
> I don't think namei.h / vfs_lookup.c is the right place to be handling
> file descriptors. Can you make these take vnodes, rather than file
> descriptors, or move them into vfs_syscalls.c?
I made the change, but it makes nameiat_simple_user() usage more
complicated, with code duplicated on each call (see example at the end)
How about just moving nameiat_simple_user as you had written it before
into vfs_syscalls.c? The utility of the routine -- particularly in
avoiding extra error branches -- is not at issue; it's only that we
ought not to have our vfs abstraction tangled up with the file
descriptor abstraction except where the two abstractions interface by
necessity, in vfs_syscalls.c and vfs_vnops.c.