]> git.baikalelectronics.ru Git - kernel.git/commit
[GFS2] Reorganize function gfs2_glmutex_lock
authorBob Peterson <rpeterso@redhat.com>
Wed, 12 Dec 2007 01:13:54 +0000 (19:13 -0600)
committerSteven Whitehouse <swhiteho@redhat.com>
Fri, 25 Jan 2008 08:13:52 +0000 (08:13 +0000)
commitdb9e829654fcd9e62304aacac37792a6da3e964b
tree64cf07eb0f461aa5d26c2abdc873c8727d8a2bad
parent2136e007dedcc9d49d9d810a22532d8ec3805b94
[GFS2] Reorganize function gfs2_glmutex_lock

This patch optimizes the function gfs2_glmutex_lock.
The basic theory is: Why bother initializing a holder, setting up
wait bits and then waiting on them, if you know the glock can be
yours.  So the holder stuff is placed inside the if checking if the
glock is locked.  This one needs careful scrutiny because changing
anything to do with locking should strike terror into one's heart.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/glock.c