* exporting open_namei to modules
@ 2001-10-12 23:18 Etay Meiri
2001-10-13 0:03 ` Alexander Viro
0 siblings, 1 reply; 3+ messages in thread
From: Etay Meiri @ 2001-10-12 23:18 UTC (permalink / raw)
To: linux-kernel; +Cc: cl1
Hi,
Is there a particular reason why open_namei() is
not exported to modules?
Please CC me since I'm not on the list.
TIA
-Etay
--
************************************************
"When in doubt, use brute force."
Ken Thompson
Etay Meiri
cl1@netvision.net.il
************************************************
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: exporting open_namei to modules
2001-10-12 23:18 exporting open_namei to modules Etay Meiri
@ 2001-10-13 0:03 ` Alexander Viro
2001-10-13 5:58 ` Etay Meiri
0 siblings, 1 reply; 3+ messages in thread
From: Alexander Viro @ 2001-10-13 0:03 UTC (permalink / raw)
To: Etay Meiri; +Cc: linux-kernel
On Sat, 13 Oct 2001, Etay Meiri wrote:
> Hi,
>
> Is there a particular reason why open_namei() is
> not exported to modules?
Is there any reason for exporting it? By default, stuff is _NOT_
exported. Think for a moment and you'll see why. Exported functions are
public API. Protection is weaker than for syscalls, but it's there and
exporting a function makes harder to do changes in core kernel. Unless
there are damn serious reasons for exporting something, it isn't done.
In particular, open_namei() is a helper function of filp_open(),
which _is_ exported. What use of open_namei() do you have in mind?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: exporting open_namei to modules
2001-10-13 0:03 ` Alexander Viro
@ 2001-10-13 5:58 ` Etay Meiri
0 siblings, 0 replies; 3+ messages in thread
From: Etay Meiri @ 2001-10-13 5:58 UTC (permalink / raw)
To: Alexander Viro; +Cc: linux-kernel
On Fri, Oct 12, 2001 at 08:03:33PM -0400, Alexander Viro wrote:
>
>
> On Sat, 13 Oct 2001, Etay Meiri wrote:
>
> > Hi,
> >
> > Is there a particular reason why open_namei() is
> > not exported to modules?
>
> Is there any reason for exporting it? By default, stuff is _NOT_
> exported. Think for a moment and you'll see why. Exported functions are
> public API. Protection is weaker than for syscalls, but it's there and
> exporting a function makes harder to do changes in core kernel. Unless
> there are damn serious reasons for exporting something, it isn't done.
>
> In particular, open_namei() is a helper function of filp_open(),
> which _is_ exported. What use of open_namei() do you have in mind?
I'm writing a kernel file server. Unlike NFS, clients send me full paths
so I need to translate them to their respective inodes before calling
->open(...).
The reason I didn't use filp_open() in the first place is because it calls
get_empty_filp() and, when I started writing this thing, didn't really understand
and so I thought it was better for me to call open_namei() directly and duplicate
some of the stuff that was going on in filp_open(). Now I see that there is a better
solution.
Thanks Alexander.
>
>
--
************************************************
"When in doubt, use brute force."
Ken Thompson
Etay Meiri
cl1@netvision.net.il
************************************************
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2001-10-13 5:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-10-12 23:18 exporting open_namei to modules Etay Meiri
2001-10-13 0:03 ` Alexander Viro
2001-10-13 5:58 ` Etay Meiri
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox