GFS2: Remove potential race in flock code
authorSteven Whitehouse <swhiteho@redhat.com>
Wed, 9 Mar 2011 11:14:32 +0000 (11:14 +0000)
committerSteven Whitehouse <swhiteho@redhat.com>
Wed, 9 Mar 2011 11:14:32 +0000 (11:14 +0000)
commit0a33443b38746f35fc4acc8a5af6c7099e03ea40
tree523d8bec4c49a3b04b46fe275e1c4ef3f18fba7a
parentfc0e38dae645f65424d1fb5d2a938aab8ce48a58
GFS2: Remove potential race in flock code

This patch ensures that we always wait for glock demotion when
dropping flocks on a file in order to prevent any race
conditions associated with further flock calls or closing
the file.

Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/file.c