[haiku-development] Re: publish_vnode in ext2

  • From: Jérôme Duval <korli@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Fri, 16 Apr 2010 13:02:13 +0200

Hi Janito,

2010/4/8 Janito Ferreira Filho <jvffprog@xxxxxxxxxxx>:
> when I began to study the ext2 code, one of the first things I ran into was
> a little todo that says there was a little "hack" that used get_vnode
> instead of publish_vnode to create the vnode of the root directory so it can
> create it's file cache. How can I "fix" this "hack"? If I understood the
> problem correctly, we use get_vnode because it will call the volume's
> get_vnode hook which will create an Inode class and then the object will
> create a file_cache for that root directory. Is there some sort of a
> dependency problem here, or is the trouble somewhere else? Can't we just
> create the Inode object (outside of the volume object) and then simply
> publish it? Or is something missing? Thanks,

I'm not sure as the TODO comment seems to date from the first commit by Axel.
As I understand it, the bfs code now does a publish_vnode(). Maybe see
how it was changed in this commit by Ingo:


I hope you get the idea.


Other related posts: