[4.2.y-ckt stable] Patch "drivers/hwspinlock: use correct radix tree API" has been added to the 4.2.y-ckt tree
Kamal Mostafa
kamal at canonical.com
Thu Jun 9 14:37:28 UTC 2016
This is a note to let you know that I have just added a patch titled
drivers/hwspinlock: use correct radix tree API
to the linux-4.2.y-queue branch of the 4.2.y-ckt extended stable tree
which can be found at:
https://git.launchpad.net/~canonical-kernel/linux/+git/linux-stable-ckt/log/?h=linux-4.2.y-queue
This patch is scheduled to be released in version 4.2.8-ckt12.
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 4.2.y-ckt tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Kamal
---8<------------------------------------------------------------
>From c829483aff2f33f2e9c023ec10cfd32911360342 Mon Sep 17 00:00:00 2001
From: Matthew Wilcox <willy at linux.intel.com>
Date: Fri, 20 May 2016 17:03:01 -0700
Subject: drivers/hwspinlock: use correct radix tree API
commit b76ba4af4ddd6a06f7f65769e7be1bc56556cdf5 upstream.
radix_tree_is_indirect_ptr() is an internal API. The correct call to
use is radix_tree_deref_retry() which has the appropriate unlikely()
annotation.
Fixes: c6400ba7e13a ("drivers/hwspinlock: fix race between radix tree insertion and lookup")
Signed-off-by: Matthew Wilcox <willy at linux.intel.com>
Cc: Konstantin Khlebnikov <koct9i at gmail.com>
Cc: Kirill Shutemov <kirill.shutemov at linux.intel.com>
Cc: Jan Kara <jack at suse.com>
Cc: Neil Brown <neilb at suse.de>
Cc: Ross Zwisler <ross.zwisler at linux.intel.com>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
Signed-off-by: Kamal Mostafa <kamal at canonical.com>
---
drivers/hwspinlock/hwspinlock_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwspinlock/hwspinlock_core.c b/drivers/hwspinlock/hwspinlock_core.c
index d50c701..4074441 100644
--- a/drivers/hwspinlock/hwspinlock_core.c
+++ b/drivers/hwspinlock/hwspinlock_core.c
@@ -313,7 +313,7 @@ int of_hwspin_lock_get_id(struct device_node *np, int index)
hwlock = radix_tree_deref_slot(slot);
if (unlikely(!hwlock))
continue;
- if (radix_tree_is_indirect_ptr(hwlock)) {
+ if (radix_tree_deref_retry(hwlock)) {
slot = radix_tree_iter_retry(&iter);
continue;
}
--
2.7.4
More information about the kernel-team
mailing list