10 Data-Structures
10 Data-Structures
struct list_head {
struct list_head *next, *prev;
};
Circular Doubly-Linked Lists
struct my_struct {
int priority;
struct list_head list1;
struct list_head list1;
int other_member;
};
Circular Doubly-Linked Lists
Circular Doubly-Linked Lists
How to use Lists
C
2
A
3
list_head sorted_by_char
list_head sorted_by_num B
1
struct list_head {
struct list_head *next, *prev;
};
struct hlist_head {
struct hlist_node *first;
};
struct hlist_node {
struct hlist_node *next, **pprev;
Hash Lists
hlist_head
hlist_node *first
hlist_node
hlist_node
GS = A
CPU 0 CPU 1
GDTR GDTR
GS = B
RAM