Re: parent inode from the current struct inode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jack,

On Wed, Feb 8, 2012 at 8:48 AM, Jack David <jd6589@xxxxxxxxx> wrote:
> Hi All,
>
> Is possible to get parent directory's inode structure from the current
> inode? If so, how can I do that?

It should be possible to use the container_of macro to get the parent
dentry struct. Then, you can get the parent dentry d_parent and access
its inode. (Please correct me, if I'm wrong. I didn't test it).



Philipp

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux