~ubuntu-branches/ubuntu/wily/linux-ti-omap4/wily

« back to all changes in this revision

Viewing changes to include/linux/rculist_nulls.h

  • Committer: Package Import Robot
  • Author(s): Paolo Pisati, Paolo Pisati
  • Date: 2013-07-11 18:35:20 UTC
  • Revision ID: package-import@ubuntu.com-20130711183520-htnf1x4y5r11hndr
Tags: 3.5.0-229.42
* Release Tracking Bug
  - LP: #1199276

[ Paolo Pisati ]

* [Config] CONFIG_ATH9K_LEGACY_RATE_CONTROL is not set

Show diffs side-by-side

added added

removed removed

Lines of Context:
105
105
 * @head:       the head for your list.
106
106
 * @member:     the name of the hlist_nulls_node within the struct.
107
107
 *
 
108
 * The barrier() is needed to make sure compiler doesn't cache first element [1],
 
109
 * as this loop can be restarted [2]
 
110
 * [1] Documentation/atomic_ops.txt around line 114
 
111
 * [2] Documentation/RCU/rculist_nulls.txt around line 146
108
112
 */
109
113
#define hlist_nulls_for_each_entry_rcu(tpos, pos, head, member)                 \
110
 
        for (pos = rcu_dereference_raw(hlist_nulls_first_rcu(head));            \
 
114
        for (({barrier();}),                                                    \
 
115
             pos = rcu_dereference_raw(hlist_nulls_first_rcu(head));            \
111
116
                (!is_a_nulls(pos)) &&                                           \
112
117
                ({ tpos = hlist_nulls_entry(pos, typeof(*tpos), member); 1; }); \
113
118
                pos = rcu_dereference_raw(hlist_nulls_next_rcu(pos)))