[haiku-development] Re: fs API: get_vnode limitation

  • From: Janito Ferreira Filho <jvffprog@xxxxxxxxxxx>
  • To: Haiku Development <haiku-development@xxxxxxxxxxxxx>
  • Date: Sun, 11 Jul 2010 04:42:18 +0000

Hi Lucian,

> lucian.grijincu@xxxxxxxxx wrote:
> 
> B) add a hashmap inside my driver. The lookup() hook would insert
> (ino_t, full_path) entries in the hashmap, and the get_vnode() hook
> will access this hashmap to retrieve the corresponding full_path. All
> the locking involved would

Don't know if this helps, but there is a hash table implementation in the kernel
(util/khash.h) that also grows as needed, but AFAIK it's not thread safe, so 
you probably need a rw_lock to protect it. Just a small tip, don't know if it's
useful =)

Janito
                                          
_________________________________________________________________
Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
https://signup.live.com/signup.aspx?id=60969

Other related posts: