Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 376681
b: refs/heads/master
c: c87a124
h: refs/heads/master
i:
  376679: a7040b6
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Jun 3, 2013
1 parent 12a741e commit 5173768
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c802db1164f28e62c6a43132b8d290cb8113f2ac
refs/heads/master: c87a124a5d5e8cf8e21c4363c3372bcaf53ea190
7 changes: 6 additions & 1 deletion trunk/include/linux/rculist_nulls.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,14 @@ static inline void hlist_nulls_add_head_rcu(struct hlist_nulls_node *n,
* @head: the head for your list.
* @member: the name of the hlist_nulls_node within the struct.
*
* The barrier() is needed to make sure compiler doesn't cache first element [1],
* as this loop can be restarted [2]
* [1] Documentation/atomic_ops.txt around line 114
* [2] Documentation/RCU/rculist_nulls.txt around line 146
*/
#define hlist_nulls_for_each_entry_rcu(tpos, pos, head, member) \
for (pos = rcu_dereference_raw(hlist_nulls_first_rcu(head)); \
for (({barrier();}), \
pos = rcu_dereference_raw(hlist_nulls_first_rcu(head)); \
(!is_a_nulls(pos)) && \
({ tpos = hlist_nulls_entry(pos, typeof(*tpos), member); 1; }); \
pos = rcu_dereference_raw(hlist_nulls_next_rcu(pos)))
Expand Down

0 comments on commit 5173768

Please sign in to comment.