Go to the documentation of this file. 1 #ifndef _LINUX_LIST_NULLS_H
2 #define _LINUX_LIST_NULLS_H
24 #define INIT_HLIST_NULLS_HEAD(ptr, nulls) \
25 ((ptr)->first = (struct hlist_nulls_node *) (1UL | (((long)nulls) << 1)))
27 #define hlist_nulls_entry(ptr, type, member) container_of(ptr,type,member)
35 return ((
unsigned long)ptr & 1);
46 return ((
unsigned long)ptr) >> 1;
56 return is_a_nulls(h->
first);
67 if (!is_a_nulls(first))
76 if (!is_a_nulls(next))
94 #define hlist_nulls_for_each_entry(tpos, pos, head, member) \
95 for (pos = (head)->first; \
96 (!is_a_nulls(pos)) && \
97 ({ tpos = hlist_nulls_entry(pos, typeof(*tpos), member); 1;}); \
107 #define hlist_nulls_for_each_entry_from(tpos, pos, member) \
108 for (; (!is_a_nulls(pos)) && \
109 ({ tpos = hlist_nulls_entry(pos, typeof(*tpos), member); 1;}); \