Skip to content

Commit 8e6af01

Browse files
Ethan Hansenpaulmckrcu
authored andcommitted
rcu: Remove unused function hlist_bl_del_init_rcu()
The function hlist_bl_del_init_rcu() is declared in rculist_bl.h, but never used. This commit therefore removes it. Signed-off-by: Ethan Hansen <[email protected]> Signed-off-by: Paul E. McKenney <[email protected]>
1 parent 54ecb8f commit 8e6af01

File tree

1 file changed

+0
-28
lines changed

1 file changed

+0
-28
lines changed

include/linux/rculist_bl.h

Lines changed: 0 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -24,34 +24,6 @@ static inline struct hlist_bl_node *hlist_bl_first_rcu(struct hlist_bl_head *h)
2424
((unsigned long)rcu_dereference_check(h->first, hlist_bl_is_locked(h)) & ~LIST_BL_LOCKMASK);
2525
}
2626

27-
/**
28-
* hlist_bl_del_init_rcu - deletes entry from hash list with re-initialization
29-
* @n: the element to delete from the hash list.
30-
*
31-
* Note: hlist_bl_unhashed() on the node returns true after this. It is
32-
* useful for RCU based read lockfree traversal if the writer side
33-
* must know if the list entry is still hashed or already unhashed.
34-
*
35-
* In particular, it means that we can not poison the forward pointers
36-
* that may still be used for walking the hash list and we can only
37-
* zero the pprev pointer so list_unhashed() will return true after
38-
* this.
39-
*
40-
* The caller must take whatever precautions are necessary (such as
41-
* holding appropriate locks) to avoid racing with another
42-
* list-mutation primitive, such as hlist_bl_add_head_rcu() or
43-
* hlist_bl_del_rcu(), running on this same list. However, it is
44-
* perfectly legal to run concurrently with the _rcu list-traversal
45-
* primitives, such as hlist_bl_for_each_entry_rcu().
46-
*/
47-
static inline void hlist_bl_del_init_rcu(struct hlist_bl_node *n)
48-
{
49-
if (!hlist_bl_unhashed(n)) {
50-
__hlist_bl_del(n);
51-
n->pprev = NULL;
52-
}
53-
}
54-
5527
/**
5628
* hlist_bl_del_rcu - deletes entry from hash list without re-initialization
5729
* @n: the element to delete from the hash list.

0 commit comments

Comments
 (0)