lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130411062339.GA7603@elgon.mountain>
Date:	Thu, 11 Apr 2013 09:23:39 +0300
From:	Dan Carpenter <dan.carpenter@...cle.com>
To:	Sumit Semwal <sumit.semwal@...aro.org>
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Dave Airlie <airlied@...hat.com>,
	linaro-mm-sig@...ts.linaro.org, linux-kernel@...r.kernel.org,
	kernel-janitors@...r.kernel.org, kbuild@...org
Subject: [patch 1/2 -next] dma-buf: double unlock in debugfs code

We unlock here when we failed to take the lock.

Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
---
This is in linux-next, and I think the debugfs code is only in Sumit's
tree.

diff --git a/drivers/base/dma-buf.c b/drivers/base/dma-buf.c
index 466476f..174cd2c 100644
--- a/drivers/base/dma-buf.c
+++ b/drivers/base/dma-buf.c
@@ -593,7 +593,7 @@ static int dma_buf_describe(struct seq_file *s)
 		if (ret) {
 			seq_printf(s,
 				  "\tERROR locking buffer object: skipping\n");
-			goto skip_buffer;
+			continue;
 		}
 
 		seq_printf(s, "\t");
@@ -618,7 +618,6 @@ static int dma_buf_describe(struct seq_file *s)
 
 		count++;
 		size += buf_obj->size;
-skip_buffer:
 		mutex_unlock(&buf_obj->lock);
 	}

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ