Add cds_lfht_first/cds_lfht_next for hash table iteration
[urcu.git] / urcu / rculfhash.h
index 5e149ef629de692fbc5b1f4aeed371269d18b2b4..0a739ee86f7d11b1e9caa4b8bbb9091dbc0ff1b9 100644 (file)
@@ -197,6 +197,23 @@ void cds_lfht_lookup(struct cds_lfht *ht, void *key, size_t key_len,
  */
 void cds_lfht_next_duplicate(struct cds_lfht *ht, struct cds_lfht_iter *iter);
 
+/*
+ * cds_lfht_first - get the first node in the table.
+ *
+ * Output in "*iter". *iter->node set to NULL if table is empty.
+ * Call with rcu_read_lock held.
+ */
+void cds_lfht_first(struct cds_lfht *ht, struct cds_lfht_iter *iter);
+
+/*
+ * cds_lfht_next - get the next node in the table.
+ *
+ * Input/Output in "*iter". *iter->node set to NULL if *iter was
+ * pointing to the last table node.
+ * Call with rcu_read_lock held.
+ */
+void cds_lfht_next(struct cds_lfht *ht, struct cds_lfht_iter *iter);
+
 /*
  * cds_lfht_add - add a node to the hash table.
  *
This page took 0.022759 seconds and 4 git commands to generate.