* string to inode conversion
@ 2006-01-15 18:57 pablo.ferlop
2006-01-15 19:24 ` Arjan van de Ven
0 siblings, 1 reply; 4+ messages in thread
From: pablo.ferlop @ 2006-01-15 18:57 UTC (permalink / raw)
To: linux-kernel
Hi
I was wondering how I can get from a string with a path like "/home" or
"/lib/libc-2.3.5.so" a struct inode.
Thanks for your help.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: string to inode conversion
2006-01-15 18:57 string to inode conversion pablo.ferlop
@ 2006-01-15 19:24 ` Arjan van de Ven
2006-01-15 19:49 ` pablo.ferlop
0 siblings, 1 reply; 4+ messages in thread
From: Arjan van de Ven @ 2006-01-15 19:24 UTC (permalink / raw)
To: pablo.ferlop@gmail.com; +Cc: linux-kernel
On Sun, 2006-01-15 at 19:57 +0100, pablo.ferlop@gmail.com wrote:
> Hi
>
> I was wondering how I can get from a string with a path like "/home" or
> "/lib/libc-2.3.5.so" a struct inode.
which namespace do you want this in? The init one? or the one from the
user? (most traditional linux distributions only have one namespace, but
now that COW namespaces are merged I expect distros to start
experimenting with per user /tmp, or per-daemon data etc etc)
This is not a trivial thing... you need a "context" into which you can
ask that question (basically a process)
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: string to inode conversion
2006-01-15 19:24 ` Arjan van de Ven
@ 2006-01-15 19:49 ` pablo.ferlop
2006-01-15 20:27 ` Bob Copeland
0 siblings, 1 reply; 4+ messages in thread
From: pablo.ferlop @ 2006-01-15 19:49 UTC (permalink / raw)
To: Arjan van de Ven; +Cc: linux-kernel
Hi
This should be in kernel space, in the context of system calls.
Basically I'm trying to learn how sys_open() goes from char *filename to
a struct inode. I know (or think) that sys_open() doesn't actually use a
struct inode, but I wonder how that would go.
Thanks
El dom, 15-01-2006 a las 20:24 +0100, Arjan van de Ven escribió:
> On Sun, 2006-01-15 at 19:57 +0100, pablo.ferlop@gmail.com wrote:
> > Hi
> >
> > I was wondering how I can get from a string with a path like "/home" or
> > "/lib/libc-2.3.5.so" a struct inode.
>
> which namespace do you want this in? The init one? or the one from the
> user? (most traditional linux distributions only have one namespace, but
> now that COW namespaces are merged I expect distros to start
> experimenting with per user /tmp, or per-daemon data etc etc)
>
> This is not a trivial thing... you need a "context" into which you can
> ask that question (basically a process)
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: string to inode conversion
2006-01-15 19:49 ` pablo.ferlop
@ 2006-01-15 20:27 ` Bob Copeland
0 siblings, 0 replies; 4+ messages in thread
From: Bob Copeland @ 2006-01-15 20:27 UTC (permalink / raw)
To: pablo.ferlop@gmail.com; +Cc: Arjan van de Ven, linux-kernel
On 1/15/06, pablo.ferlop@gmail.com <pablo.ferlop@gmail.com> wrote:
> Basically I'm trying to learn how sys_open() goes from char *filename to
> a struct inode. I know (or think) that sys_open() doesn't actually use a
> struct inode, but I wonder how that would go.
Look at ext2_lookup in fs/ext2/namei.c for example. It depends on the
filesystem.
-Bob
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2006-01-15 20:27 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-01-15 18:57 string to inode conversion pablo.ferlop
2006-01-15 19:24 ` Arjan van de Ven
2006-01-15 19:49 ` pablo.ferlop
2006-01-15 20:27 ` Bob Copeland
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox