From: Andreas Gruenbacher Date: Mon, 17 Jul 2017 18:39:15 +0000 (-0500) Subject: gfs2: Lock holder cleanup (fixup) X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=283c9a97be1d7ab2cce2630b5f6cc793f3b387a1;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git gfs2: Lock holder cleanup (fixup) Function gfs2_holder_initialized should be used in do_flock as well. Signed-off-by: Andreas Gruenbacher Signed-off-by: Bob Peterson --- diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c index c2062a108d19..bb48074be019 100644 --- a/fs/gfs2/file.c +++ b/fs/gfs2/file.c @@ -1030,8 +1030,7 @@ static int do_flock(struct file *file, int cmd, struct file_lock *fl) mutex_lock(&fp->f_fl_mutex); - gl = fl_gh->gh_gl; - if (gl) { + if (gfs2_holder_initialized(fl_gh)) { if (fl_gh->gh_state == state) goto out; locks_lock_file_wait(file,