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-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <719af3d3d50b66843f876c8edf7f40486e20d334.1460380917.git.jslaby@suse.cz>
Date:	Mon, 11 Apr 2016 15:22:17 +0200
From:	Jiri Slaby <jslaby@...e.cz>
To:	stable@...r.kernel.org
Cc:	linux-kernel@...r.kernel.org,
	Wang Shilong <wangsl.fnst@...fujitsu.com>,
	Josef Bacik <jbacik@...com>, Jiri Slaby <jslaby@...e.cz>
Subject: [PATCH 3.12 15/98] Btrfs: skip locking when searching commit root

From: Wang Shilong <wangsl.fnst@...fujitsu.com>

3.12-stable review patch.  If anyone has any objections, please let me know.

===============

commit e84752d434b5cca0869e906e7b94d0531b25c6d3 upstream.

We won't change commit root, skip locking dance with commit root
when walking backrefs, this can speed up btrfs send operations.

Signed-off-by: Wang Shilong <wangsl.fnst@...fujitsu.com>
Signed-off-by: Josef Bacik <jbacik@...com>
Signed-off-by: Jiri Slaby <jslaby@...e.cz>
---
 fs/btrfs/backref.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c
index 5859a05f3a76..b7f40f2630f4 100644
--- a/fs/btrfs/backref.c
+++ b/fs/btrfs/backref.c
@@ -842,8 +842,10 @@ static int find_parent_nodes(struct btrfs_trans_handle *trans,
 	path = btrfs_alloc_path();
 	if (!path)
 		return -ENOMEM;
-	if (!trans)
+	if (!trans) {
 		path->search_commit_root = 1;
+		path->skip_locking = 1;
+	}
 
 	/*
 	 * grab both a lock on the path and a lock on the delayed ref head.
-- 
2.8.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ