]> git.baikalelectronics.ru Git - kernel.git/commit
[GFS2] Fix log entry list corruption
authorBenjamin Marzinski <bmarzins@redhat.com>
Fri, 23 Mar 2007 09:05:12 +0000 (09:05 +0000)
committerSteven Whitehouse <swhiteho@redhat.com>
Tue, 1 May 2007 08:10:50 +0000 (09:10 +0100)
commit5cb7afffc8c513ad97e803b068f5a4dca6ef34b8
treec683994d1f805914fc18f3247cc86cc011a9aa0b
parentd19e4296146b078e7c1ea0660617e0b1a028f05e
[GFS2] Fix log entry list corruption

When glock_lo_add and rg_lo_add attempt to add an element to the log, they
check to see if has already been added before locking the log. If another
process adds that element to the log in this window between the check and
locking the log, the element will be added to the list twice. This causes
the log element list to become corrupted in such a way that the log element
can never be successfully removed from the list. This patch pulls the
list_empty() check inside the log lock, to remove this window.

Signed-off-by: Benjamin E. Marzinski <bmarzins@redhat.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/lops.c