diff options
author | Justus Winter <4winter@informatik.uni-hamburg.de> | 2014-05-13 13:09:15 +0200 |
---|---|---|
committer | Justus Winter <4winter@informatik.uni-hamburg.de> | 2015-04-11 18:42:45 +0200 |
commit | 4166312a45357c2ff11b00219dfb83b7475ac4b1 (patch) | |
tree | aed733fb9c132c1745856c89f75b55ccd21cd58f /term/devio.c | |
parent | b8ffab7c38f3ede424b8a07553d6ee6b16abb85b (diff) |
ext2fs: use a seperate lock to protect nodehash
Previously, ext2fs used diskfs_node_refcnt_lock to serialize access to
the nodehash.
Use a separate lock to protect nodehash. Adjust the reference
counting accordingly. Every node in the nodehash carries a light
reference. When we are asked to give up that light reference, we
reacquire our lock momentarily to check whether someone else
reacquired a reference through the nodehash.
* ext2fs/inode.c (nodecache_lock): New lock.
(diskfs_cached_lookup): Use a separate lock to protect nodehash.
Adjust the reference counting accordingly.
(ifind): Likewise.
(diskfs_node_iterate): Likewise.
(diskfs_node_norefs): Move the code removing the node from nodehash...
(diskfs_try_dropping_softrefs): ... here, where we check whether
someone reacquired a reference, and if so hold on to our light
reference.
Diffstat (limited to 'term/devio.c')
0 files changed, 0 insertions, 0 deletions