X-Git-Url: https://git.liburcu.org/?p=urcu.git;a=blobdiff_plain;f=urcu%2Frculist.h;h=1fd2df388f57cefc0ea19fa02a0c8c0b627847e8;hp=ab88226b5f73d9ffff856ff347aefb3757c6a53f;hb=b0a841b4ff807dd29fe0cdbfe24900312f0e627b;hpb=e2fcb2d325f216c558beca525ac25e4e42115dbb diff --git a/urcu/rculist.h b/urcu/rculist.h index ab88226..1fd2df3 100644 --- a/urcu/rculist.h +++ b/urcu/rculist.h @@ -35,9 +35,8 @@ void cds_list_add_rcu(struct cds_list_head *newp, struct cds_list_head *head) { newp->next = head->next; newp->prev = head; - cmm_smp_wmb(); head->next->prev = newp; - head->next = newp; + rcu_assign_pointer(head->next, newp); } /* Add new element at the tail of the list. */ @@ -70,7 +69,7 @@ static inline void cds_list_del_rcu(struct cds_list_head *elem) { elem->next->prev = elem->prev; - elem->prev->next = elem->next; + CMM_STORE_SHARED(elem->prev->next, elem->next); } /*