diff options
author | Frederic Weisbecker <fweisbec@gmail.com> | 2009-05-08 14:21:33 +0200 |
---|---|---|
committer | Frederic Weisbecker <fweisbec@gmail.com> | 2009-09-14 07:18:19 +0200 |
commit | 09eb47a7c52ad535aafca889e0b936c445c375ce (patch) | |
tree | 81ebee49cb84f29e0aa3d884f6ed9c23ab044218 /mm/fremap.c | |
parent | b1c839bb2d8d6f1f6bf48f5c657752b4963f88f8 (diff) | |
download | blackbird-op-linux-09eb47a7c52ad535aafca889e0b936c445c375ce.tar.gz blackbird-op-linux-09eb47a7c52ad535aafca889e0b936c445c375ce.zip |
kill-the-bkl/reiserfs: reduce number of contentions in search_by_key()
search_by_key() is a central function in reiserfs which searches
the patch in the fs tree from the root to a node given its key.
It is the function that is most requesting the write lock
because it's a path very often used.
Also we forget to release the lock while reading the next tree node,
making us holding the lock in a wasteful way.
Then we release the lock while reading the current node and its childs,
all-in-one. It should be safe because we have a reference to these
blocks and even if we read a block that will be concurrently changed,
we have an fs_changed check later that will make us retry the path from
the root.
[ Impact: release the write lock while unused in a hot path ]
Cc: Jeff Mahoney <jeffm@suse.com>
Cc: Chris Mason <chris.mason@oracle.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Alexander Beregalov <a.beregalov@gmail.com>
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Diffstat (limited to 'mm/fremap.c')
0 files changed, 0 insertions, 0 deletions