/* read-side C.S. duration, in loops */
static unsigned long wdelay;
-static inline void loop_sleep(unsigned long l)
+static inline void loop_sleep(unsigned long loops)
{
- while(l-- != 0)
+ while (loops-- != 0)
caa_cpu_relax();
}
for (;;) {
struct cds_lfs_node_rcu *snode;
- struct test *node;
rcu_read_lock();
snode = cds_lfs_pop_rcu(&s);
- node = caa_container_of(snode, struct test, list);
rcu_read_unlock();
- if (node) {
+ if (snode) {
+ struct test *node;
+
+ node = caa_container_of(snode, struct test, list);
call_rcu(&node->rcu, free_node_cb);
URCU_TLS(nr_successful_dequeues)++;
}