diff options
Diffstat (limited to 'include/linux/rculist.h')
| -rw-r--r-- | include/linux/rculist.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/rculist.h b/include/linux/rculist.h index 779d70749beb..2c9b46cff3d7 100644 --- a/include/linux/rculist.h +++ b/include/linux/rculist.h | |||
| @@ -406,6 +406,11 @@ static inline void hlist_add_after_rcu(struct hlist_node *prev, | |||
| 406 | n->next->pprev = &n->next; | 406 | n->next->pprev = &n->next; |
| 407 | } | 407 | } |
| 408 | 408 | ||
| 409 | #define __hlist_for_each_rcu(pos, head) \ | ||
| 410 | for (pos = rcu_dereference((head)->first); \ | ||
| 411 | pos && ({ prefetch(pos->next); 1; }); \ | ||
| 412 | pos = rcu_dereference(pos->next)) | ||
| 413 | |||
| 409 | /** | 414 | /** |
| 410 | * hlist_for_each_entry_rcu - iterate over rcu list of given type | 415 | * hlist_for_each_entry_rcu - iterate over rcu list of given type |
| 411 | * @tpos: the type * to use as a loop cursor. | 416 | * @tpos: the type * to use as a loop cursor. |
