From: Dmitry Eremin Date: Mon, 22 Jul 2013 16:06:28 +0000 (+0800) Subject: staging/lustre/llite: A not locked mutex can be unlocked. X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e06c9dfec0f3738409b3936dcd0a4ae126acac07;p=linux-beck.git staging/lustre/llite: A not locked mutex can be unlocked. In case of memory pressure a not locked mutex can be unlocked in function ll_file_open(). This is not allowed and subsequent behavior is not defined. Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3157 Lustre-change: http://review.whamcloud.com/6028 Signed-off-by: Dmitry Eremin Reviewed-by: John Hammond Reviewed-by: Nikitas Angelinas Reviewed-by: Sebastien Buisson Reviewed-by: Andreas Dilger Signed-off-by: Peng Tao Signed-off-by: Andreas Dilger Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/lustre/llite/file.c b/drivers/staging/lustre/lustre/llite/file.c index 927b3a03e654..717682c162ec 100644 --- a/drivers/staging/lustre/lustre/llite/file.c +++ b/drivers/staging/lustre/lustre/llite/file.c @@ -526,7 +526,7 @@ int ll_file_open(struct inode *inode, struct file *file) fd = ll_file_data_get(); if (fd == NULL) - GOTO(out_och_free, rc = -ENOMEM); + GOTO(out_openerr, rc = -ENOMEM); fd->fd_file = file; if (S_ISDIR(inode->i_mode)) {