summaryrefslogtreecommitdiff
path: root/kernel/lib/list.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/lib/list.h')
-rw-r--r--kernel/lib/list.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/kernel/lib/list.h b/kernel/lib/list.h
new file mode 100644
index 0000000..8c3cce4
--- /dev/null
+++ b/kernel/lib/list.h
@@ -0,0 +1,13 @@
+#ifndef LIST_H
+#define LIST_H
+struct list {
+ void **entries;
+ int tail_index;
+};
+
+int list_init(struct list *list);
+void list_reset(struct list *list);
+void list_free(struct list *list);
+int list_add(struct list *list, void *entry);
+int list_get(const struct list *list, int index, void **out);
+#endif