projects
/
userspace-rcu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rcuhlist: make pointer stores atomic
[userspace-rcu.git]
/
urcu
/
rcuhlist.h
diff --git
a/urcu/rcuhlist.h
b/urcu/rcuhlist.h
index 36da15bc31d95394420a6958c05a5435927b1c2b..6d88692e854faf51a4105a8c7d46baa5c624e6c6 100644
(file)
--- a/
urcu/rcuhlist.h
+++ b/
urcu/rcuhlist.h
@@
-36,10
+36,9
@@
void cds_hlist_add_head_rcu(struct cds_hlist_node *newp,
{
newp->next = head->next;
newp->prev = (struct cds_hlist_node *)head;
{
newp->next = head->next;
newp->prev = (struct cds_hlist_node *)head;
- cmm_smp_wmb();
if (head->next)
head->next->prev = newp;
if (head->next)
head->next->prev = newp;
-
head->next = newp
;
+
rcu_assign_pointer(head->next, newp)
;
}
/* Remove element from list. */
}
/* Remove element from list. */
@@
-48,7
+47,7
@@
void cds_hlist_del_rcu(struct cds_hlist_node *elem)
{
if (elem->next)
elem->next->prev = elem->prev;
{
if (elem->next)
elem->next->prev = elem->prev;
-
elem->prev->next = elem->next
;
+
CMM_STORE_SHARED(elem->prev->next, elem->next)
;
}
/*
}
/*
This page took
0.025768 seconds
and
4
git commands to generate.